prometeo-design-system 1.9.5 → 1.9.7

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 (50) hide show
  1. package/dist/Avatar.es.js +1 -1
  2. package/dist/Button.es.js +1 -1
  3. package/dist/{CardProfile-Bg_q2qMm.js → CardProfile-BZajBGbO.js} +1 -1
  4. package/dist/CardProfile.es.js +1 -1
  5. package/dist/CheckBox.es.js +1 -1
  6. package/dist/CheckboxFormik.es.js +1 -1
  7. package/dist/DialogModal.es.js +39 -45
  8. package/dist/DrawerDesktop.es.js +1 -1
  9. package/dist/DrawerMobile.es.js +1 -1
  10. package/dist/DropZone.es.js +1 -1
  11. package/dist/Header.es.js +1 -1
  12. package/dist/Icons.es.js +1 -1
  13. package/dist/Input.es.js +1 -1
  14. package/dist/InputFormik.es.js +1 -1
  15. package/dist/InputMultiple.es.js +1 -1
  16. package/dist/{LayoutGeneric-p4Pll4Cm.js → LayoutGeneric-jDE96L2N.js} +1 -1
  17. package/dist/LayoutGeneric.es.js +1 -1
  18. package/dist/Logo.es.js +1 -1
  19. package/dist/Menu.es.js +1 -1
  20. package/dist/OtpInput.es.js +1 -1
  21. package/dist/Pagination.es.js +1 -1
  22. package/dist/ProfilePictureUpload.es.js +1 -1
  23. package/dist/ProgressBar.es.js +1 -1
  24. package/dist/Select.es.js +1 -1
  25. package/dist/SelectFormik.es.js +45 -47
  26. package/dist/Skeleton.d.ts +2 -0
  27. package/dist/Skeleton.es.js +71 -0
  28. package/dist/Spinner.es.js +1 -1
  29. package/dist/Steps.es.js +1 -1
  30. package/dist/SwipeContainer.es.js +1 -1
  31. package/dist/Switch.es.js +13 -13
  32. package/dist/TabLinks.es.js +1 -1
  33. package/dist/Table.es.js +1 -1
  34. package/dist/TextArea.es.js +1 -1
  35. package/dist/Tooltip.es.js +1 -1
  36. package/dist/components/Dialog/Dialog.d.ts +1 -0
  37. package/dist/components/SegmentedButton/SegmentedButton.d.ts +20 -0
  38. package/dist/components/Sidebar/components/nav-actions.d.ts +1 -1
  39. package/dist/components/Sidebar/hooks/useNavLinks.d.ts +5 -5
  40. package/dist/components/Skeleton/Skeleton.d.ts +10 -0
  41. package/dist/exports/SegmentedButton.d.ts +1 -0
  42. package/dist/exports/Skeleton.d.ts +1 -0
  43. package/dist/index.d.ts +4 -0
  44. package/dist/{jsx-runtime-DKDX3adD.js → jsx-runtime-ByW6EXIE.js} +96 -94
  45. package/dist/pages/Buttons.d.ts +2 -0
  46. package/dist/pages/Skeletons.d.ts +2 -0
  47. package/dist/preview/Layout.d.ts +2 -0
  48. package/dist/prometeo-design-system.css +1 -1
  49. package/dist/prometeo-design-system.es.js +548 -362
  50. package/package.json +9 -1
package/dist/Avatar.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as p } from "./cn-B6yFEsav.js";
3
3
  import { motion as f } from "framer-motion";
4
4
  import { useState as u } from "react";
package/dist/Button.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as o } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as o } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as x } from "./cn-B6yFEsav.js";
3
3
  import { c as N } from "./index-BOQuZ0gG.js";
4
4
  import { useAnimationControls as k, motion as y } from "framer-motion";
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as l } from "./cn-B6yFEsav.js";
3
3
  import { motion as i, AnimatePresence as u } from "framer-motion";
4
4
  import m from "./Avatar.es.js";
@@ -1,4 +1,4 @@
1
- import { C as a } from "./CardProfile-Bg_q2qMm.js";
1
+ import { C as a } from "./CardProfile-BZajBGbO.js";
2
2
  export {
3
3
  a as CardProfile
4
4
  };
