Skip to content

Tag Group

Free

A row of tags that people can read, remove, pick as filters, or open as links. The arrow keys move from tag to tag.

  • Base UI
  • React Aria
  • Motion
  • React 19
  • Tailwind CSS 4

Added Nov 9, 2026 · MIT + Commons Clause

Playground

Loading the preview

Props

Set selectionMode to pick tags, or pass onRemove to remove them. A tag with href is a link.

status-filter.tsx

TagGroup

PropTypeDefaultDescription
aria-labelstring—Defines a string value that labels the current element.
aria-labelledbystring—Identifies the element (or elements) that labels the current element.
aria-describedbystring—Identifies the element (or elements) that describes the object.
aria-detailsstring—Identifies the element (or elements) that provide a detailed, extended description for the object.
idstring—The element's unique identifier. See MDN.
dirstring—
langstring—
hiddenboolean—
inertboolean—
translate"no""yes"—
suppressHydrationWarningboolean—A React-only flag that suppresses the warning React normally logs when an element's server-rendered content doesn't match the client render during hydration. See React docs.
onClickMouseEventHandler<HTMLDivElement>—
onClickCaptureMouseEventHandler<HTMLDivElement>—
onAuxClickMouseEventHandler<HTMLDivElement>—
onAuxClickCaptureMouseEventHandler<HTMLDivElement>—
onContextMenuMouseEventHandler<HTMLDivElement>—
onContextMenuCaptureMouseEventHandler<HTMLDivElement>—
onDoubleClickMouseEventHandler<HTMLDivElement>—
onDoubleClickCaptureMouseEventHandler<HTMLDivElement>—
onMouseDownMouseEventHandler<HTMLDivElement>—
onMouseDownCaptureMouseEventHandler<HTMLDivElement>—
onMouseEnterMouseEventHandler<HTMLDivElement>—
onMouseLeaveMouseEventHandler<HTMLDivElement>—
onMouseMoveMouseEventHandler<HTMLDivElement>—
onMouseMoveCaptureMouseEventHandler<HTMLDivElement>—
onMouseOutMouseEventHandler<HTMLDivElement>—
onMouseOutCaptureMouseEventHandler<HTMLDivElement>—
onMouseOverMouseEventHandler<HTMLDivElement>—
onMouseOverCaptureMouseEventHandler<HTMLDivElement>—
onMouseUpMouseEventHandler<HTMLDivElement>—
onMouseUpCaptureMouseEventHandler<HTMLDivElement>—
onTouchCancelTouchEventHandler<HTMLDivElement>—
onTouchCancelCaptureTouchEventHandler<HTMLDivElement>—
onTouchEndTouchEventHandler<HTMLDivElement>—
onTouchEndCaptureTouchEventHandler<HTMLDivElement>—
onTouchMoveTouchEventHandler<HTMLDivElement>—
onTouchMoveCaptureTouchEventHandler<HTMLDivElement>—
onTouchStartTouchEventHandler<HTMLDivElement>—
onTouchStartCaptureTouchEventHandler<HTMLDivElement>—
onPointerDownPointerEventHandler<HTMLDivElement>—
onPointerDownCapturePointerEventHandler<HTMLDivElement>—
onPointerMovePointerEventHandler<HTMLDivElement>—
onPointerMoveCapturePointerEventHandler<HTMLDivElement>—
onPointerUpPointerEventHandler<HTMLDivElement>—
onPointerUpCapturePointerEventHandler<HTMLDivElement>—
onPointerCancelPointerEventHandler<HTMLDivElement>—
onPointerCancelCapturePointerEventHandler<HTMLDivElement>—
onPointerEnterPointerEventHandler<HTMLDivElement>—
onPointerLeavePointerEventHandler<HTMLDivElement>—
onPointerOverPointerEventHandler<HTMLDivElement>—
onPointerOverCapturePointerEventHandler<HTMLDivElement>—
onPointerOutPointerEventHandler<HTMLDivElement>—
onPointerOutCapturePointerEventHandler<HTMLDivElement>—
onGotPointerCapturePointerEventHandler<HTMLDivElement>—
onGotPointerCaptureCapturePointerEventHandler<HTMLDivElement>—
onLostPointerCapturePointerEventHandler<HTMLDivElement>—
onLostPointerCaptureCapturePointerEventHandler<HTMLDivElement>—
onScrollUIEventHandler<HTMLDivElement>—
onScrollCaptureUIEventHandler<HTMLDivElement>—
onWheelWheelEventHandler<HTMLDivElement>—
onWheelCaptureWheelEventHandler<HTMLDivElement>—
onAnimationStartAnimationEventHandler<HTMLDivElement>—
onAnimationStartCaptureAnimationEventHandler<HTMLDivElement>—
onAnimationEndAnimationEventHandler<HTMLDivElement>—
onAnimationEndCaptureAnimationEventHandler<HTMLDivElement>—
onAnimationIterationAnimationEventHandler<HTMLDivElement>—
onAnimationIterationCaptureAnimationEventHandler<HTMLDivElement>—
onTransitionCancelTransitionEventHandler<HTMLDivElement>—
onTransitionCancelCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionEndTransitionEventHandler<HTMLDivElement>—
onTransitionEndCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionRunTransitionEventHandler<HTMLDivElement>—
onTransitionRunCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionStartTransitionEventHandler<HTMLDivElement>—
onTransitionStartCaptureTransitionEventHandler<HTMLDivElement>—
selectionMode"multiple""none""single"—The type of selection that is allowed in the collection.
disallowEmptySelectionboolean—Whether the collection allows empty selection.
disabledKeysIterable<Key>—The item keys that are disabled. These items cannot be selected, focused, or otherwise interacted with.
styleCSSProperties—The inline style for the element.
childrenReactNode—The children of the component.
slotstring | null—A slot name for the component. Slots allow the component to receive props from a parent component. An explicit null value indicates that the local props completely override all props received from a parent.
renderDOMRenderFunction<"div", undefined>—Overrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.
onAction—Handler that is called when a user performs an action on an item. The exact user event depends on the collection's selectionBehavior prop and the interaction modality.
selectionBehavior"replace""toggle"'toggle'How multiple selection should behave in the collection.
shouldSelectOnPressUpboolean—Whether selection should occur on press up instead of press down.
onRemove—Handler that is called when a user deletes a tag.
escapeKeyBehavior"clearSelection""none"'clearSelection'Whether pressing the escape key should clear selection in the TagGroup or not. Most experiences should not modify this option as it eliminates a keyboard user's ability to easily clear selection. Only use if the escape key is being handled externally or should not trigger selection clearing contextually.
value"all" | Iterable<Key>—The picked keys (controlled).
defaultValue"all" | Iterable<Key>—The picked keys at first (uncontrolled).
onValueChange—Runs on each change, with the new picked keys and the Base UI change details.
classNamestring—
size"default""lg""sm""default"The tag height: sm 20px, default 24px (both 32px on touch), lg 28px (36px on touch), the chip sizes of #/lib/chip.
rounded"default""full""default"The tag corner: default 6px, or full, a pill with a round ×.

