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

fix(docsConfigProvider): Fix the issue where the ConfigProvider theme… #13187

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

lzxiaoqi
Copy link
Contributor

@lzxiaoqi lzxiaoqi commented Nov 4, 2024

… switching causes the theme styles to stack up in the document.

Before submitting a pull request, please read the contributing guide.

在提交 pull request 之前,请阅读 贡献指南

解决#13179

这个bug存在于文档ConfigProvider全局配置的demo中,并且只有暗色主题存在这个问题,看了下源码,发现应该是在顶部切换主题的时候会默认执行增删van-theme-dark 和van-theme-light逻辑,而ConfigProvider全局配置内部引入了ConfigProvider在加载时会默认添加van-theme-light,应该算是文档的一个小bug,修复逻辑是暂时在ConfigProvider全局配置的示例文件中,如果同时存在这两种主题的话将van-theme-light属性删除,不会影响其他

… switching causes the theme styles to stack up in the document.
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.65%. Comparing base (379f44a) to head (af0d041).
Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #13187      +/-   ##
==========================================
- Coverage   89.67%   89.65%   -0.03%     
==========================================
  Files         257      257              
  Lines        7004     7006       +2     
  Branches     1732     1733       +1     
==========================================
  Hits         6281     6281              
- Misses        378      382       +4     
+ Partials      345      343       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants