v3.2.5
Patch release that stacks Toast notifications with expand-on-hover, adds Select.ClearButton and a Tabs align variant, re-exports Pressable, Focusable, OverlayTriggerStateContext, and DisclosureStateContext from @heroui/react, and upgrades React Aria to 1.21.0, plus fixes for nested data-theme tokens, shadow DOM theming, native :focus-visible rings, overlay stacking, ScrollShadow, Table, Drawer, NumberField, Accordion, Label, and Tag.
Patch release: Toast collapses notifications into a stack that expands on hover, Select gains a ClearButton, Tabs adds an align variant, @heroui/react re-exports Pressable, Focusable, OverlayTriggerStateContext, and DisclosureStateContext, and React Aria is upgraded to 1.21.0 (react-aria@3.52.0). Also fixes theme tokens in nested data-theme scopes and shadow DOM, native :focus-visible rings on exported variants, and modal-level overlays being covered by closing popovers, plus ScrollShadow, Table, Drawer, NumberField, Accordion, Label, and Tag.
Installation
Update to the latest version:
npm i @heroui/styles@latest @heroui/react@latestpnpm add @heroui/styles@latest @heroui/react@latestyarn add @heroui/styles@latest @heroui/react@latestbun add @heroui/styles@latest @heroui/react@latestPeer dependencies changed. This release requires react-aria-components@^1.21.0 and react-aria@^3.52.0. If you pin either package, update it in the same install or your package manager will report a peer dependency conflict.
Using AI assistants? Simply prompt "Hey Cursor, update HeroUI to the latest version" and your AI assistant will automatically compare versions and apply the necessary changes. Learn more about the HeroUI MCP Server.
Features
Toast
Toast now collapses into a stacked layout: the newest toast sits at full size in front, while older ones scale down and stay offset by a gap. Hovering or focusing the stack expands every visible toast; leaving it collapses the stack again. Auto-dismiss timers pause while the stack is hovered or focused, and when the page is in a background tab.
- Stacking: Collapse older toasts behind the frontmost one, with expand-on-hover/focus, an
isExpandedoverride,toast.update()to replace content in place,exitDurationfor exit animations, andAlt+T/Escape/F6keyboard support (#6773).
Select
Select adds a clear affordance without nesting buttons inside Select.Trigger. Compose Select.ClearButton next to the value and indicator, and listen with the root onClear prop. The control renders as a pointer-only span (aria-hidden); keyboard and screen reader users clear with Backspace or Delete when the clear button is composed and the popover is closed.
- Clear button: Add
Select.ClearButtonand rootonClearso selections can be cleared without invalid nested buttons (#6796).
Tabs
Tabs can align tab content for the whole list with align="start" | "center" | "end". The default remains center, so existing tabs are unchanged. Alignment uses logical properties (text-start / justify-start) for RTL, and is scoped to the list so nested tabs keep their own alignment.
- Align: Set
alignonTabsto control tab text and content alignment without repeating aclassNameon every tab (#6813).
Exports
Libraries built on @heroui/react can import RAC primitives from HeroUI instead of react-aria-components directly. That keeps a single Vite-optimized instance so contexts stay shared and SSR markup matches the client.
- RAC primitives: Re-export
Pressable,Focusable,OverlayTriggerStateContext, andDisclosureStateContextfrom@heroui/react(#6828).
Bug Fixes
- Theming: Resolve theme tokens inside Shadow DOM by declaring them on
:root, :hostso radii, colors, and dark mode still apply when the stylesheet is adopted into a shadow tree (#6841). - Toast: Keep omitted
timeoutandonCloseontoast.update, restart a running countdown onreset, require an exact hotkey modifier match, drop unusedviewTransitionName, and re-measure stacked height when a toast's width changes (#6829, #6830, #6831, #6834, #6832). - Accordion: Require both
:hoveranddata-hoveredfor the default trigger hover background so a customhover:bg-*no longer flashes the default color on mouse leave (#6817). - Theming: Define missing nested
data-themetokens (--surface-*-foreground,--field-placeholder) and point overlay shadows at--overlay-shadowso scoped dark or light sections cascade into components (#6803). - Focus: Replace the impossible
:focus-visible:not(:focus)selector with native:focus-visibleso keyboard focus rings apply to native anchors and buttons using HeroUI variants, while React Aria still uses[data-focus-visible="true"](#6805). - Label: Render
Labelas aspaninsideCheckbox.Content,Switch.Content, andRadio.Contentso it no longer nests<label>elements or reuse the group labelid(#6807). - Overlays: Raise
Modal,AlertDialog, andDrawerto the shared overlay z-index and disable pointer events on exiting popover-level overlays so closingDropdown/Select/Popoverlayers no longer cover or intercept clicks on a newly opened modal (#6798). - Tag: Expand the remove-button pressable area to 24×24 while keeping the 12×12 glyph, so taps on multi-select
Autocompletechips land reliably (#6797). - ScrollShadow: Derive the fade from a CSS scroll timeline where supported so it is correct on first paint without a post-hydration measurement flicker, keep attribute-driven fades for unsupported engines and controlled modes, and merge consumer
styleprops so--scroll-shadow-size/--scroll-shadow-offsetare preserved (#6800). - ScrollShadow: Re-measure overflow after content resizes so
data-*-scrollstays in sync (including Tabs chevrons), and fireonVisibilityChangeonly on real transitions instead of every render (#6812). - ScrollShadow: Observe content mutations instead of measuring overflow on every render (#6833).
- Calendar / RangeCalendar: Memoize default
minValueandmaxValueso calendar state is not invalidated on every render (#6812). - Button, Menu, and Dropdown: Scope
will-changecompositor hints to pressed and enter/exit animation states so static labels remain sharp inside transformed overlays, including after aModalcloses and reopens (#6779). - Drawer: Scope drag gestures to the nearest owning
Drawer.Dialogso a nested drawer handle closes only its own drawer while the parent stays open and unshifted (#6780). - Table: Keep typeahead from stealing keystrokes and focus from nested editable controls.
keyboardNavigationBehavioris now exposed as a prop and defaults to"tab", while typeahead remains available in non-editable cells (#6781). - NumberField: Size the input grid from the stepper slots that are present, so fields without increment or decrement buttons no longer reserve empty side columns (#6778).
- Toast: Merge custom
styleprops with region CSS variables and toast stacking styles so passing styles such aszIndexno longer drops--toast-widthand collapses the toast (#6794).
Dependencies
- React Aria: Upgrade to React Aria 1.21.0 —
react-aria-components@1.21.0,react-aria@3.52.0, and@internationalized/date@3.12.4(#6819).
Links
Contributors
Thanks to everyone who contributed to this release!
All Releases
All updates and changes to HeroUI v3, including new features, fixes, and breaking changes.
v3.2.4
Patch release that stops the Autocomplete popover from clipping its last options, restores backdrop dismissal for modals with outside scrolling, clamps Tabs.ListContainer chevron scrolling to the scrollable range, upgrades tailwind-variants to 3.3.1 to fix variant classes falling back after a re-render, upgrades React Aria to 1.20.0, and adds a behavioral test suite to @heroui/react.