TagGroupLabel

<div>
PropTypeDefaultDescription
renderDOMRenderFunction<"label", undefined>—Overrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.
elementTypestring—
classNamestring—
...props<div> attributes—Every other attribute goes to the <div>.

TagGroupList

PropTypeDefaultDescription
dirstring—
langstring—
hiddenboolean—
inertboolean—
translate"no""yes"—
suppressHydrationWarningboolean—A React-only flag that suppresses the warning React normally logs when an element's server-rendered content doesn't match the client render during hydration. See React docs.
onClickMouseEventHandler<HTMLDivElement>—
onClickCaptureMouseEventHandler<HTMLDivElement>—
onAuxClickMouseEventHandler<HTMLDivElement>—
onAuxClickCaptureMouseEventHandler<HTMLDivElement>—
onContextMenuMouseEventHandler<HTMLDivElement>—
onContextMenuCaptureMouseEventHandler<HTMLDivElement>—
onDoubleClickMouseEventHandler<HTMLDivElement>—
onDoubleClickCaptureMouseEventHandler<HTMLDivElement>—
onMouseDownMouseEventHandler<HTMLDivElement>—
onMouseDownCaptureMouseEventHandler<HTMLDivElement>—
onMouseEnterMouseEventHandler<HTMLDivElement>—
onMouseLeaveMouseEventHandler<HTMLDivElement>—
onMouseMoveMouseEventHandler<HTMLDivElement>—
onMouseMoveCaptureMouseEventHandler<HTMLDivElement>—
onMouseOutMouseEventHandler<HTMLDivElement>—
onMouseOutCaptureMouseEventHandler<HTMLDivElement>—
onMouseOverMouseEventHandler<HTMLDivElement>—
onMouseOverCaptureMouseEventHandler<HTMLDivElement>—
onMouseUpMouseEventHandler<HTMLDivElement>—
onMouseUpCaptureMouseEventHandler<HTMLDivElement>—
onTouchCancelTouchEventHandler<HTMLDivElement>—
onTouchCancelCaptureTouchEventHandler<HTMLDivElement>—
onTouchEndTouchEventHandler<HTMLDivElement>—
onTouchEndCaptureTouchEventHandler<HTMLDivElement>—
onTouchMoveTouchEventHandler<HTMLDivElement>—
onTouchMoveCaptureTouchEventHandler<HTMLDivElement>—
onTouchStartTouchEventHandler<HTMLDivElement>—
onTouchStartCaptureTouchEventHandler<HTMLDivElement>—
onPointerDownPointerEventHandler<HTMLDivElement>—
onPointerDownCapturePointerEventHandler<HTMLDivElement>—
onPointerMovePointerEventHandler<HTMLDivElement>—
onPointerMoveCapturePointerEventHandler<HTMLDivElement>—
onPointerUpPointerEventHandler<HTMLDivElement>—
onPointerUpCapturePointerEventHandler<HTMLDivElement>—
onPointerCancelPointerEventHandler<HTMLDivElement>—
onPointerCancelCapturePointerEventHandler<HTMLDivElement>—
onPointerEnterPointerEventHandler<HTMLDivElement>—
onPointerLeavePointerEventHandler<HTMLDivElement>—
onPointerOverPointerEventHandler<HTMLDivElement>—
onPointerOverCapturePointerEventHandler<HTMLDivElement>—
onPointerOutPointerEventHandler<HTMLDivElement>—
onPointerOutCapturePointerEventHandler<HTMLDivElement>—
onGotPointerCapturePointerEventHandler<HTMLDivElement>—
onGotPointerCaptureCapturePointerEventHandler<HTMLDivElement>—
onLostPointerCapturePointerEventHandler<HTMLDivElement>—
onLostPointerCaptureCapturePointerEventHandler<HTMLDivElement>—
onScrollUIEventHandler<HTMLDivElement>—
onScrollCaptureUIEventHandler<HTMLDivElement>—
onWheelWheelEventHandler<HTMLDivElement>—
onWheelCaptureWheelEventHandler<HTMLDivElement>—
onAnimationStartAnimationEventHandler<HTMLDivElement>—
onAnimationStartCaptureAnimationEventHandler<HTMLDivElement>—
onAnimationEndAnimationEventHandler<HTMLDivElement>—
onAnimationEndCaptureAnimationEventHandler<HTMLDivElement>—
onAnimationIterationAnimationEventHandler<HTMLDivElement>—
onAnimationIterationCaptureAnimationEventHandler<HTMLDivElement>—
onTransitionCancelTransitionEventHandler<HTMLDivElement>—
onTransitionCancelCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionEndTransitionEventHandler<HTMLDivElement>—
onTransitionEndCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionRunTransitionEventHandler<HTMLDivElement>—
onTransitionRunCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionStartTransitionEventHandler<HTMLDivElement>—
onTransitionStartCaptureTransitionEventHandler<HTMLDivElement>—
itemsIterable<T>—Item objects in the collection.
styleStyleOrFunction<TagListRenderProps>—The inline style for the element. A function may be provided to compute the style based on component state.
render—Overrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.
children((item: T) => ReactNode) | ReactNode—The contents of the collection.
dependenciesreadonly any[]—Values that should invalidate the item cache when using dynamic collections.
renderEmptyState—Provides content to display when there are no items in the tag list.
classNamestring—
refRef<HTMLDivElement>—

