impact-nova 2.5.12 → 2.5.13

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 (127) hide show
  1. package/dist/components/data/data-table/build-column-tree-from-grid.d.ts +1 -0
  2. package/dist/components/data/data-table/build-column-tree-from-grid.js +55 -50
  3. package/dist/components/data/data-table/column-picker-authority.d.ts +34 -0
  4. package/dist/components/data/data-table/column-picker-authority.js +116 -0
  5. package/dist/components/data/data-table/column-picker-drop-validation.d.ts +7 -0
  6. package/dist/components/data/data-table/column-picker-drop-validation.js +37 -0
  7. package/dist/components/data/data-table/data-table-column-apply.d.ts +2 -0
  8. package/dist/components/data/data-table/data-table-column-apply.js +84 -73
  9. package/dist/components/data/data-table/data-table-column-list-tree-apply.d.ts +10 -0
  10. package/dist/components/data/data-table/data-table-column-list-tree-apply.js +79 -0
  11. package/dist/components/data/data-table/data-table-column-list.js +94 -64
  12. package/dist/components/data/data-table/data-table-column-tree-cache.d.ts +12 -6
  13. package/dist/components/data/data-table/data-table-column-tree-cache.js +250 -131
  14. package/dist/components/data/data-table/data-table-flat-column-virtual-rows.d.ts +26 -0
  15. package/dist/components/data/data-table/data-table-flat-column-virtual-rows.js +195 -0
  16. package/dist/components/data/data-table/data-table-picker-column-eligibility.d.ts +1 -0
  17. package/dist/components/data/data-table/data-table-picker-column-eligibility.js +7 -0
  18. package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.d.ts +5 -0
  19. package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.js +28 -11
  20. package/dist/components/data/data-table/reconcile-column-tree-from-grid.d.ts +12 -0
  21. package/dist/components/data/data-table/reconcile-column-tree-from-grid.js +12 -0
  22. package/dist/components/data/data-table/use-data-table-column-list-sync.d.ts +10 -0
  23. package/dist/components/data/data-table/use-data-table-column-list-sync.js +250 -196
  24. package/dist/components/data/nested-list/components/NestedListContent.d.ts +10 -2
  25. package/dist/components/data/nested-list/components/NestedListContent.js +253 -138
  26. package/dist/components/data/nested-list/components/SortableItem.d.ts +2 -1
  27. package/dist/components/data/nested-list/components/SortableItem.js +62 -60
  28. package/dist/components/data/nested-list/hooks/useNestedListDragDrop.d.ts +10 -20
  29. package/dist/components/data/nested-list/hooks/useNestedListDragDrop.js +44 -233
  30. package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.d.ts +24 -0
  31. package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.js +128 -0
  32. package/dist/components/data/nested-list/nested-list-constants.d.ts +4 -1
  33. package/dist/components/data/nested-list/nested-list-constants.js +10 -4
  34. package/dist/components/data/nested-list/nested-list-display-utils.d.ts +11 -0
  35. package/dist/components/data/nested-list/nested-list-display-utils.js +74 -0
  36. package/dist/components/data/nested-list/nested-list-drop-engine.d.ts +31 -0
  37. package/dist/components/data/nested-list/nested-list-drop-engine.js +209 -0
  38. package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.d.ts +26 -0
  39. package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.js +67 -0
  40. package/dist/components/data/nested-list/nested-list-item-tree-mutations.d.ts +4 -0
  41. package/dist/components/data/nested-list/nested-list-item-tree-mutations.js +43 -0
  42. package/dist/components/data/nested-list/nested-list-lazy-flat-rows.d.ts +3 -0
  43. package/dist/components/data/nested-list/nested-list-lazy-flat-rows.js +34 -0
  44. package/dist/components/data/nested-list/nested-list-row-estimates.d.ts +9 -0
  45. package/dist/components/data/nested-list/nested-list-row-estimates.js +14 -0
  46. package/dist/components/data/nested-list/nested-list-scroll-anchor.d.ts +36 -0
  47. package/dist/components/data/nested-list/nested-list-scroll-anchor.js +47 -0
  48. package/dist/components/data/nested-list/nested-list-virtual-drop.d.ts +59 -0
  49. package/dist/components/data/nested-list/nested-list-virtual-drop.js +341 -0
  50. package/dist/components/data/nested-list/nested-list.js +322 -336
  51. package/dist/components/data/nested-list/nested-list.types.d.ts +17 -0
  52. package/dist/components/data-display/calendar/calendar-apply-validation.d.ts +0 -2
  53. package/dist/components/data-display/calendar/calendar-apply-validation.js +67 -64
  54. package/dist/components/data-display/calendar/calendar-config.js +1 -1
  55. package/dist/components/data-display/calendar/calendar-day-picker-components.d.ts +2 -4
  56. package/dist/components/data-display/calendar/calendar-day-picker-components.js +164 -234
  57. package/dist/components/data-display/calendar/calendar-day-picker-view.js +76 -77
  58. package/dist/components/data-display/calendar/calendar-fiscal-period-nav.d.ts +0 -6
  59. package/dist/components/data-display/calendar/calendar-fiscal-period-nav.js +18 -34
  60. package/dist/components/data-display/calendar/calendar-footer.js +21 -21
  61. package/dist/components/data-display/calendar/calendar-month-picker-panel.js +49 -50
  62. package/dist/components/data-display/calendar/calendar-month-utils.d.ts +0 -5
  63. package/dist/components/data-display/calendar/calendar-month-utils.js +64 -85
  64. package/dist/components/data-display/calendar/calendar-padding-week.utils.d.ts +1 -3
  65. package/dist/components/data-display/calendar/calendar-padding-week.utils.js +5 -7
  66. package/dist/components/data-display/calendar/calendar-period-cell.js +46 -45
  67. package/dist/components/data-display/calendar/calendar-quarter-panes.js +31 -33
  68. package/dist/components/data-display/calendar/calendar-selection-appearance.d.ts +0 -10
  69. package/dist/components/data-display/calendar/calendar-selection-appearance.js +39 -53
  70. package/dist/components/data-display/calendar/calendar-selection.d.ts +0 -25
  71. package/dist/components/data-display/calendar/calendar-selection.js +23 -52
  72. package/dist/components/data-display/calendar/calendar-week-number-cell.d.ts +1 -2
  73. package/dist/components/data-display/calendar/calendar-week-number-cell.js +45 -59
  74. package/dist/components/data-display/calendar/calendar-week-utils.d.ts +3 -13
  75. package/dist/components/data-display/calendar/calendar-week-utils.js +50 -59
  76. package/dist/components/data-display/calendar/calendar-year-panes.d.ts +0 -3
  77. package/dist/components/data-display/calendar/calendar-year-panes.js +49 -53
  78. package/dist/components/data-display/calendar/calendar.js +143 -146
  79. package/dist/components/data-display/calendar/calendar.types.d.ts +0 -5
  80. package/dist/components/data-display/calendar/use-calendar-day-picker-config.d.ts +1 -2
  81. package/dist/components/data-display/calendar/use-calendar-day-picker-config.js +74 -79
  82. package/dist/components/data-display/calendar/use-calendar-state.d.ts +1 -3
  83. package/dist/components/data-display/calendar/use-calendar-state.js +325 -403
  84. package/dist/components/forms/date-picker/date-picker.js +58 -60
  85. package/dist/components/forms/date-picker/date-picker.types.d.ts +0 -5
  86. package/dist/components/forms/date-picker/date-range-picker.js +64 -66
  87. package/dist/components/forms/date-picker/fiscal-pass-through.d.ts +0 -1
  88. package/dist/components/forms/date-picker/fiscal-pass-through.js +2 -3
  89. package/dist/components/forms/date-picker/month-picker.js +59 -61
  90. package/dist/components/forms/date-picker/month-range-picker.js +61 -63
  91. package/dist/components/forms/date-picker/multi-date-picker.js +49 -51
  92. package/dist/components/forms/date-picker/multi-month-picker.js +47 -49
  93. package/dist/components/forms/date-picker/multi-quarter-picker.js +47 -51
  94. package/dist/components/forms/date-picker/multi-week-picker.js +51 -53
  95. package/dist/components/forms/date-picker/multi-year-picker.js +49 -53
  96. package/dist/components/forms/date-picker/quarter-picker.js +47 -51
  97. package/dist/components/forms/date-picker/quarter-range-picker.js +46 -50
  98. package/dist/components/forms/date-picker/week-picker.js +66 -68
  99. package/dist/components/forms/date-picker/week-range-picker.js +80 -82
  100. package/dist/components/forms/date-picker/year-picker.js +48 -52
  101. package/dist/components/forms/date-picker/year-range-picker.js +48 -52
  102. package/dist/form-react/Fields/DateInputField.js +50 -51
  103. package/dist/form-react/Fields/DateRangeField.js +13 -14
  104. package/dist/form-react/Fields/MonthRangeField.js +28 -29
  105. package/dist/form-react/Fields/MultiMonthPickerField.js +12 -13
  106. package/dist/form-react/Fields/MultiWeekPickerField.js +27 -35
  107. package/dist/form-react/Fields/WeekRangePicker.js +32 -33
  108. package/dist/form-react/types/fields.types.d.ts +0 -14
  109. package/dist/impact-nova-components.css +6 -13
  110. package/dist/impact-nova.css +1 -1
  111. package/dist/lib/fiscal-calendar/week-selection.js +2 -2
  112. package/dist/lib/hash/fnv1a128.d.ts +16 -0
  113. package/dist/lib/hash/fnv1a128.js +21 -0
  114. package/dist/llms/rules/ag-grid.js +1 -1
  115. package/dist/llms/rules/installation.js +1 -1
  116. package/dist/llms/rules/requirements.js +1 -1
  117. package/package.json +1 -1
  118. package/dist/components/data-display/calendar/calendar-available-view.d.ts +0 -27
  119. package/dist/components/data-display/calendar/calendar-available-view.js +0 -85
  120. package/dist/components/data-display/calendar/calendar-fiscal-day-cell.d.ts +0 -9
  121. package/dist/components/data-display/calendar/calendar-fiscal-day-cell.js +0 -45
  122. package/dist/components/data-display/calendar/calendar-injected-week-row.d.ts +0 -5
  123. package/dist/components/data-display/calendar/calendar-injected-week-row.js +0 -92
  124. package/dist/components/data-display/calendar/calendar-leading-week.utils.d.ts +0 -16
  125. package/dist/components/data-display/calendar/calendar-leading-week.utils.js +0 -51
  126. package/dist/components/data-display/calendar/calendar-orphan-week.d.ts +0 -23
  127. package/dist/components/forms/date-picker/fiscal-picker-fixtures.d.ts +0 -17
