Skip to content

Commit

Permalink
fix: pass rest props to the icon button container (#496)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlanFnz authored Nov 25, 2024
1 parent 35c3979 commit a4a606e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/experimental/IconButton/IconButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,8 @@ export const IconButton = ({
isLoading = false,
Icon,
variant = 'standard',
onPress
onPress,
...restProps
}: IconButtonProps): ReactElement => {
const Container = variant === 'standard' ? StandardIconContainer : TonalIconContainer;

Expand All @@ -120,6 +121,7 @@ export const IconButton = ({
isDisabled={isDisabled}
isActive={isActive}
isPending={isLoading}
{...restProps}
>
{isLoading ? (
<InlineSpinner data-testid="iconbutton-spinner" color={getSemanticValue('on-surface')} />
Expand Down

0 comments on commit a4a606e

Please sign in to comment.