impact-nova 2.1.0-alpha.9 → 2.2.1

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 (75) hide show
  1. package/README.md +6 -0
  2. package/dist/components/data/ag-grid-react/cell-renderers/editors/split-cell-editor.js +73 -94
  3. package/dist/components/data/ag-grid-react/cell-renderers/editors/split-cell-focus.d.ts +53 -0
  4. package/dist/components/data/ag-grid-react/cell-renderers/editors/split-cell-focus.js +98 -0
  5. package/dist/components/data/ag-grid-react/headers/column-menu/column-settings-menu.js +15 -13
  6. package/dist/components/data/ag-grid-react/headers/custom-header.js +56 -58
  7. package/dist/components/data/ag-grid-react/headers/custom-inner-header-group.d.ts +12 -0
  8. package/dist/components/data/ag-grid-react/headers/custom-inner-header-group.js +31 -0
  9. package/dist/components/data/ag-grid-react/headers/header-search-active-state.d.ts +10 -0
  10. package/dist/components/data/ag-grid-react/headers/header-search-active-state.js +38 -0
  11. package/dist/components/data/ag-grid-react/index.js +166 -163
  12. package/dist/components/data/ag-grid-react/notify-column-indicator-sync.d.ts +3 -4
  13. package/dist/components/data/ag-grid-react/theme.js +0 -2
  14. package/dist/components/data/data-table/data-table-column-list.js +1 -1
  15. package/dist/components/data/data-table/data-table-saved-views.js +1 -1
  16. package/dist/components/data/expandable-list-item/expandable-list-item-attributes.js +7 -6
  17. package/dist/components/data/nested-list/components/SortableItem.d.ts +3 -1
  18. package/dist/components/data/nested-list/components/SortableItem.js +111 -109
  19. package/dist/components/data-display/calendar/calendar-footer-emphasis.d.ts +28 -0
  20. package/dist/components/data-display/calendar/calendar-footer-emphasis.js +8 -0
  21. package/dist/components/data-display/calendar/calendar-footer.d.ts +4 -1
  22. package/dist/components/data-display/calendar/calendar-footer.js +60 -38
  23. package/dist/components/data-display/calendar/calendar.js +86 -82
  24. package/dist/components/data-display/calendar/calendar.types.d.ts +2 -0
  25. package/dist/components/data-display/calendar/use-calendar-state.d.ts +3 -0
  26. package/dist/components/feedback/tooltip/tab-tooltip-render.js +3 -2
  27. package/dist/components/flows/filter-strip/filter-strip.js +36 -29
  28. package/dist/components/flows/filter-strip/filter-summary.js +2 -2
  29. package/dist/components/forms/date-picker/date-input-behavior.d.ts +118 -0
  30. package/dist/components/forms/date-picker/date-input-behavior.js +164 -0
  31. package/dist/components/forms/date-picker/date-picker.js +202 -138
  32. package/dist/components/forms/date-picker/date-range-picker.js +302 -215
  33. package/dist/components/forms/date-picker/month-picker.js +160 -119
  34. package/dist/components/forms/date-picker/month-range-picker.js +302 -245
  35. package/dist/components/forms/date-picker/multi-date-picker.js +94 -80
  36. package/dist/components/forms/date-picker/multi-month-picker.js +97 -83
  37. package/dist/components/forms/date-picker/multi-week-picker.js +107 -93
  38. package/dist/components/forms/date-picker/week-picker.js +230 -140
  39. package/dist/components/forms/date-picker/week-range-picker.js +332 -226
  40. package/dist/components/forms/file-upload/file-upload.js +312 -174
  41. package/dist/components/forms/file-upload/file-upload.types.d.ts +17 -2
  42. package/dist/components/layout/dynamic-layout/dynamic-layout.variants.d.ts +1 -1
  43. package/dist/components/layout/header/header.js +45 -38
  44. package/dist/components/layout/horizontal-scroller/index.d.ts +1 -0
  45. package/dist/components/layout/horizontal-scroller/index.js +3 -2
  46. package/dist/components/ui/local-raster-icons/assets/excel-error-icon.webp.js +4 -0
  47. package/dist/components/ui/local-raster-icons/assets/file-upload-error.webp.js +4 -0
  48. package/dist/components/ui/local-raster-icons/rasterIcons.d.ts +2 -0
  49. package/dist/components/ui/local-raster-icons/rasterIcons.js +32 -22
  50. package/dist/components/ui/show.d.ts +10 -0
  51. package/dist/components/ui/show.js +7 -0
  52. package/dist/components/ui/show.types.d.ts +5 -0
  53. package/dist/i18n/defaultMessages.d.ts +17 -0
  54. package/dist/i18n/defaultMessages.js +29 -17
  55. package/dist/i18n/index.d.ts +1 -1
  56. package/dist/i18n/locales/de.js +12 -0
  57. package/dist/i18n/locales/es.js +12 -0
  58. package/dist/i18n/locales/hi.js +12 -0
  59. package/dist/i18n/locales/kn.js +12 -0
  60. package/dist/impact-nova-base.scss +6 -2
  61. package/dist/impact-nova-components.css +141 -16
  62. package/dist/impact-nova-tokens.scss +12 -0
  63. package/dist/impact-nova.css +1 -1
  64. package/dist/index.d.ts +2 -0
  65. package/dist/index.js +273 -271
  66. package/dist/lib/utils.js +40 -24
  67. package/dist/llms/rules/ag-grid.js +1 -1
  68. package/dist/llms/rules/installation.js +1 -1
  69. package/dist/llms/rules/requirements.js +1 -1
  70. package/dist/tailwind.config.js +36 -4
  71. package/dist/theme/tailwind-colors.js +3 -1
  72. package/package.json +15 -6
  73. package/tailwind.config.d.ts +3 -0
  74. package/dist/components/data/ag-grid-react/headers/custom-header-group.d.ts +0 -10
  75. package/dist/components/data/ag-grid-react/headers/custom-header-group.js +0 -58
