@base-ui/react 1.1.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +173 -0
- package/accordion/item/AccordionItem.d.ts +1 -1
- package/accordion/item/AccordionItemContext.d.ts +1 -1
- package/accordion/root/AccordionRoot.d.ts +9 -9
- package/alert-dialog/root/AlertDialogRoot.d.ts +3 -3
- package/alert-dialog/root/AlertDialogRoot.js +6 -4
- package/autocomplete/index.parts.d.ts +2 -1
- package/autocomplete/index.parts.js +8 -1
- package/autocomplete/root/AutocompleteRoot.d.ts +19 -14
- package/autocomplete/root/AutocompleteRoot.js +4 -6
- package/avatar/fallback/AvatarFallback.d.ts +7 -2
- package/avatar/fallback/AvatarFallback.js +34 -6
- package/avatar/image/AvatarImage.d.ts +7 -2
- package/avatar/image/AvatarImage.js +35 -6
- package/avatar/image/useImageLoadingStatus.d.ts +2 -2
- package/avatar/root/AvatarRoot.js +2 -2
- package/button/Button.d.ts +1 -1
- package/button/Button.js +2 -2
- package/checkbox/indicator/CheckboxIndicator.d.ts +1 -1
- package/checkbox/indicator/CheckboxIndicator.js +4 -4
- package/checkbox/root/CheckboxRoot.d.ts +13 -13
- package/checkbox/root/CheckboxRoot.js +31 -8
- package/checkbox-group/CheckboxGroup.d.ts +5 -5
- package/checkbox-group/CheckboxGroup.js +2 -2
- package/checkbox-group/useCheckboxGroupParent.d.ts +3 -3
- package/collapsible/panel/CollapsiblePanel.d.ts +2 -2
- package/collapsible/root/CollapsibleRoot.d.ts +4 -4
- package/collapsible/root/useCollapsibleRoot.d.ts +2 -2
- package/combobox/arrow/ComboboxArrow.js +2 -2
- package/combobox/arrow/ComboboxArrowDataAttributes.js +2 -2
- package/combobox/backdrop/ComboboxBackdrop.js +2 -2
- package/combobox/chip/ComboboxChip.js +6 -3
- package/combobox/chip/ComboboxChipContext.js +1 -0
- package/combobox/chip-remove/ComboboxChipRemove.js +28 -33
- package/combobox/chips/ComboboxChipsContext.js +1 -0
- package/combobox/clear/ComboboxClear.d.ts +2 -2
- package/combobox/clear/ComboboxClear.js +2 -3
- package/combobox/group/ComboboxGroup.d.ts +1 -1
- package/combobox/group/ComboboxGroupContext.d.ts +1 -1
- package/combobox/group/ComboboxGroupContext.js +1 -0
- package/combobox/icon/ComboboxIcon.d.ts +1 -1
- package/combobox/index.parts.d.ts +2 -1
- package/combobox/index.parts.js +8 -1
- package/combobox/input/ComboboxInput.d.ts +1 -1
- package/combobox/input/ComboboxInput.js +38 -8
- package/combobox/item/ComboboxItem.d.ts +3 -3
- package/combobox/item/ComboboxItem.js +15 -15
- package/combobox/item/ComboboxItemContext.js +1 -0
- package/combobox/item-indicator/ComboboxItemIndicator.d.ts +1 -1
- package/combobox/item-indicator/ComboboxItemIndicator.js +2 -2
- package/combobox/list/ComboboxList.js +2 -2
- package/combobox/popup/ComboboxPopup.d.ts +2 -2
- package/combobox/popup/ComboboxPopup.js +3 -4
- package/combobox/popup/ComboboxPopupDataAttributes.js +2 -2
- package/combobox/portal/ComboboxPortal.d.ts +1 -1
- package/combobox/portal/ComboboxPortalContext.js +1 -0
- package/combobox/positioner/ComboboxPositioner.js +5 -3
- package/combobox/positioner/ComboboxPositionerDataAttributes.js +2 -2
- package/combobox/root/AriaCombobox.d.ts +49 -44
- package/combobox/root/AriaCombobox.js +44 -62
- package/combobox/root/ComboboxRoot.d.ts +19 -14
- package/combobox/root/ComboboxRoot.js +3 -1
- package/combobox/root/ComboboxRootContext.d.ts +1 -0
- package/combobox/root/ComboboxRootContext.js +1 -0
- package/combobox/root/utils/useFilter.d.ts +2 -2
- package/combobox/root/utils/useFilteredItems.d.ts +4 -0
- package/combobox/root/utils/useFilteredItems.js +14 -0
- package/combobox/row/ComboboxRowContext.js +1 -0
- package/combobox/store.d.ts +11 -11
- package/combobox/store.js +3 -3
- package/combobox/trigger/ComboboxTrigger.d.ts +1 -1
- package/combobox/trigger/ComboboxTrigger.js +3 -4
- package/composite/item/CompositeItem.d.ts +6 -6
- package/composite/list/CompositeList.d.ts +3 -3
- package/composite/list/CompositeListContext.d.ts +1 -1
- package/composite/list/useCompositeListItem.d.ts +5 -5
- package/composite/root/CompositeRoot.d.ts +19 -19
- package/composite/root/useCompositeRoot.d.ts +12 -12
- package/context-menu/index.d.ts +1 -0
- package/context-menu/index.parts.d.ts +1 -0
- package/context-menu/index.parts.js +7 -0
- package/context-menu/root/ContextMenuRoot.d.ts +1 -1
- package/context-menu/root/ContextMenuRootContext.js +1 -0
- package/context-menu/trigger/ContextMenuTrigger.js +13 -3
- package/csp-provider/CSPContext.d.ts +2 -2
- package/csp-provider/CSPProvider.d.ts +2 -2
- package/dialog/backdrop/DialogBackdrop.d.ts +1 -1
- package/dialog/backdrop/DialogBackdrop.js +2 -2
- package/dialog/close/DialogClose.js +2 -2
- package/dialog/popup/DialogPopup.d.ts +2 -2
- package/dialog/popup/DialogPopup.js +2 -2
- package/dialog/portal/DialogPortal.d.ts +2 -2
- package/dialog/portal/DialogPortalContext.js +1 -0
- package/dialog/root/DialogRoot.d.ts +10 -10
- package/dialog/root/DialogRoot.js +17 -4
- package/dialog/root/useDialogRoot.d.ts +3 -3
- package/dialog/root/useDialogRoot.js +4 -0
- package/dialog/store/DialogStore.d.ts +258 -17
- package/dialog/store/DialogStore.js +3 -0
- package/dialog/trigger/DialogTrigger.d.ts +3 -3
- package/dialog/trigger/DialogTrigger.js +3 -3
- package/dialog/viewport/DialogViewport.js +5 -2
- package/direction-provider/DirectionProvider.d.ts +1 -1
- package/drawer/backdrop/DrawerBackdrop.d.ts +28 -0
- package/drawer/backdrop/DrawerBackdrop.js +63 -0
- package/drawer/backdrop/DrawerBackdropCssVars.d.ts +7 -0
- package/drawer/backdrop/DrawerBackdropCssVars.js +14 -0
- package/drawer/close/DrawerClose.d.ts +23 -0
- package/drawer/close/DrawerClose.js +15 -0
- package/drawer/content/DrawerContent.d.ts +15 -0
- package/drawer/content/DrawerContent.js +32 -0
- package/drawer/description/DrawerDescription.d.ts +18 -0
- package/drawer/description/DrawerDescription.js +15 -0
- package/drawer/indent/DrawerIndent.d.ts +20 -0
- package/drawer/indent/DrawerIndent.js +87 -0
- package/drawer/indent-background/DrawerIndentBackground.d.ts +18 -0
- package/drawer/indent-background/DrawerIndentBackground.js +47 -0
- package/drawer/index.d.ts +14 -0
- package/drawer/index.js +9 -0
- package/drawer/index.parts.d.ts +14 -0
- package/drawer/index.parts.js +109 -0
- package/drawer/popup/DrawerPopup.d.ts +69 -0
- package/drawer/popup/DrawerPopup.js +291 -0
- package/drawer/popup/DrawerPopupCssVars.d.ts +37 -0
- package/drawer/popup/DrawerPopupCssVars.js +44 -0
- package/drawer/popup/DrawerPopupDataAttributes.d.ts +27 -0
- package/drawer/popup/DrawerPopupDataAttributes.js +34 -0
- package/drawer/portal/DrawerPortal.d.ts +29 -0
- package/drawer/portal/DrawerPortal.js +16 -0
- package/drawer/provider/DrawerProvider.d.ts +16 -0
- package/drawer/provider/DrawerProvider.js +100 -0
- package/drawer/provider/DrawerProviderContext.d.ts +19 -0
- package/drawer/provider/DrawerProviderContext.js +21 -0
- package/drawer/root/DrawerRoot.d.ts +124 -0
- package/drawer/root/DrawerRoot.js +235 -0
- package/drawer/root/DrawerRootContext.d.ts +89 -0
- package/drawer/root/DrawerRootContext.js +21 -0
- package/drawer/root/useDrawerSnapPoints.d.ts +15 -0
- package/drawer/root/useDrawerSnapPoints.js +155 -0
- package/drawer/swipe-area/DrawerSwipeArea.d.ts +45 -0
- package/drawer/swipe-area/DrawerSwipeArea.js +385 -0
- package/drawer/title/DrawerTitle.d.ts +18 -0
- package/drawer/title/DrawerTitle.js +15 -0
- package/drawer/trigger/DrawerTrigger.d.ts +43 -0
- package/drawer/trigger/DrawerTrigger.js +15 -0
- package/drawer/viewport/DrawerViewport.d.ts +30 -0
- package/drawer/viewport/DrawerViewport.js +873 -0
- package/drawer/viewport/DrawerViewportContext.d.ts +11 -0
- package/drawer/viewport/DrawerViewportContext.js +21 -0
- package/esm/accordion/item/AccordionItem.d.ts +1 -1
- package/esm/accordion/item/AccordionItemContext.d.ts +1 -1
- package/esm/accordion/root/AccordionRoot.d.ts +9 -9
- package/esm/alert-dialog/root/AlertDialogRoot.d.ts +3 -3
- package/esm/alert-dialog/root/AlertDialogRoot.js +6 -4
- package/esm/autocomplete/index.parts.d.ts +2 -1
- package/esm/autocomplete/index.parts.js +2 -1
- package/esm/autocomplete/root/AutocompleteRoot.d.ts +19 -14
- package/esm/autocomplete/root/AutocompleteRoot.js +4 -6
- package/esm/avatar/fallback/AvatarFallback.d.ts +7 -2
- package/esm/avatar/fallback/AvatarFallback.js +33 -6
- package/esm/avatar/image/AvatarImage.d.ts +7 -2
- package/esm/avatar/image/AvatarImage.js +34 -6
- package/esm/avatar/image/useImageLoadingStatus.d.ts +2 -2
- package/esm/avatar/root/AvatarRoot.js +2 -2
- package/esm/button/Button.d.ts +1 -1
- package/esm/button/Button.js +2 -2
- package/esm/checkbox/indicator/CheckboxIndicator.d.ts +1 -1
- package/esm/checkbox/indicator/CheckboxIndicator.js +4 -4
- package/esm/checkbox/root/CheckboxRoot.d.ts +13 -13
- package/esm/checkbox/root/CheckboxRoot.js +31 -8
- package/esm/checkbox-group/CheckboxGroup.d.ts +5 -5
- package/esm/checkbox-group/CheckboxGroup.js +2 -2
- package/esm/checkbox-group/useCheckboxGroupParent.d.ts +3 -3
- package/esm/collapsible/panel/CollapsiblePanel.d.ts +2 -2
- package/esm/collapsible/root/CollapsibleRoot.d.ts +4 -4
- package/esm/collapsible/root/useCollapsibleRoot.d.ts +2 -2
- package/esm/combobox/arrow/ComboboxArrow.js +2 -2
- package/esm/combobox/arrow/ComboboxArrowDataAttributes.js +2 -2
- package/esm/combobox/backdrop/ComboboxBackdrop.js +2 -2
- package/esm/combobox/chip/ComboboxChip.js +6 -3
- package/esm/combobox/chip/ComboboxChipContext.js +2 -0
- package/esm/combobox/chip-remove/ComboboxChipRemove.js +28 -33
- package/esm/combobox/chips/ComboboxChipsContext.js +2 -0
- package/esm/combobox/clear/ComboboxClear.d.ts +2 -2
- package/esm/combobox/clear/ComboboxClear.js +2 -3
- package/esm/combobox/group/ComboboxGroup.d.ts +1 -1
- package/esm/combobox/group/ComboboxGroupContext.d.ts +1 -1
- package/esm/combobox/group/ComboboxGroupContext.js +2 -0
- package/esm/combobox/icon/ComboboxIcon.d.ts +1 -1
- package/esm/combobox/index.parts.d.ts +2 -1
- package/esm/combobox/index.parts.js +2 -1
- package/esm/combobox/input/ComboboxInput.d.ts +1 -1
- package/esm/combobox/input/ComboboxInput.js +38 -8
- package/esm/combobox/item/ComboboxItem.d.ts +3 -3
- package/esm/combobox/item/ComboboxItem.js +15 -15
- package/esm/combobox/item/ComboboxItemContext.js +2 -0
- package/esm/combobox/item-indicator/ComboboxItemIndicator.d.ts +1 -1
- package/esm/combobox/item-indicator/ComboboxItemIndicator.js +2 -2
- package/esm/combobox/list/ComboboxList.js +2 -2
- package/esm/combobox/popup/ComboboxPopup.d.ts +2 -2
- package/esm/combobox/popup/ComboboxPopup.js +3 -4
- package/esm/combobox/popup/ComboboxPopupDataAttributes.js +2 -2
- package/esm/combobox/portal/ComboboxPortal.d.ts +1 -1
- package/esm/combobox/portal/ComboboxPortalContext.js +2 -0
- package/esm/combobox/positioner/ComboboxPositioner.js +5 -3
- package/esm/combobox/positioner/ComboboxPositionerDataAttributes.js +2 -2
- package/esm/combobox/root/AriaCombobox.d.ts +49 -44
- package/esm/combobox/root/AriaCombobox.js +45 -63
- package/esm/combobox/root/ComboboxRoot.d.ts +19 -14
- package/esm/combobox/root/ComboboxRoot.js +3 -1
- package/esm/combobox/root/ComboboxRootContext.d.ts +1 -0
- package/esm/combobox/root/ComboboxRootContext.js +2 -0
- package/esm/combobox/root/utils/useFilter.d.ts +2 -2
- package/esm/combobox/root/utils/useFilteredItems.d.ts +4 -0
- package/esm/combobox/root/utils/useFilteredItems.js +9 -0
- package/esm/combobox/row/ComboboxRowContext.js +2 -0
- package/esm/combobox/store.d.ts +11 -11
- package/esm/combobox/store.js +3 -3
- package/esm/combobox/trigger/ComboboxTrigger.d.ts +1 -1
- package/esm/combobox/trigger/ComboboxTrigger.js +3 -4
- package/esm/composite/item/CompositeItem.d.ts +6 -6
- package/esm/composite/list/CompositeList.d.ts +3 -3
- package/esm/composite/list/CompositeListContext.d.ts +1 -1
- package/esm/composite/list/useCompositeListItem.d.ts +5 -5
- package/esm/composite/root/CompositeRoot.d.ts +19 -19
- package/esm/composite/root/useCompositeRoot.d.ts +12 -12
- package/esm/context-menu/index.d.ts +1 -0
- package/esm/context-menu/index.parts.d.ts +1 -0
- package/esm/context-menu/index.parts.js +1 -0
- package/esm/context-menu/root/ContextMenuRoot.d.ts +1 -1
- package/esm/context-menu/root/ContextMenuRootContext.js +2 -0
- package/esm/context-menu/trigger/ContextMenuTrigger.js +13 -3
- package/esm/csp-provider/CSPContext.d.ts +2 -2
- package/esm/csp-provider/CSPProvider.d.ts +2 -2
- package/esm/dialog/backdrop/DialogBackdrop.d.ts +1 -1
- package/esm/dialog/backdrop/DialogBackdrop.js +2 -2
- package/esm/dialog/close/DialogClose.js +2 -2
- package/esm/dialog/popup/DialogPopup.d.ts +2 -2
- package/esm/dialog/popup/DialogPopup.js +2 -2
- package/esm/dialog/portal/DialogPortal.d.ts +2 -2
- package/esm/dialog/portal/DialogPortalContext.js +2 -0
- package/esm/dialog/root/DialogRoot.d.ts +10 -10
- package/esm/dialog/root/DialogRoot.js +17 -4
- package/esm/dialog/root/useDialogRoot.d.ts +3 -3
- package/esm/dialog/root/useDialogRoot.js +4 -0
- package/esm/dialog/store/DialogStore.d.ts +258 -17
- package/esm/dialog/store/DialogStore.js +3 -0
- package/esm/dialog/trigger/DialogTrigger.d.ts +3 -3
- package/esm/dialog/trigger/DialogTrigger.js +2 -2
- package/esm/dialog/viewport/DialogViewport.js +5 -2
- package/esm/direction-provider/DirectionProvider.d.ts +1 -1
- package/esm/drawer/backdrop/DrawerBackdrop.d.ts +28 -0
- package/esm/drawer/backdrop/DrawerBackdrop.js +57 -0
- package/esm/drawer/backdrop/DrawerBackdropCssVars.d.ts +7 -0
- package/esm/drawer/backdrop/DrawerBackdropCssVars.js +8 -0
- package/esm/drawer/close/DrawerClose.d.ts +23 -0
- package/esm/drawer/close/DrawerClose.js +10 -0
- package/esm/drawer/content/DrawerContent.d.ts +15 -0
- package/esm/drawer/content/DrawerContent.js +27 -0
- package/esm/drawer/description/DrawerDescription.d.ts +18 -0
- package/esm/drawer/description/DrawerDescription.js +10 -0
- package/esm/drawer/indent/DrawerIndent.d.ts +20 -0
- package/esm/drawer/indent/DrawerIndent.js +81 -0
- package/esm/drawer/indent-background/DrawerIndentBackground.d.ts +18 -0
- package/esm/drawer/indent-background/DrawerIndentBackground.js +41 -0
- package/esm/drawer/index.d.ts +14 -0
- package/esm/drawer/index.js +1 -0
- package/esm/drawer/index.parts.d.ts +14 -0
- package/esm/drawer/index.parts.js +14 -0
- package/esm/drawer/popup/DrawerPopup.d.ts +69 -0
- package/esm/drawer/popup/DrawerPopup.js +285 -0
- package/esm/drawer/popup/DrawerPopupCssVars.d.ts +37 -0
- package/esm/drawer/popup/DrawerPopupCssVars.js +38 -0
- package/esm/drawer/popup/DrawerPopupDataAttributes.d.ts +27 -0
- package/esm/drawer/popup/DrawerPopupDataAttributes.js +28 -0
- package/esm/drawer/portal/DrawerPortal.d.ts +29 -0
- package/esm/drawer/portal/DrawerPortal.js +11 -0
- package/esm/drawer/provider/DrawerProvider.d.ts +16 -0
- package/esm/drawer/provider/DrawerProvider.js +95 -0
- package/esm/drawer/provider/DrawerProviderContext.d.ts +19 -0
- package/esm/drawer/provider/DrawerProviderContext.js +13 -0
- package/esm/drawer/root/DrawerRoot.d.ts +124 -0
- package/esm/drawer/root/DrawerRoot.js +229 -0
- package/esm/drawer/root/DrawerRootContext.d.ts +89 -0
- package/esm/drawer/root/DrawerRootContext.js +13 -0
- package/esm/drawer/root/useDrawerSnapPoints.d.ts +15 -0
- package/esm/drawer/root/useDrawerSnapPoints.js +149 -0
- package/esm/drawer/swipe-area/DrawerSwipeArea.d.ts +45 -0
- package/esm/drawer/swipe-area/DrawerSwipeArea.js +379 -0
- package/esm/drawer/title/DrawerTitle.d.ts +18 -0
- package/esm/drawer/title/DrawerTitle.js +10 -0
- package/esm/drawer/trigger/DrawerTrigger.d.ts +43 -0
- package/esm/drawer/trigger/DrawerTrigger.js +10 -0
- package/esm/drawer/viewport/DrawerViewport.d.ts +30 -0
- package/esm/drawer/viewport/DrawerViewport.js +867 -0
- package/esm/drawer/viewport/DrawerViewportContext.d.ts +11 -0
- package/esm/drawer/viewport/DrawerViewportContext.js +13 -0
- package/esm/field/control/FieldControl.d.ts +3 -3
- package/esm/field/control/FieldControl.js +22 -20
- package/esm/field/error/FieldError.d.ts +5 -2
- package/esm/field/error/FieldError.js +50 -7
- package/esm/field/item/FieldItem.d.ts +1 -1
- package/esm/field/item/FieldItemContext.js +2 -0
- package/esm/field/label/FieldLabel.d.ts +1 -1
- package/esm/field/label/FieldLabel.js +7 -2
- package/esm/field/root/FieldRoot.d.ts +9 -9
- package/esm/field/root/FieldRootContext.d.ts +1 -1
- package/esm/field/useField.d.ts +1 -1
- package/esm/field/useField.js +2 -0
- package/esm/field/validity/FieldValidity.d.ts +2 -0
- package/esm/field/validity/FieldValidity.js +11 -4
- package/esm/fieldset/legend/FieldsetLegend.js +2 -2
- package/esm/fieldset/root/FieldsetRoot.d.ts +1 -1
- package/esm/fieldset/root/FieldsetRoot.js +3 -3
- package/esm/floating-ui-react/components/FloatingDelayGroup.d.ts +2 -7
- package/esm/floating-ui-react/components/FloatingDelayGroup.js +2 -9
- package/esm/floating-ui-react/components/FloatingFocusManager.d.ts +11 -21
- package/esm/floating-ui-react/components/FloatingFocusManager.js +63 -76
- package/esm/floating-ui-react/components/FloatingPortal.d.ts +8 -9
- package/esm/floating-ui-react/components/FloatingPortal.js +1 -3
- package/esm/floating-ui-react/components/FloatingTree.d.ts +1 -1
- package/esm/floating-ui-react/hooks/useClick.d.ts +12 -6
- package/esm/floating-ui-react/hooks/useClick.js +6 -5
- package/esm/floating-ui-react/hooks/useClientPoint.d.ts +2 -12
- package/esm/floating-ui-react/hooks/useClientPoint.js +5 -16
- package/esm/floating-ui-react/hooks/useDismiss.d.ts +15 -15
- package/esm/floating-ui-react/hooks/useDismiss.js +6 -3
- package/esm/floating-ui-react/hooks/useFloating.js +2 -0
- package/esm/floating-ui-react/hooks/useFloatingRootContext.d.ts +4 -10
- package/esm/floating-ui-react/hooks/useFloatingRootContext.js +5 -3
- package/esm/floating-ui-react/hooks/useFocus.d.ts +2 -8
- package/esm/floating-ui-react/hooks/useFocus.js +11 -12
- package/esm/floating-ui-react/hooks/useHover.d.ts +7 -30
- package/esm/floating-ui-react/hooks/useHover.js +20 -37
- package/esm/floating-ui-react/hooks/useHoverFloatingInteraction.d.ts +2 -7
- package/esm/floating-ui-react/hooks/useHoverFloatingInteraction.js +35 -40
- package/esm/floating-ui-react/hooks/useHoverInteractionSharedState.d.ts +17 -14
- package/esm/floating-ui-react/hooks/useHoverInteractionSharedState.js +36 -30
- package/esm/floating-ui-react/hooks/useHoverReferenceInteraction.d.ts +7 -3
- package/esm/floating-ui-react/hooks/useHoverReferenceInteraction.js +57 -60
- package/esm/floating-ui-react/hooks/useInteractions.d.ts +2 -2
- package/esm/floating-ui-react/hooks/useListNavigation.d.ts +19 -35
- package/esm/floating-ui-react/hooks/useListNavigation.js +13 -12
- package/esm/floating-ui-react/hooks/useRole.d.ts +1 -7
- package/esm/floating-ui-react/hooks/useRole.js +2 -3
- package/esm/floating-ui-react/hooks/useSyncedFloatingRootContext.d.ts +2 -2
- package/esm/floating-ui-react/hooks/useSyncedFloatingRootContext.js +2 -0
- package/esm/floating-ui-react/hooks/useTypeahead.d.ts +6 -16
- package/esm/floating-ui-react/hooks/useTypeahead.js +48 -16
- package/esm/floating-ui-react/middleware/arrow.d.ts +1 -1
- package/esm/floating-ui-react/safePolygon.d.ts +3 -3
- package/esm/floating-ui-react/types.d.ts +14 -14
- package/esm/floating-ui-react/utils/composite.d.ts +5 -5
- package/esm/floating-ui-react/utils/composite.js +1 -2
- package/esm/floating-ui-react/utils/element.d.ts +2 -1
- package/esm/floating-ui-react/utils/element.js +16 -4
- package/esm/floating-ui-react/utils/enqueueFocus.d.ts +3 -3
- package/esm/floating-ui-react/utils/event.js +2 -4
- package/esm/floating-ui-react/utils/markOthers.js +2 -2
- package/esm/floating-ui-react/utils/tabbable.js +6 -5
- package/esm/form/Form.d.ts +5 -5
- package/esm/index.d.ts +1 -0
- package/esm/index.js +2 -1
- package/esm/input/Input.d.ts +3 -3
- package/esm/labelable-provider/LabelableContext.d.ts +1 -1
- package/esm/labelable-provider/LabelableContext.js +1 -1
- package/esm/labelable-provider/LabelableProvider.js +33 -3
- package/esm/labelable-provider/useLabelableId.d.ts +3 -2
- package/esm/labelable-provider/useLabelableId.js +38 -12
- package/esm/menu/arrow/MenuArrow.js +2 -2
- package/esm/menu/arrow/MenuArrowDataAttributes.js +2 -2
- package/esm/menu/backdrop/MenuBackdrop.js +2 -2
- package/esm/menu/checkbox-item/MenuCheckboxItem.d.ts +8 -8
- package/esm/menu/checkbox-item/MenuCheckboxItemContext.js +2 -0
- package/esm/menu/checkbox-item-indicator/MenuCheckboxItemIndicator.d.ts +2 -2
- package/esm/menu/checkbox-item-indicator/MenuCheckboxItemIndicator.js +3 -3
- package/esm/menu/group/MenuGroupContext.js +2 -0
- package/esm/menu/index.d.ts +2 -1
- package/esm/menu/index.parts.d.ts +1 -0
- package/esm/menu/index.parts.js +1 -0
- package/esm/menu/item/MenuItem.d.ts +5 -5
- package/esm/menu/item/MenuItem.js +2 -2
- package/esm/menu/item/useMenuItem.js +12 -48
- package/esm/menu/item/useMenuItemCommonProps.d.ts +43 -0
- package/esm/menu/item/useMenuItemCommonProps.js +66 -0
- package/esm/menu/link-item/MenuLinkItem.d.ts +34 -0
- package/esm/menu/link-item/MenuLinkItem.js +55 -0
- package/esm/menu/link-item/MenuLinkItemDataAttributes.d.ts +6 -0
- package/esm/menu/link-item/MenuLinkItemDataAttributes.js +7 -0
- package/esm/menu/popup/MenuPopup.d.ts +3 -2
- package/esm/menu/popup/MenuPopup.js +2 -2
- package/esm/menu/popup/MenuPopupDataAttributes.js +2 -2
- package/esm/menu/portal/MenuPortal.d.ts +1 -1
- package/esm/menu/portal/MenuPortalContext.js +2 -0
- package/esm/menu/positioner/MenuPositioner.js +6 -12
- package/esm/menu/positioner/MenuPositionerDataAttributes.js +2 -2
- package/esm/menu/radio-group/MenuRadioGroup.d.ts +2 -2
- package/esm/menu/radio-group/MenuRadioGroup.js +2 -2
- package/esm/menu/radio-group/MenuRadioGroupContext.js +2 -0
- package/esm/menu/radio-item/MenuRadioItem.d.ts +5 -5
- package/esm/menu/radio-item/MenuRadioItemContext.js +2 -0
- package/esm/menu/radio-item-indicator/MenuRadioItemIndicator.d.ts +2 -2
- package/esm/menu/radio-item-indicator/MenuRadioItemIndicator.js +3 -3
- package/esm/menu/root/MenuRoot.d.ts +15 -15
- package/esm/menu/root/MenuRoot.js +38 -36
- package/esm/menu/store/MenuStore.d.ts +255 -15
- package/esm/menu/store/MenuStore.js +2 -11
- package/esm/menu/submenu-root/MenuSubmenuRoot.d.ts +2 -2
- package/esm/menu/submenu-root/MenuSubmenuRootContext.js +2 -0
- package/esm/menu/submenu-trigger/MenuSubmenuTrigger.d.ts +22 -22
- package/esm/menu/submenu-trigger/MenuSubmenuTrigger.js +9 -7
- package/esm/menu/trigger/MenuTrigger.d.ts +10 -6
- package/esm/menu/trigger/MenuTrigger.js +4 -3
- package/esm/menubar/Menubar.d.ts +4 -4
- package/esm/menubar/Menubar.js +2 -2
- package/esm/meter/root/MeterRoot.d.ts +6 -6
- package/esm/meter/root/MeterRoot.js +3 -11
- package/esm/meter/value/MeterValue.d.ts +1 -1
- package/esm/navigation-menu/arrow/NavigationMenuArrow.js +2 -2
- package/esm/navigation-menu/arrow/NavigationMenuArrowDataAttributes.js +2 -2
- package/esm/navigation-menu/backdrop/NavigationMenuBackdrop.js +2 -2
- package/esm/navigation-menu/content/NavigationMenuContent.d.ts +8 -1
- package/esm/navigation-menu/content/NavigationMenuContent.js +26 -5
- package/esm/navigation-menu/icon/NavigationMenuIcon.d.ts +1 -1
- package/esm/navigation-menu/icon/NavigationMenuIcon.js +2 -2
- package/esm/navigation-menu/item/NavigationMenuItem.d.ts +1 -1
- package/esm/navigation-menu/item/NavigationMenuItemContext.js +2 -0
- package/esm/navigation-menu/link/NavigationMenuLink.d.ts +2 -2
- package/esm/navigation-menu/link/NavigationMenuLink.js +2 -2
- package/esm/navigation-menu/list/NavigationMenuDismissContext.js +2 -0
- package/esm/navigation-menu/list/NavigationMenuList.d.ts +1 -1
- package/esm/navigation-menu/list/NavigationMenuList.js +2 -2
- package/esm/navigation-menu/popup/NavigationMenuPopup.d.ts +13 -0
- package/esm/navigation-menu/popup/NavigationMenuPopup.js +2 -2
- package/esm/navigation-menu/popup/NavigationMenuPopupDataAttributes.js +2 -2
- package/esm/navigation-menu/portal/NavigationMenuPortal.d.ts +2 -2
- package/esm/navigation-menu/portal/NavigationMenuPortalContext.js +2 -0
- package/esm/navigation-menu/positioner/NavigationMenuPositioner.js +2 -2
- package/esm/navigation-menu/positioner/NavigationPositionerDataAttributes.js +2 -2
- package/esm/navigation-menu/root/NavigationMenuRoot.d.ts +6 -6
- package/esm/navigation-menu/root/NavigationMenuRoot.js +2 -2
- package/esm/navigation-menu/root/NavigationMenuRootContext.js +2 -0
- package/esm/navigation-menu/trigger/NavigationMenuTrigger.js +8 -124
- package/esm/navigation-menu/utils/isOutsideMenuEvent.d.ts +1 -1
- package/esm/navigation-menu/viewport/NavigationMenuViewport.js +21 -1
- package/esm/number-field/input/NumberFieldInput.js +3 -11
- package/esm/number-field/root/NumberFieldRoot.d.ts +27 -20
- package/esm/number-field/root/NumberFieldRoot.js +22 -7
- package/esm/number-field/root/NumberFieldRootContext.d.ts +2 -2
- package/esm/number-field/root/useNumberFieldButton.d.ts +3 -3
- package/esm/number-field/root/useNumberFieldButton.js +12 -7
- package/esm/number-field/scrub-area/NumberFieldScrubArea.d.ts +2 -2
- package/esm/number-field/scrub-area/NumberFieldScrubArea.js +16 -0
- package/esm/number-field/scrub-area/NumberFieldScrubAreaContext.js +2 -0
- package/esm/number-field/utils/stateAttributesMapping.js +3 -1
- package/esm/number-field/utils/subscribeToVisualViewportResize.d.ts +1 -1
- package/esm/number-field/utils/types.d.ts +5 -5
- package/esm/number-field/utils/validate.d.ts +3 -1
- package/esm/number-field/utils/validate.js +3 -2
- package/esm/popover/arrow/PopoverArrow.js +2 -2
- package/esm/popover/arrow/PopoverArrowDataAttributes.js +2 -2
- package/esm/popover/backdrop/PopoverBackdrop.js +2 -2
- package/esm/popover/popup/PopoverPopup.d.ts +3 -2
- package/esm/popover/popup/PopoverPopup.js +2 -2
- package/esm/popover/portal/PopoverPortal.d.ts +1 -1
- package/esm/popover/portal/PopoverPortal.js +1 -2
- package/esm/popover/portal/PopoverPortalContext.js +2 -0
- package/esm/popover/positioner/PopoverPositioner.js +3 -3
- package/esm/popover/positioner/PopoverPositionerDataAttributes.js +2 -2
- package/esm/popover/root/PopoverRoot.d.ts +9 -9
- package/esm/popover/root/PopoverRoot.js +18 -5
- package/esm/popover/store/PopoverStore.d.ts +255 -15
- package/esm/popover/trigger/PopoverTrigger.d.ts +7 -7
- package/esm/popover/trigger/PopoverTrigger.js +2 -2
- package/esm/popover/viewport/PopoverViewport.d.ts +9 -1
- package/esm/popover/viewport/PopoverViewport.js +19 -196
- package/esm/popover/viewport/PopoverViewportDataAttributes.d.ts +5 -0
- package/esm/popover/viewport/PopoverViewportDataAttributes.js +5 -0
- package/esm/preview-card/arrow/PreviewCardArrow.js +2 -2
- package/esm/preview-card/arrow/PreviewCardArrowDataAttributes.js +2 -2
- package/esm/preview-card/backdrop/PreviewCardBackdrop.js +2 -2
- package/esm/preview-card/popup/PreviewCardPopup.js +2 -2
- package/esm/preview-card/popup/PreviewCardPopupDataAttributes.js +2 -2
- package/esm/preview-card/portal/PreviewCardPortal.d.ts +1 -1
- package/esm/preview-card/portal/PreviewCardPortalContext.js +2 -0
- package/esm/preview-card/positioner/PreviewCardPositioner.js +2 -2
- package/esm/preview-card/positioner/PreviewCardPositionerContext.d.ts +1 -1
- package/esm/preview-card/positioner/PreviewCardPositionerDataAttributes.js +2 -2
- package/esm/preview-card/root/PreviewCardRoot.d.ts +8 -8
- package/esm/preview-card/root/PreviewCardRoot.js +17 -4
- package/esm/preview-card/store/PreviewCardStore.d.ts +255 -15
- package/esm/preview-card/trigger/PreviewCardTrigger.d.ts +4 -4
- package/esm/preview-card/trigger/PreviewCardTrigger.js +2 -2
- package/esm/preview-card/viewport/PreviewCardViewport.d.ts +6 -1
- package/esm/preview-card/viewport/PreviewCardViewport.js +14 -230
- package/esm/progress/root/ProgressRoot.d.ts +6 -6
- package/esm/progress/root/ProgressRoot.js +2 -13
- package/esm/progress/value/ProgressValue.d.ts +1 -1
- package/esm/radio/indicator/RadioIndicator.d.ts +1 -1
- package/esm/radio/indicator/RadioIndicator.js +4 -4
- package/esm/radio/root/RadioRoot.d.ts +37 -17
- package/esm/radio/root/RadioRoot.js +45 -11
- package/esm/radio-group/RadioGroup.d.ts +18 -12
- package/esm/radio-group/RadioGroup.js +69 -62
- package/esm/radio-group/RadioGroupContext.d.ts +9 -8
- package/esm/radio-group/RadioGroupContext.js +1 -13
- package/esm/scroll-area/root/ScrollAreaRoot.d.ts +4 -2
- package/esm/scroll-area/root/ScrollAreaRoot.js +2 -1
- package/esm/scroll-area/root/ScrollAreaRootContext.js +2 -0
- package/esm/scroll-area/root/ScrollAreaRootDataAttributes.d.ts +4 -0
- package/esm/scroll-area/root/ScrollAreaRootDataAttributes.js +4 -0
- package/esm/scroll-area/scrollbar/ScrollAreaScrollbar.d.ts +2 -2
- package/esm/scroll-area/scrollbar/ScrollAreaScrollbar.js +2 -2
- package/esm/scroll-area/scrollbar/ScrollAreaScrollbarContext.js +2 -0
- package/esm/scroll-area/scrollbar/ScrollAreaScrollbarDataAttributes.d.ts +1 -1
- package/esm/scroll-area/scrollbar/ScrollAreaScrollbarDataAttributes.js +1 -1
- package/esm/scroll-area/thumb/ScrollAreaThumb.d.ts +1 -1
- package/esm/scroll-area/thumb/ScrollAreaThumb.js +2 -2
- package/esm/scroll-area/utils/scrollEdges.d.ts +2 -0
- package/esm/scroll-area/utils/scrollEdges.js +22 -0
- package/esm/scroll-area/viewport/ScrollAreaViewport.js +18 -15
- package/esm/scroll-area/viewport/ScrollAreaViewportContext.js +2 -0
- package/esm/scroll-area/viewport/ScrollAreaViewportDataAttributes.d.ts +4 -0
- package/esm/scroll-area/viewport/ScrollAreaViewportDataAttributes.js +4 -0
- package/esm/select/arrow/SelectArrow.js +2 -2
- package/esm/select/arrow/SelectArrowDataAttributes.js +2 -2
- package/esm/select/backdrop/SelectBackdrop.js +2 -2
- package/esm/select/group/SelectGroupContext.js +2 -0
- package/esm/select/icon/SelectIcon.js +2 -2
- package/esm/select/item/SelectItem.d.ts +2 -2
- package/esm/select/item/SelectItem.js +13 -13
- package/esm/select/item/SelectItemContext.js +2 -0
- package/esm/select/item-indicator/SelectItemIndicator.d.ts +1 -1
- package/esm/select/item-indicator/SelectItemIndicator.js +2 -2
- package/esm/select/popup/SelectPopup.d.ts +11 -0
- package/esm/select/popup/SelectPopup.js +64 -35
- package/esm/select/popup/SelectPopupDataAttributes.js +2 -2
- package/esm/select/portal/SelectPortalContext.js +2 -0
- package/esm/select/positioner/SelectPositioner.d.ts +1 -1
- package/esm/select/positioner/SelectPositioner.js +14 -11
- package/esm/select/positioner/SelectPositionerContext.js +2 -0
- package/esm/select/positioner/SelectPositionerDataAttributes.js +2 -2
- package/esm/select/root/SelectRoot.d.ts +27 -22
- package/esm/select/root/SelectRoot.js +2 -0
- package/esm/select/root/SelectRootContext.d.ts +14 -14
- package/esm/select/root/SelectRootContext.js +2 -0
- package/esm/select/scroll-arrow/SelectScrollArrow.d.ts +1 -1
- package/esm/select/scroll-arrow/SelectScrollArrow.js +2 -2
- package/esm/select/scroll-down-arrow/SelectScrollDownArrow.d.ts +1 -1
- package/esm/select/scroll-down-arrow/SelectScrollDownArrowDataAttributes.js +1 -1
- package/esm/select/scroll-up-arrow/SelectScrollUpArrow.d.ts +1 -1
- package/esm/select/scroll-up-arrow/SelectScrollUpArrowDataAttributes.js +1 -1
- package/esm/select/store.d.ts +3 -3
- package/esm/select/store.js +3 -3
- package/esm/select/trigger/SelectTrigger.d.ts +1 -1
- package/esm/select/trigger/SelectTrigger.js +2 -2
- package/esm/select/value/SelectValue.d.ts +4 -0
- package/esm/select/value/SelectValue.js +2 -2
- package/esm/separator/Separator.d.ts +1 -1
- package/esm/separator/Separator.js +2 -2
- package/esm/slider/root/SliderRoot.d.ts +17 -17
- package/esm/slider/root/SliderRoot.js +3 -2
- package/esm/slider/root/SliderRootContext.d.ts +2 -2
- package/esm/slider/root/stateAttributesMapping.js +3 -1
- package/esm/slider/thumb/SliderThumb.d.ts +7 -7
- package/esm/slider/utils/getPushedThumbValues.d.ts +1 -1
- package/esm/slider/utils/resolveThumbCollision.d.ts +2 -2
- package/esm/slider/value/SliderValue.d.ts +1 -1
- package/esm/switch/root/SwitchRoot.d.ts +11 -11
- package/esm/switch/root/SwitchRoot.js +7 -1
- package/esm/switch/root/SwitchRootContext.js +2 -0
- package/esm/tabs/indicator/TabsIndicator.d.ts +1 -1
- package/esm/tabs/indicator/TabsIndicator.js +2 -2
- package/esm/tabs/list/TabsList.d.ts +2 -2
- package/esm/tabs/list/TabsList.js +2 -2
- package/esm/tabs/panel/TabsPanel.d.ts +4 -2
- package/esm/tabs/panel/TabsPanel.js +35 -9
- package/esm/tabs/root/TabsRoot.d.ts +4 -4
- package/esm/tabs/root/TabsRootContext.d.ts +1 -1
- package/esm/tabs/tab/TabsTab.d.ts +1 -1
- package/esm/tabs/tab/TabsTab.js +2 -2
- package/esm/toast/action/ToastAction.js +2 -2
- package/esm/toast/arrow/ToastArrow.js +2 -2
- package/esm/toast/arrow/ToastArrowDataAttributes.js +4 -3
- package/esm/toast/close/ToastClose.js +6 -8
- package/esm/toast/content/ToastContent.js +2 -2
- package/esm/toast/createToastManager.d.ts +5 -5
- package/esm/toast/createToastManager.js +3 -6
- package/esm/toast/description/ToastDescription.js +4 -6
- package/esm/toast/positioner/ToastPositioner.d.ts +2 -2
- package/esm/toast/positioner/ToastPositioner.js +6 -7
- package/esm/toast/positioner/ToastPositionerDataAttributes.js +2 -2
- package/esm/toast/provider/ToastProvider.d.ts +3 -3
- package/esm/toast/provider/ToastProvider.js +26 -285
- package/esm/toast/provider/ToastProviderContext.d.ts +4 -25
- package/esm/toast/provider/ToastProviderContext.js +3 -1
- package/esm/toast/root/ToastRoot.d.ts +1 -1
- package/esm/toast/root/ToastRoot.js +19 -27
- package/esm/toast/root/ToastRootContext.js +2 -0
- package/esm/toast/store.d.ts +51 -0
- package/esm/toast/store.js +355 -0
- package/esm/toast/title/ToastTitle.js +4 -6
- package/esm/toast/useToastManager.d.ts +20 -21
- package/esm/toast/useToastManager.js +8 -14
- package/esm/toast/viewport/ToastViewport.js +66 -92
- package/esm/toggle/Toggle.d.ts +10 -8
- package/esm/toggle/Toggle.js +13 -3
- package/esm/toggle-group/ToggleGroup.d.ts +22 -10
- package/esm/toggle-group/ToggleGroup.js +8 -5
- package/esm/toggle-group/ToggleGroupContext.d.ts +10 -5
- package/esm/toolbar/button/ToolbarButton.d.ts +2 -2
- package/esm/toolbar/button/ToolbarButton.js +2 -2
- package/esm/toolbar/group/ToolbarGroup.d.ts +1 -1
- package/esm/toolbar/group/ToolbarGroup.js +2 -2
- package/esm/toolbar/group/ToolbarGroupContext.js +2 -0
- package/esm/toolbar/input/ToolbarInput.d.ts +3 -3
- package/esm/toolbar/input/ToolbarInput.js +2 -2
- package/esm/toolbar/link/ToolbarLink.js +2 -2
- package/esm/toolbar/root/ToolbarRoot.d.ts +3 -3
- package/esm/toolbar/root/ToolbarRoot.js +2 -2
- package/esm/tooltip/arrow/TooltipArrow.d.ts +1 -0
- package/esm/tooltip/arrow/TooltipArrow.js +2 -2
- package/esm/tooltip/arrow/TooltipArrowDataAttributes.js +2 -2
- package/esm/tooltip/popup/TooltipPopup.js +2 -2
- package/esm/tooltip/popup/TooltipPopupDataAttributes.js +2 -2
- package/esm/tooltip/portal/TooltipPortal.d.ts +1 -1
- package/esm/tooltip/portal/TooltipPortalContext.js +2 -0
- package/esm/tooltip/positioner/TooltipPositioner.d.ts +1 -1
- package/esm/tooltip/positioner/TooltipPositionerContext.d.ts +1 -1
- package/esm/tooltip/positioner/TooltipPositionerDataAttributes.js +2 -2
- package/esm/tooltip/provider/TooltipProvider.d.ts +3 -3
- package/esm/tooltip/provider/TooltipProviderContext.js +2 -0
- package/esm/tooltip/root/TooltipRoot.d.ts +12 -12
- package/esm/tooltip/root/TooltipRoot.js +23 -11
- package/esm/tooltip/store/TooltipStore.d.ts +256 -16
- package/esm/tooltip/trigger/TooltipTrigger.d.ts +11 -4
- package/esm/tooltip/trigger/TooltipTrigger.js +12 -6
- package/esm/tooltip/trigger/TooltipTriggerDataAttributes.d.ts +4 -0
- package/esm/tooltip/trigger/TooltipTriggerDataAttributes.js +4 -0
- package/esm/tooltip/viewport/TooltipViewport.d.ts +9 -1
- package/esm/tooltip/viewport/TooltipViewport.js +14 -195
- package/esm/unstable-use-media-query/index.d.ts +5 -5
- package/esm/use-button/useButton.d.ts +4 -4
- package/esm/use-button/useButton.js +7 -2
- package/esm/use-render/useRender.d.ts +9 -9
- package/esm/utils/InternalBackdrop.d.ts +1 -1
- package/esm/utils/createBaseUIEventDetails.d.ts +3 -0
- package/esm/utils/formatNumber.d.ts +2 -1
- package/esm/utils/formatNumber.js +11 -0
- package/esm/utils/getDisabledMountTransitionStyles.d.ts +1 -1
- package/esm/utils/getPseudoElementBounds.js +1 -1
- package/esm/utils/itemEquality.d.ts +5 -5
- package/esm/utils/itemEquality.js +17 -17
- package/esm/utils/popupStateMapping.d.ts +10 -0
- package/esm/utils/popupStateMapping.js +10 -0
- package/esm/utils/popups/popupStoreUtils.js +2 -0
- package/esm/utils/popups/popupTriggerMap.d.ts +14 -1
- package/esm/utils/popups/popupTriggerMap.js +27 -9
- package/esm/utils/popups/store.d.ts +28 -18
- package/esm/utils/popups/store.js +8 -5
- package/esm/utils/reason-parts.d.ts +3 -0
- package/esm/utils/reason-parts.js +3 -0
- package/esm/utils/scrollable.d.ts +4 -0
- package/esm/utils/scrollable.js +32 -0
- package/esm/utils/types.d.ts +6 -6
- package/esm/utils/useAnchorPositioning.d.ts +26 -26
- package/esm/utils/useAnchorPositioning.js +19 -16
- package/esm/utils/useFocusableWhenDisabled.d.ts +4 -4
- package/esm/utils/useMixedToggleClickHandler.d.ts +1 -1
- package/esm/utils/useMixedToggleClickHandler.js +2 -0
- package/esm/utils/useOpenChangeComplete.d.ts +2 -2
- package/esm/utils/usePopupAutoResize.d.ts +3 -3
- package/esm/utils/usePopupAutoResize.js +3 -1
- package/esm/utils/usePopupViewport.d.ts +58 -0
- package/esm/utils/usePopupViewport.js +247 -0
- package/esm/utils/useRenderElement.d.ts +9 -9
- package/esm/utils/useRenderElement.js +28 -1
- package/esm/utils/useSwipeDismiss.d.ts +108 -0
- package/esm/utils/useSwipeDismiss.js +944 -0
- package/esm/utils/useValueChanged.js +2 -0
- package/field/control/FieldControl.d.ts +3 -3
- package/field/control/FieldControl.js +21 -20
- package/field/error/FieldError.d.ts +5 -2
- package/field/error/FieldError.js +51 -7
- package/field/item/FieldItem.d.ts +1 -1
- package/field/item/FieldItemContext.js +1 -0
- package/field/label/FieldLabel.d.ts +1 -1
- package/field/label/FieldLabel.js +7 -2
- package/field/root/FieldRoot.d.ts +9 -9
- package/field/root/FieldRootContext.d.ts +1 -1
- package/field/useField.d.ts +1 -1
- package/field/useField.js +1 -0
- package/field/validity/FieldValidity.d.ts +2 -0
- package/field/validity/FieldValidity.js +9 -3
- package/fieldset/legend/FieldsetLegend.js +2 -2
- package/fieldset/root/FieldsetRoot.d.ts +1 -1
- package/fieldset/root/FieldsetRoot.js +3 -3
- package/floating-ui-react/components/FloatingDelayGroup.d.ts +2 -7
- package/floating-ui-react/components/FloatingDelayGroup.js +2 -9
- package/floating-ui-react/components/FloatingFocusManager.d.ts +11 -21
- package/floating-ui-react/components/FloatingFocusManager.js +61 -74
- package/floating-ui-react/components/FloatingPortal.d.ts +8 -9
- package/floating-ui-react/components/FloatingPortal.js +1 -3
- package/floating-ui-react/components/FloatingTree.d.ts +1 -1
- package/floating-ui-react/hooks/useClick.d.ts +12 -6
- package/floating-ui-react/hooks/useClick.js +6 -5
- package/floating-ui-react/hooks/useClientPoint.d.ts +2 -12
- package/floating-ui-react/hooks/useClientPoint.js +4 -16
- package/floating-ui-react/hooks/useDismiss.d.ts +15 -15
- package/floating-ui-react/hooks/useDismiss.js +4 -2
- package/floating-ui-react/hooks/useFloating.js +1 -0
- package/floating-ui-react/hooks/useFloatingRootContext.d.ts +4 -10
- package/floating-ui-react/hooks/useFloatingRootContext.js +4 -3
- package/floating-ui-react/hooks/useFocus.d.ts +2 -8
- package/floating-ui-react/hooks/useFocus.js +9 -11
- package/floating-ui-react/hooks/useHover.d.ts +7 -30
- package/floating-ui-react/hooks/useHover.js +18 -36
- package/floating-ui-react/hooks/useHoverFloatingInteraction.d.ts +2 -7
- package/floating-ui-react/hooks/useHoverFloatingInteraction.js +33 -39
- package/floating-ui-react/hooks/useHoverInteractionSharedState.d.ts +17 -14
- package/floating-ui-react/hooks/useHoverInteractionSharedState.js +36 -30
- package/floating-ui-react/hooks/useHoverReferenceInteraction.d.ts +7 -3
- package/floating-ui-react/hooks/useHoverReferenceInteraction.js +55 -59
- package/floating-ui-react/hooks/useInteractions.d.ts +2 -2
- package/floating-ui-react/hooks/useListNavigation.d.ts +19 -35
- package/floating-ui-react/hooks/useListNavigation.js +11 -11
- package/floating-ui-react/hooks/useRole.d.ts +1 -7
- package/floating-ui-react/hooks/useRole.js +2 -3
- package/floating-ui-react/hooks/useSyncedFloatingRootContext.d.ts +2 -2
- package/floating-ui-react/hooks/useSyncedFloatingRootContext.js +1 -0
- package/floating-ui-react/hooks/useTypeahead.d.ts +6 -16
- package/floating-ui-react/hooks/useTypeahead.js +46 -15
- package/floating-ui-react/middleware/arrow.d.ts +1 -1
- package/floating-ui-react/safePolygon.d.ts +3 -3
- package/floating-ui-react/types.d.ts +14 -14
- package/floating-ui-react/utils/composite.d.ts +5 -5
- package/floating-ui-react/utils/composite.js +1 -3
- package/floating-ui-react/utils/element.d.ts +2 -1
- package/floating-ui-react/utils/element.js +16 -4
- package/floating-ui-react/utils/enqueueFocus.d.ts +3 -3
- package/floating-ui-react/utils/event.js +2 -4
- package/floating-ui-react/utils/markOthers.js +2 -2
- package/floating-ui-react/utils/tabbable.js +5 -4
- package/form/Form.d.ts +5 -5
- package/index.d.ts +1 -0
- package/index.js +12 -1
- package/input/Input.d.ts +3 -3
- package/labelable-provider/LabelableContext.d.ts +1 -1
- package/labelable-provider/LabelableContext.js +1 -1
- package/labelable-provider/LabelableProvider.js +33 -3
- package/labelable-provider/useLabelableId.d.ts +3 -2
- package/labelable-provider/useLabelableId.js +39 -12
- package/menu/arrow/MenuArrow.js +2 -2
- package/menu/arrow/MenuArrowDataAttributes.js +2 -2
- package/menu/backdrop/MenuBackdrop.js +2 -2
- package/menu/checkbox-item/MenuCheckboxItem.d.ts +8 -8
- package/menu/checkbox-item/MenuCheckboxItemContext.js +1 -0
- package/menu/checkbox-item-indicator/MenuCheckboxItemIndicator.d.ts +2 -2
- package/menu/checkbox-item-indicator/MenuCheckboxItemIndicator.js +3 -3
- package/menu/group/MenuGroupContext.js +1 -0
- package/menu/index.d.ts +2 -1
- package/menu/index.parts.d.ts +1 -0
- package/menu/index.parts.js +7 -0
- package/menu/item/MenuItem.d.ts +5 -5
- package/menu/item/MenuItem.js +2 -2
- package/menu/item/useMenuItem.js +12 -48
- package/menu/item/useMenuItemCommonProps.d.ts +43 -0
- package/menu/item/useMenuItemCommonProps.js +72 -0
- package/menu/link-item/MenuLinkItem.d.ts +34 -0
- package/menu/link-item/MenuLinkItem.js +60 -0
- package/menu/link-item/MenuLinkItemDataAttributes.d.ts +6 -0
- package/menu/link-item/MenuLinkItemDataAttributes.js +13 -0
- package/menu/popup/MenuPopup.d.ts +3 -2
- package/menu/popup/MenuPopup.js +2 -2
- package/menu/popup/MenuPopupDataAttributes.js +2 -2
- package/menu/portal/MenuPortal.d.ts +1 -1
- package/menu/portal/MenuPortalContext.js +1 -0
- package/menu/positioner/MenuPositioner.js +6 -12
- package/menu/positioner/MenuPositionerDataAttributes.js +2 -2
- package/menu/radio-group/MenuRadioGroup.d.ts +2 -2
- package/menu/radio-group/MenuRadioGroup.js +2 -2
- package/menu/radio-group/MenuRadioGroupContext.js +1 -0
- package/menu/radio-item/MenuRadioItem.d.ts +5 -5
- package/menu/radio-item/MenuRadioItemContext.js +1 -0
- package/menu/radio-item-indicator/MenuRadioItemIndicator.d.ts +2 -2
- package/menu/radio-item-indicator/MenuRadioItemIndicator.js +3 -3
- package/menu/root/MenuRoot.d.ts +15 -15
- package/menu/root/MenuRoot.js +39 -37
- package/menu/store/MenuStore.d.ts +255 -15
- package/menu/store/MenuStore.js +2 -11
- package/menu/submenu-root/MenuSubmenuRoot.d.ts +2 -2
- package/menu/submenu-root/MenuSubmenuRootContext.js +1 -0
- package/menu/submenu-trigger/MenuSubmenuTrigger.d.ts +22 -22
- package/menu/submenu-trigger/MenuSubmenuTrigger.js +10 -8
- package/menu/trigger/MenuTrigger.d.ts +10 -6
- package/menu/trigger/MenuTrigger.js +5 -4
- package/menubar/Menubar.d.ts +4 -4
- package/menubar/Menubar.js +2 -2
- package/meter/root/MeterRoot.d.ts +6 -6
- package/meter/root/MeterRoot.js +1 -10
- package/meter/value/MeterValue.d.ts +1 -1
- package/navigation-menu/arrow/NavigationMenuArrow.js +2 -2
- package/navigation-menu/arrow/NavigationMenuArrowDataAttributes.js +2 -2
- package/navigation-menu/backdrop/NavigationMenuBackdrop.js +2 -2
- package/navigation-menu/content/NavigationMenuContent.d.ts +8 -1
- package/navigation-menu/content/NavigationMenuContent.js +26 -5
- package/navigation-menu/icon/NavigationMenuIcon.d.ts +1 -1
- package/navigation-menu/icon/NavigationMenuIcon.js +2 -2
- package/navigation-menu/item/NavigationMenuItem.d.ts +1 -1
- package/navigation-menu/item/NavigationMenuItemContext.js +1 -0
- package/navigation-menu/link/NavigationMenuLink.d.ts +2 -2
- package/navigation-menu/link/NavigationMenuLink.js +2 -2
- package/navigation-menu/list/NavigationMenuDismissContext.js +1 -0
- package/navigation-menu/list/NavigationMenuList.d.ts +1 -1
- package/navigation-menu/list/NavigationMenuList.js +2 -2
- package/navigation-menu/popup/NavigationMenuPopup.d.ts +13 -0
- package/navigation-menu/popup/NavigationMenuPopup.js +2 -2
- package/navigation-menu/popup/NavigationMenuPopupDataAttributes.js +2 -2
- package/navigation-menu/portal/NavigationMenuPortal.d.ts +2 -2
- package/navigation-menu/portal/NavigationMenuPortalContext.js +1 -0
- package/navigation-menu/positioner/NavigationMenuPositioner.js +2 -2
- package/navigation-menu/positioner/NavigationPositionerDataAttributes.js +2 -2
- package/navigation-menu/root/NavigationMenuRoot.d.ts +6 -6
- package/navigation-menu/root/NavigationMenuRoot.js +2 -2
- package/navigation-menu/root/NavigationMenuRootContext.js +1 -0
- package/navigation-menu/trigger/NavigationMenuTrigger.js +7 -124
- package/navigation-menu/utils/isOutsideMenuEvent.d.ts +1 -1
- package/navigation-menu/viewport/NavigationMenuViewport.js +21 -1
- package/number-field/input/NumberFieldInput.js +3 -11
- package/number-field/root/NumberFieldRoot.d.ts +27 -20
- package/number-field/root/NumberFieldRoot.js +22 -7
- package/number-field/root/NumberFieldRootContext.d.ts +2 -2
- package/number-field/root/useNumberFieldButton.d.ts +3 -3
- package/number-field/root/useNumberFieldButton.js +12 -7
- package/number-field/scrub-area/NumberFieldScrubArea.d.ts +2 -2
- package/number-field/scrub-area/NumberFieldScrubArea.js +16 -0
- package/number-field/scrub-area/NumberFieldScrubAreaContext.js +1 -0
- package/number-field/utils/stateAttributesMapping.js +3 -1
- package/number-field/utils/subscribeToVisualViewportResize.d.ts +1 -1
- package/number-field/utils/types.d.ts +5 -5
- package/number-field/utils/validate.d.ts +3 -1
- package/number-field/utils/validate.js +3 -2
- package/package.json +13 -4
- package/popover/arrow/PopoverArrow.js +2 -2
- package/popover/arrow/PopoverArrowDataAttributes.js +2 -2
- package/popover/backdrop/PopoverBackdrop.js +2 -2
- package/popover/popup/PopoverPopup.d.ts +3 -2
- package/popover/popup/PopoverPopup.js +2 -2
- package/popover/portal/PopoverPortal.d.ts +1 -1
- package/popover/portal/PopoverPortal.js +1 -2
- package/popover/portal/PopoverPortalContext.js +1 -0
- package/popover/positioner/PopoverPositioner.js +3 -3
- package/popover/positioner/PopoverPositionerDataAttributes.js +2 -2
- package/popover/root/PopoverRoot.d.ts +9 -9
- package/popover/root/PopoverRoot.js +18 -5
- package/popover/store/PopoverStore.d.ts +255 -15
- package/popover/trigger/PopoverTrigger.d.ts +7 -7
- package/popover/trigger/PopoverTrigger.js +3 -3
- package/popover/viewport/PopoverViewport.d.ts +9 -1
- package/popover/viewport/PopoverViewport.js +19 -196
- package/popover/viewport/PopoverViewportDataAttributes.d.ts +5 -0
- package/popover/viewport/PopoverViewportDataAttributes.js +5 -0
- package/preview-card/arrow/PreviewCardArrow.js +2 -2
- package/preview-card/arrow/PreviewCardArrowDataAttributes.js +2 -2
- package/preview-card/backdrop/PreviewCardBackdrop.js +2 -2
- package/preview-card/popup/PreviewCardPopup.js +2 -2
- package/preview-card/popup/PreviewCardPopupDataAttributes.js +2 -2
- package/preview-card/portal/PreviewCardPortal.d.ts +1 -1
- package/preview-card/portal/PreviewCardPortalContext.js +1 -0
- package/preview-card/positioner/PreviewCardPositioner.js +2 -2
- package/preview-card/positioner/PreviewCardPositionerContext.d.ts +1 -1
- package/preview-card/positioner/PreviewCardPositionerDataAttributes.js +2 -2
- package/preview-card/root/PreviewCardRoot.d.ts +8 -8
- package/preview-card/root/PreviewCardRoot.js +17 -4
- package/preview-card/store/PreviewCardStore.d.ts +255 -15
- package/preview-card/trigger/PreviewCardTrigger.d.ts +4 -4
- package/preview-card/trigger/PreviewCardTrigger.js +3 -3
- package/preview-card/viewport/PreviewCardViewport.d.ts +6 -1
- package/preview-card/viewport/PreviewCardViewport.js +14 -230
- package/progress/root/ProgressRoot.d.ts +6 -6
- package/progress/root/ProgressRoot.js +1 -12
- package/progress/value/ProgressValue.d.ts +1 -1
- package/radio/indicator/RadioIndicator.d.ts +1 -1
- package/radio/indicator/RadioIndicator.js +4 -4
- package/radio/root/RadioRoot.d.ts +37 -17
- package/radio/root/RadioRoot.js +45 -11
- package/radio-group/RadioGroup.d.ts +18 -12
- package/radio-group/RadioGroup.js +68 -61
- package/radio-group/RadioGroupContext.d.ts +9 -8
- package/radio-group/RadioGroupContext.js +1 -13
- package/scroll-area/root/ScrollAreaRoot.d.ts +4 -2
- package/scroll-area/root/ScrollAreaRoot.js +2 -1
- package/scroll-area/root/ScrollAreaRootContext.js +1 -0
- package/scroll-area/root/ScrollAreaRootDataAttributes.d.ts +4 -0
- package/scroll-area/root/ScrollAreaRootDataAttributes.js +4 -0
- package/scroll-area/scrollbar/ScrollAreaScrollbar.d.ts +2 -2
- package/scroll-area/scrollbar/ScrollAreaScrollbar.js +2 -2
- package/scroll-area/scrollbar/ScrollAreaScrollbarContext.js +1 -0
- package/scroll-area/scrollbar/ScrollAreaScrollbarDataAttributes.d.ts +1 -1
- package/scroll-area/scrollbar/ScrollAreaScrollbarDataAttributes.js +1 -1
- package/scroll-area/thumb/ScrollAreaThumb.d.ts +1 -1
- package/scroll-area/thumb/ScrollAreaThumb.js +2 -2
- package/scroll-area/utils/scrollEdges.d.ts +2 -0
- package/scroll-area/utils/scrollEdges.js +29 -0
- package/scroll-area/viewport/ScrollAreaViewport.js +18 -15
- package/scroll-area/viewport/ScrollAreaViewportContext.js +1 -0
- package/scroll-area/viewport/ScrollAreaViewportDataAttributes.d.ts +4 -0
- package/scroll-area/viewport/ScrollAreaViewportDataAttributes.js +4 -0
- package/select/arrow/SelectArrow.js +2 -2
- package/select/arrow/SelectArrowDataAttributes.js +2 -2
- package/select/backdrop/SelectBackdrop.js +2 -2
- package/select/group/SelectGroupContext.js +1 -0
- package/select/icon/SelectIcon.js +2 -2
- package/select/item/SelectItem.d.ts +2 -2
- package/select/item/SelectItem.js +13 -13
- package/select/item/SelectItemContext.js +1 -0
- package/select/item-indicator/SelectItemIndicator.d.ts +1 -1
- package/select/item-indicator/SelectItemIndicator.js +2 -2
- package/select/popup/SelectPopup.d.ts +11 -0
- package/select/popup/SelectPopup.js +64 -35
- package/select/popup/SelectPopupDataAttributes.js +2 -2
- package/select/portal/SelectPortalContext.js +1 -0
- package/select/positioner/SelectPositioner.d.ts +1 -1
- package/select/positioner/SelectPositioner.js +13 -10
- package/select/positioner/SelectPositionerContext.js +1 -0
- package/select/positioner/SelectPositionerDataAttributes.js +2 -2
- package/select/root/SelectRoot.d.ts +27 -22
- package/select/root/SelectRoot.js +2 -0
- package/select/root/SelectRootContext.d.ts +14 -14
- package/select/root/SelectRootContext.js +1 -0
- package/select/scroll-arrow/SelectScrollArrow.d.ts +1 -1
- package/select/scroll-arrow/SelectScrollArrow.js +2 -2
- package/select/scroll-down-arrow/SelectScrollDownArrow.d.ts +1 -1
- package/select/scroll-down-arrow/SelectScrollDownArrowDataAttributes.js +1 -1
- package/select/scroll-up-arrow/SelectScrollUpArrow.d.ts +1 -1
- package/select/scroll-up-arrow/SelectScrollUpArrowDataAttributes.js +1 -1
- package/select/store.d.ts +3 -3
- package/select/store.js +3 -3
- package/select/trigger/SelectTrigger.d.ts +1 -1
- package/select/trigger/SelectTrigger.js +2 -2
- package/select/value/SelectValue.d.ts +4 -0
- package/select/value/SelectValue.js +2 -2
- package/separator/Separator.d.ts +1 -1
- package/separator/Separator.js +2 -2
- package/slider/root/SliderRoot.d.ts +17 -17
- package/slider/root/SliderRoot.js +3 -2
- package/slider/root/SliderRootContext.d.ts +2 -2
- package/slider/root/stateAttributesMapping.js +3 -1
- package/slider/thumb/SliderThumb.d.ts +7 -7
- package/slider/utils/getPushedThumbValues.d.ts +1 -1
- package/slider/utils/resolveThumbCollision.d.ts +2 -2
- package/slider/value/SliderValue.d.ts +1 -1
- package/switch/root/SwitchRoot.d.ts +11 -11
- package/switch/root/SwitchRoot.js +7 -1
- package/switch/root/SwitchRootContext.js +1 -0
- package/tabs/indicator/TabsIndicator.d.ts +1 -1
- package/tabs/indicator/TabsIndicator.js +2 -2
- package/tabs/list/TabsList.d.ts +2 -2
- package/tabs/list/TabsList.js +2 -2
- package/tabs/panel/TabsPanel.d.ts +4 -2
- package/tabs/panel/TabsPanel.js +37 -10
- package/tabs/root/TabsRoot.d.ts +4 -4
- package/tabs/root/TabsRootContext.d.ts +1 -1
- package/tabs/tab/TabsTab.d.ts +1 -1
- package/tabs/tab/TabsTab.js +2 -2
- package/toast/action/ToastAction.js +2 -2
- package/toast/arrow/ToastArrow.js +2 -2
- package/toast/arrow/ToastArrowDataAttributes.js +4 -3
- package/toast/close/ToastClose.js +5 -7
- package/toast/content/ToastContent.js +2 -2
- package/toast/createToastManager.d.ts +5 -5
- package/toast/createToastManager.js +3 -6
- package/toast/description/ToastDescription.js +4 -6
- package/toast/positioner/ToastPositioner.d.ts +2 -2
- package/toast/positioner/ToastPositioner.js +5 -6
- package/toast/positioner/ToastPositionerDataAttributes.js +2 -2
- package/toast/provider/ToastProvider.d.ts +3 -3
- package/toast/provider/ToastProvider.js +24 -284
- package/toast/provider/ToastProviderContext.d.ts +4 -25
- package/toast/provider/ToastProviderContext.js +3 -2
- package/toast/root/ToastRoot.d.ts +1 -1
- package/toast/root/ToastRoot.js +18 -26
- package/toast/root/ToastRootContext.js +1 -0
- package/toast/store.d.ts +51 -0
- package/toast/store.js +362 -0
- package/toast/title/ToastTitle.js +4 -6
- package/toast/useToastManager.d.ts +20 -21
- package/toast/useToastManager.js +8 -14
- package/toast/viewport/ToastViewport.js +65 -91
- package/toggle/Toggle.d.ts +10 -8
- package/toggle/Toggle.js +13 -3
- package/toggle-group/ToggleGroup.d.ts +22 -10
- package/toggle-group/ToggleGroup.js +8 -5
- package/toggle-group/ToggleGroupContext.d.ts +10 -5
- package/toolbar/button/ToolbarButton.d.ts +2 -2
- package/toolbar/button/ToolbarButton.js +2 -2
- package/toolbar/group/ToolbarGroup.d.ts +1 -1
- package/toolbar/group/ToolbarGroup.js +2 -2
- package/toolbar/group/ToolbarGroupContext.js +1 -0
- package/toolbar/input/ToolbarInput.d.ts +3 -3
- package/toolbar/input/ToolbarInput.js +2 -2
- package/toolbar/link/ToolbarLink.js +2 -2
- package/toolbar/root/ToolbarRoot.d.ts +3 -3
- package/toolbar/root/ToolbarRoot.js +2 -2
- package/tooltip/arrow/TooltipArrow.d.ts +1 -0
- package/tooltip/arrow/TooltipArrow.js +2 -2
- package/tooltip/arrow/TooltipArrowDataAttributes.js +2 -2
- package/tooltip/popup/TooltipPopup.js +2 -2
- package/tooltip/popup/TooltipPopupDataAttributes.js +2 -2
- package/tooltip/portal/TooltipPortal.d.ts +1 -1
- package/tooltip/portal/TooltipPortalContext.js +1 -0
- package/tooltip/positioner/TooltipPositioner.d.ts +1 -1
- package/tooltip/positioner/TooltipPositionerContext.d.ts +1 -1
- package/tooltip/positioner/TooltipPositionerDataAttributes.js +2 -2
- package/tooltip/provider/TooltipProvider.d.ts +3 -3
- package/tooltip/provider/TooltipProviderContext.js +1 -0
- package/tooltip/root/TooltipRoot.d.ts +12 -12
- package/tooltip/root/TooltipRoot.js +23 -11
- package/tooltip/store/TooltipStore.d.ts +256 -16
- package/tooltip/trigger/TooltipTrigger.d.ts +11 -4
- package/tooltip/trigger/TooltipTrigger.js +12 -6
- package/tooltip/trigger/TooltipTriggerDataAttributes.d.ts +4 -0
- package/tooltip/trigger/TooltipTriggerDataAttributes.js +4 -0
- package/tooltip/viewport/TooltipViewport.d.ts +9 -1
- package/tooltip/viewport/TooltipViewport.js +14 -195
- package/unstable-use-media-query/index.d.ts +5 -5
- package/use-button/useButton.d.ts +4 -4
- package/use-button/useButton.js +7 -2
- package/use-render/useRender.d.ts +9 -9
- package/utils/InternalBackdrop.d.ts +1 -1
- package/utils/createBaseUIEventDetails.d.ts +3 -0
- package/utils/formatNumber.d.ts +2 -1
- package/utils/formatNumber.js +12 -0
- package/utils/getDisabledMountTransitionStyles.d.ts +1 -1
- package/utils/getPseudoElementBounds.js +1 -1
- package/utils/itemEquality.d.ts +5 -5
- package/utils/itemEquality.js +18 -18
- package/utils/popupStateMapping.d.ts +10 -0
- package/utils/popupStateMapping.js +10 -0
- package/utils/popups/popupStoreUtils.js +1 -0
- package/utils/popups/popupTriggerMap.d.ts +14 -1
- package/utils/popups/popupTriggerMap.js +27 -10
- package/utils/popups/store.d.ts +28 -18
- package/utils/popups/store.js +8 -5
- package/utils/reason-parts.d.ts +3 -0
- package/utils/reason-parts.js +4 -1
- package/utils/scrollable.d.ts +4 -0
- package/utils/scrollable.js +40 -0
- package/utils/types.d.ts +6 -6
- package/utils/useAnchorPositioning.d.ts +26 -26
- package/utils/useAnchorPositioning.js +19 -16
- package/utils/useFocusableWhenDisabled.d.ts +4 -4
- package/utils/useMixedToggleClickHandler.d.ts +1 -1
- package/utils/useMixedToggleClickHandler.js +1 -0
- package/utils/useOpenChangeComplete.d.ts +2 -2
- package/utils/usePopupAutoResize.d.ts +3 -3
- package/utils/usePopupAutoResize.js +2 -1
- package/utils/usePopupViewport.d.ts +58 -0
- package/utils/usePopupViewport.js +253 -0
- package/utils/useRenderElement.d.ts +9 -9
- package/utils/useRenderElement.js +28 -1
- package/utils/useSwipeDismiss.d.ts +108 -0
- package/utils/useSwipeDismiss.js +952 -0
- package/utils/useValueChanged.js +1 -0
- package/esm/toast/viewport/ToastViewportContext.d.ts +0 -6
- package/esm/toast/viewport/ToastViewportContext.js +0 -11
- package/toast/viewport/ToastViewportContext.d.ts +0 -6
- package/toast/viewport/ToastViewportContext.js +0 -20
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,178 @@
|
|
|
1
1
|
# Versions
|
|
2
2
|
|
|
3
|
+
## v1.2.0
|
|
4
|
+
|
|
5
|
+
_Feb 12, 2026_
|
|
6
|
+
|
|
7
|
+
### General changes
|
|
8
|
+
|
|
9
|
+
- Do not memoize `state` when not needed (#3812) by @flaviendelangle
|
|
10
|
+
- Support lazy element in `render` prop (#3856) by @oliviertassinari
|
|
11
|
+
- Replace Firefox deprecated mozInputSource check for virtual click detection (#3942) by @CiscoFran10
|
|
12
|
+
- Use `WeakRef` for previously focused elements (#3916) by @atomiks
|
|
13
|
+
- Fix page scroll jump when input has focus on unmount in Safari (#3925) by @atomiks
|
|
14
|
+
- Fix flash at origin before positioning completes in Preact (#3975) by @OliverSpeir
|
|
15
|
+
- Reduce style recalculation with classic scrollbars (#3854) by @mdm317
|
|
16
|
+
- Fix event handling in useEnhancedClickHandler (#3981) by @sai6855
|
|
17
|
+
|
|
18
|
+
### Autocomplete
|
|
19
|
+
|
|
20
|
+
- Fix filter method's `useMemo` dependency (#3862) by @ZeeshanTamboli
|
|
21
|
+
- Fix Autocomplete not using its internal filter method when `mode` is `list` (#3936) by @ZeeshanTamboli
|
|
22
|
+
- Remove unnecessary double stringification of item in filtering logic (#3945) by @ZeeshanTamboli
|
|
23
|
+
- Add `useFilteredItems` hook (#3732) by @guisehn
|
|
24
|
+
- Fix popup closing on iOS VoiceOver (#3859) by @atomiks
|
|
25
|
+
- Remove `aria-readonly` prop from `Clear` and `Popup` components when `readOnly` (#3907) by @markocupic024
|
|
26
|
+
|
|
27
|
+
### Avatar
|
|
28
|
+
|
|
29
|
+
- Add transition attributes (#3939) by @atomiks
|
|
30
|
+
|
|
31
|
+
### Button
|
|
32
|
+
|
|
33
|
+
- Capture component stack for `nativeButton` error message (#3861) by @atomiks
|
|
34
|
+
|
|
35
|
+
### Checkbox
|
|
36
|
+
|
|
37
|
+
- Cleanup disabled state tracking (#3913) by @atomiks
|
|
38
|
+
- Preserve modifier key properties in the change event (#3935) by @mj12albert
|
|
39
|
+
- Allow exit animations on `<Checkbox.Indicator>` when `keepMounted={false}` (#3939) by @atomiks
|
|
40
|
+
|
|
41
|
+
### Combobox
|
|
42
|
+
|
|
43
|
+
- Fix the type of the ref of the `Icon` part (#3796) by @flaviendelangle
|
|
44
|
+
- Avoid clearing selected value if item is not present in items array (#3824) by @atomiks
|
|
45
|
+
- Fix highlight change reason in `ChipRemove` (#3980) by @sai6855
|
|
46
|
+
- Keep highlight on last deselect (#3923) by @atomiks
|
|
47
|
+
- Fix inline filtering after selection in single mode (#3978) by @atomiks
|
|
48
|
+
- Clear highlight on inline blur when inline (#3973) by @atomiks
|
|
49
|
+
- Prevent opening popup on autofill change (#3924) by @atomiks
|
|
50
|
+
- Distinguish `input-press` from `trigger-press` in `onOpenChange` reason (#4015) by @jijiseong
|
|
51
|
+
- Fix async items while popup is open (#4034) by @atomiks
|
|
52
|
+
- Prevent `Chip` from receiving focus when `disabled` (#4044) by @jijiseong
|
|
53
|
+
- Add `useFilteredItems` hook (#3732) by @guisehn
|
|
54
|
+
- Fix popup closing on iOS VoiceOver (#3859) by @atomiks
|
|
55
|
+
- Remove `aria-readonly` prop from `Clear` and `Popup` components when `readOnly` (#3907) by @markocupic024
|
|
56
|
+
- Fix `onClick` `Item` type (#3964) by @atomiks
|
|
57
|
+
- Use reactive `domReferenceElement` subscriptions (#4017) by @atomiks
|
|
58
|
+
- Add `autoComplete` prop for explicit browser autofill support (#4005) by @mattrothenberg
|
|
59
|
+
- Fix inconsistent isItemEqualToValue argument order (#4056) by @atomiks
|
|
60
|
+
|
|
61
|
+
### Context Menu
|
|
62
|
+
|
|
63
|
+
- Fix `disabled` prop not working (#3806) by @arturbien
|
|
64
|
+
- Fix explicit `collisionAvoidance` with `side: 'flip'` not working (#3877) by @obeattie
|
|
65
|
+
|
|
66
|
+
### Drawer
|
|
67
|
+
|
|
68
|
+
- Create new Drawer / Sheet component (#3680) by @atomiks
|
|
69
|
+
|
|
70
|
+
### Field
|
|
71
|
+
|
|
72
|
+
- Prevent re-renders when `Field.Control` is uncontrolled (#3820) by @atomiks
|
|
73
|
+
- Fix autofocus in SSR environments (#3871) by @mj12albert
|
|
74
|
+
- Fix max update depth loop when using `<React.Activity>` (#3931) by @atomiks
|
|
75
|
+
- Add transition attributes (#3939) by @atomiks
|
|
76
|
+
|
|
77
|
+
### Input
|
|
78
|
+
|
|
79
|
+
- Fix autofocus in SSR environments (#3871) by @mj12albert
|
|
80
|
+
- Update ref type to `HTMLElement` (#3866) by @mj12albert
|
|
81
|
+
|
|
82
|
+
### Menu
|
|
83
|
+
|
|
84
|
+
- Fix `onClick` `Item` type (#3964) by @atomiks
|
|
85
|
+
- Fix submenu stuck glitch (#3783) by @atomiks
|
|
86
|
+
- Fix race conditions (#3821) by @atomiks
|
|
87
|
+
- Add `<Menu.LinkItem>` part (#3400) by @mj12albert
|
|
88
|
+
|
|
89
|
+
### Navigation Menu
|
|
90
|
+
|
|
91
|
+
- Fix forwarded ref types (#3775) by @CrawlerCode
|
|
92
|
+
- Add `keepMounted` prop to `Content` part (#3794) by @atomiks
|
|
93
|
+
|
|
94
|
+
### Number Field
|
|
95
|
+
|
|
96
|
+
- Fix click handlers on ScrubArea (#3827) by @mj12albert
|
|
97
|
+
- Remove `event.isTrusted` (#3920) by @atomiks
|
|
98
|
+
- Stop repeat change at bounds (#3915) by @atomiks
|
|
99
|
+
- Add `allowOutOfRange` prop (#3919) by @atomiks
|
|
100
|
+
- Fix pen pointer handling (#3917) by @atomiks
|
|
101
|
+
- Fix missing field state data attributes (#3909) by @mj12albert
|
|
102
|
+
|
|
103
|
+
### Popover
|
|
104
|
+
|
|
105
|
+
- Fix missing `aria-owns` element (#3959) by @atomiks
|
|
106
|
+
- Use reactive `domReferenceElement` subscriptions (#4017) by @atomiks
|
|
107
|
+
- Fix broken scale transition with detached triggers (#3810) by @michaldudak
|
|
108
|
+
|
|
109
|
+
### Preview Card
|
|
110
|
+
|
|
111
|
+
- Fix broken scale transition with detached triggers (#3810) by @michaldudak
|
|
112
|
+
|
|
113
|
+
### Progress
|
|
114
|
+
|
|
115
|
+
- De-duplicate `formatValue` function (#3805) by @sai6855
|
|
116
|
+
|
|
117
|
+
### Radio Group
|
|
118
|
+
|
|
119
|
+
- Preserve modifier key properties in the change event (#3935) by @mj12albert
|
|
120
|
+
- Allow exit animations on `<Radio.Indicator>` when `keepMounted={false}` (#3939) by @atomiks
|
|
121
|
+
- Rely on individual radio hidden inputs (#3826) by @atomiks
|
|
122
|
+
- Add generic `Value` typing to `Radio` (#4033) by @atomiks
|
|
123
|
+
|
|
124
|
+
### Scroll Area
|
|
125
|
+
|
|
126
|
+
- Add `data-scrolling` state attribute to `Root` and `Viewport` parts (#3823) by @arturbien
|
|
127
|
+
- Fix overflow edge rounding (#3888) by @atomiks
|
|
128
|
+
|
|
129
|
+
### Select
|
|
130
|
+
|
|
131
|
+
- Add `finalFocus` prop (#3785) by @markocupic024
|
|
132
|
+
- Fix `alignItemWithTrigger` transform with CSS animations (#3831) by @atomiks
|
|
133
|
+
- Fix `highlightItemOnHover` not being respected (#3868) by @sarthakmalik0810
|
|
134
|
+
- Reset typeahead on external blur (#2618) by @antonfrolovsky
|
|
135
|
+
- Fix scroll height loop (#3795) by @atomiks
|
|
136
|
+
- Add `autoComplete` prop for explicit browser autofill support (#4005) by @mattrothenberg
|
|
137
|
+
- Fix inconsistent isItemEqualToValue argument order (#4056) by @atomiks
|
|
138
|
+
|
|
139
|
+
### Slider
|
|
140
|
+
|
|
141
|
+
- Fix missing field state data attributes (#3909) by @mj12albert
|
|
142
|
+
- Fix change event cloning (#3960) by @atomiks
|
|
143
|
+
|
|
144
|
+
### Switch
|
|
145
|
+
|
|
146
|
+
- Preserve modifier key properties in the change event (#3935) by @mj12albert
|
|
147
|
+
|
|
148
|
+
### Tabs
|
|
149
|
+
|
|
150
|
+
- Add transition attributes to `<Tabs.Panel>` part (#3880) by @atomiks
|
|
151
|
+
|
|
152
|
+
### Toast
|
|
153
|
+
|
|
154
|
+
- Make `useToastManager` and `createToastManager` generic functions (#3882) by @solastley
|
|
155
|
+
- Prevent dismissed promise toast from reopening on updates (#4040) by @atomiks
|
|
156
|
+
- Introduce a store (#3464) by @flaviendelangle
|
|
157
|
+
|
|
158
|
+
### Toggle
|
|
159
|
+
|
|
160
|
+
- Improve type safety and inference (#3173) by @michaelhazan
|
|
161
|
+
|
|
162
|
+
### Toggle Group
|
|
163
|
+
|
|
164
|
+
- Type value as string to match Toggle (#3770) by @markocupic024
|
|
165
|
+
- Enable `Home`/`End` key navigation (#3971) by @jijiseong
|
|
166
|
+
- Improve type safety and inference (#3173) by @michaelhazan
|
|
167
|
+
|
|
168
|
+
### Tooltip
|
|
169
|
+
|
|
170
|
+
- Prevent opening when focusing a disabled Trigger (#3902) by @michaldudak
|
|
171
|
+
- Fix broken scale transition with detached triggers (#3810) by @michaldudak
|
|
172
|
+
- Fix disabled prop on Triggers (#4049) by @michaldudak
|
|
173
|
+
|
|
174
|
+
All contributors of this release in alphabetical order : @antonfrolovsky, @arturbien, @atomiks, @CiscoFran10, @CrawlerCode, @flaviendelangle, @guisehn, @jijiseong, @LukasTy, @markocupic024, @mattrothenberg, @mdm317, @michaelhazan, @michaldudak, @mj12albert, @obeattie, @OliverSpeir, @oliviertassinari, @sai6855, @sarthakmalik0810, @solastley, @ZeeshanTamboli
|
|
175
|
+
|
|
3
176
|
## v1.1.0
|
|
4
177
|
|
|
5
178
|
_Jan 15, 2026_
|
|
@@ -33,7 +33,7 @@ export interface AccordionItemProps extends BaseUIComponentProps<'div', Accordio
|
|
|
33
33
|
/**
|
|
34
34
|
* Event handler called when the panel is opened or closed.
|
|
35
35
|
*/
|
|
36
|
-
onOpenChange?: (open: boolean, eventDetails: AccordionItem.ChangeEventDetails) => void;
|
|
36
|
+
onOpenChange?: ((open: boolean, eventDetails: AccordionItem.ChangeEventDetails) => void) | undefined;
|
|
37
37
|
}
|
|
38
38
|
export type AccordionItemChangeEventReason = typeof REASONS.triggerPress | typeof REASONS.none;
|
|
39
39
|
export type AccordionItemChangeEventDetails = BaseUIChangeEventDetails<AccordionItem.ChangeEventReason>;
|
|
@@ -4,7 +4,7 @@ export interface AccordionItemContext {
|
|
|
4
4
|
open: boolean;
|
|
5
5
|
state: AccordionItem.State;
|
|
6
6
|
setTriggerId: (id: string | undefined) => void;
|
|
7
|
-
triggerId?: string;
|
|
7
|
+
triggerId?: string | undefined;
|
|
8
8
|
}
|
|
9
9
|
export declare const AccordionItemContext: React.Context<AccordionItemContext | undefined>;
|
|
10
10
|
export declare function useAccordionItemContext(): AccordionItemContext;
|
|
@@ -24,18 +24,18 @@ export interface AccordionRootProps extends BaseUIComponentProps<'div', Accordio
|
|
|
24
24
|
*
|
|
25
25
|
* To render an uncontrolled accordion, use the `defaultValue` prop instead.
|
|
26
26
|
*/
|
|
27
|
-
value?: AccordionValue;
|
|
27
|
+
value?: AccordionValue | undefined;
|
|
28
28
|
/**
|
|
29
29
|
* The uncontrolled value of the item(s) that should be initially expanded.
|
|
30
30
|
*
|
|
31
31
|
* To render a controlled accordion, use the `value` prop instead.
|
|
32
32
|
*/
|
|
33
|
-
defaultValue?: AccordionValue;
|
|
33
|
+
defaultValue?: AccordionValue | undefined;
|
|
34
34
|
/**
|
|
35
35
|
* Whether the component should ignore user interaction.
|
|
36
36
|
* @default false
|
|
37
37
|
*/
|
|
38
|
-
disabled?: boolean;
|
|
38
|
+
disabled?: boolean | undefined;
|
|
39
39
|
/**
|
|
40
40
|
* Allows the browser’s built-in page search to find and expand the panel contents.
|
|
41
41
|
*
|
|
@@ -43,35 +43,35 @@ export interface AccordionRootProps extends BaseUIComponentProps<'div', Accordio
|
|
|
43
43
|
* to hide the element without removing it from the DOM.
|
|
44
44
|
* @default false
|
|
45
45
|
*/
|
|
46
|
-
hiddenUntilFound?: boolean;
|
|
46
|
+
hiddenUntilFound?: boolean | undefined;
|
|
47
47
|
/**
|
|
48
48
|
* Whether to keep the element in the DOM while the panel is closed.
|
|
49
49
|
* This prop is ignored when `hiddenUntilFound` is used.
|
|
50
50
|
* @default false
|
|
51
51
|
*/
|
|
52
|
-
keepMounted?: boolean;
|
|
52
|
+
keepMounted?: boolean | undefined;
|
|
53
53
|
/**
|
|
54
54
|
* Whether to loop keyboard focus back to the first item
|
|
55
55
|
* when the end of the list is reached while using the arrow keys.
|
|
56
56
|
* @default true
|
|
57
57
|
*/
|
|
58
|
-
loopFocus?: boolean;
|
|
58
|
+
loopFocus?: boolean | undefined;
|
|
59
59
|
/**
|
|
60
60
|
* Event handler called when an accordion item is expanded or collapsed.
|
|
61
61
|
* Provides the new value as an argument.
|
|
62
62
|
*/
|
|
63
|
-
onValueChange?: (value: AccordionValue, eventDetails: AccordionRootChangeEventDetails) => void;
|
|
63
|
+
onValueChange?: ((value: AccordionValue, eventDetails: AccordionRootChangeEventDetails) => void) | undefined;
|
|
64
64
|
/**
|
|
65
65
|
* Whether multiple items can be open at the same time.
|
|
66
66
|
* @default false
|
|
67
67
|
*/
|
|
68
|
-
multiple?: boolean;
|
|
68
|
+
multiple?: boolean | undefined;
|
|
69
69
|
/**
|
|
70
70
|
* The visual orientation of the accordion.
|
|
71
71
|
* Controls whether roving focus uses left/right or up/down arrow keys.
|
|
72
72
|
* @default 'vertical'
|
|
73
73
|
*/
|
|
74
|
-
orientation?: Orientation;
|
|
74
|
+
orientation?: Orientation | undefined;
|
|
75
75
|
}
|
|
76
76
|
export type AccordionRootChangeEventReason = typeof REASONS.triggerPress | typeof REASONS.none;
|
|
77
77
|
export type AccordionRootChangeEventDetails = BaseUIChangeEventDetails<AccordionRoot.ChangeEventReason>;
|
|
@@ -13,7 +13,7 @@ export interface AlertDialogRootProps<Payload = unknown> extends Omit<DialogRoot
|
|
|
13
13
|
/**
|
|
14
14
|
* Event handler called when the dialog is opened or closed.
|
|
15
15
|
*/
|
|
16
|
-
onOpenChange?: (open: boolean, eventDetails: AlertDialogRoot.ChangeEventDetails) => void;
|
|
16
|
+
onOpenChange?: ((open: boolean, eventDetails: AlertDialogRoot.ChangeEventDetails) => void) | undefined;
|
|
17
17
|
/**
|
|
18
18
|
* A ref to imperative actions.
|
|
19
19
|
* - `unmount`: When specified, the dialog will not be unmounted when closed.
|
|
@@ -21,13 +21,13 @@ export interface AlertDialogRootProps<Payload = unknown> extends Omit<DialogRoot
|
|
|
21
21
|
* Useful when the dialog's animation is controlled by an external library.
|
|
22
22
|
* - `close`: Closes the dialog imperatively when called.
|
|
23
23
|
*/
|
|
24
|
-
actionsRef?: React.RefObject<AlertDialogRoot.Actions | null
|
|
24
|
+
actionsRef?: React.RefObject<AlertDialogRoot.Actions | null> | undefined;
|
|
25
25
|
/**
|
|
26
26
|
* A handle to associate the alert dialog with a trigger.
|
|
27
27
|
* If specified, allows external triggers to control the alert dialog's open state.
|
|
28
28
|
* Can be created with the AlertDialog.createHandle() method.
|
|
29
29
|
*/
|
|
30
|
-
handle?: DialogHandle<Payload
|
|
30
|
+
handle?: DialogHandle<Payload> | undefined;
|
|
31
31
|
}
|
|
32
32
|
export type AlertDialogRootActions = DialogRoot.Actions;
|
|
33
33
|
export type AlertDialogRootChangeEventReason = DialogRoot.ChangeEventReason;
|
|
@@ -34,16 +34,18 @@ function AlertDialogRoot(props) {
|
|
|
34
34
|
const nested = Boolean(parentDialogRootContext);
|
|
35
35
|
const store = (0, _useRefWithInit.useRefWithInit)(() => {
|
|
36
36
|
return handle?.store ?? new _DialogStore.DialogStore({
|
|
37
|
-
open:
|
|
38
|
-
|
|
37
|
+
open: defaultOpen,
|
|
38
|
+
openProp,
|
|
39
|
+
activeTriggerId: defaultTriggerIdProp,
|
|
40
|
+
triggerIdProp,
|
|
39
41
|
modal: true,
|
|
40
42
|
disablePointerDismissal: true,
|
|
41
43
|
nested,
|
|
42
44
|
role: 'alertdialog'
|
|
43
45
|
});
|
|
44
46
|
}).current;
|
|
45
|
-
store.useControlledProp('
|
|
46
|
-
store.useControlledProp('
|
|
47
|
+
store.useControlledProp('openProp', openProp);
|
|
48
|
+
store.useControlledProp('triggerIdProp', triggerIdProp);
|
|
47
49
|
store.useSyncedValue('nested', nested);
|
|
48
50
|
store.useContextCallback('onOpenChange', onOpenChange);
|
|
49
51
|
store.useContextCallback('onOpenChangeComplete', onOpenChangeComplete);
|
|
@@ -18,4 +18,5 @@ export { ComboboxRow as Row } from "../combobox/row/ComboboxRow.js";
|
|
|
18
18
|
export { ComboboxCollection as Collection } from "../combobox/collection/ComboboxCollection.js";
|
|
19
19
|
export { ComboboxEmpty as Empty } from "../combobox/empty/ComboboxEmpty.js";
|
|
20
20
|
export { Separator } from "../separator/Separator.js";
|
|
21
|
-
export { useCoreFilter as useFilter } from "../combobox/root/utils/useFilter.js";
|
|
21
|
+
export { useCoreFilter as useFilter } from "../combobox/root/utils/useFilter.js";
|
|
22
|
+
export { useFilteredItems } from "../combobox/root/utils/useFilteredItems.js";
|
|
@@ -129,6 +129,12 @@ Object.defineProperty(exports, "useFilter", {
|
|
|
129
129
|
return _useFilter.useCoreFilter;
|
|
130
130
|
}
|
|
131
131
|
});
|
|
132
|
+
Object.defineProperty(exports, "useFilteredItems", {
|
|
133
|
+
enumerable: true,
|
|
134
|
+
get: function () {
|
|
135
|
+
return _useFilteredItems.useFilteredItems;
|
|
136
|
+
}
|
|
137
|
+
});
|
|
132
138
|
var _AutocompleteRoot = require("./root/AutocompleteRoot");
|
|
133
139
|
var _AutocompleteValue = require("./value/AutocompleteValue");
|
|
134
140
|
var _ComboboxTrigger = require("../combobox/trigger/ComboboxTrigger");
|
|
@@ -149,4 +155,5 @@ var _ComboboxRow = require("../combobox/row/ComboboxRow");
|
|
|
149
155
|
var _ComboboxCollection = require("../combobox/collection/ComboboxCollection");
|
|
150
156
|
var _ComboboxEmpty = require("../combobox/empty/ComboboxEmpty");
|
|
151
157
|
var _Separator = require("../separator/Separator");
|
|
152
|
-
var _useFilter = require("../combobox/root/utils/useFilter");
|
|
158
|
+
var _useFilter = require("../combobox/root/utils/useFilter");
|
|
159
|
+
var _useFilteredItems = require("../combobox/root/utils/useFilteredItems");
|
|
@@ -20,7 +20,7 @@ export declare function AutocompleteRoot<ItemValue>(props: Omit<AutocompleteRoot
|
|
|
20
20
|
* The items to be displayed in the list.
|
|
21
21
|
* Can be either a flat array of items or an array of groups with items.
|
|
22
22
|
*/
|
|
23
|
-
items?: readonly ItemValue[];
|
|
23
|
+
items?: readonly ItemValue[] | undefined;
|
|
24
24
|
}): React.JSX.Element;
|
|
25
25
|
export type AutocompleteRootState = AriaCombobox.State;
|
|
26
26
|
export interface AutocompleteRootActions {
|
|
@@ -30,7 +30,7 @@ export type AutocompleteRootChangeEventReason = AriaCombobox.ChangeEventReason;
|
|
|
30
30
|
export type AutocompleteRootChangeEventDetails = AriaCombobox.ChangeEventDetails;
|
|
31
31
|
export type AutocompleteRootHighlightEventReason = AriaCombobox.HighlightEventReason;
|
|
32
32
|
export type AutocompleteRootHighlightEventDetails = AriaCombobox.HighlightEventDetails;
|
|
33
|
-
export interface AutocompleteRootProps<ItemValue> extends Omit<AriaCombobox.Props<ItemValue, 'none'>, 'selectionMode' | 'selectedValue' | 'defaultSelectedValue' | 'onSelectedValueChange' | 'fillInputOnItemPress' | 'itemToStringValue' | 'isItemEqualToValue' | 'inputValue' | 'defaultInputValue' | 'onInputValueChange' | 'autoComplete' | 'itemToStringLabel' | 'autoHighlight' | 'keepHighlight' | 'highlightItemOnHover' | 'actionsRef' | 'onOpenChange'> {
|
|
33
|
+
export interface AutocompleteRootProps<ItemValue> extends Omit<AriaCombobox.Props<ItemValue, 'none'>, 'selectionMode' | 'selectedValue' | 'defaultSelectedValue' | 'onSelectedValueChange' | 'fillInputOnItemPress' | 'itemToStringValue' | 'isItemEqualToValue' | 'inputValue' | 'defaultInputValue' | 'onInputValueChange' | 'autoComplete' | 'formAutoComplete' | 'itemToStringLabel' | 'autoHighlight' | 'keepHighlight' | 'highlightItemOnHover' | 'actionsRef' | 'onOpenChange' | 'openOnInputClick'> {
|
|
34
34
|
/**
|
|
35
35
|
* Controls how the autocomplete behaves with respect to list filtering and inline autocompletion.
|
|
36
36
|
* - `list` (default): items are dynamically filtered based on the input value. The input value does not change based on the active item.
|
|
@@ -39,62 +39,62 @@ export interface AutocompleteRootProps<ItemValue> extends Omit<AriaCombobox.Prop
|
|
|
39
39
|
* - `none`: items are static (not filtered), and the input value will not change based on the active item.
|
|
40
40
|
* @default 'list'
|
|
41
41
|
*/
|
|
42
|
-
mode?: 'list' | 'both' | 'inline' | 'none';
|
|
42
|
+
mode?: ('list' | 'both' | 'inline' | 'none') | undefined;
|
|
43
43
|
/**
|
|
44
44
|
* Whether the first matching item is highlighted automatically.
|
|
45
45
|
* - `true`: highlight after the user types and keep the highlight while the query changes.
|
|
46
46
|
* - `'always'`: always highlight the first item.
|
|
47
47
|
* @default false
|
|
48
48
|
*/
|
|
49
|
-
autoHighlight?: boolean | 'always';
|
|
49
|
+
autoHighlight?: (boolean | 'always') | undefined;
|
|
50
50
|
/**
|
|
51
51
|
* Whether the highlighted item should be preserved when the pointer leaves the list.
|
|
52
52
|
* @default false
|
|
53
53
|
*/
|
|
54
|
-
keepHighlight?: boolean;
|
|
54
|
+
keepHighlight?: boolean | undefined;
|
|
55
55
|
/**
|
|
56
56
|
* Whether moving the pointer over items should highlight them.
|
|
57
57
|
* Disabling this prop allows CSS `:hover` to be differentiated from the `:focus` (`data-highlighted`) state.
|
|
58
58
|
* @default true
|
|
59
59
|
*/
|
|
60
|
-
highlightItemOnHover?: boolean;
|
|
60
|
+
highlightItemOnHover?: boolean | undefined;
|
|
61
61
|
/**
|
|
62
62
|
* The uncontrolled input value of the autocomplete when it's initially rendered.
|
|
63
63
|
*
|
|
64
64
|
* To render a controlled autocomplete, use the `value` prop instead.
|
|
65
65
|
*/
|
|
66
|
-
defaultValue?: AriaCombobox.Props<React.ComponentProps<'input'>['defaultValue'], 'none'>['defaultInputValue'];
|
|
66
|
+
defaultValue?: AriaCombobox.Props<React.ComponentProps<'input'>['defaultValue'], 'none'>['defaultInputValue'] | undefined;
|
|
67
67
|
/**
|
|
68
68
|
* The input value of the autocomplete. Use when controlled.
|
|
69
69
|
*/
|
|
70
|
-
value?: AriaCombobox.Props<React.ComponentProps<'input'>['value'], 'none'>['inputValue'];
|
|
70
|
+
value?: AriaCombobox.Props<React.ComponentProps<'input'>['value'], 'none'>['inputValue'] | undefined;
|
|
71
71
|
/**
|
|
72
72
|
* Event handler called when the input value of the autocomplete changes.
|
|
73
73
|
*/
|
|
74
|
-
onValueChange?: (value: string, eventDetails: AutocompleteRootChangeEventDetails) => void;
|
|
74
|
+
onValueChange?: ((value: string, eventDetails: AutocompleteRootChangeEventDetails) => void) | undefined;
|
|
75
75
|
/**
|
|
76
76
|
* Whether clicking an item should submit the autocomplete's owning form.
|
|
77
77
|
* By default, clicking an item via a pointer or <kbd>Enter</kbd> key does not submit the owning form.
|
|
78
78
|
* Useful when the autocomplete is used as a single-field form search input.
|
|
79
79
|
* @default false
|
|
80
80
|
*/
|
|
81
|
-
submitOnItemClick?: AriaCombobox.Props<ItemValue, 'none'>['submitOnItemClick'];
|
|
81
|
+
submitOnItemClick?: AriaCombobox.Props<ItemValue, 'none'>['submitOnItemClick'] | undefined;
|
|
82
82
|
/**
|
|
83
83
|
* When the item values are objects (`<Autocomplete.Item value={object}>`), this function converts the object value to a string representation for both display in the input and form submission.
|
|
84
84
|
* If the shape of the object is `{ value, label }`, the label will be used automatically without needing to specify this prop.
|
|
85
85
|
*/
|
|
86
|
-
itemToStringValue?: (itemValue: ItemValue) => string;
|
|
86
|
+
itemToStringValue?: ((itemValue: ItemValue) => string) | undefined;
|
|
87
87
|
/**
|
|
88
88
|
* A ref to imperative actions.
|
|
89
89
|
* - `unmount`: When specified, the autocomplete will not be unmounted when closed.
|
|
90
90
|
* Instead, the `unmount` function must be called to unmount the autocomplete manually.
|
|
91
91
|
* Useful when the autocomplete's animation is controlled by an external library.
|
|
92
92
|
*/
|
|
93
|
-
actionsRef?: React.RefObject<AutocompleteRootActions | null
|
|
93
|
+
actionsRef?: React.RefObject<AutocompleteRootActions | null> | undefined;
|
|
94
94
|
/**
|
|
95
95
|
* Event handler called when the popup is opened or closed.
|
|
96
96
|
*/
|
|
97
|
-
onOpenChange?: (open: boolean, eventDetails: AutocompleteRootChangeEventDetails) => void;
|
|
97
|
+
onOpenChange?: ((open: boolean, eventDetails: AutocompleteRootChangeEventDetails) => void) | undefined;
|
|
98
98
|
/**
|
|
99
99
|
* Callback fired when an item is highlighted or unhighlighted.
|
|
100
100
|
* Receives the highlighted item value (or `undefined` if no item is highlighted) and event details with a `reason` property describing why the highlight changed.
|
|
@@ -103,7 +103,12 @@ export interface AutocompleteRootProps<ItemValue> extends Omit<AriaCombobox.Prop
|
|
|
103
103
|
* - `'pointer'`: the highlight changed due to pointer hovering.
|
|
104
104
|
* - `'none'`: the highlight changed programmatically.
|
|
105
105
|
*/
|
|
106
|
-
onItemHighlighted?: (highlightedValue: ItemValue | undefined, eventDetails: AutocompleteRootHighlightEventDetails) => void;
|
|
106
|
+
onItemHighlighted?: ((highlightedValue: ItemValue | undefined, eventDetails: AutocompleteRootHighlightEventDetails) => void) | undefined;
|
|
107
|
+
/**
|
|
108
|
+
* Whether the popup opens when clicking the input.
|
|
109
|
+
* @default false
|
|
110
|
+
*/
|
|
111
|
+
openOnInputClick?: boolean | undefined;
|
|
107
112
|
}
|
|
108
113
|
export declare namespace AutocompleteRoot {
|
|
109
114
|
type Props<ItemValue> = AutocompleteRootProps<ItemValue>;
|
|
@@ -65,21 +65,19 @@ function AutocompleteRoot(props) {
|
|
|
65
65
|
if (other.filter) {
|
|
66
66
|
return other.filter;
|
|
67
67
|
}
|
|
68
|
-
return
|
|
69
|
-
|
|
70
|
-
};
|
|
71
|
-
}, [other, collator]);
|
|
68
|
+
return collator.contains;
|
|
69
|
+
}, [other.filter, collator]);
|
|
72
70
|
const resolvedQuery = String(isControlled ? value : internalValue).trim();
|
|
73
71
|
|
|
74
72
|
// In "both", wrap filtering to use only the typed value, ignoring the inline value.
|
|
75
73
|
const resolvedFilter = React.useMemo(() => {
|
|
76
74
|
if (mode !== 'both') {
|
|
77
|
-
return staticItems ? null :
|
|
75
|
+
return staticItems ? null : baseFilter;
|
|
78
76
|
}
|
|
79
77
|
return (item, _query, toString) => {
|
|
80
78
|
return baseFilter(item, resolvedQuery, toString);
|
|
81
79
|
};
|
|
82
|
-
}, [baseFilter, mode,
|
|
80
|
+
}, [baseFilter, mode, resolvedQuery, staticItems]);
|
|
83
81
|
const handleItemHighlighted = (0, _useStableCallback.useStableCallback)((highlightedValue, eventDetails) => {
|
|
84
82
|
props.onItemHighlighted?.(highlightedValue, eventDetails);
|
|
85
83
|
if (eventDetails.reason === _reasons.REASONS.pointer) {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BaseUIComponentProps } from "../../utils/types.js";
|
|
3
3
|
import type { AvatarRoot } from "../root/AvatarRoot.js";
|
|
4
|
+
import { type TransitionStatus } from "../../utils/useTransitionStatus.js";
|
|
4
5
|
/**
|
|
5
6
|
* Rendered when the image fails to load or when no image is provided.
|
|
6
7
|
* Renders a `<span>` element.
|
|
@@ -8,12 +9,16 @@ import type { AvatarRoot } from "../root/AvatarRoot.js";
|
|
|
8
9
|
* Documentation: [Base UI Avatar](https://base-ui.com/react/components/avatar)
|
|
9
10
|
*/
|
|
10
11
|
export declare const AvatarFallback: React.ForwardRefExoticComponent<Omit<AvatarFallbackProps, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
11
|
-
export interface
|
|
12
|
+
export interface AvatarFallbackState extends AvatarRoot.State {
|
|
13
|
+
transitionStatus: TransitionStatus;
|
|
14
|
+
}
|
|
15
|
+
export interface AvatarFallbackProps extends BaseUIComponentProps<'span', AvatarFallback.State> {
|
|
12
16
|
/**
|
|
13
17
|
* How long to wait before showing the fallback. Specified in milliseconds.
|
|
14
18
|
*/
|
|
15
|
-
delay?: number;
|
|
19
|
+
delay?: number | undefined;
|
|
16
20
|
}
|
|
17
21
|
export declare namespace AvatarFallback {
|
|
22
|
+
type State = AvatarFallbackState;
|
|
18
23
|
type Props = AvatarFallbackProps;
|
|
19
24
|
}
|
|
@@ -11,6 +11,14 @@ var _useTimeout = require("@base-ui/utils/useTimeout");
|
|
|
11
11
|
var _useRenderElement = require("../../utils/useRenderElement");
|
|
12
12
|
var _AvatarRootContext = require("../root/AvatarRootContext");
|
|
13
13
|
var _stateAttributesMapping = require("../root/stateAttributesMapping");
|
|
14
|
+
var _useOpenChangeComplete = require("../../utils/useOpenChangeComplete");
|
|
15
|
+
var _stateAttributesMapping2 = require("../../utils/stateAttributesMapping");
|
|
16
|
+
var _useTransitionStatus = require("../../utils/useTransitionStatus");
|
|
17
|
+
const stateAttributesMapping = {
|
|
18
|
+
..._stateAttributesMapping.avatarStateAttributesMapping,
|
|
19
|
+
..._stateAttributesMapping2.transitionStatusMapping
|
|
20
|
+
};
|
|
21
|
+
|
|
14
22
|
/**
|
|
15
23
|
* Rendered when the image fails to load or when no image is provided.
|
|
16
24
|
* Renders a `<span>` element.
|
|
@@ -29,22 +37,42 @@ const AvatarFallback = exports.AvatarFallback = /*#__PURE__*/React.forwardRef(fu
|
|
|
29
37
|
} = (0, _AvatarRootContext.useAvatarRootContext)();
|
|
30
38
|
const [delayPassed, setDelayPassed] = React.useState(delay === undefined);
|
|
31
39
|
const timeout = (0, _useTimeout.useTimeout)();
|
|
40
|
+
const visible = imageLoadingStatus !== 'loaded' && delayPassed;
|
|
41
|
+
const {
|
|
42
|
+
mounted,
|
|
43
|
+
transitionStatus,
|
|
44
|
+
setMounted
|
|
45
|
+
} = (0, _useTransitionStatus.useTransitionStatus)(visible);
|
|
46
|
+
const fallbackRef = React.useRef(null);
|
|
32
47
|
React.useEffect(() => {
|
|
33
48
|
if (delay !== undefined) {
|
|
34
49
|
timeout.start(delay, () => setDelayPassed(true));
|
|
35
50
|
}
|
|
36
51
|
return timeout.clear;
|
|
37
52
|
}, [timeout, delay]);
|
|
38
|
-
const state =
|
|
39
|
-
imageLoadingStatus
|
|
40
|
-
|
|
53
|
+
const state = {
|
|
54
|
+
imageLoadingStatus,
|
|
55
|
+
transitionStatus
|
|
56
|
+
};
|
|
57
|
+
(0, _useOpenChangeComplete.useOpenChangeComplete)({
|
|
58
|
+
open: visible,
|
|
59
|
+
ref: fallbackRef,
|
|
60
|
+
onComplete() {
|
|
61
|
+
if (!visible) {
|
|
62
|
+
setMounted(false);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
});
|
|
41
66
|
const element = (0, _useRenderElement.useRenderElement)('span', componentProps, {
|
|
42
67
|
state,
|
|
43
|
-
ref: forwardedRef,
|
|
68
|
+
ref: [forwardedRef, fallbackRef],
|
|
44
69
|
props: elementProps,
|
|
45
|
-
stateAttributesMapping
|
|
46
|
-
enabled:
|
|
70
|
+
stateAttributesMapping,
|
|
71
|
+
enabled: mounted
|
|
47
72
|
});
|
|
73
|
+
if (!mounted) {
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
48
76
|
return element;
|
|
49
77
|
});
|
|
50
78
|
if (process.env.NODE_ENV !== "production") AvatarFallback.displayName = "AvatarFallback";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BaseUIComponentProps } from "../../utils/types.js";
|
|
3
3
|
import type { AvatarRoot } from "../root/AvatarRoot.js";
|
|
4
|
+
import { type TransitionStatus } from "../../utils/useTransitionStatus.js";
|
|
4
5
|
import { ImageLoadingStatus } from "./useImageLoadingStatus.js";
|
|
5
6
|
/**
|
|
6
7
|
* The image to be displayed in the avatar.
|
|
@@ -9,12 +10,16 @@ import { ImageLoadingStatus } from "./useImageLoadingStatus.js";
|
|
|
9
10
|
* Documentation: [Base UI Avatar](https://base-ui.com/react/components/avatar)
|
|
10
11
|
*/
|
|
11
12
|
export declare const AvatarImage: React.ForwardRefExoticComponent<Omit<AvatarImageProps, "ref"> & React.RefAttributes<HTMLImageElement>>;
|
|
12
|
-
export interface
|
|
13
|
+
export interface AvatarImageState extends AvatarRoot.State {
|
|
14
|
+
transitionStatus: TransitionStatus;
|
|
15
|
+
}
|
|
16
|
+
export interface AvatarImageProps extends BaseUIComponentProps<'img', AvatarImage.State> {
|
|
13
17
|
/**
|
|
14
18
|
* Callback fired when the loading status changes.
|
|
15
19
|
*/
|
|
16
|
-
onLoadingStatusChange?: (status: ImageLoadingStatus) => void;
|
|
20
|
+
onLoadingStatusChange?: ((status: ImageLoadingStatus) => void) | undefined;
|
|
17
21
|
}
|
|
18
22
|
export declare namespace AvatarImage {
|
|
23
|
+
type State = AvatarImageState;
|
|
19
24
|
type Props = AvatarImageProps;
|
|
20
25
|
}
|
|
@@ -12,7 +12,15 @@ var _useIsoLayoutEffect = require("@base-ui/utils/useIsoLayoutEffect");
|
|
|
12
12
|
var _useRenderElement = require("../../utils/useRenderElement");
|
|
13
13
|
var _AvatarRootContext = require("../root/AvatarRootContext");
|
|
14
14
|
var _stateAttributesMapping = require("../root/stateAttributesMapping");
|
|
15
|
+
var _useOpenChangeComplete = require("../../utils/useOpenChangeComplete");
|
|
16
|
+
var _stateAttributesMapping2 = require("../../utils/stateAttributesMapping");
|
|
17
|
+
var _useTransitionStatus = require("../../utils/useTransitionStatus");
|
|
15
18
|
var _useImageLoadingStatus = require("./useImageLoadingStatus");
|
|
19
|
+
const stateAttributesMapping = {
|
|
20
|
+
..._stateAttributesMapping.avatarStateAttributesMapping,
|
|
21
|
+
..._stateAttributesMapping2.transitionStatusMapping
|
|
22
|
+
};
|
|
23
|
+
|
|
16
24
|
/**
|
|
17
25
|
* The image to be displayed in the avatar.
|
|
18
26
|
* Renders an `<img>` element.
|
|
@@ -33,6 +41,13 @@ const AvatarImage = exports.AvatarImage = /*#__PURE__*/React.forwardRef(function
|
|
|
33
41
|
referrerPolicy,
|
|
34
42
|
crossOrigin
|
|
35
43
|
});
|
|
44
|
+
const isVisible = imageLoadingStatus === 'loading' || imageLoadingStatus === 'loaded';
|
|
45
|
+
const {
|
|
46
|
+
mounted,
|
|
47
|
+
transitionStatus,
|
|
48
|
+
setMounted
|
|
49
|
+
} = (0, _useTransitionStatus.useTransitionStatus)(isVisible);
|
|
50
|
+
const imageRef = React.useRef(null);
|
|
36
51
|
const handleLoadingStatusChange = (0, _useStableCallback.useStableCallback)(status => {
|
|
37
52
|
onLoadingStatusChangeProp?.(status);
|
|
38
53
|
context.setImageLoadingStatus(status);
|
|
@@ -42,16 +57,30 @@ const AvatarImage = exports.AvatarImage = /*#__PURE__*/React.forwardRef(function
|
|
|
42
57
|
handleLoadingStatusChange(imageLoadingStatus);
|
|
43
58
|
}
|
|
44
59
|
}, [imageLoadingStatus, handleLoadingStatusChange]);
|
|
45
|
-
const
|
|
46
|
-
|
|
47
|
-
|
|
60
|
+
const resolvedTransitionStatus = imageLoadingStatus === 'loading' ? 'starting' : transitionStatus;
|
|
61
|
+
const state = {
|
|
62
|
+
imageLoadingStatus,
|
|
63
|
+
transitionStatus: resolvedTransitionStatus
|
|
64
|
+
};
|
|
65
|
+
(0, _useOpenChangeComplete.useOpenChangeComplete)({
|
|
66
|
+
open: isVisible,
|
|
67
|
+
ref: imageRef,
|
|
68
|
+
onComplete() {
|
|
69
|
+
if (!isVisible) {
|
|
70
|
+
setMounted(false);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
});
|
|
48
74
|
const element = (0, _useRenderElement.useRenderElement)('img', componentProps, {
|
|
49
75
|
state,
|
|
50
|
-
ref: forwardedRef,
|
|
76
|
+
ref: [forwardedRef, imageRef],
|
|
51
77
|
props: elementProps,
|
|
52
|
-
stateAttributesMapping
|
|
53
|
-
enabled:
|
|
78
|
+
stateAttributesMapping,
|
|
79
|
+
enabled: mounted
|
|
54
80
|
});
|
|
81
|
+
if (!mounted) {
|
|
82
|
+
return null;
|
|
83
|
+
}
|
|
55
84
|
return element;
|
|
56
85
|
});
|
|
57
86
|
if (process.env.NODE_ENV !== "production") AvatarImage.displayName = "AvatarImage";
|