@cnc-ti/layout-basic 8.2.1 → 8.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +261 -35
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +75 -2
- package/dist/index.d.ts +75 -2
- package/dist/index.js +749 -717
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +729 -708
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -1
package/dist/index.js
CHANGED
|
@@ -67,10 +67,21 @@ __export(src_exports, {
|
|
|
67
67
|
HeaderProfileHeader: () => HeaderProfileHeader,
|
|
68
68
|
HeaderProfileItem: () => HeaderProfileItem,
|
|
69
69
|
Modal: () => Modal,
|
|
70
|
+
ModalEntidade: () => ModalEntidade,
|
|
70
71
|
ModalMudancaEntidade: () => ModalMudancaEntidade,
|
|
71
72
|
Popover: () => Popover2,
|
|
72
73
|
PopoverContent: () => PopoverContent2,
|
|
73
74
|
PopoverTrigger: () => PopoverTrigger2,
|
|
75
|
+
Select: () => Select,
|
|
76
|
+
SelectContent: () => SelectContent,
|
|
77
|
+
SelectGroup: () => SelectGroup,
|
|
78
|
+
SelectItem: () => SelectItem,
|
|
79
|
+
SelectLabel: () => SelectLabel,
|
|
80
|
+
SelectScrollDownButton: () => SelectScrollDownButton,
|
|
81
|
+
SelectScrollUpButton: () => SelectScrollUpButton,
|
|
82
|
+
SelectSeparator: () => SelectSeparator,
|
|
83
|
+
SelectTrigger: () => SelectTrigger,
|
|
84
|
+
SelectValue: () => SelectValue,
|
|
74
85
|
Sidebar: () => Sidebar,
|
|
75
86
|
SidebarContainer: () => SidebarContainer,
|
|
76
87
|
SidebarImageBrand: () => SidebarImageBrand,
|
|
@@ -87,57 +98,57 @@ var import_react_slot = require("@radix-ui/react-slot");
|
|
|
87
98
|
function r(e) {
|
|
88
99
|
var t, f, n = "";
|
|
89
100
|
if ("string" == typeof e || "number" == typeof e) n += e;
|
|
90
|
-
else if ("object" == typeof e) if (Array.isArray(e))
|
|
91
|
-
|
|
101
|
+
else if ("object" == typeof e) if (Array.isArray(e)) {
|
|
102
|
+
var o = e.length;
|
|
103
|
+
for (t = 0; t < o; t++) e[t] && (f = r(e[t])) && (n && (n += " "), n += f);
|
|
104
|
+
} else for (f in e) e[f] && (n && (n += " "), n += f);
|
|
92
105
|
return n;
|
|
93
106
|
}
|
|
94
107
|
function clsx() {
|
|
95
|
-
for (var e, t, f = 0, n = ""
|
|
108
|
+
for (var e, t, f = 0, n = "", o = arguments.length; f < o; f++) (e = arguments[f]) && (t = r(e)) && (n && (n += " "), n += t);
|
|
96
109
|
return n;
|
|
97
110
|
}
|
|
98
111
|
|
|
99
112
|
// ../../node_modules/class-variance-authority/dist/index.mjs
|
|
100
|
-
var falsyToString = (value) => typeof value === "boolean" ?
|
|
113
|
+
var falsyToString = (value) => typeof value === "boolean" ? `${value}` : value === 0 ? "0" : value;
|
|
101
114
|
var cx = clsx;
|
|
102
|
-
var cva = (base, config) => {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
const
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
if (value === void 0) {
|
|
117
|
-
return acc;
|
|
118
|
-
}
|
|
119
|
-
acc[key] = value;
|
|
115
|
+
var cva = (base, config) => (props) => {
|
|
116
|
+
var _config_compoundVariants;
|
|
117
|
+
if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
|
|
118
|
+
const { variants, defaultVariants } = config;
|
|
119
|
+
const getVariantClassNames = Object.keys(variants).map((variant) => {
|
|
120
|
+
const variantProp = props === null || props === void 0 ? void 0 : props[variant];
|
|
121
|
+
const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];
|
|
122
|
+
if (variantProp === null) return null;
|
|
123
|
+
const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);
|
|
124
|
+
return variants[variant][variantKey];
|
|
125
|
+
});
|
|
126
|
+
const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param) => {
|
|
127
|
+
let [key, value] = param;
|
|
128
|
+
if (value === void 0) {
|
|
120
129
|
return acc;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
...
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
130
|
+
}
|
|
131
|
+
acc[key] = value;
|
|
132
|
+
return acc;
|
|
133
|
+
}, {});
|
|
134
|
+
const getCompoundVariantClassNames = config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param) => {
|
|
135
|
+
let { class: cvClass, className: cvClassName, ...compoundVariantOptions } = param;
|
|
136
|
+
return Object.entries(compoundVariantOptions).every((param2) => {
|
|
137
|
+
let [key, value] = param2;
|
|
138
|
+
return Array.isArray(value) ? value.includes({
|
|
139
|
+
...defaultVariants,
|
|
140
|
+
...propsWithoutUndefined
|
|
141
|
+
}[key]) : {
|
|
142
|
+
...defaultVariants,
|
|
143
|
+
...propsWithoutUndefined
|
|
144
|
+
}[key] === value;
|
|
145
|
+
}) ? [
|
|
146
|
+
...acc,
|
|
147
|
+
cvClass,
|
|
148
|
+
cvClassName
|
|
149
|
+
] : acc;
|
|
150
|
+
}, []);
|
|
151
|
+
return cx(base, getVariantClassNames, getCompoundVariantClassNames, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
|
|
141
152
|
};
|
|
142
153
|
|
|
143
154
|
// ../../node_modules/lucide-react/dist/esm/createLucideIcon.js
|
|
@@ -214,11 +225,19 @@ var createLucideIcon = (iconName, iconNode) => {
|
|
|
214
225
|
// ../../node_modules/lucide-react/dist/esm/icons/check.js
|
|
215
226
|
var Check = createLucideIcon("Check", [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]]);
|
|
216
227
|
|
|
228
|
+
// ../../node_modules/lucide-react/dist/esm/icons/chevron-down.js
|
|
229
|
+
var ChevronDown = createLucideIcon("ChevronDown", [
|
|
230
|
+
["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]
|
|
231
|
+
]);
|
|
232
|
+
|
|
217
233
|
// ../../node_modules/lucide-react/dist/esm/icons/chevron-right.js
|
|
218
234
|
var ChevronRight = createLucideIcon("ChevronRight", [
|
|
219
235
|
["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]
|
|
220
236
|
]);
|
|
221
237
|
|
|
238
|
+
// ../../node_modules/lucide-react/dist/esm/icons/chevron-up.js
|
|
239
|
+
var ChevronUp = createLucideIcon("ChevronUp", [["path", { d: "m18 15-6-6-6 6", key: "153udz" }]]);
|
|
240
|
+
|
|
222
241
|
// ../../node_modules/lucide-react/dist/esm/icons/circle.js
|
|
223
242
|
var Circle = createLucideIcon("Circle", [
|
|
224
243
|
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }]
|
|
@@ -1393,7 +1412,7 @@ var getDefaultConfig = () => {
|
|
|
1393
1412
|
* Font Variant Numeric
|
|
1394
1413
|
* @see https://tailwindcss.com/docs/font-variant-numeric
|
|
1395
1414
|
*/
|
|
1396
|
-
"fvn-fraction": ["diagonal-fractions", "stacked-
|
|
1415
|
+
"fvn-fraction": ["diagonal-fractions", "stacked-fractions"],
|
|
1397
1416
|
/**
|
|
1398
1417
|
* Letter Spacing
|
|
1399
1418
|
* @see https://tailwindcss.com/docs/letter-spacing
|
|
@@ -2781,7 +2800,7 @@ var Button = import_react3.default.forwardRef(
|
|
|
2781
2800
|
Button.displayName = "Button";
|
|
2782
2801
|
|
|
2783
2802
|
// ../../node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs
|
|
2784
|
-
var
|
|
2803
|
+
var React31 = __toESM(require("react"), 1);
|
|
2785
2804
|
|
|
2786
2805
|
// ../../node_modules/@radix-ui/primitive/dist/index.mjs
|
|
2787
2806
|
function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {
|
|
@@ -2797,13 +2816,34 @@ function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForD
|
|
|
2797
2816
|
var React2 = __toESM(require("react"), 1);
|
|
2798
2817
|
function setRef(ref, value) {
|
|
2799
2818
|
if (typeof ref === "function") {
|
|
2800
|
-
ref(value);
|
|
2819
|
+
return ref(value);
|
|
2801
2820
|
} else if (ref !== null && ref !== void 0) {
|
|
2802
2821
|
ref.current = value;
|
|
2803
2822
|
}
|
|
2804
2823
|
}
|
|
2805
2824
|
function composeRefs(...refs) {
|
|
2806
|
-
return (node) =>
|
|
2825
|
+
return (node) => {
|
|
2826
|
+
let hasCleanup = false;
|
|
2827
|
+
const cleanups = refs.map((ref) => {
|
|
2828
|
+
const cleanup = setRef(ref, node);
|
|
2829
|
+
if (!hasCleanup && typeof cleanup == "function") {
|
|
2830
|
+
hasCleanup = true;
|
|
2831
|
+
}
|
|
2832
|
+
return cleanup;
|
|
2833
|
+
});
|
|
2834
|
+
if (hasCleanup) {
|
|
2835
|
+
return () => {
|
|
2836
|
+
for (let i = 0; i < cleanups.length; i++) {
|
|
2837
|
+
const cleanup = cleanups[i];
|
|
2838
|
+
if (typeof cleanup == "function") {
|
|
2839
|
+
cleanup();
|
|
2840
|
+
} else {
|
|
2841
|
+
setRef(refs[i], null);
|
|
2842
|
+
}
|
|
2843
|
+
}
|
|
2844
|
+
};
|
|
2845
|
+
}
|
|
2846
|
+
};
|
|
2807
2847
|
}
|
|
2808
2848
|
function useComposedRefs(...refs) {
|
|
2809
2849
|
return React2.useCallback(composeRefs(...refs), refs);
|
|
@@ -2981,78 +3021,15 @@ function dispatchDiscreteCustomEvent(target, event) {
|
|
|
2981
3021
|
}
|
|
2982
3022
|
|
|
2983
3023
|
// ../../node_modules/@radix-ui/react-menu/dist/index.mjs
|
|
2984
|
-
var
|
|
3024
|
+
var React30 = __toESM(require("react"), 1);
|
|
2985
3025
|
|
|
2986
3026
|
// ../../node_modules/@radix-ui/react-collection/dist/index.mjs
|
|
2987
3027
|
var import_react4 = __toESM(require("react"), 1);
|
|
2988
|
-
|
|
2989
|
-
// ../../node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-context/dist/index.mjs
|
|
2990
|
-
var React7 = __toESM(require("react"), 1);
|
|
2991
|
-
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
2992
|
-
function createContextScope2(scopeName, createContextScopeDeps = []) {
|
|
2993
|
-
let defaultContexts = [];
|
|
2994
|
-
function createContext32(rootComponentName, defaultContext) {
|
|
2995
|
-
const BaseContext = React7.createContext(defaultContext);
|
|
2996
|
-
const index2 = defaultContexts.length;
|
|
2997
|
-
defaultContexts = [...defaultContexts, defaultContext];
|
|
2998
|
-
function Provider(props) {
|
|
2999
|
-
const { scope, children, ...context } = props;
|
|
3000
|
-
const Context = scope?.[scopeName][index2] || BaseContext;
|
|
3001
|
-
const value = React7.useMemo(() => context, Object.values(context));
|
|
3002
|
-
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Context.Provider, { value, children });
|
|
3003
|
-
}
|
|
3004
|
-
function useContext22(consumerName, scope) {
|
|
3005
|
-
const Context = scope?.[scopeName][index2] || BaseContext;
|
|
3006
|
-
const context = React7.useContext(Context);
|
|
3007
|
-
if (context) return context;
|
|
3008
|
-
if (defaultContext !== void 0) return defaultContext;
|
|
3009
|
-
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
|
|
3010
|
-
}
|
|
3011
|
-
Provider.displayName = rootComponentName + "Provider";
|
|
3012
|
-
return [Provider, useContext22];
|
|
3013
|
-
}
|
|
3014
|
-
const createScope = () => {
|
|
3015
|
-
const scopeContexts = defaultContexts.map((defaultContext) => {
|
|
3016
|
-
return React7.createContext(defaultContext);
|
|
3017
|
-
});
|
|
3018
|
-
return function useScope(scope) {
|
|
3019
|
-
const contexts = scope?.[scopeName] || scopeContexts;
|
|
3020
|
-
return React7.useMemo(
|
|
3021
|
-
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
|
|
3022
|
-
[scope, contexts]
|
|
3023
|
-
);
|
|
3024
|
-
};
|
|
3025
|
-
};
|
|
3026
|
-
createScope.scopeName = scopeName;
|
|
3027
|
-
return [createContext32, composeContextScopes2(createScope, ...createContextScopeDeps)];
|
|
3028
|
-
}
|
|
3029
|
-
function composeContextScopes2(...scopes) {
|
|
3030
|
-
const baseScope = scopes[0];
|
|
3031
|
-
if (scopes.length === 1) return baseScope;
|
|
3032
|
-
const createScope = () => {
|
|
3033
|
-
const scopeHooks = scopes.map((createScope2) => ({
|
|
3034
|
-
useScope: createScope2(),
|
|
3035
|
-
scopeName: createScope2.scopeName
|
|
3036
|
-
}));
|
|
3037
|
-
return function useComposedScopes(overrideScopes) {
|
|
3038
|
-
const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
|
|
3039
|
-
const scopeProps = useScope(overrideScopes);
|
|
3040
|
-
const currentScope = scopeProps[`__scope${scopeName}`];
|
|
3041
|
-
return { ...nextScopes2, ...currentScope };
|
|
3042
|
-
}, {});
|
|
3043
|
-
return React7.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
|
|
3044
|
-
};
|
|
3045
|
-
};
|
|
3046
|
-
createScope.scopeName = baseScope.scopeName;
|
|
3047
|
-
return createScope;
|
|
3048
|
-
}
|
|
3049
|
-
|
|
3050
|
-
// ../../node_modules/@radix-ui/react-collection/dist/index.mjs
|
|
3051
3028
|
var import_react_slot3 = require("@radix-ui/react-slot");
|
|
3052
|
-
var
|
|
3029
|
+
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
3053
3030
|
function createCollection(name) {
|
|
3054
3031
|
const PROVIDER_NAME = name + "CollectionProvider";
|
|
3055
|
-
const [createCollectionContext, createCollectionScope3] =
|
|
3032
|
+
const [createCollectionContext, createCollectionScope3] = createContextScope(PROVIDER_NAME);
|
|
3056
3033
|
const [CollectionProviderImpl, useCollectionContext] = createCollectionContext(
|
|
3057
3034
|
PROVIDER_NAME,
|
|
3058
3035
|
{ collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
|
|
@@ -3061,7 +3038,7 @@ function createCollection(name) {
|
|
|
3061
3038
|
const { scope, children } = props;
|
|
3062
3039
|
const ref = import_react4.default.useRef(null);
|
|
3063
3040
|
const itemMap = import_react4.default.useRef(/* @__PURE__ */ new Map()).current;
|
|
3064
|
-
return /* @__PURE__ */ (0,
|
|
3041
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(CollectionProviderImpl, { scope, itemMap, collectionRef: ref, children });
|
|
3065
3042
|
};
|
|
3066
3043
|
CollectionProvider.displayName = PROVIDER_NAME;
|
|
3067
3044
|
const COLLECTION_SLOT_NAME = name + "CollectionSlot";
|
|
@@ -3070,7 +3047,7 @@ function createCollection(name) {
|
|
|
3070
3047
|
const { scope, children } = props;
|
|
3071
3048
|
const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);
|
|
3072
3049
|
const composedRefs = useComposedRefs(forwardedRef, context.collectionRef);
|
|
3073
|
-
return /* @__PURE__ */ (0,
|
|
3050
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_react_slot3.Slot, { ref: composedRefs, children });
|
|
3074
3051
|
}
|
|
3075
3052
|
);
|
|
3076
3053
|
CollectionSlot.displayName = COLLECTION_SLOT_NAME;
|
|
@@ -3086,7 +3063,7 @@ function createCollection(name) {
|
|
|
3086
3063
|
context.itemMap.set(ref, { ref, ...itemData });
|
|
3087
3064
|
return () => void context.itemMap.delete(ref);
|
|
3088
3065
|
});
|
|
3089
|
-
return /* @__PURE__ */ (0,
|
|
3066
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_react_slot3.Slot, { ...{ [ITEM_DATA_ATTR]: "" }, ref: composedRefs, children });
|
|
3090
3067
|
}
|
|
3091
3068
|
);
|
|
3092
3069
|
CollectionItemSlot.displayName = ITEM_SLOT_NAME;
|
|
@@ -3112,22 +3089,22 @@ function createCollection(name) {
|
|
|
3112
3089
|
}
|
|
3113
3090
|
|
|
3114
3091
|
// ../../node_modules/@radix-ui/react-direction/dist/index.mjs
|
|
3115
|
-
var
|
|
3116
|
-
var
|
|
3117
|
-
var DirectionContext =
|
|
3092
|
+
var React8 = __toESM(require("react"), 1);
|
|
3093
|
+
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
3094
|
+
var DirectionContext = React8.createContext(void 0);
|
|
3118
3095
|
function useDirection(localDir) {
|
|
3119
|
-
const globalDir =
|
|
3096
|
+
const globalDir = React8.useContext(DirectionContext);
|
|
3120
3097
|
return localDir || globalDir || "ltr";
|
|
3121
3098
|
}
|
|
3122
3099
|
|
|
3123
3100
|
// ../../node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs
|
|
3124
|
-
var
|
|
3101
|
+
var React10 = __toESM(require("react"), 1);
|
|
3125
3102
|
|
|
3126
3103
|
// ../../node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs
|
|
3127
|
-
var
|
|
3104
|
+
var React9 = __toESM(require("react"), 1);
|
|
3128
3105
|
function useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis?.document) {
|
|
3129
3106
|
const onEscapeKeyDown = useCallbackRef(onEscapeKeyDownProp);
|
|
3130
|
-
|
|
3107
|
+
React9.useEffect(() => {
|
|
3131
3108
|
const handleKeyDown = (event) => {
|
|
3132
3109
|
if (event.key === "Escape") {
|
|
3133
3110
|
onEscapeKeyDown(event);
|
|
@@ -3139,18 +3116,18 @@ function useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis?.docum
|
|
|
3139
3116
|
}
|
|
3140
3117
|
|
|
3141
3118
|
// ../../node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs
|
|
3142
|
-
var
|
|
3119
|
+
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
3143
3120
|
var DISMISSABLE_LAYER_NAME = "DismissableLayer";
|
|
3144
3121
|
var CONTEXT_UPDATE = "dismissableLayer.update";
|
|
3145
3122
|
var POINTER_DOWN_OUTSIDE = "dismissableLayer.pointerDownOutside";
|
|
3146
3123
|
var FOCUS_OUTSIDE = "dismissableLayer.focusOutside";
|
|
3147
3124
|
var originalBodyPointerEvents;
|
|
3148
|
-
var DismissableLayerContext =
|
|
3125
|
+
var DismissableLayerContext = React10.createContext({
|
|
3149
3126
|
layers: /* @__PURE__ */ new Set(),
|
|
3150
3127
|
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
3151
3128
|
branches: /* @__PURE__ */ new Set()
|
|
3152
3129
|
});
|
|
3153
|
-
var DismissableLayer =
|
|
3130
|
+
var DismissableLayer = React10.forwardRef(
|
|
3154
3131
|
(props, forwardedRef) => {
|
|
3155
3132
|
const {
|
|
3156
3133
|
disableOutsidePointerEvents = false,
|
|
@@ -3161,10 +3138,10 @@ var DismissableLayer = React11.forwardRef(
|
|
|
3161
3138
|
onDismiss,
|
|
3162
3139
|
...layerProps
|
|
3163
3140
|
} = props;
|
|
3164
|
-
const context =
|
|
3165
|
-
const [node, setNode] =
|
|
3141
|
+
const context = React10.useContext(DismissableLayerContext);
|
|
3142
|
+
const [node, setNode] = React10.useState(null);
|
|
3166
3143
|
const ownerDocument = node?.ownerDocument ?? globalThis?.document;
|
|
3167
|
-
const [, force] =
|
|
3144
|
+
const [, force] = React10.useState({});
|
|
3168
3145
|
const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
|
|
3169
3146
|
const layers = Array.from(context.layers);
|
|
3170
3147
|
const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);
|
|
@@ -3197,7 +3174,7 @@ var DismissableLayer = React11.forwardRef(
|
|
|
3197
3174
|
onDismiss();
|
|
3198
3175
|
}
|
|
3199
3176
|
}, ownerDocument);
|
|
3200
|
-
|
|
3177
|
+
React10.useEffect(() => {
|
|
3201
3178
|
if (!node) return;
|
|
3202
3179
|
if (disableOutsidePointerEvents) {
|
|
3203
3180
|
if (context.layersWithOutsidePointerEventsDisabled.size === 0) {
|
|
@@ -3214,7 +3191,7 @@ var DismissableLayer = React11.forwardRef(
|
|
|
3214
3191
|
}
|
|
3215
3192
|
};
|
|
3216
3193
|
}, [node, ownerDocument, disableOutsidePointerEvents, context]);
|
|
3217
|
-
|
|
3194
|
+
React10.useEffect(() => {
|
|
3218
3195
|
return () => {
|
|
3219
3196
|
if (!node) return;
|
|
3220
3197
|
context.layers.delete(node);
|
|
@@ -3222,12 +3199,12 @@ var DismissableLayer = React11.forwardRef(
|
|
|
3222
3199
|
dispatchUpdate();
|
|
3223
3200
|
};
|
|
3224
3201
|
}, [node, context]);
|
|
3225
|
-
|
|
3202
|
+
React10.useEffect(() => {
|
|
3226
3203
|
const handleUpdate = () => force({});
|
|
3227
3204
|
document.addEventListener(CONTEXT_UPDATE, handleUpdate);
|
|
3228
3205
|
return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);
|
|
3229
3206
|
}, []);
|
|
3230
|
-
return /* @__PURE__ */ (0,
|
|
3207
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
3231
3208
|
Primitive.div,
|
|
3232
3209
|
{
|
|
3233
3210
|
...layerProps,
|
|
@@ -3248,11 +3225,11 @@ var DismissableLayer = React11.forwardRef(
|
|
|
3248
3225
|
);
|
|
3249
3226
|
DismissableLayer.displayName = DISMISSABLE_LAYER_NAME;
|
|
3250
3227
|
var BRANCH_NAME = "DismissableLayerBranch";
|
|
3251
|
-
var DismissableLayerBranch =
|
|
3252
|
-
const context =
|
|
3253
|
-
const ref =
|
|
3228
|
+
var DismissableLayerBranch = React10.forwardRef((props, forwardedRef) => {
|
|
3229
|
+
const context = React10.useContext(DismissableLayerContext);
|
|
3230
|
+
const ref = React10.useRef(null);
|
|
3254
3231
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
3255
|
-
|
|
3232
|
+
React10.useEffect(() => {
|
|
3256
3233
|
const node = ref.current;
|
|
3257
3234
|
if (node) {
|
|
3258
3235
|
context.branches.add(node);
|
|
@@ -3261,15 +3238,15 @@ var DismissableLayerBranch = React11.forwardRef((props, forwardedRef) => {
|
|
|
3261
3238
|
};
|
|
3262
3239
|
}
|
|
3263
3240
|
}, [context.branches]);
|
|
3264
|
-
return /* @__PURE__ */ (0,
|
|
3241
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Primitive.div, { ...props, ref: composedRefs });
|
|
3265
3242
|
});
|
|
3266
3243
|
DismissableLayerBranch.displayName = BRANCH_NAME;
|
|
3267
3244
|
function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis?.document) {
|
|
3268
3245
|
const handlePointerDownOutside = useCallbackRef(onPointerDownOutside);
|
|
3269
|
-
const isPointerInsideReactTreeRef =
|
|
3270
|
-
const handleClickRef =
|
|
3246
|
+
const isPointerInsideReactTreeRef = React10.useRef(false);
|
|
3247
|
+
const handleClickRef = React10.useRef(() => {
|
|
3271
3248
|
});
|
|
3272
|
-
|
|
3249
|
+
React10.useEffect(() => {
|
|
3273
3250
|
const handlePointerDown = (event) => {
|
|
3274
3251
|
if (event.target && !isPointerInsideReactTreeRef.current) {
|
|
3275
3252
|
let handleAndDispatchPointerDownOutsideEvent2 = function() {
|
|
@@ -3310,8 +3287,8 @@ function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis?
|
|
|
3310
3287
|
}
|
|
3311
3288
|
function useFocusOutside(onFocusOutside, ownerDocument = globalThis?.document) {
|
|
3312
3289
|
const handleFocusOutside = useCallbackRef(onFocusOutside);
|
|
3313
|
-
const isFocusInsideReactTreeRef =
|
|
3314
|
-
|
|
3290
|
+
const isFocusInsideReactTreeRef = React10.useRef(false);
|
|
3291
|
+
React10.useEffect(() => {
|
|
3315
3292
|
const handleFocus = (event) => {
|
|
3316
3293
|
if (event.target && !isFocusInsideReactTreeRef.current) {
|
|
3317
3294
|
const eventDetail = { originalEvent: event };
|
|
@@ -3344,10 +3321,10 @@ function handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {
|
|
|
3344
3321
|
}
|
|
3345
3322
|
|
|
3346
3323
|
// ../../node_modules/@radix-ui/react-focus-guards/dist/index.mjs
|
|
3347
|
-
var
|
|
3324
|
+
var React11 = __toESM(require("react"), 1);
|
|
3348
3325
|
var count = 0;
|
|
3349
3326
|
function useFocusGuards() {
|
|
3350
|
-
|
|
3327
|
+
React11.useEffect(() => {
|
|
3351
3328
|
const edgeGuards = document.querySelectorAll("[data-radix-focus-guard]");
|
|
3352
3329
|
document.body.insertAdjacentElement("afterbegin", edgeGuards[0] ?? createFocusGuard());
|
|
3353
3330
|
document.body.insertAdjacentElement("beforeend", edgeGuards[1] ?? createFocusGuard());
|
|
@@ -3372,13 +3349,13 @@ function createFocusGuard() {
|
|
|
3372
3349
|
}
|
|
3373
3350
|
|
|
3374
3351
|
// ../../node_modules/@radix-ui/react-focus-scope/dist/index.mjs
|
|
3375
|
-
var
|
|
3376
|
-
var
|
|
3352
|
+
var React12 = __toESM(require("react"), 1);
|
|
3353
|
+
var import_jsx_runtime7 = require("react/jsx-runtime");
|
|
3377
3354
|
var AUTOFOCUS_ON_MOUNT = "focusScope.autoFocusOnMount";
|
|
3378
3355
|
var AUTOFOCUS_ON_UNMOUNT = "focusScope.autoFocusOnUnmount";
|
|
3379
3356
|
var EVENT_OPTIONS = { bubbles: false, cancelable: true };
|
|
3380
3357
|
var FOCUS_SCOPE_NAME = "FocusScope";
|
|
3381
|
-
var FocusScope =
|
|
3358
|
+
var FocusScope = React12.forwardRef((props, forwardedRef) => {
|
|
3382
3359
|
const {
|
|
3383
3360
|
loop = false,
|
|
3384
3361
|
trapped = false,
|
|
@@ -3386,12 +3363,12 @@ var FocusScope = React13.forwardRef((props, forwardedRef) => {
|
|
|
3386
3363
|
onUnmountAutoFocus: onUnmountAutoFocusProp,
|
|
3387
3364
|
...scopeProps
|
|
3388
3365
|
} = props;
|
|
3389
|
-
const [container, setContainer] =
|
|
3366
|
+
const [container, setContainer] = React12.useState(null);
|
|
3390
3367
|
const onMountAutoFocus = useCallbackRef(onMountAutoFocusProp);
|
|
3391
3368
|
const onUnmountAutoFocus = useCallbackRef(onUnmountAutoFocusProp);
|
|
3392
|
-
const lastFocusedElementRef =
|
|
3369
|
+
const lastFocusedElementRef = React12.useRef(null);
|
|
3393
3370
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setContainer(node));
|
|
3394
|
-
const focusScope =
|
|
3371
|
+
const focusScope = React12.useRef({
|
|
3395
3372
|
paused: false,
|
|
3396
3373
|
pause() {
|
|
3397
3374
|
this.paused = true;
|
|
@@ -3400,7 +3377,7 @@ var FocusScope = React13.forwardRef((props, forwardedRef) => {
|
|
|
3400
3377
|
this.paused = false;
|
|
3401
3378
|
}
|
|
3402
3379
|
}).current;
|
|
3403
|
-
|
|
3380
|
+
React12.useEffect(() => {
|
|
3404
3381
|
if (trapped) {
|
|
3405
3382
|
let handleFocusIn2 = function(event) {
|
|
3406
3383
|
if (focusScope.paused || !container) return;
|
|
@@ -3436,7 +3413,7 @@ var FocusScope = React13.forwardRef((props, forwardedRef) => {
|
|
|
3436
3413
|
};
|
|
3437
3414
|
}
|
|
3438
3415
|
}, [trapped, container, focusScope.paused]);
|
|
3439
|
-
|
|
3416
|
+
React12.useEffect(() => {
|
|
3440
3417
|
if (container) {
|
|
3441
3418
|
focusScopesStack.add(focusScope);
|
|
3442
3419
|
const previouslyFocusedElement = document.activeElement;
|
|
@@ -3467,7 +3444,7 @@ var FocusScope = React13.forwardRef((props, forwardedRef) => {
|
|
|
3467
3444
|
};
|
|
3468
3445
|
}
|
|
3469
3446
|
}, [container, onMountAutoFocus, onUnmountAutoFocus, focusScope]);
|
|
3470
|
-
const handleKeyDown =
|
|
3447
|
+
const handleKeyDown = React12.useCallback(
|
|
3471
3448
|
(event) => {
|
|
3472
3449
|
if (!loop && !trapped) return;
|
|
3473
3450
|
if (focusScope.paused) return;
|
|
@@ -3492,7 +3469,7 @@ var FocusScope = React13.forwardRef((props, forwardedRef) => {
|
|
|
3492
3469
|
},
|
|
3493
3470
|
[loop, trapped, focusScope.paused]
|
|
3494
3471
|
);
|
|
3495
|
-
return /* @__PURE__ */ (0,
|
|
3472
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Primitive.div, { tabIndex: -1, ...scopeProps, ref: composedRefs, onKeyDown: handleKeyDown });
|
|
3496
3473
|
});
|
|
3497
3474
|
FocusScope.displayName = FOCUS_SCOPE_NAME;
|
|
3498
3475
|
function focusFirst(candidates, { select = false } = {}) {
|
|
@@ -3576,18 +3553,18 @@ function removeLinks(items) {
|
|
|
3576
3553
|
}
|
|
3577
3554
|
|
|
3578
3555
|
// ../../node_modules/@radix-ui/react-id/dist/index.mjs
|
|
3579
|
-
var
|
|
3556
|
+
var React14 = __toESM(require("react"), 1);
|
|
3580
3557
|
|
|
3581
3558
|
// ../../node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs
|
|
3582
|
-
var
|
|
3583
|
-
var useLayoutEffect2 = Boolean(globalThis?.document) ?
|
|
3559
|
+
var React13 = __toESM(require("react"), 1);
|
|
3560
|
+
var useLayoutEffect2 = Boolean(globalThis?.document) ? React13.useLayoutEffect : () => {
|
|
3584
3561
|
};
|
|
3585
3562
|
|
|
3586
3563
|
// ../../node_modules/@radix-ui/react-id/dist/index.mjs
|
|
3587
|
-
var useReactId =
|
|
3564
|
+
var useReactId = React14["useId".toString()] || (() => void 0);
|
|
3588
3565
|
var count2 = 0;
|
|
3589
3566
|
function useId(deterministicId) {
|
|
3590
|
-
const [id, setId] =
|
|
3567
|
+
const [id, setId] = React14.useState(useReactId());
|
|
3591
3568
|
useLayoutEffect2(() => {
|
|
3592
3569
|
if (!deterministicId) setId((reactId) => reactId ?? String(count2++));
|
|
3593
3570
|
}, [deterministicId]);
|
|
@@ -3595,7 +3572,7 @@ function useId(deterministicId) {
|
|
|
3595
3572
|
}
|
|
3596
3573
|
|
|
3597
3574
|
// ../../node_modules/@radix-ui/react-popper/dist/index.mjs
|
|
3598
|
-
var
|
|
3575
|
+
var React18 = __toESM(require("react"), 1);
|
|
3599
3576
|
|
|
3600
3577
|
// ../../node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs
|
|
3601
3578
|
var sides = ["top", "right", "bottom", "left"];
|
|
@@ -4696,6 +4673,28 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
4696
4673
|
y
|
|
4697
4674
|
});
|
|
4698
4675
|
}
|
|
4676
|
+
function getWindowScrollBarX(element, rect) {
|
|
4677
|
+
const leftScroll = getNodeScroll(element).scrollLeft;
|
|
4678
|
+
if (!rect) {
|
|
4679
|
+
return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
|
|
4680
|
+
}
|
|
4681
|
+
return rect.left + leftScroll;
|
|
4682
|
+
}
|
|
4683
|
+
function getHTMLOffset(documentElement, scroll, ignoreScrollbarX) {
|
|
4684
|
+
if (ignoreScrollbarX === void 0) {
|
|
4685
|
+
ignoreScrollbarX = false;
|
|
4686
|
+
}
|
|
4687
|
+
const htmlRect = documentElement.getBoundingClientRect();
|
|
4688
|
+
const x = htmlRect.left + scroll.scrollLeft - (ignoreScrollbarX ? 0 : (
|
|
4689
|
+
// RTL <body> scrollbar.
|
|
4690
|
+
getWindowScrollBarX(documentElement, htmlRect)
|
|
4691
|
+
));
|
|
4692
|
+
const y = htmlRect.top + scroll.scrollTop;
|
|
4693
|
+
return {
|
|
4694
|
+
x,
|
|
4695
|
+
y
|
|
4696
|
+
};
|
|
4697
|
+
}
|
|
4699
4698
|
function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
4700
4699
|
let {
|
|
4701
4700
|
elements,
|
|
@@ -4727,23 +4726,17 @@ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
|
4727
4726
|
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
4728
4727
|
}
|
|
4729
4728
|
}
|
|
4729
|
+
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll, true) : createCoords(0);
|
|
4730
4730
|
return {
|
|
4731
4731
|
width: rect.width * scale.x,
|
|
4732
4732
|
height: rect.height * scale.y,
|
|
4733
|
-
x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x,
|
|
4734
|
-
y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y
|
|
4733
|
+
x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
|
|
4734
|
+
y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
|
|
4735
4735
|
};
|
|
4736
4736
|
}
|
|
4737
4737
|
function getClientRects(element) {
|
|
4738
4738
|
return Array.from(element.getClientRects());
|
|
4739
4739
|
}
|
|
4740
|
-
function getWindowScrollBarX(element, rect) {
|
|
4741
|
-
const leftScroll = getNodeScroll(element).scrollLeft;
|
|
4742
|
-
if (!rect) {
|
|
4743
|
-
return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
|
|
4744
|
-
}
|
|
4745
|
-
return rect.left + leftScroll;
|
|
4746
|
-
}
|
|
4747
4740
|
function getDocumentRect(element) {
|
|
4748
4741
|
const html = getDocumentElement(element);
|
|
4749
4742
|
const scroll = getNodeScroll(element);
|
|
@@ -4813,9 +4806,10 @@ function getClientRectFromClippingAncestor(element, clippingAncestor, strategy)
|
|
|
4813
4806
|
} else {
|
|
4814
4807
|
const visualOffsets = getVisualOffsets(element);
|
|
4815
4808
|
rect = {
|
|
4816
|
-
...clippingAncestor,
|
|
4817
4809
|
x: clippingAncestor.x - visualOffsets.x,
|
|
4818
|
-
y: clippingAncestor.y - visualOffsets.y
|
|
4810
|
+
y: clippingAncestor.y - visualOffsets.y,
|
|
4811
|
+
width: clippingAncestor.width,
|
|
4812
|
+
height: clippingAncestor.height
|
|
4819
4813
|
};
|
|
4820
4814
|
}
|
|
4821
4815
|
return rectToClientRect(rect);
|
|
@@ -4910,16 +4904,9 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
|
|
|
4910
4904
|
offsets.x = getWindowScrollBarX(documentElement);
|
|
4911
4905
|
}
|
|
4912
4906
|
}
|
|
4913
|
-
|
|
4914
|
-
|
|
4915
|
-
|
|
4916
|
-
const htmlRect = documentElement.getBoundingClientRect();
|
|
4917
|
-
htmlY = htmlRect.top + scroll.scrollTop;
|
|
4918
|
-
htmlX = htmlRect.left + scroll.scrollLeft - // RTL <body> scrollbar.
|
|
4919
|
-
getWindowScrollBarX(documentElement, htmlRect);
|
|
4920
|
-
}
|
|
4921
|
-
const x = rect.left + scroll.scrollLeft - offsets.x - htmlX;
|
|
4922
|
-
const y = rect.top + scroll.scrollTop - offsets.y - htmlY;
|
|
4907
|
+
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
|
|
4908
|
+
const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
|
|
4909
|
+
const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
|
|
4923
4910
|
return {
|
|
4924
4911
|
x,
|
|
4925
4912
|
y,
|
|
@@ -5158,7 +5145,7 @@ var computePosition2 = (reference, floating, options) => {
|
|
|
5158
5145
|
};
|
|
5159
5146
|
|
|
5160
5147
|
// ../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs
|
|
5161
|
-
var
|
|
5148
|
+
var React15 = __toESM(require("react"), 1);
|
|
5162
5149
|
var import_react5 = require("react");
|
|
5163
5150
|
var ReactDOM2 = __toESM(require("react-dom"), 1);
|
|
5164
5151
|
var index = typeof document !== "undefined" ? import_react5.useLayoutEffect : import_react5.useEffect;
|
|
@@ -5221,7 +5208,7 @@ function roundByDPR(element, value) {
|
|
|
5221
5208
|
return Math.round(value * dpr) / dpr;
|
|
5222
5209
|
}
|
|
5223
5210
|
function useLatestRef(value) {
|
|
5224
|
-
const ref =
|
|
5211
|
+
const ref = React15.useRef(value);
|
|
5225
5212
|
index(() => {
|
|
5226
5213
|
ref.current = value;
|
|
5227
5214
|
});
|
|
@@ -5244,7 +5231,7 @@ function useFloating(options) {
|
|
|
5244
5231
|
whileElementsMounted,
|
|
5245
5232
|
open
|
|
5246
5233
|
} = options;
|
|
5247
|
-
const [data, setData] =
|
|
5234
|
+
const [data, setData] = React15.useState({
|
|
5248
5235
|
x: 0,
|
|
5249
5236
|
y: 0,
|
|
5250
5237
|
strategy,
|
|
@@ -5252,19 +5239,19 @@ function useFloating(options) {
|
|
|
5252
5239
|
middlewareData: {},
|
|
5253
5240
|
isPositioned: false
|
|
5254
5241
|
});
|
|
5255
|
-
const [latestMiddleware, setLatestMiddleware] =
|
|
5242
|
+
const [latestMiddleware, setLatestMiddleware] = React15.useState(middleware);
|
|
5256
5243
|
if (!deepEqual(latestMiddleware, middleware)) {
|
|
5257
5244
|
setLatestMiddleware(middleware);
|
|
5258
5245
|
}
|
|
5259
|
-
const [_reference, _setReference] =
|
|
5260
|
-
const [_floating, _setFloating] =
|
|
5261
|
-
const setReference =
|
|
5246
|
+
const [_reference, _setReference] = React15.useState(null);
|
|
5247
|
+
const [_floating, _setFloating] = React15.useState(null);
|
|
5248
|
+
const setReference = React15.useCallback((node) => {
|
|
5262
5249
|
if (node !== referenceRef.current) {
|
|
5263
5250
|
referenceRef.current = node;
|
|
5264
5251
|
_setReference(node);
|
|
5265
5252
|
}
|
|
5266
5253
|
}, []);
|
|
5267
|
-
const setFloating =
|
|
5254
|
+
const setFloating = React15.useCallback((node) => {
|
|
5268
5255
|
if (node !== floatingRef.current) {
|
|
5269
5256
|
floatingRef.current = node;
|
|
5270
5257
|
_setFloating(node);
|
|
@@ -5272,14 +5259,14 @@ function useFloating(options) {
|
|
|
5272
5259
|
}, []);
|
|
5273
5260
|
const referenceEl = externalReference || _reference;
|
|
5274
5261
|
const floatingEl = externalFloating || _floating;
|
|
5275
|
-
const referenceRef =
|
|
5276
|
-
const floatingRef =
|
|
5277
|
-
const dataRef =
|
|
5262
|
+
const referenceRef = React15.useRef(null);
|
|
5263
|
+
const floatingRef = React15.useRef(null);
|
|
5264
|
+
const dataRef = React15.useRef(data);
|
|
5278
5265
|
const hasWhileElementsMounted = whileElementsMounted != null;
|
|
5279
5266
|
const whileElementsMountedRef = useLatestRef(whileElementsMounted);
|
|
5280
5267
|
const platformRef = useLatestRef(platform2);
|
|
5281
5268
|
const openRef = useLatestRef(open);
|
|
5282
|
-
const update =
|
|
5269
|
+
const update = React15.useCallback(() => {
|
|
5283
5270
|
if (!referenceRef.current || !floatingRef.current) {
|
|
5284
5271
|
return;
|
|
5285
5272
|
}
|
|
@@ -5317,7 +5304,7 @@ function useFloating(options) {
|
|
|
5317
5304
|
}));
|
|
5318
5305
|
}
|
|
5319
5306
|
}, [open]);
|
|
5320
|
-
const isMountedRef =
|
|
5307
|
+
const isMountedRef = React15.useRef(false);
|
|
5321
5308
|
index(() => {
|
|
5322
5309
|
isMountedRef.current = true;
|
|
5323
5310
|
return () => {
|
|
@@ -5334,17 +5321,17 @@ function useFloating(options) {
|
|
|
5334
5321
|
update();
|
|
5335
5322
|
}
|
|
5336
5323
|
}, [referenceEl, floatingEl, update, whileElementsMountedRef, hasWhileElementsMounted]);
|
|
5337
|
-
const refs =
|
|
5324
|
+
const refs = React15.useMemo(() => ({
|
|
5338
5325
|
reference: referenceRef,
|
|
5339
5326
|
floating: floatingRef,
|
|
5340
5327
|
setReference,
|
|
5341
5328
|
setFloating
|
|
5342
5329
|
}), [setReference, setFloating]);
|
|
5343
|
-
const elements =
|
|
5330
|
+
const elements = React15.useMemo(() => ({
|
|
5344
5331
|
reference: referenceEl,
|
|
5345
5332
|
floating: floatingEl
|
|
5346
5333
|
}), [referenceEl, floatingEl]);
|
|
5347
|
-
const floatingStyles =
|
|
5334
|
+
const floatingStyles = React15.useMemo(() => {
|
|
5348
5335
|
const initialStyles = {
|
|
5349
5336
|
position: strategy,
|
|
5350
5337
|
left: 0,
|
|
@@ -5370,7 +5357,7 @@ function useFloating(options) {
|
|
|
5370
5357
|
top: y
|
|
5371
5358
|
};
|
|
5372
5359
|
}, [strategy, transform, elements.floating, data.x, data.y]);
|
|
5373
|
-
return
|
|
5360
|
+
return React15.useMemo(() => ({
|
|
5374
5361
|
...data,
|
|
5375
5362
|
update,
|
|
5376
5363
|
refs,
|
|
@@ -5439,12 +5426,12 @@ var arrow3 = (options, deps) => ({
|
|
|
5439
5426
|
});
|
|
5440
5427
|
|
|
5441
5428
|
// ../../node_modules/@radix-ui/react-arrow/dist/index.mjs
|
|
5442
|
-
var
|
|
5443
|
-
var
|
|
5429
|
+
var React16 = __toESM(require("react"), 1);
|
|
5430
|
+
var import_jsx_runtime8 = require("react/jsx-runtime");
|
|
5444
5431
|
var NAME = "Arrow";
|
|
5445
|
-
var Arrow =
|
|
5432
|
+
var Arrow = React16.forwardRef((props, forwardedRef) => {
|
|
5446
5433
|
const { children, width = 10, height = 5, ...arrowProps } = props;
|
|
5447
|
-
return /* @__PURE__ */ (0,
|
|
5434
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
5448
5435
|
Primitive.svg,
|
|
5449
5436
|
{
|
|
5450
5437
|
...arrowProps,
|
|
@@ -5453,78 +5440,17 @@ var Arrow = React17.forwardRef((props, forwardedRef) => {
|
|
|
5453
5440
|
height,
|
|
5454
5441
|
viewBox: "0 0 30 10",
|
|
5455
5442
|
preserveAspectRatio: "none",
|
|
5456
|
-
children: props.asChild ? children : /* @__PURE__ */ (0,
|
|
5443
|
+
children: props.asChild ? children : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("polygon", { points: "0,0 30,0 15,10" })
|
|
5457
5444
|
}
|
|
5458
5445
|
);
|
|
5459
5446
|
});
|
|
5460
5447
|
Arrow.displayName = NAME;
|
|
5461
5448
|
var Root = Arrow;
|
|
5462
5449
|
|
|
5463
|
-
// ../../node_modules/@radix-ui/react-popper/node_modules/@radix-ui/react-context/dist/index.mjs
|
|
5464
|
-
var React18 = __toESM(require("react"), 1);
|
|
5465
|
-
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
5466
|
-
function createContextScope3(scopeName, createContextScopeDeps = []) {
|
|
5467
|
-
let defaultContexts = [];
|
|
5468
|
-
function createContext32(rootComponentName, defaultContext) {
|
|
5469
|
-
const BaseContext = React18.createContext(defaultContext);
|
|
5470
|
-
const index2 = defaultContexts.length;
|
|
5471
|
-
defaultContexts = [...defaultContexts, defaultContext];
|
|
5472
|
-
function Provider(props) {
|
|
5473
|
-
const { scope, children, ...context } = props;
|
|
5474
|
-
const Context = scope?.[scopeName][index2] || BaseContext;
|
|
5475
|
-
const value = React18.useMemo(() => context, Object.values(context));
|
|
5476
|
-
return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Context.Provider, { value, children });
|
|
5477
|
-
}
|
|
5478
|
-
function useContext22(consumerName, scope) {
|
|
5479
|
-
const Context = scope?.[scopeName][index2] || BaseContext;
|
|
5480
|
-
const context = React18.useContext(Context);
|
|
5481
|
-
if (context) return context;
|
|
5482
|
-
if (defaultContext !== void 0) return defaultContext;
|
|
5483
|
-
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
|
|
5484
|
-
}
|
|
5485
|
-
Provider.displayName = rootComponentName + "Provider";
|
|
5486
|
-
return [Provider, useContext22];
|
|
5487
|
-
}
|
|
5488
|
-
const createScope = () => {
|
|
5489
|
-
const scopeContexts = defaultContexts.map((defaultContext) => {
|
|
5490
|
-
return React18.createContext(defaultContext);
|
|
5491
|
-
});
|
|
5492
|
-
return function useScope(scope) {
|
|
5493
|
-
const contexts = scope?.[scopeName] || scopeContexts;
|
|
5494
|
-
return React18.useMemo(
|
|
5495
|
-
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
|
|
5496
|
-
[scope, contexts]
|
|
5497
|
-
);
|
|
5498
|
-
};
|
|
5499
|
-
};
|
|
5500
|
-
createScope.scopeName = scopeName;
|
|
5501
|
-
return [createContext32, composeContextScopes3(createScope, ...createContextScopeDeps)];
|
|
5502
|
-
}
|
|
5503
|
-
function composeContextScopes3(...scopes) {
|
|
5504
|
-
const baseScope = scopes[0];
|
|
5505
|
-
if (scopes.length === 1) return baseScope;
|
|
5506
|
-
const createScope = () => {
|
|
5507
|
-
const scopeHooks = scopes.map((createScope2) => ({
|
|
5508
|
-
useScope: createScope2(),
|
|
5509
|
-
scopeName: createScope2.scopeName
|
|
5510
|
-
}));
|
|
5511
|
-
return function useComposedScopes(overrideScopes) {
|
|
5512
|
-
const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
|
|
5513
|
-
const scopeProps = useScope(overrideScopes);
|
|
5514
|
-
const currentScope = scopeProps[`__scope${scopeName}`];
|
|
5515
|
-
return { ...nextScopes2, ...currentScope };
|
|
5516
|
-
}, {});
|
|
5517
|
-
return React18.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
|
|
5518
|
-
};
|
|
5519
|
-
};
|
|
5520
|
-
createScope.scopeName = baseScope.scopeName;
|
|
5521
|
-
return createScope;
|
|
5522
|
-
}
|
|
5523
|
-
|
|
5524
5450
|
// ../../node_modules/@radix-ui/react-use-size/dist/index.mjs
|
|
5525
|
-
var
|
|
5451
|
+
var React17 = __toESM(require("react"), 1);
|
|
5526
5452
|
function useSize(element) {
|
|
5527
|
-
const [size4, setSize] =
|
|
5453
|
+
const [size4, setSize] = React17.useState(void 0);
|
|
5528
5454
|
useLayoutEffect2(() => {
|
|
5529
5455
|
if (element) {
|
|
5530
5456
|
setSize({ width: element.offsetWidth, height: element.offsetHeight });
|
|
@@ -5559,33 +5485,33 @@ function useSize(element) {
|
|
|
5559
5485
|
}
|
|
5560
5486
|
|
|
5561
5487
|
// ../../node_modules/@radix-ui/react-popper/dist/index.mjs
|
|
5562
|
-
var
|
|
5488
|
+
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
5563
5489
|
var POPPER_NAME = "Popper";
|
|
5564
|
-
var [createPopperContext, createPopperScope] =
|
|
5490
|
+
var [createPopperContext, createPopperScope] = createContextScope(POPPER_NAME);
|
|
5565
5491
|
var [PopperProvider, usePopperContext] = createPopperContext(POPPER_NAME);
|
|
5566
5492
|
var Popper = (props) => {
|
|
5567
5493
|
const { __scopePopper, children } = props;
|
|
5568
|
-
const [anchor, setAnchor] =
|
|
5569
|
-
return /* @__PURE__ */ (0,
|
|
5494
|
+
const [anchor, setAnchor] = React18.useState(null);
|
|
5495
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(PopperProvider, { scope: __scopePopper, anchor, onAnchorChange: setAnchor, children });
|
|
5570
5496
|
};
|
|
5571
5497
|
Popper.displayName = POPPER_NAME;
|
|
5572
5498
|
var ANCHOR_NAME = "PopperAnchor";
|
|
5573
|
-
var PopperAnchor =
|
|
5499
|
+
var PopperAnchor = React18.forwardRef(
|
|
5574
5500
|
(props, forwardedRef) => {
|
|
5575
5501
|
const { __scopePopper, virtualRef, ...anchorProps } = props;
|
|
5576
5502
|
const context = usePopperContext(ANCHOR_NAME, __scopePopper);
|
|
5577
|
-
const ref =
|
|
5503
|
+
const ref = React18.useRef(null);
|
|
5578
5504
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
5579
|
-
|
|
5505
|
+
React18.useEffect(() => {
|
|
5580
5506
|
context.onAnchorChange(virtualRef?.current || ref.current);
|
|
5581
5507
|
});
|
|
5582
|
-
return virtualRef ? null : /* @__PURE__ */ (0,
|
|
5508
|
+
return virtualRef ? null : /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Primitive.div, { ...anchorProps, ref: composedRefs });
|
|
5583
5509
|
}
|
|
5584
5510
|
);
|
|
5585
5511
|
PopperAnchor.displayName = ANCHOR_NAME;
|
|
5586
5512
|
var CONTENT_NAME = "PopperContent";
|
|
5587
5513
|
var [PopperContentProvider, useContentContext] = createPopperContext(CONTENT_NAME);
|
|
5588
|
-
var PopperContent =
|
|
5514
|
+
var PopperContent = React18.forwardRef(
|
|
5589
5515
|
(props, forwardedRef) => {
|
|
5590
5516
|
const {
|
|
5591
5517
|
__scopePopper,
|
|
@@ -5604,9 +5530,9 @@ var PopperContent = React20.forwardRef(
|
|
|
5604
5530
|
...contentProps
|
|
5605
5531
|
} = props;
|
|
5606
5532
|
const context = usePopperContext(CONTENT_NAME, __scopePopper);
|
|
5607
|
-
const [content, setContent] =
|
|
5533
|
+
const [content, setContent] = React18.useState(null);
|
|
5608
5534
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setContent(node));
|
|
5609
|
-
const [arrow4, setArrow] =
|
|
5535
|
+
const [arrow4, setArrow] = React18.useState(null);
|
|
5610
5536
|
const arrowSize = useSize(arrow4);
|
|
5611
5537
|
const arrowWidth = arrowSize?.width ?? 0;
|
|
5612
5538
|
const arrowHeight = arrowSize?.height ?? 0;
|
|
@@ -5668,11 +5594,11 @@ var PopperContent = React20.forwardRef(
|
|
|
5668
5594
|
const arrowX = middlewareData.arrow?.x;
|
|
5669
5595
|
const arrowY = middlewareData.arrow?.y;
|
|
5670
5596
|
const cannotCenterArrow = middlewareData.arrow?.centerOffset !== 0;
|
|
5671
|
-
const [contentZIndex, setContentZIndex] =
|
|
5597
|
+
const [contentZIndex, setContentZIndex] = React18.useState();
|
|
5672
5598
|
useLayoutEffect2(() => {
|
|
5673
5599
|
if (content) setContentZIndex(window.getComputedStyle(content).zIndex);
|
|
5674
5600
|
}, [content]);
|
|
5675
|
-
return /* @__PURE__ */ (0,
|
|
5601
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
5676
5602
|
"div",
|
|
5677
5603
|
{
|
|
5678
5604
|
ref: refs.setFloating,
|
|
@@ -5696,7 +5622,7 @@ var PopperContent = React20.forwardRef(
|
|
|
5696
5622
|
}
|
|
5697
5623
|
},
|
|
5698
5624
|
dir: props.dir,
|
|
5699
|
-
children: /* @__PURE__ */ (0,
|
|
5625
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
5700
5626
|
PopperContentProvider,
|
|
5701
5627
|
{
|
|
5702
5628
|
scope: __scopePopper,
|
|
@@ -5705,7 +5631,7 @@ var PopperContent = React20.forwardRef(
|
|
|
5705
5631
|
arrowX,
|
|
5706
5632
|
arrowY,
|
|
5707
5633
|
shouldHideArrow: cannotCenterArrow,
|
|
5708
|
-
children: /* @__PURE__ */ (0,
|
|
5634
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
5709
5635
|
Primitive.div,
|
|
5710
5636
|
{
|
|
5711
5637
|
"data-side": placedSide,
|
|
@@ -5734,7 +5660,7 @@ var OPPOSITE_SIDE = {
|
|
|
5734
5660
|
bottom: "top",
|
|
5735
5661
|
left: "right"
|
|
5736
5662
|
};
|
|
5737
|
-
var PopperArrow =
|
|
5663
|
+
var PopperArrow = React18.forwardRef(function PopperArrow2(props, forwardedRef) {
|
|
5738
5664
|
const { __scopePopper, ...arrowProps } = props;
|
|
5739
5665
|
const contentContext = useContentContext(ARROW_NAME, __scopePopper);
|
|
5740
5666
|
const baseSide = OPPOSITE_SIDE[contentContext.placedSide];
|
|
@@ -5742,7 +5668,7 @@ var PopperArrow = React20.forwardRef(function PopperArrow2(props, forwardedRef)
|
|
|
5742
5668
|
// we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)
|
|
5743
5669
|
// doesn't report size as we'd expect on SVG elements.
|
|
5744
5670
|
// it reports their bounding box which is effectively the largest path inside the SVG.
|
|
5745
|
-
/* @__PURE__ */ (0,
|
|
5671
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
5746
5672
|
"span",
|
|
5747
5673
|
{
|
|
5748
5674
|
ref: contentContext.onArrowChange,
|
|
@@ -5765,7 +5691,7 @@ var PopperArrow = React20.forwardRef(function PopperArrow2(props, forwardedRef)
|
|
|
5765
5691
|
}[contentContext.placedSide],
|
|
5766
5692
|
visibility: contentContext.shouldHideArrow ? "hidden" : void 0
|
|
5767
5693
|
},
|
|
5768
|
-
children: /* @__PURE__ */ (0,
|
|
5694
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
5769
5695
|
Root,
|
|
5770
5696
|
{
|
|
5771
5697
|
...arrowProps,
|
|
@@ -5826,24 +5752,24 @@ var Content = PopperContent;
|
|
|
5826
5752
|
var Arrow2 = PopperArrow;
|
|
5827
5753
|
|
|
5828
5754
|
// ../../node_modules/@radix-ui/react-portal/dist/index.mjs
|
|
5829
|
-
var
|
|
5755
|
+
var React19 = __toESM(require("react"), 1);
|
|
5830
5756
|
var import_react_dom2 = __toESM(require("react-dom"), 1);
|
|
5831
|
-
var
|
|
5757
|
+
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
5832
5758
|
var PORTAL_NAME = "Portal";
|
|
5833
|
-
var Portal =
|
|
5759
|
+
var Portal = React19.forwardRef((props, forwardedRef) => {
|
|
5834
5760
|
const { container: containerProp, ...portalProps } = props;
|
|
5835
|
-
const [mounted, setMounted] =
|
|
5761
|
+
const [mounted, setMounted] = React19.useState(false);
|
|
5836
5762
|
useLayoutEffect2(() => setMounted(true), []);
|
|
5837
5763
|
const container = containerProp || mounted && globalThis?.document?.body;
|
|
5838
|
-
return container ? import_react_dom2.default.createPortal(/* @__PURE__ */ (0,
|
|
5764
|
+
return container ? import_react_dom2.default.createPortal(/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Primitive.div, { ...portalProps, ref: forwardedRef }), container) : null;
|
|
5839
5765
|
});
|
|
5840
5766
|
Portal.displayName = PORTAL_NAME;
|
|
5841
5767
|
|
|
5842
5768
|
// ../../node_modules/@radix-ui/react-presence/dist/index.mjs
|
|
5843
5769
|
var React22 = __toESM(require("react"), 1);
|
|
5844
|
-
var
|
|
5770
|
+
var React20 = __toESM(require("react"), 1);
|
|
5845
5771
|
function useStateMachine(initialState, machine) {
|
|
5846
|
-
return
|
|
5772
|
+
return React20.useReducer((state, event) => {
|
|
5847
5773
|
const nextState = machine[state][event];
|
|
5848
5774
|
return nextState ?? state;
|
|
5849
5775
|
}, initialState);
|
|
@@ -5966,87 +5892,24 @@ function getElementRef(element) {
|
|
|
5966
5892
|
}
|
|
5967
5893
|
|
|
5968
5894
|
// ../../node_modules/@radix-ui/react-roving-focus/dist/index.mjs
|
|
5969
|
-
var
|
|
5970
|
-
|
|
5971
|
-
// ../../node_modules/@radix-ui/react-roving-focus/node_modules/@radix-ui/react-context/dist/index.mjs
|
|
5972
|
-
var React24 = __toESM(require("react"), 1);
|
|
5973
|
-
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
5974
|
-
function createContextScope4(scopeName, createContextScopeDeps = []) {
|
|
5975
|
-
let defaultContexts = [];
|
|
5976
|
-
function createContext32(rootComponentName, defaultContext) {
|
|
5977
|
-
const BaseContext = React24.createContext(defaultContext);
|
|
5978
|
-
const index2 = defaultContexts.length;
|
|
5979
|
-
defaultContexts = [...defaultContexts, defaultContext];
|
|
5980
|
-
function Provider(props) {
|
|
5981
|
-
const { scope, children, ...context } = props;
|
|
5982
|
-
const Context = scope?.[scopeName][index2] || BaseContext;
|
|
5983
|
-
const value = React24.useMemo(() => context, Object.values(context));
|
|
5984
|
-
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Context.Provider, { value, children });
|
|
5985
|
-
}
|
|
5986
|
-
function useContext22(consumerName, scope) {
|
|
5987
|
-
const Context = scope?.[scopeName][index2] || BaseContext;
|
|
5988
|
-
const context = React24.useContext(Context);
|
|
5989
|
-
if (context) return context;
|
|
5990
|
-
if (defaultContext !== void 0) return defaultContext;
|
|
5991
|
-
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
|
|
5992
|
-
}
|
|
5993
|
-
Provider.displayName = rootComponentName + "Provider";
|
|
5994
|
-
return [Provider, useContext22];
|
|
5995
|
-
}
|
|
5996
|
-
const createScope = () => {
|
|
5997
|
-
const scopeContexts = defaultContexts.map((defaultContext) => {
|
|
5998
|
-
return React24.createContext(defaultContext);
|
|
5999
|
-
});
|
|
6000
|
-
return function useScope(scope) {
|
|
6001
|
-
const contexts = scope?.[scopeName] || scopeContexts;
|
|
6002
|
-
return React24.useMemo(
|
|
6003
|
-
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
|
|
6004
|
-
[scope, contexts]
|
|
6005
|
-
);
|
|
6006
|
-
};
|
|
6007
|
-
};
|
|
6008
|
-
createScope.scopeName = scopeName;
|
|
6009
|
-
return [createContext32, composeContextScopes4(createScope, ...createContextScopeDeps)];
|
|
6010
|
-
}
|
|
6011
|
-
function composeContextScopes4(...scopes) {
|
|
6012
|
-
const baseScope = scopes[0];
|
|
6013
|
-
if (scopes.length === 1) return baseScope;
|
|
6014
|
-
const createScope = () => {
|
|
6015
|
-
const scopeHooks = scopes.map((createScope2) => ({
|
|
6016
|
-
useScope: createScope2(),
|
|
6017
|
-
scopeName: createScope2.scopeName
|
|
6018
|
-
}));
|
|
6019
|
-
return function useComposedScopes(overrideScopes) {
|
|
6020
|
-
const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
|
|
6021
|
-
const scopeProps = useScope(overrideScopes);
|
|
6022
|
-
const currentScope = scopeProps[`__scope${scopeName}`];
|
|
6023
|
-
return { ...nextScopes2, ...currentScope };
|
|
6024
|
-
}, {});
|
|
6025
|
-
return React24.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
|
|
6026
|
-
};
|
|
6027
|
-
};
|
|
6028
|
-
createScope.scopeName = baseScope.scopeName;
|
|
6029
|
-
return createScope;
|
|
6030
|
-
}
|
|
6031
|
-
|
|
6032
|
-
// ../../node_modules/@radix-ui/react-roving-focus/dist/index.mjs
|
|
6033
|
-
var import_jsx_runtime14 = require("react/jsx-runtime");
|
|
5895
|
+
var React21 = __toESM(require("react"), 1);
|
|
5896
|
+
var import_jsx_runtime11 = require("react/jsx-runtime");
|
|
6034
5897
|
var ENTRY_FOCUS = "rovingFocusGroup.onEntryFocus";
|
|
6035
5898
|
var EVENT_OPTIONS2 = { bubbles: false, cancelable: true };
|
|
6036
5899
|
var GROUP_NAME = "RovingFocusGroup";
|
|
6037
5900
|
var [Collection, useCollection, createCollectionScope] = createCollection(GROUP_NAME);
|
|
6038
|
-
var [createRovingFocusGroupContext, createRovingFocusGroupScope] =
|
|
5901
|
+
var [createRovingFocusGroupContext, createRovingFocusGroupScope] = createContextScope(
|
|
6039
5902
|
GROUP_NAME,
|
|
6040
5903
|
[createCollectionScope]
|
|
6041
5904
|
);
|
|
6042
5905
|
var [RovingFocusProvider, useRovingFocusContext] = createRovingFocusGroupContext(GROUP_NAME);
|
|
6043
|
-
var RovingFocusGroup =
|
|
5906
|
+
var RovingFocusGroup = React21.forwardRef(
|
|
6044
5907
|
(props, forwardedRef) => {
|
|
6045
|
-
return /* @__PURE__ */ (0,
|
|
5908
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Collection.Provider, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Collection.Slot, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(RovingFocusGroupImpl, { ...props, ref: forwardedRef }) }) });
|
|
6046
5909
|
}
|
|
6047
5910
|
);
|
|
6048
5911
|
RovingFocusGroup.displayName = GROUP_NAME;
|
|
6049
|
-
var RovingFocusGroupImpl =
|
|
5912
|
+
var RovingFocusGroupImpl = React21.forwardRef((props, forwardedRef) => {
|
|
6050
5913
|
const {
|
|
6051
5914
|
__scopeRovingFocusGroup,
|
|
6052
5915
|
orientation,
|
|
@@ -6059,7 +5922,7 @@ var RovingFocusGroupImpl = React25.forwardRef((props, forwardedRef) => {
|
|
|
6059
5922
|
preventScrollOnEntryFocus = false,
|
|
6060
5923
|
...groupProps
|
|
6061
5924
|
} = props;
|
|
6062
|
-
const ref =
|
|
5925
|
+
const ref = React21.useRef(null);
|
|
6063
5926
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
6064
5927
|
const direction = useDirection(dir);
|
|
6065
5928
|
const [currentTabStopId = null, setCurrentTabStopId] = useControllableState({
|
|
@@ -6067,19 +5930,19 @@ var RovingFocusGroupImpl = React25.forwardRef((props, forwardedRef) => {
|
|
|
6067
5930
|
defaultProp: defaultCurrentTabStopId,
|
|
6068
5931
|
onChange: onCurrentTabStopIdChange
|
|
6069
5932
|
});
|
|
6070
|
-
const [isTabbingBackOut, setIsTabbingBackOut] =
|
|
5933
|
+
const [isTabbingBackOut, setIsTabbingBackOut] = React21.useState(false);
|
|
6071
5934
|
const handleEntryFocus = useCallbackRef(onEntryFocus);
|
|
6072
5935
|
const getItems = useCollection(__scopeRovingFocusGroup);
|
|
6073
|
-
const isClickFocusRef =
|
|
6074
|
-
const [focusableItemsCount, setFocusableItemsCount] =
|
|
6075
|
-
|
|
5936
|
+
const isClickFocusRef = React21.useRef(false);
|
|
5937
|
+
const [focusableItemsCount, setFocusableItemsCount] = React21.useState(0);
|
|
5938
|
+
React21.useEffect(() => {
|
|
6076
5939
|
const node = ref.current;
|
|
6077
5940
|
if (node) {
|
|
6078
5941
|
node.addEventListener(ENTRY_FOCUS, handleEntryFocus);
|
|
6079
5942
|
return () => node.removeEventListener(ENTRY_FOCUS, handleEntryFocus);
|
|
6080
5943
|
}
|
|
6081
5944
|
}, [handleEntryFocus]);
|
|
6082
|
-
return /* @__PURE__ */ (0,
|
|
5945
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
6083
5946
|
RovingFocusProvider,
|
|
6084
5947
|
{
|
|
6085
5948
|
scope: __scopeRovingFocusGroup,
|
|
@@ -6087,20 +5950,20 @@ var RovingFocusGroupImpl = React25.forwardRef((props, forwardedRef) => {
|
|
|
6087
5950
|
dir: direction,
|
|
6088
5951
|
loop,
|
|
6089
5952
|
currentTabStopId,
|
|
6090
|
-
onItemFocus:
|
|
5953
|
+
onItemFocus: React21.useCallback(
|
|
6091
5954
|
(tabStopId) => setCurrentTabStopId(tabStopId),
|
|
6092
5955
|
[setCurrentTabStopId]
|
|
6093
5956
|
),
|
|
6094
|
-
onItemShiftTab:
|
|
6095
|
-
onFocusableItemAdd:
|
|
5957
|
+
onItemShiftTab: React21.useCallback(() => setIsTabbingBackOut(true), []),
|
|
5958
|
+
onFocusableItemAdd: React21.useCallback(
|
|
6096
5959
|
() => setFocusableItemsCount((prevCount) => prevCount + 1),
|
|
6097
5960
|
[]
|
|
6098
5961
|
),
|
|
6099
|
-
onFocusableItemRemove:
|
|
5962
|
+
onFocusableItemRemove: React21.useCallback(
|
|
6100
5963
|
() => setFocusableItemsCount((prevCount) => prevCount - 1),
|
|
6101
5964
|
[]
|
|
6102
5965
|
),
|
|
6103
|
-
children: /* @__PURE__ */ (0,
|
|
5966
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
6104
5967
|
Primitive.div,
|
|
6105
5968
|
{
|
|
6106
5969
|
tabIndex: isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0,
|
|
@@ -6136,7 +5999,7 @@ var RovingFocusGroupImpl = React25.forwardRef((props, forwardedRef) => {
|
|
|
6136
5999
|
);
|
|
6137
6000
|
});
|
|
6138
6001
|
var ITEM_NAME = "RovingFocusGroupItem";
|
|
6139
|
-
var RovingFocusGroupItem =
|
|
6002
|
+
var RovingFocusGroupItem = React21.forwardRef(
|
|
6140
6003
|
(props, forwardedRef) => {
|
|
6141
6004
|
const {
|
|
6142
6005
|
__scopeRovingFocusGroup,
|
|
@@ -6151,20 +6014,20 @@ var RovingFocusGroupItem = React25.forwardRef(
|
|
|
6151
6014
|
const isCurrentTabStop = context.currentTabStopId === id;
|
|
6152
6015
|
const getItems = useCollection(__scopeRovingFocusGroup);
|
|
6153
6016
|
const { onFocusableItemAdd, onFocusableItemRemove } = context;
|
|
6154
|
-
|
|
6017
|
+
React21.useEffect(() => {
|
|
6155
6018
|
if (focusable) {
|
|
6156
6019
|
onFocusableItemAdd();
|
|
6157
6020
|
return () => onFocusableItemRemove();
|
|
6158
6021
|
}
|
|
6159
6022
|
}, [focusable, onFocusableItemAdd, onFocusableItemRemove]);
|
|
6160
|
-
return /* @__PURE__ */ (0,
|
|
6023
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
6161
6024
|
Collection.ItemSlot,
|
|
6162
6025
|
{
|
|
6163
6026
|
scope: __scopeRovingFocusGroup,
|
|
6164
6027
|
id,
|
|
6165
6028
|
focusable,
|
|
6166
6029
|
active,
|
|
6167
|
-
children: /* @__PURE__ */ (0,
|
|
6030
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
6168
6031
|
Primitive.span,
|
|
6169
6032
|
{
|
|
6170
6033
|
tabIndex: isCurrentTabStop ? 0 : -1,
|
|
@@ -6395,10 +6258,10 @@ function __spreadArray(to, from, pack) {
|
|
|
6395
6258
|
}
|
|
6396
6259
|
|
|
6397
6260
|
// ../../node_modules/react-remove-scroll/dist/es2015/Combination.js
|
|
6398
|
-
var
|
|
6261
|
+
var React29 = __toESM(require("react"));
|
|
6399
6262
|
|
|
6400
6263
|
// ../../node_modules/react-remove-scroll/dist/es2015/UI.js
|
|
6401
|
-
var
|
|
6264
|
+
var React25 = __toESM(require("react"));
|
|
6402
6265
|
|
|
6403
6266
|
// ../../node_modules/react-remove-scroll-bar/dist/es2015/constants.js
|
|
6404
6267
|
var zeroRightClassName = "right-scroll-bar-position";
|
|
@@ -6445,8 +6308,8 @@ function useCallbackRef2(initialValue, callback) {
|
|
|
6445
6308
|
}
|
|
6446
6309
|
|
|
6447
6310
|
// ../../node_modules/use-callback-ref/dist/es2015/useMergeRef.js
|
|
6448
|
-
var
|
|
6449
|
-
var useIsomorphicLayoutEffect = typeof window !== "undefined" ?
|
|
6311
|
+
var React23 = __toESM(require("react"));
|
|
6312
|
+
var useIsomorphicLayoutEffect = typeof window !== "undefined" ? React23.useLayoutEffect : React23.useEffect;
|
|
6450
6313
|
var currentValues = /* @__PURE__ */ new WeakMap();
|
|
6451
6314
|
function useMergeRefs(refs, defaultValue) {
|
|
6452
6315
|
var callbackRef = useCallbackRef2(defaultValue || null, function(newValue) {
|
|
@@ -6563,7 +6426,7 @@ function createSidecarMedium(options) {
|
|
|
6563
6426
|
}
|
|
6564
6427
|
|
|
6565
6428
|
// ../../node_modules/use-sidecar/dist/es2015/exports.js
|
|
6566
|
-
var
|
|
6429
|
+
var React24 = __toESM(require("react"));
|
|
6567
6430
|
var SideCar = function(_a) {
|
|
6568
6431
|
var sideCar = _a.sideCar, rest = __rest(_a, ["sideCar"]);
|
|
6569
6432
|
if (!sideCar) {
|
|
@@ -6573,7 +6436,7 @@ var SideCar = function(_a) {
|
|
|
6573
6436
|
if (!Target) {
|
|
6574
6437
|
throw new Error("Sidecar medium not found");
|
|
6575
6438
|
}
|
|
6576
|
-
return
|
|
6439
|
+
return React24.createElement(Target, __assign({}, rest));
|
|
6577
6440
|
};
|
|
6578
6441
|
SideCar.isSideCarExport = true;
|
|
6579
6442
|
function exportSidecar(medium, exported) {
|
|
@@ -6588,9 +6451,9 @@ var effectCar = createSidecarMedium();
|
|
|
6588
6451
|
var nothing = function() {
|
|
6589
6452
|
return;
|
|
6590
6453
|
};
|
|
6591
|
-
var RemoveScroll =
|
|
6592
|
-
var ref =
|
|
6593
|
-
var _a =
|
|
6454
|
+
var RemoveScroll = React25.forwardRef(function(props, parentRef) {
|
|
6455
|
+
var ref = React25.useRef(null);
|
|
6456
|
+
var _a = React25.useState({
|
|
6594
6457
|
onScrollCapture: nothing,
|
|
6595
6458
|
onWheelCapture: nothing,
|
|
6596
6459
|
onTouchMoveCapture: nothing
|
|
@@ -6599,11 +6462,11 @@ var RemoveScroll = React28.forwardRef(function(props, parentRef) {
|
|
|
6599
6462
|
var SideCar2 = sideCar;
|
|
6600
6463
|
var containerRef = useMergeRefs([ref, parentRef]);
|
|
6601
6464
|
var containerProps = __assign(__assign({}, rest), callbacks);
|
|
6602
|
-
return
|
|
6603
|
-
|
|
6465
|
+
return React25.createElement(
|
|
6466
|
+
React25.Fragment,
|
|
6604
6467
|
null,
|
|
6605
|
-
enabled &&
|
|
6606
|
-
forwardProps ?
|
|
6468
|
+
enabled && React25.createElement(SideCar2, { sideCar: effectCar, removeScrollBar, shards, noIsolation, inert, setCallbacks, allowPinchZoom: !!allowPinchZoom, lockRef: ref, gapMode }),
|
|
6469
|
+
forwardProps ? React25.cloneElement(React25.Children.only(children), __assign(__assign({}, containerProps), { ref: containerRef })) : React25.createElement(Container, __assign({}, containerProps, { className, ref: containerRef }), children)
|
|
6607
6470
|
);
|
|
6608
6471
|
});
|
|
6609
6472
|
RemoveScroll.defaultProps = {
|
|
@@ -6617,13 +6480,13 @@ RemoveScroll.classNames = {
|
|
|
6617
6480
|
};
|
|
6618
6481
|
|
|
6619
6482
|
// ../../node_modules/react-remove-scroll/dist/es2015/SideEffect.js
|
|
6620
|
-
var
|
|
6483
|
+
var React28 = __toESM(require("react"));
|
|
6621
6484
|
|
|
6622
6485
|
// ../../node_modules/react-remove-scroll-bar/dist/es2015/component.js
|
|
6623
|
-
var
|
|
6486
|
+
var React27 = __toESM(require("react"));
|
|
6624
6487
|
|
|
6625
6488
|
// ../../node_modules/react-style-singleton/dist/es2015/hook.js
|
|
6626
|
-
var
|
|
6489
|
+
var React26 = __toESM(require("react"));
|
|
6627
6490
|
|
|
6628
6491
|
// ../../node_modules/get-nonce/dist/es2015/index.js
|
|
6629
6492
|
var currentNonce;
|
|
@@ -6687,7 +6550,7 @@ var stylesheetSingleton = function() {
|
|
|
6687
6550
|
var styleHookSingleton = function() {
|
|
6688
6551
|
var sheet = stylesheetSingleton();
|
|
6689
6552
|
return function(styles, isDynamic) {
|
|
6690
|
-
|
|
6553
|
+
React26.useEffect(function() {
|
|
6691
6554
|
sheet.add(styles);
|
|
6692
6555
|
return function() {
|
|
6693
6556
|
sheet.remove();
|
|
@@ -6761,7 +6624,7 @@ var getCurrentUseCounter = function() {
|
|
|
6761
6624
|
return isFinite(counter) ? counter : 0;
|
|
6762
6625
|
};
|
|
6763
6626
|
var useLockAttribute = function() {
|
|
6764
|
-
|
|
6627
|
+
React27.useEffect(function() {
|
|
6765
6628
|
document.body.setAttribute(lockAttribute, (getCurrentUseCounter() + 1).toString());
|
|
6766
6629
|
return function() {
|
|
6767
6630
|
var newCounter = getCurrentUseCounter() - 1;
|
|
@@ -6776,10 +6639,10 @@ var useLockAttribute = function() {
|
|
|
6776
6639
|
var RemoveScrollBar = function(_a) {
|
|
6777
6640
|
var noRelative = _a.noRelative, noImportant = _a.noImportant, _b = _a.gapMode, gapMode = _b === void 0 ? "margin" : _b;
|
|
6778
6641
|
useLockAttribute();
|
|
6779
|
-
var gap =
|
|
6642
|
+
var gap = React27.useMemo(function() {
|
|
6780
6643
|
return getGapWidth(gapMode);
|
|
6781
6644
|
}, [gapMode]);
|
|
6782
|
-
return
|
|
6645
|
+
return React27.createElement(Style, { styles: getStyles(gap, !noRelative, gapMode, !noImportant ? "!important" : "") });
|
|
6783
6646
|
};
|
|
6784
6647
|
|
|
6785
6648
|
// ../../node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js
|
|
@@ -6920,16 +6783,16 @@ var generateStyle = function(id) {
|
|
|
6920
6783
|
var idCounter = 0;
|
|
6921
6784
|
var lockStack = [];
|
|
6922
6785
|
function RemoveScrollSideCar(props) {
|
|
6923
|
-
var shouldPreventQueue =
|
|
6924
|
-
var touchStartRef =
|
|
6925
|
-
var activeAxis =
|
|
6926
|
-
var id =
|
|
6927
|
-
var Style2 =
|
|
6928
|
-
var lastProps =
|
|
6929
|
-
|
|
6786
|
+
var shouldPreventQueue = React28.useRef([]);
|
|
6787
|
+
var touchStartRef = React28.useRef([0, 0]);
|
|
6788
|
+
var activeAxis = React28.useRef();
|
|
6789
|
+
var id = React28.useState(idCounter++)[0];
|
|
6790
|
+
var Style2 = React28.useState(styleSingleton)[0];
|
|
6791
|
+
var lastProps = React28.useRef(props);
|
|
6792
|
+
React28.useEffect(function() {
|
|
6930
6793
|
lastProps.current = props;
|
|
6931
6794
|
}, [props]);
|
|
6932
|
-
|
|
6795
|
+
React28.useEffect(function() {
|
|
6933
6796
|
if (props.inert) {
|
|
6934
6797
|
document.body.classList.add("block-interactivity-".concat(id));
|
|
6935
6798
|
var allow_1 = __spreadArray([props.lockRef.current], (props.shards || []).map(extractRef), true).filter(Boolean);
|
|
@@ -6945,7 +6808,7 @@ function RemoveScrollSideCar(props) {
|
|
|
6945
6808
|
}
|
|
6946
6809
|
return;
|
|
6947
6810
|
}, [props.inert, props.lockRef.current, props.shards]);
|
|
6948
|
-
var shouldCancelEvent =
|
|
6811
|
+
var shouldCancelEvent = React28.useCallback(function(event, parent) {
|
|
6949
6812
|
if ("touches" in event && event.touches.length === 2 || event.type === "wheel" && event.ctrlKey) {
|
|
6950
6813
|
return !lastProps.current.allowPinchZoom;
|
|
6951
6814
|
}
|
|
@@ -6981,7 +6844,7 @@ function RemoveScrollSideCar(props) {
|
|
|
6981
6844
|
var cancelingAxis = activeAxis.current || currentAxis;
|
|
6982
6845
|
return handleScroll(cancelingAxis, parent, event, cancelingAxis === "h" ? deltaX : deltaY, true);
|
|
6983
6846
|
}, []);
|
|
6984
|
-
var shouldPrevent =
|
|
6847
|
+
var shouldPrevent = React28.useCallback(function(_event) {
|
|
6985
6848
|
var event = _event;
|
|
6986
6849
|
if (!lockStack.length || lockStack[lockStack.length - 1] !== Style2) {
|
|
6987
6850
|
return;
|
|
@@ -7008,7 +6871,7 @@ function RemoveScrollSideCar(props) {
|
|
|
7008
6871
|
}
|
|
7009
6872
|
}
|
|
7010
6873
|
}, []);
|
|
7011
|
-
var shouldCancel =
|
|
6874
|
+
var shouldCancel = React28.useCallback(function(name, delta, target, should) {
|
|
7012
6875
|
var event = { name, delta, target, should, shadowParent: getOutermostShadowParent(target) };
|
|
7013
6876
|
shouldPreventQueue.current.push(event);
|
|
7014
6877
|
setTimeout(function() {
|
|
@@ -7017,17 +6880,17 @@ function RemoveScrollSideCar(props) {
|
|
|
7017
6880
|
});
|
|
7018
6881
|
}, 1);
|
|
7019
6882
|
}, []);
|
|
7020
|
-
var scrollTouchStart =
|
|
6883
|
+
var scrollTouchStart = React28.useCallback(function(event) {
|
|
7021
6884
|
touchStartRef.current = getTouchXY(event);
|
|
7022
6885
|
activeAxis.current = void 0;
|
|
7023
6886
|
}, []);
|
|
7024
|
-
var scrollWheel =
|
|
6887
|
+
var scrollWheel = React28.useCallback(function(event) {
|
|
7025
6888
|
shouldCancel(event.type, getDeltaXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));
|
|
7026
6889
|
}, []);
|
|
7027
|
-
var scrollTouchMove =
|
|
6890
|
+
var scrollTouchMove = React28.useCallback(function(event) {
|
|
7028
6891
|
shouldCancel(event.type, getTouchXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));
|
|
7029
6892
|
}, []);
|
|
7030
|
-
|
|
6893
|
+
React28.useEffect(function() {
|
|
7031
6894
|
lockStack.push(Style2);
|
|
7032
6895
|
props.setCallbacks({
|
|
7033
6896
|
onScrollCapture: scrollWheel,
|
|
@@ -7047,11 +6910,11 @@ function RemoveScrollSideCar(props) {
|
|
|
7047
6910
|
};
|
|
7048
6911
|
}, []);
|
|
7049
6912
|
var removeScrollBar = props.removeScrollBar, inert = props.inert;
|
|
7050
|
-
return
|
|
7051
|
-
|
|
6913
|
+
return React28.createElement(
|
|
6914
|
+
React28.Fragment,
|
|
7052
6915
|
null,
|
|
7053
|
-
inert ?
|
|
7054
|
-
removeScrollBar ?
|
|
6916
|
+
inert ? React28.createElement(Style2, { styles: generateStyle(id) }) : null,
|
|
6917
|
+
removeScrollBar ? React28.createElement(RemoveScrollBar, { gapMode: props.gapMode }) : null
|
|
7055
6918
|
);
|
|
7056
6919
|
}
|
|
7057
6920
|
function getOutermostShadowParent(node) {
|
|
@@ -7070,14 +6933,14 @@ function getOutermostShadowParent(node) {
|
|
|
7070
6933
|
var sidecar_default = exportSidecar(effectCar, RemoveScrollSideCar);
|
|
7071
6934
|
|
|
7072
6935
|
// ../../node_modules/react-remove-scroll/dist/es2015/Combination.js
|
|
7073
|
-
var ReactRemoveScroll =
|
|
7074
|
-
return
|
|
6936
|
+
var ReactRemoveScroll = React29.forwardRef(function(props, ref) {
|
|
6937
|
+
return React29.createElement(RemoveScroll, __assign({}, props, { ref, sideCar: sidecar_default }));
|
|
7075
6938
|
});
|
|
7076
6939
|
ReactRemoveScroll.classNames = RemoveScroll.classNames;
|
|
7077
6940
|
var Combination_default = ReactRemoveScroll;
|
|
7078
6941
|
|
|
7079
6942
|
// ../../node_modules/@radix-ui/react-menu/dist/index.mjs
|
|
7080
|
-
var
|
|
6943
|
+
var import_jsx_runtime12 = require("react/jsx-runtime");
|
|
7081
6944
|
var SELECTION_KEYS = ["Enter", " "];
|
|
7082
6945
|
var FIRST_KEYS = ["ArrowDown", "PageUp", "Home"];
|
|
7083
6946
|
var LAST_KEYS = ["ArrowUp", "PageDown", "End"];
|
|
@@ -7104,11 +6967,11 @@ var [MenuRootProvider, useMenuRootContext] = createMenuContext(MENU_NAME);
|
|
|
7104
6967
|
var Menu = (props) => {
|
|
7105
6968
|
const { __scopeMenu, open = false, children, dir, onOpenChange, modal = true } = props;
|
|
7106
6969
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7107
|
-
const [content, setContent] =
|
|
7108
|
-
const isUsingKeyboardRef =
|
|
6970
|
+
const [content, setContent] = React30.useState(null);
|
|
6971
|
+
const isUsingKeyboardRef = React30.useRef(false);
|
|
7109
6972
|
const handleOpenChange = useCallbackRef(onOpenChange);
|
|
7110
6973
|
const direction = useDirection(dir);
|
|
7111
|
-
|
|
6974
|
+
React30.useEffect(() => {
|
|
7112
6975
|
const handleKeyDown = () => {
|
|
7113
6976
|
isUsingKeyboardRef.current = true;
|
|
7114
6977
|
document.addEventListener("pointerdown", handlePointer, { capture: true, once: true });
|
|
@@ -7122,7 +6985,7 @@ var Menu = (props) => {
|
|
|
7122
6985
|
document.removeEventListener("pointermove", handlePointer, { capture: true });
|
|
7123
6986
|
};
|
|
7124
6987
|
}, []);
|
|
7125
|
-
return /* @__PURE__ */ (0,
|
|
6988
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Root2, { ...popperScope, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7126
6989
|
MenuProvider,
|
|
7127
6990
|
{
|
|
7128
6991
|
scope: __scopeMenu,
|
|
@@ -7130,11 +6993,11 @@ var Menu = (props) => {
|
|
|
7130
6993
|
onOpenChange: handleOpenChange,
|
|
7131
6994
|
content,
|
|
7132
6995
|
onContentChange: setContent,
|
|
7133
|
-
children: /* @__PURE__ */ (0,
|
|
6996
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7134
6997
|
MenuRootProvider,
|
|
7135
6998
|
{
|
|
7136
6999
|
scope: __scopeMenu,
|
|
7137
|
-
onClose:
|
|
7000
|
+
onClose: React30.useCallback(() => handleOpenChange(false), [handleOpenChange]),
|
|
7138
7001
|
isUsingKeyboardRef,
|
|
7139
7002
|
dir: direction,
|
|
7140
7003
|
modal,
|
|
@@ -7146,11 +7009,11 @@ var Menu = (props) => {
|
|
|
7146
7009
|
};
|
|
7147
7010
|
Menu.displayName = MENU_NAME;
|
|
7148
7011
|
var ANCHOR_NAME2 = "MenuAnchor";
|
|
7149
|
-
var MenuAnchor =
|
|
7012
|
+
var MenuAnchor = React30.forwardRef(
|
|
7150
7013
|
(props, forwardedRef) => {
|
|
7151
7014
|
const { __scopeMenu, ...anchorProps } = props;
|
|
7152
7015
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7153
|
-
return /* @__PURE__ */ (0,
|
|
7016
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Anchor, { ...popperScope, ...anchorProps, ref: forwardedRef });
|
|
7154
7017
|
}
|
|
7155
7018
|
);
|
|
7156
7019
|
MenuAnchor.displayName = ANCHOR_NAME2;
|
|
@@ -7161,30 +7024,30 @@ var [PortalProvider, usePortalContext] = createMenuContext(PORTAL_NAME2, {
|
|
|
7161
7024
|
var MenuPortal = (props) => {
|
|
7162
7025
|
const { __scopeMenu, forceMount, children, container } = props;
|
|
7163
7026
|
const context = useMenuContext(PORTAL_NAME2, __scopeMenu);
|
|
7164
|
-
return /* @__PURE__ */ (0,
|
|
7027
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PortalProvider, { scope: __scopeMenu, forceMount, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Portal, { asChild: true, container, children }) }) });
|
|
7165
7028
|
};
|
|
7166
7029
|
MenuPortal.displayName = PORTAL_NAME2;
|
|
7167
7030
|
var CONTENT_NAME2 = "MenuContent";
|
|
7168
7031
|
var [MenuContentProvider, useMenuContentContext] = createMenuContext(CONTENT_NAME2);
|
|
7169
|
-
var MenuContent =
|
|
7032
|
+
var MenuContent = React30.forwardRef(
|
|
7170
7033
|
(props, forwardedRef) => {
|
|
7171
7034
|
const portalContext = usePortalContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7172
7035
|
const { forceMount = portalContext.forceMount, ...contentProps } = props;
|
|
7173
7036
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7174
7037
|
const rootContext = useMenuRootContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7175
|
-
return /* @__PURE__ */ (0,
|
|
7038
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Collection2.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Collection2.Slot, { scope: props.__scopeMenu, children: rootContext.modal ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(MenuRootContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(MenuRootContentNonModal, { ...contentProps, ref: forwardedRef }) }) }) });
|
|
7176
7039
|
}
|
|
7177
7040
|
);
|
|
7178
|
-
var MenuRootContentModal =
|
|
7041
|
+
var MenuRootContentModal = React30.forwardRef(
|
|
7179
7042
|
(props, forwardedRef) => {
|
|
7180
7043
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7181
|
-
const ref =
|
|
7044
|
+
const ref = React30.useRef(null);
|
|
7182
7045
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7183
|
-
|
|
7046
|
+
React30.useEffect(() => {
|
|
7184
7047
|
const content = ref.current;
|
|
7185
7048
|
if (content) return hideOthers(content);
|
|
7186
7049
|
}, []);
|
|
7187
|
-
return /* @__PURE__ */ (0,
|
|
7050
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7188
7051
|
MenuContentImpl,
|
|
7189
7052
|
{
|
|
7190
7053
|
...props,
|
|
@@ -7202,9 +7065,9 @@ var MenuRootContentModal = React33.forwardRef(
|
|
|
7202
7065
|
);
|
|
7203
7066
|
}
|
|
7204
7067
|
);
|
|
7205
|
-
var MenuRootContentNonModal =
|
|
7068
|
+
var MenuRootContentNonModal = React30.forwardRef((props, forwardedRef) => {
|
|
7206
7069
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7207
|
-
return /* @__PURE__ */ (0,
|
|
7070
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7208
7071
|
MenuContentImpl,
|
|
7209
7072
|
{
|
|
7210
7073
|
...props,
|
|
@@ -7216,7 +7079,7 @@ var MenuRootContentNonModal = React33.forwardRef((props, forwardedRef) => {
|
|
|
7216
7079
|
}
|
|
7217
7080
|
);
|
|
7218
7081
|
});
|
|
7219
|
-
var MenuContentImpl =
|
|
7082
|
+
var MenuContentImpl = React30.forwardRef(
|
|
7220
7083
|
(props, forwardedRef) => {
|
|
7221
7084
|
const {
|
|
7222
7085
|
__scopeMenu,
|
|
@@ -7239,16 +7102,16 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7239
7102
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7240
7103
|
const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);
|
|
7241
7104
|
const getItems = useCollection2(__scopeMenu);
|
|
7242
|
-
const [currentItemId, setCurrentItemId] =
|
|
7243
|
-
const contentRef =
|
|
7105
|
+
const [currentItemId, setCurrentItemId] = React30.useState(null);
|
|
7106
|
+
const contentRef = React30.useRef(null);
|
|
7244
7107
|
const composedRefs = useComposedRefs(forwardedRef, contentRef, context.onContentChange);
|
|
7245
|
-
const timerRef =
|
|
7246
|
-
const searchRef =
|
|
7247
|
-
const pointerGraceTimerRef =
|
|
7248
|
-
const pointerGraceIntentRef =
|
|
7249
|
-
const pointerDirRef =
|
|
7250
|
-
const lastPointerXRef =
|
|
7251
|
-
const ScrollLockWrapper = disableOutsideScroll ? Combination_default :
|
|
7108
|
+
const timerRef = React30.useRef(0);
|
|
7109
|
+
const searchRef = React30.useRef("");
|
|
7110
|
+
const pointerGraceTimerRef = React30.useRef(0);
|
|
7111
|
+
const pointerGraceIntentRef = React30.useRef(null);
|
|
7112
|
+
const pointerDirRef = React30.useRef("right");
|
|
7113
|
+
const lastPointerXRef = React30.useRef(0);
|
|
7114
|
+
const ScrollLockWrapper = disableOutsideScroll ? Combination_default : React30.Fragment;
|
|
7252
7115
|
const scrollLockWrapperProps = disableOutsideScroll ? { as: import_react_slot4.Slot, allowPinchZoom: true } : void 0;
|
|
7253
7116
|
const handleTypeaheadSearch = (key) => {
|
|
7254
7117
|
const search = searchRef.current + key;
|
|
@@ -7267,26 +7130,26 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7267
7130
|
setTimeout(() => newItem.focus());
|
|
7268
7131
|
}
|
|
7269
7132
|
};
|
|
7270
|
-
|
|
7133
|
+
React30.useEffect(() => {
|
|
7271
7134
|
return () => window.clearTimeout(timerRef.current);
|
|
7272
7135
|
}, []);
|
|
7273
7136
|
useFocusGuards();
|
|
7274
|
-
const isPointerMovingToSubmenu =
|
|
7137
|
+
const isPointerMovingToSubmenu = React30.useCallback((event) => {
|
|
7275
7138
|
const isMovingTowards = pointerDirRef.current === pointerGraceIntentRef.current?.side;
|
|
7276
7139
|
return isMovingTowards && isPointerInGraceArea(event, pointerGraceIntentRef.current?.area);
|
|
7277
7140
|
}, []);
|
|
7278
|
-
return /* @__PURE__ */ (0,
|
|
7141
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7279
7142
|
MenuContentProvider,
|
|
7280
7143
|
{
|
|
7281
7144
|
scope: __scopeMenu,
|
|
7282
7145
|
searchRef,
|
|
7283
|
-
onItemEnter:
|
|
7146
|
+
onItemEnter: React30.useCallback(
|
|
7284
7147
|
(event) => {
|
|
7285
7148
|
if (isPointerMovingToSubmenu(event)) event.preventDefault();
|
|
7286
7149
|
},
|
|
7287
7150
|
[isPointerMovingToSubmenu]
|
|
7288
7151
|
),
|
|
7289
|
-
onItemLeave:
|
|
7152
|
+
onItemLeave: React30.useCallback(
|
|
7290
7153
|
(event) => {
|
|
7291
7154
|
if (isPointerMovingToSubmenu(event)) return;
|
|
7292
7155
|
contentRef.current?.focus();
|
|
@@ -7294,17 +7157,17 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7294
7157
|
},
|
|
7295
7158
|
[isPointerMovingToSubmenu]
|
|
7296
7159
|
),
|
|
7297
|
-
onTriggerLeave:
|
|
7160
|
+
onTriggerLeave: React30.useCallback(
|
|
7298
7161
|
(event) => {
|
|
7299
7162
|
if (isPointerMovingToSubmenu(event)) event.preventDefault();
|
|
7300
7163
|
},
|
|
7301
7164
|
[isPointerMovingToSubmenu]
|
|
7302
7165
|
),
|
|
7303
7166
|
pointerGraceTimerRef,
|
|
7304
|
-
onPointerGraceIntentChange:
|
|
7167
|
+
onPointerGraceIntentChange: React30.useCallback((intent) => {
|
|
7305
7168
|
pointerGraceIntentRef.current = intent;
|
|
7306
7169
|
}, []),
|
|
7307
|
-
children: /* @__PURE__ */ (0,
|
|
7170
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ScrollLockWrapper, { ...scrollLockWrapperProps, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7308
7171
|
FocusScope,
|
|
7309
7172
|
{
|
|
7310
7173
|
asChild: true,
|
|
@@ -7314,7 +7177,7 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7314
7177
|
contentRef.current?.focus({ preventScroll: true });
|
|
7315
7178
|
}),
|
|
7316
7179
|
onUnmountAutoFocus: onCloseAutoFocus,
|
|
7317
|
-
children: /* @__PURE__ */ (0,
|
|
7180
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7318
7181
|
DismissableLayer,
|
|
7319
7182
|
{
|
|
7320
7183
|
asChild: true,
|
|
@@ -7324,7 +7187,7 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7324
7187
|
onFocusOutside,
|
|
7325
7188
|
onInteractOutside,
|
|
7326
7189
|
onDismiss,
|
|
7327
|
-
children: /* @__PURE__ */ (0,
|
|
7190
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7328
7191
|
Root3,
|
|
7329
7192
|
{
|
|
7330
7193
|
asChild: true,
|
|
@@ -7338,7 +7201,7 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7338
7201
|
if (!rootContext.isUsingKeyboardRef.current) event.preventDefault();
|
|
7339
7202
|
}),
|
|
7340
7203
|
preventScrollOnEntryFocus: true,
|
|
7341
|
-
children: /* @__PURE__ */ (0,
|
|
7204
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7342
7205
|
Content,
|
|
7343
7206
|
{
|
|
7344
7207
|
role: "menu",
|
|
@@ -7400,31 +7263,31 @@ var MenuContentImpl = React33.forwardRef(
|
|
|
7400
7263
|
);
|
|
7401
7264
|
MenuContent.displayName = CONTENT_NAME2;
|
|
7402
7265
|
var GROUP_NAME2 = "MenuGroup";
|
|
7403
|
-
var MenuGroup =
|
|
7266
|
+
var MenuGroup = React30.forwardRef(
|
|
7404
7267
|
(props, forwardedRef) => {
|
|
7405
7268
|
const { __scopeMenu, ...groupProps } = props;
|
|
7406
|
-
return /* @__PURE__ */ (0,
|
|
7269
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Primitive.div, { role: "group", ...groupProps, ref: forwardedRef });
|
|
7407
7270
|
}
|
|
7408
7271
|
);
|
|
7409
7272
|
MenuGroup.displayName = GROUP_NAME2;
|
|
7410
7273
|
var LABEL_NAME = "MenuLabel";
|
|
7411
|
-
var MenuLabel =
|
|
7274
|
+
var MenuLabel = React30.forwardRef(
|
|
7412
7275
|
(props, forwardedRef) => {
|
|
7413
7276
|
const { __scopeMenu, ...labelProps } = props;
|
|
7414
|
-
return /* @__PURE__ */ (0,
|
|
7277
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Primitive.div, { ...labelProps, ref: forwardedRef });
|
|
7415
7278
|
}
|
|
7416
7279
|
);
|
|
7417
7280
|
MenuLabel.displayName = LABEL_NAME;
|
|
7418
7281
|
var ITEM_NAME2 = "MenuItem";
|
|
7419
7282
|
var ITEM_SELECT = "menu.itemSelect";
|
|
7420
|
-
var MenuItem =
|
|
7283
|
+
var MenuItem = React30.forwardRef(
|
|
7421
7284
|
(props, forwardedRef) => {
|
|
7422
7285
|
const { disabled = false, onSelect, ...itemProps } = props;
|
|
7423
|
-
const ref =
|
|
7286
|
+
const ref = React30.useRef(null);
|
|
7424
7287
|
const rootContext = useMenuRootContext(ITEM_NAME2, props.__scopeMenu);
|
|
7425
7288
|
const contentContext = useMenuContentContext(ITEM_NAME2, props.__scopeMenu);
|
|
7426
7289
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7427
|
-
const isPointerDownRef =
|
|
7290
|
+
const isPointerDownRef = React30.useRef(false);
|
|
7428
7291
|
const handleSelect = () => {
|
|
7429
7292
|
const menuItem = ref.current;
|
|
7430
7293
|
if (!disabled && menuItem) {
|
|
@@ -7438,7 +7301,7 @@ var MenuItem = React33.forwardRef(
|
|
|
7438
7301
|
}
|
|
7439
7302
|
}
|
|
7440
7303
|
};
|
|
7441
|
-
return /* @__PURE__ */ (0,
|
|
7304
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7442
7305
|
MenuItemImpl,
|
|
7443
7306
|
{
|
|
7444
7307
|
...itemProps,
|
|
@@ -7465,28 +7328,28 @@ var MenuItem = React33.forwardRef(
|
|
|
7465
7328
|
}
|
|
7466
7329
|
);
|
|
7467
7330
|
MenuItem.displayName = ITEM_NAME2;
|
|
7468
|
-
var MenuItemImpl =
|
|
7331
|
+
var MenuItemImpl = React30.forwardRef(
|
|
7469
7332
|
(props, forwardedRef) => {
|
|
7470
7333
|
const { __scopeMenu, disabled = false, textValue, ...itemProps } = props;
|
|
7471
7334
|
const contentContext = useMenuContentContext(ITEM_NAME2, __scopeMenu);
|
|
7472
7335
|
const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);
|
|
7473
|
-
const ref =
|
|
7336
|
+
const ref = React30.useRef(null);
|
|
7474
7337
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7475
|
-
const [isFocused, setIsFocused] =
|
|
7476
|
-
const [textContent, setTextContent] =
|
|
7477
|
-
|
|
7338
|
+
const [isFocused, setIsFocused] = React30.useState(false);
|
|
7339
|
+
const [textContent, setTextContent] = React30.useState("");
|
|
7340
|
+
React30.useEffect(() => {
|
|
7478
7341
|
const menuItem = ref.current;
|
|
7479
7342
|
if (menuItem) {
|
|
7480
7343
|
setTextContent((menuItem.textContent ?? "").trim());
|
|
7481
7344
|
}
|
|
7482
7345
|
}, [itemProps.children]);
|
|
7483
|
-
return /* @__PURE__ */ (0,
|
|
7346
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7484
7347
|
Collection2.ItemSlot,
|
|
7485
7348
|
{
|
|
7486
7349
|
scope: __scopeMenu,
|
|
7487
7350
|
disabled,
|
|
7488
7351
|
textValue: textValue ?? textContent,
|
|
7489
|
-
children: /* @__PURE__ */ (0,
|
|
7352
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Item, { asChild: true, ...rovingFocusGroupScope, focusable: !disabled, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7490
7353
|
Primitive.div,
|
|
7491
7354
|
{
|
|
7492
7355
|
role: "menuitem",
|
|
@@ -7522,10 +7385,10 @@ var MenuItemImpl = React33.forwardRef(
|
|
|
7522
7385
|
}
|
|
7523
7386
|
);
|
|
7524
7387
|
var CHECKBOX_ITEM_NAME = "MenuCheckboxItem";
|
|
7525
|
-
var MenuCheckboxItem =
|
|
7388
|
+
var MenuCheckboxItem = React30.forwardRef(
|
|
7526
7389
|
(props, forwardedRef) => {
|
|
7527
7390
|
const { checked = false, onCheckedChange, ...checkboxItemProps } = props;
|
|
7528
|
-
return /* @__PURE__ */ (0,
|
|
7391
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7529
7392
|
MenuItem,
|
|
7530
7393
|
{
|
|
7531
7394
|
role: "menuitemcheckbox",
|
|
@@ -7549,21 +7412,21 @@ var [RadioGroupProvider, useRadioGroupContext] = createMenuContext(
|
|
|
7549
7412
|
{ value: void 0, onValueChange: () => {
|
|
7550
7413
|
} }
|
|
7551
7414
|
);
|
|
7552
|
-
var MenuRadioGroup =
|
|
7415
|
+
var MenuRadioGroup = React30.forwardRef(
|
|
7553
7416
|
(props, forwardedRef) => {
|
|
7554
7417
|
const { value, onValueChange, ...groupProps } = props;
|
|
7555
7418
|
const handleValueChange = useCallbackRef(onValueChange);
|
|
7556
|
-
return /* @__PURE__ */ (0,
|
|
7419
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(RadioGroupProvider, { scope: props.__scopeMenu, value, onValueChange: handleValueChange, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(MenuGroup, { ...groupProps, ref: forwardedRef }) });
|
|
7557
7420
|
}
|
|
7558
7421
|
);
|
|
7559
7422
|
MenuRadioGroup.displayName = RADIO_GROUP_NAME;
|
|
7560
7423
|
var RADIO_ITEM_NAME = "MenuRadioItem";
|
|
7561
|
-
var MenuRadioItem =
|
|
7424
|
+
var MenuRadioItem = React30.forwardRef(
|
|
7562
7425
|
(props, forwardedRef) => {
|
|
7563
7426
|
const { value, ...radioItemProps } = props;
|
|
7564
7427
|
const context = useRadioGroupContext(RADIO_ITEM_NAME, props.__scopeMenu);
|
|
7565
7428
|
const checked = value === context.value;
|
|
7566
|
-
return /* @__PURE__ */ (0,
|
|
7429
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7567
7430
|
MenuItem,
|
|
7568
7431
|
{
|
|
7569
7432
|
role: "menuitemradio",
|
|
@@ -7586,15 +7449,15 @@ var [ItemIndicatorProvider, useItemIndicatorContext] = createMenuContext(
|
|
|
7586
7449
|
ITEM_INDICATOR_NAME,
|
|
7587
7450
|
{ checked: false }
|
|
7588
7451
|
);
|
|
7589
|
-
var MenuItemIndicator =
|
|
7452
|
+
var MenuItemIndicator = React30.forwardRef(
|
|
7590
7453
|
(props, forwardedRef) => {
|
|
7591
7454
|
const { __scopeMenu, forceMount, ...itemIndicatorProps } = props;
|
|
7592
7455
|
const indicatorContext = useItemIndicatorContext(ITEM_INDICATOR_NAME, __scopeMenu);
|
|
7593
|
-
return /* @__PURE__ */ (0,
|
|
7456
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7594
7457
|
Presence,
|
|
7595
7458
|
{
|
|
7596
7459
|
present: forceMount || isIndeterminate(indicatorContext.checked) || indicatorContext.checked === true,
|
|
7597
|
-
children: /* @__PURE__ */ (0,
|
|
7460
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7598
7461
|
Primitive.span,
|
|
7599
7462
|
{
|
|
7600
7463
|
...itemIndicatorProps,
|
|
@@ -7608,10 +7471,10 @@ var MenuItemIndicator = React33.forwardRef(
|
|
|
7608
7471
|
);
|
|
7609
7472
|
MenuItemIndicator.displayName = ITEM_INDICATOR_NAME;
|
|
7610
7473
|
var SEPARATOR_NAME = "MenuSeparator";
|
|
7611
|
-
var MenuSeparator =
|
|
7474
|
+
var MenuSeparator = React30.forwardRef(
|
|
7612
7475
|
(props, forwardedRef) => {
|
|
7613
7476
|
const { __scopeMenu, ...separatorProps } = props;
|
|
7614
|
-
return /* @__PURE__ */ (0,
|
|
7477
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7615
7478
|
Primitive.div,
|
|
7616
7479
|
{
|
|
7617
7480
|
role: "separator",
|
|
@@ -7624,11 +7487,11 @@ var MenuSeparator = React33.forwardRef(
|
|
|
7624
7487
|
);
|
|
7625
7488
|
MenuSeparator.displayName = SEPARATOR_NAME;
|
|
7626
7489
|
var ARROW_NAME2 = "MenuArrow";
|
|
7627
|
-
var MenuArrow =
|
|
7490
|
+
var MenuArrow = React30.forwardRef(
|
|
7628
7491
|
(props, forwardedRef) => {
|
|
7629
7492
|
const { __scopeMenu, ...arrowProps } = props;
|
|
7630
7493
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7631
|
-
return /* @__PURE__ */ (0,
|
|
7494
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Arrow2, { ...popperScope, ...arrowProps, ref: forwardedRef });
|
|
7632
7495
|
}
|
|
7633
7496
|
);
|
|
7634
7497
|
MenuArrow.displayName = ARROW_NAME2;
|
|
@@ -7638,14 +7501,14 @@ var MenuSub = (props) => {
|
|
|
7638
7501
|
const { __scopeMenu, children, open = false, onOpenChange } = props;
|
|
7639
7502
|
const parentMenuContext = useMenuContext(SUB_NAME, __scopeMenu);
|
|
7640
7503
|
const popperScope = usePopperScope(__scopeMenu);
|
|
7641
|
-
const [trigger, setTrigger] =
|
|
7642
|
-
const [content, setContent] =
|
|
7504
|
+
const [trigger, setTrigger] = React30.useState(null);
|
|
7505
|
+
const [content, setContent] = React30.useState(null);
|
|
7643
7506
|
const handleOpenChange = useCallbackRef(onOpenChange);
|
|
7644
|
-
|
|
7507
|
+
React30.useEffect(() => {
|
|
7645
7508
|
if (parentMenuContext.open === false) handleOpenChange(false);
|
|
7646
7509
|
return () => handleOpenChange(false);
|
|
7647
7510
|
}, [parentMenuContext.open, handleOpenChange]);
|
|
7648
|
-
return /* @__PURE__ */ (0,
|
|
7511
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Root2, { ...popperScope, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7649
7512
|
MenuProvider,
|
|
7650
7513
|
{
|
|
7651
7514
|
scope: __scopeMenu,
|
|
@@ -7653,7 +7516,7 @@ var MenuSub = (props) => {
|
|
|
7653
7516
|
onOpenChange: handleOpenChange,
|
|
7654
7517
|
content,
|
|
7655
7518
|
onContentChange: setContent,
|
|
7656
|
-
children: /* @__PURE__ */ (0,
|
|
7519
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7657
7520
|
MenuSubProvider,
|
|
7658
7521
|
{
|
|
7659
7522
|
scope: __scopeMenu,
|
|
@@ -7669,28 +7532,28 @@ var MenuSub = (props) => {
|
|
|
7669
7532
|
};
|
|
7670
7533
|
MenuSub.displayName = SUB_NAME;
|
|
7671
7534
|
var SUB_TRIGGER_NAME = "MenuSubTrigger";
|
|
7672
|
-
var MenuSubTrigger =
|
|
7535
|
+
var MenuSubTrigger = React30.forwardRef(
|
|
7673
7536
|
(props, forwardedRef) => {
|
|
7674
7537
|
const context = useMenuContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
7675
7538
|
const rootContext = useMenuRootContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
7676
7539
|
const subContext = useMenuSubContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
7677
7540
|
const contentContext = useMenuContentContext(SUB_TRIGGER_NAME, props.__scopeMenu);
|
|
7678
|
-
const openTimerRef =
|
|
7541
|
+
const openTimerRef = React30.useRef(null);
|
|
7679
7542
|
const { pointerGraceTimerRef, onPointerGraceIntentChange } = contentContext;
|
|
7680
7543
|
const scope = { __scopeMenu: props.__scopeMenu };
|
|
7681
|
-
const clearOpenTimer =
|
|
7544
|
+
const clearOpenTimer = React30.useCallback(() => {
|
|
7682
7545
|
if (openTimerRef.current) window.clearTimeout(openTimerRef.current);
|
|
7683
7546
|
openTimerRef.current = null;
|
|
7684
7547
|
}, []);
|
|
7685
|
-
|
|
7686
|
-
|
|
7548
|
+
React30.useEffect(() => clearOpenTimer, [clearOpenTimer]);
|
|
7549
|
+
React30.useEffect(() => {
|
|
7687
7550
|
const pointerGraceTimer = pointerGraceTimerRef.current;
|
|
7688
7551
|
return () => {
|
|
7689
7552
|
window.clearTimeout(pointerGraceTimer);
|
|
7690
7553
|
onPointerGraceIntentChange(null);
|
|
7691
7554
|
};
|
|
7692
7555
|
}, [pointerGraceTimerRef, onPointerGraceIntentChange]);
|
|
7693
|
-
return /* @__PURE__ */ (0,
|
|
7556
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(MenuAnchor, { asChild: true, ...scope, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7694
7557
|
MenuItemImpl,
|
|
7695
7558
|
{
|
|
7696
7559
|
id: subContext.triggerId,
|
|
@@ -7770,16 +7633,16 @@ var MenuSubTrigger = React33.forwardRef(
|
|
|
7770
7633
|
);
|
|
7771
7634
|
MenuSubTrigger.displayName = SUB_TRIGGER_NAME;
|
|
7772
7635
|
var SUB_CONTENT_NAME = "MenuSubContent";
|
|
7773
|
-
var MenuSubContent =
|
|
7636
|
+
var MenuSubContent = React30.forwardRef(
|
|
7774
7637
|
(props, forwardedRef) => {
|
|
7775
7638
|
const portalContext = usePortalContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7776
7639
|
const { forceMount = portalContext.forceMount, ...subContentProps } = props;
|
|
7777
7640
|
const context = useMenuContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7778
7641
|
const rootContext = useMenuRootContext(CONTENT_NAME2, props.__scopeMenu);
|
|
7779
7642
|
const subContext = useMenuSubContext(SUB_CONTENT_NAME, props.__scopeMenu);
|
|
7780
|
-
const ref =
|
|
7643
|
+
const ref = React30.useRef(null);
|
|
7781
7644
|
const composedRefs = useComposedRefs(forwardedRef, ref);
|
|
7782
|
-
return /* @__PURE__ */ (0,
|
|
7645
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Collection2.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Collection2.Slot, { scope: props.__scopeMenu, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
7783
7646
|
MenuContentImpl,
|
|
7784
7647
|
{
|
|
7785
7648
|
id: subContext.contentId,
|
|
@@ -7888,7 +7751,7 @@ var SubTrigger = MenuSubTrigger;
|
|
|
7888
7751
|
var SubContent = MenuSubContent;
|
|
7889
7752
|
|
|
7890
7753
|
// ../../node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs
|
|
7891
|
-
var
|
|
7754
|
+
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
7892
7755
|
var DROPDOWN_MENU_NAME = "DropdownMenu";
|
|
7893
7756
|
var [createDropdownMenuContext, createDropdownMenuScope] = createContextScope(
|
|
7894
7757
|
DROPDOWN_MENU_NAME,
|
|
@@ -7907,13 +7770,13 @@ var DropdownMenu = (props) => {
|
|
|
7907
7770
|
modal = true
|
|
7908
7771
|
} = props;
|
|
7909
7772
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
7910
|
-
const triggerRef =
|
|
7773
|
+
const triggerRef = React31.useRef(null);
|
|
7911
7774
|
const [open = false, setOpen] = useControllableState({
|
|
7912
7775
|
prop: openProp,
|
|
7913
7776
|
defaultProp: defaultOpen,
|
|
7914
7777
|
onChange: onOpenChange
|
|
7915
7778
|
});
|
|
7916
|
-
return /* @__PURE__ */ (0,
|
|
7779
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
7917
7780
|
DropdownMenuProvider,
|
|
7918
7781
|
{
|
|
7919
7782
|
scope: __scopeDropdownMenu,
|
|
@@ -7922,20 +7785,20 @@ var DropdownMenu = (props) => {
|
|
|
7922
7785
|
contentId: useId(),
|
|
7923
7786
|
open,
|
|
7924
7787
|
onOpenChange: setOpen,
|
|
7925
|
-
onOpenToggle:
|
|
7788
|
+
onOpenToggle: React31.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),
|
|
7926
7789
|
modal,
|
|
7927
|
-
children: /* @__PURE__ */ (0,
|
|
7790
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Root32, { ...menuScope, open, onOpenChange: setOpen, dir, modal, children })
|
|
7928
7791
|
}
|
|
7929
7792
|
);
|
|
7930
7793
|
};
|
|
7931
7794
|
DropdownMenu.displayName = DROPDOWN_MENU_NAME;
|
|
7932
7795
|
var TRIGGER_NAME = "DropdownMenuTrigger";
|
|
7933
|
-
var DropdownMenuTrigger =
|
|
7796
|
+
var DropdownMenuTrigger = React31.forwardRef(
|
|
7934
7797
|
(props, forwardedRef) => {
|
|
7935
7798
|
const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;
|
|
7936
7799
|
const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);
|
|
7937
7800
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
7938
|
-
return /* @__PURE__ */ (0,
|
|
7801
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Anchor2, { asChild: true, ...menuScope, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
7939
7802
|
Primitive.button,
|
|
7940
7803
|
{
|
|
7941
7804
|
type: "button",
|
|
@@ -7969,17 +7832,17 @@ var PORTAL_NAME3 = "DropdownMenuPortal";
|
|
|
7969
7832
|
var DropdownMenuPortal = (props) => {
|
|
7970
7833
|
const { __scopeDropdownMenu, ...portalProps } = props;
|
|
7971
7834
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
7972
|
-
return /* @__PURE__ */ (0,
|
|
7835
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Portal2, { ...menuScope, ...portalProps });
|
|
7973
7836
|
};
|
|
7974
7837
|
DropdownMenuPortal.displayName = PORTAL_NAME3;
|
|
7975
7838
|
var CONTENT_NAME3 = "DropdownMenuContent";
|
|
7976
|
-
var DropdownMenuContent =
|
|
7839
|
+
var DropdownMenuContent = React31.forwardRef(
|
|
7977
7840
|
(props, forwardedRef) => {
|
|
7978
7841
|
const { __scopeDropdownMenu, ...contentProps } = props;
|
|
7979
7842
|
const context = useDropdownMenuContext(CONTENT_NAME3, __scopeDropdownMenu);
|
|
7980
7843
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
7981
|
-
const hasInteractedOutsideRef =
|
|
7982
|
-
return /* @__PURE__ */ (0,
|
|
7844
|
+
const hasInteractedOutsideRef = React31.useRef(false);
|
|
7845
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
7983
7846
|
Content2,
|
|
7984
7847
|
{
|
|
7985
7848
|
id: context.contentId,
|
|
@@ -8015,73 +7878,73 @@ var DropdownMenuContent = React34.forwardRef(
|
|
|
8015
7878
|
);
|
|
8016
7879
|
DropdownMenuContent.displayName = CONTENT_NAME3;
|
|
8017
7880
|
var GROUP_NAME3 = "DropdownMenuGroup";
|
|
8018
|
-
var DropdownMenuGroup =
|
|
7881
|
+
var DropdownMenuGroup = React31.forwardRef(
|
|
8019
7882
|
(props, forwardedRef) => {
|
|
8020
7883
|
const { __scopeDropdownMenu, ...groupProps } = props;
|
|
8021
7884
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8022
|
-
return /* @__PURE__ */ (0,
|
|
7885
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Group, { ...menuScope, ...groupProps, ref: forwardedRef });
|
|
8023
7886
|
}
|
|
8024
7887
|
);
|
|
8025
7888
|
DropdownMenuGroup.displayName = GROUP_NAME3;
|
|
8026
7889
|
var LABEL_NAME2 = "DropdownMenuLabel";
|
|
8027
|
-
var DropdownMenuLabel =
|
|
7890
|
+
var DropdownMenuLabel = React31.forwardRef(
|
|
8028
7891
|
(props, forwardedRef) => {
|
|
8029
7892
|
const { __scopeDropdownMenu, ...labelProps } = props;
|
|
8030
7893
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8031
|
-
return /* @__PURE__ */ (0,
|
|
7894
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Label, { ...menuScope, ...labelProps, ref: forwardedRef });
|
|
8032
7895
|
}
|
|
8033
7896
|
);
|
|
8034
7897
|
DropdownMenuLabel.displayName = LABEL_NAME2;
|
|
8035
7898
|
var ITEM_NAME3 = "DropdownMenuItem";
|
|
8036
|
-
var DropdownMenuItem =
|
|
7899
|
+
var DropdownMenuItem = React31.forwardRef(
|
|
8037
7900
|
(props, forwardedRef) => {
|
|
8038
7901
|
const { __scopeDropdownMenu, ...itemProps } = props;
|
|
8039
7902
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8040
|
-
return /* @__PURE__ */ (0,
|
|
7903
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Item2, { ...menuScope, ...itemProps, ref: forwardedRef });
|
|
8041
7904
|
}
|
|
8042
7905
|
);
|
|
8043
7906
|
DropdownMenuItem.displayName = ITEM_NAME3;
|
|
8044
7907
|
var CHECKBOX_ITEM_NAME2 = "DropdownMenuCheckboxItem";
|
|
8045
|
-
var DropdownMenuCheckboxItem =
|
|
7908
|
+
var DropdownMenuCheckboxItem = React31.forwardRef((props, forwardedRef) => {
|
|
8046
7909
|
const { __scopeDropdownMenu, ...checkboxItemProps } = props;
|
|
8047
7910
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8048
|
-
return /* @__PURE__ */ (0,
|
|
7911
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(CheckboxItem, { ...menuScope, ...checkboxItemProps, ref: forwardedRef });
|
|
8049
7912
|
});
|
|
8050
7913
|
DropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME2;
|
|
8051
7914
|
var RADIO_GROUP_NAME2 = "DropdownMenuRadioGroup";
|
|
8052
|
-
var DropdownMenuRadioGroup =
|
|
7915
|
+
var DropdownMenuRadioGroup = React31.forwardRef((props, forwardedRef) => {
|
|
8053
7916
|
const { __scopeDropdownMenu, ...radioGroupProps } = props;
|
|
8054
7917
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8055
|
-
return /* @__PURE__ */ (0,
|
|
7918
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(RadioGroup, { ...menuScope, ...radioGroupProps, ref: forwardedRef });
|
|
8056
7919
|
});
|
|
8057
7920
|
DropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME2;
|
|
8058
7921
|
var RADIO_ITEM_NAME2 = "DropdownMenuRadioItem";
|
|
8059
|
-
var DropdownMenuRadioItem =
|
|
7922
|
+
var DropdownMenuRadioItem = React31.forwardRef((props, forwardedRef) => {
|
|
8060
7923
|
const { __scopeDropdownMenu, ...radioItemProps } = props;
|
|
8061
7924
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8062
|
-
return /* @__PURE__ */ (0,
|
|
7925
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(RadioItem, { ...menuScope, ...radioItemProps, ref: forwardedRef });
|
|
8063
7926
|
});
|
|
8064
7927
|
DropdownMenuRadioItem.displayName = RADIO_ITEM_NAME2;
|
|
8065
7928
|
var INDICATOR_NAME = "DropdownMenuItemIndicator";
|
|
8066
|
-
var DropdownMenuItemIndicator =
|
|
7929
|
+
var DropdownMenuItemIndicator = React31.forwardRef((props, forwardedRef) => {
|
|
8067
7930
|
const { __scopeDropdownMenu, ...itemIndicatorProps } = props;
|
|
8068
7931
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8069
|
-
return /* @__PURE__ */ (0,
|
|
7932
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ItemIndicator, { ...menuScope, ...itemIndicatorProps, ref: forwardedRef });
|
|
8070
7933
|
});
|
|
8071
7934
|
DropdownMenuItemIndicator.displayName = INDICATOR_NAME;
|
|
8072
7935
|
var SEPARATOR_NAME2 = "DropdownMenuSeparator";
|
|
8073
|
-
var DropdownMenuSeparator =
|
|
7936
|
+
var DropdownMenuSeparator = React31.forwardRef((props, forwardedRef) => {
|
|
8074
7937
|
const { __scopeDropdownMenu, ...separatorProps } = props;
|
|
8075
7938
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8076
|
-
return /* @__PURE__ */ (0,
|
|
7939
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Separator, { ...menuScope, ...separatorProps, ref: forwardedRef });
|
|
8077
7940
|
});
|
|
8078
7941
|
DropdownMenuSeparator.displayName = SEPARATOR_NAME2;
|
|
8079
7942
|
var ARROW_NAME3 = "DropdownMenuArrow";
|
|
8080
|
-
var DropdownMenuArrow =
|
|
7943
|
+
var DropdownMenuArrow = React31.forwardRef(
|
|
8081
7944
|
(props, forwardedRef) => {
|
|
8082
7945
|
const { __scopeDropdownMenu, ...arrowProps } = props;
|
|
8083
7946
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8084
|
-
return /* @__PURE__ */ (0,
|
|
7947
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Arrow22, { ...menuScope, ...arrowProps, ref: forwardedRef });
|
|
8085
7948
|
}
|
|
8086
7949
|
);
|
|
8087
7950
|
DropdownMenuArrow.displayName = ARROW_NAME3;
|
|
@@ -8093,20 +7956,20 @@ var DropdownMenuSub = (props) => {
|
|
|
8093
7956
|
defaultProp: defaultOpen,
|
|
8094
7957
|
onChange: onOpenChange
|
|
8095
7958
|
});
|
|
8096
|
-
return /* @__PURE__ */ (0,
|
|
7959
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Sub, { ...menuScope, open, onOpenChange: setOpen, children });
|
|
8097
7960
|
};
|
|
8098
7961
|
var SUB_TRIGGER_NAME2 = "DropdownMenuSubTrigger";
|
|
8099
|
-
var DropdownMenuSubTrigger =
|
|
7962
|
+
var DropdownMenuSubTrigger = React31.forwardRef((props, forwardedRef) => {
|
|
8100
7963
|
const { __scopeDropdownMenu, ...subTriggerProps } = props;
|
|
8101
7964
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8102
|
-
return /* @__PURE__ */ (0,
|
|
7965
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SubTrigger, { ...menuScope, ...subTriggerProps, ref: forwardedRef });
|
|
8103
7966
|
});
|
|
8104
7967
|
DropdownMenuSubTrigger.displayName = SUB_TRIGGER_NAME2;
|
|
8105
7968
|
var SUB_CONTENT_NAME2 = "DropdownMenuSubContent";
|
|
8106
|
-
var DropdownMenuSubContent =
|
|
7969
|
+
var DropdownMenuSubContent = React31.forwardRef((props, forwardedRef) => {
|
|
8107
7970
|
const { __scopeDropdownMenu, ...subContentProps } = props;
|
|
8108
7971
|
const menuScope = useMenuScope(__scopeDropdownMenu);
|
|
8109
|
-
return /* @__PURE__ */ (0,
|
|
7972
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
8110
7973
|
SubContent,
|
|
8111
7974
|
{
|
|
8112
7975
|
...menuScope,
|
|
@@ -8144,15 +8007,15 @@ var SubTrigger2 = DropdownMenuSubTrigger;
|
|
|
8144
8007
|
var SubContent2 = DropdownMenuSubContent;
|
|
8145
8008
|
|
|
8146
8009
|
// src/components/DropDownMenu/index.tsx
|
|
8147
|
-
var
|
|
8148
|
-
var
|
|
8010
|
+
var React32 = __toESM(require("react"));
|
|
8011
|
+
var import_jsx_runtime14 = require("react/jsx-runtime");
|
|
8149
8012
|
var DropdownMenu2 = Root22;
|
|
8150
8013
|
var DropdownMenuTrigger2 = Trigger;
|
|
8151
8014
|
var DropdownMenuGroup2 = Group2;
|
|
8152
8015
|
var DropdownMenuPortal2 = Portal22;
|
|
8153
8016
|
var DropdownMenuSub2 = Sub2;
|
|
8154
8017
|
var DropdownMenuRadioGroup2 = RadioGroup2;
|
|
8155
|
-
var DropdownMenuSubTrigger2 =
|
|
8018
|
+
var DropdownMenuSubTrigger2 = React32.forwardRef(({ className, inset, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
|
|
8156
8019
|
SubTrigger2,
|
|
8157
8020
|
{
|
|
8158
8021
|
ref,
|
|
@@ -8164,12 +8027,12 @@ var DropdownMenuSubTrigger2 = React35.forwardRef(({ className, inset, children,
|
|
|
8164
8027
|
...props,
|
|
8165
8028
|
children: [
|
|
8166
8029
|
children,
|
|
8167
|
-
/* @__PURE__ */ (0,
|
|
8030
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ChevronRight, { className: "cnc-ml-auto cnc-h-4 cnc-w-4" })
|
|
8168
8031
|
]
|
|
8169
8032
|
}
|
|
8170
8033
|
));
|
|
8171
8034
|
DropdownMenuSubTrigger2.displayName = SubTrigger2.displayName;
|
|
8172
|
-
var DropdownMenuSubContent2 =
|
|
8035
|
+
var DropdownMenuSubContent2 = React32.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
8173
8036
|
SubContent2,
|
|
8174
8037
|
{
|
|
8175
8038
|
ref,
|
|
@@ -8181,7 +8044,7 @@ var DropdownMenuSubContent2 = React35.forwardRef(({ className, ...props }, ref)
|
|
|
8181
8044
|
}
|
|
8182
8045
|
));
|
|
8183
8046
|
DropdownMenuSubContent2.displayName = SubContent2.displayName;
|
|
8184
|
-
var DropdownMenuContent2 =
|
|
8047
|
+
var DropdownMenuContent2 = React32.forwardRef(({ className, sideOffset = 4, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Portal22, { children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
8185
8048
|
Content22,
|
|
8186
8049
|
{
|
|
8187
8050
|
ref,
|
|
@@ -8194,7 +8057,7 @@ var DropdownMenuContent2 = React35.forwardRef(({ className, sideOffset = 4, ...p
|
|
|
8194
8057
|
}
|
|
8195
8058
|
) }));
|
|
8196
8059
|
DropdownMenuContent2.displayName = Content22.displayName;
|
|
8197
|
-
var DropdownMenuItem2 =
|
|
8060
|
+
var DropdownMenuItem2 = React32.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
8198
8061
|
Item22,
|
|
8199
8062
|
{
|
|
8200
8063
|
ref,
|
|
@@ -8207,7 +8070,7 @@ var DropdownMenuItem2 = React35.forwardRef(({ className, inset, ...props }, ref)
|
|
|
8207
8070
|
}
|
|
8208
8071
|
));
|
|
8209
8072
|
DropdownMenuItem2.displayName = Item22.displayName;
|
|
8210
|
-
var DropdownMenuCheckboxItem2 =
|
|
8073
|
+
var DropdownMenuCheckboxItem2 = React32.forwardRef(({ className, children, checked, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
|
|
8211
8074
|
CheckboxItem2,
|
|
8212
8075
|
{
|
|
8213
8076
|
ref,
|
|
@@ -8218,13 +8081,13 @@ var DropdownMenuCheckboxItem2 = React35.forwardRef(({ className, children, check
|
|
|
8218
8081
|
checked,
|
|
8219
8082
|
...props,
|
|
8220
8083
|
children: [
|
|
8221
|
-
/* @__PURE__ */ (0,
|
|
8084
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "cnc-absolute cnc-left-2 cnc-flex cnc-h-3.5 cnc-w-3.5 cnc-items-center cnc-justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ItemIndicator2, { children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Check, { className: "h-4 w-4" }) }) }),
|
|
8222
8085
|
children
|
|
8223
8086
|
]
|
|
8224
8087
|
}
|
|
8225
8088
|
));
|
|
8226
8089
|
DropdownMenuCheckboxItem2.displayName = CheckboxItem2.displayName;
|
|
8227
|
-
var DropdownMenuRadioItem2 =
|
|
8090
|
+
var DropdownMenuRadioItem2 = React32.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
|
|
8228
8091
|
RadioItem2,
|
|
8229
8092
|
{
|
|
8230
8093
|
ref,
|
|
@@ -8234,13 +8097,13 @@ var DropdownMenuRadioItem2 = React35.forwardRef(({ className, children, ...props
|
|
|
8234
8097
|
),
|
|
8235
8098
|
...props,
|
|
8236
8099
|
children: [
|
|
8237
|
-
/* @__PURE__ */ (0,
|
|
8100
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "cnc-absolute cnc-left-2 cnc-flex cnc-h-3.5 cnc-w-3.5 cnc-items-center cnc-justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ItemIndicator2, { children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Circle, { className: "h-2 w-2 fill-current" }) }) }),
|
|
8238
8101
|
children
|
|
8239
8102
|
]
|
|
8240
8103
|
}
|
|
8241
8104
|
));
|
|
8242
8105
|
DropdownMenuRadioItem2.displayName = RadioItem2.displayName;
|
|
8243
|
-
var DropdownMenuLabel2 =
|
|
8106
|
+
var DropdownMenuLabel2 = React32.forwardRef(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
8244
8107
|
Label2,
|
|
8245
8108
|
{
|
|
8246
8109
|
ref,
|
|
@@ -8253,7 +8116,7 @@ var DropdownMenuLabel2 = React35.forwardRef(({ className, inset, ...props }, ref
|
|
|
8253
8116
|
}
|
|
8254
8117
|
));
|
|
8255
8118
|
DropdownMenuLabel2.displayName = Label2.displayName;
|
|
8256
|
-
var DropdownMenuSeparator2 =
|
|
8119
|
+
var DropdownMenuSeparator2 = React32.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
8257
8120
|
Separator2,
|
|
8258
8121
|
{
|
|
8259
8122
|
ref,
|
|
@@ -8266,7 +8129,7 @@ var DropdownMenuShortcut = ({
|
|
|
8266
8129
|
className,
|
|
8267
8130
|
...props
|
|
8268
8131
|
}) => {
|
|
8269
|
-
return /* @__PURE__ */ (0,
|
|
8132
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
|
|
8270
8133
|
"span",
|
|
8271
8134
|
{
|
|
8272
8135
|
className: cn(
|
|
@@ -8280,7 +8143,7 @@ var DropdownMenuShortcut = ({
|
|
|
8280
8143
|
DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
|
|
8281
8144
|
|
|
8282
8145
|
// src/components/Header/index.tsx
|
|
8283
|
-
var
|
|
8146
|
+
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
8284
8147
|
function getInitials(fullName) {
|
|
8285
8148
|
if (!fullName) {
|
|
8286
8149
|
return "";
|
|
@@ -8293,36 +8156,49 @@ function getInitials(fullName) {
|
|
|
8293
8156
|
const lastNameInitial = nameParts[nameParts.length - 1][0].toUpperCase();
|
|
8294
8157
|
return `${firstNameInitial}${lastNameInitial}`;
|
|
8295
8158
|
}
|
|
8296
|
-
|
|
8297
|
-
|
|
8298
|
-
...props
|
|
8299
|
-
}) => {
|
|
8300
|
-
return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
|
|
8159
|
+
function Header({ variant = "default", className, ...props }) {
|
|
8160
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
8301
8161
|
"header",
|
|
8302
8162
|
{
|
|
8163
|
+
"data-header-type": variant,
|
|
8303
8164
|
className: cn(
|
|
8304
|
-
"cnc-h-[60px] cnc-flex cnc-items-center cnc-justify-end cnc-gap-4 cnc-px-4 cnc-w-full cnc-shadow-md
|
|
8165
|
+
"cnc-header cnc-h-[60px] cnc-flex cnc-items-center cnc-justify-end cnc-gap-4 cnc-px-4 lg:cnc-px-0 cnc-w-full cnc-shadow-md",
|
|
8166
|
+
variant === "primary" ? "cnc-bg-primary-800" : "cnc-bg-white",
|
|
8305
8167
|
className
|
|
8306
8168
|
),
|
|
8307
8169
|
...props
|
|
8308
8170
|
}
|
|
8309
8171
|
);
|
|
8310
|
-
}
|
|
8172
|
+
}
|
|
8311
8173
|
var HeaderContainer = ({
|
|
8312
8174
|
className,
|
|
8313
8175
|
isOpen,
|
|
8314
8176
|
onOpenMenu,
|
|
8177
|
+
hasSidebar = true,
|
|
8178
|
+
container = false,
|
|
8179
|
+
logo,
|
|
8180
|
+
logoLink,
|
|
8315
8181
|
children,
|
|
8316
8182
|
...props
|
|
8317
8183
|
}) => {
|
|
8318
|
-
|
|
8184
|
+
const renderLogo = () => {
|
|
8185
|
+
if (!hasSidebar && logo) {
|
|
8186
|
+
return logoLink ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("a", { href: logoLink, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("img", { src: logo, alt: "Logotipo", className: "cnc-h-8" }) }) : /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("img", { src: logo, alt: "Logotipo", className: "cnc-h-8" });
|
|
8187
|
+
}
|
|
8188
|
+
return null;
|
|
8189
|
+
};
|
|
8190
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
8319
8191
|
"div",
|
|
8320
8192
|
{
|
|
8321
|
-
className: cn(
|
|
8193
|
+
className: cn(
|
|
8194
|
+
"cnc-flex cnc-flex-1 cnc-justify-between cnc-items-center",
|
|
8195
|
+
container && "cnc-container cnc-mx-auto",
|
|
8196
|
+
className
|
|
8197
|
+
),
|
|
8322
8198
|
...props,
|
|
8323
8199
|
children: [
|
|
8324
|
-
/* @__PURE__ */ (0,
|
|
8325
|
-
/* @__PURE__ */ (0,
|
|
8200
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "cnc-flex cnc-items-center", children: onOpenMenu && !isOpen && hasSidebar ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("button", { onClick: onOpenMenu, className: "hover:cnc-brightness-75 cnc-sidebar-child-hidden cnc-cursor-pointer", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("svg", { stroke: "currentColor", fill: "currentColor", strokeWidth: "0", viewBox: "0 0 512 512", className: "cnc-size-6 cnc-text-brand-blue-900 cnc-header-item", height: "1em", width: "1em", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { fill: "none", strokeLinecap: "round", strokeMiterlimit: "10", strokeWidth: "48", d: "M88 152h336M88 256h336M88 360h336" }) }) }) : !hasSidebar && renderLogo() }),
|
|
8201
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "cnc-flex", children })
|
|
8326
8202
|
]
|
|
8327
8203
|
}
|
|
8328
8204
|
);
|
|
@@ -8333,22 +8209,22 @@ var HeaderProfileHeader = ({
|
|
|
8333
8209
|
}) => {
|
|
8334
8210
|
const { userName, entityName } = user;
|
|
8335
8211
|
const initials = getInitials(userName);
|
|
8336
|
-
return /* @__PURE__ */ (0,
|
|
8337
|
-
/* @__PURE__ */ (0,
|
|
8212
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(DropdownMenu2, { children: [
|
|
8213
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DropdownMenuTrigger2, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
8338
8214
|
"div",
|
|
8339
8215
|
{
|
|
8340
8216
|
id: "cnc-border-lateral",
|
|
8341
|
-
className: "cnc-border-solid cnc-border-l-2 cnc-border-brand-blue-60",
|
|
8342
|
-
children: /* @__PURE__ */ (0,
|
|
8343
|
-
/* @__PURE__ */ (0,
|
|
8344
|
-
/* @__PURE__ */ (0,
|
|
8345
|
-
/* @__PURE__ */ (0,
|
|
8217
|
+
className: "cnc-border-solid cnc-border-l-2 cnc-border-brand-blue-60 cnc-header-item",
|
|
8218
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "cnc-flex cnc-flex-row cnc-gap-2 cnc-items-center cnc-justify-center hover:cnc-bg-gray-100 cnc-transition cnc-duration-300 cnc-ease-in-out cnc-cursor-pointer cnc-px-4 cnc-py-2 cnc-rounded-lg cnc-ml-8 cnc-header-item", children: [
|
|
8219
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "cnc-flex cnc-flex-col cnc-justify-end cnc-text-end", children: [
|
|
8220
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "cnc-text-xs cnc-font-extrabold cnc-text-brand-blue-900 cnc-header-item", children: entityName }),
|
|
8221
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "cnc-text-xs cnc-font-normal cnc-text-brand-gray-700 cnc-header-item/50", children: userName })
|
|
8346
8222
|
] }),
|
|
8347
|
-
/* @__PURE__ */ (0,
|
|
8223
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "cnc-flex cnc-items-center cnc-justify-center cnc-w-10 cnc-h-10 cnc-rounded-full cnc-bg-brand-white cnc-text-brand-blue-900 cnc-text-sm cnc-font-normal cnc-border-solid cnc-border-2 cnc-header-item", children: initials }) })
|
|
8348
8224
|
] })
|
|
8349
8225
|
}
|
|
8350
8226
|
) }),
|
|
8351
|
-
/* @__PURE__ */ (0,
|
|
8227
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DropdownMenuContent2, { children })
|
|
8352
8228
|
] });
|
|
8353
8229
|
};
|
|
8354
8230
|
var HeaderProfileItem = ({
|
|
@@ -8356,38 +8232,37 @@ var HeaderProfileItem = ({
|
|
|
8356
8232
|
icon,
|
|
8357
8233
|
children
|
|
8358
8234
|
}) => {
|
|
8359
|
-
return /* @__PURE__ */ (0,
|
|
8235
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(DropdownMenuItem2, { onClick, children: [
|
|
8360
8236
|
icon,
|
|
8361
8237
|
children
|
|
8362
8238
|
] });
|
|
8363
8239
|
};
|
|
8364
8240
|
var AplicationsHeader = ({ children }) => {
|
|
8365
|
-
return /* @__PURE__ */ (0,
|
|
8366
|
-
/* @__PURE__ */ (0,
|
|
8241
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_jsx_runtime15.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(DropdownMenu2, { children: [
|
|
8242
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DropdownMenuTrigger2, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "cnc-flex cnc-flex-row cnc-gap-2 cnc-items-center cnc-justify-center hover:cnc-bg-gray-100 cnc-transition cnc-duration-300 cnc-ease-in-out cnc-cursor-pointer cnc-px-4 cnc-py-2 cnc-rounded-lg cnc-header-item", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
8367
8243
|
"svg",
|
|
8368
8244
|
{
|
|
8369
8245
|
width: "18",
|
|
8370
8246
|
height: "18",
|
|
8371
8247
|
viewBox: "0 0 16 16",
|
|
8372
|
-
fill: "none",
|
|
8373
8248
|
xmlns: "http://www.w3.org/2000/svg",
|
|
8374
|
-
|
|
8249
|
+
className: "cnc-header-item",
|
|
8250
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
8375
8251
|
"path",
|
|
8376
8252
|
{
|
|
8377
|
-
d: "M2 4C3.1 4 4 3.1 4 2C4 0.9 3.1 0 2 0C0.9 0 0 0.9 0 2C0 3.1 0.9 4 2 4ZM8 16C9.1 16 10 15.1 10 14C10 12.9 9.1 12 8 12C6.9 12 6 12.9 6 14C6 15.1 6.9 16 8 16ZM2 16C3.1 16 4 15.1 4 14C4 12.9 3.1 12 2 12C0.9 12 0 12.9 0 14C0 15.1 0.9 16 2 16ZM2 10C3.1 10 4 9.1 4 8C4 6.9 3.1 6 2 6C0.9 6 0 6.9 0 8C0 9.1 0.9 10 2 10ZM8 10C9.1 10 10 9.1 10 8C10 6.9 9.1 6 8 6C6.9 6 6 6.9 6 8C6 9.1 6.9 10 8 10ZM12 2C12 3.1 12.9 4 14 4C15.1 4 16 3.1 16 2C16 0.9 15.1 0 14 0C12.9 0 12 0.9 12 2ZM8 4C9.1 4 10 3.1 10 2C10 0.9 9.1 0 8 0C6.9 0 6 0.9 6 2C6 3.1 6.9 4 8 4ZM14 10C15.1 10 16 9.1 16 8C16 6.9 15.1 6 14 6C12.9 6 12 6.9 12 8C12 9.1 12.9 10 14 10ZM14 16C15.1 16 16 15.1 16 14C16 12.9 15.1 12 14 12C12.9 12 12 12.9 12 14C12 15.1 12.9 16 14 16Z"
|
|
8378
|
-
fill: "black"
|
|
8253
|
+
d: "M2 4C3.1 4 4 3.1 4 2C4 0.9 3.1 0 2 0C0.9 0 0 0.9 0 2C0 3.1 0.9 4 2 4ZM8 16C9.1 16 10 15.1 10 14C10 12.9 9.1 12 8 12C6.9 12 6 12.9 6 14C6 15.1 6.9 16 8 16ZM2 16C3.1 16 4 15.1 4 14C4 12.9 3.1 12 2 12C0.9 12 0 12.9 0 14C0 15.1 0.9 16 2 16ZM2 10C3.1 10 4 9.1 4 8C4 6.9 3.1 6 2 6C0.9 6 0 6.9 0 8C0 9.1 0.9 10 2 10ZM8 10C9.1 10 10 9.1 10 8C10 6.9 9.1 6 8 6C6.9 6 6 6.9 6 8C6 9.1 6.9 10 8 10ZM12 2C12 3.1 12.9 4 14 4C15.1 4 16 3.1 16 2C16 0.9 15.1 0 14 0C12.9 0 12 0.9 12 2ZM8 4C9.1 4 10 3.1 10 2C10 0.9 9.1 0 8 0C6.9 0 6 0.9 6 2C6 3.1 6.9 4 8 4ZM14 10C15.1 10 16 9.1 16 8C16 6.9 15.1 6 14 6C12.9 6 12 6.9 12 8C12 9.1 12.9 10 14 10ZM14 16C15.1 16 16 15.1 16 14C16 12.9 15.1 12 14 12C12.9 12 12 12.9 12 14C12 15.1 12.9 16 14 16Z"
|
|
8379
8254
|
}
|
|
8380
8255
|
)
|
|
8381
8256
|
}
|
|
8382
8257
|
) }) }),
|
|
8383
|
-
/* @__PURE__ */ (0,
|
|
8258
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DropdownMenuContent2, { className: "flex", children })
|
|
8384
8259
|
] }) });
|
|
8385
8260
|
};
|
|
8386
8261
|
|
|
8387
8262
|
// ../../node_modules/@radix-ui/react-dialog/dist/index.mjs
|
|
8388
|
-
var
|
|
8263
|
+
var React33 = __toESM(require("react"), 1);
|
|
8389
8264
|
var import_react_slot5 = require("@radix-ui/react-slot");
|
|
8390
|
-
var
|
|
8265
|
+
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
8391
8266
|
var DIALOG_NAME = "Dialog";
|
|
8392
8267
|
var [createDialogContext, createDialogScope] = createContextScope(DIALOG_NAME);
|
|
8393
8268
|
var [DialogProvider, useDialogContext] = createDialogContext(DIALOG_NAME);
|
|
@@ -8400,14 +8275,14 @@ var Dialog = (props) => {
|
|
|
8400
8275
|
onOpenChange,
|
|
8401
8276
|
modal = true
|
|
8402
8277
|
} = props;
|
|
8403
|
-
const triggerRef =
|
|
8404
|
-
const contentRef =
|
|
8278
|
+
const triggerRef = React33.useRef(null);
|
|
8279
|
+
const contentRef = React33.useRef(null);
|
|
8405
8280
|
const [open = false, setOpen] = useControllableState({
|
|
8406
8281
|
prop: openProp,
|
|
8407
8282
|
defaultProp: defaultOpen,
|
|
8408
8283
|
onChange: onOpenChange
|
|
8409
8284
|
});
|
|
8410
|
-
return /* @__PURE__ */ (0,
|
|
8285
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8411
8286
|
DialogProvider,
|
|
8412
8287
|
{
|
|
8413
8288
|
scope: __scopeDialog,
|
|
@@ -8418,7 +8293,7 @@ var Dialog = (props) => {
|
|
|
8418
8293
|
descriptionId: useId(),
|
|
8419
8294
|
open,
|
|
8420
8295
|
onOpenChange: setOpen,
|
|
8421
|
-
onOpenToggle:
|
|
8296
|
+
onOpenToggle: React33.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),
|
|
8422
8297
|
modal,
|
|
8423
8298
|
children
|
|
8424
8299
|
}
|
|
@@ -8426,12 +8301,12 @@ var Dialog = (props) => {
|
|
|
8426
8301
|
};
|
|
8427
8302
|
Dialog.displayName = DIALOG_NAME;
|
|
8428
8303
|
var TRIGGER_NAME2 = "DialogTrigger";
|
|
8429
|
-
var DialogTrigger =
|
|
8304
|
+
var DialogTrigger = React33.forwardRef(
|
|
8430
8305
|
(props, forwardedRef) => {
|
|
8431
8306
|
const { __scopeDialog, ...triggerProps } = props;
|
|
8432
8307
|
const context = useDialogContext(TRIGGER_NAME2, __scopeDialog);
|
|
8433
8308
|
const composedTriggerRef = useComposedRefs(forwardedRef, context.triggerRef);
|
|
8434
|
-
return /* @__PURE__ */ (0,
|
|
8309
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8435
8310
|
Primitive.button,
|
|
8436
8311
|
{
|
|
8437
8312
|
type: "button",
|
|
@@ -8454,27 +8329,27 @@ var [PortalProvider2, usePortalContext2] = createDialogContext(PORTAL_NAME4, {
|
|
|
8454
8329
|
var DialogPortal = (props) => {
|
|
8455
8330
|
const { __scopeDialog, forceMount, children, container } = props;
|
|
8456
8331
|
const context = useDialogContext(PORTAL_NAME4, __scopeDialog);
|
|
8457
|
-
return /* @__PURE__ */ (0,
|
|
8332
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(PortalProvider2, { scope: __scopeDialog, forceMount, children: React33.Children.map(children, (child) => /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Portal, { asChild: true, container, children: child }) })) });
|
|
8458
8333
|
};
|
|
8459
8334
|
DialogPortal.displayName = PORTAL_NAME4;
|
|
8460
8335
|
var OVERLAY_NAME = "DialogOverlay";
|
|
8461
|
-
var DialogOverlay =
|
|
8336
|
+
var DialogOverlay = React33.forwardRef(
|
|
8462
8337
|
(props, forwardedRef) => {
|
|
8463
8338
|
const portalContext = usePortalContext2(OVERLAY_NAME, props.__scopeDialog);
|
|
8464
8339
|
const { forceMount = portalContext.forceMount, ...overlayProps } = props;
|
|
8465
8340
|
const context = useDialogContext(OVERLAY_NAME, props.__scopeDialog);
|
|
8466
|
-
return context.modal ? /* @__PURE__ */ (0,
|
|
8341
|
+
return context.modal ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(DialogOverlayImpl, { ...overlayProps, ref: forwardedRef }) }) : null;
|
|
8467
8342
|
}
|
|
8468
8343
|
);
|
|
8469
8344
|
DialogOverlay.displayName = OVERLAY_NAME;
|
|
8470
|
-
var DialogOverlayImpl =
|
|
8345
|
+
var DialogOverlayImpl = React33.forwardRef(
|
|
8471
8346
|
(props, forwardedRef) => {
|
|
8472
8347
|
const { __scopeDialog, ...overlayProps } = props;
|
|
8473
8348
|
const context = useDialogContext(OVERLAY_NAME, __scopeDialog);
|
|
8474
8349
|
return (
|
|
8475
8350
|
// Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
|
|
8476
8351
|
// ie. when `Overlay` and `Content` are siblings
|
|
8477
|
-
/* @__PURE__ */ (0,
|
|
8352
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Combination_default, { as: import_react_slot5.Slot, allowPinchZoom: true, shards: [context.contentRef], children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8478
8353
|
Primitive.div,
|
|
8479
8354
|
{
|
|
8480
8355
|
"data-state": getState(context.open),
|
|
@@ -8487,25 +8362,25 @@ var DialogOverlayImpl = React36.forwardRef(
|
|
|
8487
8362
|
}
|
|
8488
8363
|
);
|
|
8489
8364
|
var CONTENT_NAME4 = "DialogContent";
|
|
8490
|
-
var DialogContent =
|
|
8365
|
+
var DialogContent = React33.forwardRef(
|
|
8491
8366
|
(props, forwardedRef) => {
|
|
8492
8367
|
const portalContext = usePortalContext2(CONTENT_NAME4, props.__scopeDialog);
|
|
8493
8368
|
const { forceMount = portalContext.forceMount, ...contentProps } = props;
|
|
8494
8369
|
const context = useDialogContext(CONTENT_NAME4, props.__scopeDialog);
|
|
8495
|
-
return /* @__PURE__ */ (0,
|
|
8370
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Presence, { present: forceMount || context.open, children: context.modal ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(DialogContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(DialogContentNonModal, { ...contentProps, ref: forwardedRef }) });
|
|
8496
8371
|
}
|
|
8497
8372
|
);
|
|
8498
8373
|
DialogContent.displayName = CONTENT_NAME4;
|
|
8499
|
-
var DialogContentModal =
|
|
8374
|
+
var DialogContentModal = React33.forwardRef(
|
|
8500
8375
|
(props, forwardedRef) => {
|
|
8501
8376
|
const context = useDialogContext(CONTENT_NAME4, props.__scopeDialog);
|
|
8502
|
-
const contentRef =
|
|
8377
|
+
const contentRef = React33.useRef(null);
|
|
8503
8378
|
const composedRefs = useComposedRefs(forwardedRef, context.contentRef, contentRef);
|
|
8504
|
-
|
|
8379
|
+
React33.useEffect(() => {
|
|
8505
8380
|
const content = contentRef.current;
|
|
8506
8381
|
if (content) return hideOthers(content);
|
|
8507
8382
|
}, []);
|
|
8508
|
-
return /* @__PURE__ */ (0,
|
|
8383
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8509
8384
|
DialogContentImpl,
|
|
8510
8385
|
{
|
|
8511
8386
|
...props,
|
|
@@ -8530,12 +8405,12 @@ var DialogContentModal = React36.forwardRef(
|
|
|
8530
8405
|
);
|
|
8531
8406
|
}
|
|
8532
8407
|
);
|
|
8533
|
-
var DialogContentNonModal =
|
|
8408
|
+
var DialogContentNonModal = React33.forwardRef(
|
|
8534
8409
|
(props, forwardedRef) => {
|
|
8535
8410
|
const context = useDialogContext(CONTENT_NAME4, props.__scopeDialog);
|
|
8536
|
-
const hasInteractedOutsideRef =
|
|
8537
|
-
const hasPointerDownOutsideRef =
|
|
8538
|
-
return /* @__PURE__ */ (0,
|
|
8411
|
+
const hasInteractedOutsideRef = React33.useRef(false);
|
|
8412
|
+
const hasPointerDownOutsideRef = React33.useRef(false);
|
|
8413
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8539
8414
|
DialogContentImpl,
|
|
8540
8415
|
{
|
|
8541
8416
|
...props,
|
|
@@ -8570,15 +8445,15 @@ var DialogContentNonModal = React36.forwardRef(
|
|
|
8570
8445
|
);
|
|
8571
8446
|
}
|
|
8572
8447
|
);
|
|
8573
|
-
var DialogContentImpl =
|
|
8448
|
+
var DialogContentImpl = React33.forwardRef(
|
|
8574
8449
|
(props, forwardedRef) => {
|
|
8575
8450
|
const { __scopeDialog, trapFocus, onOpenAutoFocus, onCloseAutoFocus, ...contentProps } = props;
|
|
8576
8451
|
const context = useDialogContext(CONTENT_NAME4, __scopeDialog);
|
|
8577
|
-
const contentRef =
|
|
8452
|
+
const contentRef = React33.useRef(null);
|
|
8578
8453
|
const composedRefs = useComposedRefs(forwardedRef, contentRef);
|
|
8579
8454
|
useFocusGuards();
|
|
8580
|
-
return /* @__PURE__ */ (0,
|
|
8581
|
-
/* @__PURE__ */ (0,
|
|
8455
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, { children: [
|
|
8456
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8582
8457
|
FocusScope,
|
|
8583
8458
|
{
|
|
8584
8459
|
asChild: true,
|
|
@@ -8586,7 +8461,7 @@ var DialogContentImpl = React36.forwardRef(
|
|
|
8586
8461
|
trapped: trapFocus,
|
|
8587
8462
|
onMountAutoFocus: onOpenAutoFocus,
|
|
8588
8463
|
onUnmountAutoFocus: onCloseAutoFocus,
|
|
8589
|
-
children: /* @__PURE__ */ (0,
|
|
8464
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8590
8465
|
DismissableLayer,
|
|
8591
8466
|
{
|
|
8592
8467
|
role: "dialog",
|
|
@@ -8601,37 +8476,37 @@ var DialogContentImpl = React36.forwardRef(
|
|
|
8601
8476
|
)
|
|
8602
8477
|
}
|
|
8603
8478
|
),
|
|
8604
|
-
/* @__PURE__ */ (0,
|
|
8605
|
-
/* @__PURE__ */ (0,
|
|
8606
|
-
/* @__PURE__ */ (0,
|
|
8479
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, { children: [
|
|
8480
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(TitleWarning, { titleId: context.titleId }),
|
|
8481
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(DescriptionWarning, { contentRef, descriptionId: context.descriptionId })
|
|
8607
8482
|
] })
|
|
8608
8483
|
] });
|
|
8609
8484
|
}
|
|
8610
8485
|
);
|
|
8611
8486
|
var TITLE_NAME = "DialogTitle";
|
|
8612
|
-
var DialogTitle =
|
|
8487
|
+
var DialogTitle = React33.forwardRef(
|
|
8613
8488
|
(props, forwardedRef) => {
|
|
8614
8489
|
const { __scopeDialog, ...titleProps } = props;
|
|
8615
8490
|
const context = useDialogContext(TITLE_NAME, __scopeDialog);
|
|
8616
|
-
return /* @__PURE__ */ (0,
|
|
8491
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Primitive.h2, { id: context.titleId, ...titleProps, ref: forwardedRef });
|
|
8617
8492
|
}
|
|
8618
8493
|
);
|
|
8619
8494
|
DialogTitle.displayName = TITLE_NAME;
|
|
8620
8495
|
var DESCRIPTION_NAME = "DialogDescription";
|
|
8621
|
-
var DialogDescription =
|
|
8496
|
+
var DialogDescription = React33.forwardRef(
|
|
8622
8497
|
(props, forwardedRef) => {
|
|
8623
8498
|
const { __scopeDialog, ...descriptionProps } = props;
|
|
8624
8499
|
const context = useDialogContext(DESCRIPTION_NAME, __scopeDialog);
|
|
8625
|
-
return /* @__PURE__ */ (0,
|
|
8500
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Primitive.p, { id: context.descriptionId, ...descriptionProps, ref: forwardedRef });
|
|
8626
8501
|
}
|
|
8627
8502
|
);
|
|
8628
8503
|
DialogDescription.displayName = DESCRIPTION_NAME;
|
|
8629
8504
|
var CLOSE_NAME = "DialogClose";
|
|
8630
|
-
var DialogClose =
|
|
8505
|
+
var DialogClose = React33.forwardRef(
|
|
8631
8506
|
(props, forwardedRef) => {
|
|
8632
8507
|
const { __scopeDialog, ...closeProps } = props;
|
|
8633
8508
|
const context = useDialogContext(CLOSE_NAME, __scopeDialog);
|
|
8634
|
-
return /* @__PURE__ */ (0,
|
|
8509
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
8635
8510
|
Primitive.button,
|
|
8636
8511
|
{
|
|
8637
8512
|
type: "button",
|
|
@@ -8659,7 +8534,7 @@ var TitleWarning = ({ titleId }) => {
|
|
|
8659
8534
|
If you want to hide the \`${titleWarningContext.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
8660
8535
|
|
|
8661
8536
|
For more information, see https://radix-ui.com/primitives/docs/components/${titleWarningContext.docsSlug}`;
|
|
8662
|
-
|
|
8537
|
+
React33.useEffect(() => {
|
|
8663
8538
|
if (titleId) {
|
|
8664
8539
|
const hasTitle = document.getElementById(titleId);
|
|
8665
8540
|
if (!hasTitle) console.error(MESSAGE);
|
|
@@ -8671,7 +8546,7 @@ var DESCRIPTION_WARNING_NAME = "DialogDescriptionWarning";
|
|
|
8671
8546
|
var DescriptionWarning = ({ contentRef, descriptionId }) => {
|
|
8672
8547
|
const descriptionWarningContext = useWarningContext(DESCRIPTION_WARNING_NAME);
|
|
8673
8548
|
const MESSAGE = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${descriptionWarningContext.contentName}}.`;
|
|
8674
|
-
|
|
8549
|
+
React33.useEffect(() => {
|
|
8675
8550
|
const describedById = contentRef.current?.getAttribute("aria-describedby");
|
|
8676
8551
|
if (descriptionId && describedById) {
|
|
8677
8552
|
const hasDescription = document.getElementById(descriptionId);
|
|
@@ -8690,13 +8565,13 @@ var Description = DialogDescription;
|
|
|
8690
8565
|
var Close = DialogClose;
|
|
8691
8566
|
|
|
8692
8567
|
// src/components/Dialog/index.tsx
|
|
8693
|
-
var
|
|
8694
|
-
var
|
|
8568
|
+
var React34 = __toESM(require("react"));
|
|
8569
|
+
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
8695
8570
|
var Dialog2 = Root4;
|
|
8696
8571
|
var DialogTrigger2 = Trigger2;
|
|
8697
8572
|
var DialogPortal2 = Portal3;
|
|
8698
8573
|
var DialogClose2 = Close;
|
|
8699
|
-
var DialogOverlay2 =
|
|
8574
|
+
var DialogOverlay2 = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
8700
8575
|
Overlay,
|
|
8701
8576
|
{
|
|
8702
8577
|
ref,
|
|
@@ -8708,9 +8583,9 @@ var DialogOverlay2 = React37.forwardRef(({ className, ...props }, ref) => /* @__
|
|
|
8708
8583
|
}
|
|
8709
8584
|
));
|
|
8710
8585
|
DialogOverlay2.displayName = Overlay.displayName;
|
|
8711
|
-
var DialogContent2 =
|
|
8712
|
-
/* @__PURE__ */ (0,
|
|
8713
|
-
/* @__PURE__ */ (0,
|
|
8586
|
+
var DialogContent2 = React34.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(DialogPortal2, { children: [
|
|
8587
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(DialogOverlay2, {}),
|
|
8588
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
|
|
8714
8589
|
Content3,
|
|
8715
8590
|
{
|
|
8716
8591
|
ref,
|
|
@@ -8721,9 +8596,9 @@ var DialogContent2 = React37.forwardRef(({ className, children, ...props }, ref)
|
|
|
8721
8596
|
...props,
|
|
8722
8597
|
children: [
|
|
8723
8598
|
children,
|
|
8724
|
-
/* @__PURE__ */ (0,
|
|
8725
|
-
/* @__PURE__ */ (0,
|
|
8726
|
-
/* @__PURE__ */ (0,
|
|
8599
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(Close, { className: "cnc-absolute cnc-right-4 cnc-top-4 cnc-rounded-sm cnc-opacity-70 cnc-ring-offset-background cnc-transition-opacity hover:cnc-opacity-100 focus:cnc-outline-none focus:cnc-ring-2 focus:cnc-ring-ring focus:cnc-ring-offset-2 disabled:cnc-pointer-events-none data-[state=open]:cnc-bg-accent data-[state=open]:cnc-text-muted-foreground", children: [
|
|
8600
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(X, { className: "cnc-h-4 cnc-w-4" }),
|
|
8601
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)("span", { className: "cnc-sr-only", children: "Close" })
|
|
8727
8602
|
] })
|
|
8728
8603
|
]
|
|
8729
8604
|
}
|
|
@@ -8733,7 +8608,7 @@ DialogContent2.displayName = Content3.displayName;
|
|
|
8733
8608
|
var DialogHeader = ({
|
|
8734
8609
|
className,
|
|
8735
8610
|
...props
|
|
8736
|
-
}) => /* @__PURE__ */ (0,
|
|
8611
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
8737
8612
|
"div",
|
|
8738
8613
|
{
|
|
8739
8614
|
className: cn(
|
|
@@ -8747,7 +8622,7 @@ DialogHeader.displayName = "DialogHeader";
|
|
|
8747
8622
|
var DialogFooter = ({
|
|
8748
8623
|
className,
|
|
8749
8624
|
...props
|
|
8750
|
-
}) => /* @__PURE__ */ (0,
|
|
8625
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
8751
8626
|
"div",
|
|
8752
8627
|
{
|
|
8753
8628
|
className: cn(
|
|
@@ -8758,7 +8633,7 @@ var DialogFooter = ({
|
|
|
8758
8633
|
}
|
|
8759
8634
|
);
|
|
8760
8635
|
DialogFooter.displayName = "DialogFooter";
|
|
8761
|
-
var DialogTitle2 =
|
|
8636
|
+
var DialogTitle2 = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
8762
8637
|
Title,
|
|
8763
8638
|
{
|
|
8764
8639
|
ref,
|
|
@@ -8770,7 +8645,7 @@ var DialogTitle2 = React37.forwardRef(({ className, ...props }, ref) => /* @__PU
|
|
|
8770
8645
|
}
|
|
8771
8646
|
));
|
|
8772
8647
|
DialogTitle2.displayName = Title.displayName;
|
|
8773
|
-
var DialogDescription2 =
|
|
8648
|
+
var DialogDescription2 = React34.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
8774
8649
|
Description,
|
|
8775
8650
|
{
|
|
8776
8651
|
ref,
|
|
@@ -8781,24 +8656,42 @@ var DialogDescription2 = React37.forwardRef(({ className, ...props }, ref) => /*
|
|
|
8781
8656
|
DialogDescription2.displayName = Description.displayName;
|
|
8782
8657
|
|
|
8783
8658
|
// src/components/Modal/index.tsx
|
|
8784
|
-
var
|
|
8659
|
+
var import_jsx_runtime18 = require("react/jsx-runtime");
|
|
8785
8660
|
var Modal = ({
|
|
8786
8661
|
title,
|
|
8787
8662
|
content,
|
|
8788
8663
|
visibleModal,
|
|
8789
8664
|
onClose
|
|
8790
8665
|
}) => {
|
|
8791
|
-
return /* @__PURE__ */ (0,
|
|
8792
|
-
/* @__PURE__ */ (0,
|
|
8793
|
-
/* @__PURE__ */ (0,
|
|
8794
|
-
title && /* @__PURE__ */ (0,
|
|
8795
|
-
/* @__PURE__ */ (0,
|
|
8666
|
+
return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(Dialog2, { open: visibleModal, onOpenChange: onClose, children: [
|
|
8667
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)(DialogOverlay2, { className: "cnc-inset-0 cnc-bg-blackA6= data-[state=open]:cnc-animate-overlayShow" }),
|
|
8668
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(DialogContent2, { className: "cnc-max-h-[100vh] cnc-p-0 cnc-rounded-sm cnc-bg-white cnc-focus:outline-none data-[state=open]:cnc-animate-contentShow", children: [
|
|
8669
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(DialogHeader, { className: "cnc-text-sm cnc-h-14 cnc-text-black cnc-font- cnc-border-b cnc-w-full cnc-leading-10", children: title }),
|
|
8670
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "cnc-flex cnc-flex-col cnc-mb-16 cnc-mx-20 cnc-align-middle cnc-items-left cnc-justify-center", children: content })
|
|
8796
8671
|
] })
|
|
8797
8672
|
] });
|
|
8798
8673
|
};
|
|
8799
8674
|
|
|
8800
8675
|
// src/components/Modal/ModalMudancaEntidade/index.tsx
|
|
8801
|
-
var
|
|
8676
|
+
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
8677
|
+
function ModalEntidade({ isOpen, onOpenChange, title = "Selecionar a entidade", children, className }) {
|
|
8678
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(Dialog2, { open: isOpen, onOpenChange, children: [
|
|
8679
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(DialogOverlay2, { className: "fixed inset-0 z-50 cnc-bg-black/40 data-[state=open]:cnc-animate-in data-[state=closed]:cnc-animate-out data-[state=closed]:cnc-fade-out-0 data-[state=open]:fade-in-0" }),
|
|
8680
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(DialogContent2, { className: "cnc-max-h-[100vh] cnc-p-0 cnc-rounded-sm cnc-bg-white cnc-focus:outline-none data-[state=open]:cnc-animate-contentShow", children: [
|
|
8681
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(DialogHeader, { children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(DialogTitle2, { className: "cnc-font-normal cnc-text-base", children: title }) }),
|
|
8682
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
8683
|
+
"div",
|
|
8684
|
+
{
|
|
8685
|
+
className: cn(
|
|
8686
|
+
"cnc-flex cnc-flex-col cnc-w-full cnc-max-w-[513px] cnc-mx-auto cnc-py-6",
|
|
8687
|
+
className
|
|
8688
|
+
),
|
|
8689
|
+
children
|
|
8690
|
+
}
|
|
8691
|
+
)
|
|
8692
|
+
] })
|
|
8693
|
+
] });
|
|
8694
|
+
}
|
|
8802
8695
|
var ModalMudancaEntidade = ({
|
|
8803
8696
|
title,
|
|
8804
8697
|
onClose,
|
|
@@ -8806,17 +8699,17 @@ var ModalMudancaEntidade = ({
|
|
|
8806
8699
|
SelectComponent,
|
|
8807
8700
|
buttonAction
|
|
8808
8701
|
}) => {
|
|
8809
|
-
return /* @__PURE__ */ (0,
|
|
8702
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
8810
8703
|
Modal,
|
|
8811
8704
|
{
|
|
8812
8705
|
title,
|
|
8813
8706
|
onClose,
|
|
8814
8707
|
visibleModal,
|
|
8815
|
-
content: /* @__PURE__ */ (0,
|
|
8816
|
-
/* @__PURE__ */ (0,
|
|
8817
|
-
/* @__PURE__ */ (0,
|
|
8818
|
-
/* @__PURE__ */ (0,
|
|
8819
|
-
/* @__PURE__ */ (0,
|
|
8708
|
+
content: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(import_jsx_runtime19.Fragment, { children: [
|
|
8709
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(DialogTitle2, { className: "cnc-DialogTitle cnc-mt-10 cnc-mb-4 ", children: "Selecionar a entidade" }),
|
|
8710
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "cnc-flex cnc-mb-5 ", children: [
|
|
8711
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(SelectComponent, {}),
|
|
8712
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Button, { className: "cnc-text-white cnc-ml-5", onClick: buttonAction, children: "Trocar entidade" })
|
|
8820
8713
|
] })
|
|
8821
8714
|
] })
|
|
8822
8715
|
}
|
|
@@ -8829,9 +8722,9 @@ var import_react_slot6 = require("@radix-ui/react-slot");
|
|
|
8829
8722
|
var import_react7 = require("react");
|
|
8830
8723
|
|
|
8831
8724
|
// src/components/assets/logotipo-default.tsx
|
|
8832
|
-
var
|
|
8725
|
+
var import_jsx_runtime20 = require("react/jsx-runtime");
|
|
8833
8726
|
function LogotipoDefault() {
|
|
8834
|
-
return /* @__PURE__ */ (0,
|
|
8727
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(
|
|
8835
8728
|
"svg",
|
|
8836
8729
|
{
|
|
8837
8730
|
width: "209",
|
|
@@ -8840,14 +8733,14 @@ function LogotipoDefault() {
|
|
|
8840
8733
|
fill: "none",
|
|
8841
8734
|
xmlns: "http://www.w3.org/2000/svg",
|
|
8842
8735
|
children: [
|
|
8843
|
-
/* @__PURE__ */ (0,
|
|
8736
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8844
8737
|
"path",
|
|
8845
8738
|
{
|
|
8846
8739
|
d: "M20.539 0H36.2809C36.2809 0 36.9745 4.48363 30.7294 6.63394C31.7327 5.31688 31.7006 3.41772 31.7006 3.41772H20.202C9.32 3.41772 1.29805 18.1019 0.207031 20.0001C0.207031 20.0001 4.07335 8.64018 11.9375 3.02348C13.5682 1.85731 17.0906 0 20.539 0Z",
|
|
8847
8740
|
fill: "#C89633"
|
|
8848
8741
|
}
|
|
8849
8742
|
),
|
|
8850
|
-
/* @__PURE__ */ (0,
|
|
8743
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8851
8744
|
"path",
|
|
8852
8745
|
{
|
|
8853
8746
|
fillRule: "evenodd",
|
|
@@ -8856,133 +8749,133 @@ function LogotipoDefault() {
|
|
|
8856
8749
|
fill: "#C89633"
|
|
8857
8750
|
}
|
|
8858
8751
|
),
|
|
8859
|
-
/* @__PURE__ */ (0,
|
|
8752
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8860
8753
|
"path",
|
|
8861
8754
|
{
|
|
8862
8755
|
d: "M15.6289 10.2526C17.6892 10.2994 18.8026 10.313 18.8026 10.313C19.9394 10.3344 20.9691 10.2497 21.9198 10.1621C21.1415 11.8189 19.2049 13.5127 13.9602 13.4134C7.19489 13.2859 3.46398 16.9946 1.55469 18.9863L1.56405 18.9719C3.47675 16.0444 7.38469 10.0631 15.6289 10.2526Z",
|
|
8863
8756
|
fill: "white"
|
|
8864
8757
|
}
|
|
8865
8758
|
),
|
|
8866
|
-
/* @__PURE__ */ (0,
|
|
8759
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8867
8760
|
"path",
|
|
8868
8761
|
{
|
|
8869
8762
|
d: "M60.457 3.08307V4.09961H61.9417H63.4264V3.08307V2.06652H61.9417H60.457V3.08307Z",
|
|
8870
8763
|
fill: "white"
|
|
8871
8764
|
}
|
|
8872
8765
|
),
|
|
8873
|
-
/* @__PURE__ */ (0,
|
|
8766
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8874
8767
|
"path",
|
|
8875
8768
|
{
|
|
8876
8769
|
d: "M53.2447 2.39671C51.2817 2.622 49.907 3.55062 49.4231 4.97928C49.2636 5.43535 49.2746 6.85851 49.4396 7.2926C49.885 8.49596 50.8803 9.12237 53.3052 9.7268C55.1198 10.1829 55.4222 10.2873 55.8456 10.6005C56.0601 10.7598 56.1866 11.117 56.1536 11.4906C56.0986 12.1665 55.5432 12.5017 54.372 12.5456C53.1732 12.6006 52.222 12.2929 50.9682 11.4467L50.4789 11.117L50.017 11.606C49.2581 12.4083 48.7248 13.0017 48.7467 13.0237C49.797 13.8699 51.0562 14.4853 52.2605 14.7436C53.1348 14.9304 54.6139 14.9799 55.4662 14.8425C57.3633 14.5513 58.617 13.5787 59.0019 12.1225C59.1174 11.6994 59.1284 10.6994 59.0294 10.2873C58.793 9.3092 57.9682 8.51794 56.621 7.97945C56.3405 7.86955 55.4552 7.6058 54.6524 7.397C52.8048 6.91345 52.4584 6.74861 52.2824 6.25957C51.9635 5.36391 52.6619 4.7375 53.9651 4.74849C54.4655 4.75399 54.7679 4.81443 56.0161 5.18258C56.1041 5.21006 56.1096 5.12764 56.1096 3.94625C56.1096 2.78684 56.1041 2.67694 56.0161 2.64947C55.9611 2.63299 55.6367 2.57254 55.2903 2.5066C54.5314 2.37473 53.8001 2.33626 53.2447 2.39671Z",
|
|
8877
8770
|
fill: "white"
|
|
8878
8771
|
}
|
|
8879
8772
|
),
|
|
8880
|
-
/* @__PURE__ */ (0,
|
|
8773
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8881
8774
|
"path",
|
|
8882
8775
|
{
|
|
8883
8776
|
d: "M74.6953 7.57213C74.6953 11.2592 74.7173 11.7647 74.8933 12.3142C75.1297 13.056 75.872 13.8912 76.5924 14.2374C77.4667 14.655 78.198 14.8088 79.5507 14.8528L80.469 14.8857V13.8692V12.8582L79.8806 12.7867C78.8579 12.6713 78.1045 12.3252 77.8846 11.8746C77.6976 11.4844 77.6646 11.1108 77.6646 9.23157V7.3963H79.0668H80.469V6.4347V5.47311L79.0833 5.46212L77.6921 5.44563L77.6756 4.65987L77.6591 3.87961H76.18H74.6953V7.57213Z",
|
|
8884
8777
|
fill: "white"
|
|
8885
8778
|
}
|
|
8886
8779
|
),
|
|
8887
|
-
/* @__PURE__ */ (0,
|
|
8780
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8888
8781
|
"path",
|
|
8889
8782
|
{
|
|
8890
8783
|
d: "M68.4882 5.25987C67.9383 5.3258 66.9375 5.6445 66.5031 5.89726C65.5024 6.47972 64.9305 7.50725 65.046 8.52379C65.0899 8.95239 65.2274 9.2546 65.5134 9.56231C65.9203 10.0019 66.6406 10.3151 67.8503 10.5789C68.1528 10.6448 68.6256 10.7492 68.9006 10.8096C69.5164 10.9415 70.1268 11.2272 70.2918 11.4525C70.5392 11.7987 70.3907 12.3042 69.9728 12.5515C69.7309 12.6944 69.6869 12.6999 69.0051 12.6999C68.0098 12.6944 66.6351 12.3812 65.8323 11.98C65.6288 11.8756 65.4474 11.7932 65.4309 11.7932C65.4144 11.7932 65.4034 12.3097 65.4034 12.9416V14.0955L65.6948 14.1999C66.8056 14.6121 67.6744 14.8044 68.7081 14.8538C70.1103 14.9253 71.353 14.5901 72.2658 13.9087C72.9037 13.4307 73.2831 12.8702 73.4646 12.1449C73.5855 11.6613 73.514 11.0734 73.2666 10.5624C72.8762 9.73815 71.7544 9.13372 69.8519 8.7216C69.0875 8.55676 68.4882 8.34796 68.3067 8.18311C68.1528 8.04574 68.1747 7.71605 68.3507 7.50725C68.6201 7.18855 68.7576 7.15008 69.5989 7.15008H70.3523V6.21047V5.27085L70.0168 5.23239C69.5879 5.18843 69.0106 5.19942 68.4882 5.25987Z",
|
|
8891
8784
|
fill: "white"
|
|
8892
8785
|
}
|
|
8893
8786
|
),
|
|
8894
|
-
/* @__PURE__ */ (0,
|
|
8787
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8895
8788
|
"path",
|
|
8896
8789
|
{
|
|
8897
8790
|
d: "M97.0316 5.25947C96.8116 5.28695 96.3607 5.39684 96.0253 5.50674C94.8156 5.90786 93.9523 6.67714 93.5069 7.74863C93.166 8.57285 93.1605 8.6278 93.133 11.8038L93.1055 14.7051H94.6231H96.1408V12.0511C96.1408 10.4905 96.1628 9.25971 96.1958 9.0509C96.3002 8.44098 96.6467 7.90798 97.1086 7.6717C97.345 7.55082 97.4495 7.53433 97.9554 7.53433C98.4942 7.53433 98.5547 7.54532 98.8242 7.69368C99.2861 7.95194 99.5995 8.419 99.7095 9.01793C99.748 9.22124 99.77 10.3202 99.77 12.0236V14.7051H101.282H102.794V11.9412C102.794 10.2817 102.822 9.08937 102.855 8.94101C103.064 8.02337 103.685 7.50686 104.581 7.50686C105.571 7.50686 106.215 8.11129 106.363 9.17179C106.401 9.43005 106.423 10.6169 106.423 12.1555V14.7051H107.914H109.398L109.382 11.7489C109.36 8.92452 109.354 8.78166 109.239 8.36955C108.854 6.99034 107.897 5.9738 106.572 5.52872C105.786 5.27046 105.527 5.232 104.526 5.2375C103.702 5.2375 103.526 5.25947 103.047 5.38586C102.448 5.53971 101.942 5.7595 101.563 6.01776C101.425 6.11117 101.299 6.1881 101.271 6.1881C101.249 6.1881 101.057 6.07271 100.848 5.94083C99.9459 5.35289 98.4723 5.09463 97.0316 5.25947Z",
|
|
8898
8791
|
fill: "white"
|
|
8899
8792
|
}
|
|
8900
8793
|
),
|
|
8901
|
-
/* @__PURE__ */ (0,
|
|
8794
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8902
8795
|
"path",
|
|
8903
8796
|
{
|
|
8904
8797
|
d: "M86.1337 5.30344C84.3081 5.57818 82.9884 6.49581 82.2296 8.02338C81.8887 8.71572 81.7732 9.35862 81.8062 10.3367C81.8447 11.2488 81.9327 11.65 82.2351 12.2489C82.785 13.3369 83.3898 13.9138 84.5171 14.4194C85.1274 14.6941 85.6938 14.815 86.4966 14.8534C87.085 14.8809 88.1462 14.8095 88.5532 14.7106C88.6576 14.6831 88.8116 14.6446 88.8996 14.6282L89.048 14.5952V13.5786C89.048 13.0182 89.0425 12.5621 89.037 12.5621C89.026 12.5621 88.8336 12.617 88.6081 12.6775C88.0253 12.8368 86.898 12.8808 86.3866 12.7599C85.6333 12.5841 85.0449 12.117 84.726 11.4412C84.616 11.2159 84.5446 11.0016 84.5666 10.9686C84.5885 10.9301 85.7433 10.9137 88.1682 10.9137H91.7369L91.7754 10.6609C91.8304 10.2872 91.7534 9.46851 91.605 8.80914C91.286 7.38598 90.3567 6.22657 89.1195 5.69357C88.3552 5.36938 86.9475 5.18255 86.1337 5.30344ZM87.5909 7.52884C87.7448 7.56731 87.9648 7.64973 88.0858 7.71567C88.5257 7.93546 89.0041 8.60033 89.081 9.09487L89.1195 9.32016H86.8265C84.9845 9.32016 84.5391 9.30367 84.5391 9.24872C84.5391 9.06739 84.99 8.26515 85.2099 8.05634C85.4738 7.80358 85.8588 7.58379 86.1722 7.51236C86.4911 7.43543 87.2829 7.44642 87.5909 7.52884Z",
|
|
8905
8798
|
fill: "white"
|
|
8906
8799
|
}
|
|
8907
8800
|
),
|
|
8908
|
-
/* @__PURE__ */ (0,
|
|
8801
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8909
8802
|
"path",
|
|
8910
8803
|
{
|
|
8911
8804
|
d: "M114.892 5.30939C114.634 5.33686 114.315 5.38082 114.178 5.4028L113.93 5.45225L113.914 6.58419L113.903 7.71612L114.134 7.65568C114.266 7.62821 114.815 7.60073 115.36 7.59524C116.179 7.58974 116.405 7.60623 116.652 7.68865C117.125 7.8425 117.46 8.12274 117.631 8.4854C117.779 8.80959 117.862 9.37556 117.768 9.37556C117.735 9.37556 117.515 9.32611 117.279 9.27116C116.223 9.00741 114.639 8.98543 113.573 9.20522C111.956 9.5459 110.988 10.6009 110.988 12.0296C110.988 13.2879 111.879 14.3319 113.27 14.711C113.864 14.8759 115.316 14.8924 115.91 14.744C116.41 14.6176 117.152 14.244 117.477 13.9473C117.625 13.8209 117.757 13.7165 117.774 13.7165C117.79 13.7165 117.807 13.9363 117.807 14.211V14.7055H119.242H120.672L120.65 11.5295C120.628 7.97438 120.628 7.99636 120.226 7.24357C119.517 5.9303 118.318 5.34236 116.212 5.28741C115.745 5.27093 115.151 5.28191 114.892 5.30939ZM117.235 10.7712C117.851 10.9251 117.862 10.9306 117.862 11.3537C117.862 12.2329 117.251 12.7933 116.069 12.9912C115.64 13.0681 115.497 13.0681 115.156 13.0131C114.628 12.9252 114.211 12.7164 114.04 12.4637C113.864 12.1999 113.848 11.6394 114.007 11.3757C114.205 11.0515 114.656 10.7822 115.167 10.6888C115.525 10.6229 116.844 10.6778 117.235 10.7712Z",
|
|
8912
8805
|
fill: "white"
|
|
8913
8806
|
}
|
|
8914
8807
|
),
|
|
8915
|
-
/* @__PURE__ */ (0,
|
|
8808
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8916
8809
|
"path",
|
|
8917
8810
|
{
|
|
8918
8811
|
d: "M60.457 10.1169V14.7051H61.9417H63.4264V10.1169V5.52872H61.9417H60.457V10.1169Z",
|
|
8919
8812
|
fill: "white"
|
|
8920
8813
|
}
|
|
8921
8814
|
),
|
|
8922
|
-
/* @__PURE__ */ (0,
|
|
8815
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8923
8816
|
"path",
|
|
8924
8817
|
{
|
|
8925
8818
|
d: "M173.197 1.72126C172.114 3.40817 171.586 4.24338 171.586 4.28185C171.586 4.30383 172.02 4.32031 172.554 4.32031H173.527L173.752 4.117C174.324 3.61148 175.71 2.27074 175.71 2.22678C175.71 2.19931 175.655 2.14986 175.589 2.12238C175.518 2.09491 175.034 1.8861 174.511 1.65532C173.994 1.43003 173.554 1.24321 173.538 1.24321C173.521 1.24321 173.368 1.45751 173.197 1.72126Z",
|
|
8926
8819
|
fill: "white"
|
|
8927
8820
|
}
|
|
8928
8821
|
),
|
|
8929
|
-
/* @__PURE__ */ (0,
|
|
8822
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8930
8823
|
"path",
|
|
8931
8824
|
{
|
|
8932
8825
|
d: "M194.074 2.97369V3.99023H195.559H197.044L197.033 2.98468L197.016 1.98462L195.548 1.96814L194.074 1.95715V2.97369Z",
|
|
8933
8826
|
fill: "white"
|
|
8934
8827
|
}
|
|
8935
8828
|
),
|
|
8936
|
-
/* @__PURE__ */ (0,
|
|
8829
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8937
8830
|
"path",
|
|
8938
8831
|
{
|
|
8939
8832
|
d: "M135.845 2.43604C133.887 2.63386 132.37 3.21082 131.144 4.22736C130.346 4.88674 129.653 5.94724 129.4 6.89784C129.241 7.51326 129.197 8.99687 129.323 9.76614C129.664 11.8322 131.138 13.4861 133.398 14.3488C134.173 14.6455 135.872 14.9258 136.873 14.9258H137.275V13.7554V12.5905L136.543 12.585C135.702 12.574 135.257 12.4751 134.525 12.1344C132.997 11.4201 132.144 9.99692 132.238 8.30452C132.287 7.30446 132.59 6.63409 133.283 5.94174C134.091 5.14499 135.059 4.77684 136.494 4.72189L137.275 4.68892V3.546V2.39758L136.659 2.40857C136.318 2.40857 135.949 2.42506 135.845 2.43604Z",
|
|
8940
8833
|
fill: "white"
|
|
8941
8834
|
}
|
|
8942
8835
|
),
|
|
8943
|
-
/* @__PURE__ */ (0,
|
|
8836
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8944
8837
|
"path",
|
|
8945
8838
|
{
|
|
8946
8839
|
d: "M142.609 5.13944C140.503 5.44715 138.831 6.8813 138.342 8.80449C137.797 10.964 138.847 13.1839 140.915 14.2224C141.652 14.5905 142.141 14.7114 143.104 14.7444C143.774 14.7664 143.983 14.7554 144.407 14.6565C145.424 14.4312 146.227 13.9971 146.953 13.2773C148.173 12.0519 148.635 10.4255 148.223 8.79899C148.08 8.24951 147.689 7.46375 147.349 7.04065C146.441 5.91421 144.973 5.1834 143.488 5.12296C143.17 5.10647 142.774 5.11746 142.609 5.13944ZM144.297 7.44727C144.682 7.61761 145.089 8.0517 145.237 8.45282C145.578 9.36496 145.545 10.8156 145.166 11.6014C144.83 12.2992 144.253 12.6179 143.312 12.6179C142.565 12.6179 142.174 12.497 141.778 12.1398C141.311 11.7167 141.107 11.0464 141.107 9.95291C141.107 8.48579 141.514 7.68904 142.411 7.39781C142.889 7.23846 143.884 7.26594 144.297 7.44727Z",
|
|
8947
8840
|
fill: "white"
|
|
8948
8841
|
}
|
|
8949
8842
|
),
|
|
8950
|
-
/* @__PURE__ */ (0,
|
|
8843
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8951
8844
|
"path",
|
|
8952
8845
|
{
|
|
8953
8846
|
d: "M154.046 5.12263C153.667 5.16659 152.831 5.37539 152.501 5.50177C152.044 5.6831 151.302 6.18862 150.994 6.5293C150.675 6.88097 150.345 7.43595 150.197 7.85905C149.944 8.60635 149.922 8.89208 149.922 11.8263V14.5957H151.434H152.941L152.957 11.6944L152.974 8.79866L153.106 8.46897C153.386 7.78212 153.963 7.39748 154.733 7.39748C155.267 7.39748 155.597 7.52387 155.932 7.85355C156.52 8.42502 156.575 8.79317 156.575 12.1011V14.5957H158.088H159.594L159.611 11.667C159.633 8.35358 159.616 8.45799 160.078 7.94697C160.474 7.50738 160.672 7.42496 161.359 7.42496C161.849 7.42496 161.97 7.44694 162.157 7.54584C162.448 7.70519 162.767 8.0184 162.893 8.26567C163.168 8.80416 163.174 8.88658 163.174 11.8318V14.5957H164.692H166.204L166.187 11.6944L166.165 8.79866L165.995 8.2327C165.725 7.35902 165.439 6.86449 164.922 6.36995C164.345 5.83146 163.79 5.52924 162.943 5.30945C161.348 4.89184 159.512 5.13362 158.357 5.91388C158.219 6.0018 158.088 6.07873 158.06 6.07873C158.038 6.07873 157.835 5.96883 157.615 5.83146C157.23 5.59518 156.729 5.40286 156.042 5.22703C155.712 5.14461 154.425 5.07867 154.046 5.12263Z",
|
|
8954
8847
|
fill: "white"
|
|
8955
8848
|
}
|
|
8956
8849
|
),
|
|
8957
|
-
/* @__PURE__ */ (0,
|
|
8850
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8958
8851
|
"path",
|
|
8959
8852
|
{
|
|
8960
8853
|
d: "M182.994 5.1446C181.399 5.38638 180.184 6.17763 179.579 7.36451C179.177 8.14478 179.172 8.20522 179.172 11.5845V14.5957H180.684H182.196V11.6395C182.202 8.969 182.207 8.66129 182.295 8.40853C182.526 7.74915 183.12 7.3755 184.192 7.23264C184.44 7.19967 184.726 7.15571 184.825 7.14472L185.001 7.11725L184.99 6.11719L184.973 5.11713L184.121 5.11164C183.653 5.10614 183.147 5.12263 182.994 5.1446Z",
|
|
8961
8854
|
fill: "white"
|
|
8962
8855
|
}
|
|
8963
8856
|
),
|
|
8964
|
-
/* @__PURE__ */ (0,
|
|
8857
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8965
8858
|
"path",
|
|
8966
8859
|
{
|
|
8967
8860
|
d: "M190.311 5.1395C189.706 5.2384 188.705 5.54062 188.21 5.7769C187.248 6.23297 186.61 6.81542 186.126 7.6836C185.73 8.38694 185.609 8.93642 185.609 9.98044C185.615 11.3267 185.928 12.1729 186.737 13.0465C187.479 13.8433 188.425 14.3323 189.788 14.6236C190.514 14.7829 191.62 14.8379 192.169 14.7445L192.428 14.7005V13.7004V12.7004L191.993 12.7169C190.844 12.7718 189.832 12.3927 189.107 11.6289C188.617 11.1179 188.425 10.5299 188.485 9.71669C188.54 8.88147 188.881 8.33748 189.678 7.7935C190.305 7.3649 191.136 7.12313 191.988 7.12313H192.428V6.16703C192.428 5.4582 192.411 5.19444 192.362 5.16148C192.263 5.10653 190.646 5.09004 190.311 5.1395Z",
|
|
8968
8861
|
fill: "white"
|
|
8969
8862
|
}
|
|
8970
8863
|
),
|
|
8971
|
-
/* @__PURE__ */ (0,
|
|
8864
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8972
8865
|
"path",
|
|
8973
8866
|
{
|
|
8974
8867
|
d: "M203.01 5.14533C201.784 5.32666 200.524 5.99703 199.776 6.86521C198.93 7.85428 198.473 9.26095 198.627 10.4259C198.842 12.0908 199.82 13.459 201.344 14.2228C202.168 14.6349 202.614 14.7338 203.725 14.7283C204.808 14.7283 205.22 14.6404 205.996 14.2667C208.487 13.0414 209.487 10.25 208.289 7.85977C207.491 6.27177 205.781 5.20028 203.917 5.12335C203.598 5.10686 203.191 5.11785 203.01 5.14533ZM204.72 7.44766C204.874 7.5136 205.116 7.68394 205.253 7.8268C205.666 8.24441 205.831 8.74993 205.88 9.73351C205.93 10.8105 205.71 11.6512 205.259 12.0908C204.901 12.437 204.533 12.5743 203.901 12.6073C202.592 12.6677 201.932 12.2282 201.624 11.0633C201.492 10.5742 201.498 9.24996 201.63 8.79939C201.861 8.03561 202.24 7.59602 202.839 7.39821C203.312 7.24435 204.313 7.26633 204.72 7.44766Z",
|
|
8975
8868
|
fill: "white"
|
|
8976
8869
|
}
|
|
8977
8870
|
),
|
|
8978
|
-
/* @__PURE__ */ (0,
|
|
8871
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8979
8872
|
"path",
|
|
8980
8873
|
{
|
|
8981
8874
|
d: "M171.532 5.33081C170.025 5.68797 168.931 6.54517 168.26 7.8914C167.93 8.55627 167.793 9.1662 167.793 10.0344C167.793 11.9081 168.651 13.3752 170.212 14.1775C170.768 14.4632 171.059 14.5621 171.725 14.683C172.533 14.8314 174.199 14.7434 174.958 14.5072C175.04 14.4797 175.051 14.3808 175.051 13.4741V12.4686L174.49 12.6005C173.809 12.7543 172.83 12.7708 172.34 12.6444C171.637 12.4631 171.103 12.0565 170.806 11.4795C170.696 11.2762 170.592 11.0509 170.57 10.9795L170.537 10.8586H174.133H177.735L177.768 10.6883C177.916 9.95196 177.619 8.36395 177.179 7.52324C176.684 6.56165 175.711 5.74292 174.721 5.4462C173.77 5.16597 172.434 5.11651 171.532 5.33081ZM173.523 7.40236C173.93 7.49028 174.199 7.63864 174.512 7.95184C174.804 8.24307 175.046 8.69914 175.09 9.05081L175.123 9.2651L172.846 9.25411L170.57 9.23763L170.586 9.10026C170.592 9.02333 170.685 8.78705 170.79 8.56726C170.988 8.16614 171.373 7.75952 171.719 7.57819C172.148 7.35291 172.934 7.27598 173.523 7.40236Z",
|
|
8982
8875
|
fill: "white"
|
|
8983
8876
|
}
|
|
8984
8877
|
),
|
|
8985
|
-
/* @__PURE__ */ (0,
|
|
8878
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
8986
8879
|
"path",
|
|
8987
8880
|
{
|
|
8988
8881
|
d: "M194.074 10.0075V14.5957H195.559H197.044V10.0075V5.41934H195.559H194.074V10.0075Z",
|
|
@@ -8995,12 +8888,12 @@ function LogotipoDefault() {
|
|
|
8995
8888
|
}
|
|
8996
8889
|
|
|
8997
8890
|
// src/components/Sidebar/index.tsx
|
|
8998
|
-
var
|
|
8891
|
+
var import_jsx_runtime21 = require("react/jsx-runtime");
|
|
8999
8892
|
function SidebarContainer({
|
|
9000
8893
|
isOpen = true,
|
|
9001
8894
|
...rest
|
|
9002
8895
|
}) {
|
|
9003
|
-
return /* @__PURE__ */ (0,
|
|
8896
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9004
8897
|
"div",
|
|
9005
8898
|
{
|
|
9006
8899
|
"data-is-open": isOpen,
|
|
@@ -9016,21 +8909,21 @@ function SidebarImageBrand({
|
|
|
9016
8909
|
img,
|
|
9017
8910
|
children
|
|
9018
8911
|
}) {
|
|
9019
|
-
return /* @__PURE__ */ (0,
|
|
9020
|
-
/* @__PURE__ */ (0,
|
|
8912
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "cnc-flex cnc-items-center cnc-justify-between cnc-bg-primary-900 cnc-w-full cnc-h-full cnc-max-h-[70px] cnc-py-5 cnc-px-6 cnc-transition-all cnc-duration-300 cnc-ease-in-out cnc-sidebar-child-w-0", children: [
|
|
8913
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "cnc-sidebar-child-hidden", children: asChild && !img ? children : img && img.src ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9021
8914
|
"img",
|
|
9022
8915
|
{
|
|
9023
8916
|
src: img.src,
|
|
9024
8917
|
alt: img?.alt,
|
|
9025
8918
|
className: "cnc-w-[159px] cnc-h-[28px] cnc-object-contain"
|
|
9026
8919
|
}
|
|
9027
|
-
) : /* @__PURE__ */ (0,
|
|
9028
|
-
onChangeToggle && /* @__PURE__ */ (0,
|
|
8920
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(LogotipoDefault, {}) }),
|
|
8921
|
+
onChangeToggle && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9029
8922
|
"button",
|
|
9030
8923
|
{
|
|
9031
8924
|
onClick: onChangeToggle,
|
|
9032
8925
|
className: "hover:cnc-brightness-75 cnc-sidebar-child-hidden",
|
|
9033
|
-
children: /* @__PURE__ */ (0,
|
|
8926
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9034
8927
|
"svg",
|
|
9035
8928
|
{
|
|
9036
8929
|
stroke: "currentColor",
|
|
@@ -9041,7 +8934,7 @@ function SidebarImageBrand({
|
|
|
9041
8934
|
height: "1em",
|
|
9042
8935
|
width: "1em",
|
|
9043
8936
|
xmlns: "http://www.w3.org/2000/svg",
|
|
9044
|
-
children: /* @__PURE__ */ (0,
|
|
8937
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9045
8938
|
"path",
|
|
9046
8939
|
{
|
|
9047
8940
|
fill: "none",
|
|
@@ -9058,7 +8951,7 @@ function SidebarImageBrand({
|
|
|
9058
8951
|
] });
|
|
9059
8952
|
}
|
|
9060
8953
|
function Sidebar({ children, ...rest }) {
|
|
9061
|
-
return /* @__PURE__ */ (0,
|
|
8954
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(Accordion.Root, { ...rest, children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9062
8955
|
"div",
|
|
9063
8956
|
{
|
|
9064
8957
|
className: "cnc-w-full cnc-h-screen-minus-70 cnc-flex cnc-flex-col cnc-py-8 cnc-bg-primary-800 cnc-px-5 \r\n cnc-scroll-smooth cnc-overflow-y-auto\r\n [&::-webkit-scrollbar]:cnc-w-1\r\n [&::-webkit-scrollbar-track]:cnc-bg-brand-blue-500\r\n [&::-webkit-scrollbar-thumb]:cnc-rounded\r\n [&::-webkit-scrollbar-thumb]:cnc-border\r\n [&::-webkit-scrollbar-thumb]:cnc-border-solid\r\n [&::-webkit-scrollbar-thumb]:cnc-border-brand-gray-400\r\n [&::-webkit-scrollbar-thumb]:cnc-bg-brand-gray-200\r\n cnc-sidebar-child-w-0",
|
|
@@ -9072,7 +8965,7 @@ function SidebarNavLink({
|
|
|
9072
8965
|
...rest
|
|
9073
8966
|
}) {
|
|
9074
8967
|
const Component = asChild ? import_react_slot6.Slot : "a";
|
|
9075
|
-
return /* @__PURE__ */ (0,
|
|
8968
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9076
8969
|
Component,
|
|
9077
8970
|
{
|
|
9078
8971
|
"data-type": type,
|
|
@@ -9087,13 +8980,13 @@ function SidebarNavCollapse({
|
|
|
9087
8980
|
icon,
|
|
9088
8981
|
...rest
|
|
9089
8982
|
}) {
|
|
9090
|
-
return /* @__PURE__ */ (0,
|
|
9091
|
-
/* @__PURE__ */ (0,
|
|
9092
|
-
/* @__PURE__ */ (0,
|
|
8983
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(Accordion.Item, { ...rest, className: "cnc-sidebar-item", children: [
|
|
8984
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(Accordion.Trigger, { className: "group cnc-w-full cnc-py-4 cnc-text-base cnc-text-white cnc-flex cnc-gap-2 cnc-items-center cnc-justify-between hover:cnc-text-blue-600 cnc-sidebar-child-hidden", children: [
|
|
8985
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "cnc-flex cnc-items-center cnc-gap-2", children: [
|
|
9093
8986
|
icon && renderIconItem(icon),
|
|
9094
8987
|
title
|
|
9095
8988
|
] }),
|
|
9096
|
-
/* @__PURE__ */ (0,
|
|
8989
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "cnc-w-4 cnc-h-4", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
9097
8990
|
"svg",
|
|
9098
8991
|
{
|
|
9099
8992
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -9106,11 +8999,11 @@ function SidebarNavCollapse({
|
|
|
9106
8999
|
strokeLinecap: "round",
|
|
9107
9000
|
strokeLinejoin: "round",
|
|
9108
9001
|
className: "cnc-w-full cnc-h-full cnc-text-violet10 cnc-transition-transform cnc-duration-300 cnc-ease-[cubic-bezier(0.87,_0,_0.13,_1)] group-data-[state=open]:cnc-rotate-90",
|
|
9109
|
-
children: /* @__PURE__ */ (0,
|
|
9002
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("path", { d: "m9 18 6-6-6-6" })
|
|
9110
9003
|
}
|
|
9111
9004
|
) })
|
|
9112
9005
|
] }),
|
|
9113
|
-
/* @__PURE__ */ (0,
|
|
9006
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.jsx)(Accordion.Content, { className: "cnc-overflow-hidden data-[state=closed]:cnc-animate-slideUp data-[state=open]:cnc-animate-slideDown cnc-py-2", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "cnc-bg-white/10 cnc-rounded-md cnc-font-normal cnc-px-5 cnc-py-3", children }) })
|
|
9114
9007
|
] });
|
|
9115
9008
|
}
|
|
9116
9009
|
function renderIconItem(icon) {
|
|
@@ -9123,15 +9016,15 @@ function renderIconItem(icon) {
|
|
|
9123
9016
|
});
|
|
9124
9017
|
}
|
|
9125
9018
|
if ((0, import_react7.isValidElement)(icon)) {
|
|
9126
|
-
return /* @__PURE__ */ (0,
|
|
9019
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "cnc-w-5 cnc-h-5 cnc-overflow-hidden", children: icon });
|
|
9127
9020
|
}
|
|
9128
|
-
return /* @__PURE__ */ (0,
|
|
9021
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "cnc-w-5 cnc-h-5 cnc-overflow-hidden", children: icon });
|
|
9129
9022
|
}
|
|
9130
9023
|
|
|
9131
9024
|
// ../../node_modules/@radix-ui/react-popover/dist/index.mjs
|
|
9132
|
-
var
|
|
9025
|
+
var React36 = __toESM(require("react"), 1);
|
|
9133
9026
|
var import_react_slot7 = require("@radix-ui/react-slot");
|
|
9134
|
-
var
|
|
9027
|
+
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
9135
9028
|
var POPOVER_NAME = "Popover";
|
|
9136
9029
|
var [createPopoverContext, createPopoverScope] = createContextScope(POPOVER_NAME, [
|
|
9137
9030
|
createPopperScope
|
|
@@ -9148,14 +9041,14 @@ var Popover = (props) => {
|
|
|
9148
9041
|
modal = false
|
|
9149
9042
|
} = props;
|
|
9150
9043
|
const popperScope = usePopperScope2(__scopePopover);
|
|
9151
|
-
const triggerRef =
|
|
9152
|
-
const [hasCustomAnchor, setHasCustomAnchor] =
|
|
9044
|
+
const triggerRef = React36.useRef(null);
|
|
9045
|
+
const [hasCustomAnchor, setHasCustomAnchor] = React36.useState(false);
|
|
9153
9046
|
const [open = false, setOpen] = useControllableState({
|
|
9154
9047
|
prop: openProp,
|
|
9155
9048
|
defaultProp: defaultOpen,
|
|
9156
9049
|
onChange: onOpenChange
|
|
9157
9050
|
});
|
|
9158
|
-
return /* @__PURE__ */ (0,
|
|
9051
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Root2, { ...popperScope, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9159
9052
|
PopoverProvider,
|
|
9160
9053
|
{
|
|
9161
9054
|
scope: __scopePopover,
|
|
@@ -9163,10 +9056,10 @@ var Popover = (props) => {
|
|
|
9163
9056
|
triggerRef,
|
|
9164
9057
|
open,
|
|
9165
9058
|
onOpenChange: setOpen,
|
|
9166
|
-
onOpenToggle:
|
|
9059
|
+
onOpenToggle: React36.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),
|
|
9167
9060
|
hasCustomAnchor,
|
|
9168
|
-
onCustomAnchorAdd:
|
|
9169
|
-
onCustomAnchorRemove:
|
|
9061
|
+
onCustomAnchorAdd: React36.useCallback(() => setHasCustomAnchor(true), []),
|
|
9062
|
+
onCustomAnchorRemove: React36.useCallback(() => setHasCustomAnchor(false), []),
|
|
9170
9063
|
modal,
|
|
9171
9064
|
children
|
|
9172
9065
|
}
|
|
@@ -9174,28 +9067,28 @@ var Popover = (props) => {
|
|
|
9174
9067
|
};
|
|
9175
9068
|
Popover.displayName = POPOVER_NAME;
|
|
9176
9069
|
var ANCHOR_NAME3 = "PopoverAnchor";
|
|
9177
|
-
var PopoverAnchor =
|
|
9070
|
+
var PopoverAnchor = React36.forwardRef(
|
|
9178
9071
|
(props, forwardedRef) => {
|
|
9179
9072
|
const { __scopePopover, ...anchorProps } = props;
|
|
9180
9073
|
const context = usePopoverContext(ANCHOR_NAME3, __scopePopover);
|
|
9181
9074
|
const popperScope = usePopperScope2(__scopePopover);
|
|
9182
9075
|
const { onCustomAnchorAdd, onCustomAnchorRemove } = context;
|
|
9183
|
-
|
|
9076
|
+
React36.useEffect(() => {
|
|
9184
9077
|
onCustomAnchorAdd();
|
|
9185
9078
|
return () => onCustomAnchorRemove();
|
|
9186
9079
|
}, [onCustomAnchorAdd, onCustomAnchorRemove]);
|
|
9187
|
-
return /* @__PURE__ */ (0,
|
|
9080
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Anchor, { ...popperScope, ...anchorProps, ref: forwardedRef });
|
|
9188
9081
|
}
|
|
9189
9082
|
);
|
|
9190
9083
|
PopoverAnchor.displayName = ANCHOR_NAME3;
|
|
9191
9084
|
var TRIGGER_NAME3 = "PopoverTrigger";
|
|
9192
|
-
var PopoverTrigger =
|
|
9085
|
+
var PopoverTrigger = React36.forwardRef(
|
|
9193
9086
|
(props, forwardedRef) => {
|
|
9194
9087
|
const { __scopePopover, ...triggerProps } = props;
|
|
9195
9088
|
const context = usePopoverContext(TRIGGER_NAME3, __scopePopover);
|
|
9196
9089
|
const popperScope = usePopperScope2(__scopePopover);
|
|
9197
9090
|
const composedTriggerRef = useComposedRefs(forwardedRef, context.triggerRef);
|
|
9198
|
-
const trigger = /* @__PURE__ */ (0,
|
|
9091
|
+
const trigger = /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9199
9092
|
Primitive.button,
|
|
9200
9093
|
{
|
|
9201
9094
|
type: "button",
|
|
@@ -9208,7 +9101,7 @@ var PopoverTrigger = React39.forwardRef(
|
|
|
9208
9101
|
onClick: composeEventHandlers(props.onClick, context.onOpenToggle)
|
|
9209
9102
|
}
|
|
9210
9103
|
);
|
|
9211
|
-
return context.hasCustomAnchor ? trigger : /* @__PURE__ */ (0,
|
|
9104
|
+
return context.hasCustomAnchor ? trigger : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Anchor, { asChild: true, ...popperScope, children: trigger });
|
|
9212
9105
|
}
|
|
9213
9106
|
);
|
|
9214
9107
|
PopoverTrigger.displayName = TRIGGER_NAME3;
|
|
@@ -9219,30 +9112,30 @@ var [PortalProvider3, usePortalContext3] = createPopoverContext(PORTAL_NAME5, {
|
|
|
9219
9112
|
var PopoverPortal = (props) => {
|
|
9220
9113
|
const { __scopePopover, forceMount, children, container } = props;
|
|
9221
9114
|
const context = usePopoverContext(PORTAL_NAME5, __scopePopover);
|
|
9222
|
-
return /* @__PURE__ */ (0,
|
|
9115
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(PortalProvider3, { scope: __scopePopover, forceMount, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Portal, { asChild: true, container, children }) }) });
|
|
9223
9116
|
};
|
|
9224
9117
|
PopoverPortal.displayName = PORTAL_NAME5;
|
|
9225
9118
|
var CONTENT_NAME5 = "PopoverContent";
|
|
9226
|
-
var PopoverContent =
|
|
9119
|
+
var PopoverContent = React36.forwardRef(
|
|
9227
9120
|
(props, forwardedRef) => {
|
|
9228
9121
|
const portalContext = usePortalContext3(CONTENT_NAME5, props.__scopePopover);
|
|
9229
9122
|
const { forceMount = portalContext.forceMount, ...contentProps } = props;
|
|
9230
9123
|
const context = usePopoverContext(CONTENT_NAME5, props.__scopePopover);
|
|
9231
|
-
return /* @__PURE__ */ (0,
|
|
9124
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Presence, { present: forceMount || context.open, children: context.modal ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(PopoverContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(PopoverContentNonModal, { ...contentProps, ref: forwardedRef }) });
|
|
9232
9125
|
}
|
|
9233
9126
|
);
|
|
9234
9127
|
PopoverContent.displayName = CONTENT_NAME5;
|
|
9235
|
-
var PopoverContentModal =
|
|
9128
|
+
var PopoverContentModal = React36.forwardRef(
|
|
9236
9129
|
(props, forwardedRef) => {
|
|
9237
9130
|
const context = usePopoverContext(CONTENT_NAME5, props.__scopePopover);
|
|
9238
|
-
const contentRef =
|
|
9131
|
+
const contentRef = React36.useRef(null);
|
|
9239
9132
|
const composedRefs = useComposedRefs(forwardedRef, contentRef);
|
|
9240
|
-
const isRightClickOutsideRef =
|
|
9241
|
-
|
|
9133
|
+
const isRightClickOutsideRef = React36.useRef(false);
|
|
9134
|
+
React36.useEffect(() => {
|
|
9242
9135
|
const content = contentRef.current;
|
|
9243
9136
|
if (content) return hideOthers(content);
|
|
9244
9137
|
}, []);
|
|
9245
|
-
return /* @__PURE__ */ (0,
|
|
9138
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Combination_default, { as: import_react_slot7.Slot, allowPinchZoom: true, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9246
9139
|
PopoverContentImpl,
|
|
9247
9140
|
{
|
|
9248
9141
|
...props,
|
|
@@ -9272,12 +9165,12 @@ var PopoverContentModal = React39.forwardRef(
|
|
|
9272
9165
|
) });
|
|
9273
9166
|
}
|
|
9274
9167
|
);
|
|
9275
|
-
var PopoverContentNonModal =
|
|
9168
|
+
var PopoverContentNonModal = React36.forwardRef(
|
|
9276
9169
|
(props, forwardedRef) => {
|
|
9277
9170
|
const context = usePopoverContext(CONTENT_NAME5, props.__scopePopover);
|
|
9278
|
-
const hasInteractedOutsideRef =
|
|
9279
|
-
const hasPointerDownOutsideRef =
|
|
9280
|
-
return /* @__PURE__ */ (0,
|
|
9171
|
+
const hasInteractedOutsideRef = React36.useRef(false);
|
|
9172
|
+
const hasPointerDownOutsideRef = React36.useRef(false);
|
|
9173
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9281
9174
|
PopoverContentImpl,
|
|
9282
9175
|
{
|
|
9283
9176
|
...props,
|
|
@@ -9312,7 +9205,7 @@ var PopoverContentNonModal = React39.forwardRef(
|
|
|
9312
9205
|
);
|
|
9313
9206
|
}
|
|
9314
9207
|
);
|
|
9315
|
-
var PopoverContentImpl =
|
|
9208
|
+
var PopoverContentImpl = React36.forwardRef(
|
|
9316
9209
|
(props, forwardedRef) => {
|
|
9317
9210
|
const {
|
|
9318
9211
|
__scopePopover,
|
|
@@ -9329,7 +9222,7 @@ var PopoverContentImpl = React39.forwardRef(
|
|
|
9329
9222
|
const context = usePopoverContext(CONTENT_NAME5, __scopePopover);
|
|
9330
9223
|
const popperScope = usePopperScope2(__scopePopover);
|
|
9331
9224
|
useFocusGuards();
|
|
9332
|
-
return /* @__PURE__ */ (0,
|
|
9225
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9333
9226
|
FocusScope,
|
|
9334
9227
|
{
|
|
9335
9228
|
asChild: true,
|
|
@@ -9337,7 +9230,7 @@ var PopoverContentImpl = React39.forwardRef(
|
|
|
9337
9230
|
trapped: trapFocus,
|
|
9338
9231
|
onMountAutoFocus: onOpenAutoFocus,
|
|
9339
9232
|
onUnmountAutoFocus: onCloseAutoFocus,
|
|
9340
|
-
children: /* @__PURE__ */ (0,
|
|
9233
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9341
9234
|
DismissableLayer,
|
|
9342
9235
|
{
|
|
9343
9236
|
asChild: true,
|
|
@@ -9347,7 +9240,7 @@ var PopoverContentImpl = React39.forwardRef(
|
|
|
9347
9240
|
onPointerDownOutside,
|
|
9348
9241
|
onFocusOutside,
|
|
9349
9242
|
onDismiss: () => context.onOpenChange(false),
|
|
9350
|
-
children: /* @__PURE__ */ (0,
|
|
9243
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9351
9244
|
Content,
|
|
9352
9245
|
{
|
|
9353
9246
|
"data-state": getState2(context.open),
|
|
@@ -9376,11 +9269,11 @@ var PopoverContentImpl = React39.forwardRef(
|
|
|
9376
9269
|
}
|
|
9377
9270
|
);
|
|
9378
9271
|
var CLOSE_NAME2 = "PopoverClose";
|
|
9379
|
-
var PopoverClose =
|
|
9272
|
+
var PopoverClose = React36.forwardRef(
|
|
9380
9273
|
(props, forwardedRef) => {
|
|
9381
9274
|
const { __scopePopover, ...closeProps } = props;
|
|
9382
9275
|
const context = usePopoverContext(CLOSE_NAME2, __scopePopover);
|
|
9383
|
-
return /* @__PURE__ */ (0,
|
|
9276
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
9384
9277
|
Primitive.button,
|
|
9385
9278
|
{
|
|
9386
9279
|
type: "button",
|
|
@@ -9393,11 +9286,11 @@ var PopoverClose = React39.forwardRef(
|
|
|
9393
9286
|
);
|
|
9394
9287
|
PopoverClose.displayName = CLOSE_NAME2;
|
|
9395
9288
|
var ARROW_NAME4 = "PopoverArrow";
|
|
9396
|
-
var PopoverArrow =
|
|
9289
|
+
var PopoverArrow = React36.forwardRef(
|
|
9397
9290
|
(props, forwardedRef) => {
|
|
9398
9291
|
const { __scopePopover, ...arrowProps } = props;
|
|
9399
9292
|
const popperScope = usePopperScope2(__scopePopover);
|
|
9400
|
-
return /* @__PURE__ */ (0,
|
|
9293
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Arrow2, { ...popperScope, ...arrowProps, ref: forwardedRef });
|
|
9401
9294
|
}
|
|
9402
9295
|
);
|
|
9403
9296
|
PopoverArrow.displayName = ARROW_NAME4;
|
|
@@ -9410,11 +9303,11 @@ var Portal4 = PopoverPortal;
|
|
|
9410
9303
|
var Content23 = PopoverContent;
|
|
9411
9304
|
|
|
9412
9305
|
// src/components/Popover/index.tsx
|
|
9413
|
-
var
|
|
9414
|
-
var
|
|
9306
|
+
var React37 = __toESM(require("react"));
|
|
9307
|
+
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
9415
9308
|
var Popover2 = Root23;
|
|
9416
9309
|
var PopoverTrigger2 = Trigger4;
|
|
9417
|
-
var PopoverContent2 =
|
|
9310
|
+
var PopoverContent2 = React37.forwardRef(({ className, align = "center", sideOffset = 4, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Portal4, { children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
9418
9311
|
Content23,
|
|
9419
9312
|
{
|
|
9420
9313
|
ref,
|
|
@@ -9428,6 +9321,118 @@ var PopoverContent2 = React40.forwardRef(({ className, align = "center", sideOff
|
|
|
9428
9321
|
}
|
|
9429
9322
|
) }));
|
|
9430
9323
|
PopoverContent2.displayName = Content23.displayName;
|
|
9324
|
+
|
|
9325
|
+
// src/components/Select/index.tsx
|
|
9326
|
+
var React38 = __toESM(require("react"));
|
|
9327
|
+
var SelectPrimitive = __toESM(require("@radix-ui/react-select"));
|
|
9328
|
+
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
9329
|
+
var Select = SelectPrimitive.Root;
|
|
9330
|
+
var SelectGroup = SelectPrimitive.Group;
|
|
9331
|
+
var SelectValue = SelectPrimitive.Value;
|
|
9332
|
+
var SelectTrigger = React38.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
|
|
9333
|
+
SelectPrimitive.Trigger,
|
|
9334
|
+
{
|
|
9335
|
+
ref,
|
|
9336
|
+
className: cn(
|
|
9337
|
+
"cnc-flex cnc-h-10 cnc-w-full cnc-items-center cnc-justify-between cnc-rounded-md cnc-border cnc-border-input cnc-bg-background cnc-px-3 cnc-py-2 cnc-text-sm cnc-ring-offset-background placeholder:cnc-text-muted-foreground focus:cnc-outline-none focus:cnc-ring-2 focus:cnc-ring-ring focus:cnc-ring-offset-2 disabled:cnc-cursor-not-allowed disabled:cnc-opacity-50 [&>span]:cnc-line-clamp-1",
|
|
9338
|
+
className
|
|
9339
|
+
),
|
|
9340
|
+
...props,
|
|
9341
|
+
children: [
|
|
9342
|
+
children,
|
|
9343
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ChevronDown, { className: "h-4 w-4 opacity-50" }) })
|
|
9344
|
+
]
|
|
9345
|
+
}
|
|
9346
|
+
));
|
|
9347
|
+
SelectTrigger.displayName = SelectPrimitive.Trigger.displayName;
|
|
9348
|
+
var SelectScrollUpButton = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
9349
|
+
SelectPrimitive.ScrollUpButton,
|
|
9350
|
+
{
|
|
9351
|
+
ref,
|
|
9352
|
+
className: cn(
|
|
9353
|
+
"cnc-flex cnc-cursor-default cnc-items-center cnc-justify-center cnc-py-1",
|
|
9354
|
+
className
|
|
9355
|
+
),
|
|
9356
|
+
...props,
|
|
9357
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ChevronUp, { className: "cnc-h-4 cnc-w-4" })
|
|
9358
|
+
}
|
|
9359
|
+
));
|
|
9360
|
+
SelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;
|
|
9361
|
+
var SelectScrollDownButton = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
9362
|
+
SelectPrimitive.ScrollDownButton,
|
|
9363
|
+
{
|
|
9364
|
+
ref,
|
|
9365
|
+
className: cn(
|
|
9366
|
+
"cnc-flex cnc-cursor-default cnc-items-center cnc-justify-center cnc-py-1",
|
|
9367
|
+
className
|
|
9368
|
+
),
|
|
9369
|
+
...props,
|
|
9370
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ChevronDown, { className: "cnc-h-4 cnc-w-4" })
|
|
9371
|
+
}
|
|
9372
|
+
));
|
|
9373
|
+
SelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;
|
|
9374
|
+
var SelectContent = React38.forwardRef(({ className, children, position = "popper", ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SelectPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
|
|
9375
|
+
SelectPrimitive.Content,
|
|
9376
|
+
{
|
|
9377
|
+
ref,
|
|
9378
|
+
className: cn(
|
|
9379
|
+
"cnc-relative cnc-z-50 cnc-max-h-96 cnc-min-w-[8rem] cnc-overflow-hidden cnc-rounded-md cnc-border cnc-bg-popover cnc-text-popover-foreground cnc-shadow-md data-[state=open]:cnc-animate-in data-[state=closed]:cnc-animate-out data-[state=closed]:cnc-fade-out-0 data-[state=open]:cnc-fade-in-0 data-[state=closed]:cnc-zoom-out-95 data-[state=open]:cnc-zoom-in-95 data-[side=bottom]:cnc-slide-in-from-top-2 data-[side=left]:cnc-slide-in-from-right-2 data-[side=right]:cnc-slide-in-from-left-2 data-[side=top]:cnc-slide-in-from-bottom-2",
|
|
9380
|
+
position === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
|
|
9381
|
+
className
|
|
9382
|
+
),
|
|
9383
|
+
position,
|
|
9384
|
+
...props,
|
|
9385
|
+
children: [
|
|
9386
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SelectScrollUpButton, {}),
|
|
9387
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
9388
|
+
SelectPrimitive.Viewport,
|
|
9389
|
+
{
|
|
9390
|
+
className: cn(
|
|
9391
|
+
"cnc-p-1",
|
|
9392
|
+
position === "popper" && "cnc-h-[var(--radix-select-trigger-height)] cnc-w-full cnc-min-w-[var(--radix-select-trigger-width)]"
|
|
9393
|
+
),
|
|
9394
|
+
children
|
|
9395
|
+
}
|
|
9396
|
+
),
|
|
9397
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SelectScrollDownButton, {})
|
|
9398
|
+
]
|
|
9399
|
+
}
|
|
9400
|
+
) }));
|
|
9401
|
+
SelectContent.displayName = SelectPrimitive.Content.displayName;
|
|
9402
|
+
var SelectLabel = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
9403
|
+
SelectPrimitive.Label,
|
|
9404
|
+
{
|
|
9405
|
+
ref,
|
|
9406
|
+
className: cn("cnc-py-1.5 cnc-pl-8 cnc-pr-2 cnc-text-sm cnc-font-semibold", className),
|
|
9407
|
+
...props
|
|
9408
|
+
}
|
|
9409
|
+
));
|
|
9410
|
+
SelectLabel.displayName = SelectPrimitive.Label.displayName;
|
|
9411
|
+
var SelectItem = React38.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
|
|
9412
|
+
SelectPrimitive.Item,
|
|
9413
|
+
{
|
|
9414
|
+
ref,
|
|
9415
|
+
className: cn(
|
|
9416
|
+
"cnc-relative cnc-flex cnc-w-full cnc-cursor-default cnc-select-none cnc-items-center cnc-rounded-sm cnc-py-1.5 cnc-pl-8 cnc-pr-2 cnc-text-sm cnc-outline-none focus:cnc-bg-accent focus:cnc-text-accent-foreground data-[disabled]:cnc-pointer-events-none data-[disabled]:cnc-opacity-50 hover:cnc-bg-slate-50",
|
|
9417
|
+
className
|
|
9418
|
+
),
|
|
9419
|
+
...props,
|
|
9420
|
+
children: [
|
|
9421
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)("span", { className: "cnc-absolute cnc-left-2 cnc-flex cnc-h-3.5 cnc-w-3.5 cnc-cnc-items-center cnc-justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Check, { className: "cnc-h-4 cnc-w-4" }) }) }),
|
|
9422
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SelectPrimitive.ItemText, { children })
|
|
9423
|
+
]
|
|
9424
|
+
}
|
|
9425
|
+
));
|
|
9426
|
+
SelectItem.displayName = SelectPrimitive.Item.displayName;
|
|
9427
|
+
var SelectSeparator = React38.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
9428
|
+
SelectPrimitive.Separator,
|
|
9429
|
+
{
|
|
9430
|
+
ref,
|
|
9431
|
+
className: cn("-cnc-mx-1 cnc-my-1 cnc-h-px cnc-bg-muted", className),
|
|
9432
|
+
...props
|
|
9433
|
+
}
|
|
9434
|
+
));
|
|
9435
|
+
SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
|
|
9431
9436
|
// Annotate the CommonJS export names for ESM import in node:
|
|
9432
9437
|
0 && (module.exports = {
|
|
9433
9438
|
AplicationsHeader,
|
|
@@ -9462,10 +9467,21 @@ PopoverContent2.displayName = Content23.displayName;
|
|
|
9462
9467
|
HeaderProfileHeader,
|
|
9463
9468
|
HeaderProfileItem,
|
|
9464
9469
|
Modal,
|
|
9470
|
+
ModalEntidade,
|
|
9465
9471
|
ModalMudancaEntidade,
|
|
9466
9472
|
Popover,
|
|
9467
9473
|
PopoverContent,
|
|
9468
9474
|
PopoverTrigger,
|
|
9475
|
+
Select,
|
|
9476
|
+
SelectContent,
|
|
9477
|
+
SelectGroup,
|
|
9478
|
+
SelectItem,
|
|
9479
|
+
SelectLabel,
|
|
9480
|
+
SelectScrollDownButton,
|
|
9481
|
+
SelectScrollUpButton,
|
|
9482
|
+
SelectSeparator,
|
|
9483
|
+
SelectTrigger,
|
|
9484
|
+
SelectValue,
|
|
9469
9485
|
Sidebar,
|
|
9470
9486
|
SidebarContainer,
|
|
9471
9487
|
SidebarImageBrand,
|
|
@@ -9515,6 +9531,14 @@ lucide-react/dist/esm/icons/check.js:
|
|
|
9515
9531
|
* See the LICENSE file in the root directory of this source tree.
|
|
9516
9532
|
*)
|
|
9517
9533
|
|
|
9534
|
+
lucide-react/dist/esm/icons/chevron-down.js:
|
|
9535
|
+
(**
|
|
9536
|
+
* @license lucide-react v0.453.0 - ISC
|
|
9537
|
+
*
|
|
9538
|
+
* This source code is licensed under the ISC license.
|
|
9539
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
9540
|
+
*)
|
|
9541
|
+
|
|
9518
9542
|
lucide-react/dist/esm/icons/chevron-right.js:
|
|
9519
9543
|
(**
|
|
9520
9544
|
* @license lucide-react v0.453.0 - ISC
|
|
@@ -9523,6 +9547,14 @@ lucide-react/dist/esm/icons/chevron-right.js:
|
|
|
9523
9547
|
* See the LICENSE file in the root directory of this source tree.
|
|
9524
9548
|
*)
|
|
9525
9549
|
|
|
9550
|
+
lucide-react/dist/esm/icons/chevron-up.js:
|
|
9551
|
+
(**
|
|
9552
|
+
* @license lucide-react v0.453.0 - ISC
|
|
9553
|
+
*
|
|
9554
|
+
* This source code is licensed under the ISC license.
|
|
9555
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
9556
|
+
*)
|
|
9557
|
+
|
|
9526
9558
|
lucide-react/dist/esm/icons/circle.js:
|
|
9527
9559
|
(**
|
|
9528
9560
|
* @license lucide-react v0.453.0 - ISC
|