@svgrid/grid 3.0.5 → 3.0.7

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 (166) hide show
  1. package/README.md +28 -7
  2. package/dist/GridMenus.svelte +34 -4
  3. package/dist/SvGrid.controller.svelte.d.ts +23 -3
  4. package/dist/SvGrid.controller.svelte.js +235 -54
  5. package/dist/SvGrid.css +143 -7
  6. package/dist/SvGrid.helpers.js +2 -4
  7. package/dist/SvGrid.svelte +223 -38
  8. package/dist/SvGrid.types.d.ts +77 -4
  9. package/dist/SvGridDropdown.svelte +20 -0
  10. package/dist/SvGridDropdown.svelte.d.ts +12 -0
  11. package/dist/SvModal.svelte +22 -0
  12. package/dist/SvModal.svelte.d.ts +7 -0
  13. package/dist/a11y/dismissable.d.ts +10 -0
  14. package/dist/a11y/dismissable.js +24 -2
  15. package/dist/build-api.js +81 -31
  16. package/dist/cdn/{GridMenus-CID62rlI.js → GridMenus-BgUS-W3o.js} +151 -142
  17. package/dist/cdn/GridMenus-CcwU8I4t.js +644 -0
  18. package/dist/cdn/{SvChartMenu-FBSMINA6.js → SvChartMenu-BFSTpvB-.js} +1 -1
  19. package/dist/cdn/{SvChartMenu-Bl6PBbkT.js → SvChartMenu-BZ1Iwv0y.js} +1 -1
  20. package/dist/cdn/{SvDateTimePicker-DQwt4UAs.js → SvDateTimePicker-D9u_cOf8.js} +1 -1
  21. package/dist/cdn/{SvDateTimePicker-vNU6bZ-q.js → SvDateTimePicker-s_6IUpI7.js} +1 -1
  22. package/dist/cdn/{SvGridCellEditor-B1p-vCK5.js → SvGridCellEditor-9yz-SbdZ.js} +2 -2
  23. package/dist/cdn/{SvGridCellEditor-D_0q4xAu.js → SvGridCellEditor-D7-ql1Hd.js} +2 -2
  24. package/dist/cdn/{SvGridChart-C3EWAZaM.js → SvGridChart-DMUOFxOe.js} +4 -4
  25. package/dist/cdn/{SvGridChart-DzLkSwCH.js → SvGridChart-N7ik0oWy.js} +4 -4
  26. package/dist/cdn/{SvGridChartBuilder-CfII62sZ.js → SvGridChartBuilder-CB_Jnm2k.js} +4 -4
  27. package/dist/cdn/{SvGridChartBuilder-BE2T1ykB.js → SvGridChartBuilder-Ca7gF8ZK.js} +4 -4
  28. package/dist/cdn/{SvGridChartPanel-xf4sWVTo.js → SvGridChartPanel-9GOJRHP7.js} +5 -5
  29. package/dist/cdn/{SvGridChartPanel-CCX5_Wgd.js → SvGridChartPanel-Dl-FujN8.js} +5 -5
  30. package/dist/cdn/{SvGridChartView-CfuXmY5I.js → SvGridChartView-B1LFgoPP.js} +2 -2
  31. package/dist/cdn/{SvGridChartView-DYwabQWj.js → SvGridChartView-By3n7DGZ.js} +2 -2
  32. package/dist/cdn/{SvGridDropdown-D0VdjeR8.js → SvGridDropdown-BWeM3lMe.js} +46 -46
  33. package/dist/cdn/{SvGridDropdown-D13MtJ2j.js → SvGridDropdown-CJ6QqTxu.js} +67 -67
  34. package/dist/cdn/{SvModal-CIZWCcad.js → SvModal-ClxGmpAc.js} +187 -186
  35. package/dist/cdn/{SvModal-BAE-pjZX.js → SvModal-DhB_VMFR.js} +148 -147
  36. package/dist/cdn/{cell-formatting-C2Hf5gqd.js → cell-formatting-Mnv84zoE.js} +28 -6
  37. package/dist/cdn/{chart-Dz7SqMXH.js → chart-By7h2Guv.js} +1 -1
  38. package/dist/cdn/{chart-panel-messages-CUbf2R4i.js → chart-panel-messages-BC-tOgFY.js} +1 -1
  39. package/dist/cdn/{chart-panel-messages-CmNrMdsr.js → chart-panel-messages-DUaXr-sb.js} +1 -1
  40. package/dist/cdn/{chart-summary-BJW_tg_X.js → chart-summary-BDtrNEiA.js} +1 -1
  41. package/dist/cdn/{chart-trend-CaN9mDEV.js → chart-trend-C1aOAPBZ.js} +1 -1
  42. package/dist/cdn/{dismissable-DAHetSNk.js → dismissable-Brc4EZU1.js} +5 -1
  43. package/dist/cdn/{editor-registry-BhgE3S84.js → editor-registry-BVeHvlZR.js} +49 -50
  44. package/dist/cdn/{export-format-CUDLy2yn.js → export-format-y1wdyCcv.js} +93 -97
  45. package/dist/cdn/{row-resize-niQCp040.js → row-resize-DtOS1KG6.js} +41 -32
  46. package/dist/cdn/{server-block-cache-CGoWz-87.js → server-block-cache-DIqb3VZn.js} +4 -0
  47. package/dist/cdn/{src-jcFMkBnN.js → src-25JmJ_7g.js} +4768 -4149
  48. package/dist/cdn/{src-Bklofsad.js → src-kE9B98r6.js} +4796 -4177
  49. package/dist/cdn/svgrid.js +18 -18
  50. package/dist/cdn/svgrid.svelte-external.js +18 -18
  51. package/dist/cdn/{validate-C7Rn_Bns.js → validate-AZoD8BoR.js} +6 -2
  52. package/dist/cell-formatting.d.ts +9 -0
  53. package/dist/cell-formatting.js +52 -1
  54. package/dist/cell-render.js +25 -6
  55. package/dist/clipboard.d.ts +2 -2
  56. package/dist/clipboard.js +72 -23
  57. package/dist/columns.js +7 -2
  58. package/dist/conditional-formatting.d.ts +2 -0
  59. package/dist/conditional-formatting.js +2 -0
  60. package/dist/core.d.ts +22 -6
  61. package/dist/core.js +478 -40
  62. package/dist/editing.js +24 -0
  63. package/dist/export-format.d.ts +8 -0
  64. package/dist/export-format.js +23 -16
  65. package/dist/grid-messages.d.ts +4 -0
  66. package/dist/grid-messages.js +4 -0
  67. package/dist/headless.d.ts +5 -0
  68. package/dist/headless.js +12 -0
  69. package/dist/history.d.ts +21 -0
  70. package/dist/history.js +34 -4
  71. package/dist/index.d.ts +1 -1
  72. package/dist/keyboard-handlers.js +24 -1
  73. package/dist/keyboard.js +4 -0
  74. package/dist/row-drag-touch.d.ts +1 -1
  75. package/dist/row-drag.js +35 -1
  76. package/dist/row-model.d.ts +6 -0
  77. package/dist/row-resize.js +22 -1
  78. package/dist/selection.js +1 -1
  79. package/dist/server-block-cache.d.ts +5 -0
  80. package/dist/server-block-cache.js +8 -0
  81. package/dist/server-data-source.d.ts +35 -3
  82. package/dist/server-data-source.js +11 -2
  83. package/dist/server.d.ts +1 -1
  84. package/dist/sparkline.js +7 -5
  85. package/dist/svgrid-wrapper.types.d.ts +33 -0
  86. package/dist/validate.js +9 -1
  87. package/dist/virtualization/column-virtualizer.d.ts +1 -0
  88. package/dist/virtualization/svelte-virtualizer.svelte.d.ts +1 -0
  89. package/dist/virtualization/svelte-virtualizer.svelte.js +1 -0
  90. package/dist/virtualization/virtualizer.d.ts +3 -0
  91. package/dist/virtualization/virtualizer.js +14 -1
  92. package/package.json +6 -1
  93. package/src/GridMenus.svelte +34 -4
  94. package/src/SvGrid.controller.svelte.ts +236 -57
  95. package/src/SvGrid.css +143 -7
  96. package/src/SvGrid.helpers.ts +2 -4
  97. package/src/SvGrid.svelte +223 -38
  98. package/src/SvGrid.types.ts +77 -4
  99. package/src/SvGridDropdown.svelte +20 -0
  100. package/src/SvModal.svelte +22 -0
  101. package/src/SvModal.test.ts +30 -1
  102. package/src/a11y/dismissable.test.ts +10 -1
  103. package/src/a11y/dismissable.ts +22 -2
  104. package/src/build-api.ts +85 -27
  105. package/src/cell-formatting.test.ts +17 -0
  106. package/src/cell-formatting.ts +49 -1
  107. package/src/cell-render.test.ts +24 -2
  108. package/src/cell-render.ts +24 -8
  109. package/src/clipboard.test.ts +107 -0
  110. package/src/clipboard.ts +62 -23
  111. package/src/columns.test.ts +4 -4
  112. package/src/columns.ts +7 -2
  113. package/src/conditional-formatting.test.ts +8 -0
  114. package/src/conditional-formatting.ts +3 -0
  115. package/src/core.sort.test.ts +86 -0
  116. package/src/core.tick-repair.test.ts +287 -0
  117. package/src/core.ts +478 -40
  118. package/src/editing.test.ts +52 -0
  119. package/src/editing.ts +25 -0
  120. package/src/export-dates.test.ts +114 -0
  121. package/src/export-format.ts +26 -14
  122. package/src/grid-messages.test.ts +7 -0
  123. package/src/grid-messages.ts +10 -0
  124. package/src/headless.ts +24 -0
  125. package/src/history.test.ts +49 -1
  126. package/src/history.ts +48 -2
  127. package/src/index.ts +2 -0
  128. package/src/keyboard-handlers.coverage.test.ts +65 -0
  129. package/src/keyboard-handlers.ts +26 -1
  130. package/src/keyboard.ts +3 -0
  131. package/src/row-drag-touch.ts +2 -2
  132. package/src/row-drag.test.ts +51 -0
  133. package/src/row-drag.ts +35 -2
  134. package/src/row-model.ts +6 -0
  135. package/src/row-resize.ts +24 -1
  136. package/src/selection.ts +1 -1
  137. package/src/server-block-cache.test.ts +27 -0
  138. package/src/server-block-cache.ts +13 -0
  139. package/src/server-data-source.infinite.test.ts +62 -0
  140. package/src/server-data-source.test.ts +19 -0
  141. package/src/server-data-source.ts +48 -4
  142. package/src/server.ts +2 -0
  143. package/src/sparkline.test.ts +7 -0
  144. package/src/sparkline.ts +6 -4
  145. package/src/svgrid-wrapper.types.ts +32 -0
  146. package/src/svgrid.api.test.ts +21 -0
  147. package/src/svgrid.charting.test.ts +12 -4
  148. package/src/svgrid.context-menu.test.ts +12 -0
  149. package/src/svgrid.data-push.svelte.test.ts +94 -0
  150. package/src/svgrid.detail-rows.svelte.test.ts +187 -0
  151. package/src/svgrid.filter-menu-scroll.test.ts +9 -0
  152. package/src/svgrid.gantt-seam.test.ts +1 -1
  153. package/src/svgrid.live-update-paths.svelte.test.ts +186 -0
  154. package/src/svgrid.menu-scroll-close.test.ts +10 -0
  155. package/src/svgrid.row-model-seam.svelte.test.ts +16 -0
  156. package/src/svgrid.row-pinning.test.ts +15 -1
  157. package/src/svgrid.selection-bar-seam.test.ts +1 -1
  158. package/src/svgrid.sticky-groups.svelte.test.ts +145 -0
  159. package/src/svgrid.upsell-license.test.ts +1 -1
  160. package/src/test-setup.ts +12 -0
  161. package/src/transaction.test.ts +58 -0
  162. package/src/validate.ts +7 -1
  163. package/src/virtualization/svelte-virtualizer.svelte.ts +1 -0
  164. package/src/virtualization/virtualizer.test.ts +44 -0
  165. package/src/virtualization/virtualizer.ts +13 -1
  166. package/dist/cdn/GridMenus-DLL-qZeu.js +0 -635
