impact-nova 1.5.14 → 1.6.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 (149) hide show
  1. package/dist/components/ui/accordion.d.ts +4 -1
  2. package/dist/components/ui/accordion.js +28 -22
  3. package/dist/components/ui/ag-grid-react/cell-renderers/badge-cell-renderer.js +11 -11
  4. package/dist/components/ui/ag-grid-react/cell-renderers/checkbox-display-renderer.js +12 -12
  5. package/dist/components/ui/ag-grid-react/cell-renderers/date-display-renderer.js +13 -13
  6. package/dist/components/ui/ag-grid-react/cell-renderers/editors/date-cell-editor.js +13 -13
  7. package/dist/components/ui/ag-grid-react/cell-renderers/editors/input-cell-editor.js +30 -30
  8. package/dist/components/ui/ag-grid-react/cell-renderers/editors/percent-progress-cell-editor.js +13 -13
  9. package/dist/components/ui/ag-grid-react/cell-renderers/editors/split-cell-editor.js +16 -16
  10. package/dist/components/ui/ag-grid-react/cell-renderers/editors/textarea-cell-editor.js +17 -17
  11. package/dist/components/ui/ag-grid-react/cell-renderers/input-display-renderer.js +11 -11
  12. package/dist/components/ui/ag-grid-react/cell-renderers/link-with-batch-cell-renderer.js +2 -2
  13. package/dist/components/ui/ag-grid-react/cell-renderers/percent-progress-display-renderer.js +11 -13
  14. package/dist/components/ui/ag-grid-react/cell-renderers/select-display-renderer.js +8 -8
  15. package/dist/components/ui/ag-grid-react/cell-renderers/split-cell-renderer.js +6 -6
  16. package/dist/components/ui/ag-grid-react/cell-renderers/status-badge-renderer.d.ts +1 -1
  17. package/dist/components/ui/ag-grid-react/cell-renderers/status-badge-renderer.js +14 -14
  18. package/dist/components/ui/ag-grid-react/cell-renderers/switch-display-renderer.js +18 -18
  19. package/dist/components/ui/ag-grid-react/cell-renderers/textarea-display-renderer.js +6 -6
  20. package/dist/components/ui/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.js +14 -14
  21. package/dist/components/ui/ag-grid-react/headers/advanced-filter/column-filter-section.js +35 -35
  22. package/dist/components/ui/ag-grid-react/headers/column-menu/column-settings-menu.js +49 -49
  23. package/dist/components/ui/ag-grid-react/headers/components/header-info.js +29 -29
  24. package/dist/components/ui/ag-grid-react/headers/components/info-modal.js +9 -9
  25. package/dist/components/ui/ag-grid-react/headers/components/section-renderers.js +20 -20
  26. package/dist/components/ui/ag-grid-react/headers/custom-header-group.js +10 -10
  27. package/dist/components/ui/ag-grid-react/headers/custom-header.js +76 -76
  28. package/dist/components/ui/ag-grid-react/headers/header-search-input.js +118 -118
  29. package/dist/components/ui/ag-grid-react/index.js +121 -102
  30. package/dist/components/ui/alert-dialog.js +6 -6
  31. package/dist/components/ui/alert.d.ts +4 -3
  32. package/dist/components/ui/alert.js +182 -64
  33. package/dist/components/ui/avatar.js +5 -5
  34. package/dist/components/ui/badge.d.ts +7 -2
  35. package/dist/components/ui/badge.js +105 -32
  36. package/dist/components/ui/breadcrumb.js +26 -21
  37. package/dist/components/ui/button-group.d.ts +7 -0
  38. package/dist/components/ui/button-group.js +116 -91
  39. package/dist/components/ui/button-variants.d.ts +7 -2
  40. package/dist/components/ui/button-variants.js +31 -16
  41. package/dist/components/ui/button.d.ts +2 -2
  42. package/dist/components/ui/button.js +10 -10
  43. package/dist/components/ui/calendar.js +185 -184
  44. package/dist/components/ui/card.js +24 -24
  45. package/dist/components/ui/chart/chart.js +27 -27
  46. package/dist/components/ui/chart/chart.utils.js +50 -50
  47. package/dist/components/ui/checkbox.js +22 -22
  48. package/dist/components/ui/chips.d.ts +19 -3
  49. package/dist/components/ui/chips.js +140 -41
  50. package/dist/components/ui/command-palette/command-palette-layout.d.ts +28 -0
  51. package/dist/components/ui/command-palette/command-palette-layout.js +59 -0
  52. package/dist/components/ui/command-palette/command-palette.js +254 -264
  53. package/dist/components/ui/command-palette/index.d.ts +1 -1
  54. package/dist/components/ui/command-palette/index.js +42 -41
  55. package/dist/components/ui/command-palette/kbd.js +18 -18
  56. package/dist/components/ui/command-palette/shortcut-settings.d.ts +3 -3
  57. package/dist/components/ui/command-palette/shortcut-settings.js +105 -111
  58. package/dist/components/ui/command-palette/utils.d.ts +6 -1
  59. package/dist/components/ui/command-palette/utils.js +81 -74
  60. package/dist/components/ui/data-table/data-table-column-list.js +31 -31
  61. package/dist/components/ui/data-table/data-table-constants.d.ts +6 -0
  62. package/dist/components/ui/data-table/data-table-constants.js +4 -0
  63. package/dist/components/ui/data-table/data-table-context.d.ts +4 -0
  64. package/dist/components/ui/data-table/data-table-format-options.js +35 -35
  65. package/dist/components/ui/data-table/data-table-sheet.d.ts +4 -4
  66. package/dist/components/ui/data-table/data-table-sheet.js +91 -58
  67. package/dist/components/ui/data-table/data-table-view-options.js +29 -29
  68. package/dist/components/ui/data-table/data-table.js +84 -52
  69. package/dist/components/ui/data-table/index.d.ts +1 -0
  70. package/dist/components/ui/data-table/index.js +15 -13
  71. package/dist/components/ui/date-picker/date-picker.js +35 -35
  72. package/dist/components/ui/date-picker/date-range-picker.js +166 -164
  73. package/dist/components/ui/date-picker/month-picker.js +14 -14
  74. package/dist/components/ui/date-picker/month-range-picker.js +198 -189
  75. package/dist/components/ui/date-picker/multi-date-picker.js +14 -14
  76. package/dist/components/ui/date-picker/multi-month-picker.js +1 -1
  77. package/dist/components/ui/date-picker/multi-week-picker.js +1 -1
  78. package/dist/components/ui/date-picker/week-picker.js +2 -2
  79. package/dist/components/ui/date-picker/week-range-picker.js +164 -162
  80. package/dist/components/ui/dialog.js +25 -28
  81. package/dist/components/ui/drawer.js +40 -40
  82. package/dist/components/ui/dropdown-menu.js +72 -72
  83. package/dist/components/ui/empty-container.js +73 -69
  84. package/dist/components/ui/file-upload.js +137 -135
  85. package/dist/components/ui/filter-panel/filter-panel.d.ts +2 -2
  86. package/dist/components/ui/filter-panel/filter-panel.js +175 -97
  87. package/dist/components/ui/filter-strip/filter-strip.d.ts +1 -1
  88. package/dist/components/ui/filter-strip/filter-strip.js +63 -50
  89. package/dist/components/ui/filter-strip/filter-summary.d.ts +4 -1
  90. package/dist/components/ui/filter-strip/filter-summary.js +230 -146
  91. package/dist/components/ui/filter-strip/filter-tag-list.js +125 -91
  92. package/dist/components/ui/header.d.ts +7 -3
  93. package/dist/components/ui/header.js +87 -79
  94. package/dist/components/ui/horizontal-scroller/horizontal-scroller.js +44 -44
  95. package/dist/components/ui/hover-card.js +10 -10
  96. package/dist/components/ui/input.js +79 -70
  97. package/dist/components/ui/loader.js +16 -16
  98. package/dist/components/ui/nested-list/components/NestedListCategoryFilters.js +16 -16
  99. package/dist/components/ui/nested-list/components/NestedListHeader.js +27 -27
  100. package/dist/components/ui/nested-list/components/SortableItem.js +58 -58
  101. package/dist/components/ui/notification-panel/notification-item.js +32 -32
  102. package/dist/components/ui/notification-panel/notification-list.js +24 -24
  103. package/dist/components/ui/notification-panel/notification-panel.js +26 -26
  104. package/dist/components/ui/popover.js +22 -22
  105. package/dist/components/ui/progress.js +34 -34
  106. package/dist/components/ui/prompt.js +48 -48
  107. package/dist/components/ui/radio-group.js +63 -54
  108. package/dist/components/ui/select/components/LabelWithSequence.js +6 -6
  109. package/dist/components/ui/select/components/Submenu.js +33 -33
  110. package/dist/components/ui/select/select.js +425 -376
  111. package/dist/components/ui/sheet.js +88 -66
  112. package/dist/components/ui/sidebar.js +342 -296
  113. package/dist/components/ui/skeleton.js +6 -6
  114. package/dist/components/ui/slider.js +17 -17
  115. package/dist/components/ui/statistics-card.d.ts +86 -0
  116. package/dist/components/ui/statistics-card.hooks.d.ts +150 -0
  117. package/dist/components/ui/statistics-card.hooks.js +100 -0
  118. package/dist/components/ui/statistics-card.js +259 -0
  119. package/dist/components/ui/stepper.js +51 -51
  120. package/dist/components/ui/switch.js +7 -7
  121. package/dist/components/ui/tabs.js +70 -70
  122. package/dist/components/ui/tag-group.d.ts +1 -0
  123. package/dist/components/ui/tag-group.js +14 -13
  124. package/dist/components/ui/tag.js +43 -43
  125. package/dist/components/ui/textarea.js +86 -58
  126. package/dist/components/ui/toast.js +39 -39
  127. package/dist/components/ui/tooltip.js +23 -23
  128. package/dist/components/ui/types/date-picker.types.d.ts +1 -0
  129. package/dist/components/ui/types/filter-panel.types.d.ts +3 -0
  130. package/dist/components/ui/types/filter-strip.types.d.ts +14 -0
  131. package/dist/components/ui/types/horizontal-scroller.types.d.ts +1 -1
  132. package/dist/components/ui/types/statistics-card.types.d.ts +1 -0
  133. package/dist/i18n/defaultMessages.d.ts +8 -0
  134. package/dist/i18n/defaultMessages.js +15 -9
  135. package/dist/i18n/locales/de.js +7 -1
  136. package/dist/i18n/locales/es.js +7 -1
  137. package/dist/i18n/locales/hi.js +7 -1
  138. package/dist/i18n/locales/kn.js +7 -1
  139. package/dist/icons/assets/bulk-edit.svg.js +5 -0
  140. package/dist/icons/assets/clock.svg.js +5 -0
  141. package/dist/icons/assets/statistics.svg.js +5 -0
  142. package/dist/icons/index.d.ts +3 -0
  143. package/dist/icons/index.js +254 -206
  144. package/dist/impact-nova.css +1 -1
  145. package/dist/index.d.ts +1 -0
  146. package/dist/index.js +361 -347
  147. package/package.json +3 -2
  148. package/tailwind.config.js +259 -152
  149. /package/dist/icons/assets/{PivotMode.svg.js → pivotMode.svg.js} +0 -0
