Axon 911 Frontend DocsAxon 911 Frontend Docs
Axon 911 Frontend Docs
    Loading navigation…
U
User
Switch to light mode
  1. Components
  2. Icon Button
  3. API and Development

Icon Button

API and Development

View SourceOpens in a new tabSubmit IssueOpens in a new tab
An icon-only action is Button from @prepared911/ui/button with icon and label and no children. The label is visually hidden and is the accessible name. tooltip is optional hover copy. There is no separate icon-button component, no pill prop, and no ButtonType.
Props
NameDefaultDescription
iconrequired with labelA glyph, usually <Icon glyph={...} />.
labelrequired with iconLocalized accessible name. It is not a separate tooltip.
tooltipnoneExtra hover copy. Placement belongs to Tooltip.
intentButtonIntent.NeutralAccent, Destructive, Success, or Warning.
variantButtonVariant.SoftSolid, Ghost, or Plain. Ghost is the usual in-field and toolbar look.
sizeButtonSize.LargeSmall (24px), Medium (28px), or Large (32px).
disabledfalseWhether the button is disabled.
onClickFunction to call on click.
onMouseEnterFunction to call on mouse enter.
onMouseLeaveFunction to call on mouse leave.
onMouseDownFunction to call on mouse down.
onMouseUpFunction to call on mouse up.
classNameAdditional CSS classes to apply.
togglefalseNon-link only. Opt in to sustained aria-pressed via standalone Radix Toggle (asChild). Inherited from Button.
pressed / defaultPressed / onPressedChangeNon-link only. Controlled or uncontrolled pressed state when toggle is true. Link Button strips these props before spreading onto the DOM.
Critical
Use for important icon actions that change significant product state, allowing one critical button per page.
Primary
Use for the most important icon action on a page or within a specific section.
Secondary
Use for standard icon actions throughout the interface.
Badge
Pass the pill prop to opt in to a fully rounded (pill / circular) border radius. Intended for floating toolbars and FAB-style controls such as the staff panel toggle. pill works with any ButtonType; combine with cornerStyle={ComponentCornerStyle.Sharp} to override back to square corners when a brand or layout requires it.
Secondary Alt
Use for icon actions of lesser importance when differentiating from primary actions.
Link
Use for icon buttons that function as navigation links or subtle actions.
Semantic Types
Semantic icon buttons give users visual cues about their purpose through color.
Success
Use to indicate constructive icon actions or confirmations of positive states.
Destructive
Use to indicate destructive icon actions such as deleting or removing content.
Sizes
Button shares the same three sizes as Button for consistent density.
Disabled State
Use for unavailable actions, ensuring the tooltip explains why the action is unavailable.
Common Icon Actions
Use appropriate icons for standard actions to maintain consistency.
Add Actions
Edit Actions
Delete Actions
More Options
Close or Dismiss
Search
Navigation
Icon Button Groups
Use to group related icon actions together for logical organization.
Table Row Actions
Use in table rows to provide contextual actions for each item.
With Conditional States
Use to show different icons or states based on application logic.
Previous
Icon Button / Usage
Next
Icon Button / Accessibility
On this page
Props
Critical
Primary
Secondary
Badge
Secondary Alt
Link
Semantic Types
Success
Destructive
Sizes
Disabled State
Common Icon Actions
Add Actions
Edit Actions
Delete Actions
More Options
Close or Dismiss
Search
Navigation
Icon Button Groups
Table Row Actions
With Conditional States