@@ -1,15 +1,15 @@
1
- import { E as e, F as t, G as n, H as r, I as i, L as a, N as o, U as s, V as c, X as l, Y as u, a as d, at as f, b as p, c as m, d as h, et as g, i as ee, it as _, j as v, k as y, l as b, lt as te, mt as x, nt as S, ot as C, pt as w, rt as T, s as ne, st as E, t as D, tt as re, ut as ie, v as O, x as k } from "./disclose-version-Dr7rEVv-.js";
2
- import { i as A } from "./editor-contract-LXgQJAgd.js";
3
- import { i as j } from "./popover-P-9P2YYn.js";
4
- import { t as M } from "./dismissable-DAHetSNk.js";
5
- import { n as N } from "./focus-trap-BBOQYBma.js";
1
+ import { E as e, F as t, G as n, H as r, I as i, L as a, N as o, U as s, V as c, X as l, Y as u, a as d, at as f, b as p, c as m, d as h, et as g, i as ee, it as _, j as v, k as y, l as b, lt as x, mt as S, nt as C, ot as w, pt as T, rt as E, s as te, st as D, t as O, tt as k, ut as A, v as j, x as ne } from "./disclose-version-Dr7rEVv-.js";
2
+ import { i as M } from "./editor-contract-LXgQJAgd.js";
3
+ import { i as N } from "./popover-P-9P2YYn.js";
4
+ import { t as P } from "./dismissable-Brc4EZU1.js";
5
+ import { n as F, r as re } from "./focus-trap-BBOQYBma.js";
6
6
  //#region src/a11y/scroll-lock.ts
