tfy-web-components 0.0.43 → 0.0.45
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/dist/{Button-CPJYHldw.js → Button-HHEfL8b9.js} +5 -4
- package/dist/{Button-CPJYHldw.js.map → Button-HHEfL8b9.js.map} +1 -1
- package/dist/CSPContext-Cldo9QDp.js +13 -0
- package/dist/CSPContext-Cldo9QDp.js.map +1 -0
- package/dist/{CompositeItem-DJWNsIwE.js → CompositeItem-GNejxLcK.js} +3 -3
- package/dist/{CompositeItem-DJWNsIwE.js.map → CompositeItem-GNejxLcK.js.map} +1 -1
- package/dist/{CompositeRoot-BlljDWkR.js → CompositeRoot-7_u1HqDT.js} +9 -47
- package/dist/CompositeRoot-7_u1HqDT.js.map +1 -0
- package/dist/DropdownMenu-Crlf-J4E.js +3304 -0
- package/dist/DropdownMenu-Crlf-J4E.js.map +1 -0
- package/dist/{Input-Dcxu6SVO.js → Input-BS9fWUAf.js} +3 -3
- package/dist/{Input-Dcxu6SVO.js.map → Input-BS9fWUAf.js.map} +1 -1
- package/dist/{Modal-BUWlwJcN.js → Modal-DaHG8mjy.js} +10 -10
- package/dist/{Modal-BUWlwJcN.js.map → Modal-DaHG8mjy.js.map} +1 -1
- package/dist/Popover-A8IyEt2w.js +400 -0
- package/dist/Popover-A8IyEt2w.js.map +1 -0
- package/dist/{Popover-BqqXJnK1.js → PopoverPopup-teGm7D5T.js} +25 -498
- package/dist/PopoverPopup-teGm7D5T.js.map +1 -0
- package/dist/PrehydrationScript-B3u_PP2W.js +49 -0
- package/dist/PrehydrationScript-B3u_PP2W.js.map +1 -0
- package/dist/Select-BtX40h2K.js +2187 -0
- package/dist/Select-BtX40h2K.js.map +1 -0
- package/dist/{useValueAsRef-BfFRcMg6.js → addEventListener-D-i9O6BG.js} +8 -8
- package/dist/addEventListener-D-i9O6BG.js.map +1 -0
- package/dist/clamp-D7_nsB8C.js +30 -0
- package/dist/clamp-D7_nsB8C.js.map +1 -0
- package/dist/components/atoms/Accordion.es.js +9 -9
- package/dist/components/atoms/Avatar.es.js +9 -9
- package/dist/components/atoms/Avatar.es.js.map +1 -1
- package/dist/components/atoms/Badge.d.ts +5 -6
- package/dist/components/atoms/Badge.es.js +80 -43
- package/dist/components/atoms/Badge.es.js.map +1 -1
- package/dist/components/atoms/Button.d.ts +1 -1
- package/dist/components/atoms/Button.es.js +2 -2
- package/dist/components/atoms/ButtonGroup.es.js +1 -1
- package/dist/components/atoms/Combobox.d.ts +34 -0
- package/dist/components/atoms/Combobox.es.js +3252 -0
- package/dist/components/atoms/Combobox.es.js.map +1 -0
- package/dist/components/atoms/ContextMenu.d.ts +12 -0
- package/dist/components/atoms/ContextMenu.es.js +259 -0
- package/dist/components/atoms/ContextMenu.es.js.map +1 -0
- package/dist/components/atoms/DropdownMenu.d.ts +51 -0
- package/dist/components/atoms/DropdownMenu.es.js +31 -0
- package/dist/components/atoms/DropdownMenu.es.js.map +1 -0
- package/dist/components/atoms/IconButton.d.ts +1 -1
- package/dist/components/atoms/IconButton.es.js +3 -3
- package/dist/components/atoms/IconButton.es.js.map +1 -1
- package/dist/components/atoms/IconProvider.es.js +4 -1
- package/dist/components/atoms/IconProvider.es.js.map +1 -1
- package/dist/components/atoms/Modal.es.js +1 -1
- package/dist/components/atoms/OverflowButton.es.js +2 -2
- package/dist/components/atoms/PaginationDot.d.ts +14 -0
- package/dist/components/atoms/PaginationDot.es.js +58 -0
- package/dist/components/atoms/PaginationDot.es.js.map +1 -0
- package/dist/components/atoms/PaginationItem.d.ts +15 -0
- package/dist/components/atoms/PaginationItem.es.js +87 -0
- package/dist/components/atoms/PaginationItem.es.js.map +1 -0
- package/dist/components/atoms/Popover.d.ts +10 -0
- package/dist/components/atoms/Popover.es.js +50 -0
- package/dist/components/atoms/Popover.es.js.map +1 -0
- package/dist/components/atoms/Select.d.ts +63 -0
- package/dist/components/atoms/Select.es.js +23 -0
- package/dist/components/atoms/Select.es.js.map +1 -0
- package/dist/components/atoms/Switch.es.js +7 -6
- package/dist/components/atoms/Switch.es.js.map +1 -1
- package/dist/components/atoms/TabButton.d.ts +31 -6
- package/dist/components/atoms/TabButton.es.js +425 -55
- package/dist/components/atoms/TabButton.es.js.map +1 -1
- package/dist/components/atoms/Tag.d.ts +2 -2
- package/dist/components/atoms/Tag.es.js +66 -33
- package/dist/components/atoms/Tag.es.js.map +1 -1
- package/dist/components/atoms/Tooltip.es.js +1153 -19
- package/dist/components/atoms/Tooltip.es.js.map +1 -1
- package/dist/components/atoms/stories/OverlayThemePanels.d.ts +8 -0
- package/dist/components/molecules/Alert.es.js +3 -3
- package/dist/components/molecules/CopyField.es.js +2 -2
- package/dist/components/molecules/CustomDrawer.es.js +1 -1
- package/dist/components/molecules/Dialog.es.js +1 -1
- package/dist/components/molecules/ImagesPreview.es.js +2 -2
- package/dist/components/molecules/Input.es.js +2 -2
- package/dist/components/molecules/Markdown.es.js +1 -1
- package/dist/components/molecules/Pagination.d.ts +58 -0
- package/dist/components/molecules/Pagination.es.js +272 -0
- package/dist/components/molecules/Pagination.es.js.map +1 -0
- package/dist/components/molecules/SimpleCodeEditor.es.js +3 -3
- package/dist/components/molecules/SimpleCodeEditor.es.js.map +1 -1
- package/dist/components/molecules/TagGroup.d.ts +11 -0
- package/dist/components/molecules/TagGroup.es.js +59 -0
- package/dist/components/molecules/TagGroup.es.js.map +1 -0
- package/dist/components/molecules/ToggleButton.es.js +2 -2
- package/dist/components/molecules/TopBar.d.ts +47 -0
- package/dist/components/molecules/TopBar.es.js +164 -0
- package/dist/components/molecules/TopBar.es.js.map +1 -0
- package/dist/components/molecules/agent-chat/AssistantMessage.d.ts +3 -1
- package/dist/components/molecules/agent-chat.es.js +4 -3
- package/dist/components/molecules/agent-chat.es.js.map +1 -1
- package/dist/components/theme/colors.es.js +1 -0
- package/dist/components/theme/colors.es.js.map +1 -1
- package/dist/composite-DnShFmi7.js +551 -0
- package/dist/composite-DnShFmi7.js.map +1 -0
- package/dist/{composite-C22yiNy1.js → composite-IA--dSel.js} +2 -2
- package/dist/{composite-C22yiNy1.js.map → composite-IA--dSel.js.map} +1 -1
- package/dist/constants-BaUKmVF_.js +103 -0
- package/dist/constants-BaUKmVF_.js.map +1 -0
- package/dist/{index-C-2yrwZl.js → element-B1vbc-LG.js} +69 -111
- package/dist/element-B1vbc-LG.js.map +1 -0
- package/dist/error-nCTLdGUr.js +6 -0
- package/dist/{error-FX4R42W-.js.map → error-nCTLdGUr.js.map} +1 -1
- package/dist/index.d.ts +12 -2
- package/dist/index.es.js +65 -12
- package/dist/index.es.js.map +1 -1
- package/dist/{inertValue-IJM5NA30.js → inertValue-C1Ml1s55.js} +2 -2
- package/dist/{inertValue-IJM5NA30.js.map → inertValue-C1Ml1s55.js.map} +1 -1
- package/dist/isElementDisabled-lq1fKien.js +47 -0
- package/dist/isElementDisabled-lq1fKien.js.map +1 -0
- package/dist/new-components/atoms/Alert.d.ts +9 -1
- package/dist/new-components/atoms/Alert.es.js +38 -13
- package/dist/new-components/atoms/Alert.es.js.map +1 -1
- package/dist/new-components/atoms/Checkbox.es.js +8 -7
- package/dist/new-components/atoms/Checkbox.es.js.map +1 -1
- package/dist/new-components/atoms/EmptyState.d.ts +3 -0
- package/dist/new-components/atoms/EmptyState.es.js +9 -4
- package/dist/new-components/atoms/EmptyState.es.js.map +1 -1
- package/dist/new-components/atoms/Popover.es.js +3 -2
- package/dist/new-components/atoms/Popover.es.js.map +1 -1
- package/dist/new-components/atoms/Radio.es.js +13 -24
- package/dist/new-components/atoms/Radio.es.js.map +1 -1
- package/dist/new-components/atoms/SegmentedControl.es.js +7 -7
- package/dist/new-components/atoms/Slider.es.js +14 -88
- package/dist/new-components/atoms/Slider.es.js.map +1 -1
- package/dist/new-components/atoms/Toast.d.ts +8 -12
- package/dist/new-components/atoms/Toast.es.js +202 -145
- package/dist/new-components/atoms/Toast.es.js.map +1 -1
- package/dist/new-components/atoms/Toggletip.d.ts +1 -1
- package/dist/new-components/atoms/Toggletip.es.js +3 -2
- package/dist/new-components/atoms/Toggletip.es.js.map +1 -1
- package/dist/new-components/atoms/stories/ThemeComparison.d.ts +2 -1
- package/dist/serializeValue-BLvnTy3o.js +17 -0
- package/dist/serializeValue-BLvnTy3o.js.map +1 -0
- package/dist/stringifyLocale-DOx30wH1.js +13 -0
- package/dist/stringifyLocale-DOx30wH1.js.map +1 -0
- package/dist/style.css +1 -1
- package/dist/tokens.css +24 -6
- package/dist/{useAnimationFrame-DwhymJoW.js → useAnimationFrame-DqvuRtgK.js} +2 -2
- package/dist/{useAnimationFrame-DwhymJoW.js.map → useAnimationFrame-DqvuRtgK.js.map} +1 -1
- package/dist/{useAriaLabelledBy-Lyj6n_TU.js → useAriaLabelledBy-CP4wKTYs.js} +3 -3
- package/dist/{useAriaLabelledBy-Lyj6n_TU.js.map → useAriaLabelledBy-CP4wKTYs.js.map} +1 -1
- package/dist/{useBaseUiId-CmLtG9DS.js → useBaseUiId-CYT1vFMG.js} +64 -44
- package/dist/{useBaseUiId-CmLtG9DS.js.map → useBaseUiId-CYT1vFMG.js.map} +1 -1
- package/dist/{useButton-D2BMuSfC.js → useButton-BlHadUfM.js} +4 -4
- package/dist/{useButton-D2BMuSfC.js.map → useButton-BlHadUfM.js.map} +1 -1
- package/dist/{CompositeList-D4xmSZ5V.js → useCompositeListItem-DlAKWsHE.js} +59 -59
- package/dist/useCompositeListItem-DlAKWsHE.js.map +1 -0
- package/dist/{useControlled-BSyYkg5C.js → useControlled-DMDWXIzj.js} +2 -2
- package/dist/{useControlled-BSyYkg5C.js.map → useControlled-DMDWXIzj.js.map} +1 -1
- package/dist/useFocus-C__7iwl1.js +137 -0
- package/dist/useFocus-C__7iwl1.js.map +1 -0
- package/dist/{useIsoLayoutEffect-e9VA-ICd.js → useIsoLayoutEffect-D2lpsB9D.js} +8 -4
- package/dist/{useIsoLayoutEffect-e9VA-ICd.js.map → useIsoLayoutEffect-D2lpsB9D.js.map} +1 -1
- package/dist/{usePopupHandleStore-CkW2IoED.js → usePopupHandleStore-C_Vw7xcw.js} +1966 -2002
- package/dist/usePopupHandleStore-C_Vw7xcw.js.map +1 -0
- package/dist/{Tooltip-uQIVdskf.js → usePositioner-BmYVsMO_.js} +17 -1402
- package/dist/usePositioner-BmYVsMO_.js.map +1 -0
- package/dist/{useOpenInteractionType-CDFYOw2d.js → useScrollLock-By-42HSc.js} +74 -58
- package/dist/useScrollLock-By-42HSc.js.map +1 -0
- package/dist/{useLabelableId-CcIE3RU0.js → useSetFieldFocused-CcdG6FNp.js} +27 -35
- package/dist/useSetFieldFocused-CcdG6FNp.js.map +1 -0
- package/dist/{useTimeout-BXf1hDIL.js → useTimeout-D1vYJgq4.js} +3 -3
- package/dist/{useTimeout-BXf1hDIL.js.map → useTimeout-D1vYJgq4.js.map} +1 -1
- package/dist/{useTransitionStatus-C9gg_XJ-.js → useTransitionStatus-CHrs3i5F.js} +3 -3
- package/dist/{useTransitionStatus-C9gg_XJ-.js.map → useTransitionStatus-CHrs3i5F.js.map} +1 -1
- package/dist/useTriggerFocusGuards-CXAhW8P6.js +100 -0
- package/dist/useTriggerFocusGuards-CXAhW8P6.js.map +1 -0
- package/dist/useValueChanged-BnlOop8k.js +16 -0
- package/dist/useValueChanged-BnlOop8k.js.map +1 -0
- package/package.json +1 -1
- package/dist/CompositeList-D4xmSZ5V.js.map +0 -1
- package/dist/CompositeRoot-BlljDWkR.js.map +0 -1
- package/dist/Popover-BqqXJnK1.js.map +0 -1
- package/dist/Tooltip-uQIVdskf.js.map +0 -1
- package/dist/composite-BL4bbAWg.js +0 -66
- package/dist/composite-BL4bbAWg.js.map +0 -1
- package/dist/error-FX4R42W-.js +0 -6
- package/dist/index-C-2yrwZl.js.map +0 -1
- package/dist/shadowDom-BfewIqRj.js +0 -52
- package/dist/shadowDom-BfewIqRj.js.map +0 -1
- package/dist/useLabelableId-CcIE3RU0.js.map +0 -1
- package/dist/useOpenInteractionType-CDFYOw2d.js.map +0 -1
- package/dist/usePopupHandleStore-CkW2IoED.js.map +0 -1
- package/dist/useValueAsRef-BfFRcMg6.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PopoverPopup-teGm7D5T.js","sources":["../node_modules/@base-ui/react/popover/root/PopoverRootContext.mjs","../node_modules/@base-ui/react/popover/store/PopoverStore.mjs","../node_modules/@base-ui/react/popover/root/PopoverRoot.mjs","../node_modules/@base-ui/react/popover/utils/constants.mjs","../node_modules/@base-ui/react/popover/trigger/PopoverTrigger.mjs","../node_modules/@base-ui/react/popover/portal/PopoverPortalContext.mjs","../node_modules/@base-ui/react/popover/portal/PopoverPortal.mjs","../node_modules/@base-ui/react/popover/positioner/PopoverPositionerContext.mjs","../node_modules/@base-ui/react/popover/positioner/PopoverPositioner.mjs","../node_modules/@base-ui/react/utils/closePart.mjs","../node_modules/@base-ui/react/popover/popup/PopoverPopup.mjs"],"sourcesContent":["'use client';\n\nimport _formatErrorMessage from \"@base-ui/utils/formatErrorMessage\";\nimport * as React from 'react';\nexport const PopoverRootContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") PopoverRootContext.displayName = \"PopoverRootContext\";\nexport function usePopoverRootContext(optional) {\n const context = React.useContext(PopoverRootContext);\n if (context === undefined && !optional) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Base UI: PopoverRootContext is missing. Popover parts must be placed within <Popover.Root>.' : _formatErrorMessage(47));\n }\n return context;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport { ReactStore } from '@base-ui/utils/store';\nimport { Timeout } from '@base-ui/utils/useTimeout';\nimport { NOOP } from '@base-ui/utils/empty';\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { NullStore } from \"../../utils/NullStore.mjs\";\nimport { attachPreventUnmountOnClose, createInitialPopupStoreState, popupStoreSelectors, PopupTriggerMap, createPopupOpenState } from \"../../utils/popups/index.mjs\";\nimport { PATIENT_CLICK_THRESHOLD } from \"../../internals/constants.mjs\";\nconst selectors = {\n ...popupStoreSelectors,\n disabled: state => state.disabled,\n // `trigger-change` describes a popup moving between triggers, which only has\n // meaning while it is open. Dropping it once closed keeps a late or stale\n // restoration from marking a closing popup instant and skipping its exit\n // transition, including on close paths that never reach `setOpen` — a\n // controlled consumer committing `open={false}` goes straight through the prop.\n instantType: state => state.instantType === 'trigger-change' && !popupStoreSelectors.open(state) ? undefined : state.instantType,\n openMethod: state => state.openMethod,\n openChangeReason: state => state.openChangeReason,\n isPressOpenedByTrigger: (state, triggerId) => state.openChangeReason === REASONS.triggerPress && popupStoreSelectors.isOpenedByTrigger(state, triggerId),\n // The trigger selectors below resolve to a constant for triggers that don't use them, so state\n // changes don't re-render every inactive trigger.\n isTouchPressOpen: (state, openOnHover) => openOnHover && state.openMethod === 'touch' && state.openChangeReason === REASONS.triggerPress,\n hasTriggerFocusGuards: (state, triggerId) => popupStoreSelectors.isOpenedByTrigger(state, triggerId) && !state.focusManagerModal,\n modal: state => state.modal,\n titleElementId: state => state.titleElementId,\n descriptionElementId: state => state.descriptionElementId,\n openOnHover: state => state.openOnHover,\n closeDelay: state => state.closeDelay,\n adaptiveOrigin: state => state.adaptiveOrigin\n};\n\n/**\n * The store view that detached handle-backed triggers read from. Both the real `PopoverStore` and\n * the inert fallback store satisfy it, so a trigger can read from whichever store the handle\n * currently exposes. Narrowed to the members a trigger actually uses — the trigger-data members plus\n * `setOpen` (called by the focus guards) — so the exposed surface can't bypass the open-change\n * pipeline; on the detached fallback store every one of these mutations is a no-op.\n */\n\nexport class PopoverStore extends ReactStore {\n constructor(initialState, floatingId, nested) {\n const triggerElements = new PopupTriggerMap();\n super(createInitialState(initialState, triggerElements, floatingId, nested), createInitialContext(triggerElements), selectors);\n }\n setOpen = (nextOpen, eventDetails) => {\n const isHover = eventDetails.reason === REASONS.triggerHover;\n const isKeyboardClick = eventDetails.reason === REASONS.triggerPress && eventDetails.event.detail === 0;\n const isDismissClose = !nextOpen && (eventDetails.reason === REASONS.escapeKey || eventDetails.reason == null);\n const shouldPreventUnmountOnClose = attachPreventUnmountOnClose(eventDetails);\n const activeTriggerId = this.select('activeTriggerId');\n if (!nextOpen && eventDetails.reason === REASONS.closePress && eventDetails.trigger == null && activeTriggerId != null) {\n eventDetails.trigger = this.context.triggerElements.getById(activeTriggerId) ?? this.select('activeTriggerElement') ?? undefined;\n }\n this.context.onOpenChange?.(nextOpen, eventDetails);\n if (eventDetails.isCanceled) {\n return;\n }\n this.state.floatingRootContext.dispatchOpenChange(nextOpen, eventDetails);\n const changeState = () => {\n const popupOpenState = createPopupOpenState(this.state, nextOpen, eventDetails.trigger, shouldPreventUnmountOnClose());\n popupOpenState.openChangeReason = eventDetails.reason;\n this.update(popupOpenState);\n };\n if (isHover) {\n // Only allow \"patient\" clicks to close the popover if it's open.\n // If they clicked within 500ms of the popover opening, keep it open.\n this.context.stickIfOpen = true;\n this.context.stickIfOpenTimeout.start(PATIENT_CLICK_THRESHOLD, () => {\n this.context.stickIfOpen = false;\n });\n ReactDOM.flushSync(changeState);\n } else {\n changeState();\n }\n let instantType;\n if (isKeyboardClick) {\n instantType = 'click';\n } else if (isDismissClose) {\n instantType = 'dismiss';\n } else if (eventDetails.reason === REASONS.focusOut) {\n instantType = 'focus';\n }\n this.set('instantType', instantType);\n };\n}\n\n/**\n * Creates the inert fallback store used by detached handle-backed triggers while no\n * `Popover.Root` is attached. It preserves a popover-specific trigger registry in context so\n * detached triggers can register before migrating to the live root store. `setOpen` is a no-op\n * (matching the inert reads/writes of `NullStore`), so a trigger can hand the store to focus-guard\n * helpers that expect `setOpen` without it ever taking effect while detached.\n */\nexport function createNullPopoverStore() {\n const triggerElements = new PopupTriggerMap();\n const store = new NullStore(Object.freeze(createInitialState(undefined, triggerElements)), Object.freeze(createInitialContext(triggerElements)), selectors);\n return Object.assign(store, {\n setOpen: NOOP\n });\n}\nfunction createInitialState(initialState, triggerElements, floatingId, nested = false) {\n const state = {\n ...createInitialPopupStoreState(triggerElements, floatingId, nested),\n disabled: false,\n modal: false,\n focusManagerModal: false,\n instantType: undefined,\n openMethod: null,\n openChangeReason: null,\n titleElementId: undefined,\n descriptionElementId: undefined,\n openOnHover: false,\n closeDelay: 0,\n adaptiveOrigin: undefined,\n ...initialState\n };\n if (state.open && initialState?.mounted === undefined) {\n state.mounted = true;\n }\n return state;\n}\nfunction createInitialContext(triggerElements) {\n return {\n popupRef: /*#__PURE__*/React.createRef(),\n onOpenChange: undefined,\n onOpenChangeComplete: undefined,\n triggerFocusTargetRef: /*#__PURE__*/React.createRef(),\n beforeTriggerFocusGuardRef: /*#__PURE__*/React.createRef(),\n beforeContentFocusGuardRef: /*#__PURE__*/React.createRef(),\n stickIfOpenTimeout: new Timeout(),\n stickIfOpen: true,\n triggerElements\n };\n}","'use client';\n\nimport * as React from 'react';\nimport { fastComponent } from '@base-ui/utils/fastHooks';\nimport { useDismiss, FloatingTree } from \"../../floating-ui-react/index.mjs\";\nimport { PopoverRootContext, usePopoverRootContext } from \"./PopoverRootContext.mjs\";\nimport { PopoverStore } from \"../store/PopoverStore.mjs\";\nimport { createChangeEventDetails } from \"../../internals/createBaseUIEventDetails.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { PopupHandleAttachment, useImplicitActiveTrigger, usePopupRootStore, useOpenStateTransitions, usePopupInteractionProps, usePopupRootSync } from \"../../utils/popups/index.mjs\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst PopoverRootComponent = fastComponent(function PopoverRootComponent({\n props\n}) {\n const {\n children,\n open: openProp,\n defaultOpen = false,\n onOpenChange,\n onOpenChangeComplete,\n modal = false,\n handle,\n triggerId: triggerIdProp,\n defaultTriggerId: defaultTriggerIdProp = null\n } = props;\n const store = usePopoverRootStore(handle, {\n modal,\n open: defaultOpen,\n openProp,\n activeTriggerId: defaultTriggerIdProp,\n triggerIdProp\n });\n store.useControlledProp('openProp', openProp);\n store.useControlledProp('triggerIdProp', triggerIdProp);\n const open = store.useState('open');\n const mounted = store.useState('mounted');\n const payload = store.useState('payload');\n store.useContextCallback('onOpenChange', onOpenChange);\n store.useContextCallback('onOpenChangeComplete', onOpenChangeComplete);\n usePopupRootSync(store, open);\n useImplicitActiveTrigger(store);\n const {\n forceUnmount\n } = useOpenStateTransitions(open, store, () => {\n store.context.stickIfOpen = true;\n store.set('openChangeReason', null);\n });\n store.useSyncedValues({\n modal\n });\n React.useEffect(() => {\n if (!open) {\n store.context.stickIfOpenTimeout.clear();\n }\n }, [store, open]);\n React.useImperativeHandle(props.actionsRef, () => ({\n unmount: forceUnmount,\n close: () => store.setOpen(false, createChangeEventDetails(REASONS.imperativeAction))\n }), [forceUnmount, store]);\n\n // Detached triggers share this one Root, so mounting its interactions eagerly is cheap. The\n // trigger props they publish then stay stable, so opening and closing doesn't re-render inactive\n // triggers.\n const shouldRenderInteractions = open || mounted || handle != null;\n return /*#__PURE__*/_jsxs(PopoverRootContext.Provider, {\n value: store,\n children: [handle && /*#__PURE__*/_jsx(PopupHandleAttachment, {\n handle: handle,\n store: store\n }), shouldRenderInteractions && /*#__PURE__*/_jsx(PopoverInteractions, {\n store: store,\n modal: modal\n }), typeof children === 'function' ? children({\n payload\n }) : children]\n });\n});\n\n/**\n * Groups all parts of the popover.\n * Doesn't render its own HTML element.\n *\n * Documentation: [Base UI Popover](https://base-ui.com/react/components/popover)\n */\nif (process.env.NODE_ENV !== \"production\") PopoverRootComponent.displayName = \"PopoverRootComponent\";\nexport function PopoverRoot(props) {\n if (usePopoverRootContext(true)) {\n return /*#__PURE__*/_jsx(PopoverRootComponent, {\n props: props\n });\n }\n return /*#__PURE__*/_jsx(FloatingTree, {\n children: /*#__PURE__*/_jsx(PopoverRootComponent, {\n props: props\n })\n });\n}\nfunction usePopoverRootStore(handle, initialState) {\n // The store is owned by this Root instance and created exactly once. It is not tied to the handle:\n // the handle attaches to it, so swapping the handle re-attaches rather than recreating state.\n // Default values are only initial values; controlled values and root state are synced after creation.\n const store = usePopupRootStore((floatingId, nested) => new PopoverStore(initialState, floatingId, nested));\n\n // Popover-specific: dispose the patient-click timeout held in the store's context on unmount.\n React.useEffect(() => store.context.stickIfOpenTimeout.disposeEffect(), [store]);\n return store;\n}\nfunction PopoverInteractions({\n store,\n modal\n}) {\n const floatingRootContext = store.useState('floatingRootContext');\n const dismiss = useDismiss(floatingRootContext, {\n outsidePressEvent: {\n // Ensure `aria-hidden` on outside elements is removed immediately\n // on outside press when trapping focus.\n mouse: modal === 'trap-focus' ? 'sloppy' : 'intentional',\n touch: 'sloppy'\n }\n });\n\n // `useDismiss` is not given an `enabled` option, so it always returns both prop bags. Restore\n // the `EMPTY_OBJECT` fallbacks if that ever changes: the store fields are non-optional.\n // `dismiss.trigger` is always the same object as `dismiss.reference`.\n const triggerProps = dismiss.reference;\n // PopoverPopup already spreads `FOCUSABLE_POPUP_PROPS` directly, so the popup\n // props only need to carry the dismiss handlers.\n const popupProps = dismiss.floating;\n usePopupInteractionProps(store, {\n activeTriggerProps: triggerProps,\n inactiveTriggerProps: triggerProps,\n popupProps\n });\n return null;\n}","export const OPEN_DELAY = 300;","'use client';\n\nimport _formatErrorMessage from \"@base-ui/utils/formatErrorMessage\";\nimport * as React from 'react';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { fastComponentRef } from '@base-ui/utils/fastHooks';\nimport { usePopoverRootContext } from \"../root/PopoverRootContext.mjs\";\nimport { useButton } from \"../../internals/use-button/useButton.mjs\";\nimport { triggerOpenStateMapping, pressableTriggerOpenStateMapping } from \"../../utils/popupStateMapping.mjs\";\nimport { useRenderElement } from \"../../internals/useRenderElement.mjs\";\nimport { CLICK_TRIGGER_IDENTIFIER } from \"../../internals/constants.mjs\";\nimport { safePolygon, useClick, useHoverReferenceInteraction } from \"../../floating-ui-react/index.mjs\";\nimport { OPEN_DELAY } from \"../utils/constants.mjs\";\nimport { useBaseUiId } from \"../../internals/useBaseUiId.mjs\";\nimport { FocusGuard } from \"../../utils/FocusGuard.mjs\";\nimport { usePopupHandleStore, useTriggerDataForwarding } from \"../../utils/popups/index.mjs\";\nimport { useTriggerFocusGuards } from \"../../utils/popups/useTriggerFocusGuards.mjs\";\nimport { useOpenMethodTriggerProps } from \"../../utils/useOpenInteractionType.mjs\";\n\n/**\n * A button that opens the popover.\n * Renders a `<button>` element.\n *\n * Documentation: [Base UI Popover](https://base-ui.com/react/components/popover)\n */\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const PopoverTrigger = fastComponentRef(function PopoverTrigger(componentProps, forwardedRef) {\n const {\n render,\n className,\n style,\n disabled = false,\n nativeButton = true,\n handle,\n payload,\n openOnHover = false,\n delay = OPEN_DELAY,\n closeDelay = 0,\n id: idProp,\n ...elementProps\n } = componentProps;\n const rootStore = usePopoverRootContext(true);\n const handleStore = usePopupHandleStore(handle);\n const store = handleStore ?? rootStore;\n if (!store) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Base UI: <Popover.Trigger> must be either used within a <Popover.Root> component or provided with a handle.' : _formatErrorMessage(74));\n }\n const thisTriggerId = useBaseUiId(idProp);\n const isTriggerActive = store.useState('isTriggerActive', thisTriggerId);\n const floatingContext = store.useState('floatingRootContext');\n const isOpenedByThisTrigger = store.useState('isOpenedByTrigger', thisTriggerId);\n const popupId = store.useState('triggerPopupId', thisTriggerId);\n const triggerElementRef = React.useRef(null);\n const {\n registerTrigger,\n isMountedByThisTrigger\n } = useTriggerDataForwarding(thisTriggerId, triggerElementRef, store, {\n payload,\n disabled,\n openOnHover,\n closeDelay\n });\n const isPressOpenedByThisTrigger = store.useState('isPressOpenedByTrigger', thisTriggerId);\n const isTouchPressOpen = store.useState('isTouchPressOpen', openOnHover);\n const hasFocusGuards = store.useState('hasTriggerFocusGuards', thisTriggerId);\n const hoverProps = useHoverReferenceInteraction(floatingContext, {\n enabled: !disabled && openOnHover && !isTouchPressOpen,\n mouseOnly: true,\n move: false,\n handleClose: safePolygon(),\n restMs: delay,\n delay: {\n close: closeDelay\n },\n triggerElementRef,\n isActiveTrigger: isTriggerActive,\n isClosing: () => store.select('transitionStatus') === 'ending'\n });\n const getStickIfOpen = useStableCallback(() => store.context.stickIfOpen);\n const click = useClick(floatingContext, {\n stickIfOpen: getStickIfOpen\n });\n const interactionTypeProps = useOpenMethodTriggerProps(() => store.select('open'), interactionType => {\n store.set('openMethod', interactionType);\n });\n const rootTriggerProps = store.useState('triggerProps', isMountedByThisTrigger);\n const {\n getButtonProps,\n buttonRef\n } = useButton({\n disabled,\n native: nativeButton\n });\n const stateAttributesMapping = {\n open(value) {\n if (isPressOpenedByThisTrigger) {\n return pressableTriggerOpenStateMapping.open(value);\n }\n return triggerOpenStateMapping.open(value);\n }\n };\n const {\n handlePreFocusGuardFocus,\n handleFocusTargetFocus\n } = useTriggerFocusGuards(store, triggerElementRef);\n const state = {\n disabled,\n open: isOpenedByThisTrigger\n };\n const element = useRenderElement('button', componentProps, {\n state,\n ref: [buttonRef, forwardedRef, registerTrigger, triggerElementRef],\n props: [click.reference, hoverProps, rootTriggerProps, interactionTypeProps, {\n [CLICK_TRIGGER_IDENTIFIER]: '',\n id: thisTriggerId,\n 'aria-haspopup': 'dialog',\n 'aria-expanded': isOpenedByThisTrigger,\n 'aria-controls': popupId\n }, elementProps, getButtonProps],\n stateAttributesMapping\n });\n\n // A fragment with key is required to ensure that the `element` is mounted to the same DOM node\n // regardless of whether the focus guards are rendered or not.\n const keyedElement = /*#__PURE__*/_jsx(React.Fragment, {\n children: element\n }, thisTriggerId);\n if (hasFocusGuards) {\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(FocusGuard, {\n ref: store.context.beforeTriggerFocusGuardRef,\n onFocus: handlePreFocusGuardFocus\n }), keyedElement, /*#__PURE__*/_jsx(FocusGuard, {\n ref: store.context.triggerFocusTargetRef,\n onFocus: handleFocusTargetFocus\n })]\n });\n }\n return keyedElement;\n});\nif (process.env.NODE_ENV !== \"production\") PopoverTrigger.displayName = \"PopoverTrigger\";","'use client';\n\nimport _formatErrorMessage from \"@base-ui/utils/formatErrorMessage\";\nimport * as React from 'react';\nexport const PopoverPortalContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") PopoverPortalContext.displayName = \"PopoverPortalContext\";\nexport function usePopoverPortalContext() {\n const value = React.useContext(PopoverPortalContext);\n if (value === undefined) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Base UI: <Popover.Portal> is missing.' : _formatErrorMessage(45));\n }\n return value;\n}","'use client';\n\nimport * as React from 'react';\nimport { FloatingPortal } from \"../../floating-ui-react/index.mjs\";\nimport { usePopoverRootContext } from \"../root/PopoverRootContext.mjs\";\nimport { PopoverPortalContext } from \"./PopoverPortalContext.mjs\";\n\n/**\n * A portal element that moves the popup to a different part of the DOM.\n * By default, the portal element is appended to `<body>`.\n * Renders a `<div>` element.\n *\n * Documentation: [Base UI Popover](https://base-ui.com/react/components/popover)\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const PopoverPortal = /*#__PURE__*/React.forwardRef(function PopoverPortal(props, forwardedRef) {\n const {\n keepMounted = false,\n ...portalProps\n } = props;\n const store = usePopoverRootContext();\n const mounted = store.useState('mounted');\n const shouldRender = mounted || keepMounted;\n if (!shouldRender) {\n return null;\n }\n return /*#__PURE__*/_jsx(PopoverPortalContext.Provider, {\n value: keepMounted,\n children: /*#__PURE__*/_jsx(FloatingPortal, {\n ref: forwardedRef,\n ...portalProps\n })\n });\n});\nif (process.env.NODE_ENV !== \"production\") PopoverPortal.displayName = \"PopoverPortal\";","'use client';\n\nimport _formatErrorMessage from \"@base-ui/utils/formatErrorMessage\";\nimport * as React from 'react';\nexport const PopoverPositionerContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") PopoverPositionerContext.displayName = \"PopoverPositionerContext\";\nexport function usePopoverPositionerContext() {\n const context = React.useContext(PopoverPositionerContext);\n if (!context) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Base UI: PopoverPositionerContext is missing. PopoverPositioner parts must be placed within <Popover.Positioner>.' : _formatErrorMessage(46));\n }\n return context;\n}","'use client';\n\nimport * as React from 'react';\nimport { inertValue } from '@base-ui/utils/inertValue';\nimport { FloatingNode, useFloatingNodeId } from \"../../floating-ui-react/index.mjs\";\nimport { usePopoverRootContext } from \"../root/PopoverRootContext.mjs\";\nimport { PopoverPositionerContext } from \"./PopoverPositionerContext.mjs\";\nimport { useAnchorPositioning } from \"../../internals/useAnchorPositioning.mjs\";\nimport { usePopoverPortalContext } from \"../portal/PopoverPortalContext.mjs\";\nimport { InternalBackdrop } from \"../../utils/InternalBackdrop.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { POPUP_COLLISION_AVOIDANCE } from \"../../internals/constants.mjs\";\nimport { useTriggerSwitchTransition } from \"../../internals/useTriggerSwitchTransition.mjs\";\nimport { usePositioner } from \"../../utils/usePositioner.mjs\";\nimport { useAnchoredPopupScrollLock } from \"../../utils/useAnchoredPopupScrollLock.mjs\";\n\n/**\n * Positions the popover against the trigger.\n * Renders a `<div>` element.\n *\n * Documentation: [Base UI Popover](https://base-ui.com/react/components/popover)\n */\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const PopoverPositioner = /*#__PURE__*/React.forwardRef(function PopoverPositioner(componentProps, forwardedRef) {\n const {\n render,\n className,\n style,\n anchor,\n // `useAnchorPositioning` applies the same defaults to the undefined values; the names\n // remain destructured to exclude the props from `elementProps`.\n positionMethod,\n side,\n align,\n sideOffset,\n alignOffset,\n collisionBoundary = 'clipping-ancestors',\n collisionPadding,\n arrowPadding,\n sticky,\n disableAnchorTracking = false,\n collisionAvoidance = POPUP_COLLISION_AVOIDANCE,\n ...elementProps\n } = componentProps;\n const store = usePopoverRootContext();\n const keepMounted = usePopoverPortalContext();\n const nodeId = useFloatingNodeId();\n const floatingRootContext = store.useState('floatingRootContext');\n const mounted = store.useState('mounted');\n const open = store.useState('open');\n const openReason = store.useState('openChangeReason');\n const triggerElement = store.useState('activeTriggerElement');\n const modal = store.useState('modal');\n const openMethod = store.useState('openMethod');\n const positionerElement = store.useState('positionerElement');\n const instantType = store.useState('instantType');\n const transitionStatus = store.useState('transitionStatus');\n const adaptiveOrigin = store.useState('adaptiveOrigin');\n const positioning = useAnchorPositioning({\n anchor,\n floatingRootContext,\n positionMethod,\n mounted,\n side,\n sideOffset,\n align,\n alignOffset,\n arrowPadding,\n collisionBoundary,\n collisionPadding,\n sticky,\n disableAnchorTracking,\n keepMounted,\n nodeId,\n collisionAvoidance,\n adaptiveOrigin\n });\n const domReference = floatingRootContext.useState('domReferenceElement');\n useTriggerSwitchTransition({\n store,\n domReference,\n positionerElement,\n open\n });\n const trueModalNonHover = modal === true && openReason !== REASONS.triggerHover;\n useAnchoredPopupScrollLock(open && trueModalNonHover, openMethod === 'touch', positionerElement, triggerElement);\n const setPositionerElement = store.useStateSetter('positionerElement');\n const state = {\n open,\n side: positioning.side,\n align: positioning.align,\n anchorHidden: positioning.anchorHidden,\n instant: instantType\n };\n const element = usePositioner(componentProps, state, {\n styles: positioning.positionerStyles,\n transitionStatus,\n props: elementProps,\n refs: [forwardedRef, setPositionerElement],\n hidden: !mounted,\n inert: !open\n });\n return /*#__PURE__*/_jsxs(PopoverPositionerContext.Provider, {\n value: positioning,\n children: [mounted && trueModalNonHover && /*#__PURE__*/_jsx(InternalBackdrop, {\n inert: inertValue(!open),\n cutout: triggerElement\n }), /*#__PURE__*/_jsx(FloatingNode, {\n id: nodeId,\n children: element\n })]\n });\n});\nif (process.env.NODE_ENV !== \"production\") PopoverPositioner.displayName = \"PopoverPositioner\";","'use client';\n\nimport * as React from 'react';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nexport const ClosePartContext = /*#__PURE__*/React.createContext(undefined);\nif (process.env.NODE_ENV !== \"production\") ClosePartContext.displayName = \"ClosePartContext\";\nexport function useClosePartCount() {\n const [closePartCount, setClosePartCount] = React.useState(0);\n const register = useStableCallback(() => {\n setClosePartCount(count => count + 1);\n return () => {\n setClosePartCount(count => Math.max(0, count - 1));\n };\n });\n const context = React.useMemo(() => ({\n register\n }), [register]);\n return {\n context,\n hasClosePart: closePartCount > 0\n };\n}\nexport function useClosePartRegistration() {\n const context = React.useContext(ClosePartContext);\n useIsoLayoutEffect(() => {\n return context?.register();\n }, [context]);\n}","'use client';\n\nimport * as React from 'react';\nimport { isHTMLElement } from '@floating-ui/utils/dom';\nimport { FloatingFocusManager, useHoverFloatingInteraction } from \"../../floating-ui-react/index.mjs\";\nimport { usePopoverRootContext } from \"../root/PopoverRootContext.mjs\";\nimport { usePopoverPositionerContext } from \"../positioner/PopoverPositionerContext.mjs\";\nimport { popupTransitionStateMapping } from \"../../utils/popupStateMapping.mjs\";\nimport { useOpenChangeComplete } from \"../../internals/useOpenChangeComplete.mjs\";\nimport { useRenderElement } from \"../../internals/useRenderElement.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { COMPOSITE_KEYS } from \"../../internals/composite/composite.mjs\";\nimport { useToolbarRootContext } from \"../../toolbar/root/ToolbarRootContext.mjs\";\nimport { getDisabledMountTransitionStyles } from \"../../internals/getDisabledMountTransitionStyles.mjs\";\nimport { ClosePartContext, useClosePartCount } from \"../../utils/closePart.mjs\";\nimport { FOCUSABLE_POPUP_PROPS, createDefaultInitialFocus } from \"../../utils/popups/index.mjs\";\n\n/**\n * A container for the popover contents.\n * Renders a `<div>` element.\n *\n * Documentation: [Base UI Popover](https://base-ui.com/react/components/popover)\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const PopoverPopup = /*#__PURE__*/React.forwardRef(function PopoverPopup(componentProps, forwardedRef) {\n const {\n render,\n className,\n style,\n initialFocus,\n finalFocus,\n ...elementProps\n } = componentProps;\n const store = usePopoverRootContext();\n const positioner = usePopoverPositionerContext();\n const insideToolbar = useToolbarRootContext(true) != null;\n const {\n context: closePartContext,\n hasClosePart\n } = useClosePartCount();\n const open = store.useState('open');\n const openMethod = store.useState('openMethod');\n const instantType = store.useState('instantType');\n const transitionStatus = store.useState('transitionStatus');\n const popupProps = store.useState('popupProps');\n const titleId = store.useState('titleElementId');\n const descriptionId = store.useState('descriptionElementId');\n const modal = store.useState('modal');\n const mounted = store.useState('mounted');\n const openReason = store.useState('openChangeReason');\n const activeTriggerElement = store.useState('activeTriggerElement');\n const floatingContext = store.useState('floatingRootContext');\n const floatingId = floatingContext.useState('floatingId');\n const disabled = store.useState('disabled');\n const openOnHover = store.useState('openOnHover');\n const closeDelay = store.useState('closeDelay');\n useOpenChangeComplete({\n open,\n ref: store.context.popupRef,\n onComplete() {\n if (open) {\n store.context.onOpenChangeComplete?.(true);\n }\n }\n });\n useHoverFloatingInteraction(floatingContext, {\n enabled: openOnHover && !disabled,\n closeDelay\n });\n const resolvedInitialFocus = initialFocus === undefined ? createDefaultInitialFocus(store.context.popupRef) : initialFocus;\n const focusManagerModal = modal !== false && hasClosePart;\n store.useSyncedValue('focusManagerModal', focusManagerModal);\n const setPopupElement = store.useStateSetter('popupElement');\n const state = {\n open,\n side: positioner.side,\n align: positioner.align,\n instant: instantType,\n transitionStatus\n };\n const element = useRenderElement('div', componentProps, {\n state,\n ref: [forwardedRef, store.context.popupRef, setPopupElement],\n props: [popupProps, {\n id: floatingId,\n role: 'dialog',\n ...FOCUSABLE_POPUP_PROPS,\n 'aria-labelledby': titleId,\n 'aria-describedby': descriptionId,\n onKeyDown(event) {\n if (insideToolbar && COMPOSITE_KEYS.has(event.key)) {\n event.stopPropagation();\n }\n }\n }, getDisabledMountTransitionStyles(transitionStatus), elementProps],\n stateAttributesMapping: popupTransitionStateMapping\n });\n return /*#__PURE__*/_jsx(FloatingFocusManager, {\n context: floatingContext,\n openInteractionType: openMethod,\n modal: focusManagerModal,\n disabled: !mounted || openReason === REASONS.triggerHover,\n initialFocus: resolvedInitialFocus,\n returnFocus: finalFocus,\n restoreFocus: \"popup\",\n getInsideElements: () => [store.context.beforeTriggerFocusGuardRef.current],\n previousFocusableElement: isHTMLElement(activeTriggerElement) ? activeTriggerElement : undefined,\n nextFocusableElement: store.context.triggerFocusTargetRef,\n beforeContentFocusGuardRef: store.context.beforeContentFocusGuardRef,\n children: /*#__PURE__*/_jsx(ClosePartContext.Provider, {\n value: closePartContext,\n children: element\n })\n });\n});\nif (process.env.NODE_ENV !== \"production\") PopoverPopup.displayName = \"PopoverPopup\";"],"names":["_formatErrorMessage","REASONS.triggerPress","REASONS.triggerHover","REASONS.escapeKey","REASONS.closePress","REASONS.focusOut","PopoverRootComponent","REASONS.imperativeAction","_jsxs","_jsx","PopoverTrigger","PopoverPortal","PopoverPositioner","PopoverPopup"],"mappings":";;;;;;;;;;;;;;;;;;AAIO,MAAM,qBAAkC,sBAAM,cAAc,MAAS;AAC5E,IAAI,QAAQ,IAAI,aAAa,aAAc,oBAAmB,cAAc;AACrE,SAAS,sBAAsB,UAAU;AAC9C,QAAM,UAAU,MAAM,WAAW,kBAAkB;AACnD,MAAI,YAAY,UAAa,CAAC,UAAU;AACtC,UAAM,IAAI,MAAM,QAAQ,IAAI,aAAa,eAAe,gGAAgGA,mBAAoB,EAAE,CAAC;AAAA,EACjL;AACA,SAAO;AACT;ACDA,MAAM,YAAY;AAAA,EAChB,GAAG;AAAA,EACH,UAAU,WAAS,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAMzB,aAAa,WAAS,MAAM,gBAAgB,oBAAoB,CAAC,oBAAoB,KAAK,KAAK,IAAI,SAAY,MAAM;AAAA,EACrH,YAAY,WAAS,MAAM;AAAA,EAC3B,kBAAkB,WAAS,MAAM;AAAA,EACjC,wBAAwB,CAAC,OAAO,cAAc,MAAM,qBAAqBC,gBAAwB,oBAAoB,kBAAkB,OAAO,SAAS;AAAA;AAAA;AAAA,EAGvJ,kBAAkB,CAAC,OAAO,gBAAgB,eAAe,MAAM,eAAe,WAAW,MAAM,qBAAqBA;AAAAA,EACpH,uBAAuB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,IAChB,CAAK;AAAA,EACL,CAAG;AACH,CAAC;AACD,IAAI,QAAQ,IAAI,aAAa,aAAc,cAAa,cAAc;","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10]}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { u as useCSPContext } from "./CSPContext-Cldo9QDp.js";
|
|
2
|
+
import { jsx } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { s as shimExports } from "./element-B1vbc-LG.js";
|
|
5
|
+
import { i as isReactVersionAtLeast } from "./useIsoLayoutEffect-D2lpsB9D.js";
|
|
6
|
+
const script = "";
|
|
7
|
+
const emptySubscribe = () => () => {
|
|
8
|
+
};
|
|
9
|
+
const getTrue = () => true;
|
|
10
|
+
const getFalse = () => false;
|
|
11
|
+
function useIsHydratedModern() {
|
|
12
|
+
return shimExports.useSyncExternalStore(emptySubscribe, getTrue, getFalse);
|
|
13
|
+
}
|
|
14
|
+
function useIsHydratedLegacy() {
|
|
15
|
+
const [hydrated, setHydrated] = React.useState(false);
|
|
16
|
+
React.useEffect(() => {
|
|
17
|
+
setHydrated(true);
|
|
18
|
+
}, []);
|
|
19
|
+
return hydrated;
|
|
20
|
+
}
|
|
21
|
+
const useIsHydrated = isReactVersionAtLeast(18) ? useIsHydratedModern : useIsHydratedLegacy;
|
|
22
|
+
function useIsHydrating() {
|
|
23
|
+
return !useIsHydrated();
|
|
24
|
+
}
|
|
25
|
+
function PrehydrationScript(props) {
|
|
26
|
+
const {
|
|
27
|
+
script: script2
|
|
28
|
+
} = props;
|
|
29
|
+
const {
|
|
30
|
+
nonce
|
|
31
|
+
} = useCSPContext();
|
|
32
|
+
const isHydrating = useIsHydrating();
|
|
33
|
+
if (!isHydrating) {
|
|
34
|
+
return null;
|
|
35
|
+
}
|
|
36
|
+
return /* @__PURE__ */ jsx("script", {
|
|
37
|
+
nonce,
|
|
38
|
+
dangerouslySetInnerHTML: {
|
|
39
|
+
__html: script2
|
|
40
|
+
},
|
|
41
|
+
suppressHydrationWarning: true
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
export {
|
|
45
|
+
PrehydrationScript as P,
|
|
46
|
+
script as s,
|
|
47
|
+
useIsHydrating as u
|
|
48
|
+
};
|
|
49
|
+
//# sourceMappingURL=PrehydrationScript-B3u_PP2W.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PrehydrationScript-B3u_PP2W.js","sources":["../node_modules/@base-ui/react/internals/prehydrationScript.stub.mjs","../node_modules/@base-ui/utils/hydration.mjs","../node_modules/@base-ui/react/internals/PrehydrationScript.mjs"],"sourcesContent":["// Shared browser-bundle replacement for the per-component `prehydrationScript.min.ts` files,\n// selected via the `browser` condition of every `#prehydration/*` entry in package.json\n// `imports`. The real scripts only ever execute from server-rendered HTML, so client bundles\n// don't need their contents. See `internals/PrehydrationScript.tsx` for why an empty script is\n// still rendered during hydration.\nexport const script = '';","'use client';\n\nimport * as React from 'react';\n/* We need to import the shim because React 17 does not support the `useSyncExternalStore` API. */\nimport { useSyncExternalStore } from 'use-sync-external-store/shim';\nimport { isReactVersionAtLeast } from \"./reactVersion.mjs\";\nconst emptySubscribe = () => () => {};\nconst getTrue = () => true;\nconst getFalse = () => false;\nfunction useIsHydratedModern() {\n // The server snapshot is what React renders with while hydrating, so this\n // distinguishes a hydration pass from a client-only mount, which reads the\n // client snapshot straight away.\n return useSyncExternalStore(emptySubscribe, getTrue, getFalse);\n}\n\n/**\n * React 17 path. The shim only forwards to React's own implementation when\n * there is one; its fallback takes `(subscribe, getSnapshot)` and drops\n * `getServerSnapshot`, so a shim-based hook would report `true` on the server —\n * the opposite of what this exists for.\n *\n * `useState` cannot tell hydration from a client-only mount, so both report\n * \"not hydrated\" for one render before settling.\n */\nfunction useIsHydratedLegacy() {\n const [hydrated, setHydrated] = React.useState(false);\n React.useEffect(() => {\n setHydrated(true);\n }, []);\n return hydrated;\n}\n\n/** Returns `true` once React has taken over on the client. */\nexport const useIsHydrated = isReactVersionAtLeast(18) ? useIsHydratedModern : useIsHydratedLegacy;\n\n/**\n * Returns `true` while React is hydrating server-rendered markup and `false`\n * for fresh client-only mounts — the exact inverse of {@link useIsHydrated}.\n */\nexport function useIsHydrating() {\n return !useIsHydrated();\n}","'use client';\n\nimport * as React from 'react';\nimport { useIsHydrating } from \"../utils/useIsHydrating.mjs\";\nimport { useCSPContext } from \"./csp-context/CSPContext.mjs\";\n\n/**\n * Renders an inline script that runs before React hydrates, used by components that need\n * to position server-rendered content ahead of hydration (e.g. `Tabs.Indicator`,\n * `Slider.Thumb`).\n *\n * The `script` source is imported by the caller through the package's `#prehydration/*`\n * subpath import, whose `browser` condition resolves to a stub module exporting an empty\n * string — so the script body is excluded from client bundles. It only ever executes from\n * server-rendered HTML.\n *\n * Render this only when the script should be emitted (i.e. gate `renderBeforeHydration`\n * and any structural conditions at the call site). The element is still rendered (with\n * empty content) on the client during the hydration pass so the React tree matches the\n * server markup; `suppressHydrationWarning` bridges the content difference and React keeps\n * the already-executed server script. Once `isHydrating` flips to `false` the element\n * unmounts.\n *\n * The component must stay in client bundles: returning `null` on the client (e.g. by\n * stubbing the whole component) would drop an element the server emitted and trigger a\n * recoverable hydration error (React #418) in consumers' apps. Only the script body is\n * excluded from client bundles, via the `#prehydration/*` `browser` condition.\n *\n * When adding a new consumer, register a matching `#prehydration/*` entry (with `browser`\n * and `default` conditions) in `packages/react/package.json` `imports`; the `browser`\n * condition reuses the shared `internals/prehydrationScript.stub.ts`.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport function PrehydrationScript(props) {\n const {\n script\n } = props;\n const {\n nonce\n } = useCSPContext();\n const isHydrating = useIsHydrating();\n if (!isHydrating) {\n return null;\n }\n return /*#__PURE__*/_jsx(\"script\", {\n nonce: nonce\n // eslint-disable-next-line react/no-danger\n ,\n dangerouslySetInnerHTML: {\n __html: script\n },\n suppressHydrationWarning: true\n });\n}"],"names":["useSyncExternalStore","script","_jsx"],"mappings":";;;;;AAKY,MAAC,SAAS;ACCtB,MAAM,iBAAiB,MAAM,MAAM;AAAC;AACpC,MAAM,UAAU,MAAM;AACtB,MAAM,WAAW,MAAM;AACvB,SAAS,sBAAsB;AAI7B,SAAOA,iCAAqB,gBAAgB,SAAS,QAAQ;AAC/D;AAWA,SAAS,sBAAsB;AAC7B,QAAM,CAAC,UAAU,WAAW,IAAI,MAAM,SAAS,KAAK;AACpD,QAAM,UAAU,MAAM;AACpB,gBAAY,IAAI;AAAA,EAClB,GAAG,CAAA,CAAE;AACL,SAAO;AACT;AAGO,MAAM,gBAAgB,sBAAsB,EAAE,IAAI,sBAAsB;AAMxE,SAAS,iBAAiB;AAC/B,SAAO,CAAC,cAAa;AACvB;ACTO,SAAS,mBAAmB,OAAO;AACxC,QAAM;AAAA,IACJ,QAAAC;AAAA,EACJ,IAAM;AACJ,QAAM;AAAA,IACJ;AAAA,EACJ,IAAM,cAAa;AACjB,QAAM,cAAc,eAAc;AAClC,MAAI,CAAC,aAAa;AAChB,WAAO;AAAA,EACT;AACA,SAAoBC,oBAAK,UAAU;AAAA,IACjC;AAAA,IAGA,yBAAyB;AAAA,MACvB,QAAQD;AAAA,IACd;AAAA,IACI,0BAA0B;AAAA,EAC9B,CAAG;AACH;","x_google_ignoreList":[0,1,2]}
|