@@ -1,259 +1,252 @@
1
- import { jsx as e, jsxs as m, Fragment as le } from "react/jsx-runtime";
2
- import * as o from "react";
3
- import * as S from "@radix-ui/react-dialog";
4
- import { Search as W } from "lucide-react";
5
- import { cn as d } from "../../../lib/utils.js";
6
- import { useCommandPalette as me } from "./command-palette-context.js";
7
- import { Kbd as E } from "./kbd.js";
8
- import { fuzzyFilter as fe, keybindingToSymbols as ue } from "./utils.js";
9
- const pe = /* @__PURE__ */ new Set(["browser", "system", "ag-grid"]);
10
- function xe(s) {
11
- return !!s && pe.has(s);
1
+ import { jsx as e, jsxs as c, Fragment as se } from "react/jsx-runtime";
2
+ import * as r from "react";
3
+ import * as P from "@radix-ui/react-dialog";
4
+ import { Search as Q } from "lucide-react";
5
+ import { cn as l } from "../../../lib/utils.js";
6
+ import { useCommandPalette as ie } from "./command-palette-context.js";
7
+ import { Kbd as v } from "./kbd.js";
8
+ import { buildCommandPaletteLayout as de } from "./command-palette-layout.js";
9
+ import { fuzzyFilter as le, keybindingToSymbols as ce, COMMAND_SOURCE_LABELS as me } from "./utils.js";
10
+ const ue = /* @__PURE__ */ new Set(["browser", "system", "ag-grid"]);
11
+ function pe(o) {
12
+ return !!o && ue.has(o);
12
13
  }
13
- const D = o.createContext({
14
+ const R = r.createContext({
14
15
  query: "",
15
16
  setQuery: () => {
16
17
  },
17
18
  selectedIndex: 0,
18
19
  setSelectedIndex: () => {
19
20
  },
20
- flatItems: [],
21
+ orderedCommands: [],
21
22
  onExecute: () => {
22
23
  }
23
24
  });
24
- function he({
25
- className: s,
25
+ function fe({
26
+ className: o,
26
27
  children: a,
27
28
  commands: n,
28
29
  placeholder: i = "Type a command or search...",
29
- emptyTitle: f = "No results found",
30
- emptyDescription: x = "Try a different search term",
31
- recentGroupLabel: l = "Recently Used",
32
- defaultGroupLabel: c = "Commands",
33
- navigateLabel: O = "Navigate",
34
- runLabel: A = "Run",
35
- closeLabel: F = "Close",
36
- configureShortcutsLabel: j = "Configure Shortcuts",
37
- onCommandExecute: q,
38
- onOpenChange: L
30
+ emptyTitle: m = "No results found",
31
+ emptyDescription: u = "Try a different search term",
32
+ recentGroupLabel: p = "Recently Used",
33
+ defaultGroupLabel: d = "Commands",
34
+ navigateLabel: I = "Navigate",
35
+ runLabel: z = "Run",
36
+ closeLabel: M = "Close",
37
+ configureShortcutsLabel: D = "Configure Shortcuts",
38
+ onCommandExecute: O,
39
+ onOpenChange: W
39
40
  }) {
40
- const { open: M, setOpen: ee, getPaletteCommands: te, getEffectiveKeybinding: ae, registry: k } = me(), [w, T] = o.useState(""), [v, N] = o.useState(0), $ = o.useRef(null), K = o.useRef(null), U = o.useMemo(() => n ?? te(), [n, M]), B = o.useMemo(() => {
41
- const t = fe(
42
- U,
43
- w,
44
- (r) => `${r.category ? r.category + ": " : ""}${r.label}${r.description ? " " + r.description : ""}`
41
+ const { open: E, setOpen: Y, getPaletteCommands: Z, getEffectiveKeybinding: G, registry: k } = ie(), [g, $] = r.useState(""), [N, h] = r.useState(0), A = r.useRef(null), F = r.useRef(null), j = r.useMemo(() => n ?? Z(), [n, E]), q = r.useMemo(() => {
42
+ const t = le(
43
+ j,
44
+ g,
45
+ (s) => `${s.category ? s.category + ": " : ""}${s.label}${s.description ? " " + s.description : ""}`
45
46
  );
46
- if (!w.trim()) {
47
- const r = k.getRecentCommandIds(), R = new Set(r), h = [], C = [];
48
- for (const g of t)
49
- R.has(g.item.id) ? h.push(g) : C.push(g);
50
- return h.sort((g, z) => r.indexOf(g.item.id) - r.indexOf(z.item.id)), [...h, ...C];
47
+ if (!g.trim()) {
48
+ const s = k.getRecentCommandIds(), y = new Set(s), f = [], C = [];
49
+ for (const x of t)
50
+ y.has(x.item.id) ? f.push(x) : C.push(x);
51
+ return f.sort((x, oe) => s.indexOf(x.item.id) - s.indexOf(oe.item.id)), [...f, ...C];
51
52
  }
52
53
  return t;
53
- }, [U, w, k]), p = o.useMemo(() => B.map((t) => t.item), [B]), ne = o.useMemo(() => {
54
- const t = /* @__PURE__ */ new Map(), r = new Set(k.getRecentCommandIds());
55
- if (w.trim())
56
- for (const u of p) {
57
- const y = u.category || c;
58
- t.has(y) || t.set(y, []), t.get(y).push(u);
59
- }
60
- else {
61
- const u = p.filter((b) => r.has(b.id));
62
- u.length > 0 && t.set(l, u);
63
- const y = p.filter((b) => !r.has(b.id));
64
- for (const b of y) {
65
- const P = b.category || c;
66
- t.has(P) || t.set(P, []), t.get(P).push(b);
67
- }
68
- }
69
- const R = { modal: 4, page: 3, module: 2, global: 1 }, h = { user: 2, "ag-grid": 1, browser: 0, system: 0 }, C = /* @__PURE__ */ new Map();
70
- for (const [u, y] of t.entries()) {
71
- let b = -1;
72
- for (const P of y) {
73
- const ce = R[P.scope] ?? 1, de = h[P.source ?? "user"] ?? 0;
74
- b = Math.max(b, ce * 10 + de);
75
- }
76
- C.set(u, b);
77
- }
78
- const g = /* @__PURE__ */ new Map(), z = t.get(l);
79
- z && g.set(l, z);
80
- const ie = Array.from(t.entries()).filter(([u]) => u !== l).sort(([u], [y]) => (C.get(y) ?? 0) - (C.get(u) ?? 0));
81
- for (const [u, y] of ie)
82
- g.set(u, y);
83
- return g;
84
- }, [p, w, k, l, c]);
85
- o.useEffect(() => {
86
- M && (T(""), N(0), requestAnimationFrame(() => {
87
- $.current?.focus();
54
+ }, [j, g, k]), T = r.useMemo(
55
+ () => q.map((t) => t.item),
56
+ [q]
57
+ ), ee = r.useMemo(
58
+ () => de({
59
+ filteredCommands: T,
60
+ emptyQuery: !g.trim(),
61
+ recentCommandIds: k.getRecentCommandIds(),
62
+ recentGroupLabel: p,
63
+ defaultGroupLabel: d
64
+ }),
65
+ [T, g, k, p, d]
66
+ ), { groups: te, orderedCommands: b } = ee, S = r.useRef({ ordered: b, index: N });
67
+ S.current = { ordered: b, index: N }, r.useEffect(() => {
68
+ E && ($(""), h(0), requestAnimationFrame(() => {
69
+ A.current?.focus();
88
70
  }));
89
- }, [M]);
90
- const Q = (t) => {
91
- ee(t), L?.(t);
92
- }, I = o.useCallback((t) => {
93
- t.handler(), k.addRecentCommand(t.id), q?.(t), Q(!1);
94
- }, [k, q]), se = o.useCallback((t) => {
95
- switch (t.key) {
96
- case "ArrowDown": {
97
- t.preventDefault(), N((r) => Math.min(r + 1, p.length - 1));
98
- break;
99
- }
100
- case "ArrowUp": {
101
- t.preventDefault(), N((r) => Math.max(r - 1, 0));
102
- break;
71
+ }, [E]);
72
+ const K = (t) => {
73
+ Y(t), W?.(t);
74
+ }, w = r.useCallback((t) => {
75
+ t.handler(), k.addRecentCommand(t.id), O?.(t), K(!1);
76
+ }, [k, O]), ae = r.useCallback(
77
+ (t) => {
78
+ const { ordered: s } = S.current, y = Math.max(s.length - 1, 0);
79
+ switch (t.key) {
80
+ case "ArrowDown": {
81
+ t.preventDefault(), h((f) => Math.min(f + 1, y));
82
+ break;
83
+ }
84
+ case "ArrowUp": {
85
+ t.preventDefault(), h((f) => Math.max(f - 1, 0));
86
+ break;
87
+ }
88
+ case "Enter": {
89
+ t.preventDefault();
90
+ const { ordered: f, index: C } = S.current, x = f[C];
91
+ x && w(x);
92
+ break;
93
+ }
94
+ case "Home": {
95
+ t.preventDefault(), h(0);
96
+ break;
97
+ }
98
+ case "End": {
99
+ t.preventDefault(), h(y);
100
+ break;
101
+ }
103
102
  }
104
- case "Enter": {
105
- t.preventDefault();
106
- const r = p[v];
107
- r && I(r);
108
- break;
109
- }
110
- case "Home": {
111
- t.preventDefault(), N(0);
112
- break;
113
- }
114
- case "End": {
115
- t.preventDefault(), N(Math.max(p.length - 1, 0));
116
- break;
117
- }
118
- }
119
- }, [p, v, I]);
120
- o.useEffect(() => {
121
- N(0);
122
- }, [w]), o.useEffect(() => {
123
- const t = K.current;
103
+ },
104
+ [w]
105
+ );
106
+ r.useEffect(() => {
107
+ h(0);
108
+ }, [g]), r.useEffect(() => {
109
+ const t = b.length;
110
+ h((s) => t === 0 ? 0 : Math.min(s, t - 1));
111
+ }, [b.length]), r.useLayoutEffect(() => {
112
+ const t = F.current;
124
113
  if (!t) return;
125
- const r = t.querySelector('[data-selected="true"]');
126
- r && r.scrollIntoView({ block: "nearest" });
127
- }, [v]);
128
- const re = o.useMemo(
114
+ const s = t.querySelector('[data-selected="true"]');
115
+ s && s.scrollIntoView({
116
+ block: "nearest",
117
+ inline: "nearest",
118
+ behavior: "auto"
119
+ });
120
+ }, [N]);
121
+ const ne = r.useMemo(
129
122
  () => ({
130
- query: w,
131
- setQuery: T,
132
- selectedIndex: v,
133
- setSelectedIndex: N,
134
- flatItems: p,
135
- onExecute: I,
123
+ query: g,
124
+ setQuery: $,
125
+ selectedIndex: N,
126
+ setSelectedIndex: h,
127
+ orderedCommands: b,
128
+ onExecute: w,
136
129
  placeholder: i,
137
- emptyTitle: f,
138
- emptyDescription: x,
139
- recentGroupLabel: l,
140
- defaultGroupLabel: c,
141
- navigateLabel: O,
142
- runLabel: A,
143
- closeLabel: F,
144
- configureShortcutsLabel: j
130
+ emptyTitle: m,
131
+ emptyDescription: u,
132
+ recentGroupLabel: p,
133
+ defaultGroupLabel: d,
134
+ navigateLabel: I,
135
+ runLabel: z,
136
+ closeLabel: M,
137
+ configureShortcutsLabel: D
145
138
  }),
146
139
  [
140
+ g,
141
+ N,
142
+ b,
147
143
  w,
148
- v,
144
+ i,
145
+ m,
146
+ u,
149
147
  p,
148
+ d,
150
149
  I,
151
- i,
152
- f,
153
- x,
154
- l,
155
- c,
156
- O,
157
- A,
158
- F,
159
- j
150
+ z,
151
+ M,
152
+ D
160
153
  ]
161
- ), oe = o.Children.count(a) > 0;
162
- return /* @__PURE__ */ e(S.Root, { open: M, onOpenChange: Q, children: /* @__PURE__ */ m(S.Portal, { children: [
154
+ ), re = r.Children.count(a) > 0;
155
+ return /* @__PURE__ */ e(P.Root, { open: E, onOpenChange: K, children: /* @__PURE__ */ c(P.Portal, { children: [
163
156
  /* @__PURE__ */ e(
164
- S.Overlay,
157
+ P.Overlay,
165
158
  {
166
- className: "fixed inset-0 z-50 bg-black/40 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0"
159
+ className: "fixed inset-0 z-50 bg-scrim data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0"
167
160
  }
168
161
  ),
169
- /* @__PURE__ */ m(
170
- S.Content,
162
+ /* @__PURE__ */ c(
163
+ P.Content,
171
164
  {
172
165
  "aria-describedby": void 0,
173
166
  "data-command-palette": !0,
174
167
  "data-component": "command-palette",
175
- onKeyDown: se,
176
- className: d(
168
+ onKeyDown: ae,
169
+ className: l(
177
170
  "fixed left-[50%] top-[20%] z-50 w-full max-w-[640px] -translate-x-1/2",
178
- "rounded-xl border border-[#d1d5db] bg-white shadow-2xl overflow-hidden",
171
+ "rounded-xl border border-stroke-hairline bg-canvas-elevated shadow-2xl overflow-hidden",
179
172
  "data-[state=open]:animate-in data-[state=closed]:animate-out",
180
173
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
181
174
  "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95",
182
175
  // Pin translate-x at -50% during animation so it stays centered (no horizontal slide)
183
176
  "data-[state=open]:slide-in-from-left-1/2 data-[state=closed]:slide-out-to-left-1/2",
184
177
  "duration-150",
185
- s
178
+ o
186
179
  ),
187
180
  style: { transformOrigin: "top center" },
188
181
  children: [
189
- /* @__PURE__ */ e(S.Title, { className: "sr-only", children: "Command Palette" }),
190
- /* @__PURE__ */ e(D.Provider, { value: re, children: oe ? a : /* @__PURE__ */ m(le, { children: [
182
+ /* @__PURE__ */ e(P.Title, { className: "sr-only", children: "Command Palette" }),
183
+ /* @__PURE__ */ e(R.Provider, { value: ne, children: re ? a : /* @__PURE__ */ c(se, { children: [
191
184
  /* @__PURE__ */ e(
192
- _,
185
+ U,
193
186
  {
194
- ref: $,
187
+ ref: A,
195
188
  placeholder: i
196
189
  }
197
190
  ),
198
- /* @__PURE__ */ e(H, { ref: K, children: p.length === 0 ? /* @__PURE__ */ e(Y, {}) : Array.from(ne.entries()).map(([t, r], R) => /* @__PURE__ */ m(o.Fragment, { children: [
199
- R > 0 && /* @__PURE__ */ e(Z, {}),
200
- /* @__PURE__ */ e(V, { heading: t, children: r.map((h) => {
201
- const C = p.indexOf(h), g = ae(h.id);
191
+ /* @__PURE__ */ e(_, { ref: F, children: b.length === 0 ? /* @__PURE__ */ e(V, {}) : te.map((t, s) => /* @__PURE__ */ c(r.Fragment, { children: [
192
+ s > 0 && /* @__PURE__ */ e(X, {}),
193
+ /* @__PURE__ */ e(B, { heading: t.heading, children: t.items.map((y, f) => {
194
+ const C = t.rowStart + f, x = G(y.id);
202
195
  return /* @__PURE__ */ e(
203
- X,
196
+ H,
204
197
  {
205
- command: h,
206
- isSelected: C === v,
207
- onSelect: () => I(h),
208
- onMouseEnter: () => N(C),
209
- keybinding: g
198
+ command: y,
199
+ isSelected: C === N,
200
+ onSelect: () => w(y),
201
+ onMouseEnter: () => h(C),
202
+ keybinding: x
210
203
  },
211
- h.id
204
+ y.id
212
205
  );
213
206
  }) })
214
- ] }, t)) }),
215
- /* @__PURE__ */ e(G, {})
207
+ ] }, `${t.heading}-${t.rowStart}`)) }),
208
+ /* @__PURE__ */ e(J, {})
216
209
  ] }) })
217
210
  ]
218
211
  }
219
212
  )
220
213
  ] }) });
221
214
  }
222
- he.displayName = "CommandPalette";
223
- const _ = o.forwardRef(
224
- ({ className: s, placeholder: a, onValueChange: n, ...i }, f) => {
225
- const { query: x, setQuery: l } = o.useContext(D);
226
- return /* @__PURE__ */ m(
215
+ fe.displayName = "CommandPalette";
216
+ const U = r.forwardRef(
217
+ ({ className: o, placeholder: a, onValueChange: n, ...i }, m) => {
218
+ const { query: u, setQuery: p } = r.useContext(R);
219
+ return /* @__PURE__ */ c(
227
220
  "div",
228
221
  {
229
- className: d(
230
- "flex items-center gap-3 border-b border-[#e5e7eb] px-4",
231
- s
222
+ className: l(
223
+ "flex items-center gap-3 border-b border-stroke-hairline px-4",
224
+ o
232
225
  ),
233
226
  "data-command-palette-input": !0,
234
227
  children: [
235
- /* @__PURE__ */ e(W, { className: "h-4 w-4 shrink-0 text-[#9ca3af]" }),
228
+ /* @__PURE__ */ e(Q, { className: "h-4 w-4 shrink-0 text-content-muted" }),
236
229
  /* @__PURE__ */ e(
237
230
  "input",
238
231
  {
239
- ref: f,
240
- value: x,
241
- onChange: (c) => {
242
- l(c.target.value), n?.(c.target.value);
232
+ ref: m,
233
+ value: u,
234
+ onChange: (d) => {
235
+ p(d.target.value), n?.(d.target.value);
243
236
  },
244
237
  placeholder: a,
245
238
  autoComplete: "off",
246
239
  autoCorrect: "off",
247
240
  spellCheck: !1,
248
- className: d(
241
+ className: l(
249
242
  "flex h-12 w-full bg-transparent py-3 text-sm font-medium outline-none",
250
- "placeholder:text-[#9ca3af]"
243
+ "placeholder:text-content-muted"
251
244
  ),
252
245
  ...i
253
246
  }
254
247
  ),
255
248
  /* @__PURE__ */ e(
256
- E,
249
+ v,
257
250
  {
258
251
  keybinding: { key: "Escape" },
259
252
  size: "sm",
@@ -266,198 +259,195 @@ const _ = o.forwardRef(
266
259
  );
267
260
  }
268
261
  );
269
- _.displayName = "CommandPaletteInput";
270
- const H = o.forwardRef(({ className: s, children: a, ...n }, i) => /* @__PURE__ */ e(
262
+ U.displayName = "CommandPaletteInput";
263
+ const _ = r.forwardRef(({ className: o, children: a, ...n }, i) => /* @__PURE__ */ e(
271
264
  "div",
272
265
  {
273
266
  ref: i,
274
267
  role: "listbox",
275
268
  "data-command-palette-list": !0,
276
- className: d(
269
+ className: l(
277
270
  "max-h-[360px] overflow-y-auto overscroll-contain py-1",
278
- s
271
+ o
279
272
  ),
280
273
  ...n,
281
274
  children: a
282
275
  }
283
276
  ));
284
- H.displayName = "CommandPaletteList";
285
- const V = o.forwardRef(
286
- ({ className: s, heading: a, children: n, ...i }, f) => /* @__PURE__ */ m(
277
+ _.displayName = "CommandPaletteList";
278
+ const B = r.forwardRef(
279
+ ({ className: o, heading: a, children: n, ...i }, m) => /* @__PURE__ */ c(
287
280
  "div",
288
281
  {
289
- ref: f,
282
+ ref: m,
290
283
  role: "group",
291
284
  "aria-label": a,
292
285
  "data-command-palette-group": !0,
293
- className: d("py-1", s),
286
+ className: l("py-1", o),
294
287
  ...i,
295
288
  children: [
296
- a && /* @__PURE__ */ e("div", { className: "px-4 py-1.5 text-[10px] font-semibold uppercase tracking-wider text-[#9ca3af]", children: a }),
289
+ a && /* @__PURE__ */ e("div", { className: "px-4 py-1.5 text-[10px] font-semibold uppercase tracking-wider text-content-muted", children: a }),
297
290
  n
298
291
  ]
299
292
  }
300
293
  )
301
294
  );
302
- V.displayName = "CommandPaletteGroup";
303
- const ge = {
304
- browser: "Browser",
305
- "ag-grid": "AG Grid",
306
- system: "System"
307
- };
308
- function ye({ source: s, isSelected: a }) {
309
- if (!s || s === "user") return null;
310
- const n = ge[s];
295
+ B.displayName = "CommandPaletteGroup";
296
+ function xe({ source: o, isSelected: a }) {
297
+ if (!o || o === "user") return null;
298
+ const n = me[o];
311
299
  return n ? /* @__PURE__ */ e(
312
300
  "span",
313
301
  {
314
- className: d(
302
+ className: l(
315
303
  "shrink-0 rounded px-1.5 py-px text-[9px] font-medium leading-tight tracking-wide",
316
- a ? "text-white/50" : "text-[#9ca3af] border border-[#e5e7eb]"
304
+ a ? "text-brand-foreground/50" : "text-content-muted border border-stroke-hairline"
317
305
  ),
318
306
  children: n
319
307
  }
320
308
  ) : null;
321
309
  }
322
- const X = o.forwardRef(
323
- ({ className: s, command: a, isSelected: n, onSelect: i, keybinding: f, ...x }, l) => {
324
- const c = xe(a.source);
325
- return /* @__PURE__ */ m(
310
+ const H = r.forwardRef(
311
+ ({ className: o, command: a, isSelected: n, onSelect: i, keybinding: m, ...u }, p) => {
312
+ const d = pe(a.source);
313
+ return /* @__PURE__ */ c(
326
314
  "div",
327
315
  {
328
- ref: l,
316
+ ref: p,
329
317
  role: "option",
330
318
  "aria-selected": n,
331
319
  "data-selected": n,
332
320
  "data-command-palette-item": !0,
333
321
  "data-command-id": a.id,
334
322
  onClick: i,
335
- className: d(
323
+ className: l(
336
324
  "flex items-center gap-3 cursor-pointer px-4 py-2 text-sm",
337
- "transition-colors duration-75",
338
- n ? "bg-[#4259ee] text-white" : c ? "text-[#9ca3af] hover:bg-[#f9fafb]" : "text-[#374151] hover:bg-[#f3f4f6]",
339
- s
325
+ // Smooth selection shift; scroll-margin keeps row clear of list edges when scrolling into view
326
+ "transition-[color,background-color] duration-150 ease-out [scroll-margin-block:6px]",
327
+ n ? "bg-brand text-brand-foreground" : d ? "text-content-muted hover:bg-canvas-muted" : "text-content-charcoal hover:bg-canvas-muted",
328
+ o
340
329
  ),
341
- ...x,
330
+ ...u,
342
331
  children: [
343
- a.icon && /* @__PURE__ */ e("span", { className: d(
332
+ a.icon && /* @__PURE__ */ e("span", { className: l(
344
333
  "flex h-4 w-4 shrink-0 items-center justify-center",
345
- n ? "text-white" : c ? "text-[#d1d5db]" : "text-[#6b7280]"
334
+ n ? "text-brand-foreground" : d ? "text-stroke-hairline" : "text-content-muted"
346
335
  ), children: a.icon }),
347
- /* @__PURE__ */ m("div", { className: "flex flex-1 flex-col min-w-0", children: [
348
- /* @__PURE__ */ e("span", { className: d(
336
+ /* @__PURE__ */ c("div", { className: "flex flex-1 flex-col min-w-0", children: [
337
+ /* @__PURE__ */ e("span", { className: l(
349
338
  "truncate",
350
- c && !n ? "font-normal" : "font-medium"
339
+ d && !n ? "font-normal" : "font-medium"
351
340
  ), children: a.label }),
352
- a.description && /* @__PURE__ */ e("span", { className: d(
341
+ a.description && /* @__PURE__ */ e("span", { className: l(
353
342
  "truncate text-xs",
354
- n ? "text-white/70" : c ? "text-[#d1d5db]" : "text-[#9ca3af]"
343
+ n ? "text-brand-foreground/70" : d ? "text-stroke-hairline" : "text-content-muted"
355
344
  ), children: a.description })
356
345
  ] }),
357
- /* @__PURE__ */ e(ye, { source: a.source, isSelected: n }),
358
- f && /* @__PURE__ */ e(J, { keybinding: f, isSelected: n, external: c })
346
+ /* @__PURE__ */ e(xe, { source: a.source, isSelected: n }),
347
+ m && /* @__PURE__ */ e(L, { keybinding: m, isSelected: n, external: d })
359
348
  ]
360
349
  }
361
350
  );
362
351
  }
363
352
  );
364
- X.displayName = "CommandPaletteItem";
365
- function J({ keybinding: s, isSelected: a, external: n, className: i, ...f }) {
366
- const x = ue(s);
353
+ H.displayName = "CommandPaletteItem";
354
+ function L({ keybinding: o, isSelected: a, external: n, className: i, ...m }) {
355
+ const u = ce(o);
367
356
  return /* @__PURE__ */ e(
368
357
  "span",
369
358
  {
370
- className: d("ml-auto flex items-center gap-0.5 shrink-0", i),
359
+ className: l("ml-auto flex items-center gap-0.5 shrink-0", i),
371
360
  "data-command-palette-shortcut": !0,
372
- ...f,
373
- children: x.map((l, c) => /* @__PURE__ */ e(
361
+ ...m,
362
+ children: u.map((p, d) => /* @__PURE__ */ e(
374
363
  "kbd",
375
364
  {
376
- className: d(
365
+ className: l(
377
366
  "inline-flex min-w-[20px] items-center justify-center rounded px-1 h-[20px] text-[10px] font-mono leading-none",
378
- a ? "bg-white/20 text-white border border-white/30" : n ? "bg-[#f9fafb] text-[#d1d5db] border border-[#e5e7eb]" : "bg-[#f4f5f7] text-[#6b7280] border border-[#d1d5db]"
367
+ "transition-[color,background-color,border-color] duration-150 ease-out",
368
+ a ? "bg-canvas-elevated/20 text-brand-foreground border border-brand-foreground/30" : n ? "bg-canvas-muted text-stroke-hairline border border-stroke-hairline" : "bg-canvas-muted text-content-muted border border-stroke-hairline"
379
369
  ),
380
- children: l
370
+ children: p
381
371
  },
382
- `${l}-${c}`
372
+ `${p}-${d}`
383
373
  ))
384
374
  }
385
375
  );
386
376
  }
387
- J.displayName = "CommandPaletteShortcut";
388
- function Y({ className: s, ...a }) {
389
- const { emptyTitle: n, emptyDescription: i } = o.useContext(D);
390
- return /* @__PURE__ */ m(
377
+ L.displayName = "CommandPaletteShortcut";
378
+ function V({ className: o, ...a }) {
379
+ const { emptyTitle: n, emptyDescription: i } = r.useContext(R);
380
+ return /* @__PURE__ */ c(
391
381
  "div",
392
382
  {
393
383
  "data-command-palette-empty": !0,
394
- className: d(
395
- "flex flex-col items-center justify-center py-12 text-center text-sm text-[#9ca3af]",
396
- s
384
+ className: l(
385
+ "flex flex-col items-center justify-center py-12 text-center text-sm text-content-muted",
386
+ o
397
387
  ),
398
388
  ...a,
399
389
  children: [
400
- /* @__PURE__ */ e(W, { className: "h-8 w-8 mb-3 text-[#d1d5db]" }),
390
+ /* @__PURE__ */ e(Q, { className: "h-8 w-8 mb-3 text-stroke-hairline" }),
401
391
  /* @__PURE__ */ e("p", { className: "font-medium", children: n }),
402
392
  /* @__PURE__ */ e("p", { className: "text-xs mt-1", children: i })
403
393
  ]
404
394
  }
405
395
  );
406
396
  }
407
- Y.displayName = "CommandPaletteEmpty";
408
- function Z({ className: s, ...a }) {
397
+ V.displayName = "CommandPaletteEmpty";
398
+ function X({ className: o, ...a }) {
409
399
  return /* @__PURE__ */ e(
410
400
  "div",
411
401
  {
412
402
  "data-command-palette-separator": !0,
413
- className: d("h-px bg-[#e5e7eb] mx-2", s),
403
+ className: l("h-px bg-stroke-hairline mx-2", o),
414
404
  ...a
415
405
  }
416
406
  );
417
407
  }
418
- Z.displayName = "CommandPaletteSeparator";
419
- function G({ className: s, ...a }) {
420
- const { navigateLabel: n, runLabel: i, closeLabel: f, configureShortcutsLabel: x } = o.useContext(D);
421
- return /* @__PURE__ */ m(
408
+ X.displayName = "CommandPaletteSeparator";
409
+ function J({ className: o, ...a }) {
410
+ const { navigateLabel: n, runLabel: i, closeLabel: m, configureShortcutsLabel: u } = r.useContext(R);
411
+ return /* @__PURE__ */ c(
422
412
  "div",
423
413
  {
424
414
  "data-command-palette-footer": !0,
425
- className: d(
426
- "flex items-center gap-4 border-t border-[#e5e7eb] px-4 py-2 text-[11px] text-[#9ca3af]",
427
- s
415
+ className: l(
416
+ "flex items-center gap-4 border-t border-stroke-hairline px-4 py-2 text-[11px] text-content-muted",
417
+ o
428
418
  ),
429
419
  ...a,
430
420
  children: [
431
- /* @__PURE__ */ m("span", { className: "inline-flex items-center gap-1", children: [
432
- /* @__PURE__ */ e(E, { keys: ["↑"], size: "sm", variant: "muted" }),
433
- /* @__PURE__ */ e(E, { keys: ["↓"], size: "sm", variant: "muted" }),
421
+ /* @__PURE__ */ c("span", { className: "inline-flex items-center gap-1", children: [
422
+ /* @__PURE__ */ e(v, { keys: ["↑"], size: "sm", variant: "muted" }),
423
+ /* @__PURE__ */ e(v, { keys: ["↓"], size: "sm", variant: "muted" }),
434
424
  /* @__PURE__ */ e("span", { children: n })
435
425
  ] }),
436
- /* @__PURE__ */ m("span", { className: "inline-flex items-center gap-1", children: [
437
- /* @__PURE__ */ e(E, { keys: ["↵"], size: "sm", variant: "muted" }),
426
+ /* @__PURE__ */ c("span", { className: "inline-flex items-center gap-1", children: [
427
+ /* @__PURE__ */ e(v, { keys: ["↵"], size: "sm", variant: "muted" }),
438
428
  /* @__PURE__ */ e("span", { children: i })
439
429
  ] }),
440
- /* @__PURE__ */ m("span", { className: "inline-flex items-center gap-1", children: [
441
- /* @__PURE__ */ e(E, { keys: ["Escape"], size: "sm", variant: "muted" }),
442
- /* @__PURE__ */ e("span", { children: f })
430
+ /* @__PURE__ */ c("span", { className: "inline-flex items-center gap-1", children: [
431
+ /* @__PURE__ */ e(v, { keys: ["Escape"], size: "sm", variant: "muted" }),
432
+ /* @__PURE__ */ e("span", { children: m })
443
433
  ] }),
444
- x && /* @__PURE__ */ m("span", { className: "ml-auto inline-flex items-center gap-1", children: [
445
- /* @__PURE__ */ e(E, { keybinding: { key: "k", alt: !0 }, size: "sm", variant: "muted" }),
446
- /* @__PURE__ */ e("span", { children: x })
434
+ u && /* @__PURE__ */ c("span", { className: "ml-auto inline-flex items-center gap-1", children: [
435
+ /* @__PURE__ */ e(v, { keybinding: { key: "k", alt: !0 }, size: "sm", variant: "muted" }),
436
+ /* @__PURE__ */ e("span", { children: u })
447
437
  ] })
448
438
  ]
449
439
  }
450
440
  );
451
441
  }
452
- G.displayName = "CommandPaletteFooter";
442
+ J.displayName = "CommandPaletteFooter";
453
443
  export {
454
- he as CommandPalette,
455
- Y as CommandPaletteEmpty,
456
- G as CommandPaletteFooter,
457
- V as CommandPaletteGroup,
458
- _ as CommandPaletteInput,
459
- X as CommandPaletteItem,
460
- H as CommandPaletteList,
461
- Z as CommandPaletteSeparator,
462
- J as CommandPaletteShortcut
444
+ fe as CommandPalette,
445
+ V as CommandPaletteEmpty,
446
+ J as CommandPaletteFooter,
447
+ B as CommandPaletteGroup,
448
+ U as CommandPaletteInput,
449
+ H as CommandPaletteItem,
450
+ _ as CommandPaletteList,
451
+ X as CommandPaletteSeparator,
452
+ L as CommandPaletteShortcut
463
453
  };