@process.co/ui 0.0.18 → 0.0.20
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/css/ui.css +22 -0
- package/dist/components/fields/index.cjs +12 -19
- package/dist/components/fields/index.cjs.map +1 -1
- package/dist/components/fields/index.js +12 -19
- package/dist/components/fields/index.js.map +1 -1
- package/dist/components/slots/index.cjs +3286 -0
- package/dist/components/slots/index.cjs.map +1 -0
- package/dist/components/slots/index.d.cts +2 -0
- package/dist/components/slots/index.d.ts +2 -0
- package/dist/components/slots/index.js +3263 -0
- package/dist/components/slots/index.js.map +1 -0
- package/dist/index-DeN5zh8_.d.cts +21 -0
- package/dist/index-DeN5zh8_.d.ts +21 -0
- package/dist/index.cjs +461 -448
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +417 -405
- package/dist/index.js.map +1 -1
- package/package.json +11 -1
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var React45 = require('react');
|
|
4
4
|
var jsxRuntime = require('react/jsx-runtime');
|
|
5
5
|
var ReactDOM4 = require('react-dom');
|
|
6
6
|
|
|
@@ -22,7 +22,7 @@ function _interopNamespace(e) {
|
|
|
22
22
|
return Object.freeze(n);
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
var
|
|
25
|
+
var React45__namespace = /*#__PURE__*/_interopNamespace(React45);
|
|
26
26
|
var ReactDOM4__namespace = /*#__PURE__*/_interopNamespace(ReactDOM4);
|
|
27
27
|
|
|
28
28
|
var __defProp = Object.defineProperty;
|
|
@@ -62,10 +62,10 @@ function composeRefs(...refs) {
|
|
|
62
62
|
};
|
|
63
63
|
}
|
|
64
64
|
function useComposedRefs(...refs) {
|
|
65
|
-
return
|
|
65
|
+
return React45__namespace.useCallback(composeRefs(...refs), refs);
|
|
66
66
|
}
|
|
67
67
|
var REACT_LAZY_TYPE = Symbol.for("react.lazy");
|
|
68
|
-
var use =
|
|
68
|
+
var use = React45__namespace[" use ".trim().toString()];
|
|
69
69
|
function isPromiseLike(value) {
|
|
70
70
|
return typeof value === "object" && value !== null && "then" in value;
|
|
71
71
|
}
|
|
@@ -75,24 +75,24 @@ function isLazyComponent(element) {
|
|
|
75
75
|
// @__NO_SIDE_EFFECTS__
|
|
76
76
|
function createSlot(ownerName) {
|
|
77
77
|
const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
|
|
78
|
-
const Slot22 =
|
|
78
|
+
const Slot22 = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
79
79
|
let { children, ...slotProps } = props;
|
|
80
80
|
if (isLazyComponent(children) && typeof use === "function") {
|
|
81
81
|
children = use(children._payload);
|
|
82
82
|
}
|
|
83
|
-
const childrenArray =
|
|
83
|
+
const childrenArray = React45__namespace.Children.toArray(children);
|
|
84
84
|
const slottable = childrenArray.find(isSlottable);
|
|
85
85
|
if (slottable) {
|
|
86
86
|
const newElement = slottable.props.children;
|
|
87
87
|
const newChildren = childrenArray.map((child) => {
|
|
88
88
|
if (child === slottable) {
|
|
89
|
-
if (
|
|
90
|
-
return
|
|
89
|
+
if (React45__namespace.Children.count(newElement) > 1) return React45__namespace.Children.only(null);
|
|
90
|
+
return React45__namespace.isValidElement(newElement) ? newElement.props.children : null;
|
|
91
91
|
} else {
|
|
92
92
|
return child;
|
|
93
93
|
}
|
|
94
94
|
});
|
|
95
|
-
return /* @__PURE__ */ jsxRuntime.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children:
|
|
95
|
+
return /* @__PURE__ */ jsxRuntime.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React45__namespace.isValidElement(newElement) ? React45__namespace.cloneElement(newElement, void 0, newChildren) : null });
|
|
96
96
|
}
|
|
97
97
|
return /* @__PURE__ */ jsxRuntime.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
|
|
98
98
|
});
|
|
@@ -102,27 +102,27 @@ function createSlot(ownerName) {
|
|
|
102
102
|
var Slot = /* @__PURE__ */ createSlot("Slot");
|
|
103
103
|
// @__NO_SIDE_EFFECTS__
|
|
104
104
|
function createSlotClone(ownerName) {
|
|
105
|
-
const SlotClone =
|
|
105
|
+
const SlotClone = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
106
106
|
let { children, ...slotProps } = props;
|
|
107
107
|
if (isLazyComponent(children) && typeof use === "function") {
|
|
108
108
|
children = use(children._payload);
|
|
109
109
|
}
|
|
110
|
-
if (
|
|
110
|
+
if (React45__namespace.isValidElement(children)) {
|
|
111
111
|
const childrenRef = getElementRef(children);
|
|
112
112
|
const props2 = mergeProps(slotProps, children.props);
|
|
113
|
-
if (children.type !==
|
|
113
|
+
if (children.type !== React45__namespace.Fragment) {
|
|
114
114
|
props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
|
|
115
115
|
}
|
|
116
|
-
return
|
|
116
|
+
return React45__namespace.cloneElement(children, props2);
|
|
117
117
|
}
|
|
118
|
-
return
|
|
118
|
+
return React45__namespace.Children.count(children) > 1 ? React45__namespace.Children.only(null) : null;
|
|
119
119
|
});
|
|
120
120
|
SlotClone.displayName = `${ownerName}.SlotClone`;
|
|
121
121
|
return SlotClone;
|
|
122
122
|
}
|
|
123
123
|
var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
|
|
124
124
|
function isSlottable(child) {
|
|
125
|
-
return
|
|
125
|
+
return React45__namespace.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
|
|
126
126
|
}
|
|
127
127
|
function mergeProps(slotProps, childProps) {
|
|
128
128
|
const overrideProps = { ...childProps };
|
|
@@ -3269,7 +3269,7 @@ function Button({
|
|
|
3269
3269
|
...props
|
|
3270
3270
|
}) {
|
|
3271
3271
|
const Comp = asChild ? Slot : "button";
|
|
3272
|
-
return /* @__PURE__ */
|
|
3272
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
3273
3273
|
Comp,
|
|
3274
3274
|
{
|
|
3275
3275
|
"data-slot": "button",
|
|
@@ -3286,9 +3286,9 @@ function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForD
|
|
|
3286
3286
|
}
|
|
3287
3287
|
};
|
|
3288
3288
|
}
|
|
3289
|
-
var useLayoutEffect2 = globalThis?.document ?
|
|
3289
|
+
var useLayoutEffect2 = globalThis?.document ? React45__namespace.useLayoutEffect : () => {
|
|
3290
3290
|
};
|
|
3291
|
-
var useInsertionEffect =
|
|
3291
|
+
var useInsertionEffect = React45__namespace[" useInsertionEffect ".trim().toString()] || useLayoutEffect2;
|
|
3292
3292
|
function useControllableState({
|
|
3293
3293
|
prop,
|
|
3294
3294
|
defaultProp,
|
|
@@ -3303,8 +3303,8 @@ function useControllableState({
|
|
|
3303
3303
|
const isControlled = prop !== void 0;
|
|
3304
3304
|
const value = isControlled ? prop : uncontrolledProp;
|
|
3305
3305
|
{
|
|
3306
|
-
const isControlledRef =
|
|
3307
|
-
|
|
3306
|
+
const isControlledRef = React45__namespace.useRef(prop !== void 0);
|
|
3307
|
+
React45__namespace.useEffect(() => {
|
|
3308
3308
|
const wasControlled = isControlledRef.current;
|
|
3309
3309
|
if (wasControlled !== isControlled) {
|
|
3310
3310
|
const from = wasControlled ? "controlled" : "uncontrolled";
|
|
@@ -3316,7 +3316,7 @@ function useControllableState({
|
|
|
3316
3316
|
isControlledRef.current = isControlled;
|
|
3317
3317
|
}, [isControlled, caller]);
|
|
3318
3318
|
}
|
|
3319
|
-
const setValue =
|
|
3319
|
+
const setValue = React45__namespace.useCallback(
|
|
3320
3320
|
(nextValue) => {
|
|
3321
3321
|
if (isControlled) {
|
|
3322
3322
|
const value2 = isFunction(nextValue) ? nextValue(prop) : nextValue;
|
|
@@ -3335,13 +3335,13 @@ function useUncontrolledState({
|
|
|
3335
3335
|
defaultProp,
|
|
3336
3336
|
onChange
|
|
3337
3337
|
}) {
|
|
3338
|
-
const [value, setValue] =
|
|
3339
|
-
const prevValueRef =
|
|
3340
|
-
const onChangeRef =
|
|
3338
|
+
const [value, setValue] = React45__namespace.useState(defaultProp);
|
|
3339
|
+
const prevValueRef = React45__namespace.useRef(value);
|
|
3340
|
+
const onChangeRef = React45__namespace.useRef(onChange);
|
|
3341
3341
|
useInsertionEffect(() => {
|
|
3342
3342
|
onChangeRef.current = onChange;
|
|
3343
3343
|
}, [onChange]);
|
|
3344
|
-
|
|
3344
|
+
React45__namespace.useEffect(() => {
|
|
3345
3345
|
if (prevValueRef.current !== value) {
|
|
3346
3346
|
onChangeRef.current?.(value);
|
|
3347
3347
|
prevValueRef.current = value;
|
|
@@ -3355,21 +3355,21 @@ function isFunction(value) {
|
|
|
3355
3355
|
// @__NO_SIDE_EFFECTS__
|
|
3356
3356
|
function createSlot2(ownerName) {
|
|
3357
3357
|
const SlotClone = /* @__PURE__ */ createSlotClone2(ownerName);
|
|
3358
|
-
const Slot22 =
|
|
3358
|
+
const Slot22 = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
3359
3359
|
const { children, ...slotProps } = props;
|
|
3360
|
-
const childrenArray =
|
|
3360
|
+
const childrenArray = React45__namespace.Children.toArray(children);
|
|
3361
3361
|
const slottable = childrenArray.find(isSlottable2);
|
|
3362
3362
|
if (slottable) {
|
|
3363
3363
|
const newElement = slottable.props.children;
|
|
3364
3364
|
const newChildren = childrenArray.map((child) => {
|
|
3365
3365
|
if (child === slottable) {
|
|
3366
|
-
if (
|
|
3367
|
-
return
|
|
3366
|
+
if (React45__namespace.Children.count(newElement) > 1) return React45__namespace.Children.only(null);
|
|
3367
|
+
return React45__namespace.isValidElement(newElement) ? newElement.props.children : null;
|
|
3368
3368
|
} else {
|
|
3369
3369
|
return child;
|
|
3370
3370
|
}
|
|
3371
3371
|
});
|
|
3372
|
-
return /* @__PURE__ */ jsxRuntime.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children:
|
|
3372
|
+
return /* @__PURE__ */ jsxRuntime.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React45__namespace.isValidElement(newElement) ? React45__namespace.cloneElement(newElement, void 0, newChildren) : null });
|
|
3373
3373
|
}
|
|
3374
3374
|
return /* @__PURE__ */ jsxRuntime.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
|
|
3375
3375
|
});
|
|
@@ -3378,24 +3378,24 @@ function createSlot2(ownerName) {
|
|
|
3378
3378
|
}
|
|
3379
3379
|
// @__NO_SIDE_EFFECTS__
|
|
3380
3380
|
function createSlotClone2(ownerName) {
|
|
3381
|
-
const SlotClone =
|
|
3381
|
+
const SlotClone = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
3382
3382
|
const { children, ...slotProps } = props;
|
|
3383
|
-
if (
|
|
3383
|
+
if (React45__namespace.isValidElement(children)) {
|
|
3384
3384
|
const childrenRef = getElementRef2(children);
|
|
3385
3385
|
const props2 = mergeProps2(slotProps, children.props);
|
|
3386
|
-
if (children.type !==
|
|
3386
|
+
if (children.type !== React45__namespace.Fragment) {
|
|
3387
3387
|
props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
|
|
3388
3388
|
}
|
|
3389
|
-
return
|
|
3389
|
+
return React45__namespace.cloneElement(children, props2);
|
|
3390
3390
|
}
|
|
3391
|
-
return
|
|
3391
|
+
return React45__namespace.Children.count(children) > 1 ? React45__namespace.Children.only(null) : null;
|
|
3392
3392
|
});
|
|
3393
3393
|
SlotClone.displayName = `${ownerName}.SlotClone`;
|
|
3394
3394
|
return SlotClone;
|
|
3395
3395
|
}
|
|
3396
3396
|
var SLOTTABLE_IDENTIFIER2 = Symbol("radix.slottable");
|
|
3397
3397
|
function isSlottable2(child) {
|
|
3398
|
-
return
|
|
3398
|
+
return React45__namespace.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER2;
|
|
3399
3399
|
}
|
|
3400
3400
|
function mergeProps2(slotProps, childProps) {
|
|
3401
3401
|
const overrideProps = { ...childProps };
|
|
@@ -3455,7 +3455,7 @@ var NODES = [
|
|
|
3455
3455
|
];
|
|
3456
3456
|
var Primitive = NODES.reduce((primitive, node) => {
|
|
3457
3457
|
const Slot4 = createSlot2(`Primitive.${node}`);
|
|
3458
|
-
const Node2 =
|
|
3458
|
+
const Node2 = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
3459
3459
|
const { asChild, ...primitiveProps } = props;
|
|
3460
3460
|
const Comp = asChild ? Slot4 : node;
|
|
3461
3461
|
if (typeof window !== "undefined") {
|
|
@@ -3470,7 +3470,7 @@ function dispatchDiscreteCustomEvent(target, event) {
|
|
|
3470
3470
|
if (target) ReactDOM4__namespace.flushSync(() => target.dispatchEvent(event));
|
|
3471
3471
|
}
|
|
3472
3472
|
var NAME = "Toggle";
|
|
3473
|
-
var Toggle =
|
|
3473
|
+
var Toggle = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
3474
3474
|
const { pressed: pressedProp, defaultPressed, onPressedChange, ...buttonProps } = props;
|
|
3475
3475
|
const [pressed, setPressed] = useControllableState({
|
|
3476
3476
|
prop: pressedProp,
|
|
@@ -3524,7 +3524,7 @@ var toggleButtonVariants = cva(
|
|
|
3524
3524
|
}
|
|
3525
3525
|
);
|
|
3526
3526
|
function ToggleButton({ className, variant, size: size4, ...props }) {
|
|
3527
|
-
return /* @__PURE__ */
|
|
3527
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
3528
3528
|
Root,
|
|
3529
3529
|
{
|
|
3530
3530
|
"data-slot": "toggle-button",
|
|
@@ -3540,32 +3540,32 @@ var logicToggleButtonStyles = [
|
|
|
3540
3540
|
].join(" ");
|
|
3541
3541
|
var logicToggleButtonLabelStyles = "uii:inline-block uii:whitespace-nowrap uii:[transform:rotate(-90deg)]";
|
|
3542
3542
|
function LogicToggleButton({ className, children, ...props }) {
|
|
3543
|
-
return /* @__PURE__ */
|
|
3543
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
3544
3544
|
Root,
|
|
3545
3545
|
{
|
|
3546
3546
|
"data-slot": "logic-toggle-button",
|
|
3547
3547
|
className: cn(logicToggleButtonStyles, className),
|
|
3548
3548
|
...props
|
|
3549
3549
|
},
|
|
3550
|
-
children != null ? /* @__PURE__ */
|
|
3550
|
+
children != null ? /* @__PURE__ */ React45__namespace.createElement("span", { className: logicToggleButtonLabelStyles }, children) : null
|
|
3551
3551
|
);
|
|
3552
3552
|
}
|
|
3553
3553
|
function createContextScope(scopeName, createContextScopeDeps = []) {
|
|
3554
3554
|
let defaultContexts = [];
|
|
3555
3555
|
function createContext32(rootComponentName, defaultContext) {
|
|
3556
|
-
const BaseContext =
|
|
3556
|
+
const BaseContext = React45__namespace.createContext(defaultContext);
|
|
3557
3557
|
const index2 = defaultContexts.length;
|
|
3558
3558
|
defaultContexts = [...defaultContexts, defaultContext];
|
|
3559
3559
|
const Provider = (props) => {
|
|
3560
3560
|
const { scope, children, ...context } = props;
|
|
3561
3561
|
const Context = scope?.[scopeName]?.[index2] || BaseContext;
|
|
3562
|
-
const value =
|
|
3562
|
+
const value = React45__namespace.useMemo(() => context, Object.values(context));
|
|
3563
3563
|
return /* @__PURE__ */ jsxRuntime.jsx(Context.Provider, { value, children });
|
|
3564
3564
|
};
|
|
3565
3565
|
Provider.displayName = rootComponentName + "Provider";
|
|
3566
3566
|
function useContext22(consumerName, scope) {
|
|
3567
3567
|
const Context = scope?.[scopeName]?.[index2] || BaseContext;
|
|
3568
|
-
const context =
|
|
3568
|
+
const context = React45__namespace.useContext(Context);
|
|
3569
3569
|
if (context) return context;
|
|
3570
3570
|
if (defaultContext !== void 0) return defaultContext;
|
|
3571
3571
|
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
|
|
@@ -3574,11 +3574,11 @@ function createContextScope(scopeName, createContextScopeDeps = []) {
|
|
|
3574
3574
|
}
|
|
3575
3575
|
const createScope = () => {
|
|
3576
3576
|
const scopeContexts = defaultContexts.map((defaultContext) => {
|
|
3577
|
-
return
|
|
3577
|
+
return React45__namespace.createContext(defaultContext);
|
|
3578
3578
|
});
|
|
3579
3579
|
return function useScope(scope) {
|
|
3580
3580
|
const contexts = scope?.[scopeName] || scopeContexts;
|
|
3581
|
-
return
|
|
3581
|
+
return React45__namespace.useMemo(
|
|
3582
3582
|
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
|
|
3583
3583
|
[scope, contexts]
|
|
3584
3584
|
);
|
|
@@ -3601,7 +3601,7 @@ function composeContextScopes(...scopes) {
|
|
|
3601
3601
|
const currentScope = scopeProps[`__scope${scopeName}`];
|
|
3602
3602
|
return { ...nextScopes2, ...currentScope };
|
|
3603
3603
|
}, {});
|
|
3604
|
-
return
|
|
3604
|
+
return React45__namespace.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
|
|
3605
3605
|
};
|
|
3606
3606
|
};
|
|
3607
3607
|
createScope.scopeName = baseScope.scopeName;
|
|
@@ -3616,14 +3616,14 @@ function createCollection(name) {
|
|
|
3616
3616
|
);
|
|
3617
3617
|
const CollectionProvider = (props) => {
|
|
3618
3618
|
const { scope, children } = props;
|
|
3619
|
-
const ref =
|
|
3620
|
-
const itemMap =
|
|
3619
|
+
const ref = React45__namespace.default.useRef(null);
|
|
3620
|
+
const itemMap = React45__namespace.default.useRef(/* @__PURE__ */ new Map()).current;
|
|
3621
3621
|
return /* @__PURE__ */ jsxRuntime.jsx(CollectionProviderImpl, { scope, itemMap, collectionRef: ref, children });
|
|
3622
3622
|
};
|
|
3623
3623
|
CollectionProvider.displayName = PROVIDER_NAME;
|
|
3624
3624
|
const COLLECTION_SLOT_NAME = name + "CollectionSlot";
|
|
3625
3625
|
const CollectionSlotImpl = createSlot2(COLLECTION_SLOT_NAME);
|
|
3626
|
-
const CollectionSlot =
|
|
3626
|
+
const CollectionSlot = React45__namespace.default.forwardRef(
|
|
3627
3627
|
(props, forwardedRef) => {
|
|
3628
3628
|
const { scope, children } = props;
|
|
3629
3629
|
const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);
|
|
@@ -3635,13 +3635,13 @@ function createCollection(name) {
|
|
|
3635
3635
|
const ITEM_SLOT_NAME = name + "CollectionItemSlot";
|
|
3636
3636
|
const ITEM_DATA_ATTR = "data-radix-collection-item";
|
|
3637
3637
|
const CollectionItemSlotImpl = createSlot2(ITEM_SLOT_NAME);
|
|
3638
|
-
const CollectionItemSlot =
|
|
3638
|
+
const CollectionItemSlot = React45__namespace.default.forwardRef(
|
|
3639
3639
|
(props, forwardedRef) => {
|
|
3640
3640
|
const { scope, children, ...itemData } = props;
|
|
3641
|
-
const ref =
|
|
3641
|
+
const ref = React45__namespace.default.useRef(null);
|
|
3642
3642
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
3643
3643
|
const context = useCollectionContext(ITEM_SLOT_NAME, scope);
|
|
3644
|
-
|
|
3644
|
+
React45__namespace.default.useEffect(() => {
|
|
3645
3645
|
context.itemMap.set(ref, { ref, ...itemData });
|
|
3646
3646
|
return () => void context.itemMap.delete(ref);
|
|
3647
3647
|
});
|
|
@@ -3651,7 +3651,7 @@ function createCollection(name) {
|
|
|
3651
3651
|
CollectionItemSlot.displayName = ITEM_SLOT_NAME;
|
|
3652
3652
|
function useCollection4(scope) {
|
|
3653
3653
|
const context = useCollectionContext(name + "CollectionConsumer", scope);
|
|
3654
|
-
const getItems =
|
|
3654
|
+
const getItems = React45__namespace.default.useCallback(() => {
|
|
3655
3655
|
const collectionNode = context.collectionRef.current;
|
|
3656
3656
|
if (!collectionNode) return [];
|
|
3657
3657
|
const orderedNodes = Array.from(collectionNode.querySelectorAll(`[${ITEM_DATA_ATTR}]`));
|
|
@@ -3669,21 +3669,21 @@ function createCollection(name) {
|
|
|
3669
3669
|
createCollectionScope4
|
|
3670
3670
|
];
|
|
3671
3671
|
}
|
|
3672
|
-
var DirectionContext =
|
|
3672
|
+
var DirectionContext = React45__namespace.createContext(void 0);
|
|
3673
3673
|
function useDirection(localDir) {
|
|
3674
|
-
const globalDir =
|
|
3674
|
+
const globalDir = React45__namespace.useContext(DirectionContext);
|
|
3675
3675
|
return localDir || globalDir || "ltr";
|
|
3676
3676
|
}
|
|
3677
3677
|
function useCallbackRef(callback) {
|
|
3678
|
-
const callbackRef =
|
|
3679
|
-
|
|
3678
|
+
const callbackRef = React45__namespace.useRef(callback);
|
|
3679
|
+
React45__namespace.useEffect(() => {
|
|
3680
3680
|
callbackRef.current = callback;
|
|
3681
3681
|
});
|
|
3682
|
-
return
|
|
3682
|
+
return React45__namespace.useMemo(() => (...args) => callbackRef.current?.(...args), []);
|
|
3683
3683
|
}
|
|
3684
3684
|
function useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis?.document) {
|
|
3685
3685
|
const onEscapeKeyDown = useCallbackRef(onEscapeKeyDownProp);
|
|
3686
|
-
|
|
3686
|
+
React45__namespace.useEffect(() => {
|
|
3687
3687
|
const handleKeyDown = (event) => {
|
|
3688
3688
|
if (event.key === "Escape") {
|
|
3689
3689
|
onEscapeKeyDown(event);
|
|
@@ -3698,12 +3698,12 @@ var CONTEXT_UPDATE = "dismissableLayer.update";
|
|
|
3698
3698
|
var POINTER_DOWN_OUTSIDE = "dismissableLayer.pointerDownOutside";
|
|
3699
3699
|
var FOCUS_OUTSIDE = "dismissableLayer.focusOutside";
|
|
3700
3700
|
var originalBodyPointerEvents;
|
|
3701
|
-
var DismissableLayerContext =
|
|
3701
|
+
var DismissableLayerContext = React45__namespace.createContext({
|
|
3702
3702
|
layers: /* @__PURE__ */ new Set(),
|
|
3703
3703
|
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
3704
3704
|
branches: /* @__PURE__ */ new Set()
|
|
3705
3705
|
});
|
|
3706
|
-
var DismissableLayer =
|
|
3706
|
+
var DismissableLayer = React45__namespace.forwardRef(
|
|
3707
3707
|
(props, forwardedRef) => {
|
|
3708
3708
|
const {
|
|
3709
3709
|
disableOutsidePointerEvents = false,
|
|
@@ -3714,10 +3714,10 @@ var DismissableLayer = React44__namespace.forwardRef(
|
|
|
3714
3714
|
onDismiss,
|
|
3715
3715
|
...layerProps
|
|
3716
3716
|
} = props;
|
|
3717
|
-
const context =
|
|
3718
|
-
const [node, setNode] =
|
|
3717
|
+
const context = React45__namespace.useContext(DismissableLayerContext);
|
|
3718
|
+
const [node, setNode] = React45__namespace.useState(null);
|
|
3719
3719
|
const ownerDocument = node?.ownerDocument ?? globalThis?.document;
|
|
3720
|
-
const [, force] =
|
|
3720
|
+
const [, force] = React45__namespace.useState({});
|
|
3721
3721
|
const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
|
|
3722
3722
|
const layers = Array.from(context.layers);
|
|
3723
3723
|
const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);
|
|
@@ -3750,7 +3750,7 @@ var DismissableLayer = React44__namespace.forwardRef(
|
|
|
3750
3750
|
onDismiss();
|
|
3751
3751
|
}
|
|
3752
3752
|
}, ownerDocument);
|
|
3753
|
-
|
|
3753
|
+
React45__namespace.useEffect(() => {
|
|
3754
3754
|
if (!node) return;
|
|
3755
3755
|
if (disableOutsidePointerEvents) {
|
|
3756
3756
|
if (context.layersWithOutsidePointerEventsDisabled.size === 0) {
|
|
@@ -3767,7 +3767,7 @@ var DismissableLayer = React44__namespace.forwardRef(
|
|
|
3767
3767
|
}
|
|
3768
3768
|
};
|
|
3769
3769
|
}, [node, ownerDocument, disableOutsidePointerEvents, context]);
|
|
3770
|
-
|
|
3770
|
+
React45__namespace.useEffect(() => {
|
|
3771
3771
|
return () => {
|
|
3772
3772
|
if (!node) return;
|
|
3773
3773
|
context.layers.delete(node);
|
|
@@ -3775,7 +3775,7 @@ var DismissableLayer = React44__namespace.forwardRef(
|
|
|
3775
3775
|
dispatchUpdate();
|
|
3776
3776
|
};
|
|
3777
3777
|
}, [node, context]);
|
|
3778
|
-
|
|
3778
|
+
React45__namespace.useEffect(() => {
|
|
3779
3779
|
const handleUpdate = () => force({});
|
|
3780
3780
|
document.addEventListener(CONTEXT_UPDATE, handleUpdate);
|
|
3781
3781
|
return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);
|
|
@@ -3801,11 +3801,11 @@ var DismissableLayer = React44__namespace.forwardRef(
|
|
|
3801
3801
|
);
|
|
3802
3802
|
DismissableLayer.displayName = DISMISSABLE_LAYER_NAME;
|
|
3803
3803
|
var BRANCH_NAME = "DismissableLayerBranch";
|
|
3804
|
-
var DismissableLayerBranch =
|
|
3805
|
-
const context =
|
|
3806
|
-
const ref =
|
|
3804
|
+
var DismissableLayerBranch = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
3805
|
+
const context = React45__namespace.useContext(DismissableLayerContext);
|
|
3806
|
+
const ref = React45__namespace.useRef(null);
|
|
3807
3807
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
3808
|
-
|
|
3808
|
+
React45__namespace.useEffect(() => {
|
|
3809
3809
|
const node = ref.current;
|
|
3810
3810
|
if (node) {
|
|
3811
3811
|
context.branches.add(node);
|
|
@@ -3819,10 +3819,10 @@ var DismissableLayerBranch = React44__namespace.forwardRef((props, forwardedRef)
|
|
|
3819
3819
|
DismissableLayerBranch.displayName = BRANCH_NAME;
|
|
3820
3820
|
function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis?.document) {
|
|
3821
3821
|
const handlePointerDownOutside = useCallbackRef(onPointerDownOutside);
|
|
3822
|
-
const isPointerInsideReactTreeRef =
|
|
3823
|
-
const handleClickRef =
|
|
3822
|
+
const isPointerInsideReactTreeRef = React45__namespace.useRef(false);
|
|
3823
|
+
const handleClickRef = React45__namespace.useRef(() => {
|
|
3824
3824
|
});
|
|
3825
|
-
|
|
3825
|
+
React45__namespace.useEffect(() => {
|
|
3826
3826
|
const handlePointerDown = (event) => {
|
|
3827
3827
|
if (event.target && !isPointerInsideReactTreeRef.current) {
|
|
3828
3828
|
let handleAndDispatchPointerDownOutsideEvent2 = function() {
|
|
@@ -3862,8 +3862,8 @@ function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis?
|
|
|
3862
3862
|
}
|
|
3863
3863
|
function useFocusOutside(onFocusOutside, ownerDocument = globalThis?.document) {
|
|
3864
3864
|
const handleFocusOutside = useCallbackRef(onFocusOutside);
|
|
3865
|
-
const isFocusInsideReactTreeRef =
|
|
3866
|
-
|
|
3865
|
+
const isFocusInsideReactTreeRef = React45__namespace.useRef(false);
|
|
3866
|
+
React45__namespace.useEffect(() => {
|
|
3867
3867
|
const handleFocus = (event) => {
|
|
3868
3868
|
if (event.target && !isFocusInsideReactTreeRef.current) {
|
|
3869
3869
|
const eventDetail = { originalEvent: event };
|
|
@@ -3896,7 +3896,7 @@ function handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {
|
|
|
3896
3896
|
}
|
|
3897
3897
|
var count = 0;
|
|
3898
3898
|
function useFocusGuards() {
|
|
3899
|
-
|
|
3899
|
+
React45__namespace.useEffect(() => {
|
|
3900
3900
|
const edgeGuards = document.querySelectorAll("[data-radix-focus-guard]");
|
|
3901
3901
|
document.body.insertAdjacentElement("afterbegin", edgeGuards[0] ?? createFocusGuard());
|
|
3902
3902
|
document.body.insertAdjacentElement("beforeend", edgeGuards[1] ?? createFocusGuard());
|
|
@@ -3923,7 +3923,7 @@ var AUTOFOCUS_ON_MOUNT = "focusScope.autoFocusOnMount";
|
|
|
3923
3923
|
var AUTOFOCUS_ON_UNMOUNT = "focusScope.autoFocusOnUnmount";
|
|
3924
3924
|
var EVENT_OPTIONS = { bubbles: false, cancelable: true };
|
|
3925
3925
|
var FOCUS_SCOPE_NAME = "FocusScope";
|
|
3926
|
-
var FocusScope =
|
|
3926
|
+
var FocusScope = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
3927
3927
|
const {
|
|
3928
3928
|
loop = false,
|
|
3929
3929
|
trapped = false,
|
|
@@ -3931,12 +3931,12 @@ var FocusScope = React44__namespace.forwardRef((props, forwardedRef) => {
|
|
|
3931
3931
|
onUnmountAutoFocus: onUnmountAutoFocusProp,
|
|
3932
3932
|
...scopeProps
|
|
3933
3933
|
} = props;
|
|
3934
|
-
const [container, setContainer] =
|
|
3934
|
+
const [container, setContainer] = React45__namespace.useState(null);
|
|
3935
3935
|
const onMountAutoFocus = useCallbackRef(onMountAutoFocusProp);
|
|
3936
3936
|
const onUnmountAutoFocus = useCallbackRef(onUnmountAutoFocusProp);
|
|
3937
|
-
const lastFocusedElementRef =
|
|
3937
|
+
const lastFocusedElementRef = React45__namespace.useRef(null);
|
|
3938
3938
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setContainer(node));
|
|
3939
|
-
const focusScope =
|
|
3939
|
+
const focusScope = React45__namespace.useRef({
|
|
3940
3940
|
paused: false,
|
|
3941
3941
|
pause() {
|
|
3942
3942
|
this.paused = true;
|
|
@@ -3945,7 +3945,7 @@ var FocusScope = React44__namespace.forwardRef((props, forwardedRef) => {
|
|
|
3945
3945
|
this.paused = false;
|
|
3946
3946
|
}
|
|
3947
3947
|
}).current;
|
|
3948
|
-
|
|
3948
|
+
React45__namespace.useEffect(() => {
|
|
3949
3949
|
if (trapped) {
|
|
3950
3950
|
let handleFocusIn2 = function(event) {
|
|
3951
3951
|
if (focusScope.paused || !container) return;
|
|
@@ -3980,7 +3980,7 @@ var FocusScope = React44__namespace.forwardRef((props, forwardedRef) => {
|
|
|
3980
3980
|
};
|
|
3981
3981
|
}
|
|
3982
3982
|
}, [trapped, container, focusScope.paused]);
|
|
3983
|
-
|
|
3983
|
+
React45__namespace.useEffect(() => {
|
|
3984
3984
|
if (container) {
|
|
3985
3985
|
focusScopesStack.add(focusScope);
|
|
3986
3986
|
const previouslyFocusedElement = document.activeElement;
|
|
@@ -4011,7 +4011,7 @@ var FocusScope = React44__namespace.forwardRef((props, forwardedRef) => {
|
|
|
4011
4011
|
};
|
|
4012
4012
|
}
|
|
4013
4013
|
}, [container, onMountAutoFocus, onUnmountAutoFocus, focusScope]);
|
|
4014
|
-
const handleKeyDown =
|
|
4014
|
+
const handleKeyDown = React45__namespace.useCallback(
|
|
4015
4015
|
(event) => {
|
|
4016
4016
|
if (!loop && !trapped) return;
|
|
4017
4017
|
if (focusScope.paused) return;
|
|
@@ -4118,10 +4118,10 @@ function arrayRemove(array, item) {
|
|
|
4118
4118
|
function removeLinks(items) {
|
|
4119
4119
|
return items.filter((item) => item.tagName !== "A");
|
|
4120
4120
|
}
|
|
4121
|
-
var useReactId =
|
|
4121
|
+
var useReactId = React45__namespace[" useId ".trim().toString()] || (() => void 0);
|
|
4122
4122
|
var count2 = 0;
|
|
4123
4123
|
function useId(deterministicId) {
|
|
4124
|
-
const [id, setId] =
|
|
4124
|
+
const [id, setId] = React45__namespace.useState(useReactId());
|
|
4125
4125
|
useLayoutEffect2(() => {
|
|
4126
4126
|
setId((reactId) => reactId ?? String(count2++));
|
|
4127
4127
|
}, [deterministicId]);
|
|
@@ -5736,7 +5736,7 @@ var computePosition2 = (reference, floating, options) => {
|
|
|
5736
5736
|
var isClient = typeof document !== "undefined";
|
|
5737
5737
|
var noop = function noop2() {
|
|
5738
5738
|
};
|
|
5739
|
-
var index = isClient ?
|
|
5739
|
+
var index = isClient ? React45.useLayoutEffect : noop;
|
|
5740
5740
|
function deepEqual(a, b) {
|
|
5741
5741
|
if (a === b) {
|
|
5742
5742
|
return true;
|
|
@@ -5796,7 +5796,7 @@ function roundByDPR(element, value) {
|
|
|
5796
5796
|
return Math.round(value * dpr) / dpr;
|
|
5797
5797
|
}
|
|
5798
5798
|
function useLatestRef(value) {
|
|
5799
|
-
const ref =
|
|
5799
|
+
const ref = React45__namespace.useRef(value);
|
|
5800
5800
|
index(() => {
|
|
5801
5801
|
ref.current = value;
|
|
5802
5802
|
});
|
|
@@ -5819,7 +5819,7 @@ function useFloating(options) {
|
|
|
5819
5819
|
whileElementsMounted,
|
|
5820
5820
|
open
|
|
5821
5821
|
} = options;
|
|
5822
|
-
const [data, setData] =
|
|
5822
|
+
const [data, setData] = React45__namespace.useState({
|
|
5823
5823
|
x: 0,
|
|
5824
5824
|
y: 0,
|
|
5825
5825
|
strategy,
|
|
@@ -5827,19 +5827,19 @@ function useFloating(options) {
|
|
|
5827
5827
|
middlewareData: {},
|
|
5828
5828
|
isPositioned: false
|
|
5829
5829
|
});
|
|
5830
|
-
const [latestMiddleware, setLatestMiddleware] =
|
|
5830
|
+
const [latestMiddleware, setLatestMiddleware] = React45__namespace.useState(middleware);
|
|
5831
5831
|
if (!deepEqual(latestMiddleware, middleware)) {
|
|
5832
5832
|
setLatestMiddleware(middleware);
|
|
5833
5833
|
}
|
|
5834
|
-
const [_reference, _setReference] =
|
|
5835
|
-
const [_floating, _setFloating] =
|
|
5836
|
-
const setReference =
|
|
5834
|
+
const [_reference, _setReference] = React45__namespace.useState(null);
|
|
5835
|
+
const [_floating, _setFloating] = React45__namespace.useState(null);
|
|
5836
|
+
const setReference = React45__namespace.useCallback((node) => {
|
|
5837
5837
|
if (node !== referenceRef.current) {
|
|
5838
5838
|
referenceRef.current = node;
|
|
5839
5839
|
_setReference(node);
|
|
5840
5840
|
}
|
|
5841
5841
|
}, []);
|
|
5842
|
-
const setFloating =
|
|
5842
|
+
const setFloating = React45__namespace.useCallback((node) => {
|
|
5843
5843
|
if (node !== floatingRef.current) {
|
|
5844
5844
|
floatingRef.current = node;
|
|
5845
5845
|
_setFloating(node);
|
|
@@ -5847,14 +5847,14 @@ function useFloating(options) {
|
|
|
5847
5847
|
}, []);
|
|
5848
5848
|
const referenceEl = externalReference || _reference;
|
|
5849
5849
|
const floatingEl = externalFloating || _floating;
|
|
5850
|
-
const referenceRef =
|
|
5851
|
-
const floatingRef =
|
|
5852
|
-
const dataRef =
|
|
5850
|
+
const referenceRef = React45__namespace.useRef(null);
|
|
5851
|
+
const floatingRef = React45__namespace.useRef(null);
|
|
5852
|
+
const dataRef = React45__namespace.useRef(data);
|
|
5853
5853
|
const hasWhileElementsMounted = whileElementsMounted != null;
|
|
5854
5854
|
const whileElementsMountedRef = useLatestRef(whileElementsMounted);
|
|
5855
5855
|
const platformRef = useLatestRef(platform2);
|
|
5856
5856
|
const openRef = useLatestRef(open);
|
|
5857
|
-
const update =
|
|
5857
|
+
const update = React45__namespace.useCallback(() => {
|
|
5858
5858
|
if (!referenceRef.current || !floatingRef.current) {
|
|
5859
5859
|
return;
|
|
5860
5860
|
}
|
|
@@ -5892,7 +5892,7 @@ function useFloating(options) {
|
|
|
5892
5892
|
}));
|
|
5893
5893
|
}
|
|
5894
5894
|
}, [open]);
|
|
5895
|
-
const isMountedRef =
|
|
5895
|
+
const isMountedRef = React45__namespace.useRef(false);
|
|
5896
5896
|
index(() => {
|
|
5897
5897
|
isMountedRef.current = true;
|
|
5898
5898
|
return () => {
|
|
@@ -5909,17 +5909,17 @@ function useFloating(options) {
|
|
|
5909
5909
|
update();
|
|
5910
5910
|
}
|
|
5911
5911
|
}, [referenceEl, floatingEl, update, whileElementsMountedRef, hasWhileElementsMounted]);
|
|
5912
|
-
const refs =
|
|
5912
|
+
const refs = React45__namespace.useMemo(() => ({
|
|
5913
5913
|
reference: referenceRef,
|
|
5914
5914
|
floating: floatingRef,
|
|
5915
5915
|
setReference,
|
|
5916
5916
|
setFloating
|
|
5917
5917
|
}), [setReference, setFloating]);
|
|
5918
|
-
const elements =
|
|
5918
|
+
const elements = React45__namespace.useMemo(() => ({
|
|
5919
5919
|
reference: referenceEl,
|
|
5920
5920
|
floating: floatingEl
|
|
5921
5921
|
}), [referenceEl, floatingEl]);
|
|
5922
|
-
const floatingStyles =
|
|
5922
|
+
const floatingStyles = React45__namespace.useMemo(() => {
|
|
5923
5923
|
const initialStyles = {
|
|
5924
5924
|
position: strategy,
|
|
5925
5925
|
left: 0,
|
|
@@ -5945,7 +5945,7 @@ function useFloating(options) {
|
|
|
5945
5945
|
top: y
|
|
5946
5946
|
};
|
|
5947
5947
|
}, [strategy, transform, elements.floating, data.x, data.y]);
|
|
5948
|
-
return
|
|
5948
|
+
return React45__namespace.useMemo(() => ({
|
|
5949
5949
|
...data,
|
|
5950
5950
|
update,
|
|
5951
5951
|
refs,
|
|
@@ -6013,7 +6013,7 @@ var arrow3 = (options, deps) => ({
|
|
|
6013
6013
|
options: [options, deps]
|
|
6014
6014
|
});
|
|
6015
6015
|
var NAME2 = "Arrow";
|
|
6016
|
-
var Arrow =
|
|
6016
|
+
var Arrow = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
6017
6017
|
const { children, width = 10, height = 5, ...arrowProps } = props;
|
|
6018
6018
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6019
6019
|
Primitive.svg,
|
|
@@ -6031,7 +6031,7 @@ var Arrow = React44__namespace.forwardRef((props, forwardedRef) => {
|
|
|
6031
6031
|
Arrow.displayName = NAME2;
|
|
6032
6032
|
var Root2 = Arrow;
|
|
6033
6033
|
function useSize(element) {
|
|
6034
|
-
const [size4, setSize] =
|
|
6034
|
+
const [size4, setSize] = React45__namespace.useState(void 0);
|
|
6035
6035
|
useLayoutEffect2(() => {
|
|
6036
6036
|
if (element) {
|
|
6037
6037
|
setSize({ width: element.offsetWidth, height: element.offsetHeight });
|
|
@@ -6069,19 +6069,19 @@ var [createPopperContext, createPopperScope] = createContextScope(POPPER_NAME);
|
|
|
6069
6069
|
var [PopperProvider, usePopperContext] = createPopperContext(POPPER_NAME);
|
|
6070
6070
|
var Popper = (props) => {
|
|
6071
6071
|
const { __scopePopper, children } = props;
|
|
6072
|
-
const [anchor, setAnchor] =
|
|
6072
|
+
const [anchor, setAnchor] = React45__namespace.useState(null);
|
|
6073
6073
|
return /* @__PURE__ */ jsxRuntime.jsx(PopperProvider, { scope: __scopePopper, anchor, onAnchorChange: setAnchor, children });
|
|
6074
6074
|
};
|
|
6075
6075
|
Popper.displayName = POPPER_NAME;
|
|
6076
6076
|
var ANCHOR_NAME = "PopperAnchor";
|
|
6077
|
-
var PopperAnchor =
|
|
6077
|
+
var PopperAnchor = React45__namespace.forwardRef(
|
|
6078
6078
|
(props, forwardedRef) => {
|
|
6079
6079
|
const { __scopePopper, virtualRef, ...anchorProps } = props;
|
|
6080
6080
|
const context = usePopperContext(ANCHOR_NAME, __scopePopper);
|
|
6081
|
-
const ref =
|
|
6081
|
+
const ref = React45__namespace.useRef(null);
|
|
6082
6082
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
6083
|
-
const anchorRef =
|
|
6084
|
-
|
|
6083
|
+
const anchorRef = React45__namespace.useRef(null);
|
|
6084
|
+
React45__namespace.useEffect(() => {
|
|
6085
6085
|
const previousAnchor = anchorRef.current;
|
|
6086
6086
|
anchorRef.current = virtualRef?.current || ref.current;
|
|
6087
6087
|
if (previousAnchor !== anchorRef.current) {
|
|
@@ -6094,7 +6094,7 @@ var PopperAnchor = React44__namespace.forwardRef(
|
|
|
6094
6094
|
PopperAnchor.displayName = ANCHOR_NAME;
|
|
6095
6095
|
var CONTENT_NAME = "PopperContent";
|
|
6096
6096
|
var [PopperContentProvider, useContentContext] = createPopperContext(CONTENT_NAME);
|
|
6097
|
-
var PopperContent =
|
|
6097
|
+
var PopperContent = React45__namespace.forwardRef(
|
|
6098
6098
|
(props, forwardedRef) => {
|
|
6099
6099
|
const {
|
|
6100
6100
|
__scopePopper,
|
|
@@ -6113,9 +6113,9 @@ var PopperContent = React44__namespace.forwardRef(
|
|
|
6113
6113
|
...contentProps
|
|
6114
6114
|
} = props;
|
|
6115
6115
|
const context = usePopperContext(CONTENT_NAME, __scopePopper);
|
|
6116
|
-
const [content, setContent] =
|
|
6116
|
+
const [content, setContent] = React45__namespace.useState(null);
|
|
6117
6117
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setContent(node));
|
|
6118
|
-
const [arrow4, setArrow] =
|
|
6118
|
+
const [arrow4, setArrow] = React45__namespace.useState(null);
|
|
6119
6119
|
const arrowSize = useSize(arrow4);
|
|
6120
6120
|
const arrowWidth = arrowSize?.width ?? 0;
|
|
6121
6121
|
const arrowHeight = arrowSize?.height ?? 0;
|
|
@@ -6177,7 +6177,7 @@ var PopperContent = React44__namespace.forwardRef(
|
|
|
6177
6177
|
const arrowX = middlewareData.arrow?.x;
|
|
6178
6178
|
const arrowY = middlewareData.arrow?.y;
|
|
6179
6179
|
const cannotCenterArrow = middlewareData.arrow?.centerOffset !== 0;
|
|
6180
|
-
const [contentZIndex, setContentZIndex] =
|
|
6180
|
+
const [contentZIndex, setContentZIndex] = React45__namespace.useState();
|
|
6181
6181
|
useLayoutEffect2(() => {
|
|
6182
6182
|
if (content) setContentZIndex(window.getComputedStyle(content).zIndex);
|
|
6183
6183
|
}, [content]);
|
|
@@ -6243,7 +6243,7 @@ var OPPOSITE_SIDE = {
|
|
|
6243
6243
|
bottom: "top",
|
|
6244
6244
|
left: "right"
|
|
6245
6245
|
};
|
|
6246
|
-
var PopperArrow =
|
|
6246
|
+
var PopperArrow = React45__namespace.forwardRef(function PopperArrow2(props, forwardedRef) {
|
|
6247
6247
|
const { __scopePopper, ...arrowProps } = props;
|
|
6248
6248
|
const contentContext = useContentContext(ARROW_NAME, __scopePopper);
|
|
6249
6249
|
const baseSide = OPPOSITE_SIDE[contentContext.placedSide];
|
|
@@ -6334,16 +6334,16 @@ var Anchor = PopperAnchor;
|
|
|
6334
6334
|
var Content = PopperContent;
|
|
6335
6335
|
var Arrow2 = PopperArrow;
|
|
6336
6336
|
var PORTAL_NAME = "Portal";
|
|
6337
|
-
var Portal =
|
|
6337
|
+
var Portal = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
6338
6338
|
const { container: containerProp, ...portalProps } = props;
|
|
6339
|
-
const [mounted, setMounted] =
|
|
6339
|
+
const [mounted, setMounted] = React45__namespace.useState(false);
|
|
6340
6340
|
useLayoutEffect2(() => setMounted(true), []);
|
|
6341
6341
|
const container = containerProp || mounted && globalThis?.document?.body;
|
|
6342
6342
|
return container ? ReactDOM4__namespace.default.createPortal(/* @__PURE__ */ jsxRuntime.jsx(Primitive.div, { ...portalProps, ref: forwardedRef }), container) : null;
|
|
6343
6343
|
});
|
|
6344
6344
|
Portal.displayName = PORTAL_NAME;
|
|
6345
6345
|
function useStateMachine(initialState, machine) {
|
|
6346
|
-
return
|
|
6346
|
+
return React45__namespace.useReducer((state, event) => {
|
|
6347
6347
|
const nextState = machine[state][event];
|
|
6348
6348
|
return nextState ?? state;
|
|
6349
6349
|
}, initialState);
|
|
@@ -6351,17 +6351,17 @@ function useStateMachine(initialState, machine) {
|
|
|
6351
6351
|
var Presence = (props) => {
|
|
6352
6352
|
const { present, children } = props;
|
|
6353
6353
|
const presence = usePresence(present);
|
|
6354
|
-
const child = typeof children === "function" ? children({ present: presence.isPresent }) :
|
|
6354
|
+
const child = typeof children === "function" ? children({ present: presence.isPresent }) : React45__namespace.Children.only(children);
|
|
6355
6355
|
const ref = useComposedRefs(presence.ref, getElementRef3(child));
|
|
6356
6356
|
const forceMount = typeof children === "function";
|
|
6357
|
-
return forceMount || presence.isPresent ?
|
|
6357
|
+
return forceMount || presence.isPresent ? React45__namespace.cloneElement(child, { ref }) : null;
|
|
6358
6358
|
};
|
|
6359
6359
|
Presence.displayName = "Presence";
|
|
6360
6360
|
function usePresence(present) {
|
|
6361
|
-
const [node, setNode] =
|
|
6362
|
-
const stylesRef =
|
|
6363
|
-
const prevPresentRef =
|
|
6364
|
-
const prevAnimationNameRef =
|
|
6361
|
+
const [node, setNode] = React45__namespace.useState();
|
|
6362
|
+
const stylesRef = React45__namespace.useRef(null);
|
|
6363
|
+
const prevPresentRef = React45__namespace.useRef(present);
|
|
6364
|
+
const prevAnimationNameRef = React45__namespace.useRef("none");
|
|
6365
6365
|
const initialState = present ? "mounted" : "unmounted";
|
|
6366
6366
|
const [state, send] = useStateMachine(initialState, {
|
|
6367
6367
|
mounted: {
|
|
@@ -6376,7 +6376,7 @@ function usePresence(present) {
|
|
|
6376
6376
|
MOUNT: "mounted"
|
|
6377
6377
|
}
|
|
6378
6378
|
});
|
|
6379
|
-
|
|
6379
|
+
React45__namespace.useEffect(() => {
|
|
6380
6380
|
const currentAnimationName = getAnimationName(stylesRef.current);
|
|
6381
6381
|
prevAnimationNameRef.current = state === "mounted" ? currentAnimationName : "none";
|
|
6382
6382
|
}, [state]);
|
|
@@ -6442,7 +6442,7 @@ function usePresence(present) {
|
|
|
6442
6442
|
}, [node, send]);
|
|
6443
6443
|
return {
|
|
6444
6444
|
isPresent: ["mounted", "unmountSuspended"].includes(state),
|
|
6445
|
-
ref:
|
|
6445
|
+
ref: React45__namespace.useCallback((node2) => {
|
|
6446
6446
|
stylesRef.current = node2 ? getComputedStyle(node2) : null;
|
|
6447
6447
|
setNode(node2);
|
|
6448
6448
|
}, [])
|
|
@@ -6473,13 +6473,13 @@ var [createRovingFocusGroupContext, createRovingFocusGroupScope] = createContext
|
|
|
6473
6473
|
[createCollectionScope]
|
|
6474
6474
|
);
|
|
6475
6475
|
var [RovingFocusProvider, useRovingFocusContext] = createRovingFocusGroupContext(GROUP_NAME);
|
|
6476
|
-
var RovingFocusGroup =
|
|
6476
|
+
var RovingFocusGroup = React45__namespace.forwardRef(
|
|
6477
6477
|
(props, forwardedRef) => {
|
|
6478
6478
|
return /* @__PURE__ */ jsxRuntime.jsx(Collection.Provider, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsxRuntime.jsx(Collection.Slot, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsxRuntime.jsx(RovingFocusGroupImpl, { ...props, ref: forwardedRef }) }) });
|
|
6479
6479
|
}
|
|
6480
6480
|
);
|
|
6481
6481
|
RovingFocusGroup.displayName = GROUP_NAME;
|
|
6482
|
-
var RovingFocusGroupImpl =
|
|
6482
|
+
var RovingFocusGroupImpl = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
6483
6483
|
const {
|
|
6484
6484
|
__scopeRovingFocusGroup,
|
|
6485
6485
|
orientation,
|
|
@@ -6492,7 +6492,7 @@ var RovingFocusGroupImpl = React44__namespace.forwardRef((props, forwardedRef) =
|
|
|
6492
6492
|
preventScrollOnEntryFocus = false,
|
|
6493
6493
|
...groupProps
|
|
6494
6494
|
} = props;
|
|
6495
|
-
const ref =
|
|
6495
|
+
const ref = React45__namespace.useRef(null);
|
|
6496
6496
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
6497
6497
|
const direction = useDirection(dir);
|
|
6498
6498
|
const [currentTabStopId, setCurrentTabStopId] = useControllableState({
|
|
@@ -6501,12 +6501,12 @@ var RovingFocusGroupImpl = React44__namespace.forwardRef((props, forwardedRef) =
|
|
|
6501
6501
|
onChange: onCurrentTabStopIdChange,
|
|
6502
6502
|
caller: GROUP_NAME
|
|
6503
6503
|
});
|
|
6504
|
-
const [isTabbingBackOut, setIsTabbingBackOut] =
|
|
6504
|
+
const [isTabbingBackOut, setIsTabbingBackOut] = React45__namespace.useState(false);
|
|
6505
6505
|
const handleEntryFocus = useCallbackRef(onEntryFocus);
|
|
6506
6506
|
const getItems = useCollection(__scopeRovingFocusGroup);
|
|
6507
|
-
const isClickFocusRef =
|
|
6508
|
-
const [focusableItemsCount, setFocusableItemsCount] =
|
|
6509
|
-
|
|
6507
|
+
const isClickFocusRef = React45__namespace.useRef(false);
|
|
6508
|
+
const [focusableItemsCount, setFocusableItemsCount] = React45__namespace.useState(0);
|
|
6509
|
+
React45__namespace.useEffect(() => {
|
|
6510
6510
|
const node = ref.current;
|
|
6511
6511
|
if (node) {
|
|
6512
6512
|
node.addEventListener(ENTRY_FOCUS, handleEntryFocus);
|
|
@@ -6521,16 +6521,16 @@ var RovingFocusGroupImpl = React44__namespace.forwardRef((props, forwardedRef) =
|
|
|
6521
6521
|
dir: direction,
|
|
6522
6522
|
loop,
|
|
6523
6523
|
currentTabStopId,
|
|
6524
|
-
onItemFocus:
|
|
6524
|
+
onItemFocus: React45__namespace.useCallback(
|
|
6525
6525
|
(tabStopId) => setCurrentTabStopId(tabStopId),
|
|
6526
6526
|
[setCurrentTabStopId]
|
|
6527
6527
|
),
|
|
6528
|
-
onItemShiftTab:
|
|
6529
|
-
onFocusableItemAdd:
|
|
6528
|
+
onItemShiftTab: React45__namespace.useCallback(() => setIsTabbingBackOut(true), []),
|
|
6529
|
+
onFocusableItemAdd: React45__namespace.useCallback(
|
|
6530
6530
|
() => setFocusableItemsCount((prevCount) => prevCount + 1),
|
|
6531
6531
|
[]
|
|
6532
6532
|
),
|
|
6533
|
-
onFocusableItemRemove:
|
|
6533
|
+
onFocusableItemRemove: React45__namespace.useCallback(
|
|
6534
6534
|
() => setFocusableItemsCount((prevCount) => prevCount - 1),
|
|
6535
6535
|
[]
|
|
6536
6536
|
),
|
|
@@ -6570,7 +6570,7 @@ var RovingFocusGroupImpl = React44__namespace.forwardRef((props, forwardedRef) =
|
|
|
6570
6570
|
);
|
|
6571
6571
|
});
|
|
6572
6572
|
var ITEM_NAME = "RovingFocusGroupItem";
|
|
6573
|
-
var RovingFocusGroupItem =
|
|
6573
|
+
var RovingFocusGroupItem = React45__namespace.forwardRef(
|
|
6574
6574
|
(props, forwardedRef) => {
|
|
6575
6575
|
const {
|
|
6576
6576
|
__scopeRovingFocusGroup,
|
|
@@ -6586,7 +6586,7 @@ var RovingFocusGroupItem = React44__namespace.forwardRef(
|
|
|
6586
6586
|
const isCurrentTabStop = context.currentTabStopId === id;
|
|
6587
6587
|
const getItems = useCollection(__scopeRovingFocusGroup);
|
|
6588
6588
|
const { onFocusableItemAdd, onFocusableItemRemove, currentTabStopId } = context;
|
|
6589
|
-
|
|
6589
|
+
React45__namespace.useEffect(() => {
|
|
6590
6590
|
if (focusable) {
|
|
6591
6591
|
onFocusableItemAdd();
|
|
6592
6592
|
return () => onFocusableItemRemove();
|
|
@@ -6843,7 +6843,7 @@ function assignRef(ref, value) {
|
|
|
6843
6843
|
return ref;
|
|
6844
6844
|
}
|
|
6845
6845
|
function useCallbackRef2(initialValue, callback) {
|
|
6846
|
-
var ref =
|
|
6846
|
+
var ref = React45.useState(function() {
|
|
6847
6847
|
return {
|
|
6848
6848
|
// value
|
|
6849
6849
|
value: initialValue,
|
|
@@ -6867,7 +6867,7 @@ function useCallbackRef2(initialValue, callback) {
|
|
|
6867
6867
|
ref.callback = callback;
|
|
6868
6868
|
return ref.facade;
|
|
6869
6869
|
}
|
|
6870
|
-
var useIsomorphicLayoutEffect = typeof window !== "undefined" ?
|
|
6870
|
+
var useIsomorphicLayoutEffect = typeof window !== "undefined" ? React45__namespace.useLayoutEffect : React45__namespace.useEffect;
|
|
6871
6871
|
var currentValues = /* @__PURE__ */ new WeakMap();
|
|
6872
6872
|
function useMergeRefs(refs, defaultValue) {
|
|
6873
6873
|
var callbackRef = useCallbackRef2(null, function(newValue) {
|
|
@@ -6991,7 +6991,7 @@ var SideCar = function(_a) {
|
|
|
6991
6991
|
if (!Target) {
|
|
6992
6992
|
throw new Error("Sidecar medium not found");
|
|
6993
6993
|
}
|
|
6994
|
-
return
|
|
6994
|
+
return React45__namespace.createElement(Target, __assign({}, rest));
|
|
6995
6995
|
};
|
|
6996
6996
|
SideCar.isSideCarExport = true;
|
|
6997
6997
|
function exportSidecar(medium, exported) {
|
|
@@ -7006,9 +7006,9 @@ var effectCar = createSidecarMedium();
|
|
|
7006
7006
|
var nothing = function() {
|
|
7007
7007
|
return;
|
|
7008
7008
|
};
|
|
7009
|
-
var RemoveScroll =
|
|
7010
|
-
var ref =
|
|
7011
|
-
var _a =
|
|
7009
|
+
var RemoveScroll = React45__namespace.forwardRef(function(props, parentRef) {
|
|
7010
|
+
var ref = React45__namespace.useRef(null);
|
|
7011
|
+
var _a = React45__namespace.useState({
|
|
7012
7012
|
onScrollCapture: nothing,
|
|
7013
7013
|
onWheelCapture: nothing,
|
|
7014
7014
|
onTouchMoveCapture: nothing
|
|
@@ -7017,11 +7017,11 @@ var RemoveScroll = React44__namespace.forwardRef(function(props, parentRef) {
|
|
|
7017
7017
|
var SideCar2 = sideCar;
|
|
7018
7018
|
var containerRef = useMergeRefs([ref, parentRef]);
|
|
7019
7019
|
var containerProps = __assign(__assign({}, rest), callbacks);
|
|
7020
|
-
return
|
|
7021
|
-
|
|
7020
|
+
return React45__namespace.createElement(
|
|
7021
|
+
React45__namespace.Fragment,
|
|
7022
7022
|
null,
|
|
7023
|
-
enabled &&
|
|
7024
|
-
forwardProps ?
|
|
7023
|
+
enabled && React45__namespace.createElement(SideCar2, { sideCar: effectCar, removeScrollBar, shards, noRelative, noIsolation, inert, setCallbacks, allowPinchZoom: !!allowPinchZoom, lockRef: ref, gapMode }),
|
|
7024
|
+
forwardProps ? React45__namespace.cloneElement(React45__namespace.Children.only(children), __assign(__assign({}, containerProps), { ref: containerRef })) : React45__namespace.createElement(Container, __assign({}, containerProps, { className, ref: containerRef }), children)
|
|
7025
7025
|
);
|
|
7026
7026
|
});
|
|
7027
7027
|
RemoveScroll.defaultProps = {
|
|
@@ -7090,7 +7090,7 @@ var stylesheetSingleton = function() {
|
|
|
7090
7090
|
var styleHookSingleton = function() {
|
|
7091
7091
|
var sheet = stylesheetSingleton();
|
|
7092
7092
|
return function(styles, isDynamic) {
|
|
7093
|
-
|
|
7093
|
+
React45__namespace.useEffect(function() {
|
|
7094
7094
|
sheet.add(styles);
|
|
7095
7095
|
return function() {
|
|
7096
7096
|
sheet.remove();
|
|
@@ -7164,7 +7164,7 @@ var getCurrentUseCounter = function() {
|
|
|
7164
7164
|
return isFinite(counter) ? counter : 0;
|
|
7165
7165
|
};
|
|
7166
7166
|
var useLockAttribute = function() {
|
|
7167
|
-
|
|
7167
|
+
React45__namespace.useEffect(function() {
|
|
7168
7168
|
document.body.setAttribute(lockAttribute, (getCurrentUseCounter() + 1).toString());
|
|
7169
7169
|
return function() {
|
|
7170
7170
|
var newCounter = getCurrentUseCounter() - 1;
|
|
@@ -7179,10 +7179,10 @@ var useLockAttribute = function() {
|
|
|
7179
7179
|
var RemoveScrollBar = function(_a) {
|
|
7180
7180
|
var noRelative = _a.noRelative, noImportant = _a.noImportant, _b = _a.gapMode, gapMode = _b === void 0 ? "margin" : _b;
|
|
7181
7181
|
useLockAttribute();
|
|
7182
|
-
var gap =
|
|
7182
|
+
var gap = React45__namespace.useMemo(function() {
|
|
7183
7183
|
return getGapWidth(gapMode);
|
|
7184
7184
|
}, [gapMode]);
|
|
7185
|
-
return
|
|
7185
|
+
return React45__namespace.createElement(Style, { styles: getStyles(gap, !noRelative, gapMode, !noImportant ? "!important" : "") });
|
|
7186
7186
|
};
|
|
7187
7187
|
|
|
7188
7188
|
// ../../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@19.2.2_react@19.2.2/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js
|
|
@@ -7323,16 +7323,16 @@ var generateStyle = function(id) {
|
|
|
7323
7323
|
var idCounter = 0;
|
|
7324
7324
|
var lockStack = [];
|
|
7325
7325
|
function RemoveScrollSideCar(props) {
|
|
7326
|
-
var shouldPreventQueue =
|
|
7327
|
-
var touchStartRef =
|
|
7328
|
-
var activeAxis =
|
|
7329
|
-
var id =
|
|
7330
|
-
var Style2 =
|
|
7331
|
-
var lastProps =
|
|
7332
|
-
|
|
7326
|
+
var shouldPreventQueue = React45__namespace.useRef([]);
|
|
7327
|
+
var touchStartRef = React45__namespace.useRef([0, 0]);
|
|
7328
|
+
var activeAxis = React45__namespace.useRef();
|
|
7329
|
+
var id = React45__namespace.useState(idCounter++)[0];
|
|
7330
|
+
var Style2 = React45__namespace.useState(styleSingleton)[0];
|
|
7331
|
+
var lastProps = React45__namespace.useRef(props);
|
|
7332
|
+
React45__namespace.useEffect(function() {
|
|
7333
7333
|
lastProps.current = props;
|
|
7334
7334
|
}, [props]);
|
|
7335
|
-
|
|
7335
|
+
React45__namespace.useEffect(function() {
|
|
7336
7336
|
if (props.inert) {
|
|
7337
7337
|
document.body.classList.add("block-interactivity-".concat(id));
|
|
7338
7338
|
var allow_1 = __spreadArray([props.lockRef.current], (props.shards || []).map(extractRef)).filter(Boolean);
|
|
@@ -7348,7 +7348,7 @@ function RemoveScrollSideCar(props) {
|
|
|
7348
7348
|
}
|
|
7349
7349
|
return;
|
|
7350
7350
|
}, [props.inert, props.lockRef.current, props.shards]);
|
|
7351
|
-
var shouldCancelEvent =
|
|
7351
|
+
var shouldCancelEvent = React45__namespace.useCallback(function(event, parent) {
|
|
7352
7352
|
if ("touches" in event && event.touches.length === 2 || event.type === "wheel" && event.ctrlKey) {
|
|
7353
7353
|
return !lastProps.current.allowPinchZoom;
|
|
7354
7354
|
}
|
|
@@ -7384,7 +7384,7 @@ function RemoveScrollSideCar(props) {
|
|
|
7384
7384
|
var cancelingAxis = activeAxis.current || currentAxis;
|
|
7385
7385
|
return handleScroll(cancelingAxis, parent, event, cancelingAxis === "h" ? deltaX : deltaY);
|
|
7386
7386
|
}, []);
|
|
7387
|
-
var shouldPrevent =
|
|
7387
|
+
var shouldPrevent = React45__namespace.useCallback(function(_event) {
|
|
7388
7388
|
var event = _event;
|
|
7389
7389
|
if (!lockStack.length || lockStack[lockStack.length - 1] !== Style2) {
|
|
7390
7390
|
return;
|
|
@@ -7411,7 +7411,7 @@ function RemoveScrollSideCar(props) {
|
|
|
7411
7411
|
}
|
|
7412
7412
|
}
|
|
7413
7413
|
}, []);
|
|
7414
|
-
var shouldCancel =
|
|
7414
|
+
var shouldCancel = React45__namespace.useCallback(function(name, delta, target, should) {
|
|
7415
7415
|
var event = { name, delta, target, should, shadowParent: getOutermostShadowParent(target) };
|
|
7416
7416
|
shouldPreventQueue.current.push(event);
|
|
7417
7417
|
setTimeout(function() {
|
|
@@ -7420,17 +7420,17 @@ function RemoveScrollSideCar(props) {
|
|
|
7420
7420
|
});
|
|
7421
7421
|
}, 1);
|
|
7422
7422
|
}, []);
|
|
7423
|
-
var scrollTouchStart =
|
|
7423
|
+
var scrollTouchStart = React45__namespace.useCallback(function(event) {
|
|
7424
7424
|
touchStartRef.current = getTouchXY(event);
|
|
7425
7425
|
activeAxis.current = void 0;
|
|
7426
7426
|
}, []);
|
|
7427
|
-
var scrollWheel =
|
|
7427
|
+
var scrollWheel = React45__namespace.useCallback(function(event) {
|
|
7428
7428
|
shouldCancel(event.type, getDeltaXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));
|
|
7429
7429
|
}, []);
|
|
7430
|
-
var scrollTouchMove =
|
|
7430
|
+
var scrollTouchMove = React45__namespace.useCallback(function(event) {
|
|
7431
7431
|
shouldCancel(event.type, getTouchXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));
|
|
7432
7432
|
}, []);
|
|
7433
|
-
|
|
7433
|
+
React45__namespace.useEffect(function() {
|
|
7434
7434
|
lockStack.push(Style2);
|
|
7435
7435
|
props.setCallbacks({
|
|
7436
7436
|
onScrollCapture: scrollWheel,
|
|
@@ -7450,11 +7450,11 @@ function RemoveScrollSideCar(props) {
|
|
|
7450
7450
|
};
|
|
7451
7451
|
}, []);
|
|
7452
7452
|
var removeScrollBar = props.removeScrollBar, inert = props.inert;
|
|
7453
|
-
return
|
|
7454
|
-
|
|
7453
|
+
return React45__namespace.createElement(
|
|
7454
|
+
React45__namespace.Fragment,
|
|
7455
7455
|
null,
|
|
7456
|
-
inert ?
|
|
7457
|
-
removeScrollBar ?
|
|
7456
|
+
inert ? React45__namespace.createElement(Style2, { styles: generateStyle(id) }) : null,
|
|
7457
|
+
removeScrollBar ? React45__namespace.createElement(RemoveScrollBar, { noRelative: props.noRelative, gapMode: props.gapMode }) : null
|
|
7458
7458
|
);
|
|
7459
7459
|
}
|
|
7460
7460
|
function getOutermostShadowParent(node) {
|
|
@@ -7473,8 +7473,8 @@ function getOutermostShadowParent(node) {
|
|
|
7473
7473
|
var sidecar_default = exportSidecar(effectCar, RemoveScrollSideCar);
|
|
7474
7474
|
|
|
7475
7475
|
// ../../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@19.2.2_react@19.2.2/node_modules/react-remove-scroll/dist/es2015/Combination.js
|
|
7476
|
-
var ReactRemoveScroll =
|
|
7477
|
-
return
|
|
7476
|
+
var ReactRemoveScroll = React45__namespace.forwardRef(function(props, ref) {
|
|
7477
|
+
return React45__namespace.createElement(RemoveScroll, __assign({}, props, { ref, sideCar: sidecar_default }));
|
|
7478
7478
|
});
|
|
7479
7479
|
ReactRemoveScroll.classNames = RemoveScroll.classNames;
|
|
7480
7480
|
var Combination_default = ReactRemoveScroll;
|
|
@@ -7504,11 +7504,11 @@ var [MenuRootProvider, useMenuRootContext] = createMenuContext(MENU_NAME);
|
|
|
7504
7504
|
var Menu = (props) => {
|
|
7505
7505
|
const { __scopeMenu, open = false, children, dir, onOpenChange, modal = true } = props;
|
|
7506
7506
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7507
|
-
const [content, setContent] =
|
|
7508
|
-
const isUsingKeyboardRef =
|
|
7507
|
+
const [content, setContent] = React45__namespace.useState(null);
|
|
7508
|
+
const isUsingKeyboardRef = React45__namespace.useRef(false);
|
|
7509
7509
|
const handleOpenChange = useCallbackRef(onOpenChange);
|
|
7510
7510
|
const direction = useDirection(dir);
|
|
7511
|
-
|
|
7511
|
+
React45__namespace.useEffect(() => {
|
|
7512
7512
|
const handleKeyDown = () => {
|
|
7513
7513
|
isUsingKeyboardRef.current = true;
|
|
7514
7514
|
document.addEventListener("pointerdown", handlePointer, { capture: true, once: true });
|
|
@@ -7534,7 +7534,7 @@ var Menu = (props) => {
|
|
|
7534
7534
|
MenuRootProvider,
|
|
7535
7535
|
{
|
|
7536
7536
|
scope: __scopeMenu,
|
|
7537
|
-
onClose:
|
|
7537
|
+
onClose: React45__namespace.useCallback(() => handleOpenChange(false), [handleOpenChange]),
|
|
7538
7538
|
isUsingKeyboardRef,
|
|
7539
7539
|
dir: direction,
|
|
7540
7540
|
modal,
|
|
@@ -7546,7 +7546,7 @@ var Menu = (props) => {
|
|
|
7546
7546
|
};
|
|
7547
7547
|
Menu.displayName = MENU_NAME;
|
|
7548
7548
|
var ANCHOR_NAME2 = "MenuAnchor";
|
|
7549
|
-
var MenuAnchor =
|
|
7549
|
+
var MenuAnchor = React45__namespace.forwardRef(
|
|
7550
7550
|
(props, forwardedRef) => {
|
|
7551
7551
|
const { __scopeMenu, ...anchorProps } = props;
|
|
7552
7552
|
const popperScope = usePopperScope(__scopeMenu);
|
|
@@ -7566,7 +7566,7 @@ var MenuPortal = (props) => {
|
|
|
7566
7566
|
MenuPortal.displayName = PORTAL_NAME2;
|
|
7567
7567
|
var CONTENT_NAME2 = "MenuContent";
|
|
7568
7568
|
var [MenuContentProvider, useMenuContentContext] = createMenuContext(CONTENT_NAME2);
|
|
7569
|
-
var MenuContent =
|
|
7569
|
+
var MenuContent = React45__namespace.forwardRef(
|
|
7570
7570
|
(props, forwardedRef) => {
|
|
7571
7571
|
const portalContext = usePortalContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7572
7572
|
const { forceMount = portalContext.forceMount, ...contentProps } = props;
|
|
@@ -7575,12 +7575,12 @@ var MenuContent = React44__namespace.forwardRef(
|
|
|
7575
7575
|
return /* @__PURE__ */ jsxRuntime.jsx(Collection2.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsxRuntime.jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsxRuntime.jsx(Collection2.Slot, { scope: props.__scopeMenu, children: rootContext.modal ? /* @__PURE__ */ jsxRuntime.jsx(MenuRootContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ jsxRuntime.jsx(MenuRootContentNonModal, { ...contentProps, ref: forwardedRef }) }) }) });
|
|
7576
7576
|
}
|
|
7577
7577
|
);
|
|
7578
|
-
var MenuRootContentModal =
|
|
7578
|
+
var MenuRootContentModal = React45__namespace.forwardRef(
|
|
7579
7579
|
(props, forwardedRef) => {
|
|
7580
7580
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7581
|
-
const ref =
|
|
7581
|
+
const ref = React45__namespace.useRef(null);
|
|
7582
7582
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7583
|
-
|
|
7583
|
+
React45__namespace.useEffect(() => {
|
|
7584
7584
|
const content = ref.current;
|
|
7585
7585
|
if (content) return hideOthers(content);
|
|
7586
7586
|
}, []);
|
|
@@ -7602,7 +7602,7 @@ var MenuRootContentModal = React44__namespace.forwardRef(
|
|
|
7602
7602
|
);
|
|
7603
7603
|
}
|
|
7604
7604
|
);
|
|
7605
|
-
var MenuRootContentNonModal =
|
|
7605
|
+
var MenuRootContentNonModal = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
7606
7606
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7607
7607
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7608
7608
|
MenuContentImpl,
|
|
@@ -7617,7 +7617,7 @@ var MenuRootContentNonModal = React44__namespace.forwardRef((props, forwardedRef
|
|
|
7617
7617
|
);
|
|
7618
7618
|
});
|
|
7619
7619
|
var Slot2 = createSlot2("MenuContent.ScrollLock");
|
|
7620
|
-
var MenuContentImpl =
|
|
7620
|
+
var MenuContentImpl = React45__namespace.forwardRef(
|
|
7621
7621
|
(props, forwardedRef) => {
|
|
7622
7622
|
const {
|
|
7623
7623
|
__scopeMenu,
|
|
@@ -7640,16 +7640,16 @@ var MenuContentImpl = React44__namespace.forwardRef(
|
|
|
7640
7640
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7641
7641
|
const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);
|
|
7642
7642
|
const getItems = useCollection2(__scopeMenu);
|
|
7643
|
-
const [currentItemId, setCurrentItemId] =
|
|
7644
|
-
const contentRef =
|
|
7643
|
+
const [currentItemId, setCurrentItemId] = React45__namespace.useState(null);
|
|
7644
|
+
const contentRef = React45__namespace.useRef(null);
|
|
7645
7645
|
const composedRefs = useComposedRefs(forwardedRef, contentRef, context.onContentChange);
|
|
7646
|
-
const timerRef =
|
|
7647
|
-
const searchRef =
|
|
7648
|
-
const pointerGraceTimerRef =
|
|
7649
|
-
const pointerGraceIntentRef =
|
|
7650
|
-
const pointerDirRef =
|
|
7651
|
-
const lastPointerXRef =
|
|
7652
|
-
const ScrollLockWrapper = disableOutsideScroll ? Combination_default :
|
|
7646
|
+
const timerRef = React45__namespace.useRef(0);
|
|
7647
|
+
const searchRef = React45__namespace.useRef("");
|
|
7648
|
+
const pointerGraceTimerRef = React45__namespace.useRef(0);
|
|
7649
|
+
const pointerGraceIntentRef = React45__namespace.useRef(null);
|
|
7650
|
+
const pointerDirRef = React45__namespace.useRef("right");
|
|
7651
|
+
const lastPointerXRef = React45__namespace.useRef(0);
|
|
7652
|
+
const ScrollLockWrapper = disableOutsideScroll ? Combination_default : React45__namespace.Fragment;
|
|
7653
7653
|
const scrollLockWrapperProps = disableOutsideScroll ? { as: Slot2, allowPinchZoom: true } : void 0;
|
|
7654
7654
|
const handleTypeaheadSearch = (key) => {
|
|
7655
7655
|
const search = searchRef.current + key;
|
|
@@ -7668,11 +7668,11 @@ var MenuContentImpl = React44__namespace.forwardRef(
|
|
|
7668
7668
|
setTimeout(() => newItem.focus());
|
|
7669
7669
|
}
|
|
7670
7670
|
};
|
|
7671
|
-
|
|
7671
|
+
React45__namespace.useEffect(() => {
|
|
7672
7672
|
return () => window.clearTimeout(timerRef.current);
|
|
7673
7673
|
}, []);
|
|
7674
7674
|
useFocusGuards();
|
|
7675
|
-
const isPointerMovingToSubmenu =
|
|
7675
|
+
const isPointerMovingToSubmenu = React45__namespace.useCallback((event) => {
|
|
7676
7676
|
const isMovingTowards = pointerDirRef.current === pointerGraceIntentRef.current?.side;
|
|
7677
7677
|
return isMovingTowards && isPointerInGraceArea(event, pointerGraceIntentRef.current?.area);
|
|
7678
7678
|
}, []);
|
|
@@ -7681,13 +7681,13 @@ var MenuContentImpl = React44__namespace.forwardRef(
|
|
|
7681
7681
|
{
|
|
7682
7682
|
scope: __scopeMenu,
|
|
7683
7683
|
searchRef,
|
|
7684
|
-
onItemEnter:
|
|
7684
|
+
onItemEnter: React45__namespace.useCallback(
|
|
7685
7685
|
(event) => {
|
|
7686
7686
|
if (isPointerMovingToSubmenu(event)) event.preventDefault();
|
|
7687
7687
|
},
|
|
7688
7688
|
[isPointerMovingToSubmenu]
|
|
7689
7689
|
),
|
|
7690
|
-
onItemLeave:
|
|
7690
|
+
onItemLeave: React45__namespace.useCallback(
|
|
7691
7691
|
(event) => {
|
|
7692
7692
|
if (isPointerMovingToSubmenu(event)) return;
|
|
7693
7693
|
contentRef.current?.focus();
|
|
@@ -7695,14 +7695,14 @@ var MenuContentImpl = React44__namespace.forwardRef(
|
|
|
7695
7695
|
},
|
|
7696
7696
|
[isPointerMovingToSubmenu]
|
|
7697
7697
|
),
|
|
7698
|
-
onTriggerLeave:
|
|
7698
|
+
onTriggerLeave: React45__namespace.useCallback(
|
|
7699
7699
|
(event) => {
|
|
7700
7700
|
if (isPointerMovingToSubmenu(event)) event.preventDefault();
|
|
7701
7701
|
},
|
|
7702
7702
|
[isPointerMovingToSubmenu]
|
|
7703
7703
|
),
|
|
7704
7704
|
pointerGraceTimerRef,
|
|
7705
|
-
onPointerGraceIntentChange:
|
|
7705
|
+
onPointerGraceIntentChange: React45__namespace.useCallback((intent) => {
|
|
7706
7706
|
pointerGraceIntentRef.current = intent;
|
|
7707
7707
|
}, []),
|
|
7708
7708
|
children: /* @__PURE__ */ jsxRuntime.jsx(ScrollLockWrapper, { ...scrollLockWrapperProps, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -7801,7 +7801,7 @@ var MenuContentImpl = React44__namespace.forwardRef(
|
|
|
7801
7801
|
);
|
|
7802
7802
|
MenuContent.displayName = CONTENT_NAME2;
|
|
7803
7803
|
var GROUP_NAME2 = "MenuGroup";
|
|
7804
|
-
var MenuGroup =
|
|
7804
|
+
var MenuGroup = React45__namespace.forwardRef(
|
|
7805
7805
|
(props, forwardedRef) => {
|
|
7806
7806
|
const { __scopeMenu, ...groupProps } = props;
|
|
7807
7807
|
return /* @__PURE__ */ jsxRuntime.jsx(Primitive.div, { role: "group", ...groupProps, ref: forwardedRef });
|
|
@@ -7809,7 +7809,7 @@ var MenuGroup = React44__namespace.forwardRef(
|
|
|
7809
7809
|
);
|
|
7810
7810
|
MenuGroup.displayName = GROUP_NAME2;
|
|
7811
7811
|
var LABEL_NAME = "MenuLabel";
|
|
7812
|
-
var MenuLabel =
|
|
7812
|
+
var MenuLabel = React45__namespace.forwardRef(
|
|
7813
7813
|
(props, forwardedRef) => {
|
|
7814
7814
|
const { __scopeMenu, ...labelProps } = props;
|
|
7815
7815
|
return /* @__PURE__ */ jsxRuntime.jsx(Primitive.div, { ...labelProps, ref: forwardedRef });
|
|
@@ -7818,14 +7818,14 @@ var MenuLabel = React44__namespace.forwardRef(
|
|
|
7818
7818
|
MenuLabel.displayName = LABEL_NAME;
|
|
7819
7819
|
var ITEM_NAME2 = "MenuItem";
|
|
7820
7820
|
var ITEM_SELECT = "menu.itemSelect";
|
|
7821
|
-
var MenuItem =
|
|
7821
|
+
var MenuItem = React45__namespace.forwardRef(
|
|
7822
7822
|
(props, forwardedRef) => {
|
|
7823
7823
|
const { disabled = false, onSelect, ...itemProps } = props;
|
|
7824
|
-
const ref =
|
|
7824
|
+
const ref = React45__namespace.useRef(null);
|
|
7825
7825
|
const rootContext = useMenuRootContext(ITEM_NAME2, props.__scopeMenu);
|
|
7826
7826
|
const contentContext = useMenuContentContext(ITEM_NAME2, props.__scopeMenu);
|
|
7827
7827
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7828
|
-
const isPointerDownRef =
|
|
7828
|
+
const isPointerDownRef = React45__namespace.useRef(false);
|
|
7829
7829
|
const handleSelect = () => {
|
|
7830
7830
|
const menuItem = ref.current;
|
|
7831
7831
|
if (!disabled && menuItem) {
|
|
@@ -7866,16 +7866,16 @@ var MenuItem = React44__namespace.forwardRef(
|
|
|
7866
7866
|
}
|
|
7867
7867
|
);
|
|
7868
7868
|
MenuItem.displayName = ITEM_NAME2;
|
|
7869
|
-
var MenuItemImpl =
|
|
7869
|
+
var MenuItemImpl = React45__namespace.forwardRef(
|
|
7870
7870
|
(props, forwardedRef) => {
|
|
7871
7871
|
const { __scopeMenu, disabled = false, textValue, ...itemProps } = props;
|
|
7872
7872
|
const contentContext = useMenuContentContext(ITEM_NAME2, __scopeMenu);
|
|
7873
7873
|
const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);
|
|
7874
|
-
const ref =
|
|
7874
|
+
const ref = React45__namespace.useRef(null);
|
|
7875
7875
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7876
|
-
const [isFocused, setIsFocused] =
|
|
7877
|
-
const [textContent, setTextContent] =
|
|
7878
|
-
|
|
7876
|
+
const [isFocused, setIsFocused] = React45__namespace.useState(false);
|
|
7877
|
+
const [textContent, setTextContent] = React45__namespace.useState("");
|
|
7878
|
+
React45__namespace.useEffect(() => {
|
|
7879
7879
|
const menuItem = ref.current;
|
|
7880
7880
|
if (menuItem) {
|
|
7881
7881
|
setTextContent((menuItem.textContent ?? "").trim());
|
|
@@ -7923,7 +7923,7 @@ var MenuItemImpl = React44__namespace.forwardRef(
|
|
|
7923
7923
|
}
|
|
7924
7924
|
);
|
|
7925
7925
|
var CHECKBOX_ITEM_NAME = "MenuCheckboxItem";
|
|
7926
|
-
var MenuCheckboxItem =
|
|
7926
|
+
var MenuCheckboxItem = React45__namespace.forwardRef(
|
|
7927
7927
|
(props, forwardedRef) => {
|
|
7928
7928
|
const { checked = false, onCheckedChange, ...checkboxItemProps } = props;
|
|
7929
7929
|
return /* @__PURE__ */ jsxRuntime.jsx(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -7950,7 +7950,7 @@ var [RadioGroupProvider, useRadioGroupContext] = createMenuContext(
|
|
|
7950
7950
|
{ value: void 0, onValueChange: () => {
|
|
7951
7951
|
} }
|
|
7952
7952
|
);
|
|
7953
|
-
var MenuRadioGroup =
|
|
7953
|
+
var MenuRadioGroup = React45__namespace.forwardRef(
|
|
7954
7954
|
(props, forwardedRef) => {
|
|
7955
7955
|
const { value, onValueChange, ...groupProps } = props;
|
|
7956
7956
|
const handleValueChange = useCallbackRef(onValueChange);
|
|
@@ -7959,7 +7959,7 @@ var MenuRadioGroup = React44__namespace.forwardRef(
|
|
|
7959
7959
|
);
|
|
7960
7960
|
MenuRadioGroup.displayName = RADIO_GROUP_NAME;
|
|
7961
7961
|
var RADIO_ITEM_NAME = "MenuRadioItem";
|
|
7962
|
-
var MenuRadioItem =
|
|
7962
|
+
var MenuRadioItem = React45__namespace.forwardRef(
|
|
7963
7963
|
(props, forwardedRef) => {
|
|
7964
7964
|
const { value, ...radioItemProps } = props;
|
|
7965
7965
|
const context = useRadioGroupContext(RADIO_ITEM_NAME, props.__scopeMenu);
|
|
@@ -7987,7 +7987,7 @@ var [ItemIndicatorProvider, useItemIndicatorContext] = createMenuContext(
|
|
|
7987
7987
|
ITEM_INDICATOR_NAME,
|
|
7988
7988
|
{ checked: false }
|
|
7989
7989
|
);
|
|
7990
|
-
var MenuItemIndicator =
|
|
7990
|
+
var MenuItemIndicator = React45__namespace.forwardRef(
|
|
7991
7991
|
(props, forwardedRef) => {
|
|
7992
7992
|
const { __scopeMenu, forceMount, ...itemIndicatorProps } = props;
|
|
7993
7993
|
const indicatorContext = useItemIndicatorContext(ITEM_INDICATOR_NAME, __scopeMenu);
|
|
@@ -8009,7 +8009,7 @@ var MenuItemIndicator = React44__namespace.forwardRef(
|
|
|
8009
8009
|
);
|
|
8010
8010
|
MenuItemIndicator.displayName = ITEM_INDICATOR_NAME;
|
|
8011
8011
|
var SEPARATOR_NAME = "MenuSeparator";
|
|
8012
|
-
var MenuSeparator =
|
|
8012
|
+
var MenuSeparator = React45__namespace.forwardRef(
|
|
8013
8013
|
(props, forwardedRef) => {
|
|
8014
8014
|
const { __scopeMenu, ...separatorProps } = props;
|
|
8015
8015
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8025,7 +8025,7 @@ var MenuSeparator = React44__namespace.forwardRef(
|
|
|
8025
8025
|
);
|
|
8026
8026
|
MenuSeparator.displayName = SEPARATOR_NAME;
|
|
8027
8027
|
var ARROW_NAME2 = "MenuArrow";
|
|
8028
|
-
var MenuArrow =
|
|
8028
|
+
var MenuArrow = React45__namespace.forwardRef(
|
|
8029
8029
|
(props, forwardedRef) => {
|
|
8030
8030
|
const { __scopeMenu, ...arrowProps } = props;
|
|
8031
8031
|
const popperScope = usePopperScope(__scopeMenu);
|
|
@@ -8039,10 +8039,10 @@ var MenuSub = (props) => {
|
|
|
8039
8039
|
const { __scopeMenu, children, open = false, onOpenChange } = props;
|
|
8040
8040
|
const parentMenuContext = useMenuContext(SUB_NAME, __scopeMenu);
|
|
8041
8041
|
const popperScope = usePopperScope(__scopeMenu);
|
|
8042
|
-
const [trigger, setTrigger] =
|
|
8043
|
-
const [content, setContent] =
|
|
8042
|
+
const [trigger, setTrigger] = React45__namespace.useState(null);
|
|
8043
|
+
const [content, setContent] = React45__namespace.useState(null);
|
|
8044
8044
|
const handleOpenChange = useCallbackRef(onOpenChange);
|
|
8045
|
-
|
|
8045
|
+
React45__namespace.useEffect(() => {
|
|
8046
8046
|
if (parentMenuContext.open === false) handleOpenChange(false);
|
|
8047
8047
|
return () => handleOpenChange(false);
|
|
8048
8048
|
}, [parentMenuContext.open, handleOpenChange]);
|
|
@@ -8070,21 +8070,21 @@ var MenuSub = (props) => {
|
|
|
8070
8070
|
};
|
|
8071
8071
|
MenuSub.displayName = SUB_NAME;
|
|
8072
8072
|
var SUB_TRIGGER_NAME = "MenuSubTrigger";
|
|
8073
|
-
var MenuSubTrigger =
|
|
8073
|
+
var MenuSubTrigger = React45__namespace.forwardRef(
|
|
8074
8074
|
(props, forwardedRef) => {
|
|
8075
8075
|
const context = useMenuContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
8076
8076
|
const rootContext = useMenuRootContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
8077
8077
|
const subContext = useMenuSubContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
8078
8078
|
const contentContext = useMenuContentContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
8079
|
-
const openTimerRef =
|
|
8079
|
+
const openTimerRef = React45__namespace.useRef(null);
|
|
8080
8080
|
const { pointerGraceTimerRef, onPointerGraceIntentChange } = contentContext;
|
|
8081
8081
|
const scope = { __scopeMenu: props.__scopeMenu };
|
|
8082
|
-
const clearOpenTimer =
|
|
8082
|
+
const clearOpenTimer = React45__namespace.useCallback(() => {
|
|
8083
8083
|
if (openTimerRef.current) window.clearTimeout(openTimerRef.current);
|
|
8084
8084
|
openTimerRef.current = null;
|
|
8085
8085
|
}, []);
|
|
8086
|
-
|
|
8087
|
-
|
|
8086
|
+
React45__namespace.useEffect(() => clearOpenTimer, [clearOpenTimer]);
|
|
8087
|
+
React45__namespace.useEffect(() => {
|
|
8088
8088
|
const pointerGraceTimer = pointerGraceTimerRef.current;
|
|
8089
8089
|
return () => {
|
|
8090
8090
|
window.clearTimeout(pointerGraceTimer);
|
|
@@ -8171,14 +8171,14 @@ var MenuSubTrigger = React44__namespace.forwardRef(
|
|
|
8171
8171
|
);
|
|
8172
8172
|
MenuSubTrigger.displayName = SUB_TRIGGER_NAME;
|
|
8173
8173
|
var SUB_CONTENT_NAME = "MenuSubContent";
|
|
8174
|
-
var MenuSubContent =
|
|
8174
|
+
var MenuSubContent = React45__namespace.forwardRef(
|
|
8175
8175
|
(props, forwardedRef) => {
|
|
8176
8176
|
const portalContext = usePortalContext(CONTENT_NAME2, props.__scopeMenu);
|
|
8177
8177
|
const { forceMount = portalContext.forceMount, ...subContentProps } = props;
|
|
8178
8178
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
8179
8179
|
const rootContext = useMenuRootContext(CONTENT_NAME2, props.__scopeMenu);
|
|
8180
8180
|
const subContext = useMenuSubContext(SUB_CONTENT_NAME, props.__scopeMenu);
|
|
8181
|
-
const ref =
|
|
8181
|
+
const ref = React45__namespace.useRef(null);
|
|
8182
8182
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
8183
8183
|
return /* @__PURE__ */ jsxRuntime.jsx(Collection2.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsxRuntime.jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsxRuntime.jsx(Collection2.Slot, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8184
8184
|
MenuContentImpl,
|
|
@@ -8307,7 +8307,7 @@ var DropdownMenu = (props) => {
|
|
|
8307
8307
|
modal = true
|
|
8308
8308
|
} = props;
|
|
8309
8309
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8310
|
-
const triggerRef =
|
|
8310
|
+
const triggerRef = React45__namespace.useRef(null);
|
|
8311
8311
|
const [open, setOpen] = useControllableState({
|
|
8312
8312
|
prop: openProp,
|
|
8313
8313
|
defaultProp: defaultOpen ?? false,
|
|
@@ -8323,7 +8323,7 @@ var DropdownMenu = (props) => {
|
|
|
8323
8323
|
contentId: useId(),
|
|
8324
8324
|
open,
|
|
8325
8325
|
onOpenChange: setOpen,
|
|
8326
|
-
onOpenToggle:
|
|
8326
|
+
onOpenToggle: React45__namespace.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),
|
|
8327
8327
|
modal,
|
|
8328
8328
|
children: /* @__PURE__ */ jsxRuntime.jsx(Root32, { ...menuScope, open, onOpenChange: setOpen, dir, modal, children })
|
|
8329
8329
|
}
|
|
@@ -8331,7 +8331,7 @@ var DropdownMenu = (props) => {
|
|
|
8331
8331
|
};
|
|
8332
8332
|
DropdownMenu.displayName = DROPDOWN_MENU_NAME;
|
|
8333
8333
|
var TRIGGER_NAME = "DropdownMenuTrigger";
|
|
8334
|
-
var DropdownMenuTrigger =
|
|
8334
|
+
var DropdownMenuTrigger = React45__namespace.forwardRef(
|
|
8335
8335
|
(props, forwardedRef) => {
|
|
8336
8336
|
const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;
|
|
8337
8337
|
const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);
|
|
@@ -8374,12 +8374,12 @@ var DropdownMenuPortal = (props) => {
|
|
|
8374
8374
|
};
|
|
8375
8375
|
DropdownMenuPortal.displayName = PORTAL_NAME3;
|
|
8376
8376
|
var CONTENT_NAME3 = "DropdownMenuContent";
|
|
8377
|
-
var DropdownMenuContent =
|
|
8377
|
+
var DropdownMenuContent = React45__namespace.forwardRef(
|
|
8378
8378
|
(props, forwardedRef) => {
|
|
8379
8379
|
const { __scopeDropdownMenu, ...contentProps } = props;
|
|
8380
8380
|
const context = useDropdownMenuContext(CONTENT_NAME3, __scopeDropdownMenu);
|
|
8381
8381
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8382
|
-
const hasInteractedOutsideRef =
|
|
8382
|
+
const hasInteractedOutsideRef = React45__namespace.useRef(false);
|
|
8383
8383
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8384
8384
|
Content2,
|
|
8385
8385
|
{
|
|
@@ -8416,7 +8416,7 @@ var DropdownMenuContent = React44__namespace.forwardRef(
|
|
|
8416
8416
|
);
|
|
8417
8417
|
DropdownMenuContent.displayName = CONTENT_NAME3;
|
|
8418
8418
|
var GROUP_NAME3 = "DropdownMenuGroup";
|
|
8419
|
-
var DropdownMenuGroup =
|
|
8419
|
+
var DropdownMenuGroup = React45__namespace.forwardRef(
|
|
8420
8420
|
(props, forwardedRef) => {
|
|
8421
8421
|
const { __scopeDropdownMenu, ...groupProps } = props;
|
|
8422
8422
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
@@ -8425,7 +8425,7 @@ var DropdownMenuGroup = React44__namespace.forwardRef(
|
|
|
8425
8425
|
);
|
|
8426
8426
|
DropdownMenuGroup.displayName = GROUP_NAME3;
|
|
8427
8427
|
var LABEL_NAME2 = "DropdownMenuLabel";
|
|
8428
|
-
var DropdownMenuLabel =
|
|
8428
|
+
var DropdownMenuLabel = React45__namespace.forwardRef(
|
|
8429
8429
|
(props, forwardedRef) => {
|
|
8430
8430
|
const { __scopeDropdownMenu, ...labelProps } = props;
|
|
8431
8431
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
@@ -8434,7 +8434,7 @@ var DropdownMenuLabel = React44__namespace.forwardRef(
|
|
|
8434
8434
|
);
|
|
8435
8435
|
DropdownMenuLabel.displayName = LABEL_NAME2;
|
|
8436
8436
|
var ITEM_NAME3 = "DropdownMenuItem";
|
|
8437
|
-
var DropdownMenuItem =
|
|
8437
|
+
var DropdownMenuItem = React45__namespace.forwardRef(
|
|
8438
8438
|
(props, forwardedRef) => {
|
|
8439
8439
|
const { __scopeDropdownMenu, ...itemProps } = props;
|
|
8440
8440
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
@@ -8443,42 +8443,42 @@ var DropdownMenuItem = React44__namespace.forwardRef(
|
|
|
8443
8443
|
);
|
|
8444
8444
|
DropdownMenuItem.displayName = ITEM_NAME3;
|
|
8445
8445
|
var CHECKBOX_ITEM_NAME2 = "DropdownMenuCheckboxItem";
|
|
8446
|
-
var DropdownMenuCheckboxItem =
|
|
8446
|
+
var DropdownMenuCheckboxItem = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8447
8447
|
const { __scopeDropdownMenu, ...checkboxItemProps } = props;
|
|
8448
8448
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8449
8449
|
return /* @__PURE__ */ jsxRuntime.jsx(CheckboxItem, { ...menuScope, ...checkboxItemProps, ref: forwardedRef });
|
|
8450
8450
|
});
|
|
8451
8451
|
DropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME2;
|
|
8452
8452
|
var RADIO_GROUP_NAME2 = "DropdownMenuRadioGroup";
|
|
8453
|
-
var DropdownMenuRadioGroup =
|
|
8453
|
+
var DropdownMenuRadioGroup = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8454
8454
|
const { __scopeDropdownMenu, ...radioGroupProps } = props;
|
|
8455
8455
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8456
8456
|
return /* @__PURE__ */ jsxRuntime.jsx(RadioGroup, { ...menuScope, ...radioGroupProps, ref: forwardedRef });
|
|
8457
8457
|
});
|
|
8458
8458
|
DropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME2;
|
|
8459
8459
|
var RADIO_ITEM_NAME2 = "DropdownMenuRadioItem";
|
|
8460
|
-
var DropdownMenuRadioItem =
|
|
8460
|
+
var DropdownMenuRadioItem = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8461
8461
|
const { __scopeDropdownMenu, ...radioItemProps } = props;
|
|
8462
8462
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8463
8463
|
return /* @__PURE__ */ jsxRuntime.jsx(RadioItem, { ...menuScope, ...radioItemProps, ref: forwardedRef });
|
|
8464
8464
|
});
|
|
8465
8465
|
DropdownMenuRadioItem.displayName = RADIO_ITEM_NAME2;
|
|
8466
8466
|
var INDICATOR_NAME = "DropdownMenuItemIndicator";
|
|
8467
|
-
var DropdownMenuItemIndicator =
|
|
8467
|
+
var DropdownMenuItemIndicator = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8468
8468
|
const { __scopeDropdownMenu, ...itemIndicatorProps } = props;
|
|
8469
8469
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8470
8470
|
return /* @__PURE__ */ jsxRuntime.jsx(ItemIndicator, { ...menuScope, ...itemIndicatorProps, ref: forwardedRef });
|
|
8471
8471
|
});
|
|
8472
8472
|
DropdownMenuItemIndicator.displayName = INDICATOR_NAME;
|
|
8473
8473
|
var SEPARATOR_NAME2 = "DropdownMenuSeparator";
|
|
8474
|
-
var DropdownMenuSeparator =
|
|
8474
|
+
var DropdownMenuSeparator = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8475
8475
|
const { __scopeDropdownMenu, ...separatorProps } = props;
|
|
8476
8476
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8477
8477
|
return /* @__PURE__ */ jsxRuntime.jsx(Separator, { ...menuScope, ...separatorProps, ref: forwardedRef });
|
|
8478
8478
|
});
|
|
8479
8479
|
DropdownMenuSeparator.displayName = SEPARATOR_NAME2;
|
|
8480
8480
|
var ARROW_NAME3 = "DropdownMenuArrow";
|
|
8481
|
-
var DropdownMenuArrow =
|
|
8481
|
+
var DropdownMenuArrow = React45__namespace.forwardRef(
|
|
8482
8482
|
(props, forwardedRef) => {
|
|
8483
8483
|
const { __scopeDropdownMenu, ...arrowProps } = props;
|
|
8484
8484
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
@@ -8498,14 +8498,14 @@ var DropdownMenuSub = (props) => {
|
|
|
8498
8498
|
return /* @__PURE__ */ jsxRuntime.jsx(Sub, { ...menuScope, open, onOpenChange: setOpen, children });
|
|
8499
8499
|
};
|
|
8500
8500
|
var SUB_TRIGGER_NAME2 = "DropdownMenuSubTrigger";
|
|
8501
|
-
var DropdownMenuSubTrigger =
|
|
8501
|
+
var DropdownMenuSubTrigger = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8502
8502
|
const { __scopeDropdownMenu, ...subTriggerProps } = props;
|
|
8503
8503
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8504
8504
|
return /* @__PURE__ */ jsxRuntime.jsx(SubTrigger, { ...menuScope, ...subTriggerProps, ref: forwardedRef });
|
|
8505
8505
|
});
|
|
8506
8506
|
DropdownMenuSubTrigger.displayName = SUB_TRIGGER_NAME2;
|
|
8507
8507
|
var SUB_CONTENT_NAME2 = "DropdownMenuSubContent";
|
|
8508
|
-
var DropdownMenuSubContent =
|
|
8508
|
+
var DropdownMenuSubContent = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
8509
8509
|
const { __scopeDropdownMenu, ...subContentProps } = props;
|
|
8510
8510
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8511
8511
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8565,7 +8565,7 @@ var defaultAttributes = {
|
|
|
8565
8565
|
};
|
|
8566
8566
|
|
|
8567
8567
|
// ../../node_modules/.pnpm/lucide-react@0.476.0_react@19.2.2/node_modules/lucide-react/dist/esm/Icon.js
|
|
8568
|
-
var Icon =
|
|
8568
|
+
var Icon = React45.forwardRef(
|
|
8569
8569
|
({
|
|
8570
8570
|
color = "currentColor",
|
|
8571
8571
|
size: size4 = 24,
|
|
@@ -8576,7 +8576,7 @@ var Icon = React44.forwardRef(
|
|
|
8576
8576
|
iconNode,
|
|
8577
8577
|
...rest
|
|
8578
8578
|
}, ref) => {
|
|
8579
|
-
return
|
|
8579
|
+
return React45.createElement(
|
|
8580
8580
|
"svg",
|
|
8581
8581
|
{
|
|
8582
8582
|
ref,
|
|
@@ -8589,7 +8589,7 @@ var Icon = React44.forwardRef(
|
|
|
8589
8589
|
...rest
|
|
8590
8590
|
},
|
|
8591
8591
|
[
|
|
8592
|
-
...iconNode.map(([tag, attrs]) =>
|
|
8592
|
+
...iconNode.map(([tag, attrs]) => React45.createElement(tag, attrs)),
|
|
8593
8593
|
...Array.isArray(children) ? children : [children]
|
|
8594
8594
|
]
|
|
8595
8595
|
);
|
|
@@ -8598,8 +8598,8 @@ var Icon = React44.forwardRef(
|
|
|
8598
8598
|
|
|
8599
8599
|
// ../../node_modules/.pnpm/lucide-react@0.476.0_react@19.2.2/node_modules/lucide-react/dist/esm/createLucideIcon.js
|
|
8600
8600
|
var createLucideIcon = (iconName, iconNode) => {
|
|
8601
|
-
const Component =
|
|
8602
|
-
({ className, ...props }, ref) =>
|
|
8601
|
+
const Component = React45.forwardRef(
|
|
8602
|
+
({ className, ...props }, ref) => React45.createElement(Icon, {
|
|
8603
8603
|
ref,
|
|
8604
8604
|
iconNode,
|
|
8605
8605
|
className: mergeClasses(`lucide-${toKebabCase(iconName)}`, className),
|
|
@@ -8634,17 +8634,17 @@ var Circle = createLucideIcon("Circle", __iconNode5);
|
|
|
8634
8634
|
function DropdownMenu2({
|
|
8635
8635
|
...props
|
|
8636
8636
|
}) {
|
|
8637
|
-
return /* @__PURE__ */
|
|
8637
|
+
return /* @__PURE__ */ React45__namespace.createElement(Root23, { "data-slot": "dropdown-menu", ...props });
|
|
8638
8638
|
}
|
|
8639
8639
|
function DropdownMenuPortal2({
|
|
8640
8640
|
...props
|
|
8641
8641
|
}) {
|
|
8642
|
-
return /* @__PURE__ */
|
|
8642
|
+
return /* @__PURE__ */ React45__namespace.createElement(Portal22, { "data-slot": "dropdown-menu-portal", ...props });
|
|
8643
8643
|
}
|
|
8644
8644
|
function DropdownMenuTrigger2({
|
|
8645
8645
|
...props
|
|
8646
8646
|
}) {
|
|
8647
|
-
return /* @__PURE__ */
|
|
8647
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8648
8648
|
Trigger,
|
|
8649
8649
|
{
|
|
8650
8650
|
"data-slot": "dropdown-menu-trigger",
|
|
@@ -8657,7 +8657,7 @@ function DropdownMenuContent2({
|
|
|
8657
8657
|
sideOffset = 4,
|
|
8658
8658
|
...props
|
|
8659
8659
|
}) {
|
|
8660
|
-
return /* @__PURE__ */
|
|
8660
|
+
return /* @__PURE__ */ React45__namespace.createElement(Portal22, null, /* @__PURE__ */ React45__namespace.createElement(
|
|
8661
8661
|
Content22,
|
|
8662
8662
|
{
|
|
8663
8663
|
"data-slot": "dropdown-menu-content",
|
|
@@ -8674,30 +8674,30 @@ function DropdownMenuClose({
|
|
|
8674
8674
|
className,
|
|
8675
8675
|
...props
|
|
8676
8676
|
}) {
|
|
8677
|
-
return /* @__PURE__ */
|
|
8677
|
+
return /* @__PURE__ */ React45__namespace.createElement(Item22, { "data-slot": "dropdown-menu-close", className: "hidden", ...props });
|
|
8678
8678
|
}
|
|
8679
8679
|
function DropdownMenuGroup2({
|
|
8680
8680
|
...props
|
|
8681
8681
|
}) {
|
|
8682
|
-
return /* @__PURE__ */
|
|
8682
|
+
return /* @__PURE__ */ React45__namespace.createElement(Group2, { "data-slot": "dropdown-menu-group", ...props });
|
|
8683
8683
|
}
|
|
8684
8684
|
function ConfirmationDropdownMenuItem({
|
|
8685
8685
|
...props
|
|
8686
8686
|
}) {
|
|
8687
8687
|
const { onClick: originalOnClick, ...rest } = props;
|
|
8688
|
-
const [isConfirming, setIsConfirming] =
|
|
8689
|
-
return !isConfirming ? /* @__PURE__ */
|
|
8688
|
+
const [isConfirming, setIsConfirming] = React45__namespace.useState(false);
|
|
8689
|
+
return !isConfirming ? /* @__PURE__ */ React45__namespace.createElement(DropdownMenuItem2, { ...rest, onClick: (e) => {
|
|
8690
8690
|
setIsConfirming(true);
|
|
8691
8691
|
e.preventDefault();
|
|
8692
8692
|
e.stopPropagation();
|
|
8693
|
-
} }) : /* @__PURE__ */
|
|
8693
|
+
} }) : /* @__PURE__ */ React45__namespace.createElement(DropdownMenuItem2, { ...rest, onClick: (e) => {
|
|
8694
8694
|
if (originalOnClick) {
|
|
8695
8695
|
setIsConfirming(false);
|
|
8696
8696
|
originalOnClick(e);
|
|
8697
8697
|
e.preventDefault();
|
|
8698
8698
|
e.stopPropagation();
|
|
8699
8699
|
}
|
|
8700
|
-
} }, /* @__PURE__ */
|
|
8700
|
+
} }, /* @__PURE__ */ React45__namespace.createElement("div", { className: "flex flex-row gap-2 items-center" }, /* @__PURE__ */ React45__namespace.createElement("div", { className: "text-destructive" }, "Are you sure ?")));
|
|
8701
8701
|
}
|
|
8702
8702
|
function DropdownMenuItem2({
|
|
8703
8703
|
className,
|
|
@@ -8705,7 +8705,7 @@ function DropdownMenuItem2({
|
|
|
8705
8705
|
variant = "default",
|
|
8706
8706
|
...props
|
|
8707
8707
|
}) {
|
|
8708
|
-
return /* @__PURE__ */
|
|
8708
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8709
8709
|
Item22,
|
|
8710
8710
|
{
|
|
8711
8711
|
"data-slot": "dropdown-menu-item",
|
|
@@ -8725,7 +8725,7 @@ function DropdownMenuCheckboxItem2({
|
|
|
8725
8725
|
checked,
|
|
8726
8726
|
...props
|
|
8727
8727
|
}) {
|
|
8728
|
-
return /* @__PURE__ */
|
|
8728
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8729
8729
|
CheckboxItem2,
|
|
8730
8730
|
{
|
|
8731
8731
|
"data-slot": "dropdown-menu-checkbox-item",
|
|
@@ -8736,14 +8736,14 @@ function DropdownMenuCheckboxItem2({
|
|
|
8736
8736
|
checked,
|
|
8737
8737
|
...props
|
|
8738
8738
|
},
|
|
8739
|
-
/* @__PURE__ */
|
|
8739
|
+
/* @__PURE__ */ React45__namespace.createElement("span", { className: "uii:pointer-events-none uii:absolute uii:left-2 uii:flex uii:size-3.5 uii:items-center uii:justify-center" }, /* @__PURE__ */ React45__namespace.createElement(ItemIndicator2, null, /* @__PURE__ */ React45__namespace.createElement(Check, { className: "uii:size-4" }))),
|
|
8740
8740
|
children
|
|
8741
8741
|
);
|
|
8742
8742
|
}
|
|
8743
8743
|
function DropdownMenuRadioGroup2({
|
|
8744
8744
|
...props
|
|
8745
8745
|
}) {
|
|
8746
|
-
return /* @__PURE__ */
|
|
8746
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8747
8747
|
RadioGroup2,
|
|
8748
8748
|
{
|
|
8749
8749
|
"data-slot": "dropdown-menu-radio-group",
|
|
@@ -8756,7 +8756,7 @@ function DropdownMenuRadioItem2({
|
|
|
8756
8756
|
children,
|
|
8757
8757
|
...props
|
|
8758
8758
|
}) {
|
|
8759
|
-
return /* @__PURE__ */
|
|
8759
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8760
8760
|
RadioItem2,
|
|
8761
8761
|
{
|
|
8762
8762
|
"data-slot": "dropdown-menu-radio-item",
|
|
@@ -8766,7 +8766,7 @@ function DropdownMenuRadioItem2({
|
|
|
8766
8766
|
),
|
|
8767
8767
|
...props
|
|
8768
8768
|
},
|
|
8769
|
-
/* @__PURE__ */
|
|
8769
|
+
/* @__PURE__ */ React45__namespace.createElement("span", { className: "uii:pointer-events-none uii:absolute uii:left-2 uii:flex uii:size-3.5 uii:items-center uii:justify-center" }, /* @__PURE__ */ React45__namespace.createElement(ItemIndicator2, null, /* @__PURE__ */ React45__namespace.createElement(Circle, { className: "uii:size-2 uii:fill-current" }))),
|
|
8770
8770
|
children
|
|
8771
8771
|
);
|
|
8772
8772
|
}
|
|
@@ -8775,7 +8775,7 @@ function DropdownMenuLabel2({
|
|
|
8775
8775
|
inset,
|
|
8776
8776
|
...props
|
|
8777
8777
|
}) {
|
|
8778
|
-
return /* @__PURE__ */
|
|
8778
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8779
8779
|
Label2,
|
|
8780
8780
|
{
|
|
8781
8781
|
"data-slot": "dropdown-menu-label",
|
|
@@ -8792,7 +8792,7 @@ function DropdownMenuSeparator2({
|
|
|
8792
8792
|
className,
|
|
8793
8793
|
...props
|
|
8794
8794
|
}) {
|
|
8795
|
-
return /* @__PURE__ */
|
|
8795
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8796
8796
|
Separator2,
|
|
8797
8797
|
{
|
|
8798
8798
|
"data-slot": "dropdown-menu-separator",
|
|
@@ -8805,7 +8805,7 @@ function DropdownMenuShortcut({
|
|
|
8805
8805
|
className,
|
|
8806
8806
|
...props
|
|
8807
8807
|
}) {
|
|
8808
|
-
return /* @__PURE__ */
|
|
8808
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8809
8809
|
"span",
|
|
8810
8810
|
{
|
|
8811
8811
|
"data-slot": "dropdown-menu-shortcut",
|
|
@@ -8820,7 +8820,7 @@ function DropdownMenuShortcut({
|
|
|
8820
8820
|
function DropdownMenuSub2({
|
|
8821
8821
|
...props
|
|
8822
8822
|
}) {
|
|
8823
|
-
return /* @__PURE__ */
|
|
8823
|
+
return /* @__PURE__ */ React45__namespace.createElement(Sub2, { "data-slot": "dropdown-menu-sub", ...props });
|
|
8824
8824
|
}
|
|
8825
8825
|
function DropdownMenuSubTrigger2({
|
|
8826
8826
|
className,
|
|
@@ -8828,7 +8828,7 @@ function DropdownMenuSubTrigger2({
|
|
|
8828
8828
|
children,
|
|
8829
8829
|
...props
|
|
8830
8830
|
}) {
|
|
8831
|
-
return /* @__PURE__ */
|
|
8831
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8832
8832
|
SubTrigger2,
|
|
8833
8833
|
{
|
|
8834
8834
|
"data-slot": "dropdown-menu-sub-trigger",
|
|
@@ -8840,14 +8840,14 @@ function DropdownMenuSubTrigger2({
|
|
|
8840
8840
|
...props
|
|
8841
8841
|
},
|
|
8842
8842
|
children,
|
|
8843
|
-
/* @__PURE__ */
|
|
8843
|
+
/* @__PURE__ */ React45__namespace.createElement(ChevronRight, { className: "uii:ml-auto uii:size-4" })
|
|
8844
8844
|
);
|
|
8845
8845
|
}
|
|
8846
8846
|
function DropdownMenuSubContent2({
|
|
8847
8847
|
className,
|
|
8848
8848
|
...props
|
|
8849
8849
|
}) {
|
|
8850
|
-
return /* @__PURE__ */
|
|
8850
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
8851
8851
|
SubContent2,
|
|
8852
8852
|
{
|
|
8853
8853
|
"data-slot": "dropdown-menu-sub-content",
|
|
@@ -8905,10 +8905,10 @@ __export(fields_exports, {
|
|
|
8905
8905
|
useTemplateFieldContext: () => useTemplateFieldContext,
|
|
8906
8906
|
useTriggerLayoutUpdate: () => useTriggerLayoutUpdate
|
|
8907
8907
|
});
|
|
8908
|
-
var DevContext =
|
|
8908
|
+
var DevContext = React45.createContext(null);
|
|
8909
8909
|
function useResolvedExpectedType(expectedType, devCtx) {
|
|
8910
8910
|
const inferredTypes = devCtx?.inferredTypes;
|
|
8911
|
-
return
|
|
8911
|
+
return React45__namespace.useMemo(() => {
|
|
8912
8912
|
if (!expectedType) return "any";
|
|
8913
8913
|
if (!expectedType.startsWith("$infer<")) {
|
|
8914
8914
|
return expectedType;
|
|
@@ -8954,31 +8954,24 @@ function Input({
|
|
|
8954
8954
|
caseSensitive = false,
|
|
8955
8955
|
onCaseSensitiveChange
|
|
8956
8956
|
}) {
|
|
8957
|
-
const devCtx =
|
|
8957
|
+
const devCtx = React45.useContext(DevContext);
|
|
8958
8958
|
const resolvedExpectedType = useResolvedExpectedType(expectedType, devCtx);
|
|
8959
|
-
const displayValue =
|
|
8959
|
+
const displayValue = React45__namespace.useMemo(() => {
|
|
8960
8960
|
if (value != null && typeof value === "object" && "expression" in value) {
|
|
8961
8961
|
return String(value.expression ?? "");
|
|
8962
8962
|
}
|
|
8963
8963
|
return String(value ?? "");
|
|
8964
8964
|
}, [value]);
|
|
8965
|
-
const isExpression =
|
|
8965
|
+
const isExpression = React45__namespace.useMemo(() => {
|
|
8966
8966
|
return value != null && typeof value === "object" && "expression" in value;
|
|
8967
8967
|
}, [value]);
|
|
8968
|
-
const handleChange =
|
|
8969
|
-
|
|
8970
|
-
|
|
8971
|
-
|
|
8972
|
-
expression: newValue,
|
|
8973
|
-
type: "expression"
|
|
8974
|
-
});
|
|
8975
|
-
} else {
|
|
8976
|
-
onChange(newValue);
|
|
8977
|
-
}
|
|
8978
|
-
}, [onChange]);
|
|
8968
|
+
const handleChange = React45__namespace.useCallback(
|
|
8969
|
+
(e) => onChange(e.target.value),
|
|
8970
|
+
[onChange]
|
|
8971
|
+
);
|
|
8979
8972
|
const showError = hasRequiredError || required && !displayValue;
|
|
8980
8973
|
const isWaiting = resolvedExpectedType.startsWith("Waiting for:") || resolvedExpectedType.startsWith("Subscribing to:");
|
|
8981
|
-
return /* @__PURE__ */
|
|
8974
|
+
return /* @__PURE__ */ React45__namespace.createElement("div", { className: cn("uii:mb-2", className) }, /* @__PURE__ */ React45__namespace.createElement("div", { className: "uii:flex uii:items-center uii:gap-2 uii:mt-2" }, /* @__PURE__ */ React45__namespace.createElement(
|
|
8982
8975
|
"label",
|
|
8983
8976
|
{
|
|
8984
8977
|
htmlFor: fieldName,
|
|
@@ -8986,7 +8979,7 @@ function Input({
|
|
|
8986
8979
|
},
|
|
8987
8980
|
label,
|
|
8988
8981
|
":"
|
|
8989
|
-
), resolvedExpectedType !== "$.interface.timer" && /* @__PURE__ */
|
|
8982
|
+
), resolvedExpectedType !== "$.interface.timer" && /* @__PURE__ */ React45__namespace.createElement(
|
|
8990
8983
|
"span",
|
|
8991
8984
|
{
|
|
8992
8985
|
className: cn(
|
|
@@ -8996,7 +8989,7 @@ function Input({
|
|
|
8996
8989
|
title: resolvedExpectedType
|
|
8997
8990
|
},
|
|
8998
8991
|
resolvedExpectedType
|
|
8999
|
-
), showError && /* @__PURE__ */
|
|
8992
|
+
), showError && /* @__PURE__ */ React45__namespace.createElement("span", { className: "uii:-mt-2 uii:inline-flex uii:px-1 uii:py-0.5 uii:bg-red-100 uii:text-red-600 uii:rounded-sm uii:text-[10px] uii:font-medium" }, "Required"), showCaseSensitivity && onCaseSensitiveChange && /* @__PURE__ */ React45__namespace.createElement(
|
|
9000
8993
|
"button",
|
|
9001
8994
|
{
|
|
9002
8995
|
type: "button",
|
|
@@ -9008,7 +9001,7 @@ function Input({
|
|
|
9008
9001
|
)
|
|
9009
9002
|
},
|
|
9010
9003
|
"Aa"
|
|
9011
|
-
)), /* @__PURE__ */
|
|
9004
|
+
)), /* @__PURE__ */ React45__namespace.createElement("div", { className: "uii:mt-0.5" }, /* @__PURE__ */ React45__namespace.createElement(
|
|
9012
9005
|
"input",
|
|
9013
9006
|
{
|
|
9014
9007
|
id: fieldName,
|
|
@@ -9036,8 +9029,8 @@ function clamp2(value, [min2, max2]) {
|
|
|
9036
9029
|
return Math.min(max2, Math.max(min2, value));
|
|
9037
9030
|
}
|
|
9038
9031
|
function usePrevious(value) {
|
|
9039
|
-
const ref =
|
|
9040
|
-
return
|
|
9032
|
+
const ref = React45__namespace.useRef({ value, previous: value });
|
|
9033
|
+
return React45__namespace.useMemo(() => {
|
|
9041
9034
|
if (ref.current.value !== value) {
|
|
9042
9035
|
ref.current.previous = ref.current.value;
|
|
9043
9036
|
ref.current.value = value;
|
|
@@ -9059,7 +9052,7 @@ var VISUALLY_HIDDEN_STYLES = Object.freeze({
|
|
|
9059
9052
|
wordWrap: "normal"
|
|
9060
9053
|
});
|
|
9061
9054
|
var NAME3 = "VisuallyHidden";
|
|
9062
|
-
var VisuallyHidden =
|
|
9055
|
+
var VisuallyHidden = React45__namespace.forwardRef(
|
|
9063
9056
|
(props, forwardedRef) => {
|
|
9064
9057
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
9065
9058
|
Primitive.span,
|
|
@@ -9101,9 +9094,9 @@ var Select = (props) => {
|
|
|
9101
9094
|
form
|
|
9102
9095
|
} = props;
|
|
9103
9096
|
const popperScope = usePopperScope2(__scopeSelect);
|
|
9104
|
-
const [trigger, setTrigger] =
|
|
9105
|
-
const [valueNode, setValueNode] =
|
|
9106
|
-
const [valueNodeHasChildren, setValueNodeHasChildren] =
|
|
9097
|
+
const [trigger, setTrigger] = React45__namespace.useState(null);
|
|
9098
|
+
const [valueNode, setValueNode] = React45__namespace.useState(null);
|
|
9099
|
+
const [valueNodeHasChildren, setValueNodeHasChildren] = React45__namespace.useState(false);
|
|
9107
9100
|
const direction = useDirection(dir);
|
|
9108
9101
|
const [open, setOpen] = useControllableState({
|
|
9109
9102
|
prop: openProp,
|
|
@@ -9117,9 +9110,9 @@ var Select = (props) => {
|
|
|
9117
9110
|
onChange: onValueChange,
|
|
9118
9111
|
caller: SELECT_NAME
|
|
9119
9112
|
});
|
|
9120
|
-
const triggerPointerDownPosRef =
|
|
9113
|
+
const triggerPointerDownPosRef = React45__namespace.useRef(null);
|
|
9121
9114
|
const isFormControl = trigger ? form || !!trigger.closest("form") : true;
|
|
9122
|
-
const [nativeOptionsSet, setNativeOptionsSet] =
|
|
9115
|
+
const [nativeOptionsSet, setNativeOptionsSet] = React45__namespace.useState(/* @__PURE__ */ new Set());
|
|
9123
9116
|
const nativeSelectKey = Array.from(nativeOptionsSet).map((option) => option.props.value).join(";");
|
|
9124
9117
|
return /* @__PURE__ */ jsxRuntime.jsx(Root22, { ...popperScope, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
9125
9118
|
SelectProvider,
|
|
@@ -9145,10 +9138,10 @@ var Select = (props) => {
|
|
|
9145
9138
|
SelectNativeOptionsProvider,
|
|
9146
9139
|
{
|
|
9147
9140
|
scope: props.__scopeSelect,
|
|
9148
|
-
onNativeOptionAdd:
|
|
9141
|
+
onNativeOptionAdd: React45__namespace.useCallback((option) => {
|
|
9149
9142
|
setNativeOptionsSet((prev) => new Set(prev).add(option));
|
|
9150
9143
|
}, []),
|
|
9151
|
-
onNativeOptionRemove:
|
|
9144
|
+
onNativeOptionRemove: React45__namespace.useCallback((option) => {
|
|
9152
9145
|
setNativeOptionsSet((prev) => {
|
|
9153
9146
|
const optionsSet = new Set(prev);
|
|
9154
9147
|
optionsSet.delete(option);
|
|
@@ -9183,7 +9176,7 @@ var Select = (props) => {
|
|
|
9183
9176
|
};
|
|
9184
9177
|
Select.displayName = SELECT_NAME;
|
|
9185
9178
|
var TRIGGER_NAME2 = "SelectTrigger";
|
|
9186
|
-
var SelectTrigger =
|
|
9179
|
+
var SelectTrigger = React45__namespace.forwardRef(
|
|
9187
9180
|
(props, forwardedRef) => {
|
|
9188
9181
|
const { __scopeSelect, disabled = false, ...triggerProps } = props;
|
|
9189
9182
|
const popperScope = usePopperScope2(__scopeSelect);
|
|
@@ -9191,7 +9184,7 @@ var SelectTrigger = React44__namespace.forwardRef(
|
|
|
9191
9184
|
const isDisabled = context.disabled || disabled;
|
|
9192
9185
|
const composedRefs = useComposedRefs(forwardedRef, context.onTriggerChange);
|
|
9193
9186
|
const getItems = useCollection3(__scopeSelect);
|
|
9194
|
-
const pointerTypeRef =
|
|
9187
|
+
const pointerTypeRef = React45__namespace.useRef("touch");
|
|
9195
9188
|
const [searchRef, handleTypeaheadSearch, resetTypeahead] = useTypeaheadSearch((search) => {
|
|
9196
9189
|
const enabledItems = getItems().filter((item) => !item.disabled);
|
|
9197
9190
|
const currentItem = enabledItems.find((item) => item.value === context.value);
|
|
@@ -9261,7 +9254,7 @@ var SelectTrigger = React44__namespace.forwardRef(
|
|
|
9261
9254
|
);
|
|
9262
9255
|
SelectTrigger.displayName = TRIGGER_NAME2;
|
|
9263
9256
|
var VALUE_NAME = "SelectValue";
|
|
9264
|
-
var SelectValue =
|
|
9257
|
+
var SelectValue = React45__namespace.forwardRef(
|
|
9265
9258
|
(props, forwardedRef) => {
|
|
9266
9259
|
const { __scopeSelect, className, style, children, placeholder = "", ...valueProps } = props;
|
|
9267
9260
|
const context = useSelectContext(VALUE_NAME, __scopeSelect);
|
|
@@ -9284,7 +9277,7 @@ var SelectValue = React44__namespace.forwardRef(
|
|
|
9284
9277
|
);
|
|
9285
9278
|
SelectValue.displayName = VALUE_NAME;
|
|
9286
9279
|
var ICON_NAME = "SelectIcon";
|
|
9287
|
-
var SelectIcon =
|
|
9280
|
+
var SelectIcon = React45__namespace.forwardRef(
|
|
9288
9281
|
(props, forwardedRef) => {
|
|
9289
9282
|
const { __scopeSelect, children, ...iconProps } = props;
|
|
9290
9283
|
return /* @__PURE__ */ jsxRuntime.jsx(Primitive.span, { "aria-hidden": true, ...iconProps, ref: forwardedRef, children: children || "\u25BC" });
|
|
@@ -9297,10 +9290,10 @@ var SelectPortal = (props) => {
|
|
|
9297
9290
|
};
|
|
9298
9291
|
SelectPortal.displayName = PORTAL_NAME4;
|
|
9299
9292
|
var CONTENT_NAME4 = "SelectContent";
|
|
9300
|
-
var SelectContent =
|
|
9293
|
+
var SelectContent = React45__namespace.forwardRef(
|
|
9301
9294
|
(props, forwardedRef) => {
|
|
9302
9295
|
const context = useSelectContext(CONTENT_NAME4, props.__scopeSelect);
|
|
9303
|
-
const [fragment, setFragment] =
|
|
9296
|
+
const [fragment, setFragment] = React45__namespace.useState();
|
|
9304
9297
|
useLayoutEffect2(() => {
|
|
9305
9298
|
setFragment(new DocumentFragment());
|
|
9306
9299
|
}, []);
|
|
@@ -9319,7 +9312,7 @@ var CONTENT_MARGIN = 10;
|
|
|
9319
9312
|
var [SelectContentProvider, useSelectContentContext] = createSelectContext(CONTENT_NAME4);
|
|
9320
9313
|
var CONTENT_IMPL_NAME = "SelectContentImpl";
|
|
9321
9314
|
var Slot3 = createSlot2("SelectContent.RemoveScroll");
|
|
9322
|
-
var SelectContentImpl =
|
|
9315
|
+
var SelectContentImpl = React45__namespace.forwardRef(
|
|
9323
9316
|
(props, forwardedRef) => {
|
|
9324
9317
|
const {
|
|
9325
9318
|
__scopeSelect,
|
|
@@ -9343,21 +9336,21 @@ var SelectContentImpl = React44__namespace.forwardRef(
|
|
|
9343
9336
|
...contentProps
|
|
9344
9337
|
} = props;
|
|
9345
9338
|
const context = useSelectContext(CONTENT_NAME4, __scopeSelect);
|
|
9346
|
-
const [content, setContent] =
|
|
9347
|
-
const [viewport, setViewport] =
|
|
9339
|
+
const [content, setContent] = React45__namespace.useState(null);
|
|
9340
|
+
const [viewport, setViewport] = React45__namespace.useState(null);
|
|
9348
9341
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setContent(node));
|
|
9349
|
-
const [selectedItem, setSelectedItem] =
|
|
9350
|
-
const [selectedItemText, setSelectedItemText] =
|
|
9342
|
+
const [selectedItem, setSelectedItem] = React45__namespace.useState(null);
|
|
9343
|
+
const [selectedItemText, setSelectedItemText] = React45__namespace.useState(
|
|
9351
9344
|
null
|
|
9352
9345
|
);
|
|
9353
9346
|
const getItems = useCollection3(__scopeSelect);
|
|
9354
|
-
const [isPositioned, setIsPositioned] =
|
|
9355
|
-
const firstValidItemFoundRef =
|
|
9356
|
-
|
|
9347
|
+
const [isPositioned, setIsPositioned] = React45__namespace.useState(false);
|
|
9348
|
+
const firstValidItemFoundRef = React45__namespace.useRef(false);
|
|
9349
|
+
React45__namespace.useEffect(() => {
|
|
9357
9350
|
if (content) return hideOthers(content);
|
|
9358
9351
|
}, [content]);
|
|
9359
9352
|
useFocusGuards();
|
|
9360
|
-
const focusFirst4 =
|
|
9353
|
+
const focusFirst4 = React45__namespace.useCallback(
|
|
9361
9354
|
(candidates) => {
|
|
9362
9355
|
const [firstItem, ...restItems] = getItems().map((item) => item.ref.current);
|
|
9363
9356
|
const [lastItem] = restItems.slice(-1);
|
|
@@ -9373,17 +9366,17 @@ var SelectContentImpl = React44__namespace.forwardRef(
|
|
|
9373
9366
|
},
|
|
9374
9367
|
[getItems, viewport]
|
|
9375
9368
|
);
|
|
9376
|
-
const focusSelectedItem =
|
|
9369
|
+
const focusSelectedItem = React45__namespace.useCallback(
|
|
9377
9370
|
() => focusFirst4([selectedItem, content]),
|
|
9378
9371
|
[focusFirst4, selectedItem, content]
|
|
9379
9372
|
);
|
|
9380
|
-
|
|
9373
|
+
React45__namespace.useEffect(() => {
|
|
9381
9374
|
if (isPositioned) {
|
|
9382
9375
|
focusSelectedItem();
|
|
9383
9376
|
}
|
|
9384
9377
|
}, [isPositioned, focusSelectedItem]);
|
|
9385
9378
|
const { onOpenChange, triggerPointerDownPosRef } = context;
|
|
9386
|
-
|
|
9379
|
+
React45__namespace.useEffect(() => {
|
|
9387
9380
|
if (content) {
|
|
9388
9381
|
let pointerMoveDelta = { x: 0, y: 0 };
|
|
9389
9382
|
const handlePointerMove = (event) => {
|
|
@@ -9413,7 +9406,7 @@ var SelectContentImpl = React44__namespace.forwardRef(
|
|
|
9413
9406
|
};
|
|
9414
9407
|
}
|
|
9415
9408
|
}, [content, onOpenChange, triggerPointerDownPosRef]);
|
|
9416
|
-
|
|
9409
|
+
React45__namespace.useEffect(() => {
|
|
9417
9410
|
const close = () => onOpenChange(false);
|
|
9418
9411
|
window.addEventListener("blur", close);
|
|
9419
9412
|
window.addEventListener("resize", close);
|
|
@@ -9430,7 +9423,7 @@ var SelectContentImpl = React44__namespace.forwardRef(
|
|
|
9430
9423
|
setTimeout(() => nextItem.ref.current.focus());
|
|
9431
9424
|
}
|
|
9432
9425
|
});
|
|
9433
|
-
const itemRefCallback =
|
|
9426
|
+
const itemRefCallback = React45__namespace.useCallback(
|
|
9434
9427
|
(node, value, disabled) => {
|
|
9435
9428
|
const isFirstValidItem = !firstValidItemFoundRef.current && !disabled;
|
|
9436
9429
|
const isSelectedItem = context.value !== void 0 && context.value === value;
|
|
@@ -9441,8 +9434,8 @@ var SelectContentImpl = React44__namespace.forwardRef(
|
|
|
9441
9434
|
},
|
|
9442
9435
|
[context.value]
|
|
9443
9436
|
);
|
|
9444
|
-
const handleItemLeave =
|
|
9445
|
-
const itemTextRefCallback =
|
|
9437
|
+
const handleItemLeave = React45__namespace.useCallback(() => content?.focus(), [content]);
|
|
9438
|
+
const itemTextRefCallback = React45__namespace.useCallback(
|
|
9446
9439
|
(node, value, disabled) => {
|
|
9447
9440
|
const isFirstValidItem = !firstValidItemFoundRef.current && !disabled;
|
|
9448
9441
|
const isSelectedItem = context.value !== void 0 && context.value === value;
|
|
@@ -9553,18 +9546,18 @@ var SelectContentImpl = React44__namespace.forwardRef(
|
|
|
9553
9546
|
);
|
|
9554
9547
|
SelectContentImpl.displayName = CONTENT_IMPL_NAME;
|
|
9555
9548
|
var ITEM_ALIGNED_POSITION_NAME = "SelectItemAlignedPosition";
|
|
9556
|
-
var SelectItemAlignedPosition =
|
|
9549
|
+
var SelectItemAlignedPosition = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
9557
9550
|
const { __scopeSelect, onPlaced, ...popperProps } = props;
|
|
9558
9551
|
const context = useSelectContext(CONTENT_NAME4, __scopeSelect);
|
|
9559
9552
|
const contentContext = useSelectContentContext(CONTENT_NAME4, __scopeSelect);
|
|
9560
|
-
const [contentWrapper, setContentWrapper] =
|
|
9561
|
-
const [content, setContent] =
|
|
9553
|
+
const [contentWrapper, setContentWrapper] = React45__namespace.useState(null);
|
|
9554
|
+
const [content, setContent] = React45__namespace.useState(null);
|
|
9562
9555
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setContent(node));
|
|
9563
9556
|
const getItems = useCollection3(__scopeSelect);
|
|
9564
|
-
const shouldExpandOnScrollRef =
|
|
9565
|
-
const shouldRepositionRef =
|
|
9557
|
+
const shouldExpandOnScrollRef = React45__namespace.useRef(false);
|
|
9558
|
+
const shouldRepositionRef = React45__namespace.useRef(true);
|
|
9566
9559
|
const { viewport, selectedItem, selectedItemText, focusSelectedItem } = contentContext;
|
|
9567
|
-
const position =
|
|
9560
|
+
const position = React45__namespace.useCallback(() => {
|
|
9568
9561
|
if (context.trigger && context.valueNode && contentWrapper && content && viewport && selectedItem && selectedItemText) {
|
|
9569
9562
|
const triggerRect = context.trigger.getBoundingClientRect();
|
|
9570
9563
|
const contentRect = content.getBoundingClientRect();
|
|
@@ -9664,11 +9657,11 @@ var SelectItemAlignedPosition = React44__namespace.forwardRef((props, forwardedR
|
|
|
9664
9657
|
onPlaced
|
|
9665
9658
|
]);
|
|
9666
9659
|
useLayoutEffect2(() => position(), [position]);
|
|
9667
|
-
const [contentZIndex, setContentZIndex] =
|
|
9660
|
+
const [contentZIndex, setContentZIndex] = React45__namespace.useState();
|
|
9668
9661
|
useLayoutEffect2(() => {
|
|
9669
9662
|
if (content) setContentZIndex(window.getComputedStyle(content).zIndex);
|
|
9670
9663
|
}, [content]);
|
|
9671
|
-
const handleScrollButtonChange =
|
|
9664
|
+
const handleScrollButtonChange = React45__namespace.useCallback(
|
|
9672
9665
|
(node) => {
|
|
9673
9666
|
if (node && shouldRepositionRef.current === true) {
|
|
9674
9667
|
position();
|
|
@@ -9717,7 +9710,7 @@ var SelectItemAlignedPosition = React44__namespace.forwardRef((props, forwardedR
|
|
|
9717
9710
|
});
|
|
9718
9711
|
SelectItemAlignedPosition.displayName = ITEM_ALIGNED_POSITION_NAME;
|
|
9719
9712
|
var POPPER_POSITION_NAME = "SelectPopperPosition";
|
|
9720
|
-
var SelectPopperPosition =
|
|
9713
|
+
var SelectPopperPosition = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
9721
9714
|
const {
|
|
9722
9715
|
__scopeSelect,
|
|
9723
9716
|
align = "start",
|
|
@@ -9752,13 +9745,13 @@ var SelectPopperPosition = React44__namespace.forwardRef((props, forwardedRef) =
|
|
|
9752
9745
|
SelectPopperPosition.displayName = POPPER_POSITION_NAME;
|
|
9753
9746
|
var [SelectViewportProvider, useSelectViewportContext] = createSelectContext(CONTENT_NAME4, {});
|
|
9754
9747
|
var VIEWPORT_NAME = "SelectViewport";
|
|
9755
|
-
var SelectViewport =
|
|
9748
|
+
var SelectViewport = React45__namespace.forwardRef(
|
|
9756
9749
|
(props, forwardedRef) => {
|
|
9757
9750
|
const { __scopeSelect, nonce, ...viewportProps } = props;
|
|
9758
9751
|
const contentContext = useSelectContentContext(VIEWPORT_NAME, __scopeSelect);
|
|
9759
9752
|
const viewportContext = useSelectViewportContext(VIEWPORT_NAME, __scopeSelect);
|
|
9760
9753
|
const composedRefs = useComposedRefs(forwardedRef, contentContext.onViewportChange);
|
|
9761
|
-
const prevScrollTopRef =
|
|
9754
|
+
const prevScrollTopRef = React45__namespace.useRef(0);
|
|
9762
9755
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
9763
9756
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9764
9757
|
"style",
|
|
@@ -9821,7 +9814,7 @@ var SelectViewport = React44__namespace.forwardRef(
|
|
|
9821
9814
|
SelectViewport.displayName = VIEWPORT_NAME;
|
|
9822
9815
|
var GROUP_NAME4 = "SelectGroup";
|
|
9823
9816
|
var [SelectGroupContextProvider, useSelectGroupContext] = createSelectContext(GROUP_NAME4);
|
|
9824
|
-
var SelectGroup =
|
|
9817
|
+
var SelectGroup = React45__namespace.forwardRef(
|
|
9825
9818
|
(props, forwardedRef) => {
|
|
9826
9819
|
const { __scopeSelect, ...groupProps } = props;
|
|
9827
9820
|
const groupId = useId();
|
|
@@ -9830,7 +9823,7 @@ var SelectGroup = React44__namespace.forwardRef(
|
|
|
9830
9823
|
);
|
|
9831
9824
|
SelectGroup.displayName = GROUP_NAME4;
|
|
9832
9825
|
var LABEL_NAME3 = "SelectLabel";
|
|
9833
|
-
var SelectLabel =
|
|
9826
|
+
var SelectLabel = React45__namespace.forwardRef(
|
|
9834
9827
|
(props, forwardedRef) => {
|
|
9835
9828
|
const { __scopeSelect, ...labelProps } = props;
|
|
9836
9829
|
const groupContext = useSelectGroupContext(LABEL_NAME3, __scopeSelect);
|
|
@@ -9840,7 +9833,7 @@ var SelectLabel = React44__namespace.forwardRef(
|
|
|
9840
9833
|
SelectLabel.displayName = LABEL_NAME3;
|
|
9841
9834
|
var ITEM_NAME4 = "SelectItem";
|
|
9842
9835
|
var [SelectItemContextProvider, useSelectItemContext] = createSelectContext(ITEM_NAME4);
|
|
9843
|
-
var SelectItem =
|
|
9836
|
+
var SelectItem = React45__namespace.forwardRef(
|
|
9844
9837
|
(props, forwardedRef) => {
|
|
9845
9838
|
const {
|
|
9846
9839
|
__scopeSelect,
|
|
@@ -9852,14 +9845,14 @@ var SelectItem = React44__namespace.forwardRef(
|
|
|
9852
9845
|
const context = useSelectContext(ITEM_NAME4, __scopeSelect);
|
|
9853
9846
|
const contentContext = useSelectContentContext(ITEM_NAME4, __scopeSelect);
|
|
9854
9847
|
const isSelected = context.value === value;
|
|
9855
|
-
const [textValue, setTextValue] =
|
|
9856
|
-
const [isFocused, setIsFocused] =
|
|
9848
|
+
const [textValue, setTextValue] = React45__namespace.useState(textValueProp ?? "");
|
|
9849
|
+
const [isFocused, setIsFocused] = React45__namespace.useState(false);
|
|
9857
9850
|
const composedRefs = useComposedRefs(
|
|
9858
9851
|
forwardedRef,
|
|
9859
9852
|
(node) => contentContext.itemRefCallback?.(node, value, disabled)
|
|
9860
9853
|
);
|
|
9861
9854
|
const textId = useId();
|
|
9862
|
-
const pointerTypeRef =
|
|
9855
|
+
const pointerTypeRef = React45__namespace.useRef("touch");
|
|
9863
9856
|
const handleSelect = () => {
|
|
9864
9857
|
if (!disabled) {
|
|
9865
9858
|
context.onValueChange(value);
|
|
@@ -9879,7 +9872,7 @@ var SelectItem = React44__namespace.forwardRef(
|
|
|
9879
9872
|
disabled,
|
|
9880
9873
|
textId,
|
|
9881
9874
|
isSelected,
|
|
9882
|
-
onItemTextChange:
|
|
9875
|
+
onItemTextChange: React45__namespace.useCallback((node) => {
|
|
9883
9876
|
setTextValue((prevTextValue) => prevTextValue || (node?.textContent ?? "").trim());
|
|
9884
9877
|
}, []),
|
|
9885
9878
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -9942,14 +9935,14 @@ var SelectItem = React44__namespace.forwardRef(
|
|
|
9942
9935
|
);
|
|
9943
9936
|
SelectItem.displayName = ITEM_NAME4;
|
|
9944
9937
|
var ITEM_TEXT_NAME = "SelectItemText";
|
|
9945
|
-
var SelectItemText =
|
|
9938
|
+
var SelectItemText = React45__namespace.forwardRef(
|
|
9946
9939
|
(props, forwardedRef) => {
|
|
9947
9940
|
const { __scopeSelect, className, style, ...itemTextProps } = props;
|
|
9948
9941
|
const context = useSelectContext(ITEM_TEXT_NAME, __scopeSelect);
|
|
9949
9942
|
const contentContext = useSelectContentContext(ITEM_TEXT_NAME, __scopeSelect);
|
|
9950
9943
|
const itemContext = useSelectItemContext(ITEM_TEXT_NAME, __scopeSelect);
|
|
9951
9944
|
const nativeOptionsContext = useSelectNativeOptionsContext(ITEM_TEXT_NAME, __scopeSelect);
|
|
9952
|
-
const [itemTextNode, setItemTextNode] =
|
|
9945
|
+
const [itemTextNode, setItemTextNode] = React45__namespace.useState(null);
|
|
9953
9946
|
const composedRefs = useComposedRefs(
|
|
9954
9947
|
forwardedRef,
|
|
9955
9948
|
(node) => setItemTextNode(node),
|
|
@@ -9957,7 +9950,7 @@ var SelectItemText = React44__namespace.forwardRef(
|
|
|
9957
9950
|
(node) => contentContext.itemTextRefCallback?.(node, itemContext.value, itemContext.disabled)
|
|
9958
9951
|
);
|
|
9959
9952
|
const textContent = itemTextNode?.textContent;
|
|
9960
|
-
const nativeOption =
|
|
9953
|
+
const nativeOption = React45__namespace.useMemo(
|
|
9961
9954
|
() => /* @__PURE__ */ jsxRuntime.jsx("option", { value: itemContext.value, disabled: itemContext.disabled, children: textContent }, itemContext.value),
|
|
9962
9955
|
[itemContext.disabled, itemContext.value, textContent]
|
|
9963
9956
|
);
|
|
@@ -9974,7 +9967,7 @@ var SelectItemText = React44__namespace.forwardRef(
|
|
|
9974
9967
|
);
|
|
9975
9968
|
SelectItemText.displayName = ITEM_TEXT_NAME;
|
|
9976
9969
|
var ITEM_INDICATOR_NAME2 = "SelectItemIndicator";
|
|
9977
|
-
var SelectItemIndicator =
|
|
9970
|
+
var SelectItemIndicator = React45__namespace.forwardRef(
|
|
9978
9971
|
(props, forwardedRef) => {
|
|
9979
9972
|
const { __scopeSelect, ...itemIndicatorProps } = props;
|
|
9980
9973
|
const itemContext = useSelectItemContext(ITEM_INDICATOR_NAME2, __scopeSelect);
|
|
@@ -9983,10 +9976,10 @@ var SelectItemIndicator = React44__namespace.forwardRef(
|
|
|
9983
9976
|
);
|
|
9984
9977
|
SelectItemIndicator.displayName = ITEM_INDICATOR_NAME2;
|
|
9985
9978
|
var SCROLL_UP_BUTTON_NAME = "SelectScrollUpButton";
|
|
9986
|
-
var SelectScrollUpButton =
|
|
9979
|
+
var SelectScrollUpButton = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
9987
9980
|
const contentContext = useSelectContentContext(SCROLL_UP_BUTTON_NAME, props.__scopeSelect);
|
|
9988
9981
|
const viewportContext = useSelectViewportContext(SCROLL_UP_BUTTON_NAME, props.__scopeSelect);
|
|
9989
|
-
const [canScrollUp, setCanScrollUp] =
|
|
9982
|
+
const [canScrollUp, setCanScrollUp] = React45__namespace.useState(false);
|
|
9990
9983
|
const composedRefs = useComposedRefs(forwardedRef, viewportContext.onScrollButtonChange);
|
|
9991
9984
|
useLayoutEffect2(() => {
|
|
9992
9985
|
if (contentContext.viewport && contentContext.isPositioned) {
|
|
@@ -10016,10 +10009,10 @@ var SelectScrollUpButton = React44__namespace.forwardRef((props, forwardedRef) =
|
|
|
10016
10009
|
});
|
|
10017
10010
|
SelectScrollUpButton.displayName = SCROLL_UP_BUTTON_NAME;
|
|
10018
10011
|
var SCROLL_DOWN_BUTTON_NAME = "SelectScrollDownButton";
|
|
10019
|
-
var SelectScrollDownButton =
|
|
10012
|
+
var SelectScrollDownButton = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
10020
10013
|
const contentContext = useSelectContentContext(SCROLL_DOWN_BUTTON_NAME, props.__scopeSelect);
|
|
10021
10014
|
const viewportContext = useSelectViewportContext(SCROLL_DOWN_BUTTON_NAME, props.__scopeSelect);
|
|
10022
|
-
const [canScrollDown, setCanScrollDown] =
|
|
10015
|
+
const [canScrollDown, setCanScrollDown] = React45__namespace.useState(false);
|
|
10023
10016
|
const composedRefs = useComposedRefs(forwardedRef, viewportContext.onScrollButtonChange);
|
|
10024
10017
|
useLayoutEffect2(() => {
|
|
10025
10018
|
if (contentContext.viewport && contentContext.isPositioned) {
|
|
@@ -10049,18 +10042,18 @@ var SelectScrollDownButton = React44__namespace.forwardRef((props, forwardedRef)
|
|
|
10049
10042
|
) : null;
|
|
10050
10043
|
});
|
|
10051
10044
|
SelectScrollDownButton.displayName = SCROLL_DOWN_BUTTON_NAME;
|
|
10052
|
-
var SelectScrollButtonImpl =
|
|
10045
|
+
var SelectScrollButtonImpl = React45__namespace.forwardRef((props, forwardedRef) => {
|
|
10053
10046
|
const { __scopeSelect, onAutoScroll, ...scrollIndicatorProps } = props;
|
|
10054
10047
|
const contentContext = useSelectContentContext("SelectScrollButton", __scopeSelect);
|
|
10055
|
-
const autoScrollTimerRef =
|
|
10048
|
+
const autoScrollTimerRef = React45__namespace.useRef(null);
|
|
10056
10049
|
const getItems = useCollection3(__scopeSelect);
|
|
10057
|
-
const clearAutoScrollTimer =
|
|
10050
|
+
const clearAutoScrollTimer = React45__namespace.useCallback(() => {
|
|
10058
10051
|
if (autoScrollTimerRef.current !== null) {
|
|
10059
10052
|
window.clearInterval(autoScrollTimerRef.current);
|
|
10060
10053
|
autoScrollTimerRef.current = null;
|
|
10061
10054
|
}
|
|
10062
10055
|
}, []);
|
|
10063
|
-
|
|
10056
|
+
React45__namespace.useEffect(() => {
|
|
10064
10057
|
return () => clearAutoScrollTimer();
|
|
10065
10058
|
}, [clearAutoScrollTimer]);
|
|
10066
10059
|
useLayoutEffect2(() => {
|
|
@@ -10092,7 +10085,7 @@ var SelectScrollButtonImpl = React44__namespace.forwardRef((props, forwardedRef)
|
|
|
10092
10085
|
);
|
|
10093
10086
|
});
|
|
10094
10087
|
var SEPARATOR_NAME3 = "SelectSeparator";
|
|
10095
|
-
var SelectSeparator =
|
|
10088
|
+
var SelectSeparator = React45__namespace.forwardRef(
|
|
10096
10089
|
(props, forwardedRef) => {
|
|
10097
10090
|
const { __scopeSelect, ...separatorProps } = props;
|
|
10098
10091
|
return /* @__PURE__ */ jsxRuntime.jsx(Primitive.div, { "aria-hidden": true, ...separatorProps, ref: forwardedRef });
|
|
@@ -10100,7 +10093,7 @@ var SelectSeparator = React44__namespace.forwardRef(
|
|
|
10100
10093
|
);
|
|
10101
10094
|
SelectSeparator.displayName = SEPARATOR_NAME3;
|
|
10102
10095
|
var ARROW_NAME4 = "SelectArrow";
|
|
10103
|
-
var SelectArrow =
|
|
10096
|
+
var SelectArrow = React45__namespace.forwardRef(
|
|
10104
10097
|
(props, forwardedRef) => {
|
|
10105
10098
|
const { __scopeSelect, ...arrowProps } = props;
|
|
10106
10099
|
const popperScope = usePopperScope2(__scopeSelect);
|
|
@@ -10111,12 +10104,12 @@ var SelectArrow = React44__namespace.forwardRef(
|
|
|
10111
10104
|
);
|
|
10112
10105
|
SelectArrow.displayName = ARROW_NAME4;
|
|
10113
10106
|
var BUBBLE_INPUT_NAME = "SelectBubbleInput";
|
|
10114
|
-
var SelectBubbleInput =
|
|
10107
|
+
var SelectBubbleInput = React45__namespace.forwardRef(
|
|
10115
10108
|
({ __scopeSelect, value, ...props }, forwardedRef) => {
|
|
10116
|
-
const ref =
|
|
10109
|
+
const ref = React45__namespace.useRef(null);
|
|
10117
10110
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
10118
10111
|
const prevValue = usePrevious(value);
|
|
10119
|
-
|
|
10112
|
+
React45__namespace.useEffect(() => {
|
|
10120
10113
|
const select = ref.current;
|
|
10121
10114
|
if (!select) return;
|
|
10122
10115
|
const selectProto = window.HTMLSelectElement.prototype;
|
|
@@ -10148,9 +10141,9 @@ function shouldShowPlaceholder(value) {
|
|
|
10148
10141
|
}
|
|
10149
10142
|
function useTypeaheadSearch(onSearchChange) {
|
|
10150
10143
|
const handleSearchChange = useCallbackRef(onSearchChange);
|
|
10151
|
-
const searchRef =
|
|
10152
|
-
const timerRef =
|
|
10153
|
-
const handleTypeaheadSearch =
|
|
10144
|
+
const searchRef = React45__namespace.useRef("");
|
|
10145
|
+
const timerRef = React45__namespace.useRef(0);
|
|
10146
|
+
const handleTypeaheadSearch = React45__namespace.useCallback(
|
|
10154
10147
|
(key) => {
|
|
10155
10148
|
const search = searchRef.current + key;
|
|
10156
10149
|
handleSearchChange(search);
|
|
@@ -10162,11 +10155,11 @@ function useTypeaheadSearch(onSearchChange) {
|
|
|
10162
10155
|
},
|
|
10163
10156
|
[handleSearchChange]
|
|
10164
10157
|
);
|
|
10165
|
-
const resetTypeahead =
|
|
10158
|
+
const resetTypeahead = React45__namespace.useCallback(() => {
|
|
10166
10159
|
searchRef.current = "";
|
|
10167
10160
|
window.clearTimeout(timerRef.current);
|
|
10168
10161
|
}, []);
|
|
10169
|
-
|
|
10162
|
+
React45__namespace.useEffect(() => {
|
|
10170
10163
|
return () => window.clearTimeout(timerRef.current);
|
|
10171
10164
|
}, []);
|
|
10172
10165
|
return [searchRef, handleTypeaheadSearch, resetTypeahead];
|
|
@@ -10203,19 +10196,19 @@ var ScrollDownButton = SelectScrollDownButton;
|
|
|
10203
10196
|
function Select2({
|
|
10204
10197
|
...props
|
|
10205
10198
|
}) {
|
|
10206
|
-
return /* @__PURE__ */
|
|
10199
|
+
return /* @__PURE__ */ React45__namespace.createElement(Root24, { "data-slot": "select", ...props });
|
|
10207
10200
|
}
|
|
10208
10201
|
function SelectValue2({
|
|
10209
10202
|
...props
|
|
10210
10203
|
}) {
|
|
10211
|
-
return /* @__PURE__ */
|
|
10204
|
+
return /* @__PURE__ */ React45__namespace.createElement(Value, { "data-slot": "select-value", ...props });
|
|
10212
10205
|
}
|
|
10213
10206
|
function SelectTrigger2({
|
|
10214
10207
|
className,
|
|
10215
10208
|
children,
|
|
10216
10209
|
...props
|
|
10217
10210
|
}) {
|
|
10218
|
-
return /* @__PURE__ */
|
|
10211
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
10219
10212
|
Trigger2,
|
|
10220
10213
|
{
|
|
10221
10214
|
"data-slot": "select-trigger",
|
|
@@ -10226,7 +10219,7 @@ function SelectTrigger2({
|
|
|
10226
10219
|
...props
|
|
10227
10220
|
},
|
|
10228
10221
|
children,
|
|
10229
|
-
/* @__PURE__ */
|
|
10222
|
+
/* @__PURE__ */ React45__namespace.createElement(Icon2, { asChild: true }, /* @__PURE__ */ React45__namespace.createElement(ChevronDown, { className: "uii:size-4 uii:opacity-50" }))
|
|
10230
10223
|
);
|
|
10231
10224
|
}
|
|
10232
10225
|
function SelectContent2({
|
|
@@ -10238,7 +10231,7 @@ function SelectContent2({
|
|
|
10238
10231
|
hideScrollDownButton = false,
|
|
10239
10232
|
...props
|
|
10240
10233
|
}) {
|
|
10241
|
-
return /* @__PURE__ */
|
|
10234
|
+
return /* @__PURE__ */ React45__namespace.createElement(Portal3, null, /* @__PURE__ */ React45__namespace.createElement(
|
|
10242
10235
|
Content23,
|
|
10243
10236
|
{
|
|
10244
10237
|
"data-slot": "select-content",
|
|
@@ -10251,8 +10244,8 @@ function SelectContent2({
|
|
|
10251
10244
|
position,
|
|
10252
10245
|
...props
|
|
10253
10246
|
},
|
|
10254
|
-
!hideScrollUpButton && /* @__PURE__ */
|
|
10255
|
-
/* @__PURE__ */
|
|
10247
|
+
!hideScrollUpButton && /* @__PURE__ */ React45__namespace.createElement(SelectScrollUpButton2, null),
|
|
10248
|
+
/* @__PURE__ */ React45__namespace.createElement(
|
|
10256
10249
|
Viewport,
|
|
10257
10250
|
{
|
|
10258
10251
|
className: cn(
|
|
@@ -10262,8 +10255,8 @@ function SelectContent2({
|
|
|
10262
10255
|
},
|
|
10263
10256
|
children
|
|
10264
10257
|
),
|
|
10265
|
-
footer ? /* @__PURE__ */
|
|
10266
|
-
!hideScrollDownButton && /* @__PURE__ */
|
|
10258
|
+
footer ? /* @__PURE__ */ React45__namespace.createElement("div", { className: "uii:border-t uii:p-2 uii:bg-popover" }, footer) : null,
|
|
10259
|
+
!hideScrollDownButton && /* @__PURE__ */ React45__namespace.createElement(SelectScrollDownButton2, null)
|
|
10267
10260
|
));
|
|
10268
10261
|
}
|
|
10269
10262
|
function SelectItem2({
|
|
@@ -10271,7 +10264,7 @@ function SelectItem2({
|
|
|
10271
10264
|
children,
|
|
10272
10265
|
...props
|
|
10273
10266
|
}) {
|
|
10274
|
-
return /* @__PURE__ */
|
|
10267
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
10275
10268
|
Item3,
|
|
10276
10269
|
{
|
|
10277
10270
|
"data-slot": "select-item",
|
|
@@ -10281,15 +10274,15 @@ function SelectItem2({
|
|
|
10281
10274
|
),
|
|
10282
10275
|
...props
|
|
10283
10276
|
},
|
|
10284
|
-
/* @__PURE__ */
|
|
10285
|
-
/* @__PURE__ */
|
|
10277
|
+
/* @__PURE__ */ React45__namespace.createElement("span", { className: "uii:absolute uii:right-2 uii:flex uii:size-3.5 uii:items-center uii:justify-center" }, /* @__PURE__ */ React45__namespace.createElement(ItemIndicator3, null, /* @__PURE__ */ React45__namespace.createElement(Check, { className: "uii:size-4" }))),
|
|
10278
|
+
/* @__PURE__ */ React45__namespace.createElement(ItemText, null, children)
|
|
10286
10279
|
);
|
|
10287
10280
|
}
|
|
10288
10281
|
function SelectScrollUpButton2({
|
|
10289
10282
|
className,
|
|
10290
10283
|
...props
|
|
10291
10284
|
}) {
|
|
10292
|
-
return /* @__PURE__ */
|
|
10285
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
10293
10286
|
ScrollUpButton,
|
|
10294
10287
|
{
|
|
10295
10288
|
"data-slot": "select-scroll-up-button",
|
|
@@ -10299,14 +10292,14 @@ function SelectScrollUpButton2({
|
|
|
10299
10292
|
),
|
|
10300
10293
|
...props
|
|
10301
10294
|
},
|
|
10302
|
-
/* @__PURE__ */
|
|
10295
|
+
/* @__PURE__ */ React45__namespace.createElement(ChevronUp, { className: "uii:size-4" })
|
|
10303
10296
|
);
|
|
10304
10297
|
}
|
|
10305
10298
|
function SelectScrollDownButton2({
|
|
10306
10299
|
className,
|
|
10307
10300
|
...props
|
|
10308
10301
|
}) {
|
|
10309
|
-
return /* @__PURE__ */
|
|
10302
|
+
return /* @__PURE__ */ React45__namespace.createElement(
|
|
10310
10303
|
ScrollDownButton,
|
|
10311
10304
|
{
|
|
10312
10305
|
"data-slot": "select-scroll-down-button",
|
|
@@ -10316,14 +10309,14 @@ function SelectScrollDownButton2({
|
|
|
10316
10309
|
),
|
|
10317
10310
|
...props
|
|
10318
10311
|
},
|
|
10319
|
-
/* @__PURE__ */
|
|
10312
|
+
/* @__PURE__ */ React45__namespace.createElement(ChevronDown, { className: "uii:size-4" })
|
|
10320
10313
|
);
|
|
10321
10314
|
}
|
|
10322
10315
|
|
|
10323
10316
|
// src/components/fields/Select.tsx
|
|
10324
10317
|
function useResolvedExpectedType2(expectedType, devCtx) {
|
|
10325
10318
|
const inferredTypes = devCtx?.inferredTypes;
|
|
10326
|
-
return
|
|
10319
|
+
return React45__namespace.useMemo(() => {
|
|
10327
10320
|
if (!expectedType) return "any";
|
|
10328
10321
|
if (!expectedType.startsWith("$infer<")) {
|
|
10329
10322
|
return expectedType;
|
|
@@ -10368,46 +10361,46 @@ function Select3({
|
|
|
10368
10361
|
className,
|
|
10369
10362
|
children
|
|
10370
10363
|
}) {
|
|
10371
|
-
const devCtx =
|
|
10364
|
+
const devCtx = React45.useContext(DevContext);
|
|
10372
10365
|
const resolvedExpectedType = useResolvedExpectedType2(expectedType, devCtx);
|
|
10373
|
-
const [isExpressionMode, setIsExpressionMode] =
|
|
10374
|
-
const [expressionValue, setExpressionValue] =
|
|
10375
|
-
const options =
|
|
10366
|
+
const [isExpressionMode, setIsExpressionMode] = React45__namespace.useState(false);
|
|
10367
|
+
const [expressionValue, setExpressionValue] = React45__namespace.useState("");
|
|
10368
|
+
const options = React45__namespace.useMemo(() => {
|
|
10376
10369
|
return rawOptions.map(
|
|
10377
10370
|
(opt) => typeof opt === "string" ? { value: opt, label: opt } : opt
|
|
10378
10371
|
);
|
|
10379
10372
|
}, [rawOptions]);
|
|
10380
|
-
const displayValue =
|
|
10373
|
+
const displayValue = React45__namespace.useMemo(() => {
|
|
10381
10374
|
if (value != null && typeof value === "object" && "expression" in value) {
|
|
10382
10375
|
return String(value.expression ?? "");
|
|
10383
10376
|
}
|
|
10384
10377
|
return String(value ?? "");
|
|
10385
10378
|
}, [value]);
|
|
10386
|
-
const isExpression =
|
|
10379
|
+
const isExpression = React45__namespace.useMemo(() => {
|
|
10387
10380
|
return value && typeof value === "object" && "expression" in value;
|
|
10388
10381
|
}, [value]);
|
|
10389
|
-
|
|
10382
|
+
React45__namespace.useEffect(() => {
|
|
10390
10383
|
if (isExpression) {
|
|
10391
10384
|
setIsExpressionMode(true);
|
|
10392
10385
|
setExpressionValue(displayValue);
|
|
10393
10386
|
}
|
|
10394
10387
|
}, [isExpression, displayValue]);
|
|
10395
|
-
const handleSelectChange =
|
|
10388
|
+
const handleSelectChange = React45__namespace.useCallback((newValue) => {
|
|
10396
10389
|
if (newValue === "__expression__") {
|
|
10397
10390
|
setIsExpressionMode(true);
|
|
10398
10391
|
return;
|
|
10399
10392
|
}
|
|
10400
10393
|
onChange(newValue);
|
|
10401
10394
|
}, [onChange]);
|
|
10402
|
-
const handleExpressionChange =
|
|
10403
|
-
|
|
10404
|
-
|
|
10405
|
-
|
|
10406
|
-
|
|
10407
|
-
|
|
10408
|
-
|
|
10409
|
-
|
|
10410
|
-
const handleSwitchToValue =
|
|
10395
|
+
const handleExpressionChange = React45__namespace.useCallback(
|
|
10396
|
+
(e) => {
|
|
10397
|
+
const newValue = e.target.value;
|
|
10398
|
+
setExpressionValue(newValue);
|
|
10399
|
+
onChange(newValue);
|
|
10400
|
+
},
|
|
10401
|
+
[onChange]
|
|
10402
|
+
);
|
|
10403
|
+
const handleSwitchToValue = React45__namespace.useCallback(() => {
|
|
10411
10404
|
setIsExpressionMode(false);
|
|
10412
10405
|
setExpressionValue("");
|
|
10413
10406
|
onChange("");
|
|
@@ -10436,7 +10429,7 @@ function Select3({
|
|
|
10436
10429
|
hasError: showError
|
|
10437
10430
|
};
|
|
10438
10431
|
const isWaiting = resolvedExpectedType.startsWith("Waiting for:") || resolvedExpectedType.startsWith("Subscribing to:");
|
|
10439
|
-
return /* @__PURE__ */
|
|
10432
|
+
return /* @__PURE__ */ React45__namespace.createElement("div", { className: cn("uii:mb-2", className) }, /* @__PURE__ */ React45__namespace.createElement("div", { className: "uii:flex uii:items-center uii:gap-2 uii:mt-2" }, /* @__PURE__ */ React45__namespace.createElement(
|
|
10440
10433
|
"label",
|
|
10441
10434
|
{
|
|
10442
10435
|
htmlFor: fieldName,
|
|
@@ -10444,7 +10437,7 @@ function Select3({
|
|
|
10444
10437
|
},
|
|
10445
10438
|
label,
|
|
10446
10439
|
":"
|
|
10447
|
-
), resolvedExpectedType !== "$.interface.timer" && /* @__PURE__ */
|
|
10440
|
+
), resolvedExpectedType !== "$.interface.timer" && /* @__PURE__ */ React45__namespace.createElement(
|
|
10448
10441
|
"span",
|
|
10449
10442
|
{
|
|
10450
10443
|
className: cn(
|
|
@@ -10454,12 +10447,12 @@ function Select3({
|
|
|
10454
10447
|
title: resolvedExpectedType
|
|
10455
10448
|
},
|
|
10456
10449
|
resolvedExpectedType
|
|
10457
|
-
), showError && /* @__PURE__ */
|
|
10450
|
+
), showError && /* @__PURE__ */ React45__namespace.createElement("span", { className: "uii:-mt-2 uii:inline-flex uii:px-1 uii:py-0.5 uii:bg-red-100 uii:text-red-600 uii:rounded-sm uii:text-[10px] uii:font-medium" }, "Required")), /* @__PURE__ */ React45__namespace.createElement("div", { className: "uii:mt-0.5" }, children ? (
|
|
10458
10451
|
// Use custom render function
|
|
10459
10452
|
children(renderProps)
|
|
10460
10453
|
) : isExpressionMode ? (
|
|
10461
10454
|
// Expression mode - show input with clear button
|
|
10462
|
-
/* @__PURE__ */
|
|
10455
|
+
/* @__PURE__ */ React45__namespace.createElement("div", { className: "uii:flex uii:items-center uii:h-9 uii:rounded-sm uii:border uii:border-amber-500/50 uii:bg-amber-500/5" }, /* @__PURE__ */ React45__namespace.createElement(
|
|
10463
10456
|
"input",
|
|
10464
10457
|
{
|
|
10465
10458
|
id: fieldName,
|
|
@@ -10475,7 +10468,7 @@ function Select3({
|
|
|
10475
10468
|
disabled && "uii:opacity-50 uii:cursor-not-allowed"
|
|
10476
10469
|
)
|
|
10477
10470
|
}
|
|
10478
|
-
), /* @__PURE__ */
|
|
10471
|
+
), /* @__PURE__ */ React45__namespace.createElement(
|
|
10479
10472
|
"button",
|
|
10480
10473
|
{
|
|
10481
10474
|
type: "button",
|
|
@@ -10517,21 +10510,21 @@ function Select3({
|
|
|
10517
10510
|
// 📝 Custom Expression
|
|
10518
10511
|
// </option>
|
|
10519
10512
|
// </select>
|
|
10520
|
-
/* @__PURE__ */
|
|
10513
|
+
/* @__PURE__ */ React45__namespace.createElement(
|
|
10521
10514
|
Select2,
|
|
10522
10515
|
{
|
|
10523
10516
|
value: displayValue,
|
|
10524
10517
|
onValueChange: (e) => handleSelectChange(e),
|
|
10525
10518
|
disabled: disabled ?? disabled
|
|
10526
10519
|
},
|
|
10527
|
-
/* @__PURE__ */
|
|
10520
|
+
/* @__PURE__ */ React45__namespace.createElement(
|
|
10528
10521
|
SelectTrigger2,
|
|
10529
10522
|
{
|
|
10530
10523
|
className: "ui:w-full ui:h-9 ui:px-3 ui:border ui:border-input ui:rounded-sm ui:bg-background"
|
|
10531
10524
|
},
|
|
10532
|
-
/* @__PURE__ */
|
|
10525
|
+
/* @__PURE__ */ React45__namespace.createElement(SelectValue2, { placeholder })
|
|
10533
10526
|
),
|
|
10534
|
-
/* @__PURE__ */
|
|
10527
|
+
/* @__PURE__ */ React45__namespace.createElement(SelectContent2, null, options.map((opt) => /* @__PURE__ */ React45__namespace.createElement(SelectItem2, { key: opt.value, value: opt.value }, opt.node ? opt.node : /* @__PURE__ */ React45__namespace.createElement(React45__namespace.Fragment, null, opt.label))))
|
|
10535
10528
|
)
|
|
10536
10529
|
)));
|
|
10537
10530
|
}
|
|
@@ -10662,17 +10655,17 @@ function useFieldPath(fieldName) {
|
|
|
10662
10655
|
return fieldName;
|
|
10663
10656
|
}
|
|
10664
10657
|
function TemplateFieldProvider({ children }) {
|
|
10665
|
-
return /* @__PURE__ */
|
|
10658
|
+
return /* @__PURE__ */ React45__namespace.default.createElement(React45__namespace.default.Fragment, null, children);
|
|
10666
10659
|
}
|
|
10667
10660
|
function NestedFieldProvider({
|
|
10668
10661
|
children
|
|
10669
10662
|
}) {
|
|
10670
|
-
return /* @__PURE__ */
|
|
10663
|
+
return /* @__PURE__ */ React45__namespace.default.createElement(React45__namespace.default.Fragment, null, children);
|
|
10671
10664
|
}
|
|
10672
|
-
var InferredTypesContext =
|
|
10665
|
+
var InferredTypesContext = React45.createContext(null);
|
|
10673
10666
|
function useInferredTypes() {
|
|
10674
|
-
const devContext =
|
|
10675
|
-
const realContext =
|
|
10667
|
+
const devContext = React45.useContext(DevContext);
|
|
10668
|
+
const realContext = React45.useContext(InferredTypesContext);
|
|
10676
10669
|
if (devContext) {
|
|
10677
10670
|
return {
|
|
10678
10671
|
inferredTypes: devContext.inferredTypes,
|
|
@@ -10685,7 +10678,7 @@ function useInferredTypes() {
|
|
|
10685
10678
|
return realContext;
|
|
10686
10679
|
}
|
|
10687
10680
|
function InferredTypesProvider({ children }) {
|
|
10688
|
-
return /* @__PURE__ */
|
|
10681
|
+
return /* @__PURE__ */ React45__namespace.default.createElement(React45__namespace.default.Fragment, null, children);
|
|
10689
10682
|
}
|
|
10690
10683
|
function intersectTypes(types) {
|
|
10691
10684
|
const validTypes = types.filter((t) => !!t && t.length > 0);
|
|
@@ -10746,33 +10739,33 @@ function getOperatorsForType(type) {
|
|
|
10746
10739
|
];
|
|
10747
10740
|
}
|
|
10748
10741
|
function NodePropertyProvider({ children }) {
|
|
10749
|
-
return /* @__PURE__ */
|
|
10742
|
+
return /* @__PURE__ */ React45__namespace.default.createElement(React45__namespace.default.Fragment, null, children);
|
|
10750
10743
|
}
|
|
10751
10744
|
function useSetFieldMetadataOnly() {
|
|
10752
|
-
return
|
|
10745
|
+
return React45.useCallback((_fieldKey, _metadata) => {
|
|
10753
10746
|
}, []);
|
|
10754
10747
|
}
|
|
10755
10748
|
function useIsInNodePropertyProvider() {
|
|
10756
|
-
const devContext =
|
|
10749
|
+
const devContext = React45.useContext(DevContext);
|
|
10757
10750
|
return devContext !== null;
|
|
10758
10751
|
}
|
|
10759
10752
|
function useNodeProperty(key) {
|
|
10760
|
-
const devContext =
|
|
10761
|
-
const [devValue, setDevValue] =
|
|
10753
|
+
const devContext = React45.useContext(DevContext);
|
|
10754
|
+
const [devValue, setDevValue] = React45.useState(
|
|
10762
10755
|
() => devContext?.data?.[key]
|
|
10763
10756
|
);
|
|
10764
|
-
|
|
10757
|
+
React45__namespace.default.useEffect(() => {
|
|
10765
10758
|
if (devContext) {
|
|
10766
10759
|
setDevValue(devContext.data[key]);
|
|
10767
10760
|
}
|
|
10768
10761
|
}, [devContext, key]);
|
|
10769
|
-
const devSetter =
|
|
10762
|
+
const devSetter = React45.useCallback((value, _metadata) => {
|
|
10770
10763
|
if (devContext) {
|
|
10771
10764
|
devContext.setProperty(key, value);
|
|
10772
10765
|
setDevValue(value);
|
|
10773
10766
|
}
|
|
10774
10767
|
}, [devContext, key]);
|
|
10775
|
-
const noopSetter =
|
|
10768
|
+
const noopSetter = React45.useCallback(() => {
|
|
10776
10769
|
console.warn(`[useNodeProperty] No provider - cannot set "${key}"`);
|
|
10777
10770
|
}, [key]);
|
|
10778
10771
|
if (devContext) {
|
|
@@ -10781,16 +10774,16 @@ function useNodeProperty(key) {
|
|
|
10781
10774
|
return [void 0, noopSetter];
|
|
10782
10775
|
}
|
|
10783
10776
|
function useNodeProperties() {
|
|
10784
|
-
const devContext =
|
|
10785
|
-
const [devData, setDevData] =
|
|
10777
|
+
const devContext = React45.useContext(DevContext);
|
|
10778
|
+
const [devData, setDevData] = React45.useState(
|
|
10786
10779
|
() => devContext?.data ?? {}
|
|
10787
10780
|
);
|
|
10788
|
-
|
|
10781
|
+
React45__namespace.default.useEffect(() => {
|
|
10789
10782
|
if (devContext) {
|
|
10790
10783
|
setDevData({ ...devContext.data });
|
|
10791
10784
|
}
|
|
10792
10785
|
}, [devContext, devContext?.data]);
|
|
10793
|
-
const devSetter =
|
|
10786
|
+
const devSetter = React45.useCallback((updates) => {
|
|
10794
10787
|
if (devContext) {
|
|
10795
10788
|
Object.entries(updates).forEach(([key, value]) => {
|
|
10796
10789
|
devContext.setProperty(key, value);
|
|
@@ -10798,7 +10791,7 @@ function useNodeProperties() {
|
|
|
10798
10791
|
setDevData((prev) => ({ ...prev, ...updates }));
|
|
10799
10792
|
}
|
|
10800
10793
|
}, [devContext]);
|
|
10801
|
-
const noopSetter =
|
|
10794
|
+
const noopSetter = React45.useCallback(() => {
|
|
10802
10795
|
console.warn("[useNodeProperties] No provider - cannot set properties");
|
|
10803
10796
|
}, []);
|
|
10804
10797
|
if (devContext) {
|
|
@@ -10807,11 +10800,11 @@ function useNodeProperties() {
|
|
|
10807
10800
|
return [{}, noopSetter];
|
|
10808
10801
|
}
|
|
10809
10802
|
function useInferredType(fieldName) {
|
|
10810
|
-
const devContext =
|
|
10811
|
-
const [devInferredType, setDevInferredType] =
|
|
10803
|
+
const devContext = React45.useContext(DevContext);
|
|
10804
|
+
const [devInferredType, setDevInferredType] = React45.useState(
|
|
10812
10805
|
() => devContext?.inferredTypes?.[fieldName]
|
|
10813
10806
|
);
|
|
10814
|
-
|
|
10807
|
+
React45__namespace.default.useEffect(() => {
|
|
10815
10808
|
if (devContext) {
|
|
10816
10809
|
setDevInferredType(devContext.inferredTypes[fieldName]);
|
|
10817
10810
|
}
|
|
@@ -10822,8 +10815,8 @@ function useInferredType(fieldName) {
|
|
|
10822
10815
|
return void 0;
|
|
10823
10816
|
}
|
|
10824
10817
|
function useSetInferredType() {
|
|
10825
|
-
const devContext =
|
|
10826
|
-
return
|
|
10818
|
+
const devContext = React45.useContext(DevContext);
|
|
10819
|
+
return React45.useCallback((fieldName, type) => {
|
|
10827
10820
|
if (devContext) {
|
|
10828
10821
|
devContext.setInferredType(fieldName, type);
|
|
10829
10822
|
} else {
|
|
@@ -10832,8 +10825,8 @@ function useSetInferredType() {
|
|
|
10832
10825
|
}, [devContext]);
|
|
10833
10826
|
}
|
|
10834
10827
|
function useClearInferredType() {
|
|
10835
|
-
const devContext =
|
|
10836
|
-
return
|
|
10828
|
+
const devContext = React45.useContext(DevContext);
|
|
10829
|
+
return React45.useCallback((fieldName) => {
|
|
10837
10830
|
if (devContext) {
|
|
10838
10831
|
devContext.clearInferredType(fieldName);
|
|
10839
10832
|
} else {
|
|
@@ -10842,8 +10835,8 @@ function useClearInferredType() {
|
|
|
10842
10835
|
}, [devContext]);
|
|
10843
10836
|
}
|
|
10844
10837
|
function useClearAllInferredTypes() {
|
|
10845
|
-
const devContext =
|
|
10846
|
-
return
|
|
10838
|
+
const devContext = React45.useContext(DevContext);
|
|
10839
|
+
return React45.useCallback(() => {
|
|
10847
10840
|
if (devContext) {
|
|
10848
10841
|
devContext.clearAllInferredTypes();
|
|
10849
10842
|
} else {
|
|
@@ -10852,7 +10845,7 @@ function useClearAllInferredTypes() {
|
|
|
10852
10845
|
}, [devContext]);
|
|
10853
10846
|
}
|
|
10854
10847
|
function useClearValidationErrorsByPrefix() {
|
|
10855
|
-
return
|
|
10848
|
+
return React45.useCallback((fieldPrefix) => {
|
|
10856
10849
|
console.log(`[useClearValidationErrorsByPrefix] Dev mode - clearing errors with prefix "${fieldPrefix}" is a no-op`);
|
|
10857
10850
|
}, []);
|
|
10858
10851
|
}
|
|
@@ -10869,11 +10862,11 @@ function useFlowEditorActions() {
|
|
|
10869
10862
|
};
|
|
10870
10863
|
}
|
|
10871
10864
|
function useAllInferredTypes() {
|
|
10872
|
-
const devContext =
|
|
10873
|
-
const [devTypes, setDevTypes] =
|
|
10865
|
+
const devContext = React45.useContext(DevContext);
|
|
10866
|
+
const [devTypes, setDevTypes] = React45.useState(
|
|
10874
10867
|
() => devContext?.inferredTypes ?? {}
|
|
10875
10868
|
);
|
|
10876
|
-
|
|
10869
|
+
React45__namespace.default.useEffect(() => {
|
|
10877
10870
|
if (devContext) {
|
|
10878
10871
|
setDevTypes({ ...devContext.inferredTypes });
|
|
10879
10872
|
}
|
|
@@ -10884,8 +10877,8 @@ function useAllInferredTypes() {
|
|
|
10884
10877
|
return {};
|
|
10885
10878
|
}
|
|
10886
10879
|
function useSetProperty() {
|
|
10887
|
-
const devContext =
|
|
10888
|
-
return
|
|
10880
|
+
const devContext = React45.useContext(DevContext);
|
|
10881
|
+
return React45.useCallback((key, value, _metadata) => {
|
|
10889
10882
|
if (devContext) {
|
|
10890
10883
|
devContext.setProperty(key, value);
|
|
10891
10884
|
} else {
|
|
@@ -10894,8 +10887,8 @@ function useSetProperty() {
|
|
|
10894
10887
|
}, [devContext]);
|
|
10895
10888
|
}
|
|
10896
10889
|
function useTriggerLayoutUpdate() {
|
|
10897
|
-
const devContext =
|
|
10898
|
-
return
|
|
10890
|
+
const devContext = React45.useContext(DevContext);
|
|
10891
|
+
return React45.useCallback(() => {
|
|
10899
10892
|
if (devContext) {
|
|
10900
10893
|
console.log("[useTriggerLayoutUpdate] Dev mode - layout update is a no-op");
|
|
10901
10894
|
} else {
|
|
@@ -10904,28 +10897,28 @@ function useTriggerLayoutUpdate() {
|
|
|
10904
10897
|
}, [devContext]);
|
|
10905
10898
|
}
|
|
10906
10899
|
function useFieldValidation() {
|
|
10907
|
-
const setFieldRequired =
|
|
10900
|
+
const setFieldRequired = React45.useCallback((fieldName, required) => {
|
|
10908
10901
|
console.warn(`[useFieldValidation] Mock mode - cannot set required for "${fieldName}"`);
|
|
10909
10902
|
}, []);
|
|
10910
|
-
const setFieldRequiredIf =
|
|
10903
|
+
const setFieldRequiredIf = React45.useCallback(
|
|
10911
10904
|
(fieldName, requiredIf) => {
|
|
10912
10905
|
console.warn(`[useFieldValidation] Mock mode - cannot set requiredIf for "${fieldName}"`);
|
|
10913
10906
|
},
|
|
10914
10907
|
[]
|
|
10915
10908
|
);
|
|
10916
|
-
const setFieldValidation =
|
|
10909
|
+
const setFieldValidation = React45.useCallback(
|
|
10917
10910
|
(fieldName, customValidation) => {
|
|
10918
10911
|
console.warn(`[useFieldValidation] Mock mode - cannot set validation for "${fieldName}"`);
|
|
10919
10912
|
},
|
|
10920
10913
|
[]
|
|
10921
10914
|
);
|
|
10922
|
-
const clearFieldValidation =
|
|
10915
|
+
const clearFieldValidation = React45.useCallback((fieldName) => {
|
|
10923
10916
|
console.warn(`[useFieldValidation] Mock mode - cannot clear validation for "${fieldName}"`);
|
|
10924
10917
|
}, []);
|
|
10925
|
-
const isFieldRequired =
|
|
10918
|
+
const isFieldRequired = React45.useCallback((fieldName) => {
|
|
10926
10919
|
return false;
|
|
10927
10920
|
}, []);
|
|
10928
|
-
const validateField =
|
|
10921
|
+
const validateField = React45.useCallback((fieldName) => {
|
|
10929
10922
|
return null;
|
|
10930
10923
|
}, []);
|
|
10931
10924
|
return {
|
|
@@ -10937,6 +10930,25 @@ function useFieldValidation() {
|
|
|
10937
10930
|
validateField
|
|
10938
10931
|
};
|
|
10939
10932
|
}
|
|
10933
|
+
|
|
10934
|
+
// src/components/slots/index.tsx
|
|
10935
|
+
var slots_exports = {};
|
|
10936
|
+
__export(slots_exports, {
|
|
10937
|
+
ExportManager: () => ExportManager,
|
|
10938
|
+
SlotElements: () => SlotElements
|
|
10939
|
+
});
|
|
10940
|
+
|
|
10941
|
+
// src/components/slots/SlotElements.tsx
|
|
10942
|
+
var SlotElements = (props) => {
|
|
10943
|
+
const { slotId } = props;
|
|
10944
|
+
return /* @__PURE__ */ React.createElement("div", { className: "uii:flex uii:flex-row uii:gap-2 uii:border-dashed uii:border uii:border-gray-300 \n uii:rounded-sm uii:p-2 uii:h-10 uii:w-full uii:items-center uii:justify-start uii:p-1" }, /* @__PURE__ */ React.createElement("div", { className: "uii:w-8 uii:h-8 uii:rounded-xs uii:overflow-hidden uii:flex uii:items-center uii:justify-center uii:relative uii:z-20" }, /* @__PURE__ */ React.createElement("img", { alt: "Send GET Request", className: "uii:w-8 uii:h-8 uii:object-contain uii:rounded-xs uii:z-20", src: "https://res.cloudinary.com/process-co/image/fetch/w_64,h_64,c_fill,g_face/https://res.cloudinary.com/process-co/image/upload/v1755226713/namespace-icons/http.svg" })), /* @__PURE__ */ React.createElement("div", { className: "uii:w-8 uii:h-8 uii:rounded-xs uii:overflow-hidden uii:flex uii:items-center uii:justify-center uii:relative uii:z-20" }, /* @__PURE__ */ React.createElement("img", { alt: "Send GET Request", className: "uii:w-8 uii:h-8 uii:object-contain uii:rounded-xs uii:z-20", src: "https://res.cloudinary.com/process-co/image/fetch/w_64,h_64,c_fill,g_face/https://res.cloudinary.com/process-co/image/upload/v1755227094/namespace-icons/mailgun.svg" })), /* @__PURE__ */ React.createElement("div", { className: "uii:w-8 uii:h-8 uii:rounded-xs uii:overflow-hidden uii:flex uii:items-center uii:justify-center uii:relative uii:z-20" }, /* @__PURE__ */ React.createElement("img", { alt: "Send GET Request", className: "uii:w-8 uii:h-8 uii:object-contain uii:rounded-xs uii:z-20", src: "https://res.cloudinary.com/process-co/image/upload/v1772002004/img.icons8.com.png" })), /* @__PURE__ */ React.createElement("div", { className: "uii:w-8 uii:h-8 uii:rounded-xs uii:overflow-hidden uii:flex uii:items-center uii:justify-center uii:relative uii:z-20" }, /* @__PURE__ */ React.createElement("img", { alt: "Send GET Request", className: "uii:w-8 uii:h-8 uii:object-contain uii:rounded-xs uii:z-20", src: "https://res.cloudinary.com/process-co/image/fetch/w_64,h_64,c_fill,g_face/https://res.cloudinary.com/process-co/image/upload/v1755226713/namespace-icons/http.svg" })));
|
|
10945
|
+
};
|
|
10946
|
+
|
|
10947
|
+
// src/components/slots/ExportManager.tsx
|
|
10948
|
+
var ExportManager = (props) => {
|
|
10949
|
+
const { slotId } = props;
|
|
10950
|
+
return /* @__PURE__ */ React.createElement(Button, { variant: "outline", size: "sm" }, "Manage Exports");
|
|
10951
|
+
};
|
|
10940
10952
|
/*! Bundled license information:
|
|
10941
10953
|
|
|
10942
10954
|
lucide-react/dist/esm/shared/src/utils.js:
|
|
@@ -10980,6 +10992,7 @@ exports.ToggleButton = ToggleButton;
|
|
|
10980
10992
|
exports.buttonVariants = buttonVariants;
|
|
10981
10993
|
exports.fields = fields_exports;
|
|
10982
10994
|
exports.logicToggleButtonStyles = logicToggleButtonStyles;
|
|
10995
|
+
exports.slots = slots_exports;
|
|
10983
10996
|
exports.toggleButtonVariants = toggleButtonVariants;
|
|
10984
10997
|
//# sourceMappingURL=index.cjs.map
|
|
10985
10998
|
//# sourceMappingURL=index.cjs.map
|