@@ -1,4 +1,4 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as l } from "./Icons.es.js";
3
3
  import { useId as o, useRef as d } from "react";
4
4
  const k = ({ className: s, disabled: e, ...a }) => {
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as x } from "./Icons.es.js";
3
3
  import { c as r } from "./cn-B6yFEsav.js";
4
4
  import { useField as h, ErrorMessage as p } from "formik";
@@ -1,46 +1,40 @@
1
- import { j as s } from "./jsx-runtime-DKDX3adD.js";
2
- import { forwardRef as f, useState as g, useCallback as x, useMemo as m, useImperativeHandle as j, useRef as D } from "react";
3
- import { c as d } from "./cn-B6yFEsav.js";
4
- const u = f(
5
- ({ children: e, onClose: o, className: r }, l) => {
6
- const [t, a] = g(!1), i = x(() => a(!0), []), n = () => {
7
- a(!1), o?.();
8
- }, c = m(
9
- () => ({
10
- open: i,
11
- close: n,
12
- isOpen: t
13
- }),
14
- [i, n, t]
15
- );
16
- return j(l, () => c, [c]), /* @__PURE__ */ s.jsx(s.Fragment, { children: t && /* @__PURE__ */ s.jsx(
17
- "div",
18
- {
19
- className: "fixed inset-0 z-50 flex items-center justify-center bg-black/30 backdrop-blur-[1.5px]",
20
- onClick: n,
21
- children: /* @__PURE__ */ s.jsx(
22
- "div",
23
- {
24
- className: d(
25
- "bg-neutral-default-default w-3/4 h-3/4 xl:w-3/4 xl:h-10/12 rounded-lg shadow-lg border-neutral-strong-default border relative p-6",
26
- r
27
- ),
28
- onClick: (p) => p.stopPropagation(),
29
- children: e
30
- }
31
- )
32
- }
33
- ) });
34
- }
35
- ), b = ({ children: e, className: o }) => /* @__PURE__ */ s.jsx("div", { className: o, children: /* @__PURE__ */ s.jsx("div", { className: d("flex flex-col gap-4"), children: e }) }), h = ({ children: e, className: o }) => /* @__PURE__ */ s.jsx("h1", { className: o, children: e }), v = ({ children: e, className: o }) => /* @__PURE__ */ s.jsx("div", { className: o, children: e }), C = ({ children: e, className: o }) => /* @__PURE__ */ s.jsx("div", { className: o, children: e }), N = Object.assign(u, {
36
- Content: b,
37
- Header: v,
38
- Footer: C,
39
- Title: h
40
- });
41
- u.displayName = "Dialog";
42
- const R = () => {
43
- const e = D(null);
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
+ import { forwardRef as u, useState as p, useImperativeHandle as f, useRef as g } from "react";
3
+ import { c as i } from "./cn-B6yFEsav.js";
4
+ const x = u(({
5
+ children: e,
6
+ onClose: o,
7
+ className: s
8
+ }, n) => {
9
+ const [r, l] = p(!1), c = () => l(!0), a = () => {
10
+ l(!1), o?.();
11
+ };
12
+ return f(n, () => ({
13
+ open: c,
14
+ close: a,
15
+ isOpen: r
16
+ })), /* @__PURE__ */ t.jsx(t.Fragment, { children: r && /* @__PURE__ */ t.jsx(
17
+ "div",
18
+ {
19
+ className: "fixed inset-0 z-50 flex items-center justify-center bg-black/30 backdrop-blur-[1.5px]",
20
+ onClick: a,
21
+ children: /* @__PURE__ */ t.jsx(
22
+ "div",
23
+ {
24
+ className: i("bg-neutral-default-default w-3/4 h-3/4 xl:w-3/4 xl:h-10/12 rounded-lg shadow-lg border-neutral-strong-default border relative p-6", s),
25
+ onClick: (d) => d.stopPropagation(),
26
+ children: e
27
+ }
28
+ )
29
+ }
30
+ ) });
31
+ }), m = ({ children: e, className: o }) => /* @__PURE__ */ t.jsx("div", { className: o, children: /* @__PURE__ */ t.jsx("div", { className: i("flex flex-col gap-4"), children: e }) }), j = ({ children: e, className: o }) => /* @__PURE__ */ t.jsx("h1", { className: o, children: e }), D = ({ children: e, className: o }) => /* @__PURE__ */ t.jsx("div", { className: o, children: e }), b = ({ children: e, className: o }) => /* @__PURE__ */ t.jsx("div", { className: o, children: e }), C = Object.assign(x, {
32
+ Content: m,
33
+ Header: D,
34
+ Footer: b,
35
+ Title: j
36
+ }), k = () => {
37
+ const e = g(null);
44
38
  return {
45
39
  ref: e,
46
40
  open: () => {
@@ -53,6 +47,6 @@ const R = () => {
53
47
  };
54
48
  };
55
49
  export {
56
- N as default,
57
- R as useDialogControl
50
+ C as default,
51
+ k as useDialogControl
58
52
  };
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as j } from "./Icons.es.js";
3
3
  import { c as m } from "./cn-B6yFEsav.js";
4
4
  import { c as d } from "./index-BOQuZ0gG.js";
@@ -1,4 +1,4 @@
1
- import { j as r } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as r } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { forwardRef as O, useState as g, useRef as x, useCallback as t, useImperativeHandle as D } from "react";
3
3
  import { Drawer as n } from "vaul";
4
4
  import { c as R } from "./cn-B6yFEsav.js";
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as i } from "./cn-B6yFEsav.js";
3
3
  import w, { useCallback as z } from "react";
