@epam/ai-dial-ui-kit 0.2.0-rc.22 → 0.2.0-rc.23

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.
@@ -1,31 +1,31 @@
1
- import { jsx as r, jsxs as f, Fragment as ae } from "react/jsx-runtime";
2
- import i from "classnames";
3
- import { IconCircleCheck as le, IconAlertTriangle as oe, IconAlertCircle as ie, IconInfoCircle as ce, IconX as M, IconLoader as de, IconMinus as ue, IconCheck as U, IconExclamationCircle as me, IconClipboardX as fe, IconEyeOff as pe, IconEye as xe, IconSearch as he } from "@tabler/icons-react";
4
- import { createContext as ge, useState as _, useRef as be, useMemo as ye, useContext as Ce, forwardRef as $, isValidElement as ve, cloneElement as Ne, useCallback as S, useEffect as we } from "react";
5
- import { useFloating as G, offset as De, flip as Ie, shift as ke, arrow as Re, autoUpdate as Se, useHover as Fe, useFocus as Ee, useDismiss as K, useRole as Z, useInteractions as X, useMergeRefs as q, FloatingPortal as Q, FloatingArrow as Te, FloatingOverlay as Pe, FloatingFocusManager as Ae } from "@floating-ui/react";
6
- const W = ({ errorText: e }) => e && /* @__PURE__ */ r("span", { className: "text-error dial-tiny mt-1", children: e }), O = ({
1
+ import { jsx as r, jsxs as f, Fragment as oe } from "react/jsx-runtime";
2
+ import c from "classnames";
3
+ import { IconCircleCheck as le, IconAlertTriangle as ie, IconAlertCircle as ce, IconInfoCircle as de, IconX as W, IconLoader as ue, IconMinus as me, IconCheck as $, IconExclamationCircle as fe, IconClipboardX as pe, IconChevronsLeft as xe, IconChevronsRight as he, IconEyeOff as ge, IconEye as be, IconSearch as ye } from "@tabler/icons-react";
4
+ import { createContext as Ce, useState as T, useRef as ve, useMemo as Ne, useContext as we, forwardRef as U, isValidElement as De, cloneElement as Ie, useCallback as S, useEffect as ke } from "react";
5
+ import { useFloating as G, offset as Re, flip as Se, shift as Fe, arrow as Ee, autoUpdate as Te, useHover as Pe, useFocus as Le, useDismiss as K, useRole as Z, useInteractions as X, useMergeRefs as q, FloatingPortal as Q, FloatingArrow as Ae, FloatingOverlay as Oe, FloatingFocusManager as ze } from "@floating-ui/react";
6
+ const _ = ({ errorText: e }) => e && /* @__PURE__ */ r("span", { className: "text-error dial-tiny mt-1", children: e }), j = ({
7
7
  fieldTitle: e,
8
8
  htmlFor: n,
9
9
  optional: t,
10
- optionalText: s,
11
- cssClass: a
10
+ optionalText: a,
11
+ cssClass: s
12
12
  }) => e ? /* @__PURE__ */ f(
13
13
  "label",
14
14
  {
15
- className: i(
15
+ className: c(
16
16
  "dial-tiny text-secondary",
17
- a,
18
- !a?.includes("mb") && "mb-2"
17
+ s,
18
+ !s?.includes("mb") && "mb-2"
19
19
  ),
20
20
  htmlFor: n,
21
21
  children: [
22
22
  /* @__PURE__ */ r("span", { className: "min-h-4", children: e }),
23
- t && /* @__PURE__ */ r("span", { className: "ml-1", children: s ?? "(Optional)" })
23
+ t && /* @__PURE__ */ r("span", { className: "ml-1", children: a ?? "(Optional)" })
24
24
  ]
25
25
  }
26
- ) : null, D = ({ icon: e, className: n }) => e ? /* @__PURE__ */ r("span", { className: i("flex-shrink-0", n), children: e }) : null;
26
+ ) : null, D = ({ icon: e, className: n }) => e ? /* @__PURE__ */ r("span", { className: c("flex-shrink-0", n), children: e }) : null;
27
27
  var v = /* @__PURE__ */ ((e) => (e.Primary = "primary", e.Secondary = "secondary", e.Tertiary = "tertiary", e.Danger = "danger", e))(v || {});
28
- const Le = {
28
+ const Be = {
29
29
  [v.Primary]: "dial-primary-button",
30
30
  [v.Secondary]: "dial-secondary-button",
31
31
  [v.Tertiary]: "dial-tertiary-button",
@@ -34,188 +34,188 @@ const Le = {
34
34
  title: e,
35
35
  variant: n,
36
36
  cssClass: t,
37
- ref: s,
38
- onClick: a,
39
- disable: l,
40
- iconAfter: o,
41
- iconBefore: c,
42
- hideTitleOnMobile: d,
43
- ariaLabel: u
37
+ ref: a,
38
+ onClick: s,
39
+ disable: o,
40
+ iconAfter: l,
41
+ iconBefore: d,
42
+ hideTitleOnMobile: u,
43
+ ariaLabel: i
44
44
  }) => {
45
- const m = i(
45
+ const m = c(
46
46
  "dial-small-semi",
47
- o ? "mr-2" : "",
48
- c ? "ml-2" : "",
49
- d ? "hidden sm:inline" : "inline"
50
- ), x = i(
51
- n && Le[n],
47
+ l ? "mr-2" : "",
48
+ d ? "ml-2" : "",
49
+ u ? "hidden sm:inline" : "inline"
50
+ ), p = c(
51
+ n && Be[n],
52
52
  t,
53
53
  "focus-visible:outline outline-offset-0"
54
54
  );
55
55
  return /* @__PURE__ */ f(
56
56
  "button",
57
57
  {
58
- ref: s,
58
+ ref: a,
59
59
  type: "button",
60
- className: x,
61
- onClick: (h) => a?.(h),
62
- disabled: l,
63
- "aria-label": e || u,
60
+ className: p,
61
+ onClick: (x) => s?.(x),
62
+ disabled: o,
63
+ "aria-label": e || i,
64
64
  children: [
65
- /* @__PURE__ */ r(D, { icon: c }),
65
+ /* @__PURE__ */ r(D, { icon: d }),
66
66
  e && /* @__PURE__ */ r("span", { className: m, children: e }),
67
- /* @__PURE__ */ r(D, { icon: o })
67
+ /* @__PURE__ */ r(D, { icon: l })
68
68
  ]
69
69
  }
70
70
  );
71
71
  };
72
72
  var k = /* @__PURE__ */ ((e) => (e.Info = "info", e.Success = "success", e.Warning = "warning", e.Error = "error", e))(k || {});
73
- const ze = {
74
- info: /* @__PURE__ */ r(ce, { size: 24, stroke: 2 }),
75
- error: /* @__PURE__ */ r(ie, { size: 24, stroke: 2 }),
76
- warning: /* @__PURE__ */ r(oe, { size: 24, stroke: 2 }),
73
+ const je = {
74
+ info: /* @__PURE__ */ r(de, { size: 24, stroke: 2 }),
75
+ error: /* @__PURE__ */ r(ce, { size: 24, stroke: 2 }),
76
+ warning: /* @__PURE__ */ r(ie, { size: 24, stroke: 2 }),
77
77
  success: /* @__PURE__ */ r(le, { size: 24, stroke: 2 })
78
- }, Be = {
78
+ }, Ve = {
79
79
  [k.Info]: "bg-info border-info text-info",
80
80
  [k.Success]: "bg-success border-success text-success",
81
81
  [k.Warning]: "bg-warning border-warning text-warning",
82
82
  [k.Error]: "bg-error border-error text-error"
83
- }, Oe = "items-center justify-between gap-2 p-3 border border-solid dial-small-150 rounded flex", kr = ({
83
+ }, Me = "items-center justify-between gap-2 p-3 border border-solid dial-small-150 rounded flex", Fr = ({
84
84
  variant: e = k.Info,
85
85
  message: n,
86
86
  cssClass: t,
87
- closable: s = !1,
88
- onClose: a
87
+ closable: a = !1,
88
+ onClose: s
89
89
  }) => /* @__PURE__ */ f(
90
90
  "div",
91
91
  {
92
92
  role: "alert",
93
- className: i(
94
- Oe,
95
- Be[e],
93
+ className: c(
94
+ Me,
95
+ Ve[e],
96
96
  t
97
97
  ),
98
98
  children: [
99
99
  /* @__PURE__ */ f("div", { className: "flex items-center gap-2", children: [
100
- /* @__PURE__ */ r(D, { icon: ze[e] }),
100
+ /* @__PURE__ */ r(D, { icon: je[e] }),
101
101
  /* @__PURE__ */ r("div", { className: "text-primary", children: n })
102
102
  ] }),
103
- s && /* @__PURE__ */ r(
103
+ a && /* @__PURE__ */ r(
104
104
  P,
105
105
  {
106
106
  cssClass: "ml-2 text-secondary hover:text-primary",
107
107
  ariaLabel: "Close alert",
108
- iconBefore: /* @__PURE__ */ r(M, { size: 16 }),
109
- onClick: (l) => a?.(l)
108
+ iconBefore: /* @__PURE__ */ r(W, { size: 16 }),
109
+ onClick: (o) => s?.(o)
110
110
  }
111
111
  )
112
112
  ]
113
113
  }
114
- ), Ve = "flex items-center justify-center text-secondary", je = "shrink-0 grow-0 basis-auto animate-spin-steps", Me = ({
114
+ ), We = "flex items-center justify-center text-secondary", _e = "shrink-0 grow-0 basis-auto animate-spin-steps", He = ({
115
115
  size: e = 18,
116
116
  cssClass: n,
117
117
  iconClass: t,
118
- fullWidth: s = !0,
119
- ariaLabel: a = "Loading"
118
+ fullWidth: a = !0,
119
+ ariaLabel: s = "Loading"
120
120
  }) => /* @__PURE__ */ r(
121
121
  "div",
122
122
  {
123
123
  role: "status",
124
- "aria-label": a,
125
- className: i({
126
- [Ve]: !0,
127
- "w-full h-full": s,
124
+ "aria-label": s,
125
+ className: c({
126
+ [We]: !0,
127
+ "w-full h-full": a,
128
128
  [n || ""]: !!n
129
129
  }),
130
130
  children: /* @__PURE__ */ r(
131
131
  D,
132
132
  {
133
133
  icon: /* @__PURE__ */ r(
134
- de,
134
+ ue,
135
135
  {
136
136
  width: e,
137
137
  height: e,
138
- className: i(je, t)
138
+ className: c(_e, t)
139
139
  }
140
140
  )
141
141
  }
142
142
  )
143
143
  }
144
- ), _e = 7, We = 2, Y = ge(null), J = () => {
145
- const e = Ce(Y);
144
+ ), $e = 7, Ue = 2, Y = Ce(null), J = () => {
145
+ const e = we(Y);
146
146
  if (e == null)
147
147
  throw new Error("Tooltip components must be wrapped in <Tooltip />");
148
148
  return e;
149
- }, He = ({
149
+ }, Ge = ({
150
150
  initialOpen: e = !1,
151
151
  placement: n = "bottom",
152
152
  isTriggerClickable: t = !1,
153
- open: s,
154
- onOpenChange: a
153
+ open: a,
154
+ onOpenChange: s
155
155
  } = {}) => {
156
- const [l, o] = _(e), c = be(null), d = s ?? l, u = a ?? o, m = G({
156
+ const [o, l] = T(e), d = ve(null), u = a ?? o, i = s ?? l, m = G({
157
157
  placement: n,
158
- open: d,
159
- onOpenChange: u,
160
- whileElementsMounted: Se,
158
+ open: u,
159
+ onOpenChange: i,
160
+ whileElementsMounted: Te,
161
161
  middleware: [
162
- De(_e + We),
163
- Ie({
162
+ Re($e + Ue),
163
+ Se({
164
164
  crossAxis: n.includes("-"),
165
165
  fallbackAxisSideDirection: "start",
166
166
  padding: 5
167
167
  }),
168
- ke({ padding: 5 }),
169
- Re({
170
- element: c
168
+ Fe({ padding: 5 }),
169
+ Ee({
170
+ element: d
171
171
  })
172
172
  ]
173
- }), x = Fe(m.context, {
173
+ }), p = Pe(m.context, {
174
174
  move: !1,
175
- enabled: s == null,
175
+ enabled: a == null,
176
176
  mouseOnly: t,
177
177
  delay: { open: 500, close: 0 }
178
- }), h = Ee(m.context, {
179
- enabled: s == null
180
- }), g = K(m.context), y = Z(m.context, { role: "tooltip" }), p = X([x, h, g, y]);
181
- return ye(
178
+ }), x = Le(m.context, {
179
+ enabled: a == null
180
+ }), h = K(m.context), y = Z(m.context, { role: "tooltip" }), g = X([p, x, h, y]);
181
+ return Ne(
182
182
  () => ({
183
- open: d,
184
- setOpen: u,
185
- arrowRef: c,
186
- ...p,
183
+ open: u,
184
+ setOpen: i,
185
+ arrowRef: d,
186
+ ...g,
187
187
  ...m
188
188
  }),
189
- [d, u, p, m]
189
+ [u, i, g, m]
190
190
  );
191
- }, Ue = ({
191
+ }, Ke = ({
192
192
  children: e,
193
193
  ...n
194
194
  }) => {
195
- const t = He(n);
195
+ const t = Ge(n);
196
196
  return /* @__PURE__ */ r(Y.Provider, { value: t, children: e });
197
- }, $e = $(function({ style: n, ...t }, s) {
198
- const a = J(), l = q([a.refs.setFloating, s]);
199
- return a.open ? /* @__PURE__ */ r(Q, { id: "tooltip-portal", children: /* @__PURE__ */ f(
197
+ }, Ze = U(function({ style: n, ...t }, a) {
198
+ const s = J(), o = q([s.refs.setFloating, a]);
199
+ return s.open ? /* @__PURE__ */ r(Q, { id: "tooltip-portal", children: /* @__PURE__ */ f(
200
200
  "div",
201
201
  {
202
- ref: l,
202
+ ref: o,
203
203
  style: {
204
- ...a.floatingStyles,
204
+ ...s.floatingStyles,
205
205
  ...n
206
206
  },
207
- ...a.getFloatingProps(t),
208
- className: i(
207
+ ...s.getFloatingProps(t),
208
+ className: c(
209
209
  "z-[55] whitespace-pre-wrap rounded border border-primary bg-blackout px-2 py-1 dial-tiny shadow max-w-[300px]",
210
- a.getFloatingProps(t).className
210
+ s.getFloatingProps(t).className
211
211
  ),
212
212
  children: [
213
213
  t.children,
214
214
  /* @__PURE__ */ r(
215
- Te,
215
+ Ae,
216
216
  {
217
- ref: a.arrowRef,
218
- context: a.context,
217
+ ref: s.arrowRef,
218
+ context: s.context,
219
219
  fill: "currentColor",
220
220
  strokeWidth: 1,
221
221
  className: "stroke-primary w-2 text-[var(--bg-layer-0,_#000000)]"
@@ -224,21 +224,21 @@ const ze = {
224
224
  ]
225
225
  }
226
226
  ) }) : null;
227
- }), Ge = $(function({ children: n, asChild: t = !1, ...s }, a) {
228
- const l = J(), c = n && typeof n == "object" && "ref" in n && n.ref !== void 0 ? n.ref : void 0, d = q([l.refs.setReference, a, c]);
229
- return t && ve(n) ? Ne(
227
+ }), Xe = U(function({ children: n, asChild: t = !1, ...a }, s) {
228
+ const o = J(), d = n && typeof n == "object" && "ref" in n && n.ref !== void 0 ? n.ref : void 0, u = q([o.refs.setReference, s, d]);
229
+ return t && De(n) ? Ie(
230
230
  n,
231
- l.getReferenceProps({
232
- ref: d,
233
- ...s,
231
+ o.getReferenceProps({
232
+ ref: u,
233
+ ...a,
234
234
  ...n.props
235
235
  })
236
236
  ) : /* @__PURE__ */ r(
237
237
  "span",
238
238
  {
239
- ref: d,
240
- ...l.getReferenceProps(s),
241
- className: s.className ?? "dial-tooltip-trigger text-left",
239
+ ref: u,
240
+ ...o.getReferenceProps(a),
241
+ className: a.className ?? "dial-tooltip-trigger text-left",
242
242
  children: n
243
243
  }
244
244
  );
@@ -246,68 +246,68 @@ const ze = {
246
246
  hideTooltip: e,
247
247
  tooltip: n,
248
248
  children: t,
249
- triggerClassName: s,
250
- contentClassName: a,
251
- ...l
252
- }) => /* @__PURE__ */ f(Ue, { ...l, children: [
253
- /* @__PURE__ */ r(Ge, { className: i(s, "truncate"), children: t }),
249
+ triggerClassName: a,
250
+ contentClassName: s,
251
+ ...o
252
+ }) => /* @__PURE__ */ f(Ke, { ...o, children: [
253
+ /* @__PURE__ */ r(Xe, { className: c(a, "truncate"), children: t }),
254
254
  /* @__PURE__ */ r(
255
- $e,
255
+ Ze,
256
256
  {
257
- className: i(
257
+ className: c(
258
258
  "text-primary",
259
- a,
259
+ s,
260
260
  "max-w-[300px]",
261
261
  (e || !n) && "hidden"
262
262
  ),
263
263
  children: n
264
264
  }
265
265
  )
266
- ] }), Ke = 18, A = {
267
- size: Ke,
266
+ ] }), ee = 18, F = {
267
+ size: ee,
268
268
  stroke: 2
269
- }, Rr = ({
269
+ }, Er = ({
270
270
  label: e,
271
271
  id: n,
272
272
  checked: t,
273
- indeterminate: s,
274
- disabled: a,
275
- ariaLabel: l,
276
- onChange: o
273
+ indeterminate: a,
274
+ disabled: s,
275
+ ariaLabel: o,
276
+ onChange: l
277
277
  }) => {
278
- const c = S(
278
+ const d = S(
279
279
  (m) => {
280
- m.stopPropagation(), o?.(m.target.checked, n);
280
+ m.stopPropagation(), l?.(m.target.checked, n);
281
281
  },
282
- [o, n]
283
- ), d = i(
282
+ [l, n]
283
+ ), u = c(
284
284
  "flex flex-row items-center cursor-pointer text-accent-primary small-medium flex-1 min-w-0",
285
285
  `${t ? "" : 'before:content-[""] before:inline-block before:w-[18px] before:h-[18px] before:border before:border-hover before:rounded before:mr-2'}`,
286
- a ? "pointer-events-none text-secondary before:border-icon-secondary before:bg-layer-4" : ""
287
- ), u = i(
286
+ s ? "pointer-events-none text-secondary before:border-icon-secondary before:bg-layer-4" : ""
287
+ ), i = c(
288
288
  "mr-2 border rounded",
289
- a ? "bg-layer-4 border-icon-secondary" : ""
289
+ s ? "bg-layer-4 border-icon-secondary" : ""
290
290
  );
291
- return /* @__PURE__ */ f("label", { className: d, htmlFor: n, children: [
292
- t && (s ? /* @__PURE__ */ r(ue, { className: u, ...A }) : /* @__PURE__ */ r(U, { className: u, ...A })),
291
+ return /* @__PURE__ */ f("label", { className: u, htmlFor: n, children: [
292
+ t && (a ? /* @__PURE__ */ r(me, { className: i, ...F }) : /* @__PURE__ */ r($, { className: i, ...F })),
293
293
  e && /* @__PURE__ */ r(V, { tooltip: e, triggerClassName: "flex-1 min-w-0", children: /* @__PURE__ */ r("p", { className: "text-primary w-full truncate", children: e }) }),
294
294
  /* @__PURE__ */ r(
295
295
  "input",
296
296
  {
297
297
  type: "checkbox",
298
- onChange: c,
298
+ onChange: d,
299
299
  id: n,
300
300
  checked: t,
301
- "aria-checked": s ? "mixed" : t,
302
- "aria-disabled": a || void 0,
303
- "aria-label": e ? void 0 : l,
301
+ "aria-checked": a ? "mixed" : t,
302
+ "aria-disabled": s || void 0,
303
+ "aria-label": e ? void 0 : o,
304
304
  className: "invisible w-0 h-0"
305
305
  }
306
306
  )
307
307
  ] });
308
308
  };
309
309
  var C = /* @__PURE__ */ ((e) => (e.VALID = "valid", e.ERROR = "error", e))(C || {});
310
- const Ze = (e, n) => {
310
+ const qe = (e, n) => {
311
311
  if (n === e.id)
312
312
  switch (e.status) {
313
313
  case C.VALID:
@@ -325,7 +325,7 @@ const Ze = (e, n) => {
325
325
  default:
326
326
  return "border-primary text-secondary";
327
327
  }
328
- }, Xe = (e, n) => {
328
+ }, Qe = (e, n) => {
329
329
  if (n === e.id)
330
330
  switch (e.status) {
331
331
  case C.VALID:
@@ -343,71 +343,71 @@ const Ze = (e, n) => {
343
343
  default:
344
344
  return "bg-layer-4";
345
345
  }
346
- }, qe = ({
346
+ }, Ye = ({
347
347
  step: e,
348
348
  index: n,
349
349
  currentStep: t,
350
- onChangeStep: s
350
+ onChangeStep: a
351
351
  }) => {
352
- const a = "h-[32px] flex flex-1 min-w-[180px] items-center dial-tiny border-t-2 cursor-pointer", l = "w-[22px] h-[22px] flex justify-center items-center mr-2 rounded-full text-white", o = () => t === e.id && e.status === C.ERROR ? /* @__PURE__ */ r(me, { stroke: 2, size: 16 }) : t !== e.id && e.status === C.VALID ? /* @__PURE__ */ r(U, { stroke: 2, size: 16 }) : n + 1;
352
+ const s = "h-[32px] flex flex-1 min-w-[180px] items-center dial-tiny border-t-2 cursor-pointer", o = "w-[22px] h-[22px] flex justify-center items-center mr-2 rounded-full text-white", l = () => t === e.id && e.status === C.ERROR ? /* @__PURE__ */ r(fe, { stroke: 2, size: 16 }) : t !== e.id && e.status === C.VALID ? /* @__PURE__ */ r($, { stroke: 2, size: 16 }) : n + 1;
353
353
  return /* @__PURE__ */ f(
354
354
  "button",
355
355
  {
356
- className: i(a, Ze(e, t)),
357
- onClick: () => s(e.id),
356
+ className: c(s, qe(e, t)),
357
+ onClick: () => a(e.id),
358
358
  children: [
359
359
  /* @__PURE__ */ r(
360
360
  "span",
361
361
  {
362
- className: i(l, Xe(e, t)),
363
- children: o()
362
+ className: c(o, Qe(e, t)),
363
+ children: l()
364
364
  }
365
365
  ),
366
366
  /* @__PURE__ */ r("span", { children: e.name })
367
367
  ]
368
368
  }
369
369
  );
370
- }, Sr = ({
370
+ }, Tr = ({
371
371
  steps: e,
372
372
  currentStep: n,
373
373
  onChangeStep: t
374
374
  }) => {
375
- const s = (a) => {
376
- const l = e.findIndex((c) => c.id === n), o = e.findIndex((c) => c.id === a);
377
- (a !== n && e[l].status === C.VALID || o < l) && t(a);
375
+ const a = (s) => {
376
+ const o = e.findIndex((d) => d.id === n), l = e.findIndex((d) => d.id === s);
377
+ (s !== n && e[o].status === C.VALID || l < o) && t(s);
378
378
  };
379
- return /* @__PURE__ */ r("div", { id: "steps", className: "flex gap-x-3", children: e.map((a, l) => /* @__PURE__ */ r(
380
- qe,
379
+ return /* @__PURE__ */ r("div", { id: "steps", className: "flex gap-x-3", children: e.map((s, o) => /* @__PURE__ */ r(
380
+ Ye,
381
381
  {
382
382
  currentStep: n,
383
- onChangeStep: s,
384
- step: a,
385
- index: l
383
+ onChangeStep: a,
384
+ step: s,
385
+ index: o
386
386
  },
387
- a.id
387
+ s.id
388
388
  )) });
389
- }, Qe = ({
389
+ }, Je = ({
390
390
  name: e,
391
391
  value: n,
392
392
  title: t,
393
- description: s,
394
- checked: a = !1,
395
- inputId: l,
396
- cssClass: o,
397
- labelCssClass: c,
398
- disabled: d,
399
- onChange: u,
393
+ description: a,
394
+ checked: s = !1,
395
+ inputId: o,
396
+ cssClass: l,
397
+ labelCssClass: d,
398
+ disabled: u,
399
+ onChange: i,
400
400
  descriptionCssClass: m
401
401
  }) => {
402
- const x = `${l}-desc`, h = i(
402
+ const p = `${o}-desc`, x = c(
403
403
  "dial-small cursor-pointer",
404
- d ? "text-secondary" : "text-primary",
405
- c
406
- ), g = i(
404
+ u ? "text-secondary" : "text-primary",
405
+ d
406
+ ), h = c(
407
407
  "cursor-pointer dial-input-radio",
408
408
  t && "mr-2",
409
- o
410
- ), y = i("flex flex-col", !!s && "mb-2"), p = i(
409
+ l
410
+ ), y = c("flex flex-col", !!a && "mb-2"), g = c(
411
411
  "dial-tiny mt-2 ml-[26px] text-secondary",
412
412
  m
413
413
  );
@@ -417,115 +417,180 @@ const Ze = (e, n) => {
417
417
  "input",
418
418
  {
419
419
  type: "radio",
420
- id: l,
420
+ id: o,
421
421
  name: e,
422
422
  value: n,
423
- checked: a,
424
- disabled: d,
425
- "aria-describedby": a && s ? x : void 0,
426
- className: g,
423
+ checked: s,
424
+ disabled: u,
425
+ "aria-describedby": s && a ? p : void 0,
426
+ className: h,
427
427
  onChange: (w) => {
428
- d || w.target.checked && u?.(n);
428
+ u || w.target.checked && i?.(n);
429
429
  }
430
430
  }
431
431
  ),
432
- t ? /* @__PURE__ */ r("label", { className: h, htmlFor: l, children: t }) : null
432
+ t ? /* @__PURE__ */ r("label", { className: x, htmlFor: o, children: t }) : null
433
433
  ] }),
434
- a && s && /* @__PURE__ */ r("div", { id: x, className: p, children: s })
434
+ s && a && /* @__PURE__ */ r("div", { id: p, className: g, children: a })
435
435
  ] });
436
436
  };
437
- var j = /* @__PURE__ */ ((e) => (e.Row = "Row", e.Column = "Column", e))(j || {});
438
- const Ye = "flex flex-col gap-2", Je = "flex", er = "pb-1 mt-2", rr = {
439
- [j.Column]: "flex-col gap-y-3",
440
- [j.Row]: "flex-row gap-x-6"
441
- }, Fr = ({
437
+ var M = /* @__PURE__ */ ((e) => (e.Row = "Row", e.Column = "Column", e))(M || {});
438
+ const er = "flex flex-col gap-2", rr = "flex", nr = "pb-1 mt-2", tr = {
439
+ [M.Column]: "flex-col gap-y-3",
440
+ [M.Row]: "flex-row gap-x-6"
441
+ }, Pr = ({
442
442
  fieldTitle: e,
443
443
  radioCssClass: n,
444
444
  labelCssClass: t,
445
- disabled: s,
446
- elementId: a,
447
- radioButtons: l,
448
- activeRadioButton: o,
449
- orientation: c,
450
- onChange: d
451
- }) => /* @__PURE__ */ f("div", { className: Ye, children: [
452
- e && /* @__PURE__ */ r(O, { fieldTitle: e, htmlFor: a }),
445
+ disabled: a,
446
+ elementId: s,
447
+ radioButtons: o,
448
+ activeRadioButton: l,
449
+ orientation: d,
450
+ onChange: u
451
+ }) => /* @__PURE__ */ f("div", { className: er, children: [
452
+ e && /* @__PURE__ */ r(j, { fieldTitle: e, htmlFor: s }),
453
453
  /* @__PURE__ */ r(
454
454
  "div",
455
455
  {
456
456
  role: "radiogroup",
457
457
  "aria-label": e,
458
- "aria-disabled": s || void 0,
459
- className: i(
460
- Je,
461
- rr[c]
458
+ "aria-disabled": a || void 0,
459
+ className: c(
460
+ rr,
461
+ tr[d]
462
462
  ),
463
- children: l.map((u) => /* @__PURE__ */ f("div", { className: "flex flex-col", children: [
463
+ children: o.map((i) => /* @__PURE__ */ f("div", { className: "flex flex-col", children: [
464
464
  /* @__PURE__ */ r(
465
- Qe,
465
+ Je,
466
466
  {
467
- name: a,
468
- value: u.id,
469
- inputId: u.id,
470
- disabled: s,
467
+ name: s,
468
+ value: i.id,
469
+ inputId: i.id,
470
+ disabled: a,
471
471
  cssClass: n,
472
472
  labelCssClass: t,
473
- title: u.name,
474
- checked: u.id === o,
475
- onChange: () => d(u.id)
473
+ title: i.name,
474
+ checked: i.id === l,
475
+ onChange: () => u(i.id)
476
476
  }
477
477
  ),
478
- u.id === o && u.content ? /* @__PURE__ */ r("div", { className: er, children: u.content }) : null
479
- ] }, u.id))
478
+ i.id === l && i.content ? /* @__PURE__ */ r("div", { className: nr, children: i.content }) : null
479
+ ] }, i.id))
480
480
  }
481
481
  )
482
- ] }), Er = ({
482
+ ] }), Lr = ({
483
483
  icon: e,
484
484
  title: n,
485
485
  description: t
486
486
  }) => /* @__PURE__ */ f("div", { className: "h-full w-full flex flex-col items-center justify-center text-secondary", children: [
487
- e || /* @__PURE__ */ r(fe, { width: 60, height: 60 }),
487
+ e || /* @__PURE__ */ r(pe, { width: 60, height: 60 }),
488
488
  /* @__PURE__ */ r("span", { className: "small mt-2 text-primary", children: n }),
489
489
  t && /* @__PURE__ */ r("span", { className: "mt-1 text-primary", children: t })
490
- ] }), nr = ({
490
+ ] }), sr = 60, Ar = ({
491
+ containerCssClass: e,
492
+ children: n,
493
+ width: t,
494
+ title: a,
495
+ iconSize: s = ee,
496
+ titleCssClass: o,
497
+ additionalButtons: l
498
+ }) => {
499
+ const [d, u] = T(t), [i, m] = T(!0), p = c([
500
+ "transform rotate-180 [writing-mode:tb-rl]",
501
+ i && "hidden",
502
+ o
503
+ ]), x = c([
504
+ "flex flex-row gap-2 cursor-pointer text-secondary",
505
+ i ? "justify-end" : "justify-center"
506
+ ]), h = () => {
507
+ u(i ? sr : t), m(!i);
508
+ };
509
+ return /* @__PURE__ */ f(
510
+ "div",
511
+ {
512
+ className: c([
513
+ "rounded p-4 flex flex-col justify-between overflow-y-auto flex-shrink-0",
514
+ e
515
+ ]),
516
+ style: { width: `${d}px` },
517
+ children: [
518
+ /* @__PURE__ */ r(
519
+ "div",
520
+ {
521
+ className: c([
522
+ "flex-1 min-h-0 overflow-auto",
523
+ !i && "hidden"
524
+ ]),
525
+ children: n
526
+ }
527
+ ),
528
+ /* @__PURE__ */ r("div", { className: p, children: a }),
529
+ /* @__PURE__ */ f("div", { className: x, children: [
530
+ i && l,
531
+ /* @__PURE__ */ r(
532
+ P,
533
+ {
534
+ cssClass: "hover:text-icon-accent-primary",
535
+ onClick: h,
536
+ iconBefore: i ? /* @__PURE__ */ r(
537
+ xe,
538
+ {
539
+ size: s,
540
+ stroke: F.stroke
541
+ }
542
+ ) : /* @__PURE__ */ r(
543
+ he,
544
+ {
545
+ size: s,
546
+ stroke: F.stroke
547
+ }
548
+ )
549
+ }
550
+ )
551
+ ] })
552
+ ]
553
+ }
554
+ );
555
+ }, ar = ({
491
556
  ariaLabel: e,
492
557
  cssClass: n,
493
558
  size: t = 24,
494
- onClose: s
559
+ onClose: a
495
560
  }) => /* @__PURE__ */ r(
496
561
  P,
497
562
  {
498
563
  ariaLabel: e,
499
- cssClass: i("text-secondary hover:text-accent-primary", n),
500
- onClick: s,
501
- iconBefore: /* @__PURE__ */ r(M, { size: t })
564
+ cssClass: c("text-secondary hover:text-accent-primary", n),
565
+ onClick: a,
566
+ iconBefore: /* @__PURE__ */ r(W, { size: t })
502
567
  }
503
- ), tr = ({
568
+ ), or = ({
504
569
  value: e,
505
570
  textareaId: n,
506
571
  placeholder: t,
507
- cssClass: s = "",
508
- disabled: a,
509
- invalid: l,
510
- readonly: o,
511
- onChange: c
572
+ cssClass: a = "",
573
+ disabled: s,
574
+ invalid: o,
575
+ readonly: l,
576
+ onChange: d
512
577
  }) => /* @__PURE__ */ r(V, { tooltip: e, triggerClassName: "flex", children: /* @__PURE__ */ r(
513
578
  "textarea",
514
579
  {
515
580
  id: n,
516
581
  placeholder: t,
517
582
  value: e || "",
518
- disabled: a,
519
- className: i(
583
+ disabled: s,
584
+ className: c(
520
585
  "dial-textarea dial-input px-3 py-2",
521
- l ? "dial-input-error" : "",
522
- a && "dial-input-disable",
523
- o && "dial-input-readonly",
524
- s
586
+ o ? "dial-input-error" : "",
587
+ s && "dial-input-disable",
588
+ l && "dial-input-readonly",
589
+ a
525
590
  ),
526
- onChange: (d) => !o && c?.(d.currentTarget.value)
591
+ onChange: (u) => !l && d?.(u.currentTarget.value)
527
592
  }
528
- ) }), sr = [
593
+ ) }), lr = [
529
594
  "ArrowLeft",
530
595
  "ArrowRight",
531
596
  "ArrowUp",
@@ -537,75 +602,75 @@ const Ye = "flex flex-col gap-2", Je = "flex", er = "pb-1 mt-2", rr = {
537
602
  "Escape",
538
603
  "Home",
539
604
  "End"
540
- ], ar = (e, n, t, s) => {
541
- if ((n === "number" || t !== void 0 || s !== void 0) && !sr.includes(e.key) && !(e.key === "-" && e.currentTarget.selectionStart === 0 && (t === void 0 || t < 0)) && !(e.key === "." && n === "number" && !e.currentTarget.value.includes("."))) {
605
+ ], ir = (e, n, t, a) => {
606
+ if ((n === "number" || t !== void 0 || a !== void 0) && !lr.includes(e.key) && !(e.key === "-" && e.currentTarget.selectionStart === 0 && (t === void 0 || t < 0)) && !(e.key === "." && n === "number" && !e.currentTarget.value.includes("."))) {
542
607
  if (!/^[0-9]$/.test(e.key)) {
543
608
  e.preventDefault();
544
609
  return;
545
610
  }
546
- if (t !== void 0 || s !== void 0) {
547
- const l = e.currentTarget.value, o = e.currentTarget.selectionStart || 0, c = l.slice(0, o) + e.key + l.slice(o), d = parseFloat(c);
548
- if (!isNaN(d)) {
549
- if (t !== void 0 && d < t) {
611
+ if (t !== void 0 || a !== void 0) {
612
+ const o = e.currentTarget.value, l = e.currentTarget.selectionStart || 0, d = o.slice(0, l) + e.key + o.slice(l), u = parseFloat(d);
613
+ if (!isNaN(u)) {
614
+ if (t !== void 0 && u < t) {
550
615
  e.preventDefault();
551
616
  return;
552
617
  }
553
- if (s !== void 0 && d > s) {
618
+ if (a !== void 0 && u > a) {
554
619
  e.preventDefault();
555
620
  return;
556
621
  }
557
622
  }
558
623
  }
559
624
  }
560
- }, L = ({
625
+ }, O = ({
561
626
  iconBefore: e,
562
627
  iconAfter: n,
563
628
  hideBorder: t,
564
- value: s,
565
- elementId: a,
566
- placeholder: l = "",
567
- cssClass: o = "",
568
- containerCssClass: c,
569
- tooltipTriggerClassName: d,
570
- type: u = "text",
629
+ value: a,
630
+ elementId: s,
631
+ placeholder: o = "",
632
+ cssClass: l = "",
633
+ containerCssClass: d,
634
+ tooltipTriggerClassName: u,
635
+ type: i = "text",
571
636
  disabled: m,
572
- readonly: x,
573
- invalid: h,
574
- onChange: g,
637
+ readonly: p,
638
+ invalid: x,
639
+ onChange: h,
575
640
  min: y,
576
- max: p,
641
+ max: g,
577
642
  prefix: N,
578
643
  suffix: w,
579
644
  textBeforeInput: b,
580
- textAfterInput: E
645
+ textAfterInput: L
581
646
  }) => {
582
- const re = (I) => I.target.blur(), ne = u === "number" || y !== void 0 || p !== void 0, te = (I) => {
583
- ar(I, u, y, p);
584
- }, se = (I) => {
585
- const F = I.currentTarget.value;
586
- if (ne && F !== "") {
587
- const T = parseFloat(F);
588
- if (isNaN(T) && F !== "-" && F !== "." || !isNaN(T) && (y !== void 0 && T < y || p !== void 0 && T > p))
647
+ const ne = (I) => I.target.blur(), te = i === "number" || y !== void 0 || g !== void 0, se = (I) => {
648
+ ir(I, i, y, g);
649
+ }, ae = (I) => {
650
+ const E = I.currentTarget.value;
651
+ if (te && E !== "") {
652
+ const A = parseFloat(E);
653
+ if (isNaN(A) && E !== "-" && E !== "." || !isNaN(A) && (y !== void 0 && A < y || g !== void 0 && A > g))
589
654
  return;
590
655
  }
591
- g?.(F);
656
+ h?.(E);
592
657
  };
593
658
  return /* @__PURE__ */ f(
594
659
  "div",
595
660
  {
596
- className: i(
661
+ className: c(
597
662
  "dial-input-field flex flex-row items-center justify-between py-2",
598
663
  t ? "dial-input-no-border" : "dial-input",
599
- h && "dial-input-error",
664
+ x && "dial-input-error",
600
665
  m && "dial-input-disable",
601
- x && "dial-input-readonly",
666
+ p && "dial-input-readonly",
602
667
  !b && "pl-3",
603
- !E && "pr-3",
604
- c
668
+ !L && "pr-3",
669
+ d
605
670
  ),
606
671
  children: [
607
672
  b && /* @__PURE__ */ r("div", { children: /* @__PURE__ */ r(
608
- L,
673
+ O,
609
674
  {
610
675
  hideBorder: !0,
611
676
  containerCssClass: "rounded-r-none border-r-0",
@@ -623,23 +688,23 @@ const Ye = "flex flex-col gap-2", Je = "flex", er = "pb-1 mt-2", rr = {
623
688
  /* @__PURE__ */ r(
624
689
  V,
625
690
  {
626
- tooltip: s,
627
- triggerClassName: i(d, "flex-1"),
691
+ tooltip: a,
692
+ triggerClassName: c(u, "flex-1"),
628
693
  children: /* @__PURE__ */ r(
629
694
  "input",
630
695
  {
631
- type: u,
696
+ type: i,
632
697
  autoComplete: "off",
633
- id: a,
634
- placeholder: l,
635
- value: s ?? "",
698
+ id: s,
699
+ placeholder: o,
700
+ value: a ?? "",
636
701
  disabled: m,
637
- className: i("border-0 bg-transparent px-2", o),
638
- onChange: (I) => !x && se?.(I),
639
- onKeyDown: te,
640
- onWheel: re,
702
+ className: c("border-0 bg-transparent px-2", l),
703
+ onChange: (I) => !p && ae?.(I),
704
+ onKeyDown: se,
705
+ onWheel: ne,
641
706
  min: y,
642
- max: p
707
+ max: g
643
708
  }
644
709
  )
645
710
  }
@@ -649,96 +714,96 @@ const Ye = "flex flex-col gap-2", Je = "flex", er = "pb-1 mt-2", rr = {
649
714
  " ",
650
715
  w
651
716
  ] }),
652
- E && /* @__PURE__ */ r("div", { children: /* @__PURE__ */ r(
653
- L,
717
+ L && /* @__PURE__ */ r("div", { children: /* @__PURE__ */ r(
718
+ O,
654
719
  {
655
720
  hideBorder: !0,
656
721
  containerCssClass: "rounded-l-none border-l-0",
657
722
  cssClass: "px-2",
658
- value: E,
723
+ value: L,
659
724
  disabled: !0,
660
- elementId: E + "textAfter"
725
+ elementId: L + "textAfter"
661
726
  }
662
727
  ) })
663
728
  ]
664
729
  }
665
730
  );
666
- }, lr = /^0+\.(\d+)?$/, or = /^0+/, ee = ({
731
+ }, cr = /^0+\.(\d+)?$/, dr = /^0+/, re = ({
667
732
  fieldTitle: e,
668
733
  errorText: n,
669
734
  optional: t,
670
- elementCssClass: s,
671
- elementContainerCssClass: a,
672
- elementId: l,
673
- containerCssClass: o,
674
- readonly: c,
675
- defaultEmptyText: d,
676
- min: u,
735
+ elementCssClass: a,
736
+ elementContainerCssClass: s,
737
+ elementId: o,
738
+ containerCssClass: l,
739
+ readonly: d,
740
+ defaultEmptyText: u,
741
+ min: i,
677
742
  max: m,
678
- ...x
679
- }) => /* @__PURE__ */ f("div", { className: i("flex flex-col", o), children: [
743
+ ...p
744
+ }) => /* @__PURE__ */ f("div", { className: c("flex flex-col", l), children: [
680
745
  /* @__PURE__ */ r(
681
- O,
746
+ j,
682
747
  {
683
748
  fieldTitle: e,
684
749
  optional: t,
685
- htmlFor: l
750
+ htmlFor: o
686
751
  }
687
752
  ),
688
- c ? /* @__PURE__ */ r("span", { children: x.value || (d ?? "None") }) : /* @__PURE__ */ f(ae, { children: [
753
+ d ? /* @__PURE__ */ r("span", { children: p.value || (u ?? "None") }) : /* @__PURE__ */ f(oe, { children: [
689
754
  /* @__PURE__ */ r(
690
- L,
755
+ O,
691
756
  {
692
- elementId: l,
693
- cssClass: s,
694
- containerCssClass: a,
757
+ elementId: o,
758
+ cssClass: a,
759
+ containerCssClass: s,
695
760
  invalid: n != null,
696
- min: u,
761
+ min: i,
697
762
  max: m,
698
- ...x
763
+ ...p
699
764
  }
700
765
  ),
701
- /* @__PURE__ */ r(W, { errorText: n })
766
+ /* @__PURE__ */ r(_, { errorText: n })
702
767
  ] })
703
- ] }), Tr = ({
768
+ ] }), Or = ({
704
769
  onChange: e,
705
770
  value: n,
706
771
  min: t,
707
- max: s,
708
- ...a
772
+ max: a,
773
+ ...s
709
774
  }) => {
710
- const l = (o) => String(o)?.match(lr) ? String(o)?.replace(or, "0") : Number(o);
775
+ const o = (l) => String(l)?.match(cr) ? String(l)?.replace(dr, "0") : Number(l);
711
776
  return /* @__PURE__ */ r(
712
- ee,
777
+ re,
713
778
  {
714
779
  type: "number",
715
- onChange: (o) => e?.(l(o)),
780
+ onChange: (l) => e?.(o(l)),
716
781
  value: n,
717
782
  min: t,
718
- max: s,
719
- ...a
783
+ max: a,
784
+ ...s
720
785
  }
721
786
  );
722
- }, Pr = ({
787
+ }, zr = ({
723
788
  onChange: e,
724
789
  ...n
725
790
  }) => /* @__PURE__ */ r(
726
- ee,
791
+ re,
727
792
  {
728
793
  type: "text",
729
794
  onChange: (t) => e?.(t),
730
795
  ...n
731
796
  }
732
- ), Ar = ({
797
+ ), Br = ({
733
798
  fieldTitle: e,
734
799
  optional: n,
735
800
  elementId: t,
736
- elementCssClass: s,
737
- errorText: a,
738
- ...l
801
+ elementCssClass: a,
802
+ errorText: s,
803
+ ...o
739
804
  }) => /* @__PURE__ */ f("div", { className: "flex flex-col", children: [
740
805
  /* @__PURE__ */ r(
741
- O,
806
+ j,
742
807
  {
743
808
  fieldTitle: e,
744
809
  optional: n,
@@ -746,50 +811,50 @@ const Ye = "flex flex-col gap-2", Je = "flex", er = "pb-1 mt-2", rr = {
746
811
  }
747
812
  ),
748
813
  /* @__PURE__ */ r(
749
- tr,
814
+ or,
750
815
  {
751
816
  textareaId: t,
752
- cssClass: s,
753
- ...l
817
+ cssClass: a,
818
+ ...o
754
819
  }
755
820
  ),
756
- /* @__PURE__ */ r(W, { errorText: a })
757
- ] }), Lr = ({
821
+ /* @__PURE__ */ r(_, { errorText: s })
822
+ ] }), jr = ({
758
823
  title: e,
759
824
  switchId: n,
760
825
  isOn: t = !1,
761
- disabled: s,
762
- onChange: a
826
+ disabled: a,
827
+ onChange: s
763
828
  }) => {
764
- const l = i(
829
+ const o = c(
765
830
  "flex w-[36px] h-[18px] cursor-pointer items-center gap-1 rounded-full p-0.5 transition-all duration-200",
766
831
  t ? "flex-row-reverse" : "flex-row",
767
- s ? "pointer-events-none" : "",
768
- s ? t ? "bg-controls-disable" : "bg-layer-4" : t ? "bg-accent-primary" : "bg-layer-4"
769
- ), o = S(
770
- (c) => {
771
- c.stopPropagation(), a?.(!t);
832
+ a ? "pointer-events-none" : "",
833
+ a ? t ? "bg-controls-disable" : "bg-layer-4" : t ? "bg-accent-primary" : "bg-layer-4"
834
+ ), l = S(
835
+ (d) => {
836
+ d.stopPropagation(), s?.(!t);
772
837
  },
773
- [a, t]
838
+ [s, t]
774
839
  );
775
840
  return /* @__PURE__ */ f("div", { className: "flex flex-row items-center", children: [
776
841
  /* @__PURE__ */ r(
777
842
  "input",
778
843
  {
779
844
  type: "checkbox",
780
- onChange: o,
845
+ onChange: l,
781
846
  id: n,
782
- disabled: s,
847
+ disabled: a,
783
848
  className: "invisible w-0 h-0",
784
849
  checked: t
785
850
  }
786
851
  ),
787
- /* @__PURE__ */ r("label", { htmlFor: n, className: l, children: /* @__PURE__ */ r(
852
+ /* @__PURE__ */ r("label", { htmlFor: n, className: o, children: /* @__PURE__ */ r(
788
853
  "span",
789
854
  {
790
- className: i(
855
+ className: c(
791
856
  "size-3 rounded-full",
792
- s ? t ? "bg-layer-4" : "bg-controls-disable" : "bg-controls-enable-primary"
857
+ a ? t ? "bg-layer-4" : "bg-controls-disable" : "bg-controls-enable-primary"
793
858
  )
794
859
  }
795
860
  ) }),
@@ -797,74 +862,74 @@ const Ye = "flex flex-col gap-2", Je = "flex", er = "pb-1 mt-2", rr = {
797
862
  ] });
798
863
  };
799
864
  var R = /* @__PURE__ */ ((e) => (e.Sm = "sm", e.Md = "md", e.Lg = "lg", e))(R || {});
800
- const ir = "z-[52] flex items-center justify-center bg-blackout md:p-4", cr = "relative max-h-full rounded bg-layer-3 flex flex-col shadow w-full h-full md:h-auto", dr = "divide-tertiary divide-y", ur = "flex flex-row justify-between py-4 px-6 items-center", mr = {
865
+ const ur = "z-[52] flex items-center justify-center bg-blackout md:p-4", mr = "relative max-h-full rounded bg-layer-3 flex flex-col shadow w-full h-full md:h-auto", fr = "divide-tertiary divide-y", pr = "flex flex-row justify-between py-4 px-6 items-center", xr = {
801
866
  [R.Sm]: "max-w-full md:max-w-[400px]",
802
867
  [R.Md]: "max-w-full md:max-w-[800px]",
803
868
  [R.Lg]: "max-w-full md:max-w-[1200px]"
804
- }, fr = ({
869
+ }, hr = ({
805
870
  open: e = !1,
806
871
  title: n,
807
872
  portalId: t,
808
- cssClass: s,
809
- overlayClass: a,
810
- headingClass: l,
811
- dividers: o = !0,
812
- children: c,
813
- footer: d,
814
- onClose: u,
873
+ cssClass: a,
874
+ overlayClass: s,
875
+ headingClass: o,
876
+ dividers: l = !0,
877
+ children: d,
878
+ footer: u,
879
+ onClose: i,
815
880
  size: m = R.Md
816
881
  }) => {
817
- const { refs: x, context: h } = G({
882
+ const { refs: p, context: x } = G({
818
883
  open: e,
819
884
  onOpenChange: (b) => {
820
- b || u?.(null);
885
+ b || i?.(null);
821
886
  }
822
- }), g = Z(h, { role: "dialog" }), y = K(h, { outsidePress: !0 }), { getFloatingProps: p } = X([g, y]);
887
+ }), h = Z(x, { role: "dialog" }), y = K(x, { outsidePress: !0 }), { getFloatingProps: g } = X([h, y]);
823
888
  if (!e) return null;
824
889
  const N = typeof n == "string" ? "dial-popup-heading" : void 0, w = (b) => b ? typeof b == "string" ? /* @__PURE__ */ r(
825
890
  "h3",
826
891
  {
827
892
  id: N,
828
- className: i(
893
+ className: c(
829
894
  "flex-1 min-w-0 mr-3 truncate dial-h3 text-primary",
830
- l
895
+ o
831
896
  ),
832
897
  children: /* @__PURE__ */ r(V, { tooltip: b, children: b })
833
898
  }
834
899
  ) : b : /* @__PURE__ */ r("span", {});
835
- return /* @__PURE__ */ r(Q, { id: t, children: /* @__PURE__ */ r(Pe, { className: i(ir, a), children: /* @__PURE__ */ r(Ae, { context: h, children: /* @__PURE__ */ f(
900
+ return /* @__PURE__ */ r(Q, { id: t, children: /* @__PURE__ */ r(Oe, { className: c(ur, s), children: /* @__PURE__ */ r(ze, { context: x, children: /* @__PURE__ */ f(
836
901
  "div",
837
902
  {
838
- ref: x.setFloating,
839
- ...p(),
903
+ ref: p.setFloating,
904
+ ...g(),
840
905
  role: "dialog",
841
906
  "aria-modal": "true",
842
907
  "aria-labelledby": N,
843
- className: i(
844
- cr,
845
- mr[m],
846
- o && dr,
847
- s
908
+ className: c(
909
+ mr,
910
+ xr[m],
911
+ l && fr,
912
+ a
848
913
  ),
849
914
  children: [
850
- /* @__PURE__ */ f("div", { className: ur, children: [
915
+ /* @__PURE__ */ f("div", { className: pr, children: [
851
916
  w(n),
852
917
  /* @__PURE__ */ r(
853
- nr,
918
+ ar,
854
919
  {
855
920
  ariaLabel: "Close dialog",
856
- onClose: (b) => u?.(b)
921
+ onClose: (b) => i?.(b)
857
922
  }
858
923
  )
859
924
  ] }),
860
- /* @__PURE__ */ r("div", { className: "flex-grow overflow-auto", children: c }),
861
- d
925
+ /* @__PURE__ */ r("div", { className: "flex-grow overflow-auto", children: d }),
926
+ u
862
927
  ]
863
928
  }
864
929
  ) }) }) });
865
930
  };
866
931
  var z = /* @__PURE__ */ ((e) => (e.Info = "info", e.Danger = "danger", e))(z || {});
867
- const pr = "flex justify-end gap-2 px-6 py-4", xr = "text-secondary dial-small-150 px-6 py-4", hr = "Cancel", H = {
932
+ const gr = "flex justify-end gap-2 px-6 py-4", br = "text-secondary dial-small-150 px-6 py-4", yr = "Cancel", H = {
868
933
  [z.Info]: {
869
934
  confirmVariant: v.Primary,
870
935
  cancelVariant: v.Secondary
@@ -874,57 +939,57 @@ const pr = "flex justify-end gap-2 px-6 py-4", xr = "text-secondary dial-small-1
874
939
  confirmVariant: v.Danger,
875
940
  cancelVariant: v.Secondary
876
941
  }
877
- }, zr = ({
942
+ }, Vr = ({
878
943
  title: e,
879
944
  description: n,
880
945
  descriptionCssClass: t,
881
- open: s = !1,
882
- confirmLabel: a,
883
- cancelLabel: l = hr,
884
- isLoading: o = !1,
885
- disableConfirmButton: c = !1,
886
- cssClass: d,
887
- confirmClassName: u,
946
+ open: a = !1,
947
+ confirmLabel: s,
948
+ cancelLabel: o = yr,
949
+ isLoading: l = !1,
950
+ disableConfirmButton: d = !1,
951
+ cssClass: u,
952
+ confirmClassName: i,
888
953
  onClose: m,
889
- onConfirm: x,
890
- onCancel: h,
891
- children: g,
954
+ onConfirm: p,
955
+ onCancel: x,
956
+ children: h,
892
957
  dividers: y = !1,
893
- variant: p = z.Info,
958
+ variant: g = z.Info,
894
959
  size: N = R.Sm
895
960
  }) => {
896
- const w = o ? null : /* @__PURE__ */ f("div", { className: pr, children: [
961
+ const w = l ? null : /* @__PURE__ */ f("div", { className: gr, children: [
897
962
  /* @__PURE__ */ r(
898
963
  P,
899
964
  {
900
965
  variant: v.Secondary,
901
- title: l,
902
- onClick: () => h ? h() : m?.()
966
+ title: o,
967
+ onClick: () => x ? x() : m?.()
903
968
  }
904
969
  ),
905
970
  /* @__PURE__ */ r(
906
971
  P,
907
972
  {
908
- variant: H[p].confirmVariant,
909
- cssClass: u,
910
- title: a,
911
- disable: c,
912
- onClick: () => x()
973
+ variant: H[g].confirmVariant,
974
+ cssClass: i,
975
+ title: s,
976
+ disable: d,
977
+ onClick: () => p()
913
978
  }
914
979
  )
915
- ] }), b = S(() => o ? /* @__PURE__ */ r("div", { className: "px-6 py-4 h-[120px]", children: /* @__PURE__ */ r(Me, { size: 50 }) }) : g ?? (n ? /* @__PURE__ */ r(
980
+ ] }), b = S(() => l ? /* @__PURE__ */ r("div", { className: "px-6 py-4 h-[120px]", children: /* @__PURE__ */ r(He, { size: 50 }) }) : h ?? (n ? /* @__PURE__ */ r(
916
981
  "div",
917
982
  {
918
- className: i(xr, t),
983
+ className: c(br, t),
919
984
  children: n
920
985
  }
921
- ) : null), [g, n, o, t]);
986
+ ) : null), [h, n, l, t]);
922
987
  return /* @__PURE__ */ r(
923
- fr,
988
+ hr,
924
989
  {
925
- open: s,
990
+ open: a,
926
991
  title: e,
927
- cssClass: i(H[p].container, d),
992
+ cssClass: c(H[g].container, u),
928
993
  dividers: y,
929
994
  onClose: () => m?.(),
930
995
  footer: w,
@@ -932,54 +997,54 @@ const pr = "flex justify-end gap-2 px-6 py-4", xr = "text-secondary dial-small-1
932
997
  children: b()
933
998
  }
934
999
  );
935
- }, gr = ({ onClick: e }) => /* @__PURE__ */ r(
936
- pe,
1000
+ }, Cr = ({ onClick: e }) => /* @__PURE__ */ r(
1001
+ ge,
937
1002
  {
938
- ...A,
1003
+ ...F,
939
1004
  className: "text-primary",
940
1005
  onClick: e
941
1006
  }
942
- ), br = ({ onClick: e }) => /* @__PURE__ */ r(xe, { ...A, className: "text-primary", onClick: e }), yr = ({ ...e }) => {
943
- const [n, t] = _(!1), s = S((a) => {
944
- t(a);
1007
+ ), vr = ({ onClick: e }) => /* @__PURE__ */ r(be, { ...F, className: "text-primary", onClick: e }), Nr = ({ ...e }) => {
1008
+ const [n, t] = T(!1), a = S((s) => {
1009
+ t(s);
945
1010
  }, []);
946
1011
  return /* @__PURE__ */ r(
947
- L,
1012
+ O,
948
1013
  {
949
1014
  type: n ? "text" : "password",
950
1015
  ...e,
951
- iconAfter: n ? /* @__PURE__ */ r(gr, { onClick: () => s(!1) }) : /* @__PURE__ */ r(br, { onClick: () => s(!0) })
1016
+ iconAfter: n ? /* @__PURE__ */ r(Cr, { onClick: () => a(!1) }) : /* @__PURE__ */ r(vr, { onClick: () => a(!0) })
952
1017
  }
953
1018
  );
954
- }, Br = ({
1019
+ }, Mr = ({
955
1020
  fieldTitle: e,
956
1021
  optional: n,
957
1022
  elementCssClass: t,
958
- elementId: s,
959
- errorText: a,
960
- ...l
1023
+ elementId: a,
1024
+ errorText: s,
1025
+ ...o
961
1026
  }) => /* @__PURE__ */ f("div", { className: "flex flex-col", children: [
962
1027
  /* @__PURE__ */ r(
963
- O,
1028
+ j,
964
1029
  {
965
1030
  fieldTitle: e,
966
1031
  optional: n,
967
- htmlFor: s
1032
+ htmlFor: a
968
1033
  }
969
1034
  ),
970
1035
  /* @__PURE__ */ r(
971
- yr,
1036
+ Nr,
972
1037
  {
973
1038
  cssClass: t,
974
- elementId: s,
975
- invalid: !!a,
976
- ...l
1039
+ elementId: a,
1040
+ invalid: !!s,
1041
+ ...o
977
1042
  }
978
1043
  ),
979
- /* @__PURE__ */ r(W, { errorText: a })
1044
+ /* @__PURE__ */ r(_, { errorText: s })
980
1045
  ] });
981
1046
  var B = /* @__PURE__ */ ((e) => (e.Small = "small", e.Base = "base", e))(B || {});
982
- const Cr = {
1047
+ const wr = {
983
1048
  [B.Small]: {
984
1049
  textClass: "text-xs px-1",
985
1050
  containerClass: "px-[6px] py-1 h-[22px]",
@@ -992,51 +1057,51 @@ const Cr = {
992
1057
  iconSize: 18,
993
1058
  iconStroke: 1.5
994
1059
  }
995
- }, Or = ({
1060
+ }, Wr = ({
996
1061
  elementId: e,
997
1062
  value: n,
998
1063
  placeholder: t,
999
- disabled: s,
1000
- readonly: a,
1001
- invalid: l,
1002
- cssClass: o,
1003
- containerCssClass: c,
1004
- onChange: d,
1005
- size: u = B.Base
1064
+ disabled: a,
1065
+ readonly: s,
1066
+ invalid: o,
1067
+ cssClass: l,
1068
+ containerCssClass: d,
1069
+ onChange: u,
1070
+ size: i = B.Base
1006
1071
  }) => {
1007
- const [m, x] = _(n || "");
1008
- we(() => {
1009
- x(n || "");
1072
+ const [m, p] = T(n || "");
1073
+ ke(() => {
1074
+ p(n || "");
1010
1075
  }, [n]);
1011
- const h = S(
1012
- (p) => {
1013
- x(p), d?.(p);
1076
+ const x = S(
1077
+ (g) => {
1078
+ p(g), u?.(g);
1014
1079
  },
1015
- [d]
1016
- ), g = Cr[u], y = S(() => {
1017
- h("");
1018
- }, [h]);
1080
+ [u]
1081
+ ), h = wr[i], y = S(() => {
1082
+ x("");
1083
+ }, [x]);
1019
1084
  return /* @__PURE__ */ f(
1020
1085
  "div",
1021
1086
  {
1022
- className: i(
1087
+ className: c(
1023
1088
  "dial-input flex flex-row items-center justify-between",
1024
- l && "dial-input-error",
1025
- s && "dial-input-disable",
1026
- a && "dial-input-readonly",
1027
- g.containerClass,
1028
- c
1089
+ o && "dial-input-error",
1090
+ a && "dial-input-disable",
1091
+ s && "dial-input-readonly",
1092
+ h.containerClass,
1093
+ d
1029
1094
  ),
1030
1095
  children: [
1031
1096
  /* @__PURE__ */ r(
1032
1097
  D,
1033
1098
  {
1034
- className: i(s ? "text-secondary" : "text-primary"),
1099
+ className: c(a ? "text-secondary" : "text-primary"),
1035
1100
  icon: /* @__PURE__ */ r(
1036
- he,
1101
+ ye,
1037
1102
  {
1038
- size: g.iconSize,
1039
- stroke: g.iconStroke
1103
+ size: h.iconSize,
1104
+ stroke: h.iconStroke
1040
1105
  }
1041
1106
  )
1042
1107
  }
@@ -1049,25 +1114,25 @@ const Cr = {
1049
1114
  autoComplete: "off",
1050
1115
  placeholder: t,
1051
1116
  value: m ?? "",
1052
- disabled: s,
1053
- readOnly: a,
1054
- className: i(
1117
+ disabled: a,
1118
+ readOnly: s,
1119
+ className: c(
1055
1120
  "border-0 bg-transparent w-full",
1056
- o,
1057
- g.textClass
1121
+ l,
1122
+ h.textClass
1058
1123
  ),
1059
- onChange: (p) => !a && h(p.currentTarget.value)
1124
+ onChange: (g) => !s && x(g.currentTarget.value)
1060
1125
  }
1061
1126
  ),
1062
- m && !a && !s && /* @__PURE__ */ r(
1127
+ m && !s && !a && /* @__PURE__ */ r(
1063
1128
  D,
1064
1129
  {
1065
1130
  className: "text-primary cursor-pointer",
1066
1131
  icon: /* @__PURE__ */ r(
1067
- M,
1132
+ W,
1068
1133
  {
1069
- size: g.iconSize,
1070
- stroke: g.iconStroke,
1134
+ size: h.iconSize,
1135
+ stroke: h.iconStroke,
1071
1136
  onClick: y,
1072
1137
  "aria-label": "Clear search",
1073
1138
  role: "button"
@@ -1083,31 +1148,33 @@ export {
1083
1148
  k as AlertVariant,
1084
1149
  v as ButtonVariant,
1085
1150
  z as ConfirmationPopupVariant,
1086
- kr as DialAlert,
1151
+ Fr as DialAlert,
1087
1152
  P as DialButton,
1088
- Rr as DialCheckbox,
1089
- nr as DialCloseButton,
1090
- zr as DialConfirmationPopup,
1091
- W as DialErrorText,
1092
- O as DialFieldLabel,
1153
+ Er as DialCheckbox,
1154
+ ar as DialCloseButton,
1155
+ Ar as DialCollapsibleSidebar,
1156
+ Vr as DialConfirmationPopup,
1157
+ _ as DialErrorText,
1158
+ j as DialFieldLabel,
1093
1159
  D as DialIcon,
1094
- L as DialInput,
1095
- Me as DialLoader,
1096
- Er as DialNoDataContent,
1097
- Tr as DialNumberInputField,
1098
- yr as DialPasswordInput,
1099
- Br as DialPasswordInputField,
1100
- fr as DialPopup,
1101
- Qe as DialRadioButton,
1102
- Fr as DialRadioGroup,
1103
- Or as DialSearch,
1104
- Sr as DialSteps,
1105
- Lr as DialSwitch,
1106
- Ar as DialTextAreaField,
1107
- Pr as DialTextInputField,
1108
- tr as DialTextarea,
1160
+ O as DialInput,
1161
+ He as DialLoader,
1162
+ Lr as DialNoDataContent,
1163
+ Or as DialNumberInputField,
1164
+ Nr as DialPasswordInput,
1165
+ Mr as DialPasswordInputField,
1166
+ hr as DialPopup,
1167
+ Je as DialRadioButton,
1168
+ Pr as DialRadioGroup,
1169
+ Wr as DialSearch,
1170
+ Tr as DialSteps,
1171
+ jr as DialSwitch,
1172
+ Br as DialTextAreaField,
1173
+ zr as DialTextInputField,
1174
+ or as DialTextarea,
1109
1175
  V as DialTooltip,
1110
1176
  R as PopupSize,
1111
- j as RadioGroupOrientation,
1177
+ M as RadioGroupOrientation,
1178
+ B as SearchSize,
1112
1179
  C as StepStatus
1113
1180
  };