@jerry-fd/ui 0.5.4 → 0.5.5
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/antd-data-filter.js +1 -1
- package/chunk-PICBT6ES.js +2 -0
- package/chunk-U66T3F2Z.js +1 -0
- package/data-table.js +2 -2
- package/index.d.ts +103 -58
- package/index.js +2 -2
- package/package.json +1 -1
- package/styles/index.css +1 -1
- package/theme/typography.css +14 -14
- package/chunk-AIVCLPYT.js +0 -2
- package/chunk-ALNSID3D.js +0 -1
package/index.d.ts
CHANGED
|
@@ -1602,7 +1602,6 @@ type AnimationCardProps = {
|
|
|
1602
1602
|
variants?: Variants;
|
|
1603
1603
|
transition?: Transition;
|
|
1604
1604
|
rootTransition?: Transition;
|
|
1605
|
-
lazy?: boolean;
|
|
1606
1605
|
} & ({
|
|
1607
1606
|
initialKey: React$1.Key;
|
|
1608
1607
|
defaultCardHeight: number;
|
|
@@ -1610,67 +1609,113 @@ type AnimationCardProps = {
|
|
|
1610
1609
|
initialKey?: never;
|
|
1611
1610
|
defaultCardHeight?: never;
|
|
1612
1611
|
});
|
|
1613
|
-
declare function AnimationCard({ activeKey, children, className, rootClassName, defaultCardHeight, initialKey, variants, transition, rootTransition,
|
|
1612
|
+
declare function AnimationCard({ activeKey, children, className, rootClassName, defaultCardHeight, initialKey, variants, transition, rootTransition, }: AnimationCardProps): react_jsx_runtime.JSX.Element;
|
|
1614
1613
|
|
|
1615
|
-
|
|
1616
|
-
type
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
* 使用 renderCount 时,必须是从 0 开始的连续整数(0 ~ renderCount-1),直接对应 DOM 子节点下标。
|
|
1621
|
-
* 不使用 renderCount 时,可以是任意数字。
|
|
1622
|
-
*/
|
|
1614
|
+
/** Built-in motion presets supported by UIViewTransition. */
|
|
1615
|
+
type AnimationName$1 = 'slide' | 'slideVertical' | 'slideLayers' | 'reveal' | 'pushSlide' | 'zoomFade';
|
|
1616
|
+
/** `UIScreen` 底层使用的视图过渡容器。 */
|
|
1617
|
+
type UIViewTransitionProps = {
|
|
1618
|
+
/** 当前视图的数值标识,用于推导切换方向并缓存对应高度。 */
|
|
1623
1619
|
activeKey: number;
|
|
1624
|
-
/**
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
* 而无需等待 activeKey 切换后再挂载新内容。
|
|
1628
|
-
* 与 activeKey 使用相同的 key 空间,使用 renderCount 时同样须从 0 开始。
|
|
1629
|
-
*/
|
|
1630
|
-
nextKey?: number;
|
|
1631
|
-
name: AnimationName;
|
|
1632
|
-
direction?: 'auto' | 'inverse' | 1 | -1;
|
|
1633
|
-
/**
|
|
1634
|
-
* 固定渲染的面板数量,用于 Tab 等数量固定的场景。
|
|
1635
|
-
* 传入后,activeKey 会被当作从 0 开始的直接下标,所有面板始终保留在 DOM 中(非活跃项 display:none)。
|
|
1636
|
-
* 不传时,activeKey 是任意数字,切换后只保留前后两帧缓存,其余内容会被清理。
|
|
1637
|
-
*/
|
|
1638
|
-
renderCount?: number;
|
|
1639
|
-
shouldRestoreHeight?: boolean;
|
|
1640
|
-
/**
|
|
1641
|
-
* 动画结束后是否卸载非活跃面板。
|
|
1642
|
-
* false(默认):旧面板保留在 DOM 中(display:none),切回时不重新挂载,状态得以保留。
|
|
1643
|
-
* true:动画结束后旧面板从 DOM 卸载,释放内存,但切回时状态丢失。
|
|
1644
|
-
* 可配合 cleanupExceptionKey / cleanupOnlyKey 精细控制保留或删除哪些面板。
|
|
1645
|
-
*/
|
|
1646
|
-
shouldCleanup?: boolean;
|
|
1647
|
-
/**
|
|
1648
|
-
* 是否开启后层变暗效果(仅对 pushSlide / slideLayers 有效)。
|
|
1649
|
-
* 开启后,容器背景变为黑色,每个面板强制白色背景;动画期间后面的面板 opacity 渐变至 0.5,
|
|
1650
|
-
* 产生类似 iOS push/pop 时的灰色遮罩效果。
|
|
1651
|
-
*/
|
|
1652
|
-
shouldDimBehind?: boolean;
|
|
1653
|
-
/** 清理时保留该 key 对应的面板,其余全部卸载。需配合 shouldCleanup 使用。使用 renderCount 时须从 0 开始。 */
|
|
1654
|
-
cleanupExceptionKey?: number;
|
|
1655
|
-
/** 清理时仅卸载该 key 对应的面板,其余保留。需配合 shouldCleanup 使用。使用 renderCount 时须从 0 开始。 */
|
|
1656
|
-
cleanupOnlyKey?: number;
|
|
1657
|
-
/**
|
|
1658
|
-
* 是否为每个面板包裹一层额外的 <div>。用于异步组件(React.lazy)场景:
|
|
1659
|
-
* 异步组件在首次动画期间可能重新挂载,导致 DOM 节点变化、动画 class 位置错乱。
|
|
1660
|
-
* 开启后,外层稳定的 div 承载动画 class,内部组件的重挂载不影响动画执行。
|
|
1661
|
-
*/
|
|
1662
|
-
shouldWrap?: boolean;
|
|
1663
|
-
/** shouldWrap 为 true 时,跳过对该 key 面板的包裹(用于同一 Transition 中的同步组件)。使用 renderCount 时须从 0 开始。 */
|
|
1664
|
-
wrapExceptionKey?: number;
|
|
1665
|
-
id?: string;
|
|
1620
|
+
/** 当前切换使用的动画名称。 */
|
|
1621
|
+
animation?: AnimationName$1;
|
|
1622
|
+
/** 应用在最外层过渡容器上的类名。 */
|
|
1666
1623
|
className?: string;
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1624
|
+
/** 应用在实际动画视图层上的类名。 */
|
|
1625
|
+
viewClassName?: string;
|
|
1626
|
+
children: React__default.ReactNode;
|
|
1627
|
+
/** 是否让退出视图变暗,仅对支持该效果的动画生效。 */
|
|
1628
|
+
dimmed?: boolean;
|
|
1671
1629
|
};
|
|
1630
|
+
declare function UIViewTransition({ activeKey, animation, dimmed, className, viewClassName, children, }: UIViewTransitionProps): react_jsx_runtime.JSX.Element;
|
|
1672
1631
|
|
|
1673
|
-
|
|
1632
|
+
type UIMorphingModalLength = number | string;
|
|
1633
|
+
type UIMorphingModalExpandedSize = {
|
|
1634
|
+
width: UIMorphingModalLength;
|
|
1635
|
+
height: UIMorphingModalLength;
|
|
1636
|
+
};
|
|
1637
|
+
type UIMorphingModalContentAnimationState = 'entered' | 'exited';
|
|
1638
|
+
type UIMorphingModalProps = {
|
|
1639
|
+
/** 是否打开弹窗 */
|
|
1640
|
+
open?: boolean;
|
|
1641
|
+
/** 是否处于加载中;加载结束后会从默认尺寸展开 */
|
|
1642
|
+
loading?: boolean;
|
|
1643
|
+
/** 弹窗打开时,需要缩放的背景视图节点 */
|
|
1644
|
+
backgroundViewRef?: React$1.RefObject<HTMLElement | null>;
|
|
1645
|
+
/** 弹窗展开后显示的内容 */
|
|
1646
|
+
children?: React$1.ReactNode;
|
|
1647
|
+
/** 透传给弹窗内容容器的类名 */
|
|
1648
|
+
className?: string;
|
|
1649
|
+
containerClassName?: string;
|
|
1650
|
+
/** 始终显示在弹窗中的视觉锚点内容 */
|
|
1651
|
+
visual?: React$1.ReactNode;
|
|
1652
|
+
/** 弹窗默认的紧凑尺寸 */
|
|
1653
|
+
defaultSize?: UIMorphingModalLength;
|
|
1654
|
+
/** 弹窗展开后的宽高 */
|
|
1655
|
+
expandedSize?: UIMorphingModalExpandedSize;
|
|
1656
|
+
/** 预留的确认回调 */
|
|
1657
|
+
onOk?: () => void;
|
|
1658
|
+
/** 关闭动画完成后的回调 */
|
|
1659
|
+
onCloseComplete?: () => void;
|
|
1660
|
+
/** 内容显隐动画完成后的回调 */
|
|
1661
|
+
onContentAnimationComplete?: (state: UIMorphingModalContentAnimationState) => void;
|
|
1662
|
+
/** 尺寸展开状态变化动画完成后的回调 */
|
|
1663
|
+
onExpandedChangeComplete?: (expanded: boolean) => void;
|
|
1664
|
+
};
|
|
1665
|
+
declare function UIMorphingModal({ open, loading, visual, backgroundViewRef, children, className, containerClassName, defaultSize, expandedSize, onCloseComplete, onContentAnimationComplete, onExpandedChangeComplete, }: UIMorphingModalProps): react_jsx_runtime.JSX.Element;
|
|
1666
|
+
|
|
1667
|
+
/** Allowed screen identifier type for UIScreen. */
|
|
1668
|
+
type UIScreenValue = string | number;
|
|
1669
|
+
type AnimationName = NonNullable<UIViewTransitionProps['animation']>;
|
|
1670
|
+
/** One-off overrides for a single navigation. */
|
|
1671
|
+
type UIScreenNavigateOptions = {
|
|
1672
|
+
/** Overrides the animation used by the next navigation only. */
|
|
1673
|
+
animation?: AnimationName;
|
|
1674
|
+
};
|
|
1675
|
+
/**
|
|
1676
|
+
* `useUIScreen` 暴露的导航函数。
|
|
1677
|
+
*
|
|
1678
|
+
* @example
|
|
1679
|
+
* ```tsx
|
|
1680
|
+
* const { navigate } = useUIScreen<PageKey>();
|
|
1681
|
+
*
|
|
1682
|
+
* navigate(Page.Detail);
|
|
1683
|
+
* navigate(Page.Confirm, { animation: 'pushSlide' });
|
|
1684
|
+
* ```
|
|
1685
|
+
*/
|
|
1686
|
+
type UIScreenNavigateFn<T extends UIScreenValue = UIScreenValue> = (screen: T, options?: UIScreenNavigateOptions) => void;
|
|
1687
|
+
/** Current UIScreen state and navigation helpers. */
|
|
1688
|
+
type UIScreenControls<T extends UIScreenValue = UIScreenValue> = {
|
|
1689
|
+
/** 当前激活的 screen。 */
|
|
1690
|
+
screen: T;
|
|
1691
|
+
/** 导航到指定 screen,可按次覆盖本次切换动画。 */
|
|
1692
|
+
navigate: UIScreenNavigateFn<T>;
|
|
1693
|
+
};
|
|
1694
|
+
declare function useUIScreen<T extends UIScreenValue = UIScreenValue>(): UIScreenControls<T>;
|
|
1695
|
+
/** 声明 `UIScreen` 中的一个可切换视图。 */
|
|
1696
|
+
type UIScreenViewProps<T extends UIScreenValue = UIScreenValue> = {
|
|
1697
|
+
/** 当前视图的唯一标识,同时也用于按声明顺序推导切换方向。 */
|
|
1698
|
+
value: T;
|
|
1699
|
+
/** 进入当前视图时使用的动画,优先级高于 `UIScreen` 的默认动画。 */
|
|
1700
|
+
animation?: AnimationName;
|
|
1701
|
+
/** 应用在当前视图动画包裹层上的类名。 */
|
|
1702
|
+
className?: string;
|
|
1703
|
+
children: React__default.ReactNode;
|
|
1704
|
+
};
|
|
1705
|
+
/** Props for the high-level screen switcher built on top of UIViewTransition. */
|
|
1706
|
+
type UIScreenProps<T extends UIScreenValue = UIScreenValue> = Omit<UIViewTransitionProps, 'activeKey' | 'children'> & {
|
|
1707
|
+
/** Controlled active screen. Cannot be used together with defaultScreen. */
|
|
1708
|
+
screen?: T;
|
|
1709
|
+
/** Initial screen for uncontrolled usage. */
|
|
1710
|
+
defaultScreen?: T;
|
|
1711
|
+
/** Called whenever navigation requests a different screen. */
|
|
1712
|
+
onScreenChange?: (screen: T) => void;
|
|
1713
|
+
children: React__default.ReactNode;
|
|
1714
|
+
};
|
|
1715
|
+
type UIScreenComponent = (<T extends UIScreenValue>(props: UIScreenProps<T>) => React__default.ReactElement) & {
|
|
1716
|
+
View: <T extends UIScreenValue>(props: UIScreenViewProps<T>) => React__default.ReactElement;
|
|
1717
|
+
};
|
|
1718
|
+
declare const UIScreen: UIScreenComponent;
|
|
1674
1719
|
|
|
1675
1720
|
declare const useForceUpdate: () => () => void;
|
|
1676
1721
|
|
|
@@ -1684,4 +1729,4 @@ declare const useFlag: (initial?: boolean) => [boolean, NoneToVoidFunction, None
|
|
|
1684
1729
|
|
|
1685
1730
|
declare const useToggle: (initial?: boolean) => [boolean, NoneToVoidFunction];
|
|
1686
1731
|
|
|
1687
|
-
export { AnimationCard, type AnimationCardProps, index as Avatar, Badge, type BadgeProps, ButtonSharedProps, card as Card, Collapsible, CollapsibleContent, CollapsibleTrigger, ColorPanel, command as Command, CopyableText, type CopyableTextProps, type DebouncedFunction, Drawer, type DrawerProps, DropdownMenu, type DropdownMenuItemProps, type DropdownMenuProps, type DropdownMenuVariants, HoverCard, type MenuPropBase, PopConfirm, type PopConfirmProps, popover as Popover, PopoverPreset, type PopoverPresetProps, type Scheduler, ScrollArea, Skeleton, Spinner, StateSwitcher, Swap, Switch, tabs as Tabs, type ThrottledFunction, Tooltip, TooltipArrow, TooltipProvider, TooltipRoot, TooltipTrigger, UIProvider,
|
|
1732
|
+
export { AnimationCard, type AnimationCardProps, type AnimationName$1 as AnimationName, index as Avatar, Badge, type BadgeProps, ButtonSharedProps, card as Card, Collapsible, CollapsibleContent, CollapsibleTrigger, ColorPanel, command as Command, CopyableText, type CopyableTextProps, type DebouncedFunction, Drawer, type DrawerProps, DropdownMenu, type DropdownMenuItemProps, type DropdownMenuProps, type DropdownMenuVariants, HoverCard, type MenuPropBase, PopConfirm, type PopConfirmProps, popover as Popover, PopoverPreset, type PopoverPresetProps, type Scheduler, ScrollArea, Skeleton, Spinner, StateSwitcher, Swap, Switch, tabs as Tabs, type ThrottledFunction, Tooltip, TooltipArrow, TooltipProvider, TooltipRoot, TooltipTrigger, UIMorphingModal, type UIMorphingModalContentAnimationState, type UIMorphingModalProps, UIProvider, UIScreen, type UIScreenControls, type UIScreenNavigateFn, type UIScreenNavigateOptions, type UIScreenProps, type UIScreenValue, type UIScreenViewProps, UIViewTransition, type UIViewTransitionProps, type UseDrawerOptions, cn, compact, debounce, dropdownMenuStyles, findOption, formatCurrency, formatIntegerCompact, formatNumber, getFirstLetters, mergeRefs, omit, pick, throttle, tooltipVariants, tv, twMergeConfig, unique, useDisableContentMenu, useDrawer, useFlag, useForceUpdate, usePrevious, useToggle, useUIScreen };
|
package/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {a as a$1}from'./chunk-AIVCLPYT.js';import {e,j,n}from'./chunk-ALNSID3D.js';export{p as DropdownMenu,n as Skeleton,m as Switch,i as Tabs,a as UIProvider,c as debounce,o as dropdownMenuStyles,e as mergeRefs,d as throttle,q as useFlag}from'./chunk-ALNSID3D.js';import {b,c,F,J,G,H as H$1,I,P,Q as Q$1,i,E}from'./chunk-G54QLYD2.js';export{P as Button,v as Card,D as Command,K as Popover,L as Spinner,i as Tooltip,f as TooltipArrow,h as TooltipProvider,d as TooltipRoot,e as TooltipTrigger,N as baseButtonStyle,O as buttonVariants,c as cn,g as tooltipVariants,b as tv,a as twMergeConfig,M as useDisableContentMenu}from'./chunk-G54QLYD2.js';import {a}from'./chunk-M7AD2PUT.js';import {Slot,Collapsible,ScrollArea,HoverCard}from'radix-ui';import*as Q from'react';import Q__default,{useRef}from'react';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {CircleAlert,Copy,CheckCheck}from'lucide-react';import {AnimatePresence,m,LazyMotion}from'motion/react';import {Drawer}from'vaul';import jr from'react-use-measure';var ie=new WeakMap;function ne(t){return((...e)=>{let r=ie.get(t),a=e.map(String).join("_");if(r){let i=r.get(a);if(i)return i}else r=new Map,ie.set(t,r);let o=t(...e);return r.set(a,o),o})}function wa(t,e,r="zh-CN"){return new Intl.NumberFormat(r,e).format(t)}function Ca(t,e,r="zh-CN"){return new Intl.NumberFormat(r,{style:"currency",...e}).format(t)}function ka(t,e="en-US"){return new Intl.NumberFormat(e,{notation:"compact",compactDisplay:"short"}).format(t)}var Pa=ne((t,e=2)=>t.replace(/[.,!@#$%^&*()_+=\-`~[\]/\\{}:"|<>?]+/gi,"").trim().split(/\s+/).slice(0,e).map(r=>{if(!r.length)return "";if(/\s+/.test(t))return r.match(/./u)?.[0].toUpperCase();let a=new RegExp(".".repeat(e),"u"),o=r.match(a)?.[0];return o?o.charAt(0).toUpperCase()+o.slice(1):t.charAt(0).toUpperCase()+t.slice(1,2)}).join(""));function Aa(t,e){return Array.isArray(e)?t.filter(r=>e.some(a=>a===r.value)):t.find(r=>r.value===e)}function Sa(t){return Array.from(new Set(t))}function Da(t){return t.filter(ar)}function ar(t){return !!t}function or(t,e){return e.reduce((r,a)=>(r[a]=t[a],r),{})}function se(t,e){let r=new Set(e.map(String)),a=Object.keys(t).filter(o=>!r.has(o));return or(t,a)}var we={};a(we,{AVATAR_ROOT_NAME:()=>de,Badge:()=>xe,BrandLogo:()=>he,Image:()=>Bt,Indicator:()=>ge,Notification:()=>ye,Root:()=>fe,Status:()=>be,avatarRingVariants:()=>pe,avatarStatusVariants:()=>ve,avatarVariants:()=>Rt});function st(t,e,r,a,o){let i=Q__default.Children.map(t,(n,l)=>{if(!Q__default.isValidElement(n))return n;let m=n.type?.displayName||"",c=r.includes(m)?e:{},v=n.props;return Q__default.cloneElement(n,{...c,key:`${a}-${l}`},st(v?.children,e,r,a,v?.asChild))});return o?i?.[0]:i}function le(t){let e=Q.useId();return jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 80 80",...t,children:[jsxs("g",{fill:"#fff",clipPath:`url(#${e})`,children:[jsx("ellipse",{cx:40,cy:78,fillOpacity:.72,rx:32,ry:24}),jsx("circle",{cx:40,cy:32,r:16,opacity:.9})]}),jsx("defs",{children:jsx("clipPath",{id:e,children:jsx("rect",{width:80,height:80,fill:"#fff",rx:40})})})]})}function ce(t){let e=Q.useId(),r=Q.useId(),a=Q.useId();return jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:56,height:56,fill:"none",viewBox:"0 0 56 56",...t,children:[jsxs("g",{clipPath:`url(#${e})`,children:[jsx("rect",{width:56,height:56,className:"fill-bg-soft",rx:28}),jsx("path",{className:"fill-bg-soft",d:"M0 0h56v56H0z"}),jsx("g",{filter:`url(#${r})`,opacity:.48,children:jsx("path",{fill:"#fff",d:"M7 24.9a2.8 2.8 0 012.8-2.8h21a2.8 2.8 0 012.8 2.8v49a2.8 2.8 0 01-2.8 2.8h-21A2.8 2.8 0 017 73.9v-49z"})}),jsx("path",{className:"fill-bg-soft",d:"M12.6 28.7a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2z"}),jsx("g",{filter:`url(#${a})`,children:jsx("path",{fill:"#fff",fillOpacity:.8,d:"M21 14a2.8 2.8 0 012.8-2.8h21a2.8 2.8 0 012.8 2.8v49a2.8 2.8 0 01-2.8 2.8h-21A2.8 2.8 0 0121 63V14z"})}),jsx("path",{className:"fill-bg-soft",d:"M26.6 17.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7V22a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm9.8-29.4a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7V22a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2z"})]}),jsxs("defs",{children:[jsxs("filter",{id:r,width:34.6,height:62.6,x:3,y:18.1,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feGaussianBlur",{in:"BackgroundImageFix",stdDeviation:2}),jsx("feComposite",{in2:"SourceAlpha",operator:"in",result:"effect1_backgroundBlur_36237_4888"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_backgroundBlur_36237_4888",result:"shape"})]}),jsxs("filter",{id:a,width:42.6,height:70.6,x:13,y:3.2,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feGaussianBlur",{in:"BackgroundImageFix",stdDeviation:4}),jsx("feComposite",{in2:"SourceAlpha",operator:"in",result:"effect1_backgroundBlur_36237_4888"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_backgroundBlur_36237_4888",result:"shape"}),jsx("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),jsx("feOffset",{dy:4}),jsx("feGaussianBlur",{stdDeviation:2}),jsx("feComposite",{in2:"hardAlpha",k2:-1,k3:1,operator:"arithmetic"}),jsx("feColorMatrix",{values:"0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.25 0"}),jsx("feBlend",{in2:"shape",result:"effect2_innerShadow_36237_4888"})]}),jsx("clipPath",{id:e,children:jsx("rect",{width:56,height:56,fill:"#fff",rx:28})})]})]})}var de="AvatarRoot",me="AvatarImage",ue="AvatarIndicator",nr="AvatarStatus",sr="AvatarBrandLogo",lr="AvatarNotification",cr="AvatarBadge",Vt=Slot.Root,Rt=b({slots:{root:["relative flex shrink-0 items-center justify-center rounded-full","text-center uppercase select-none"],image:"size-full rounded-full object-cover",indicator:"absolute flex size-32 items-center justify-center drop-shadow-[0_2px_4px_#1b1c1d0a]"},variants:{withRing:{true:""},size:{80:{root:"size-80 text-title-h5"},72:{root:"size-72 text-title-h5"},64:{root:"size-64 text-title-h5"},56:{root:"size-56 text-label-lg"},48:{root:"size-48 text-label-lg"},42:{root:"size-42 text-label-md"},38:{root:"size-38 text-label-md"},32:{root:"size-32 text-label-sm"},24:{root:"size-24 text-label-xs"},20:{root:"size-20 text-label-xs"}},color:{gray:{root:"bg-bg-soft text-static-black/80"},yellow:{root:"bg-yellow-500 text-static-white"},blue:{root:"bg-blue-500 text-static-white"},sky:{root:"bg-sky-500 text-static-white"},purple:{root:"bg-purple-500 text-static-white"},red:{root:"bg-red-500 text-static-white"},green:{root:"bg-green-500 text-static-white"},teal:{root:"bg-teal-500 text-static-white"},violet:{root:"bg-violet-500 text-static-white"},pink:{root:"bg-pink-500 text-static-white"},orange:{root:"bg-orange-500 text-static-white"}}},compoundVariants:[{size:["80","72"],class:{indicator:"-right-8"}},{size:"64",class:{indicator:"-right-8 scale-[.875]"}},{size:"56",class:{indicator:"-right-6 scale-75"}},{size:"48",class:{indicator:"-right-6 scale-[.625]"}},{size:"42",class:{indicator:"-right-6 scale-[.5725]"}},{size:"38",class:{indicator:"-right-6 scale-[.5625]"}},{size:"32",class:{indicator:"-right-6 scale-50"}},{size:"24",class:{indicator:"-right-4 scale-[.375]"}},{size:"20",class:{indicator:"-right-4 scale-[.3125]"}},{withRing:true,size:"80",class:{indicator:"-right-12"}},{withRing:true,size:"72",class:{indicator:"-right-13"}},{withRing:true,size:"64",class:{indicator:"-right-12"}},{withRing:true,size:"56",class:{indicator:"-right-10"}},{withRing:true,size:["48","42","38","32"],class:{indicator:"-right-9"}},{withRing:true,size:["24","20"],class:{indicator:"-right-7"}}],defaultVariants:{size:"48",color:"gray"}}),pe=b({base:"ring-2 ring-offset-2",variants:{color:{gray:"ring-black/10",yellow:"ring-yellow-500",blue:"ring-blue-500",sky:"ring-sky-500",purple:"ring-purple-500",red:"ring-red-500",green:"ring-green-500",teal:"ring-teal-500",violet:"ring-violet-500",pink:"ring-pink-500",orange:"ring-orange-500",white:"ring-static-white",black:"ring-static-black"}},defaultVariants:{color:"gray"}}),Bt=Q.forwardRef(({asChild:t,className:e,size:r,color:a,...o},i)=>{let n=t?Vt:"img",{image:l}=Rt({size:r,color:a});return jsx(n,{ref:i,className:l({class:e}),...o})});Bt.displayName=me;var fe=Q.forwardRef(({asChild:t,children:e,size:r,color:a,ring:o,className:i,placeholderType:n="user",...l},m)=>{let c$1=Q.useId(),v=t?Vt:"div",p=o?pe({color:o===true?a:typeof o=="string"?o:void 0}):void 0,{root:C}=Rt({size:r,color:a}),y=c(C(),p,i),x={size:r,color:a};if(!e)return jsx("div",{className:y,...l,children:jsx(Bt,{asChild:true,children:n==="company"?jsx(ce,{}):jsx(le,{})})});let R=st(e,x,[me,ue],c$1,t);return jsx(v,{ref:m,className:y,...l,children:R})});fe.displayName=de;function ge({size:t,color:e,className:r,position:a="bottom",withRing:o,...i}){let{indicator:n}=Rt({size:t,color:e,withRing:o});return jsx("div",{className:c(n({class:r}),{"top-0 origin-top-right":a==="top","bottom-0 origin-bottom-right":a==="bottom"}),...i})}ge.displayName=ue;var ve=b({base:"box-content size-12 rounded-full border-4 border-bg-white",variants:{status:{online:"bg-success-base",offline:"bg-gray-500",busy:"bg-error-base",away:"bg-away-base"}},defaultVariants:{status:"online"}});function be({status:t,className:e,...r}){return jsx("div",{className:ve({status:t,class:e}),...r})}be.displayName=nr;var he=Q.forwardRef(({asChild:t,className:e,...r},a)=>jsx(t?Vt:"img",{draggable:false,ref:a,className:c("box-content size-24 rounded-full border-2 border-bg-white",e),...r}));he.displayName=sr;function ye({className:t,...e}){return jsx("div",{className:c("box-content size-12 rounded-full border-2 border-bg-white bg-error-base",t),...e})}ye.displayName=lr;function xe({className:t,...e}){return jsx("div",{className:c("box-content rounded-full border-2 border-bg-white bg-error-base px-6 text-static-white",t),...e})}xe.displayName=cr;function ct({className:t,variant:e="neutral",mode:r="stroke",size:a="small",...o}){return jsx(P,{variant:e,mode:r,size:a,className:c("absolute top-12 right-10 z-10 m-auto aspect-square rounded-full border-transparent text-text-soft hover:text-text-strong",t),...o,children:jsxs("svg",{width:"1em",height:"1em",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsx("path",{d:"M10.4854 1.99998L2.00007 10.4853",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),jsx("path",{d:"M10.4854 10.4844L2.00007 1.99908",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})})}var Ht=b({slots:{root:"relative flex w-fit max-w-xl flex-col rounded-[12px] border border-stroke-soft p-0 text-md",content:"",arrowCls:"",header:"flex items-center pe-28 select-none",close:"rounded-full"},variants:{variant:{default:{root:"gap-8 bg-bg-white p-16 pt-12",close:"top-12 right-12 hover:bg-bg-weak"},accent:{root:"bg-bg-weak p-4",content:"rounded-[8px] bg-bg-white px-12 py-8 shadow-sm",header:"px-12 py-4 pb-6",close:"top-9 right-8 hover:bg-bg-white",arrowCls:"bg-bg-weak"}}},defaultVariants:{variant:"default"}});function mr({variant:t,className:e,contentClassName:r,side:a="bottom",align:o="start",arrow:i=true,unstyled:n=true,closeable:l=true,sideOffset:m=1,title:c$1,content:v,children:p,asChild:C,defaultOpen:y,open:x,onOpenChange:R,onClose:z,...A}){let{root:O,content:S,header:T,close:b,arrowCls:f}=Ht({variant:t}),[_,V]=Q__default.useState(y??false),D=x!==void 0,N=D?x:_,B=Q__default.useCallback(E=>{D||V(E),R?.(E);},[D,R]);return jsxs(F,{open:N,onOpenChange:B,children:[D&&N&&jsx(J,{}),jsx(G,{className:c(D&&N&&"relative z-20"),asChild:C,children:p}),jsxs(H$1,{className:O({className:e}),arrowClassName:f(),unstyled:n,side:a,align:o,sideOffset:m,arrow:i,...A,children:[c$1&&jsxs("header",{className:T(),children:[jsx("h4",{className:"text-16 m-0 leading-26 font-medium text-text-strong",children:c$1}),l&&jsx(I,{asChild:true,onClick:z,children:jsx(ct,{size:"xsmall",mode:"ghost",className:b({class:"size-24 p-0"})})})]}),jsx("div",{className:S({className:r}),children:v})]})]})}function gr({variant:t="default",title:e,content:r,children:a,defaultOpen:o,className:i,side:n="top",align:l="center",sideOffset:m$1=1,arrow:c$1=true,open:v,contentClassName:p,onOpenChange:C,onConfirm:y,onCancel:x,...R}){let{root:z,content:A,header:O,arrowCls:S}=Ht({variant:t}),[T,b]=Q__default.useState(o??false),f=v!==void 0,_=f?v:T,V=Q__default.useCallback(E=>{f||b(E),C?.(E);},[f,C]),[D,N]=Q__default.useState(false),B=Q__default.useCallback(async()=>{V(false);try{N(!0),await y?.();}catch{}finally{N(false);}},[V,y]);return jsxs(F,{open:_,onOpenChange:V,children:[jsx(AnimatePresence,{children:_&&jsx(J,{as:m.div,...j,className:"bg-black/5"})}),jsx(G,{className:c(_&&"relative z-20"),children:jsx("div",{className:"inline-flex items-center",children:Q__default.isValidElement(a)?Q__default.cloneElement(a,{loading:D}):a})}),jsxs(H$1,{className:z({className:c("max-w-lg",i)}),arrowClassName:S(),unstyled:true,side:n,align:l,sideOffset:m$1,arrow:c$1,...R,children:[e&&jsxs("header",{className:O({className:"gap-6"}),children:[jsx(CircleAlert,{className:"text-red-500",size:16}),jsx("h4",{className:"m-0 text-15 leading-26 font-medium text-text-strong",children:e})]}),jsxs("div",{className:A({className:p}),children:[r,jsxs("div",{className:"mt-8 flex justify-end gap-12",children:[jsx(I,{unstyled:true,onClick:x,asChild:true,children:jsx(P,{size:"xsmall",variant:"neutral",mode:"stroke",className:"h-26",children:"Cancel"})}),jsx(P,{size:"xsmall",mode:"stroke",className:"h-26",onClick:B,children:"Confirm"})]})]})]})]})}function Pe({...t}){return jsx(Drawer.Root,{"data-slot":"drawer",...t})}function Re({...t}){return jsx(Drawer.Trigger,{"data-slot":"drawer-trigger",...t})}function vr({...t}){return jsx(Drawer.Portal,{"data-slot":"drawer-portal",...t})}function _t({...t}){return jsx(Drawer.Close,{"data-slot":"drawer-close",...t})}function br({className:t,...e}){return jsx(Drawer.Overlay,{"data-slot":"drawer-overlay",className:c("fixed inset-0 z-50 bg-black/10 data-closed:animate-out data-closed:fade-out-0 data-open:animate-in data-open:fade-in-0",t),...e})}var hr={top:"inset-x-8 top-8 max-h-[80vh]",bottom:"inset-x-8 bottom-8 mt-96 max-h-[80vh]",left:"inset-y-8 left-8 w-3/5",right:"inset-y-8 right-8 w-3/5"};function Ne({className:t,direction:e,children:r,...a}){let o=Q.useRef({"--initial-transform":"calc(100% + 8px)"});return jsxs(vr,{"data-slot":"drawer-portal",children:[jsx(br,{}),jsx(Drawer.Content,{"data-slot":"drawer-content",style:o.current,className:c("group/drawer-content fixed z-50 flex h-auto flex-col rounded-[12px] bg-static-white outline-none",e&&hr[e],t),...a,children:r})]})}function Te({className:t,...e}){return jsx("div",{"data-slot":"drawer-header",className:c("flex flex-col px-16 py-12",t),...e})}function Ae({className:t,...e}){return jsx("div",{"data-slot":"drawer-body",className:c("scrollbar-thin overflow-y-auto p-16 select-text",t),...e})}function Se({className:t,...e}){return jsx("div",{"data-slot":"drawer-footer",className:c("mt-auto flex flex-col gap-8 px-16 py-18",t),...e})}function De({className:t,...e}){return jsx(Drawer.Title,{"data-slot":"drawer-title",className:c("m-0 text-xl leading-32 font-medium text-text-strong",t),...e})}function Ee({className:t,...e}){return jsx(Drawer.Description,{"data-slot":"drawer-description",className:c("m-0 text-md text-text-sub",t),...e})}function wr({direction:t="right",dismissible:e=true,skeletonItemCount:r=5,className:a,footerClassName:o,bodyClassName:i,headerClassName:n,title:l="Title",description:m,footer:c$1,trigger:v,container:p,children:C,open:y,onOpenChange:x,loading:R,handleOnly:z=true,style:A,width:O,onClose:S,onOk:T,...b}){let f=Q$1(),_=Q__default.useRef({...A,width:O}),[V,D]=Q__default.useState(false),[N,B]=Q__default.useState(false),E=y!==void 0,Kt=E?y:V,K=Q__default.useCallback(P=>{!P&&N||(E||D(P),x?.(P));},[E,x,N]),k=Q__default.useCallback(async()=>{if(!T){K(false);return}let P=T();if(P instanceof Promise){B(true);try{await P,K(!1);}catch{}finally{B(false);}}else K(false);},[T,K]),u=!N&&e;return jsxs(Pe,{container:p,direction:t,dismissible:u,handleOnly:z,autoFocus:true,open:Kt,onOpenChange:K,...b,children:[v&&jsx(Re,{asChild:true,children:v}),jsxs(Ne,{direction:t,className:c(p&&p!==document.body&&"absolute",a),style:_.current,children:[e&&jsx(_t,{asChild:true,children:jsx(ct,{disabled:!u})}),e===false&&jsx(ct,{disabled:!u,onClick:S}),jsxs(Te,{className:c("border-b border-b-stroke-antd",n),children:[jsx(De,{className:"pe-42",asChild:true,children:typeof l=="string"?jsx("h3",{children:l}):jsx("div",{children:l})}),jsx(Ee,{className:c(!m&&"sr-only"),children:m})]}),jsxs(Ae,{className:i,children:[R&&jsx(Cr,{count:r}),!R&&C]}),jsxs(Se,{className:c("flex-row border-t border-t-stroke-antd",o),children:[c$1,!c$1&&jsxs(Fragment,{children:[e&&jsx(_t,{asChild:true,children:jsx(P,{variant:"neutral",mode:"stroke",className:"w-2/5",disabled:!u,children:f("close")})}),e===false&&jsx(P,{variant:"neutral",mode:"stroke",className:"w-2/5",disabled:!u,onClick:S,children:f("close")}),jsx(P,{variant:"neutral",mode:"filled",className:"w-3/5",loading:R||N,onClick:k,children:f("ok")})]})]})]})]})}function Cr({count:t=5}){let e=Array.from({length:t});return jsxs("div",{className:"flex flex-col gap-16",children:[jsxs("div",{className:"flex flex-row items-center gap-12",children:[jsx(n,{className:"size-58 rounded-2xl"}),jsxs("div",{className:"flex flex-1 flex-col gap-4",children:[jsx(n,{className:"mb-4 h-14 w-3/10"}),jsx(n,{className:"h-10 w-7/10"}),jsx(n,{className:"h-10 w-9/10"})]})]}),e.map((r,a)=>jsxs("div",{className:"flex flex-col gap-8",children:[jsx(n,{className:"h-12 w-5/10"}),jsx(n,{className:"h-12 w-7/10"}),jsx(n,{className:"h-12 w-full"})]},a))]})}function Pr(t){let[e,r]=Q__default.useState(false),[a,o]=Q__default.useState(null),i=Q__default.useCallback(c=>{o(c),r(true);},[]),n=Q__default.useCallback(()=>{r(false),o(null);},[]),l=Q__default.useCallback(c=>{r(c),c||o(null);},[]);return [{...t,open:e,onOpenChange:l,onClose:n},a,i,n]}var Ie=async t=>{if(!t)return;if(navigator.clipboard){await navigator.clipboard.writeText(t);return}let e=document.createElement("textarea");e.setAttribute("readonly",""),e.tabIndex=-1,e.style.position="fixed",e.style.left="-9999px",e.value=t,document.body.appendChild(e);let r=document.getSelection();if(r){let a=r.rangeCount>0&&r.getRangeAt(0);e.select(),document.execCommand("copy"),a&&(r.removeAllRanges(),r.addRange(a));}document.body.removeChild(e);};var Nr={initial:{scale:.5,opacity:0,filter:"blur(2px)"},animate:{scale:1,opacity:1,filter:"blur(0px)"},exit:{scale:.5,opacity:0,filter:"blur(2px)"}},Tr={opacity:{duration:.25},filter:{duration:.25},scale:{duration:.35,ease:[.34,1.56,.64,1]}},Ar={variants:Nr,initial:"initial",animate:"animate",exit:"exit",transition:Tr};function Ft({initial:t=false,state:e,states:r,asDiv:a,className:o,style:i,...n}){let l=a?m.div:m.span;return jsx(AnimatePresence,{initial:t,mode:"popLayout",children:jsx(l,{className:c("inline-flex items-center justify-center",o),...Ar,style:i,...n,children:r[e]},e)})}function Ut({swap:t,on:e,off:r,className:a}){return jsx(Ft,{state:t?"on":"off",states:{on:e,off:r},className:a})}function Ir({content:t,delay:e=700,tooltipDelayDuration:r=700,variant:a="neutral",mode:o="stroke",size:i$1="small",as:n="button",children:l,onCopy:m,className:c$1}){let v=Q$1(),[p,C]=Q__default.useState(false),[y,x]=Q__default.useState(false),[R,z]=Q__default.useState(false),A=Q__default.useRef(null),O=Q__default.useRef(null);Q__default.useEffect(()=>()=>{A.current&&clearTimeout(A.current),O.current&&clearTimeout(O.current);},[]);let S=Q__default.useCallback(async()=>{p||(C(true),z(true),await Ie(t),m?.(t),A.current=setTimeout(()=>{z(false),O.current=setTimeout(()=>C(false),150);},e));},[p,e,t,m]),T=jsx(Ut,{swap:p,on:jsx(CheckCheck,{width:"1em",height:"1em"}),off:jsx(Copy,{width:"1em",height:"1em"})}),b=(()=>{switch(n){case "text":return jsx("span",{className:c("relative cursor-pointer before:absolute before:-inset-x-4 before:-inset-y-1 before:rounded-md hover:before:bg-bg-antd",c$1),onClick:S,children:jsx("span",{className:"relative z-1",children:l??t})});case "inline":return jsxs("span",{className:c("relative inline-flex cursor-pointer items-center gap-6 before:absolute before:-inset-x-4 before:-inset-y-1 before:rounded-md hover:before:bg-bg-antd",c$1),onClick:S,children:[jsx("span",{className:"relative z-1",children:l??t}),jsx("span",{className:c("inline-flex items-center text-zinc-500",p&&"text-primary-base"),children:T})]});default:return jsx(P,{variant:a,mode:o,size:i$1,className:c(p&&"cursor-not-allowed",c$1),onClick:S,startContent:T})}})();return jsx(i,{content:v(p?"copied":"copy"),size:i$1,open:R||y,delayDuration:r,onOpenChange:x,hideWhenDetached:true,children:b})}var Vr=b({base:"flex shrink-0 items-center justify-center rounded-2xl ring-1 ring-transparent ring-inset",variants:{variant:{filled:"text-static-white",lighter:"",outline:"ring-current"},ring:{true:""},color:{neutral:"",slate:"",red:"",orange:"",amber:"",yellow:"",lime:"",green:"",emerald:"",teal:"",cyan:"",sky:"",blue:"",indigo:"",violet:"",purple:"",fuchsia:"",pink:"",rose:""}},compoundVariants:[{variant:"filled",color:"neutral",class:"bg-black/90"},{variant:"filled",color:"slate",class:"bg-slate-500"},{variant:"filled",color:"red",class:"bg-red-500"},{variant:"filled",color:"orange",class:"bg-orange-500"},{variant:"filled",color:"amber",class:"bg-amber-500"},{variant:"filled",color:"yellow",class:"bg-yellow-500"},{variant:"filled",color:"lime",class:"bg-lime-500"},{variant:"filled",color:"green",class:"bg-green-500"},{variant:"filled",color:"emerald",class:"bg-emerald-500"},{variant:"filled",color:"teal",class:"bg-teal-500"},{variant:"filled",color:"cyan",class:"bg-cyan-500"},{variant:"filled",color:"sky",class:"bg-sky-500"},{variant:"filled",color:"blue",class:"bg-blue-500"},{variant:"filled",color:"indigo",class:"bg-indigo-500"},{variant:"filled",color:"violet",class:"bg-violet-500"},{variant:"filled",color:"purple",class:"bg-purple-500"},{variant:"filled",color:"fuchsia",class:"bg-fuchsia-500"},{variant:"filled",color:"pink",class:"bg-pink-500"},{variant:"filled",color:"rose",class:"bg-rose-500"},{variant:"filled",ring:true,color:"neutral",class:"ring-neutral-700"},{variant:"filled",ring:true,color:"slate",class:"ring-slate-600"},{variant:"filled",ring:true,color:"red",class:"ring-red-700"},{variant:"filled",ring:true,color:"orange",class:"ring-orange-600"},{variant:"filled",ring:true,color:"amber",class:"ring-amber-600"},{variant:"filled",ring:true,color:"yellow",class:"ring-yellow-600"},{variant:"filled",ring:true,color:"lime",class:"ring-lime-600"},{variant:"filled",ring:true,color:"green",class:"ring-green-600"},{variant:"filled",ring:true,color:"emerald",class:"ring-emerald-600"},{variant:"filled",ring:true,color:"teal",class:"ring-teal-600"},{variant:"filled",ring:true,color:"cyan",class:"ring-cyan-600"},{variant:"filled",ring:true,color:"sky",class:"ring-sky-600"},{variant:"filled",ring:true,color:"blue",class:"ring-blue-700"},{variant:"filled",ring:true,color:"indigo",class:"ring-indigo-600"},{variant:"filled",ring:true,color:"violet",class:"ring-violet-600"},{variant:"filled",ring:true,color:"purple",class:"ring-purple-600"},{variant:"filled",ring:true,color:"fuchsia",class:"ring-fuchsia-600"},{variant:"filled",ring:true,color:"pink",class:"ring-pink-600"},{variant:"filled",ring:true,color:"rose",class:"ring-rose-600"},{variant:"lighter",color:"neutral",class:"bg-neutral-100 text-neutral-600"},{variant:"lighter",color:"slate",class:"bg-slate-100 text-slate-500"},{variant:"lighter",color:"red",class:"bg-red-50 text-red-500"},{variant:"lighter",color:"orange",class:"bg-orange-50 text-orange-500"},{variant:"lighter",color:"amber",class:"bg-amber-50 text-amber-500"},{variant:"lighter",color:"yellow",class:"bg-yellow-50 text-yellow-500"},{variant:"lighter",color:"lime",class:"bg-lime-50 text-lime-500"},{variant:"lighter",color:"green",class:"bg-green-50 text-green-500"},{variant:"lighter",color:"emerald",class:"bg-emerald-50 text-emerald-500"},{variant:"lighter",color:"teal",class:"bg-teal-50 text-teal-500"},{variant:"lighter",color:"cyan",class:"bg-cyan-50 text-cyan-500"},{variant:"lighter",color:"sky",class:"bg-sky-50 text-sky-500"},{variant:"lighter",color:"blue",class:"bg-blue-50 text-blue-500"},{variant:"lighter",color:"indigo",class:"bg-indigo-50 text-indigo-500"},{variant:"lighter",color:"violet",class:"bg-violet-50 text-violet-500"},{variant:"lighter",color:"purple",class:"bg-purple-50 text-purple-500"},{variant:"lighter",color:"fuchsia",class:"bg-fuchsia-50 text-fuchsia-500"},{variant:"lighter",color:"pink",class:"bg-pink-50 text-pink-500"},{variant:"lighter",color:"rose",class:"bg-rose-50 text-rose-500"},{variant:["lighter","outline"],ring:true,color:"neutral",class:"ring-neutral-200"},{variant:["lighter","outline"],ring:true,color:"slate",class:"ring-slate-200"},{variant:["lighter","outline"],ring:true,color:"red",class:"ring-red-200"},{variant:["lighter","outline"],ring:true,color:"orange",class:"ring-orange-200"},{variant:["lighter","outline"],ring:true,color:"amber",class:"ring-amber-200"},{variant:["lighter","outline"],ring:true,color:"yellow",class:"ring-yellow-200"},{variant:["lighter","outline"],ring:true,color:"lime",class:"ring-lime-200"},{variant:["lighter","outline"],ring:true,color:"green",class:"ring-green-200"},{variant:["lighter","outline"],ring:true,color:"emerald",class:"ring-emerald-200"},{variant:["lighter","outline"],ring:true,color:"teal",class:"ring-teal-200"},{variant:["lighter","outline"],ring:true,color:"cyan",class:"ring-cyan-200"},{variant:["lighter","outline"],ring:true,color:"sky",class:"ring-sky-200"},{variant:["lighter","outline"],ring:true,color:"blue",class:"ring-blue-200"},{variant:["lighter","outline"],ring:true,color:"indigo",class:"ring-indigo-200"},{variant:["lighter","outline"],ring:true,color:"violet",class:"ring-violet-200"},{variant:["lighter","outline"],ring:true,color:"purple",class:"ring-purple-200"},{variant:["lighter","outline"],ring:true,color:"fuchsia",class:"ring-fuchsia-200"},{variant:["lighter","outline"],ring:true,color:"pink",class:"ring-pink-200"},{variant:["lighter","outline"],ring:true,color:"rose",class:"ring-rose-200"},{variant:"outline",color:"neutral",class:"text-neutral-500"},{variant:"outline",color:"slate",class:"text-slate-400"},{variant:"outline",color:"red",class:"text-red-500"},{variant:"outline",color:"orange",class:"text-orange-500"},{variant:"outline",color:"amber",class:"text-amber-500"},{variant:"outline",color:"yellow",class:"text-yellow-500"},{variant:"outline",color:"lime",class:"text-lime-500"},{variant:"outline",color:"green",class:"text-green-500"},{variant:"outline",color:"emerald",class:"text-emerald-500"},{variant:"outline",color:"teal",class:"text-teal-500"},{variant:"outline",color:"cyan",class:"text-cyan-500"},{variant:"outline",color:"sky",class:"text-sky-500"},{variant:"outline",color:"blue",class:"text-blue-500"},{variant:"outline",color:"indigo",class:"text-indigo-500"},{variant:"outline",color:"violet",class:"text-violet-500"},{variant:"outline",color:"purple",class:"text-purple-500"},{variant:"outline",color:"fuchsia",class:"text-fuchsia-500"},{variant:"outline",color:"pink",class:"text-pink-500"},{variant:"outline",color:"rose",class:"text-rose-500"}],defaultVariants:{variant:"outline",color:"slate"}});function Fo({asChild:t,children:e,className:r,color:a,variant:o,ring:i,...n}){let l=t?Slot.Root:"div",m=Vr({variant:o,color:a,ring:i,className:r});return jsx(l,{className:m,...n,children:e})}function Wo({...t}){return jsx(Collapsible.Root,{"data-slot":"collapsible",...t})}function qo({...t}){return jsx(Collapsible.CollapsibleTrigger,{"data-slot":"collapsible-trigger",...t})}function jo({className:t,...e}){return jsx(Collapsible.CollapsibleContent,{"data-slot":"collapsible-content",className:c("collapsible-content",t),...e})}var Mr="BadgeRoot",Be="BadgeIcon",Le="BadgeDot",$t=b({slots:{root:"inline-flex w-fit appearance-none items-center justify-center border-none leading-none font-medium whitespace-nowrap transition duration-200 ease-out select-none",icon:"uicon shrink-0",dot:["uidot flex items-center justify-center","before:size-4 before:rounded-full before:bg-current"]},variants:{size:{medium:{root:"h-24 gap-4 px-10 text-md has-[>.uicon]:gap-6 has-[>.uidot]:gap-4",icon:"-mx-2 size-14",dot:"-mx-4 size-16 before:size-6"},small:{root:"h-20 gap-4 px-8 text-sm has-[>.uicon]:gap-4 has-[>.uidot]:gap-3",icon:"-mx-px size-12",dot:"-mx-4 size-16 before:size-5"},xsmall:{root:"h-16 gap-3 px-7 text-xs has-[>.uicon]:gap-4 has-[>.uidot]:gap-4",icon:"-mx-px size-10",dot:"-mx-5 size-16"}},variant:{filled:{root:"text-static-white"},outline:{root:"ring-1 ring-current ring-inset"},lighter:"",ghost:""},color:{primary:"",info:"",success:"",warning:"",error:"",neutral:""},shape:{default:"",circle:{root:"rounded-full"}},disabled:{true:{root:"cursor-not-allowed opacity-75"}}},compoundVariants:[{shape:"default",size:"xsmall",class:{root:"rounded-[3px] px-5"}},{shape:"default",size:"small",class:{root:"rounded-[4px] px-6"}},{shape:"default",size:"medium",class:{root:"rounded-lg px-7",icon:"ms-0"}},{variant:"filled",color:"primary",class:{root:"bg-primary-base"}},{variant:"filled",color:"info",class:{root:"bg-cyan-500"}},{variant:"filled",color:"success",class:{root:"bg-emerald-500"}},{variant:"filled",color:"warning",class:{root:"bg-orange-500"}},{variant:"filled",color:"error",class:{root:"bg-red-600"}},{variant:"filled",color:"neutral",class:{root:"bg-black/90"}},{variant:"outline",color:"primary",class:{root:"text-primary-base"}},{variant:"outline",color:"info",class:{root:"text-cyan-600"}},{variant:"outline",color:"success",class:{root:"text-emerald-500"}},{variant:"outline",color:"warning",class:{root:"text-orange-500"}},{variant:"outline",color:"error",class:{root:"text-red-600"}},{variant:"outline",color:"neutral",class:{root:"text-neutral-600 ring-neutral-200"}},{variant:"lighter",color:"primary",class:{root:"bg-blue-50 text-primary-base"}},{variant:"lighter",color:"info",class:{root:"bg-cyan-50 text-cyan-600"}},{variant:"lighter",color:"success",class:{root:"bg-emerald-50 text-emerald-600"}},{variant:"lighter",color:"warning",class:{root:"bg-orange-50 text-orange-600"}},{variant:"lighter",color:"error",class:{root:"bg-red-50 text-red-600"}},{variant:"lighter",color:"neutral",class:{root:"bg-neutral-100 text-neutral-600"}},{variant:"ghost",color:"primary",class:{root:"text-primary-base"}},{variant:"ghost",color:"info",class:{root:"text-cyan-600"}},{variant:"ghost",color:"success",class:{root:"text-emerald-600"}},{variant:"ghost",color:"warning",class:{root:"text-orange-600"}},{variant:"ghost",color:"error",class:{root:"text-red-600"}},{variant:"ghost",color:"neutral",class:{root:"text-neutral-600"}}],defaultVariants:{variant:"filled",color:"primary",size:"medium",shape:"default"}}),Me=({asChild:t,size:e,variant:r,color:a,shape:o,children:i,className:n,disabled:l,...m})=>{let c=Q.useId(),v=t?Slot.Root:"div",{root:p}=$t({variant:r,color:a,size:e,shape:o,disabled:l}),y=st(i,{size:e,variant:r,color:a},[Be,Le],c,t);return jsx(v,{"data-slot":"badge",className:p({class:n}),...m,children:y})};Me.displayName=Mr;function He({className:t,size:e,variant:r,color:a,as:o,...i}){let n=o||"div",{icon:l}=$t({size:e,variant:r,color:a});return jsx(n,{"data-slot":"icon",className:l({class:t}),...i})}He.displayName=Be;function _e({size:t,variant:e,color:r,className:a,...o}){let{dot:i}=$t({size:t,variant:e,color:r});return jsx("div",{"data-slot":"dot",className:i({class:a}),...o})}_e.displayName=Le;function ti({icon:t,dot:e,children:r,asChild:a,...o}){return jsxs(Me,{asChild:a,...o,children:[t&&!a&&jsx(He,{as:t}),e&&!a&&jsx(_e,{}),r]})}function _r({className:t,scrollBarClassName:e,children:r,...a}){return jsxs(ScrollArea.Root,{"data-slot":"scroll-area",className:c("relative",t),...a,children:[jsx(ScrollArea.Viewport,{"data-slot":"scroll-area-viewport",className:"size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-2 focus-visible:ring-primary-base focus-visible:outline-1",children:r}),jsx(Fe,{orientation:"vertical",className:e}),jsx(Fe,{orientation:"horizontal",className:e}),jsx(ScrollArea.Corner,{})]})}function Fe({className:t,orientation:e="vertical",...r}){return jsx(ScrollArea.ScrollAreaScrollbar,{"data-slot":"scroll-area-scrollbar","data-orientation":e,orientation:e,className:c("flex touch-none p-2 transition-colors select-none data-[orientation=horizontal]:h-10 data-[orientation=horizontal]:flex-col data-[orientation=horizontal]:border-t data-[orientation=horizontal]:border-t-transparent data-[orientation=vertical]:h-full data-[orientation=vertical]:w-10 data-[orientation=vertical]:border-l data-[orientation=vertical]:border-l-transparent",t),...r,children:jsx(ScrollArea.ScrollAreaThumb,{"data-slot":"scroll-area-thumb",className:"relative flex-1 rounded-full bg-stroke-sub"})})}function Ur({open:t,defaultOpen:e,openDelay:r=300,closeDelay:a,asChild:o=true,arrow:i=true,content:n,children:l,onOpenChange:m,...c}){return jsxs(Yr,{"data-slot":"hover-card",open:t,defaultOpen:e,openDelay:r,closeDelay:a,onOpenChange:m,children:[jsx(Gr,{asChild:o,children:l}),jsxs($r,{...c,children:[n,i&&jsx(HoverCard.Arrow,{asChild:true,children:jsx(E,{className:"-translate-y-6.5"})})]})]})}function Yr({...t}){return jsx(HoverCard.Root,{"data-slot":"hover-card",...t})}function Gr({...t}){return jsx(HoverCard.Trigger,{"data-slot":"hover-card-trigger",...t})}function $r({className:t,align:e="center",sideOffset:r=4,collisionPadding:a=16,...o}){return jsx(HoverCard.Portal,{"data-slot":"hover-card-portal",children:jsx(HoverCard.Content,{"data-slot":"hover-card-content",align:e,sideOffset:r,collisionPadding:a,className:c("z-50 rounded-2xl bg-bg-white px-10 py-6 text-md text-text-strong shadow-regular-md ring-1 ring-stroke-soft outline-hidden duration-100 ring-inset","origin-(--radix-hover-card-content-transform-origin) data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",t),...o})})}var Kr=()=>import('./motion-features-BVPA56CL.js').then(t=>t.default),Jr={initial:{opacity:0,scale:.96,y:4,filter:"blur(2px)"},exit:{opacity:0,scale:.96,y:4,filter:"blur(2px)"},animate:{opacity:1,scale:1,y:0,filter:"blur(0px)"}},Zr={type:"spring",bounce:.1,duration:.25},Qr={ease:[.26,.08,.25,1],duration:.27};function Xr({activeKey:t,children:e,className:r,rootClassName:a,defaultCardHeight:o,initialKey:i,variants:n=Jr,transition:l=Qr,rootTransition:m$1=Zr,lazy:c=false}){let[v,{height:p}]=jr(),C=Q.useRef(o??0);p>0&&(C.current=p);let y=t===i?o:p||C.current,x=jsx(m.div,{"data-slot":"animation-root",className:a,initial:false,animate:{height:y},transition:m$1,children:jsx("div",{ref:v,"data-slot":"animation-container",children:jsx(AnimatePresence,{mode:"popLayout",initial:false,children:jsx(m.div,{"data-slot":"animation-page",variants:n,transition:l,initial:"initial",animate:"animate",exit:"exit",className:r,children:e},t)})})});return c?jsx(LazyMotion,{features:Kr,strict:true,children:x}):x}var Wt=()=>{let[,t]=Q.useState(false);return Q.useCallback(()=>{t(e=>!e);},[])};function qt(t,e){let r=Q.useRef(void 0),{current:a}=r;return Q.useEffect(()=>{(!e||t!==void 0)&&(r.current=t);},[t,e]),a}function $e(t,e,r,a){ta("animationend",t,e,r,a);}function ta(t,e,r,a,o){let i=false;function n(l){i||l.target!==l.currentTarget||a||(i=true,e.removeEventListener(t,n),setTimeout(()=>{r();},50));}e.addEventListener(t,n),setTimeout(()=>{i||(e.removeEventListener(t,n),r());},o);}var At=new WeakMap,We=new WeakMap;function tt(t,e,r=false){if(!t)return;if(!r){let o=e.split(" ");if(o.length>1){o.forEach(i=>{tt(t,i,true);});return}}t.classList.add(e);let a=At.get(t);a?a.add(e):At.set(t,new Set([e]));}function Y(t,e,r=false){if(!r){let o=e.split(" ");if(o.length>1){o.forEach(i=>{Y(t,i,true);});return}}t.classList.remove(e);let a=At.get(t);a&&(a.delete(e),a.size||At.delete(t));}function H(t,e,r,a=false){if(!a){let o=e.split(" ");if(o.length>1){o.forEach(i=>{H(t,i,r,true);});return}}t.classList.toggle(e,r),t.classList.contains(e)?tt(t,e):Y(t,e);}function bt(t,e){We.set(t,e),ea(t);}function ea(t){let e=Object.entries(We.get(t)).reduce((r,[a,o])=>(a.startsWith("--")?t.style.setProperty(a,o):r[a]=o,r),{});Object.assign(t.style,e);}a$1(`.ui-transition{--layer-blackout-opacity: .1;--dim-behind-opacity: .7;--layer-transition: .3s cubic-bezier(.33, 1, .68, 1);--layer-transition-behind: .3s cubic-bezier(.33, 1, .68, 1);--slide-transition: .3s cubic-bezier(.25, 1, .5, 1);--color-background: 255, 255, 255;--color-container: 255, 255, 255;position:relative;width:100%;height:100%}.ui-transition-slide{width:100%;height:100%;animation-fill-mode:forwards!important}.ui-transition-slide-from,.ui-transition-slide-to{position:absolute;top:0;left:0}.ui-transition-slide-from{pointer-events:none}.ui-transition-slide-inactive{display:none!important}.ui-transition--slide>.ui-transition-slide-to{transform:translate(100%);animation:slide-in var(--slide-transition)}.ui-transition--slide>.ui-transition-slide-from{animation:slide-out var(--slide-transition)}.ui-transition--slide-backwards>.ui-transition-slide-to{transform:translate(-100%);animation:slide-out-backwards var(--slide-transition)}.ui-transition--slide-backwards>.ui-transition-slide-from{animation:slide-in-backwards var(--slide-transition)}.ui-transition--slide-vertical>.ui-transition-slide-to{transform:translateY(100%);animation:slide-vertical-in var(--slide-transition)}.ui-transition--slide-vertical>.ui-transition-slide-from{animation:slide-vertical-out var(--slide-transition)}.ui-transition--slide-vertical-backwards>.ui-transition-slide-to{transform:translateY(-100%);animation:slide-vertical-out-backwards var(--slide-transition)}.ui-transition--slide-vertical-backwards>.ui-transition-slide-from{animation:slide-vertical-in-backwards var(--slide-transition)}.ui-transition--slide-vertical-fade>.ui-transition-slide-to{transform:translateY(100%);animation:slide-vertical-fade-in var(--slide-transition)}.ui-transition--slide-vertical-fade>.ui-transition-slide-from{animation:slide-vertical-fade-out var(--slide-transition)}.ui-transition--slide-vertical-fade-backwards>.ui-transition-slide-to{transform:translateY(-100%);animation:slide-vertical-fade-out-backwards var(--slide-transition)}.ui-transition--slide-vertical-fade-backwards>.ui-transition-slide-from{animation:slide-vertical-fade-in-backwards var(--slide-transition)}.ui-transition--slide-fade>.ui-transition-slide-from{transform:translate(0);transform-origin:left;opacity:1;animation:fade-out-opacity var(--slide-transition),slide-fade-out-move var(--slide-transition)}.ui-transition--slide-fade>.ui-transition-slide-to{transform:translate(1.5rem);transform-origin:left;opacity:0;animation:fade-in-opacity var(--slide-transition),slide-fade-in-move var(--slide-transition)}.ui-transition--slide-fade-backwards>.ui-transition-slide-from{transform:translate(0);opacity:1;animation:fade-in-backwards-opacity var(--slide-transition),slide-fade-in-backwards-move var(--slide-transition)}.ui-transition--slide-fade-backwards>.ui-transition-slide-to{transform:translate(-1.5rem);opacity:0;animation:fade-out-backwards-opacity var(--slide-transition),slide-fade-out-backwards-move var(--slide-transition)}.ui-transition--slide-fade-android{--background-color: rgba(var(--color-container), 1)}.ui-transition--slide-fade-android>.ui-transition-slide{z-index:0;background:var(--background-color)}.ui-transition--slide-fade-android>.ui-transition-slide-to{transform:translate(1.5rem);transform-origin:left;opacity:0;animation:fade-in-opacity var(--slide-transition),slide-fade-in-move-android var(--slide-transition)}.ui-transition--slide-fade-android-backwards{--background-color: rgba(var(--color-container), 1)}.ui-transition--slide-fade-android-backwards>.ui-transition-slide{z-index:0;background:var(--background-color)}.ui-transition--slide-fade-android-backwards>.ui-transition-slide-from{transform:translate(0);opacity:1;animation:fade-in-backwards-opacity var(--slide-transition),slide-fade-in-backwards-move-android var(--slide-transition)}.ui-transition--zoom-fade>.ui-transition-slide-from{transform:scale(1);transform-origin:center;opacity:1;animation:fade-out-opacity .15s ease}.ui-transition--zoom-fade>.ui-transition-slide-to{transform-origin:center;opacity:0;animation:fade-in-opacity .15s ease,zoom-fade-in-move .15s ease}.ui-transition--zoom-fade-backwards>.ui-transition-slide-from{transform:scale(1);animation:fade-in-backwards-opacity .1s ease,zoom-fade-in-backwards-move .15s ease}.ui-transition--zoom-fade-backwards>.ui-transition-slide-to{transform:scale(.95);animation:fade-out-backwards-opacity .15s ease,zoom-fade-out-backwards-move .15s ease}.ui-transition--fade>.ui-transition-slide-from,.ui-transition--fade-backwards>.ui-transition-slide-from{opacity:1;animation:fade-out-opacity .15s ease}.ui-transition--fade>.ui-transition-slide-to,.ui-transition--fade-backwards>.ui-transition-slide-to{opacity:0;animation:fade-in-opacity .15s ease}.ui-transition--semi-fade>.ui-transition-slide{isolation:isolate}.ui-transition--semi-fade>.ui-transition-slide-from{opacity:1}.ui-transition--semi-fade>.ui-transition-slide-to{opacity:0;animation:fade-in-opacity .25s ease}.ui-transition--semi-fade-backwards>.ui-transition-slide-from{opacity:1;animation:fade-in-backwards-opacity .25s ease}.ui-transition--semi-fade-backwards>.ui-transition-slide-to{opacity:1;animation:none!important}.ui-transition--slide-layers{--background-color: rgba(var(--color-container), 1)}.ui-transition--slide-layers>.ui-transition-slide{background:var(--background-color)}.ui-transition--slide-layers>.ui-transition-slide-to{transform:translate(100%);animation:slide-in var(--layer-transition)}.ui-transition--slide-layers>.ui-transition-slide-from{animation:slide-layers-out var(--layer-transition-behind)}.ui-transition--slide-layers-backwards{--background-color: rgba(var(--color-container), 1)}.ui-transition--slide-layers-backwards>.ui-transition-slide{background:var(--background-color)}.ui-transition--slide-layers-backwards>.ui-transition-slide-to{transform:translate(-20%);opacity:calc(1 - var(--layer-blackout-opacity));animation:slide-layers-out-backwards var(--layer-transition-behind);animation-duration:.45s}.ui-transition--slide-layers-backwards>.ui-transition-slide-from{animation:slide-in-backwards var(--layer-transition)}.ui-transition--push-slide>.ui-transition-slide{background:var(--color-background)}.ui-transition--push-slide>.ui-transition-slide-from{transform:scale(1);transform-origin:center;opacity:1;animation:push-out .25s ease-in-out}.ui-transition--push-slide>.ui-transition-slide-from .custom-scroll{scrollbar-color:transparent!important}.ui-transition--push-slide>.ui-transition-slide-from .custom-scroll::-webkit-scrollbar-thumb{background-color:transparent!important}.ui-transition--push-slide>.ui-transition-slide-to{transform:translate(100%);animation:slide-in-200 .25s ease-in-out}.ui-transition--push-slide-backwards>.ui-transition-slide{background:var(--color-background)}.ui-transition--push-slide-backwards>.ui-transition-slide-to{transform:scale(.7);opacity:0;animation:push-out-backwards .25s ease-in-out}.ui-transition--push-slide-backwards>.ui-transition-slide-from{animation:slide-in-200-backwards .25s ease-in-out}.ui-transition--dim-behind{background:#000}.ui-transition--dim-behind>.ui-transition-slide{background:#fff}.ui-transition--dim-behind.ui-transition--push-slide>.ui-transition-slide-from{transform:none;animation:dim-behind-out .25s ease-in-out}.ui-transition--dim-behind.ui-transition--push-slide-backwards>.ui-transition-slide-to{transform:none;opacity:var(--dim-behind-opacity);animation:dim-behind-out-backwards .25s ease-in-out}.ui-transition--dim-behind.ui-transition--slide-layers>.ui-transition-slide-from{animation:dim-behind-slide-layers-out var(--layer-transition-behind)}.ui-transition--dim-behind.ui-transition--slide-layers-backwards>.ui-transition-slide-to{transform:translate(-20%);opacity:var(--dim-behind-opacity);animation:dim-behind-slide-layers-out-backwards var(--layer-transition-behind)}.ui-transition--reveal>.ui-transition-slide-to{-webkit-clip-path:inset(0 100% 0 0);clip-path:inset(0 100% 0 0);animation:reveal-in .35s ease-in}.ui-transition--reveal-backwards>.ui-transition-slide-from{-webkit-clip-path:inset(0 0 0 0);clip-path:inset(0 0 0 0);animation:reveal-in-backwards .35s ease-out}.ui-transition--reveal-backwards>.ui-transition-slide-to{-webkit-clip-path:none;clip-path:none;animation:none}@keyframes fade-in-opacity{0%{opacity:0}to{opacity:1}}@keyframes fade-out-opacity{0%{opacity:1}to{opacity:0}}@keyframes fade-in-backwards-opacity{0%{opacity:1}to{opacity:0}}@keyframes fade-out-backwards-opacity{0%{opacity:0}to{opacity:1}}@keyframes slide-in{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes slide-out{0%{transform:translate(0)}to{transform:translate(-100%)}}@keyframes slide-in-backwards{0%{transform:translate(0)}to{transform:translate(100%)}}@keyframes slide-out-backwards{0%{transform:translate(-100%)}to{transform:translate(0)}}@keyframes slide-vertical-in{0%{transform:translateY(100%)}to{transform:translateY(0)}}@keyframes slide-vertical-out{0%{transform:translateY(0)}to{transform:translateY(-100%)}}@keyframes slide-vertical-in-backwards{0%{transform:translateY(0)}to{transform:translateY(100%)}}@keyframes slide-vertical-out-backwards{0%{transform:translateY(-100%)}to{transform:translateY(0)}}@keyframes slide-vertical-fade-in{0%{transform:translateY(100%);opacity:0}to{transform:translateY(0);opacity:1}}@keyframes slide-vertical-fade-out{0%{transform:translateY(0);opacity:1}to{transform:translateY(-100%);opacity:0}}@keyframes slide-vertical-fade-in-backwards{0%{transform:translateY(0);opacity:1}to{transform:translateY(100%);opacity:0}}@keyframes slide-vertical-fade-out-backwards{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}@keyframes slide-fade-in-move{0%{transform:translate(1.5rem)}to{transform:translate(0)}}@keyframes slide-fade-out-move{0%{transform:translate(0)}to{transform:translate(-1.5rem)}}@keyframes slide-fade-in-backwards-move{0%{transform:translate(0)}to{transform:translate(1.5rem)}}@keyframes slide-fade-out-backwards-move{0%{transform:translate(-1.5rem)}to{transform:translate(0)}}@keyframes slide-fade-in-move-android{0%{transform:translate(20%)}to{transform:translate(0)}}@keyframes slide-fade-in-backwards-move-android{0%{transform:translate(0)}to{transform:translate(15%)}}@keyframes zoom-fade-in-move{0%{transform:scale(1.1)}to{transform:scale(1)}}@keyframes zoom-fade-in-backwards-move{0%{transform:scale(1)}to{transform:scale(1.1)}}@keyframes zoom-fade-out-backwards-move{0%{transform:scale(.95)}to{transform:scale(1)}}@keyframes slide-layers-out{0%{transform:translate(0);opacity:1}to{transform:translate(-20%);opacity:calc(1 - var(--layer-blackout-opacity))}}@keyframes slide-layers-out-backwards{0%{transform:translate(-20%);opacity:calc(1 - var(--layer-blackout-opacity))}to{transform:translate(0);opacity:1}}@keyframes push-out{0%{transform:scale(1);opacity:1}to{transform:scale(.7);opacity:0}}@keyframes push-out-backwards{0%{transform:scale(.7);opacity:0}to{transform:scale(1);opacity:1}}@keyframes slide-in-200{0%{transform:translate(200%)}to{transform:translate(0)}}@keyframes slide-in-200-backwards{0%{transform:translate(0)}to{transform:translate(200%)}}@keyframes dim-behind-out{0%{opacity:1}to{opacity:var(--dim-behind-opacity)}}@keyframes dim-behind-out-backwards{0%{opacity:var(--dim-behind-opacity)}to{opacity:1}}@keyframes dim-behind-slide-layers-out{0%{transform:translate(0);opacity:1}to{transform:translate(-20%);opacity:var(--dim-behind-opacity)}}@keyframes dim-behind-slide-layers-out-backwards{0%{transform:translate(-20%);opacity:var(--dim-behind-opacity)}to{transform:translate(0);opacity:1}}@keyframes reveal-in{0%{-webkit-clip-path:inset(0 100% 0 0);clip-path:inset(0 100% 0 0)}to{-webkit-clip-path:inset(0 0 0 0);clip-path:inset(0 0 0 0)}}@keyframes reveal-in-backwards{0%{-webkit-clip-path:inset(0 0 0 0);clip-path:inset(0 0 0 0)}to{-webkit-clip-path:inset(0 100% 0 0);clip-path:inset(0 100% 0 0)}}
|
|
2
|
-
|
|
1
|
+
import'./chunk-PICBT6ES.js';import {a as a$1,k,o,r}from'./chunk-U66T3F2Z.js';export{q as DropdownMenu,o as Skeleton,n as Switch,j as Tabs,b as UIProvider,d as debounce,p as dropdownMenuStyles,f as mergeRefs,e as throttle,r as useFlag}from'./chunk-U66T3F2Z.js';import {b,c,F,J,G,H,I,P as P$1,Q,i,E}from'./chunk-G54QLYD2.js';export{P as Button,v as Card,D as Command,K as Popover,L as Spinner,i as Tooltip,f as TooltipArrow,h as TooltipProvider,d as TooltipRoot,e as TooltipTrigger,N as baseButtonStyle,O as buttonVariants,c as cn,g as tooltipVariants,b as tv,a as twMergeConfig,M as useDisableContentMenu}from'./chunk-G54QLYD2.js';import {a}from'./chunk-M7AD2PUT.js';import {Slot,Collapsible,ScrollArea,HoverCard,Portal}from'radix-ui';import*as P from'react';import P__default,{useRef,useState,useLayoutEffect}from'react';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {CircleAlert,Copy,CheckCheck}from'lucide-react';import {m,AnimatePresence}from'motion/react';import {Drawer}from'vaul';import Qr from'react-use-measure';var Je=new WeakMap;function Qe(e){return((...t)=>{let r=Je.get(e),o=t.map(String).join("_");if(r){let i=r.get(o);if(i)return i}else r=new Map,Je.set(e,r);let a=e(...t);return r.set(o,a),a})}function ra(e,t,r="zh-CN"){return new Intl.NumberFormat(r,t).format(e)}function oa(e,t,r="zh-CN"){return new Intl.NumberFormat(r,{style:"currency",...t}).format(e)}function aa(e,t="en-US"){return new Intl.NumberFormat(t,{notation:"compact",compactDisplay:"short"}).format(e)}var na=Qe((e,t=2)=>e.replace(/[.,!@#$%^&*()_+=\-`~[\]/\\{}:"|<>?]+/gi,"").trim().split(/\s+/).slice(0,t).map(r=>{if(!r.length)return "";if(/\s+/.test(e))return r.match(/./u)?.[0].toUpperCase();let o=new RegExp(".".repeat(t),"u"),a=r.match(o)?.[0];return a?a.charAt(0).toUpperCase()+a.slice(1):e.charAt(0).toUpperCase()+e.slice(1,2)}).join(""));function ca(e,t){return Array.isArray(t)?e.filter(r=>t.some(o=>o===r.value)):e.find(r=>r.value===t)}function pa(e){return Array.from(new Set(e))}function da(e){return e.filter(lr)}function lr(e){return !!e}function cr(e,t){return t.reduce((r,o)=>(r[o]=e[o],r),{})}function ma(e,t){let r=new Set(t.map(String)),o=Object.keys(e).filter(a=>!r.has(a));return cr(e,o)}var mt={};a(mt,{AVATAR_ROOT_NAME:()=>tt,Badge:()=>dt,BrandLogo:()=>ct,Image:()=>De,Indicator:()=>it,Notification:()=>pt,Root:()=>nt,Status:()=>lt,avatarRingVariants:()=>at,avatarStatusVariants:()=>st,avatarVariants:()=>be});function oe(e,t,r,o,a){let i=P__default.Children.map(e,(s,l)=>{if(!P__default.isValidElement(s))return s;let d=s.type?.displayName||"",p=r.includes(d)?t:{},c=s.props;return P__default.cloneElement(s,{...p,key:`${o}-${l}`},oe(c?.children,t,r,o,c?.asChild))});return a?i?.[0]:i}function je(e){let t=P.useId();return jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 80 80",...e,children:[jsxs("g",{fill:"#fff",clipPath:`url(#${t})`,children:[jsx("ellipse",{cx:40,cy:78,fillOpacity:.72,rx:32,ry:24}),jsx("circle",{cx:40,cy:32,r:16,opacity:.9})]}),jsx("defs",{children:jsx("clipPath",{id:t,children:jsx("rect",{width:80,height:80,fill:"#fff",rx:40})})})]})}function et(e){let t=P.useId(),r=P.useId(),o=P.useId();return jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:56,height:56,fill:"none",viewBox:"0 0 56 56",...e,children:[jsxs("g",{clipPath:`url(#${t})`,children:[jsx("rect",{width:56,height:56,className:"fill-bg-soft",rx:28}),jsx("path",{className:"fill-bg-soft",d:"M0 0h56v56H0z"}),jsx("g",{filter:`url(#${r})`,opacity:.48,children:jsx("path",{fill:"#fff",d:"M7 24.9a2.8 2.8 0 012.8-2.8h21a2.8 2.8 0 012.8 2.8v49a2.8 2.8 0 01-2.8 2.8h-21A2.8 2.8 0 017 73.9v-49z"})}),jsx("path",{className:"fill-bg-soft",d:"M12.6 28.7a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2z"}),jsx("g",{filter:`url(#${o})`,children:jsx("path",{fill:"#fff",fillOpacity:.8,d:"M21 14a2.8 2.8 0 012.8-2.8h21a2.8 2.8 0 012.8 2.8v49a2.8 2.8 0 01-2.8 2.8h-21A2.8 2.8 0 0121 63V14z"})}),jsx("path",{className:"fill-bg-soft",d:"M26.6 17.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7V22a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm9.8-29.4a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7V22a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2zm0 9.8a.7.7 0 01.7-.7h4.2a.7.7 0 01.7.7v4.2a.7.7 0 01-.7.7h-4.2a.7.7 0 01-.7-.7v-4.2z"})]}),jsxs("defs",{children:[jsxs("filter",{id:r,width:34.6,height:62.6,x:3,y:18.1,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feGaussianBlur",{in:"BackgroundImageFix",stdDeviation:2}),jsx("feComposite",{in2:"SourceAlpha",operator:"in",result:"effect1_backgroundBlur_36237_4888"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_backgroundBlur_36237_4888",result:"shape"})]}),jsxs("filter",{id:o,width:42.6,height:70.6,x:13,y:3.2,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feGaussianBlur",{in:"BackgroundImageFix",stdDeviation:4}),jsx("feComposite",{in2:"SourceAlpha",operator:"in",result:"effect1_backgroundBlur_36237_4888"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_backgroundBlur_36237_4888",result:"shape"}),jsx("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),jsx("feOffset",{dy:4}),jsx("feGaussianBlur",{stdDeviation:2}),jsx("feComposite",{in2:"hardAlpha",k2:-1,k3:1,operator:"arithmetic"}),jsx("feColorMatrix",{values:"0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.25 0"}),jsx("feBlend",{in2:"shape",result:"effect2_innerShadow_36237_4888"})]}),jsx("clipPath",{id:t,children:jsx("rect",{width:56,height:56,fill:"#fff",rx:28})})]})]})}var tt="AvatarRoot",rt="AvatarImage",ot="AvatarIndicator",dr="AvatarStatus",mr="AvatarBrandLogo",ur="AvatarNotification",fr="AvatarBadge",Ve=Slot.Root,be=b({slots:{root:["relative flex shrink-0 items-center justify-center rounded-full","text-center uppercase select-none"],image:"size-full rounded-full object-cover",indicator:"absolute flex size-32 items-center justify-center drop-shadow-[0_2px_4px_#1b1c1d0a]"},variants:{withRing:{true:""},size:{80:{root:"size-80 text-title-h5"},72:{root:"size-72 text-title-h5"},64:{root:"size-64 text-title-h5"},56:{root:"size-56 text-label-lg"},48:{root:"size-48 text-label-lg"},42:{root:"size-42 text-label-md"},38:{root:"size-38 text-label-md"},32:{root:"size-32 text-label-sm"},24:{root:"size-24 text-label-xs"},20:{root:"size-20 text-label-xs"}},color:{gray:{root:"bg-bg-soft text-static-black/80"},yellow:{root:"bg-yellow-500 text-static-white"},blue:{root:"bg-blue-500 text-static-white"},sky:{root:"bg-sky-500 text-static-white"},purple:{root:"bg-purple-500 text-static-white"},red:{root:"bg-red-500 text-static-white"},green:{root:"bg-green-500 text-static-white"},teal:{root:"bg-teal-500 text-static-white"},violet:{root:"bg-violet-500 text-static-white"},pink:{root:"bg-pink-500 text-static-white"},orange:{root:"bg-orange-500 text-static-white"}}},compoundVariants:[{size:["80","72"],class:{indicator:"-right-8"}},{size:"64",class:{indicator:"-right-8 scale-[.875]"}},{size:"56",class:{indicator:"-right-6 scale-75"}},{size:"48",class:{indicator:"-right-6 scale-[.625]"}},{size:"42",class:{indicator:"-right-6 scale-[.5725]"}},{size:"38",class:{indicator:"-right-6 scale-[.5625]"}},{size:"32",class:{indicator:"-right-6 scale-50"}},{size:"24",class:{indicator:"-right-4 scale-[.375]"}},{size:"20",class:{indicator:"-right-4 scale-[.3125]"}},{withRing:true,size:"80",class:{indicator:"-right-12"}},{withRing:true,size:"72",class:{indicator:"-right-13"}},{withRing:true,size:"64",class:{indicator:"-right-12"}},{withRing:true,size:"56",class:{indicator:"-right-10"}},{withRing:true,size:["48","42","38","32"],class:{indicator:"-right-9"}},{withRing:true,size:["24","20"],class:{indicator:"-right-7"}}],defaultVariants:{size:"48",color:"gray"}}),at=b({base:"ring-2 ring-offset-2",variants:{color:{gray:"ring-black/10",yellow:"ring-yellow-500",blue:"ring-blue-500",sky:"ring-sky-500",purple:"ring-purple-500",red:"ring-red-500",green:"ring-green-500",teal:"ring-teal-500",violet:"ring-violet-500",pink:"ring-pink-500",orange:"ring-orange-500",white:"ring-static-white",black:"ring-static-black"}},defaultVariants:{color:"gray"}}),De=P.forwardRef(({asChild:e,className:t,size:r,color:o,...a},i)=>{let s=e?Ve:"img",{image:l}=be({size:r,color:o});return jsx(s,{ref:i,className:l({class:t}),...a})});De.displayName=rt;var nt=P.forwardRef(({asChild:e,children:t,size:r,color:o,ring:a,className:i,placeholderType:s="user",...l},d)=>{let p=P.useId(),c$1=e?Ve:"div",m=a?at({color:a===true?o:typeof a=="string"?a:void 0}):void 0,{root:u}=be({size:r,color:o}),g=c(u(),m,i),h={size:r,color:o};if(!t)return jsx("div",{className:g,...l,children:jsx(De,{asChild:true,children:s==="company"?jsx(et,{}):jsx(je,{})})});let y=oe(t,h,[rt,ot],p,e);return jsx(c$1,{ref:d,className:g,...l,children:y})});nt.displayName=tt;function it({size:e,color:t,className:r,position:o="bottom",withRing:a,...i}){let{indicator:s}=be({size:e,color:t,withRing:a});return jsx("div",{className:c(s({class:r}),{"top-0 origin-top-right":o==="top","bottom-0 origin-bottom-right":o==="bottom"}),...i})}it.displayName=ot;var st=b({base:"box-content size-12 rounded-full border-4 border-bg-white",variants:{status:{online:"bg-success-base",offline:"bg-gray-500",busy:"bg-error-base",away:"bg-away-base"}},defaultVariants:{status:"online"}});function lt({status:e,className:t,...r}){return jsx("div",{className:st({status:e,class:t}),...r})}lt.displayName=dr;var ct=P.forwardRef(({asChild:e,className:t,...r},o)=>jsx(e?Ve:"img",{draggable:false,ref:o,className:c("box-content size-24 rounded-full border-2 border-bg-white",t),...r}));ct.displayName=mr;function pt({className:e,...t}){return jsx("div",{className:c("box-content size-12 rounded-full border-2 border-bg-white bg-error-base",e),...t})}pt.displayName=ur;function dt({className:e,...t}){return jsx("div",{className:c("box-content rounded-full border-2 border-bg-white bg-error-base px-6 text-static-white",e),...t})}dt.displayName=fr;function ne({className:e,variant:t="neutral",mode:r="stroke",size:o="small",...a}){return jsx(P$1,{variant:t,mode:r,size:o,className:c("absolute top-12 right-10 z-10 m-auto aspect-square rounded-full border-transparent text-text-soft hover:text-text-strong",e),...a,children:jsxs("svg",{width:"1em",height:"1em",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsx("path",{d:"M10.4854 1.99998L2.00007 10.4853",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),jsx("path",{d:"M10.4854 10.4844L2.00007 1.99908",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})})}var ze=b({slots:{root:"relative flex w-fit max-w-xl flex-col rounded-[12px] border border-stroke-soft p-0 text-md",content:"",arrowCls:"",header:"flex items-center pe-28 select-none",close:"rounded-full"},variants:{variant:{default:{root:"gap-8 bg-bg-white p-16 pt-12",close:"top-12 right-12 hover:bg-bg-weak"},accent:{root:"bg-bg-weak p-4",content:"rounded-[8px] bg-bg-white px-12 py-8 shadow-sm",header:"px-12 py-4 pb-6",close:"top-9 right-8 hover:bg-bg-white",arrowCls:"bg-bg-weak"}}},defaultVariants:{variant:"default"}});function vr({variant:e,className:t,contentClassName:r,side:o="bottom",align:a="start",arrow:i=true,unstyled:s=true,closeable:l=true,sideOffset:d=1,title:p,content:c$1,children:m,asChild:u,defaultOpen:g,open:h,onOpenChange:y,onClose:w,...v}){let{root:x,content:R,header:b,close:z,arrowCls:T}=ze({variant:e}),[k,O]=P__default.useState(g??false),N=h!==void 0,I$1=N?h:k,W=P__default.useCallback(M=>{N||O(M),y?.(M);},[N,y]);return jsxs(F,{open:I$1,onOpenChange:W,children:[N&&I$1&&jsx(J,{}),jsx(G,{className:c(N&&I$1&&"relative z-20"),asChild:u,children:m}),jsxs(H,{className:x({className:t}),arrowClassName:T(),unstyled:s,side:o,align:a,sideOffset:d,arrow:i,...v,children:[p&&jsxs("header",{className:b(),children:[jsx("h4",{className:"text-16 m-0 leading-26 font-medium text-text-strong",children:p}),l&&jsx(I,{asChild:true,onClick:w,children:jsx(ne,{size:"xsmall",mode:"ghost",className:z({class:"size-24 p-0"})})})]}),jsx("div",{className:R({className:r}),children:c$1})]})]})}function br({variant:e="default",title:t,content:r,children:o,defaultOpen:a,className:i,side:s="top",align:l="center",sideOffset:d=1,arrow:p=true,open:c$1,contentClassName:m$1,onOpenChange:u,onConfirm:g,onCancel:h,...y}){let{root:w,content:v,header:x,arrowCls:R}=ze({variant:e}),[b,z]=P__default.useState(a??false),T=c$1!==void 0,k$1=T?c$1:b,O=P__default.useCallback(M=>{T||z(M),u?.(M);},[T,u]),[N,I$1]=P__default.useState(false),W=P__default.useCallback(async()=>{O(false);try{I$1(!0),await g?.();}catch{}finally{I$1(false);}},[O,g]);return jsxs(F,{open:k$1,onOpenChange:O,children:[jsx(AnimatePresence,{children:k$1&&jsx(J,{as:m.div,...k,className:"bg-black/5"})}),jsx(G,{className:c(k$1&&"relative z-20"),children:jsx("div",{className:"inline-flex items-center",children:P__default.isValidElement(o)?P__default.cloneElement(o,{loading:N}):o})}),jsxs(H,{className:w({className:c("max-w-lg",i)}),arrowClassName:R(),unstyled:true,side:s,align:l,sideOffset:d,arrow:p,...y,children:[t&&jsxs("header",{className:x({className:"gap-6"}),children:[jsx(CircleAlert,{className:"text-red-500",size:16}),jsx("h4",{className:"m-0 text-15 leading-26 font-medium text-text-strong",children:t})]}),jsxs("div",{className:v({className:m$1}),children:[r,jsxs("div",{className:"mt-8 flex justify-end gap-12",children:[jsx(I,{unstyled:true,onClick:h,asChild:true,children:jsx(P$1,{size:"xsmall",variant:"neutral",mode:"stroke",className:"h-26",children:"Cancel"})}),jsx(P$1,{size:"xsmall",mode:"stroke",className:"h-26",onClick:W,children:"Confirm"})]})]})]})]})}function gt({...e}){return jsx(Drawer.Root,{"data-slot":"drawer",...e})}function vt({...e}){return jsx(Drawer.Trigger,{"data-slot":"drawer-trigger",...e})}function Cr({...e}){return jsx(Drawer.Portal,{"data-slot":"drawer-portal",...e})}function ke({...e}){return jsx(Drawer.Close,{"data-slot":"drawer-close",...e})}function Rr({className:e,...t}){return jsx(Drawer.Overlay,{"data-slot":"drawer-overlay",className:c("fixed inset-0 z-50 bg-black/10 data-closed:animate-out data-closed:fade-out-0 data-open:animate-in data-open:fade-in-0",e),...t})}var wr={top:"inset-x-8 top-8 max-h-[80vh]",bottom:"inset-x-8 bottom-8 mt-96 max-h-[80vh]",left:"inset-y-8 left-8 w-3/5",right:"inset-y-8 right-8 w-3/5"};function ht({className:e,direction:t,children:r,...o}){let a=P.useRef({"--initial-transform":"calc(100% + 8px)"});return jsxs(Cr,{"data-slot":"drawer-portal",children:[jsx(Rr,{}),jsx(Drawer.Content,{"data-slot":"drawer-content",style:a.current,className:c("group/drawer-content fixed z-50 flex h-auto flex-col rounded-[12px] bg-static-white outline-none",t&&wr[t],e),...o,children:r})]})}function xt({className:e,...t}){return jsx("div",{"data-slot":"drawer-header",className:c("flex flex-col px-16 py-12",e),...t})}function yt({className:e,...t}){return jsx("div",{"data-slot":"drawer-body",className:c("scrollbar-thin overflow-y-auto p-16 select-text",e),...t})}function bt({className:e,...t}){return jsx("div",{"data-slot":"drawer-footer",className:c("mt-auto flex flex-col gap-8 px-16 py-18",e),...t})}function Ct({className:e,...t}){return jsx(Drawer.Title,{"data-slot":"drawer-title",className:c("m-0 text-xl leading-32 font-medium text-text-strong",e),...t})}function Rt({className:e,...t}){return jsx(Drawer.Description,{"data-slot":"drawer-description",className:c("m-0 text-md text-text-sub",e),...t})}function Ir({direction:e="right",dismissible:t=true,skeletonItemCount:r=5,className:o,footerClassName:a,bodyClassName:i,headerClassName:s,title:l="Title",description:d,footer:p,trigger:c$1,container:m,children:u,open:g,onOpenChange:h,loading:y,handleOnly:w=true,style:v,width:x,onClose:R,onOk:b,...z}){let T=Q(),k=P__default.useRef({...v,width:x}),[O,N]=P__default.useState(false),[I,W]=P__default.useState(false),M=g!==void 0,Xt=M?g:O,te=P__default.useCallback(q=>{!q&&I||(M||N(q),h?.(q));},[M,h,I]),Jt=P__default.useCallback(async()=>{if(!b){te(false);return}let q=b();if(q instanceof Promise){W(true);try{await q,te(!1);}catch{}finally{W(false);}}else te(false);},[b,te]),re=!I&&t;return jsxs(gt,{container:m,direction:e,dismissible:re,handleOnly:w,autoFocus:true,open:Xt,onOpenChange:te,...z,children:[c$1&&jsx(vt,{asChild:true,children:c$1}),jsxs(ht,{direction:e,className:c(m&&m!==document.body&&"absolute",o),style:k.current,children:[t&&jsx(ke,{asChild:true,children:jsx(ne,{disabled:!re})}),t===false&&jsx(ne,{disabled:!re,onClick:R}),jsxs(xt,{className:c("border-b border-b-stroke-antd",s),children:[jsx(Ct,{className:"pe-42",asChild:true,children:typeof l=="string"?jsx("h3",{children:l}):jsx("div",{children:l})}),jsx(Rt,{className:c(!d&&"sr-only"),children:d})]}),jsxs(yt,{className:i,children:[y&&jsx(Sr,{count:r}),!y&&u]}),jsxs(bt,{className:c("flex-row border-t border-t-stroke-antd",a),children:[p,!p&&jsxs(Fragment,{children:[t&&jsx(ke,{asChild:true,children:jsx(P$1,{variant:"neutral",mode:"stroke",className:"w-2/5",disabled:!re,children:T("close")})}),t===false&&jsx(P$1,{variant:"neutral",mode:"stroke",className:"w-2/5",disabled:!re,onClick:R,children:T("close")}),jsx(P$1,{variant:"neutral",mode:"filled",className:"w-3/5",loading:y||I,onClick:Jt,children:T("ok")})]})]})]})]})}function Sr({count:e=5}){let t=Array.from({length:e});return jsxs("div",{className:"flex flex-col gap-16",children:[jsxs("div",{className:"flex flex-row items-center gap-12",children:[jsx(o,{className:"size-58 rounded-2xl"}),jsxs("div",{className:"flex flex-1 flex-col gap-4",children:[jsx(o,{className:"mb-4 h-14 w-3/10"}),jsx(o,{className:"h-10 w-7/10"}),jsx(o,{className:"h-10 w-9/10"})]})]}),t.map((r,o$1)=>jsxs("div",{className:"flex flex-col gap-8",children:[jsx(o,{className:"h-12 w-5/10"}),jsx(o,{className:"h-12 w-7/10"}),jsx(o,{className:"h-12 w-full"})]},o$1))]})}function Ar(e){let[t,r]=P__default.useState(false),[o,a]=P__default.useState(null),i=P__default.useCallback(p=>{a(p),r(true);},[]),s=P__default.useCallback(()=>{r(false),a(null);},[]),l=P__default.useCallback(p=>{r(p),p||a(null);},[]);return [{...e,open:t,onOpenChange:l,onClose:s},o,i,s]}var wt=async e=>{if(!e)return;if(navigator.clipboard){await navigator.clipboard.writeText(e);return}let t=document.createElement("textarea");t.setAttribute("readonly",""),t.tabIndex=-1,t.style.position="fixed",t.style.left="-9999px",t.value=e,document.body.appendChild(t);let r=document.getSelection();if(r){let o=r.rangeCount>0&&r.getRangeAt(0);t.select(),document.execCommand("copy"),o&&(r.removeAllRanges(),r.addRange(o));}document.body.removeChild(t);};var Dr={initial:{scale:.5,opacity:0,filter:"blur(2px)"},animate:{scale:1,opacity:1,filter:"blur(0px)"},exit:{scale:.5,opacity:0,filter:"blur(2px)"}},Er={opacity:{duration:.25},filter:{duration:.25},scale:{duration:.35,ease:[.34,1.56,.64,1]}},Ur={variants:Dr,initial:"initial",animate:"animate",exit:"exit",transition:Er};function Oe({initial:e=false,state:t,states:r,asDiv:o,className:a,style:i,...s}){let l=o?m.div:m.span;return jsx(AnimatePresence,{initial:e,mode:"popLayout",children:jsx(l,{className:c("inline-flex items-center justify-center",a),...Ur,style:i,...s,children:r[t]},t)})}function Me({swap:e,on:t,off:r,className:o}){return jsx(Oe,{state:e?"on":"off",states:{on:t,off:r},className:o})}function Mr({content:e,delay:t=700,tooltipDelayDuration:r=700,variant:o="neutral",mode:a="stroke",size:i$1="small",as:s="button",children:l,onCopy:d,className:p}){let c$1=Q(),[m,u]=P__default.useState(false),[g,h]=P__default.useState(false),[y,w]=P__default.useState(false),v=P__default.useRef(null),x=P__default.useRef(null);P__default.useEffect(()=>()=>{v.current&&clearTimeout(v.current),x.current&&clearTimeout(x.current);},[]);let R=P__default.useCallback(async()=>{m||(u(true),w(true),await wt(e),d?.(e),v.current=setTimeout(()=>{w(false),x.current=setTimeout(()=>u(false),150);},t));},[m,t,e,d]),b=jsx(Me,{swap:m,on:jsx(CheckCheck,{width:"1em",height:"1em"}),off:jsx(Copy,{width:"1em",height:"1em"})}),z=(()=>{switch(s){case "text":return jsx("span",{className:c("relative cursor-pointer before:absolute before:-inset-x-4 before:-inset-y-1 before:rounded-md hover:before:bg-bg-antd",p),onClick:R,children:jsx("span",{className:"relative z-1",children:l??e})});case "inline":return jsxs("span",{className:c("relative inline-flex cursor-pointer items-center gap-6 before:absolute before:-inset-x-4 before:-inset-y-1 before:rounded-md hover:before:bg-bg-antd",p),onClick:R,children:[jsx("span",{className:"relative z-1",children:l??e}),jsx("span",{className:c("inline-flex items-center text-zinc-500",m&&"text-primary-base"),children:b})]});default:return jsx(P$1,{variant:o,mode:a,size:i$1,className:c(m&&"cursor-not-allowed",p),onClick:R,startContent:b})}})();return jsx(i,{content:c$1(m?"copied":"copy"),size:i$1,open:y||g,delayDuration:r,onOpenChange:h,hideWhenDetached:true,children:z})}var Lr=b({base:"flex shrink-0 items-center justify-center rounded-2xl ring-1 ring-transparent ring-inset",variants:{variant:{filled:"text-static-white",lighter:"",outline:"ring-current"},ring:{true:""},color:{neutral:"",slate:"",red:"",orange:"",amber:"",yellow:"",lime:"",green:"",emerald:"",teal:"",cyan:"",sky:"",blue:"",indigo:"",violet:"",purple:"",fuchsia:"",pink:"",rose:""}},compoundVariants:[{variant:"filled",color:"neutral",class:"bg-black/90"},{variant:"filled",color:"slate",class:"bg-slate-500"},{variant:"filled",color:"red",class:"bg-red-500"},{variant:"filled",color:"orange",class:"bg-orange-500"},{variant:"filled",color:"amber",class:"bg-amber-500"},{variant:"filled",color:"yellow",class:"bg-yellow-500"},{variant:"filled",color:"lime",class:"bg-lime-500"},{variant:"filled",color:"green",class:"bg-green-500"},{variant:"filled",color:"emerald",class:"bg-emerald-500"},{variant:"filled",color:"teal",class:"bg-teal-500"},{variant:"filled",color:"cyan",class:"bg-cyan-500"},{variant:"filled",color:"sky",class:"bg-sky-500"},{variant:"filled",color:"blue",class:"bg-blue-500"},{variant:"filled",color:"indigo",class:"bg-indigo-500"},{variant:"filled",color:"violet",class:"bg-violet-500"},{variant:"filled",color:"purple",class:"bg-purple-500"},{variant:"filled",color:"fuchsia",class:"bg-fuchsia-500"},{variant:"filled",color:"pink",class:"bg-pink-500"},{variant:"filled",color:"rose",class:"bg-rose-500"},{variant:"filled",ring:true,color:"neutral",class:"ring-neutral-700"},{variant:"filled",ring:true,color:"slate",class:"ring-slate-600"},{variant:"filled",ring:true,color:"red",class:"ring-red-700"},{variant:"filled",ring:true,color:"orange",class:"ring-orange-600"},{variant:"filled",ring:true,color:"amber",class:"ring-amber-600"},{variant:"filled",ring:true,color:"yellow",class:"ring-yellow-600"},{variant:"filled",ring:true,color:"lime",class:"ring-lime-600"},{variant:"filled",ring:true,color:"green",class:"ring-green-600"},{variant:"filled",ring:true,color:"emerald",class:"ring-emerald-600"},{variant:"filled",ring:true,color:"teal",class:"ring-teal-600"},{variant:"filled",ring:true,color:"cyan",class:"ring-cyan-600"},{variant:"filled",ring:true,color:"sky",class:"ring-sky-600"},{variant:"filled",ring:true,color:"blue",class:"ring-blue-700"},{variant:"filled",ring:true,color:"indigo",class:"ring-indigo-600"},{variant:"filled",ring:true,color:"violet",class:"ring-violet-600"},{variant:"filled",ring:true,color:"purple",class:"ring-purple-600"},{variant:"filled",ring:true,color:"fuchsia",class:"ring-fuchsia-600"},{variant:"filled",ring:true,color:"pink",class:"ring-pink-600"},{variant:"filled",ring:true,color:"rose",class:"ring-rose-600"},{variant:"lighter",color:"neutral",class:"bg-neutral-100 text-neutral-600"},{variant:"lighter",color:"slate",class:"bg-slate-100 text-slate-500"},{variant:"lighter",color:"red",class:"bg-red-50 text-red-500"},{variant:"lighter",color:"orange",class:"bg-orange-50 text-orange-500"},{variant:"lighter",color:"amber",class:"bg-amber-50 text-amber-500"},{variant:"lighter",color:"yellow",class:"bg-yellow-50 text-yellow-500"},{variant:"lighter",color:"lime",class:"bg-lime-50 text-lime-500"},{variant:"lighter",color:"green",class:"bg-green-50 text-green-500"},{variant:"lighter",color:"emerald",class:"bg-emerald-50 text-emerald-500"},{variant:"lighter",color:"teal",class:"bg-teal-50 text-teal-500"},{variant:"lighter",color:"cyan",class:"bg-cyan-50 text-cyan-500"},{variant:"lighter",color:"sky",class:"bg-sky-50 text-sky-500"},{variant:"lighter",color:"blue",class:"bg-blue-50 text-blue-500"},{variant:"lighter",color:"indigo",class:"bg-indigo-50 text-indigo-500"},{variant:"lighter",color:"violet",class:"bg-violet-50 text-violet-500"},{variant:"lighter",color:"purple",class:"bg-purple-50 text-purple-500"},{variant:"lighter",color:"fuchsia",class:"bg-fuchsia-50 text-fuchsia-500"},{variant:"lighter",color:"pink",class:"bg-pink-50 text-pink-500"},{variant:"lighter",color:"rose",class:"bg-rose-50 text-rose-500"},{variant:["lighter","outline"],ring:true,color:"neutral",class:"ring-neutral-200"},{variant:["lighter","outline"],ring:true,color:"slate",class:"ring-slate-200"},{variant:["lighter","outline"],ring:true,color:"red",class:"ring-red-200"},{variant:["lighter","outline"],ring:true,color:"orange",class:"ring-orange-200"},{variant:["lighter","outline"],ring:true,color:"amber",class:"ring-amber-200"},{variant:["lighter","outline"],ring:true,color:"yellow",class:"ring-yellow-200"},{variant:["lighter","outline"],ring:true,color:"lime",class:"ring-lime-200"},{variant:["lighter","outline"],ring:true,color:"green",class:"ring-green-200"},{variant:["lighter","outline"],ring:true,color:"emerald",class:"ring-emerald-200"},{variant:["lighter","outline"],ring:true,color:"teal",class:"ring-teal-200"},{variant:["lighter","outline"],ring:true,color:"cyan",class:"ring-cyan-200"},{variant:["lighter","outline"],ring:true,color:"sky",class:"ring-sky-200"},{variant:["lighter","outline"],ring:true,color:"blue",class:"ring-blue-200"},{variant:["lighter","outline"],ring:true,color:"indigo",class:"ring-indigo-200"},{variant:["lighter","outline"],ring:true,color:"violet",class:"ring-violet-200"},{variant:["lighter","outline"],ring:true,color:"purple",class:"ring-purple-200"},{variant:["lighter","outline"],ring:true,color:"fuchsia",class:"ring-fuchsia-200"},{variant:["lighter","outline"],ring:true,color:"pink",class:"ring-pink-200"},{variant:["lighter","outline"],ring:true,color:"rose",class:"ring-rose-200"},{variant:"outline",color:"neutral",class:"text-neutral-500"},{variant:"outline",color:"slate",class:"text-slate-400"},{variant:"outline",color:"red",class:"text-red-500"},{variant:"outline",color:"orange",class:"text-orange-500"},{variant:"outline",color:"amber",class:"text-amber-500"},{variant:"outline",color:"yellow",class:"text-yellow-500"},{variant:"outline",color:"lime",class:"text-lime-500"},{variant:"outline",color:"green",class:"text-green-500"},{variant:"outline",color:"emerald",class:"text-emerald-500"},{variant:"outline",color:"teal",class:"text-teal-500"},{variant:"outline",color:"cyan",class:"text-cyan-500"},{variant:"outline",color:"sky",class:"text-sky-500"},{variant:"outline",color:"blue",class:"text-blue-500"},{variant:"outline",color:"indigo",class:"text-indigo-500"},{variant:"outline",color:"violet",class:"text-violet-500"},{variant:"outline",color:"purple",class:"text-purple-500"},{variant:"outline",color:"fuchsia",class:"text-fuchsia-500"},{variant:"outline",color:"pink",class:"text-pink-500"},{variant:"outline",color:"rose",class:"text-rose-500"}],defaultVariants:{variant:"outline",color:"slate"}});function wn({asChild:e,children:t,className:r,color:o,variant:a,ring:i,...s}){let l=e?Slot.Root:"div",d=Lr({variant:a,color:o,ring:i,className:r});return jsx(l,{className:d,...s,children:t})}function Nn({...e}){return jsx(Collapsible.Root,{"data-slot":"collapsible",...e})}function An({...e}){return jsx(Collapsible.CollapsibleTrigger,{"data-slot":"collapsible-trigger",...e})}function Vn({className:e,...t}){return jsx(Collapsible.CollapsibleContent,{"data-slot":"collapsible-content",className:c("collapsible-content",e),...t})}var Gr="BadgeRoot",St="BadgeIcon",Nt="BadgeDot",Le=b({slots:{root:"inline-flex w-fit appearance-none items-center justify-center border-none leading-none font-medium whitespace-nowrap transition duration-200 ease-out select-none",icon:"uicon shrink-0",dot:["uidot flex items-center justify-center","before:size-4 before:rounded-full before:bg-current"]},variants:{size:{medium:{root:"h-24 gap-4 px-10 text-md has-[>.uicon]:gap-6 has-[>.uidot]:gap-4",icon:"-mx-2 size-14",dot:"-mx-4 size-16 before:size-6"},small:{root:"h-20 gap-4 px-8 text-sm has-[>.uicon]:gap-4 has-[>.uidot]:gap-3",icon:"-mx-px size-12",dot:"-mx-4 size-16 before:size-5"},xsmall:{root:"h-16 gap-3 px-7 text-xs has-[>.uicon]:gap-4 has-[>.uidot]:gap-4",icon:"-mx-px size-10",dot:"-mx-5 size-16"}},variant:{filled:{root:"text-static-white"},outline:{root:"ring-1 ring-current ring-inset"},lighter:"",ghost:""},color:{primary:"",info:"",success:"",warning:"",error:"",neutral:""},shape:{default:"",circle:{root:"rounded-full"}},disabled:{true:{root:"cursor-not-allowed opacity-75"}}},compoundVariants:[{shape:"default",size:"xsmall",class:{root:"rounded-[3px] px-5"}},{shape:"default",size:"small",class:{root:"rounded-[4px] px-6"}},{shape:"default",size:"medium",class:{root:"rounded-lg px-7",icon:"ms-0"}},{variant:"filled",color:"primary",class:{root:"bg-primary-base"}},{variant:"filled",color:"info",class:{root:"bg-cyan-500"}},{variant:"filled",color:"success",class:{root:"bg-emerald-500"}},{variant:"filled",color:"warning",class:{root:"bg-orange-500"}},{variant:"filled",color:"error",class:{root:"bg-red-600"}},{variant:"filled",color:"neutral",class:{root:"bg-black/90"}},{variant:"outline",color:"primary",class:{root:"text-primary-base"}},{variant:"outline",color:"info",class:{root:"text-cyan-600"}},{variant:"outline",color:"success",class:{root:"text-emerald-500"}},{variant:"outline",color:"warning",class:{root:"text-orange-500"}},{variant:"outline",color:"error",class:{root:"text-red-600"}},{variant:"outline",color:"neutral",class:{root:"text-neutral-600 ring-neutral-200"}},{variant:"lighter",color:"primary",class:{root:"bg-blue-50 text-primary-base"}},{variant:"lighter",color:"info",class:{root:"bg-cyan-50 text-cyan-600"}},{variant:"lighter",color:"success",class:{root:"bg-emerald-50 text-emerald-600"}},{variant:"lighter",color:"warning",class:{root:"bg-orange-50 text-orange-600"}},{variant:"lighter",color:"error",class:{root:"bg-red-50 text-red-600"}},{variant:"lighter",color:"neutral",class:{root:"bg-neutral-100 text-neutral-600"}},{variant:"ghost",color:"primary",class:{root:"text-primary-base"}},{variant:"ghost",color:"info",class:{root:"text-cyan-600"}},{variant:"ghost",color:"success",class:{root:"text-emerald-600"}},{variant:"ghost",color:"warning",class:{root:"text-orange-600"}},{variant:"ghost",color:"error",class:{root:"text-red-600"}},{variant:"ghost",color:"neutral",class:{root:"text-neutral-600"}}],defaultVariants:{variant:"filled",color:"primary",size:"medium",shape:"default"}}),At=({asChild:e,size:t,variant:r,color:o,shape:a,children:i,className:s,disabled:l,...d})=>{let p=P.useId(),c=e?Slot.Root:"div",{root:m}=Le({variant:r,color:o,size:t,shape:a,disabled:l}),g=oe(i,{size:t,variant:r,color:o},[St,Nt],p,e);return jsx(c,{"data-slot":"badge",className:m({class:s}),...d,children:g})};At.displayName=Gr;function Vt({className:e,size:t,variant:r,color:o,as:a,...i}){let s=a||"div",{icon:l}=Le({size:t,variant:r,color:o});return jsx(s,{"data-slot":"icon",className:l({class:e}),...i})}Vt.displayName=St;function Dt({size:e,variant:t,color:r,className:o,...a}){let{dot:i}=Le({size:e,variant:t,color:r});return jsx("div",{"data-slot":"dot",className:i({class:o}),...a})}Dt.displayName=Nt;function On({icon:e,dot:t,children:r,asChild:o,...a}){return jsxs(At,{asChild:o,...a,children:[e&&!o&&jsx(Vt,{as:e}),t&&!o&&jsx(Dt,{}),r]})}function $r({className:e,scrollBarClassName:t,children:r,...o}){return jsxs(ScrollArea.Root,{"data-slot":"scroll-area",className:c("relative",e),...o,children:[jsx(ScrollArea.Viewport,{"data-slot":"scroll-area-viewport",className:"size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-2 focus-visible:ring-primary-base focus-visible:outline-1",children:r}),jsx(Et,{orientation:"vertical",className:t}),jsx(Et,{orientation:"horizontal",className:t}),jsx(ScrollArea.Corner,{})]})}function Et({className:e,orientation:t="vertical",...r}){return jsx(ScrollArea.ScrollAreaScrollbar,{"data-slot":"scroll-area-scrollbar","data-orientation":t,orientation:t,className:c("flex touch-none p-2 transition-colors select-none data-[orientation=horizontal]:h-10 data-[orientation=horizontal]:flex-col data-[orientation=horizontal]:border-t data-[orientation=horizontal]:border-t-transparent data-[orientation=vertical]:h-full data-[orientation=vertical]:w-10 data-[orientation=vertical]:border-l data-[orientation=vertical]:border-l-transparent",e),...r,children:jsx(ScrollArea.ScrollAreaThumb,{"data-slot":"scroll-area-thumb",className:"relative flex-1 rounded-full bg-stroke-sub"})})}function qr({open:e,defaultOpen:t,openDelay:r=300,closeDelay:o,asChild:a=true,arrow:i=true,content:s,children:l,onOpenChange:d,...p}){return jsxs(Yr,{"data-slot":"hover-card",open:e,defaultOpen:t,openDelay:r,closeDelay:o,onOpenChange:d,children:[jsx(Zr,{asChild:a,children:l}),jsxs(Xr,{...p,children:[s,i&&jsx(HoverCard.Arrow,{asChild:true,children:jsx(E,{className:"-translate-y-6.5"})})]})]})}function Yr({...e}){return jsx(HoverCard.Root,{"data-slot":"hover-card",...e})}function Zr({...e}){return jsx(HoverCard.Trigger,{"data-slot":"hover-card-trigger",...e})}function Xr({className:e,align:t="center",sideOffset:r=4,collisionPadding:o=16,...a}){return jsx(HoverCard.Portal,{"data-slot":"hover-card-portal",children:jsx(HoverCard.Content,{"data-slot":"hover-card-content",align:t,sideOffset:r,collisionPadding:o,className:c("z-50 rounded-2xl bg-bg-white px-10 py-6 text-md text-text-strong shadow-regular-md ring-1 ring-stroke-soft outline-hidden duration-100 ring-inset","origin-(--radix-hover-card-content-transform-origin) data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",e),...a})})}var jr={initial:{opacity:0,scale:.96,y:4,filter:"blur(2px)"},exit:{opacity:0,scale:.96,y:4,filter:"blur(2px)"},animate:{opacity:1,scale:1,y:0,filter:"blur(0px)"}},eo={type:"spring",bounce:.1,duration:.25},to={ease:[.26,.08,.25,1],duration:.27};function ro({activeKey:e,children:t,className:r,rootClassName:o,defaultCardHeight:a,initialKey:i,variants:s=jr,transition:l=to,rootTransition:d=eo}){let[p,{height:c}]=Qr(),m$1=P.useRef(a??0);c>0&&(m$1.current=c);let u=e===i?a:c||m$1.current;return jsx(a$1,{children:jsx(m.div,{"data-slot":"animation-root",className:o,initial:false,animate:{height:u},transition:d,children:jsx("div",{ref:p,"data-slot":"animation-container",children:jsx(AnimatePresence,{mode:"popLayout",initial:false,children:jsx(m.div,{"data-slot":"animation-page",variants:s,transition:l,initial:"initial",animate:"animate",exit:"exit",className:r,children:t},e)})})})})}function $(e,t){let r=P.useRef(void 0),{current:o}=r;return P.useEffect(()=>{(!t||e!==void 0)&&(r.current=e);},[e,t]),o}var so={type:"tween",duration:.3,ease:[.25,1,.5,1]},lo={type:"tween",duration:.38,ease:[.25,1,.5,1]},Re={type:"spring",stiffness:260,damping:30},co={type:"tween",duration:.35,ease:"easeIn"},po={type:"tween",duration:.35,ease:"easeOut"},mo={type:"tween",duration:.35,ease:"linear"},j={type:"tween",duration:.25,ease:"easeInOut"},Fe=[.25,.1,.25,1],Bt=1.12,uo=.93,we={type:"tween",duration:.22,ease:Fe},fo={scale:{type:"tween",duration:.22,ease:Fe},opacity:{type:"tween",duration:.16,ease:Fe}},go={type:"spring",stiffness:260,damping:30},vo=.7,ho=.9,_t="bg-white";function Lt(e){return e?vo:ho}function He(e,t){return e==="x"?{x:t}:{y:t}}function Ht(e,t=so){return {supportsDimmed:false,variants:{enterFrom:({direction:r})=>({...He(e,r===0?0:r>0?"100%":"-100%"),zIndex:1,transition:t}),active:{...He(e,0),zIndex:1,transition:t},exit:({direction:r})=>({...He(e,r<0?"100%":"-100%"),zIndex:0,transition:t})}}}function xo(){return {supportsDimmed:true,variants:{enterFrom:({direction:e,dimmed:t})=>e===0?{x:0,opacity:1,transition:Re}:{x:e>0?"100%":"-20%",opacity:e>0?1:Lt(t),zIndex:1,transition:Re},active:{x:0,opacity:1,zIndex:1,transition:Re},exit:({direction:e,dimmed:t})=>({x:e<0?"100%":"-20%",opacity:e<0?1:Lt(t),zIndex:e<0?5:0,transition:Re})}}}function yo(){return {supportsDimmed:false,variants:{enterFrom:({direction:e})=>({clipPath:e>0?"inset(0 100% 0 0)":"inset(0 0 0 0)",zIndex:1}),active:({direction:e})=>({clipPath:"inset(0 0 0 0)",zIndex:1,transition:e>0?co:void 0}),exit:({direction:e})=>e<0?{clipPath:"inset(0 100% 0 0)",zIndex:2,transition:po}:{opacity:.999,zIndex:0,transition:mo}}}}function bo(){return {supportsDimmed:false,variants:{enterFrom:({direction:e})=>e===0?{x:0,scale:1,opacity:1,zIndex:1,transition:j}:e>0?{x:"200%",opacity:1,zIndex:2,transition:j}:{scale:.7,opacity:0,zIndex:0,transition:j},active:{x:0,scale:1,opacity:1,zIndex:1,transition:j},exit:({direction:e})=>e<0?{x:"200%",opacity:1,zIndex:2,transition:j}:{x:0,scale:.7,opacity:0,zIndex:0,transition:j}}}}function Co(){return {supportsDimmed:false,variants:{enterFrom:({direction:e})=>e===0?{scale:1,opacity:1,zIndex:1,transition:we}:{scale:e>0?Bt:uo,opacity:0,zIndex:e>0?1:0,transition:we},active:{scale:1,opacity:1,zIndex:1,transition:we},exit:({direction:e})=>e<0?{scale:Bt,opacity:0,zIndex:2,transition:fo}:{scale:1,opacity:0,zIndex:0,transition:we}}}}var Ft={slide:Ht("x"),slideVertical:Ht("y",lo),slideLayers:xo(),reveal:yo(),pushSlide:bo(),zoomFade:Co()};function Pe(e,t){let r=Ft[e.animation].variants[t];return typeof r=="function"?r(e,{},{}):r}var Ro={enterFrom:e=>Pe(e,"enterFrom"),active:e=>Pe(e,"active"),exit:e=>Pe(e,"exit")};function Ge({activeKey:e,animation:t="slideLayers",dimmed:r=true,className:o,viewClassName:a,children:i}){let s=$(e),l=s!==void 0&&e!==s,d=l?e>s?1:-1:0,p=Ft[t],c$1={animation:t,direction:d,dimmed:!!(r&&p.supportsDimmed)},m$1=Pe(c$1,"active"),u=typeof m$1=="string"?m$1:{...m$1,transition:{duration:0}},g=useRef(new Map),[h,y]=Qr(),[w,v]=useState(void 0);return useLayoutEffect(()=>{if(!y.height)return;let x=g.current.get(e);(!x||Math.abs(x-y.height)>1)&&(g.current.set(e,y.height),v(y.height));},[y.height,e]),useLayoutEffect(()=>{let x=g.current.get(e);x&&v(x);},[e]),jsx(a$1,{children:jsxs(m.div,{"data-slot":"ui-transition-root",className:c("relative w-full overflow-hidden",c$1.dimmed&&"bg-black",o),initial:false,animate:{height:w},style:{height:w},transition:go,children:[!g.current.has(e)&&jsx("div",{className:"pointer-events-none absolute inset-0 opacity-0",children:jsx("div",{ref:h,className:c(_t,a),children:i})}),jsx(AnimatePresence,{initial:false,custom:c$1,mode:"sync",children:jsx(m.div,{"data-slot":"ui-transition-item",custom:c$1,variants:Ro,initial:d===0?false:"enterFrom",animate:l?"active":u,exit:"exit",className:c("absolute inset-0 size-full",_t,a),children:i},e)})]})})}function Kt(e,t){let r=$(e);P.useEffect(()=>{t&&!r&&e?Po(t):t&&!e&&r&&Gt(t);},[t,e,r]),P.useEffect(()=>()=>{t&&e&&Gt(t);},[t,e]);}function Po(e){if(e){let r=e.clientHeight,o=(r-24)/r;e.style.overflow="hidden",e.style.willChange="transform",e.style.transition="transform 250ms linear",e.style.transform=`translateY(calc(env(safe-area-inset-top, 0) - 24px)) scale(${o})`;}}function Gt(e){function t(){e.style.removeProperty("overflow"),e.style.removeProperty("will-change"),e.style.removeProperty("transition"),e.removeEventListener("transitionend",t);}e&&(e.style.removeProperty("transform"),e.addEventListener("transitionend",t));}var Io={variants:{initial:{opacity:0},animate:{opacity:.05},exit:{opacity:0}},initial:"initial",animate:"animate",exit:"exit"},So={initial:{opacity:0,y:24},animate:{opacity:1,y:0},exit:{opacity:0,y:24}},No={variants:So,initial:"initial",animate:"animate",exit:"exit"},Ao={duration:.3,delay:.35},Vo={variants:{initial:{borderRadius:24,opacity:0},exit:{borderRadius:24,opacity:0},animate:{borderRadius:24,opacity:1}},initial:"initial",animate:"animate",exit:"exit"},Do=100,Eo=300,Uo={width:440,height:680};function $e(e){return typeof e=="number"?`${e}px`:e}function zo({open:e,loading:t,visual:r$1,backgroundViewRef:o,children:a,className:i,containerClassName:s,defaultSize:l=Do,expandedSize:d=Uo,onCloseComplete:p,onContentAnimationComplete:c$1,onExpandedChangeComplete:m$1}){let[u,g]=P.useState(!!e),[h,y,w]=r(false),v=P.useRef(false),x=P.useRef(null),R=P.useRef(false),b=P.useRef(null),z=P.useRef({"--modal-size":$e(l),"--modal-expanded-width":$e(d.width),"--modal-expanded-height":$e(d.height)});Kt(!!(e&&h&&o?.current),o?.current);let T=P.useCallback(()=>{b.current&&clearTimeout(b.current),b.current=setTimeout(()=>{b.current=null,g(false);},Eo);},[]),k=P.useCallback(()=>{x.current!==null&&(m$1?.(x.current),x.current=null),v.current&&(v.current=false,T());},[m$1,T]),O=P.useCallback(()=>{R.current&&(R.current=false,p?.());},[p]),N=P.useCallback(I=>{if(I==="animate"){c$1?.("entered");return}I==="exit"&&c$1?.("exited");},[c$1]);return P.useEffect(()=>{e&&(b.current&&(clearTimeout(b.current),b.current=null),v.current=false,R.current=false,g(true));},[e]),P.useEffect(()=>{if(u){if(e){if(t){h&&(x.current=false),w();return}h||(x.current=true),y();return}if(R.current=true,!v.current){if(h){x.current=false,v.current=true,w();return}T();}}},[w,h,t,e,u,T,y]),P.useEffect(()=>()=>{b.current&&clearTimeout(b.current);},[]),jsx(a$1,{children:jsx(AnimatePresence,{onExitComplete:O,children:u&&jsxs(Portal.Root,{style:z.current,"data-slot":"ui-modal-root",children:[jsx(m.div,{"data-slot":"ui-modal-backdrop",className:"fixed inset-0 z-10 bg-black",...Io}),jsxs(m.div,{layout:true,"data-slot":"ui-modal-container","data-state":h&&"expanded",className:c("flex flex-col items-center justify-start bg-white p-16 ring-1 ring-stone-950/6","fixed top-1/2 left-1/2 z-20 -translate-x-1/2 -translate-y-1/2","h-(--modal-size) w-(--modal-size)","data-[state=expanded]:h-(--modal-expanded-height) data-[state=expanded]:w-(--modal-expanded-width)",s),onLayoutAnimationComplete:k,...Vo,children:[jsx(m.div,{"data-slot":"ui-modal-visual",layout:true,children:r$1}),jsx(AnimatePresence,{children:h&&jsx(m.div,{"data-slot":"ui-modal-content",onAnimationComplete:N,...No,transition:Ao,className:c("flex w-full flex-col overflow-hidden",i),children:a},"content")})]})]})})})}var qt=P__default.createContext(null);function ko(){let e=P__default.useContext(qt);if(!e)throw new Error("useUIScreen must be used within <UIScreen>");return e}function qe({value:e,animation:t,className:r,children:o}){return jsx(Fragment,{children:o})}qe.displayName="UIScreen.View";function Oo(e){return P__default.isValidElement(e)&&e.type===qe}function Yt(e,t=[]){return P__default.Children.forEach(e,r=>{if(P__default.isValidElement(r)&&r.type===P__default.Fragment){Yt(r.props.children,t);return}Oo(r)&&t.push({value:r.props.value,animation:r.props.animation,className:r.props.className,activeKey:t.length,children:r.props.children});}),t}function Mo(e){let t=new Set;e.forEach(({value:r})=>{if(t.has(r))throw new Error(`Duplicate UIScreen.View value "${String(r)}".`);t.add(r);});}function Zt({screen:e,defaultScreen:t,onScreenChange:r,children:o,...a}){let i=e!==void 0,[s,l]=P__default.useState(t),d=e??s,p=$(d),c$1=P__default.useRef(null),m=Yt(o);if(!m.length)throw new Error("UIScreen requires at least one UIScreen.View child.");if(e!==void 0&&t!==void 0)throw new Error("UIScreen accepts either screen or defaultScreen, but not both.");if(d===void 0)throw new Error("UIScreen requires either a screen or defaultScreen prop.");let u=d;Mo(m);let g=m.find(v=>v.value===u);if(!g)throw new Error(`UIScreen could not find a UIScreen.View matching screen "${String(u)}".`);let h=c$1.current,y=h!==null&&p===h.from&&u===h.to;P__default.useLayoutEffect(()=>{let v=c$1.current;v&&u!==v.from&&(c$1.current=null);},[u]);let w=P__default.useMemo(()=>({screen:u,navigate:(v,x)=>{let R=x?.animation;c$1.current=v!==u&&R?{from:u,to:v,animation:R}:null,i||l(v),r?.(v);}}),[i,r,u]);return jsx(qt.Provider,{value:w,children:jsx(Ge,{...a,animation:(y?h.animation:g.animation)??a.animation,viewClassName:c(a.viewClassName,g.className),activeKey:g.activeKey,children:g.children})})}Zt.displayName="UIScreen";var Bo=Object.assign(Zt,{View:qe});var Lo=()=>{let[,e]=P.useState(false);return P.useCallback(()=>{e(t=>!t);},[])};var Ho=(e=false)=>{let[t,r]=P.useState(e),o=P.useCallback(()=>{r(a=>!a);},[]);return [t,o]};
|
|
2
|
+
export{ro as AnimationCard,mt as Avatar,On as Badge,Nn as Collapsible,Vn as CollapsibleContent,An as CollapsibleTrigger,wn as ColorPanel,Mr as CopyableText,Ir as Drawer,qr as HoverCard,br as PopConfirm,vr as PopoverPreset,$r as ScrollArea,Oe as StateSwitcher,Me as Swap,zo as UIMorphingModal,Bo as UIScreen,Ge as UIViewTransition,da as compact,ca as findOption,oa as formatCurrency,aa as formatIntegerCompact,ra as formatNumber,na as getFirstLetters,ma as omit,cr as pick,pa as unique,Ar as useDrawer,Lo as useForceUpdate,$ as usePrevious,Ho as useToggle,ko as useUIScreen};
|