@ds-mo/ui 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (213) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +81 -0
  3. package/dist/index.css +1 -0
  4. package/dist/index.d.ts +969 -0
  5. package/dist/index.js +2623 -0
  6. package/dist/index.js.map +1 -0
  7. package/dist/r/accordion.json +79 -0
  8. package/dist/r/badge.json +69 -0
  9. package/dist/r/banner.json +90 -0
  10. package/dist/r/breadcrumb.json +70 -0
  11. package/dist/r/button-group.json +65 -0
  12. package/dist/r/button.json +137 -0
  13. package/dist/r/card.json +82 -0
  14. package/dist/r/checkbox.json +91 -0
  15. package/dist/r/divider.json +57 -0
  16. package/dist/r/empty-state.json +69 -0
  17. package/dist/r/error-boundary.json +66 -0
  18. package/dist/r/fade.json +65 -0
  19. package/dist/r/field.json +71 -0
  20. package/dist/r/header.json +67 -0
  21. package/dist/r/input.json +77 -0
  22. package/dist/r/loader.json +54 -0
  23. package/dist/r/menu.json +130 -0
  24. package/dist/r/modal.json +93 -0
  25. package/dist/r/pagination.json +80 -0
  26. package/dist/r/radio.json +85 -0
  27. package/dist/r/registry.json +1600 -0
  28. package/dist/r/scrollbar.json +68 -0
  29. package/dist/r/select.json +93 -0
  30. package/dist/r/sidebar.json +105 -0
  31. package/dist/r/skeleton.json +72 -0
  32. package/dist/r/slider.json +87 -0
  33. package/dist/r/surface.json +97 -0
  34. package/dist/r/tab-group.json +72 -0
  35. package/dist/r/tab.json +71 -0
  36. package/dist/r/table.json +110 -0
  37. package/dist/r/tag.json +110 -0
  38. package/dist/r/text.json +94 -0
  39. package/dist/r/toast.json +77 -0
  40. package/dist/r/toggle-button-group.json +65 -0
  41. package/dist/r/toggle-button.json +94 -0
  42. package/dist/r/toggle.json +65 -0
  43. package/dist/r/tooltip.json +86 -0
  44. package/package.json +80 -0
  45. package/src/components/Accordion/Accordion.module.css +66 -0
  46. package/src/components/Accordion/Accordion.stories.tsx +95 -0
  47. package/src/components/Accordion/Accordion.tsx +122 -0
  48. package/src/components/Accordion/index.ts +2 -0
  49. package/src/components/Badge/Badge.module.css +6 -0
  50. package/src/components/Badge/Badge.stories.tsx +99 -0
  51. package/src/components/Badge/Badge.tsx +23 -0
  52. package/src/components/Badge/index.ts +2 -0
  53. package/src/components/Banner/Banner.module.css +67 -0
  54. package/src/components/Banner/Banner.stories.tsx +81 -0
  55. package/src/components/Banner/Banner.tsx +109 -0
  56. package/src/components/Banner/index.ts +2 -0
  57. package/src/components/Breadcrumb/Breadcrumb.module.css +46 -0
  58. package/src/components/Breadcrumb/Breadcrumb.stories.tsx +72 -0
  59. package/src/components/Breadcrumb/Breadcrumb.tsx +68 -0
  60. package/src/components/Breadcrumb/index.ts +2 -0
  61. package/src/components/Button/Button.module.css +343 -0
  62. package/src/components/Button/Button.stories.tsx +575 -0
  63. package/src/components/Button/Button.tsx +201 -0
  64. package/src/components/Button/index.ts +10 -0
  65. package/src/components/ButtonGroup/ButtonGroup.module.css +157 -0
  66. package/src/components/ButtonGroup/ButtonGroup.stories.tsx +384 -0
  67. package/src/components/ButtonGroup/ButtonGroup.tsx +122 -0
  68. package/src/components/ButtonGroup/index.ts +2 -0
  69. package/src/components/Card/Card.module.css +36 -0
  70. package/src/components/Card/Card.stories.tsx +78 -0
  71. package/src/components/Card/Card.tsx +53 -0
  72. package/src/components/Card/index.ts +2 -0
  73. package/src/components/Checkbox/Checkbox.module.css +47 -0
  74. package/src/components/Checkbox/Checkbox.stories.tsx +129 -0
  75. package/src/components/Checkbox/Checkbox.tsx +68 -0
  76. package/src/components/Checkbox/index.ts +2 -0
  77. package/src/components/Divider/Divider.module.css +19 -0
  78. package/src/components/Divider/Divider.stories.tsx +55 -0
  79. package/src/components/Divider/Divider.tsx +28 -0
  80. package/src/components/Divider/index.ts +2 -0
  81. package/src/components/EmptyState/EmptyState.module.css +8 -0
  82. package/src/components/EmptyState/EmptyState.stories.tsx +53 -0
  83. package/src/components/EmptyState/EmptyState.tsx +31 -0
  84. package/src/components/EmptyState/index.ts +2 -0
  85. package/src/components/ErrorBoundary/ErrorBoundary.module.css +18 -0
  86. package/src/components/ErrorBoundary/ErrorBoundary.stories.tsx +38 -0
  87. package/src/components/ErrorBoundary/ErrorBoundary.tsx +50 -0
  88. package/src/components/ErrorBoundary/index.ts +2 -0
  89. package/src/components/Fade/Fade.module.css +31 -0
  90. package/src/components/Fade/Fade.stories.tsx +35 -0
  91. package/src/components/Fade/Fade.tsx +33 -0
  92. package/src/components/Fade/index.ts +2 -0
  93. package/src/components/Field/Field.module.css +5 -0
  94. package/src/components/Field/Field.stories.tsx +111 -0
  95. package/src/components/Field/Field.tsx +22 -0
  96. package/src/components/Field/index.ts +2 -0
  97. package/src/components/Header/Header.module.css +33 -0
  98. package/src/components/Header/Header.stories.tsx +52 -0
  99. package/src/components/Header/Header.tsx +42 -0
  100. package/src/components/Header/index.ts +2 -0
  101. package/src/components/Input/Input.module.css +71 -0
  102. package/src/components/Input/Input.stories.tsx +135 -0
  103. package/src/components/Input/Input.tsx +76 -0
  104. package/src/components/Input/index.ts +2 -0
  105. package/src/components/LabelWrap/LabelWrap.module.css +34 -0
  106. package/src/components/LabelWrap/LabelWrap.tsx +32 -0
  107. package/src/components/LabelWrap/index.ts +1 -0
  108. package/src/components/Loader/Loader.module.css +9 -0
  109. package/src/components/Loader/Loader.stories.tsx +44 -0
  110. package/src/components/Loader/Loader.tsx +43 -0
  111. package/src/components/Loader/index.ts +2 -0
  112. package/src/components/Menu/DestructiveMenuItem.module.css +57 -0
  113. package/src/components/Menu/DestructiveMenuItem.tsx +64 -0
  114. package/src/components/Menu/Menu.module.css +49 -0
  115. package/src/components/Menu/Menu.stories.tsx +129 -0
  116. package/src/components/Menu/Menu.tsx +269 -0
  117. package/src/components/Menu/MenuItem.module.css +84 -0
  118. package/src/components/Menu/MenuItem.tsx +101 -0
  119. package/src/components/Menu/index.ts +6 -0
  120. package/src/components/Modal/Modal.module.css +67 -0
  121. package/src/components/Modal/Modal.stories.tsx +71 -0
  122. package/src/components/Modal/Modal.tsx +122 -0
  123. package/src/components/Modal/index.ts +2 -0
  124. package/src/components/Pagination/Pagination.module.css +64 -0
  125. package/src/components/Pagination/Pagination.stories.tsx +51 -0
  126. package/src/components/Pagination/Pagination.tsx +103 -0
  127. package/src/components/Pagination/index.ts +2 -0
  128. package/src/components/Radio/Radio.module.css +61 -0
  129. package/src/components/Radio/Radio.stories.tsx +101 -0
  130. package/src/components/Radio/Radio.tsx +108 -0
  131. package/src/components/Radio/index.ts +2 -0
  132. package/src/components/Scrollbar/Scrollbar.module.css +81 -0
  133. package/src/components/Scrollbar/Scrollbar.stories.tsx +46 -0
  134. package/src/components/Scrollbar/Scrollbar.tsx +187 -0
  135. package/src/components/Scrollbar/index.ts +2 -0
  136. package/src/components/Select/Select.module.css +31 -0
  137. package/src/components/Select/Select.stories.tsx +59 -0
  138. package/src/components/Select/Select.tsx +92 -0
  139. package/src/components/Select/index.ts +2 -0
  140. package/src/components/Sidebar/Sidebar.module.css +161 -0
  141. package/src/components/Sidebar/Sidebar.stories.tsx +125 -0
  142. package/src/components/Sidebar/Sidebar.tsx +129 -0
  143. package/src/components/Sidebar/SidebarItem.tsx +57 -0
  144. package/src/components/Sidebar/SidebarSection.tsx +42 -0
  145. package/src/components/Sidebar/index.ts +6 -0
  146. package/src/components/Skeleton/Skeleton.module.css +53 -0
  147. package/src/components/Skeleton/Skeleton.stories.tsx +89 -0
  148. package/src/components/Skeleton/Skeleton.tsx +66 -0
  149. package/src/components/Skeleton/index.ts +2 -0
  150. package/src/components/Slider/Slider.module.css +62 -0
  151. package/src/components/Slider/Slider.stories.tsx +120 -0
  152. package/src/components/Slider/Slider.tsx +74 -0
  153. package/src/components/Slider/index.ts +2 -0
  154. package/src/components/Surface/Surface.module.css +222 -0
  155. package/src/components/Surface/Surface.stories.tsx +213 -0
  156. package/src/components/Surface/Surface.tsx +219 -0
  157. package/src/components/Surface/index.ts +12 -0
  158. package/src/components/Tab/Tab.module.css +66 -0
  159. package/src/components/Tab/Tab.stories.tsx +103 -0
  160. package/src/components/Tab/Tab.tsx +41 -0
  161. package/src/components/Tab/index.ts +2 -0
  162. package/src/components/TabGroup/TabGroup.module.css +26 -0
  163. package/src/components/TabGroup/TabGroup.stories.tsx +60 -0
  164. package/src/components/TabGroup/TabGroup.tsx +83 -0
  165. package/src/components/TabGroup/index.ts +2 -0
  166. package/src/components/Table/Table.module.css +130 -0
  167. package/src/components/Table/Table.stories.tsx +111 -0
  168. package/src/components/Table/Table.tsx +226 -0
  169. package/src/components/Table/index.ts +11 -0
  170. package/src/components/Tag/Tag.module.css +270 -0
  171. package/src/components/Tag/Tag.stories.tsx +399 -0
  172. package/src/components/Tag/Tag.tsx +162 -0
  173. package/src/components/Tag/index.ts +2 -0
  174. package/src/components/Text/Text.module.css +166 -0
  175. package/src/components/Text/Text.stories.tsx +212 -0
  176. package/src/components/Text/Text.tsx +181 -0
  177. package/src/components/Text/index.ts +13 -0
  178. package/src/components/Toast/Toast.module.css +91 -0
  179. package/src/components/Toast/Toast.stories.tsx +66 -0
  180. package/src/components/Toast/Toast.tsx +182 -0
  181. package/src/components/Toast/index.ts +8 -0
  182. package/src/components/Toggle/Toggle.module.css +87 -0
  183. package/src/components/Toggle/Toggle.stories.tsx +85 -0
  184. package/src/components/Toggle/Toggle.tsx +52 -0
  185. package/src/components/Toggle/index.ts +2 -0
  186. package/src/components/ToggleButton/ToggleButton.module.css +172 -0
  187. package/src/components/ToggleButton/ToggleButton.stories.tsx +299 -0
  188. package/src/components/ToggleButton/ToggleButton.tsx +118 -0
  189. package/src/components/ToggleButton/index.ts +2 -0
  190. package/src/components/ToggleButtonGroup/ToggleButtonGroup.module.css +163 -0
  191. package/src/components/ToggleButtonGroup/ToggleButtonGroup.stories.tsx +341 -0
  192. package/src/components/ToggleButtonGroup/ToggleButtonGroup.tsx +111 -0
  193. package/src/components/ToggleButtonGroup/index.ts +2 -0
  194. package/src/components/Tooltip/Tooltip.module.css +45 -0
  195. package/src/components/Tooltip/Tooltip.stories.tsx +46 -0
  196. package/src/components/Tooltip/Tooltip.tsx +224 -0
  197. package/src/components/Tooltip/index.ts +2 -0
  198. package/src/css-modules.d.ts +4 -0
  199. package/src/docs/ColorUsage.mdx +195 -0
  200. package/src/docs/ElevationUsage.mdx +95 -0
  201. package/src/docs/Introduction.mdx +97 -0
  202. package/src/docs/OpticalSizing.mdx +178 -0
  203. package/src/docs/TypographyUsage.mdx +121 -0
  204. package/src/index.ts +154 -0
  205. package/src/stories/Colors.stories.tsx +528 -0
  206. package/src/stories/Dimensions.stories.tsx +200 -0
  207. package/src/stories/Effects.stories.tsx +231 -0
  208. package/src/stories/Icons.stories.tsx +159 -0
  209. package/src/stories/Typography.stories.tsx +157 -0
  210. package/src/types/icons.ts +15 -0
  211. package/src/types/index.ts +1 -0
  212. package/src/utils/cn.ts +6 -0
  213. package/src/utils/css-tokens.ts +22 -0
