Commit 4c02ee4
authored
fix: restore icon centering after MUI v9 upgrade (#12440)
MUI v5's Box converted the system prop fontSize={0} to font-size: 0,
zeroing the strut so the svg child filled the icon span. Since the v9
upgrade (52d5bce) Box only styles through sx, so the prop was passed
through as a dead font-size="0" DOM attribute and every s:true icon
(svg child path) drifted down a few px inside text-sized containers
(e.g. MaskBlue size={16} in the ProfileCard avatar badge).
Move fontSize: 0 into the sx base style (restoring v5 semantics), add
lineHeight: 0 to guard against host pages inheriting an absolute
line-height, and drop the dead prop.1 parent f5be376 commit 4c02ee4
1 file changed
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
36 | 39 | | |
37 | 40 | | |
38 | 41 | | |
| |||
56 | 59 | | |
57 | 60 | | |
58 | 61 | | |
59 | | - | |
60 | | - | |
61 | 62 | | |
62 | 63 | | |
63 | 64 | | |
| |||
0 commit comments