angular / angular/components

icon: Keep symbol viewBox value when register an iconSet

未关闭
#5,488 11 条评论 11 个 reaction 已指派 0 人 在 GitHub 查看
area: material/icon P4
主要语言
TypeScript
星标
25k
派生
6.8k
平均合并
1 天 8 小时
30 天内合并 PR
91

描述

#### Bug, feature request, or proposal:
Bug

#### What is the expected behavior?
When registering an SVG iconSet, every symbol may provide a custom `viewBox` attribute. This attribute should be keep in the newly SVG element created.

#### What is the current behavior?
The `viewBox` attribute is swallowed.

#### What are the steps to reproduce?

#### What is the use-case or motivation for changing an existing behavior?

#### Which versions of Angular, Material, OS, TypeScript, browsers are affected?
At least since beta 7

#### Is there anything else we should know?
This is related to #5188 #2981
For SVG icon set with `symbol`, see

贡献指南

打开贡献指南

调研方向

issue 中没有指定文件或测试。首先跟踪 iconSet 的注册和 SVG 符号的创建,然后验证每个符号的自定义 viewBox 是否会保留在新创建的 SVG 元素中,并为该行为添加覆盖测试。

由索引模型根据 Issue 内容生成。

评估

技术栈
angular, typescript
领域
frontend
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。