prometeo-design-system 2.8.4 → 2.8.5
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.
- package/dist/Avatar.es.js +23 -28
- package/dist/Button.es.js +1 -1
- package/dist/{CardProfile-BB-IP1MR.js → CardProfile-CsytJlKZ.js} +9 -9
- package/dist/CardProfile.d.ts +4 -0
- package/dist/CardProfile.es.js +3 -2
- package/dist/CheckBox.es.js +5 -5
- package/dist/DatePicker.d.ts +2 -0
- package/dist/DatePicker.es.js +1479 -1538
- package/dist/DialogModal.es.js +1 -1
- package/dist/DrawerDesktop.es.js +2 -2
- package/dist/DrawerMobile.es.js +1 -1
- package/dist/DropZone.d.ts +4 -0
- package/dist/DropZone.es.js +18 -17
- package/dist/FAButton.es.js +2 -2
- package/dist/Header.es.js +1 -1
- package/dist/{HelperComponent-D_Cqdf1J.js → HelperComponent-g_xuKWzK.js} +8 -8
- package/dist/Icons/Icons.d.ts +1 -1
- package/dist/Icons-DtFC5DJ7.js +1079 -0
- package/dist/Icons.d.ts +4 -0
- package/dist/Icons.es.js +3 -1053
- package/dist/Image.es.js +2 -2
- package/dist/{ImageGallery-CjaJ0UCN.js → ImageGallery-Ckxg9OIC.js} +35 -35
- package/dist/ImageGallery.es.js +1 -1
- package/dist/{Input-Bdo-Acix.js → Input-Cck37DpG.js} +12 -12
- package/dist/Input.es.js +1 -1
- package/dist/InputMultiple.d.ts +4 -0
- package/dist/InputMultiple.es.js +37 -36
- package/dist/{LayoutGeneric-B6E-yOYJ.js → LayoutGeneric-CbaoatQB.js} +1 -1
- package/dist/LayoutGeneric.es.js +1 -1
- package/dist/Logo.es.js +2 -2
- package/dist/Menu.d.ts +4 -0
- package/dist/Menu.es.js +3 -2
- package/dist/OtpInput.es.js +44 -44
- package/dist/Pagination.es.js +1 -1
- package/dist/ProfilePictureUpload.d.ts +4 -0
- package/dist/ProfilePictureUpload.es.js +79 -103
- package/dist/ProgressBar.es.js +1 -1
- package/dist/RadioButton.d.ts +4 -0
- package/dist/RadioButton.es.js +4 -3
- package/dist/SegmentedButton.d.ts +4 -0
- package/dist/SegmentedButton.es.js +3 -2
- package/dist/{Select-D2APaG1z.js → Select-BD5FTxVw.js} +5 -5
- package/dist/Select.es.js +1 -1
- package/dist/SelectSearch.es.js +2 -2
- package/dist/Skeleton.d.ts +4 -0
- package/dist/Skeleton.es.js +3 -2
- package/dist/Spinner.es.js +1 -1
- package/dist/Steps.d.ts +4 -0
- package/dist/Steps.es.js +4 -3
- package/dist/SwipeContainer.es.js +1 -1
- package/dist/Switch.d.ts +4 -0
- package/dist/Switch.es.js +3 -2
- package/dist/TabLinks.es.js +1 -1
- package/dist/Table.es.js +1 -1
- package/dist/TextArea.es.js +1 -1
- package/dist/Toast.es.js +23 -23
- package/dist/ToastProvider.es.js +1 -1
- package/dist/Tooltip.es.js +2 -2
- package/dist/components/ProfilePictureUpload/ProfilePictureUpload.d.ts +1 -1
- package/dist/exports/CardProfile.d.ts +1 -0
- package/dist/exports/DatePicker.d.ts +2 -0
- package/dist/exports/DropZone.d.ts +2 -0
- package/dist/exports/Icons.d.ts +2 -1
- package/dist/exports/InputMultiple.d.ts +2 -0
- package/dist/exports/Menu.d.ts +1 -0
- package/dist/exports/ProfilePictureUpload.d.ts +1 -0
- package/dist/exports/RadioButton.d.ts +2 -0
- package/dist/exports/SegmentedButton.d.ts +2 -0
- package/dist/exports/Skeleton.d.ts +2 -0
- package/dist/exports/Steps.d.ts +1 -0
- package/dist/exports/Switch.d.ts +2 -0
- package/dist/index.d.ts +0 -4
- package/dist/{jsx-runtime-ByW6EXIE.js → jsx-runtime-DKDX3adD.js} +94 -96
- package/dist/prometeo-design-system.es.js +117 -123
- package/dist/styles.d.ts +0 -0
- package/package.json +283 -274
- package/src/styles/app.css +1314 -0
- package/src/styles/base.css +1323 -0
- package/src/styles/fonts.css +46 -0
- package/src/styles/palette.css +83 -0
- package/src/styles/utilities.css +1126 -0
- package/dist/components/Button/Button_Legacy.d.ts +0 -29
package/dist/OtpInput.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { j as p } from "./jsx-runtime-
|
|
2
|
-
import {
|
|
1
|
+
import { j as p } from "./jsx-runtime-DKDX3adD.js";
|
|
2
|
+
import { C as Re, E as De } from "./Icons-DtFC5DJ7.js";
|
|
3
3
|
import { c as $ } from "./cn-B6yFEsav.js";
|
|
4
4
|
import * as n from "react";
|
|
5
5
|
import ge, { memo as Oe } from "react";
|
|
@@ -28,8 +28,8 @@ function Ge({ containerRef: t, inputRef: a, pushPasswordManagerStrategy: r, isFo
|
|
|
28
28
|
let [M, d] = n.useState(!1), [D, k] = n.useState(!1), [O, B] = n.useState(!1), _ = n.useMemo(() => r === "none" ? !1 : (r === "increase-width" || r === "experimental-no-flickering") && M && D, [M, D, r]), x = n.useCallback(() => {
|
|
29
29
|
let f = t.current, v = a.current;
|
|
30
30
|
if (!f || !v || O || r === "none") return;
|
|
31
|
-
let m = f, b = m.getBoundingClientRect().left + m.offsetWidth, w = m.getBoundingClientRect().top + m.offsetHeight / 2, o = b - Le,
|
|
32
|
-
document.querySelectorAll(ze).length === 0 && document.elementFromPoint(o,
|
|
31
|
+
let m = f, b = m.getBoundingClientRect().left + m.offsetWidth, w = m.getBoundingClientRect().top + m.offsetHeight / 2, o = b - Le, C = w;
|
|
32
|
+
document.querySelectorAll(ze).length === 0 && document.elementFromPoint(o, C) === f || (d(!0), B(!0));
|
|
33
33
|
}, [t, a, O, r]);
|
|
34
34
|
return n.useEffect(() => {
|
|
35
35
|
let f = t.current;
|
|
@@ -55,10 +55,10 @@ function Ge({ containerRef: t, inputRef: a, pushPasswordManagerStrategy: r, isFo
|
|
|
55
55
|
}, [a, u, r, x]), { hasPWMBadge: M, willPushPWMBadge: _, PWM_BADGE_SPACE_WIDTH: $e };
|
|
56
56
|
}
|
|
57
57
|
var Ve = n.createContext({}), Se = n.forwardRef((t, a) => {
|
|
58
|
-
var r = t, { value: u, onChange: M, maxLength: d, textAlign: D = "left", pattern: k, placeholder: O, inputMode: B = "numeric", onComplete: _, pushPasswordManagerStrategy: x = "increase-width", pasteTransformer: f, containerClassName: v, noScriptCSSFallback: m = qe, render: b, children: w } = r, o = Ie(r, ["value", "onChange", "maxLength", "textAlign", "pattern", "placeholder", "inputMode", "onComplete", "pushPasswordManagerStrategy", "pasteTransformer", "containerClassName", "noScriptCSSFallback", "render", "children"]),
|
|
59
|
-
let [te, ne] = n.useState(typeof o.defaultValue == "string" ? o.defaultValue : ""),
|
|
58
|
+
var r = t, { value: u, onChange: M, maxLength: d, textAlign: D = "left", pattern: k, placeholder: O, inputMode: B = "numeric", onComplete: _, pushPasswordManagerStrategy: x = "increase-width", pasteTransformer: f, containerClassName: v, noScriptCSSFallback: m = qe, render: b, children: w } = r, o = Ie(r, ["value", "onChange", "maxLength", "textAlign", "pattern", "placeholder", "inputMode", "onComplete", "pushPasswordManagerStrategy", "pasteTransformer", "containerClassName", "noScriptCSSFallback", "render", "children"]), C, N, U, T, V;
|
|
59
|
+
let [te, ne] = n.useState(typeof o.defaultValue == "string" ? o.defaultValue : ""), s = u ?? te, E = He(s), q = n.useCallback((e) => {
|
|
60
60
|
M?.(e), ne(e);
|
|
61
|
-
}, [M]),
|
|
61
|
+
}, [M]), P = n.useMemo(() => k ? typeof k == "string" ? new RegExp(k) : k : null, [k]), c = n.useRef(null), le = n.useRef(null), ae = n.useRef({ value: s, onChange: q, isIOS: typeof window < "u" && ((N = (C = window?.CSS) == null ? void 0 : C.supports) == null ? void 0 : N.call(C, "-webkit-touch-callout", "none")) }), X = n.useRef({ prev: [(U = c.current) == null ? void 0 : U.selectionStart, (T = c.current) == null ? void 0 : T.selectionEnd, (V = c.current) == null ? void 0 : V.selectionDirection] });
|
|
62
62
|
n.useImperativeHandle(a, () => c.current, []), n.useEffect(() => {
|
|
63
63
|
let e = c.current, l = le.current;
|
|
64
64
|
if (!e || !l) return;
|
|
@@ -68,33 +68,33 @@ var Ve = n.createContext({}), Se = n.forwardRef((t, a) => {
|
|
|
68
68
|
J(null), K(null);
|
|
69
69
|
return;
|
|
70
70
|
}
|
|
71
|
-
let
|
|
72
|
-
if (F.length !== 0 &&
|
|
73
|
-
let Me =
|
|
71
|
+
let i = e.selectionStart, g = e.selectionEnd, Y = e.selectionDirection, j = e.maxLength, F = e.value, R = X.current.prev, W = -1, A = -1, H;
|
|
72
|
+
if (F.length !== 0 && i !== null && g !== null) {
|
|
73
|
+
let Me = i === g, ke = i === F.length && F.length < j;
|
|
74
74
|
if (Me && !ke) {
|
|
75
|
-
let L =
|
|
75
|
+
let L = i;
|
|
76
76
|
if (L === 0) W = 0, A = 1, H = "forward";
|
|
77
77
|
else if (L === j) W = L - 1, A = L, H = "backward";
|
|
78
78
|
else if (j > 1 && F.length > 1) {
|
|
79
|
-
let
|
|
79
|
+
let se = 0;
|
|
80
80
|
if (R[0] !== null && R[1] !== null) {
|
|
81
81
|
H = L < R[1] ? "backward" : "forward";
|
|
82
82
|
let Ne = R[0] === R[1] && R[0] < j;
|
|
83
|
-
H === "backward" && !Ne && (
|
|
83
|
+
H === "backward" && !Ne && (se = -1);
|
|
84
84
|
}
|
|
85
|
-
W =
|
|
85
|
+
W = se + L, A = se + L + 1;
|
|
86
86
|
}
|
|
87
87
|
}
|
|
88
88
|
W !== -1 && A !== -1 && W !== A && c.current.setSelectionRange(W, A, H);
|
|
89
89
|
}
|
|
90
|
-
let he = W !== -1 ? W :
|
|
91
|
-
J(he), K(ve), X.current.prev = [he, ve,
|
|
90
|
+
let he = W !== -1 ? W : i, ve = A !== -1 ? A : g, Pe = H ?? Y;
|
|
91
|
+
J(he), K(ve), X.current.prev = [he, ve, Pe];
|
|
92
92
|
}
|
|
93
93
|
if (document.addEventListener("selectionchange", h, { capture: !0 }), h(), document.activeElement === e && re(!0), !document.getElementById("input-otp-style")) {
|
|
94
|
-
let
|
|
95
|
-
if (
|
|
94
|
+
let i = document.createElement("style");
|
|
95
|
+
if (i.id = "input-otp-style", document.head.appendChild(i), i.sheet) {
|
|
96
96
|
let g = "background: transparent !important; color: transparent !important; border-color: transparent !important; opacity: 0 !important; box-shadow: none !important; -webkit-box-shadow: none !important; -webkit-text-fill-color: transparent !important;";
|
|
97
|
-
Q(
|
|
97
|
+
Q(i.sheet, "[data-input-otp]::selection { background: transparent !important; color: transparent !important; }"), Q(i.sheet, `[data-input-otp]:autofill { ${g} }`), Q(i.sheet, `[data-input-otp]:-webkit-autofill { ${g} }`), Q(i.sheet, "@supports (-webkit-touch-callout: none) { [data-input-otp] { letter-spacing: -.6em !important; font-weight: 100 !important; font-stretch: ultra-condensed; font-optical-sizing: none !important; left: -1px !important; right: 1px !important; } }"), Q(i.sheet, "[data-input-otp] + * { pointer-events: all !important; }");
|
|
98
98
|
}
|
|
99
99
|
}
|
|
100
100
|
let y = () => {
|
|
@@ -111,20 +111,20 @@ var Ve = n.createContext({}), Se = n.forwardRef((t, a) => {
|
|
|
111
111
|
Fe(() => {
|
|
112
112
|
var e, l, h, y;
|
|
113
113
|
(e = c.current) == null || e.dispatchEvent(new Event("input"));
|
|
114
|
-
let S = (l = c.current) == null ? void 0 : l.selectionStart,
|
|
115
|
-
S !== null &&
|
|
114
|
+
let S = (l = c.current) == null ? void 0 : l.selectionStart, i = (h = c.current) == null ? void 0 : h.selectionEnd, g = (y = c.current) == null ? void 0 : y.selectionDirection;
|
|
115
|
+
S !== null && i !== null && (J(S), K(i), X.current.prev = [S, i, g]);
|
|
116
116
|
});
|
|
117
|
-
}, [
|
|
118
|
-
E !== void 0 &&
|
|
119
|
-
}, [d, _, E,
|
|
117
|
+
}, [s, Z]), n.useEffect(() => {
|
|
118
|
+
E !== void 0 && s !== E && E.length < d && s.length === d && _?.(s);
|
|
119
|
+
}, [d, _, E, s]);
|
|
120
120
|
let G = Ge({ containerRef: le, inputRef: c, pushPasswordManagerStrategy: x, isFocused: Z }), de = n.useCallback((e) => {
|
|
121
121
|
let l = e.currentTarget.value.slice(0, d);
|
|
122
|
-
if (l.length > 0 &&
|
|
122
|
+
if (l.length > 0 && P && !P.test(l)) {
|
|
123
123
|
e.preventDefault();
|
|
124
124
|
return;
|
|
125
125
|
}
|
|
126
126
|
typeof E == "string" && l.length < E.length && document.dispatchEvent(new Event("selectionchange")), q(l);
|
|
127
|
-
}, [d, q, E,
|
|
127
|
+
}, [d, q, E, P]), fe = n.useCallback(() => {
|
|
128
128
|
var e;
|
|
129
129
|
if (c.current) {
|
|
130
130
|
let l = Math.min(c.current.value.length, d - 1), h = c.current.value.length;
|
|
@@ -135,14 +135,14 @@ var Ve = n.createContext({}), Se = n.forwardRef((t, a) => {
|
|
|
135
135
|
var l, h;
|
|
136
136
|
let y = c.current;
|
|
137
137
|
if (!f && (!ae.current.isIOS || !e.clipboardData || !y)) return;
|
|
138
|
-
let S = e.clipboardData.getData("text/plain"),
|
|
138
|
+
let S = e.clipboardData.getData("text/plain"), i = f ? f(S) : S;
|
|
139
139
|
e.preventDefault();
|
|
140
|
-
let g = (l = c.current) == null ? void 0 : l.selectionStart, Y = (h = c.current) == null ? void 0 : h.selectionEnd, j = (g !== Y ?
|
|
141
|
-
if (j.length > 0 &&
|
|
140
|
+
let g = (l = c.current) == null ? void 0 : l.selectionStart, Y = (h = c.current) == null ? void 0 : h.selectionEnd, j = (g !== Y ? s.slice(0, g) + i + s.slice(Y) : s.slice(0, g) + i + s.slice(g)).slice(0, d);
|
|
141
|
+
if (j.length > 0 && P && !P.test(j)) return;
|
|
142
142
|
y.value = j, q(j);
|
|
143
143
|
let F = Math.min(j.length, d - 1), R = j.length;
|
|
144
144
|
y.setSelectionRange(F, R), J(F), K(R);
|
|
145
|
-
}, [d, q,
|
|
145
|
+
}, [d, q, P, s]), Ee = n.useMemo(() => ({ position: "relative", cursor: o.disabled ? "default" : "text", userSelect: "none", WebkitUserSelect: "none", pointerEvents: "none" }), [o.disabled]), me = n.useMemo(() => ({ position: "absolute", inset: 0, width: G.willPushPWMBadge ? `calc(100% + ${G.PWM_BADGE_SPACE_WIDTH})` : "100%", clipPath: G.willPushPWMBadge ? `inset(0 ${G.PWM_BADGE_SPACE_WIDTH} 0 0)` : void 0, height: "100%", display: "flex", textAlign: D, opacity: "1", color: "transparent", pointerEvents: "all", background: "transparent", caretColor: "transparent", border: "0 solid transparent", outline: "0 solid transparent", boxShadow: "none", lineHeight: "1", letterSpacing: "-.5em", fontSize: "var(--root-height)", fontFamily: "monospace", fontVariantNumeric: "tabular-nums" }), [G.PWM_BADGE_SPACE_WIDTH, G.willPushPWMBadge, D]), je = n.useMemo(() => n.createElement("input", _e(Be({ autoComplete: o.autoComplete || "one-time-code" }, o), { "data-input-otp": !0, "data-input-otp-placeholder-shown": s.length === 0 || void 0, "data-input-otp-mss": I, "data-input-otp-mse": z, inputMode: B, pattern: P?.source, "aria-placeholder": O, style: me, maxLength: d, value: s, ref: c, onPaste: (e) => {
|
|
146
146
|
var l;
|
|
147
147
|
pe(e), (l = o.onPaste) == null || l.call(o, e);
|
|
148
148
|
}, onChange: de, onMouseOver: (e) => {
|
|
@@ -157,12 +157,12 @@ var Ve = n.createContext({}), Se = n.forwardRef((t, a) => {
|
|
|
157
157
|
}, onBlur: (e) => {
|
|
158
158
|
var l;
|
|
159
159
|
re(!1), (l = o.onBlur) == null || l.call(o, e);
|
|
160
|
-
} })), [de, fe, pe, B, me, d, z, I, o,
|
|
160
|
+
} })), [de, fe, pe, B, me, d, z, I, o, P?.source, s]), oe = n.useMemo(() => ({ slots: Array.from({ length: d }).map((e, l) => {
|
|
161
161
|
var h;
|
|
162
|
-
let y = Z && I !== null && z !== null && (I === z && l === I || l >= I && l < z), S =
|
|
163
|
-
return { char: S, placeholderChar:
|
|
164
|
-
}), isFocused: Z, isHovering: !o.disabled && ue }), [Z, ue, d, z, I, o.disabled,
|
|
165
|
-
return n.createElement(n.Fragment, null, m !== null && n.createElement("noscript", null, n.createElement("style", null, m)), n.createElement("div", { ref: le, "data-input-otp-container": !0, style: Ee, className: v },
|
|
162
|
+
let y = Z && I !== null && z !== null && (I === z && l === I || l >= I && l < z), S = s[l] !== void 0 ? s[l] : null, i = s[0] !== void 0 ? null : (h = O?.[l]) != null ? h : null;
|
|
163
|
+
return { char: S, placeholderChar: i, isActive: y, hasFakeCaret: y && S === null };
|
|
164
|
+
}), isFocused: Z, isHovering: !o.disabled && ue }), [Z, ue, d, z, I, o.disabled, s]), Ce = n.useMemo(() => b ? b(oe) : n.createElement(Ve.Provider, { value: oe }, w), [w, oe, b]);
|
|
165
|
+
return n.createElement(n.Fragment, null, m !== null && n.createElement("noscript", null, n.createElement("style", null, m)), n.createElement("div", { ref: le, "data-input-otp-container": !0, style: Ee, className: v }, Ce, n.createElement("div", { style: { position: "absolute", inset: 0, pointerEvents: "none" } }, je)));
|
|
166
166
|
});
|
|
167
167
|
Se.displayName = "Input";
|
|
168
168
|
function Q(t, a) {
|
|
@@ -212,7 +212,7 @@ const Ze = ({
|
|
|
212
212
|
variant: w = "default",
|
|
213
213
|
hideSlotsMiddleSeparator: o = !1
|
|
214
214
|
}) => {
|
|
215
|
-
const
|
|
215
|
+
const C = m === "left" ? "justify-start w-full text-left" : m === "center" ? "justify-center" : "justify-end text-right w-full", N = {
|
|
216
216
|
default: {
|
|
217
217
|
text: "text-neutral-default-default",
|
|
218
218
|
icon: null
|
|
@@ -246,23 +246,23 @@ const Ze = ({
|
|
|
246
246
|
const V = Math.floor(T.length / 2), te = T.slice(0, V), ne = T.slice(V);
|
|
247
247
|
return /* @__PURE__ */ p.jsxs("div", { className: "flex flex-col items-center", children: [
|
|
248
248
|
/* @__PURE__ */ p.jsxs("div", { className: "flex items-center", children: [
|
|
249
|
-
/* @__PURE__ */ p.jsx("div", { className: "flex", children: te.map((
|
|
249
|
+
/* @__PURE__ */ p.jsx("div", { className: "flex", children: te.map((s, E) => /* @__PURE__ */ p.jsx(ie, { ...s, placeholder: D, hasError: f, className: b, variant: w }, E)) }),
|
|
250
250
|
/* @__PURE__ */ p.jsx("hr", { className: $("w-2 h-1 mx-2 border-neutral-default-default", o && "hidden") }),
|
|
251
|
-
/* @__PURE__ */ p.jsx("div", { className: "flex", children: ne.map((
|
|
251
|
+
/* @__PURE__ */ p.jsx("div", { className: "flex", children: ne.map((s, E) => /* @__PURE__ */ p.jsx(ie, { ...s, placeholder: D, hasError: f, variant: w, className: b }, E)) })
|
|
252
252
|
] }),
|
|
253
|
-
f && x && (typeof x == "string" ? /* @__PURE__ */ p.jsxs("span", { className: $("text-error-default-default text-xs mt-1 flex items-center gap-1",
|
|
253
|
+
f && x && (typeof x == "string" ? /* @__PURE__ */ p.jsxs("span", { className: $("text-error-default-default text-xs mt-1 flex items-center gap-1", C, N.error.text), children: [
|
|
254
254
|
N.error.icon,
|
|
255
255
|
x
|
|
256
256
|
] }) : ge.cloneElement(x, { className: $(
|
|
257
257
|
"text-error-default-default text-xs mt-1",
|
|
258
|
-
|
|
258
|
+
C,
|
|
259
259
|
N.error.text,
|
|
260
260
|
x?.props?.className
|
|
261
261
|
) })),
|
|
262
|
-
v && m && (typeof v == "string" ? /* @__PURE__ */ p.jsxs("span", { className: $("text-neutral-medium-default text-xs mt-1 flex items-center gap-1", N[w].text,
|
|
262
|
+
v && m && (typeof v == "string" ? /* @__PURE__ */ p.jsxs("span", { className: $("text-neutral-medium-default text-xs mt-1 flex items-center gap-1", N[w].text, C), children: [
|
|
263
263
|
N[w].icon,
|
|
264
264
|
v
|
|
265
|
-
] }) : ge.cloneElement(v, { className: $("text-neutral-medium-default text-xs mt-1",
|
|
265
|
+
] }) : ge.cloneElement(v, { className: $("text-neutral-medium-default text-xs mt-1", C, N[w].text, v?.props?.className) }))
|
|
266
266
|
] });
|
|
267
267
|
}
|
|
268
268
|
}
|
|
@@ -294,8 +294,8 @@ const Je = (t) => {
|
|
|
294
294
|
]
|
|
295
295
|
}
|
|
296
296
|
);
|
|
297
|
-
},
|
|
298
|
-
|
|
297
|
+
}, ie = Oe(Je);
|
|
298
|
+
ie.displayName = "Slot";
|
|
299
299
|
export {
|
|
300
300
|
Ze as default
|
|
301
301
|
};
|
package/dist/Pagination.es.js
CHANGED
|
@@ -1,151 +1,134 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
|
|
6
|
-
const I = {
|
|
1
|
+
import { j as o } from "./jsx-runtime-DKDX3adD.js";
|
|
2
|
+
import { memo as L, useRef as w, useLayoutEffect as N } from "react";
|
|
3
|
+
import R from "./Avatar.es.js";
|
|
4
|
+
import { c as i } from "./cn-B6yFEsav.js";
|
|
5
|
+
const F = {
|
|
7
6
|
sm: "w-16 h-16",
|
|
8
7
|
md: "w-24 h-24",
|
|
9
8
|
lg: "w-32 h-32",
|
|
10
9
|
xl: "w-40 h-40"
|
|
11
|
-
},
|
|
10
|
+
}, A = {
|
|
12
11
|
sm: "w-4 h-4",
|
|
13
12
|
md: "w-5 h-5",
|
|
14
13
|
lg: "w-6 h-6",
|
|
15
14
|
xl: "w-8 h-8"
|
|
16
|
-
},
|
|
15
|
+
}, M = {
|
|
17
16
|
sm: "w-6 h-6",
|
|
18
17
|
md: "w-7 h-7",
|
|
19
18
|
lg: "w-8 h-8",
|
|
20
19
|
xl: "w-10 h-10"
|
|
21
|
-
},
|
|
20
|
+
}, T = {
|
|
22
21
|
sm: "-bottom-1 -right-0.5",
|
|
23
22
|
md: "-bottom-0.5 -right-0.5",
|
|
24
23
|
lg: "bottom-1 right-1",
|
|
25
24
|
xl: "bottom-3 right-2"
|
|
26
|
-
},
|
|
25
|
+
}, b = {
|
|
27
26
|
sm: "w-4 h-4",
|
|
28
27
|
md: "w-5 h-5",
|
|
29
28
|
lg: "w-6 h-6",
|
|
30
29
|
xl: "w-7 h-7"
|
|
31
|
-
},
|
|
30
|
+
}, U = {
|
|
32
31
|
sm: "-top-0.5 -right-0.5",
|
|
33
32
|
md: "-top-1 -right-1",
|
|
34
33
|
lg: "-top-1 -right-0",
|
|
35
34
|
xl: "top-1 right-1"
|
|
36
35
|
};
|
|
37
|
-
function
|
|
36
|
+
function z({
|
|
38
37
|
imageUrl: t,
|
|
39
38
|
fallbackText: e = "S L",
|
|
40
|
-
onFileSelect:
|
|
41
|
-
onEditClick:
|
|
42
|
-
onRemoveClick:
|
|
43
|
-
size:
|
|
44
|
-
className:
|
|
45
|
-
disabled:
|
|
39
|
+
onFileSelect: y,
|
|
40
|
+
onEditClick: m,
|
|
41
|
+
onRemoveClick: k,
|
|
42
|
+
size: r = "lg",
|
|
43
|
+
className: C,
|
|
44
|
+
disabled: n = !1,
|
|
46
45
|
showRemoveButton: j = !0,
|
|
47
|
-
acceptedTypes:
|
|
48
|
-
maxFileSize:
|
|
49
|
-
onError:
|
|
50
|
-
disableEntryAnimation: w = !1
|
|
46
|
+
acceptedTypes: p = "image/*",
|
|
47
|
+
maxFileSize: h = 5 * 1024 * 1024,
|
|
48
|
+
onError: g
|
|
51
49
|
}) {
|
|
52
|
-
const
|
|
53
|
-
`La imagen debe ser menor a ${Math.round(
|
|
54
|
-
), !1) : !0 : (
|
|
55
|
-
const a =
|
|
56
|
-
a && (
|
|
57
|
-
},
|
|
58
|
-
|
|
59
|
-
},
|
|
60
|
-
|
|
50
|
+
const f = w(null), u = w(null), x = (l) => l.type.startsWith("image/") ? l.size > h ? (g?.(
|
|
51
|
+
`La imagen debe ser menor a ${Math.round(h / 1024 / 1024)}MB`
|
|
52
|
+
), !1) : !0 : (g?.("Por favor selecciona un archivo de imagen válido"), !1), v = (l) => {
|
|
53
|
+
const a = l.target.files?.[0];
|
|
54
|
+
a && (x(a) && y?.(a), l.target.value = "");
|
|
55
|
+
}, B = () => {
|
|
56
|
+
n || (m ? m() : f.current?.click());
|
|
57
|
+
}, S = (l) => {
|
|
58
|
+
l.stopPropagation(), !n && k?.();
|
|
61
59
|
};
|
|
62
|
-
|
|
60
|
+
return N(() => {
|
|
63
61
|
if (u.current) {
|
|
64
|
-
const a = ((
|
|
65
|
-
let c =
|
|
62
|
+
const a = ((E) => {
|
|
63
|
+
let c = E;
|
|
66
64
|
for (; c && c !== document.body; ) {
|
|
67
65
|
const d = window.getComputedStyle(c).backgroundColor;
|
|
68
66
|
if (d && d !== "transparent" && d !== "rgba(0, 0, 0, 0)")
|
|
69
67
|
return d;
|
|
70
68
|
c = c.parentElement;
|
|
71
69
|
}
|
|
72
|
-
const
|
|
73
|
-
return
|
|
70
|
+
const s = window.getComputedStyle(document.body).backgroundColor;
|
|
71
|
+
return s && s !== "transparent" && s !== "rgba(0, 0, 0, 0)" ? s : "rgb(255, 255, 255)";
|
|
74
72
|
})(
|
|
75
73
|
u.current.parentElement
|
|
76
74
|
);
|
|
77
75
|
u.current.style.borderColor = a;
|
|
78
76
|
}
|
|
79
|
-
}, [])
|
|
80
|
-
const E = w ? {} : { width: 0, height: 0 }, R = w ? {} : { width: "auto", height: "auto" };
|
|
81
|
-
return /* @__PURE__ */ n.jsxs(
|
|
77
|
+
}, []), /* @__PURE__ */ o.jsxs(
|
|
82
78
|
"div",
|
|
83
79
|
{
|
|
84
|
-
className:
|
|
80
|
+
className: i("relative inline-block border-inherit group", C),
|
|
85
81
|
children: [
|
|
86
|
-
/* @__PURE__ */
|
|
82
|
+
/* @__PURE__ */ o.jsx(
|
|
87
83
|
"input",
|
|
88
84
|
{
|
|
89
|
-
ref:
|
|
85
|
+
ref: f,
|
|
90
86
|
type: "file",
|
|
91
|
-
accept:
|
|
92
|
-
onChange:
|
|
87
|
+
accept: p,
|
|
88
|
+
onChange: v,
|
|
93
89
|
className: "hidden",
|
|
94
|
-
disabled:
|
|
90
|
+
disabled: n
|
|
95
91
|
}
|
|
96
92
|
),
|
|
97
|
-
/* @__PURE__ */
|
|
98
|
-
|
|
93
|
+
/* @__PURE__ */ o.jsx(
|
|
94
|
+
"div",
|
|
99
95
|
{
|
|
100
|
-
className:
|
|
101
|
-
|
|
96
|
+
className: i(
|
|
97
|
+
F[r],
|
|
102
98
|
"rounded-full overflow-hidden flex items-center justify-center relative",
|
|
103
|
-
|
|
99
|
+
n && "opacity-50 cursor-not-default"
|
|
104
100
|
),
|
|
105
|
-
children: /* @__PURE__ */
|
|
106
|
-
|
|
101
|
+
children: /* @__PURE__ */ o.jsx(
|
|
102
|
+
R,
|
|
107
103
|
{
|
|
108
104
|
imageUrl: t,
|
|
109
105
|
fallbackText: e,
|
|
110
|
-
sizeImage:
|
|
111
|
-
sizeFallback:
|
|
106
|
+
sizeImage: r,
|
|
107
|
+
sizeFallback: r
|
|
112
108
|
}
|
|
113
109
|
)
|
|
114
110
|
}
|
|
115
111
|
),
|
|
116
|
-
/* @__PURE__ */
|
|
117
|
-
|
|
112
|
+
/* @__PURE__ */ o.jsx(
|
|
113
|
+
"button",
|
|
118
114
|
{
|
|
119
115
|
ref: u,
|
|
120
|
-
className:
|
|
116
|
+
className: i(
|
|
121
117
|
"absolute bg-primary-default-default rounded-lg border-2 hover:bg-primary-default-hover cursor-pointer grid place-content-center",
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
118
|
+
T[r],
|
|
119
|
+
M[r],
|
|
120
|
+
n && "opacity-50 cursor-not-default"
|
|
125
121
|
),
|
|
126
|
-
onClick:
|
|
127
|
-
disabled:
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
animate: R,
|
|
131
|
-
transition: { duration: 0.3, ease: "easeOut" },
|
|
132
|
-
children: /* @__PURE__ */ n.jsx(
|
|
133
|
-
s.svg,
|
|
122
|
+
onClick: B,
|
|
123
|
+
disabled: n,
|
|
124
|
+
children: /* @__PURE__ */ o.jsx(
|
|
125
|
+
"svg",
|
|
134
126
|
{
|
|
135
|
-
className:
|
|
127
|
+
className: i(A[r], "text-white"),
|
|
136
128
|
fill: "none",
|
|
137
129
|
stroke: "currentColor",
|
|
138
130
|
viewBox: "0 0 24 24",
|
|
139
|
-
|
|
140
|
-
x: [0, -1, 0, 1, -1, 0, 1],
|
|
141
|
-
y: [0, 1, 0, 1, 0, 1, 1],
|
|
142
|
-
rotate: [0, 5, -3, 8, -5, 3, 1]
|
|
143
|
-
},
|
|
144
|
-
transition: {
|
|
145
|
-
duration: 2,
|
|
146
|
-
ease: "easeInOut"
|
|
147
|
-
},
|
|
148
|
-
children: /* @__PURE__ */ n.jsx(
|
|
131
|
+
children: /* @__PURE__ */ o.jsx(
|
|
149
132
|
"path",
|
|
150
133
|
{
|
|
151
134
|
strokeLinecap: "round",
|
|
@@ -158,35 +141,27 @@ function O({
|
|
|
158
141
|
)
|
|
159
142
|
}
|
|
160
143
|
),
|
|
161
|
-
t && j && !
|
|
162
|
-
|
|
144
|
+
t && j && !n && /* @__PURE__ */ o.jsx(
|
|
145
|
+
"button",
|
|
163
146
|
{
|
|
164
|
-
className:
|
|
147
|
+
className: i(
|
|
165
148
|
"absolute rounded-full shadow-lg bg-error-light flex cursor-pointer items-center justify-center",
|
|
166
149
|
"opacity-0 scale-80 group-hover:opacity-100 group-hover:scale-100",
|
|
167
150
|
"transition-all duration-200 ease-out",
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
151
|
+
U[r],
|
|
152
|
+
b[r],
|
|
153
|
+
n && "opacity-50 cursor-default"
|
|
171
154
|
),
|
|
172
|
-
disabled:
|
|
173
|
-
onClick:
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
type: "spring",
|
|
177
|
-
stiffness: 300,
|
|
178
|
-
damping: 25
|
|
179
|
-
},
|
|
180
|
-
children: /* @__PURE__ */ n.jsx(
|
|
181
|
-
s.svg,
|
|
155
|
+
disabled: n,
|
|
156
|
+
onClick: S,
|
|
157
|
+
children: /* @__PURE__ */ o.jsx(
|
|
158
|
+
"svg",
|
|
182
159
|
{
|
|
183
|
-
className:
|
|
160
|
+
className: i(b[r], "text-white p-1"),
|
|
184
161
|
fill: "none",
|
|
185
162
|
stroke: "currentColor",
|
|
186
163
|
viewBox: "0 0 24 24",
|
|
187
|
-
|
|
188
|
-
transition: { duration: 0.2 },
|
|
189
|
-
children: /* @__PURE__ */ n.jsx(
|
|
164
|
+
children: /* @__PURE__ */ o.jsx(
|
|
190
165
|
"path",
|
|
191
166
|
{
|
|
192
167
|
strokeLinecap: "round",
|
|
@@ -203,11 +178,12 @@ function O({
|
|
|
203
178
|
}
|
|
204
179
|
);
|
|
205
180
|
}
|
|
206
|
-
const
|
|
207
|
-
|
|
181
|
+
const W = L(
|
|
182
|
+
z,
|
|
208
183
|
(t, e) => t.imageUrl === e.imageUrl && t.fallbackText === e.fallbackText && t.size === e.size && t.className === e.className && t.disabled === e.disabled && t.showRemoveButton === e.showRemoveButton && t.acceptedTypes === e.acceptedTypes && t.maxFileSize === e.maxFileSize && t.disableEntryAnimation === e.disableEntryAnimation && t.onFileSelect === e.onFileSelect && t.onEditClick === e.onEditClick && t.onRemoveClick === e.onRemoveClick && t.onError === e.onError
|
|
209
184
|
);
|
|
210
|
-
|
|
185
|
+
W.displayName = "ProfilePictureUpload";
|
|
211
186
|
export {
|
|
212
|
-
|
|
187
|
+
W as ProfilePictureUpload,
|
|
188
|
+
W as default
|
|
213
189
|
};
|
package/dist/ProgressBar.es.js
CHANGED
package/dist/RadioButton.d.ts
CHANGED
package/dist/RadioButton.es.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { j as e } from "./jsx-runtime-
|
|
1
|
+
import { j as e } from "./jsx-runtime-DKDX3adD.js";
|
|
2
2
|
import { c as t } from "./cn-B6yFEsav.js";
|
|
3
3
|
import { memo as x, forwardRef as k, useRef as g, useEffect as y } from "react";
|
|
4
|
-
import { H as j } from "./HelperComponent-
|
|
4
|
+
import { H as j } from "./HelperComponent-g_xuKWzK.js";
|
|
5
5
|
const s = k((n, a) => {
|
|
6
6
|
const r = g(null);
|
|
7
7
|
y(() => {
|
|
@@ -73,5 +73,6 @@ const s = k((n, a) => {
|
|
|
73
73
|
s.displayName = "RadioButton";
|
|
74
74
|
const z = x(s);
|
|
75
75
|
export {
|
|
76
|
-
z as RadioButton
|
|
76
|
+
z as RadioButton,
|
|
77
|
+
z as default
|
|
77
78
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { j as u } from "./jsx-runtime-
|
|
1
|
+
import { j as u } from "./jsx-runtime-DKDX3adD.js";
|
|
2
2
|
import { c as s } from "./cn-B6yFEsav.js";
|
|
3
3
|
import z, { useState as M, useMemo as C, useEffect as L } from "react";
|
|
4
4
|
import { motion as E } from "framer-motion";
|
|
@@ -180,5 +180,6 @@ const X = (T) => {
|
|
|
180
180
|
);
|
|
181
181
|
};
|
|
182
182
|
export {
|
|
183
|
-
X as SegmentedButton
|
|
183
|
+
X as SegmentedButton,
|
|
184
|
+
X as default
|
|
184
185
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { j as s } from "./jsx-runtime-
|
|
2
|
-
import {
|
|
1
|
+
import { j as s } from "./jsx-runtime-DKDX3adD.js";
|
|
2
|
+
import { a as Qe, i as Xe, f as Ue, S as Ye } from "./Icons-DtFC5DJ7.js";
|
|
3
3
|
import { c as f } from "./cn-B6yFEsav.js";
|
|
4
4
|
import Ne, { memo as Z, useState as De, useRef as ce, useMemo as oe, useCallback as U, useEffect as ve, useImperativeHandle as Ze } from "react";
|
|
5
5
|
import et from "./Spinner.es.js";
|
|
6
6
|
import { createPortal as tt } from "react-dom";
|
|
7
7
|
import { u as nt } from "./useDragScroll-CHN9OMwn.js";
|
|
8
|
-
import { u as rt, I as lt } from "./Input-
|
|
9
|
-
import { H as ot } from "./HelperComponent-
|
|
8
|
+
import { u as rt, I as lt } from "./Input-Cck37DpG.js";
|
|
9
|
+
import { H as ot } from "./HelperComponent-g_xuKWzK.js";
|
|
10
10
|
import st from "./CheckBox.es.js";
|
|
11
|
-
import
|
|
11
|
+
import Ke from "./Skeleton.es.js";
|
|
12
12
|
const at = {
|
|
13
13
|
default: {
|
|
14
14
|
container: "text-neutral-default-default border-neutral-default-default ",
|
package/dist/Select.es.js
CHANGED
package/dist/SelectSearch.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { j as G } from "./jsx-runtime-
|
|
2
|
-
import { g as i, S as H } from "./Select-
|
|
1
|
+
import { j as G } from "./jsx-runtime-DKDX3adD.js";
|
|
2
|
+
import { g as i, S as H } from "./Select-BD5FTxVw.js";
|
|
3
3
|
import { useState as T, useRef as I, useEffect as h, useMemo as Q, useCallback as X } from "react";
|
|
4
4
|
function te(e) {
|
|
5
5
|
const {
|
package/dist/Skeleton.d.ts
CHANGED
package/dist/Skeleton.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { j as E } from "./jsx-runtime-
|
|
1
|
+
import { j as E } from "./jsx-runtime-DKDX3adD.js";
|
|
2
2
|
import { c as B } from "./cn-B6yFEsav.js";
|
|
3
3
|
import { memo as N, useRef as R, useCallback as D, useLayoutEffect as M } from "react";
|
|
4
4
|
const y = (n) => {
|
|
@@ -69,5 +69,6 @@ const y = (n) => {
|
|
|
69
69
|
y.displayName = "Skeleton";
|
|
70
70
|
const x = N(y, (n, e) => n.debugMode === e.debugMode && n.className === e.className && n.children === e.children && n.shape === e.shape && n.animation === e.animation && n.onlyContainer === e.onlyContainer);
|
|
71
71
|
export {
|
|
72
|
-
x as Skeleton
|
|
72
|
+
x as Skeleton,
|
|
73
|
+
x as default
|
|
73
74
|
};
|
package/dist/Spinner.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { j as e } from "./jsx-runtime-
|
|
1
|
+
import { j as e } from "./jsx-runtime-DKDX3adD.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 = ({
|