npm / bits-ui
bits-ui
What changed in bits-ui 2, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-28.
4 breaking1 new APIs and options1 performance34 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initbits-ui 240 changes
Breaking changes 4
Home and End move the text cursor instead of highlighting the first or last item.
Select, Combobox, and DropdownMenu triggers no longer open when disabled by an ancestor fieldset.
Content mounted open in Collapsible and Accordion no longer plays its open animation.
Tooltip closes when any scrolling ancestor of its trigger scrolls.
New APIs and options 1
The hidden input now defaults to autocomplete="off"; the new autocomplete prop lets developers override it.
Performance 1
Avoid remounting all items on the first search character when shouldFilter is false.
Fixes and other changes 34
A trigger opens on clicks with detail 0, including element.click() and VoiceOver activation in Safari.
The date field no longer rejects or renders day 31 before a month is selected.
When force-mounted content opens, its z-index is applied to the floating wrapper.
Pressing Space toggles items.
The pressed item is selected when the list scrolls under a stationary pointer before release.
Consumer builds no longer emit state_referenced_locally compiler warnings for intentional initialization-time prop reads.
Keep a day tabbable when the placeholder is disabled after mount or after Prev/Next; also applies to RangeCalendar, DatePicker, and DateRangePicker.
Select the pressed item when the content scrolls under a still pointer before release; also applies to ContextMenu and Menubar.
Avoid an invalid z-index: undefined wrapper style that logs warnings in Firefox.
Preserve the weekday when moving focus with Arrow Up/Down past disabled dates.
Delayed open autofocus no longer focuses replaced content.
Body pointer-events are restored as soon as the last body-scroll lock is released, so clicks immediately after a layer closes are not lost.
Checkbox passes the form prop to the button again and submits the linked form when Enter is pressed with type="submit".
Deferred root work is skipped after Command.Root is destroyed.
The first item is scrolled into view when items are not grouped.
Command item selection logic is fixed.
Content no longer flashes visible for a frame after its exit animation when Svelte async mode is enabled.
Segments reset when value is cleared externally after a date has been typed.
The day period is preserved when typing or deleting the hour in 12-hour mode.
Focus remains on elements inside an open shadow root nested in the scope instead of treating them as escaping the trap.
Auto-focusing on open, trapping focus, and restoring focus on close no longer scroll the page.
Hidden form inputs stay in sync with component state after a native form reset, preserving the current value and subsequent updates.
The document pointerup listener registered while open is always removed, preventing it from firing after the preview closes or unmounts.
Dismiss and escape layers are registered only while content is open, so closed force-mounted content no longer closes the open item on inside clicks or steals escape focus.
DatePicker and DateRangePicker respect preventDefault() so the calendar day is not automatically focused.
The callback is now called with true after content opens and its animations finish, as well as on close.
Calendar-related components fall back to the default placeholder when spread props are reassigned and placeholder is not bound, preventing an undefined-property error.
Select and Combobox stop scroll-button auto scrolling when content closes while the button is hovered.
Unselected Select.Item and Combobox.Item options now expose aria-selected="false" to report their selection state per the APG listbox pattern.
A click with no preceding pointer press, such as element.click() or VoiceOver activation in Safari, now opens the trigger.
Select.Trigger now has the combobox role and points aria-controls at the mounted listbox.
Select and Combobox keep the highlighted item aligned while content settles after positioning, realigning on viewport resize until the user scrolls.
Slider throws a descriptive error for non-finite min, max, or step values, or a step of 0, instead of hanging the browser.
Calendar weekday headers, headings, and cell labels no longer shift by a day when a ZonedDateTime uses a time zone ahead of the local one.