You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "adoin (via GitHub)" <gi...@apache.org> on 2023/06/06 07:13:14 UTC

[GitHub] [echarts] adoin commented on issue #18716: [Feature] 动态主题切换需求,实现思路(CSS var)

adoin commented on issue #18716:
URL: https://github.com/apache/echarts/issues/18716#issuecomment-1578053947

   > 切换主题重新 echarts.init 就行了,用 CSS 是想解决什么问题?Canvas 肯定是要重绘的,所以放在 CSS 里似乎没什么用。
   
   举个例子,你在100个页面里写了120个Echarts,那么你的主题切换方法需要写120次。
   而css变量则不需要,外部切换主题能让所有颜色自动切换。
   当然canvas难点,源码里引入mitt之类的事件机制技术栈辅助实现,唤起重绘方法。


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org