IconButton: IconButtons are now correctly aligned in Safari (#48759)

* fix icon alignment in safari

* add comment
This commit is contained in:
Ashley Harrison 2022-05-17 11:03:35 +01:00 committed by GitHub
parent 18cbea84b1
commit a3e68eef17
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -20,14 +20,15 @@ export interface IconProps extends React.HTMLAttributes<HTMLDivElement> {
const getIconStyles = stylesFactory((theme: GrafanaTheme) => {
return {
// line-height: 0; is needed for correct icon alignment in Safari
container: css`
label: Icon;
display: inline-block;
line-height: 0;
`,
icon: css`
vertical-align: middle;
display: inline-block;
margin-bottom: ${theme.spacing.xxs};
fill: currentColor;
`,
orange: css`

View File

@ -154,7 +154,6 @@ const getStyles = stylesFactory((theme: GrafanaTheme2, size: IconSize, variant:
}
`,
icon: css`
margin-bottom: 0;
vertical-align: baseline;
display: flex;
`,