TagGroupTag

PropTypeDefaultDescription
hrefstring—A URL to link to. See MDN.
hrefLangstring—Hints at the human language of the linked URL. SeeMDN.
target"_blank""_parent""_self""_top"string—The target window for the link. See MDN.
relstring—The relationship between the linked resource and the current page. See MDN.
downloadstring | boolean—Causes the browser to download the linked URL. A string may be provided to suggest a file name. See MDN.
pingstring—A space-separated list of URLs to ping when the link is followed. See MDN.
referrerPolicy"""no-referrer""no-referrer-when-downgrade""origin""origin-when-cross-origin""same-origin""strict-origin""strict-origin-when-cross-origin""unsafe-url"—How much of the referrer to send when following the link. See MDN.
routerOptions—Options for the configured client side router.
dirstring—
langstring—
hiddenboolean—
inertboolean—
translate"no""yes"—
suppressHydrationWarningboolean—A React-only flag that suppresses the warning React normally logs when an element's server-rendered content doesn't match the client render during hydration. See React docs.
onClickCaptureMouseEventHandler<HTMLDivElement>—
onAuxClickMouseEventHandler<HTMLDivElement>—
onAuxClickCaptureMouseEventHandler<HTMLDivElement>—
onContextMenuMouseEventHandler<HTMLDivElement>—
onContextMenuCaptureMouseEventHandler<HTMLDivElement>—
onDoubleClickMouseEventHandler<HTMLDivElement>—
onDoubleClickCaptureMouseEventHandler<HTMLDivElement>—
onMouseDownMouseEventHandler<HTMLDivElement>—
onMouseDownCaptureMouseEventHandler<HTMLDivElement>—
onMouseEnterMouseEventHandler<HTMLDivElement>—
onMouseLeaveMouseEventHandler<HTMLDivElement>—
onMouseMoveMouseEventHandler<HTMLDivElement>—
onMouseMoveCaptureMouseEventHandler<HTMLDivElement>—
onMouseOutMouseEventHandler<HTMLDivElement>—
onMouseOutCaptureMouseEventHandler<HTMLDivElement>—
onMouseOverMouseEventHandler<HTMLDivElement>—
onMouseOverCaptureMouseEventHandler<HTMLDivElement>—
onMouseUpMouseEventHandler<HTMLDivElement>—
onMouseUpCaptureMouseEventHandler<HTMLDivElement>—
onTouchCancelTouchEventHandler<HTMLDivElement>—
onTouchCancelCaptureTouchEventHandler<HTMLDivElement>—
onTouchEndTouchEventHandler<HTMLDivElement>—
onTouchEndCaptureTouchEventHandler<HTMLDivElement>—
onTouchMoveTouchEventHandler<HTMLDivElement>—
onTouchMoveCaptureTouchEventHandler<HTMLDivElement>—
onTouchStartTouchEventHandler<HTMLDivElement>—
onTouchStartCaptureTouchEventHandler<HTMLDivElement>—
onPointerDownPointerEventHandler<HTMLDivElement>—
onPointerDownCapturePointerEventHandler<HTMLDivElement>—
onPointerMovePointerEventHandler<HTMLDivElement>—
onPointerMoveCapturePointerEventHandler<HTMLDivElement>—
onPointerUpPointerEventHandler<HTMLDivElement>—
onPointerUpCapturePointerEventHandler<HTMLDivElement>—
onPointerCancelPointerEventHandler<HTMLDivElement>—
onPointerCancelCapturePointerEventHandler<HTMLDivElement>—
onPointerEnterPointerEventHandler<HTMLDivElement>—
onPointerLeavePointerEventHandler<HTMLDivElement>—
onPointerOverPointerEventHandler<HTMLDivElement>—
onPointerOverCapturePointerEventHandler<HTMLDivElement>—
onPointerOutPointerEventHandler<HTMLDivElement>—
onPointerOutCapturePointerEventHandler<HTMLDivElement>—
onGotPointerCapturePointerEventHandler<HTMLDivElement>—
onGotPointerCaptureCapturePointerEventHandler<HTMLDivElement>—
onLostPointerCapturePointerEventHandler<HTMLDivElement>—
onLostPointerCaptureCapturePointerEventHandler<HTMLDivElement>—
onScrollUIEventHandler<HTMLDivElement>—
onScrollCaptureUIEventHandler<HTMLDivElement>—
onWheelWheelEventHandler<HTMLDivElement>—
onWheelCaptureWheelEventHandler<HTMLDivElement>—
onAnimationStartAnimationEventHandler<HTMLDivElement>—
onAnimationStartCaptureAnimationEventHandler<HTMLDivElement>—
onAnimationEndAnimationEventHandler<HTMLDivElement>—
onAnimationEndCaptureAnimationEventHandler<HTMLDivElement>—
onAnimationIterationAnimationEventHandler<HTMLDivElement>—
onAnimationIterationCaptureAnimationEventHandler<HTMLDivElement>—
onTransitionCancelTransitionEventHandler<HTMLDivElement>—
onTransitionCancelCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionEndTransitionEventHandler<HTMLDivElement>—
onTransitionEndCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionRunTransitionEventHandler<HTMLDivElement>—
onTransitionRunCaptureTransitionEventHandler<HTMLDivElement>—
onTransitionStartTransitionEventHandler<HTMLDivElement>—
onTransitionStartCaptureTransitionEventHandler<HTMLDivElement>—
onFocus—Handler that is called when the element receives focus.
onBlur—Handler that is called when the element loses focus.
onFocusChange—Handler that is called when the element's focus status changes.
onHoverStart—Handler that is called when a hover interaction starts.
onHoverEnd—Handler that is called when a hover interaction ends.
onHoverChange—Handler that is called when the hover state changes.
onPress—Handler that is called when the press is released over the target.
onPressStart—Handler that is called when a press interaction starts.
onPressEnd—Handler that is called when a press interaction ends, either over the target or when the pointer leaves the target.
onPressChange—Handler that is called when the press state changes.
onPressUp—Handler that is called when a press is released over the target, regardless of whether it started on the target or not.
onClick—**Not recommended – use onPress instead.** onClick is an alias for onPress provided for compatibility with other libraries. onPress provides additional event details for non-mouse interactions.
styleStyleOrFunction<TagRenderProps>—The inline style for the element. A function may be provided to compute the style based on component state.
childrenChildrenOrFunction<TagRenderProps>—The children of the component. A function may be provided to alter the children based on component state.
renderDOMRenderFunction<"div", TagRenderProps>—Overrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.
idKey—A unique id for the tag.
textValuestring—A string representation of the tags's contents, used for accessibility. Required if children is not a plain text string.
onAction—Handler that is called when a user performs an action on the item. The exact user event depends on the collection's selectionBehavior prop and the interaction modality.
disabledboolean—Turns off the control: no focus, no edits, and the disabled look.
classNamestring—
refRef<HTMLDivElement>—

TagGroupTagRemove

PropTypeDefaultDescription
aria-labelstring—Defines a string value that labels the current element.
aria-labelledbystring—Identifies the element (or elements) that labels the current element.
aria-describedbystring—Identifies the element (or elements) that describes the object.
aria-detailsstring—Identifies the element (or elements) that provide a detailed, extended description for the object.
idstring—The element's unique identifier. See MDN.
excludeFromTabOrderboolean—Whether to exclude the element from the sequential tab order. If true, the element will not be focusable via the keyboard by tabbing. This should be avoided except in rare scenarios where an alternative means of accessing the element or its functionality via the keyboard is available.
dirstring—
langstring—
hiddenboolean—
inertboolean—
translate"no""yes"—
suppressHydrationWarningboolean—A React-only flag that suppresses the warning React normally logs when an element's server-rendered content doesn't match the client render during hydration. See React docs.
onClickCaptureMouseEventHandler<HTMLButtonElement>—
onAuxClickMouseEventHandler<HTMLButtonElement>—
onAuxClickCaptureMouseEventHandler<HTMLButtonElement>—
onContextMenuMouseEventHandler<HTMLButtonElement>—
onContextMenuCaptureMouseEventHandler<HTMLButtonElement>—
onDoubleClickMouseEventHandler<HTMLButtonElement>—
onDoubleClickCaptureMouseEventHandler<HTMLButtonElement>—
onMouseDownMouseEventHandler<HTMLButtonElement>—
onMouseDownCaptureMouseEventHandler<HTMLButtonElement>—
onMouseEnterMouseEventHandler<HTMLButtonElement>—
onMouseLeaveMouseEventHandler<HTMLButtonElement>—
onMouseMoveMouseEventHandler<HTMLButtonElement>—
onMouseMoveCaptureMouseEventHandler<HTMLButtonElement>—
onMouseOutMouseEventHandler<HTMLButtonElement>—
onMouseOutCaptureMouseEventHandler<HTMLButtonElement>—
onMouseOverMouseEventHandler<HTMLButtonElement>—
onMouseOverCaptureMouseEventHandler<HTMLButtonElement>—
onMouseUpMouseEventHandler<HTMLButtonElement>—
onMouseUpCaptureMouseEventHandler<HTMLButtonElement>—
onTouchCancelTouchEventHandler<HTMLButtonElement>—
onTouchCancelCaptureTouchEventHandler<HTMLButtonElement>—
onTouchEndTouchEventHandler<HTMLButtonElement>—
onTouchEndCaptureTouchEventHandler<HTMLButtonElement>—
onTouchMoveTouchEventHandler<HTMLButtonElement>—
onTouchMoveCaptureTouchEventHandler<HTMLButtonElement>—
onTouchStartTouchEventHandler<HTMLButtonElement>—
onTouchStartCaptureTouchEventHandler<HTMLButtonElement>—
onPointerDownPointerEventHandler<HTMLButtonElement>—
onPointerDownCapturePointerEventHandler<HTMLButtonElement>—
onPointerMovePointerEventHandler<HTMLButtonElement>—
onPointerMoveCapturePointerEventHandler<HTMLButtonElement>—
onPointerUpPointerEventHandler<HTMLButtonElement>—
onPointerUpCapturePointerEventHandler<HTMLButtonElement>—
onPointerCancelPointerEventHandler<HTMLButtonElement>—
onPointerCancelCapturePointerEventHandler<HTMLButtonElement>—
onPointerEnterPointerEventHandler<HTMLButtonElement>—
onPointerLeavePointerEventHandler<HTMLButtonElement>—
onPointerOverPointerEventHandler<HTMLButtonElement>—
onPointerOverCapturePointerEventHandler<HTMLButtonElement>—
onPointerOutPointerEventHandler<HTMLButtonElement>—
onPointerOutCapturePointerEventHandler<HTMLButtonElement>—
onGotPointerCapturePointerEventHandler<HTMLButtonElement>—
onGotPointerCaptureCapturePointerEventHandler<HTMLButtonElement>—
onLostPointerCapturePointerEventHandler<HTMLButtonElement>—
onLostPointerCaptureCapturePointerEventHandler<HTMLButtonElement>—
onScrollUIEventHandler<HTMLButtonElement>—
onScrollCaptureUIEventHandler<HTMLButtonElement>—
onWheelWheelEventHandler<HTMLButtonElement>—
onWheelCaptureWheelEventHandler<HTMLButtonElement>—
onAnimationStartAnimationEventHandler<HTMLButtonElement>—
onAnimationStartCaptureAnimationEventHandler<HTMLButtonElement>—
onAnimationEndAnimationEventHandler<HTMLButtonElement>—
onAnimationEndCaptureAnimationEventHandler<HTMLButtonElement>—
onAnimationIterationAnimationEventHandler<HTMLButtonElement>—
onAnimationIterationCaptureAnimationEventHandler<HTMLButtonElement>—
onTransitionCancel—
onTransitionCancelCapture—
onTransitionEnd—
onTransitionEndCapture—
onTransitionRun—
onTransitionRunCapture—
onTransitionStart—
onTransitionStartCapture—
onKeyDown—Handler that is called when a key is pressed.
onKeyUp—Handler that is called when a key is released.
onFocus—Handler that is called when the element receives focus.
onBlur—Handler that is called when the element loses focus.
onFocusChange—Handler that is called when the element's focus status changes.
onHoverStart—Handler that is called when a hover interaction starts.
onHoverEnd—Handler that is called when a hover interaction ends.
onHoverChange—Handler that is called when the hover state changes.
onPress—Handler that is called when the press is released over the target.
onPressStart—Handler that is called when a press interaction starts.
onPressEnd—Handler that is called when a press interaction ends, either over the target or when the pointer leaves the target.
onPressChange—Handler that is called when the press state changes.
onPressUp—Handler that is called when a press is released over the target, regardless of whether it started on the target or not.
onClick—**Not recommended – use onPress instead.** onClick is an alias for onPress provided for compatibility with other libraries. onPress provides additional event details for non-mouse interactions.
autoFocusboolean—Whether the element should receive focus on render.
styleStyleOrFunction<ButtonRenderProps>—The inline style for the element. A function may be provided to compute the style based on component state.
childrenChildrenOrFunction<ButtonRenderProps>—The children of the component. A function may be provided to alter the children based on component state.
render—Overrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.
aria-disabled"false" | "true" | boolean—Indicates whether the element is disabled to users of assistive technology.
aria-expanded"false" | "true" | boolean—Indicates whether the element, or another grouping element it controls, is currently expanded or collapsed.
aria-haspopup—Indicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.
aria-controlsstring—Identifies the element (or elements) whose contents or presence are controlled by the current element.
aria-pressed"false" | "mixed" | "true" | boolean—Indicates the current "pressed" state of toggle buttons.
aria-current—Indicates whether this element represents the current item within a container or set of related elements.
type"button""reset""submit"'button'The behavior of the button when used in an HTML form.
preventFocusOnPressboolean—Whether to prevent focus from moving to the button when pressing it. Caution, this can make the button inaccessible and should only be used when alternative keyboard interaction is provided, such as ComboBox's MenuTrigger or a NumberField's increment/decrement control.
formstring—The <form> element to associate the button with. The value of this attribute must be the id of a <form> in the same document. See MDN.
formAction—The URL that processes the information submitted by the button. Overrides the action attribute of the button's form owner.
formEncTypestring—Indicates how to encode the form data that is submitted.
formMethodstring—Indicates the HTTP method used to submit the form.
formNoValidateboolean—Indicates that the form is not to be validated when it is submitted.
formTargetstring—Overrides the target attribute of the button's form owner.
namestring—Submitted as a pair with the button's value as part of the form data.
valuestring—The value associated with the button's name when it's submitted with the form data.
isPendingboolean—Whether the button is in a pending state. This disables press and hover events while retaining focusability, and announces the pending state to screen readers.
disabledboolean—Turns off the control: no focus, no edits, and the disabled look.
classNamestring—

TagGroupDescription

<p>
PropTypeDefaultDescription
...props<p> attributes—Every other attribute goes to the <p>, with a ref.

TagGroupError

<p>
PropTypeDefaultDescription
...props<p> attributes—Every other attribute goes to the <p>, with a ref.
  • Use it for a set of tags with one tab stop and arrow keys between them.
  • Use selectionMode (single or multiple) for filter chips.
  • Use onRemove to add the remove button and the Delete and Backspace keys.
  • Use href on a tag to make it a link.
  • When people type new values, use a Tags Input.
  • For one status label with no action, use a Badge.
TabMoves focus to the group. The group is one tab stop.
Left ArroworRight ArrowMoves focus between the tags. Right to left swaps them.
HomeorEndMoves focus to the first or the last tag.
EnterorSpaceIn a selectable group, turns the focused tag on or off.
EnterOn a link tag, opens the link.
DeleteorBackspaceWith onRemove, removes the focused tag. A held key removes one tag.

It is a React Aria tag group, a grid with one tab stop. The arrow keys move between tags.

TagGroupLabel names the grid. A selected tag shows a check, so color is not the only signal.

On a touch screen the tags are 32px high with 8px between them.

New tag
fade · 150ms · ease-out (0, 0, 0.2, 1) · a removed tag goes at once
  1. AddedTag Group.
Open the release