@scbt-ecom/ui 0.50.1 → 0.51.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- import { HTMLAttributes, ReactElement } from 'react';
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
2
  export interface BadgeProps extends HTMLAttributes<HTMLSpanElement> {
3
- children: ReactElement | string;
3
+ children: ReactNode;
4
4
  className?: string;
5
5
  }
6
6
  export declare const Badge: ({ children, className, ...props }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
@@ -3,7 +3,7 @@ export interface SpritesMap {
3
3
  brandLogos: 'logoBlack' | 'logoBusiness' | 'logoGray' | 'logoInsurance' | 'logoMain' | 'logoWhite';
4
4
  editor: 'bold' | 'heading' | 'italic' | 'link' | 'list' | 'palette' | 'redo' | 'removeFormatting' | 'space' | 'strikethrough' | 'typography' | 'underline' | 'undo';
5
5
  files: 'border' | 'borderError' | 'documentFilled' | 'documentOutline' | 'upload';
6
- general: 'calendar' | 'check' | 'close' | 'edit' | 'hiddenEye' | 'plus' | 'showEye';
6
+ general: 'calendar' | 'check' | 'close' | 'edit' | 'hiddenEye' | 'plus' | 'reorder' | 'showEye';
7
7
  info: 'helpCircle' | 'warningCircle';
8
8
  logos: 'beeline' | 'megafon' | 'mts';
9
9
  social: 'classmates' | 'telegram' | 'vk';
@@ -1,4 +1,3 @@
1
- export * from './section';
2
1
  export * from './responsiveContainer';
3
2
  export * from './button';
4
3
  export * from './buttonIcon';
@@ -36,6 +36,32 @@ export declare class ZodUtils {
36
36
  * // }
37
37
  * // }
38
38
  */
39
- static getZodDefaults<ZodSchema extends z.AnyZodObject, Schema = z.TypeOf<ZodSchema>>(zodSchema: ZodSchema | z.ZodEffects<ZodSchema> | z.ZodIntersection<ZodSchema, ZodSchema>, options?: ZodUtilsGetDefaultsOptions): Schema;
39
+ static getZodDefaults<ZodSchema extends z.AnyZodObject, Schema = z.TypeOf<ZodSchema>>(zodSchema: ZodSchema | z.ZodEffects<ZodSchema>, options?: ZodUtilsGetDefaultsOptions): Schema;
40
+ /**
41
+ * Функция для объединения zod схождений
42
+ * @param {ZodIntersection} zodSchema
43
+ * @returns объединенная схема двух схождений
44
+ *
45
+ * @example
46
+ * let schema = z.object({
47
+ * foo: z.string()
48
+ * })
49
+ * // this will return intersection and we need
50
+ * // to merge its left to right schema's
51
+ * .and(
52
+ * z.object({
53
+ * bar: z.string()
54
+ * })
55
+ * )
56
+ *
57
+ * schema = ZodUtils.zodMergeIntersection(schema)
58
+ *
59
+ * // schema will be
60
+ * z.object({
61
+ * foo: z.string(),
62
+ * bar: z.string()
63
+ * })
64
+ */
65
+ static zodMergeIntersection<ZodLeft extends z.ZodTypeAny, ZodRight extends z.ZodTypeAny>(zodSchema: z.ZodIntersection<ZodLeft, ZodRight>): z.ZodObject<z.objectUtil.MergeShapes<z.TypeOf<ZodLeft>, z.TypeOf<ZodRight>>>;
40
66
  }
41
67
  export {};
@@ -1 +1 @@
1
- <svg width="0" height="0"><symbol xmlns="http://www.w3.org/2000/svg" id="calendar" fill="none" viewBox="0 0 19 20"><path fill="currentColor" fill-rule="evenodd" d="M4.56 0a1 1 0 0 1 1 1v.543h8.19V1a1 1 0 1 1 2 0v.604c1.714.317 3 1.834 3 3.639V16.3c0 2.032-1.63 3.7-3.667 3.7H4.417C2.38 20 .75 18.332.75 16.3V5.243a3.696 3.696 0 0 1 2.81-3.599V1a1 1 0 0 1 1-1Zm-.02 3.543h-.123c-.91 0-1.667.75-1.667 1.7v.671h14v-.671c0-.95-.758-1.7-1.667-1.7H4.58a1.066 1.066 0 0 1-.04 0Zm12.21 4.371h-14V16.3c0 .95.758 1.7 1.667 1.7h10.666c.91 0 1.667-.75 1.667-1.7V7.914Z" clip-rule="evenodd"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="check" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2.5" d="m4.892 13.269 4.274 4.274L18.709 8"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="close" fill="none" viewBox="0 0 24 24"><path fill="currentColor" d="M5.293 5.293a1 1 0 0 1 1.414 0L12 10.586l5.293-5.293a1 1 0 1 1 1.414 1.414L13.414 12l5.293 5.293a1 1 0 0 1-1.414 1.414L12 13.414l-5.293 5.293a1 1 0 0 1-1.414-1.414L10.586 12 5.293 6.707a1 1 0 0 1 0-1.414Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="edit" fill="none" viewBox="0 0 19 19"><path fill="currentColor" d="M13.293.293a1 1 0 0 1 1.414 0l4 4a1 1 0 0 1 0 1.414l-13 13A1 1 0 0 1 5 19H1a1 1 0 0 1-1-1v-4a1 1 0 0 1 .293-.707l13-13ZM14 2.414l-12 12V17h2.586l12-12L14 2.414Z"/><path fill="currentColor" fill-rule="evenodd" d="M9 18a1 1 0 0 1 1-1h8a1 1 0 1 1 0 2h-8a1 1 0 0 1-1-1Z" clip-rule="evenodd"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="hiddenEye" fill="none" viewBox="0 0 20 18"><path fill="currentColor" d="M2.707.293a1 1 0 0 0-1.414 1.414l2.424 2.424C2.287 5.207 1.04 6.685.106 8.553a1 1 0 0 0 0 .894C2.264 13.764 6.096 16 10 16c1.555 0 3.1-.355 4.53-1.055l2.763 2.762a1 1 0 0 0 1.414-1.414l-16-16Zm10.307 13.135c-.98.383-2 .572-3.014.572-2.969 0-6.002-1.62-7.87-5 .817-1.479 1.858-2.62 3.018-3.437l2.144 2.144a3 3 0 0 0 4.001 4.001l1.72 1.72Zm3.538-2.532c.483-.556.926-1.187 1.318-1.896-1.868-3.38-4.9-5-7.87-5-.112 0-.224.002-.336.007L7.879 2.223A10.215 10.215 0 0 1 10 2c3.903 0 7.736 2.236 9.894 6.553a1 1 0 0 1 0 .894 13.107 13.107 0 0 1-1.925 2.865l-1.417-1.416Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="plus" fill="none" viewBox="0 0 16 16"><path fill="currentColor" d="M8 0a1 1 0 0 1 1 1v6h6a1 1 0 1 1 0 2H9v6a1 1 0 1 1-2 0V9H1a1 1 0 1 1 0-2h6V1a1 1 0 0 1 1-1Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="showEye" fill="none" viewBox="0 0 20 14"><path fill="currentColor" d="M13 7a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"/><path fill="currentColor" d="M19.894 6.553C17.736 2.236 13.904 0 10 0 6.097 0 2.264 2.236.106 6.553a1 1 0 0 0 0 .894C2.264 11.764 6.096 14 10 14c3.903 0 7.736-2.236 9.894-6.553a1 1 0 0 0 0-.894ZM10 12c-2.969 0-6.002-1.62-7.87-5C3.998 3.62 7.03 2 10 2c2.969 0 6.002 1.62 7.87 5-1.868 3.38-4.901 5-7.87 5Z"/></symbol></svg>
1
+ <svg width="0" height="0"><symbol xmlns="http://www.w3.org/2000/svg" id="calendar" fill="none" viewBox="0 0 19 20"><path fill="currentColor" fill-rule="evenodd" d="M4.56 0a1 1 0 0 1 1 1v.543h8.19V1a1 1 0 1 1 2 0v.604c1.714.317 3 1.834 3 3.639V16.3c0 2.032-1.63 3.7-3.667 3.7H4.417C2.38 20 .75 18.332.75 16.3V5.243a3.696 3.696 0 0 1 2.81-3.599V1a1 1 0 0 1 1-1Zm-.02 3.543h-.123c-.91 0-1.667.75-1.667 1.7v.671h14v-.671c0-.95-.758-1.7-1.667-1.7H4.58a1.066 1.066 0 0 1-.04 0Zm12.21 4.371h-14V16.3c0 .95.758 1.7 1.667 1.7h10.666c.91 0 1.667-.75 1.667-1.7V7.914Z" clip-rule="evenodd"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="check" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2.5" d="m4.892 13.269 4.274 4.274L18.709 8"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="close" fill="none" viewBox="0 0 24 24"><path fill="currentColor" d="M5.293 5.293a1 1 0 0 1 1.414 0L12 10.586l5.293-5.293a1 1 0 1 1 1.414 1.414L13.414 12l5.293 5.293a1 1 0 0 1-1.414 1.414L12 13.414l-5.293 5.293a1 1 0 0 1-1.414-1.414L10.586 12 5.293 6.707a1 1 0 0 1 0-1.414Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="edit" fill="none" viewBox="0 0 19 19"><path fill="currentColor" d="M13.293.293a1 1 0 0 1 1.414 0l4 4a1 1 0 0 1 0 1.414l-13 13A1 1 0 0 1 5 19H1a1 1 0 0 1-1-1v-4a1 1 0 0 1 .293-.707l13-13ZM14 2.414l-12 12V17h2.586l12-12L14 2.414Z"/><path fill="currentColor" fill-rule="evenodd" d="M9 18a1 1 0 0 1 1-1h8a1 1 0 1 1 0 2h-8a1 1 0 0 1-1-1Z" clip-rule="evenodd"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="hiddenEye" fill="none" viewBox="0 0 20 18"><path fill="currentColor" d="M2.707.293a1 1 0 0 0-1.414 1.414l2.424 2.424C2.287 5.207 1.04 6.685.106 8.553a1 1 0 0 0 0 .894C2.264 13.764 6.096 16 10 16c1.555 0 3.1-.355 4.53-1.055l2.763 2.762a1 1 0 0 0 1.414-1.414l-16-16Zm10.307 13.135c-.98.383-2 .572-3.014.572-2.969 0-6.002-1.62-7.87-5 .817-1.479 1.858-2.62 3.018-3.437l2.144 2.144a3 3 0 0 0 4.001 4.001l1.72 1.72Zm3.538-2.532c.483-.556.926-1.187 1.318-1.896-1.868-3.38-4.9-5-7.87-5-.112 0-.224.002-.336.007L7.879 2.223A10.215 10.215 0 0 1 10 2c3.903 0 7.736 2.236 9.894 6.553a1 1 0 0 1 0 .894 13.107 13.107 0 0 1-1.925 2.865l-1.417-1.416Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="plus" fill="none" viewBox="0 0 16 16"><path fill="currentColor" d="M8 0a1 1 0 0 1 1 1v6h6a1 1 0 1 1 0 2H9v6a1 1 0 1 1-2 0V9H1a1 1 0 1 1 0-2h6V1a1 1 0 0 1 1-1Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="reorder" fill="none" viewBox="0 0 12 18"><path fill="currentColor" d="M2.5 4a2 2 0 1 0 0-4 2 2 0 0 0 0 4Zm0 7a2 2 0 1 0 0-4 2 2 0 0 0 0 4Zm2 5a2 2 0 1 1-4 0 2 2 0 0 1 4 0Zm5-12a2 2 0 1 0 0-4 2 2 0 0 0 0 4Zm2 5a2 2 0 1 1-4 0 2 2 0 0 1 4 0Zm-2 9a2 2 0 1 0 0-4 2 2 0 0 0 0 4Z"/></symbol><symbol xmlns="http://www.w3.org/2000/svg" id="showEye" fill="none" viewBox="0 0 20 14"><path fill="currentColor" d="M13 7a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"/><path fill="currentColor" d="M19.894 6.553C17.736 2.236 13.904 0 10 0 6.097 0 2.264 2.236.106 6.553a1 1 0 0 0 0 .894C2.264 11.764 6.096 14 10 14c3.903 0 7.736-2.236 9.894-6.553a1 1 0 0 0 0-.894ZM10 12c-2.969 0-6.002-1.62-7.87-5C3.998 3.62 7.03 2 10 2c2.969 0 6.002 1.62 7.87 5-1.868 3.38-4.901 5-7.87 5Z"/></symbol></svg>
package/dist/ui.js CHANGED
@@ -1,9 +1,9 @@
1
- import { j as p, c as We, R as Ye, B as E, u as Je, f as Qe, g as Ze, h as et, i as k, k as ve, l as tt, m as nt, n as U, o as ot, A as rt, H as it, I as N, p as lt, q as me, D as ut, V as st, O as at } from "./index-DXLhMM4P.js";
2
- import { d as Kn, r as Xn, e as Wn, C as Yn, s as Jn, K as Qn, L as Zn, N as eo, P as to, a as no, S as oo, t as ro, U as io, b as lo } from "./index-DXLhMM4P.js";
1
+ import { j as p, c as We, R as Ye, B as E, u as Je, f as Qe, g as Ze, h as et, i as k, k as Re, l as tt, m as nt, n as U, o as ot, A as rt, H as it, I as N, p as lt, q as me, D as ut, V as st, O as at } from "./index-MnignE4U.js";
2
+ import { d as Un, r as Kn, e as Xn, C as Wn, s as Yn, K as Jn, L as Qn, N as Zn, P as eo, a as to, S as no, U as oo, b as ro, t as io } from "./index-MnignE4U.js";
3
3
  import * as P from "react";
4
4
  import { forwardRef as D, useState as he, useEffect as gt } from "react";
5
5
  import { c as w, T as Se } from "./typeGuards-BigW-JS1.js";
6
- import { D as so, d as ao, f as go, b as co, a as fo } from "./utils-Od0KoTas.js";
6
+ import { D as uo, d as so, f as ao, b as go, a as co } from "./utils-Od0KoTas.js";
7
7
  import { createPortal as dt } from "react-dom";
8
8
  import { a as xe } from "./useDebounce-QgEEiWs9.js";
9
9
  const ct = We(
@@ -26,9 +26,9 @@ const ct = We(
26
26
  size: "lg"
27
27
  }
28
28
  }
29
- ), An = D(
29
+ ), Hn = D(
30
30
  ({ size: e, intent: o, children: t, classes: n, type: r = "button", ...i }, l) => /* @__PURE__ */ p.jsx("button", { ref: l, type: r, className: w(ct({ intent: o, size: e }), n == null ? void 0 : n.button), ...i, children: /* @__PURE__ */ p.jsx("span", { className: w(n == null ? void 0 : n.icon), children: t }) })
31
- ), Hn = ({ className: e }) => /* @__PURE__ */ p.jsx("div", { className: w("skeleton-apply h-full w-full", e) }), Gn = ({ isVisible: e, classes: o, children: t, buttonProps: n }) => /* @__PURE__ */ p.jsxs(
31
+ ), An = ({ className: e }) => /* @__PURE__ */ p.jsx("div", { className: w("skeleton-apply h-full w-full", e) }), Gn = ({ isVisible: e, classes: o, children: t, buttonProps: n }) => /* @__PURE__ */ p.jsxs(
32
32
  Ye,
33
33
  {
34
34
  className: w(
@@ -65,8 +65,8 @@ const ct = We(
65
65
  o && /* @__PURE__ */ p.jsx("div", { className: w("mt-2 flex justify-between gap-5", r == null ? void 0 : r.bottomContent), children: o })
66
66
  ] });
67
67
  var le = "Tabs", [ft, Ln] = Ze(le, [
68
- ve
69
- ]), _e = ve(), [pt, ue] = ft(le), Fe = P.forwardRef(
68
+ Re
69
+ ]), _e = Re(), [pt, ue] = ft(le), Fe = P.forwardRef(
70
70
  (e, o) => {
71
71
  const {
72
72
  __scopeTabs: t,
@@ -237,12 +237,12 @@ const Ct = ({ classes: e, contents: o }) => /* @__PURE__ */ p.jsx("div", { class
237
237
  animate: { opacity: 1 },
238
238
  exit: { opacity: 0 },
239
239
  transition: { duration: 0.3, ease: "easeInOut" }
240
- }, Rt = {
240
+ }, vt = {
241
241
  initial: { opacity: 0, scale: 0 },
242
242
  animate: { opacity: 1, scale: 1 },
243
243
  exit: { opacity: 0, scale: 0 },
244
244
  transition: { duration: 0.3, ease: "easeInOut" }
245
- }, vt = ({ title: e, closeModal: o, classes: t }) => /* @__PURE__ */ p.jsxs("div", { className: w("flex items-start justify-between gap-4", t == null ? void 0 : t.header), children: [
245
+ }, Rt = ({ title: e, closeModal: o, classes: t }) => /* @__PURE__ */ p.jsxs("div", { className: w("flex items-start justify-between gap-4", t == null ? void 0 : t.header), children: [
246
246
  e && /* @__PURE__ */ p.jsx(it, { as: "h3", className: w("flex-1 text-color-dark", t == null ? void 0 : t.title), children: e }),
247
247
  /* @__PURE__ */ p.jsx(
248
248
  N,
@@ -285,9 +285,9 @@ const Ct = ({ classes: e, contents: o }) => /* @__PURE__ */ p.jsx("div", { class
285
285
  l == null ? void 0 : l.modal
286
286
  ),
287
287
  "data-test-id": "modal",
288
- ...Rt,
288
+ ...vt,
289
289
  children: [
290
- /* @__PURE__ */ p.jsx(vt, { title: e, closeModal: i, classes: l == null ? void 0 : l.modalHeader }),
290
+ /* @__PURE__ */ p.jsx(Rt, { title: e, closeModal: i, classes: l == null ? void 0 : l.modalHeader }),
291
291
  /* @__PURE__ */ p.jsx("div", { className: w("mt-4", l == null ? void 0 : l.content), children: o })
292
292
  ]
293
293
  }
@@ -295,10 +295,10 @@ const Ct = ({ classes: e, contents: o }) => /* @__PURE__ */ p.jsx("div", { class
295
295
  }
296
296
  ) });
297
297
  return /* @__PURE__ */ p.jsx(p.Fragment, { children: n ? dt(s, r) : s });
298
- }, Ae = D((e, o) => /* @__PURE__ */ p.jsx("table", { ref: o, ...e }));
299
- Ae.displayName = "Table";
300
- const He = D((e, o) => /* @__PURE__ */ p.jsx("thead", { ref: o, ...e }));
301
- He.displayName = "TableHeader";
298
+ }, He = D((e, o) => /* @__PURE__ */ p.jsx("table", { ref: o, ...e }));
299
+ He.displayName = "Table";
300
+ const Ae = D((e, o) => /* @__PURE__ */ p.jsx("thead", { ref: o, ...e }));
301
+ Ae.displayName = "TableHeader";
302
302
  const Ge = D((e, o) => /* @__PURE__ */ p.jsx("tbody", { ref: o, ...e }));
303
303
  Ge.displayName = "TableBody";
304
304
  const xt = D((e, o) => /* @__PURE__ */ p.jsx("tfoot", { ref: o, ...e }));
@@ -369,14 +369,14 @@ function yt() {
369
369
  group: (e) => e
370
370
  };
371
371
  }
372
- function A(e, o) {
372
+ function H(e, o) {
373
373
  return typeof e == "function" ? e(o) : e;
374
374
  }
375
375
  function $(e, o) {
376
376
  return (t) => {
377
377
  o.setState((n) => ({
378
378
  ...n,
379
- [e]: A(t, n[e])
379
+ [e]: H(t, n[e])
380
380
  }));
381
381
  };
382
382
  }
@@ -569,22 +569,22 @@ function z(e, o, t, n) {
569
569
  id: [n, `${a}`].filter(Boolean).join("_"),
570
570
  headers: []
571
571
  }, h = [];
572
- c.forEach((R) => {
573
- const v = [...h].reverse()[0], x = R.column.depth === m.depth;
572
+ c.forEach((v) => {
573
+ const R = [...h].reverse()[0], x = v.column.depth === m.depth;
574
574
  let _, M = !1;
575
- if (x && R.column.parent ? _ = R.column.parent : (_ = R.column, M = !0), v && (v == null ? void 0 : v.column) === _)
576
- v.subHeaders.push(R);
575
+ if (x && v.column.parent ? _ = v.column.parent : (_ = v.column, M = !0), R && (R == null ? void 0 : R.column) === _)
576
+ R.subHeaders.push(v);
577
577
  else {
578
578
  const y = we(t, _, {
579
- id: [n, a, _.id, R == null ? void 0 : R.id].filter(Boolean).join("_"),
579
+ id: [n, a, _.id, v == null ? void 0 : v.id].filter(Boolean).join("_"),
580
580
  isPlaceholder: M,
581
581
  placeholderId: M ? `${h.filter((G) => G.column === _).length}` : void 0,
582
582
  depth: a,
583
583
  index: h.length
584
584
  });
585
- y.subHeaders.push(R), h.push(y);
585
+ y.subHeaders.push(v), h.push(y);
586
586
  }
587
- m.headers.push(R), R.headerGroup = m;
587
+ m.headers.push(v), v.headerGroup = m;
588
588
  }), s.push(m), a > 0 && g(h, a - 1);
589
589
  }, d = o.map((c, a) => we(t, c, {
590
590
  depth: l,
@@ -592,18 +592,18 @@ function z(e, o, t, n) {
592
592
  }));
593
593
  g(d, l - 1), s.reverse();
594
594
  const f = (c) => c.filter((m) => m.column.getIsVisible()).map((m) => {
595
- let h = 0, R = 0, v = [0];
596
- m.subHeaders && m.subHeaders.length ? (v = [], f(m.subHeaders).forEach((_) => {
595
+ let h = 0, v = 0, R = [0];
596
+ m.subHeaders && m.subHeaders.length ? (R = [], f(m.subHeaders).forEach((_) => {
597
597
  let {
598
598
  colSpan: M,
599
599
  rowSpan: y
600
600
  } = _;
601
- h += M, v.push(y);
601
+ h += M, R.push(y);
602
602
  })) : h = 1;
603
- const x = Math.min(...v);
604
- return R = R + x, m.colSpan = h, m.rowSpan = R, {
603
+ const x = Math.min(...R);
604
+ return v = v + x, m.colSpan = h, m.rowSpan = v, {
605
605
  colSpan: h,
606
- rowSpan: R
606
+ rowSpan: v
607
607
  };
608
608
  });
609
609
  return f((r = (i = s[0]) == null ? void 0 : i.headers) != null ? r : []), s;
@@ -759,8 +759,8 @@ const Et = {
759
759
  return (t = (n = o.getState().columnFilters) == null ? void 0 : n.findIndex((r) => r.id === e.id)) != null ? t : -1;
760
760
  }, e.setFilterValue = (t) => {
761
761
  o.setColumnFilters((n) => {
762
- const r = e.getFilterFn(), i = n == null ? void 0 : n.find((d) => d.id === e.id), l = A(t, i ? i.value : void 0);
763
- if (Re(r, l, e)) {
762
+ const r = e.getFilterFn(), i = n == null ? void 0 : n.find((d) => d.id === e.id), l = H(t, i ? i.value : void 0);
763
+ if (ve(r, l, e)) {
764
764
  var u;
765
765
  return (u = n == null ? void 0 : n.filter((d) => d.id !== e.id)) != null ? u : [];
766
766
  }
@@ -783,11 +783,11 @@ const Et = {
783
783
  e.setColumnFilters = (o) => {
784
784
  const t = e.getAllLeafColumns(), n = (r) => {
785
785
  var i;
786
- return (i = A(o, r)) == null ? void 0 : i.filter((l) => {
786
+ return (i = H(o, r)) == null ? void 0 : i.filter((l) => {
787
787
  const u = t.find((s) => s.id === l.id);
788
788
  if (u) {
789
789
  const s = u.getFilterFn();
790
- if (Re(s, l.value, u))
790
+ if (ve(s, l.value, u))
791
791
  return !1;
792
792
  }
793
793
  return !0;
@@ -800,13 +800,13 @@ const Et = {
800
800
  }, e.getPreFilteredRowModel = () => e.getCoreRowModel(), e.getFilteredRowModel = () => (!e._getFilteredRowModel && e.options.getFilteredRowModel && (e._getFilteredRowModel = e.options.getFilteredRowModel(e)), e.options.manualFiltering || !e._getFilteredRowModel ? e.getPreFilteredRowModel() : e._getFilteredRowModel());
801
801
  }
802
802
  };
803
- function Re(e, o, t) {
803
+ function ve(e, o, t) {
804
804
  return (e && e.autoRemove ? e.autoRemove(o, t) : !1) || typeof o > "u" || typeof o == "string" && !o;
805
805
  }
806
- const At = (e, o, t) => t.reduce((n, r) => {
806
+ const Ht = (e, o, t) => t.reduce((n, r) => {
807
807
  const i = r.getValue(e);
808
808
  return n + (typeof i == "number" ? i : 0);
809
- }, 0), Ht = (e, o, t) => {
809
+ }, 0), At = (e, o, t) => {
810
810
  let n;
811
811
  return t.forEach((r) => {
812
812
  const i = r.getValue(e);
@@ -841,8 +841,8 @@ const At = (e, o, t) => t.reduce((n, r) => {
841
841
  const n = Math.floor(t.length / 2), r = t.sort((i, l) => i - l);
842
842
  return t.length % 2 !== 0 ? r[n] : (r[n - 1] + r[n]) / 2;
843
843
  }, zt = (e, o) => Array.from(new Set(o.map((t) => t.getValue(e))).values()), bt = (e, o) => new Set(o.map((t) => t.getValue(e))).size, Tt = (e, o) => o.length, K = {
844
- sum: At,
845
- min: Ht,
844
+ sum: Ht,
845
+ min: At,
846
846
  max: Gt,
847
847
  extent: jt,
848
848
  mean: Lt,
@@ -1104,7 +1104,7 @@ const kt = {
1104
1104
  return (i) => {
1105
1105
  if (!n || !r || (i.persist == null || i.persist(), Y(i) && i.touches && i.touches.length > 1))
1106
1106
  return;
1107
- const l = e.getSize(), u = e ? e.getLeafHeaders().map((v) => [v.column.id, v.column.getSize()]) : [[n.id, n.getSize()]], s = Y(i) ? Math.round(i.touches[0].clientX) : i.clientX, g = {}, d = (v, x) => {
1107
+ const l = e.getSize(), u = e ? e.getLeafHeaders().map((R) => [R.column.id, R.column.getSize()]) : [[n.id, n.getSize()]], s = Y(i) ? Math.round(i.touches[0].clientX) : i.clientX, g = {}, d = (R, x) => {
1108
1108
  typeof x == "number" && (o.setColumnSizingInfo((_) => {
1109
1109
  var M, y;
1110
1110
  const G = o.options.columnResizeDirection === "rtl" ? -1 : 1, ce = (x - ((M = _ == null ? void 0 : _.startOffset) != null ? M : 0)) * G, fe = Math.max(ce / ((y = _ == null ? void 0 : _.startSize) != null ? y : 0), -0.999999);
@@ -1116,12 +1116,12 @@ const kt = {
1116
1116
  deltaOffset: ce,
1117
1117
  deltaPercentage: fe
1118
1118
  };
1119
- }), (o.options.columnResizeMode === "onChange" || v === "end") && o.setColumnSizing((_) => ({
1119
+ }), (o.options.columnResizeMode === "onChange" || R === "end") && o.setColumnSizing((_) => ({
1120
1120
  ..._,
1121
1121
  ...g
1122
1122
  })));
1123
- }, f = (v) => d("move", v), c = (v) => {
1124
- d("end", v), o.setColumnSizingInfo((x) => ({
1123
+ }, f = (R) => d("move", R), c = (R) => {
1124
+ d("end", R), o.setColumnSizingInfo((x) => ({
1125
1125
  ...x,
1126
1126
  isResizingColumn: !1,
1127
1127
  startOffset: null,
@@ -1131,21 +1131,21 @@ const kt = {
1131
1131
  columnSizingStart: []
1132
1132
  }));
1133
1133
  }, a = t || typeof document < "u" ? document : null, m = {
1134
- moveHandler: (v) => f(v.clientX),
1135
- upHandler: (v) => {
1136
- a == null || a.removeEventListener("mousemove", m.moveHandler), a == null || a.removeEventListener("mouseup", m.upHandler), c(v.clientX);
1134
+ moveHandler: (R) => f(R.clientX),
1135
+ upHandler: (R) => {
1136
+ a == null || a.removeEventListener("mousemove", m.moveHandler), a == null || a.removeEventListener("mouseup", m.upHandler), c(R.clientX);
1137
1137
  }
1138
1138
  }, h = {
1139
- moveHandler: (v) => (v.cancelable && (v.preventDefault(), v.stopPropagation()), f(v.touches[0].clientX), !1),
1140
- upHandler: (v) => {
1139
+ moveHandler: (R) => (R.cancelable && (R.preventDefault(), R.stopPropagation()), f(R.touches[0].clientX), !1),
1140
+ upHandler: (R) => {
1141
1141
  var x;
1142
- a == null || a.removeEventListener("touchmove", h.moveHandler), a == null || a.removeEventListener("touchend", h.upHandler), v.cancelable && (v.preventDefault(), v.stopPropagation()), c((x = v.touches[0]) == null ? void 0 : x.clientX);
1142
+ a == null || a.removeEventListener("touchmove", h.moveHandler), a == null || a.removeEventListener("touchend", h.upHandler), R.cancelable && (R.preventDefault(), R.stopPropagation()), c((x = R.touches[0]) == null ? void 0 : x.clientX);
1143
1143
  }
1144
- }, R = Kt() ? {
1144
+ }, v = Kt() ? {
1145
1145
  passive: !1
1146
1146
  } : !1;
1147
- Y(i) ? (a == null || a.addEventListener("touchmove", h.moveHandler, R), a == null || a.addEventListener("touchend", h.upHandler, R)) : (a == null || a.addEventListener("mousemove", m.moveHandler, R), a == null || a.addEventListener("mouseup", m.upHandler, R)), o.setColumnSizingInfo((v) => ({
1148
- ...v,
1147
+ Y(i) ? (a == null || a.addEventListener("touchmove", h.moveHandler, v), a == null || a.addEventListener("touchend", h.upHandler, v)) : (a == null || a.addEventListener("mousemove", m.moveHandler, v), a == null || a.addEventListener("mouseup", m.upHandler, v)), o.setColumnSizingInfo((R) => ({
1148
+ ...R,
1149
1149
  startOffset: s,
1150
1150
  startSize: l,
1151
1151
  deltaOffset: 0,
@@ -1404,14 +1404,14 @@ const Wt = {
1404
1404
  });
1405
1405
  }
1406
1406
  }, e.setPagination = (n) => {
1407
- const r = (i) => A(n, i);
1407
+ const r = (i) => H(n, i);
1408
1408
  return e.options.onPaginationChange == null ? void 0 : e.options.onPaginationChange(r);
1409
1409
  }, e.resetPagination = (n) => {
1410
1410
  var r;
1411
1411
  e.setPagination(n ? J() : (r = e.initialState.pagination) != null ? r : J());
1412
1412
  }, e.setPageIndex = (n) => {
1413
1413
  e.setPagination((r) => {
1414
- let i = A(n, r.pageIndex);
1414
+ let i = H(n, r.pageIndex);
1415
1415
  const l = typeof e.options.pageCount > "u" || e.options.pageCount === -1 ? Number.MAX_SAFE_INTEGER : e.options.pageCount - 1;
1416
1416
  return i = Math.max(0, Math.min(i, l)), {
1417
1417
  ...r,
@@ -1426,7 +1426,7 @@ const Wt = {
1426
1426
  e.setPageSize(n ? ne : (r = (i = e.initialState) == null || (i = i.pagination) == null ? void 0 : i.pageSize) != null ? r : ne);
1427
1427
  }, e.setPageSize = (n) => {
1428
1428
  e.setPagination((r) => {
1429
- const i = Math.max(1, A(n, r.pageSize)), l = r.pageSize * r.pageIndex, u = Math.floor(l / i);
1429
+ const i = Math.max(1, H(n, r.pageSize)), l = r.pageSize * r.pageIndex, u = Math.floor(l / i);
1430
1430
  return {
1431
1431
  ...r,
1432
1432
  pageIndex: u,
@@ -1435,7 +1435,7 @@ const Wt = {
1435
1435
  });
1436
1436
  }, e.setPageCount = (n) => e.setPagination((r) => {
1437
1437
  var i;
1438
- let l = A(n, (i = e.options.pageCount) != null ? i : -1);
1438
+ let l = H(n, (i = e.options.pageCount) != null ? i : -1);
1439
1439
  return typeof l == "number" && (l = Math.max(-1, l)), {
1440
1440
  ...r,
1441
1441
  pageCount: l
@@ -1716,14 +1716,14 @@ function re(e, o, t) {
1716
1716
  }
1717
1717
  }), r ? "all" : i ? "some" : !1;
1718
1718
  }
1719
- const ie = /([0-9]+)/gm, tn = (e, o, t) => qe(H(e.getValue(t)).toLowerCase(), H(o.getValue(t)).toLowerCase()), nn = (e, o, t) => qe(H(e.getValue(t)), H(o.getValue(t))), on = (e, o, t) => de(H(e.getValue(t)).toLowerCase(), H(o.getValue(t)).toLowerCase()), rn = (e, o, t) => de(H(e.getValue(t)), H(o.getValue(t))), ln = (e, o, t) => {
1719
+ const ie = /([0-9]+)/gm, tn = (e, o, t) => qe(A(e.getValue(t)).toLowerCase(), A(o.getValue(t)).toLowerCase()), nn = (e, o, t) => qe(A(e.getValue(t)), A(o.getValue(t))), on = (e, o, t) => de(A(e.getValue(t)).toLowerCase(), A(o.getValue(t)).toLowerCase()), rn = (e, o, t) => de(A(e.getValue(t)), A(o.getValue(t))), ln = (e, o, t) => {
1720
1720
  const n = e.getValue(t), r = o.getValue(t);
1721
1721
  return n > r ? 1 : n < r ? -1 : 0;
1722
1722
  }, un = (e, o, t) => de(e.getValue(t), o.getValue(t));
1723
1723
  function de(e, o) {
1724
1724
  return e === o ? 0 : e > o ? 1 : -1;
1725
1725
  }
1726
- function H(e) {
1726
+ function A(e) {
1727
1727
  return typeof e == "number" ? isNaN(e) || e === 1 / 0 || e === -1 / 0 ? "" : String(e) : typeof e == "string" ? e : "";
1728
1728
  }
1729
1729
  function qe(e, o) {
@@ -1903,7 +1903,7 @@ function gn(e) {
1903
1903
  r.setState(r.initialState);
1904
1904
  },
1905
1905
  setOptions: (c) => {
1906
- const a = A(c, r.options);
1906
+ const a = H(c, r.options);
1907
1907
  r.options = l(a);
1908
1908
  },
1909
1909
  getState: () => r.options.state,
@@ -1934,8 +1934,8 @@ function gn(e) {
1934
1934
  },
1935
1935
  // footer: props => props.header.column.id,
1936
1936
  cell: (m) => {
1937
- var h, R;
1938
- return (h = (R = m.renderValue()) == null || R.toString == null ? void 0 : R.toString()) != null ? h : null;
1937
+ var h, v;
1938
+ return (h = (v = m.renderValue()) == null || v.toString == null ? void 0 : v.toString()) != null ? h : null;
1939
1939
  },
1940
1940
  ...r._features.reduce((m, h) => Object.assign(m, h.getDefaultColumnDef == null ? void 0 : h.getDefaultColumnDef()), {}),
1941
1941
  ...c
@@ -1943,10 +1943,10 @@ function gn(e) {
1943
1943
  }, C(e, "debugColumns", "_getDefaultColumnDef")),
1944
1944
  _getColumnDefs: () => r.options.columns,
1945
1945
  getAllColumns: S(() => [r._getColumnDefs()], (c) => {
1946
- const a = function(m, h, R) {
1947
- return R === void 0 && (R = 0), m.map((v) => {
1948
- const x = It(r, v, R, h), _ = v;
1949
- return x.columns = _.columns ? a(_.columns, x, R + 1) : [], x;
1946
+ const a = function(m, h, v) {
1947
+ return v === void 0 && (v = 0), m.map((R) => {
1948
+ const x = It(r, R, v, h), _ = R;
1949
+ return x.columns = _.columns ? a(_.columns, x, v + 1) : [], x;
1950
1950
  });
1951
1951
  };
1952
1952
  return a(c);
@@ -2131,16 +2131,16 @@ function Sn() {
2131
2131
  for (let m = 0; m < r.length; m++) {
2132
2132
  g = r[m];
2133
2133
  const h = g.id;
2134
- a.columnFilters[h] = g.filterFn(a, h, g.resolvedValue, (R) => {
2135
- a.columnFiltersMeta[h] = R;
2134
+ a.columnFilters[h] = g.filterFn(a, h, g.resolvedValue, (v) => {
2135
+ a.columnFiltersMeta[h] = v;
2136
2136
  });
2137
2137
  }
2138
2138
  if (i.length) {
2139
2139
  for (let m = 0; m < i.length; m++) {
2140
2140
  d = i[m];
2141
2141
  const h = d.id;
2142
- if (d.filterFn(a, h, d.resolvedValue, (R) => {
2143
- a.columnFiltersMeta[h] = R;
2142
+ if (d.filterFn(a, h, d.resolvedValue, (v) => {
2143
+ a.columnFiltersMeta[h] = v;
2144
2144
  })) {
2145
2145
  a.columnFilters.__global__ = !0;
2146
2146
  break;
@@ -2212,18 +2212,18 @@ function wn() {
2212
2212
  return g.sort((d, f) => {
2213
2213
  for (let a = 0; a < i.length; a += 1) {
2214
2214
  var c;
2215
- const m = i[a], h = l[m.id], R = h.sortUndefined, v = (c = m == null ? void 0 : m.desc) != null ? c : !1;
2215
+ const m = i[a], h = l[m.id], v = h.sortUndefined, R = (c = m == null ? void 0 : m.desc) != null ? c : !1;
2216
2216
  let x = 0;
2217
- if (R) {
2217
+ if (v) {
2218
2218
  const _ = d.getValue(m.id), M = f.getValue(m.id), y = _ === void 0, G = M === void 0;
2219
2219
  if (y || G) {
2220
- if (R === "first") return y ? -1 : 1;
2221
- if (R === "last") return y ? 1 : -1;
2222
- x = y && G ? 0 : y ? R : -R;
2220
+ if (v === "first") return y ? -1 : 1;
2221
+ if (v === "last") return y ? 1 : -1;
2222
+ x = y && G ? 0 : y ? v : -v;
2223
2223
  }
2224
2224
  }
2225
2225
  if (x === 0 && (x = h.sortingFn(d, f, m.id)), x !== 0)
2226
- return v && (x *= -1), h.invertSorting && (x *= -1), x;
2226
+ return R && (x *= -1), h.invertSorting && (x *= -1), x;
2227
2227
  }
2228
2228
  return d.index - f.index;
2229
2229
  }), g.forEach((d) => {
@@ -2249,12 +2249,12 @@ function wn() {
2249
2249
  * @license MIT
2250
2250
  */
2251
2251
  function B(e, o) {
2252
- return e ? Rn(e) ? /* @__PURE__ */ P.createElement(e, o) : e : null;
2253
- }
2254
- function Rn(e) {
2255
- return vn(e) || typeof e == "function" || xn(e);
2252
+ return e ? vn(e) ? /* @__PURE__ */ P.createElement(e, o) : e : null;
2256
2253
  }
2257
2254
  function vn(e) {
2255
+ return Rn(e) || typeof e == "function" || xn(e);
2256
+ }
2257
+ function Rn(e) {
2258
2258
  return typeof e == "function" && (() => {
2259
2259
  const o = Object.getPrototypeOf(e);
2260
2260
  return o.prototype && o.prototype.isReactComponent;
@@ -2418,8 +2418,8 @@ const Fn = ({
2418
2418
  classes: n == null ? void 0 : n.pagination
2419
2419
  };
2420
2420
  return /* @__PURE__ */ p.jsxs("div", { className: w("flex w-full flex-col gap-y-4", n == null ? void 0 : n.root), children: [
2421
- /* @__PURE__ */ p.jsxs(Ae, { className: w("w-full", n == null ? void 0 : n.table), children: [
2422
- o && /* @__PURE__ */ p.jsx(He, { className: "px-2", children: t.getHeaderGroups().map((u) => /* @__PURE__ */ p.jsx(
2421
+ /* @__PURE__ */ p.jsxs(He, { className: w("w-full", n == null ? void 0 : n.table), children: [
2422
+ o && /* @__PURE__ */ p.jsx(Ae, { className: "px-2", children: t.getHeaderGroups().map((u) => /* @__PURE__ */ p.jsx(
2423
2423
  O,
2424
2424
  {
2425
2425
  className: w(
@@ -2618,52 +2618,51 @@ const On = ({ maxToastViewLimit: e = 2, toastDuration: o = 5e3 }) => {
2618
2618
  )
2619
2619
  ]
2620
2620
  }
2621
- ) : /* @__PURE__ */ p.jsx("div", { "aria-current": "page", className: "desk-body-regular-m text-color-blue-grey-600", children: o.label }) })) }), kn = (e) => !!e && !Array.isArray(e);
2621
+ ) : /* @__PURE__ */ p.jsx("div", { "aria-current": "page", className: "desk-body-regular-m text-color-blue-grey-600", children: o.label }) })) });
2622
2622
  export {
2623
2623
  rt as Accordion,
2624
- Kn as Badge,
2624
+ Un as Badge,
2625
2625
  Bn as Breadcrumbs,
2626
2626
  E as Button,
2627
- An as ButtonIcon,
2628
- Xn as Calendar,
2629
- Wn as Controlled,
2630
- Yn as CustomLink,
2631
- so as DATE_VISIBLE_PATTERN,
2627
+ Hn as ButtonIcon,
2628
+ Kn as Calendar,
2629
+ Xn as Controlled,
2630
+ Wn as CustomLink,
2631
+ uo as DATE_VISIBLE_PATTERN,
2632
2632
  bn as DataTable,
2633
2633
  Ft as DataTableColumnHeader,
2634
2634
  Gn as FloatButton,
2635
2635
  it as Heading,
2636
- Jn as Hint,
2636
+ Yn as Hint,
2637
2637
  N as Icon,
2638
- Qn as KeyboardShortcuts,
2639
- Zn as Loader,
2638
+ Jn as KeyboardShortcuts,
2639
+ Qn as Loader,
2640
2640
  zn as Modal,
2641
- eo as Notification,
2641
+ Zn as Notification,
2642
2642
  On as NotificationProvider,
2643
2643
  Fn as Pagination,
2644
- to as PhoneView,
2645
- no as Popover,
2644
+ eo as PhoneView,
2645
+ to as Popover,
2646
2646
  jn as ProgressBar,
2647
2647
  Ye as ResponsiveContainer,
2648
- oo as Section,
2649
- Hn as Skeleton,
2650
- ro as Slot,
2651
- Ae as Table,
2648
+ An as Skeleton,
2649
+ no as Slot,
2650
+ He as Table,
2652
2651
  Ge as TableBody,
2653
2652
  _t as TableCaption,
2654
2653
  ee as TableCell,
2655
2654
  xt as TableFooter,
2656
2655
  je as TableHead,
2657
- He as TableHeader,
2656
+ Ae as TableHeader,
2658
2657
  O as TableRow,
2659
2658
  Tn as TableUtils,
2660
2659
  Nn as TabsSwitcher,
2661
- io as Uncontrolled,
2662
- lo as brandLogos,
2663
- ao as defaultClassNames,
2664
- go as formatDateToLocaleString,
2665
- co as formatDateToMonthString,
2666
- fo as formatDateToYearString,
2667
- kn as isSingleOption
2660
+ oo as Uncontrolled,
2661
+ ro as brandLogos,
2662
+ so as defaultClassNames,
2663
+ ao as formatDateToLocaleString,
2664
+ go as formatDateToMonthString,
2665
+ co as formatDateToYearString,
2666
+ io as isSingleOption
2668
2667
  };
2669
2668
  //# sourceMappingURL=ui.js.map