@quantinuum/quantinuum-ui 3.5.1 → 3.6.0-release-input-group.1
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/node_modules/@radix-ui/react-collection/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-collection/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-popover/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-popover/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-slot/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-slot/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-slot/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.mjs.js +2 -0
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
- package/dist/src/custom/icons.js +1 -1
- package/dist/src/custom/icons.js.map +1 -1
- package/dist/src/index.js +1 -1
- package/dist/src/shadcn/ui/breadcrumb.js +1 -1
- package/dist/src/shadcn/ui/button.js +1 -1
- package/dist/src/shadcn/ui/form.js +1 -1
- package/dist/src/shadcn/ui/input-group.js +3 -0
- package/dist/src/shadcn/ui/input-group.js.map +1 -0
- package/dist/tailwind-manifest.js +785 -129
- package/dist/types/src/custom/icons.d.ts +3 -0
- package/dist/types/src/index.d.ts +1 -0
- package/dist/types/src/shadcn/ui/input-group.d.ts +18 -0
- package/dist/types/stories/shadcn/input-group.stories.d.ts +5 -0
- package/package.json +9 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
import React__default, { useRef, useCallback, forwardRef, Children, isValidElement,
|
|
3
|
+
import React__default, { useRef, createContext, useMemo, createElement, useContext, useCallback, forwardRef, Children, isValidElement, cloneElement, Fragment as Fragment$1, useEffect, useState, useLayoutEffect, useReducer } from 'react';
|
|
4
4
|
import * as ReactDOM from 'react-dom';
|
|
5
5
|
import ReactDOM__default, { flushSync, createPortal } from 'react-dom';
|
|
6
6
|
import { MenuIcon, SunIcon, MoonIcon, Check, Copy, ComputerIcon, Search, ChevronRight, Circle, Minus } from 'lucide-react';
|
|
@@ -385,6 +385,9 @@ const StatusIconSubmitted = (props) => {
|
|
|
385
385
|
const StatusIconRetrying = (props) => {
|
|
386
386
|
return jsxs("svg", Object.assign({ width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: cn$1("size-5 text-muted-foreground", props.className) }, { children: [jsx("g", Object.assign({ clipPath: "url(#clip0_4504_53241)" }, { children: jsx("path", { d: "M10 2C14.4183 2 18 5.58172 18 10C18 14.4183 14.4183 18 10 18C5.58172 18 2 14.4183 2 10C2 5.58172 5.58172 2 10 2ZM12.4424 6.55762C12.1983 6.31354 11.8017 6.31354 11.5576 6.55762C11.3135 6.80169 11.3135 7.19831 11.5576 7.44238L12.4902 8.375H9.0625C8.35591 8.375 7.67431 8.64675 7.16895 9.13672C6.66291 9.62742 6.375 10.2975 6.375 11C6.375 11.3474 6.44544 11.6909 6.58203 12.0107C6.71865 12.3306 6.91852 12.6204 7.16895 12.8633C7.67431 13.3532 8.35591 13.625 9.0625 13.625H10.375C10.7202 13.625 11 13.3452 11 13C11 12.6548 10.7202 12.375 10.375 12.375H9.0625C8.67519 12.375 8.30727 12.2259 8.03906 11.9658C7.90645 11.8372 7.80212 11.685 7.73145 11.5195C7.6609 11.3542 7.625 11.1777 7.625 11C7.625 10.6416 7.77151 10.2936 8.03906 10.0342C8.30727 9.77415 8.67519 9.625 9.0625 9.625H12.4902L11.5576 10.5576C11.3135 10.8017 11.3135 11.1983 11.5576 11.4424C11.8017 11.6865 12.1983 11.6865 12.4424 11.4424L14.4424 9.44238C14.6865 9.19831 14.6865 8.80169 14.4424 8.55762L12.4424 6.55762Z", fill: "currentColor" }) })), jsx("defs", { children: jsx("clipPath", Object.assign({ id: "clip0_4504_53241" }, { children: jsx("rect", { width: "16", height: "16", fill: "white", transform: "translate(2 2)" }) })) })] }));
|
|
387
387
|
};
|
|
388
|
+
const ExactMatchIcon = (props) => {
|
|
389
|
+
return (jsxs("svg", Object.assign({ width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: cn$1("size-5", props.className) }, { children: [jsx("rect", { x: "0.5", y: "0.5", width: "19", height: "19", rx: "1.5", stroke: "currentColor" }), jsx("path", { d: "M17 13H14.4074C14.1325 12.9996 13.869 12.8941 13.6746 12.7067C13.4802 12.5192 13.3708 12.2651 13.3704 12V9C13.3704 8.73478 13.4796 8.48043 13.6741 8.29289C13.8686 8.10536 14.1324 8 14.4074 8H17V9H14.4074V12H17V13ZM11.2963 8H9.22222V6H8.18518V13H11.2963C11.5712 12.9996 11.8347 12.8941 12.0291 12.7067C12.2235 12.5192 12.3329 12.2651 12.3333 12V9C12.3333 8.73478 12.2241 8.48043 12.0296 8.29289C11.8351 8.10536 11.5713 8 11.2963 8ZM9.22222 12V9H11.2963V12H9.22222ZM6.11111 8H3.51852V9H6.11111V10H4.03704C3.762 10 3.49822 10.1054 3.30374 10.2929C3.10926 10.4804 3 10.7348 3 11V12C3 12.2652 3.10926 12.5196 3.30374 12.7071C3.49822 12.8946 3.762 13 4.03704 13H7.14815V9C7.14815 8.73478 7.03889 8.48043 6.84441 8.29289C6.64992 8.10536 6.38615 8 6.11111 8ZM6.11111 12H4.03704V11H6.11111V12Z", fill: "currentColor" })] })));
|
|
390
|
+
};
|
|
388
391
|
|
|
389
392
|
const SlideIn = (props) => {
|
|
390
393
|
const ref = useRef(null);
|
|
@@ -404,113 +407,136 @@ const SlideIn = (props) => {
|
|
|
404
407
|
return (jsx("div", Object.assign({ className: "opacity-0", ref: ref }, { children: props.children })));
|
|
405
408
|
};
|
|
406
409
|
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
410
|
+
// packages/react/compose-refs/src/compose-refs.tsx
|
|
411
|
+
function setRef$1(ref, value) {
|
|
412
|
+
if (typeof ref === "function") {
|
|
413
|
+
return ref(value);
|
|
414
|
+
} else if (ref !== null && ref !== void 0) {
|
|
415
|
+
ref.current = value;
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
function composeRefs$1(...refs) {
|
|
419
|
+
return (node) => {
|
|
420
|
+
let hasCleanup = false;
|
|
421
|
+
const cleanups = refs.map((ref) => {
|
|
422
|
+
const cleanup = setRef$1(ref, node);
|
|
423
|
+
if (!hasCleanup && typeof cleanup == "function") {
|
|
424
|
+
hasCleanup = true;
|
|
425
|
+
}
|
|
426
|
+
return cleanup;
|
|
427
|
+
});
|
|
428
|
+
if (hasCleanup) {
|
|
429
|
+
return () => {
|
|
430
|
+
for (let i = 0; i < cleanups.length; i++) {
|
|
431
|
+
const cleanup = cleanups[i];
|
|
432
|
+
if (typeof cleanup == "function") {
|
|
433
|
+
cleanup();
|
|
434
|
+
} else {
|
|
435
|
+
setRef$1(refs[i], null);
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
};
|
|
412
439
|
}
|
|
413
|
-
|
|
414
|
-
}, _extends.apply(null, arguments);
|
|
440
|
+
};
|
|
415
441
|
}
|
|
416
442
|
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
else if (ref !== null && ref !== undefined) ref.current = value;
|
|
423
|
-
}
|
|
424
|
-
/**
|
|
425
|
-
* A utility to compose multiple refs together
|
|
426
|
-
* Accepts callback refs and RefObject(s)
|
|
427
|
-
*/ function $6ed0406888f73fc4$export$43e446d32b3d21af$1(...refs) {
|
|
428
|
-
return (node)=>refs.forEach((ref)=>$6ed0406888f73fc4$var$setRef$1(ref, node)
|
|
429
|
-
)
|
|
430
|
-
;
|
|
443
|
+
// src/slot.tsx
|
|
444
|
+
var REACT_LAZY_TYPE = Symbol.for("react.lazy");
|
|
445
|
+
var use = React[" use ".trim().toString()];
|
|
446
|
+
function isPromiseLike(value) {
|
|
447
|
+
return typeof value === "object" && value !== null && "then" in value;
|
|
431
448
|
}
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
* Accepts callback refs and RefObject(s)
|
|
435
|
-
*/ function $6ed0406888f73fc4$export$c7b2cbe3552a0d05$1(...refs) {
|
|
436
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
437
|
-
return useCallback($6ed0406888f73fc4$export$43e446d32b3d21af$1(...refs), refs);
|
|
449
|
+
function isLazyComponent(element) {
|
|
450
|
+
return element != null && typeof element === "object" && "$$typeof" in element && element.$$typeof === REACT_LAZY_TYPE && "_payload" in element && isPromiseLike(element._payload);
|
|
438
451
|
}
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
452
|
+
// @__NO_SIDE_EFFECTS__
|
|
453
|
+
function createSlot$1(ownerName) {
|
|
454
|
+
const SlotClone = /* @__PURE__ */ createSlotClone$1(ownerName);
|
|
455
|
+
const Slot2 = React.forwardRef((props, forwardedRef) => {
|
|
456
|
+
let { children, ...slotProps } = props;
|
|
457
|
+
if (isLazyComponent(children) && typeof use === "function") {
|
|
458
|
+
children = use(children._payload);
|
|
459
|
+
}
|
|
460
|
+
const childrenArray = React.Children.toArray(children);
|
|
461
|
+
const slottable = childrenArray.find(isSlottable$1);
|
|
446
462
|
if (slottable) {
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$1, _extends({}, slotProps, {
|
|
458
|
-
ref: forwardedRef
|
|
459
|
-
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
463
|
+
const newElement = slottable.props.children;
|
|
464
|
+
const newChildren = childrenArray.map((child) => {
|
|
465
|
+
if (child === slottable) {
|
|
466
|
+
if (React.Children.count(newElement) > 1) return React.Children.only(null);
|
|
467
|
+
return React.isValidElement(newElement) ? newElement.props.children : null;
|
|
468
|
+
} else {
|
|
469
|
+
return child;
|
|
470
|
+
}
|
|
471
|
+
});
|
|
472
|
+
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });
|
|
460
473
|
}
|
|
461
|
-
return
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
$5e63c961fc1ce211$export$8c6ed5c666ac1360$1.displayName = 'Slot';
|
|
466
|
-
/* -------------------------------------------------------------------------------------------------
|
|
467
|
-
* SlotClone
|
|
468
|
-
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$1 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
469
|
-
const { children: children , ...slotProps } = props;
|
|
470
|
-
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
471
|
-
...$5e63c961fc1ce211$var$mergeProps$1(slotProps, children.props),
|
|
472
|
-
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
473
|
-
});
|
|
474
|
-
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
475
|
-
});
|
|
476
|
-
$5e63c961fc1ce211$var$SlotClone$1.displayName = 'SlotClone';
|
|
477
|
-
/* -------------------------------------------------------------------------------------------------
|
|
478
|
-
* Slottable
|
|
479
|
-
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$1 = ({ children: children })=>{
|
|
480
|
-
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
481
|
-
};
|
|
482
|
-
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$1(child) {
|
|
483
|
-
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$1;
|
|
474
|
+
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
|
|
475
|
+
});
|
|
476
|
+
Slot2.displayName = `${ownerName}.Slot`;
|
|
477
|
+
return Slot2;
|
|
484
478
|
}
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
};
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
479
|
+
var Slot = /* @__PURE__ */ createSlot$1("Slot");
|
|
480
|
+
// @__NO_SIDE_EFFECTS__
|
|
481
|
+
function createSlotClone$1(ownerName) {
|
|
482
|
+
const SlotClone = React.forwardRef((props, forwardedRef) => {
|
|
483
|
+
let { children, ...slotProps } = props;
|
|
484
|
+
if (isLazyComponent(children) && typeof use === "function") {
|
|
485
|
+
children = use(children._payload);
|
|
486
|
+
}
|
|
487
|
+
if (React.isValidElement(children)) {
|
|
488
|
+
const childrenRef = getElementRef$2(children);
|
|
489
|
+
const props2 = mergeProps$1(slotProps, children.props);
|
|
490
|
+
if (children.type !== React.Fragment) {
|
|
491
|
+
props2.ref = forwardedRef ? composeRefs$1(forwardedRef, childrenRef) : childrenRef;
|
|
492
|
+
}
|
|
493
|
+
return React.cloneElement(children, props2);
|
|
494
|
+
}
|
|
495
|
+
return React.Children.count(children) > 1 ? React.Children.only(null) : null;
|
|
496
|
+
});
|
|
497
|
+
SlotClone.displayName = `${ownerName}.SlotClone`;
|
|
498
|
+
return SlotClone;
|
|
499
|
+
}
|
|
500
|
+
var SLOTTABLE_IDENTIFIER$1 = Symbol("radix.slottable");
|
|
501
|
+
function isSlottable$1(child) {
|
|
502
|
+
return React.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER$1;
|
|
503
|
+
}
|
|
504
|
+
function mergeProps$1(slotProps, childProps) {
|
|
505
|
+
const overrideProps = { ...childProps };
|
|
506
|
+
for (const propName in childProps) {
|
|
507
|
+
const slotPropValue = slotProps[propName];
|
|
508
|
+
const childPropValue = childProps[propName];
|
|
509
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
510
|
+
if (isHandler) {
|
|
511
|
+
if (slotPropValue && childPropValue) {
|
|
512
|
+
overrideProps[propName] = (...args) => {
|
|
513
|
+
const result = childPropValue(...args);
|
|
514
|
+
slotPropValue(...args);
|
|
515
|
+
return result;
|
|
504
516
|
};
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
517
|
+
} else if (slotPropValue) {
|
|
518
|
+
overrideProps[propName] = slotPropValue;
|
|
519
|
+
}
|
|
520
|
+
} else if (propName === "style") {
|
|
521
|
+
overrideProps[propName] = { ...slotPropValue, ...childPropValue };
|
|
522
|
+
} else if (propName === "className") {
|
|
523
|
+
overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
|
|
509
524
|
}
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
525
|
+
}
|
|
526
|
+
return { ...slotProps, ...overrideProps };
|
|
527
|
+
}
|
|
528
|
+
function getElementRef$2(element) {
|
|
529
|
+
let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
|
|
530
|
+
let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
531
|
+
if (mayWarn) {
|
|
532
|
+
return element.ref;
|
|
533
|
+
}
|
|
534
|
+
getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
|
|
535
|
+
mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
536
|
+
if (mayWarn) {
|
|
537
|
+
return element.props.ref;
|
|
538
|
+
}
|
|
539
|
+
return element.props.ref || element.ref;
|
|
514
540
|
}
|
|
515
541
|
|
|
516
542
|
function r$1(e){var t,f,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(f=r$1(e[t]))&&(n&&(n+=" "),n+=f);else for(t in e)e[t]&&(n&&(n+=" "),n+=t);return n}function clsx$1(){for(var e,t,f=0,n="";f<arguments.length;)(e=arguments[f++])&&(t=r$1(e))&&(n&&(n+=" "),n+=t);return n}
|
|
@@ -582,7 +608,7 @@ const buttonVariants = cva("inline-flex items-center justify-center gap-2 whites
|
|
|
582
608
|
});
|
|
583
609
|
const Button$1 = React.forwardRef((_a, ref) => {
|
|
584
610
|
var { className, variant, size, asChild = false } = _a, props = __rest$1(_a, ["className", "variant", "size", "asChild"]);
|
|
585
|
-
const Comp = asChild ?
|
|
611
|
+
const Comp = asChild ? Slot : "button";
|
|
586
612
|
return (jsx(Comp, Object.assign({ className: cn$1(buttonVariants({ variant, size, className })), ref: ref }, props)));
|
|
587
613
|
});
|
|
588
614
|
Button$1.displayName = "Button";
|
|
@@ -657,6 +683,16 @@ const ThemeSelector = React__default.forwardRef(({ theme, setMode }, ref) => {
|
|
|
657
683
|
}, ref: ref }, { children: stateMap[theme.mode].icon })));
|
|
658
684
|
});
|
|
659
685
|
|
|
686
|
+
function _extends() {
|
|
687
|
+
return _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
688
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
689
|
+
var t = arguments[e];
|
|
690
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
691
|
+
}
|
|
692
|
+
return n;
|
|
693
|
+
}, _extends.apply(null, arguments);
|
|
694
|
+
}
|
|
695
|
+
|
|
660
696
|
/* -------------------------------------------------------------------------------------------------
|
|
661
697
|
* createContextScope
|
|
662
698
|
* -----------------------------------------------------------------------------------------------*/ function $c512c27ab02ef895$export$50c7b4e9d9f19c1$1(scopeName, createContextScopeDeps = []) {
|
|
@@ -754,6 +790,105 @@ const ThemeSelector = React__default.forwardRef(({ theme, setMode }, ref) => {
|
|
|
754
790
|
return createScope1;
|
|
755
791
|
}
|
|
756
792
|
|
|
793
|
+
/**
|
|
794
|
+
* Set a given ref to a given value
|
|
795
|
+
* This utility takes care of different types of refs: callback refs and RefObject(s)
|
|
796
|
+
*/ function $6ed0406888f73fc4$var$setRef$1(ref, value) {
|
|
797
|
+
if (typeof ref === 'function') ref(value);
|
|
798
|
+
else if (ref !== null && ref !== undefined) ref.current = value;
|
|
799
|
+
}
|
|
800
|
+
/**
|
|
801
|
+
* A utility to compose multiple refs together
|
|
802
|
+
* Accepts callback refs and RefObject(s)
|
|
803
|
+
*/ function $6ed0406888f73fc4$export$43e446d32b3d21af$1(...refs) {
|
|
804
|
+
return (node)=>refs.forEach((ref)=>$6ed0406888f73fc4$var$setRef$1(ref, node)
|
|
805
|
+
)
|
|
806
|
+
;
|
|
807
|
+
}
|
|
808
|
+
/**
|
|
809
|
+
* A custom hook that composes multiple refs
|
|
810
|
+
* Accepts callback refs and RefObject(s)
|
|
811
|
+
*/ function $6ed0406888f73fc4$export$c7b2cbe3552a0d05$1(...refs) {
|
|
812
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
813
|
+
return useCallback($6ed0406888f73fc4$export$43e446d32b3d21af$1(...refs), refs);
|
|
814
|
+
}
|
|
815
|
+
|
|
816
|
+
/* -------------------------------------------------------------------------------------------------
|
|
817
|
+
* Slot
|
|
818
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$7 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
819
|
+
const { children: children , ...slotProps } = props;
|
|
820
|
+
const childrenArray = Children.toArray(children);
|
|
821
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$7);
|
|
822
|
+
if (slottable) {
|
|
823
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
824
|
+
const newElement = slottable.props.children;
|
|
825
|
+
const newChildren = childrenArray.map((child)=>{
|
|
826
|
+
if (child === slottable) {
|
|
827
|
+
// because the new element will be the one rendered, we are only interested
|
|
828
|
+
// in grabbing its children (`newElement.props.children`)
|
|
829
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
830
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
831
|
+
} else return child;
|
|
832
|
+
});
|
|
833
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$7, _extends({}, slotProps, {
|
|
834
|
+
ref: forwardedRef
|
|
835
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
836
|
+
}
|
|
837
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$7, _extends({}, slotProps, {
|
|
838
|
+
ref: forwardedRef
|
|
839
|
+
}), children);
|
|
840
|
+
});
|
|
841
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$7.displayName = 'Slot';
|
|
842
|
+
/* -------------------------------------------------------------------------------------------------
|
|
843
|
+
* SlotClone
|
|
844
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$7 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
845
|
+
const { children: children , ...slotProps } = props;
|
|
846
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
847
|
+
...$5e63c961fc1ce211$var$mergeProps$7(slotProps, children.props),
|
|
848
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
849
|
+
});
|
|
850
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
851
|
+
});
|
|
852
|
+
$5e63c961fc1ce211$var$SlotClone$7.displayName = 'SlotClone';
|
|
853
|
+
/* -------------------------------------------------------------------------------------------------
|
|
854
|
+
* Slottable
|
|
855
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$7 = ({ children: children })=>{
|
|
856
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
857
|
+
};
|
|
858
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$7(child) {
|
|
859
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$7;
|
|
860
|
+
}
|
|
861
|
+
function $5e63c961fc1ce211$var$mergeProps$7(slotProps, childProps) {
|
|
862
|
+
// all child props should override
|
|
863
|
+
const overrideProps = {
|
|
864
|
+
...childProps
|
|
865
|
+
};
|
|
866
|
+
for(const propName in childProps){
|
|
867
|
+
const slotPropValue = slotProps[propName];
|
|
868
|
+
const childPropValue = childProps[propName];
|
|
869
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
870
|
+
if (isHandler) {
|
|
871
|
+
// if the handler exists on both, we compose them
|
|
872
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
873
|
+
childPropValue(...args);
|
|
874
|
+
slotPropValue(...args);
|
|
875
|
+
};
|
|
876
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
877
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
878
|
+
...slotPropValue,
|
|
879
|
+
...childPropValue
|
|
880
|
+
};
|
|
881
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
882
|
+
slotPropValue,
|
|
883
|
+
childPropValue
|
|
884
|
+
].filter(Boolean).join(' ');
|
|
885
|
+
}
|
|
886
|
+
return {
|
|
887
|
+
...slotProps,
|
|
888
|
+
...overrideProps
|
|
889
|
+
};
|
|
890
|
+
}
|
|
891
|
+
|
|
757
892
|
// We have resorted to returning slots directly rather than exposing primitives that can then
|
|
758
893
|
// be slotted like `<CollectionItem as={Slot}>…</CollectionItem>`.
|
|
759
894
|
// This is because we encountered issues with generic types that cannot be statically analysed
|
|
@@ -786,7 +921,7 @@ function $e02a7d9cb1dc128c$export$c74125a8e3af6bb2(name) {
|
|
|
786
921
|
const { scope: scope , children: children } = props;
|
|
787
922
|
const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);
|
|
788
923
|
const composedRefs = $6ed0406888f73fc4$export$c7b2cbe3552a0d05$1(forwardedRef, context.collectionRef);
|
|
789
|
-
return /*#__PURE__*/ React__default.createElement($5e63c961fc1ce211$export$8c6ed5c666ac1360$
|
|
924
|
+
return /*#__PURE__*/ React__default.createElement($5e63c961fc1ce211$export$8c6ed5c666ac1360$7, {
|
|
790
925
|
ref: composedRefs
|
|
791
926
|
}, children);
|
|
792
927
|
});
|
|
@@ -807,7 +942,7 @@ function $e02a7d9cb1dc128c$export$c74125a8e3af6bb2(name) {
|
|
|
807
942
|
return ()=>void context.itemMap.delete(ref)
|
|
808
943
|
;
|
|
809
944
|
});
|
|
810
|
-
return /*#__PURE__*/ React__default.createElement($5e63c961fc1ce211$export$8c6ed5c666ac1360$
|
|
945
|
+
return /*#__PURE__*/ React__default.createElement($5e63c961fc1ce211$export$8c6ed5c666ac1360$7, {
|
|
811
946
|
[ITEM_DATA_ATTR]: '',
|
|
812
947
|
ref: composedRefs
|
|
813
948
|
}, children);
|
|
@@ -906,6 +1041,82 @@ function $71cd76cc60e0454e$var$useUncontrolledState$1({ defaultProp: defaultProp
|
|
|
906
1041
|
return uncontrolledState;
|
|
907
1042
|
}
|
|
908
1043
|
|
|
1044
|
+
/* -------------------------------------------------------------------------------------------------
|
|
1045
|
+
* Slot
|
|
1046
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$6 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
1047
|
+
const { children: children , ...slotProps } = props;
|
|
1048
|
+
const childrenArray = Children.toArray(children);
|
|
1049
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$6);
|
|
1050
|
+
if (slottable) {
|
|
1051
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
1052
|
+
const newElement = slottable.props.children;
|
|
1053
|
+
const newChildren = childrenArray.map((child)=>{
|
|
1054
|
+
if (child === slottable) {
|
|
1055
|
+
// because the new element will be the one rendered, we are only interested
|
|
1056
|
+
// in grabbing its children (`newElement.props.children`)
|
|
1057
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
1058
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
1059
|
+
} else return child;
|
|
1060
|
+
});
|
|
1061
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$6, _extends({}, slotProps, {
|
|
1062
|
+
ref: forwardedRef
|
|
1063
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
1064
|
+
}
|
|
1065
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$6, _extends({}, slotProps, {
|
|
1066
|
+
ref: forwardedRef
|
|
1067
|
+
}), children);
|
|
1068
|
+
});
|
|
1069
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$6.displayName = 'Slot';
|
|
1070
|
+
/* -------------------------------------------------------------------------------------------------
|
|
1071
|
+
* SlotClone
|
|
1072
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$6 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
1073
|
+
const { children: children , ...slotProps } = props;
|
|
1074
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
1075
|
+
...$5e63c961fc1ce211$var$mergeProps$6(slotProps, children.props),
|
|
1076
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
1077
|
+
});
|
|
1078
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
1079
|
+
});
|
|
1080
|
+
$5e63c961fc1ce211$var$SlotClone$6.displayName = 'SlotClone';
|
|
1081
|
+
/* -------------------------------------------------------------------------------------------------
|
|
1082
|
+
* Slottable
|
|
1083
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$6 = ({ children: children })=>{
|
|
1084
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
1085
|
+
};
|
|
1086
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$6(child) {
|
|
1087
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$6;
|
|
1088
|
+
}
|
|
1089
|
+
function $5e63c961fc1ce211$var$mergeProps$6(slotProps, childProps) {
|
|
1090
|
+
// all child props should override
|
|
1091
|
+
const overrideProps = {
|
|
1092
|
+
...childProps
|
|
1093
|
+
};
|
|
1094
|
+
for(const propName in childProps){
|
|
1095
|
+
const slotPropValue = slotProps[propName];
|
|
1096
|
+
const childPropValue = childProps[propName];
|
|
1097
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
1098
|
+
if (isHandler) {
|
|
1099
|
+
// if the handler exists on both, we compose them
|
|
1100
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
1101
|
+
childPropValue(...args);
|
|
1102
|
+
slotPropValue(...args);
|
|
1103
|
+
};
|
|
1104
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
1105
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
1106
|
+
...slotPropValue,
|
|
1107
|
+
...childPropValue
|
|
1108
|
+
};
|
|
1109
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
1110
|
+
slotPropValue,
|
|
1111
|
+
childPropValue
|
|
1112
|
+
].filter(Boolean).join(' ');
|
|
1113
|
+
}
|
|
1114
|
+
return {
|
|
1115
|
+
...slotProps,
|
|
1116
|
+
...overrideProps
|
|
1117
|
+
};
|
|
1118
|
+
}
|
|
1119
|
+
|
|
909
1120
|
const $8927f6f2acc4f386$var$NODES$1 = [
|
|
910
1121
|
'a',
|
|
911
1122
|
'button',
|
|
@@ -931,7 +1142,7 @@ const $8927f6f2acc4f386$var$NODES$1 = [
|
|
|
931
1142
|
* -----------------------------------------------------------------------------------------------*/ const $8927f6f2acc4f386$export$250ffa63cdc0d034$1 = $8927f6f2acc4f386$var$NODES$1.reduce((primitive, node)=>{
|
|
932
1143
|
const Node = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
933
1144
|
const { asChild: asChild , ...primitiveProps } = props;
|
|
934
|
-
const Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac1360$
|
|
1145
|
+
const Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac1360$6 : node;
|
|
935
1146
|
useEffect(()=>{
|
|
936
1147
|
window[Symbol.for('radix-ui')] = true;
|
|
937
1148
|
}, []);
|
|
@@ -4422,7 +4633,7 @@ const BreadcrumbItem = React.forwardRef((_a, ref) => {
|
|
|
4422
4633
|
BreadcrumbItem.displayName = "BreadcrumbItem";
|
|
4423
4634
|
const BreadcrumbLink = React.forwardRef((_a, ref) => {
|
|
4424
4635
|
var { asChild, className } = _a, props = __rest$1(_a, ["asChild", "className"]);
|
|
4425
|
-
const Comp = asChild ?
|
|
4636
|
+
const Comp = asChild ? Slot : "a";
|
|
4426
4637
|
return (jsx(Comp, Object.assign({ ref: ref, className: cn$1("transition-colors hover:text-foreground", className) }, props)));
|
|
4427
4638
|
});
|
|
4428
4639
|
BreadcrumbLink.displayName = "BreadcrumbLink";
|
|
@@ -10618,10 +10829,10 @@ function $71cd76cc60e0454e$var$useUncontrolledState({ defaultProp: defaultProp ,
|
|
|
10618
10829
|
|
|
10619
10830
|
/* -------------------------------------------------------------------------------------------------
|
|
10620
10831
|
* Slot
|
|
10621
|
-
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
10832
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$5 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
10622
10833
|
const { children: children , ...slotProps } = props;
|
|
10623
10834
|
const childrenArray = Children.toArray(children);
|
|
10624
|
-
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable);
|
|
10835
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$5);
|
|
10625
10836
|
if (slottable) {
|
|
10626
10837
|
// the new element to render is the one passed as a child of `Slottable`
|
|
10627
10838
|
const newElement = slottable.props.children;
|
|
@@ -10633,35 +10844,35 @@ function $71cd76cc60e0454e$var$useUncontrolledState({ defaultProp: defaultProp ,
|
|
|
10633
10844
|
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
10634
10845
|
} else return child;
|
|
10635
10846
|
});
|
|
10636
|
-
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone, _extends({}, slotProps, {
|
|
10847
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$5, _extends({}, slotProps, {
|
|
10637
10848
|
ref: forwardedRef
|
|
10638
10849
|
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
10639
10850
|
}
|
|
10640
|
-
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone, _extends({}, slotProps, {
|
|
10851
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$5, _extends({}, slotProps, {
|
|
10641
10852
|
ref: forwardedRef
|
|
10642
10853
|
}), children);
|
|
10643
10854
|
});
|
|
10644
|
-
$5e63c961fc1ce211$export$8c6ed5c666ac1360.displayName = 'Slot';
|
|
10855
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$5.displayName = 'Slot';
|
|
10645
10856
|
/* -------------------------------------------------------------------------------------------------
|
|
10646
10857
|
* SlotClone
|
|
10647
|
-
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
10858
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$5 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
10648
10859
|
const { children: children , ...slotProps } = props;
|
|
10649
10860
|
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
10650
|
-
...$5e63c961fc1ce211$var$mergeProps(slotProps, children.props),
|
|
10861
|
+
...$5e63c961fc1ce211$var$mergeProps$5(slotProps, children.props),
|
|
10651
10862
|
ref: $6ed0406888f73fc4$export$43e446d32b3d21af(forwardedRef, children.ref)
|
|
10652
10863
|
});
|
|
10653
10864
|
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
10654
10865
|
});
|
|
10655
|
-
$5e63c961fc1ce211$var$SlotClone.displayName = 'SlotClone';
|
|
10866
|
+
$5e63c961fc1ce211$var$SlotClone$5.displayName = 'SlotClone';
|
|
10656
10867
|
/* -------------------------------------------------------------------------------------------------
|
|
10657
10868
|
* Slottable
|
|
10658
|
-
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 = ({ children: children })=>{
|
|
10869
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$5 = ({ children: children })=>{
|
|
10659
10870
|
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
10660
10871
|
};
|
|
10661
|
-
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable(child) {
|
|
10662
|
-
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45;
|
|
10872
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$5(child) {
|
|
10873
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$5;
|
|
10663
10874
|
}
|
|
10664
|
-
function $5e63c961fc1ce211$var$mergeProps(slotProps, childProps) {
|
|
10875
|
+
function $5e63c961fc1ce211$var$mergeProps$5(slotProps, childProps) {
|
|
10665
10876
|
// all child props should override
|
|
10666
10877
|
const overrideProps = {
|
|
10667
10878
|
...childProps
|
|
@@ -10711,7 +10922,7 @@ const $8927f6f2acc4f386$var$NODES = [
|
|
|
10711
10922
|
* -----------------------------------------------------------------------------------------------*/ const $8927f6f2acc4f386$export$250ffa63cdc0d034 = $8927f6f2acc4f386$var$NODES.reduce((primitive, node)=>{
|
|
10712
10923
|
const Node = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
10713
10924
|
const { asChild: asChild , ...primitiveProps } = props;
|
|
10714
|
-
const Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac1360 : node;
|
|
10925
|
+
const Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac1360$5 : node;
|
|
10715
10926
|
useEffect(()=>{
|
|
10716
10927
|
window[Symbol.for('radix-ui')] = true;
|
|
10717
10928
|
}, []);
|
|
@@ -12233,7 +12444,7 @@ const $5d3850c4d0b4e6c7$var$DialogOverlayImpl$1 = /*#__PURE__*/ forwardRef((prop
|
|
|
12233
12444
|
return(/*#__PURE__*/ // Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
|
|
12234
12445
|
// ie. when `Overlay` and `Content` are siblings
|
|
12235
12446
|
createElement(ReactRemoveScroll$1, {
|
|
12236
|
-
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360,
|
|
12447
|
+
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$5,
|
|
12237
12448
|
allowPinchZoom: true,
|
|
12238
12449
|
shards: [
|
|
12239
12450
|
context.contentRef
|
|
@@ -13384,6 +13595,82 @@ var SideCar = exportSidecar(effectCar, RemoveScrollSideCar);
|
|
|
13384
13595
|
var ReactRemoveScroll = React.forwardRef(function (props, ref) { return (React.createElement(RemoveScroll, __assign$1({}, props, { ref: ref, sideCar: SideCar }))); });
|
|
13385
13596
|
ReactRemoveScroll.classNames = RemoveScroll.classNames;
|
|
13386
13597
|
|
|
13598
|
+
/* -------------------------------------------------------------------------------------------------
|
|
13599
|
+
* Slot
|
|
13600
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$4 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
13601
|
+
const { children: children , ...slotProps } = props;
|
|
13602
|
+
const childrenArray = Children.toArray(children);
|
|
13603
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$4);
|
|
13604
|
+
if (slottable) {
|
|
13605
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
13606
|
+
const newElement = slottable.props.children;
|
|
13607
|
+
const newChildren = childrenArray.map((child)=>{
|
|
13608
|
+
if (child === slottable) {
|
|
13609
|
+
// because the new element will be the one rendered, we are only interested
|
|
13610
|
+
// in grabbing its children (`newElement.props.children`)
|
|
13611
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
13612
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
13613
|
+
} else return child;
|
|
13614
|
+
});
|
|
13615
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$4, _extends({}, slotProps, {
|
|
13616
|
+
ref: forwardedRef
|
|
13617
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
13618
|
+
}
|
|
13619
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$4, _extends({}, slotProps, {
|
|
13620
|
+
ref: forwardedRef
|
|
13621
|
+
}), children);
|
|
13622
|
+
});
|
|
13623
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$4.displayName = 'Slot';
|
|
13624
|
+
/* -------------------------------------------------------------------------------------------------
|
|
13625
|
+
* SlotClone
|
|
13626
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$4 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
13627
|
+
const { children: children , ...slotProps } = props;
|
|
13628
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
13629
|
+
...$5e63c961fc1ce211$var$mergeProps$4(slotProps, children.props),
|
|
13630
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
13631
|
+
});
|
|
13632
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
13633
|
+
});
|
|
13634
|
+
$5e63c961fc1ce211$var$SlotClone$4.displayName = 'SlotClone';
|
|
13635
|
+
/* -------------------------------------------------------------------------------------------------
|
|
13636
|
+
* Slottable
|
|
13637
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$4 = ({ children: children })=>{
|
|
13638
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
13639
|
+
};
|
|
13640
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$4(child) {
|
|
13641
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$4;
|
|
13642
|
+
}
|
|
13643
|
+
function $5e63c961fc1ce211$var$mergeProps$4(slotProps, childProps) {
|
|
13644
|
+
// all child props should override
|
|
13645
|
+
const overrideProps = {
|
|
13646
|
+
...childProps
|
|
13647
|
+
};
|
|
13648
|
+
for(const propName in childProps){
|
|
13649
|
+
const slotPropValue = slotProps[propName];
|
|
13650
|
+
const childPropValue = childProps[propName];
|
|
13651
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
13652
|
+
if (isHandler) {
|
|
13653
|
+
// if the handler exists on both, we compose them
|
|
13654
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
13655
|
+
childPropValue(...args);
|
|
13656
|
+
slotPropValue(...args);
|
|
13657
|
+
};
|
|
13658
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
13659
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
13660
|
+
...slotPropValue,
|
|
13661
|
+
...childPropValue
|
|
13662
|
+
};
|
|
13663
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
13664
|
+
slotPropValue,
|
|
13665
|
+
childPropValue
|
|
13666
|
+
].filter(Boolean).join(' ');
|
|
13667
|
+
}
|
|
13668
|
+
return {
|
|
13669
|
+
...slotProps,
|
|
13670
|
+
...overrideProps
|
|
13671
|
+
};
|
|
13672
|
+
}
|
|
13673
|
+
|
|
13387
13674
|
/* -------------------------------------------------------------------------------------------------
|
|
13388
13675
|
* Dialog
|
|
13389
13676
|
* -----------------------------------------------------------------------------------------------*/ const $5d3850c4d0b4e6c7$var$DIALOG_NAME = 'Dialog';
|
|
@@ -13472,7 +13759,7 @@ const $5d3850c4d0b4e6c7$var$DialogOverlayImpl = /*#__PURE__*/ forwardRef((props,
|
|
|
13472
13759
|
return(/*#__PURE__*/ // Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
|
|
13473
13760
|
// ie. when `Overlay` and `Content` are siblings
|
|
13474
13761
|
createElement(ReactRemoveScroll, {
|
|
13475
|
-
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$
|
|
13762
|
+
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$4,
|
|
13476
13763
|
allowPinchZoom: true,
|
|
13477
13764
|
shards: [
|
|
13478
13765
|
context.contentRef
|
|
@@ -16050,6 +16337,82 @@ function $d7bdfb9eb0fdf311$var$focusFirst(candidates) {
|
|
|
16050
16337
|
const $d7bdfb9eb0fdf311$export$be92b6f5f03c0fe9 = $d7bdfb9eb0fdf311$export$8699f7c8af148338;
|
|
16051
16338
|
const $d7bdfb9eb0fdf311$export$6d08773d2e66f8f2 = $d7bdfb9eb0fdf311$export$ab9df7c53fe8454;
|
|
16052
16339
|
|
|
16340
|
+
/* -------------------------------------------------------------------------------------------------
|
|
16341
|
+
* Slot
|
|
16342
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$3 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
16343
|
+
const { children: children , ...slotProps } = props;
|
|
16344
|
+
const childrenArray = Children.toArray(children);
|
|
16345
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$3);
|
|
16346
|
+
if (slottable) {
|
|
16347
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
16348
|
+
const newElement = slottable.props.children;
|
|
16349
|
+
const newChildren = childrenArray.map((child)=>{
|
|
16350
|
+
if (child === slottable) {
|
|
16351
|
+
// because the new element will be the one rendered, we are only interested
|
|
16352
|
+
// in grabbing its children (`newElement.props.children`)
|
|
16353
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
16354
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
16355
|
+
} else return child;
|
|
16356
|
+
});
|
|
16357
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$3, _extends({}, slotProps, {
|
|
16358
|
+
ref: forwardedRef
|
|
16359
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
16360
|
+
}
|
|
16361
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$3, _extends({}, slotProps, {
|
|
16362
|
+
ref: forwardedRef
|
|
16363
|
+
}), children);
|
|
16364
|
+
});
|
|
16365
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$3.displayName = 'Slot';
|
|
16366
|
+
/* -------------------------------------------------------------------------------------------------
|
|
16367
|
+
* SlotClone
|
|
16368
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$3 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
16369
|
+
const { children: children , ...slotProps } = props;
|
|
16370
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
16371
|
+
...$5e63c961fc1ce211$var$mergeProps$3(slotProps, children.props),
|
|
16372
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
16373
|
+
});
|
|
16374
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
16375
|
+
});
|
|
16376
|
+
$5e63c961fc1ce211$var$SlotClone$3.displayName = 'SlotClone';
|
|
16377
|
+
/* -------------------------------------------------------------------------------------------------
|
|
16378
|
+
* Slottable
|
|
16379
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$3 = ({ children: children })=>{
|
|
16380
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
16381
|
+
};
|
|
16382
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$3(child) {
|
|
16383
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$3;
|
|
16384
|
+
}
|
|
16385
|
+
function $5e63c961fc1ce211$var$mergeProps$3(slotProps, childProps) {
|
|
16386
|
+
// all child props should override
|
|
16387
|
+
const overrideProps = {
|
|
16388
|
+
...childProps
|
|
16389
|
+
};
|
|
16390
|
+
for(const propName in childProps){
|
|
16391
|
+
const slotPropValue = slotProps[propName];
|
|
16392
|
+
const childPropValue = childProps[propName];
|
|
16393
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
16394
|
+
if (isHandler) {
|
|
16395
|
+
// if the handler exists on both, we compose them
|
|
16396
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
16397
|
+
childPropValue(...args);
|
|
16398
|
+
slotPropValue(...args);
|
|
16399
|
+
};
|
|
16400
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
16401
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
16402
|
+
...slotPropValue,
|
|
16403
|
+
...childPropValue
|
|
16404
|
+
};
|
|
16405
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
16406
|
+
slotPropValue,
|
|
16407
|
+
childPropValue
|
|
16408
|
+
].filter(Boolean).join(' ');
|
|
16409
|
+
}
|
|
16410
|
+
return {
|
|
16411
|
+
...slotProps,
|
|
16412
|
+
...overrideProps
|
|
16413
|
+
};
|
|
16414
|
+
}
|
|
16415
|
+
|
|
16053
16416
|
const $6cc32821e9371a1c$var$SELECTION_KEYS = [
|
|
16054
16417
|
'Enter',
|
|
16055
16418
|
' '
|
|
@@ -16252,7 +16615,7 @@ const $6cc32821e9371a1c$var$MenuRootContentNonModal = /*#__PURE__*/ forwardRef((
|
|
|
16252
16615
|
const lastPointerXRef = useRef(0);
|
|
16253
16616
|
const ScrollLockWrapper = disableOutsideScroll ? ReactRemoveScroll : Fragment$1;
|
|
16254
16617
|
const scrollLockWrapperProps = disableOutsideScroll ? {
|
|
16255
|
-
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$
|
|
16618
|
+
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$3,
|
|
16256
16619
|
allowPinchZoom: true
|
|
16257
16620
|
} : undefined;
|
|
16258
16621
|
const handleTypeaheadSearch = (key)=>{
|
|
@@ -17256,7 +17619,7 @@ FormLabel.displayName = "FormLabel";
|
|
|
17256
17619
|
const FormControl = React.forwardRef((_a, ref) => {
|
|
17257
17620
|
var props = __rest$1(_a, []);
|
|
17258
17621
|
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
17259
|
-
return (jsx(
|
|
17622
|
+
return (jsx(Slot, Object.assign({ ref: ref, id: formItemId, "aria-describedby": !error
|
|
17260
17623
|
? `${formDescriptionId}`
|
|
17261
17624
|
: `${formDescriptionId} ${formMessageId}`, "aria-invalid": !!error }, props)));
|
|
17262
17625
|
});
|
|
@@ -17500,6 +17863,77 @@ const Input = React.forwardRef((_a, ref) => {
|
|
|
17500
17863
|
});
|
|
17501
17864
|
Input.displayName = "Input";
|
|
17502
17865
|
|
|
17866
|
+
const Textarea = React.forwardRef((_a, ref) => {
|
|
17867
|
+
var { className } = _a, props = __rest$1(_a, ["className"]);
|
|
17868
|
+
return (jsx("textarea", Object.assign({ className: cn$1("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50", className), ref: ref }, props)));
|
|
17869
|
+
});
|
|
17870
|
+
Textarea.displayName = "Textarea";
|
|
17871
|
+
|
|
17872
|
+
function InputGroup(_a) {
|
|
17873
|
+
var { className } = _a, props = __rest$1(_a, ["className"]);
|
|
17874
|
+
return (jsx("div", Object.assign({ "data-slot": "input-group", role: "group", className: cn$1("group/input-group border-input shadow-xs relative flex w-full items-center rounded-md border outline-none transition-[color,box-shadow]", "h-9 has-[>textarea]:h-auto",
|
|
17875
|
+
// Variants based on alignment.
|
|
17876
|
+
"has-[>[data-align=inline-start]]:[&>input]:pl-2", "has-[>[data-align=inline-end]]:[&>input]:pr-2", "has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>[data-align=block-start]]:[&>input]:pb-3", "has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-end]]:[&>input]:pt-3",
|
|
17877
|
+
// Focus state.
|
|
17878
|
+
"has-[[data-slot=input-group-control]:focus-visible]:ring-ring has-[[data-slot=input-group-control]:focus-visible]:ring-1",
|
|
17879
|
+
// Error state.
|
|
17880
|
+
"has-[[data-slot][aria-invalid=true]]:ring-destructive/20 has-[[data-slot][aria-invalid=true]]:border-destructive dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40", className) }, props)));
|
|
17881
|
+
}
|
|
17882
|
+
const inputGroupAddonVariants = cva("text-muted-foreground flex h-auto cursor-text select-none items-center justify-center gap-2 py-1.5 text-sm font-medium group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4", {
|
|
17883
|
+
variants: {
|
|
17884
|
+
align: {
|
|
17885
|
+
"inline-start": "order-first pl-3 has-[>button]:ml-[-0.45rem] has-[>kbd]:ml-[-0.35rem]",
|
|
17886
|
+
"inline-end": "order-last pr-3 has-[>button]:mr-[-0.4rem] has-[>kbd]:mr-[-0.35rem]",
|
|
17887
|
+
"block-start": "[.border-b]:pb-3 order-first w-full justify-start px-3 pt-3 group-has-[>input]/input-group:pt-2.5",
|
|
17888
|
+
"block-end": "[.border-t]:pt-3 order-last w-full justify-start px-3 pb-3 group-has-[>input]/input-group:pb-2.5",
|
|
17889
|
+
},
|
|
17890
|
+
},
|
|
17891
|
+
defaultVariants: {
|
|
17892
|
+
align: "inline-start",
|
|
17893
|
+
},
|
|
17894
|
+
});
|
|
17895
|
+
function InputGroupAddon(_a) {
|
|
17896
|
+
var { className, align = "inline-start" } = _a, props = __rest$1(_a, ["className", "align"]);
|
|
17897
|
+
return (jsx("div", Object.assign({ role: "group", "data-slot": "input-group-addon", "data-align": align, className: cn$1(inputGroupAddonVariants({ align }), className), onClick: (e) => {
|
|
17898
|
+
var _a, _b;
|
|
17899
|
+
if (e.target.closest("button")) {
|
|
17900
|
+
return;
|
|
17901
|
+
}
|
|
17902
|
+
(_b = (_a = e.currentTarget.parentElement) === null || _a === void 0 ? void 0 : _a.querySelector("input")) === null || _b === void 0 ? void 0 : _b.focus();
|
|
17903
|
+
} }, props)));
|
|
17904
|
+
}
|
|
17905
|
+
const inputGroupButtonVariants = cva("flex items-center gap-2 text-sm shadow-none", {
|
|
17906
|
+
variants: {
|
|
17907
|
+
size: {
|
|
17908
|
+
xs: "h-6 gap-1 rounded-[calc(var(--radius)-5px)] px-2 has-[>svg]:px-2 [&>svg:not([class*='size-'])]:size-3.5",
|
|
17909
|
+
sm: "h-8 gap-1.5 rounded-md px-2.5 has-[>svg]:px-2.5",
|
|
17910
|
+
"icon-xs": "size-6 rounded-[calc(var(--radius)-5px)] p-0 has-[>svg]:p-0",
|
|
17911
|
+
"icon-sm": "size-8 p-0 has-[>svg]:p-0",
|
|
17912
|
+
},
|
|
17913
|
+
},
|
|
17914
|
+
defaultVariants: {
|
|
17915
|
+
size: "xs",
|
|
17916
|
+
},
|
|
17917
|
+
});
|
|
17918
|
+
function InputGroupButton(_a) {
|
|
17919
|
+
var { className, type = "button", variant = "ghost", size = "xs" } = _a, props = __rest$1(_a, ["className", "type", "variant", "size"]);
|
|
17920
|
+
return (jsx(Button$1, Object.assign({ type: type, "data-size": size, variant: variant, className: cn$1(inputGroupButtonVariants({ size }), className) }, props)));
|
|
17921
|
+
}
|
|
17922
|
+
function InputGroupText(_a) {
|
|
17923
|
+
var { className } = _a, props = __rest$1(_a, ["className"]);
|
|
17924
|
+
return (jsx("span", Object.assign({ className: cn$1("text-muted-foreground flex items-center gap-2 text-sm [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none", className) }, props)));
|
|
17925
|
+
}
|
|
17926
|
+
const InputGroupInput = React.forwardRef((_a, ref) => {
|
|
17927
|
+
var { className } = _a, props = __rest$1(_a, ["className"]);
|
|
17928
|
+
return (jsx(Input, Object.assign({ "data-slot": "input-group-control", className: cn$1("flex-1 rounded-none border-0 bg-transparent shadow-none focus-visible:ring-0 dark:bg-transparent", className) }, props)));
|
|
17929
|
+
});
|
|
17930
|
+
InputGroupInput.displayName = "InputGroupInput";
|
|
17931
|
+
const InputGroupTextarea = React.forwardRef((_a, ref) => {
|
|
17932
|
+
var { className } = _a, props = __rest$1(_a, ["className"]);
|
|
17933
|
+
return (jsx(Textarea, Object.assign({ ref: ref, "data-slot": "input-group-control", className: cn$1("flex-1 resize-none rounded-none border-0 bg-transparent py-3 shadow-none focus-visible:ring-0 dark:bg-transparent", className) }, props)));
|
|
17934
|
+
});
|
|
17935
|
+
InputGroupTextarea.displayName = "InputGroupTextarea";
|
|
17936
|
+
|
|
17503
17937
|
var Bt=Object.defineProperty,At=Object.defineProperties;var kt=Object.getOwnPropertyDescriptors;var Y=Object.getOwnPropertySymbols;var gt=Object.prototype.hasOwnProperty,Et=Object.prototype.propertyIsEnumerable;var vt=(r,s,e)=>s in r?Bt(r,s,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[s]=e,St=(r,s)=>{for(var e in s||(s={}))gt.call(s,e)&&vt(r,e,s[e]);if(Y)for(var e of Y(s))Et.call(s,e)&&vt(r,e,s[e]);return r},bt=(r,s)=>At(r,kt(s));var Pt=(r,s)=>{var e={};for(var u in r)gt.call(r,u)&&s.indexOf(u)<0&&(e[u]=r[u]);if(r!=null&&Y)for(var u of Y(r))s.indexOf(u)<0&&Et.call(r,u)&&(e[u]=r[u]);return e};function ht(r){let s=setTimeout(r,0),e=setTimeout(r,10),u=setTimeout(r,50);return [s,e,u]}function _t(r){let s=React.useRef();return React.useEffect(()=>{s.current=r;}),s.current}var Ot=18,wt=40,Gt=`${wt}px`,xt=["[data-lastpass-icon-root]","com-1password-button","[data-dashlanecreated]",'[style$="2147483647 !important;"]'].join(",");function Tt({containerRef:r,inputRef:s,pushPasswordManagerStrategy:e,isFocused:u}){let[P,D]=React.useState(!1),[G,H]=React.useState(!1),[F,W]=React.useState(!1),Z=React.useMemo(()=>e==="none"?!1:(e==="increase-width"||e==="experimental-no-flickering")&&P&&G,[P,G,e]),T=React.useCallback(()=>{let f=r.current,h=s.current;if(!f||!h||F||e==="none")return;let a=f,B=a.getBoundingClientRect().left+a.offsetWidth,A=a.getBoundingClientRect().top+a.offsetHeight/2,z=B-Ot,q=A;document.querySelectorAll(xt).length===0&&document.elementFromPoint(z,q)===f||(D(!0),W(!0));},[r,s,F,e]);return React.useEffect(()=>{let f=r.current;if(!f||e==="none")return;function h(){let A=window.innerWidth-f.getBoundingClientRect().right;H(A>=wt);}h();let a=setInterval(h,1e3);return ()=>{clearInterval(a);}},[r,e]),React.useEffect(()=>{let f=u||document.activeElement===s.current;if(e==="none"||!f)return;let h=setTimeout(T,0),a=setTimeout(T,2e3),B=setTimeout(T,5e3),A=setTimeout(()=>{W(!0);},6e3);return ()=>{clearTimeout(h),clearTimeout(a),clearTimeout(B),clearTimeout(A);}},[s,u,e,T]),{hasPWMBadge:P,willPushPWMBadge:Z,PWM_BADGE_SPACE_WIDTH:Gt}}var jt=React.createContext({}),Lt=React.forwardRef((A,B)=>{var z=A,{value:r,onChange:s,maxLength:e,textAlign:u="left",pattern:P,placeholder:D,inputMode:G="numeric",onComplete:H,pushPasswordManagerStrategy:F="increase-width",pasteTransformer:W,containerClassName:Z,noScriptCSSFallback:T=Nt,render:f,children:h}=z,a=Pt(z,["value","onChange","maxLength","textAlign","pattern","placeholder","inputMode","onComplete","pushPasswordManagerStrategy","pasteTransformer","containerClassName","noScriptCSSFallback","render","children"]);var X,lt,ut,dt,ft;let[q,nt]=React.useState(typeof a.defaultValue=="string"?a.defaultValue:""),i=r!=null?r:q,I=_t(i),x=React.useCallback(t=>{s==null||s(t),nt(t);},[s]),m=React.useMemo(()=>P?typeof P=="string"?new RegExp(P):P:null,[P]),l=React.useRef(null),K=React.useRef(null),J=React.useRef({value:i,onChange:x,isIOS:typeof window!="undefined"&&((lt=(X=window==null?void 0:window.CSS)==null?void 0:X.supports)==null?void 0:lt.call(X,"-webkit-touch-callout","none"))}),V=React.useRef({prev:[(ut=l.current)==null?void 0:ut.selectionStart,(dt=l.current)==null?void 0:dt.selectionEnd,(ft=l.current)==null?void 0:ft.selectionDirection]});React.useImperativeHandle(B,()=>l.current,[]),React.useEffect(()=>{let t=l.current,o=K.current;if(!t||!o)return;J.current.value!==t.value&&J.current.onChange(t.value),V.current.prev=[t.selectionStart,t.selectionEnd,t.selectionDirection];function d(){if(document.activeElement!==t){L(null),N(null);return}let c=t.selectionStart,b=t.selectionEnd,mt=t.selectionDirection,v=t.maxLength,C=t.value,_=V.current.prev,g=-1,E=-1,w;if(C.length!==0&&c!==null&&b!==null){let Dt=c===b,Ht=c===C.length&&C.length<v;if(Dt&&!Ht){let y=c;if(y===0)g=0,E=1,w="forward";else if(y===v)g=y-1,E=y,w="backward";else if(v>1&&C.length>1){let et=0;if(_[0]!==null&&_[1]!==null){w=y<_[1]?"backward":"forward";let Wt=_[0]===_[1]&&_[0]<v;w==="backward"&&!Wt&&(et=-1);}g=et+y,E=et+y+1;}}g!==-1&&E!==-1&&g!==E&&l.current.setSelectionRange(g,E,w);}let pt=g!==-1?g:c,Rt=E!==-1?E:b,yt=w!=null?w:mt;L(pt),N(Rt),V.current.prev=[pt,Rt,yt];}if(document.addEventListener("selectionchange",d,{capture:!0}),d(),document.activeElement===t&&Q(!0),!document.getElementById("input-otp-style")){let c=document.createElement("style");if(c.id="input-otp-style",document.head.appendChild(c),c.sheet){let b="background: transparent !important; color: transparent !important; border-color: transparent !important; opacity: 0 !important; box-shadow: none !important; -webkit-box-shadow: none !important; -webkit-text-fill-color: transparent !important;";$(c.sheet,"[data-input-otp]::selection { background: transparent !important; color: transparent !important; }"),$(c.sheet,`[data-input-otp]:autofill { ${b} }`),$(c.sheet,`[data-input-otp]:-webkit-autofill { ${b} }`),$(c.sheet,"@supports (-webkit-touch-callout: none) { [data-input-otp] { letter-spacing: -.6em !important; font-weight: 100 !important; font-stretch: ultra-condensed; font-optical-sizing: none !important; left: -1px !important; right: 1px !important; } }"),$(c.sheet,"[data-input-otp] + * { pointer-events: all !important; }");}}let p=()=>{o&&o.style.setProperty("--root-height",`${t.clientHeight}px`);};p();let R=new ResizeObserver(p);return R.observe(t),()=>{document.removeEventListener("selectionchange",d,{capture:!0}),R.disconnect();}},[]);let[ot,rt]=React.useState(!1),[j,Q]=React.useState(!1),[M,L]=React.useState(null),[k,N]=React.useState(null);React.useEffect(()=>{ht(()=>{var p,R,c,b;(p=l.current)==null||p.dispatchEvent(new Event("input"));let t=(R=l.current)==null?void 0:R.selectionStart,o=(c=l.current)==null?void 0:c.selectionEnd,d=(b=l.current)==null?void 0:b.selectionDirection;t!==null&&o!==null&&(L(t),N(o),V.current.prev=[t,o,d]);});},[i,j]),React.useEffect(()=>{I!==void 0&&i!==I&&I.length<e&&i.length===e&&(H==null||H(i));},[e,H,I,i]);let O=Tt({containerRef:K,inputRef:l,pushPasswordManagerStrategy:F,isFocused:j}),st=React.useCallback(t=>{let o=t.currentTarget.value.slice(0,e);if(o.length>0&&m&&!m.test(o)){t.preventDefault();return}typeof I=="string"&&o.length<I.length&&document.dispatchEvent(new Event("selectionchange")),x(o);},[e,x,I,m]),at=React.useCallback(()=>{var t;if(l.current){let o=Math.min(l.current.value.length,e-1),d=l.current.value.length;(t=l.current)==null||t.setSelectionRange(o,d),L(o),N(d);}Q(!0);},[e]),ct=React.useCallback(t=>{var g,E;let o=l.current;if(!W&&(!J.current.isIOS||!t.clipboardData||!o))return;let d=t.clipboardData.getData("text/plain"),p=W?W(d):d;console.log({_content:d,content:p}),t.preventDefault();let R=(g=l.current)==null?void 0:g.selectionStart,c=(E=l.current)==null?void 0:E.selectionEnd,v=(R!==c?i.slice(0,R)+p+i.slice(c):i.slice(0,R)+p+i.slice(R)).slice(0,e);if(v.length>0&&m&&!m.test(v))return;o.value=v,x(v);let C=Math.min(v.length,e-1),_=v.length;o.setSelectionRange(C,_),L(C),N(_);},[e,x,m,i]),It=React.useMemo(()=>({position:"relative",cursor:a.disabled?"default":"text",userSelect:"none",WebkitUserSelect:"none",pointerEvents:"none"}),[a.disabled]),it=React.useMemo(()=>({position:"absolute",inset:0,width:O.willPushPWMBadge?`calc(100% + ${O.PWM_BADGE_SPACE_WIDTH})`:"100%",clipPath:O.willPushPWMBadge?`inset(0 ${O.PWM_BADGE_SPACE_WIDTH} 0 0)`:void 0,height:"100%",display:"flex",textAlign:u,opacity:"1",color:"transparent",pointerEvents:"all",background:"transparent",caretColor:"transparent",border:"0 solid transparent",outline:"0 solid transparent",boxShadow:"none",lineHeight:"1",letterSpacing:"-.5em",fontSize:"var(--root-height)",fontFamily:"monospace",fontVariantNumeric:"tabular-nums"}),[O.PWM_BADGE_SPACE_WIDTH,O.willPushPWMBadge,u]),Mt=React.useMemo(()=>React.createElement("input",bt(St({autoComplete:a.autoComplete||"one-time-code"},a),{"data-input-otp":!0,"data-input-otp-placeholder-shown":i.length===0||void 0,"data-input-otp-mss":M,"data-input-otp-mse":k,inputMode:G,pattern:m==null?void 0:m.source,"aria-placeholder":D,style:it,maxLength:e,value:i,ref:l,onPaste:t=>{var o;ct(t),(o=a.onPaste)==null||o.call(a,t);},onChange:st,onMouseOver:t=>{var o;rt(!0),(o=a.onMouseOver)==null||o.call(a,t);},onMouseLeave:t=>{var o;rt(!1),(o=a.onMouseLeave)==null||o.call(a,t);},onFocus:t=>{var o;at(),(o=a.onFocus)==null||o.call(a,t);},onBlur:t=>{var o;Q(!1),(o=a.onBlur)==null||o.call(a,t);}})),[st,at,ct,G,it,e,k,M,a,m==null?void 0:m.source,i]),tt=React.useMemo(()=>({slots:Array.from({length:e}).map((t,o)=>{var c;let d=j&&M!==null&&k!==null&&(M===k&&o===M||o>=M&&o<k),p=i[o]!==void 0?i[o]:null,R=i[0]!==void 0?null:(c=D==null?void 0:D[o])!=null?c:null;return {char:p,placeholderChar:R,isActive:d,hasFakeCaret:d&&p===null}}),isFocused:j,isHovering:!a.disabled&&ot}),[j,ot,e,k,M,a.disabled,i]),Ct=React.useMemo(()=>f?f(tt):React.createElement(jt.Provider,{value:tt},h),[h,tt,f]);return React.createElement(React.Fragment,null,T!==null&&React.createElement("noscript",null,React.createElement("style",null,T)),React.createElement("div",{ref:K,"data-input-otp-container":!0,style:It,className:Z},Ct,React.createElement("div",{style:{position:"absolute",inset:0,pointerEvents:"none"}},Mt)))});Lt.displayName="Input";function $(r,s){try{r.insertRule(s);}catch(e){console.error("input-otp could not insert CSS rule:",s);}}var Nt=`
|
|
17504
17938
|
[data-input-otp] {
|
|
17505
17939
|
--nojs-bg: white !important;
|
|
@@ -18415,6 +18849,82 @@ const PaginationEllipsis = (_a) => {
|
|
|
18415
18849
|
return (jsxs("span", Object.assign({ "aria-hidden": true, className: cn$1("flex h-9 w-9 items-center justify-center", className) }, props, { children: [jsx(DotsHorizontalIcon, { className: "h-4 w-4" }), jsx("span", Object.assign({ className: "sr-only" }, { children: "More pages" }))] })));
|
|
18416
18850
|
};
|
|
18417
18851
|
|
|
18852
|
+
/* -------------------------------------------------------------------------------------------------
|
|
18853
|
+
* Slot
|
|
18854
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$2 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
18855
|
+
const { children: children , ...slotProps } = props;
|
|
18856
|
+
const childrenArray = Children.toArray(children);
|
|
18857
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$2);
|
|
18858
|
+
if (slottable) {
|
|
18859
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
18860
|
+
const newElement = slottable.props.children;
|
|
18861
|
+
const newChildren = childrenArray.map((child)=>{
|
|
18862
|
+
if (child === slottable) {
|
|
18863
|
+
// because the new element will be the one rendered, we are only interested
|
|
18864
|
+
// in grabbing its children (`newElement.props.children`)
|
|
18865
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
18866
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
18867
|
+
} else return child;
|
|
18868
|
+
});
|
|
18869
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$2, _extends({}, slotProps, {
|
|
18870
|
+
ref: forwardedRef
|
|
18871
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
18872
|
+
}
|
|
18873
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$2, _extends({}, slotProps, {
|
|
18874
|
+
ref: forwardedRef
|
|
18875
|
+
}), children);
|
|
18876
|
+
});
|
|
18877
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$2.displayName = 'Slot';
|
|
18878
|
+
/* -------------------------------------------------------------------------------------------------
|
|
18879
|
+
* SlotClone
|
|
18880
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$2 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
18881
|
+
const { children: children , ...slotProps } = props;
|
|
18882
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
18883
|
+
...$5e63c961fc1ce211$var$mergeProps$2(slotProps, children.props),
|
|
18884
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
18885
|
+
});
|
|
18886
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
18887
|
+
});
|
|
18888
|
+
$5e63c961fc1ce211$var$SlotClone$2.displayName = 'SlotClone';
|
|
18889
|
+
/* -------------------------------------------------------------------------------------------------
|
|
18890
|
+
* Slottable
|
|
18891
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$2 = ({ children: children })=>{
|
|
18892
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
18893
|
+
};
|
|
18894
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$2(child) {
|
|
18895
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$2;
|
|
18896
|
+
}
|
|
18897
|
+
function $5e63c961fc1ce211$var$mergeProps$2(slotProps, childProps) {
|
|
18898
|
+
// all child props should override
|
|
18899
|
+
const overrideProps = {
|
|
18900
|
+
...childProps
|
|
18901
|
+
};
|
|
18902
|
+
for(const propName in childProps){
|
|
18903
|
+
const slotPropValue = slotProps[propName];
|
|
18904
|
+
const childPropValue = childProps[propName];
|
|
18905
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
18906
|
+
if (isHandler) {
|
|
18907
|
+
// if the handler exists on both, we compose them
|
|
18908
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
18909
|
+
childPropValue(...args);
|
|
18910
|
+
slotPropValue(...args);
|
|
18911
|
+
};
|
|
18912
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
18913
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
18914
|
+
...slotPropValue,
|
|
18915
|
+
...childPropValue
|
|
18916
|
+
};
|
|
18917
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
18918
|
+
slotPropValue,
|
|
18919
|
+
childPropValue
|
|
18920
|
+
].filter(Boolean).join(' ');
|
|
18921
|
+
}
|
|
18922
|
+
return {
|
|
18923
|
+
...slotProps,
|
|
18924
|
+
...overrideProps
|
|
18925
|
+
};
|
|
18926
|
+
}
|
|
18927
|
+
|
|
18418
18928
|
/* -------------------------------------------------------------------------------------------------
|
|
18419
18929
|
* Popover
|
|
18420
18930
|
* -----------------------------------------------------------------------------------------------*/ const $cb5cc270b50c6fcd$var$POPOVER_NAME = 'Popover';
|
|
@@ -18518,7 +19028,7 @@ const $cb5cc270b50c6fcd$export$d7e1f420b25549ff = /*#__PURE__*/ forwardRef((prop
|
|
|
18518
19028
|
if (content) return hideOthers(content);
|
|
18519
19029
|
}, []);
|
|
18520
19030
|
return /*#__PURE__*/ createElement(ReactRemoveScroll, {
|
|
18521
|
-
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$
|
|
19031
|
+
as: $5e63c961fc1ce211$export$8c6ed5c666ac1360$2,
|
|
18522
19032
|
allowPinchZoom: true
|
|
18523
19033
|
}, /*#__PURE__*/ createElement($cb5cc270b50c6fcd$var$PopoverContentImpl, _extends({}, props, {
|
|
18524
19034
|
ref: composedRefs // we make sure we're not trapping once it's been closed
|
|
@@ -20058,6 +20568,82 @@ function $ae6933e535247d3d$export$7d15b64cf5a3a4c4(value, [min, max]) {
|
|
|
20058
20568
|
return Math.min(max, Math.max(min, value));
|
|
20059
20569
|
}
|
|
20060
20570
|
|
|
20571
|
+
/* -------------------------------------------------------------------------------------------------
|
|
20572
|
+
* Slot
|
|
20573
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360$1 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
20574
|
+
const { children: children , ...slotProps } = props;
|
|
20575
|
+
const childrenArray = Children.toArray(children);
|
|
20576
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable$1);
|
|
20577
|
+
if (slottable) {
|
|
20578
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
20579
|
+
const newElement = slottable.props.children;
|
|
20580
|
+
const newChildren = childrenArray.map((child)=>{
|
|
20581
|
+
if (child === slottable) {
|
|
20582
|
+
// because the new element will be the one rendered, we are only interested
|
|
20583
|
+
// in grabbing its children (`newElement.props.children`)
|
|
20584
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
20585
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
20586
|
+
} else return child;
|
|
20587
|
+
});
|
|
20588
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$1, _extends({}, slotProps, {
|
|
20589
|
+
ref: forwardedRef
|
|
20590
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
20591
|
+
}
|
|
20592
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone$1, _extends({}, slotProps, {
|
|
20593
|
+
ref: forwardedRef
|
|
20594
|
+
}), children);
|
|
20595
|
+
});
|
|
20596
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360$1.displayName = 'Slot';
|
|
20597
|
+
/* -------------------------------------------------------------------------------------------------
|
|
20598
|
+
* SlotClone
|
|
20599
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone$1 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
20600
|
+
const { children: children , ...slotProps } = props;
|
|
20601
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
20602
|
+
...$5e63c961fc1ce211$var$mergeProps$1(slotProps, children.props),
|
|
20603
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
20604
|
+
});
|
|
20605
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
20606
|
+
});
|
|
20607
|
+
$5e63c961fc1ce211$var$SlotClone$1.displayName = 'SlotClone';
|
|
20608
|
+
/* -------------------------------------------------------------------------------------------------
|
|
20609
|
+
* Slottable
|
|
20610
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$1 = ({ children: children })=>{
|
|
20611
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
20612
|
+
};
|
|
20613
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable$1(child) {
|
|
20614
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45$1;
|
|
20615
|
+
}
|
|
20616
|
+
function $5e63c961fc1ce211$var$mergeProps$1(slotProps, childProps) {
|
|
20617
|
+
// all child props should override
|
|
20618
|
+
const overrideProps = {
|
|
20619
|
+
...childProps
|
|
20620
|
+
};
|
|
20621
|
+
for(const propName in childProps){
|
|
20622
|
+
const slotPropValue = slotProps[propName];
|
|
20623
|
+
const childPropValue = childProps[propName];
|
|
20624
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
20625
|
+
if (isHandler) {
|
|
20626
|
+
// if the handler exists on both, we compose them
|
|
20627
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
20628
|
+
childPropValue(...args);
|
|
20629
|
+
slotPropValue(...args);
|
|
20630
|
+
};
|
|
20631
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
20632
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
20633
|
+
...slotPropValue,
|
|
20634
|
+
...childPropValue
|
|
20635
|
+
};
|
|
20636
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
20637
|
+
slotPropValue,
|
|
20638
|
+
childPropValue
|
|
20639
|
+
].filter(Boolean).join(' ');
|
|
20640
|
+
}
|
|
20641
|
+
return {
|
|
20642
|
+
...slotProps,
|
|
20643
|
+
...overrideProps
|
|
20644
|
+
};
|
|
20645
|
+
}
|
|
20646
|
+
|
|
20061
20647
|
const $cc7e05a45900e73f$var$OPEN_KEYS = [
|
|
20062
20648
|
' ',
|
|
20063
20649
|
'Enter',
|
|
@@ -22830,12 +23416,6 @@ const TabsContent = React.forwardRef((_a, ref) => {
|
|
|
22830
23416
|
});
|
|
22831
23417
|
TabsContent.displayName = $69cb30bb0017df05$export$7c6e2c02157bb7d2.displayName;
|
|
22832
23418
|
|
|
22833
|
-
const Textarea = React.forwardRef((_a, ref) => {
|
|
22834
|
-
var { className } = _a, props = __rest$1(_a, ["className"]);
|
|
22835
|
-
return (jsx("textarea", Object.assign({ className: cn$1("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50", className), ref: ref }, props)));
|
|
22836
|
-
});
|
|
22837
|
-
Textarea.displayName = "Textarea";
|
|
22838
|
-
|
|
22839
23419
|
const $b3bbe2732c13b576$export$bea8ebba691c5813 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
22840
23420
|
const { pressed: pressedProp , defaultPressed: defaultPressed = false , onPressedChange: onPressedChange , ...buttonProps } = props;
|
|
22841
23421
|
const [pressed = false, setPressed] = $71cd76cc60e0454e$export$6f32135080cb4c3$1({
|
|
@@ -23049,6 +23629,82 @@ const ToggleGroupItem = React.forwardRef((_a, ref) => {
|
|
|
23049
23629
|
});
|
|
23050
23630
|
ToggleGroupItem.displayName = $6c1fd9e6a8969628$export$6d08773d2e66f8f2.displayName;
|
|
23051
23631
|
|
|
23632
|
+
/* -------------------------------------------------------------------------------------------------
|
|
23633
|
+
* Slot
|
|
23634
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
23635
|
+
const { children: children , ...slotProps } = props;
|
|
23636
|
+
const childrenArray = Children.toArray(children);
|
|
23637
|
+
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable);
|
|
23638
|
+
if (slottable) {
|
|
23639
|
+
// the new element to render is the one passed as a child of `Slottable`
|
|
23640
|
+
const newElement = slottable.props.children;
|
|
23641
|
+
const newChildren = childrenArray.map((child)=>{
|
|
23642
|
+
if (child === slottable) {
|
|
23643
|
+
// because the new element will be the one rendered, we are only interested
|
|
23644
|
+
// in grabbing its children (`newElement.props.children`)
|
|
23645
|
+
if (Children.count(newElement) > 1) return Children.only(null);
|
|
23646
|
+
return /*#__PURE__*/ isValidElement(newElement) ? newElement.props.children : null;
|
|
23647
|
+
} else return child;
|
|
23648
|
+
});
|
|
23649
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone, _extends({}, slotProps, {
|
|
23650
|
+
ref: forwardedRef
|
|
23651
|
+
}), /*#__PURE__*/ isValidElement(newElement) ? /*#__PURE__*/ cloneElement(newElement, undefined, newChildren) : null);
|
|
23652
|
+
}
|
|
23653
|
+
return /*#__PURE__*/ createElement($5e63c961fc1ce211$var$SlotClone, _extends({}, slotProps, {
|
|
23654
|
+
ref: forwardedRef
|
|
23655
|
+
}), children);
|
|
23656
|
+
});
|
|
23657
|
+
$5e63c961fc1ce211$export$8c6ed5c666ac1360.displayName = 'Slot';
|
|
23658
|
+
/* -------------------------------------------------------------------------------------------------
|
|
23659
|
+
* SlotClone
|
|
23660
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
|
|
23661
|
+
const { children: children , ...slotProps } = props;
|
|
23662
|
+
if (/*#__PURE__*/ isValidElement(children)) return /*#__PURE__*/ cloneElement(children, {
|
|
23663
|
+
...$5e63c961fc1ce211$var$mergeProps(slotProps, children.props),
|
|
23664
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af$1(forwardedRef, children.ref) : children.ref
|
|
23665
|
+
});
|
|
23666
|
+
return Children.count(children) > 1 ? Children.only(null) : null;
|
|
23667
|
+
});
|
|
23668
|
+
$5e63c961fc1ce211$var$SlotClone.displayName = 'SlotClone';
|
|
23669
|
+
/* -------------------------------------------------------------------------------------------------
|
|
23670
|
+
* Slottable
|
|
23671
|
+
* -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 = ({ children: children })=>{
|
|
23672
|
+
return /*#__PURE__*/ createElement(Fragment$1, null, children);
|
|
23673
|
+
};
|
|
23674
|
+
/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable(child) {
|
|
23675
|
+
return /*#__PURE__*/ isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45;
|
|
23676
|
+
}
|
|
23677
|
+
function $5e63c961fc1ce211$var$mergeProps(slotProps, childProps) {
|
|
23678
|
+
// all child props should override
|
|
23679
|
+
const overrideProps = {
|
|
23680
|
+
...childProps
|
|
23681
|
+
};
|
|
23682
|
+
for(const propName in childProps){
|
|
23683
|
+
const slotPropValue = slotProps[propName];
|
|
23684
|
+
const childPropValue = childProps[propName];
|
|
23685
|
+
const isHandler = /^on[A-Z]/.test(propName);
|
|
23686
|
+
if (isHandler) {
|
|
23687
|
+
// if the handler exists on both, we compose them
|
|
23688
|
+
if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{
|
|
23689
|
+
childPropValue(...args);
|
|
23690
|
+
slotPropValue(...args);
|
|
23691
|
+
};
|
|
23692
|
+
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
23693
|
+
} else if (propName === 'style') overrideProps[propName] = {
|
|
23694
|
+
...slotPropValue,
|
|
23695
|
+
...childPropValue
|
|
23696
|
+
};
|
|
23697
|
+
else if (propName === 'className') overrideProps[propName] = [
|
|
23698
|
+
slotPropValue,
|
|
23699
|
+
childPropValue
|
|
23700
|
+
].filter(Boolean).join(' ');
|
|
23701
|
+
}
|
|
23702
|
+
return {
|
|
23703
|
+
...slotProps,
|
|
23704
|
+
...overrideProps
|
|
23705
|
+
};
|
|
23706
|
+
}
|
|
23707
|
+
|
|
23052
23708
|
const [$a093c7e1ec25a057$var$createTooltipContext, $a093c7e1ec25a057$export$1c540a2224f0d865] = $c512c27ab02ef895$export$50c7b4e9d9f19c1$1('Tooltip', [
|
|
23053
23709
|
$cf1ac5d9fe0e8206$export$722aac194ae923
|
|
23054
23710
|
]);
|
|
@@ -23397,7 +24053,7 @@ const $a093c7e1ec25a057$var$TooltipContentImpl = /*#__PURE__*/ forwardRef((props
|
|
|
23397
24053
|
'--radix-tooltip-trigger-width': 'var(--radix-popper-anchor-width)',
|
|
23398
24054
|
'--radix-tooltip-trigger-height': 'var(--radix-popper-anchor-height)'
|
|
23399
24055
|
}
|
|
23400
|
-
}), /*#__PURE__*/ createElement($5e63c961fc1ce211$export$d9f1ccf0bdb05d45
|
|
24056
|
+
}), /*#__PURE__*/ createElement($5e63c961fc1ce211$export$d9f1ccf0bdb05d45, null, children), /*#__PURE__*/ createElement($a093c7e1ec25a057$var$VisuallyHiddenContentContextProvider, {
|
|
23401
24057
|
scope: __scopeTooltip,
|
|
23402
24058
|
isInside: true
|
|
23403
24059
|
}, /*#__PURE__*/ createElement($ea1ef594cf570d83$export$be92b6f5f03c0fe9, {
|
|
@@ -23644,4 +24300,4 @@ const tailwindTheme = {
|
|
|
23644
24300
|
plugins: [animate, typography],
|
|
23645
24301
|
};
|
|
23646
24302
|
|
|
23647
|
-
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertTitle, Avatar, AvatarFallback, AvatarImage, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button$1 as Button, Calendar, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Checkbox, CodeCopy, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Footer$1 as DocsFooter, DocsHeaderLeft, DocsHeaderRight, DocsHeaderSubtitle, DocsHeaderTitle, DocsHeaderWrapper, HelpCard as DocsHelpCard, NavBar as DocsNavBar, DocsPageLayout, TripleCard as DocsTripleCard, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HoverCard, HoverCardContent, HoverCardTrigger, Input, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Label, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverContent, PopoverTrigger, Progress, RadioGroup, RadioGroupItem, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, SlideIn, SonnerToast, StatusIconCancelled, StatusIconError, StatusIconQueued, StatusIconRetrying, StatusIconSubmitted, StatusIconSuccess, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeSelector, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, badgeVariants, buttonVariants, cn$1 as cn, getTheme, navigationMenuTriggerStyle, setTheme, index as sonner, subscribeToTheme, tailwindTheme, useTheme };
|
|
24303
|
+
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertTitle, Avatar, AvatarFallback, AvatarImage, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button$1 as Button, Calendar, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Checkbox, CodeCopy, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Footer$1 as DocsFooter, DocsHeaderLeft, DocsHeaderRight, DocsHeaderSubtitle, DocsHeaderTitle, DocsHeaderWrapper, HelpCard as DocsHelpCard, NavBar as DocsNavBar, DocsPageLayout, TripleCard as DocsTripleCard, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, ExactMatchIcon, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HoverCard, HoverCardContent, HoverCardTrigger, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Label, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverContent, PopoverTrigger, Progress, RadioGroup, RadioGroupItem, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, SlideIn, SonnerToast, StatusIconCancelled, StatusIconError, StatusIconQueued, StatusIconRetrying, StatusIconSubmitted, StatusIconSuccess, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeSelector, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, badgeVariants, buttonVariants, cn$1 as cn, getTheme, navigationMenuTriggerStyle, setTheme, index as sonner, subscribeToTheme, tailwindTheme, useTheme };
|