@iamfiro/design 0.3.1 → 0.3.4

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 (161) hide show
  1. package/agents/INDEX.md +1 -1
  2. package/agents/avatar/AGENTS.md +29 -1
  3. package/agents/brand-icon/AGENTS.md +1 -1
  4. package/agents/social-login-button/AGENTS.md +4 -3
  5. package/agents/tooltip/AGENTS.md +1 -1
  6. package/lib/components/Accordion/Accordion2.js +92 -92
  7. package/lib/components/ActionBar/ActionBar2.js +42 -45
  8. package/lib/components/Alert/Alert2.js +77 -77
  9. package/lib/components/AppShell/AppShell2.js +70 -71
  10. package/lib/components/AreaChart/AreaChart.js +32 -35
  11. package/lib/components/BarChart/BarChart2.js +155 -155
  12. package/lib/components/BarList/BarList2.js +93 -93
  13. package/lib/components/Breadcrumb/Breadcrumb2.js +62 -64
  14. package/lib/components/Calendar/Calendar2.js +183 -182
  15. package/lib/components/Calendar/DatePicker2.js +116 -115
  16. package/lib/components/Calendar/date.js +67 -66
  17. package/lib/components/Card/Card2.js +67 -67
  18. package/lib/components/CardFrame/CardFrame2.js +34 -37
  19. package/lib/components/Chart/ChartParts.js +90 -90
  20. package/lib/components/Chart/chart2.js +62 -62
  21. package/lib/components/Chart/useChartInteraction.js +51 -51
  22. package/lib/components/ChatBubble/ChatBubble2.js +117 -117
  23. package/lib/components/ChatBubble/formatChatTime.js +37 -36
  24. package/lib/components/ChatComposer/ChatComposer2.js +55 -55
  25. package/lib/components/CodeBlock/CodeBlock2.js +60 -60
  26. package/lib/components/CodeBlock/highlight.js +72 -72
  27. package/lib/components/ColorPicker/ColorPicker2.js +232 -231
  28. package/lib/components/ColorPicker/color.js +67 -67
  29. package/lib/components/ColorPicker/presets.js +25 -24
  30. package/lib/components/Combobox/Combobox2.js +140 -140
  31. package/lib/components/CommandMenu/CommandMenu.js +135 -135
  32. package/lib/components/Comment/Comment2.js +82 -57
  33. package/lib/components/ContextMenu/ContextMenu2.js +101 -100
  34. package/lib/components/DataGrid/DataGrid2.js +872 -871
  35. package/lib/components/DataGrid/GridPopover.js +98 -98
  36. package/lib/components/DataGrid/anchor.js +34 -33
  37. package/lib/components/DataGrid/model.js +291 -290
  38. package/lib/components/DataGrid/panels.js +337 -336
  39. package/lib/components/DataGrid/typeMeta.js +49 -48
  40. package/lib/components/DataGrid/types.js +34 -33
  41. package/lib/components/DescriptionList/DescriptionList2.js +109 -109
  42. package/lib/components/Dialog/AlertDialog.js +53 -53
  43. package/lib/components/Dialog/Dialog2.js +72 -72
  44. package/lib/components/Dialog/modal.js +67 -68
  45. package/lib/components/Drawer/Drawer2.js +117 -117
  46. package/lib/components/DropdownMenu/DropdownMenu2.js +267 -266
  47. package/lib/components/DropdownMenu/menuCore.js +68 -42
  48. package/lib/components/Dropzone/Dropzone2.js +78 -78
  49. package/lib/components/EmptyState/EmptyState2.js +58 -56
  50. package/lib/components/FileChip/FileChip2.js +72 -48
  51. package/lib/components/FileUpload/FileUpload.js +137 -138
  52. package/lib/components/FilterChips/FilterChips2.js +61 -61
  53. package/lib/components/FunnelChart/FunnelChart2.js +161 -161
  54. package/lib/components/FunnelChart/funnel.js +50 -49
  55. package/lib/components/Highlight/Highlight2.js +56 -56
  56. package/lib/components/HoverCard/HoverCard.js +73 -73
  57. package/lib/components/InlineDiff/InlineDiff2.js +129 -129
  58. package/lib/components/InlineDiff/diff.js +87 -87
  59. package/lib/components/InlineDiff/useDiffReview.js +54 -52
  60. package/lib/components/Kanban/Kanban2.js +383 -384
  61. package/lib/components/Kanban/KanbanCard.js +68 -93
  62. package/lib/components/Kanban/move.js +43 -43
  63. package/lib/components/LineChart/LineChart2.js +164 -164
  64. package/lib/components/List/List2.js +60 -60
  65. package/lib/components/Listbox/Listbox2.js +108 -108
  66. package/lib/components/Marker/Marker2.js +59 -57
  67. package/lib/components/Menubar/Menubar2.js +120 -119
  68. package/lib/components/MultiSelect/MultiSelect2.js +111 -111
  69. package/lib/components/NavigationMenu/NavigationMenu2.js +277 -279
  70. package/lib/components/NoticeStack/NoticeStack2.js +109 -109
  71. package/lib/components/NumberStepper/NumberStepper2.js +70 -70
  72. package/lib/components/OtpInput/OtpInput2.js +94 -94
  73. package/lib/components/Pagination/Pagination2.js +109 -109
  74. package/lib/components/Pagination/paginationRange.js +37 -38
  75. package/lib/components/PhoneInput/PhoneInput.js +83 -84
  76. package/lib/components/PieChart/PieChart2.js +157 -157
  77. package/lib/components/PieChart/arc.js +72 -72
  78. package/lib/components/PieChart/useArcTween.js +50 -53
  79. package/lib/components/Popover/Popover2.js +62 -61
  80. package/lib/components/ProgressTracker/ProgressTracker2.js +104 -104
  81. package/lib/components/Rating/Rating2.js +89 -88
  82. package/lib/components/Resizable/Resizable2.js +133 -134
  83. package/lib/components/Resizable/layout.js +56 -56
  84. package/lib/components/ScaledPreview/ScaledPreview2.js +64 -63
  85. package/lib/components/ScatterChart/ScatterChart2.js +252 -251
  86. package/lib/components/ScatterChart/scatter.js +50 -52
  87. package/lib/components/ScrollArea/ScrollArea2.js +122 -122
  88. package/lib/components/Select/Select2.js +84 -85
  89. package/lib/components/Sidebar/Sidebar2.js +79 -79
  90. package/lib/components/Skeleton/Skeleton2.js +56 -56
  91. package/lib/components/Slider/Slider2.js +63 -63
  92. package/lib/components/SocialLoginButton/SocialLoginButton.js +54 -46
  93. package/lib/components/SparkChart/SparkChart2.js +129 -128
  94. package/lib/components/SparkChart/spark.js +49 -48
  95. package/lib/components/Sparkbar/Sparkbar2.js +59 -58
  96. package/lib/components/SplitView/SplitView2.js +54 -55
  97. package/lib/components/Stat/Stat2.js +59 -59
  98. package/lib/components/StepList/StepList2.js +78 -78
  99. package/lib/components/Table/Table2.js +55 -55
  100. package/lib/components/Tabs/Tabs2.js +76 -76
  101. package/lib/components/TagInput/TagInput2.js +218 -215
  102. package/lib/components/TimePicker/TimePicker2.js +204 -204
  103. package/lib/components/TimePicker/time.js +59 -58
  104. package/lib/components/Timeline/Timeline2.js +179 -179
  105. package/lib/components/Timeline/scale.js +60 -55
  106. package/lib/components/Toast/Toaster.js +103 -103
  107. package/lib/components/Toast/store.js +47 -47
  108. package/lib/components/ToggleGroup/ToggleGroup2.js +77 -77
  109. package/lib/components/Toolbar/Toolbar2.js +138 -138
  110. package/lib/components/Tracker/Tracker2.js +99 -99
  111. package/lib/components/TreeDiagram/TreeDiagram2.js +117 -117
  112. package/lib/components/TreeView/TreeView2.js +145 -145
  113. package/lib/hooks/timing.js +33 -33
  114. package/lib/hooks/useControllableState.js +33 -33
  115. package/lib/hooks/useCountdown.js +54 -55
  116. package/lib/hooks/useDigitInput.js +85 -84
  117. package/lib/hooks/useDismiss.js +55 -55
  118. package/lib/hooks/useElapsed.js +55 -55
  119. package/lib/hooks/useFloating.js +21 -21
  120. package/lib/hooks/useFocusTrap.js +67 -67
  121. package/lib/hooks/usePresence.js +33 -29
  122. package/lib/hooks/usePressToOpen.js +33 -33
  123. package/lib/hooks/useScrollLock.js +54 -55
  124. package/lib/hooks/useSelection.js +54 -48
  125. package/lib/index.js +67 -68
  126. package/lib/primitives/AspectRatio2.js +58 -54
  127. package/lib/primitives/BrandIcon.js +189 -158
  128. package/lib/primitives/ColorDot2.js +52 -51
  129. package/lib/primitives/CopyButton2.js +66 -64
  130. package/lib/primitives/CountBadge2.js +56 -56
  131. package/lib/primitives/Countdown2.js +36 -34
  132. package/lib/primitives/Delta2.js +41 -66
  133. package/lib/primitives/Elapsed.js +32 -32
  134. package/lib/primitives/FileIcon2.js +90 -90
  135. package/lib/primitives/Flag2.js +157 -157
  136. package/lib/primitives/IconStack2.js +60 -58
  137. package/lib/primitives/IconTile2.js +46 -48
  138. package/lib/primitives/Kbd2.js +51 -51
  139. package/lib/primitives/Layout2.js +71 -71
  140. package/lib/primitives/Link2.js +37 -35
  141. package/lib/primitives/MaskedText2.js +71 -75
  142. package/lib/primitives/Progress2.js +72 -72
  143. package/lib/primitives/RelativeTime.js +60 -64
  144. package/lib/primitives/SearchInput2.js +55 -56
  145. package/lib/primitives/SelectorButton2.js +69 -71
  146. package/lib/primitives/Spinner2.js +63 -59
  147. package/lib/primitives/StatusIcon2.js +66 -66
  148. package/lib/primitives/Swatch2.js +54 -56
  149. package/lib/primitives/Tooltip2.js +77 -77
  150. package/lib/primitives/Typography2.js +67 -67
  151. package/lib/primitives/formatCountdown.js +38 -41
  152. package/lib/primitives/formatElapsed.js +41 -40
  153. package/lib/primitives/formatRelativeTime.js +74 -48
  154. package/lib/primitives/hotkey.js +81 -81
  155. package/lib/primitives/index.js +220 -199
  156. package/lib/primitives/maskValue.js +53 -52
  157. package/lib/style.css +1 -1
  158. package/lib/types/components/SocialLoginButton/SocialLoginButton.d.ts +1 -1
  159. package/lib/types/primitives/BrandIcon.d.ts +1 -1
  160. package/lib/types/primitives/index.d.ts +6 -2
  161. package/package.json +1 -1
