@epam/ai-dial-ui-kit 0.16.0-dev.20 → 0.16.0-dev.22

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 (31) hide show
  1. package/README.md +2 -0
  2. package/dist/CHANGELOG.md +2 -0
  3. package/dist/{DateCellRenderer-DDEzIi2B.cjs → DateCellRenderer-BEZLnOm0.cjs} +1 -1
  4. package/dist/JsonEditor-eAV7SaKu.cjs +1 -0
  5. package/dist/{MarkdownEditor-BKtFs714.cjs → MarkdownEditor-Cp-KX6-T.cjs} +1 -1
  6. package/dist/{MarkdownEditor-Bapd1ycU.cjs → MarkdownEditor-Dav_pp0T.cjs} +1 -1
  7. package/dist/MarkdownEditorContainer-D8YTX8EM.cjs +1 -0
  8. package/dist/components/MarkdownEditor/MarkdownEditorContainer.js +18 -16
  9. package/dist/components/New/Calendar/Calendar.js +288 -216
  10. package/dist/components/New/Calendar/TimePickerPanel.js +87 -0
  11. package/dist/components/New/Calendar/constants.js +26 -24
  12. package/dist/components/New/ResizeHandle/ResizeHandle.js +147 -0
  13. package/dist/components-manifest.json +78 -4
  14. package/dist/constants/public-class-names.js +2 -0
  15. package/dist/dial-ui-kit.cjs +3 -3
  16. package/dist/dial-ui-kit.js +174 -172
  17. package/dist/editor-BH6_A1k2.cjs +1 -0
  18. package/dist/editors.cjs +1 -1
  19. package/dist/grid.cjs +1 -1
  20. package/dist/index.css +1 -1
  21. package/dist/lazy-DMVYJhUR.cjs +1 -0
  22. package/dist/src/components/New/Calendar/Calendar.d.ts +7 -0
  23. package/dist/src/components/New/Calendar/TimePickerPanel.d.ts +15 -0
  24. package/dist/src/components/New/Calendar/constants.d.ts +2 -0
  25. package/dist/src/components/New/ResizeHandle/ResizeHandle.d.ts +68 -0
  26. package/dist/src/constants/public-class-names.d.ts +2 -0
  27. package/dist/src/index.d.ts +2 -0
  28. package/package.json +1 -1
  29. package/dist/JsonEditor-Bxui5wJH.cjs +0 -1
  30. package/dist/MarkdownEditorContainer-DLPODjar.cjs +0 -1
  31. package/dist/lazy-_W6FYhKg.cjs +0 -1
@@ -1,234 +1,306 @@
1
- import { jsx as e, jsxs as d, Fragment as w } from "react/jsx-runtime";
2
- import { useFloating as oe, autoUpdate as ce, offset as de, flip as me, shift as pe, useClick as fe, useDismiss as ue, useRole as he, useInteractions as ge, FloatingPortal as be, FloatingFocusManager as xe } from "@floating-ui/react";
3
- import { IconChevronDown as ye } from "@tabler/icons-react";
4
- import { useId as ve, useState as z, useMemo as S, useEffect as Ne } from "react";
5
- import { Label as De } from "../Label/Label.js";
6
- import { StaticIconButton as P } from "../IconButton/IconButtonWrappers.js";
7
- import { DIAL_KIT_ICON_STROKE as Ce } from "../constants/icon.js";
8
- import { DIAL_ICON_SIZE as Le } from "../../../constants/icon.js";
9
- import { CalendarMode as D } from "../../../types/calendar.js";
10
- import { ElementSize as W } from "../../../types/size.js";
11
- import { useThemeScope as Ie } from "../ThemeScope/ThemeScope.js";
1
+ import { jsx as e, jsxs as d, Fragment as A } from "react/jsx-runtime";
2
+ import { useFloating as X, autoUpdate as ee, offset as te, flip as ae, shift as le, useDismiss as ne, useRole as se, useInteractions as re, FloatingPortal as ie, FloatingFocusManager as oe, useClick as Ce } from "@floating-ui/react";
3
+ import { IconChevronDown as De, IconClock as Ie } from "@tabler/icons-react";
4
+ import { useId as Fe, useState as _, useMemo as P, useEffect as Le } from "react";
5
+ import { Label as Se } from "../Label/Label.js";
6
+ import { StaticIconButton as W } from "../IconButton/IconButtonWrappers.js";
7
+ import { DIAL_KIT_ICON_STROKE as ce } from "../constants/icon.js";
8
+ import { DIAL_ICON_SIZE as de } from "../../../constants/icon.js";
9
+ import { CalendarMode as F } from "../../../types/calendar.js";
10
+ import { ElementSize as U } from "../../../types/size.js";
11
+ import { useThemeScope as me } from "../ThemeScope/ThemeScope.js";
12
12
  import { mergeClasses as i } from "../../../utils/merge-classes.js";
