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

optimize(projects): supports custom menu icon sizes #534

Merged
merged 1 commit into from
Jul 9, 2024

Conversation

wynn-w
Copy link
Contributor

@wynn-w wynn-w commented Jul 9, 2024

修改菜单栏的图标时( naive UI 的 Menu 组件), 使用组件的 theme-overrides 方法修改图标大小无效。
原因:路由初始化使用 SvgIconVNode 方法,在 svg 的根标签上注入了 font-size 属性。导致 theme-overrides 在父元素设置的 font-size 无法影响到 svg 元素。

  • 考虑到向前兼容的问题,RouteMeta 添加可选属性 iconFontSize,以控制图标大小

@honghuangdc honghuangdc merged commit e035eab into soybeanjs:main Jul 9, 2024
@Azir-11
Copy link
Member

Azir-11 commented Jul 9, 2024

感兴趣在文档里也补充一下相关meta信息吗?比较忙的话我代劳也行

@wynn-w
Copy link
Contributor Author

wynn-w commented Jul 9, 2024

感兴趣在文档里也补充一下相关meta信息吗?比较忙的话我代劳也行

对文档不太熟,还是辛苦老哥吧🤣

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.

3 participants