Skip to content

Commit

Permalink
[StepIcon] Fix text centering when changing browser font size (#32706)
Browse files Browse the repository at this point in the history
  • Loading branch information
alansouzati committed Jun 8, 2022
1 parent 783499b commit 9b19d91
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/mui-material/src/StepIcon/StepIcon.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,9 @@ const StepIcon = React.forwardRef(function StepIcon(inProps, ref) {
<StepIconText
className={classes.text}
x="12"
y="16"
y="12"
textAnchor="middle"
dominantBaseline="central"
ownerState={ownerState}
>
{icon}
Expand Down
17 changes: 17 additions & 0 deletions test/regressions/fixtures/StepIcon/BiggerStepIconREM.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import * as React from 'react';
import StepIcon from '@mui/material/StepIcon';
import GlobalStyles from '@mui/material/GlobalStyles';

export default function BiggerStepIconREM() {
return (
<React.Fragment>
<GlobalStyles
styles={{
html: { fontSize: '24px' },
}}
/>
<StepIcon completed icon={1} />
<StepIcon icon={2} />
</React.Fragment>
);
}

0 comments on commit 9b19d91

Please sign in to comment.