-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Primvue V4 Style Configuration : colorScheme Dark Surface Not Work as expected #5963
Comments
I think I have the same issue with 4.0.0-rc.2. As I understand the new theming system, the Aura preset sets the fieldset background to If I'm correct, in the example, the background of the fieldset should be #00ffff in light theme and The css variable |
There is a bug in how "toggleTheme" is implemented. It should be the following:
That is why you aren't seeing the update when the theme "switches" (because it isn't currently switching). |
Wow thanks! The documentation needs to be updated (https://primevue.org/theming/styled/#darkmodetoggle). |
And that is the solution, Thanks man. |
So far, I still can't switch between light and dark colors, according to the code in the documentation |
This works for me. |
Describe the bug
surface Variables: Still Take the root variables for light and dark mode
semantic: {
colorScheme: {
light: {
surface: {
0: '#00ffff',
50: '{zinc.50}',
100: '{zinc.100}',
200: '{zinc.200}',
300: '{zinc.300}',
400: '{zinc.400}',
500: '{zinc.500}',
600: '{zinc.600}',
700: '{zinc.700}',
800: '{zinc.800}',
900: '{zinc.900}',
950: '{zinc.950}',
},
},
dark: {
surface: {
0: '#ff2',
50: '{slate.50}',
100: '{slate.100}',
200: '{slate.200}',
300: '{slate.300}',
400: '{slate.400}',
500: '{slate.500}',
600: '{slate.600}',
700: '{slate.700}',
800: '{slate.800}',
900: '{slate.900}',
950: '{slate.950}',
},
},
},
},
.
Reproducer
https://stackblitz.com/edit/nuxt-starter-dhgcfm?file=theme.js
PrimeVue version
4.0.0-rc.2
Vue version
3.x
Language
TypeScript
Build / Runtime
Vue CLI App
Browser(s)
Chrome
Steps to reproduce the behavior
Go to the repro link:
https://stackblitz.com/edit/nuxt-starter-dhgcfm?file=theme.js
Expected behavior
No response
The text was updated successfully, but these errors were encountered: