Skip to content

Conversation

@abolix
Copy link

@abolix abolix commented Sep 4, 2025

This fixes an issue where explicitly configured color mode preferences (like preference: 'light') would be overridden by previously stored values from localStorage/cookies.

When a user sets preference to a specific mode (not 'system'), it should take precedence over any stored preferences from previous sessions.

Fixes: Color mode preference not respected when switching between projects

🔗 Linked issue

Fixes #318

❓ Type of change

  • 📖 Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

This fixes an issue where explicitly configured color mode preferences
(like preference: 'light') would be overridden by previously stored
values from localStorage/cookies.

When a user sets preference to a specific mode (not 'system'), it should
take precedence over any stored preferences from previous sessions.

Fixes: Color mode preference not respected when switching between projects
@netlify
Copy link

netlify bot commented Sep 4, 2025

👷 Deploy Preview for nuxt-color-mode processing.

Name Link
🔨 Latest commit bbfadef
🔍 Latest deploy log https://app.netlify.com/projects/nuxt-color-mode/deploys/68b957c19f68c70007611b3a

@netlify
Copy link

netlify bot commented Sep 4, 2025

Deploy Preview for nuxt-color-mode canceled.

Name Link
🔨 Latest commit dc1002d
🔍 Latest deploy log https://app.netlify.com/projects/nuxt-color-mode/deploys/68c1335d958d5500086fc276

- Remove trailing spaces on empty lines to fix linting error
- Fixes @stylistic/no-trailing-spaces eslint rule
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

forced dark and light mode in 2 different projects

1 participant