Skip to content

Commit

Permalink
feat(Button)!: rename icon-size CSS API (#1972)
Browse files Browse the repository at this point in the history
  • Loading branch information
amje authored Dec 2, 2024
1 parent 30e8379 commit be1c107
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions src/components/Button/Button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -89,39 +89,39 @@ $block: '.#{variables.$ns}button';
--_--height: 20px;
--_--border-radius: var(--g-border-radius-xs);
--_--padding: 6px;
--_--icon-size: 12px;
--_--icon-space: 12px;
--_--icon-offset: 4px;
}

&_s {
--_--height: 24px;
--_--border-radius: var(--g-border-radius-s);
--_--padding: 8px;
--_--icon-size: 16px;
--_--icon-space: 16px;
--_--icon-offset: 4px;
}

&_m {
--_--height: 28px;
--_--border-radius: var(--g-border-radius-m);
--_--padding: 12px;
--_--icon-size: 16px;
--_--icon-space: 16px;
--_--icon-offset: 8px;
}

&_l {
--_--height: 36px;
--_--border-radius: var(--g-border-radius-l);
--_--padding: 16px;
--_--icon-size: 16px;
--_--icon-space: 16px;
--_--icon-offset: 8px;
}

&_xl {
--_--height: 44px;
--_--border-radius: var(--g-border-radius-xl);
--_--padding: 24px;
--_--icon-size: 20px;
--_--icon-space: 20px;
--_--icon-offset: 12px;
--_--font-size: var(--g-text-body-2-font-size);
}
Expand Down Expand Up @@ -269,8 +269,8 @@ $block: '.#{variables.$ns}button';
calc(
(
var(--g-button-height, var(--_--height)) - var(
--g-button-icon-size,
var(--_--icon-size)
--g-button-icon-space,
var(--_--icon-space)
)
) /
2 * -1
Expand Down
2 changes: 1 addition & 1 deletion src/components/Button/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -495,5 +495,5 @@ LANDING_BLOCK-->
| `--g-button-padding` | Side paddings |
| `--g-button-border-radius` | Border radius |
| `--g-button-font-size` | Text font size |
| `--g-button-icon-size` | Icon size |
| `--g-button-icon-space` | Icon available space |
| `--g-button-icon-offset` | Icon offset |

0 comments on commit be1c107

Please sign in to comment.