PrimaryIconButton
The Primary Icon Button serves as a visually prominent interactive element for high-priority, icon-only actions. It is typically used in scenarios where a traditional primary button would be placed, but the action is better represented by a single, recognizable icon (e.g., quick add to cart):
![]()
If need be, the button can also be disabled:
![]()
Parameters
The Painter for the icon to display.
The action to perform when the button is clicked. Not performed when the button is disabled.
Optional Modifier to be applied to the PrimaryIconButton. Defaults to Modifier.
Whether the button is enabled or not. Defaults to true.
The String describing the icon button for accessibility.
Optional hoisted MutableInteractionSource for observing and emitting Interactions for this icon button. You can use this to change the button's appearance or preview the button in different states. Defaults to a remembered MutableInteractionSource.