Skip to content

[FIX] Improve dark mode text contrast on landing and shared components (Fixes #11)#12

Merged
CipherYuvraj merged 1 commit intoCipherYuvraj:mainfrom
debangshu919:fix/dark-mode-text-contrast
Oct 3, 2025
Merged

[FIX] Improve dark mode text contrast on landing and shared components (Fixes #11)#12
CipherYuvraj merged 1 commit intoCipherYuvraj:mainfrom
debangshu919:fix/dark-mode-text-contrast

Conversation

@debangshu919
Copy link
Contributor

Summary

This PR addresses unreadable text in dark mode where content blended into the background. It enables Tailwind's class-based dark mode and updates landing page typography and cards to use appropriate dark: color tokens with sufficient contrast.

Linked Issue

resolves #11

Changes

  • Enable Tailwind dark mode class strategy
    • frontend/tailwind.config.js: darkMode: 'class'
  • Global background/text defaults for dark mode
    • frontend/src/index.css: add .dark body { background-color: #111827; color: #e5e7eb; }
  • Landing page contrast fixes
    • frontend/src/pages/Home.jsx:
      • Headings and paragraphs: add dark:text-white and dark:text-gray-300
      • Feature cards: dark:bg-gray-800, dark:text-white, dark:text-gray-300
      • Category cards: dark:bg-gray-800, headings/desc updated for dark
      • Algorithm tags: dark:bg-gray-700, dark:text-gray-200

Testing

  • Manual checks across routes with theme toggle:
    • All texts are readable in dark mode.
    • Light mode remains visually consistent.

Screenshots

image image

Checklist

  • Dark mode enabled via class strategy
  • Landing page text meets contrast guidelines
  • Changes scoped and tested locally

@CipherYuvraj CipherYuvraj merged commit 958b96c into CipherYuvraj:main Oct 3, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Texts not visible in dark mode

2 participants

Comments