@jobber/components 7.10.0 → 7.11.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/dist/Autocomplete/index.cjs +1 -0
- package/dist/Autocomplete/index.mjs +1 -0
- package/dist/Card/index.cjs +3 -0
- package/dist/Card/index.mjs +3 -0
- package/dist/Chip/index.cjs +1 -0
- package/dist/Chip/index.mjs +1 -0
- package/dist/Chips/InternalChipDismissible/hooks/index.cjs +1 -0
- package/dist/Chips/InternalChipDismissible/hooks/index.mjs +1 -0
- package/dist/Chips/InternalChipDismissible/index.cjs +1 -0
- package/dist/Chips/InternalChipDismissible/index.mjs +1 -0
- package/dist/Chips/index.cjs +1 -0
- package/dist/Chips/index.mjs +1 -0
- package/dist/Combobox/components/ComboboxActivator/index.cjs +1 -0
- package/dist/Combobox/components/ComboboxActivator/index.mjs +1 -0
- package/dist/Combobox/components/ComboboxContent/index.cjs +1 -0
- package/dist/Combobox/components/ComboboxContent/index.mjs +1 -0
- package/dist/Combobox/components/ComboboxTrigger/index.cjs +1 -0
- package/dist/Combobox/components/ComboboxTrigger/index.mjs +1 -0
- package/dist/Combobox/index.cjs +1 -0
- package/dist/Combobox/index.mjs +1 -0
- package/dist/ConfirmationModal/index.cjs +1 -0
- package/dist/ConfirmationModal/index.mjs +1 -0
- package/dist/DataDump/index.cjs +3 -0
- package/dist/DataDump/index.mjs +3 -0
- package/dist/DataList/components/DataListActions/index.cjs +1 -0
- package/dist/DataList/components/DataListActions/index.mjs +1 -0
- package/dist/DataList/components/DataListBulkActions/index.cjs +1 -0
- package/dist/DataList/components/DataListBulkActions/index.mjs +1 -0
- package/dist/DataList/components/DataListFilters/components/DataListSort/index.cjs +1 -0
- package/dist/DataList/components/DataListFilters/components/DataListSort/index.mjs +1 -0
- package/dist/DataList/components/DataListFilters/index.cjs +1 -0
- package/dist/DataList/components/DataListFilters/index.mjs +1 -0
- package/dist/DataList/components/DataListHeader/index.cjs +1 -0
- package/dist/DataList/components/DataListHeader/index.mjs +1 -0
- package/dist/DataList/components/DataListItem/index.cjs +1 -0
- package/dist/DataList/components/DataListItem/index.mjs +1 -0
- package/dist/DataList/components/DataListItemActions/index.cjs +1 -0
- package/dist/DataList/components/DataListItemActions/index.mjs +1 -0
- package/dist/DataList/components/DataListItemActionsOverflow/index.cjs +1 -0
- package/dist/DataList/components/DataListItemActionsOverflow/index.mjs +1 -0
- package/dist/DataList/components/DataListItems/index.cjs +1 -0
- package/dist/DataList/components/DataListItems/index.mjs +1 -0
- package/dist/DataList/components/DataListLayout/index.cjs +1 -0
- package/dist/DataList/components/DataListLayout/index.mjs +1 -0
- package/dist/DataList/components/DataListLayoutActions/index.cjs +1 -0
- package/dist/DataList/components/DataListLayoutActions/index.mjs +1 -0
- package/dist/DataList/index.cjs +1 -0
- package/dist/DataList/index.mjs +1 -0
- package/dist/DatePicker/index.cjs +1 -0
- package/dist/DatePicker/index.mjs +1 -0
- package/dist/DrawerRoot-cjs.js +181 -968
- package/dist/DrawerRoot-es.js +5 -734
- package/dist/FormatFile/index.cjs +1 -0
- package/dist/FormatFile/index.mjs +1 -0
- package/dist/Gallery/index.cjs +1 -0
- package/dist/Gallery/index.mjs +1 -0
- package/dist/InputDate/index.cjs +1 -0
- package/dist/InputDate/index.mjs +1 -0
- package/dist/InputNumberExperimental-cjs.js +783 -0
- package/dist/InputNumberExperimental-es.js +763 -0
- package/dist/LightBox/index.cjs +1 -0
- package/dist/LightBox/index.mjs +1 -0
- package/dist/Menu/index.cjs +3 -0
- package/dist/Menu/index.mjs +3 -0
- package/dist/MenuSubmenuTrigger-cjs.js +202 -447
- package/dist/MenuSubmenuTrigger-es.js +7 -249
- package/dist/Modal/index.cjs +1 -0
- package/dist/Modal/index.mjs +1 -0
- package/dist/NumberFieldInput-cjs.js +1828 -0
- package/dist/NumberFieldInput-es.js +1788 -0
- package/dist/Page/index.cjs +3 -0
- package/dist/Page/index.mjs +3 -0
- package/dist/Popover/index.cjs +1 -0
- package/dist/Popover/index.mjs +1 -0
- package/dist/Tooltip/index.cjs +1 -0
- package/dist/Tooltip/index.mjs +1 -0
- package/dist/docs/Menu/Menu.md +197 -37
- package/dist/floating-ui.react-cjs.js +35 -34
- package/dist/floating-ui.react-dom-cjs.js +65 -64
- package/dist/floating-ui.react-dom-es.js +2 -1
- package/dist/floating-ui.react-es.js +2 -1
- package/dist/floating-ui.utils.dom-cjs.js +185 -0
- package/dist/floating-ui.utils.dom-es.js +165 -0
- package/dist/index.cjs +3 -0
- package/dist/index.esm-cjs.js +0 -183
- package/dist/index.esm-es.js +1 -165
- package/dist/index.mjs +3 -0
- package/dist/primitives/BottomSheet/index.cjs +3 -1
- package/dist/primitives/BottomSheet/index.mjs +3 -1
- package/dist/primitives/InputNumberExperimental/InputNumberExperimental.d.ts +20 -0
- package/dist/primitives/InputNumberExperimental/index.cjs +22 -0
- package/dist/primitives/InputNumberExperimental/index.d.ts +2 -0
- package/dist/primitives/InputNumberExperimental/index.mjs +16 -0
- package/dist/primitives/InputNumberExperimental/types.d.ts +147 -0
- package/dist/primitives/index.cjs +9 -1
- package/dist/primitives/index.d.ts +2 -0
- package/dist/primitives/index.mjs +8 -1
- package/dist/styles.css +499 -0
- package/dist/unstyledPrimitives/index.cjs +264 -2039
- package/dist/unstyledPrimitives/index.mjs +72 -1847
- package/dist/useBaseUiId-cjs.js +275 -0
- package/dist/useBaseUiId-es.js +251 -0
- package/dist/useValueChanged-cjs.js +820 -0
- package/dist/useValueChanged-es.js +736 -0
- package/package.json +2 -2
- package/rollup.config.mjs +13 -2
|
@@ -1,247 +1,14 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { u as useDialogRootContext, i as isTypeableElement, e as useFloatingParentNodeId, F as FloatingRootStore, P as PopupTriggerMap, f as useFloatingTree, g as getTarget, m as matchesFocusVisible, h as isTargetInsideEnabledTrigger, j as createAttribute, k as activeElement, l as contains, T as TYPEABLE_SELECTOR, n as getNodeChildren, o as getFloatingFocusElement, p as isTypeableCombobox, q as isIndexOutOfListBounds, r as getMinListIndex, s as getMaxListIndex, t as createGridCellMap, v as isListIndexDisabled, w as getGridNavigatedIndex, x as getGridCellIndices, y as getGridCellIndexOfCorner, A as ARROW_DOWN, z as ARROW_LEFT, B as ARROW_RIGHT, C as findNonDisabledListIndex, E as enqueueFocus, G as ARROW_UP, H as isElementVisible, I as useTriggerDataForwarding, J as useInteractions, K as CLICK_TRIGGER_IDENTIFIER, L as triggerOpenStateMapping, M as DISABLED_TRANSITIONS_STYLE, N as popupStateMapping, O as COMPOSITE_KEYS, Q as FloatingFocusManager, R as FloatingPortal, S as POPUP_COLLISION_AVOIDANCE, U as InternalBackdrop, V as inertValue, W as FloatingNode, X as DROPDOWN_COLLISION_AVOIDANCE, Y as popupStoreSelectors, Z as createSelector, _ as ReactStore, $ as createInitialPopupStoreState, a0 as FloatingTreeStore, a1 as fastComponent, a2 as useOnFirstRender, a3 as useFloatingNodeId, a4 as useOpenInteractionType, a5 as useImplicitActiveTrigger, a6 as useOpenStateTransitions, a7 as useScrollLock, a8 as useSyncedFloatingRootContext, a9 as useDismiss, aa as useRole, ab as TYPEAHEAD_RESET_MS, ac as FloatingTree, ad as fastComponentRef, ae as getTabbableBeforeElement, af as isOutsideEvent, ag as getTabbableAfterElement, ah as getNextTabbable, ai as pressableTriggerOpenStateMapping, aj as FocusGuard, ak as PATIENT_CLICK_THRESHOLD, al as useTriggerRegistration } from './DrawerRoot-es.js';
|
|
3
|
+
import { u as useRenderElement, E as EMPTY_OBJECT, b as useRefWithInit, f as formatErrorMessage, m as mergeProps, c as useMergedRefs, d as EMPTY_ARRAY } from './useRenderElement-es.js';
|
|
4
|
+
import { k as createChangeEventDetails, B as closePress, C as isMouseLikePointerType, D as useAnimationFrame, c as useTimeout, E as isClickLikeEvent, F as triggerPress, b as useId, u as useIsoLayoutEffect, G as triggerFocus, H as isMac, I as isSafari, s as ownerDocument, J as escapeKey, f as useOnMount, T as Timeout, a as useStableCallback, K as triggerHover, i as useValueAsRef, z as stopEvent, L as listNavigation, M as focusOut, N as isVirtualClick, O as isVirtualPointerEvent, P as itemPress, t as transitionStatusMapping, e as useOpenChangeComplete, Q as outsidePress, R as useAnimationsFinished, U as siblingOpen, h as useControlled, d as useTransitionStatus, V as imperativeAction, W as cancelOpen } from './useValueChanged-es.js';
|
|
5
|
+
import { a as useButton, u as useBaseUiId, b as useCompositeRootContext } from './useBaseUiId-es.js';
|
|
4
6
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
5
|
-
import {
|
|
7
|
+
import { b as isElement, k as getWindow, a as isHTMLElement, d as isLastTraversableNode, e as getParentNode } from './floating-ui.utils.dom-es.js';
|
|
8
|
+
import { e as evaluate, o as getPaddingObject, n as getAlignmentAxis, k as getAlignment, q as getAxisLength, p as clamp, g as getSide, b as getSideAxis } from './index.esm-es.js';
|
|
6
9
|
import { u as useFloating$1, h as hide$1, f as flip, d as size, b as autoUpdate, o as offset, s as shift, l as limitShift } from './floating-ui.react-dom-es.js';
|
|
7
10
|
import * as ReactDOM from 'react-dom';
|
|
8
11
|
|
|
9
|
-
let set;
|
|
10
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
11
|
-
set = new Set();
|
|
12
|
-
}
|
|
13
|
-
function error(...messages) {
|
|
14
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
15
|
-
const messageKey = messages.join(' ');
|
|
16
|
-
if (!set.has(messageKey)) {
|
|
17
|
-
set.add(messageKey);
|
|
18
|
-
console.error(`Base UI: ${messageKey}`);
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
const CompositeRootContext = /*#__PURE__*/React.createContext(undefined);
|
|
24
|
-
if (process.env.NODE_ENV !== "production") CompositeRootContext.displayName = "CompositeRootContext";
|
|
25
|
-
function useCompositeRootContext(optional = false) {
|
|
26
|
-
const context = React.useContext(CompositeRootContext);
|
|
27
|
-
if (context === undefined && !optional) {
|
|
28
|
-
throw new Error(process.env.NODE_ENV !== "production" ? 'Base UI: CompositeRootContext is missing. Composite parts must be placed within <Composite.Root>.' : formatErrorMessage(16));
|
|
29
|
-
}
|
|
30
|
-
return context;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
function useFocusableWhenDisabled(parameters) {
|
|
34
|
-
const {
|
|
35
|
-
focusableWhenDisabled,
|
|
36
|
-
disabled,
|
|
37
|
-
composite = false,
|
|
38
|
-
tabIndex: tabIndexProp = 0,
|
|
39
|
-
isNativeButton
|
|
40
|
-
} = parameters;
|
|
41
|
-
const isFocusableComposite = composite && focusableWhenDisabled !== false;
|
|
42
|
-
const isNonFocusableComposite = composite && focusableWhenDisabled === false;
|
|
43
|
-
|
|
44
|
-
// we can't explicitly assign `undefined` to any of these props because it
|
|
45
|
-
// would otherwise prevent subsequently merged props from setting them
|
|
46
|
-
const props = React.useMemo(() => {
|
|
47
|
-
const additionalProps = {
|
|
48
|
-
// allow Tabbing away from focusableWhenDisabled elements
|
|
49
|
-
onKeyDown(event) {
|
|
50
|
-
if (disabled && focusableWhenDisabled && event.key !== 'Tab') {
|
|
51
|
-
event.preventDefault();
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
};
|
|
55
|
-
if (!composite) {
|
|
56
|
-
additionalProps.tabIndex = tabIndexProp;
|
|
57
|
-
if (!isNativeButton && disabled) {
|
|
58
|
-
additionalProps.tabIndex = focusableWhenDisabled ? tabIndexProp : -1;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
if (isNativeButton && (focusableWhenDisabled || isFocusableComposite) || !isNativeButton && disabled) {
|
|
62
|
-
additionalProps['aria-disabled'] = disabled;
|
|
63
|
-
}
|
|
64
|
-
if (isNativeButton && (!focusableWhenDisabled || isNonFocusableComposite)) {
|
|
65
|
-
additionalProps.disabled = disabled;
|
|
66
|
-
}
|
|
67
|
-
return additionalProps;
|
|
68
|
-
}, [composite, disabled, focusableWhenDisabled, isFocusableComposite, isNonFocusableComposite, isNativeButton, tabIndexProp]);
|
|
69
|
-
return {
|
|
70
|
-
props
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
function useButton(parameters = {}) {
|
|
75
|
-
const {
|
|
76
|
-
disabled = false,
|
|
77
|
-
focusableWhenDisabled,
|
|
78
|
-
tabIndex = 0,
|
|
79
|
-
native: isNativeButton = true,
|
|
80
|
-
composite: compositeProp
|
|
81
|
-
} = parameters;
|
|
82
|
-
const elementRef = React.useRef(null);
|
|
83
|
-
const compositeRootContext = useCompositeRootContext(true);
|
|
84
|
-
const isCompositeItem = compositeProp ?? compositeRootContext !== undefined;
|
|
85
|
-
const {
|
|
86
|
-
props: focusableWhenDisabledProps
|
|
87
|
-
} = useFocusableWhenDisabled({
|
|
88
|
-
focusableWhenDisabled,
|
|
89
|
-
disabled,
|
|
90
|
-
composite: isCompositeItem,
|
|
91
|
-
tabIndex,
|
|
92
|
-
isNativeButton
|
|
93
|
-
});
|
|
94
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
95
|
-
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
96
|
-
React.useEffect(() => {
|
|
97
|
-
if (!elementRef.current) {
|
|
98
|
-
return;
|
|
99
|
-
}
|
|
100
|
-
const isButtonTag = isButtonElement(elementRef.current);
|
|
101
|
-
if (isNativeButton) {
|
|
102
|
-
if (!isButtonTag) {
|
|
103
|
-
const ownerStackMessage = SafeReact.captureOwnerStack?.() || '';
|
|
104
|
-
const message = 'A component that acts as a button expected a native <button> because the ' + '`nativeButton` prop is true. Rendering a non-<button> removes native button ' + 'semantics, which can impact forms and accessibility. Use a real <button> in the ' + '`render` prop, or set `nativeButton` to `false`.';
|
|
105
|
-
error(`${message}${ownerStackMessage}`);
|
|
106
|
-
}
|
|
107
|
-
} else if (isButtonTag) {
|
|
108
|
-
const ownerStackMessage = SafeReact.captureOwnerStack?.() || '';
|
|
109
|
-
const message = 'A component that acts as a button expected a non-<button> because the `nativeButton` ' + 'prop is false. Rendering a <button> keeps native behavior while Base UI applies ' + 'non-native attributes and handlers, which can add unintended extra attributes (such ' + 'as `role` or `aria-disabled`). Use a non-<button> in the `render` prop, or set ' + '`nativeButton` to `true`.';
|
|
110
|
-
error(`${message}${ownerStackMessage}`);
|
|
111
|
-
}
|
|
112
|
-
}, [isNativeButton]);
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
// handles a disabled composite button rendering another button, e.g.
|
|
116
|
-
// <Toolbar.Button disabled render={<Menu.Trigger />} />
|
|
117
|
-
// the `disabled` prop needs to pass through 2 `useButton`s then finally
|
|
118
|
-
// delete the `disabled` attribute from DOM
|
|
119
|
-
const updateDisabled = React.useCallback(() => {
|
|
120
|
-
const element = elementRef.current;
|
|
121
|
-
if (!isButtonElement(element)) {
|
|
122
|
-
return;
|
|
123
|
-
}
|
|
124
|
-
if (isCompositeItem && disabled && focusableWhenDisabledProps.disabled === undefined && element.disabled) {
|
|
125
|
-
element.disabled = false;
|
|
126
|
-
}
|
|
127
|
-
}, [disabled, focusableWhenDisabledProps.disabled, isCompositeItem]);
|
|
128
|
-
useIsoLayoutEffect(updateDisabled, [updateDisabled]);
|
|
129
|
-
const getButtonProps = React.useCallback((externalProps = {}) => {
|
|
130
|
-
const {
|
|
131
|
-
onClick: externalOnClick,
|
|
132
|
-
onMouseDown: externalOnMouseDown,
|
|
133
|
-
onKeyUp: externalOnKeyUp,
|
|
134
|
-
onKeyDown: externalOnKeyDown,
|
|
135
|
-
onPointerDown: externalOnPointerDown,
|
|
136
|
-
...otherExternalProps
|
|
137
|
-
} = externalProps;
|
|
138
|
-
const type = isNativeButton ? 'button' : undefined;
|
|
139
|
-
return mergeProps({
|
|
140
|
-
type,
|
|
141
|
-
onClick(event) {
|
|
142
|
-
if (disabled) {
|
|
143
|
-
event.preventDefault();
|
|
144
|
-
return;
|
|
145
|
-
}
|
|
146
|
-
externalOnClick?.(event);
|
|
147
|
-
},
|
|
148
|
-
onMouseDown(event) {
|
|
149
|
-
if (!disabled) {
|
|
150
|
-
externalOnMouseDown?.(event);
|
|
151
|
-
}
|
|
152
|
-
},
|
|
153
|
-
onKeyDown(event) {
|
|
154
|
-
if (disabled) {
|
|
155
|
-
return;
|
|
156
|
-
}
|
|
157
|
-
makeEventPreventable(event);
|
|
158
|
-
externalOnKeyDown?.(event);
|
|
159
|
-
if (event.baseUIHandlerPrevented) {
|
|
160
|
-
return;
|
|
161
|
-
}
|
|
162
|
-
const isCurrentTarget = event.target === event.currentTarget;
|
|
163
|
-
const currentTarget = event.currentTarget;
|
|
164
|
-
const isButton = isButtonElement(currentTarget);
|
|
165
|
-
const isLink = !isNativeButton && isValidLinkElement(currentTarget);
|
|
166
|
-
const shouldClick = isCurrentTarget && (isNativeButton ? isButton : !isLink);
|
|
167
|
-
const isEnterKey = event.key === 'Enter';
|
|
168
|
-
const isSpaceKey = event.key === ' ';
|
|
169
|
-
const role = currentTarget.getAttribute('role');
|
|
170
|
-
const isTextNavigationRole = role?.startsWith('menuitem') || role === 'option' || role === 'gridcell';
|
|
171
|
-
if (isCurrentTarget && isCompositeItem && isSpaceKey) {
|
|
172
|
-
if (event.defaultPrevented && isTextNavigationRole) {
|
|
173
|
-
return;
|
|
174
|
-
}
|
|
175
|
-
event.preventDefault();
|
|
176
|
-
if (isLink || isNativeButton && isButton) {
|
|
177
|
-
currentTarget.click();
|
|
178
|
-
event.preventBaseUIHandler();
|
|
179
|
-
} else if (shouldClick) {
|
|
180
|
-
externalOnClick?.(event);
|
|
181
|
-
event.preventBaseUIHandler();
|
|
182
|
-
}
|
|
183
|
-
return;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
// Keyboard accessibility for native and non-native elements.
|
|
187
|
-
if (shouldClick) {
|
|
188
|
-
if (!isNativeButton && (isSpaceKey || isEnterKey)) {
|
|
189
|
-
event.preventDefault();
|
|
190
|
-
}
|
|
191
|
-
if (!isNativeButton && isEnterKey) {
|
|
192
|
-
externalOnClick?.(event);
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
},
|
|
196
|
-
onKeyUp(event) {
|
|
197
|
-
if (disabled) {
|
|
198
|
-
return;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
// calling preventDefault in keyUp on a <button> will not dispatch a click event if Space is pressed
|
|
202
|
-
// https://codesandbox.io/p/sandbox/button-keyup-preventdefault-dn7f0
|
|
203
|
-
makeEventPreventable(event);
|
|
204
|
-
externalOnKeyUp?.(event);
|
|
205
|
-
if (event.target === event.currentTarget && isNativeButton && isCompositeItem && isButtonElement(event.currentTarget) && event.key === ' ') {
|
|
206
|
-
event.preventDefault();
|
|
207
|
-
return;
|
|
208
|
-
}
|
|
209
|
-
if (event.baseUIHandlerPrevented) {
|
|
210
|
-
return;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
// Keyboard accessibility for non interactive elements
|
|
214
|
-
if (event.target === event.currentTarget && !isNativeButton && !isCompositeItem && event.key === ' ') {
|
|
215
|
-
externalOnClick?.(event);
|
|
216
|
-
}
|
|
217
|
-
},
|
|
218
|
-
onPointerDown(event) {
|
|
219
|
-
if (disabled) {
|
|
220
|
-
event.preventDefault();
|
|
221
|
-
return;
|
|
222
|
-
}
|
|
223
|
-
externalOnPointerDown?.(event);
|
|
224
|
-
}
|
|
225
|
-
}, !isNativeButton ? {
|
|
226
|
-
role: 'button'
|
|
227
|
-
} : undefined, focusableWhenDisabledProps, otherExternalProps);
|
|
228
|
-
}, [disabled, focusableWhenDisabledProps, isCompositeItem, isNativeButton]);
|
|
229
|
-
const buttonRef = useStableCallback(element => {
|
|
230
|
-
elementRef.current = element;
|
|
231
|
-
updateDisabled();
|
|
232
|
-
});
|
|
233
|
-
return {
|
|
234
|
-
getButtonProps,
|
|
235
|
-
buttonRef
|
|
236
|
-
};
|
|
237
|
-
}
|
|
238
|
-
function isButtonElement(elem) {
|
|
239
|
-
return isHTMLElement(elem) && elem.tagName === 'BUTTON';
|
|
240
|
-
}
|
|
241
|
-
function isValidLinkElement(elem) {
|
|
242
|
-
return Boolean(elem?.tagName === 'A' && elem?.href);
|
|
243
|
-
}
|
|
244
|
-
|
|
245
12
|
/**
|
|
246
13
|
* A button that closes the dialog.
|
|
247
14
|
* Renders a `<button>` element.
|
|
@@ -293,15 +60,6 @@ if (process.env.NODE_ENV !== "production") DialogClose.displayName = "DialogClos
|
|
|
293
60
|
*/
|
|
294
61
|
const DrawerClose = DialogClose;
|
|
295
62
|
|
|
296
|
-
/**
|
|
297
|
-
* Wraps `useId` and prefixes generated `id`s with `base-ui-`
|
|
298
|
-
* @param {string | undefined} idOverride overrides the generated id when provided
|
|
299
|
-
* @returns {string | undefined}
|
|
300
|
-
*/
|
|
301
|
-
function useBaseUiId(idOverride) {
|
|
302
|
-
return useId(idOverride, 'base-ui');
|
|
303
|
-
}
|
|
304
|
-
|
|
305
63
|
function resolveValue(value, pointerType) {
|
|
306
64
|
if (pointerType != null && !isMouseLikePointerType(pointerType)) {
|
|
307
65
|
return 0;
|
|
@@ -5221,4 +4979,4 @@ const MenuSubmenuTrigger = /*#__PURE__*/React.forwardRef(function SubmenuTrigger
|
|
|
5221
4979
|
});
|
|
5222
4980
|
if (process.env.NODE_ENV !== "production") MenuSubmenuTrigger.displayName = "MenuSubmenuTrigger";
|
|
5223
4981
|
|
|
5224
|
-
export {
|
|
4982
|
+
export { useTypeahead as A, getPseudoElementBounds as B, CompositeList as C, DrawerTrigger as D, useAnchorPositioning as E, getDisabledMountTransitionStyles as F, IndexGuessBehavior as I, MenuTrigger as M, REGULAR_ITEM as R, DrawerTitle as a, DrawerClose as b, MenuLinkItem as c, MenuItem as d, MenuRadioItem as e, MenuRadioItemIndicator as f, MenuSubmenuTrigger as g, MenuRoot as h, MenuPortal as i, MenuPositioner as j, MenuPopup as k, MenuRadioGroup as l, MenuGroup as m, MenuSubmenuRoot as n, MenuGroupLabel as o, useMenuPositionerContext as p, useContextMenuRootContext as q, useCompositeListItem as r, useMenuItem as s, itemMapping as t, useMenuRootContext as u, useDirection as v, MenuStore as w, useFloatingRootContext as x, useClick as y, useListNavigation as z };
|
package/dist/Modal/index.cjs
CHANGED
|
@@ -18,6 +18,7 @@ require('react-router-dom');
|
|
|
18
18
|
require('../Icon-cjs.js');
|
|
19
19
|
require('@jobber/design');
|
|
20
20
|
require('../_commonjsHelpers-cjs.js');
|
|
21
|
+
require('../floating-ui.utils.dom-cjs.js');
|
|
21
22
|
require('../index.esm-cjs.js');
|
|
22
23
|
require('react/jsx-runtime');
|
|
23
24
|
require('../floating-ui.react-dom-cjs.js');
|
package/dist/Modal/index.mjs
CHANGED
|
@@ -16,6 +16,7 @@ import 'react-router-dom';
|
|
|
16
16
|
import '../Icon-es.js';
|
|
17
17
|
import '@jobber/design';
|
|
18
18
|
import '../_commonjsHelpers-es.js';
|
|
19
|
+
import '../floating-ui.utils.dom-es.js';
|
|
19
20
|
import '../index.esm-es.js';
|
|
20
21
|
import 'react/jsx-runtime';
|
|
21
22
|
import '../floating-ui.react-dom-es.js';
|