4
4
  import { useDropzone as R } from "react-dropzone";
package/dist/Header.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as x } from "./cn-B6yFEsav.js";
3
3
  import { motion as i } from "framer-motion";
4
4
  import { memo as m } from "react";
package/dist/Icons.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as q } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as q } from "./jsx-runtime-ByW6EXIE.js";
2
2
  const l = ({
3
3
  size: t = 24,
4
4
  className: h,
package/dist/Input.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as O } from "./Icons.es.js";
3
3
  import { c as e } from "./cn-B6yFEsav.js";
4
4
  import { memo as ue, useState as N, useRef as ce, useCallback as fe, useEffect as $, useLayoutEffect as ie } from "react";
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as u } from "./cn-B6yFEsav.js";
3
3
  import { FastField as O, ErrorMessage as q } from "formik";
4
4
  import { memo as G, useState as I, useRef as H, useCallback as y, useLayoutEffect as J } from "react";
@@ -1,4 +1,4 @@
1
- import { j as r } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as r } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as E } from "./Icons.es.js";
3
3
  import { c as d } from "./cn-B6yFEsav.js";
4
4
  import M, { useRef as D, useState as p, useCallback as W, useEffect as X } from "react";
@@ -1,4 +1,4 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { useRef as a, createContext as i, useContext as u, memo as c } from "react";
3
3
  const o = i(null), l = ({ children: e }) => {
4
4
  const r = a(null), s = (n) => {
@@ -1,4 +1,4 @@
1
- import { L as f } from "./LayoutGeneric-p4Pll4Cm.js";
1
+ import { L as f } from "./LayoutGeneric-jDE96L2N.js";
2
2
  export {
3
3
  f as default
4
4
  };
package/dist/Logo.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as t } from "./Icons.es.js";
3
3
  const s = () => /* @__PURE__ */ e.jsxs("div", { className: "container-logo flex items-center justify-center gap-1 bg-gradient-to-br from-[#312C85] to-[#1E1A4D] rounded-md min-w-[185px]", children: [
4
4
  /* @__PURE__ */ e.jsx(t.TicketFilled, { size: 28, className: "rotate-140 text-primary-medium-pressed icon-logo" }),
package/dist/Menu.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as r } from "./cn-B6yFEsav.js";
3
3
  import { AnimatePresence as n, motion as o } from "framer-motion";
4
4
  const s = ({ menuRef: t, children: a, className: i }) => /* @__PURE__ */ e.jsx("div", { ref: t, className: r("flex bg-neutral-default-default absolute bottom-10 left-24 border-1 border-neutral-strong-default h-auto w-60 rounded-md px-2", i), children: /* @__PURE__ */ e.jsx(n, { mode: "wait", children: /* @__PURE__ */ e.jsx(
@@ -1,4 +1,4 @@
1
- import { j as p } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as p } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as ve } from "./Icons.es.js";
3
3
  import { c as L } from "./cn-B6yFEsav.js";
4
4
  import * as n from "react";
@@ -1,4 +1,4 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { motion as a } from "framer-motion";
3
3
  function h({
4
4
  currentPage: i = 1,
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { motion as i, AnimatePresence as E } from "framer-motion";
3
3
  import { useRef as v, useState as R, useLayoutEffect as A } from "react";
4
4
  import H from "./Avatar.es.js";
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as x } from "./cn-B6yFEsav.js";
3
3
  import u from "react";
4
4
  const j = u.forwardRef(
package/dist/Select.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { Icons as w } from "./Icons.es.js";
3
3
  import { c as o } from "./cn-B6yFEsav.js";
4
4
  import { memo as se, useState as y, useRef as re, useEffect as oe } from "react";
@@ -1,41 +1,41 @@
1
- import { j as t } from "./jsx-runtime-DKDX3adD.js";
2
- import { Icons as v } from "./Icons.es.js";
3
- import { c as o } from "./cn-B6yFEsav.js";
1
+ import { j as t } from "./jsx-runtime-ByW6EXIE.js";
2
+ import { Icons as h } from "./Icons.es.js";
3
+ import { c as i } from "./cn-B6yFEsav.js";
4
4
  import { useField as P, ErrorMessage as M } from "formik";
5
5
  import { useState as w, useRef as R, useEffect as L } from "react";
6
6
  import B from "./Spinner.es.js";
7
7
  const T = ({
8
8
  label: N,
9
9
  name: A,
10
- placeholder: b = "",
11
- disabled: c,
10
+ placeholder: v = "",
11
+ disabled: g,
12
12
  containerClassName: k,
13
13
  className: C,
14
- options: u = [],
14
+ options: o = [],
15
15
  multiple: n = !1,
16
16
  emptyMessage: D = "No hay opciones disponibles",
17
- labelVariant: g = "default",
17
+ labelVariant: b = "default",
18
18
  isFetching: O = !1
19
19
  }) => {
20
- const [a, y, i] = P(A), [l, f] = w(!1), [m, j] = w(!1), x = R(null), p = y.touched && y.error, d = a.value && (Array.isArray(a.value) ? a.value.length > 0 : a.value.toString().length > 0), S = () => g === "static" || d || l || m ? "-top-3 left-2 scale-90" : "top-1/2 -translate-y-1/2 scale-100", V = () => a.value ? Array.isArray(a.value) ? u.filter((e) => a.value.includes(e.id)) : u.filter((e) => e.id === a.value) : [], z = (e) => {
20
+ const [r, y, u] = P(A), [l, c] = w(!1), [f, j] = w(!1), m = R(null), x = y.touched && y.error, d = r.value && (Array.isArray(r.value) ? r.value.length > 0 : r.value.toString().length > 0), S = () => b === "static" || d || l || f ? "-top-3 left-2 scale-90" : "top-1/2 -translate-y-1/2 scale-100", V = () => r.value ? Array.isArray(r.value) ? o.filter((e) => r.value.includes(e.id)) : o.filter((e) => e.id === r.value) : [], z = (e) => {
21
21
  if (n) {
22
- const r = Array.isArray(a.value) ? a.value : [], s = r.includes(e.id) ? r.filter((h) => h !== e.id) : [...r, e.id];
23
- i.setValue(s);
22
+ const a = Array.isArray(r.value) ? r.value : [], s = a.includes(e.id) ? a.filter((p) => p !== e.id) : [...a, e.id];
23
+ u.setValue(s);
24
24
  } else
25
- i.setValue(e.id), f(!1);
25
+ u.setValue(e.id), c(!1);
26
26
  }, E = (e) => {
27
- e.stopPropagation(), i.setValue(n ? [] : "");
28
- }, F = (e, r) => {
29
- if (r?.stopPropagation(), n && Array.isArray(a.value)) {
30
- const s = a.value.filter(
31
- (h) => h !== e
27
+ e.stopPropagation(), u.setValue(n ? [] : "");
28
+ }, F = (e, a) => {
29
+ if (a?.stopPropagation(), n && Array.isArray(r.value)) {
30
+ const s = r.value.filter(
31
+ (p) => p !== e
32
32
  );
33
- i.setValue(s);
33
+ u.setValue(s);
34
34
  }
35
35
  };
36
36
  L(() => {
37
- const e = (r) => {
38
- x.current && !x.current.contains(r.target) && f(!1);
37
+ const e = (a) => {
38
+ m.current && !m.current.contains(a.target) && c(!1);
39
39
  };
40
40
  return l && document.addEventListener("mousedown", e), () => {
41
41
  document.removeEventListener("mousedown", e);
@@ -43,61 +43,59 @@ const T = ({
43
43
  }, [l]);
44
44
  const I = () => {
45
45
  const e = V();
46
- return e.length === 0 ? b ? /* @__PURE__ */ t.jsx("span", { className: "text-neutral-medium-default opacity-50", children: b }) : null : n ? /* @__PURE__ */ t.jsx("div", { className: "flex items-center gap-1 flex-wrap py-1", children: e.map((r) => /* @__PURE__ */ t.jsxs(
46
+ return e.length === 0 ? v ? /* @__PURE__ */ t.jsx("span", { className: "text-neutral-medium-default opacity-50", children: v }) : null : n ? /* @__PURE__ */ t.jsx("div", { className: "flex items-center gap-1 flex-wrap py-1", children: e.map((a) => /* @__PURE__ */ t.jsxs(
47
47
  "div",
48
48
  {
49
49
  className: "inline-flex items-center gap-1 px-2 py-1 bg-primary-default-default text-white text-xs rounded-md",
50
50
  children: [
51
- /* @__PURE__ */ t.jsx("span", { className: "truncate max-w-20", children: r.label }),
51
+ /* @__PURE__ */ t.jsx("span", { className: "truncate max-w-20", children: a.label }),
52
52
  /* @__PURE__ */ t.jsx(
53
53
  "button",
54
54
  {
55
55
  onMouseDown: (s) => {
56
- s.preventDefault(), F(r.id, s);
56
+ s.preventDefault(), F(a.id, s);
57
57
  },
58
58
  className: "flex-shrink-0 hover:bg-primary-strong-default rounded-sm p-0.5 transition-colors",
59
59
  type: "button",
60
60
  tabIndex: -1,
61
- children: /* @__PURE__ */ t.jsx(v.Close, { size: 12, className: "" })
61
+ children: /* @__PURE__ */ t.jsx(h.Close, { size: 12, className: "" })
62
62
  }
63
63
  )
64
64
  ]
65
65
  },
66
- r.id
66
+ a.id
67
67
  )) }) : /* @__PURE__ */ t.jsx("span", { children: e[0]?.label });
68
68
  };
69
69
  return /* @__PURE__ */ t.jsxs(
70
70
  "div",
71
71
  {
72
- className: o("relative w-full bg-inherit", k),
73
- ref: x,
72
+ className: i("relative w-full bg-inherit", k),
73
+ ref: m,
74
74
  children: [
75
75
  /* @__PURE__ */ t.jsxs("div", { className: "relative bg-inherit", children: [
76
76
  /* @__PURE__ */ t.jsxs(
77
- "button",
77
+ "div",
78
78
  {
79
- type: "button",
80
- disabled: c,
81
- onClick: () => !c && f(!l),
79
+ onClick: () => !g && c(!l),
82
80
  onFocus: () => j(!0),
83
81
  onBlur: () => j(!1),
84
- className: o(
85
- "w-full px-3 h-12 text-left border-1 rounded-lg transition-all duration-200 ease-in-out text-neutral-default-default",
82
+ className: i(
83
+ "w-full px-3 h-12 text-left border-1 rounded-lg transition-all duration-300 ease-in-out text-neutral-default-default",
86
84
  "flex items-center justify-between bg-transparent focus:outline-none",
87
- d || l || m ? "border-primary-default-default border-2" : p ? "border-error-default-default" : "border-neutral-default-default hover:border-neutral-strong-default",
88
- c && "opacity-50 cursor-not-allowed",
85
+ d || l || f ? " border-primary-default-focused ring-primary-default-focused ring-[2px]" : x ? "ring-error-default-default ring-[2px]" : "border-neutral-default-default hover:border-primary-default-hover",
86
+ g && "opacity-50 cursor-not-allowed pointer-events-none",
89
87
  C
90
88
  ),
91
89
  children: [
92
90
  /* @__PURE__ */ t.jsx(
93
91
  "label",
94
92
  {
95
- className: o(
93
+ className: i(
96
94
  "absolute pointer-events-none bg-inherit px-1 z-10",
97
- g === "default" && "transition-all duration-200 ease-in-out",
95
+ b === "default" && "transition-all duration-200 ease-in-out",
98
96
  "text-md",
99
97
  S(),
100
- d || l || m ? "text-primary-default-default" : p ? "text-red-500" : "text-neutral-medium-default",
98
+ d || l || f ? "text-primary-default-default" : x ? "text-red-500" : "text-neutral-medium-default",
101
99
  "left-3"
102
100
  ),
103
101
  children: N
@@ -114,14 +112,14 @@ const T = ({
114
112
  className: "text-neutral-medium-default hover:text-neutral-default-default transition-colors",
115
113
  type: "button",
116
114
  tabIndex: -1,
117
- children: /* @__PURE__ */ t.jsx(v.Close, { size: 16, className: "" })
115
+ children: /* @__PURE__ */ t.jsx(h.Close, { size: 16, className: "" })
118
116
  }
119
117
  ),
120
118
  O ? /* @__PURE__ */ t.jsx(B, { size: 20, variant: "clip" }) : /* @__PURE__ */ t.jsx(
121
- v.ChevronDown,
119
+ h.ChevronDown,
122
120
  {
123
121
  size: 20,
124
- className: o(
122
+ className: i(
125
123
  "transition-transform text-neutral-default-default",
126
124
  l ? "rotate-180" : ""
127
125
  )
@@ -131,24 +129,24 @@ const T = ({
131
129
  ]
132
130
  }
133
131
  ),
134
- l && /* @__PURE__ */ t.jsx("div", { className: "absolute z-50 w-full mt-1 bg-neutral-default-default border border-neutral-default-default rounded-md shadow-lg max-h-60 overflow-auto", children: u.length === 0 ? /* @__PURE__ */ t.jsx("div", { className: "px-3 py-2 text-neutral-medium-default", children: D }) : u.map((e) => {
135
- const r = n ? Array.isArray(a.value) && a.value.includes(e.id) : a.value === e.id;
132
+ l && /* @__PURE__ */ t.jsx("div", { className: "absolute z-50 w-full mt-1 bg-neutral-default-default border border-neutral-default-default rounded-md shadow-lg max-h-60 overflow-auto", children: o.length === 0 ? /* @__PURE__ */ t.jsx("div", { className: "px-3 py-2 text-neutral-medium-default", children: D }) : o.map((e) => {
133
+ const a = n ? Array.isArray(r.value) && r.value.includes(e.id) : r.value === e.id;
136
134
  return /* @__PURE__ */ t.jsxs(
137
135
  "div",
138
136
  {
139
137
  onMouseDown: (s) => {
140
138
  s.preventDefault(), z(e), s.stopPropagation();
141
139
  },
142
- className: o(
140
+ className: i(
143
141
  "px-3 py-2 cursor-pointer flex items-center transition-colors",
144
- r ? "bg-primary-default-default text-white" : "hover:bg-neutral-medium-selected text-neutral-default-default"
142
+ a ? "bg-primary-default-default text-white" : "hover:bg-neutral-medium-selected text-neutral-default-default"
145
143
  ),
146
144
  children: [
147
145
  n && /* @__PURE__ */ t.jsx(
148
146
  "input",
149
147
  {
150
148
  type: "checkbox",
151
- checked: r,
149
+ checked: a,
152
150
  onChange: () => {
153
151
  },
154
152
  className: "mr-2 pointer-events-none"
@@ -161,10 +159,10 @@ const T = ({
161
159
  );
162
160
  }) })
163
161
  ] }),
164
- p && /* @__PURE__ */ t.jsx(
162
+ x && /* @__PURE__ */ t.jsx(
165
163
  M,
166
164
  {
167
- name: a.name,
165
+ name: r.name,
168
166
  component: "span",
169
167
  className: "block text-error-default-default text-xs mt-1"
170
168
  }
@@ -0,0 +1,2 @@
1
+ export * from './exports/Skeleton'
2
+ export {}
@@ -0,0 +1,71 @@
1
+ import { j as x } from "./jsx-runtime-ByW6EXIE.js";
2
+ import { c as P } from "./cn-B6yFEsav.js";
3
+ import { useRef as $, useLayoutEffect as B } from "react";
4
+ const v = (g) => {
5
+ const e = $(null), { debugMode: b = !1, className: y = "", children: p, shape: f = "rounded", animation: i = "shimmer", onlyContainer: m = !1 } = g;
6
+ let d = "255, 255, 255", u = "255, 255, 255, 0.1";
7
+ B(() => {
8
+ if (e.current) {
9
+ const n = (a) => {
10
+ let r = a;
11
+ for (; r && r !== document.body; ) {
12
+ const o = window.getComputedStyle(r).backgroundColor;
13
+ if (o && o !== "transparent" && o !== "rgba(0, 0, 0, 0)")
14
+ return o;
15
+ r = r.parentElement;
16
+ }
17
+ const t = window.getComputedStyle(document.body).backgroundColor;
18
+ return t && t !== "transparent" && t !== "rgba(0, 0, 0, 0)" ? t : "rgb(255, 255, 255)";
19
+ }, c = (a) => {
20
+ const r = document.createElement("canvas");
21
+ r.width = 1, r.height = 1;
22
+ const t = r.getContext("2d");
23
+ if (!t) return [255, 255, 255];
24
+ t.fillStyle = a, t.fillRect(0, 0, 1, 1);
25
+ const o = t.getImageData(0, 0, 1, 1).data;
26
+ return [o[0], o[1], o[2]];
27
+ }, C = n(e.current.parentElement), s = c(C), S = s.reduce((a, r) => a + r, 0) < 382;
28
+ let l;
29
+ S ? l = `rgb(${s[0] + 10}, ${s[1] + 10}, ${s[2] + 10})` : (l = `rgb(${s[0] - 30}, ${s[1] - 30}, ${s[2] - 30})`, d = "115,115,115", u = "255,255,255, 0.4"), m && (l = "transparent", e.current.style.animation = "none"), e.current.style.backgroundColor = l, h();
30
+ }
31
+ }, [i]);
32
+ const h = () => {
33
+ if (!m && e.current)
34
+ switch (i) {
35
+ case "shimmer":
36
+ e.current.classList.add("skeleton-shimmer-animation");
37
+ const n = u.split(",").map(Number);
38
+ n && n.length >= 3 && (e.current.style.setProperty("--shimmer-color-r", n[0].toString()), e.current.style.setProperty("--shimmer-color-g", n[1].toString()), e.current.style.setProperty("--shimmer-color-b", n[2].toString()), e.current.style.setProperty("--shimmer-color-a", n[3].toString()));
39
+ break;
40
+ case "none":
41
+ e.current.style.animation = "none";
42
+ break;
43
+ case "border":
44
+ e.current.classList.add("skeleton-border-animation"), e.current.style.backgroundColor = "transparent";
45
+ const c = d.match(/\d+/g);
46
+ c && c.length >= 3 && (e.current.style.setProperty("--border-color-r", c[0]), e.current.style.setProperty("--border-color-g", c[1]), e.current.style.setProperty("--border-color-b", c[2]));
47
+ break;
48
+ }
49
+ }, k = {
50
+ circle: "rounded-full aspect-square",
51
+ square: "rounded-none",
52
+ rounded: "rounded"
53
+ };
54
+ return /* @__PURE__ */ x.jsx(
55
+ "div",
56
+ {
57
+ ref: e,
58
+ className: P(
59
+ b && " border-red-600/20 border",
60
+ y,
61
+ "skeleton-container",
62
+ k[f]
63
+ ),
64
+ children: p
65
+ },
66
+ `skeleton-${Math.random().toFixed(10)}`
67
+ );
68
+ };
69
+ export {
70
+ v as Skeleton
71
+ };
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { ClipLoader as l, SyncLoader as m, HashLoader as p, GridLoader as x, DotLoader as j, BounceLoader as f } from "react-spinners";
3
3
  import { c as L } from "./cn-B6yFEsav.js";
4
4
  const y = ({
package/dist/Steps.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as e } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as e } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as j } from "./cn-B6yFEsav.js";
3
3
  import { motion as r } from "framer-motion";
4
4
  import N from "react";
@@ -1,4 +1,4 @@
1
- import { j as o } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as o } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as i } from "./cn-B6yFEsav.js";
3
3
  import { useState as d, useRef as D, useEffect as L } from "react";
4
4
  const O = ({
package/dist/Switch.es.js CHANGED
@@ -1,13 +1,13 @@
1
- import { j as n } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as n } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { c as r } from "./cn-B6yFEsav.js";
3
3
  import { useRef as p } from "react";
4
- import { motion as u } from "framer-motion";
5
- const x = ({ name: l, value: o, onChange: c, disabled: e = !1 }) => {
6
- const a = p(null), d = () => {
4
+ import { motion as l } from "framer-motion";
5
+ const x = ({ name: c, value: o, onChange: d, disabled: e = !1 }) => {
6
+ const a = p(null), i = () => {
7
7
  if (!a.current || e) return;
8
8
  const m = !a.current.checked;
9
- c(l, m);
10
- }, i = {
9
+ d(c, m);
10
+ }, s = {
11
11
  on: {
12
12
  default: {
13
13
  container: "bg-primary-default-default",
@@ -45,20 +45,20 @@ const x = ({ name: l, value: o, onChange: c, disabled: e = !1 }) => {
45
45
  off: {
46
46
  width: 16
47
47
  }
48
- }, t = o ? "on" : "off", s = e ? "disabled" : "default";
48
+ }, t = o ? "on" : "off", u = e ? "disabled" : "default";
49
49
  return /* @__PURE__ */ n.jsxs("div", { children: [
50
- /* @__PURE__ */ n.jsx("input", { type: "checkbox", hidden: !0, ref: a, checked: o, disabled: e }),
50
+ /* @__PURE__ */ n.jsx("input", { type: "checkbox", hidden: !0, ref: a, checked: o, disabled: e, onChange: i }),
51
51
  /* @__PURE__ */ n.jsx(
52
52
  "div",
53
53
  {
54
54
  className: r(
55
55
  "w-14 h-8 rounded-full relative px-2",
56
- i[t][s].container
56
+ s[t][u].container
57
57
  ),
58
58
  children: /* @__PURE__ */ n.jsx(
59
- u.span,
59
+ l.span,
60
60
  {
61
- onClick: d,
61
+ onClick: i,
62
62
  animate: f[t],
63
63
  whileHover: e ? {} : {
64
64
  background: t === "off" ? "rgba(29, 27, 32, 0.08)" : "rgba(101, 85, 143, 0.12)"
@@ -69,7 +69,7 @@ const x = ({ name: l, value: o, onChange: c, disabled: e = !1 }) => {
69
69
  "cursor-pointer"
70
70
  ),
71
71
  children: /* @__PURE__ */ n.jsx(
72
- u.span,
72
+ l.span,
73
73
  {
74
74
  animate: h[t],
75
75
  whileTap: e ? {} : {
@@ -78,7 +78,7 @@ const x = ({ name: l, value: o, onChange: c, disabled: e = !1 }) => {
78
78
  },
79
79
  className: r(
80
80
  "size-4 aspect-square rounded-full z-10",
81
- i[t][s].dot
81
+ s[t][u].dot
82
82
  )
83
83
  }
84
84
  )
@@ -1,4 +1,4 @@
1
- import { j as a } from "./jsx-runtime-DKDX3adD.js";
1
+ import { j as a } from "./jsx-runtime-ByW6EXIE.js";
2
2
  import { motion as x } from "framer-motion";
3
3
  import { memo as b } from "react";
4
4
  import { c as r } from "./cn-B6yFEsav.js";