@purpurds/password-field 8.13.0 → 8.14.0
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/LICENSE.txt +4 -4
- package/dist/{main-D9Xr_zTI.mjs → main-BR_vazIG.mjs} +2 -2
- package/dist/{main-D9Xr_zTI.mjs.map → main-BR_vazIG.mjs.map} +1 -1
- package/dist/{main-C62dnRdU.js → main-RjhaxNG1.js} +2 -2
- package/dist/{main-C62dnRdU.js.map → main-RjhaxNG1.js.map} +1 -1
- package/dist/{password-field-MPoIOo3H.js → password-field-CTbEtb0H.js} +2 -2
- package/dist/{password-field-MPoIOo3H.js.map → password-field-CTbEtb0H.js.map} +1 -1
- package/dist/{password-field-CFC1tL8k.mjs → password-field-rjwA_Jz0.mjs} +124 -124
- package/dist/{password-field-CFC1tL8k.mjs.map → password-field-rjwA_Jz0.mjs.map} +1 -1
- package/dist/password-field.cjs.js +1 -1
- package/dist/password-field.es.js +1 -1
- package/package.json +9 -9
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as m, jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import * as
|
|
2
|
+
import * as v from "react";
|
|
3
3
|
import { forwardRef as O, useId as et, useRef as nt, useState as E, useMemo as ut, useEffect as it, isValidElement as pt } from "react";
|
|
4
4
|
import "react-dom";
|
|
5
5
|
const at = {
|
|
@@ -54,12 +54,12 @@ const ct = /* @__PURE__ */ st(lt), _t = "_rotate_12t9p_1", dt = "_dash_12t9p_1",
|
|
|
54
54
|
dash: dt,
|
|
55
55
|
"purpur-spinner__circle--disabled": "_purpur-spinner__circle--disabled_12t9p_41",
|
|
56
56
|
"purpur-spinner__circle--negative": "_purpur-spinner__circle--negative_12t9p_44"
|
|
57
|
-
}, tr = ct.bind(ft), P = "purpur-spinner",
|
|
57
|
+
}, tr = ct.bind(ft), P = "purpur-spinner", gt = {
|
|
58
58
|
SM: "sm"
|
|
59
59
|
}, Dr = ({
|
|
60
60
|
disabled: t = !1,
|
|
61
61
|
negative: i = !1,
|
|
62
|
-
size: n =
|
|
62
|
+
size: n = gt.SM,
|
|
63
63
|
className: a,
|
|
64
64
|
...p
|
|
65
65
|
}) => /* @__PURE__ */ s("div", { className: tr(P, `${P}--${n}`, a), ...p, children: /* @__PURE__ */ s("svg", { viewBox: "0 0 50 50", children: /* @__PURE__ */ s(
|
|
@@ -75,11 +75,11 @@ const ct = /* @__PURE__ */ st(lt), _t = "_rotate_12t9p_1", dt = "_dash_12t9p_1",
|
|
|
75
75
|
}
|
|
76
76
|
) }) });
|
|
77
77
|
Dr.displayName = "Spinner";
|
|
78
|
-
function
|
|
78
|
+
function vt(t) {
|
|
79
79
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
80
80
|
}
|
|
81
81
|
var er = { exports: {} }, nr;
|
|
82
|
-
function
|
|
82
|
+
function ht() {
|
|
83
83
|
return nr || (nr = 1, (function(t) {
|
|
84
84
|
(function() {
|
|
85
85
|
var i = {}.hasOwnProperty;
|
|
@@ -111,8 +111,8 @@ function vt() {
|
|
|
111
111
|
})();
|
|
112
112
|
})(er)), er.exports;
|
|
113
113
|
}
|
|
114
|
-
var mt =
|
|
115
|
-
const bt = /* @__PURE__ */
|
|
114
|
+
var mt = ht();
|
|
115
|
+
const bt = /* @__PURE__ */ vt(mt), yt = {
|
|
116
116
|
"purpur-button": "_purpur-button_10jh0_1",
|
|
117
117
|
"purpur-button--xs": "_purpur-button--xs_10jh0_22",
|
|
118
118
|
"purpur-button--icon-only": "_purpur-button--icon-only_10jh0_25",
|
|
@@ -147,9 +147,9 @@ const bt = /* @__PURE__ */ gt(mt), yt = {
|
|
|
147
147
|
onClick: u,
|
|
148
148
|
size: d = "md",
|
|
149
149
|
variant: o,
|
|
150
|
-
type:
|
|
150
|
+
type: g = "button",
|
|
151
151
|
...l
|
|
152
|
-
},
|
|
152
|
+
}, h) => {
|
|
153
153
|
if (p && o === "destructive")
|
|
154
154
|
return null;
|
|
155
155
|
const y = ur(
|
|
@@ -172,8 +172,8 @@ const bt = /* @__PURE__ */ gt(mt), yt = {
|
|
|
172
172
|
"button",
|
|
173
173
|
{
|
|
174
174
|
className: y,
|
|
175
|
-
type:
|
|
176
|
-
ref:
|
|
175
|
+
type: g,
|
|
176
|
+
ref: h,
|
|
177
177
|
"aria-disabled": c,
|
|
178
178
|
onClick: f,
|
|
179
179
|
...l,
|
|
@@ -248,32 +248,32 @@ const St = /* @__PURE__ */ xt($t), jt = {
|
|
|
248
248
|
i ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
|
|
249
249
|
], a = i ? `<title>${i}</title>` : "";
|
|
250
250
|
return `<svg ${Pt(n)}>${a}${t}</svg>`;
|
|
251
|
-
},
|
|
251
|
+
}, qt = (t) => t.replace(/<(\/?)svg([^>]*)>/g, "").trim(), V = ({ svg: t, allyTitle: i, className: n, size: a = Ot, ...p }) => {
|
|
252
252
|
const r = At({
|
|
253
|
-
content:
|
|
253
|
+
content: qt(t.svg),
|
|
254
254
|
title: i
|
|
255
255
|
}), e = Nt(ar, `${ar}--${a}`, n);
|
|
256
256
|
return /* @__PURE__ */ s("span", { className: e, dangerouslySetInnerHTML: { __html: r }, ...p });
|
|
257
257
|
};
|
|
258
258
|
V.displayName = "Icon";
|
|
259
|
-
const
|
|
259
|
+
const Ct = {
|
|
260
260
|
name: "password-invisible",
|
|
261
261
|
svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M2.364 2.364a.9.9 0 0 1 1.272 0l3.809 3.808a11.61 11.61 0 0 1 2.218-.789A9.944 9.944 0 0 1 12 5.1c2.652 0 5 1.103 6.826 2.42 1.827 1.317 3.2 2.897 3.923 3.98l.333.5-.333.5c-.647.969-1.81 2.33-3.349 3.547a.9.9 0 0 1-1.116-1.413A15.273 15.273 0 0 0 20.894 12a15.297 15.297 0 0 0-3.12-3.02C16.134 7.797 14.148 6.9 12 6.9c-.655 0-1.295.083-1.914.233-.435.105-.86.242-1.274.407l.418.417a4.9 4.9 0 0 1 7.632 4.654.9.9 0 1 1-1.786-.222 3.1 3.1 0 0 0-4.538-3.123l11.098 11.098a.9.9 0 1 1-1.272 1.272l-3.809-3.808c-1.362.642-2.9 1.072-4.555 1.072-2.651 0-5-1.103-6.826-2.42-1.827-1.317-3.2-2.897-3.923-3.98L.918 12l.333-.5c.645-.966 1.804-2.322 3.335-3.536a.9.9 0 1 1 1.118 1.411A15.266 15.266 0 0 0 3.107 12a15.294 15.294 0 0 0 3.12 3.02C7.866 16.203 9.85 17.1 12 17.1c1.114 0 2.185-.24 3.188-.64l-.418-.418A4.9 4.9 0 0 1 7.1 12a8.888 8.888 0 0 1-.007-.225 2.488 2.488 0 0 1 .014-.385.9.9 0 1 1 1.786.222.79.79 0 0 0-.001.11A6.245 6.245 0 0 1 8.9 12a3.1 3.1 0 0 0 4.562 2.734L8.586 9.859a.912.912 0 0 1-.102-.102l-6.12-6.12a.9.9 0 0 1 0-1.273Z" clip-rule="evenodd"/></svg>',
|
|
262
262
|
keywords: ["password-invisible"],
|
|
263
263
|
category: "action"
|
|
264
|
-
}, Lr = (t) => /* @__PURE__ */ s(V, { ...t, svg:
|
|
264
|
+
}, Lr = (t) => /* @__PURE__ */ s(V, { ...t, svg: Ct });
|
|
265
265
|
Lr.displayName = "IconPasswordInvisible";
|
|
266
|
-
const
|
|
266
|
+
const Mt = {
|
|
267
267
|
name: "password-visible",
|
|
268
268
|
svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M3.107 12a15.294 15.294 0 0 0 3.12 3.02C7.866 16.203 9.85 17.1 12 17.1c2.149 0 4.134-.897 5.774-2.08a15.295 15.295 0 0 0 3.12-3.02 15.3 15.3 0 0 0-3.12-3.02C16.134 7.797 14.148 6.9 12 6.9c-2.149 0-4.134.897-5.774 2.08A15.299 15.299 0 0 0 3.106 12Zm2.067-4.48C7 6.203 9.349 5.1 12 5.1c2.652 0 5 1.103 6.826 2.42 1.827 1.317 3.2 2.897 3.923 3.98l.333.5-.333.5c-.722 1.083-2.096 2.663-3.923 3.98C17 17.797 14.651 18.9 12 18.9s-5-1.103-6.826-2.42c-1.827-1.317-3.2-2.897-3.923-3.98L.918 12l.333-.5c.722-1.083 2.096-2.663 3.923-3.98ZM12 8.9a3.1 3.1 0 1 0 0 6.2 3.1 3.1 0 0 0 0-6.2ZM7.1 12a4.9 4.9 0 1 1 9.8 0 4.9 4.9 0 0 1-9.8 0Zm4-1.538a.9.9 0 0 1 .9-.9A2.438 2.438 0 0 1 14.438 12a.9.9 0 0 1-1.8 0 .638.638 0 0 0-.638-.638.9.9 0 0 1-.9-.9Z" clip-rule="evenodd"/></svg>',
|
|
269
269
|
keywords: ["password-visible"],
|
|
270
270
|
category: "action"
|
|
271
|
-
}, Tr = (t) => /* @__PURE__ */ s(V, { ...t, svg:
|
|
271
|
+
}, Tr = (t) => /* @__PURE__ */ s(V, { ...t, svg: Mt });
|
|
272
272
|
Tr.displayName = "IconPasswordVisible";
|
|
273
|
-
const
|
|
273
|
+
const zt = {
|
|
274
274
|
LG: "lg"
|
|
275
275
|
};
|
|
276
|
-
function
|
|
276
|
+
function Rt(t) {
|
|
277
277
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
278
278
|
}
|
|
279
279
|
var sr = { exports: {} }, or;
|
|
@@ -310,7 +310,7 @@ function Et() {
|
|
|
310
310
|
})(sr)), sr.exports;
|
|
311
311
|
}
|
|
312
312
|
var It = Et();
|
|
313
|
-
const kt = /* @__PURE__ */
|
|
313
|
+
const kt = /* @__PURE__ */ Rt(It), Dt = "_rotate_12t9p_1", Bt = "_dash_12t9p_1", Lt = {
|
|
314
314
|
"purpur-spinner": "_purpur-spinner_12t9p_2",
|
|
315
315
|
rotate: Dt,
|
|
316
316
|
"purpur-spinner--xxs": "_purpur-spinner--xxs_12t9p_6",
|
|
@@ -415,9 +415,9 @@ const Ft = /* @__PURE__ */ Wt(Gt), Vt = {
|
|
|
415
415
|
onClick: u,
|
|
416
416
|
size: d = "md",
|
|
417
417
|
variant: o,
|
|
418
|
-
type:
|
|
418
|
+
type: g = "button",
|
|
419
419
|
...l
|
|
420
|
-
},
|
|
420
|
+
}, h) => {
|
|
421
421
|
if (p && o === "destructive")
|
|
422
422
|
return null;
|
|
423
423
|
const y = dr(
|
|
@@ -440,8 +440,8 @@ const Ft = /* @__PURE__ */ Wt(Gt), Vt = {
|
|
|
440
440
|
"button",
|
|
441
441
|
{
|
|
442
442
|
className: y,
|
|
443
|
-
type:
|
|
444
|
-
ref:
|
|
443
|
+
type: g,
|
|
444
|
+
ref: h,
|
|
445
445
|
"aria-disabled": c,
|
|
446
446
|
onClick: f,
|
|
447
447
|
...l,
|
|
@@ -449,7 +449,7 @@ const Ft = /* @__PURE__ */ Wt(Gt), Vt = {
|
|
|
449
449
|
r && /* @__PURE__ */ s(
|
|
450
450
|
Wr,
|
|
451
451
|
{
|
|
452
|
-
size: d ===
|
|
452
|
+
size: d === zt.LG ? "xs" : "xxs",
|
|
453
453
|
negative: e,
|
|
454
454
|
disabled: c,
|
|
455
455
|
className: dr(`${j}__spinner`)
|
|
@@ -466,9 +466,9 @@ Zr.displayName = "Button";
|
|
|
466
466
|
function Ht(t) {
|
|
467
467
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
468
468
|
}
|
|
469
|
-
var fr = { exports: {} },
|
|
469
|
+
var fr = { exports: {} }, gr;
|
|
470
470
|
function Kt() {
|
|
471
|
-
return
|
|
471
|
+
return gr || (gr = 1, (function(t) {
|
|
472
472
|
(function() {
|
|
473
473
|
var i = {}.hasOwnProperty;
|
|
474
474
|
function n() {
|
|
@@ -508,7 +508,7 @@ const Yt = /* @__PURE__ */ Ht(Ut), Xt = {
|
|
|
508
508
|
"purpur-icon--md": "_purpur-icon--md_8u1lq_16",
|
|
509
509
|
"purpur-icon--lg": "_purpur-icon--lg_8u1lq_20",
|
|
510
510
|
"purpur-icon--xl": "_purpur-icon--xl_8u1lq_24"
|
|
511
|
-
}, Jt = Yt.bind(Xt),
|
|
511
|
+
}, Jt = Yt.bind(Xt), vr = "purpur-icon", Qt = "md", re = (t) => t.filter((i) => Object.keys(i).length >= 1).map((i) => `${i.name}="${i.value}"`).join(" "), te = ({ content: t = "", title: i } = {}) => {
|
|
512
512
|
const n = [
|
|
513
513
|
{ name: "xmlns", value: "http://www.w3.org/2000/svg" },
|
|
514
514
|
{ name: "fill", value: "currentColor" },
|
|
@@ -520,7 +520,7 @@ const Yt = /* @__PURE__ */ Ht(Ut), Xt = {
|
|
|
520
520
|
const r = te({
|
|
521
521
|
content: ee(t.svg),
|
|
522
522
|
title: i
|
|
523
|
-
}), e = Jt(
|
|
523
|
+
}), e = Jt(vr, `${vr}--${a}`, n);
|
|
524
524
|
return /* @__PURE__ */ s("span", { className: e, dangerouslySetInnerHTML: { __html: r }, ...p });
|
|
525
525
|
};
|
|
526
526
|
Gr.displayName = "Icon";
|
|
@@ -533,7 +533,7 @@ const ne = {
|
|
|
533
533
|
function ue(t) {
|
|
534
534
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
535
535
|
}
|
|
536
|
-
var
|
|
536
|
+
var hr = { exports: {} }, mr;
|
|
537
537
|
function ie() {
|
|
538
538
|
return mr || (mr = 1, (function(t) {
|
|
539
539
|
(function() {
|
|
@@ -564,7 +564,7 @@ function ie() {
|
|
|
564
564
|
}
|
|
565
565
|
t.exports ? (n.default = n, t.exports = n) : window.classNames = n;
|
|
566
566
|
})();
|
|
567
|
-
})(
|
|
567
|
+
})(hr)), hr.exports;
|
|
568
568
|
}
|
|
569
569
|
var pe = ie();
|
|
570
570
|
const ae = /* @__PURE__ */ ue(pe), se = {
|
|
@@ -630,10 +630,10 @@ function ce() {
|
|
|
630
630
|
}
|
|
631
631
|
var _e = ce();
|
|
632
632
|
const de = /* @__PURE__ */ le(_e), fe = {
|
|
633
|
-
"purpur-field-helper-text": "_purpur-field-helper-
|
|
634
|
-
"purpur-field-helper-text--disabled": "_purpur-field-helper-text--
|
|
635
|
-
"purpur-field-helper-text--negative": "_purpur-field-helper-text--
|
|
636
|
-
},
|
|
633
|
+
"purpur-field-helper-text": "_purpur-field-helper-text_1ociq_1",
|
|
634
|
+
"purpur-field-helper-text--disabled": "_purpur-field-helper-text--disabled_1ociq_9",
|
|
635
|
+
"purpur-field-helper-text--negative": "_purpur-field-helper-text--negative_1ociq_12"
|
|
636
|
+
}, ge = de.bind(fe), W = "purpur-field-helper-text", ve = ({
|
|
637
637
|
children: t,
|
|
638
638
|
className: i,
|
|
639
639
|
disabled: n,
|
|
@@ -641,13 +641,13 @@ const de = /* @__PURE__ */ le(_e), fe = {
|
|
|
641
641
|
negative: p,
|
|
642
642
|
...r
|
|
643
643
|
}) => {
|
|
644
|
-
const e =
|
|
644
|
+
const e = ge(i, W, {
|
|
645
645
|
[`${W}--disabled`]: n,
|
|
646
646
|
[`${W}--negative`]: p
|
|
647
647
|
});
|
|
648
648
|
return /* @__PURE__ */ s("span", { id: a, className: e, ...r, children: t });
|
|
649
649
|
};
|
|
650
|
-
function
|
|
650
|
+
function he(t) {
|
|
651
651
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
652
652
|
}
|
|
653
653
|
var wr = { exports: {} }, $r;
|
|
@@ -684,7 +684,7 @@ function me() {
|
|
|
684
684
|
})(wr)), wr.exports;
|
|
685
685
|
}
|
|
686
686
|
var be = me();
|
|
687
|
-
const ye = /* @__PURE__ */
|
|
687
|
+
const ye = /* @__PURE__ */ he(be), xe = {
|
|
688
688
|
"purpur-icon": "_purpur-icon_8u1lq_1",
|
|
689
689
|
"purpur-icon--xxs": "_purpur-icon--xxs_8u1lq_4",
|
|
690
690
|
"purpur-icon--xs": "_purpur-icon--xs_8u1lq_8",
|
|
@@ -744,34 +744,34 @@ function Ae(...t) {
|
|
|
744
744
|
};
|
|
745
745
|
}
|
|
746
746
|
// @__NO_SIDE_EFFECTS__
|
|
747
|
-
function
|
|
748
|
-
const i = /* @__PURE__ */
|
|
749
|
-
const { children: r, ...e } = a, u =
|
|
747
|
+
function qe(t) {
|
|
748
|
+
const i = /* @__PURE__ */ Ce(t), n = v.forwardRef((a, p) => {
|
|
749
|
+
const { children: r, ...e } = a, u = v.Children.toArray(r), d = u.find(ze);
|
|
750
750
|
if (d) {
|
|
751
|
-
const o = d.props.children,
|
|
752
|
-
return /* @__PURE__ */ s(i, { ...e, ref: p, children:
|
|
751
|
+
const o = d.props.children, g = u.map((l) => l === d ? v.Children.count(o) > 1 ? v.Children.only(null) : v.isValidElement(o) ? o.props.children : null : l);
|
|
752
|
+
return /* @__PURE__ */ s(i, { ...e, ref: p, children: v.isValidElement(o) ? v.cloneElement(o, void 0, g) : null });
|
|
753
753
|
}
|
|
754
754
|
return /* @__PURE__ */ s(i, { ...e, ref: p, children: r });
|
|
755
755
|
});
|
|
756
756
|
return n.displayName = `${t}.Slot`, n;
|
|
757
757
|
}
|
|
758
758
|
// @__NO_SIDE_EFFECTS__
|
|
759
|
-
function
|
|
760
|
-
const i =
|
|
759
|
+
function Ce(t) {
|
|
760
|
+
const i = v.forwardRef((n, a) => {
|
|
761
761
|
const { children: p, ...r } = n;
|
|
762
|
-
if (
|
|
763
|
-
const e = Ee(p), u =
|
|
764
|
-
return p.type !==
|
|
762
|
+
if (v.isValidElement(p)) {
|
|
763
|
+
const e = Ee(p), u = Re(r, p.props);
|
|
764
|
+
return p.type !== v.Fragment && (u.ref = a ? Ae(a, e) : e), v.cloneElement(p, u);
|
|
765
765
|
}
|
|
766
|
-
return
|
|
766
|
+
return v.Children.count(p) > 1 ? v.Children.only(null) : null;
|
|
767
767
|
});
|
|
768
768
|
return i.displayName = `${t}.SlotClone`, i;
|
|
769
769
|
}
|
|
770
|
-
var
|
|
771
|
-
function
|
|
772
|
-
return
|
|
770
|
+
var Me = Symbol("radix.slottable");
|
|
771
|
+
function ze(t) {
|
|
772
|
+
return v.isValidElement(t) && typeof t.type == "function" && "__radixId" in t.type && t.type.__radixId === Me;
|
|
773
773
|
}
|
|
774
|
-
function
|
|
774
|
+
function Re(t, i) {
|
|
775
775
|
const n = { ...i };
|
|
776
776
|
for (const a in i) {
|
|
777
777
|
const p = t[a], r = i[a];
|
|
@@ -805,12 +805,12 @@ var Ie = [
|
|
|
805
805
|
"svg",
|
|
806
806
|
"ul"
|
|
807
807
|
], ke = Ie.reduce((t, i) => {
|
|
808
|
-
const n = /* @__PURE__ */
|
|
808
|
+
const n = /* @__PURE__ */ qe(`Primitive.${i}`), a = v.forwardRef((p, r) => {
|
|
809
809
|
const { asChild: e, ...u } = p, d = e ? n : i;
|
|
810
810
|
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ s(d, { ...u, ref: r });
|
|
811
811
|
});
|
|
812
812
|
return a.displayName = `Primitive.${i}`, { ...t, [i]: a };
|
|
813
|
-
}, {}), De = "Label", Hr =
|
|
813
|
+
}, {}), De = "Label", Hr = v.forwardRef((t, i) => /* @__PURE__ */ s(
|
|
814
814
|
ke.label,
|
|
815
815
|
{
|
|
816
816
|
...t,
|
|
@@ -925,7 +925,7 @@ const Ye = /* @__PURE__ */ He(Ue), Xe = "_rotate_12t9p_1", Je = "_dash_12t9p_1",
|
|
|
925
925
|
dash: Je,
|
|
926
926
|
"purpur-spinner__circle--disabled": "_purpur-spinner__circle--disabled_12t9p_41",
|
|
927
927
|
"purpur-spinner__circle--negative": "_purpur-spinner__circle--negative_12t9p_44"
|
|
928
|
-
},
|
|
928
|
+
}, qr = Ye.bind(Qe), q = "purpur-spinner", rn = {
|
|
929
929
|
SM: "sm"
|
|
930
930
|
}, Kr = ({
|
|
931
931
|
disabled: t = !1,
|
|
@@ -933,12 +933,12 @@ const Ye = /* @__PURE__ */ He(Ue), Xe = "_rotate_12t9p_1", Je = "_dash_12t9p_1",
|
|
|
933
933
|
size: n = rn.SM,
|
|
934
934
|
className: a,
|
|
935
935
|
...p
|
|
936
|
-
}) => /* @__PURE__ */ s("div", { className:
|
|
936
|
+
}) => /* @__PURE__ */ s("div", { className: qr(q, `${q}--${n}`, a), ...p, children: /* @__PURE__ */ s("svg", { viewBox: "0 0 50 50", children: /* @__PURE__ */ s(
|
|
937
937
|
"circle",
|
|
938
938
|
{
|
|
939
|
-
className:
|
|
940
|
-
[`${
|
|
941
|
-
[`${
|
|
939
|
+
className: qr(`${q}__circle`, {
|
|
940
|
+
[`${q}__circle--disabled`]: t,
|
|
941
|
+
[`${q}__circle--negative`]: i
|
|
942
942
|
}),
|
|
943
943
|
cx: "25",
|
|
944
944
|
cy: "25",
|
|
@@ -949,9 +949,9 @@ Kr.displayName = "Spinner";
|
|
|
949
949
|
function tn(t) {
|
|
950
950
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
951
951
|
}
|
|
952
|
-
var
|
|
952
|
+
var Cr = { exports: {} }, Mr;
|
|
953
953
|
function en() {
|
|
954
|
-
return
|
|
954
|
+
return Mr || (Mr = 1, (function(t) {
|
|
955
955
|
(function() {
|
|
956
956
|
var i = {}.hasOwnProperty;
|
|
957
957
|
function n() {
|
|
@@ -980,30 +980,30 @@ function en() {
|
|
|
980
980
|
}
|
|
981
981
|
t.exports ? (n.default = n, t.exports = n) : window.classNames = n;
|
|
982
982
|
})();
|
|
983
|
-
})(
|
|
983
|
+
})(Cr)), Cr.exports;
|
|
984
984
|
}
|
|
985
985
|
var nn = en();
|
|
986
986
|
const un = /* @__PURE__ */ tn(nn), pn = {
|
|
987
|
-
"purpur-text-field": "_purpur-text-
|
|
988
|
-
"purpur-text-field__label": "_purpur-text-
|
|
989
|
-
"purpur-text-field__label-text": "_purpur-text-field__label-
|
|
990
|
-
"purpur-text-field__field-row": "_purpur-text-field__field-
|
|
991
|
-
"purpur-text-field__frame": "_purpur-text-
|
|
992
|
-
"purpur-text-field__frame--negative": "_purpur-text-field__frame--
|
|
993
|
-
"purpur-text-field__input-container": "_purpur-text-field__input-
|
|
994
|
-
"purpur-text-field__input-container--disabled": "_purpur-text-field__input-container--
|
|
995
|
-
"purpur-text-field__input-container--readonly": "_purpur-text-field__input-container--
|
|
996
|
-
"purpur-text-field__input-container--has-clear-button": "_purpur-text-field__input-container--has-clear-
|
|
997
|
-
"purpur-text-field__input-container--end-adornment": "_purpur-text-field__input-container--end-
|
|
998
|
-
"purpur-text-field__input": "_purpur-text-
|
|
999
|
-
"purpur-text-field__input-container--start-adornment": "_purpur-text-field__input-container--start-
|
|
1000
|
-
"purpur-text-field__input-container--negative": "_purpur-text-field__input-container--
|
|
1001
|
-
"purpur-text-field__input--valid": "_purpur-text-field__input--
|
|
1002
|
-
"purpur-text-field__input--error": "_purpur-text-field__input--
|
|
1003
|
-
"purpur-text-field__input--negative": "_purpur-text-field__input--
|
|
1004
|
-
"purpur-text-field__adornment-container": "_purpur-text-field__adornment-
|
|
1005
|
-
"purpur-text-field__valid-icon": "_purpur-text-field__valid-
|
|
1006
|
-
"purpur-text-field__valid-icon--negative": "_purpur-text-field__valid-icon--
|
|
987
|
+
"purpur-text-field": "_purpur-text-field_1n0q1_1",
|
|
988
|
+
"purpur-text-field__label": "_purpur-text-field__label_1n0q1_7",
|
|
989
|
+
"purpur-text-field__label-text": "_purpur-text-field__label-text_1n0q1_12",
|
|
990
|
+
"purpur-text-field__field-row": "_purpur-text-field__field-row_1n0q1_15",
|
|
991
|
+
"purpur-text-field__frame": "_purpur-text-field__frame_1n0q1_19",
|
|
992
|
+
"purpur-text-field__frame--negative": "_purpur-text-field__frame--negative_1n0q1_26",
|
|
993
|
+
"purpur-text-field__input-container": "_purpur-text-field__input-container_1n0q1_29",
|
|
994
|
+
"purpur-text-field__input-container--disabled": "_purpur-text-field__input-container--disabled_1n0q1_40",
|
|
995
|
+
"purpur-text-field__input-container--readonly": "_purpur-text-field__input-container--readonly_1n0q1_43",
|
|
996
|
+
"purpur-text-field__input-container--has-clear-button": "_purpur-text-field__input-container--has-clear-button_1n0q1_46",
|
|
997
|
+
"purpur-text-field__input-container--end-adornment": "_purpur-text-field__input-container--end-adornment_1n0q1_49",
|
|
998
|
+
"purpur-text-field__input": "_purpur-text-field__input_1n0q1_29",
|
|
999
|
+
"purpur-text-field__input-container--start-adornment": "_purpur-text-field__input-container--start-adornment_1n0q1_55",
|
|
1000
|
+
"purpur-text-field__input-container--negative": "_purpur-text-field__input-container--negative_1n0q1_61",
|
|
1001
|
+
"purpur-text-field__input--valid": "_purpur-text-field__input--valid_1n0q1_109",
|
|
1002
|
+
"purpur-text-field__input--error": "_purpur-text-field__input--error_1n0q1_109",
|
|
1003
|
+
"purpur-text-field__input--negative": "_purpur-text-field__input--negative_1n0q1_130",
|
|
1004
|
+
"purpur-text-field__adornment-container": "_purpur-text-field__adornment-container_1n0q1_146",
|
|
1005
|
+
"purpur-text-field__valid-icon": "_purpur-text-field__valid-icon_1n0q1_151",
|
|
1006
|
+
"purpur-text-field__valid-icon--negative": "_purpur-text-field__valid-icon--negative_1n0q1_154"
|
|
1007
1007
|
}, an = (t) => nt(t), $ = un.bind(pn), _ = "purpur-text-field", Ur = O(
|
|
1008
1008
|
({
|
|
1009
1009
|
["data-testid"]: t,
|
|
@@ -1016,19 +1016,19 @@ const un = /* @__PURE__ */ tn(nn), pn = {
|
|
|
1016
1016
|
helperText: u,
|
|
1017
1017
|
hideRequiredAsterisk: d = !1,
|
|
1018
1018
|
label: o,
|
|
1019
|
-
loading:
|
|
1019
|
+
loading: g = !1,
|
|
1020
1020
|
onClear: l,
|
|
1021
|
-
startAdornment:
|
|
1021
|
+
startAdornment: h,
|
|
1022
1022
|
valid: y = !1,
|
|
1023
1023
|
negative: f = !1,
|
|
1024
1024
|
...c
|
|
1025
1025
|
}, b) => {
|
|
1026
|
-
const Jr = et(), k = c.id ?? Jr, x = (w) => t ? `${t}-${w}` : void 0, Y = y && !e, D = u ? `${k}-helper-text` : void 0, B = [
|
|
1026
|
+
const Jr = et(), k = c.id ?? Jr, x = (w) => t ? `${t}-${w}` : void 0, Y = y && !e, D = u ? `${k}-helper-text` : void 0, B = [h].filter((w) => !!w), X = (typeof c.value == "number" ? c.value !== void 0 : c.value?.length) && !c.disabled && !c.readOnly && !g && l && n, J = an(null), Qr = (w) => {
|
|
1027
1027
|
J.current = w, typeof b == "function" ? b(w) : b && (b.current = w);
|
|
1028
1028
|
}, rt = () => {
|
|
1029
1029
|
l?.(), J.current?.focus();
|
|
1030
1030
|
}, L = [
|
|
1031
|
-
|
|
1031
|
+
g && /* @__PURE__ */ s(
|
|
1032
1032
|
Kr,
|
|
1033
1033
|
{
|
|
1034
1034
|
disabled: c.disabled,
|
|
@@ -1138,7 +1138,7 @@ const un = /* @__PURE__ */ tn(nn), pn = {
|
|
|
1138
1138
|
!!p && p
|
|
1139
1139
|
] }),
|
|
1140
1140
|
D && /* @__PURE__ */ s(
|
|
1141
|
-
|
|
1141
|
+
ve,
|
|
1142
1142
|
{
|
|
1143
1143
|
"data-testid": x("helper-text"),
|
|
1144
1144
|
id: D,
|
|
@@ -1156,9 +1156,9 @@ function sn(t) {
|
|
|
1156
1156
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
1157
1157
|
}
|
|
1158
1158
|
var G = { exports: {} };
|
|
1159
|
-
var
|
|
1159
|
+
var zr;
|
|
1160
1160
|
function on() {
|
|
1161
|
-
return
|
|
1161
|
+
return zr || (zr = 1, (function(t) {
|
|
1162
1162
|
(function() {
|
|
1163
1163
|
var i = {}.hasOwnProperty;
|
|
1164
1164
|
function n() {
|
|
@@ -1190,7 +1190,7 @@ function on() {
|
|
|
1190
1190
|
})(G)), G.exports;
|
|
1191
1191
|
}
|
|
1192
1192
|
var ln = on();
|
|
1193
|
-
const K = /* @__PURE__ */ sn(ln),
|
|
1193
|
+
const K = /* @__PURE__ */ sn(ln), C = {
|
|
1194
1194
|
WEAK: "weak",
|
|
1195
1195
|
MEDIUM: "medium",
|
|
1196
1196
|
STRONG: "strong"
|
|
@@ -1203,7 +1203,7 @@ const K = /* @__PURE__ */ sn(ln), M = {
|
|
|
1203
1203
|
function _n(t) {
|
|
1204
1204
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
1205
1205
|
}
|
|
1206
|
-
var
|
|
1206
|
+
var Rr = { exports: {} }, Er;
|
|
1207
1207
|
function dn() {
|
|
1208
1208
|
return Er || (Er = 1, (function(t) {
|
|
1209
1209
|
(function() {
|
|
@@ -1234,10 +1234,10 @@ function dn() {
|
|
|
1234
1234
|
}
|
|
1235
1235
|
t.exports ? (n.default = n, t.exports = n) : window.classNames = n;
|
|
1236
1236
|
})();
|
|
1237
|
-
})(
|
|
1237
|
+
})(Rr)), Rr.exports;
|
|
1238
1238
|
}
|
|
1239
1239
|
var fn = dn();
|
|
1240
|
-
const
|
|
1240
|
+
const gn = /* @__PURE__ */ _n(fn), vn = {
|
|
1241
1241
|
"purpur-paragraph": "_purpur-paragraph_1vz75_1",
|
|
1242
1242
|
"purpur-paragraph--disabled": "_purpur-paragraph--disabled_1vz75_7",
|
|
1243
1243
|
"purpur-paragraph--hyphens": "_purpur-paragraph--hyphens_1vz75_10",
|
|
@@ -1253,9 +1253,9 @@ const hn = /* @__PURE__ */ _n(fn), gn = {
|
|
|
1253
1253
|
"purpur-paragraph--additional-100-bold": "_purpur-paragraph--additional-100-bold_1vz75_67",
|
|
1254
1254
|
"purpur-paragraph--overline-100": "_purpur-paragraph--overline-100_1vz75_74",
|
|
1255
1255
|
"purpur-paragraph--overline-200": "_purpur-paragraph--overline-200_1vz75_82"
|
|
1256
|
-
},
|
|
1256
|
+
}, hn = gn.bind(vn), mn = {
|
|
1257
1257
|
PARAGRAPH100: "paragraph-100"
|
|
1258
|
-
},
|
|
1258
|
+
}, M = "purpur-paragraph", Yr = ({
|
|
1259
1259
|
children: t,
|
|
1260
1260
|
className: i,
|
|
1261
1261
|
disabled: n,
|
|
@@ -1264,10 +1264,10 @@ const hn = /* @__PURE__ */ _n(fn), gn = {
|
|
|
1264
1264
|
variant: r = mn.PARAGRAPH100,
|
|
1265
1265
|
...e
|
|
1266
1266
|
}) => {
|
|
1267
|
-
const u =
|
|
1268
|
-
[`${
|
|
1269
|
-
[`${
|
|
1270
|
-
[`${
|
|
1267
|
+
const u = hn(i, M, `${M}--${r}`, {
|
|
1268
|
+
[`${M}--hyphens`]: a,
|
|
1269
|
+
[`${M}--disabled`]: n,
|
|
1270
|
+
[`${M}--negative`]: p
|
|
1271
1271
|
});
|
|
1272
1272
|
return /* @__PURE__ */ s("p", { ...e, className: u, children: t });
|
|
1273
1273
|
};
|
|
@@ -1304,13 +1304,13 @@ const bn = {
|
|
|
1304
1304
|
);
|
|
1305
1305
|
I.displayName = "PasswordStrengthIndicator";
|
|
1306
1306
|
const wn = (t, i, n, a) => {
|
|
1307
|
-
const [p, r] = E(0), [e, u] = E(), [d, o] = E(void 0),
|
|
1307
|
+
const [p, r] = E(0), [e, u] = E(), [d, o] = E(void 0), g = ut(
|
|
1308
1308
|
() => ({
|
|
1309
|
-
0: [
|
|
1310
|
-
1: [
|
|
1311
|
-
2: [
|
|
1312
|
-
3: [
|
|
1313
|
-
4: [
|
|
1309
|
+
0: [C.WEAK, i],
|
|
1310
|
+
1: [C.WEAK, i],
|
|
1311
|
+
2: [C.MEDIUM, n],
|
|
1312
|
+
3: [C.STRONG, a],
|
|
1313
|
+
4: [C.STRONG, a]
|
|
1314
1314
|
}),
|
|
1315
1315
|
[i, n, a]
|
|
1316
1316
|
);
|
|
@@ -1319,16 +1319,16 @@ const wn = (t, i, n, a) => {
|
|
|
1319
1319
|
if (!t)
|
|
1320
1320
|
r(0), u(void 0), o(void 0);
|
|
1321
1321
|
else {
|
|
1322
|
-
const { default: l } = await import("./main-
|
|
1323
|
-
r(
|
|
1322
|
+
const { default: l } = await import("./main-BR_vazIG.mjs").then((c) => c.m), { score: h } = l(t), [y, f] = g[h];
|
|
1323
|
+
r(h), u(y), o(f);
|
|
1324
1324
|
}
|
|
1325
1325
|
})();
|
|
1326
|
-
}, [t,
|
|
1326
|
+
}, [t, g]), {
|
|
1327
1327
|
score: p,
|
|
1328
1328
|
passwordStrength: e,
|
|
1329
1329
|
currentPasswordStrengthText: d
|
|
1330
1330
|
};
|
|
1331
|
-
},
|
|
1331
|
+
}, R = K.bind(bn), z = "purpur-password-strength", U = O(
|
|
1332
1332
|
({
|
|
1333
1333
|
["data-testid"]: t = "password-strength",
|
|
1334
1334
|
className: i,
|
|
@@ -1339,14 +1339,14 @@ const wn = (t, i, n, a) => {
|
|
|
1339
1339
|
strongText: e,
|
|
1340
1340
|
...u
|
|
1341
1341
|
}, d) => {
|
|
1342
|
-
const o =
|
|
1342
|
+
const o = R(i, z), { score: g, passwordStrength: l, currentPasswordStrengthText: h } = wn(
|
|
1343
1343
|
n,
|
|
1344
1344
|
p,
|
|
1345
1345
|
r,
|
|
1346
1346
|
e
|
|
1347
1347
|
);
|
|
1348
1348
|
return /* @__PURE__ */ m("div", { "data-testid": t, className: o, ref: d, ...u, children: [
|
|
1349
|
-
/* @__PURE__ */ m("div", { className:
|
|
1349
|
+
/* @__PURE__ */ m("div", { className: R(`${z}__indicator-container`), children: [
|
|
1350
1350
|
/* @__PURE__ */ s(
|
|
1351
1351
|
I,
|
|
1352
1352
|
{
|
|
@@ -1357,14 +1357,14 @@ const wn = (t, i, n, a) => {
|
|
|
1357
1357
|
/* @__PURE__ */ s(
|
|
1358
1358
|
I,
|
|
1359
1359
|
{
|
|
1360
|
-
active: !!l &&
|
|
1360
|
+
active: !!l && g > 1,
|
|
1361
1361
|
passwordStrength: l
|
|
1362
1362
|
}
|
|
1363
1363
|
),
|
|
1364
1364
|
/* @__PURE__ */ s(
|
|
1365
1365
|
I,
|
|
1366
1366
|
{
|
|
1367
|
-
active: !!l &&
|
|
1367
|
+
active: !!l && g > 2,
|
|
1368
1368
|
passwordStrength: l
|
|
1369
1369
|
}
|
|
1370
1370
|
)
|
|
@@ -1374,15 +1374,15 @@ const wn = (t, i, n, a) => {
|
|
|
1374
1374
|
{
|
|
1375
1375
|
"aria-live": "polite",
|
|
1376
1376
|
"data-testid": `${t}-text`,
|
|
1377
|
-
className:
|
|
1378
|
-
[`${
|
|
1377
|
+
className: R(`${z}__password-strength-text`, {
|
|
1378
|
+
[`${z}__password-strength-text--${l}`]: l
|
|
1379
1379
|
}),
|
|
1380
1380
|
children: [
|
|
1381
|
-
/* @__PURE__ */ m("span", { className:
|
|
1381
|
+
/* @__PURE__ */ m("span", { className: R(`${z}__password-strength-label`), children: [
|
|
1382
1382
|
a,
|
|
1383
|
-
|
|
1383
|
+
h ? ": " : ""
|
|
1384
1384
|
] }),
|
|
1385
|
-
|
|
1385
|
+
h
|
|
1386
1386
|
]
|
|
1387
1387
|
}
|
|
1388
1388
|
)
|
|
@@ -1400,10 +1400,10 @@ const Ir = K.bind(cn), kr = "purpur-password-field", Xr = O(
|
|
|
1400
1400
|
showPasswordAriaLabel: r,
|
|
1401
1401
|
...e
|
|
1402
1402
|
}, u) => {
|
|
1403
|
-
const d = Ir(n, kr), [o,
|
|
1403
|
+
const d = Ir(n, kr), [o, g] = E(N.PASSWORD), l = async (f) => {
|
|
1404
1404
|
p?.(f);
|
|
1405
|
-
},
|
|
1406
|
-
|
|
1405
|
+
}, h = () => {
|
|
1406
|
+
g(o === N.PASSWORD ? N.TEXT : N.PASSWORD);
|
|
1407
1407
|
}, y = o === N.PASSWORD ? Tr : Lr;
|
|
1408
1408
|
return /* @__PURE__ */ m("div", { className: d, children: [
|
|
1409
1409
|
/* @__PURE__ */ s(
|
|
@@ -1419,7 +1419,7 @@ const Ir = K.bind(cn), kr = "purpur-password-field", Xr = O(
|
|
|
1419
1419
|
{
|
|
1420
1420
|
"aria-label": o === N.PASSWORD ? r : a,
|
|
1421
1421
|
"data-testid": `${t}-type-toggle-button`,
|
|
1422
|
-
onClick:
|
|
1422
|
+
onClick: h,
|
|
1423
1423
|
size: "sm",
|
|
1424
1424
|
variant: "tertiary-purple",
|
|
1425
1425
|
iconOnly: !0,
|
|
@@ -1441,4 +1441,4 @@ export {
|
|
|
1441
1441
|
sn as g,
|
|
1442
1442
|
Nn as i
|
|
1443
1443
|
};
|
|
1444
|
-
//# sourceMappingURL=password-field-
|
|
1444
|
+
//# sourceMappingURL=password-field-rjwA_Jz0.mjs.map
|