@purpurds/text-field 8.8.1 → 8.9.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 +6 -6
- package/dist/styles.css +1 -1
- package/dist/text-field.cjs.js +1 -37
- package/dist/text-field.cjs.js.map +1 -1
- package/dist/text-field.es.js +288 -345
- package/dist/text-field.es.js.map +1 -1
- package/package.json +25 -25
package/dist/text-field.es.js
CHANGED
|
@@ -1,28 +1,22 @@
|
|
|
1
1
|
import { jsxs as b, jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import * as s from "react";
|
|
3
|
-
import { forwardRef as
|
|
3
|
+
import { forwardRef as sr, useRef as wr, useId as jr, isValidElement as Sr } from "react";
|
|
4
4
|
import "react-dom";
|
|
5
|
-
const
|
|
5
|
+
const Nr = {
|
|
6
6
|
LG: "lg"
|
|
7
7
|
};
|
|
8
|
-
function
|
|
8
|
+
function Or(e) {
|
|
9
9
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
10
10
|
}
|
|
11
|
-
var
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Licensed under the MIT License (MIT), see
|
|
15
|
-
http://jedwatson.github.io/classnames
|
|
16
|
-
*/
|
|
17
|
-
var Z;
|
|
18
|
-
function Mr() {
|
|
19
|
-
return Z || (Z = 1, (function(e) {
|
|
11
|
+
var L = { exports: {} }, D;
|
|
12
|
+
function Cr() {
|
|
13
|
+
return D || (D = 1, (function(e) {
|
|
20
14
|
(function() {
|
|
21
|
-
var
|
|
15
|
+
var u = {}.hasOwnProperty;
|
|
22
16
|
function n() {
|
|
23
17
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
24
18
|
var i = arguments[t];
|
|
25
|
-
i && (r =
|
|
19
|
+
i && (r = a(r, p.call(this, i)));
|
|
26
20
|
}
|
|
27
21
|
return r;
|
|
28
22
|
}
|
|
@@ -37,68 +31,62 @@ function Mr() {
|
|
|
37
31
|
return r.toString();
|
|
38
32
|
var t = "";
|
|
39
33
|
for (var i in r)
|
|
40
|
-
|
|
34
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
41
35
|
return t;
|
|
42
36
|
}
|
|
43
|
-
function
|
|
37
|
+
function a(r, t) {
|
|
44
38
|
return t ? r ? r + " " + t : r + t : r;
|
|
45
39
|
}
|
|
46
40
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
47
41
|
})();
|
|
48
|
-
})(
|
|
42
|
+
})(L)), L.exports;
|
|
49
43
|
}
|
|
50
|
-
var
|
|
51
|
-
const
|
|
44
|
+
var kr = Cr();
|
|
45
|
+
const Mr = /* @__PURE__ */ Or(kr), Ar = "_rotate_12t9p_1", qr = "_dash_12t9p_1", Rr = {
|
|
52
46
|
"purpur-spinner": "_purpur-spinner_12t9p_2",
|
|
53
|
-
rotate:
|
|
47
|
+
rotate: Ar,
|
|
54
48
|
"purpur-spinner--xxs": "_purpur-spinner--xxs_12t9p_6",
|
|
55
49
|
"purpur-spinner--xs": "_purpur-spinner--xs_12t9p_10",
|
|
56
50
|
"purpur-spinner--sm": "_purpur-spinner--sm_12t9p_14",
|
|
57
51
|
"purpur-spinner--md": "_purpur-spinner--md_12t9p_18",
|
|
58
52
|
"purpur-spinner--lg": "_purpur-spinner--lg_12t9p_22",
|
|
59
53
|
"purpur-spinner__circle": "_purpur-spinner__circle_12t9p_26",
|
|
60
|
-
dash:
|
|
54
|
+
dash: qr,
|
|
61
55
|
"purpur-spinner__circle--disabled": "_purpur-spinner__circle--disabled_12t9p_41",
|
|
62
56
|
"purpur-spinner__circle--negative": "_purpur-spinner__circle--negative_12t9p_44"
|
|
63
|
-
},
|
|
57
|
+
}, Z = Mr.bind(Rr), $ = "purpur-spinner", Ir = {
|
|
64
58
|
SM: "sm"
|
|
65
|
-
},
|
|
59
|
+
}, cr = ({
|
|
66
60
|
disabled: e = !1,
|
|
67
|
-
negative:
|
|
68
|
-
size: n =
|
|
61
|
+
negative: u = !1,
|
|
62
|
+
size: n = Ir.SM,
|
|
69
63
|
className: p,
|
|
70
|
-
...
|
|
71
|
-
}) => /* @__PURE__ */ l("div", { className:
|
|
64
|
+
...a
|
|
65
|
+
}) => /* @__PURE__ */ l("div", { className: Z($, `${$}--${n}`, p), ...a, children: /* @__PURE__ */ l("svg", { viewBox: "0 0 50 50", children: /* @__PURE__ */ l(
|
|
72
66
|
"circle",
|
|
73
67
|
{
|
|
74
|
-
className:
|
|
68
|
+
className: Z(`${$}__circle`, {
|
|
75
69
|
[`${$}__circle--disabled`]: e,
|
|
76
|
-
[`${$}__circle--negative`]:
|
|
70
|
+
[`${$}__circle--negative`]: u
|
|
77
71
|
}),
|
|
78
72
|
cx: "25",
|
|
79
73
|
cy: "25",
|
|
80
74
|
r: "20"
|
|
81
75
|
}
|
|
82
76
|
) }) });
|
|
83
|
-
|
|
84
|
-
function
|
|
77
|
+
cr.displayName = "Spinner";
|
|
78
|
+
function Br(e) {
|
|
85
79
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
86
80
|
}
|
|
87
|
-
var
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
Licensed under the MIT License (MIT), see
|
|
91
|
-
http://jedwatson.github.io/classnames
|
|
92
|
-
*/
|
|
93
|
-
var T;
|
|
94
|
-
function zr() {
|
|
95
|
-
return T || (T = 1, (function(e) {
|
|
81
|
+
var W = { exports: {} }, F;
|
|
82
|
+
function Pr() {
|
|
83
|
+
return F || (F = 1, (function(e) {
|
|
96
84
|
(function() {
|
|
97
|
-
var
|
|
85
|
+
var u = {}.hasOwnProperty;
|
|
98
86
|
function n() {
|
|
99
87
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
100
88
|
var i = arguments[t];
|
|
101
|
-
i && (r =
|
|
89
|
+
i && (r = a(r, p.call(this, i)));
|
|
102
90
|
}
|
|
103
91
|
return r;
|
|
104
92
|
}
|
|
@@ -113,18 +101,18 @@ function zr() {
|
|
|
113
101
|
return r.toString();
|
|
114
102
|
var t = "";
|
|
115
103
|
for (var i in r)
|
|
116
|
-
|
|
104
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
117
105
|
return t;
|
|
118
106
|
}
|
|
119
|
-
function
|
|
107
|
+
function a(r, t) {
|
|
120
108
|
return t ? r ? r + " " + t : r + t : r;
|
|
121
109
|
}
|
|
122
110
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
123
111
|
})();
|
|
124
|
-
})(
|
|
112
|
+
})(W)), W.exports;
|
|
125
113
|
}
|
|
126
|
-
var
|
|
127
|
-
const
|
|
114
|
+
var zr = Pr();
|
|
115
|
+
const Er = /* @__PURE__ */ Br(zr), Vr = {
|
|
128
116
|
"purpur-button": "_purpur-button_10jh0_1",
|
|
129
117
|
"purpur-button--xs": "_purpur-button--xs_10jh0_22",
|
|
130
118
|
"purpur-button--icon-only": "_purpur-button--icon-only_10jh0_25",
|
|
@@ -147,39 +135,39 @@ const Vr = /* @__PURE__ */ Pr(Er), Lr = {
|
|
|
147
135
|
"purpur-button--text-negative": "_purpur-button--text-negative_10jh0_185",
|
|
148
136
|
"purpur-button--text": "_purpur-button--text_10jh0_185",
|
|
149
137
|
"purpur-button__spinner": "_purpur-button__spinner_10jh0_235"
|
|
150
|
-
},
|
|
138
|
+
}, T = Er.bind(Vr), m = "purpur-button", _r = sr(
|
|
151
139
|
({
|
|
152
140
|
children: e,
|
|
153
|
-
className:
|
|
141
|
+
className: u,
|
|
154
142
|
disabled: n = !1,
|
|
155
143
|
fullWidth: p = !1,
|
|
156
|
-
iconOnly:
|
|
144
|
+
iconOnly: a,
|
|
157
145
|
loading: r = !1,
|
|
158
146
|
negative: t = !1,
|
|
159
147
|
onClick: i,
|
|
160
|
-
size:
|
|
148
|
+
size: d = "md",
|
|
161
149
|
variant: _,
|
|
162
150
|
type: x = "button",
|
|
163
|
-
...
|
|
151
|
+
...h
|
|
164
152
|
}, N) => {
|
|
165
|
-
if (
|
|
153
|
+
if (a && _ === "destructive")
|
|
166
154
|
return null;
|
|
167
|
-
const O =
|
|
155
|
+
const O = T(
|
|
168
156
|
[
|
|
169
157
|
m,
|
|
170
158
|
`${m}--${t ? `${_}-negative` : _}`,
|
|
171
|
-
`${m}--${
|
|
159
|
+
`${m}--${d}`
|
|
172
160
|
],
|
|
173
161
|
{
|
|
174
|
-
[`${m}--icon-only`]:
|
|
162
|
+
[`${m}--icon-only`]: a,
|
|
175
163
|
[`${m}--negative`]: t,
|
|
176
164
|
[`${m}--full-width`]: p,
|
|
177
165
|
[`${m}--disabled`]: n || r
|
|
178
166
|
},
|
|
179
|
-
|
|
167
|
+
u
|
|
180
168
|
), o = (j) => {
|
|
181
169
|
n || r ? j.preventDefault() : i && i(j);
|
|
182
|
-
}, y = !!
|
|
170
|
+
}, y = !!h["aria-disabled"] || n || r;
|
|
183
171
|
return /* @__PURE__ */ b(
|
|
184
172
|
"button",
|
|
185
173
|
{
|
|
@@ -188,15 +176,15 @@ const Vr = /* @__PURE__ */ Pr(Er), Lr = {
|
|
|
188
176
|
ref: N,
|
|
189
177
|
"aria-disabled": y,
|
|
190
178
|
onClick: o,
|
|
191
|
-
...
|
|
179
|
+
...h,
|
|
192
180
|
children: [
|
|
193
181
|
r && /* @__PURE__ */ l(
|
|
194
|
-
|
|
182
|
+
cr,
|
|
195
183
|
{
|
|
196
|
-
size:
|
|
184
|
+
size: d === Nr.LG ? "xs" : "xxs",
|
|
197
185
|
negative: t,
|
|
198
186
|
disabled: y,
|
|
199
|
-
className:
|
|
187
|
+
className: T(`${m}__spinner`)
|
|
200
188
|
}
|
|
201
189
|
),
|
|
202
190
|
" ",
|
|
@@ -206,25 +194,19 @@ const Vr = /* @__PURE__ */ Pr(Er), Lr = {
|
|
|
206
194
|
);
|
|
207
195
|
}
|
|
208
196
|
);
|
|
209
|
-
|
|
210
|
-
function
|
|
197
|
+
_r.displayName = "Button";
|
|
198
|
+
function Lr(e) {
|
|
211
199
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
212
200
|
}
|
|
213
|
-
var
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
Licensed under the MIT License (MIT), see
|
|
217
|
-
http://jedwatson.github.io/classnames
|
|
218
|
-
*/
|
|
219
|
-
var U;
|
|
220
|
-
function Zr() {
|
|
221
|
-
return U || (U = 1, (function(e) {
|
|
201
|
+
var G = { exports: {} }, H;
|
|
202
|
+
function Dr() {
|
|
203
|
+
return H || (H = 1, (function(e) {
|
|
222
204
|
(function() {
|
|
223
|
-
var
|
|
205
|
+
var u = {}.hasOwnProperty;
|
|
224
206
|
function n() {
|
|
225
207
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
226
208
|
var i = arguments[t];
|
|
227
|
-
i && (r =
|
|
209
|
+
i && (r = a(r, p.call(this, i)));
|
|
228
210
|
}
|
|
229
211
|
return r;
|
|
230
212
|
}
|
|
@@ -239,18 +221,18 @@ function Zr() {
|
|
|
239
221
|
return r.toString();
|
|
240
222
|
var t = "";
|
|
241
223
|
for (var i in r)
|
|
242
|
-
|
|
224
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
243
225
|
return t;
|
|
244
226
|
}
|
|
245
|
-
function
|
|
227
|
+
function a(r, t) {
|
|
246
228
|
return t ? r ? r + " " + t : r + t : r;
|
|
247
229
|
}
|
|
248
230
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
249
231
|
})();
|
|
250
|
-
})(
|
|
232
|
+
})(G)), G.exports;
|
|
251
233
|
}
|
|
252
|
-
var
|
|
253
|
-
const
|
|
234
|
+
var Zr = Dr();
|
|
235
|
+
const Wr = /* @__PURE__ */ Lr(Zr), Fr = {
|
|
254
236
|
"purpur-icon": "_purpur-icon_8u1lq_1",
|
|
255
237
|
"purpur-icon--xxs": "_purpur-icon--xxs_8u1lq_4",
|
|
256
238
|
"purpur-icon--xs": "_purpur-icon--xs_8u1lq_8",
|
|
@@ -258,46 +240,40 @@ const Fr = /* @__PURE__ */ Dr(Wr), Tr = {
|
|
|
258
240
|
"purpur-icon--md": "_purpur-icon--md_8u1lq_16",
|
|
259
241
|
"purpur-icon--lg": "_purpur-icon--lg_8u1lq_20",
|
|
260
242
|
"purpur-icon--xl": "_purpur-icon--xl_8u1lq_24"
|
|
261
|
-
},
|
|
243
|
+
}, Tr = Wr.bind(Fr), U = "purpur-icon", Gr = "md", Hr = (e) => e.filter((u) => Object.keys(u).length >= 1).map((u) => `${u.name}="${u.value}"`).join(" "), Ur = ({ content: e = "", title: u } = {}) => {
|
|
262
244
|
const n = [
|
|
263
245
|
{ name: "xmlns", value: "http://www.w3.org/2000/svg" },
|
|
264
246
|
{ name: "fill", value: "currentColor" },
|
|
265
247
|
{ name: "viewBox", value: "0 0 24 24" },
|
|
266
|
-
|
|
267
|
-
], p =
|
|
268
|
-
return `<svg ${
|
|
269
|
-
},
|
|
270
|
-
const r =
|
|
271
|
-
content:
|
|
272
|
-
title:
|
|
273
|
-
}), t =
|
|
274
|
-
return /* @__PURE__ */ l("span", { className: t, dangerouslySetInnerHTML: { __html: r }, ...
|
|
248
|
+
u ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
|
|
249
|
+
], p = u ? `<title>${u}</title>` : "";
|
|
250
|
+
return `<svg ${Hr(n)}>${p}${e}</svg>`;
|
|
251
|
+
}, Yr = (e) => e.replace(/<(\/?)svg([^>]*)>/g, "").trim(), dr = ({ svg: e, allyTitle: u, className: n, size: p = Gr, ...a }) => {
|
|
252
|
+
const r = Ur({
|
|
253
|
+
content: Yr(e.svg),
|
|
254
|
+
title: u
|
|
255
|
+
}), t = Tr(U, `${U}--${p}`, n);
|
|
256
|
+
return /* @__PURE__ */ l("span", { className: t, dangerouslySetInnerHTML: { __html: r }, ...a });
|
|
275
257
|
};
|
|
276
|
-
|
|
277
|
-
const
|
|
258
|
+
dr.displayName = "Icon";
|
|
259
|
+
const Jr = {
|
|
278
260
|
name: "error-filled",
|
|
279
261
|
svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 25 24" fill="currentColor"><path fill-rule="evenodd" d="M14.268 3.5c-.77-1.333-2.694-1.333-3.464 0l-8.66 15c-.77 1.333.192 3 1.732 3h17.32c1.54 0 2.502-1.667 1.733-3l-8.66-15Zm-.694 5.067-.247 6.876h-1.566l-.247-6.876a1.03 1.03 0 1 1 2.06 0Zm.212 8.917c0 .649-.585 1.234-1.25 1.234-.648 0-1.25-.585-1.25-1.234 0-.633.602-1.234 1.25-1.234.665 0 1.25.601 1.25 1.234Z" clip-rule="evenodd"/></svg>',
|
|
280
262
|
keywords: ["error-filled"],
|
|
281
263
|
category: "status"
|
|
282
264
|
};
|
|
283
|
-
function
|
|
265
|
+
function Kr(e) {
|
|
284
266
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
285
267
|
}
|
|
286
|
-
var
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
Licensed under the MIT License (MIT), see
|
|
290
|
-
http://jedwatson.github.io/classnames
|
|
291
|
-
*/
|
|
292
|
-
var K;
|
|
293
|
-
function Xr() {
|
|
294
|
-
return K || (K = 1, (function(e) {
|
|
268
|
+
var Y = { exports: {} }, J;
|
|
269
|
+
function Qr() {
|
|
270
|
+
return J || (J = 1, (function(e) {
|
|
295
271
|
(function() {
|
|
296
|
-
var
|
|
272
|
+
var u = {}.hasOwnProperty;
|
|
297
273
|
function n() {
|
|
298
274
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
299
275
|
var i = arguments[t];
|
|
300
|
-
i && (r =
|
|
276
|
+
i && (r = a(r, p.call(this, i)));
|
|
301
277
|
}
|
|
302
278
|
return r;
|
|
303
279
|
}
|
|
@@ -312,60 +288,54 @@ function Xr() {
|
|
|
312
288
|
return r.toString();
|
|
313
289
|
var t = "";
|
|
314
290
|
for (var i in r)
|
|
315
|
-
|
|
291
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
316
292
|
return t;
|
|
317
293
|
}
|
|
318
|
-
function
|
|
294
|
+
function a(r, t) {
|
|
319
295
|
return t ? r ? r + " " + t : r + t : r;
|
|
320
296
|
}
|
|
321
297
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
322
298
|
})();
|
|
323
|
-
})(
|
|
299
|
+
})(Y)), Y.exports;
|
|
324
300
|
}
|
|
325
|
-
var
|
|
326
|
-
const
|
|
301
|
+
var Xr = Qr();
|
|
302
|
+
const re = /* @__PURE__ */ Kr(Xr), ee = {
|
|
327
303
|
"purpur-field-error-text": "_purpur-field-error-text_u1cy2_1",
|
|
328
304
|
"purpur-field-error-text--negative": "_purpur-field-error-text--negative_u1cy2_11",
|
|
329
305
|
"purpur-field-error-text__icon": "_purpur-field-error-text__icon_u1cy2_14"
|
|
330
|
-
},
|
|
306
|
+
}, K = re.bind(ee), q = "purpur-field-error-text", te = ({
|
|
331
307
|
children: e,
|
|
332
|
-
className:
|
|
308
|
+
className: u,
|
|
333
309
|
negative: n = !1,
|
|
334
310
|
["aria-relevant"]: p = "additions text",
|
|
335
|
-
...
|
|
311
|
+
...a
|
|
336
312
|
}) => /* @__PURE__ */ b(
|
|
337
313
|
"div",
|
|
338
314
|
{
|
|
339
|
-
className:
|
|
315
|
+
className: K(u, q, {
|
|
340
316
|
[`${q}--negative`]: n
|
|
341
317
|
}),
|
|
342
318
|
"aria-live": "assertive",
|
|
343
319
|
"aria-relevant": p,
|
|
344
|
-
...
|
|
320
|
+
...a,
|
|
345
321
|
children: [
|
|
346
|
-
/* @__PURE__ */ l(
|
|
322
|
+
/* @__PURE__ */ l(dr, { svg: Jr, size: "xs", className: K(`${q}__icon`) }),
|
|
347
323
|
e
|
|
348
324
|
]
|
|
349
325
|
}
|
|
350
326
|
);
|
|
351
|
-
function
|
|
327
|
+
function ne(e) {
|
|
352
328
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
353
329
|
}
|
|
354
|
-
var
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
Licensed under the MIT License (MIT), see
|
|
358
|
-
http://jedwatson.github.io/classnames
|
|
359
|
-
*/
|
|
360
|
-
var rr;
|
|
361
|
-
function ue() {
|
|
362
|
-
return rr || (rr = 1, (function(e) {
|
|
330
|
+
var Q = { exports: {} }, X;
|
|
331
|
+
function ie() {
|
|
332
|
+
return X || (X = 1, (function(e) {
|
|
363
333
|
(function() {
|
|
364
|
-
var
|
|
334
|
+
var u = {}.hasOwnProperty;
|
|
365
335
|
function n() {
|
|
366
336
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
367
337
|
var i = arguments[t];
|
|
368
|
-
i && (r =
|
|
338
|
+
i && (r = a(r, p.call(this, i)));
|
|
369
339
|
}
|
|
370
340
|
return r;
|
|
371
341
|
}
|
|
@@ -380,53 +350,47 @@ function ue() {
|
|
|
380
350
|
return r.toString();
|
|
381
351
|
var t = "";
|
|
382
352
|
for (var i in r)
|
|
383
|
-
|
|
353
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
384
354
|
return t;
|
|
385
355
|
}
|
|
386
|
-
function
|
|
356
|
+
function a(r, t) {
|
|
387
357
|
return t ? r ? r + " " + t : r + t : r;
|
|
388
358
|
}
|
|
389
359
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
390
360
|
})();
|
|
391
|
-
})(
|
|
361
|
+
})(Q)), Q.exports;
|
|
392
362
|
}
|
|
393
|
-
var
|
|
394
|
-
const
|
|
363
|
+
var ue = ie();
|
|
364
|
+
const ae = /* @__PURE__ */ ne(ue), pe = {
|
|
395
365
|
"purpur-field-helper-text": "_purpur-field-helper-text_11nsh_1",
|
|
396
366
|
"purpur-field-helper-text--disabled": "_purpur-field-helper-text--disabled_11nsh_9",
|
|
397
367
|
"purpur-field-helper-text--negative": "_purpur-field-helper-text--negative_11nsh_12"
|
|
398
|
-
},
|
|
368
|
+
}, le = ae.bind(pe), R = "purpur-field-helper-text", oe = ({
|
|
399
369
|
children: e,
|
|
400
|
-
className:
|
|
370
|
+
className: u,
|
|
401
371
|
disabled: n,
|
|
402
372
|
id: p,
|
|
403
|
-
negative:
|
|
373
|
+
negative: a,
|
|
404
374
|
...r
|
|
405
375
|
}) => {
|
|
406
|
-
const t =
|
|
376
|
+
const t = le(u, R, {
|
|
407
377
|
[`${R}--disabled`]: n,
|
|
408
|
-
[`${R}--negative`]:
|
|
378
|
+
[`${R}--negative`]: a
|
|
409
379
|
});
|
|
410
380
|
return /* @__PURE__ */ l("span", { id: p, className: t, ...r, children: e });
|
|
411
381
|
};
|
|
412
|
-
function
|
|
382
|
+
function se(e) {
|
|
413
383
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
414
384
|
}
|
|
415
|
-
var
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
Licensed under the MIT License (MIT), see
|
|
419
|
-
http://jedwatson.github.io/classnames
|
|
420
|
-
*/
|
|
421
|
-
var tr;
|
|
422
|
-
function _e() {
|
|
423
|
-
return tr || (tr = 1, (function(e) {
|
|
385
|
+
var rr = { exports: {} }, er;
|
|
386
|
+
function ce() {
|
|
387
|
+
return er || (er = 1, (function(e) {
|
|
424
388
|
(function() {
|
|
425
|
-
var
|
|
389
|
+
var u = {}.hasOwnProperty;
|
|
426
390
|
function n() {
|
|
427
391
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
428
392
|
var i = arguments[t];
|
|
429
|
-
i && (r =
|
|
393
|
+
i && (r = a(r, p.call(this, i)));
|
|
430
394
|
}
|
|
431
395
|
return r;
|
|
432
396
|
}
|
|
@@ -441,18 +405,18 @@ function _e() {
|
|
|
441
405
|
return r.toString();
|
|
442
406
|
var t = "";
|
|
443
407
|
for (var i in r)
|
|
444
|
-
|
|
408
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
445
409
|
return t;
|
|
446
410
|
}
|
|
447
|
-
function
|
|
411
|
+
function a(r, t) {
|
|
448
412
|
return t ? r ? r + " " + t : r + t : r;
|
|
449
413
|
}
|
|
450
414
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
451
415
|
})();
|
|
452
|
-
})(
|
|
416
|
+
})(rr)), rr.exports;
|
|
453
417
|
}
|
|
454
|
-
var
|
|
455
|
-
const
|
|
418
|
+
var _e = ce();
|
|
419
|
+
const de = /* @__PURE__ */ se(_e), fe = {
|
|
456
420
|
"purpur-icon": "_purpur-icon_8u1lq_1",
|
|
457
421
|
"purpur-icon--xxs": "_purpur-icon--xxs_8u1lq_4",
|
|
458
422
|
"purpur-icon--xs": "_purpur-icon--xs_8u1lq_8",
|
|
@@ -460,111 +424,110 @@ const fe = /* @__PURE__ */ ce(de), ve = {
|
|
|
460
424
|
"purpur-icon--md": "_purpur-icon--md_8u1lq_16",
|
|
461
425
|
"purpur-icon--lg": "_purpur-icon--lg_8u1lq_20",
|
|
462
426
|
"purpur-icon--xl": "_purpur-icon--xl_8u1lq_24"
|
|
463
|
-
},
|
|
427
|
+
}, ve = de.bind(fe), tr = "purpur-icon", ge = "md", he = (e) => e.filter((u) => Object.keys(u).length >= 1).map((u) => `${u.name}="${u.value}"`).join(" "), me = ({ content: e = "", title: u } = {}) => {
|
|
464
428
|
const n = [
|
|
465
429
|
{ name: "xmlns", value: "http://www.w3.org/2000/svg" },
|
|
466
430
|
{ name: "fill", value: "currentColor" },
|
|
467
431
|
{ name: "viewBox", value: "0 0 24 24" },
|
|
468
|
-
|
|
469
|
-
], p =
|
|
470
|
-
return `<svg ${
|
|
471
|
-
},
|
|
472
|
-
const r =
|
|
473
|
-
content:
|
|
474
|
-
title:
|
|
475
|
-
}), t =
|
|
476
|
-
return /* @__PURE__ */ l("span", { className: t, dangerouslySetInnerHTML: { __html: r }, ...
|
|
432
|
+
u ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
|
|
433
|
+
], p = u ? `<title>${u}</title>` : "";
|
|
434
|
+
return `<svg ${he(n)}>${p}${e}</svg>`;
|
|
435
|
+
}, ye = (e) => e.replace(/<(\/?)svg([^>]*)>/g, "").trim(), P = ({ svg: e, allyTitle: u, className: n, size: p = ge, ...a }) => {
|
|
436
|
+
const r = me({
|
|
437
|
+
content: ye(e.svg),
|
|
438
|
+
title: u
|
|
439
|
+
}), t = ve(tr, `${tr}--${p}`, n);
|
|
440
|
+
return /* @__PURE__ */ l("span", { className: t, dangerouslySetInnerHTML: { __html: r }, ...a });
|
|
477
441
|
};
|
|
478
442
|
P.displayName = "Icon";
|
|
479
|
-
const
|
|
443
|
+
const be = {
|
|
480
444
|
name: "check-circle-filled",
|
|
481
445
|
svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Zm4.712-12.491a.875.875 0 1 0-1.424-1.018l-4.4 6.16-2.27-2.27a.875.875 0 0 0-1.237 1.238l3 3a.875.875 0 0 0 1.331-.11l5-7Z" clip-rule="evenodd"/></svg>',
|
|
482
446
|
keywords: ["check-circle-filled"],
|
|
483
447
|
category: "status"
|
|
484
|
-
},
|
|
485
|
-
|
|
486
|
-
const
|
|
448
|
+
}, fr = (e) => /* @__PURE__ */ l(P, { ...e, svg: be });
|
|
449
|
+
fr.displayName = "IconCheckCircleFilled";
|
|
450
|
+
const xe = {
|
|
487
451
|
name: "close",
|
|
488
452
|
svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M4.864 4.864a.9.9 0 0 1 1.273 0L12 10.727l5.864-5.863a.9.9 0 0 1 1.272 1.272L13.273 12l5.863 5.864a.9.9 0 1 1-1.272 1.272L12 13.273l-5.863 5.863a.9.9 0 0 1-1.273-1.272L10.727 12 4.864 6.136a.9.9 0 0 1 0-1.272Z" clip-rule="evenodd"/></svg>',
|
|
489
453
|
keywords: ["close"],
|
|
490
454
|
category: "utility"
|
|
491
|
-
},
|
|
492
|
-
|
|
493
|
-
function
|
|
455
|
+
}, vr = (e) => /* @__PURE__ */ l(P, { ...e, svg: xe });
|
|
456
|
+
vr.displayName = "IconClose";
|
|
457
|
+
function nr(e, u) {
|
|
494
458
|
if (typeof e == "function")
|
|
495
|
-
return e(
|
|
496
|
-
e != null && (e.current =
|
|
459
|
+
return e(u);
|
|
460
|
+
e != null && (e.current = u);
|
|
497
461
|
}
|
|
498
|
-
function
|
|
499
|
-
return (
|
|
462
|
+
function $e(...e) {
|
|
463
|
+
return (u) => {
|
|
500
464
|
let n = !1;
|
|
501
|
-
const p = e.map((
|
|
502
|
-
const r =
|
|
465
|
+
const p = e.map((a) => {
|
|
466
|
+
const r = nr(a, u);
|
|
503
467
|
return !n && typeof r == "function" && (n = !0), r;
|
|
504
468
|
});
|
|
505
469
|
if (n)
|
|
506
470
|
return () => {
|
|
507
|
-
for (let
|
|
508
|
-
const r = p[
|
|
509
|
-
typeof r == "function" ? r() :
|
|
471
|
+
for (let a = 0; a < p.length; a++) {
|
|
472
|
+
const r = p[a];
|
|
473
|
+
typeof r == "function" ? r() : nr(e[a], null);
|
|
510
474
|
}
|
|
511
475
|
};
|
|
512
476
|
};
|
|
513
477
|
}
|
|
514
|
-
var
|
|
515
|
-
function
|
|
478
|
+
var we = Symbol.for("react.lazy"), S = s[" use ".trim().toString()];
|
|
479
|
+
function je(e) {
|
|
516
480
|
return typeof e == "object" && e !== null && "then" in e;
|
|
517
481
|
}
|
|
518
|
-
function
|
|
519
|
-
return e != null && typeof e == "object" && "$$typeof" in e && e.$$typeof ===
|
|
482
|
+
function gr(e) {
|
|
483
|
+
return e != null && typeof e == "object" && "$$typeof" in e && e.$$typeof === we && "_payload" in e && je(e._payload);
|
|
520
484
|
}
|
|
521
485
|
// @__NO_SIDE_EFFECTS__
|
|
522
|
-
function
|
|
523
|
-
const
|
|
486
|
+
function Se(e) {
|
|
487
|
+
const u = /* @__PURE__ */ Ne(e), n = s.forwardRef((p, a) => {
|
|
524
488
|
let { children: r, ...t } = p;
|
|
525
|
-
|
|
526
|
-
const i = s.Children.toArray(r),
|
|
527
|
-
if (
|
|
528
|
-
const _ =
|
|
529
|
-
return /* @__PURE__ */ l(
|
|
489
|
+
gr(r) && typeof S == "function" && (r = S(r._payload));
|
|
490
|
+
const i = s.Children.toArray(r), d = i.find(Ce);
|
|
491
|
+
if (d) {
|
|
492
|
+
const _ = d.props.children, x = i.map((h) => h === d ? s.Children.count(_) > 1 ? s.Children.only(null) : s.isValidElement(_) ? _.props.children : null : h);
|
|
493
|
+
return /* @__PURE__ */ l(u, { ...t, ref: a, children: s.isValidElement(_) ? s.cloneElement(_, void 0, x) : null });
|
|
530
494
|
}
|
|
531
|
-
return /* @__PURE__ */ l(
|
|
495
|
+
return /* @__PURE__ */ l(u, { ...t, ref: a, children: r });
|
|
532
496
|
});
|
|
533
497
|
return n.displayName = `${e}.Slot`, n;
|
|
534
498
|
}
|
|
535
499
|
// @__NO_SIDE_EFFECTS__
|
|
536
|
-
function
|
|
537
|
-
const
|
|
538
|
-
let { children:
|
|
539
|
-
if (
|
|
540
|
-
const t =
|
|
541
|
-
return
|
|
500
|
+
function Ne(e) {
|
|
501
|
+
const u = s.forwardRef((n, p) => {
|
|
502
|
+
let { children: a, ...r } = n;
|
|
503
|
+
if (gr(a) && typeof S == "function" && (a = S(a._payload)), s.isValidElement(a)) {
|
|
504
|
+
const t = Me(a), i = ke(r, a.props);
|
|
505
|
+
return a.type !== s.Fragment && (i.ref = p ? $e(p, t) : t), s.cloneElement(a, i);
|
|
542
506
|
}
|
|
543
|
-
return s.Children.count(
|
|
507
|
+
return s.Children.count(a) > 1 ? s.Children.only(null) : null;
|
|
544
508
|
});
|
|
545
|
-
return
|
|
509
|
+
return u.displayName = `${e}.SlotClone`, u;
|
|
546
510
|
}
|
|
547
|
-
var
|
|
548
|
-
function
|
|
549
|
-
return s.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId ===
|
|
511
|
+
var Oe = Symbol("radix.slottable");
|
|
512
|
+
function Ce(e) {
|
|
513
|
+
return s.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === Oe;
|
|
550
514
|
}
|
|
551
|
-
function
|
|
552
|
-
const n = { ...
|
|
553
|
-
for (const p in
|
|
554
|
-
const
|
|
555
|
-
/^on[A-Z]/.test(p) ?
|
|
515
|
+
function ke(e, u) {
|
|
516
|
+
const n = { ...u };
|
|
517
|
+
for (const p in u) {
|
|
518
|
+
const a = e[p], r = u[p];
|
|
519
|
+
/^on[A-Z]/.test(p) ? a && r ? n[p] = (...t) => {
|
|
556
520
|
const i = r(...t);
|
|
557
|
-
return
|
|
558
|
-
} :
|
|
521
|
+
return a(...t), i;
|
|
522
|
+
} : a && (n[p] = a) : p === "style" ? n[p] = { ...a, ...r } : p === "className" && (n[p] = [a, r].filter(Boolean).join(" "));
|
|
559
523
|
}
|
|
560
524
|
return { ...e, ...n };
|
|
561
525
|
}
|
|
562
|
-
function
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
return u ? e.ref : (p = (n = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : n.get, u = p && "isReactWarning" in p && p.isReactWarning, u ? e.props.ref : e.props.ref || e.ref);
|
|
526
|
+
function Me(e) {
|
|
527
|
+
let u = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, n = u && "isReactWarning" in u && u.isReactWarning;
|
|
528
|
+
return n ? e.ref : (u = Object.getOwnPropertyDescriptor(e, "ref")?.get, n = u && "isReactWarning" in u && u.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
566
529
|
}
|
|
567
|
-
var
|
|
530
|
+
var Ae = [
|
|
568
531
|
"a",
|
|
569
532
|
"button",
|
|
570
533
|
"div",
|
|
@@ -582,43 +545,36 @@ var qe = [
|
|
|
582
545
|
"span",
|
|
583
546
|
"svg",
|
|
584
547
|
"ul"
|
|
585
|
-
],
|
|
586
|
-
const n = /* @__PURE__ */
|
|
587
|
-
const { asChild: t, ...i } =
|
|
588
|
-
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ l(
|
|
548
|
+
], qe = Ae.reduce((e, u) => {
|
|
549
|
+
const n = /* @__PURE__ */ Se(`Primitive.${u}`), p = s.forwardRef((a, r) => {
|
|
550
|
+
const { asChild: t, ...i } = a, d = t ? n : u;
|
|
551
|
+
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ l(d, { ...i, ref: r });
|
|
589
552
|
});
|
|
590
|
-
return p.displayName = `Primitive.${
|
|
591
|
-
}, {}),
|
|
592
|
-
|
|
553
|
+
return p.displayName = `Primitive.${u}`, { ...e, [u]: p };
|
|
554
|
+
}, {}), Re = "Label", hr = s.forwardRef((e, u) => /* @__PURE__ */ l(
|
|
555
|
+
qe.label,
|
|
593
556
|
{
|
|
594
557
|
...e,
|
|
595
|
-
ref:
|
|
558
|
+
ref: u,
|
|
596
559
|
onMouseDown: (n) => {
|
|
597
|
-
|
|
598
|
-
n.target.closest("button, input, select, textarea") || ((p = e.onMouseDown) == null || p.call(e, n), !n.defaultPrevented && n.detail > 1 && n.preventDefault());
|
|
560
|
+
n.target.closest("button, input, select, textarea") || (e.onMouseDown?.(n), !n.defaultPrevented && n.detail > 1 && n.preventDefault());
|
|
599
561
|
}
|
|
600
562
|
}
|
|
601
563
|
));
|
|
602
|
-
|
|
603
|
-
var
|
|
604
|
-
function
|
|
564
|
+
hr.displayName = Re;
|
|
565
|
+
var Ie = hr;
|
|
566
|
+
function Be(e) {
|
|
605
567
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
606
568
|
}
|
|
607
|
-
var
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
Licensed under the MIT License (MIT), see
|
|
611
|
-
http://jedwatson.github.io/classnames
|
|
612
|
-
*/
|
|
613
|
-
var ar;
|
|
614
|
-
function ze() {
|
|
615
|
-
return ar || (ar = 1, (function(e) {
|
|
569
|
+
var ir = { exports: {} }, ur;
|
|
570
|
+
function Pe() {
|
|
571
|
+
return ur || (ur = 1, (function(e) {
|
|
616
572
|
(function() {
|
|
617
|
-
var
|
|
573
|
+
var u = {}.hasOwnProperty;
|
|
618
574
|
function n() {
|
|
619
575
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
620
576
|
var i = arguments[t];
|
|
621
|
-
i && (r =
|
|
577
|
+
i && (r = a(r, p.call(this, i)));
|
|
622
578
|
}
|
|
623
579
|
return r;
|
|
624
580
|
}
|
|
@@ -633,52 +589,46 @@ function ze() {
|
|
|
633
589
|
return r.toString();
|
|
634
590
|
var t = "";
|
|
635
591
|
for (var i in r)
|
|
636
|
-
|
|
592
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
637
593
|
return t;
|
|
638
594
|
}
|
|
639
|
-
function
|
|
595
|
+
function a(r, t) {
|
|
640
596
|
return t ? r ? r + " " + t : r + t : r;
|
|
641
597
|
}
|
|
642
598
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
643
599
|
})();
|
|
644
|
-
})(
|
|
600
|
+
})(ir)), ir.exports;
|
|
645
601
|
}
|
|
646
|
-
var
|
|
647
|
-
const
|
|
602
|
+
var ze = Pe();
|
|
603
|
+
const Ee = /* @__PURE__ */ Be(ze), Ve = {
|
|
648
604
|
"purpur-label": "_purpur-label_1x80u_1",
|
|
649
605
|
"purpur-label--negative": "_purpur-label--negative_1x80u_8",
|
|
650
606
|
"purpur-label--disabled": "_purpur-label--disabled_1x80u_11"
|
|
651
|
-
},
|
|
607
|
+
}, Le = Ee.bind(Ve), I = "purpur-label", De = ({
|
|
652
608
|
children: e,
|
|
653
|
-
className:
|
|
609
|
+
className: u,
|
|
654
610
|
disabled: n,
|
|
655
611
|
negative: p = !1,
|
|
656
|
-
...
|
|
612
|
+
...a
|
|
657
613
|
}) => {
|
|
658
|
-
const r =
|
|
614
|
+
const r = Le(u, I, {
|
|
659
615
|
[`${I}--disabled`]: n,
|
|
660
616
|
[`${I}--negative`]: p
|
|
661
617
|
});
|
|
662
|
-
return /* @__PURE__ */ l(
|
|
618
|
+
return /* @__PURE__ */ l(Ie, { className: r, ...a, children: e });
|
|
663
619
|
};
|
|
664
|
-
function
|
|
620
|
+
function Ze(e) {
|
|
665
621
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
666
622
|
}
|
|
667
|
-
var
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
Licensed under the MIT License (MIT), see
|
|
671
|
-
http://jedwatson.github.io/classnames
|
|
672
|
-
*/
|
|
673
|
-
var lr;
|
|
674
|
-
function Fe() {
|
|
675
|
-
return lr || (lr = 1, (function(e) {
|
|
623
|
+
var ar = { exports: {} }, pr;
|
|
624
|
+
function We() {
|
|
625
|
+
return pr || (pr = 1, (function(e) {
|
|
676
626
|
(function() {
|
|
677
|
-
var
|
|
627
|
+
var u = {}.hasOwnProperty;
|
|
678
628
|
function n() {
|
|
679
629
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
680
630
|
var i = arguments[t];
|
|
681
|
-
i && (r =
|
|
631
|
+
i && (r = a(r, p.call(this, i)));
|
|
682
632
|
}
|
|
683
633
|
return r;
|
|
684
634
|
}
|
|
@@ -693,68 +643,63 @@ function Fe() {
|
|
|
693
643
|
return r.toString();
|
|
694
644
|
var t = "";
|
|
695
645
|
for (var i in r)
|
|
696
|
-
|
|
646
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
697
647
|
return t;
|
|
698
648
|
}
|
|
699
|
-
function
|
|
649
|
+
function a(r, t) {
|
|
700
650
|
return t ? r ? r + " " + t : r + t : r;
|
|
701
651
|
}
|
|
702
652
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
703
653
|
})();
|
|
704
|
-
})(
|
|
654
|
+
})(ar)), ar.exports;
|
|
705
655
|
}
|
|
706
|
-
var
|
|
707
|
-
const
|
|
656
|
+
var Fe = We();
|
|
657
|
+
const Te = /* @__PURE__ */ Ze(Fe), Ge = "_rotate_12t9p_1", He = "_dash_12t9p_1", Ue = {
|
|
708
658
|
"purpur-spinner": "_purpur-spinner_12t9p_2",
|
|
709
|
-
rotate:
|
|
659
|
+
rotate: Ge,
|
|
710
660
|
"purpur-spinner--xxs": "_purpur-spinner--xxs_12t9p_6",
|
|
711
661
|
"purpur-spinner--xs": "_purpur-spinner--xs_12t9p_10",
|
|
712
662
|
"purpur-spinner--sm": "_purpur-spinner--sm_12t9p_14",
|
|
713
663
|
"purpur-spinner--md": "_purpur-spinner--md_12t9p_18",
|
|
714
664
|
"purpur-spinner--lg": "_purpur-spinner--lg_12t9p_22",
|
|
715
665
|
"purpur-spinner__circle": "_purpur-spinner__circle_12t9p_26",
|
|
716
|
-
dash:
|
|
666
|
+
dash: He,
|
|
717
667
|
"purpur-spinner__circle--disabled": "_purpur-spinner__circle--disabled_12t9p_41",
|
|
718
668
|
"purpur-spinner__circle--negative": "_purpur-spinner__circle--negative_12t9p_44"
|
|
719
|
-
},
|
|
669
|
+
}, lr = Te.bind(Ue), w = "purpur-spinner", Ye = {
|
|
720
670
|
SM: "sm"
|
|
721
|
-
},
|
|
671
|
+
}, mr = ({
|
|
722
672
|
disabled: e = !1,
|
|
723
|
-
negative:
|
|
724
|
-
size: n =
|
|
673
|
+
negative: u = !1,
|
|
674
|
+
size: n = Ye.SM,
|
|
725
675
|
className: p,
|
|
726
|
-
...
|
|
727
|
-
}) => /* @__PURE__ */ l("div", { className:
|
|
676
|
+
...a
|
|
677
|
+
}) => /* @__PURE__ */ l("div", { className: lr(w, `${w}--${n}`, p), ...a, children: /* @__PURE__ */ l("svg", { viewBox: "0 0 50 50", children: /* @__PURE__ */ l(
|
|
728
678
|
"circle",
|
|
729
679
|
{
|
|
730
|
-
className:
|
|
680
|
+
className: lr(`${w}__circle`, {
|
|
731
681
|
[`${w}__circle--disabled`]: e,
|
|
732
|
-
[`${w}__circle--negative`]:
|
|
682
|
+
[`${w}__circle--negative`]: u
|
|
733
683
|
}),
|
|
734
684
|
cx: "25",
|
|
735
685
|
cy: "25",
|
|
736
686
|
r: "20"
|
|
737
687
|
}
|
|
738
688
|
) }) });
|
|
739
|
-
|
|
740
|
-
function
|
|
689
|
+
mr.displayName = "Spinner";
|
|
690
|
+
function Je(e) {
|
|
741
691
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
742
692
|
}
|
|
743
693
|
var B = { exports: {} };
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
http://jedwatson.github.io/classnames
|
|
748
|
-
*/
|
|
749
|
-
var sr;
|
|
750
|
-
function Qe() {
|
|
751
|
-
return sr || (sr = 1, (function(e) {
|
|
694
|
+
var or;
|
|
695
|
+
function Ke() {
|
|
696
|
+
return or || (or = 1, (function(e) {
|
|
752
697
|
(function() {
|
|
753
|
-
var
|
|
698
|
+
var u = {}.hasOwnProperty;
|
|
754
699
|
function n() {
|
|
755
700
|
for (var r = "", t = 0; t < arguments.length; t++) {
|
|
756
701
|
var i = arguments[t];
|
|
757
|
-
i && (r =
|
|
702
|
+
i && (r = a(r, p.call(this, i)));
|
|
758
703
|
}
|
|
759
704
|
return r;
|
|
760
705
|
}
|
|
@@ -769,18 +714,18 @@ function Qe() {
|
|
|
769
714
|
return r.toString();
|
|
770
715
|
var t = "";
|
|
771
716
|
for (var i in r)
|
|
772
|
-
|
|
717
|
+
u.call(r, i) && r[i] && (t = a(t, this && this[i] || i));
|
|
773
718
|
return t;
|
|
774
719
|
}
|
|
775
|
-
function
|
|
720
|
+
function a(r, t) {
|
|
776
721
|
return t ? r ? r + " " + t : r + t : r;
|
|
777
722
|
}
|
|
778
723
|
e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
|
|
779
724
|
})();
|
|
780
725
|
})(B)), B.exports;
|
|
781
726
|
}
|
|
782
|
-
var
|
|
783
|
-
const
|
|
727
|
+
var Qe = Ke();
|
|
728
|
+
const Xe = /* @__PURE__ */ Je(Qe), rt = {
|
|
784
729
|
"purpur-text-field": "_purpur-text-field_3gl1k_1",
|
|
785
730
|
"purpur-text-field__label": "_purpur-text-field__label_3gl1k_7",
|
|
786
731
|
"purpur-text-field__label-text": "_purpur-text-field__label-text_3gl1k_12",
|
|
@@ -797,103 +742,101 @@ const rt = /* @__PURE__ */ Ke(Xe), et = {
|
|
|
797
742
|
"purpur-text-field__input--error": "_purpur-text-field__input--error_3gl1k_94",
|
|
798
743
|
"purpur-text-field__adornment-container": "_purpur-text-field__adornment-container_3gl1k_106",
|
|
799
744
|
"purpur-text-field__valid-icon": "_purpur-text-field__valid-icon_3gl1k_111"
|
|
800
|
-
},
|
|
745
|
+
}, et = (e) => wr(e), g = Xe.bind(rt), c = "purpur-text-field", yr = sr(
|
|
801
746
|
({
|
|
802
747
|
["data-testid"]: e,
|
|
803
|
-
className:
|
|
748
|
+
className: u,
|
|
804
749
|
clearButtonAriaLabel: n,
|
|
805
750
|
beforeField: p,
|
|
806
|
-
afterField:
|
|
751
|
+
afterField: a,
|
|
807
752
|
endAdornment: r,
|
|
808
753
|
errorText: t,
|
|
809
754
|
helperText: i,
|
|
810
|
-
hideRequiredAsterisk:
|
|
755
|
+
hideRequiredAsterisk: d = !1,
|
|
811
756
|
label: _,
|
|
812
757
|
loading: x = !1,
|
|
813
|
-
onClear:
|
|
758
|
+
onClear: h,
|
|
814
759
|
startAdornment: N,
|
|
815
760
|
valid: O = !1,
|
|
816
761
|
...o
|
|
817
762
|
}, y) => {
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
v == null || v(), (d = V.current) == null || d.focus();
|
|
824
|
-
}, C = [
|
|
763
|
+
const j = jr(), C = o.id ?? j, f = (v) => e ? `${e}-${v}` : void 0, z = O && !t, k = i ? `${C}-helper-text` : void 0, M = [N].filter((v) => !!v), E = (typeof o.value == "number" ? o.value !== void 0 : o.value?.length) && !o.disabled && !o.readOnly && !x && h && n, V = et(null), br = (v) => {
|
|
764
|
+
V.current = v, typeof y == "function" ? y(v) : y && (y.current = v);
|
|
765
|
+
}, xr = () => {
|
|
766
|
+
h?.(), V.current?.focus();
|
|
767
|
+
}, A = [
|
|
825
768
|
x && /* @__PURE__ */ l(
|
|
826
|
-
|
|
769
|
+
mr,
|
|
827
770
|
{
|
|
828
771
|
disabled: o.disabled,
|
|
829
772
|
size: "xs",
|
|
830
|
-
"data-testid":
|
|
773
|
+
"data-testid": f("spinner")
|
|
831
774
|
},
|
|
832
775
|
"spinner"
|
|
833
776
|
),
|
|
834
777
|
E && /* @__PURE__ */ l(
|
|
835
|
-
|
|
778
|
+
_r,
|
|
836
779
|
{
|
|
837
780
|
variant: "tertiary-purple",
|
|
838
|
-
onClick:
|
|
781
|
+
onClick: xr,
|
|
839
782
|
iconOnly: !0,
|
|
840
783
|
"aria-label": n ?? "",
|
|
841
|
-
"data-testid":
|
|
784
|
+
"data-testid": f("clear-button"),
|
|
842
785
|
tabIndex: -1,
|
|
843
|
-
children: /* @__PURE__ */ l(
|
|
786
|
+
children: /* @__PURE__ */ l(vr, { size: "xs" })
|
|
844
787
|
},
|
|
845
788
|
"clear-button"
|
|
846
789
|
),
|
|
847
790
|
z && /* @__PURE__ */ l(
|
|
848
|
-
|
|
791
|
+
fr,
|
|
849
792
|
{
|
|
850
|
-
"data-testid":
|
|
851
|
-
className:
|
|
793
|
+
"data-testid": f("valid-icon"),
|
|
794
|
+
className: g(`${c}__valid-icon`)
|
|
852
795
|
},
|
|
853
796
|
"valid-icon"
|
|
854
797
|
)
|
|
855
|
-
].filter((
|
|
856
|
-
[`${c}__input-container--start-adornment`]:
|
|
857
|
-
[`${c}__input-container--end-adornment`]:
|
|
798
|
+
].filter((v) => !!v), $r = g(`${c}__input-container`, {
|
|
799
|
+
[`${c}__input-container--start-adornment`]: M.length,
|
|
800
|
+
[`${c}__input-container--end-adornment`]: A.length || r,
|
|
858
801
|
[`${c}__input-container--disabled`]: o.disabled,
|
|
859
802
|
[`${c}__input-container--has-clear-button`]: E,
|
|
860
803
|
[`${c}__input-container--readonly`]: o.readOnly && !o.disabled
|
|
861
804
|
});
|
|
862
|
-
return /* @__PURE__ */ b("div", { className:
|
|
805
|
+
return /* @__PURE__ */ b("div", { className: g(u, c), children: [
|
|
863
806
|
_ && /* @__PURE__ */ b(
|
|
864
|
-
|
|
807
|
+
De,
|
|
865
808
|
{
|
|
866
|
-
htmlFor:
|
|
867
|
-
className:
|
|
868
|
-
"data-testid":
|
|
809
|
+
htmlFor: C,
|
|
810
|
+
className: g(`${c}__label`),
|
|
811
|
+
"data-testid": f("label"),
|
|
869
812
|
disabled: o.disabled,
|
|
870
813
|
children: [
|
|
871
|
-
o.required && !
|
|
814
|
+
o.required && !d && /* @__PURE__ */ l("span", { "aria-hidden": !0, children: "*" }),
|
|
872
815
|
_
|
|
873
816
|
]
|
|
874
817
|
}
|
|
875
818
|
),
|
|
876
|
-
/* @__PURE__ */ b("div", { className:
|
|
819
|
+
/* @__PURE__ */ b("div", { className: g(`${c}__field-row`), children: [
|
|
877
820
|
!!p && p,
|
|
878
|
-
/* @__PURE__ */ b("div", { className:
|
|
879
|
-
!!
|
|
821
|
+
/* @__PURE__ */ b("div", { className: $r, children: [
|
|
822
|
+
!!M.length && /* @__PURE__ */ l(
|
|
880
823
|
"div",
|
|
881
824
|
{
|
|
882
|
-
"data-testid":
|
|
883
|
-
className:
|
|
884
|
-
children:
|
|
825
|
+
"data-testid": f("start-adornments"),
|
|
826
|
+
className: g(`${c}__adornment-container`),
|
|
827
|
+
children: M
|
|
885
828
|
}
|
|
886
829
|
),
|
|
887
830
|
/* @__PURE__ */ l(
|
|
888
831
|
"input",
|
|
889
832
|
{
|
|
890
833
|
...o,
|
|
891
|
-
id:
|
|
892
|
-
ref:
|
|
893
|
-
"data-testid":
|
|
894
|
-
"aria-describedby": o["aria-describedby"] ||
|
|
834
|
+
id: C,
|
|
835
|
+
ref: br,
|
|
836
|
+
"data-testid": f("input"),
|
|
837
|
+
"aria-describedby": o["aria-describedby"] || k,
|
|
895
838
|
"aria-invalid": o["aria-invalid"] || !!t,
|
|
896
|
-
className:
|
|
839
|
+
className: g([
|
|
897
840
|
`${c}__input`,
|
|
898
841
|
{
|
|
899
842
|
[`${c}__input--valid`]: z,
|
|
@@ -902,30 +845,30 @@ const rt = /* @__PURE__ */ Ke(Xe), et = {
|
|
|
902
845
|
])
|
|
903
846
|
}
|
|
904
847
|
),
|
|
905
|
-
/* @__PURE__ */ l("div", { className:
|
|
906
|
-
(!!
|
|
848
|
+
/* @__PURE__ */ l("div", { className: g(`${c}__frame`) }),
|
|
849
|
+
(!!A.length || r) && /* @__PURE__ */ b(
|
|
907
850
|
"div",
|
|
908
851
|
{
|
|
909
|
-
"data-testid":
|
|
910
|
-
className:
|
|
852
|
+
"data-testid": f("end-adornments"),
|
|
853
|
+
className: g(`${c}__adornment-container`),
|
|
911
854
|
children: [
|
|
912
|
-
|
|
855
|
+
A,
|
|
913
856
|
r
|
|
914
857
|
]
|
|
915
858
|
}
|
|
916
859
|
)
|
|
917
860
|
] }),
|
|
918
|
-
!!
|
|
861
|
+
!!a && a
|
|
919
862
|
] }),
|
|
920
|
-
|
|
921
|
-
t && /* @__PURE__ */ l(
|
|
863
|
+
k && /* @__PURE__ */ l(oe, { "data-testid": f("helper-text"), id: k, children: i }),
|
|
864
|
+
t && /* @__PURE__ */ l(te, { "data-testid": f("error-text"), children: t })
|
|
922
865
|
] });
|
|
923
866
|
}
|
|
924
867
|
);
|
|
925
|
-
|
|
926
|
-
const
|
|
868
|
+
yr.displayName = "TextField";
|
|
869
|
+
const at = (e) => Sr(e) && e.type.displayName === yr.displayName;
|
|
927
870
|
export {
|
|
928
|
-
|
|
929
|
-
|
|
871
|
+
yr as TextField,
|
|
872
|
+
at as isTextField
|
|
930
873
|
};
|
|
931
874
|
//# sourceMappingURL=text-field.es.js.map
|