Skip to content
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

Enhance-tailwind #19

Merged
merged 7 commits into from
Dec 8, 2023
Merged

Enhance-tailwind #19

merged 7 commits into from
Dec 8, 2023

Conversation

mayank1513
Copy link
Member

@mayank1513 mayank1513 commented Dec 8, 2023

2.0.0

Major Changes

  • 6f17cce: # Additonal CSS Combinations + Ensure seamless support for Tailwind

    • No changes required for client side code as [data-theme=] selectors work as before.
    • If you are using ServerSideWrapper or NextJsServerTarget or NextJsSSGThemeSwitcher, you need to convert forcedPages elements to objects of the shape { pathMatcher: RegExp | string; props: ThemeSwitcherProps }.
    • Use resolvedColorScheme for more sturdy dark/light/system modes
    • Use combinations of [data-th=""] and [data-color-scheme=""] for dark/light varients of themes
    • Use [data-csp=""] to style based on colorSchemePreference.

Minor Changes

  • Support custom themeTransition

    • Provide themeTransition prop to ThemeSwitcher component to apply smooth transition while changing theme.
    • Use setThemeSet to set lightTheme and darkTheme together.

@mayank1513 mayank1513 self-assigned this Dec 8, 2023
@mayank1513 mayank1513 merged commit 9da7693 into main Dec 8, 2023
2 checks passed
@mayank1513 mayank1513 deleted the enhance-tailwind branch December 8, 2023 15:18
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.

None yet

1 participant