@@ -1,91 +1,88 @@
1
1
  "use client";
2
- function e(t, r) {
3
- t -= 142;
4
- let i = n(), a = i[t];
5
- e.iqUhwS === void 0 && (e.beTAiG = function(e) {
2
+ (function(e, t) {
3
+ let n = a, r = e();
4
+ for (;;) try {
5
+ if (parseInt(n(461)) / 1 + -parseInt(n(451)) / 2 + parseInt(n(458)) / 3 + parseInt(n(462)) / 4 * (-parseInt(n(459)) / 5) + -parseInt(n(448)) / 6 + -parseInt(n(455)) / 7 * (parseInt(n(452)) / 8) + parseInt(n(450)) / 9 == t) break;
6
+ r.push(r.shift());
7
+ } catch {
8
+ r.push(r.shift());
9
+ }
10
+ })(o, 116397);
11
+ import { cubicBezier as e } from "./arc.js";
12
+ import { useEffect as t, useLayoutEffect as n, useRef as r, useState as i } from "react";
13
+ function a(e, t) {
14
+ e -= 448;
15
+ let n = o(), r = n[e];
16
+ a.JfZUHv === void 0 && (a.xmAaEz = function(e) {
6
17
  let t = "", n = "";
7
18
  for (let n = 0, r, i, a = 0; i = e.charAt(a++); ~i && (r = n % 4 ? r * 64 + i : i, n++ % 4) && (t += String.fromCharCode(255 & r >> (-2 * n & 6)))) i = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=".indexOf(i);
8
19
  for (let e = 0, r = t.length; e < r; e++) n += "%" + ("00" + t.charCodeAt(e).toString(16)).slice(-2);
9
20
  return decodeURIComponent(n);
10
- }, e.HvqaCc = {}, e.iqUhwS = !0);
11
- let o = i[0];
12
- e.xFLykm !== o && (e.HvqaCc = {}, e.xFLykm = o);
13
- let s = e.HvqaCc[t];
14
- return s === void 0 ? (a = e.beTAiG(a), e.HvqaCc[t] = a) : a = s, a;
21
+ }, a.HqeWeI = {}, a.JfZUHv = !0);
22
+ let i = n[0];
23
+ a.lSoPGU !== i && (a.HqeWeI = {}, a.lSoPGU = i);
24
+ let s = a.HqeWeI[e];
25
+ return s === void 0 ? (r = a.xmAaEz(r), a.HqeWeI[e] = r) : r = s, r;
15
26
  }
16
- (function(t, n) {
17
- let r = e, i = t();
18
- for (;;) try {
19
- if (parseInt(r(145)) / 1 * (-parseInt(r(144)) / 2) + -parseInt(r(150)) / 3 * (-parseInt(r(149)) / 4) + parseInt(r(158)) / 5 + -parseInt(r(148)) / 6 * (parseInt(r(153)) / 7) + -parseInt(r(159)) / 8 + -parseInt(r(146)) / 9 + parseInt(r(142)) / 10 == n) break;
20
- i.push(i.shift());
21
- } catch {
22
- i.push(i.shift());
23
- }
24
- })(n, 681100);
25
- import { cubicBezier as t } from "./arc.js";
26
- function n() {
27
+ function o() {
27
28
  let e = [
28
- "mJi2mJm5tePRrNDP",
29
- "AM9PBG",
30
- "BwfW",
31
- "ndjovg1dzMy",
32
- "y3vYCMvUDa",
33
29
  "z2v0",
30
+ "nJu1mdy4qNvkAKXk",
31
+ "nw1oqu9kEa",
32
+ "zMLSDgvY",
33
+ "mJiWnZrduffczM0",
34
+ "nJi2odC2tufHquTv",
35
+ "ode5nZKYC25etur2",
36
+ "BwfW",
37
+ "mJi3nJe5ow1zzxz3zG",
38
+ "mta0mtK2sKHAwhDz",
39
+ "ohbgELLIsa",
34
40
  "Dg9gAxHLza",
35
- "AgfZ",
36
- "nta0ntC3mgrowuzjvq",
37
- "mJe4mtq0z1HYDu9L",
38
- "ntm0ntGXme5euvzYCW",
39
41
  "A2v5",
40
- "mtm0oefNvNfYrq",
41
- "nde3vxrfz3H3",
42
- "mJG0nZy1ne1YDunjAW",
43
- "y29SB3i",
44
- "ote2nJiWAwnUu3bQ",
45
- "mZzgs0fbqNu"
42
+ "mJiWndy1sML5Eerc",
43
+ "y3vYCMvUDa"
46
44
  ];
47
- return n = function() {
45
+ return o = function() {
48
46
  return e;
49
- }, n();
47
+ }, o();
50
48
  }
51
- import { useEffect as r, useLayoutEffect as i, useRef as a, useState as o } from "react";
52
- var s = t(.32, .72, 0, 1);
53
- function c(t, { enter: n = 900, update: c = 600 } = {}) {
54
- let l = e, [u, d] = o(() => t[l(152)]((e) => ({
49
+ var s = e(.32, .72, 0, 1);
50
+ function c(e, { enter: o = 900, update: c = 600 } = {}) {
51
+ let l = a, [u, d] = i(() => e[l(449)]((e) => ({
55
52
  ...e,
56
53
  a0: 0,
57
54
  a1: 0
58
- }))), f = a(u), p = a(t);
59
- i(() => {
60
- let e = l;
61
- p[e(154)] = t;
55
+ }))), f = r(u), p = r(e);
56
+ n(() => {
57
+ let t = l;
58
+ p[t(456)] = e;
62
59
  });
63
- let m = a(!1), h = t[l(152)]((e) => e[l(143)] + ":" + e.a0[l(156)](5) + ":" + e.a1[l(156)](5) + ":" + e[l(147)])[l(151)]("|");
64
- return r(() => {
65
- let e = l, t = p[e(154)], r = !m[e(154)], i = new Map(f[e(154)][e(152)]((e) => [e.key, e])), a = new Set(t.map((t) => t[e(143)])), o = f[e(154)].filter((t) => !a[e(157)](t[e(143)]) && t.a1 - t.a0 > 1e-4)[e(152)]((e) => {
60
+ let m = r(!1), h = e[l(449)]((e) => e.key + ":" + e.a0[l(453)](5) + ":" + e.a1[l(453)](5) + ":" + e.color).join("|");
61
+ return t(() => {
62
+ let e = l, t = p[e(456)], n = !m[e(456)], r = new Map(f[e(456)].map((e) => [e.key, e])), i = new Set(t.map((t) => t[e(454)])), a = f.current[e(460)]((t) => !i.has(t[e(454)]) && t.a1 - t.a0 > 1e-4).map((e) => {
66
63
  let t = (e.a0 + e.a1) / 2;
67
64
  return {
68
65
  ...e,
69
66
  a0: t,
70
67
  a1: t
71
68
  };
72
- }), u = [...t, ...o], h = u[e(152)]((t) => i[e(155)](t[e(143)]) ?? {
69
+ }), u = [...t, ...a], h = u[e(449)]((t) => r[e(457)](t.key) ?? {
73
70
  ...t,
74
71
  a1: t.a0
75
- }), g = r ? n : c, _ = 0, v = 0, y = (n) => {
72
+ }), g = n ? o : c, _ = 0, v = 0, y = (n) => {
76
73
  let r = e;
77
74
  v ||= n;
78
- let i = Math.min(1, (n - v) / g), a = s(i), o = i < 1 ? u[r(152)]((e, t) => ({
75
+ let i = Math.min(1, (n - v) / g), a = s(i), o = i < 1 ? u.map((e, t) => ({
79
76
  ...e,
80
77
  a0: h[t].a0 + (e.a0 - h[t].a0) * a,
81
78
  a1: h[t].a1 + (e.a1 - h[t].a1) * a
82
79
  })) : t;
83
- f.current = o, d(o), i < 1 ? _ = requestAnimationFrame(y) : m[r(154)] = !0;
80
+ f[r(456)] = o, d(o), i < 1 ? _ = requestAnimationFrame(y) : m[r(456)] = !0;
84
81
  };
85
82
  return _ = requestAnimationFrame(() => _ = requestAnimationFrame(y)), () => cancelAnimationFrame(_);
86
83
  }, [
87
84
  h,
88
- n,
85
+ o,
89
86
  c
90
87
  ]), u;
91
88
  }
@@ -1,111 +1,112 @@
1
1
  "use client";
2
+ const e = h;
2
3
  (function(e, t) {
3
- let n = i, r = e();
4
+ let n = h, r = e();
4
5
  for (;;) try {
5
- if (parseInt(n(176)) / 1 + -parseInt(n(181)) / 2 + parseInt(n(180)) / 3 + -parseInt(n(160)) / 4 * (parseInt(n(189)) / 5) + parseInt(n(169)) / 6 + parseInt(n(166)) / 7 + -parseInt(n(171)) / 8 == t) break;
6
+ if (-parseInt(n(155)) / 1 + -parseInt(n(146)) / 2 * (parseInt(n(130)) / 3) + -parseInt(n(129)) / 4 + -parseInt(n(136)) / 5 * (parseInt(n(152)) / 6) + -parseInt(n(120)) / 7 * (-parseInt(n(143)) / 8) + parseInt(n(119)) / 9 + parseInt(n(158)) / 10 * (parseInt(n(139)) / 11) == t) break;
6
7
  r.push(r.shift());
7
8
  } catch {
8
9
  r.push(r.shift());
9
10
  }
10
- })(h, 474237);
11
- import { TIMING as e } from "../../hooks/timing.js";
12
- import { usePresence as t } from "../../hooks/usePresence.js";
13
- import { useControllableState as n } from "../../hooks/useControllableState.js";
14
- import { cx as r } from "../../primitives/index.js";
15
- function i(e, t) {
16
- e -= 158;
17
- let n = h(), r = n[e];
18
- i.aWBxIk === void 0 && (i.vPExGf = function(e) {
11
+ })(s, 823626);
12
+ import { TIMING as t } from "../../hooks/timing.js";
13
+ import { usePresence as n } from "../../hooks/usePresence.js";
14
+ import { useControllableState as r } from "../../hooks/useControllableState.js";
15
+ import { cx as i } from "../../primitives/index.js";
16
+ import { useFloating as a } from "../../hooks/useFloating.js";
17
+ import { useDismiss as o } from "../../hooks/useDismiss.js";
18
+ function s() {
19
+ let e = /* @__PURE__ */ "y2fSyYGXmdb2DYaTide2ChGP.y2XLyxjuAw1LB3v0.zhmTzMXVyxrPBMC.mJGYDvr4shLl.C2v0vgLTzw91Da.y2XVC2LUzW.mtqZnZKWnKTbwK1ptG.y2XPy2S.zNvUy3rPB24.nZqWndGWmeDKAfD0yG.Cg9PBNrLCLr5Cgu.A2v5.rxnJyxbL.B3bLBG.mtCXmtC3m2DNug5yrG.mteXmZCXmZnjyKHYrNi.zhmTzMXVyxrPBMCTlxbHzc0.oMzVy3vZlxzPC2LIBgu.ChjLDMvUDerLzMf1Bhq.y29UDgfPBNm.yM9KEq.C3bHBG.Ag92zxi.C3rHCNq.mtK5ody3mLrAELHgEq.mta1ndGZD2jKCM96.Bw91C2u.zgvMyxvSDfbYzxzLBNrLza.DgfYz2v0.ywn0AxzLrwXLBwvUDa.Ag92zxjjBNrLBNq.mtu4otbRvej5wMe.zM9JDxm.zhmTC2nYB2XS.mJjfzu1Hzue.CMvSyxrLzfrHCMDLDa.Bw91BNrLza.zhmTCg9WB3zLCI1HBMnOB3i.ohz4C0vdAq.y2XVC2vK.Bwf0y2HLCW.mJbUuwH4rxG.y3vYCMvUDa.Ag92zxjhCMfJzq".split(".");
20
+ return s = function() {
21
+ return e;
22
+ }, s();
23
+ }
24
+ import { focusableIn as c } from "../../hooks/useFocusTrap.js";
25
+ /* empty css */
26
+ import { useEffect as l, useRef as u } from "react";
27
+ import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
28
+ import { createPortal as m } from "react-dom";
29
+ function h(e, t) {
30
+ e -= 116;
31
+ let n = s(), r = n[e];
32
+ h.dVpeEv === void 0 && (h.bGFrik = function(e) {
19
33
  let t = "", n = "";
20
34
  for (let n = 0, r, i, a = 0; i = e.charAt(a++); ~i && (r = n % 4 ? r * 64 + i : i, n++ % 4) && (t += String.fromCharCode(255 & r >> (-2 * n & 6)))) i = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=".indexOf(i);
21
35
  for (let e = 0, r = t.length; e < r; e++) n += "%" + ("00" + t.charCodeAt(e).toString(16)).slice(-2);
22
36
  return decodeURIComponent(n);
23
- }, i.BPJCMx = {}, i.aWBxIk = !0);
24
- let a = n[0];
25
- i.SGeYxq !== a && (i.BPJCMx = {}, i.SGeYxq = a);
26
- let o = i.BPJCMx[e];
27
- return o === void 0 ? (r = i.vPExGf(r), i.BPJCMx[e] = r) : r = o, r;
28
- }
29
- import { useFloating as a } from "../../hooks/useFloating.js";
30
- import { useDismiss as o } from "../../hooks/useDismiss.js";
31
- import { focusableIn as s } from "../../hooks/useFocusTrap.js";
32
- /* empty css */
33
- import { useEffect as c, useRef as l } from "react";
34
- import { Fragment as u, jsx as d, jsxs as f } from "react/jsx-runtime";
35
- import { createPortal as p } from "react-dom";
36
- var m = 160;
37
- function h() {
38
- let e = /* @__PURE__ */ "zNvUy3rPB24.C2v0vgLTzw91Da.zhmTzMXVyxrPBMC.Ag92zxi.zM9JDxm.mJG3nJGXmuLeshzSqG.A2v5.CMvSyxrLzfrHCMDLDa.ndu5oda1mMf6thLoEG.C3bHBG.nZiZodq4meLSvKTyyW.y29UDgfPBNm.ChjLDMvUDerLzMf1Bhq.DgfYz2v0.Bwf0y2HLCW.ndKYnZCWBw1QyKTq.Ag92zxjhCMfJzq.B3bLBG.Cg9PBNrLCLr5Cgu.nda3mZKXDevwAfv6.mJGZodj0ELvhqvi.y2XLyxjuAw1LB3v0.zhmTzMXVyxrPBMCTlxbHzc0.y2XVC2vK.zgLHBg9N.Bw91C2u.ywn0AxzLrwXLBwvUDa.y2XPy2S.mZqZodCWEM9VwNbL.Bw91BNrLza.zgvMyxvSDfbYzxzLBNrLza.yM9KEq.y3vYCMvUDa.mJrzBK9hzee".split(".");
39
- return h = function() {
40
- return e;
41
- }, h();
37
+ }, h.NYoOSP = {}, h.dVpeEv = !0);
38
+ let i = n[0];
39
+ h.muNqRa !== i && (h.NYoOSP = {}, h.muNqRa = i);
40
+ let a = h.NYoOSP[e];
41
+ return a === void 0 ? (r = h.bGFrik(r), h.NYoOSP[e] = r) : r = a, r;
42
42
  }
43
- function g({ trigger: h, children: g, open: _, defaultOpen: v = !1, onOpenChange: y, openOn: b = "click", align: x = "start", width: S, padding: C = "md", autoFocus: w = !0, className: T, "aria-label": E }) {
44
- let D = i, [O, k] = n(_, v, y), A = t(O, m), j = l(null), M = l(null), N = l(0), { style: P, side: F } = a(j, A[D(190)], {
43
+ var g = 160;
44
+ function _({ trigger: s, children: h, open: _, defaultOpen: v = !1, onOpenChange: y, openOn: b = e(156), align: x = e(128), width: S, padding: C = "md", autoFocus: w = !0, className: T, "aria-label": E }) {
45
+ let D = e, [O, k] = r(_, v, y), A = n(O, g), j = u(null), M = u(null), N = u(0), { style: P, side: F } = a(j, A[D(141)], {
45
46
  matchWidth: !1,
46
47
  align: x,
47
48
  panelRef: M,
48
49
  maxHeight: 560
49
50
  });
50
- o(O, [j, M], () => k(!1)), c(() => () => window.clearTimeout(N.current), []), c(() => {
51
+ o(O, [j, M], () => k(!1)), l(() => () => window[D(150)](N[D(147)]), []), l(() => {
51
52
  let e = D;
52
- if (!O || b !== e(188) || !w) return;
53
+ if (!O || b !== e(156) || !w) return;
53
54
  let t = requestAnimationFrame(() => {
54
- let t = e, n = M.current;
55
- n && (s(n)[0] ?? n)[t(165)]({ preventScroll: !0 });
55
+ let t = e, n = M[t(147)];
56
+ n && (c(n)[0] ?? n)[t(137)]({ preventScroll: !0 });
56
57
  });
57
58
  return () => cancelAnimationFrame(t);
58
59
  }, [
59
60
  O,
60
61
  b,
61
62
  w
62
- ]), c(() => {
63
+ ]), l(() => {
63
64
  let e = D;
64
- !O && M[e(159)]?.contains(document[e(187)]) && j[e(159)] && s(j[e(159)])[0]?.[e(165)]({ preventScroll: !0 });
65
+ !O && M[e(147)]?.[e(124)](document[e(134)]) && j[e(147)] && c(j[e(147)])[0]?.[e(137)]({ preventScroll: !0 });
65
66
  }, [O]);
66
67
  let I = () => k(!1), L = (e) => {
67
- let t = D, n = e[t(168)];
68
- j[t(159)]?.[t(172)](n) || M[t(159)]?.[t(172)](n) || k(!1);
68
+ let t = D, n = e[t(140)];
69
+ j[t(147)]?.contains(n) || M.current?.[t(124)](n) || k(!1);
69
70
  }, R = (e) => {
70
71
  let t = D;
71
- e[t(167)] === "Escape" && O && !e[t(191)] && (e[t(173)](), I());
72
- }, z = b === D(164) ? {
73
- onPointerEnter: (t) => {
72
+ e[t(116)] === t(117) && O && !e[t(132)] && (e[t(123)](), I());
73
+ }, z = b === D(127) ? {
74
+ onPointerEnter: (e) => {
74
75
  let n = D;
75
- t[n(179)] === n(186) && (window[n(182)](N.current), N[n(159)] = window[n(162)](() => k(!0), O ? 0 : e.hoverIntent));
76
+ e[n(159)] === n(131) && (window[n(150)](N.current), N[n(147)] = window[n(153)](() => k(!0), O ? 0 : t[n(135)]));
76
77
  },
77
- onPointerLeave: (t) => {
78
+ onPointerLeave: (e) => {
78
79
  let n = D;
79
- t[n(179)] === n(186) && (window[n(182)](N.current), N[n(159)] = window.setTimeout(() => k(!1), e[n(177)]));
80
+ e[n(159)] === n(131) && (window.clearTimeout(N[n(147)]), N[n(147)] = window.setTimeout(() => k(!1), t[n(148)]));
80
81
  }
81
82
  } : {};
82
- return f(u, { children: [d(D(170), {
83
+ return p(d, { children: [f(D(126), {
83
84
  ref: j,
84
- className: "ds-popover-anchor",
85
- onClick: b === "click" ? () => k(!O) : void 0,
86
- onFocus: b === "hover" ? (e) => e[D(174)][D(175)](":focus-visible") && k(!0) : void 0,
87
- onBlur: b === "hover" ? L : void 0,
85
+ className: D(142),
86
+ onClick: b === D(156) ? () => k(!O) : void 0,
87
+ onFocus: b === D(127) ? (e) => e[D(133)][D(145)](D(122)) && k(!0) : void 0,
88
+ onBlur: b === D(127) ? L : void 0,
88
89
  onKeyDown: R,
89
90
  "aria-expanded": O,
90
91
  ...z,
91
- children: h
92
- }), A[D(190)] && p(d("div", {
92
+ children: s
93
+ }), A[D(141)] && m(f("div", {
93
94
  ref: M,
94
- role: D(185),
95
+ role: "dialog",
95
96
  "aria-label": E,
96
97
  tabIndex: -1,
97
- className: r(D(163), "ds-scroll", D(183) + C, T),
98
+ className: i(D(151), D(138), D(121) + C, T),
98
99
  "data-side": F,
99
- "data-state": A.closing ? D(184) : D(178),
100
+ "data-state": A[D(154)] ? D(144) : D(118),
100
101
  style: {
101
102
  ...P,
102
103
  width: S,
103
- maxWidth: "calc(100vw - 16px)"
104
+ maxWidth: D(149)
104
105
  },
105
106
  onKeyDown: R,
106
- onBlur: b === "hover" ? L : void 0,
107
+ onBlur: b === D(127) ? L : void 0,
107
108
  ...z,
108
- children: typeof g === D(161) ? g(() => I()) : g
109
- }), document[D(158)])] });
109
+ children: typeof h === D(157) ? h(() => I()) : h
110
+ }), document[D(125)])] });
110
111
  }
111
- export { g as Popover };
112
+ export { _ as Popover };