nuxt-modules / color-mode

Dark and Light mode with auto detection made easy with Nuxt 🌗
https://color-mode.nuxtjs.org
MIT License
1.12k stars 112 forks source link

feat: add `disableTransition` option and set default to `true` #192

Closed zcf0508 closed 8 months ago

zcf0508 commented 1 year ago

Reference:

https://vueuse.org/core/useColorMode/ https://paco.me/writing/disable-theme-transitions

netlify[bot] commented 1 year ago

Deploy Preview for nuxt-color-mode ready!

Name Link
Latest commit 8e8f17100633d955d717a488326d826e831fc393
Latest deploy log https://app.netlify.com/sites/nuxt-color-mode/deploys/65fbfe08766a8b00084ba159
Deploy Preview https://deploy-preview-192--nuxt-color-mode.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

antfu commented 1 year ago

I am a bit hesitate if this should be enabled by default. Would love to have some feedback from the community.

antfu commented 1 year ago

I think it might be better to have it default to false for now, so we can move forward. Later we could revise the defaults on the next major

zcf0508 commented 1 year ago

I think it might be better to have it default to false for now, so we can move forward. Later we could revise the defaults on the next major

OK, I think it is better too.

hacknug commented 1 year ago

Perhaps default could come from @media/prefers-reduced-motion and then config allows you to force enable/disable.

In case it counts, I'd prefer transitions to be disabled by default.

fos7er commented 1 year ago

I'm looking forward for this feature