@@ -1,19 +1,19 @@
1
1
  import { jsxs as f, jsx as r } from "react/jsx-runtime";
2
2
  import * as a from "react";
3
- import { Cross as _, CalendarMonth as ee } from "impact-nova-icons";
4
- import { format as te } from "date-fns";
5
- import { cn as re } from "../../../lib/utils.js";
6
- import { Input as oe } from "../input/input.js";
7
- import { Popover as ne, PopoverAnchor as ae, PopoverContent as se } from "../../feedback/popover/popover.js";
8
- import { Calendar as ie } from "../../data-display/calendar/calendar.js";
3
+ import { Cross as Z, CalendarMonth as _ } from "impact-nova-icons";
4
+ import { format as ee } from "date-fns";
5
+ import { cn as te } from "../../../lib/utils.js";
6
+ import { Input as re } from "../input/input.js";
7
+ import { Popover as oe, PopoverAnchor as ne, PopoverContent as ae } from "../../feedback/popover/popover.js";
8
+ import { Calendar as se } from "../../data-display/calendar/calendar.js";
9
9
  import { Tooltip as P, TooltipTrigger as C, TooltipContent as k } from "../../feedback/tooltip/tooltip.js";
10
- import { useImpactNovaI18n as ce } from "../../../i18n/use-impact-nova-i18n.js";
11
- import { getDateFnsLocale as le } from "../../../i18n/getDateFnsLocale.js";
12
- import { coerceDateArrayApply as pe, coerceDateArray as de } from "./calendar-selection-adapters.js";
13
- import { usePickerDismissActionsRef as fe, usePickerFooterDismissNudge as me, handlePickerSurfacePointerDown as ue } from "./date-input-behavior.js";
14
- import { buildDateBoundsMatcher as he } from "../../../lib/date-bounds-matcher.js";
15
- import { fiscalCalendarPassThrough as ye } from "./fiscal-pass-through.js";
16
- const ge = a.forwardRef(
10
+ import { useImpactNovaI18n as ie } from "../../../i18n/use-impact-nova-i18n.js";
11
+ import { getDateFnsLocale as ce } from "../../../i18n/getDateFnsLocale.js";
12
+ import { coerceDateArrayApply as le, coerceDateArray as pe } from "./calendar-selection-adapters.js";
13
+ import { usePickerDismissActionsRef as de, usePickerFooterDismissNudge as fe, handlePickerSurfacePointerDown as me } from "./date-input-behavior.js";
14
+ import { buildDateBoundsMatcher as ue } from "../../../lib/date-bounds-matcher.js";
15
+ import { fiscalCalendarPassThrough as he } from "./fiscal-pass-through.js";
16
+ const ye = a.forwardRef(
17
17
  ({
18
18
  value: t,
19
19
  onChange: m,
@@ -34,61 +34,60 @@ const ge = a.forwardRef(
34
34
  fiscalConfig: O,
35
35
  showPresets: w,
36
36
  showPeriodBoundaries: E,
37
- autoNavigateToAvailable: v,
38
- comparison: z,
39
- onComparisonChange: K,
40
- ...q
41
- }, B) => {
42
- const { locale: h, t: s } = ce(), H = a.useMemo(() => le(h), [h]), V = M ?? s("datePicker.selectMultipleDates"), [i, n] = a.useState(!1), u = a.useRef(null), y = fe(), { footerFlashKey: $, footerFlashTarget: G, popoverHandlers: J } = me(l, i, y, u), [p, d] = a.useState(t);
37
+ comparison: v,
38
+ onComparisonChange: z,
39
+ ...K
40
+ }, q) => {
41
+ const { locale: h, t: s } = ie(), B = a.useMemo(() => ce(h), [h]), H = M ?? s("datePicker.selectMultipleDates"), [i, n] = a.useState(!1), u = a.useRef(null), y = de(), { footerFlashKey: V, footerFlashTarget: $, popoverHandlers: G } = fe(l, i, y, u), [p, d] = a.useState(t);
43
42
  a.useEffect(() => {
44
43
  d(t);
45
44
  }, [i, t]);
46
- const Q = (e) => {
47
- const c = de(e);
45
+ const J = (e) => {
46
+ const c = pe(e);
48
47
  d(c), l || m?.(c);
49
- }, U = (e) => {
50
- const c = pe(e, p);
48
+ }, Q = (e) => {
49
+ const c = le(e, p);
51
50
  m?.(c), n(!1);
52
51
  }, g = () => {
53
52
  d(t), n(!1);
54
53
  }, D = () => {
55
54
  d(void 0), m?.(void 0), l || n(!1);
56
- }, W = t && t.length > 0 ? t.length === 1 ? te(t[0], x, { locale: H }) : `${t.length} dates selected` : "", X = a.useCallback(() => {
55
+ }, U = t && t.length > 0 ? t.length === 1 ? ee(t[0], x, { locale: B }) : `${t.length} dates selected` : "", W = a.useCallback(() => {
57
56
  const e = p?.length ?? 0, c = t?.length ?? 0;
58
57
  return e === c && (p ?? []).every(
59
- (Y, Z) => Y.getTime() === t?.[Z]?.getTime()
58
+ (X, Y) => X.getTime() === t?.[Y]?.getTime()
60
59
  ) ? "dismiss" : e > 0 ? "apply" : "cancel";
61
60
  }, [p, t]);
62
61
  return a.useLayoutEffect(() => {
63
62
  y.current = {
64
63
  onDismiss: g,
65
- resolveFlash: X
64
+ resolveFlash: W
66
65
  };
67
- }), /* @__PURE__ */ f(ne, { open: o ? !1 : i, onOpenChange: (e) => {
66
+ }), /* @__PURE__ */ f(oe, { open: o ? !1 : i, onOpenChange: (e) => {
68
67
  o || !e && l || n(e);
69
68
  }, children: [
70
- /* @__PURE__ */ r(ae, { asChild: !0, children: /* @__PURE__ */ r(
69
+ /* @__PURE__ */ r(ne, { asChild: !0, children: /* @__PURE__ */ r(
71
70
  "div",
72
71
  {
73
72
  ref: u,
74
- onPointerDown: (e) => ue({
73
+ onPointerDown: (e) => me({
75
74
  disabled: o,
76
75
  event: e,
77
76
  onOpen: () => n(!0),
78
77
  focusField: () => u.current?.querySelector("input")?.focus()
79
78
  }),
80
79
  children: /* @__PURE__ */ r(
81
- oe,
80
+ re,
82
81
  {
83
- ref: B,
84
- value: W,
85
- placeholder: V,
82
+ ref: q,
83
+ value: U,
84
+ placeholder: H,
86
85
  readOnly: !0,
87
86
  disabled: o,
88
87
  onClick: () => {
89
88
  !o && !i && n(!0);
90
89
  },
91
- className: re("cursor-pointer", R),
90
+ className: te("cursor-pointer", R),
92
91
  suffix: /* @__PURE__ */ f("div", { className: "flex items-center gap-1", children: [
93
92
  t && t.length > 0 && !o && /* @__PURE__ */ f(P, { children: [
94
93
  /* @__PURE__ */ r(C, { asChild: !0, children: /* @__PURE__ */ r(
@@ -101,7 +100,7 @@ const ge = a.forwardRef(
101
100
  e.stopPropagation(), D();
102
101
  },
103
102
  className: "inline-flex size-4 items-center justify-center bg-transparent border-none p-0 cursor-pointer",
104
- children: /* @__PURE__ */ r(_, { className: "size-3 hover:text-content" })
103
+ children: /* @__PURE__ */ r(Z, { className: "size-3 hover:text-content" })
105
104
  }
106
105
  ) }),
107
106
  /* @__PURE__ */ r(k, { variant: "tertiary", side: "top", children: s("calendar.clear") })
@@ -121,42 +120,42 @@ const ge = a.forwardRef(
121
120
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), e.stopPropagation(), o || n(!i));
122
121
  },
123
122
  className: "inline-flex items-center justify-center bg-transparent border-none p-0 cursor-pointer",
124
- children: /* @__PURE__ */ r(ee, { className: "h-4 w-4 text-secondary-foreground" })
123
+ children: /* @__PURE__ */ r(_, { className: "h-4 w-4 text-secondary-foreground" })
125
124
  }
126
125
  ) }),
127
126
  /* @__PURE__ */ r(k, { variant: "tertiary", side: "top", children: s("datePicker.selectMultipleDates") })
128
127
  ] })
129
128
  ] }),
130
- ...q
129
+ ...K
131
130
  }
132
131
  )
133
132
  }
134
133
  ) }),
135
134
  /* @__PURE__ */ r(
136
- se,
135
+ ae,
137
136
  {
138
137
  className: "w-auto p-0",
139
138
  align: "start",
140
139
  "aria-label": s("datePicker.selectMultipleDates"),
141
140
  onOpenAutoFocus: (e) => e.preventDefault(),
142
- ...J,
141
+ ...G,
143
142
  children: /* @__PURE__ */ r(
144
- ie,
143
+ se,
145
144
  {
146
145
  mode: "multiple",
147
146
  selected: p,
148
- footerFlashKey: $,
149
- footerFlashTarget: G,
150
- onSelect: Q,
151
- disabled: he(A, N),
147
+ footerFlashKey: V,
148
+ footerFlashTarget: $,
149
+ onSelect: J,
150
+ disabled: ue(A, N),
152
151
  startMonth: b,
153
152
  endMonth: T,
154
153
  showFooter: l,
155
- onApply: U,
154
+ onApply: Q,
156
155
  onCancel: g,
157
156
  onClear: D,
158
157
  captionLayout: "dropdown",
159
- ...ye({
158
+ ...he({
160
159
  calendarKind: S,
161
160
  fiscalMode: F,
162
161
  granularity: I,
@@ -165,9 +164,8 @@ const ge = a.forwardRef(
165
164
  fiscalConfig: O,
166
165
  showPresets: w,
167
166
  showPeriodBoundaries: E,
168
- autoNavigateToAvailable: v,
169
- comparison: z,
170
- onComparisonChange: K
167
+ comparison: v,
168
+ onComparisonChange: z
171
169
  })
172
170
  }
173
171
  )
@@ -176,7 +174,7 @@ const ge = a.forwardRef(
176
174
  ] });
177
175
  }
178
176
  );
179
- ge.displayName = "MultiDatePicker";
177
+ ye.displayName = "MultiDatePicker";
180
178
  export {
181
- ge as MultiDatePicker
179
+ ye as MultiDatePicker
182
180
  };
@@ -1,17 +1,17 @@
1
1
  import { jsxs as d, jsx as n } from "react/jsx-runtime";
2
2
  import * as s from "react";
3
- import { Cross as Z, CalendarMonth as _ } from "impact-nova-icons";
4
- import { cn as ee } from "../../../lib/utils.js";
5
- import { Input as te } from "../input/input.js";
6
- import { Popover as ne, PopoverAnchor as re, PopoverContent as oe } from "../../feedback/popover/popover.js";
7
- import { Calendar as se } from "../../data-display/calendar/calendar.js";
3
+ import { Cross as Y, CalendarMonth as Z } from "impact-nova-icons";
4
+ import { cn as _ } from "../../../lib/utils.js";
5
+ import { Input as ee } from "../input/input.js";
6
+ import { Popover as te, PopoverAnchor as ne, PopoverContent as re } from "../../feedback/popover/popover.js";
7
+ import { Calendar as oe } from "../../data-display/calendar/calendar.js";
8
8
  import { Tooltip as D, TooltipTrigger as b, TooltipContent as x } from "../../feedback/tooltip/tooltip.js";
9
- import { useImpactNovaI18n as ie } from "../../../i18n/use-impact-nova-i18n.js";
10
- import { coerceMonthArrayApply as ce, coerceMonthArray as ae } from "./calendar-selection-adapters.js";
11
- import { usePickerDismissActionsRef as le, usePickerFooterDismissNudge as pe, handlePickerSurfacePointerDown as fe } from "./date-input-behavior.js";
12
- import { buildDateBoundsMatcher as de } from "../../../lib/date-bounds-matcher.js";
13
- import { fiscalCalendarPassThrough as he } from "./fiscal-pass-through.js";
14
- const ue = s.forwardRef(
9
+ import { useImpactNovaI18n as se } from "../../../i18n/use-impact-nova-i18n.js";
10
+ import { coerceMonthArrayApply as ie, coerceMonthArray as ce } from "./calendar-selection-adapters.js";
11
+ import { usePickerDismissActionsRef as ae, usePickerFooterDismissNudge as le, handlePickerSurfacePointerDown as pe } from "./date-input-behavior.js";
12
+ import { buildDateBoundsMatcher as fe } from "../../../lib/date-bounds-matcher.js";
13
+ import { fiscalCalendarPassThrough as de } from "./fiscal-pass-through.js";
14
+ const he = s.forwardRef(
15
15
  ({
16
16
  value: t,
17
17
  onChange: h,
@@ -31,28 +31,27 @@ const ue = s.forwardRef(
31
31
  fiscalConfig: E,
32
32
  showPresets: F,
33
33
  showPeriodBoundaries: K,
34
- autoNavigateToAvailable: z,
35
- comparison: L,
36
- onComparisonChange: V,
37
- ...$
38
- }, q) => {
39
- const { t: i } = ie(), B = A ?? i("datePicker.selectMultipleMonths"), [c, o] = s.useState(!1), u = s.useRef(!1), m = s.useRef(null), g = le(), { footerFlashKey: H, footerFlashTarget: G, popoverHandlers: J } = pe(l, c, g, m), [p, f] = s.useState(t);
34
+ comparison: z,
35
+ onComparisonChange: L,
36
+ ...V
37
+ }, $) => {
38
+ const { t: i } = se(), q = A ?? i("datePicker.selectMultipleMonths"), [c, o] = s.useState(!1), u = s.useRef(!1), m = s.useRef(null), g = ae(), { footerFlashKey: B, footerFlashTarget: H, popoverHandlers: G } = le(l, c, g, m), [p, f] = s.useState(t);
40
39
  s.useEffect(() => {
41
40
  f(t);
42
41
  }, [c, t]);
43
- const Q = (e) => {
44
- const a = ae(e);
42
+ const J = (e) => {
43
+ const a = ce(e);
45
44
  f(a), l || h?.(a);
46
- }, U = (e) => {
47
- const a = ce(e, p);
45
+ }, Q = (e) => {
46
+ const a = ie(e, p);
48
47
  h?.(a), o(!1);
49
48
  }, M = () => {
50
49
  f(t), o(!1);
51
50
  }, P = () => {
52
51
  f(void 0), h?.(void 0), l || o(!1);
53
- }, W = t && t.length > 0 ? t.length === 1 ? `${t[0].month + 1}/${t[0].year}` : i("datePicker.monthsSelected", { count: t.length }) : "", X = (e) => {
52
+ }, U = t && t.length > 0 ? t.length === 1 ? `${t[0].month + 1}/${t[0].year}` : i("datePicker.monthsSelected", { count: t.length }) : "", W = (e) => {
54
53
  r || !e && l || o(e);
55
- }, Y = s.useCallback(() => {
54
+ }, X = s.useCallback(() => {
56
55
  const e = p?.length ?? 0, a = t?.length ?? 0;
57
56
  return e === a && (p ?? []).every(
58
57
  (C, k) => C.month === t?.[k]?.month && C.year === t?.[k]?.year
@@ -61,31 +60,31 @@ const ue = s.forwardRef(
61
60
  return s.useLayoutEffect(() => {
62
61
  g.current = {
63
62
  onDismiss: M,
64
- resolveFlash: Y
63
+ resolveFlash: X
65
64
  };
66
- }), /* @__PURE__ */ d(ne, { open: r ? !1 : c, onOpenChange: X, children: [
67
- /* @__PURE__ */ n(re, { asChild: !0, children: /* @__PURE__ */ n(
65
+ }), /* @__PURE__ */ d(te, { open: r ? !1 : c, onOpenChange: W, children: [
66
+ /* @__PURE__ */ n(ne, { asChild: !0, children: /* @__PURE__ */ n(
68
67
  "div",
69
68
  {
70
69
  ref: m,
71
- onPointerDown: (e) => fe({
70
+ onPointerDown: (e) => pe({
72
71
  disabled: r,
73
72
  event: e,
74
73
  onOpen: () => o(!0),
75
74
  focusField: () => m.current?.querySelector("input")?.focus()
76
75
  }),
77
76
  children: /* @__PURE__ */ n(
78
- te,
77
+ ee,
79
78
  {
80
- ref: q,
81
- value: W,
82
- placeholder: B,
79
+ ref: $,
80
+ value: U,
81
+ placeholder: q,
83
82
  readOnly: !0,
84
83
  disabled: r,
85
84
  onClick: () => {
86
85
  !r && !c && o(!0);
87
86
  },
88
- className: ee("cursor-pointer", S),
87
+ className: _("cursor-pointer", S),
89
88
  suffix: /* @__PURE__ */ d("div", { className: "flex items-center gap-1", children: [
90
89
  t && t.length > 0 && !r && /* @__PURE__ */ d(D, { children: [
91
90
  /* @__PURE__ */ n(b, { asChild: !0, children: /* @__PURE__ */ n(
@@ -98,7 +97,7 @@ const ue = s.forwardRef(
98
97
  e.stopPropagation(), P();
99
98
  },
100
99
  className: "inline-flex size-4 items-center justify-center bg-transparent border-none p-0 cursor-pointer",
101
- children: /* @__PURE__ */ n(Z, { className: "size-3 hover:text-content" })
100
+ children: /* @__PURE__ */ n(Y, { className: "size-3 hover:text-content" })
102
101
  }
103
102
  ) }),
104
103
  /* @__PURE__ */ n(x, { variant: "tertiary", side: "top", children: i("calendar.clear") })
@@ -118,19 +117,19 @@ const ue = s.forwardRef(
118
117
  (e.key === "Enter" || e.key === " ") && (e.preventDefault(), e.stopPropagation(), r || (u.current = !0, o(!c)));
119
118
  },
120
119
  className: "inline-flex items-center justify-center bg-transparent border-none p-0 cursor-pointer",
121
- children: /* @__PURE__ */ n(_, { className: "h-4 w-4 text-secondary-foreground" })
120
+ children: /* @__PURE__ */ n(Z, { className: "h-4 w-4 text-secondary-foreground" })
122
121
  }
123
122
  ) }),
124
123
  /* @__PURE__ */ n(x, { variant: "tertiary", side: "top", children: i("datePicker.selectMultipleMonths") })
125
124
  ] })
126
125
  ] }),
127
- ...$
126
+ ...V
128
127
  }
129
128
  )
130
129
  }
131
130
  ) }),
132
131
  /* @__PURE__ */ n(
133
- oe,
132
+ re,
134
133
  {
135
134
  className: "w-auto p-0",
136
135
  align: "start",
@@ -138,26 +137,26 @@ const ue = s.forwardRef(
138
137
  onOpenAutoFocus: (e) => {
139
138
  u.current || e.preventDefault(), u.current = !1;
140
139
  },
141
- ...J,
140
+ ...G,
142
141
  children: /* @__PURE__ */ n(
143
- se,
142
+ oe,
144
143
  {
145
144
  pickerType: "month",
146
145
  monthMode: "multiple",
147
146
  selectedMonths: p,
148
- footerFlashKey: H,
149
- footerFlashTarget: G,
150
- onMonthSelect: Q,
151
- disabled: de(y, N),
147
+ footerFlashKey: B,
148
+ footerFlashTarget: H,
149
+ onMonthSelect: J,
150
+ disabled: fe(y, N),
152
151
  startMonth: R,
153
152
  endMonth: T,
154
153
  defaultMonth: y,
155
154
  showFooter: l,
156
- onApply: U,
155
+ onApply: Q,
157
156
  onCancel: M,
158
157
  onClear: P,
159
158
  captionLayout: "dropdown",
160
- ...he({
159
+ ...de({
161
160
  calendarKind: I,
162
161
  fiscalMode: O,
163
162
  granularity: j,
@@ -166,9 +165,8 @@ const ue = s.forwardRef(
166
165
  fiscalConfig: E,
167
166
  showPresets: F,
168
167
  showPeriodBoundaries: K,
169
- autoNavigateToAvailable: z,
170
- comparison: L,
171
- onComparisonChange: V
168
+ comparison: z,
169
+ onComparisonChange: L
172
170
  })
173
171
  }
174
172
  )
@@ -177,7 +175,7 @@ const ue = s.forwardRef(
177
175
  ] });
178
176
  }
179
177
  );
180
- ue.displayName = "MultiMonthPicker";
178
+ he.displayName = "MultiMonthPicker";
181
179
  export {
182
- ue as MultiMonthPicker
180
+ he as MultiMonthPicker
183
181
  };
@@ -1,18 +1,18 @@
1
1
  import { jsx as r, jsxs as g } from "react/jsx-runtime";
2
2
  import * as n from "react";
3
- import { Cross as _, CalendarMonth as $ } from "impact-nova-icons";
4
- import { cn as ee } from "../../../lib/utils.js";
5
- import { Input as te } from "../input/input.js";
6
- import { Calendar as re } from "../../data-display/calendar/calendar.js";
3
+ import { Cross as Y, CalendarMonth as Z } from "impact-nova-icons";
4
+ import { cn as _ } from "../../../lib/utils.js";
5
+ import { Input as $ } from "../input/input.js";
6
+ import { Calendar as ee } from "../../data-display/calendar/calendar.js";
7
7
  import { Tooltip as M, TooltipTrigger as x, TooltipContent as b } from "../../feedback/tooltip/tooltip.js";
8
- import { useImpactNovaI18n as ne } from "../../../i18n/use-impact-nova-i18n.js";
9
- import { buildDateBoundsMatcher as oe } from "../../../lib/date-bounds-matcher.js";
10
- import { fiscalCalendarPassThrough as ae } from "./fiscal-pass-through.js";
11
- import { DatePickerShell as ie } from "./date-picker-shell.js";
12
- import { usePickerDismissActionsRef as ce, usePickerFooterDismissNudge as se, handleReadonlyPickerKeyDown as le, handlePickerSurfacePointerDown as pe } from "./date-input-behavior.js";
13
- import { formatQuarterInput as ue } from "../../data-display/calendar/calendar-fiscal-labels.js";
14
- import { viewMonthFromQuarter as fe } from "../../data-display/calendar/calendar-quarter-utils.js";
15
- const de = n.forwardRef(
8
+ import { useImpactNovaI18n as te } from "../../../i18n/use-impact-nova-i18n.js";
9
+ import { buildDateBoundsMatcher as re } from "../../../lib/date-bounds-matcher.js";
10
+ import { fiscalCalendarPassThrough as ne } from "./fiscal-pass-through.js";
11
+ import { DatePickerShell as oe } from "./date-picker-shell.js";
12
+ import { usePickerDismissActionsRef as ae, usePickerFooterDismissNudge as ie, handleReadonlyPickerKeyDown as ce, handlePickerSurfacePointerDown as se } from "./date-input-behavior.js";
13
+ import { formatQuarterInput as le } from "../../data-display/calendar/calendar-fiscal-labels.js";
14
+ import { viewMonthFromQuarter as pe } from "../../data-display/calendar/calendar-quarter-utils.js";
15
+ const ue = n.forwardRef(
16
16
  ({
17
17
  value: t,
18
18
  onChange: u,
@@ -30,33 +30,29 @@ const de = n.forwardRef(
30
30
  fiscalMonthPattern: w,
31
31
  fiscalYearStartMonth: v,
32
32
  fiscalConfig: K,
33
- weekStartsOn: j,
34
- showPresets: F,
35
- showPeriodBoundaries: z,
36
- autoNavigateToAvailable: E,
37
- ...H
38
- }, L) => {
39
- const { t: a } = ne(), V = R ?? a("datePicker.selectMultipleQuarters"), f = n.useRef(null), y = n.useRef(null);
40
- n.useImperativeHandle(L, () => f.current);
41
- const [i, c] = n.useState(!1), d = n.useRef(!1), k = ce(), { footerFlashKey: q, footerFlashTarget: B, popoverHandlers: G } = se(s, i, k, y), [P, l] = n.useState(t), [J, U] = n.useState(fe(t?.[0]));
33
+ showPresets: j,
34
+ showPeriodBoundaries: F,
35
+ ...z
36
+ }, E) => {
37
+ const { t: a } = te(), H = R ?? a("datePicker.selectMultipleQuarters"), f = n.useRef(null), y = n.useRef(null);
38
+ n.useImperativeHandle(E, () => f.current);
39
+ const [i, c] = n.useState(!1), d = n.useRef(!1), k = ae(), { footerFlashKey: L, footerFlashTarget: V, popoverHandlers: q } = ie(s, i, k, y), [P, l] = n.useState(t), [B, G] = n.useState(pe(t?.[0]));
42
40
  n.useEffect(() => {
43
41
  i || l(t);
44
42
  }, [i, t]);
45
- const m = n.useCallback(() => c(!1), []), W = ae({
43
+ const m = n.useCallback(() => c(!1), []), J = ne({
46
44
  calendarKind: I,
47
45
  fiscalMode: O,
48
46
  granularity: T,
49
47
  fiscalMonthPattern: w,
50
48
  fiscalYearStartMonth: v,
51
49
  fiscalConfig: K,
52
- weekStartsOn: j,
53
- showPresets: F,
54
- showPeriodBoundaries: z,
55
- autoNavigateToAvailable: E
56
- }), X = (e) => {
50
+ showPresets: j,
51
+ showPeriodBoundaries: F
52
+ }), U = (e) => {
57
53
  const p = Array.isArray(e) && e.length > 0 ? e : void 0;
58
54
  l(p), s || u?.(p);
59
- }, Y = () => {
55
+ }, W = () => {
60
56
  u?.(P), m();
61
57
  }, h = () => {
62
58
  l(t), m();
@@ -66,9 +62,9 @@ const de = n.forwardRef(
66
62
  n.useLayoutEffect(() => {
67
63
  k.current = { onDismiss: h, resolveFlash: () => "cancel" };
68
64
  });
69
- const Z = t && t.length > 0 ? t.length === 1 ? ue(t[0]) : a("datePicker.quartersSelected", { count: t.length }) : "";
65
+ const X = t && t.length > 0 ? t.length === 1 ? le(t[0]) : a("datePicker.quartersSelected", { count: t.length }) : "";
70
66
  return /* @__PURE__ */ r(
71
- ie,
67
+ oe,
72
68
  {
73
69
  open: i,
74
70
  disabled: o,
@@ -79,26 +75,26 @@ const de = n.forwardRef(
79
75
  onOpenAutoFocus: (e) => {
80
76
  d.current || e.preventDefault(), d.current = !1;
81
77
  },
82
- popoverHandlers: G,
78
+ popoverHandlers: q,
83
79
  trigger: /* @__PURE__ */ r(
84
80
  "div",
85
81
  {
86
82
  ref: y,
87
83
  "data-component": "multi-quarter-picker",
88
84
  "data-state": i ? "open" : "closed",
89
- onPointerDown: (e) => pe({
85
+ onPointerDown: (e) => se({
90
86
  disabled: o,
91
87
  event: e,
92
88
  onOpen: () => c(!0),
93
89
  focusField: () => f.current?.focus()
94
90
  }),
95
91
  children: /* @__PURE__ */ r(
96
- te,
92
+ $,
97
93
  {
98
94
  ref: f,
99
- value: Z,
95
+ value: X,
100
96
  readOnly: !0,
101
- onKeyDown: (e) => le(e, {
97
+ onKeyDown: (e) => ce(e, {
102
98
  disabled: o,
103
99
  open: i,
104
100
  onOpen: () => c(!0),
@@ -108,10 +104,10 @@ const de = n.forwardRef(
108
104
  }
109
105
  }),
110
106
  onClick: () => !o && c(!0),
111
- placeholder: V,
107
+ placeholder: H,
112
108
  disabled: o,
113
109
  "data-form-control": "input",
114
- className: ee("cursor-pointer", A),
110
+ className: _("cursor-pointer", A),
115
111
  suffix: /* @__PURE__ */ g("div", { className: "flex items-center gap-1", children: [
116
112
  t && t.length > 0 && !o ? /* @__PURE__ */ g(M, { children: [
117
113
  /* @__PURE__ */ r(x, { asChild: !0, children: /* @__PURE__ */ r(
@@ -124,7 +120,7 @@ const de = n.forwardRef(
124
120
  e.stopPropagation(), C();
125
121
  },
126
122
  className: "inline-flex size-4 items-center justify-center border-none bg-transparent p-0",
127
- children: /* @__PURE__ */ r(_, { className: "size-3 hover:text-content" })
123
+ children: /* @__PURE__ */ r(Y, { className: "size-3 hover:text-content" })
128
124
  }
129
125
  ) }),
130
126
  /* @__PURE__ */ r(b, { variant: "tertiary", side: "top", children: a("calendar.clear") })
@@ -141,43 +137,43 @@ const de = n.forwardRef(
141
137
  e.stopPropagation(), o || c((p) => !p);
142
138
  },
143
139
  className: "inline-flex items-center justify-center border-none bg-transparent p-0",
144
- children: /* @__PURE__ */ r($, { className: "h-4 w-4 text-secondary-foreground" })
140
+ children: /* @__PURE__ */ r(Z, { className: "h-4 w-4 text-secondary-foreground" })
145
141
  }
146
142
  ) }),
147
143
  /* @__PURE__ */ r(b, { variant: "tertiary", side: "top", children: a("datePicker.selectMultipleQuarters") })
148
144
  ] })
149
145
  ] }),
150
- ...H
146
+ ...z
151
147
  }
152
148
  )
153
149
  }
154
150
  ),
155
151
  children: /* @__PURE__ */ r(
156
- re,
152
+ ee,
157
153
  {
158
154
  pickerType: "quarter",
159
155
  monthMode: "multiple",
160
156
  selectedQuarters: P,
161
- footerFlashKey: q,
162
- footerFlashTarget: B,
163
- onQuarterSelect: X,
164
- month: J,
165
- onMonthChange: U,
166
- disabled: oe(D, Q),
157
+ footerFlashKey: L,
158
+ footerFlashTarget: V,
159
+ onQuarterSelect: U,
160
+ month: B,
161
+ onMonthChange: G,
162
+ disabled: re(D, Q),
167
163
  startMonth: N,
168
164
  endMonth: S,
169
165
  showFooter: s,
170
- onApply: Y,
166
+ onApply: W,
171
167
  onCancel: h,
172
168
  onClear: C,
173
- ...W
169
+ ...J
174
170
  }
175
171
  )
176
172
  }
177
173
  );
178
174
  }
179
175
  );
180
- de.displayName = "MultiQuarterPicker";
176
+ ue.displayName = "MultiQuarterPicker";
181
177
  export {
182
- de as MultiQuarterPicker
178
+ ue as MultiQuarterPicker
183
179
  };