Skip to content

Commit c0e8619

Browse files
committed
fix(Button): actions
1 parent 508f1ec commit c0e8619

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/components/actions/ItemAction/ItemAction.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,12 @@ const ItemActionElement = tasty({
8181
'$local-icon-size': 'var(--icon-size)',
8282

8383
Icon: {
84+
...(ITEM_ACTION_BASE_STYLES.Icon as Styles),
8485
'$icon-size': 'min($local-icon-size, ($action-size - .5x))',
8586
},
8687

8788
RightIcon: {
89+
...(ITEM_ACTION_BASE_STYLES.Icon as Styles),
8890
'$icon-size': 'min($local-icon-size, ($action-size - .5x))',
8991
},
9092
},

src/components/actions/ItemButton/ItemButton.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,10 @@ const ActionsWrapper = tasty({
7979
},
8080
transition: 'theme, translate',
8181

82-
'$side-padding': 'max(min(.5x, (($size - 3x + 2bw) / 2)), 1bw)',
82+
// Size for the action buttons
83+
'$action-size': 'min(max((2x + 2bw), ($size - 1x - 2bw)), (4x - 2bw))',
84+
// Side padding for the button
85+
'$side-padding': '(($size - $action-size - 2bw) / 2)',
8386
},
8487
},
8588
});

0 commit comments

Comments
 (0)