Open xuanxuan321 opened 10 months ago
macOS
Chrome
黑暗模式下,每次进入页面的时候,都回会先闪烁一下浅色模式,然后再切换回暗色模式
黑暗模式下,每次进入页面的时候,都不要出现闪烁
访问这个页面https://dumi-theme.lobehub.com/components/action-icon,然后切换到黑暗模式,刷新页面即可复现
No response
原因是 ssr 渲染只包含了亮色主题,没有暗色主题。因此首先渲染的html是亮色的。等到 js加载完才会变成暗色。这个是目前 cssinjs 遇到的一个问题,正在研究怎么解决。
💻 系统环境 | Operating System
macOS
🌐 浏览器 | Browser
Chrome
🐛 问题描述 | Bug Description
黑暗模式下,每次进入页面的时候,都回会先闪烁一下浅色模式,然后再切换回暗色模式
🚦 期望结果 | Expected Behavior
黑暗模式下,每次进入页面的时候,都不要出现闪烁
📷 复现步骤 | Recurrence Steps
访问这个页面https://dumi-theme.lobehub.com/components/action-icon,然后切换到黑暗模式,刷新页面即可复现
📝 补充信息 | Additional Information
No response