Skip to content

Fix dark theme slider showing wrong status when canceling#407

Open
Grohiik wants to merge 1 commit intomainfrom
neea/fix_dark_slider
Open

Fix dark theme slider showing wrong status when canceling#407
Grohiik wants to merge 1 commit intomainfrom
neea/fix_dark_slider

Conversation

@Grohiik
Copy link
Collaborator

@Grohiik Grohiik commented Mar 6, 2026

No description provided.

Copy link
Owner

@CodeyBoi CodeyBoi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it, rather than changing Switch behaviour, would be better to have the Switch be a controlled element tied to the colorscheme value, i.e. use the first return value of useState as value in the Switch component and update the colorscheme when changing that value.

Right now the Switch's initial state is still off even if the colorscheme is dark when first entering the page (or refreshing). I think the above suggestion would fix both issues.

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.

2 participants