package/dist/index.js ADDED
@@ -0,0 +1,2623 @@
1
+ import { jsx as o, jsxs as S, Fragment as Ze } from "react/jsx-runtime";
2
+ import le, { forwardRef as C, useState as z, useId as it, useRef as D, useCallback as ce, useEffect as q, useMemo as $e, useLayoutEffect as Pe, Component as yt, useSyncExternalStore as gt } from "react";
3
+ import bt, { createPortal as Xe } from "react-dom";
4
+ import { ChevronDown as ft, Cross as wt } from "@ds-mo/icons";
5
+ const xt = "_text_12t2m_1", Nt = "_truncate1Line_12t2m_9", St = "_truncate2Lines_12t2m_15", Mt = "_truncate3Lines_12t2m_24", $t = "_truncate4Lines_12t2m_33", kt = "_truncate5Lines_12t2m_42", Lt = "_noTruncation_12t2m_51", Bt = "_wrapNowrap_12t2m_56", It = "_wrapBalance_12t2m_64", Rt = "_wrapPretty_12t2m_68", zt = "_colorPrimary_12t2m_76", Ct = "_colorSecondary_12t2m_80", Tt = "_colorTertiary_12t2m_84", Ft = "_colorBrand_12t2m_88", At = "_colorNegative_12t2m_92", Dt = "_colorPositive_12t2m_96", Et = "_colorWarning_12t2m_100", Wt = "_colorCaution_12t2m_104", Gt = "_colorAi_12t2m_108", Ht = "_colorOnStrong_12t2m_112", Pt = "_colorOnBold_12t2m_116", Xt = "_colorInherit_12t2m_120", Ot = "_decorationNone_12t2m_128", Ut = "_decorationUnderline_12t2m_132", qt = "_decorationDottedUnderline_12t2m_138", jt = "_italic_12t2m_148", Kt = "_alignLeft_12t2m_156", Vt = "_alignCenter_12t2m_160", Yt = "_alignRight_12t2m_164", A = {
6
+ text: xt,
7
+ truncate1Line: Nt,
8
+ truncate2Lines: St,
9
+ truncate3Lines: Mt,
10
+ truncate4Lines: $t,
11
+ truncate5Lines: kt,
12
+ noTruncation: Lt,
13
+ wrapNowrap: Bt,
14
+ wrapBalance: It,
15
+ wrapPretty: Rt,
16
+ colorPrimary: zt,
17
+ colorSecondary: Ct,
18
+ colorTertiary: Tt,
19
+ colorBrand: Ft,
20
+ colorNegative: At,
21
+ colorPositive: Dt,
22
+ colorWarning: Et,
23
+ colorCaution: Wt,
24
+ colorAi: Gt,
25
+ colorOnStrong: Ht,
26
+ colorOnBold: Pt,
27
+ colorInherit: Xt,
28
+ decorationNone: Ot,
29
+ decorationUnderline: Ut,
30
+ decorationDottedUnderline: qt,
31
+ italic: jt,
32
+ alignLeft: Kt,
33
+ alignCenter: Vt,
34
+ alignRight: Yt
35
+ }, Zt = {
36
+ primary: A.colorPrimary,
37
+ secondary: A.colorSecondary,
38
+ tertiary: A.colorTertiary,
39
+ brand: A.colorBrand,
40
+ negative: A.colorNegative,
41
+ positive: A.colorPositive,
42
+ warning: A.colorWarning,
43
+ caution: A.colorCaution,
44
+ ai: A.colorAi,
45
+ "on-strong": A.colorOnStrong,
46
+ "on-bold": A.colorOnBold,
47
+ inherit: A.colorInherit
48
+ }, Jt = {
49
+ none: A.decorationNone,
50
+ underline: A.decorationUnderline,
51
+ "dotted-underline": A.decorationDottedUnderline
52
+ }, Qt = {
53
+ left: A.alignLeft,
54
+ center: A.alignCenter,
55
+ right: A.alignRight
56
+ }, en = {
57
+ 1: A.truncate1Line,
58
+ 2: A.truncate2Lines,
59
+ 3: A.truncate3Lines,
60
+ 4: A.truncate4Lines,
61
+ 5: A.truncate5Lines,
62
+ none: A.noTruncation
63
+ }, Je = (e) => e.startsWith("var(--"), $ = C(
64
+ ({
65
+ variant: e = "text-body-medium",
66
+ children: t,
67
+ color: n,
68
+ decoration: s,
69
+ italic: i,
70
+ align: a,
71
+ lineTruncation: r = "none",
72
+ wrap: l,
73
+ as: c = "p",
74
+ id: _,
75
+ htmlFor: d,
76
+ className: v = "",
77
+ style: u
78
+ }, m) => {
79
+ const b = l === "nowrap" ? A.wrapNowrap : l === "balance" ? A.wrapBalance : l === "pretty" ? A.wrapPretty : "", f = l === "nowrap" ? "" : en[r], w = [
80
+ e,
81
+ A.text,
82
+ b,
83
+ f,
84
+ n && !Je(n) ? Zt[n] : "",
85
+ s ? Jt[s] : "",
86
+ i ? A.italic : "",
87
+ a ? Qt[a] : "",
88
+ v
89
+ ].filter(Boolean).join(" "), M = {
90
+ ...u,
91
+ ...n && Je(n) ? { color: n } : {}
92
+ }, p = {
93
+ className: w,
94
+ style: Object.keys(M).length > 0 ? M : void 0,
95
+ ..._ ? { id: _ } : {},
96
+ ...c === "label" && d ? { htmlFor: d } : {}
97
+ };
98
+ return /* @__PURE__ */ o(c, { ref: m, ...p, children: t });
99
+ }
100
+ );
101
+ $.displayName = "Text";
102
+ const tn = "_surface_65ypw_7", nn = "_bgPrimary_65ypw_28", on = "_bgSecondary_65ypw_32", sn = "_bgTransparent_65ypw_36", rn = "_bgTranslucent_65ypw_40", an = "_intentBrandFaint_65ypw_51", cn = "_intentBrandMedium_65ypw_52", ln = "_intentBrandBold_65ypw_53", dn = "_intentBrandStrong_65ypw_54", _n = "_intentPositiveFaint_65ypw_57", un = "_intentPositiveMedium_65ypw_58", mn = "_intentPositiveBold_65ypw_59", hn = "_intentPositiveStrong_65ypw_60", vn = "_intentNegativeFaint_65ypw_63", pn = "_intentNegativeMedium_65ypw_64", yn = "_intentNegativeBold_65ypw_65", gn = "_intentNegativeStrong_65ypw_66", bn = "_intentWarningFaint_65ypw_69", fn = "_intentWarningMedium_65ypw_70", wn = "_intentWarningBold_65ypw_71", xn = "_intentWarningStrong_65ypw_72", Nn = "_intentCautionFaint_65ypw_75", Sn = "_intentCautionMedium_65ypw_76", Mn = "_intentCautionBold_65ypw_77", $n = "_intentCautionStrong_65ypw_78", kn = "_intentAiFaint_65ypw_81", Ln = "_intentAiMedium_65ypw_82", Bn = "_intentAiBold_65ypw_83", In = "_intentAiStrong_65ypw_84", Rn = "_intentNeutralFaint_65ypw_87", zn = "_intentNeutralMedium_65ypw_88", Cn = "_intentNeutralBold_65ypw_89", Tn = "_intentNeutralStrong_65ypw_90", Fn = "_intentWalkthroughFaint_65ypw_93", An = "_intentWalkthroughMedium_65ypw_94", Dn = "_intentWalkthroughBold_65ypw_95", En = "_intentWalkthroughStrong_65ypw_96", Wn = "_intentGuideFaint_65ypw_99", Gn = "_intentGuideMedium_65ypw_100", Hn = "_intentGuideBold_65ypw_101", Pn = "_intentGuideStrong_65ypw_102", Xn = "_elevationNone_65ypw_108", On = "_elevationDepressed_65ypw_110", Un = "_elevationDepressedMd_65ypw_114", qn = "_elevationFlat_65ypw_118", jn = "_elevationElevated_65ypw_122", Kn = "_elevationFloating_65ypw_126", Vn = "_elevationOverlayTop_65ypw_130", Yn = "_elevationOverlayRight_65ypw_134", Zn = "_elevationOverlayBottom_65ypw_138", Jn = "_elevationOverlayLeft_65ypw_142", Qn = "_edgeTop_65ypw_150", eo = "_edgeRight_65ypw_151", to = "_edgeBottom_65ypw_152", no = "_edgeLeft_65ypw_153", oo = "_radiusNone_65ypw_159", so = "_radiusXs_65ypw_160", ro = "_radiusSm_65ypw_161", io = "_radiusMd_65ypw_162", ao = "_radiusLg_65ypw_163", co = "_radiusXl_65ypw_164", lo = "_radius2xl_65ypw_165", _o = "_radiusFull_65ypw_166", uo = "_interactive_65ypw_172", mo = "_selected_65ypw_199", ho = "_inactive_65ypw_218", R = {
103
+ surface: tn,
104
+ bgPrimary: nn,
105
+ bgSecondary: on,
106
+ bgTransparent: sn,
107
+ bgTranslucent: rn,
108
+ intentBrandFaint: an,
109
+ intentBrandMedium: cn,
110
+ intentBrandBold: ln,
111
+ intentBrandStrong: dn,
112
+ intentPositiveFaint: _n,
113
+ intentPositiveMedium: un,
114
+ intentPositiveBold: mn,
115
+ intentPositiveStrong: hn,
116
+ intentNegativeFaint: vn,
117
+ intentNegativeMedium: pn,
118
+ intentNegativeBold: yn,
119
+ intentNegativeStrong: gn,
120
+ intentWarningFaint: bn,
121
+ intentWarningMedium: fn,
122
+ intentWarningBold: wn,
123
+ intentWarningStrong: xn,
124
+ intentCautionFaint: Nn,
125
+ intentCautionMedium: Sn,
126
+ intentCautionBold: Mn,
127
+ intentCautionStrong: $n,
128
+ intentAiFaint: kn,
129
+ intentAiMedium: Ln,
130
+ intentAiBold: Bn,
131
+ intentAiStrong: In,
132
+ intentNeutralFaint: Rn,
133
+ intentNeutralMedium: zn,
134
+ intentNeutralBold: Cn,
135
+ intentNeutralStrong: Tn,
136
+ intentWalkthroughFaint: Fn,
137
+ intentWalkthroughMedium: An,
138
+ intentWalkthroughBold: Dn,
139
+ intentWalkthroughStrong: En,
140
+ intentGuideFaint: Wn,
141
+ intentGuideMedium: Gn,
142
+ intentGuideBold: Hn,
143
+ intentGuideStrong: Pn,
144
+ elevationNone: Xn,
145
+ elevationDepressed: On,
146
+ elevationDepressedMd: Un,
147
+ elevationFlat: qn,
148
+ elevationElevated: jn,
149
+ elevationFloating: Kn,
150
+ elevationOverlayTop: Vn,
151
+ elevationOverlayRight: Yn,
152
+ elevationOverlayBottom: Zn,
153
+ elevationOverlayLeft: Jn,
154
+ edgeTop: Qn,
155
+ edgeRight: eo,
156
+ edgeBottom: to,
157
+ edgeLeft: no,
158
+ radiusNone: oo,
159
+ radiusXs: so,
160
+ radiusSm: ro,
161
+ radiusMd: io,
162
+ radiusLg: ao,
163
+ radiusXl: co,
164
+ radius2xl: lo,
165
+ radiusFull: _o,
166
+ interactive: uo,
167
+ selected: mo,
168
+ inactive: ho
169
+ }, vo = {
170
+ primary: R.bgPrimary,
171
+ secondary: R.bgSecondary,
172
+ transparent: R.bgTransparent,
173
+ translucent: R.bgTranslucent
174
+ }, po = {
175
+ none: R.elevationNone,
176
+ depressed: R.elevationDepressed,
177
+ "depressed-md": R.elevationDepressedMd,
178
+ flat: R.elevationFlat,
179
+ elevated: R.elevationElevated,
180
+ floating: R.elevationFloating,
181
+ overlayTop: R.elevationOverlayTop,
182
+ overlayRight: R.elevationOverlayRight,
183
+ overlayBottom: R.elevationOverlayBottom,
184
+ overlayLeft: R.elevationOverlayLeft
185
+ }, Qe = {
186
+ top: R.edgeTop,
187
+ right: R.edgeRight,
188
+ bottom: R.edgeBottom,
189
+ left: R.edgeLeft
190
+ }, at = {
191
+ none: R.radiusNone,
192
+ xs: R.radiusXs,
193
+ sm: R.radiusSm,
194
+ md: R.radiusMd,
195
+ lg: R.radiusLg,
196
+ xl: R.radiusXl,
197
+ "2xl": R.radius2xl,
198
+ full: R.radiusFull
199
+ }, yo = (e, t) => {
200
+ const n = e.charAt(0).toUpperCase() + e.slice(1), s = t.charAt(0).toUpperCase() + t.slice(1);
201
+ return R[`intent${n}${s}`] || "";
202
+ }, Ue = (e) => e in at, be = C(
203
+ ({
204
+ children: e,
205
+ background: t = "transparent",
206
+ intent: n,
207
+ contrast: s = "faint",
208
+ elevation: i = "none",
209
+ edge: a,
210
+ radius: r,
211
+ interactive: l = !1,
212
+ selected: c = !1,
213
+ inactive: _ = !1,
214
+ as: d = "div",
215
+ className: v = "",
216
+ style: u,
217
+ type: m,
218
+ ...b
219
+ }, f) => {
220
+ const w = [
221
+ R.surface,
222
+ // Background or intent+contrast
223
+ n ? yo(n, s) : vo[t],
224
+ // Elevation
225
+ po[i],
226
+ // Edge(s) — only when elevation is 'none'
227
+ ...a && i === "none" ? Array.isArray(a) ? a.map((B) => Qe[B]) : [Qe[a]] : [],
228
+ // Radius (preset only — custom handled via inline style)
229
+ r && Ue(r) ? at[r] : "",
230
+ // States
231
+ l ? R.interactive : "",
232
+ c ? R.selected : "",
233
+ _ ? R.inactive : "",
234
+ v
235
+ ].filter(Boolean).join(" "), M = {
236
+ ...u,
237
+ ...r && !Ue(r) ? { borderRadius: r } : {}
238
+ }, p = r && !Ue(r) || u && Object.keys(u).length > 0, x = {
239
+ ref: f,
240
+ className: w,
241
+ style: p ? M : void 0,
242
+ disabled: d === "button" ? _ : void 0,
243
+ type: d === "button" ? m || "button" : void 0,
244
+ ...b
245
+ };
246
+ return (
247
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
248
+ /* @__PURE__ */ o(d, { ...x, children: e })
249
+ );
250
+ }
251
+ );
252
+ be.displayName = "Surface";
253
+ const go = "_card_1idsz_6", bo = "_elevationFlat_1idsz_13", fo = "_elevationElevated_1idsz_14", wo = "_elevationFloating_1idsz_15", xo = "_radiusSm_1idsz_18", No = "_radiusMd_1idsz_19", So = "_radiusLg_1idsz_20", Mo = "_radiusXl_1idsz_21", $o = "_header_1idsz_24", ko = "_body_1idsz_29", Lo = "_footer_1idsz_33", _e = {
254
+ card: go,
255
+ elevationFlat: bo,
256
+ elevationElevated: fo,
257
+ elevationFloating: wo,
258
+ radiusSm: xo,
259
+ radiusMd: No,
260
+ radiusLg: So,
261
+ radiusXl: Mo,
262
+ header: $o,
263
+ body: ko,
264
+ footer: Lo
265
+ };
266
+ function N(...e) {
267
+ return e.filter(Boolean).join(" ");
268
+ }
269
+ const Bo = {
270
+ flat: _e.elevationFlat,
271
+ elevated: _e.elevationElevated,
272
+ floating: _e.elevationFloating
273
+ }, Io = {
274
+ sm: _e.radiusSm,
275
+ md: _e.radiusMd,
276
+ lg: _e.radiusLg,
277
+ xl: _e.radiusXl
278
+ }, Ro = C(
279
+ ({ children: e, header: t, footer: n, elevation: s = "elevated", radius: i = "lg", className: a, style: r }, l) => /* @__PURE__ */ S(
280
+ "div",
281
+ {
282
+ ref: l,
283
+ className: N(_e.card, Bo[s], Io[i], a),
284
+ style: r,
285
+ children: [
286
+ t && /* @__PURE__ */ o("div", { className: _e.header, children: t }),
287
+ /* @__PURE__ */ o("div", { className: _e.body, children: e }),
288
+ n && /* @__PURE__ */ o("div", { className: _e.footer, children: n })
289
+ ]
290
+ }
291
+ )
292
+ );
293
+ Ro.displayName = "Card";
294
+ const zo = "_labelWrap_1t38o_8", Co = "_sizeSm_1t38o_16", To = "_sizeXs_1t38o_19", Fo = "_truncate_1t38o_22", Ae = {
295
+ labelWrap: zo,
296
+ sizeSm: Co,
297
+ sizeXs: To,
298
+ truncate: Fo
299
+ }, Oe = ({ children: e, size: t = "md", truncate: n = !1, className: s }) => /* @__PURE__ */ o("span", { className: N(Ae.labelWrap, t === "sm" && Ae.sizeSm, t === "xs" && Ae.sizeXs, n && Ae.truncate, s), children: e });
300
+ Oe.displayName = "LabelWrap";
301
+ const Ao = "_loader_fz5t7_1", Do = {
302
+ loader: Ao
303
+ }, ct = ({ size: e = 20, className: t }) => /* @__PURE__ */ o(
304
+ "svg",
305
+ {
306
+ width: e,
307
+ height: e,
308
+ viewBox: "0 0 16 16",
309
+ fill: "none",
310
+ className: `${Do.loader}${t ? ` ${t}` : ""}`,
311
+ "aria-hidden": "true",
312
+ children: /* @__PURE__ */ o(
313
+ "circle",
314
+ {
315
+ cx: "8",
316
+ cy: "8",
317
+ r: "5",
318
+ stroke: "currentColor",
319
+ strokeWidth: "1",
320
+ strokeLinecap: "round",
321
+ strokeDasharray: "23.6 7.9"
322
+ }
323
+ )
324
+ }
325
+ );
326
+ ct.displayName = "Loader";
327
+ const Eo = "_button_1vroe_6", Wo = "_inactive_1vroe_35", Go = "_onMedium_1vroe_50", Ho = "_onBold_1vroe_56", Po = "_onStrong_1vroe_62", Xo = "_onAlwaysDark_1vroe_68", Oo = "_primary_1vroe_79", Uo = "_intentNone_1vroe_84", qo = "_intentBrand_1vroe_102", jo = "_intentNeutral_1vroe_103", Ko = "_intentPositive_1vroe_104", Vo = "_intentNegative_1vroe_105", Yo = "_intentWarning_1vroe_106", Zo = "_intentCaution_1vroe_107", Jo = "_intentAi_1vroe_108", Qo = "_contrastMedium_1vroe_112", es = "_contrastStrong_1vroe_126", ts = "_contrastFaint_1vroe_140", ns = "_secondary_1vroe_158", os = "_elevationFlat_1vroe_224", ss = "_elevationElevated_1vroe_228", rs = "_elevationFloating_1vroe_235", is = "_elevationNone_1vroe_248", as = "_iconOnly_1vroe_275", cs = "_labelOnly_1vroe_276", ls = "_iconAndLabel_1vroe_277", ds = "_dropdown_1vroe_278", _s = "_sizeSM_1vroe_284", us = "_sizeXS_1vroe_289", ms = "_sizeLG_1vroe_293", hs = "_rounded_1vroe_302", vs = "_badge_1vroe_324", ps = "_fullWidth_1vroe_340", Q = {
328
+ button: Eo,
329
+ inactive: Wo,
330
+ onMedium: Go,
331
+ onBold: Ho,
332
+ onStrong: Po,
333
+ onAlwaysDark: Xo,
334
+ primary: Oo,
335
+ intentNone: Uo,
336
+ intentBrand: qo,
337
+ intentNeutral: jo,
338
+ intentPositive: Ko,
339
+ intentNegative: Vo,
340
+ intentWarning: Yo,
341
+ intentCaution: Zo,
342
+ intentAi: Jo,
343
+ contrastMedium: Qo,
344
+ contrastStrong: es,
345
+ contrastFaint: ts,
346
+ secondary: ns,
347
+ elevationFlat: os,
348
+ elevationElevated: ss,
349
+ elevationFloating: rs,
350
+ elevationNone: is,
351
+ iconOnly: as,
352
+ labelOnly: cs,
353
+ iconAndLabel: ls,
354
+ dropdown: ds,
355
+ sizeSM: _s,
356
+ sizeXS: us,
357
+ sizeLG: ms,
358
+ rounded: hs,
359
+ badge: vs,
360
+ fullWidth: ps
361
+ }, ys = { xs: 12, sm: 16, md: 20, lg: 24 }, gs = {
362
+ xs: "text-caption-emphasis",
363
+ sm: "text-body-small-emphasis",
364
+ md: "text-body-medium-emphasis",
365
+ lg: "text-body-large-emphasis"
366
+ }, bs = C(
367
+ ({
368
+ as: e,
369
+ variant: t = "primary",
370
+ label: n,
371
+ icon: s,
372
+ intent: i = "brand",
373
+ size: a = "md",
374
+ rounded: r = !1,
375
+ fullWidth: l = !1,
376
+ width: c,
377
+ contrast: _ = "bold",
378
+ background: d,
379
+ dropdown: v = !1,
380
+ badgeCount: u,
381
+ elevation: m,
382
+ loading: b = !1,
383
+ onClick: f,
384
+ onMouseEnter: w,
385
+ onMouseLeave: M,
386
+ className: p,
387
+ inactive: x = !1,
388
+ type: B = "button",
389
+ id: T,
390
+ "aria-label": j,
391
+ href: F,
392
+ target: re,
393
+ rel: X
394
+ }, U) => {
395
+ const G = e ?? "button", K = !e || e === "button", te = !x && !b, ne = !!s, de = !!n, O = ne || b, ue = O && !de, ve = de && !O, E = O && de, y = ys[a], I = gs[a], h = m ?? (t === "primary" ? "none" : "flat"), g = h.charAt(0).toUpperCase() + h.slice(1), L = N(
396
+ Q.button,
397
+ Q[t],
398
+ Q[`intent${i.charAt(0).toUpperCase() + i.slice(1)}`],
399
+ a !== "md" && Q[`size${a.toUpperCase()}`],
400
+ r && Q.rounded,
401
+ (x || b) && Q.inactive,
402
+ ue && Q.iconOnly,
403
+ ve && Q.labelOnly,
404
+ E && Q.iconAndLabel,
405
+ v && Q.dropdown,
406
+ t === "primary" && i !== "none" && _ !== "bold" && Q[`contrast${_.charAt(0).toUpperCase() + _.slice(1)}`],
407
+ Q[`elevation${g}`],
408
+ d && d !== "faint" && Q[d === "always-dark" ? "onAlwaysDark" : `on${d.charAt(0).toUpperCase() + d.slice(1)}`],
409
+ l && Q.fullWidth,
410
+ p
411
+ ), H = j || n || "button", k = {};
412
+ return K && (k.type = B, k.disabled = x || b), F && (k.href = F), re && (k.target = re), X && (k.rel = X), /* @__PURE__ */ S(
413
+ G,
414
+ {
415
+ ref: U,
416
+ id: T,
417
+ className: L,
418
+ style: c ? { width: c } : void 0,
419
+ onClick: te ? f : void 0,
420
+ onMouseEnter: te ? w : void 0,
421
+ onMouseLeave: te ? M : void 0,
422
+ "aria-label": H,
423
+ "aria-busy": b || void 0,
424
+ ...k,
425
+ children: [
426
+ b ? /* @__PURE__ */ o(ct, { size: y }) : s && /* @__PURE__ */ o(s, { size: y }),
427
+ n && /* @__PURE__ */ o(Oe, { truncate: l, children: /* @__PURE__ */ o($, { variant: I, as: "span", color: "inherit", children: n }) }),
428
+ v && /* @__PURE__ */ o(ft, { size: y }),
429
+ u != null && u > 0 && /* @__PURE__ */ o("span", { className: Q.badge, children: u > 9 ? "+" : u })
430
+ ]
431
+ }
432
+ );
433
+ }
434
+ );
435
+ bs.displayName = "Button";
436
+ const fs = "_toggleButton_ywix4_11", ws = "_inactive_ywix4_38", xs = "_onMedium_ywix4_51", Ns = "_onBold_ywix4_57", Ss = "_onStrong_ywix4_63", Ms = "_onAlwaysDark_ywix4_69", $s = "_elevationElevated_ywix4_81", ks = "_elevationFlat_ywix4_91", Ls = "_elevationNone_ywix4_98", Bs = "_elevationFloating_ywix4_104", Is = "_pressed_ywix4_129", Rs = "_iconOnly_ywix4_138", zs = "_labelOnly_ywix4_139", Cs = "_iconAndLabel_ywix4_140", Ts = "_sizeSM_ywix4_146", Fs = "_sizeXS_ywix4_151", As = "_rounded_ywix4_159", me = {
437
+ toggleButton: fs,
438
+ inactive: ws,
439
+ onMedium: xs,
440
+ onBold: Ns,
441
+ onStrong: Ss,
442
+ onAlwaysDark: Ms,
443
+ elevationElevated: $s,
444
+ elevationFlat: ks,
445
+ elevationNone: Ls,
446
+ elevationFloating: Bs,
447
+ pressed: Is,
448
+ iconOnly: Rs,
449
+ labelOnly: zs,
450
+ iconAndLabel: Cs,
451
+ sizeSM: Ts,
452
+ sizeXS: Fs,
453
+ rounded: As
454
+ }, Ds = { md: 20, sm: 16, xs: 12 }, Es = {
455
+ md: "text-body-medium-emphasis",
456
+ sm: "text-body-small-emphasis",
457
+ xs: "text-caption-emphasis"
458
+ }, Ws = C(
459
+ ({
460
+ elevation: e = "elevated",
461
+ label: t,
462
+ icon: n,
463
+ size: s = "md",
464
+ rounded: i = !1,
465
+ background: a,
466
+ pressed: r,
467
+ onPressedChange: l,
468
+ inactive: c = !1,
469
+ className: _,
470
+ id: d,
471
+ "aria-label": v
472
+ }, u) => {
473
+ const m = !!n, b = !!t, f = m && !b, w = b && !m, M = m && b, p = Ds[s], x = Es[s], B = e.charAt(0).toUpperCase() + e.slice(1), T = N(
474
+ me.toggleButton,
475
+ me[`elevation${B}`],
476
+ s !== "md" && me[`size${s.toUpperCase()}`],
477
+ i && me.rounded,
478
+ c && me.inactive,
479
+ f && me.iconOnly,
480
+ w && me.labelOnly,
481
+ M && me.iconAndLabel,
482
+ a && a !== "faint" && me[a === "always-dark" ? "onAlwaysDark" : `on${a.charAt(0).toUpperCase() + a.slice(1)}`],
483
+ r && me.pressed,
484
+ _
485
+ );
486
+ return /* @__PURE__ */ S(
487
+ "button",
488
+ {
489
+ ref: u,
490
+ id: d,
491
+ className: T,
492
+ onClick: c ? void 0 : () => l(!r),
493
+ type: "button",
494
+ disabled: c,
495
+ "aria-label": v || t || "toggle",
496
+ "aria-pressed": r,
497
+ children: [
498
+ n && /* @__PURE__ */ o(n, { size: p }),
499
+ t && /* @__PURE__ */ o(Oe, { children: /* @__PURE__ */ o($, { variant: x, as: "span", color: "inherit", children: t }) })
500
+ ]
501
+ }
502
+ );
503
+ }
504
+ );
505
+ Ws.displayName = "ToggleButton";
506
+ const Gs = "_group_1u9mw_5", Hs = "_groupElevated_1u9mw_27", Ps = "_groupFlat_1u9mw_31", Xs = "_groupFloating_1u9mw_33", Os = "_groupRounded_1u9mw_37", Us = "_item_1u9mw_23", qs = "_divider_1u9mw_64", js = "_dividerGhost_1u9mw_75", Ks = "_dividerGhostXS_1u9mw_76", Vs = "_dividerGhostSM_1u9mw_77", Ys = "_dividerGhostLG_1u9mw_78", Zs = "_dividerBold_1u9mw_81", Js = "_dividerMedium_1u9mw_82", Qs = "_dividerStrong_1u9mw_83", er = "_itemShort_1u9mw_100", tr = "_first_1u9mw_94", nr = "_last_1u9mw_94", or = "_middle_1u9mw_95", sr = "_roundedFirstMD_1u9mw_145", rr = "_roundedLastMD_1u9mw_146", ir = "_roundedMidMD_1u9mw_147", ar = "_roundedFirstSM_1u9mw_150", cr = "_roundedLastSM_1u9mw_151", lr = "_roundedMidSM_1u9mw_152", dr = "_roundedFirstLG_1u9mw_155", _r = "_roundedLastLG_1u9mw_156", ur = "_roundedMidLG_1u9mw_157", Y = {
507
+ group: Gs,
508
+ groupElevated: Hs,
509
+ groupFlat: Ps,
510
+ groupFloating: Xs,
511
+ groupRounded: Os,
512
+ item: Us,
513
+ divider: qs,
514
+ dividerGhost: js,
515
+ dividerGhostXS: Ks,
516
+ dividerGhostSM: Vs,
517
+ dividerGhostLG: Ys,
518
+ dividerBold: Zs,
519
+ dividerMedium: Js,
520
+ dividerStrong: Qs,
521
+ itemShort: er,
522
+ first: tr,
523
+ last: nr,
524
+ middle: or,
525
+ roundedFirstMD: sr,
526
+ roundedLastMD: rr,
527
+ roundedMidMD: ir,
528
+ roundedFirstSM: ar,
529
+ roundedLastSM: cr,
530
+ roundedMidSM: lr,
531
+ roundedFirstLG: dr,
532
+ roundedLastLG: _r,
533
+ roundedMidLG: ur
534
+ }, mr = ({ children: e, className: t }) => {
535
+ const n = le.Children.toArray(e).filter(le.isValidElement), s = n.length, i = n[0], a = i == null ? void 0 : i.props, r = (a == null ? void 0 : a.variant) ?? "secondary", l = (a == null ? void 0 : a.elevation) ?? (r === "primary" ? "none" : "flat"), c = !!(a != null && a.rounded), _ = l.charAt(0).toUpperCase() + l.slice(1);
536
+ return /* @__PURE__ */ o(
537
+ "div",
538
+ {
539
+ className: N(
540
+ Y.group,
541
+ Y[`group${_}`],
542
+ c && Y.groupRounded,
543
+ t
544
+ ),
545
+ role: "group",
546
+ children: n.map((d, v) => {
547
+ const u = d, m = u.props, b = v === 0, f = v === s - 1, w = !b && !f, M = m.variant ?? "secondary", p = m.size ?? "md", x = m.contrast ?? "bold", B = m.intent ?? "brand", T = !!m.rounded, j = !!m.icon && !m.label, F = M === "secondary" && (m.elevation ?? "flat") === "none", re = M === "primary" && B !== "none", X = x.charAt(0).toUpperCase() + x.slice(1), U = p.toUpperCase(), G = T && !j && p !== "xs", K = N(
548
+ Y.divider,
549
+ F && Y.dividerGhost,
550
+ F && p === "xs" && Y.dividerGhostXS,
551
+ F && p === "sm" && Y.dividerGhostSM,
552
+ F && p === "lg" && Y.dividerGhostLG,
553
+ re && Y[`divider${X}`]
554
+ );
555
+ return /* @__PURE__ */ S(le.Fragment, { children: [
556
+ v > 0 && /* @__PURE__ */ o("div", { className: K, "aria-hidden": "true" }),
557
+ le.cloneElement(u, {
558
+ className: N(
559
+ m.className,
560
+ Y.item,
561
+ b && Y.first,
562
+ f && Y.last,
563
+ w && Y.middle,
564
+ // Ghost (secondary+elevation=none): ::after overlay gets 4px radius treatment
565
+ F && Y.itemShort,
566
+ // Rounded: revert inner-edge padding to base (non-pill) value
567
+ G && b && Y[`roundedFirst${U}`],
568
+ G && f && Y[`roundedLast${U}`],
569
+ G && w && Y[`roundedMid${U}`]
570
+ )
571
+ })
572
+ ] }, v);
573
+ })
574
+ }
575
+ );
576
+ };
577
+ mr.displayName = "ButtonGroup";
578
+ const hr = "_group_14dyx_5", vr = "_groupElevated_14dyx_27", pr = "_groupFlat_14dyx_31", yr = "_groupFloating_14dyx_33", gr = "_groupRounded_14dyx_37", br = "_item_14dyx_23", fr = "_divider_14dyx_66", wr = "_dividerGhost_14dyx_77", xr = "_dividerGhostXS_14dyx_78", Nr = "_dividerGhostSM_14dyx_79", Sr = "_itemPressed_14dyx_86", Mr = "_itemShort_14dyx_102", $r = "_first_14dyx_96", kr = "_last_14dyx_96", Lr = "_middle_14dyx_96", Br = "_roundedFirstMD_14dyx_156", Ir = "_roundedLastMD_14dyx_157", Rr = "_roundedMidMD_14dyx_158", zr = "_roundedFirstSM_14dyx_161", Cr = "_roundedLastSM_14dyx_162", Tr = "_roundedMidSM_14dyx_163", Z = {
579
+ group: hr,
580
+ groupElevated: vr,
581
+ groupFlat: pr,
582
+ groupFloating: yr,
583
+ groupRounded: gr,
584
+ item: br,
585
+ divider: fr,
586
+ dividerGhost: wr,
587
+ dividerGhostXS: xr,
588
+ dividerGhostSM: Nr,
589
+ itemPressed: Sr,
590
+ itemShort: Mr,
591
+ first: $r,
592
+ last: kr,
593
+ middle: Lr,
594
+ roundedFirstMD: Br,
595
+ roundedLastMD: Ir,
596
+ roundedMidMD: Rr,
597
+ roundedFirstSM: zr,
598
+ roundedLastSM: Cr,
599
+ roundedMidSM: Tr
600
+ }, Fr = ({ children: e, className: t }) => {
601
+ const n = le.Children.toArray(e).filter(le.isValidElement), s = n.length, i = n[0], a = i == null ? void 0 : i.props, r = (a == null ? void 0 : a.elevation) ?? "elevated", l = !!(a != null && a.rounded), c = r.charAt(0).toUpperCase() + r.slice(1);
602
+ return /* @__PURE__ */ o(
603
+ "div",
604
+ {
605
+ className: N(
606
+ Z.group,
607
+ Z[`group${c}`],
608
+ l && Z.groupRounded,
609
+ t
610
+ ),
611
+ role: "group",
612
+ children: n.map((_, d) => {
613
+ const v = _, u = v.props, m = d === 0, b = d === s - 1, f = !m && !b, w = u.size ?? "md", M = !!u.rounded, p = !!u.pressed, x = !!u.icon && !u.label, B = (u.elevation ?? "elevated") === "none", T = w.toUpperCase(), j = M && !x && w !== "xs", F = N(
614
+ Z.divider,
615
+ B && Z.dividerGhost,
616
+ B && w === "xs" && Z.dividerGhostXS,
617
+ B && w === "sm" && Z.dividerGhostSM
618
+ );
619
+ return /* @__PURE__ */ S(le.Fragment, { children: [
620
+ d > 0 && /* @__PURE__ */ o("div", { className: F, "aria-hidden": "true" }),
621
+ le.cloneElement(v, {
622
+ className: N(
623
+ u.className,
624
+ Z.item,
625
+ m && Z.first,
626
+ b && Z.last,
627
+ f && Z.middle,
628
+ // Ghost variant: ::after overlay gets 4px radius treatment
629
+ B && Z.itemShort,
630
+ // Ghost + pressed: selected state background chip
631
+ B && p && Z.itemPressed,
632
+ // Rounded: revert inner-edge padding to base (non-pill) value
633
+ j && m && Z[`roundedFirst${T}`],
634
+ j && b && Z[`roundedLast${T}`],
635
+ j && f && Z[`roundedMid${T}`]
636
+ )
637
+ })
638
+ ] }, d);
639
+ })
640
+ }
641
+ );
642
+ };
643
+ Fr.displayName = "ToggleButtonGroup";
644
+ const Ar = "_tag_1sd2v_6", Dr = "_sizeMd_1sd2v_27", Er = "_sizeSm_1sd2v_28", Wr = "_sizeXs_1sd2v_29", Gr = "_rounded_1sd2v_35", Hr = "_roundedLeftMD_1sd2v_46", Pr = "_roundedRightMD_1sd2v_47", Xr = "_roundedLeftSM_1sd2v_50", Or = "_roundedRightSM_1sd2v_51", Ur = "_roundedLeftXS_1sd2v_54", qr = "_roundedRightXS_1sd2v_55", jr = "_iconLeftMD_1sd2v_69", Kr = "_iconRightMD_1sd2v_70", Vr = "_iconLeftSM_1sd2v_72", Yr = "_iconRightSM_1sd2v_73", Zr = "_iconLeftXS_1sd2v_75", Jr = "_iconRightXS_1sd2v_76", Qr = "_onMedium_1sd2v_82", ei = "_onBold_1sd2v_87", ti = "_onStrong_1sd2v_92", ni = "_onAlwaysDark_1sd2v_97", oi = "_elevationFlat_1sd2v_111", si = "_intentNeutral_1sd2v_120", ri = "_contrastBold_1sd2v_120", ii = "_intentBrand_1sd2v_121", ai = "_intentAi_1sd2v_122", ci = "_intentNegative_1sd2v_123", li = "_intentWarning_1sd2v_124", di = "_intentCaution_1sd2v_125", _i = "_intentPositive_1sd2v_126", ui = "_contrastStrong_1sd2v_128", mi = "_contrastMedium_1sd2v_136", hi = "_contrastFaint_1sd2v_144", vi = "_elevationElevated_1sd2v_152", pi = "_interactive_1sd2v_206", yi = "_pressed_1sd2v_226", gi = "_removable_1sd2v_236", bi = "_removeButton_1sd2v_239", fi = "_inactive_1sd2v_270", J = {
645
+ tag: Ar,
646
+ sizeMd: Dr,
647
+ sizeSm: Er,
648
+ sizeXs: Wr,
649
+ rounded: Gr,
650
+ roundedLeftMD: Hr,
651
+ roundedRightMD: Pr,
652
+ roundedLeftSM: Xr,
653
+ roundedRightSM: Or,
654
+ roundedLeftXS: Ur,
655
+ roundedRightXS: qr,
656
+ iconLeftMD: jr,
657
+ iconRightMD: Kr,
658
+ iconLeftSM: Vr,
659
+ iconRightSM: Yr,
660
+ iconLeftXS: Zr,
661
+ iconRightXS: Jr,
662
+ onMedium: Qr,
663
+ onBold: ei,
664
+ onStrong: ti,
665
+ onAlwaysDark: ni,
666
+ elevationFlat: oi,
667
+ intentNeutral: si,
668
+ contrastBold: ri,
669
+ intentBrand: ii,
670
+ intentAi: ai,
671
+ intentNegative: ci,
672
+ intentWarning: li,
673
+ intentCaution: di,
674
+ intentPositive: _i,
675
+ contrastStrong: ui,
676
+ contrastMedium: mi,
677
+ contrastFaint: hi,
678
+ elevationElevated: vi,
679
+ interactive: pi,
680
+ pressed: yi,
681
+ removable: gi,
682
+ removeButton: bi,
683
+ inactive: fi
684
+ }, wi = { md: 20, sm: 16, xs: 12 }, xi = {
685
+ md: "text-body-medium",
686
+ sm: "text-body-small",
687
+ xs: "text-caption"
688
+ }, Ni = C(
689
+ ({
690
+ label: e,
691
+ intent: t = "neutral",
692
+ contrast: n = "faint",
693
+ elevation: s = "none",
694
+ size: i = "md",
695
+ rounded: a = !1,
696
+ icon: r,
697
+ removable: l = !1,
698
+ onRemove: c,
699
+ removeIcon: _,
700
+ maxWidth: d,
701
+ inactive: v = !1,
702
+ background: u,
703
+ onClick: m,
704
+ pressed: b,
705
+ onPressedChange: f,
706
+ className: w
707
+ }, M) => {
708
+ const p = !!m || !!f, x = l && !!c, B = wi[i], T = xi[i], j = s.charAt(0).toUpperCase() + s.slice(1), F = i.toUpperCase(), re = N(
709
+ J.tag,
710
+ J[`intent${t.charAt(0).toUpperCase() + t.slice(1)}`],
711
+ J[`contrast${n.charAt(0).toUpperCase() + n.slice(1)}`],
712
+ J[`elevation${j}`],
713
+ J[`size${i.charAt(0).toUpperCase() + i.slice(1)}`],
714
+ a && J.rounded,
715
+ // Pill padding correction — extra space-050 on bare sides (no content anchor)
716
+ a && !r && J[`roundedLeft${F}`],
717
+ a && !x && J[`roundedRight${F}`],
718
+ // Icon-edge correction — reduce padding to (height − icon) / 2 on icon sides
719
+ !!r && J[`iconLeft${F}`],
720
+ x && J[`iconRight${F}`],
721
+ l && J.removable,
722
+ p && J.interactive,
723
+ u && u !== "faint" && J[u === "always-dark" ? "onAlwaysDark" : `on${u.charAt(0).toUpperCase() + u.slice(1)}`],
724
+ v && J.inactive,
725
+ b && J.pressed,
726
+ w
727
+ ), X = d != null ? { maxWidth: typeof d == "number" ? `${d}px` : d } : void 0;
728
+ return /* @__PURE__ */ S(
729
+ "div",
730
+ {
731
+ ref: M,
732
+ className: re,
733
+ style: X,
734
+ onClick: p && !v ? () => {
735
+ f == null || f(!b), m == null || m();
736
+ } : void 0,
737
+ onKeyDown: p && !v ? (K) => {
738
+ (K.key === "Enter" || K.key === " ") && (K.preventDefault(), f == null || f(!b), m == null || m());
739
+ } : void 0,
740
+ role: p ? "button" : void 0,
741
+ tabIndex: p && !v ? 0 : void 0,
742
+ "aria-pressed": f != null ? b : void 0,
743
+ "aria-disabled": v || void 0,
744
+ children: [
745
+ r && /* @__PURE__ */ o(r, { size: B }),
746
+ /* @__PURE__ */ o(Oe, { size: i, children: /* @__PURE__ */ o($, { variant: T, as: "span", color: "inherit", children: e }) }),
747
+ l && c && /* @__PURE__ */ o(
748
+ "button",
749
+ {
750
+ type: "button",
751
+ className: J.removeButton,
752
+ onClick: (K) => {
753
+ K.stopPropagation(), c();
754
+ },
755
+ "aria-label": `Remove ${e}`,
756
+ tabIndex: -1,
757
+ children: _ ? /* @__PURE__ */ o(_, { size: B }) : /* @__PURE__ */ o(wt, { size: B })
758
+ }
759
+ )
760
+ ]
761
+ }
762
+ );
763
+ }
764
+ );
765
+ Ni.displayName = "Tag";
766
+ const Si = "_badge_1nscu_1", Mi = {
767
+ badge: Si
768
+ }, $i = ({ count: e, isSelected: t = !1, className: n }) => {
769
+ if (e === 0) return null;
770
+ const s = e > 9 ? "+" : e.toString();
771
+ return /* @__PURE__ */ o("span", { className: `${Mi.badge} ${n || ""}`, "aria-label": `${e} unread`, children: /* @__PURE__ */ o($, { variant: "text-caption-emphasis", as: "span", color: t ? "primary" : "secondary", children: s }) });
772
+ };
773
+ $i.displayName = "Badge";
774
+ const ki = "_toggle_1aw6v_1", Li = "_checked_1aw6v_35", Bi = "_thumb_1aw6v_39", Ii = "_inactive_1aw6v_62", De = {
775
+ toggle: ki,
776
+ checked: Li,
777
+ thumb: Bi,
778
+ inactive: Ii
779
+ }, Ri = C(
780
+ ({ checked: e = !1, onChange: t, inactive: n = !1, className: s, "aria-label": i }, a) => {
781
+ const [r, l] = z(!1), c = (v) => {
782
+ n || (v.preventDefault(), l(!0));
783
+ }, _ = () => {
784
+ n || !r || (l(!1), t == null || t(!e));
785
+ }, d = () => {
786
+ r && l(!1);
787
+ };
788
+ return /* @__PURE__ */ o(
789
+ "button",
790
+ {
791
+ ref: a,
792
+ type: "button",
793
+ role: "switch",
794
+ "aria-checked": e,
795
+ "aria-label": i,
796
+ disabled: n,
797
+ className: N(De.toggle, e && De.checked, n && De.inactive, s),
798
+ onMouseDown: c,
799
+ onMouseUp: _,
800
+ onMouseLeave: d,
801
+ children: /* @__PURE__ */ o("span", { className: De.thumb })
802
+ }
803
+ );
804
+ }
805
+ );
806
+ Ri.displayName = "Toggle";
807
+ const zi = "_checkbox_1brbf_1", Ci = "_inactive_1brbf_18", Ti = "_box_1brbf_25", Fi = "_boxChecked_1brbf_37", Ai = "_checkmark_1brbf_42", Be = {
808
+ checkbox: zi,
809
+ inactive: Ci,
810
+ box: Ti,
811
+ boxChecked: Fi,
812
+ checkmark: Ai
813
+ }, Di = C(
814
+ ({
815
+ label: e,
816
+ checked: t = !1,
817
+ indeterminate: n = !1,
818
+ onChange: s,
819
+ inactive: i = !1,
820
+ className: a,
821
+ checkedIcon: r,
822
+ uncheckedIcon: l,
823
+ indeterminateIcon: c
824
+ }, _) => {
825
+ const d = () => {
826
+ i || s == null || s(!t);
827
+ }, v = n || t ? "var(--color-foreground-primary)" : "var(--color-foreground-secondary)", u = n ? c : t ? r : l;
828
+ return /* @__PURE__ */ S(
829
+ "div",
830
+ {
831
+ ref: _,
832
+ role: "checkbox",
833
+ "aria-checked": n ? "mixed" : t,
834
+ "aria-inactive": i,
835
+ tabIndex: i ? -1 : 0,
836
+ className: N(Be.checkbox, i && Be.inactive, a),
837
+ onClick: d,
838
+ onKeyDown: (m) => {
839
+ (m.key === " " || m.key === "Enter") && (m.preventDefault(), d());
840
+ },
841
+ children: [
842
+ u ? /* @__PURE__ */ o(u, { size: 20, color: v }) : /* @__PURE__ */ o("span", { className: N(Be.box, (t || n) && Be.boxChecked), children: (t || n) && /* @__PURE__ */ o("span", { className: Be.checkmark, children: n ? "−" : "✓" }) }),
843
+ /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", color: "inherit", children: e })
844
+ ]
845
+ }
846
+ );
847
+ }
848
+ );
849
+ Di.displayName = "Checkbox";
850
+ const Ei = "_wrapper_14bd3_1", Wi = "_row_14bd3_16", Gi = "_input_14bd3_24", Hi = "_clearButton_14bd3_49", Pi = "_suffix_14bd3_65", Ie = {
851
+ wrapper: Ei,
852
+ row: Wi,
853
+ input: Gi,
854
+ clearButton: Hi,
855
+ suffix: Pi
856
+ }, Xi = C(
857
+ ({
858
+ value: e,
859
+ onChange: t,
860
+ id: n,
861
+ placeholder: s,
862
+ autoFocus: i = !1,
863
+ className: a,
864
+ type: r = "text",
865
+ inactive: l = !1,
866
+ onKeyDown: c,
867
+ suffix: _,
868
+ clearIcon: d,
869
+ "aria-label": v
870
+ }, u) => {
871
+ const m = r === "search" && e.length > 0 && !l, b = () => {
872
+ t({ target: { value: "" } });
873
+ };
874
+ return /* @__PURE__ */ o("div", { ref: u, className: N(Ie.wrapper, a), children: /* @__PURE__ */ S("div", { className: Ie.row, children: [
875
+ /* @__PURE__ */ o(
876
+ "input",
877
+ {
878
+ type: r,
879
+ id: n,
880
+ value: e,
881
+ onChange: t,
882
+ onKeyDown: c,
883
+ placeholder: s,
884
+ className: Ie.input,
885
+ autoFocus: i,
886
+ disabled: l,
887
+ "aria-label": v
888
+ }
889
+ ),
890
+ m && /* @__PURE__ */ o("button", { type: "button", className: Ie.clearButton, onClick: b, "aria-label": "Clear", children: d ? /* @__PURE__ */ o(d, { size: 16 }) : /* @__PURE__ */ o("span", { "aria-hidden": !0, children: "×" }) }),
891
+ _ && /* @__PURE__ */ o("div", { className: Ie.suffix, children: _ })
892
+ ] }) });
893
+ }
894
+ );
895
+ Xi.displayName = "Input";
896
+ const Oi = "_field_6azt6_1", Ui = "_labelRow_6azt6_2", qi = "_track_6azt6_4", ji = "_trackInner_6azt6_10", Ki = "_fillTrack_6azt6_16", Vi = "_fill_6azt6_16", Yi = "_trackAtMin_6azt6_27", Zi = "_thumb_6azt6_29", Ji = "_trackInactive_6azt6_49", Qi = "_input_6azt6_54", he = {
897
+ field: Oi,
898
+ labelRow: Ui,
899
+ track: qi,
900
+ trackInner: ji,
901
+ fillTrack: Ki,
902
+ fill: Vi,
903
+ trackAtMin: Yi,
904
+ thumb: Zi,
905
+ trackInactive: Ji,
906
+ input: Qi
907
+ }, ea = C(
908
+ ({ value: e, onChange: t, min: n = 0, max: s = 100, step: i = 1, label: a, id: r, inactive: l = !1, className: c }, _) => {
909
+ const d = it(), v = r ?? d, u = D(null), [m, b] = z(() => {
910
+ const M = s - n;
911
+ return M === 0 ? 0 : Math.round((e - n) / M * 100);
912
+ }), f = ce(() => {
913
+ const M = s - n;
914
+ b(M === 0 ? 0 : Math.round((e - n) / M * 100));
915
+ }, [e, n, s]);
916
+ q(() => {
917
+ f();
918
+ }, [f]);
919
+ const w = (M) => {
920
+ t(Number(M.target.value));
921
+ };
922
+ return /* @__PURE__ */ S("div", { ref: _, className: N(he.field, c), children: [
923
+ /* @__PURE__ */ S("div", { className: he.labelRow, children: [
924
+ /* @__PURE__ */ o($, { variant: "text-body-small-emphasis", as: "label", htmlFor: v, children: a }),
925
+ /* @__PURE__ */ o($, { variant: "text-body-small-emphasis", as: "span", children: e })
926
+ ] }),
927
+ /* @__PURE__ */ S(
928
+ "div",
929
+ {
930
+ ref: u,
931
+ className: N(he.track, l && he.trackInactive, m === 0 && he.trackAtMin),
932
+ style: { "--slider-pct": m },
933
+ children: [
934
+ /* @__PURE__ */ S("div", { className: he.trackInner, children: [
935
+ /* @__PURE__ */ o("div", { className: he.fillTrack, children: /* @__PURE__ */ o("div", { className: he.fill }) }),
936
+ /* @__PURE__ */ o("div", { className: he.thumb })
937
+ ] }),
938
+ /* @__PURE__ */ o(
939
+ "input",
940
+ {
941
+ type: "range",
942
+ id: v,
943
+ min: n,
944
+ max: s,
945
+ step: i,
946
+ value: e,
947
+ onChange: w,
948
+ disabled: l,
949
+ className: he.input,
950
+ "aria-valuemin": n,
951
+ "aria-valuemax": s,
952
+ "aria-valuenow": e
953
+ }
954
+ )
955
+ ]
956
+ }
957
+ )
958
+ ] });
959
+ }
960
+ );
961
+ ea.displayName = "Slider";
962
+ const ta = "_field_140we_1", na = {
963
+ field: ta
964
+ }, oa = C(
965
+ ({ label: e, children: t, id: n, className: s }, i) => /* @__PURE__ */ S("div", { ref: i, className: N(na.field, s), children: [
966
+ /* @__PURE__ */ o($, { variant: "text-body-small-emphasis", as: "label", htmlFor: n, children: e }),
967
+ t
968
+ ] })
969
+ );
970
+ oa.displayName = "Field";
971
+ const sa = "_backdrop_k4mxw_1", ra = "_closing_k4mxw_15", ia = "_dialog_k4mxw_29", aa = "_header_k4mxw_51", ca = "_subtitle_k4mxw_55", la = "_body_k4mxw_60", da = "_footer_k4mxw_65", fe = {
972
+ backdrop: sa,
973
+ closing: ra,
974
+ dialog: ia,
975
+ header: aa,
976
+ subtitle: ca,
977
+ body: la,
978
+ footer: da
979
+ }, _a = {
980
+ sm: "var(--dimension-modal-width-sm, 400px)",
981
+ md: "var(--dimension-modal-width-md, 560px)",
982
+ lg: "var(--dimension-modal-width-lg, 720px)"
983
+ }, ua = 220, ma = ({
984
+ isOpen: e,
985
+ onClose: t,
986
+ title: n,
987
+ subtitle: s,
988
+ children: i,
989
+ footer: a,
990
+ width: r = "md",
991
+ bodyClassName: l
992
+ }) => {
993
+ const c = D(null), _ = it(), [d, v] = z(!1), [u, m] = z(e), b = $e(() => r === "sm" || r === "md" || r === "lg" ? _a[r] : r, [r]);
994
+ return q(() => {
995
+ if (e)
996
+ m(!0), v(!1);
997
+ else if (u) {
998
+ v(!0);
999
+ const f = setTimeout(() => {
1000
+ m(!1), v(!1);
1001
+ }, ua);
1002
+ return () => clearTimeout(f);
1003
+ }
1004
+ }, [e, u]), q(() => {
1005
+ if (!e) return;
1006
+ const f = (w) => {
1007
+ w.key === "Escape" && t();
1008
+ };
1009
+ return document.addEventListener("keydown", f), () => document.removeEventListener("keydown", f);
1010
+ }, [e, t]), q(() => {
1011
+ if (!e || !u) return;
1012
+ const f = requestAnimationFrame(() => {
1013
+ var w;
1014
+ (w = c.current) == null || w.focus();
1015
+ });
1016
+ return () => cancelAnimationFrame(f);
1017
+ }, [e, u]), u ? Xe(
1018
+ /* @__PURE__ */ o(
1019
+ "div",
1020
+ {
1021
+ className: `${fe.backdrop} ${d ? fe.closing : ""}`,
1022
+ onMouseDown: (f) => {
1023
+ f.target === f.currentTarget && t();
1024
+ },
1025
+ children: /* @__PURE__ */ S(
1026
+ be,
1027
+ {
1028
+ ref: c,
1029
+ background: "primary",
1030
+ elevation: "floating",
1031
+ radius: "var(--dimension-radius-275, 22px)",
1032
+ className: fe.dialog,
1033
+ style: { width: `min(${b}, calc(100vw - 32px))` },
1034
+ role: "dialog",
1035
+ "aria-modal": "true",
1036
+ "aria-labelledby": _,
1037
+ tabIndex: -1,
1038
+ children: [
1039
+ /* @__PURE__ */ S("div", { className: fe.header, children: [
1040
+ /* @__PURE__ */ o($, { id: _, as: "h2", variant: "text-title-small", children: n }),
1041
+ s != null && /* @__PURE__ */ o("div", { className: fe.subtitle, children: s })
1042
+ ] }),
1043
+ /* @__PURE__ */ o("div", { className: `${fe.body} ${l ?? ""}`.trim(), children: i }),
1044
+ a != null && /* @__PURE__ */ o("div", { className: fe.footer, children: a })
1045
+ ]
1046
+ }
1047
+ )
1048
+ }
1049
+ ),
1050
+ document.body
1051
+ ) : null;
1052
+ };
1053
+ ma.displayName = "Modal";
1054
+ const ha = "_menuItem_ozcs1_1", va = "_subtext_ozcs1_15", pa = "_iconPrefix_ozcs1_17", ya = "_menuItemSelected_ozcs1_24", ga = "_content_ozcs1_26", ba = "_label_ozcs1_34", fa = "_menuItemLabelTertiary_ozcs1_37", wa = "_menuItemNegative_ozcs1_38", xa = "_menuItemInactive_ozcs1_42", Na = "_toggleSuffix_ozcs1_44", Sa = "_toggle_ozcs1_44", Ma = "_toggleOn_ozcs1_55", $a = "_toggleThumb_ozcs1_57", ka = "_checkSuffix_ozcs1_70", La = "_chevronSuffix_ozcs1_77", ee = {
1055
+ menuItem: ha,
1056
+ subtext: va,
1057
+ iconPrefix: pa,
1058
+ menuItemSelected: ya,
1059
+ content: ga,
1060
+ label: ba,
1061
+ menuItemLabelTertiary: fa,
1062
+ menuItemNegative: wa,
1063
+ menuItemInactive: xa,
1064
+ toggleSuffix: Na,
1065
+ toggle: Sa,
1066
+ toggleOn: Ma,
1067
+ toggleThumb: $a,
1068
+ checkSuffix: ka,
1069
+ chevronSuffix: La
1070
+ }, lt = C(
1071
+ ({
1072
+ label: e,
1073
+ onClick: t,
1074
+ isSelected: n = !1,
1075
+ isInactive: s = !1,
1076
+ icon: i,
1077
+ labelColor: a,
1078
+ subtext: r,
1079
+ showToggle: l = !1,
1080
+ toggleValue: c = !1,
1081
+ intent: _,
1082
+ selectionStyle: d = "highlight",
1083
+ showTrailingChevron: v = !1,
1084
+ checkIcon: u,
1085
+ chevronIcon: m
1086
+ }, b) => {
1087
+ const f = d === "radio";
1088
+ return /* @__PURE__ */ S(
1089
+ be,
1090
+ {
1091
+ ref: b,
1092
+ as: "button",
1093
+ interactive: !s,
1094
+ selected: n && !(d === "noOverlay" || f),
1095
+ radius: "sm",
1096
+ className: `${ee.menuItem} ${n ? ee.menuItemSelected : ""} ${s ? ee.menuItemInactive : ""} ${_ === "negative" ? ee.menuItemNegative : ""} ${a === "tertiary" ? ee.menuItemLabelTertiary : ""}`,
1097
+ onClick: t,
1098
+ type: "button",
1099
+ inactive: s,
1100
+ children: [
1101
+ i && /* @__PURE__ */ o("div", { className: ee.iconPrefix, children: /* @__PURE__ */ o(i, { size: 20 }) }),
1102
+ /* @__PURE__ */ S("div", { className: ee.content, children: [
1103
+ /* @__PURE__ */ o(
1104
+ $,
1105
+ {
1106
+ variant: n ? "text-body-medium-emphasis" : "text-body-medium",
1107
+ color: a,
1108
+ as: "span",
1109
+ className: ee.label,
1110
+ children: e
1111
+ }
1112
+ ),
1113
+ r && /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", className: ee.subtext, children: r })
1114
+ ] }),
1115
+ l && /* @__PURE__ */ o("div", { className: ee.toggleSuffix, children: /* @__PURE__ */ o("div", { className: `${ee.toggle} ${c ? ee.toggleOn : ""}`, children: /* @__PURE__ */ o("div", { className: ee.toggleThumb }) }) }),
1116
+ f && n && u && /* @__PURE__ */ o("div", { className: ee.checkSuffix, children: /* @__PURE__ */ o(u, { size: 20 }) }),
1117
+ v && m && /* @__PURE__ */ o("div", { className: ee.chevronSuffix, children: /* @__PURE__ */ o(m, { size: 20 }) })
1118
+ ]
1119
+ }
1120
+ );
1121
+ }
1122
+ );
1123
+ lt.displayName = "MenuItem";
1124
+ const Ba = "_destructiveMenuItem_1t03u_1", Ia = "_subtext_1t03u_19", Ra = "_progressFill_1t03u_21", za = "_content_1t03u_44", Ca = "_label_1t03u_53", Re = {
1125
+ destructiveMenuItem: Ba,
1126
+ subtext: Ia,
1127
+ progressFill: Ra,
1128
+ content: za,
1129
+ label: Ca
1130
+ }, dt = C(
1131
+ ({ label: e, onClick: t, holdDuration: n = 4e3, subtext: s }, i) => {
1132
+ const [a, r] = z(0), l = D(null), c = D(0), _ = D(null), d = () => {
1133
+ r(0), l.current && (clearTimeout(l.current), l.current = null), _.current && (cancelAnimationFrame(_.current), _.current = null);
1134
+ }, v = (b) => {
1135
+ if (b.stopPropagation(), b.preventDefault(), n === 0) {
1136
+ t();
1137
+ return;
1138
+ }
1139
+ c.current = performance.now();
1140
+ const f = () => {
1141
+ const w = performance.now() - c.current, M = Math.min(w / n * 100, 100);
1142
+ r(M), M < 100 && (_.current = requestAnimationFrame(f));
1143
+ };
1144
+ _.current = requestAnimationFrame(f), l.current = window.setTimeout(() => {
1145
+ t(), d();
1146
+ }, n);
1147
+ }, u = (b) => {
1148
+ b.stopPropagation(), d();
1149
+ }, m = (b) => {
1150
+ b.stopPropagation(), d();
1151
+ };
1152
+ return q(() => () => {
1153
+ d();
1154
+ }, []), /* @__PURE__ */ S(
1155
+ "button",
1156
+ {
1157
+ ref: i,
1158
+ className: Re.destructiveMenuItem,
1159
+ onMouseDown: v,
1160
+ onMouseUp: u,
1161
+ onMouseLeave: m,
1162
+ type: "button",
1163
+ children: [
1164
+ /* @__PURE__ */ o("div", { className: Re.progressFill, style: { width: `${a}%` } }),
1165
+ /* @__PURE__ */ S("div", { className: Re.content, children: [
1166
+ /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", className: Re.label, children: e }),
1167
+ s && /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", className: Re.subtext, children: s })
1168
+ ] })
1169
+ ]
1170
+ }
1171
+ );
1172
+ }
1173
+ );
1174
+ dt.displayName = "DestructiveMenuItem";
1175
+ function et(e, t) {
1176
+ if (typeof document > "u") return t;
1177
+ const n = getComputedStyle(document.documentElement).getPropertyValue(e).trim(), s = parseFloat(n);
1178
+ return Number.isNaN(s) ? t : s;
1179
+ }
1180
+ function _t(e, t) {
1181
+ if (typeof document > "u") return t;
1182
+ const n = getComputedStyle(document.documentElement).getPropertyValue(e).trim();
1183
+ return n.endsWith("ms") ? parseFloat(n) || t : n.endsWith("s") && (parseFloat(n) || 0) * 1e3 || t;
1184
+ }
1185
+ const Ta = "_menuContainer_ljt4d_1", Fa = "_closing_ljt4d_21", Aa = "_menuSection_ljt4d_30", Da = "_sectionHeader_ljt4d_37", Ea = "_sectionLabel_ljt4d_46", ze = {
1186
+ menuContainer: Ta,
1187
+ closing: Fa,
1188
+ menuSection: Aa,
1189
+ sectionHeader: Da,
1190
+ sectionLabel: Ea
1191
+ }, Wa = 220, ut = ({
1192
+ isOpen: e,
1193
+ onClose: t,
1194
+ anchorRef: n,
1195
+ items: s,
1196
+ sections: i,
1197
+ side: a = "bottom",
1198
+ align: r = "start",
1199
+ sideOffset: l = 4,
1200
+ alignOffset: c = 0,
1201
+ sideOffsetToken: _,
1202
+ alignOffsetToken: d,
1203
+ width: v,
1204
+ minWidth: u,
1205
+ maxWidth: m,
1206
+ matchAnchorWidth: b = !1,
1207
+ matchAnchorWidthOffset: f = 0,
1208
+ usePortal: w = !0
1209
+ }) => {
1210
+ const [M, p] = z(!1), [x, B] = z(e), [T, j] = z(!1), [F, re] = z({ x: 0, y: 0 }), [X, U] = z({ width: 0, height: 0 }), [G, K] = z({ width: 0, height: 0 }), te = D(!1), ne = D(null), de = D([]), O = i || (s ? [{ items: s }] : []), ue = O.some((h) => h.items.length > 0);
1211
+ !M && O.length > 0 && ue && (de.current = O);
1212
+ const ve = M ? de.current : O;
1213
+ if (q(() => {
1214
+ if (e)
1215
+ B(!0), p(!1), j(!1), te.current = !1;
1216
+ else if (x) {
1217
+ p(!0);
1218
+ const h = setTimeout(() => {
1219
+ B(!1), p(!1), te.current = !1;
1220
+ }, Wa);
1221
+ return () => clearTimeout(h);
1222
+ }
1223
+ }, [e, x]), Pe(() => {
1224
+ if (!e || !x || !ne.current) return;
1225
+ const h = () => {
1226
+ if (!ne.current) return;
1227
+ const g = ne.current.getBoundingClientRect();
1228
+ g.width > 0 && g.height > 0 && U({ width: g.width, height: g.height });
1229
+ };
1230
+ if (h(), requestAnimationFrame(() => requestAnimationFrame(h)), typeof ResizeObserver < "u") {
1231
+ const g = new ResizeObserver(h);
1232
+ return g.observe(ne.current), () => g.disconnect();
1233
+ }
1234
+ }, [e, x, O.length]), Pe(() => {
1235
+ if (!e || !x || !n.current || !ne.current) return;
1236
+ const h = () => {
1237
+ const L = n.current, H = ne.current;
1238
+ if (!L || !H) return;
1239
+ const k = L.getBoundingClientRect(), oe = H.getBoundingClientRect(), ie = oe.width || X.width || 200, se = oe.height || X.height || 160;
1240
+ K({ width: k.width, height: k.height });
1241
+ const ae = _ != null ? et(_, 12) : l, V = d != null ? et(d, 4) : c;
1242
+ let ke = 0, Le = 0;
1243
+ switch (a) {
1244
+ case "top":
1245
+ Le = k.top - se - ae, ke = r === "start" ? k.left + V : r === "end" ? k.right - ie + V : k.left + k.width / 2 - ie / 2 + V;
1246
+ break;
1247
+ case "bottom":
1248
+ Le = k.bottom + ae, ke = r === "start" ? k.left + V : r === "end" ? k.right - ie + V : k.left + k.width / 2 - ie / 2 + V;
1249
+ break;
1250
+ case "left":
1251
+ ke = k.left - ie - ae, Le = r === "start" ? k.top + V : r === "end" ? k.bottom - se + V : k.top + k.height / 2 - se / 2 + V;
1252
+ break;
1253
+ case "right":
1254
+ ke = k.right + ae, Le = r === "start" ? k.top + V : r === "end" ? k.bottom - se + V : k.top + k.height / 2 - se / 2 + V;
1255
+ break;
1256
+ }
1257
+ const Fe = 4;
1258
+ re({
1259
+ x: Math.min(Math.max(ke, Fe), window.innerWidth - ie - Fe),
1260
+ y: Math.min(Math.max(Le, Fe), window.innerHeight - se - Fe)
1261
+ }), te.current = !0, j(!0);
1262
+ };
1263
+ te.current || (h(), requestAnimationFrame(() => {
1264
+ te.current || h();
1265
+ }));
1266
+ const g = () => h();
1267
+ return window.addEventListener("scroll", g, !0), window.addEventListener("resize", g), () => {
1268
+ window.removeEventListener("scroll", g, !0), window.removeEventListener("resize", g);
1269
+ };
1270
+ }, [e, x, n, a, r, l, c, _, d, X.width, X.height, O.length, f]), q(() => {
1271
+ if (!e || !x) return;
1272
+ const h = (g) => {
1273
+ var H, k;
1274
+ const L = g.target;
1275
+ (H = ne.current) != null && H.contains(L) || (k = n.current) != null && k.contains(L) || t();
1276
+ };
1277
+ return document.addEventListener("mousedown", h, !0), () => document.removeEventListener("mousedown", h, !0);
1278
+ }, [e, x, t, n]), q(() => {
1279
+ if (!e) return;
1280
+ const h = (g) => {
1281
+ g.key === "Escape" && t();
1282
+ };
1283
+ return document.addEventListener("keydown", h), () => document.removeEventListener("keydown", h);
1284
+ }, [e, t]), !x || ve.length === 0) return null;
1285
+ const E = (h, g) => h.isDestructive ? /* @__PURE__ */ o(
1286
+ dt,
1287
+ {
1288
+ label: h.label,
1289
+ subtext: h.subtext,
1290
+ holdDuration: h.holdDuration ?? 4e3,
1291
+ onClick: () => {
1292
+ h.onClick(), h.keepOpenOnClick || t();
1293
+ }
1294
+ },
1295
+ g
1296
+ ) : /* @__PURE__ */ o(
1297
+ lt,
1298
+ {
1299
+ icon: h.icon,
1300
+ label: h.label,
1301
+ subtext: h.subtext,
1302
+ onClick: () => {
1303
+ h.isInactive || (h.onClick(), h.keepOpenOnClick || t());
1304
+ },
1305
+ isSelected: h.isSelected,
1306
+ isInactive: h.isInactive,
1307
+ intent: h.intent,
1308
+ showToggle: h.showToggle,
1309
+ toggleValue: h.toggleValue,
1310
+ selectionStyle: h.selectionStyle
1311
+ },
1312
+ g
1313
+ ), y = {
1314
+ position: "absolute",
1315
+ left: 0,
1316
+ top: 0,
1317
+ transform: `translate(${Math.round(F.x)}px, ${Math.round(F.y)}px)`,
1318
+ willChange: "transform",
1319
+ zIndex: 9998,
1320
+ visibility: T ? "visible" : "hidden",
1321
+ ...b && G.width > 0 ? { width: `${G.width + f}px` } : v ? { width: v } : {},
1322
+ ...u ? { minWidth: u } : {},
1323
+ ...m ? { maxWidth: m } : {}
1324
+ }, I = /* @__PURE__ */ o("div", { ref: ne, className: `${ze.menuContainer} ${M ? ze.closing : ""}`, style: y, role: "menu", "aria-label": "Menu", children: ve.map((h, g) => /* @__PURE__ */ S(
1325
+ be,
1326
+ {
1327
+ as: "div",
1328
+ className: ze.menuSection,
1329
+ edge: g < ve.length - 1 ? "bottom" : void 0,
1330
+ elevation: "none",
1331
+ children: [
1332
+ h.header && /* @__PURE__ */ o("div", { className: ze.sectionHeader, children: /* @__PURE__ */ o($, { variant: "text-body-small-emphasis", as: "span", className: ze.sectionLabel, children: h.header }) }),
1333
+ h.items.map((L, H) => E(L, H))
1334
+ ]
1335
+ },
1336
+ g
1337
+ )) });
1338
+ return w ? Xe(I, document.body) : I;
1339
+ };
1340
+ ut.displayName = "Menu";
1341
+ const Ga = "_tooltip_3kdaq_1", Ha = "_tooltipInner_3kdaq_14", Pa = "_keyHint_3kdaq_21", Xa = "_closing_3kdaq_33", Ee = {
1342
+ tooltip: Ga,
1343
+ tooltipInner: Ha,
1344
+ keyHint: Pa,
1345
+ closing: Xa
1346
+ }, Oa = 1e3, Ua = 300, qa = 200;
1347
+ let tt = 0;
1348
+ const ja = ({
1349
+ label: e,
1350
+ children: t,
1351
+ delay: n,
1352
+ side: s = "top",
1353
+ align: i = "center",
1354
+ sideOffset: a = 4,
1355
+ alignOffset: r = 0,
1356
+ shortcutKey: l,
1357
+ shortcutKeyPosition: c = "end",
1358
+ usePortal: _ = !0
1359
+ }) => {
1360
+ const d = _t("--effect-animation-delay-medium-3", Oa), v = n ?? d, u = D(null), m = D(null), b = ce(
1361
+ (E) => {
1362
+ u.current = E;
1363
+ const y = le.Children.only(t), I = "ref" in y ? y.ref : void 0;
1364
+ typeof I == "function" ? I(E) : I && typeof I == "object" && (I.current = E);
1365
+ },
1366
+ [t]
1367
+ ), [f, w] = z(!1), [M, p] = z(!1), [x, B] = z(!1), [T, j] = z({ x: 0, y: 0 }), [F, re] = z({ width: 0, height: 0 }), X = D(null), U = D(null), G = 4, K = () => {
1368
+ X.current && (clearTimeout(X.current), X.current = null);
1369
+ }, te = () => {
1370
+ if (K(), Date.now() - tt < Ua) {
1371
+ w(!0), B(!0), p(!1);
1372
+ return;
1373
+ }
1374
+ X.current = setTimeout(() => {
1375
+ X.current = null, w(!0), B(!0), p(!1);
1376
+ }, v);
1377
+ }, ne = () => {
1378
+ K(), U.current && (clearTimeout(U.current), U.current = null), !(!f && !x) && (tt = Date.now(), p(!0), U.current = setTimeout(() => {
1379
+ U.current = null, B(!1), w(!1), p(!1);
1380
+ }, qa));
1381
+ };
1382
+ q(() => () => {
1383
+ K(), U.current && clearTimeout(U.current);
1384
+ }, []), Pe(() => {
1385
+ if (!x || !m.current) return;
1386
+ const E = () => {
1387
+ if (!m.current) return;
1388
+ const y = m.current.getBoundingClientRect(), I = y.width || m.current.offsetWidth, h = y.height || m.current.offsetHeight;
1389
+ I > 0 && h > 0 && re({ width: I, height: h });
1390
+ };
1391
+ if (E(), requestAnimationFrame(E), typeof ResizeObserver < "u") {
1392
+ const y = new ResizeObserver(E);
1393
+ return y.observe(m.current), () => y.disconnect();
1394
+ }
1395
+ }, [x, e, l, c]), Pe(() => {
1396
+ if (!x || !u.current || !m.current) return;
1397
+ const E = () => {
1398
+ if (!u.current || !m.current) return;
1399
+ const y = u.current.getBoundingClientRect(), I = m.current.getBoundingClientRect().width || F.width || 80, h = m.current.getBoundingClientRect().height || F.height || 24;
1400
+ let g = 0, L = 0;
1401
+ switch (s) {
1402
+ case "top":
1403
+ L = y.top - h - a, g = i === "start" ? y.left + r : i === "end" ? y.right - I + r : y.left + y.width / 2 - I / 2 + r;
1404
+ break;
1405
+ case "bottom":
1406
+ L = y.bottom + a, g = i === "start" ? y.left + r : i === "end" ? y.right - I + r : y.left + y.width / 2 - I / 2 + r;
1407
+ break;
1408
+ case "left":
1409
+ g = y.left - I - a, L = i === "start" ? y.top + r : i === "end" ? y.bottom - h + r : y.top + y.height / 2 - h / 2 + r;
1410
+ break;
1411
+ case "right":
1412
+ g = y.right + a, L = i === "start" ? y.top + r : i === "end" ? y.bottom - h + r : y.top + y.height / 2 - h / 2 + r;
1413
+ break;
1414
+ }
1415
+ j({
1416
+ x: Math.min(Math.max(g, G), window.innerWidth - I - G),
1417
+ y: Math.min(Math.max(L, G), window.innerHeight - h - G)
1418
+ });
1419
+ };
1420
+ E(), requestAnimationFrame(() => requestAnimationFrame(E));
1421
+ }, [x, s, i, a, r, F.width, F.height, e]), q(() => {
1422
+ if (!x) return;
1423
+ const E = () => {
1424
+ if (!u.current || !m.current) return;
1425
+ const y = u.current.getBoundingClientRect(), I = F.width || 80, h = F.height || 24;
1426
+ let g = 0, L = 0;
1427
+ switch (s) {
1428
+ case "top":
1429
+ L = y.top - h - a, g = i === "start" ? y.left + r : i === "end" ? y.right - I + r : y.left + y.width / 2 - I / 2 + r;
1430
+ break;
1431
+ case "bottom":
1432
+ L = y.bottom + a, g = i === "start" ? y.left + r : i === "end" ? y.right - I + r : y.left + y.width / 2 - I / 2 + r;
1433
+ break;
1434
+ case "left":
1435
+ g = y.left - I - a, L = i === "start" ? y.top + r : i === "end" ? y.bottom - h + r : y.top + y.height / 2 - h / 2 + r;
1436
+ break;
1437
+ case "right":
1438
+ g = y.right + a, L = i === "start" ? y.top + r : i === "end" ? y.bottom - h + r : y.top + y.height / 2 - h / 2 + r;
1439
+ break;
1440
+ }
1441
+ j({
1442
+ x: Math.min(Math.max(g, G), window.innerWidth - I - G),
1443
+ y: Math.min(Math.max(L, G), window.innerHeight - h - G)
1444
+ });
1445
+ };
1446
+ return window.addEventListener("scroll", E, !0), window.addEventListener("resize", E), () => {
1447
+ window.removeEventListener("scroll", E, !0), window.removeEventListener("resize", E);
1448
+ };
1449
+ }, [x, s, i, a, r, F.width, F.height]);
1450
+ const de = l ? /* @__PURE__ */ o("div", { className: Ee.keyHint, "aria-hidden": !0, children: /* @__PURE__ */ o($, { variant: "text-caption-emphasis", as: "span", color: "primary", children: l }) }) : null, O = x ? /* @__PURE__ */ o(
1451
+ "div",
1452
+ {
1453
+ ref: m,
1454
+ className: `${Ee.tooltip} ${M ? Ee.closing : ""}`,
1455
+ style: {
1456
+ position: "fixed",
1457
+ left: 0,
1458
+ top: 0,
1459
+ transform: `translate(${Math.round(T.x)}px, ${Math.round(T.y)}px)`,
1460
+ willChange: "transform",
1461
+ zIndex: 1e4
1462
+ },
1463
+ role: "tooltip",
1464
+ children: /* @__PURE__ */ S("div", { className: Ee.tooltipInner, children: [
1465
+ l && c === "start" && de,
1466
+ /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", color: "primary", children: e }),
1467
+ l && c === "end" && de
1468
+ ] })
1469
+ }
1470
+ ) : null, ue = le.Children.only(t), ve = le.isValidElement(ue) ? le.cloneElement(ue, {
1471
+ ref: b,
1472
+ onMouseEnter: (E) => {
1473
+ var y, I;
1474
+ te(), (I = (y = ue.props).onMouseEnter) == null || I.call(y, E);
1475
+ },
1476
+ onMouseLeave: (E) => {
1477
+ var y, I;
1478
+ ne(), (I = (y = ue.props).onMouseLeave) == null || I.call(y, E);
1479
+ }
1480
+ }) : t;
1481
+ return /* @__PURE__ */ S(Ze, { children: [
1482
+ ve,
1483
+ _ ? Xe(O, document.body) : O
1484
+ ] });
1485
+ };
1486
+ ja.displayName = "Tooltip";
1487
+ const Ka = "_selectWrapper_17kkf_1", Va = "_selectButton_17kkf_6", Ya = "_chevron_17kkf_26", qe = {
1488
+ selectWrapper: Ka,
1489
+ selectButton: Va,
1490
+ chevron: Ya
1491
+ }, Za = C(
1492
+ ({ value: e, onChange: t, options: n, placeholder: s = "Select option", className: i, inactive: a = !1, id: r, chevronIcon: l }, c) => {
1493
+ const [_, d] = z(!1), v = D(null), u = n.find((w) => w.value === e), m = (u == null ? void 0 : u.label) || s, b = n.map((w) => ({
1494
+ label: w.label,
1495
+ onClick: () => {
1496
+ t(w.value), d(!1);
1497
+ },
1498
+ isSelected: w.value === e
1499
+ })), f = () => {
1500
+ a || d((w) => !w);
1501
+ };
1502
+ return /* @__PURE__ */ S("div", { ref: c, className: `${qe.selectWrapper} ${i || ""}`, children: [
1503
+ /* @__PURE__ */ S(
1504
+ be,
1505
+ {
1506
+ id: r,
1507
+ ref: v,
1508
+ as: "button",
1509
+ type: "button",
1510
+ elevation: "elevated",
1511
+ radius: "sm",
1512
+ interactive: !0,
1513
+ selected: _,
1514
+ className: qe.selectButton,
1515
+ onClick: f,
1516
+ inactive: a,
1517
+ children: [
1518
+ /* @__PURE__ */ o(
1519
+ $,
1520
+ {
1521
+ variant: "text-body-medium",
1522
+ as: "span",
1523
+ color: u ? "primary" : "secondary",
1524
+ children: m
1525
+ }
1526
+ ),
1527
+ l && /* @__PURE__ */ o("span", { className: qe.chevron, children: /* @__PURE__ */ o(l, { size: 16 }) })
1528
+ ]
1529
+ }
1530
+ ),
1531
+ /* @__PURE__ */ o(
1532
+ ut,
1533
+ {
1534
+ isOpen: _,
1535
+ onClose: () => d(!1),
1536
+ anchorRef: v,
1537
+ items: b,
1538
+ side: "bottom",
1539
+ align: "start",
1540
+ sideOffset: 4,
1541
+ alignOffset: -4,
1542
+ matchAnchorWidth: !0,
1543
+ matchAnchorWidthOffset: 8
1544
+ }
1545
+ )
1546
+ ] });
1547
+ }
1548
+ );
1549
+ Za.displayName = "Select";
1550
+ const Ja = "_bannerWrapper_xz2oj_1", Qa = "_banner_xz2oj_1", ec = "_bannerHeaderSurface_xz2oj_10", tc = "_bannerHeader_xz2oj_10", nc = "_bannerBody_xz2oj_30", oc = "_message_xz2oj_35", sc = "_floatingPosition_xz2oj_41", rc = "_floatingToast_xz2oj_49", ic = "_closing_xz2oj_55", pe = {
1551
+ bannerWrapper: Ja,
1552
+ banner: Qa,
1553
+ bannerHeaderSurface: ec,
1554
+ bannerHeader: tc,
1555
+ bannerBody: nc,
1556
+ message: oc,
1557
+ floatingPosition: sc,
1558
+ floatingToast: rc,
1559
+ closing: ic
1560
+ }, ac = 4e3, cc = 200, lc = (e, t) => t === "bold" ? "var(--color-foreground-on-bold-background-primary)" : `var(--color-foreground-${t === "faint" ? "bold" : t === "medium" ? "strong" : "medium"}-${e})`, dc = ({
1561
+ intent: e,
1562
+ contrast: t,
1563
+ message: n,
1564
+ header: s = !1,
1565
+ className: i = "",
1566
+ floating: a = !1,
1567
+ onDismiss: r
1568
+ }) => {
1569
+ const l = _t("--effect-animation-delay-long-2", ac), c = lc(e, t), [_, d] = z(!1), v = D(null), u = D(null), m = ce(() => {
1570
+ v.current && clearTimeout(v.current), u.current && clearTimeout(u.current), v.current = setTimeout(() => {
1571
+ v.current = null, d(!0), u.current = setTimeout(() => {
1572
+ u.current = null, r == null || r();
1573
+ }, cc);
1574
+ }, l);
1575
+ }, [r, l]);
1576
+ q(() => (a && n && m(), () => {
1577
+ v.current && clearTimeout(v.current), u.current && clearTimeout(u.current);
1578
+ }), [a, n, m]);
1579
+ const b = /* @__PURE__ */ o(
1580
+ "div",
1581
+ {
1582
+ className: `${pe.bannerWrapper} ${i}`.trim(),
1583
+ style: { "--banner-content": c },
1584
+ children: /* @__PURE__ */ S(
1585
+ be,
1586
+ {
1587
+ elevation: a ? "floating" : "elevated",
1588
+ intent: e,
1589
+ contrast: t,
1590
+ radius: "sm",
1591
+ className: pe.banner,
1592
+ children: [
1593
+ s && /* @__PURE__ */ o("div", { className: pe.bannerHeaderSurface, children: /* @__PURE__ */ o("div", { className: pe.bannerHeader, "aria-hidden": !0 }) }),
1594
+ /* @__PURE__ */ o("div", { className: pe.bannerBody, children: /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", className: pe.message, children: n }) })
1595
+ ]
1596
+ }
1597
+ )
1598
+ }
1599
+ );
1600
+ return a ? Xe(
1601
+ /* @__PURE__ */ o("div", { className: pe.floatingPosition, style: { zIndex: 9998 }, children: /* @__PURE__ */ o("div", { className: `${pe.floatingToast} ${_ ? pe.closing : ""}`, children: b }) }),
1602
+ document.body
1603
+ ) : b;
1604
+ };
1605
+ dc.displayName = "Banner";
1606
+ const _c = "_tableWrapper_1xqt4_1", uc = "_tableScroll_1xqt4_9", mc = "_table_1xqt4_1", hc = "_headerRow_1xqt4_20", vc = "_headerCell_1xqt4_24", pc = "_sortable_1xqt4_38", yc = "_sortIndicator_1xqt4_46", gc = "_row_1xqt4_51", bc = "_cell_1xqt4_55", fc = "_rowSelected_1xqt4_59", wc = "_rowClickable_1xqt4_63", xc = "_alignRight_1xqt4_77", Nc = "_alignCenter_1xqt4_78", Sc = "_emptyRow_1xqt4_80", Mc = "_skeleton_1xqt4_88", $c = "_pagination_1xqt4_102", kc = "_pageButton_1xqt4_112", W = {
1607
+ tableWrapper: _c,
1608
+ tableScroll: uc,
1609
+ table: mc,
1610
+ headerRow: hc,
1611
+ headerCell: vc,
1612
+ sortable: pc,
1613
+ sortIndicator: yc,
1614
+ row: gc,
1615
+ cell: bc,
1616
+ rowSelected: fc,
1617
+ rowClickable: wc,
1618
+ alignRight: xc,
1619
+ alignCenter: Nc,
1620
+ emptyRow: Sc,
1621
+ skeleton: Mc,
1622
+ pagination: $c,
1623
+ pageButton: kc
1624
+ };
1625
+ function je(e, t) {
1626
+ if (e.accessorKey) return t[e.accessorKey];
1627
+ if (e.accessor) return e.accessor(t);
1628
+ }
1629
+ function Lc(e, t, n) {
1630
+ const s = n === "asc" ? 1 : -1;
1631
+ return e == null && t == null ? 0 : e == null ? s : t == null ? -s : typeof e == "number" && typeof t == "number" ? (e - t) * s : String(e).localeCompare(String(t)) * s;
1632
+ }
1633
+ function Bc({
1634
+ columns: e,
1635
+ data: t,
1636
+ sortState: n,
1637
+ onSort: s,
1638
+ className: i,
1639
+ onRowClick: a,
1640
+ selectedRows: r,
1641
+ loading: l = !1,
1642
+ pagination: c,
1643
+ onPaginationChange: _,
1644
+ emptyMessage: d = "No results found."
1645
+ }) {
1646
+ const v = $e(() => e.filter((p) => !p.hide), [e]), u = $e(
1647
+ () => v.map((p) => p.width ? typeof p.width == "number" ? `${p.width}px` : p.width : "minmax(120px, 1fr)").join(" "),
1648
+ [v]
1649
+ ), m = $e(() => {
1650
+ if (!n) return t;
1651
+ const p = e.find((x) => x.id === n.columnId);
1652
+ return p ? [...t].sort(
1653
+ (x, B) => Lc(je(p, x), je(p, B), n.direction)
1654
+ ) : t;
1655
+ }, [t, e, n]), b = $e(() => {
1656
+ if (!c) return m;
1657
+ const p = c.pageIndex * c.pageSize;
1658
+ return m.slice(p, p + c.pageSize);
1659
+ }, [m, c]), f = c ? Math.ceil(m.length / c.pageSize) : 1, w = !l && b.length === 0, M = (p) => {
1660
+ s && s(p);
1661
+ };
1662
+ return /* @__PURE__ */ S("div", { className: N(W.tableWrapper, i), children: [
1663
+ /* @__PURE__ */ o("div", { className: W.tableScroll, children: /* @__PURE__ */ S("div", { className: W.table, style: { gridTemplateColumns: u }, role: "table", children: [
1664
+ /* @__PURE__ */ o("div", { className: W.headerRow, role: "row", children: v.map((p) => /* @__PURE__ */ S(
1665
+ "div",
1666
+ {
1667
+ className: N(
1668
+ W.headerCell,
1669
+ p.sortable && W.sortable,
1670
+ p.align === "right" && W.alignRight,
1671
+ p.align === "center" && W.alignCenter
1672
+ ),
1673
+ role: "columnheader",
1674
+ onClick: () => p.sortable && M(p.id),
1675
+ style: p.minWidth ? { minWidth: typeof p.minWidth == "number" ? `${p.minWidth}px` : p.minWidth } : void 0,
1676
+ children: [
1677
+ typeof p.header == "string" ? /* @__PURE__ */ o($, { variant: "text-body-small-emphasis", as: "span", color: "secondary", children: p.header }) : p.header,
1678
+ (n == null ? void 0 : n.columnId) === p.id && /* @__PURE__ */ o("span", { className: W.sortIndicator, "aria-hidden": !0, children: n.direction === "asc" ? "↑" : "↓" })
1679
+ ]
1680
+ },
1681
+ p.id
1682
+ )) }),
1683
+ l && Array.from({ length: 5 }).map((p, x) => /* @__PURE__ */ o("div", { className: W.row, role: "row", children: v.map((B) => /* @__PURE__ */ o("div", { className: W.cell, role: "cell", children: /* @__PURE__ */ o("div", { className: W.skeleton }) }, B.id)) }, `skeleton-${x}`)),
1684
+ w && /* @__PURE__ */ o("div", { className: W.emptyRow, style: { gridColumn: "1 / -1" }, children: /* @__PURE__ */ o($, { variant: "text-body-medium", as: "p", color: "secondary", children: d }) }),
1685
+ !l && b.map((p, x) => {
1686
+ const B = r == null ? void 0 : r.has(x);
1687
+ return /* @__PURE__ */ o(
1688
+ "div",
1689
+ {
1690
+ className: N(
1691
+ W.row,
1692
+ B && W.rowSelected,
1693
+ a && W.rowClickable
1694
+ ),
1695
+ role: "row",
1696
+ onClick: () => a == null ? void 0 : a(p, x),
1697
+ children: v.map((T) => /* @__PURE__ */ o(
1698
+ "div",
1699
+ {
1700
+ className: N(
1701
+ W.cell,
1702
+ T.align === "right" && W.alignRight,
1703
+ T.align === "center" && W.alignCenter
1704
+ ),
1705
+ role: "cell",
1706
+ children: T.renderCell ? T.renderCell(p, x) : /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", lineTruncation: 1, children: String(je(T, p) ?? "") })
1707
+ },
1708
+ T.id
1709
+ ))
1710
+ },
1711
+ x
1712
+ );
1713
+ })
1714
+ ] }) }),
1715
+ c && _ && f > 1 && /* @__PURE__ */ S("div", { className: W.pagination, children: [
1716
+ /* @__PURE__ */ o(
1717
+ "button",
1718
+ {
1719
+ className: W.pageButton,
1720
+ disabled: c.pageIndex === 0,
1721
+ onClick: () => _(c.pageIndex - 1, c.pageSize),
1722
+ type: "button",
1723
+ children: /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", children: "Previous" })
1724
+ }
1725
+ ),
1726
+ /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", color: "secondary", children: `Page ${c.pageIndex + 1} of ${f}` }),
1727
+ /* @__PURE__ */ o(
1728
+ "button",
1729
+ {
1730
+ className: W.pageButton,
1731
+ disabled: c.pageIndex >= f - 1,
1732
+ onClick: () => _(c.pageIndex + 1, c.pageSize),
1733
+ type: "button",
1734
+ children: /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", children: "Next" })
1735
+ }
1736
+ )
1737
+ ] })
1738
+ ] });
1739
+ }
1740
+ Bc.displayName = "Table";
1741
+ const Ic = "_tab_7ngwl_5", Rc = "_tabSelected_7ngwl_33", zc = "_onMedium_7ngwl_39", Cc = "_onBold_7ngwl_44", Tc = "_onStrong_7ngwl_52", Fc = "_onAlwaysDark_7ngwl_60", Ke = {
1742
+ tab: Ic,
1743
+ tabSelected: Rc,
1744
+ onMedium: zc,
1745
+ onBold: Cc,
1746
+ onStrong: Tc,
1747
+ onAlwaysDark: Fc
1748
+ }, mt = C(
1749
+ ({ id: e, label: t, isSelected: n = !1, background: s, onClick: i, className: a }, r) => {
1750
+ const l = s && s !== "faint" ? Ke[s === "always-dark" ? "onAlwaysDark" : `on${s.charAt(0).toUpperCase() + s.slice(1)}`] : void 0;
1751
+ return /* @__PURE__ */ o(
1752
+ "button",
1753
+ {
1754
+ ref: r,
1755
+ id: e,
1756
+ className: N(Ke.tab, n && Ke.tabSelected, l, a),
1757
+ onClick: i,
1758
+ type: "button",
1759
+ "aria-selected": n,
1760
+ role: "tab",
1761
+ children: /* @__PURE__ */ o($, { variant: n ? "text-body-medium-emphasis" : "text-body-medium", as: "span", children: t })
1762
+ }
1763
+ );
1764
+ }
1765
+ );
1766
+ mt.displayName = "Tab";
1767
+ const Ac = "_emptyState_1988v_1", Dc = {
1768
+ emptyState: Ac
1769
+ }, Ec = {
1770
+ "no-content": "No page contents to display.",
1771
+ "no-results": "No results found.",
1772
+ "no-results-filter": "No results found. Please update search criteria.",
1773
+ "no-access": "You don't have access to this page."
1774
+ }, ht = C(
1775
+ ({ type: e = "no-content", message: t, className: n }, s) => /* @__PURE__ */ o("div", { ref: s, className: N(Dc.emptyState, n), children: /* @__PURE__ */ o($, { variant: "text-body-medium", as: "p", color: "secondary", children: t || Ec[e] }) })
1776
+ );
1777
+ ht.displayName = "EmptyState";
1778
+ const Wc = "_fade_8nnao_1", Gc = "_fadeTop_8nnao_13", Hc = "_fadeBottom_8nnao_18", Pc = "_fadeLeft_8nnao_23", Xc = "_fadeRight_8nnao_28", nt = {
1779
+ fade: Wc,
1780
+ fadeTop: Gc,
1781
+ fadeBottom: Hc,
1782
+ fadeLeft: Pc,
1783
+ fadeRight: Xc
1784
+ }, Oc = {
1785
+ top: "fadeTop",
1786
+ bottom: "fadeBottom",
1787
+ left: "fadeLeft",
1788
+ right: "fadeRight"
1789
+ }, Uc = C(
1790
+ ({ side: e, height: t, background: n = "var(--color-background-secondary)", className: s, style: i = {} }, a) => /* @__PURE__ */ o(
1791
+ "div",
1792
+ {
1793
+ ref: a,
1794
+ className: N(nt.fade, nt[Oc[e]], s),
1795
+ style: { ...i, height: t, "--background": n },
1796
+ "aria-hidden": "true"
1797
+ }
1798
+ )
1799
+ );
1800
+ Uc.displayName = "Fade";
1801
+ const qc = "_container_153sa_1", jc = "_content_153sa_8", Kc = "_track_153sa_20", Vc = "_thumb_153sa_35", Yc = "_trackHorizontal_153sa_49", Zc = "_thumbHorizontal_153sa_64", Jc = "_thick_153sa_78", we = {
1802
+ container: qc,
1803
+ content: jc,
1804
+ track: Kc,
1805
+ thumb: Vc,
1806
+ trackHorizontal: Yc,
1807
+ thumbHorizontal: Zc,
1808
+ thick: Jc
1809
+ }, Qc = ({
1810
+ children: e,
1811
+ className: t,
1812
+ variant: n = "default",
1813
+ showTrackOnHover: s = !0,
1814
+ onScroll: i,
1815
+ fadeOverlay: a,
1816
+ contentRef: r
1817
+ }) => {
1818
+ const l = D(null), c = D(null), _ = r || c, d = D(null), v = D(null), [u, m] = z(0), [b, f] = z(0), [w, M] = z(0), [p, x] = z(0), [B, T] = z(!1), [j, F] = z(!1), [re, X] = z(!1), U = D(0), G = D(0), K = D(0), te = D(0), ne = ce(() => {
1819
+ s && X(!0);
1820
+ }, [s]), de = ce(() => {
1821
+ X(!1);
1822
+ }, []), O = ce(() => {
1823
+ const h = l.current, g = _.current;
1824
+ if (!h || !g) return;
1825
+ const L = h.clientHeight, H = h.clientWidth, k = g.scrollHeight, oe = g.scrollWidth, ie = g.scrollTop, se = g.scrollLeft;
1826
+ if (k <= L)
1827
+ m(0);
1828
+ else {
1829
+ const ae = L / k, V = Math.max(20, L * ae);
1830
+ m(V), f(ie / (k - L) * (L - V));
1831
+ }
1832
+ if (oe <= H)
1833
+ M(0);
1834
+ else {
1835
+ const ae = H / oe, V = Math.max(20, H * ae);
1836
+ M(V), x(se / (oe - H) * (H - V));
1837
+ }
1838
+ }, [_]);
1839
+ q(() => {
1840
+ const h = _.current;
1841
+ if (!h) return;
1842
+ const g = (L) => {
1843
+ O(), i && i(L);
1844
+ };
1845
+ return h.addEventListener("scroll", g), () => h.removeEventListener("scroll", g);
1846
+ }, [O, i, _]), q(() => {
1847
+ const h = _.current;
1848
+ if (!h) return;
1849
+ const g = () => O();
1850
+ if (window.addEventListener("resize", g), typeof ResizeObserver < "u") {
1851
+ const L = new ResizeObserver(g);
1852
+ return L.observe(h), () => {
1853
+ window.removeEventListener("resize", g), L.disconnect();
1854
+ };
1855
+ }
1856
+ return () => window.removeEventListener("resize", g);
1857
+ }, [O, _]), q(() => {
1858
+ O();
1859
+ }, [O, e]);
1860
+ const ue = ce((h) => {
1861
+ h.preventDefault(), h.stopPropagation();
1862
+ const g = _.current;
1863
+ if (!g) return;
1864
+ T(!0), U.current = h.clientY, G.current = g.scrollTop;
1865
+ const L = (k) => {
1866
+ const oe = l.current;
1867
+ if (!oe || !g) return;
1868
+ const ie = k.clientY - U.current, se = g.scrollHeight - oe.clientHeight, ae = se / (oe.clientHeight - u);
1869
+ g.scrollTop = Math.max(0, Math.min(se, G.current + ie * ae));
1870
+ }, H = () => {
1871
+ T(!1), document.removeEventListener("mousemove", L), document.removeEventListener("mouseup", H);
1872
+ };
1873
+ document.addEventListener("mousemove", L), document.addEventListener("mouseup", H);
1874
+ }, [u, _]), ve = ce((h) => {
1875
+ h.preventDefault(), h.stopPropagation();
1876
+ const g = _.current;
1877
+ if (!g) return;
1878
+ F(!0), K.current = h.clientX, te.current = g.scrollLeft;
1879
+ const L = (k) => {
1880
+ const oe = l.current;
1881
+ if (!oe || !g) return;
1882
+ const ie = k.clientX - K.current, se = g.scrollWidth - oe.clientWidth, ae = se / (oe.clientWidth - w);
1883
+ g.scrollLeft = Math.max(0, Math.min(se, te.current + ie * ae));
1884
+ }, H = () => {
1885
+ F(!1), document.removeEventListener("mousemove", L), document.removeEventListener("mouseup", H);
1886
+ };
1887
+ document.addEventListener("mousemove", L), document.addEventListener("mouseup", H);
1888
+ }, [w, _]), E = u > 0, y = w > 0, I = s && (re || B || j);
1889
+ return /* @__PURE__ */ S(
1890
+ "div",
1891
+ {
1892
+ ref: l,
1893
+ className: N(we.container, n === "thick" && we.thick, t),
1894
+ onMouseEnter: ne,
1895
+ onMouseLeave: de,
1896
+ "data-dragging": B || j,
1897
+ "data-show-track": I ? "true" : "false",
1898
+ children: [
1899
+ /* @__PURE__ */ o("div", { ref: _, className: we.content, children: e }),
1900
+ a,
1901
+ E && /* @__PURE__ */ o("div", { className: we.track, children: /* @__PURE__ */ o("div", { ref: d, className: we.thumb, style: { height: `${u}px`, top: `${b}px` }, onMouseDown: ue }) }),
1902
+ y && /* @__PURE__ */ o("div", { className: we.trackHorizontal, children: /* @__PURE__ */ o("div", { ref: v, className: we.thumbHorizontal, style: { width: `${w}px`, left: `${p}px` }, onMouseDown: ve }) })
1903
+ ]
1904
+ }
1905
+ );
1906
+ };
1907
+ Qc.displayName = "Scrollbar";
1908
+ const el = "_errorBoundary_1avvb_1", tl = "_errorDetails_1avvb_11", ot = {
1909
+ errorBoundary: el,
1910
+ errorDetails: tl
1911
+ };
1912
+ class Vd extends yt {
1913
+ constructor(t) {
1914
+ super(t), this.handleReset = () => {
1915
+ this.setState({ hasError: !1, error: null });
1916
+ }, this.state = { hasError: !1, error: null };
1917
+ }
1918
+ static getDerivedStateFromError(t) {
1919
+ return { hasError: !0, error: t };
1920
+ }
1921
+ componentDidCatch(t, n) {
1922
+ console.error("ErrorBoundary caught an error:", t, n);
1923
+ }
1924
+ render() {
1925
+ return this.state.hasError ? this.props.fallback ? this.props.fallback : /* @__PURE__ */ S("div", { className: ot.errorBoundary, children: [
1926
+ /* @__PURE__ */ o(ht, { type: "no-content" }),
1927
+ /* @__PURE__ */ o("div", { className: ot.errorDetails, children: /* @__PURE__ */ o($, { variant: "text-body-small", as: "p", color: "secondary", children: "Something went wrong. Please refresh the page." }) })
1928
+ ] }) : this.props.children;
1929
+ }
1930
+ }
1931
+ const nl = "_sidebar_1al5s_2", ol = "_resizing_1al5s_14", sl = "_collapsed_1al5s_16", rl = "_mobile_1al5s_18", il = "_mini_1al5s_26", al = "_itemLabel_1al5s_26", cl = "_itemBadge_1al5s_27", ll = "_sectionHeader_1al5s_28", dl = "_backdrop_1al5s_30", _l = "_content_1al5s_37", ul = "_footer_1al5s_47", ml = "_resizeHandle_1al5s_54", hl = "_section_1al5s_28", vl = "_sectionHeaderClickable_1al5s_87", pl = "_sectionItems_1al5s_89", yl = "_itemWrapper_1al5s_96", gl = "_item_1al5s_26", bl = "_itemSelected_1al5s_130", fl = "_itemDisabled_1al5s_133", wl = "_itemIcon_1al5s_135", xl = "_subItems_1al5s_156", P = {
1932
+ sidebar: nl,
1933
+ resizing: ol,
1934
+ collapsed: sl,
1935
+ mobile: rl,
1936
+ mini: il,
1937
+ itemLabel: al,
1938
+ itemBadge: cl,
1939
+ sectionHeader: ll,
1940
+ backdrop: dl,
1941
+ content: _l,
1942
+ footer: ul,
1943
+ resizeHandle: ml,
1944
+ section: hl,
1945
+ sectionHeaderClickable: vl,
1946
+ sectionItems: pl,
1947
+ itemWrapper: yl,
1948
+ item: gl,
1949
+ itemSelected: bl,
1950
+ itemDisabled: fl,
1951
+ itemIcon: wl,
1952
+ subItems: xl
1953
+ }, Nl = 56, Sl = 240, Ml = 180, $l = 140, kl = C(
1954
+ ({
1955
+ children: e,
1956
+ isCollapsed: t = !1,
1957
+ onToggle: n,
1958
+ width: s = "default",
1959
+ onWidthChange: i,
1960
+ resizable: a = !0,
1961
+ footer: r,
1962
+ className: l,
1963
+ isMobile: c = !1
1964
+ }, _) => {
1965
+ const d = D(null), v = _ || d, [u, m] = z(!1), b = s === "mini", f = s === "mini" ? Nl : s === "default" ? Sl : s, w = ce((M) => {
1966
+ if (!a || !i) return;
1967
+ M.preventDefault(), m(!0), M.clientX;
1968
+ const p = (B) => {
1969
+ const T = B.clientX;
1970
+ T < $l ? i("mini") : T < Ml ? i("default") : i(T);
1971
+ }, x = () => {
1972
+ m(!1), document.removeEventListener("mousemove", p), document.removeEventListener("mouseup", x), document.body.style.cursor = "", document.body.style.userSelect = "";
1973
+ };
1974
+ document.body.style.cursor = "col-resize", document.body.style.userSelect = "none", document.addEventListener("mousemove", p), document.addEventListener("mouseup", x);
1975
+ }, [a, i]);
1976
+ return q(() => {
1977
+ if (!c || t) return;
1978
+ const M = (p) => {
1979
+ p.key === "Escape" && (n == null || n());
1980
+ };
1981
+ return document.addEventListener("keydown", M), () => document.removeEventListener("keydown", M);
1982
+ }, [c, t, n]), t && !c ? null : /* @__PURE__ */ S(Ze, { children: [
1983
+ c && !t && /* @__PURE__ */ o("div", { className: P.backdrop, onClick: n, "aria-hidden": !0 }),
1984
+ /* @__PURE__ */ S(
1985
+ "aside",
1986
+ {
1987
+ ref: v,
1988
+ className: N(
1989
+ P.sidebar,
1990
+ b && P.mini,
1991
+ c && P.mobile,
1992
+ t && P.collapsed,
1993
+ u && P.resizing,
1994
+ l
1995
+ ),
1996
+ style: { width: t ? 0 : f },
1997
+ role: "navigation",
1998
+ "aria-label": "Sidebar",
1999
+ children: [
2000
+ /* @__PURE__ */ o("div", { className: P.content, children: e }),
2001
+ r && /* @__PURE__ */ o("div", { className: P.footer, children: r }),
2002
+ a && !c && /* @__PURE__ */ o(
2003
+ "div",
2004
+ {
2005
+ className: P.resizeHandle,
2006
+ onMouseDown: w,
2007
+ role: "separator",
2008
+ "aria-orientation": "vertical",
2009
+ "aria-label": "Resize sidebar"
2010
+ }
2011
+ )
2012
+ ]
2013
+ }
2014
+ )
2015
+ ] });
2016
+ }
2017
+ );
2018
+ kl.displayName = "Sidebar";
2019
+ const Ll = C(
2020
+ ({ label: e, children: t, collapsible: n = !1, defaultCollapsed: s = !1, className: i }, a) => {
2021
+ const [r, l] = z(s);
2022
+ return /* @__PURE__ */ S("div", { ref: a, className: N(P.section, i), children: [
2023
+ e && /* @__PURE__ */ o(
2024
+ "div",
2025
+ {
2026
+ className: N(P.sectionHeader, n && P.sectionHeaderClickable),
2027
+ onClick: n ? () => l((c) => !c) : void 0,
2028
+ role: n ? "button" : void 0,
2029
+ "aria-expanded": n ? !r : void 0,
2030
+ children: /* @__PURE__ */ o($, { variant: "text-caption-emphasis", as: "span", color: "tertiary", children: e })
2031
+ }
2032
+ ),
2033
+ !r && /* @__PURE__ */ o("div", { className: P.sectionItems, children: t })
2034
+ ] });
2035
+ }
2036
+ );
2037
+ Ll.displayName = "SidebarSection";
2038
+ const Bl = C(
2039
+ ({ label: e, icon: t, isSelected: n = !1, isDisabled: s = !1, onClick: i, badge: a, children: r, className: l }, c) => /* @__PURE__ */ S("div", { className: N(P.itemWrapper, l), children: [
2040
+ /* @__PURE__ */ S(
2041
+ "button",
2042
+ {
2043
+ ref: c,
2044
+ className: N(
2045
+ P.item,
2046
+ n && P.itemSelected,
2047
+ s && P.itemDisabled
2048
+ ),
2049
+ onClick: i,
2050
+ disabled: s,
2051
+ type: "button",
2052
+ "aria-current": n ? "page" : void 0,
2053
+ children: [
2054
+ t && /* @__PURE__ */ o("span", { className: P.itemIcon, children: /* @__PURE__ */ o(t, { size: 20 }) }),
2055
+ /* @__PURE__ */ o(
2056
+ $,
2057
+ {
2058
+ variant: n ? "text-body-medium-emphasis" : "text-body-medium",
2059
+ as: "span",
2060
+ className: P.itemLabel,
2061
+ lineTruncation: 1,
2062
+ children: e
2063
+ }
2064
+ ),
2065
+ a && /* @__PURE__ */ o("span", { className: P.itemBadge, children: a })
2066
+ ]
2067
+ }
2068
+ ),
2069
+ r && n && /* @__PURE__ */ o("div", { className: P.subItems, children: r })
2070
+ ] })
2071
+ );
2072
+ Bl.displayName = "SidebarItem";
2073
+ const Il = "_header_1902d_1", Rl = "_left_1902d_11", zl = "_center_1902d_19", Cl = "_right_1902d_28", We = {
2074
+ header: Il,
2075
+ left: Rl,
2076
+ center: zl,
2077
+ right: Cl
2078
+ }, Tl = C(
2079
+ ({ title: e, left: t, center: n, right: s, background: i = "secondary", className: a }, r) => /* @__PURE__ */ S(
2080
+ be,
2081
+ {
2082
+ ref: r,
2083
+ as: "header",
2084
+ background: i,
2085
+ elevation: "none",
2086
+ edge: "bottom",
2087
+ className: N(We.header, a),
2088
+ children: [
2089
+ /* @__PURE__ */ S("div", { className: We.left, children: [
2090
+ t,
2091
+ e && !n && /* @__PURE__ */ o($, { variant: "text-title-small", as: "h1", lineTruncation: 1, children: e })
2092
+ ] }),
2093
+ n && /* @__PURE__ */ o("div", { className: We.center, children: n }),
2094
+ /* @__PURE__ */ o("div", { className: We.right, children: s })
2095
+ ]
2096
+ }
2097
+ )
2098
+ );
2099
+ Tl.displayName = "Header";
2100
+ const Fl = "_group_9khnl_1", Al = "_horizontal_9khnl_7", Dl = "_radio_9khnl_14", El = "_inactive_9khnl_31", Wl = "_circle_9khnl_39", Gl = "_circleChecked_9khnl_52", Hl = "_dot_9khnl_56", Ne = {
2101
+ group: Fl,
2102
+ horizontal: Al,
2103
+ radio: Dl,
2104
+ inactive: El,
2105
+ circle: Wl,
2106
+ circleChecked: Gl,
2107
+ dot: Hl
2108
+ }, Pl = C(
2109
+ ({
2110
+ value: e,
2111
+ onChange: t,
2112
+ options: n,
2113
+ "aria-label": s,
2114
+ direction: i = "vertical",
2115
+ inactive: a = !1,
2116
+ className: r
2117
+ }, l) => /* @__PURE__ */ o(
2118
+ "div",
2119
+ {
2120
+ ref: l,
2121
+ role: "radiogroup",
2122
+ "aria-label": s,
2123
+ className: N(
2124
+ Ne.group,
2125
+ i === "horizontal" && Ne.horizontal,
2126
+ r
2127
+ ),
2128
+ children: n.map((c) => /* @__PURE__ */ o(
2129
+ vt,
2130
+ {
2131
+ label: c.label,
2132
+ checked: e === c.value,
2133
+ inactive: a || c.inactive,
2134
+ onChange: () => t(c.value)
2135
+ },
2136
+ c.value
2137
+ ))
2138
+ }
2139
+ )
2140
+ );
2141
+ Pl.displayName = "RadioGroup";
2142
+ const vt = C(
2143
+ ({ label: e, checked: t = !1, onChange: n, inactive: s = !1, className: i }, a) => {
2144
+ const r = () => {
2145
+ !s && !t && (n == null || n());
2146
+ };
2147
+ return /* @__PURE__ */ S(
2148
+ "div",
2149
+ {
2150
+ ref: a,
2151
+ role: "radio",
2152
+ "aria-checked": t,
2153
+ tabIndex: s ? -1 : 0,
2154
+ className: N(Ne.radio, s && Ne.inactive, i),
2155
+ onClick: r,
2156
+ onKeyDown: (l) => {
2157
+ (l.key === " " || l.key === "Enter") && (l.preventDefault(), r());
2158
+ },
2159
+ children: [
2160
+ /* @__PURE__ */ o("span", { className: N(Ne.circle, t && Ne.circleChecked), children: t && /* @__PURE__ */ o("span", { className: Ne.dot }) }),
2161
+ /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", color: "inherit", children: e })
2162
+ ]
2163
+ }
2164
+ );
2165
+ }
2166
+ );
2167
+ vt.displayName = "RadioItem";
2168
+ const Xl = "_tabGroup_1kx0a_1", Ol = "_tabsRow_1kx0a_7", Ul = "_track_1kx0a_12", ql = "_indicator_1kx0a_18", Ge = {
2169
+ tabGroup: Xl,
2170
+ tabsRow: Ol,
2171
+ track: Ul,
2172
+ indicator: ql
2173
+ }, jl = C(
2174
+ ({ tabs: e, activeIndex: t = 0, onTabChange: n, className: s }, i) => {
2175
+ const a = D([]), [r, l] = z({ left: 0, width: 0 }), c = ce(() => {
2176
+ const _ = a.current[t];
2177
+ _ && _.parentElement && l({
2178
+ left: _.offsetLeft,
2179
+ width: _.offsetWidth
2180
+ });
2181
+ }, [t]);
2182
+ return q(() => {
2183
+ c();
2184
+ }, [c]), q(() => {
2185
+ var v;
2186
+ const _ = new ResizeObserver(c), d = (v = a.current[0]) == null ? void 0 : v.parentElement;
2187
+ return d && _.observe(d), () => _.disconnect();
2188
+ }, [c]), /* @__PURE__ */ S(
2189
+ "div",
2190
+ {
2191
+ ref: i,
2192
+ role: "tablist",
2193
+ className: N(Ge.tabGroup, s),
2194
+ children: [
2195
+ /* @__PURE__ */ o("div", { className: Ge.tabsRow, children: e.map((_, d) => /* @__PURE__ */ o(
2196
+ mt,
2197
+ {
2198
+ ref: (v) => {
2199
+ a.current[d] = v;
2200
+ },
2201
+ id: _.id,
2202
+ label: _.label,
2203
+ isSelected: d === t,
2204
+ onClick: () => n == null ? void 0 : n(d)
2205
+ },
2206
+ _.id ?? d
2207
+ )) }),
2208
+ /* @__PURE__ */ o("div", { className: Ge.track, children: /* @__PURE__ */ o(
2209
+ "div",
2210
+ {
2211
+ className: Ge.indicator,
2212
+ style: {
2213
+ transform: `translateX(${r.left}px)`,
2214
+ width: r.width
2215
+ }
2216
+ }
2217
+ ) })
2218
+ ]
2219
+ }
2220
+ );
2221
+ }
2222
+ );
2223
+ jl.displayName = "TabGroup";
2224
+ const Kl = "_accordion_15kid_1", Vl = "_item_15kid_8", Yl = "_inactive_15kid_16", Zl = "_trigger_15kid_23", Jl = "_chevron_15kid_44", Ql = "_chevronOpen_15kid_52", ed = "_body_15kid_58", td = "_bodyInner_15kid_63", ge = {
2225
+ accordion: Kl,
2226
+ item: Vl,
2227
+ inactive: Yl,
2228
+ trigger: Zl,
2229
+ chevron: Jl,
2230
+ chevronOpen: Ql,
2231
+ body: ed,
2232
+ bodyInner: td
2233
+ }, nd = C(
2234
+ ({ items: e, multiple: t = !1, expandedIds: n, onExpandedChange: s, className: i }, a) => {
2235
+ const [r, l] = z([]), c = n ?? r, _ = (d) => {
2236
+ let v;
2237
+ c.includes(d) ? v = c.filter((u) => u !== d) : v = t ? [...c, d] : [d], l(v), s == null || s(v);
2238
+ };
2239
+ return /* @__PURE__ */ o("div", { ref: a, className: N(ge.accordion, i), children: e.map((d) => /* @__PURE__ */ o(
2240
+ pt,
2241
+ {
2242
+ label: d.label,
2243
+ isExpanded: c.includes(d.id),
2244
+ inactive: d.inactive,
2245
+ onToggle: () => _(d.id),
2246
+ children: d.content
2247
+ },
2248
+ d.id
2249
+ )) });
2250
+ }
2251
+ );
2252
+ nd.displayName = "Accordion";
2253
+ const pt = C(
2254
+ ({ label: e, children: t, isExpanded: n = !1, onToggle: s, inactive: i = !1, className: a }, r) => {
2255
+ const l = D(null), [c, _] = z(0), d = ce(() => {
2256
+ l.current && _(l.current.scrollHeight);
2257
+ }, []);
2258
+ return q(() => {
2259
+ d();
2260
+ const v = l.current;
2261
+ if (!v) return;
2262
+ const u = new ResizeObserver(d);
2263
+ return u.observe(v), () => u.disconnect();
2264
+ }, [d]), /* @__PURE__ */ S("div", { ref: r, className: N(ge.item, i && ge.inactive, a), children: [
2265
+ /* @__PURE__ */ S(
2266
+ "button",
2267
+ {
2268
+ type: "button",
2269
+ className: ge.trigger,
2270
+ onClick: () => !i && (s == null ? void 0 : s()),
2271
+ "aria-expanded": n,
2272
+ tabIndex: i ? -1 : 0,
2273
+ children: [
2274
+ /* @__PURE__ */ o($, { variant: "text-body-medium-emphasis", as: "span", color: "inherit", children: e }),
2275
+ /* @__PURE__ */ o("span", { className: N(ge.chevron, n && ge.chevronOpen), children: "›" })
2276
+ ]
2277
+ }
2278
+ ),
2279
+ /* @__PURE__ */ o(
2280
+ "div",
2281
+ {
2282
+ className: ge.body,
2283
+ style: { height: n ? c : 0 },
2284
+ "aria-hidden": !n,
2285
+ children: /* @__PURE__ */ o("div", { ref: l, className: ge.bodyInner, children: t })
2286
+ }
2287
+ )
2288
+ ] });
2289
+ }
2290
+ );
2291
+ pt.displayName = "AccordionItem";
2292
+ const od = "_breadcrumb_1xq6b_1", sd = "_list_1xq6b_6", rd = "_item_1xq6b_15", id = "_link_1xq6b_21", ad = "_separator_1xq6b_41", Se = {
2293
+ breadcrumb: od,
2294
+ list: sd,
2295
+ item: rd,
2296
+ link: id,
2297
+ separator: ad
2298
+ }, cd = C(
2299
+ ({ items: e, separator: t = "/", className: n }, s) => /* @__PURE__ */ o("nav", { ref: s, "aria-label": "Breadcrumb", className: N(Se.breadcrumb, n), children: /* @__PURE__ */ o("ol", { className: Se.list, children: e.map((i, a) => {
2300
+ const r = a === e.length - 1;
2301
+ return /* @__PURE__ */ o("li", { className: Se.item, children: r ? /* @__PURE__ */ o($, { variant: "text-body-medium-emphasis", as: "span", color: "primary", "aria-current": "page", children: i.label }) : /* @__PURE__ */ S(Ze, { children: [
2302
+ i.href ? /* @__PURE__ */ o(
2303
+ "a",
2304
+ {
2305
+ href: i.href,
2306
+ className: Se.link,
2307
+ onClick: (l) => {
2308
+ i.onClick && (l.preventDefault(), i.onClick());
2309
+ },
2310
+ children: /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", color: "inherit", children: i.label })
2311
+ }
2312
+ ) : /* @__PURE__ */ o(
2313
+ "button",
2314
+ {
2315
+ type: "button",
2316
+ className: Se.link,
2317
+ onClick: i.onClick,
2318
+ children: /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", color: "inherit", children: i.label })
2319
+ }
2320
+ ),
2321
+ /* @__PURE__ */ o("span", { className: Se.separator, "aria-hidden": "true", children: t })
2322
+ ] }) }, a);
2323
+ }) }) })
2324
+ );
2325
+ cd.displayName = "Breadcrumb";
2326
+ const ld = "_pagination_ax4c0_1", dd = "_inactive_ax4c0_9", _d = "_button_ax4c0_16", ud = "_active_ax4c0_45", md = "_nav_ax4c0_52", hd = "_ellipsis_ax4c0_58", ye = {
2327
+ pagination: ld,
2328
+ inactive: dd,
2329
+ button: _d,
2330
+ active: ud,
2331
+ nav: md,
2332
+ ellipsis: hd
2333
+ };
2334
+ function He(e, t) {
2335
+ const n = [];
2336
+ for (let s = e; s <= t; s++) n.push(s);
2337
+ return n;
2338
+ }
2339
+ function vd(e, t, n) {
2340
+ const s = n * 2 + 5;
2341
+ if (t <= s) return He(1, t);
2342
+ const i = Math.max(e - n, 2), a = Math.min(e + n, t - 1), r = i > 2, l = a < t - 1;
2343
+ return !r && l ? [...He(1, n * 2 + 3), "ellipsis", t] : r && !l ? [1, "ellipsis", ...He(t - (n * 2 + 2), t)] : [1, "ellipsis", ...He(i, a), "ellipsis", t];
2344
+ }
2345
+ const pd = C(
2346
+ ({ page: e, totalPages: t, onPageChange: n, siblingCount: s = 1, inactive: i = !1, className: a }, r) => {
2347
+ const l = $e(() => vd(e, t, s), [e, t, s]);
2348
+ return t <= 1 ? null : /* @__PURE__ */ S("nav", { ref: r, "aria-label": "Pagination", className: N(ye.pagination, i && ye.inactive, a), children: [
2349
+ /* @__PURE__ */ o(
2350
+ "button",
2351
+ {
2352
+ type: "button",
2353
+ className: N(ye.button, ye.nav),
2354
+ disabled: e <= 1 || i,
2355
+ onClick: () => n(e - 1),
2356
+ "aria-label": "Previous page",
2357
+ children: /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", color: "inherit", children: "‹" })
2358
+ }
2359
+ ),
2360
+ l.map(
2361
+ (c, _) => c === "ellipsis" ? /* @__PURE__ */ o("span", { className: ye.ellipsis, children: /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", color: "tertiary", children: "…" }) }, `e${_}`) : /* @__PURE__ */ o(
2362
+ "button",
2363
+ {
2364
+ type: "button",
2365
+ className: N(ye.button, c === e && ye.active),
2366
+ onClick: () => n(c),
2367
+ "aria-current": c === e ? "page" : void 0,
2368
+ disabled: i,
2369
+ children: /* @__PURE__ */ o($, { variant: c === e ? "text-body-small-emphasis" : "text-body-small", as: "span", color: "inherit", children: c })
2370
+ },
2371
+ c
2372
+ )
2373
+ ),
2374
+ /* @__PURE__ */ o(
2375
+ "button",
2376
+ {
2377
+ type: "button",
2378
+ className: N(ye.button, ye.nav),
2379
+ disabled: e >= t || i,
2380
+ onClick: () => n(e + 1),
2381
+ "aria-label": "Next page",
2382
+ children: /* @__PURE__ */ o($, { variant: "text-body-small", as: "span", color: "inherit", children: "›" })
2383
+ }
2384
+ )
2385
+ ] });
2386
+ }
2387
+ );
2388
+ pd.displayName = "Pagination";
2389
+ const yd = "_divider_yo1st_1", gd = "_vertical_yo1st_9", st = {
2390
+ divider: yd,
2391
+ vertical: gd
2392
+ }, bd = C(
2393
+ ({ orientation: e = "horizontal", className: t }, n) => /* @__PURE__ */ o(
2394
+ "hr",
2395
+ {
2396
+ ref: n,
2397
+ role: "separator",
2398
+ "aria-orientation": e,
2399
+ className: N(
2400
+ st.divider,
2401
+ e === "vertical" && st.vertical,
2402
+ t
2403
+ )
2404
+ }
2405
+ )
2406
+ );
2407
+ bd.displayName = "Divider";
2408
+ const fd = "_skeleton_gebkr_1", wd = "_text_gebkr_9", xd = "_circular_gebkr_15", Nd = "_rectangular_gebkr_21", Sd = "_textGroup_gebkr_29", Md = "_animate_gebkr_37", $d = "_shimmer_gebkr_1", xe = {
2409
+ skeleton: fd,
2410
+ text: wd,
2411
+ circular: xd,
2412
+ rectangular: Nd,
2413
+ textGroup: Sd,
2414
+ animate: Md,
2415
+ shimmer: $d
2416
+ }, kd = C(
2417
+ ({
2418
+ variant: e = "text",
2419
+ width: t,
2420
+ height: n,
2421
+ lines: s = 1,
2422
+ animate: i = !0,
2423
+ className: a
2424
+ }, r) => e === "text" && s > 1 ? /* @__PURE__ */ o("div", { ref: r, className: N(xe.textGroup, a), style: { width: t }, children: Array.from({ length: s }, (l, c) => /* @__PURE__ */ o(
2425
+ "div",
2426
+ {
2427
+ className: N(xe.skeleton, xe.text, i && xe.animate),
2428
+ style: {
2429
+ width: c === s - 1 ? "60%" : "100%",
2430
+ height: n
2431
+ }
2432
+ },
2433
+ c
2434
+ )) }) : /* @__PURE__ */ o(
2435
+ "div",
2436
+ {
2437
+ ref: r,
2438
+ className: N(
2439
+ xe.skeleton,
2440
+ xe[e],
2441
+ i && xe.animate,
2442
+ a
2443
+ ),
2444
+ style: { width: t, height: n },
2445
+ "aria-hidden": "true"
2446
+ }
2447
+ )
2448
+ );
2449
+ kd.displayName = "Skeleton";
2450
+ const Ld = "_container_ssyox_3", Bd = "_topCenter_ssyox_16", Id = "_topRight_ssyox_23", Rd = "_bottomCenter_ssyox_29", zd = "_bottomRight_ssyox_36", Cd = "_toast_ssyox_44", Td = "_slideIn_ssyox_1", Fd = "_toastExit_ssyox_54", Ad = "_fadeOut_ssyox_1", Dd = "_dismiss_ssyox_58", Te = {
2451
+ container: Ld,
2452
+ topCenter: Bd,
2453
+ topRight: Id,
2454
+ bottomCenter: Rd,
2455
+ bottomRight: zd,
2456
+ toast: Cd,
2457
+ slideIn: Td,
2458
+ toastExit: Fd,
2459
+ fadeOut: Ad,
2460
+ dismiss: Dd
2461
+ };
2462
+ let Me = [];
2463
+ const Ye = /* @__PURE__ */ new Set();
2464
+ function Ve() {
2465
+ Ye.forEach((e) => e());
2466
+ }
2467
+ function rt() {
2468
+ return Me;
2469
+ }
2470
+ function Ed(e) {
2471
+ return Ye.add(e), () => {
2472
+ Ye.delete(e);
2473
+ };
2474
+ }
2475
+ let Wd = 0;
2476
+ const Ce = {
2477
+ show(e) {
2478
+ const t = `toast-${++Wd}`;
2479
+ return Me = [...Me, { id: t, ...e }], Ve(), t;
2480
+ },
2481
+ info(e, t) {
2482
+ return Ce.show({ message: e, intent: "neutral", ...t });
2483
+ },
2484
+ success(e, t) {
2485
+ return Ce.show({ message: e, intent: "positive", ...t });
2486
+ },
2487
+ error(e, t) {
2488
+ return Ce.show({ message: e, intent: "negative", ...t });
2489
+ },
2490
+ warning(e, t) {
2491
+ return Ce.show({ message: e, intent: "warning", ...t });
2492
+ },
2493
+ dismiss(e) {
2494
+ Me = Me.filter((t) => t.id !== e), Ve();
2495
+ },
2496
+ dismissAll() {
2497
+ Me = [], Ve();
2498
+ }
2499
+ };
2500
+ function Gd() {
2501
+ return gt(Ed, rt, rt);
2502
+ }
2503
+ const Hd = {
2504
+ neutral: "neutral",
2505
+ brand: "brand",
2506
+ positive: "positive",
2507
+ negative: "negative",
2508
+ warning: "warning",
2509
+ caution: "caution"
2510
+ }, Pd = ({ data: e }) => {
2511
+ const [t, n] = z(!1), s = D(), i = ce(() => {
2512
+ n(!0), setTimeout(() => {
2513
+ var a;
2514
+ Ce.dismiss(e.id), (a = e.onDismiss) == null || a.call(e);
2515
+ }, 200);
2516
+ }, [e]);
2517
+ return q(() => {
2518
+ const a = e.duration ?? 4e3;
2519
+ return a > 0 && (s.current = setTimeout(i, a)), () => {
2520
+ s.current && clearTimeout(s.current);
2521
+ };
2522
+ }, [e.duration, i]), /* @__PURE__ */ S(
2523
+ be,
2524
+ {
2525
+ intent: Hd[e.intent ?? "neutral"],
2526
+ contrast: "bold",
2527
+ elevation: "floating",
2528
+ radius: "lg",
2529
+ className: N(Te.toast, t && Te.toastExit),
2530
+ role: "status",
2531
+ "aria-live": "polite",
2532
+ children: [
2533
+ /* @__PURE__ */ o($, { variant: "text-body-medium", as: "span", color: "inherit", children: e.message }),
2534
+ /* @__PURE__ */ o(
2535
+ "button",
2536
+ {
2537
+ type: "button",
2538
+ className: Te.dismiss,
2539
+ onClick: i,
2540
+ "aria-label": "Dismiss",
2541
+ children: "×"
2542
+ }
2543
+ )
2544
+ ]
2545
+ }
2546
+ );
2547
+ }, Xd = C(
2548
+ ({ position: e = "top-center" }, t) => {
2549
+ const n = Gd();
2550
+ return typeof document > "u" ? null : bt.createPortal(
2551
+ /* @__PURE__ */ o(
2552
+ "div",
2553
+ {
2554
+ ref: t,
2555
+ className: N(Te.container, Te[Od(e)]),
2556
+ "aria-label": "Notifications",
2557
+ children: n.map((s) => /* @__PURE__ */ o(Pd, { data: s }, s.id))
2558
+ }
2559
+ ),
2560
+ document.body
2561
+ );
2562
+ }
2563
+ );
2564
+ Xd.displayName = "ToastContainer";
2565
+ function Od(e) {
2566
+ switch (e) {
2567
+ case "top-center":
2568
+ return "topCenter";
2569
+ case "top-right":
2570
+ return "topRight";
2571
+ case "bottom-center":
2572
+ return "bottomCenter";
2573
+ case "bottom-right":
2574
+ return "bottomRight";
2575
+ }
2576
+ }
2577
+ export {
2578
+ nd as Accordion,
2579
+ pt as AccordionItem,
2580
+ $i as Badge,
2581
+ dc as Banner,
2582
+ cd as Breadcrumb,
2583
+ bs as Button,
2584
+ mr as ButtonGroup,
2585
+ Ro as Card,
2586
+ Di as Checkbox,
2587
+ dt as DestructiveMenuItem,
2588
+ bd as Divider,
2589
+ ht as EmptyState,
2590
+ Vd as ErrorBoundary,
2591
+ Uc as Fade,
2592
+ oa as Field,
2593
+ Tl as Header,
2594
+ Xi as Input,
2595
+ ct as Loader,
2596
+ ut as Menu,
2597
+ lt as MenuItem,
2598
+ ma as Modal,
2599
+ pd as Pagination,
2600
+ Pl as RadioGroup,
2601
+ vt as RadioItem,
2602
+ Qc as Scrollbar,
2603
+ Za as Select,
2604
+ kl as Sidebar,
2605
+ Bl as SidebarItem,
2606
+ Ll as SidebarSection,
2607
+ kd as Skeleton,
2608
+ ea as Slider,
2609
+ be as Surface,
2610
+ mt as Tab,
2611
+ jl as TabGroup,
2612
+ Bc as Table,
2613
+ Ni as Tag,
2614
+ $ as Text,
2615
+ Xd as ToastContainer,
2616
+ Ri as Toggle,
2617
+ Ws as ToggleButton,
2618
+ Fr as ToggleButtonGroup,
2619
+ ja as Tooltip,
2620
+ Ce as toast,
2621
+ Gd as useToasts
2622
+ };
2623
+ //# sourceMappingURL=index.js.map