13
13
  import { getTimezoneLabel as Te } from "../../../utils/timezone.js";
14
- import { DEFAULT_CALENDAR_LOCALE as Se, calendarModeDefaultPlaceholder as Fe, calendarFieldIconClassName as Me, calendarNavIcons as U, calendarDaySelectedClassName as we, calendarDayTodayClassName as Oe, calendarDayOutsideClassName as ke, calendarDayButtonBaseClassName as Ae, calendarIcon as _e, calendarFieldDisabledClassName as Q, calendarFieldInvalidClassName as X, calendarFieldBaseClassName as ee, calendarPopoverClassName as Ee } from "./constants.js";
15
- import { getWeekdayShortLabels as Be, getWeekdayOptions as ze, getMonthGrid as Re, formatTimeLabel as M, formatMonthLabel as $e, isSameDay as Y, isDateOutOfRange as G, formatDayAriaLabel as je, sanitizeTimeInput as Ve, isCompleteTimeString as Ke, setTimeOnDate as Z, formatDateLabel as q } from "./utils.js";
16
- import { DIAL_KIT_CLASS as B } from "../../../constants/public-class-names.js";
17
- const H = ({
18
- id: o,
19
- disabled: a,
20
- invalid: f,
21
- trigger: C,
22
- panelClassName: c,
23
- fieldClassName: L,
24
- panel: x,
25
- labelledBy: y,
26
- panelLabel: I
14
+ import { DEFAULT_CALENDAR_LOCALE as Me, calendarModeDefaultPlaceholder as Oe, calendarFieldIconClassName as ke, calendarNavIcons as Y, calendarDaySelectedClassName as we, calendarDayTodayClassName as Pe, calendarDayOutsideClassName as Ae, calendarDayButtonBaseClassName as Ee, calendarIcon as _e, calendarFieldDisabledClassName as pe, calendarFieldInvalidClassName as fe, calendarFieldBaseClassName as ue, timePickerButtonClassName as Be, timePickerPopoverClassName as Re, calendarPopoverClassName as ze } from "./constants.js";
15
+ import { getWeekdayShortLabels as $e, getWeekdayOptions as je, getMonthGrid as Ve, formatTimeLabel as E, formatMonthLabel as Ke, isSameDay as G, isDateOutOfRange as Z, formatDayAriaLabel as We, sanitizeTimeInput as Ue, isCompleteTimeString as Ye, setTimeOnDate as q, formatDateLabel as H } from "./utils.js";
16
+ import { DIAL_KIT_CLASS as z } from "../../../constants/public-class-names.js";
17
+ import { TimePickerPanel as Ge } from "./TimePickerPanel.js";
18
+ const J = ({
19
+ id: m,
20
+ disabled: l,
21
+ invalid: g,
22
+ trigger: L,
23
+ panelClassName: r,
24
+ fieldClassName: T,
25
+ panel: N,
26
+ labelledBy: C,
27
+ panelLabel: M
27
28
  }) => {
28
- const u = Ie(), [h, v] = z(!1), { refs: l, floatingStyles: g, context: m } = oe({
29
- open: h,
30
- onOpenChange: (k) => v(a ? !1 : k),
29
+ const b = me(), [v, p] = _(!1), { refs: n, floatingStyles: x, context: f } = X({
30
+ open: v,
31
+ onOpenChange: (S) => p(l ? !1 : S),
31
32
  placement: "bottom-start",
32
- whileElementsMounted: ce,
33
- middleware: [de(8), me({ padding: 8 }), pe({ padding: 8 })]
34
- }), s = fe(m, { enabled: !a }), n = ue(m), O = he(m, { role: "dialog" }), { getReferenceProps: b, getFloatingProps: F } = ge([
35
- s,
36
- n,
37
- O
33
+ whileElementsMounted: ee,
34
+ middleware: [te(8), ae({ padding: 8 }), le({ padding: 8 })]
35
+ }), D = Ce(f, { enabled: !l }), h = ne(f), a = se(f, { role: "dialog" }), { getReferenceProps: O, getFloatingProps: o } = re([
36
+ D,
37
+ h,
38
+ a
38
39
  ]);
39
- return /* @__PURE__ */ d(w, { children: [
40
+ return /* @__PURE__ */ d(A, { children: [
40
41
  /* @__PURE__ */ e(
41
42
  "div",
42
43
  {
43
- id: o,
44
- ref: l.setReference,
44
+ id: m,
45
+ ref: n.setReference,
45
46
  role: "button",
46
47
  "aria-haspopup": "dialog",
47
- "aria-expanded": h,
48
- "aria-disabled": a,
49
- "aria-labelledby": y,
50
- tabIndex: a ? -1 : 0,
48
+ "aria-expanded": v,
49
+ "aria-disabled": l,
50
+ "aria-labelledby": C,
51
+ tabIndex: l ? -1 : 0,
51
52
  className: i(
52
- ee,
53
+ ue,
53
54
  "focus-visible:outline focus-visible:outline-focus",
54
- f && X,
55
- a && Q,
56
- L
55
+ g && fe,
56
+ l && pe,
57
+ T
57
58
  ),
58
- ...b(),
59
- children: C
59
+ ...O(),
60
+ children: L
60
61
  }
61
62
  ),
62
- h && /* @__PURE__ */ e(be, { children: /* @__PURE__ */ e(
63
- xe,
63
+ v && /* @__PURE__ */ e(ie, { children: /* @__PURE__ */ e(
64
+ oe,
64
65
  {
65
- context: m,
66
+ context: f,
66
67
  modal: !1,
67
68
  initialFocus: -1,
68
69
  returnFocus: !0,
69
70
  children: /* @__PURE__ */ e(
70
71
  "div",
71
72
  {
72
- ref: l.setFloating,
73
- style: g,
74
- "aria-label": I,
73
+ ref: n.setFloating,
74
+ style: x,
75
+ "aria-label": M,
75
76
  className: i(
76
- Ee,
77
- u,
78
- c
77
+ ze,
78
+ b,
79
+ r
79
80
  ),
80
- ...F(),
81
- children: x(() => v(!1))
81
+ ...o(),
82
+ children: N(() => p(!1))
82
83
  }
83
84
  )
84
85
  }
85
86
  ) })
86
87
  ] });
87
- }, J = ({
88
- id: o,
89
- value: a,
90
- onChange: f,
91
- onBlur: C,
92
- disabled: c,
93
- invalid: L,
94
- className: x,
95
- ariaLabel: y,
96
- placeholder: I = "--:--",
97
- timezoneLabel: u,
98
- timezoneLabelClassName: h
88
+ }, Q = ({
89
+ id: m,
90
+ value: l,
91
+ onChange: g,
92
+ onBlur: L,
93
+ disabled: r,
94
+ invalid: T,
95
+ className: N,
96
+ ariaLabel: C,
97
+ placeholder: M = "--:--",
98
+ timezoneLabel: b,
99
+ timezoneLabelClassName: v,
100
+ picker: p = !1
99
101
  }) => {
100
- const [v, l] = z(a);
101
- Ne(() => {
102
- l(a);
103
- }, [a]);
104
- const g = /* @__PURE__ */ e(
102
+ const [n, x] = _(l), [f, D] = _(!1), h = me(), { refs: a, floatingStyles: O, context: o } = X({
103
+ open: f,
104
+ onOpenChange: (c) => D(r ? !1 : c),
105
+ placement: "bottom-start",
106
+ whileElementsMounted: ee,
107
+ middleware: [te(8), ae({ padding: 8 }), le({ padding: 8 })]
108
+ }), S = ne(o), B = se(o, { role: "dialog" }), { getFloatingProps: k } = re([S, B]);
109
+ Le(() => {
110
+ x(l);
111
+ }, [l]);
112
+ const w = /* @__PURE__ */ e(
105
113
  "input",
106
114
  {
107
- id: o,
115
+ id: m,
108
116
  type: "text",
109
117
  inputMode: "numeric",
110
118
  autoComplete: "off",
111
- "aria-label": y,
112
- placeholder: I,
113
- disabled: c,
114
- value: v,
115
- onChange: (m) => {
116
- const s = Ve(m.target.value);
117
- l(s), Ke(s) && f(s);
119
+ "aria-label": C,
120
+ placeholder: M,
121
+ disabled: r,
122
+ value: n,
123
+ onChange: (c) => {
124
+ const u = Ue(c.target.value);
125
+ x(u), Ye(u) && g(u);
118
126
  },
119
- onBlur: C,
127
+ onBlur: L,
120
128
  className: i(
121
- ee,
122
- L && X,
123
- c && Q,
124
- x
129
+ ue,
130
+ T && fe,
131
+ r && pe,
132
+ p && "pe-12",
133
+ N
125
134
  )
126
135
  }
127
136
  );
128
- return u ? /* @__PURE__ */ d("div", { className: "relative w-full", children: [
129
- g,
130
- /* @__PURE__ */ e(
131
- "span",
132
- {
133
- className: i(
134
- "dial-small-paragraph-text pointer-events-none absolute end-4 top-1/2 -translate-y-1/2 truncate text-secondary",
135
- h
137
+ return !b && !p ? w : /* @__PURE__ */ d(
138
+ "div",
139
+ {
140
+ ref: p ? a.setReference : void 0,
141
+ className: "relative w-full",
142
+ children: [
143
+ w,
144
+ b && /* @__PURE__ */ e(
145
+ "span",
146
+ {
147
+ className: i(
148
+ "dial-small-paragraph-text pointer-events-none absolute end-4 top-1/2 -translate-y-1/2 truncate text-secondary",
149
+ p && "end-12",
150
+ v
151
+ ),
152
+ children: b
153
+ }
136
154
  ),
137
- children: u
138
- }
139
- )
140
- ] }) : g;
141
- }, rt = ({
142
- mode: o = D.Date,
143
- value: a,
144
- onChange: f,
145
- onBlur: C,
146
- labelProps: c,
147
- placeholder: L,
148
- disabled: x = !1,
149
- invalid: y = !1,
150
- id: I,
151
- className: u,
152
- minDate: h,
153
- maxDate: v,
154
- locale: l = Se,
155
- fieldClassName: g,
156
- showTimezone: m = !1
155
+ p && /* @__PURE__ */ d(A, { children: [
156
+ /* @__PURE__ */ e(
157
+ "button",
158
+ {
159
+ type: "button",
160
+ "aria-label": "Choose time",
161
+ "aria-haspopup": "dialog",
162
+ "aria-expanded": f,
163
+ disabled: r,
164
+ className: Be,
165
+ onClick: () => D((c) => !c),
166
+ children: /* @__PURE__ */ e(
167
+ Ie,
168
+ {
169
+ size: de.MD,
170
+ stroke: ce,
171
+ "aria-hidden": "true"
172
+ }
173
+ )
174
+ }
175
+ ),
176
+ f && /* @__PURE__ */ e(ie, { children: /* @__PURE__ */ e(
177
+ oe,
178
+ {
179
+ context: o,
180
+ modal: !1,
181
+ initialFocus: -1,
182
+ returnFocus: !0,
183
+ children: /* @__PURE__ */ e(
184
+ "div",
185
+ {
186
+ ref: a.setFloating,
187
+ style: O,
188
+ "aria-label": "Choose time",
189
+ className: i(
190
+ Re,
191
+ h
192
+ ),
193
+ ...k(),
194
+ children: /* @__PURE__ */ e(
195
+ Ge,
196
+ {
197
+ value: n,
198
+ onSelect: (c, u) => {
199
+ x(c), g(c), u && D(!1);
200
+ }
201
+ }
202
+ )
203
+ }
204
+ )
205
+ }
206
+ ) })
207
+ ] })
208
+ ]
209
+ }
210
+ );
211
+ }, mt = ({
212
+ mode: m = F.Date,
213
+ value: l,
214
+ onChange: g,
215
+ onBlur: L,
216
+ labelProps: r,
217
+ placeholder: T,
218
+ disabled: N = !1,
219
+ invalid: C = !1,
220
+ id: M,
221
+ className: b,
222
+ minDate: v,
223
+ maxDate: p,
224
+ locale: n = Me,
225
+ fieldClassName: x,
226
+ showTimezone: f = !1,
227
+ showTimePicker: D = !0
157
228
  }) => {
158
- const s = L ?? Fe[o], n = a instanceof Date ? a : null, O = ve(), b = I ?? O, F = c?.id ?? `${b}-label`, k = !!c?.label, A = typeof c?.label == "string" ? c.label : void 0, R = k ? `${F} ${b}` : void 0, _ = c ? /* @__PURE__ */ e(De, { ...c, id: F, htmlFor: b }) : null, [T, te] = z(
159
- () => n ?? /* @__PURE__ */ new Date()
160
- ), ae = S(() => /* @__PURE__ */ new Date(), []), E = S(
161
- () => m ? Te({ locale: l }) : null,
162
- [m, l]
163
- ), le = S(
164
- () => Be(l),
165
- [l]
166
- ), $ = S(() => ze(l), [l]), ne = S(
167
- () => Re(T.getFullYear(), T.getMonth()),
168
- [T]
169
- ), j = (r) => {
170
- te(
171
- (t) => new Date(t.getFullYear(), t.getMonth() + r, 1)
229
+ const h = T ?? Oe[m], a = l instanceof Date ? l : null, O = Fe(), o = M ?? O, S = r?.id ?? `${o}-label`, B = !!r?.label, k = typeof r?.label == "string" ? r.label : void 0, w = B ? `${S} ${o}` : void 0, c = r ? /* @__PURE__ */ e(Se, { ...r, id: S, htmlFor: o }) : null, [u, he] = _(
230
+ () => a ?? /* @__PURE__ */ new Date()
231
+ ), ge = P(() => /* @__PURE__ */ new Date(), []), R = P(
232
+ () => f ? Te({ locale: n }) : null,
233
+ [f, n]
234
+ ), be = P(
235
+ () => $e(n),
236
+ [n]
237
+ ), $ = P(() => je(n), [n]), xe = P(
238
+ () => Ve(u.getFullYear(), u.getMonth()),
239
+ [u]
240
+ ), j = (s) => {
241
+ he(
242
+ (t) => new Date(t.getFullYear(), t.getMonth() + s, 1)
172
243
  );
173
- }, re = (r, t) => {
174
- if (G(r, h, v)) return;
175
- const N = o === D.DateTime && n ? Z(r, M(n)) : r;
176
- f?.(N), o === D.Date && t();
177
- }, se = (r) => {
178
- f?.(Z(n ?? /* @__PURE__ */ new Date(), r));
179
- }, ie = () => n ? o === D.DateTime ? `${q(n, l)}, ${M(n)}` : q(n, l) : s;
180
- if (o === D.Time) {
181
- const r = typeof a == "string" ? a : n ? M(n) : "";
244
+ }, ye = (s, t) => {
245
+ if (Z(s, v, p)) return;
246
+ const I = m === F.DateTime && a ? q(s, E(a)) : s;
247
+ g?.(I), m === F.Date && t();
248
+ }, ve = (s) => {
249
+ g?.(q(a ?? /* @__PURE__ */ new Date(), s));
250
+ }, Ne = () => a ? m === F.DateTime ? `${H(a, n)}, ${E(a)}` : H(a, n) : h;
251
+ if (m === F.Time) {
252
+ const s = typeof l == "string" ? l : a ? E(a) : "";
182
253
  return /* @__PURE__ */ d(
183
254
  "div",
184
255
  {
185
256
  className: i(
186
257
  "flex flex-col gap-y-3",
187
- u,
188
- B.calendar
258
+ b,
259
+ z.calendar
189
260
  ),
190
261
  children: [
191
- _,
262
+ c,
192
263
  /* @__PURE__ */ e(
193
- J,
264
+ Q,
194
265
  {
195
- id: b,
196
- value: r,
197
- onChange: (t) => f?.(t),
198
- onBlur: C,
199
- disabled: x,
200
- invalid: y,
201
- placeholder: s,
202
- className: g,
203
- timezoneLabel: E
266
+ id: o,
267
+ value: s,
268
+ onChange: (t) => g?.(t),
269
+ onBlur: L,
270
+ disabled: N,
271
+ invalid: C,
272
+ placeholder: h,
273
+ className: x,
274
+ timezoneLabel: R,
275
+ picker: D
204
276
  }
205
277
  )
206
278
  ]
207
279
  }
208
280
  );
209
281
  }
210
- if (o === D.Weekday) {
211
- const r = typeof a == "string" ? a : void 0, t = $.find((N) => N.value === r);
282
+ if (m === F.Weekday) {
283
+ const s = typeof l == "string" ? l : void 0, t = $.find((I) => I.value === s);
212
284
  return /* @__PURE__ */ d(
213
285
  "div",
214
286
  {
215
287
  className: i(
216
288
  "flex flex-col gap-y-3",
217
- u,
218
- B.calendar
289
+ b,
290
+ z.calendar
219
291
  ),
220
292
  children: [
221
- _,
293
+ c,
222
294
  /* @__PURE__ */ e(
223
- H,
295
+ J,
224
296
  {
225
- id: b,
226
- disabled: x,
227
- invalid: y,
228
- labelledBy: R,
229
- panelLabel: A ?? s,
230
- fieldClassName: g,
231
- trigger: /* @__PURE__ */ d(w, { children: [
297
+ id: o,
298
+ disabled: N,
299
+ invalid: C,
300
+ labelledBy: w,
301
+ panelLabel: k ?? h,
302
+ fieldClassName: x,
303
+ trigger: /* @__PURE__ */ d(A, { children: [
232
304
  /* @__PURE__ */ e(
233
305
  "span",
234
306
  {
@@ -236,42 +308,42 @@ const H = ({
236
308
  "truncate",
237
309
  !t && "text-secondary"
238
310
  ),
239
- children: t?.label ?? s
311
+ children: t?.label ?? h
240
312
  }
241
313
  ),
242
314
  /* @__PURE__ */ e(
243
- ye,
315
+ De,
244
316
  {
245
- size: Le.MD,
246
- stroke: Ce,
317
+ size: de.MD,
318
+ stroke: ce,
247
319
  "aria-hidden": "true",
248
- className: Me
320
+ className: ke
249
321
  }
250
322
  )
251
323
  ] }),
252
- panel: (N) => /* @__PURE__ */ e(
324
+ panel: (I) => /* @__PURE__ */ e(
253
325
  "div",
254
326
  {
255
327
  role: "listbox",
256
- "aria-label": A ?? s,
328
+ "aria-label": k ?? h,
257
329
  className: "flex flex-col gap-0.5",
258
- children: $.map((p) => /* @__PURE__ */ e(
330
+ children: $.map((y) => /* @__PURE__ */ e(
259
331
  "button",
260
332
  {
261
333
  type: "button",
262
334
  role: "option",
263
- "aria-selected": p.value === r,
335
+ "aria-selected": y.value === s,
264
336
  className: i(
265
337
  "flex w-full items-center rounded-lg px-3 py-2 text-left dial-small-text text-primary hover:bg-control-accent-alpha-hover",
266
338
  "focus-visible:outline focus-visible:outline-focus",
267
- p.value === r && "bg-control-accent-alpha-hover"
339
+ y.value === s && "bg-control-accent-alpha-hover"
268
340
  ),
269
341
  onClick: () => {
270
- f?.(p.value), N();
342
+ g?.(y.value), I();
271
343
  },
272
- children: p.label
344
+ children: y.label
273
345
  },
274
- p.value
346
+ y.value
275
347
  ))
276
348
  }
277
349
  )
@@ -286,41 +358,41 @@ const H = ({
286
358
  {
287
359
  className: i(
288
360
  "flex flex-col gap-y-3",
289
- u,
290
- B.calendar
361
+ b,
362
+ z.calendar
291
363
  ),
292
364
  children: [
293
- _,
365
+ c,
294
366
  /* @__PURE__ */ e(
295
- H,
367
+ J,
296
368
  {
297
- id: b,
298
- disabled: x,
299
- invalid: y,
300
- labelledBy: R,
301
- panelLabel: A ?? s,
302
- fieldClassName: g,
303
- trigger: /* @__PURE__ */ d(w, { children: [
369
+ id: o,
370
+ disabled: N,
371
+ invalid: C,
372
+ labelledBy: w,
373
+ panelLabel: k ?? h,
374
+ fieldClassName: x,
375
+ trigger: /* @__PURE__ */ d(A, { children: [
304
376
  /* @__PURE__ */ e(
305
377
  "span",
306
378
  {
307
379
  className: i(
308
380
  "truncate",
309
- !n && "text-secondary"
381
+ !a && "text-secondary"
310
382
  ),
311
- children: ie()
383
+ children: Ne()
312
384
  }
313
385
  ),
314
386
  _e
315
387
  ] }),
316
- panel: (r) => /* @__PURE__ */ d(w, { children: [
388
+ panel: (s) => /* @__PURE__ */ d(A, { children: [
317
389
  /* @__PURE__ */ d("div", { className: "flex items-center justify-between", children: [
318
390
  /* @__PURE__ */ e(
319
- P,
391
+ W,
320
392
  {
321
393
  "aria-label": "Previous month",
322
- icon: U.prev,
323
- size: W.Small,
394
+ icon: Y.prev,
395
+ size: U.Small,
324
396
  onClick: () => j(-1)
325
397
  }
326
398
  ),
@@ -329,21 +401,21 @@ const H = ({
329
401
  {
330
402
  className: "dial-small-semi-text text-primary",
331
403
  "aria-live": "polite",
332
- children: $e(T, l)
404
+ children: Ke(u, n)
333
405
  }
334
406
  ),
335
407
  /* @__PURE__ */ e(
336
- P,
408
+ W,
337
409
  {
338
410
  "aria-label": "Next month",
339
- icon: U.next,
340
- size: W.Small,
411
+ icon: Y.next,
412
+ size: U.Small,
341
413
  onClick: () => j(1)
342
414
  }
343
415
  )
344
416
  ] }),
345
417
  /* @__PURE__ */ d("div", { className: "grid grid-cols-7 gap-y-1 text-center", children: [
346
- le.map((t) => /* @__PURE__ */ e(
418
+ be.map((t) => /* @__PURE__ */ e(
347
419
  "div",
348
420
  {
349
421
  "aria-hidden": "true",
@@ -352,44 +424,44 @@ const H = ({
352
424
  },
353
425
  t
354
426
  )),
355
- ne.map((t) => {
356
- const N = t.getMonth() !== T.getMonth(), p = Y(t, n), V = Y(t, ae), K = G(t, h, v);
427
+ xe.map((t) => {
428
+ const I = t.getMonth() !== u.getMonth(), y = G(t, a), V = G(t, ge), K = Z(t, v, p);
357
429
  return /* @__PURE__ */ e(
358
430
  "button",
359
431
  {
360
432
  type: "button",
361
433
  disabled: K,
362
- "aria-label": je(t, l),
363
- "aria-pressed": p,
434
+ "aria-label": We(t, n),
435
+ "aria-pressed": y,
364
436
  "aria-current": V ? "date" : void 0,
365
437
  className: i(
366
- Ae,
367
- N && ke,
368
- V && !p && Oe,
369
- p && we,
438
+ Ee,
439
+ I && Ae,
440
+ V && !y && Pe,
441
+ y && we,
370
442
  K && "cursor-not-allowed opacity-40 hover:bg-transparent"
371
443
  ),
372
- onClick: () => re(t, r),
444
+ onClick: () => ye(t, s),
373
445
  children: t.getDate()
374
446
  },
375
447
  t.toISOString()
376
448
  );
377
449
  })
378
450
  ] }),
379
- o === D.DateTime && /* @__PURE__ */ d("div", { className: "flex items-center justify-between gap-3 border-t border-secondary pt-3", children: [
451
+ m === F.DateTime && /* @__PURE__ */ d("div", { className: "flex items-center justify-between gap-3 border-t border-secondary pt-3", children: [
380
452
  /* @__PURE__ */ e("span", { className: "dial-small-text text-primary", children: "Time" }),
381
453
  /* @__PURE__ */ e(
382
- J,
454
+ Q,
383
455
  {
384
456
  ariaLabel: "Time",
385
- value: n ? M(n) : "",
386
- onChange: se,
387
- onBlur: C,
457
+ value: a ? E(a) : "",
458
+ onChange: ve,
459
+ onBlur: L,
388
460
  className: i(
389
- !E && "w-[120px]",
461
+ !R && "w-[120px]",
390
462
  "px-3 py-1.5"
391
463
  ),
392
- timezoneLabel: E,
464
+ timezoneLabel: R,
393
465
  timezoneLabelClassName: "end-3 max-w-[60%]"
394
466
  }
395
467
  )
@@ -402,5 +474,5 @@ const H = ({
402
474
  );
403
475
  };
404
476
  export {
405
- rt as Calendar
477
+ mt as Calendar
406
478
  };