7
- var P = 0, F = "", I = "";
8
- function L() {
7
+ var I = 0, L = "", R = "";
8
+ function z() {
9
9
  if (typeof document > "u") return () => {};
10
10
  let e = document.body;
11
- if (P === 0) {
12
- F = e.style.overflow, I = e.style.paddingRight;
11
+ if (I === 0) {
12
+ L = e.style.overflow, R = e.style.paddingRight;
13
13
  let t = window.innerWidth - document.documentElement.clientWidth;
14
14
  if (t > 0) {
15
15
  let n = parseFloat(getComputedStyle(e).paddingRight) || 0;
@@ -17,24 +17,24 @@ function L() {
17
17
  }
18
18
  e.style.overflow = "hidden";
19
19
  }
20
- P++;
20
+ I++;
21
21
  let t = !1;
22
22
  return () => {
23
- t || (t = !0, P = Math.max(0, P - 1), P === 0 && (e.style.overflow = F, e.style.paddingRight = I));
23
+ t || (t = !0, I = Math.max(0, I - 1), I === 0 && (e.style.overflow = L, e.style.paddingRight = R));
24
24
  };
25
25
  }
26
- function R() {
27
- return P;
26
+ function B() {
27
+ return I;
28
28
  }
29
29
  //#endregion
30
30
  //#region src/createOverlay.svelte.ts
31
- function z(e) {
31
+ function ie(e) {
32
32
  return l(() => {
33
33
  if (!e.open() || !e.getDialog()) return;
34
34
  e.onOpen?.();
35
- let t = e.getDialog(), n = e.trapFocus?.() ?? !0 ? N(t, e.initialFocus ? { initialFocus: e.initialFocus } : void 0) : null;
35
+ let t = e.getDialog(), n = e.trapFocus?.() ?? !0 ? F(t, e.initialFocus ? { initialFocus: e.initialFocus } : void 0) : null;
36
36
  n?.activate();
37
- let r = e.scrollLock?.() ?? !0 ? L() : null, i = M({
37
+ let r = e.scrollLock?.() ?? !0 ? z() : null, i = P({
38
38
  element: () => e.getDialog(),
39
39
  onDismiss: (t) => {
40
40
  (t === "escape" ? e.closeOnEsc?.() ?? !0 : e.closeOnBackdrop?.() ?? !0) && e.onClose();
@@ -53,10 +53,10 @@ function z(e) {
53
53
  }
54
54
  //#endregion
55
55
  //#region src/createTabs.svelte.ts
56
- var B = 0;
57
- function V(e) {
58
- let t = `sv-tabs-${B++}`, r = () => e.tabs(), i = () => e.orientation?.() ?? "horizontal", a = () => e.activation?.() ?? "automatic", o = E(() => r().filter((e) => !e.disabled)), s = E(() => e.value() ?? r().find((e) => !e.disabled)?.id ?? r()[0]?.id ?? ""), c = f(""), l = f(0), u = (e) => {
59
- _(c, e, !0), C(l);
56
+ var V = 0;
57
+ function H(e) {
58
+ let t = `sv-tabs-${V++}`, r = () => e.tabs(), i = () => e.orientation?.() ?? "horizontal", a = () => e.activation?.() ?? "automatic", o = D(() => r().filter((e) => !e.disabled)), s = D(() => e.value() ?? r().find((e) => !e.disabled)?.id ?? r()[0]?.id ?? ""), c = f(""), l = f(0), u = (e) => {
59
+ _(c, e, !0), w(l);
60
60
  }, d = (e) => `${t}-tab-${e}`, p = (e) => `${t}-panel-${e}`;
61
61
  function m(t) {
62
62
  let n = r().find((e) => e.id === t);
@@ -125,66 +125,66 @@ function V(e) {
125
125
  }
126
126
  //#endregion
127
127
  //#region src/SvTabs.svelte
128
- var H = a("<button type=\"button\" class=\"sv-tabs__scroll svelte-kxoh8m\" tabindex=\"-1\" aria-hidden=\"true\"><svg viewBox=\"0 0 24 24\" width=\"15\" height=\"15\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M15 18l-6-6 6-6\"></path></svg></button>"), ae = a("<button type=\"button\" class=\"sv-tabs__close svelte-kxoh8m\" tabindex=\"-1\"><svg viewBox=\"0 0 24 24\" width=\"12\" height=\"12\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.5\" stroke-linecap=\"round\"><path d=\"M6 6l12 12M18 6L6 18\"></path></svg></button>"), oe = a("<span role=\"presentation\"><button> </button> <!></span>"), U = a("<button type=\"button\" class=\"sv-tabs__scroll svelte-kxoh8m\" tabindex=\"-1\" aria-hidden=\"true\"><svg viewBox=\"0 0 24 24\" width=\"15\" height=\"15\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M9 18l6-6-6-6\"></path></svg></button>"), W = a("<div><!></div>"), G = a("<div><div class=\"sv-tabs__strip svelte-kxoh8m\"><!> <div></div> <!></div> <!></div>"), se = {
128
+ var U = a("<button type=\"button\" class=\"sv-tabs__scroll svelte-kxoh8m\" tabindex=\"-1\" aria-hidden=\"true\"><svg viewBox=\"0 0 24 24\" width=\"15\" height=\"15\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M15 18l-6-6 6-6\"></path></svg></button>"), ae = a("<button type=\"button\" class=\"sv-tabs__close svelte-kxoh8m\" tabindex=\"-1\"><svg viewBox=\"0 0 24 24\" width=\"12\" height=\"12\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.5\" stroke-linecap=\"round\"><path d=\"M6 6l12 12M18 6L6 18\"></path></svg></button>"), oe = a("<span role=\"presentation\"><button> </button> <!></span>"), W = a("<button type=\"button\" class=\"sv-tabs__scroll svelte-kxoh8m\" tabindex=\"-1\" aria-hidden=\"true\"><svg viewBox=\"0 0 24 24\" width=\"15\" height=\"15\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M9 18l6-6-6-6\"></path></svg></button>"), G = a("<div><!></div>"), K = a("<div><div class=\"sv-tabs__strip svelte-kxoh8m\"><!> <div></div> <!></div> <!></div>"), se = {
129
129
  hash: "svelte-kxoh8m",
130
130
  code: ".sv-tabs.svelte-kxoh8m {--_accent: var(--sg-accent, #2563eb);display:flex;gap:0;}.sv-tabs--top.svelte-kxoh8m {flex-direction:column;}.sv-tabs--bottom.svelte-kxoh8m {flex-direction:column-reverse;}.sv-tabs--left.svelte-kxoh8m {flex-direction:row;}.sv-tabs--right.svelte-kxoh8m {flex-direction:row-reverse;}.sv-tabs__strip.svelte-kxoh8m {display:flex;align-items:center;min-width:0;}.sv-tabs--vertical.svelte-kxoh8m .sv-tabs__strip:where(.svelte-kxoh8m) {align-items:stretch;}.sv-tabs__list.svelte-kxoh8m {display:flex;gap:2px;}.sv-tabs--horizontal.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {overflow-x:auto;flex:1 1 auto;min-width:0;scrollbar-width:none;scroll-behavior:smooth;}.sv-tabs--horizontal.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m)::-webkit-scrollbar {display:none;}.sv-tabs--horizontal.svelte-kxoh8m .sv-tabs__tabwrap:where(.svelte-kxoh8m) {flex:none;}.sv-tabs--vertical.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {flex-direction:column;}.sv-tabs__scroll.svelte-kxoh8m {flex:none;display:grid;place-items:center;width:26px;align-self:stretch;background:none;border:0;color:var(--sg-muted, #64748b);cursor:pointer;}.sv-tabs__scroll.svelte-kxoh8m:hover:not(:disabled) {color:var(--_accent);}.sv-tabs__scroll.svelte-kxoh8m:disabled {opacity:0.3;cursor:default;}\n /* Drag-reorder feedback */.sv-tabs__tabwrap.is-drag.svelte-kxoh8m {opacity:0.4;}.sv-tabs__tabwrap.is-over.svelte-kxoh8m::before {content:'';position:absolute;inset-inline-start:-1px;top:5px;bottom:5px;width:2px;background:var(--_accent);border-radius:2px;}.sv-tabs__tabwrap[draggable='true'].svelte-kxoh8m .sv-tabs__tab:where(.svelte-kxoh8m) {cursor:grab;}.sv-tabs--top.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {border-bottom:1px solid var(--sg-border, #e2e8f0);}.sv-tabs--bottom.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {border-top:1px solid var(--sg-border, #e2e8f0);}.sv-tabs--left.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {border-inline-end:1px solid var(--sg-border, #e2e8f0);}.sv-tabs--right.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {border-inline-start:1px solid var(--sg-border, #e2e8f0);}.sv-tabs--pill.svelte-kxoh8m .sv-tabs__list:where(.svelte-kxoh8m) {border:0;background:var(--sg-header-bg, #f1f5f9);padding:3px;border-radius:9px;gap:3px;}.sv-tabs__tabwrap.svelte-kxoh8m {position:relative;display:inline-flex;align-items:center;}.sv-tabs__tab.svelte-kxoh8m {background:none;border:0;font:inherit;font-size:13px;font-weight:600;color:var(--sg-muted, #64748b);padding:9px 14px;cursor:pointer;white-space:nowrap;}.sv-tabs__tabwrap.is-closable.svelte-kxoh8m .sv-tabs__tab:where(.svelte-kxoh8m) {padding-inline-end:4px;}.sv-tabs__tab.svelte-kxoh8m:hover:not(:disabled):not(.is-active) {color:var(--sg-fg, #0f172a);}.sv-tabs__tab.svelte-kxoh8m:disabled {opacity:0.45;cursor:not-allowed;}.sv-tabs__tab.svelte-kxoh8m:focus-visible {outline:2px solid var(--sg-focus-ring, var(--_accent));outline-offset:-2px;border-radius:6px;}.sv-tabs__close.svelte-kxoh8m {display:grid;place-items:center;width:18px;height:18px;margin-inline-end:8px;flex:none;background:none;border:0;color:var(--sg-muted, #64748b);cursor:pointer;border-radius:4px;}.sv-tabs__close.svelte-kxoh8m:hover {background:var(--sg-row-hover-bg, #f1f5f9);color:var(--sg-danger, #dc2626);}.sv-tabs--line.svelte-kxoh8m .sv-tabs__tab.is-active:where(.svelte-kxoh8m) {color:var(--_accent);}.sv-tabs--line.svelte-kxoh8m .sv-tabs__tabwrap.is-active:where(.svelte-kxoh8m)::after {content:'';position:absolute;background:var(--_accent);}.sv-tabs--line.sv-tabs--top.svelte-kxoh8m .sv-tabs__tabwrap.is-active:where(.svelte-kxoh8m)::after {left:8px;right:8px;height:2px;bottom:-1px;}.sv-tabs--line.sv-tabs--bottom.svelte-kxoh8m .sv-tabs__tabwrap.is-active:where(.svelte-kxoh8m)::after {left:8px;right:8px;height:2px;top:-1px;}.sv-tabs--line.sv-tabs--left.svelte-kxoh8m .sv-tabs__tabwrap.is-active:where(.svelte-kxoh8m)::after {top:8px;bottom:8px;width:2px;inset-inline-end:-1px;}.sv-tabs--line.sv-tabs--right.svelte-kxoh8m .sv-tabs__tabwrap.is-active:where(.svelte-kxoh8m)::after {top:8px;bottom:8px;width:2px;inset-inline-start:-1px;}.sv-tabs--pill.svelte-kxoh8m .sv-tabs__tab:where(.svelte-kxoh8m) {border-radius:7px;padding:7px 14px;}.sv-tabs--pill.svelte-kxoh8m .sv-tabs__tabwrap.is-active:where(.svelte-kxoh8m) .sv-tabs__tab:where(.svelte-kxoh8m), .sv-tabs--pill.svelte-kxoh8m .sv-tabs__tab.is-active:where(.svelte-kxoh8m) {background:var(--sg-bg, #fff);color:var(--sg-fg, #0f172a);box-shadow:0 1px 2px rgba(0,0,0,0.08);}.sv-tabs__panel.svelte-kxoh8m {padding:16px 2px;outline:none;flex:1;min-width:0;}"
131
131
  };
132
- function K(i, a) {
133
- ie(a, !0), k(i, se);
134
- let c = D(a, "value", 15), p = D(a, "variant", 3, "line"), m = D(a, "activation", 3, "automatic"), x = D(a, "reorderable", 3, !1), C = E(() => a.tabPosition ?? (a.orientation === "vertical" ? "left" : "top")), T = E(() => n(C) === "left" || n(C) === "right" ? "vertical" : "horizontal"), re = E(() => a.dir === "ltr" || a.dir === "rtl" ? a.dir : void 0), A = f(0), j = f(0), M = f(0), N = E(() => n(T) === "horizontal" && n(M) > n(j) + 1), P = E(() => n(A) <= 1), F = E(() => n(A) + n(j) >= n(M) - 1);
135
- function I() {
136
- J && (_(j, J.clientWidth, !0), _(M, J.scrollWidth, !0), _(A, J.scrollLeft, !0));
132
+ function q(i, a) {
133
+ A(a, !0), ne(i, se);
134
+ let c = O(a, "value", 15), p = O(a, "variant", 3, "line"), m = O(a, "activation", 3, "automatic"), S = O(a, "reorderable", 3, !1), w = D(() => a.tabPosition ?? (a.orientation === "vertical" ? "left" : "top")), E = D(() => n(w) === "left" || n(w) === "right" ? "vertical" : "horizontal"), k = D(() => a.dir === "ltr" || a.dir === "rtl" ? a.dir : void 0), M = f(0), N = f(0), P = f(0), F = D(() => n(E) === "horizontal" && n(P) > n(N) + 1), re = D(() => n(M) <= 1), I = D(() => n(M) + n(N) >= n(P) - 1);
135
+ function L() {
136
+ J && (_(N, J.clientWidth, !0), _(P, J.scrollWidth, !0), _(M, J.scrollLeft, !0));
137
137
  }
138
138
  l(() => {
139
- a.tabs.length, queueMicrotask(I);
139
+ a.tabs.length, queueMicrotask(L);
140
140
  }), l(() => {
141
- let e = () => I();
141
+ let e = () => L();
142
142
  return window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
143
143
  });
144
- function L(e) {
144
+ function R(e) {
145
145
  J?.scrollBy({
146
- left: e * Math.max(120, n(j) * .7),
146
+ left: e * Math.max(120, n(N) * .7),
147
147
  behavior: "smooth"
148
148
  });
149
149
  }
150
- let R = f(null), z = f(null);
151
- function B(e, t) {
150
+ let z = f(null), B = f(null);
151
+ function ie(e, t) {
152
152
  if (e === t) return;
153
153
  let n = a.tabs.map((e) => e.id), r = n.indexOf(e), i = n.indexOf(t);
154
154
  r < 0 || i < 0 || (n.splice(i, 0, n.splice(r, 1)[0]), a.onReorder?.(n));
155
155
  }
156
- let K = V({
156
+ let V = H({
157
157
  tabs: () => a.tabs,
158
158
  value: () => c(),
159
159
  onChange: (e) => {
160
160
  c(e), a.onChange?.(e);
161
161
  },
162
162
  onClose: (e) => a.onClose?.(e),
163
- orientation: () => n(T),
163
+ orientation: () => n(E),
164
164
  activation: () => m(),
165
165
  dir: () => a.dir,
166
166
  ariaLabel: () => a.ariaLabel
167
- }), q = E(() => K.activeId), J = null, Y = 0;
167
+ }), q = D(() => V.activeId), J = null, Y = 0;
168
168
  l(() => {
169
- if (K.focusTick !== Y) {
170
- Y = K.focusTick;
171
- let e = K.focusId;
169
+ if (V.focusTick !== Y) {
170
+ Y = V.focusTick;
171
+ let e = V.focusId;
172
172
  queueMicrotask(() => J?.querySelector(`[data-tab="${e}"]`)?.focus());
173
173
  }
174
174
  });
175
- var X = G(), Z = g(X), ce = g(Z), Q = (e) => {
176
- var i = H();
177
- u(() => i.disabled = n(P)), r("click", i, () => L(-1)), t(e, i);
175
+ var X = K(), Z = g(X), ce = g(Z), le = (e) => {
176
+ var i = U();
177
+ u(() => i.disabled = n(re)), r("click", i, () => R(-1)), t(e, i);
178
178
  };
179
179
  y(ce, (e) => {
180
- n(N) && e(Q);
180
+ n(F) && e(le);
181
181
  });
182
- var $ = S(ce, 2), le = (e) => _(A, e.currentTarget.scrollLeft, !0);
183
- b($, (e) => ({
182
+ var Q = C(ce, 2), $ = (e) => _(M, e.currentTarget.scrollLeft, !0);
183
+ b(Q, (e) => ({
184
184
  class: "sv-tabs__list",
185
- onscroll: le,
185
+ onscroll: $,
186
186
  ...e
187
- }), [() => K.tablistProps()], void 0, void 0, "svelte-kxoh8m"), e($, 21, () => a.tabs, (e) => e.id, (e, i) => {
187
+ }), [() => V.tablistProps()], void 0, void 0, "svelte-kxoh8m"), e(Q, 21, () => a.tabs, (e) => e.id, (e, i) => {
188
188
  var a = oe();
189
189
  let c;
190
190
  var l = g(a);
@@ -192,199 +192,200 @@ function K(i, a) {
192
192
  type: "button",
193
193
  class: "sv-tabs__tab",
194
194
  ...e,
195
- [ne]: { "is-active": n(i).id === n(q) }
196
- }), [() => K.tabProps(n(i).id)], void 0, void 0, "svelte-kxoh8m");
195
+ [te]: { "is-active": n(i).id === n(q) }
196
+ }), [() => V.tabProps(n(i).id)], void 0, void 0, "svelte-kxoh8m");
197
197
  var d = g(l, !0);
198
- w(l);
199
- var f = S(l, 2), p = (e) => {
198
+ T(l);
199
+ var f = C(l, 2), p = (e) => {
200
200
  var a = ae();
201
201
  u(() => h(a, "aria-label", `Close ${n(i).label}`)), r("click", a, (e) => {
202
- e.stopPropagation(), K.close(n(i).id);
202
+ e.stopPropagation(), V.close(n(i).id);
203
203
  }), t(e, a);
204
204
  };
205
205
  y(f, (e) => {
206
206
  n(i).closable && e(p);
207
- }), w(a), u(() => {
208
- c = O(a, 1, "sv-tabs__tabwrap svelte-kxoh8m", null, c, {
207
+ }), T(a), u(() => {
208
+ c = j(a, 1, "sv-tabs__tabwrap svelte-kxoh8m", null, c, {
209
209
  "is-active": n(i).id === n(q),
210
210
  "is-closable": n(i).closable,
211
- "is-drag": n(R) === n(i).id,
212
- "is-over": n(z) === n(i).id
213
- }), h(a, "draggable", x() && !n(i).disabled), o(d, n(i).label);
211
+ "is-drag": n(z) === n(i).id,
212
+ "is-over": n(B) === n(i).id
213
+ }), h(a, "draggable", S() && !n(i).disabled), o(d, n(i).label);
214
214
  }), s("dragstart", a, function(...e) {
215
- (x() ? (e) => {
216
- _(R, n(i).id, !0), e.dataTransfer && (e.dataTransfer.effectAllowed = "move");
215
+ (S() ? (e) => {
216
+ _(z, n(i).id, !0), e.dataTransfer && (e.dataTransfer.effectAllowed = "move");
217
217
  } : void 0)?.apply(this, e);
218
218
  }), s("dragover", a, function(...e) {
219
- (x() ? (e) => {
220
- e.preventDefault(), _(z, n(i).id, !0);
219
+ (S() ? (e) => {
220
+ e.preventDefault(), _(B, n(i).id, !0);
221
221
  } : void 0)?.apply(this, e);
222
222
  }), s("dragleave", a, function(...e) {
223
- (x() ? () => {
224
- n(z) === n(i).id && _(z, null);
223
+ (S() ? () => {
224
+ n(B) === n(i).id && _(B, null);
225
225
  } : void 0)?.apply(this, e);
226
226
  }), s("drop", a, function(...e) {
227
- (x() ? (e) => {
228
- e.preventDefault(), n(R) && B(n(R), n(i).id), _(R, null), _(z, null);
227
+ (S() ? (e) => {
228
+ e.preventDefault(), n(z) && ie(n(z), n(i).id), _(z, null), _(B, null);
229
229
  } : void 0)?.apply(this, e);
230
230
  }), s("dragend", a, function(...e) {
231
- (x() ? () => {
232
- _(R, null), _(z, null);
231
+ (S() ? () => {
232
+ _(z, null), _(B, null);
233
233
  } : void 0)?.apply(this, e);
234
234
  }), t(e, a);
235
- }), w($), ee($, (e) => J = e, () => J);
236
- var ue = S($, 2), de = (e) => {
237
- var i = U();
238
- u(() => i.disabled = n(F)), r("click", i, () => L(1)), t(e, i);
235
+ }), T(Q), ee(Q, (e) => J = e, () => J);
236
+ var ue = C(Q, 2), de = (e) => {
237
+ var i = W();
238
+ u(() => i.disabled = n(I)), r("click", i, () => R(1)), t(e, i);
239
239
  };
240
240
  y(ue, (e) => {
241
- n(N) && e(de);
242
- }), w(Z);
243
- var fe = S(Z, 2), pe = (e) => {
244
- var r = W();
241
+ n(F) && e(de);
242
+ }), T(Z);
243
+ var fe = C(Z, 2), pe = (e) => {
244
+ var r = G();
245
245
  b(r, (e) => ({
246
246
  class: "sv-tabs__panel",
247
247
  ...e
248
- }), [() => K.panelProps(n(q))], void 0, void 0, "svelte-kxoh8m");
248
+ }), [() => V.panelProps(n(q))], void 0, void 0, "svelte-kxoh8m");
249
249
  var i = g(r);
250
- v(i, () => a.panel, () => n(q)), w(r), t(e, r);
250
+ v(i, () => a.panel, () => n(q)), T(r), t(e, r);
251
251
  };
252
252
  y(fe, (e) => {
253
253
  a.panel && e(pe);
254
- }), w(X), u(() => {
255
- O(X, 1, `sv-tabs sv-tabs--${n(C) ?? ""} sv-tabs--${n(T) ?? ""} sv-tabs--${p() ?? ""}`, "svelte-kxoh8m"), h(X, "dir", n(re)), X.dir = X.dir;
256
- }), d($, "clientWidth", (e) => _(j, e)), t(i, X), te();
254
+ }), T(X), u(() => {
255
+ j(X, 1, `sv-tabs sv-tabs--${n(w) ?? ""} sv-tabs--${n(E) ?? ""} sv-tabs--${p() ?? ""}`, "svelte-kxoh8m"), h(X, "dir", n(k)), X.dir = X.dir;
256
+ }), d(Q, "clientWidth", (e) => _(N, e)), t(i, X), x();
257
257
  }
258
258
  c(["click"]);
259
259
  //#endregion
260
260
  //#region src/SvModal.svelte
261
- var q = a("<button type=\"button\" class=\"sv-modal__x\" aria-label=\"Close\">&times;</button>"), J = a("<div><h2 class=\"sv-modal__title\"> </h2> <!></div>"), Y = a("<div class=\"sv-modal__footer\"><!></div>"), X = a("<div class=\"sv-modal__resize\" aria-hidden=\"true\"></div>"), Z = a("<div class=\"sv-modal__backdrop\"><div><!> <div class=\"sv-modal__body\"><!></div> <!> <!></div></div>"), ce = {
261
+ var J = a("<button type=\"button\" class=\"sv-modal__x\" aria-label=\"Close\">&times;</button>"), Y = a("<div><h2 class=\"sv-modal__title\"> </h2> <!></div>"), X = a("<div class=\"sv-modal__footer\"><!></div>"), Z = a("<div class=\"sv-modal__resize\" aria-hidden=\"true\"></div>"), ce = a("<div class=\"sv-modal__backdrop\"><div><!> <div class=\"sv-modal__body\"><!></div> <!> <!></div></div>"), le = {
262
262
  hash: "svelte-11fjt09",
263
263
  code: ".sv-modal__backdrop {position:fixed;inset:0;z-index:2147483000;background:rgba(15, 23, 42, 0.45);backdrop-filter:blur(1.5px);\n animation: svelte-11fjt09-sv-modal-fade 0.16s ease both;}\n @keyframes svelte-11fjt09-sv-modal-fade { from { opacity: 0 } to { opacity: 1 } }\n @media (prefers-reduced-motion: reduce) {.sv-modal__backdrop { animation: none} }.sv-modal {position:fixed;top:50%;left:50%;display:flex;flex-direction:column;max-width:94vw;max-height:88vh;min-width:240px;background:var(--sg-bg, #fff);color:var(--sg-fg, #0f172a);border:1px solid var(--sg-border, #e2e8f0);border-radius:12px;overflow:hidden;box-shadow:0 24px 64px -16px rgba(15, 23, 42, 0.5);\n animation: svelte-11fjt09-sv-modal-in 0.18s cubic-bezier(0.16, 1, 0.3, 1) both;}\n @keyframes svelte-11fjt09-sv-modal-in { from { opacity: 0; transform: translate(-50%, -50%) scale(0.94) } to { opacity: 1 } }\n @media (prefers-reduced-motion: reduce) {.sv-modal { animation: none} }.sv-modal--sm {width:360px;}.sv-modal--md {width:520px;}.sv-modal--lg {width:720px;}.sv-modal.is-resized {max-width:none;max-height:none;}.sv-modal__header {display:flex;align-items:center;gap:12px;padding:13px 16px;border-bottom:1px solid var(--sg-border, #e2e8f0);}.sv-modal__header.is-draggable {cursor:move;touch-action:none;user-select:none;}.sv-modal__title {flex:1;margin:0;font-size:15px;font-weight:650;}.sv-modal__x {flex:none;width:28px;height:28px;display:grid;place-items:center;background:none;border:0;color:var(--sg-muted, #64748b);cursor:pointer;border-radius:6px;font-size:20px;line-height:1;}.sv-modal__x:hover {background:var(--sg-row-hover-bg, #f1f5f9);color:var(--sg-fg, #0f172a);}.sv-modal__body {padding:16px;overflow:auto;flex:1;font-size:13.5px;line-height:1.6;}.sv-modal__footer {display:flex;justify-content:flex-end;gap:8px;padding:12px 16px;border-top:1px solid var(--sg-border, #e2e8f0);}.sv-modal__resize {position:absolute;inset-inline-end:0;bottom:0;width:16px;height:16px;cursor:nwse-resize;touch-action:none;background:linear-gradient(135deg, transparent 50%, var(--sg-muted, #94a3b8) 50%, var(--sg-muted, #94a3b8) 60%, transparent 60%, transparent 72%, var(--sg-muted, #94a3b8) 72%, var(--sg-muted, #94a3b8) 82%, transparent 82%);opacity:0.6;}"
264
264
  };
265
265
  function Q(e, a) {
266
- ie(a, !0), k(e, ce);
267
- let c = D(a, "open", 15, !1), l = D(a, "size", 3, "md"), d = D(a, "draggable", 3, !1), C = D(a, "resizable", 3, !1), E = D(a, "closeOnBackdrop", 3, !0), M = D(a, "closeOnEsc", 3, !0), N = D(a, "hideClose", 3, !1), P = A("sv-modal-title"), F = f(null), I = f(T({
266
+ A(a, !0), ne(e, le);
267
+ let c = O(a, "open", 15, !1), l = O(a, "size", 3, "md"), d = O(a, "draggable", 3, !1), w = O(a, "resizable", 3, !1), D = O(a, "closeOnBackdrop", 3, !0), P = O(a, "closeOnEsc", 3, !0), F = O(a, "hideClose", 3, !1), I = M("sv-modal-title"), L = f(null), R = f(E({
268
268
  x: 0,
269
269
  y: 0
270
- })), L = f(null);
271
- function R() {
270
+ })), z = f(null);
271
+ function B() {
272
272
  c(!1), a.onClose?.();
273
273
  }
274
- let B = z({
274
+ let V = ie({
275
275
  open: () => c(),
276
- getDialog: () => n(F),
277
- onClose: R,
278
- closeOnEsc: () => M(),
279
- closeOnBackdrop: () => E(),
276
+ getDialog: () => n(L),
277
+ onClose: B,
278
+ closeOnEsc: () => P(),
279
+ closeOnBackdrop: () => D(),
280
280
  onOpen: () => {
281
- _(I, {
281
+ _(R, {
282
282
  x: 0,
283
283
  y: 0
284
- }, !0), _(L, null);
285
- }
286
- }), V = !1, H = {
284
+ }, !0), _(z, null);
285
+ },
286
+ initialFocus: () => a.initialFocus?.() || (n(L) ? re(n(L)).find((e) => !e.closest(".sv-modal__header")) ?? n(L) : null)
287
+ }), H = !1, U = {
287
288
  x: 0,
288
289
  y: 0,
289
290
  ox: 0,
290
291
  oy: 0
291
292
  };
292
293
  function ae(e) {
293
- !d() || e.target.closest(".sv-modal__x") || (V = !0, H = {
294
+ !d() || e.target.closest(".sv-modal__x") || (H = !0, U = {
294
295
  x: e.clientX,
295
296
  y: e.clientY,
296
- ox: n(I).x,
297
- oy: n(I).y
297
+ ox: n(R).x,
298
+ oy: n(R).y
298
299
  }, e.currentTarget.setPointerCapture(e.pointerId));
299
300
  }
300
301
  function oe(e) {
301
- V && _(I, {
302
- x: H.ox + (e.clientX - H.x),
303
- y: H.oy + (e.clientY - H.y)
302
+ H && _(R, {
303
+ x: U.ox + (e.clientX - U.x),
304
+ y: U.oy + (e.clientY - U.y)
304
305
  }, !0);
305
306
  }
306
- function U(e) {
307
- V && (V = !1, e.currentTarget.releasePointerCapture(e.pointerId));
307
+ function W(e) {
308
+ H && (H = !1, e.currentTarget.releasePointerCapture(e.pointerId));
308
309
  }
309
- let W = !1, G = {
310
+ let G = !1, K = {
310
311
  x: 0,
311
312
  y: 0,
312
313
  w: 0,
313
314
  h: 0
314
315
  };
315
316
  function se(e) {
316
- if (!C() || !n(F)) return;
317
- e.stopPropagation(), W = !0;
318
- let t = n(F).getBoundingClientRect();
319
- G = {
317
+ if (!w() || !n(L)) return;
318
+ e.stopPropagation(), G = !0;
319
+ let t = n(L).getBoundingClientRect();
320
+ K = {
320
321
  x: e.clientX,
321
322
  y: e.clientY,
322
323
  w: t.width,
323
324
  h: t.height
324
- }, _(L, {
325
+ }, _(z, {
325
326
  w: t.width,
326
327
  h: t.height
327
328
  }, !0), e.currentTarget.setPointerCapture(e.pointerId);
328
329
  }
329
- function K(e) {
330
- W && _(L, {
331
- w: Math.max(240, G.w + (e.clientX - G.x)),
332
- h: Math.max(160, G.h + (e.clientY - G.y))
330
+ function q(e) {
331
+ G && _(z, {
332
+ w: Math.max(240, K.w + (e.clientX - K.x)),
333
+ h: Math.max(160, K.h + (e.clientY - K.y))
333
334
  }, !0);
334
335
  }
335
336
  function Q(e) {
336
- W && (W = !1, e.currentTarget.releasePointerCapture(e.pointerId));
337
+ G && (G = !1, e.currentTarget.releasePointerCapture(e.pointerId));
337
338
  }
338
- var $ = i(), le = re($), ue = (e) => {
339
- var i = Z(), c = g(i);
339
+ var $ = i(), ue = k($), de = (e) => {
340
+ var i = ce(), c = g(i);
340
341
  b(c, (e) => ({
341
342
  class: `sv-modal sv-modal--${l() ?? ""}`,
342
343
  ...e,
343
- [ne]: { "is-resized": !!n(L) },
344
+ [te]: { "is-resized": !!n(z) },
344
345
  [m]: {
345
- transform: `translate(calc(-50% + ${n(I).x}px), calc(-50% + ${n(I).y}px))`,
346
- width: n(L) ? `${n(L).w}px` : a.width ? `${a.width}px` : void 0,
347
- height: n(L) ? `${n(L).h}px` : void 0
346
+ transform: `translate(calc(-50% + ${n(R).x}px), calc(-50% + ${n(R).y}px))`,
347
+ width: n(z) ? `${n(z).w}px` : a.width ? `${a.width}px` : void 0,
348
+ height: n(z) ? `${n(z).h}px` : void 0
348
349
  }
349
- }), [() => B.dialogProps({ labelledBy: a.title ? P : void 0 })]);
350
- var f = g(c), te = (e) => {
351
- var n = J();
350
+ }), [() => V.dialogProps({ labelledBy: a.title ? I : void 0 })]);
351
+ var f = g(c), x = (e) => {
352
+ var n = Y();
352
353
  let i;
353
354
  var c = g(n), l = g(c, !0);
354
- w(c);
355
- var f = S(c, 2), p = (e) => {
356
- var n = q();
357
- r("click", n, R), t(e, n);
355
+ T(c);
356
+ var f = C(c, 2), p = (e) => {
357
+ var n = J();
358
+ r("click", n, B), t(e, n);
358
359
  };
359
360
  y(f, (e) => {
360
- N() || e(p);
361
- }), w(n), u(() => {
362
- i = O(n, 1, "sv-modal__header", null, i, { "is-draggable": d() }), h(c, "id", P), o(l, a.title ?? "");
363
- }), r("pointerdown", n, ae), r("pointermove", n, oe), r("pointerup", n, U), s("pointercancel", n, U), t(e, n);
361
+ F() || e(p);
362
+ }), T(n), u(() => {
363
+ i = j(n, 1, "sv-modal__header", null, i, { "is-draggable": d() }), h(c, "id", I), o(l, a.title ?? "");
364
+ }), r("pointerdown", n, ae), r("pointermove", n, oe), r("pointerup", n, W), s("pointercancel", n, W), t(e, n);
364
365
  };
365
366
  y(f, (e) => {
366
- (a.title || !N()) && e(te);
367
+ (a.title || !F()) && e(x);
367
368
  });
368
- var T = S(f, 2), E = g(T);
369
- v(E, () => a.children ?? x), w(T);
370
- var D = S(T, 2), re = (e) => {
371
- var n = Y(), r = g(n);
372
- v(r, () => a.footer), w(n), t(e, n);
369
+ var E = C(f, 2), D = g(E);
370
+ v(D, () => a.children ?? S), T(E);
371
+ var O = C(E, 2), k = (e) => {
372
+ var n = X(), r = g(n);
373
+ v(r, () => a.footer), T(n), t(e, n);
373
374
  };
374
- y(D, (e) => {
375
- a.footer && e(re);
375
+ y(O, (e) => {
376
+ a.footer && e(k);
376
377
  });
377
- var ie = S(D, 2), k = (e) => {
378
- var n = X();
379
- r("pointerdown", n, se), r("pointermove", n, K), r("pointerup", n, Q), s("pointercancel", n, Q), t(e, n);
378
+ var A = C(O, 2), ne = (e) => {
379
+ var n = Z();
380
+ r("pointerdown", n, se), r("pointermove", n, q), r("pointerup", n, Q), s("pointercancel", n, Q), t(e, n);
380
381
  };
381
- y(ie, (e) => {
382
- C() && e(k);
383
- }), w(c), ee(c, (e) => _(F, e), () => n(F)), w(i), p(i, (e) => j?.(e)), t(e, i);
382
+ y(A, (e) => {
383
+ w() && e(ne);
384
+ }), T(c), ee(c, (e) => _(L, e), () => n(L)), T(i), p(i, (e) => N?.(e)), t(e, i);
384
385
  };
385
- y(le, (e) => {
386
- c() && e(ue);
387
- }), t(e, $), te();
386
+ y(ue, (e) => {
387
+ c() && e(de);
388
+ }), t(e, $), x();
388
389
  }
389
390
  c([
390
391
  "pointerdown",
@@ -393,4 +394,4 @@ c([
393
394
  "click"
394
395
  ]);
395
396
  //#endregion
396
- export { L as a, z as i, K as n, R as o, V as r, Q as t };
397
+ export { z as a, ie as i, q as n, B as o, H as r, Q as t };
@@ -54,15 +54,37 @@ function e(e, t) {
54
54
  }
55
55
  var t = /* @__PURE__ */ new Map();
56
56
  function n(e, n) {
57
- let r = (Array.isArray(e) ? e.join(",") : e ?? "") + "|" + (n.style ?? "") + "|" + (n.currency ?? "") + "|" + (n.minimumFractionDigits ?? "") + "|" + (n.maximumFractionDigits ?? "") + "|" + (n.useGrouping ?? "") + "|" + (n.currencyDisplay ?? "") + "|" + (n.notation ?? ""), i = t.get(r);
57
+ let r = (Array.isArray(e) ? e.join(",") : e ?? "") + "|" + (n.style ?? "") + "|" + (n.currency ?? "") + "|" + (n.minimumFractionDigits ?? "") + "|" + (n.maximumFractionDigits ?? "") + "|" + (n.useGrouping ?? "") + "|" + (n.currencyDisplay ?? "") + "|" + (n.notation ?? "") + "|" + (n.signDisplay ?? "") + "|" + (n.minimumIntegerDigits ?? "") + "|" + (n.compactDisplay ?? "") + "|" + (n.unit ?? "") + "|" + (n.unitDisplay ?? "") + "|" + (n.minimumSignificantDigits ?? "") + "|" + (n.maximumSignificantDigits ?? ""), i = t.get(r);
58
58
  return i || (i = new Intl.NumberFormat(e, n), t.set(r, i)), i;
59
59
  }
60
- var r = /* @__PURE__ */ new Map();
61
- function i(e, t) {
62
- let n = (Array.isArray(e) ? e.join(",") : e ?? "") + "|" + (t.dateStyle ?? "") + "|" + (t.timeStyle ?? "") + "|" + (t.year ?? "") + "|" + (t.month ?? "") + "|" + (t.day ?? "") + "|" + (t.hour ?? "") + "|" + (t.minute ?? "") + "|" + (t.second ?? "") + "|" + (t.weekday ?? "") + "|" + (t.hour12 ?? ""), i = r.get(n);
63
- return i || (i = new Intl.DateTimeFormat(e, t), r.set(n, i)), i;
60
+ function r(e) {
61
+ if (e instanceof Date) return Number.isNaN(e.getTime()) ? null : e;
62
+ if (typeof e == "number") {
63
+ if (!Number.isFinite(e)) return null;
64
+ let t = new Date(e);
65
+ return Number.isNaN(t.getTime()) ? null : t;
66
+ }
67
+ if (typeof e != "string") return null;
68
+ let t = e.trim();
69
+ if (t === "") return null;
70
+ let n = /^(\d{4})-(\d{2})-(\d{2})$/.exec(t);
71
+ if (n) {
72
+ let [e, t, r] = [
73
+ Number(n[1]),
74
+ Number(n[2]) - 1,
75
+ Number(n[3])
76
+ ], i = /* @__PURE__ */ new Date(0);
77
+ return i.setFullYear(e, t, r), i.setHours(0, 0, 0, 0), i.getMonth() === t && i.getDate() === r ? i : null;
78
+ }
79
+ let r = new Date(t);
80
+ return Number.isNaN(r.getTime()) ? null : r;
64
81
  }
82
+ var i = /* @__PURE__ */ new Map();
65
83
  function a(e, t) {
84
+ let n = (Array.isArray(e) ? e.join(",") : e ?? "") + "|" + (t.dateStyle ?? "") + "|" + (t.timeStyle ?? "") + "|" + (t.year ?? "") + "|" + (t.month ?? "") + "|" + (t.day ?? "") + "|" + (t.hour ?? "") + "|" + (t.minute ?? "") + "|" + (t.second ?? "") + "|" + (t.weekday ?? "") + "|" + (t.hour12 ?? ""), r = i.get(n);
85
+ return r || (r = new Intl.DateTimeFormat(e, t), i.set(n, r)), r;
86
+ }
87
+ function o(e, t) {
66
88
  let r = typeof e == "number" ? e : Number(e);
67
89
  if (!Number.isFinite(r)) return String(e ?? "");
68
90
  let i = t.locales;
@@ -83,4 +105,4 @@ function a(e, t) {
83
105
  return n(i, t.options ?? {}).format(r);
84
106
  }
85
107
  //#endregion
86
- export { e as i, i as n, n as r, a as t };
108
+ export { e as a, r as i, a as n, n as r, o as t };
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
2
- import { i as t, n, r, t as i } from "./chart-trend-CaN9mDEV.js";
2
+ import { i as t, n, r, t as i } from "./chart-trend-C1aOAPBZ.js";
3
3
  //#region src/chart-scale.ts
4
4
  var a = [
5
5
  "#2563eb",
@@ -1,6 +1,6 @@
1
1
  import { E as e, F as t, G as n, H as r, L as i, N as a, V as o, Y as s, d as c, et as l, f as u, g as d, h as f, k as p, lt as m, m as h, nt as g, pt as _, st as v, t as y, tt as b, u as x, ut as S, v as ee } from "./disclose-version-Dr7rEVv-.js";
2
2
  import { a as C } from "./editor-contract-LXgQJAgd.js";
3
- import { b as te } from "./chart-Dz7SqMXH.js";
3
+ import { b as te } from "./chart-By7h2Guv.js";
4
4
  //#region src/SvGridChartPickers.svelte
5
5
  var w = [
6
6
  {
@@ -1,5 +1,5 @@
1
1
  import { a as e } from "./editor-contract-LXgQJAgd.js";
2
- import { b as t } from "./chart-Dz7SqMXH.js";
2
+ import { b as t } from "./chart-By7h2Guv.js";
3
3
  import * as n from "svelte/internal/client";
4
4
  import "svelte/internal/disclose-version";
5
5
  //#region src/SvGridChartPickers.svelte
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
2
- import { i as t, n, t as r } from "./chart-trend-CaN9mDEV.js";
2
+ import { i as t, n, t as r } from "./chart-trend-C1aOAPBZ.js";
3
3
  //#region src/chart-summary.ts
4
4
  var i = /* @__PURE__ */ e({ chartSummary: () => d }), a = (e) => typeof e == "number" && Number.isFinite(e);
5
5
  function o(e) {
@@ -1,4 +1,4 @@
1
- import { r as e } from "./cell-formatting-C2Hf5gqd.js";
1
+ import { r as e } from "./cell-formatting-Mnv84zoE.js";
2
2
  //#region src/chart-format.ts
3
3
  function t(e) {
4
4
  let t = Math.abs(e);
@@ -37,8 +37,12 @@ function o(t, n) {
37
37
  if (typeof window > "u") return () => {};
38
38
  let r = (r) => {
39
39
  e(t(), r.target) || n();
40
+ }, i = !1, a = requestAnimationFrame(() => {
41
+ a = null, i = !0, window.addEventListener("scroll", r, !0);
42
+ });
43
+ return () => {
44
+ a !== null && cancelAnimationFrame(a), a = null, i && window.removeEventListener("scroll", r, !0), i = !1;
40
45
  };
41
- return window.addEventListener("scroll", r, !0), () => window.removeEventListener("scroll", r, !0);
42
46
  }
43
47
  //#endregion
44
48
  export { a as n, o as r, i as t };