package/README.md CHANGED
@@ -14,6 +14,12 @@
14
14
  [![Internationalization](https://img.shields.io/badge/i18n-Built--in-059669.svg?style=flat)](#internationalization-i18n)
15
15
  [![Documentation](https://img.shields.io/badge/Documentation-online-FF4785?style=flat&logo=storybook&logoColor=white)](https://impact-nova.iaproducts.ai/)
16
16
  [![npm impact-nova-mcp](https://img.shields.io/npm/v/impact-nova-mcp?label=impact-nova-mcp&logo=npm)](https://www.npmjs.com/package/impact-nova-mcp)
17
+ [![Vitest](https://img.shields.io/badge/Vitest-4.0-6E9F18.svg?style=flat&logo=vitest&logoColor=white)](https://vitest.dev/)
18
+ [![Testing Library](https://img.shields.io/badge/Testing%20Library-16.3-E33332.svg?style=flat&logo=testing-library&logoColor=white)](https://testing-library.com/docs/react-testing-library/intro/)
19
+ [![Playwright](https://img.shields.io/badge/Playwright-1.58-2EAD33.svg?style=flat&logo=playwright&logoColor=white)](https://playwright.dev/)
20
+ [![Storybook Tests](https://img.shields.io/badge/Storybook%20Tests-10.2-FF4785.svg?style=flat&logo=storybook&logoColor=white)](https://storybook.js.org/docs/writing-tests)
21
+ [![a11y](https://img.shields.io/badge/a11y-axe%20CI-0E7C86.svg?style=flat)](https://storybook.js.org/docs/writing-tests/accessibility-testing)
22
+ [![Coverage](https://img.shields.io/badge/Coverage-ratchet-4C1.svg?style=flat)](https://impact-nova.iaproducts.ai/?path=/docs/brand-identity-testing-quality--documentation)
17
23
 
18
24
  </div>
19
25
 
@@ -1,127 +1,106 @@
1
- import { jsx as I } from "react/jsx-runtime";
2
- import { forwardRef as $, useMemo as x, useEffect as R, useImperativeHandle as B, useState as G, useCallback as H } from "react";
3
- import { resolveCellEditable as D, resolveValueFormatter as q, applyValueFormatter as z } from "../cell-renderer-utils.js";
4
- function Y() {
1
+ import { jsx as C } from "react/jsx-runtime";
2
+ import { forwardRef as z, useState as F, useImperativeHandle as B, useEffect as H, useMemo as L, useCallback as M } from "react";
3
+ import { resolveValueFormatter as q, applyValueFormatter as J, resolveCellEditable as I } from "../cell-renderer-utils.js";
4
+ import { initializeSplitCellFocusSession as Q } from "./split-cell-focus.js";
5
+ function X() {
5
6
  return document;
6
7
  }
7
- function A(g, _, l, m, r) {
8
- const s = l, f = typeof m?.editable == "boolean" ? m.editable : void 0, C = g[_], c = C?.field?.split(".")?.pop(), n = c ? r?.[c] : void 0;
9
- return D(f, C?.editable, s, n);
8
+ function Y(p, w, a, u, r) {
9
+ const n = a, s = typeof u?.editable == "boolean" ? u.editable : void 0, f = p[w], i = f?.field?.split(".")?.pop(), l = i ? r?.[i] : void 0;
10
+ return I(s, f?.editable, n, l);
10
11
  }
11
- const J = $((g, _) => {
12
- const { splits: l, commonParams: m, data: r, node: s, api: f, column: C, context: c, value: n, colDef: i, valueFormatter: U } = g, S = x(() => document.__splitCellLastClickY == null, []), M = x(() => document.__splitCellLastWasEditable !== !1, []), v = x(() => {
13
- let e = 0, t = !0, a = !1, o;
14
- try {
15
- const d = g.eGridCell;
16
- if (!d || !l?.length)
17
- return { index: e, wasEditable: t, clearClickY: a, activeIndex: o };
18
- if (S) {
19
- const u = Y().__splitCellLastActiveIndex;
20
- if (u != null && u >= 0 && u < l.length)
21
- return e = u, t = A(l, u, r, i, n), { index: e, wasEditable: t, clearClickY: a, activeIndex: o };
22
- for (let p = 0; p < l.length; p++)
23
- if (A(l, p, r, i, n))
24
- return e = p, t = !0, { index: e, wasEditable: t, clearClickY: a, activeIndex: o };
25
- return { index: 0, wasEditable: !1, clearClickY: a, activeIndex: o };
26
- }
27
- const h = Y().__splitCellLastClickY;
28
- if (h == null)
29
- return { index: e, wasEditable: t, clearClickY: a, activeIndex: o };
30
- const w = d.getBoundingClientRect(), K = h - w.top, E = w.height / l.length, F = Math.floor(K / E);
31
- return e = Math.max(0, Math.min(F, l.length - 1)), a = !0, o = e, t = A(l, e, r, i, n), { index: e, wasEditable: t, clearClickY: a, activeIndex: o };
32
- } catch {
33
- return { index: 0, wasEditable: !0, clearClickY: !1, activeIndex: void 0 };
34
- }
35
- }, [l, g, S, r, i, n]);
36
- R(() => {
37
- const e = Y();
38
- v.clearClickY && (e.__splitCellLastClickY = void 0), v.activeIndex != null && (e.__splitCellLastActiveIndex = v.activeIndex), e.__splitCellLastWasEditable = v.wasEditable;
39
- }, [v]);
40
- const k = v.index, y = x(() => {
41
- if (!l?.length) return !1;
42
- const e = l[k];
43
- if (!e) return !1;
44
- const t = r, a = typeof i?.editable == "boolean" ? i.editable : void 0, o = e.field?.split(".")?.pop(), d = o ? n?.[o] : void 0;
45
- return !D(a, e.editable, t, d);
46
- }, [l, k, r, i, n]) || S && !M;
47
- B(_, () => ({
12
+ const Z = z((p, w) => {
13
+ const { splits: a, commonParams: u, data: r, node: n, api: s, column: f, context: i, value: l, colDef: o, valueFormatter: U, eventKey: D } = p, [N] = F(() => {
14
+ const e = p.eGridCell;
15
+ return Q({
16
+ cellElement: e,
17
+ splits: a,
18
+ eventKey: D,
19
+ data: r,
20
+ colDef: o,
21
+ value: l,
22
+ documentState: X(),
23
+ resolveSplitEditable: Y
24
+ });
25
+ }), { targetSplitIndex: k, isKeyboardEntry: A, lastWasEditable: P, targetIsNonEditable: R } = N, v = R || A && !P;
26
+ B(w, () => ({
48
27
  getValue() {
49
- const e = i?.field;
50
- return e && s?.data ? s.data[e] : n;
28
+ const e = o?.field;
29
+ return e && n?.data ? n.data[e] : l;
51
30
  },
52
31
  isCancelBeforeStart() {
53
- return y;
32
+ return v;
54
33
  },
55
34
  isCancelAfterEnd() {
56
35
  return !1;
57
36
  }
58
- }), [i, s, n, y]), R(() => {
59
- y && setTimeout(() => {
60
- f?.stopEditing();
37
+ }), [o, n, l, v]), H(() => {
38
+ v && setTimeout(() => {
39
+ s?.stopEditing();
61
40
  }, 0);
62
- }, [y, f]);
63
- const j = x(() => l?.map((e) => {
64
- const t = e?.field?.split(".")?.pop() ?? "", a = n?.[t]?.value;
65
- return { valueKey: t, field: e.field, newValue: a };
66
- }) ?? [], [l, n]), [V, O] = G(j), P = H((e) => {
67
- const t = V.find((b) => b.field === e);
68
- if (!t || !i.field) return;
69
- const a = n?.[t.valueKey]?.value;
70
- if (String(t.newValue ?? "") === String(a ?? ""))
41
+ }, [v, s]);
42
+ const j = L(() => a?.map((e) => {
43
+ const t = e?.field?.split(".")?.pop() ?? "", d = l?.[t]?.value;
44
+ return { valueKey: t, field: e.field, newValue: d };
45
+ }) ?? [], [a, l]), [g, O] = F(j), $ = M((e) => {
46
+ const t = g.find((b) => b.field === e);
47
+ if (!t || !o.field) return;
48
+ const d = l?.[t.valueKey]?.value;
49
+ if (String(t.newValue ?? "") === String(d ?? ""))
71
50
  return;
72
51
  document.__splitCellLastWasEditable = !0;
73
- const o = {
74
- api: f,
75
- colDef: i,
76
- column: C,
77
- context: c,
52
+ const c = {
53
+ api: s,
54
+ colDef: o,
55
+ column: f,
56
+ context: i,
78
57
  data: r,
79
- field: i.field,
80
- node: s,
81
- rowIndex: s?.rowIndex ?? null,
82
- rowPinned: s?.rowPinned ?? void 0,
58
+ field: o.field,
59
+ node: n,
60
+ rowIndex: n?.rowIndex ?? null,
61
+ rowPinned: n?.rowPinned ?? void 0,
83
62
  source: "edit",
84
63
  type: "cellValueChanged",
85
64
  currentCellUpdate: t,
86
65
  newValue: { [t.valueKey]: { value: t.newValue } },
87
- oldValue: { [t.valueKey]: { value: n?.[t.valueKey]?.value } },
66
+ oldValue: { [t.valueKey]: { value: l?.[t.valueKey]?.value } },
88
67
  value: { [t.valueKey]: { value: t.newValue } }
89
- }, d = n?.[t.valueKey] ?? {};
90
- s.setDataValue(i.field, { ...n, [t.valueKey]: { ...d, value: t.newValue } }), c?.onCellUpdate?.(o);
91
- }, [V, f, i, C, c, r, s, n]), W = (e) => {
68
+ }, m = l?.[t.valueKey] ?? {};
69
+ n.setDataValue(o.field, { ...l, [t.valueKey]: { ...m, value: t.newValue } }), i?.onCellUpdate?.(c);
70
+ }, [g, s, o, f, i, r, n, l]), G = (e) => {
92
71
  if (typeof e == "string") {
93
- const t = f?.getGridOption("components");
94
- return c?.frameworkComponents?.[e] || t?.[e];
72
+ const t = s?.getGridOption("components");
73
+ return i?.frameworkComponents?.[e] || t?.[e];
95
74
  }
96
75
  return e;
97
76
  };
98
- return /* @__PURE__ */ I("div", { style: { display: "grid", gridTemplateRows: `repeat(${l?.length}, 1fr)`, height: "100%", width: "100%" }, children: l?.map((e, t) => {
99
- const a = e?.field?.split(".")?.pop();
100
- if (!a) return null;
101
- const o = n?.[a], d = o?.value, b = r, h = q(o, b, e?.valueFormatter, U ?? null), w = h ? z(h, d) : d?.toString(), K = typeof i?.editable == "boolean" ? i.editable : void 0, E = D(K, e.editable, b, o), F = t === k && E, L = E ? m?.cellEditor ?? m?.cellRenderer : m?.cellRenderer ?? void 0, u = L ? W(L) : void 0;
102
- return /* @__PURE__ */ I("div", { className: "flex items-center max-h-full overflow-hidden", children: u ? /* @__PURE__ */ I(
103
- u,
77
+ return /* @__PURE__ */ C("div", { style: { display: "grid", gridTemplateRows: `repeat(${a?.length}, 1fr)`, height: "100%", width: "100%" }, children: a?.map((e, t) => {
78
+ const d = e?.field?.split(".")?.pop();
79
+ if (!d) return null;
80
+ const c = l?.[d], m = c?.value, b = r, V = q(c, b, e?.valueFormatter, U ?? null), h = V ? J(V, m) : m?.toString(), T = typeof o?.editable == "boolean" ? o.editable : void 0, y = I(T, e.editable, b, c), W = t === k && y, E = y ? u?.cellEditor ?? u?.cellRenderer : u?.cellRenderer ?? void 0, S = E ? G(E) : void 0;
81
+ return /* @__PURE__ */ C("div", { className: "flex items-center max-h-full overflow-hidden", children: S ? /* @__PURE__ */ C(
82
+ S,
104
83
  {
105
- context: c,
84
+ context: i,
106
85
  data: r,
107
- value: o,
108
- onValueChange: (p) => {
109
- const N = V.find((T) => T.field === e.field);
110
- N ? N.newValue = p : O([...V, { valueKey: a, field: e.field, newValue: p }]);
86
+ value: c,
87
+ onValueChange: (x) => {
88
+ const K = g.find((_) => _.field === e.field);
89
+ K ? K.newValue = x : O([...g, { valueKey: d, field: e.field, newValue: x }]);
111
90
  },
112
- valueFormatted: w ?? void 0,
113
- colDef: { ...e, editable: E },
91
+ valueFormatted: h ?? void 0,
92
+ colDef: { ...e, editable: y },
114
93
  stopEditing: () => {
115
- P(e.field);
94
+ $(e.field);
116
95
  },
117
- node: s,
118
- suppressAutoFocus: !F,
119
- className: t !== l.length - 1 ? "border-b border-stroke-hairline" : ""
96
+ node: n,
97
+ suppressAutoFocus: !W,
98
+ className: t !== a.length - 1 ? "border-b border-stroke-hairline" : ""
120
99
  }
121
- ) : /* @__PURE__ */ I("div", { className: "w-full h-full flex items-center ag-cell-inner-padding overflow-hidden text-ellipsis whitespace-nowrap", children: String(w ?? d ?? "") }) }, `${e.field}-${t}`);
100
+ ) : /* @__PURE__ */ C("div", { className: "w-full h-full flex items-center ag-cell-inner-padding overflow-hidden text-ellipsis whitespace-nowrap", children: String(h ?? m ?? "") }) }, `${e.field}-${t}`);
122
101
  }) });
123
102
  });
124
- J.displayName = "SplitCellEditor";
103
+ Z.displayName = "SplitCellEditor";
125
104
  export {
126
- J as SplitCellEditor
105
+ Z as SplitCellEditor
127
106
  };
@@ -0,0 +1,53 @@
1
+ import { ColDef } from 'ag-grid-enterprise';
2
+ import { SplitConfig, SplitCellValue } from '../types';
3
+ export type SplitCellDocumentState = {
4
+ __splitCellLastClickY?: number;
5
+ __splitCellLastActiveIndex?: number;
6
+ __splitCellLastWasEditable?: boolean;
7
+ };
8
+ /**
9
+ * True when edit was started by keyboard (Enter/F2/type-to-edit), not mouse click.
10
+ * eventKey wins over stale __splitCellLastClickY left by a prior mousedown that did not edit.
11
+ */
12
+ export declare function isSplitCellKeyboardEntry(eventKey: string | null | undefined, documentState: SplitCellDocumentState): boolean;
13
+ /**
14
+ * Call from colDef.suppressKeyboardEvent before AG Grid evaluates editable().
15
+ * Clears stale click coordinates so Enter/F2/type-to-edit use keyboard focus rules.
16
+ */
17
+ export declare function prepareSplitCellKeyboardEditStart(eventKey: string, isEditing: boolean): void;
18
+ export type SplitCellFocusMeta = {
19
+ index: number;
20
+ wasEditable: boolean;
21
+ clearClickY: boolean;
22
+ activeIndex?: number;
23
+ };
24
+ type ResolveSplitEditable = (splits: SplitConfig[], index: number, data: unknown, colDef: ColDef | undefined, value: SplitCellValue | undefined) => boolean;
25
+ export declare function computeSplitCellFocusMeta(options: {
26
+ cellElement?: HTMLElement;
27
+ splits?: SplitConfig[];
28
+ isKeyboardEntry: boolean;
29
+ eventKey: string | null | undefined;
30
+ data: unknown;
31
+ colDef: ColDef | undefined;
32
+ value: SplitCellValue | undefined;
33
+ documentState: SplitCellDocumentState;
34
+ resolveSplitEditable: ResolveSplitEditable;
35
+ }): SplitCellFocusMeta;
36
+ export type SplitCellFocusSession = {
37
+ targetSplitIndex: number;
38
+ isKeyboardEntry: boolean;
39
+ lastWasEditable: boolean;
40
+ targetIsNonEditable: boolean;
41
+ };
42
+ export declare function initializeSplitCellFocusSession(options: {
43
+ cellElement?: HTMLElement;
44
+ splits?: SplitConfig[];
45
+ eventKey: string | null | undefined;
46
+ data: unknown;
47
+ colDef: ColDef | undefined;
48
+ value: SplitCellValue | undefined;
49
+ documentState: SplitCellDocumentState;
50
+ resolveSplitEditable: ResolveSplitEditable;
51
+ }): SplitCellFocusSession;
52
+ export declare function applySplitCellFocusMeta(documentState: SplitCellDocumentState, focusMeta: SplitCellFocusMeta): void;
53
+ export {};
@@ -0,0 +1,98 @@
1
+ function x(e, l) {
2
+ return e != null && e !== "" ? !0 : l.__splitCellLastClickY == null;
3
+ }
4
+ function _(e, l, a, n, s, i) {
5
+ for (let t = 0; t < e.length; t++)
6
+ if (s(e, t, l, a, n))
7
+ return i.__splitCellLastActiveIndex = t, i.__splitCellLastWasEditable = !0, { index: t, wasEditable: !0, clearClickY: !1 };
8
+ return i.__splitCellLastWasEditable = !1, { index: 0, wasEditable: !1, clearClickY: !1 };
9
+ }
10
+ function b(e, l, a, n, s, i) {
11
+ const t = i.__splitCellLastActiveIndex;
12
+ if (t != null && t >= 0 && t < e.length) {
13
+ const r = s(e, t, l, a, n);
14
+ return i.__splitCellLastWasEditable = r, { index: t, wasEditable: r, clearClickY: !1 };
15
+ }
16
+ return _(e, l, a, n, s, i);
17
+ }
18
+ function p(e, l, a, n, s, i, t) {
19
+ const r = t.__splitCellLastClickY;
20
+ if (r == null)
21
+ return { index: 0, wasEditable: !0, clearClickY: !1 };
22
+ const c = e.getBoundingClientRect(), d = r - c.top, u = c.height / l.length, f = Math.floor(d / u), C = Math.max(0, Math.min(f, l.length - 1)), o = i(l, C, a, n, s);
23
+ return t.__splitCellLastClickY = void 0, t.__splitCellLastActiveIndex = C, t.__splitCellLastWasEditable = o, {
24
+ index: C,
25
+ wasEditable: o,
26
+ clearClickY: !1,
27
+ activeIndex: void 0
28
+ };
29
+ }
30
+ function E(e) {
31
+ const {
32
+ cellElement: l,
33
+ splits: a,
34
+ isKeyboardEntry: n,
35
+ eventKey: s,
36
+ data: i,
37
+ colDef: t,
38
+ value: r,
39
+ documentState: c,
40
+ resolveSplitEditable: d
41
+ } = e;
42
+ return !l || !a?.length ? { index: 0, wasEditable: !0, clearClickY: !1 } : n ? s === "Tab" ? b(
43
+ a,
44
+ i,
45
+ t,
46
+ r,
47
+ d,
48
+ c
49
+ ) : _(
50
+ a,
51
+ i,
52
+ t,
53
+ r,
54
+ d,
55
+ c
56
+ ) : p(
57
+ l,
58
+ a,
59
+ i,
60
+ t,
61
+ r,
62
+ d,
63
+ c
64
+ );
65
+ }
66
+ const L = {
67
+ index: 0,
68
+ wasEditable: !0,
69
+ clearClickY: !1
70
+ };
71
+ function k(e) {
72
+ const { documentState: l, eventKey: a } = e, n = x(a, l);
73
+ n && (l.__splitCellLastClickY = void 0);
74
+ const s = l.__splitCellLastWasEditable !== !1;
75
+ let i = L;
76
+ try {
77
+ i = E({
78
+ ...e,
79
+ isKeyboardEntry: n
80
+ }), v(l, i);
81
+ } catch {
82
+ }
83
+ return {
84
+ targetSplitIndex: i.index,
85
+ isKeyboardEntry: n,
86
+ lastWasEditable: s,
87
+ targetIsNonEditable: !i.wasEditable
88
+ };
89
+ }
90
+ function v(e, l) {
91
+ l.clearClickY && (e.__splitCellLastClickY = void 0), l.activeIndex != null && (e.__splitCellLastActiveIndex = l.activeIndex), e.__splitCellLastWasEditable = l.wasEditable;
92
+ }
93
+ export {
94
+ v as applySplitCellFocusMeta,
95
+ E as computeSplitCellFocusMeta,
96
+ k as initializeSplitCellFocusSession,
97
+ x as isSplitCellKeyboardEntry
98
+ };
@@ -1,10 +1,12 @@
1
1
  import { jsxs as r, jsx as e, Fragment as B } from "react/jsx-runtime";
2
2
  import "react";
3
- import { Settings as W, Checkmark as m, Search as J } from "impact-nova-icons";
3
+ import { Settings as W, Checkmark as m, Search as I } from "impact-nova-icons";
4
4
  import { DropdownMenu as A, DropdownMenuTrigger as F, DropdownMenuContent as P, DropdownMenuItem as i, DropdownMenuLabel as T, DropdownMenuSeparator as j, DropdownMenuSub as g, DropdownMenuSubTrigger as C, DropdownMenuSubContent as x } from "../../../../feedback/dropdown-menu/dropdown-menu.js";
5
- import { useImpactNovaI18n as K } from "../../../../../i18n/use-impact-nova-i18n.js";
6
- import { useGridHeader as Q } from "../context/grid-header-context.js";
7
- const I = ({
5
+ import { useImpactNovaI18n as J } from "../../../../../i18n/use-impact-nova-i18n.js";
6
+ import { useGridHeader as K } from "../context/grid-header-context.js";
7
+ import { setActiveSearchColumnId as Q } from "../header-search-active-state.js";
8
+ import { notifyColumnIndicatorSync as U } from "../../notify-column-indicator-sync.js";
9
+ const re = ({
8
10
  isOpen: S,
9
11
  onClose: a,
10
12
  columnId: c,
@@ -12,9 +14,9 @@ const I = ({
12
14
  anchor: q,
13
15
  variant: d = "column"
14
16
  }) => {
15
- const { t } = K(), h = Q(), u = d === "column" ? s.getColumn(c) : null;
17
+ const { t } = J(), h = K(), u = d === "column" ? s.getColumn(c) : null;
16
18
  if (d === "column" && !u) return null;
17
- const l = u?.getColDef(), w = u?.getSort(), y = u?.getPinned(), E = d === "column" && l?.sortable !== !1, H = l?.filter || "agTextColumnFilter", b = H === "agNumberColumnFilter" || (Array.isArray(l?.type) ? l.type.includes("numericColumn") : l?.type === "numericColumn"), k = H === "agDateColumnFilter" || (Array.isArray(l?.type) ? l.type.includes("dateColumn") : l?.type === "dateColumn"), G = s.getGridOption("suppressRowVirtualisation") !== !0, p = (n) => {
19
+ const l = u?.getColDef(), y = u?.getSort(), w = u?.getPinned(), E = d === "column" && l?.sortable !== !1, H = l?.filter || "agTextColumnFilter", b = H === "agNumberColumnFilter" || (Array.isArray(l?.type) ? l.type.includes("numericColumn") : l?.type === "numericColumn"), k = H === "agDateColumnFilter" || (Array.isArray(l?.type) ? l.type.includes("dateColumn") : l?.type === "dateColumn"), G = s.getGridOption("suppressRowVirtualisation") !== !0, p = (n) => {
18
20
  queueMicrotask(() => {
19
21
  s.applyColumnState({
20
22
  state: [{ colId: c, sort: n }],
@@ -42,7 +44,7 @@ const I = ({
42
44
  h.openSearch(c);
43
45
  else {
44
46
  const n = s.getGridOption("context") || {};
45
- s.setGridOption("context", { ...n, activeSearchColumnId: c }), s.refreshHeader();
47
+ s.setGridOption("context", { ...n, activeSearchColumnId: c }), Q(c), U(s);
46
48
  }
47
49
  a();
48
50
  }, L = () => {
@@ -113,11 +115,11 @@ const I = ({
113
115
  /* @__PURE__ */ r(x, { sideOffset: 10, alignOffset: -5, children: [
114
116
  /* @__PURE__ */ e(i, { onClick: () => p("asc"), children: /* @__PURE__ */ r("span", { className: "flex items-center w-full justify-between", children: [
115
117
  /* @__PURE__ */ e("span", { children: t(b ? "gridHeader.sortAscNumber" : k ? "gridHeader.sortAscDate" : "gridHeader.sortAscText") }),
116
- w === "asc" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
118
+ y === "asc" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
117
119
  ] }) }),
118
120
  /* @__PURE__ */ e(i, { onClick: () => p("desc"), children: /* @__PURE__ */ r("span", { className: "flex items-center w-full justify-between", children: [
119
121
  /* @__PURE__ */ e("span", { children: t(b ? "gridHeader.sortDescNumber" : k ? "gridHeader.sortDescDate" : "gridHeader.sortDescText") }),
120
- w === "desc" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
122
+ y === "desc" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
121
123
  ] }) }),
122
124
  /* @__PURE__ */ e(i, { onClick: () => p(null), children: /* @__PURE__ */ e("span", { children: t("gridHeader.reset") }) })
123
125
  ] })
@@ -127,11 +129,11 @@ const I = ({
127
129
  /* @__PURE__ */ r(x, { className: "z-[120]", sideOffset: 10, alignOffset: -5, children: [
128
130
  /* @__PURE__ */ e(i, { onClick: () => f("left"), children: /* @__PURE__ */ r("span", { className: "flex items-center w-full justify-between", children: [
129
131
  /* @__PURE__ */ e("span", { children: t("gridHeader.pinLeft") }),
130
- y === "left" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
132
+ w === "left" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
131
133
  ] }) }),
132
134
  /* @__PURE__ */ e(i, { onClick: () => f("right"), children: /* @__PURE__ */ r("span", { className: "flex items-center w-full justify-between", children: [
133
135
  /* @__PURE__ */ e("span", { children: t("gridHeader.pinRight") }),
134
- y === "right" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
136
+ w === "right" && /* @__PURE__ */ e(m, { size: "sm", className: "ml-2 text-content-tertiary" })
135
137
  ] }) }),
136
138
  /* @__PURE__ */ e(i, { onClick: () => f(null), children: /* @__PURE__ */ e("span", { children: t("gridHeader.noPin") }) })
137
139
  ] })
@@ -148,7 +150,7 @@ const I = ({
148
150
  (M || O) && /* @__PURE__ */ r(B, { children: [
149
151
  /* @__PURE__ */ e(j, {}),
150
152
  /* @__PURE__ */ r(T, { className: "flex items-center gap-2 text-content-tertiary", children: [
151
- /* @__PURE__ */ e(J, { size: "xs" }),
153
+ /* @__PURE__ */ e(I, { size: "xs" }),
152
154
  " ",
153
155
  t("gridHeader.searchOptions")
154
156
  ] }),
@@ -161,5 +163,5 @@ const I = ({
161
163
  ] });
162
164
  };
163
165
  export {
164
- I as ColumnSettingsMenu
166
+ re as ColumnSettingsMenu
165
167
  };