@purpurds/modal 5.14.0 → 5.15.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 +10 -10
- package/dist/modal.cjs.js +23 -23
- package/dist/modal.cjs.js.map +1 -1
- package/dist/modal.es.js +583 -557
- package/dist/modal.es.js.map +1 -1
- package/package.json +9 -9
- package/src/modal-content.tsx +1 -1
package/dist/modal.es.js
CHANGED
|
@@ -1,52 +1,51 @@
|
|
|
1
|
-
import { jsxs as j, jsx as
|
|
1
|
+
import { jsxs as j, jsx as b } from "react/jsx-runtime";
|
|
2
2
|
import * as m from "react";
|
|
3
|
-
import { useCallback as
|
|
4
|
-
import
|
|
3
|
+
import { useCallback as Q, createContext as Oe, useMemo as me, createElement as _, useContext as rt, useLayoutEffect as It, useRef as N, useEffect as A, useState as H, forwardRef as S, Children as I, isValidElement as U, cloneElement as ae, Fragment as Ie, useReducer as Rt } from "react";
|
|
4
|
+
import Mt, { flushSync as ot } from "react-dom";
|
|
5
5
|
function P() {
|
|
6
6
|
return P = Object.assign ? Object.assign.bind() : function(e) {
|
|
7
7
|
for (var n = 1; n < arguments.length; n++) {
|
|
8
8
|
var t = arguments[n];
|
|
9
|
-
for (var o in t)
|
|
10
|
-
Object.prototype.hasOwnProperty.call(t, o) && (e[o] = t[o]);
|
|
9
|
+
for (var o in t) ({}).hasOwnProperty.call(t, o) && (e[o] = t[o]);
|
|
11
10
|
}
|
|
12
11
|
return e;
|
|
13
|
-
}, P.apply(
|
|
12
|
+
}, P.apply(null, arguments);
|
|
14
13
|
}
|
|
15
14
|
function B(e, n, { checkForDefaultPrevented: t = !0 } = {}) {
|
|
16
15
|
return function(a) {
|
|
17
16
|
if (e == null || e(a), t === !1 || !a.defaultPrevented) return n == null ? void 0 : n(a);
|
|
18
17
|
};
|
|
19
18
|
}
|
|
20
|
-
function
|
|
19
|
+
function kt(e, n) {
|
|
21
20
|
typeof e == "function" ? e(n) : e != null && (e.current = n);
|
|
22
21
|
}
|
|
23
|
-
function
|
|
22
|
+
function at(...e) {
|
|
24
23
|
return (n) => e.forEach(
|
|
25
|
-
(t) =>
|
|
24
|
+
(t) => kt(t, n)
|
|
26
25
|
);
|
|
27
26
|
}
|
|
28
|
-
function
|
|
29
|
-
return
|
|
27
|
+
function J(...e) {
|
|
28
|
+
return Q(at(...e), e);
|
|
30
29
|
}
|
|
31
|
-
function
|
|
30
|
+
function Ft(e, n = []) {
|
|
32
31
|
let t = [];
|
|
33
32
|
function o(r, i) {
|
|
34
|
-
const c = /* @__PURE__ */
|
|
33
|
+
const c = /* @__PURE__ */ Oe(i), s = t.length;
|
|
35
34
|
t = [
|
|
36
35
|
...t,
|
|
37
36
|
i
|
|
38
37
|
];
|
|
39
38
|
function d(l) {
|
|
40
|
-
const { scope:
|
|
39
|
+
const { scope: v, children: f, ...E } = l, u = (v == null ? void 0 : v[e][s]) || c, h = me(
|
|
41
40
|
() => E,
|
|
42
41
|
Object.values(E)
|
|
43
42
|
);
|
|
44
|
-
return /* @__PURE__ */
|
|
45
|
-
value:
|
|
43
|
+
return /* @__PURE__ */ _(u.Provider, {
|
|
44
|
+
value: h
|
|
46
45
|
}, f);
|
|
47
46
|
}
|
|
48
|
-
function p(l,
|
|
49
|
-
const f = (
|
|
47
|
+
function p(l, v) {
|
|
48
|
+
const f = (v == null ? void 0 : v[e][s]) || c, E = rt(f);
|
|
50
49
|
if (E) return E;
|
|
51
50
|
if (i !== void 0) return i;
|
|
52
51
|
throw new Error(`\`${l}\` must be used within \`${r}\``);
|
|
@@ -57,10 +56,10 @@ function Lt(e, n = []) {
|
|
|
57
56
|
];
|
|
58
57
|
}
|
|
59
58
|
const a = () => {
|
|
60
|
-
const r = t.map((i) => /* @__PURE__ */
|
|
59
|
+
const r = t.map((i) => /* @__PURE__ */ Oe(i));
|
|
61
60
|
return function(c) {
|
|
62
61
|
const s = (c == null ? void 0 : c[e]) || r;
|
|
63
|
-
return
|
|
62
|
+
return me(
|
|
64
63
|
() => ({
|
|
65
64
|
[`__scope${e}`]: {
|
|
66
65
|
...c,
|
|
@@ -76,10 +75,10 @@ function Lt(e, n = []) {
|
|
|
76
75
|
};
|
|
77
76
|
return a.scopeName = e, [
|
|
78
77
|
o,
|
|
79
|
-
|
|
78
|
+
jt(a, ...n)
|
|
80
79
|
];
|
|
81
80
|
}
|
|
82
|
-
function
|
|
81
|
+
function jt(...e) {
|
|
83
82
|
const n = e[0];
|
|
84
83
|
if (e.length === 1) return n;
|
|
85
84
|
const t = () => {
|
|
@@ -97,7 +96,7 @@ function Rt(...e) {
|
|
|
97
96
|
...l
|
|
98
97
|
};
|
|
99
98
|
}, {});
|
|
100
|
-
return
|
|
99
|
+
return me(
|
|
101
100
|
() => ({
|
|
102
101
|
[`__scope${n.scopeName}`]: i
|
|
103
102
|
}),
|
|
@@ -109,25 +108,25 @@ function Rt(...e) {
|
|
|
109
108
|
};
|
|
110
109
|
return t.scopeName = n.scopeName, t;
|
|
111
110
|
}
|
|
112
|
-
const
|
|
113
|
-
},
|
|
111
|
+
const Ne = globalThis != null && globalThis.document ? It : () => {
|
|
112
|
+
}, Bt = m.useId || (() => {
|
|
114
113
|
});
|
|
115
|
-
let
|
|
116
|
-
function
|
|
117
|
-
const [n, t] = m.useState(
|
|
118
|
-
return
|
|
114
|
+
let Ut = 0;
|
|
115
|
+
function be(e) {
|
|
116
|
+
const [n, t] = m.useState(Bt());
|
|
117
|
+
return Ne(() => {
|
|
119
118
|
e || t(
|
|
120
|
-
(o) => o ?? String(
|
|
119
|
+
(o) => o ?? String(Ut++)
|
|
121
120
|
);
|
|
122
121
|
}, [
|
|
123
122
|
e
|
|
124
123
|
]), e || (n ? `radix-${n}` : "");
|
|
125
124
|
}
|
|
126
|
-
function
|
|
125
|
+
function V(e) {
|
|
127
126
|
const n = N(e);
|
|
128
127
|
return A(() => {
|
|
129
128
|
n.current = e;
|
|
130
|
-
}),
|
|
129
|
+
}), me(
|
|
131
130
|
() => (...t) => {
|
|
132
131
|
var o;
|
|
133
132
|
return (o = n.current) === null || o === void 0 ? void 0 : o.call(n, ...t);
|
|
@@ -135,12 +134,12 @@ function K(e) {
|
|
|
135
134
|
[]
|
|
136
135
|
);
|
|
137
136
|
}
|
|
138
|
-
function
|
|
137
|
+
function Wt({ prop: e, defaultProp: n, onChange: t = () => {
|
|
139
138
|
} }) {
|
|
140
|
-
const [o, a] =
|
|
139
|
+
const [o, a] = zt({
|
|
141
140
|
defaultProp: n,
|
|
142
141
|
onChange: t
|
|
143
|
-
}), r = e !== void 0, i = r ? e : o, c =
|
|
142
|
+
}), r = e !== void 0, i = r ? e : o, c = V(t), s = Q((d) => {
|
|
144
143
|
if (r) {
|
|
145
144
|
const l = typeof d == "function" ? d(e) : d;
|
|
146
145
|
l !== e && c(l);
|
|
@@ -156,8 +155,8 @@ function Ft({ prop: e, defaultProp: n, onChange: t = () => {
|
|
|
156
155
|
s
|
|
157
156
|
];
|
|
158
157
|
}
|
|
159
|
-
function
|
|
160
|
-
const t = H(e), [o] = t, a = N(o), r =
|
|
158
|
+
function zt({ defaultProp: e, onChange: n }) {
|
|
159
|
+
const t = H(e), [o] = t, a = N(o), r = V(n);
|
|
161
160
|
return A(() => {
|
|
162
161
|
a.current !== o && (r(o), a.current = o);
|
|
163
162
|
}, [
|
|
@@ -166,32 +165,32 @@ function jt({ defaultProp: e, onChange: n }) {
|
|
|
166
165
|
r
|
|
167
166
|
]), t;
|
|
168
167
|
}
|
|
169
|
-
const
|
|
170
|
-
const { children: t, ...o } = e, a =
|
|
168
|
+
const Re = /* @__PURE__ */ S((e, n) => {
|
|
169
|
+
const { children: t, ...o } = e, a = I.toArray(t), r = a.find(Ht);
|
|
171
170
|
if (r) {
|
|
172
|
-
const i = r.props.children, c = a.map((s) => s === r ?
|
|
173
|
-
return /* @__PURE__ */
|
|
171
|
+
const i = r.props.children, c = a.map((s) => s === r ? I.count(i) > 1 ? I.only(null) : /* @__PURE__ */ U(i) ? i.props.children : null : s);
|
|
172
|
+
return /* @__PURE__ */ _(Pe, P({}, o, {
|
|
174
173
|
ref: n
|
|
175
|
-
}), /* @__PURE__ */ U(i) ? /* @__PURE__ */
|
|
174
|
+
}), /* @__PURE__ */ U(i) ? /* @__PURE__ */ ae(i, void 0, c) : null);
|
|
176
175
|
}
|
|
177
|
-
return /* @__PURE__ */
|
|
176
|
+
return /* @__PURE__ */ _(Pe, P({}, o, {
|
|
178
177
|
ref: n
|
|
179
178
|
}), t);
|
|
180
179
|
});
|
|
181
|
-
|
|
182
|
-
const
|
|
180
|
+
Re.displayName = "Slot";
|
|
181
|
+
const Pe = /* @__PURE__ */ S((e, n) => {
|
|
183
182
|
const { children: t, ...o } = e;
|
|
184
|
-
return /* @__PURE__ */ U(t) ? /* @__PURE__ */
|
|
185
|
-
...
|
|
186
|
-
ref: n ?
|
|
187
|
-
}) :
|
|
183
|
+
return /* @__PURE__ */ U(t) ? /* @__PURE__ */ ae(t, {
|
|
184
|
+
...Vt(o, t.props),
|
|
185
|
+
ref: n ? at(n, t.ref) : t.ref
|
|
186
|
+
}) : I.count(t) > 1 ? I.only(null) : null;
|
|
188
187
|
});
|
|
189
|
-
|
|
190
|
-
const
|
|
191
|
-
function
|
|
192
|
-
return /* @__PURE__ */ U(e) && e.type ===
|
|
188
|
+
Pe.displayName = "SlotClone";
|
|
189
|
+
const qt = ({ children: e }) => /* @__PURE__ */ _(Ie, null, e);
|
|
190
|
+
function Ht(e) {
|
|
191
|
+
return /* @__PURE__ */ U(e) && e.type === qt;
|
|
193
192
|
}
|
|
194
|
-
function
|
|
193
|
+
function Vt(e, n) {
|
|
195
194
|
const t = {
|
|
196
195
|
...n
|
|
197
196
|
};
|
|
@@ -212,7 +211,7 @@ function Wt(e, n) {
|
|
|
212
211
|
...t
|
|
213
212
|
};
|
|
214
213
|
}
|
|
215
|
-
const
|
|
214
|
+
const Kt = [
|
|
216
215
|
"a",
|
|
217
216
|
"button",
|
|
218
217
|
"div",
|
|
@@ -229,12 +228,12 @@ const zt = [
|
|
|
229
228
|
"span",
|
|
230
229
|
"svg",
|
|
231
230
|
"ul"
|
|
232
|
-
], W =
|
|
231
|
+
], W = Kt.reduce((e, n) => {
|
|
233
232
|
const t = /* @__PURE__ */ S((o, a) => {
|
|
234
|
-
const { asChild: r, ...i } = o, c = r ?
|
|
233
|
+
const { asChild: r, ...i } = o, c = r ? Re : n;
|
|
235
234
|
return A(() => {
|
|
236
235
|
window[Symbol.for("radix-ui")] = !0;
|
|
237
|
-
}, []), /* @__PURE__ */
|
|
236
|
+
}, []), /* @__PURE__ */ _(c, P({}, i, {
|
|
238
237
|
ref: a
|
|
239
238
|
}));
|
|
240
239
|
});
|
|
@@ -243,13 +242,13 @@ const zt = [
|
|
|
243
242
|
[n]: t
|
|
244
243
|
};
|
|
245
244
|
}, {});
|
|
246
|
-
function
|
|
247
|
-
e &&
|
|
245
|
+
function Xt(e, n) {
|
|
246
|
+
e && ot(
|
|
248
247
|
() => e.dispatchEvent(n)
|
|
249
248
|
);
|
|
250
249
|
}
|
|
251
|
-
function
|
|
252
|
-
const t =
|
|
250
|
+
function Gt(e, n = globalThis == null ? void 0 : globalThis.document) {
|
|
251
|
+
const t = V(e);
|
|
253
252
|
A(() => {
|
|
254
253
|
const o = (a) => {
|
|
255
254
|
a.key === "Escape" && t(a);
|
|
@@ -260,40 +259,40 @@ function Ht(e, n = globalThis == null ? void 0 : globalThis.document) {
|
|
|
260
259
|
n
|
|
261
260
|
]);
|
|
262
261
|
}
|
|
263
|
-
const
|
|
264
|
-
let
|
|
265
|
-
const
|
|
262
|
+
const Ae = "dismissableLayer.update", Yt = "dismissableLayer.pointerDownOutside", Zt = "dismissableLayer.focusOutside";
|
|
263
|
+
let je;
|
|
264
|
+
const Qt = /* @__PURE__ */ Oe({
|
|
266
265
|
layers: /* @__PURE__ */ new Set(),
|
|
267
266
|
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
268
267
|
branches: /* @__PURE__ */ new Set()
|
|
269
|
-
}),
|
|
268
|
+
}), Jt = /* @__PURE__ */ S((e, n) => {
|
|
270
269
|
var t;
|
|
271
|
-
const { disableOutsidePointerEvents: o = !1, onEscapeKeyDown: a, onPointerDownOutside: r, onFocusOutside: i, onInteractOutside: c, onDismiss: s, ...d } = e, p =
|
|
270
|
+
const { disableOutsidePointerEvents: o = !1, onEscapeKeyDown: a, onPointerDownOutside: r, onFocusOutside: i, onInteractOutside: c, onDismiss: s, ...d } = e, p = rt(Qt), [l, v] = H(null), f = (t = l == null ? void 0 : l.ownerDocument) !== null && t !== void 0 ? t : globalThis == null ? void 0 : globalThis.document, [, E] = H({}), u = J(
|
|
272
271
|
n,
|
|
273
|
-
(
|
|
274
|
-
),
|
|
272
|
+
(w) => v(w)
|
|
273
|
+
), h = Array.from(p.layers), [g] = [
|
|
275
274
|
...p.layersWithOutsidePointerEventsDisabled
|
|
276
|
-
].slice(-1), C =
|
|
277
|
-
const
|
|
275
|
+
].slice(-1), C = h.indexOf(g), y = l ? h.indexOf(l) : -1, $ = p.layersWithOutsidePointerEventsDisabled.size > 0, x = y >= C, z = en((w) => {
|
|
276
|
+
const L = w.target, ie = [
|
|
278
277
|
...p.branches
|
|
279
278
|
].some(
|
|
280
|
-
(R) => R.contains(
|
|
279
|
+
(R) => R.contains(L)
|
|
281
280
|
);
|
|
282
|
-
!
|
|
283
|
-
}, f), D =
|
|
284
|
-
const
|
|
281
|
+
!x || ie || (r == null || r(w), c == null || c(w), w.defaultPrevented || s == null || s());
|
|
282
|
+
}, f), D = tn((w) => {
|
|
283
|
+
const L = w.target;
|
|
285
284
|
[
|
|
286
285
|
...p.branches
|
|
287
286
|
].some(
|
|
288
|
-
(R) => R.contains(
|
|
289
|
-
) || (i == null || i(
|
|
287
|
+
(R) => R.contains(L)
|
|
288
|
+
) || (i == null || i(w), c == null || c(w), w.defaultPrevented || s == null || s());
|
|
290
289
|
}, f);
|
|
291
|
-
return
|
|
292
|
-
y === p.layers.size - 1 && (a == null || a(
|
|
290
|
+
return Gt((w) => {
|
|
291
|
+
y === p.layers.size - 1 && (a == null || a(w), !w.defaultPrevented && s && (w.preventDefault(), s()));
|
|
293
292
|
}, f), A(() => {
|
|
294
293
|
if (l)
|
|
295
|
-
return o && (p.layersWithOutsidePointerEventsDisabled.size === 0 && (
|
|
296
|
-
o && p.layersWithOutsidePointerEventsDisabled.size === 1 && (f.body.style.pointerEvents =
|
|
294
|
+
return o && (p.layersWithOutsidePointerEventsDisabled.size === 0 && (je = f.body.style.pointerEvents, f.body.style.pointerEvents = "none"), p.layersWithOutsidePointerEventsDisabled.add(l)), p.layers.add(l), Be(), () => {
|
|
295
|
+
o && p.layersWithOutsidePointerEventsDisabled.size === 1 && (f.body.style.pointerEvents = je);
|
|
297
296
|
};
|
|
298
297
|
}, [
|
|
299
298
|
l,
|
|
@@ -301,17 +300,17 @@ const Gt = /* @__PURE__ */ Se({
|
|
|
301
300
|
o,
|
|
302
301
|
p
|
|
303
302
|
]), A(() => () => {
|
|
304
|
-
l && (p.layers.delete(l), p.layersWithOutsidePointerEventsDisabled.delete(l),
|
|
303
|
+
l && (p.layers.delete(l), p.layersWithOutsidePointerEventsDisabled.delete(l), Be());
|
|
305
304
|
}, [
|
|
306
305
|
l,
|
|
307
306
|
p
|
|
308
307
|
]), A(() => {
|
|
309
|
-
const
|
|
310
|
-
return document.addEventListener(
|
|
311
|
-
}, []), /* @__PURE__ */
|
|
308
|
+
const w = () => E({});
|
|
309
|
+
return document.addEventListener(Ae, w), () => document.removeEventListener(Ae, w);
|
|
310
|
+
}, []), /* @__PURE__ */ _(W.div, P({}, d, {
|
|
312
311
|
ref: u,
|
|
313
312
|
style: {
|
|
314
|
-
pointerEvents: $ ?
|
|
313
|
+
pointerEvents: $ ? x ? "auto" : "none" : void 0,
|
|
315
314
|
...e.style
|
|
316
315
|
},
|
|
317
316
|
onFocusCapture: B(e.onFocusCapture, D.onFocusCapture),
|
|
@@ -319,14 +318,14 @@ const Gt = /* @__PURE__ */ Se({
|
|
|
319
318
|
onPointerDownCapture: B(e.onPointerDownCapture, z.onPointerDownCapture)
|
|
320
319
|
}));
|
|
321
320
|
});
|
|
322
|
-
function
|
|
323
|
-
const t =
|
|
321
|
+
function en(e, n = globalThis == null ? void 0 : globalThis.document) {
|
|
322
|
+
const t = V(e), o = N(!1), a = N(() => {
|
|
324
323
|
});
|
|
325
324
|
return A(() => {
|
|
326
325
|
const r = (c) => {
|
|
327
326
|
if (c.target && !o.current) {
|
|
328
327
|
let d = function() {
|
|
329
|
-
|
|
328
|
+
it(Yt, t, s, {
|
|
330
329
|
discrete: !0
|
|
331
330
|
});
|
|
332
331
|
};
|
|
@@ -353,11 +352,11 @@ function Yt(e, n = globalThis == null ? void 0 : globalThis.document) {
|
|
|
353
352
|
onPointerDownCapture: () => o.current = !0
|
|
354
353
|
};
|
|
355
354
|
}
|
|
356
|
-
function
|
|
357
|
-
const t =
|
|
355
|
+
function tn(e, n = globalThis == null ? void 0 : globalThis.document) {
|
|
356
|
+
const t = V(e), o = N(!1);
|
|
358
357
|
return A(() => {
|
|
359
358
|
const a = (r) => {
|
|
360
|
-
r.target && !o.current &&
|
|
359
|
+
r.target && !o.current && it(Zt, t, {
|
|
361
360
|
originalEvent: r
|
|
362
361
|
}, {
|
|
363
362
|
discrete: !1
|
|
@@ -372,11 +371,11 @@ function Zt(e, n = globalThis == null ? void 0 : globalThis.document) {
|
|
|
372
371
|
onBlurCapture: () => o.current = !1
|
|
373
372
|
};
|
|
374
373
|
}
|
|
375
|
-
function
|
|
376
|
-
const e = new CustomEvent(
|
|
374
|
+
function Be() {
|
|
375
|
+
const e = new CustomEvent(Ae);
|
|
377
376
|
document.dispatchEvent(e);
|
|
378
377
|
}
|
|
379
|
-
function
|
|
378
|
+
function it(e, n, t, { discrete: o }) {
|
|
380
379
|
const a = t.originalEvent.target, r = new CustomEvent(e, {
|
|
381
380
|
bubbles: !1,
|
|
382
381
|
cancelable: !0,
|
|
@@ -384,13 +383,13 @@ function nt(e, n, t, { discrete: o }) {
|
|
|
384
383
|
});
|
|
385
384
|
n && a.addEventListener(e, n, {
|
|
386
385
|
once: !0
|
|
387
|
-
}), o ?
|
|
386
|
+
}), o ? Xt(a, r) : a.dispatchEvent(r);
|
|
388
387
|
}
|
|
389
|
-
const
|
|
388
|
+
const $e = "focusScope.autoFocusOnMount", ye = "focusScope.autoFocusOnUnmount", Ue = {
|
|
390
389
|
bubbles: !1,
|
|
391
390
|
cancelable: !0
|
|
392
|
-
},
|
|
393
|
-
const { loop: t = !1, trapped: o = !1, onMountAutoFocus: a, onUnmountAutoFocus: r, ...i } = e, [c, s] = H(null), d =
|
|
391
|
+
}, nn = /* @__PURE__ */ S((e, n) => {
|
|
392
|
+
const { loop: t = !1, trapped: o = !1, onMountAutoFocus: a, onUnmountAutoFocus: r, ...i } = e, [c, s] = H(null), d = V(a), p = V(r), l = N(null), v = J(
|
|
394
393
|
n,
|
|
395
394
|
(u) => s(u)
|
|
396
395
|
), f = N({
|
|
@@ -410,23 +409,23 @@ const be = "focusScope.autoFocusOnMount", $e = "focusScope.autoFocusOnUnmount",
|
|
|
410
409
|
c.contains($) ? l.current = $ : F(l.current, {
|
|
411
410
|
select: !0
|
|
412
411
|
});
|
|
413
|
-
},
|
|
412
|
+
}, h = function(y) {
|
|
414
413
|
if (f.paused || !c) return;
|
|
415
414
|
const $ = y.relatedTarget;
|
|
416
415
|
$ !== null && (c.contains($) || F(l.current, {
|
|
417
416
|
select: !0
|
|
418
417
|
}));
|
|
419
|
-
},
|
|
418
|
+
}, g = function(y) {
|
|
420
419
|
if (document.activeElement === document.body)
|
|
421
|
-
for (const
|
|
420
|
+
for (const x of y) x.removedNodes.length > 0 && F(c);
|
|
422
421
|
};
|
|
423
|
-
document.addEventListener("focusin", u), document.addEventListener("focusout",
|
|
424
|
-
const C = new MutationObserver(
|
|
422
|
+
document.addEventListener("focusin", u), document.addEventListener("focusout", h);
|
|
423
|
+
const C = new MutationObserver(g);
|
|
425
424
|
return c && C.observe(c, {
|
|
426
425
|
childList: !0,
|
|
427
426
|
subtree: !0
|
|
428
427
|
}), () => {
|
|
429
|
-
document.removeEventListener("focusin", u), document.removeEventListener("focusout",
|
|
428
|
+
document.removeEventListener("focusin", u), document.removeEventListener("focusout", h), C.disconnect();
|
|
430
429
|
};
|
|
431
430
|
}
|
|
432
431
|
}, [
|
|
@@ -435,20 +434,20 @@ const be = "focusScope.autoFocusOnMount", $e = "focusScope.autoFocusOnUnmount",
|
|
|
435
434
|
f.paused
|
|
436
435
|
]), A(() => {
|
|
437
436
|
if (c) {
|
|
438
|
-
|
|
437
|
+
ze.add(f);
|
|
439
438
|
const u = document.activeElement;
|
|
440
439
|
if (!c.contains(u)) {
|
|
441
|
-
const
|
|
442
|
-
c.addEventListener(
|
|
440
|
+
const g = new CustomEvent($e, Ue);
|
|
441
|
+
c.addEventListener($e, d), c.dispatchEvent(g), g.defaultPrevented || (rn(sn(ct(c)), {
|
|
443
442
|
select: !0
|
|
444
443
|
}), document.activeElement === u && F(c));
|
|
445
444
|
}
|
|
446
445
|
return () => {
|
|
447
|
-
c.removeEventListener(
|
|
448
|
-
const
|
|
449
|
-
c.addEventListener(
|
|
446
|
+
c.removeEventListener($e, d), setTimeout(() => {
|
|
447
|
+
const g = new CustomEvent(ye, Ue);
|
|
448
|
+
c.addEventListener(ye, p), c.dispatchEvent(g), g.defaultPrevented || F(u ?? document.body, {
|
|
450
449
|
select: !0
|
|
451
|
-
}), c.removeEventListener(
|
|
450
|
+
}), c.removeEventListener(ye, p), ze.remove(f);
|
|
452
451
|
}, 0);
|
|
453
452
|
};
|
|
454
453
|
}
|
|
@@ -458,44 +457,44 @@ const be = "focusScope.autoFocusOnMount", $e = "focusScope.autoFocusOnUnmount",
|
|
|
458
457
|
p,
|
|
459
458
|
f
|
|
460
459
|
]);
|
|
461
|
-
const E =
|
|
460
|
+
const E = Q((u) => {
|
|
462
461
|
if (!t && !o || f.paused) return;
|
|
463
|
-
const
|
|
464
|
-
if (
|
|
465
|
-
const C = u.currentTarget, [y, $] =
|
|
466
|
-
y && $ ? !u.shiftKey &&
|
|
462
|
+
const h = u.key === "Tab" && !u.altKey && !u.ctrlKey && !u.metaKey, g = document.activeElement;
|
|
463
|
+
if (h && g) {
|
|
464
|
+
const C = u.currentTarget, [y, $] = on(C);
|
|
465
|
+
y && $ ? !u.shiftKey && g === $ ? (u.preventDefault(), t && F(y, {
|
|
467
466
|
select: !0
|
|
468
|
-
})) : u.shiftKey &&
|
|
467
|
+
})) : u.shiftKey && g === y && (u.preventDefault(), t && F($, {
|
|
469
468
|
select: !0
|
|
470
|
-
})) :
|
|
469
|
+
})) : g === C && u.preventDefault();
|
|
471
470
|
}
|
|
472
471
|
}, [
|
|
473
472
|
t,
|
|
474
473
|
o,
|
|
475
474
|
f.paused
|
|
476
475
|
]);
|
|
477
|
-
return /* @__PURE__ */
|
|
476
|
+
return /* @__PURE__ */ _(W.div, P({
|
|
478
477
|
tabIndex: -1
|
|
479
478
|
}, i, {
|
|
480
|
-
ref:
|
|
479
|
+
ref: v,
|
|
481
480
|
onKeyDown: E
|
|
482
481
|
}));
|
|
483
482
|
});
|
|
484
|
-
function
|
|
483
|
+
function rn(e, { select: n = !1 } = {}) {
|
|
485
484
|
const t = document.activeElement;
|
|
486
485
|
for (const o of e)
|
|
487
486
|
if (F(o, {
|
|
488
487
|
select: n
|
|
489
488
|
}), document.activeElement !== t) return;
|
|
490
489
|
}
|
|
491
|
-
function
|
|
492
|
-
const n =
|
|
490
|
+
function on(e) {
|
|
491
|
+
const n = ct(e), t = We(n, e), o = We(n.reverse(), e);
|
|
493
492
|
return [
|
|
494
493
|
t,
|
|
495
494
|
o
|
|
496
495
|
];
|
|
497
496
|
}
|
|
498
|
-
function
|
|
497
|
+
function ct(e) {
|
|
499
498
|
const n = [], t = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, {
|
|
500
499
|
acceptNode: (o) => {
|
|
501
500
|
const a = o.tagName === "INPUT" && o.type === "hidden";
|
|
@@ -505,13 +504,13 @@ function rt(e) {
|
|
|
505
504
|
for (; t.nextNode(); ) n.push(t.currentNode);
|
|
506
505
|
return n;
|
|
507
506
|
}
|
|
508
|
-
function
|
|
507
|
+
function We(e, n) {
|
|
509
508
|
for (const t of e)
|
|
510
|
-
if (!
|
|
509
|
+
if (!an(t, {
|
|
511
510
|
upTo: n
|
|
512
511
|
})) return t;
|
|
513
512
|
}
|
|
514
|
-
function
|
|
513
|
+
function an(e, { upTo: n }) {
|
|
515
514
|
if (getComputedStyle(e).visibility === "hidden") return !0;
|
|
516
515
|
for (; e; ) {
|
|
517
516
|
if (n !== void 0 && e === n) return !1;
|
|
@@ -520,7 +519,7 @@ function tn(e, { upTo: n }) {
|
|
|
520
519
|
}
|
|
521
520
|
return !1;
|
|
522
521
|
}
|
|
523
|
-
function
|
|
522
|
+
function cn(e) {
|
|
524
523
|
return e instanceof HTMLInputElement && "select" in e;
|
|
525
524
|
}
|
|
526
525
|
function F(e, { select: n = !1 } = {}) {
|
|
@@ -528,58 +527,58 @@ function F(e, { select: n = !1 } = {}) {
|
|
|
528
527
|
const t = document.activeElement;
|
|
529
528
|
e.focus({
|
|
530
529
|
preventScroll: !0
|
|
531
|
-
}), e !== t &&
|
|
530
|
+
}), e !== t && cn(e) && n && e.select();
|
|
532
531
|
}
|
|
533
532
|
}
|
|
534
|
-
const
|
|
535
|
-
function
|
|
533
|
+
const ze = un();
|
|
534
|
+
function un() {
|
|
536
535
|
let e = [];
|
|
537
536
|
return {
|
|
538
537
|
add(n) {
|
|
539
538
|
const t = e[0];
|
|
540
|
-
n !== t && (t == null || t.pause()), e =
|
|
539
|
+
n !== t && (t == null || t.pause()), e = qe(e, n), e.unshift(n);
|
|
541
540
|
},
|
|
542
541
|
remove(n) {
|
|
543
542
|
var t;
|
|
544
|
-
e =
|
|
543
|
+
e = qe(e, n), (t = e[0]) === null || t === void 0 || t.resume();
|
|
545
544
|
}
|
|
546
545
|
};
|
|
547
546
|
}
|
|
548
|
-
function
|
|
547
|
+
function qe(e, n) {
|
|
549
548
|
const t = [
|
|
550
549
|
...e
|
|
551
550
|
], o = t.indexOf(n);
|
|
552
551
|
return o !== -1 && t.splice(o, 1), t;
|
|
553
552
|
}
|
|
554
|
-
function
|
|
553
|
+
function sn(e) {
|
|
555
554
|
return e.filter(
|
|
556
555
|
(n) => n.tagName !== "A"
|
|
557
556
|
);
|
|
558
557
|
}
|
|
559
|
-
const
|
|
558
|
+
const ln = /* @__PURE__ */ S((e, n) => {
|
|
560
559
|
var t;
|
|
561
560
|
const { container: o = globalThis == null || (t = globalThis.document) === null || t === void 0 ? void 0 : t.body, ...a } = e;
|
|
562
|
-
return o ? /* @__PURE__ */
|
|
561
|
+
return o ? /* @__PURE__ */ Mt.createPortal(/* @__PURE__ */ _(W.div, P({}, a, {
|
|
563
562
|
ref: n
|
|
564
563
|
})), o) : null;
|
|
565
564
|
});
|
|
566
|
-
function
|
|
567
|
-
return
|
|
565
|
+
function dn(e, n) {
|
|
566
|
+
return Rt((t, o) => {
|
|
568
567
|
const a = n[t][o];
|
|
569
568
|
return a ?? t;
|
|
570
569
|
}, e);
|
|
571
570
|
}
|
|
572
|
-
const
|
|
573
|
-
const { present: n, children: t } = e, o =
|
|
571
|
+
const ge = (e) => {
|
|
572
|
+
const { present: n, children: t } = e, o = pn(n), a = typeof t == "function" ? t({
|
|
574
573
|
present: o.isPresent
|
|
575
|
-
}) :
|
|
576
|
-
return typeof t == "function" || o.isPresent ? /* @__PURE__ */
|
|
574
|
+
}) : I.only(t), r = J(o.ref, a.ref);
|
|
575
|
+
return typeof t == "function" || o.isPresent ? /* @__PURE__ */ ae(a, {
|
|
577
576
|
ref: r
|
|
578
577
|
}) : null;
|
|
579
578
|
};
|
|
580
|
-
|
|
581
|
-
function
|
|
582
|
-
const [n, t] = H(), o = N({}), a = N(e), r = N("none"), i = e ? "mounted" : "unmounted", [c, s] =
|
|
579
|
+
ge.displayName = "Presence";
|
|
580
|
+
function pn(e) {
|
|
581
|
+
const [n, t] = H(), o = N({}), a = N(e), r = N("none"), i = e ? "mounted" : "unmounted", [c, s] = dn(i, {
|
|
583
582
|
mounted: {
|
|
584
583
|
UNMOUNT: "unmounted",
|
|
585
584
|
ANIMATION_OUT: "unmountSuspended"
|
|
@@ -593,28 +592,28 @@ function un(e) {
|
|
|
593
592
|
}
|
|
594
593
|
});
|
|
595
594
|
return A(() => {
|
|
596
|
-
const d =
|
|
595
|
+
const d = ce(o.current);
|
|
597
596
|
r.current = c === "mounted" ? d : "none";
|
|
598
597
|
}, [
|
|
599
598
|
c
|
|
600
|
-
]),
|
|
599
|
+
]), Ne(() => {
|
|
601
600
|
const d = o.current, p = a.current;
|
|
602
601
|
if (p !== e) {
|
|
603
|
-
const
|
|
604
|
-
e ? s("MOUNT") : f === "none" || (d == null ? void 0 : d.display) === "none" ? s("UNMOUNT") : s(p &&
|
|
602
|
+
const v = r.current, f = ce(d);
|
|
603
|
+
e ? s("MOUNT") : f === "none" || (d == null ? void 0 : d.display) === "none" ? s("UNMOUNT") : s(p && v !== f ? "ANIMATION_OUT" : "UNMOUNT"), a.current = e;
|
|
605
604
|
}
|
|
606
605
|
}, [
|
|
607
606
|
e,
|
|
608
607
|
s
|
|
609
|
-
]),
|
|
608
|
+
]), Ne(() => {
|
|
610
609
|
if (n) {
|
|
611
610
|
const d = (l) => {
|
|
612
|
-
const f =
|
|
613
|
-
l.target === n && f &&
|
|
611
|
+
const f = ce(o.current).includes(l.animationName);
|
|
612
|
+
l.target === n && f && ot(
|
|
614
613
|
() => s("ANIMATION_END")
|
|
615
614
|
);
|
|
616
615
|
}, p = (l) => {
|
|
617
|
-
l.target === n && (r.current =
|
|
616
|
+
l.target === n && (r.current = ce(o.current));
|
|
618
617
|
};
|
|
619
618
|
return n.addEventListener("animationstart", p), n.addEventListener("animationcancel", d), n.addEventListener("animationend", d), () => {
|
|
620
619
|
n.removeEventListener("animationstart", p), n.removeEventListener("animationcancel", d), n.removeEventListener("animationend", d);
|
|
@@ -629,27 +628,27 @@ function un(e) {
|
|
|
629
628
|
"mounted",
|
|
630
629
|
"unmountSuspended"
|
|
631
630
|
].includes(c),
|
|
632
|
-
ref:
|
|
631
|
+
ref: Q((d) => {
|
|
633
632
|
d && (o.current = getComputedStyle(d)), t(d);
|
|
634
633
|
}, [])
|
|
635
634
|
};
|
|
636
635
|
}
|
|
637
|
-
function
|
|
636
|
+
function ce(e) {
|
|
638
637
|
return (e == null ? void 0 : e.animationName) || "none";
|
|
639
638
|
}
|
|
640
|
-
let
|
|
641
|
-
function
|
|
639
|
+
let Ee = 0;
|
|
640
|
+
function fn() {
|
|
642
641
|
A(() => {
|
|
643
642
|
var e, n;
|
|
644
643
|
const t = document.querySelectorAll("[data-radix-focus-guard]");
|
|
645
|
-
return document.body.insertAdjacentElement("afterbegin", (e = t[0]) !== null && e !== void 0 ? e :
|
|
646
|
-
|
|
644
|
+
return document.body.insertAdjacentElement("afterbegin", (e = t[0]) !== null && e !== void 0 ? e : He()), document.body.insertAdjacentElement("beforeend", (n = t[1]) !== null && n !== void 0 ? n : He()), Ee++, () => {
|
|
645
|
+
Ee === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach(
|
|
647
646
|
(o) => o.remove()
|
|
648
|
-
),
|
|
647
|
+
), Ee--;
|
|
649
648
|
};
|
|
650
649
|
}, []);
|
|
651
650
|
}
|
|
652
|
-
function
|
|
651
|
+
function He() {
|
|
653
652
|
const e = document.createElement("span");
|
|
654
653
|
return e.setAttribute("data-radix-focus-guard", ""), e.tabIndex = 0, e.style.cssText = "outline: none; opacity: 0; position: fixed; pointer-events: none", e;
|
|
655
654
|
}
|
|
@@ -662,7 +661,7 @@ var k = function() {
|
|
|
662
661
|
return n;
|
|
663
662
|
}, k.apply(this, arguments);
|
|
664
663
|
};
|
|
665
|
-
function
|
|
664
|
+
function ut(e, n) {
|
|
666
665
|
var t = {};
|
|
667
666
|
for (var o in e) Object.prototype.hasOwnProperty.call(e, o) && n.indexOf(o) < 0 && (t[o] = e[o]);
|
|
668
667
|
if (e != null && typeof Object.getOwnPropertySymbols == "function")
|
|
@@ -670,16 +669,16 @@ function ot(e, n) {
|
|
|
670
669
|
n.indexOf(o[a]) < 0 && Object.prototype.propertyIsEnumerable.call(e, o[a]) && (t[o[a]] = e[o[a]]);
|
|
671
670
|
return t;
|
|
672
671
|
}
|
|
673
|
-
function
|
|
672
|
+
function vn(e, n, t) {
|
|
674
673
|
if (t || arguments.length === 2) for (var o = 0, a = n.length, r; o < a; o++)
|
|
675
674
|
(r || !(o in n)) && (r || (r = Array.prototype.slice.call(n, 0, o)), r[o] = n[o]);
|
|
676
675
|
return e.concat(r || Array.prototype.slice.call(n));
|
|
677
676
|
}
|
|
678
|
-
var
|
|
679
|
-
function
|
|
677
|
+
var ve = "right-scroll-bar-position", he = "width-before-scroll-bar", hn = "with-scroll-bars-hidden", mn = "--removed-body-scroll-bar-size";
|
|
678
|
+
function we(e, n) {
|
|
680
679
|
return typeof e == "function" ? e(n) : e && (e.current = n), e;
|
|
681
680
|
}
|
|
682
|
-
function
|
|
681
|
+
function gn(e, n) {
|
|
683
682
|
var t = H(function() {
|
|
684
683
|
return {
|
|
685
684
|
// value
|
|
@@ -700,18 +699,31 @@ function vn(e, n) {
|
|
|
700
699
|
})[0];
|
|
701
700
|
return t.callback = n, t.facade;
|
|
702
701
|
}
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
702
|
+
var _n = typeof window < "u" ? m.useLayoutEffect : m.useEffect, Ve = /* @__PURE__ */ new WeakMap();
|
|
703
|
+
function bn(e, n) {
|
|
704
|
+
var t = gn(null, function(o) {
|
|
705
|
+
return e.forEach(function(a) {
|
|
706
|
+
return we(a, o);
|
|
707
707
|
});
|
|
708
708
|
});
|
|
709
|
+
return _n(function() {
|
|
710
|
+
var o = Ve.get(t);
|
|
711
|
+
if (o) {
|
|
712
|
+
var a = new Set(o), r = new Set(e), i = t.current;
|
|
713
|
+
a.forEach(function(c) {
|
|
714
|
+
r.has(c) || we(c, null);
|
|
715
|
+
}), r.forEach(function(c) {
|
|
716
|
+
a.has(c) || we(c, i);
|
|
717
|
+
});
|
|
718
|
+
}
|
|
719
|
+
Ve.set(t, e);
|
|
720
|
+
}, [e]), t;
|
|
709
721
|
}
|
|
710
|
-
function
|
|
722
|
+
function $n(e) {
|
|
711
723
|
return e;
|
|
712
724
|
}
|
|
713
|
-
function
|
|
714
|
-
n === void 0 && (n =
|
|
725
|
+
function yn(e, n) {
|
|
726
|
+
n === void 0 && (n = $n);
|
|
715
727
|
var t = [], o = !1, a = {
|
|
716
728
|
read: function() {
|
|
717
729
|
if (o)
|
|
@@ -765,13 +777,13 @@ function gn(e, n) {
|
|
|
765
777
|
};
|
|
766
778
|
return a;
|
|
767
779
|
}
|
|
768
|
-
function
|
|
780
|
+
function En(e) {
|
|
769
781
|
e === void 0 && (e = {});
|
|
770
|
-
var n =
|
|
782
|
+
var n = yn(null);
|
|
771
783
|
return n.options = k({ async: !0, ssr: !1 }, e), n;
|
|
772
784
|
}
|
|
773
|
-
var
|
|
774
|
-
var n = e.sideCar, t =
|
|
785
|
+
var st = function(e) {
|
|
786
|
+
var n = e.sideCar, t = ut(e, ["sideCar"]);
|
|
775
787
|
if (!n)
|
|
776
788
|
throw new Error("Sidecar: please provide `sideCar` property to import the right car");
|
|
777
789
|
var o = n.read();
|
|
@@ -779,64 +791,64 @@ var at = function(e) {
|
|
|
779
791
|
throw new Error("Sidecar medium not found");
|
|
780
792
|
return m.createElement(o, k({}, t));
|
|
781
793
|
};
|
|
782
|
-
|
|
783
|
-
function
|
|
784
|
-
return e.useMedium(n),
|
|
794
|
+
st.isSideCarExport = !0;
|
|
795
|
+
function wn(e, n) {
|
|
796
|
+
return e.useMedium(n), st;
|
|
785
797
|
}
|
|
786
|
-
var
|
|
787
|
-
},
|
|
798
|
+
var lt = En(), xe = function() {
|
|
799
|
+
}, _e = m.forwardRef(function(e, n) {
|
|
788
800
|
var t = m.useRef(null), o = m.useState({
|
|
789
|
-
onScrollCapture:
|
|
790
|
-
onWheelCapture:
|
|
791
|
-
onTouchMoveCapture:
|
|
792
|
-
}), a = o[0], r = o[1], i = e.forwardProps, c = e.children, s = e.className, d = e.removeScrollBar, p = e.enabled, l = e.shards,
|
|
801
|
+
onScrollCapture: xe,
|
|
802
|
+
onWheelCapture: xe,
|
|
803
|
+
onTouchMoveCapture: xe
|
|
804
|
+
}), a = o[0], r = o[1], i = e.forwardProps, c = e.children, s = e.className, d = e.removeScrollBar, p = e.enabled, l = e.shards, v = e.sideCar, f = e.noIsolation, E = e.inert, u = e.allowPinchZoom, h = e.as, g = h === void 0 ? "div" : h, C = ut(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noIsolation", "inert", "allowPinchZoom", "as"]), y = v, $ = bn([t, n]), x = k(k({}, C), a);
|
|
793
805
|
return m.createElement(
|
|
794
806
|
m.Fragment,
|
|
795
807
|
null,
|
|
796
|
-
p && m.createElement(y, { sideCar:
|
|
797
|
-
i ? m.cloneElement(m.Children.only(c), k(k({},
|
|
808
|
+
p && m.createElement(y, { sideCar: lt, removeScrollBar: d, shards: l, noIsolation: f, inert: E, setCallbacks: r, allowPinchZoom: !!u, lockRef: t }),
|
|
809
|
+
i ? m.cloneElement(m.Children.only(c), k(k({}, x), { ref: $ })) : m.createElement(g, k({}, x, { className: s, ref: $ }), c)
|
|
798
810
|
);
|
|
799
811
|
});
|
|
800
|
-
|
|
812
|
+
_e.defaultProps = {
|
|
801
813
|
enabled: !0,
|
|
802
814
|
removeScrollBar: !0,
|
|
803
815
|
inert: !1
|
|
804
816
|
};
|
|
805
|
-
|
|
806
|
-
fullWidth:
|
|
807
|
-
zeroRight:
|
|
817
|
+
_e.classNames = {
|
|
818
|
+
fullWidth: he,
|
|
819
|
+
zeroRight: ve
|
|
808
820
|
};
|
|
809
|
-
var
|
|
821
|
+
var xn = function() {
|
|
810
822
|
if (typeof __webpack_nonce__ < "u")
|
|
811
823
|
return __webpack_nonce__;
|
|
812
824
|
};
|
|
813
|
-
function
|
|
825
|
+
function Sn() {
|
|
814
826
|
if (!document)
|
|
815
827
|
return null;
|
|
816
828
|
var e = document.createElement("style");
|
|
817
829
|
e.type = "text/css";
|
|
818
|
-
var n =
|
|
830
|
+
var n = xn();
|
|
819
831
|
return n && e.setAttribute("nonce", n), e;
|
|
820
832
|
}
|
|
821
|
-
function
|
|
833
|
+
function Cn(e, n) {
|
|
822
834
|
e.styleSheet ? e.styleSheet.cssText = n : e.appendChild(document.createTextNode(n));
|
|
823
835
|
}
|
|
824
|
-
function
|
|
836
|
+
function On(e) {
|
|
825
837
|
var n = document.head || document.getElementsByTagName("head")[0];
|
|
826
838
|
n.appendChild(e);
|
|
827
839
|
}
|
|
828
|
-
var
|
|
840
|
+
var Nn = function() {
|
|
829
841
|
var e = 0, n = null;
|
|
830
842
|
return {
|
|
831
843
|
add: function(t) {
|
|
832
|
-
e == 0 && (n =
|
|
844
|
+
e == 0 && (n = Sn()) && (Cn(n, t), On(n)), e++;
|
|
833
845
|
},
|
|
834
846
|
remove: function() {
|
|
835
847
|
e--, !e && n && (n.parentNode && n.parentNode.removeChild(n), n = null);
|
|
836
848
|
}
|
|
837
849
|
};
|
|
838
|
-
},
|
|
839
|
-
var e =
|
|
850
|
+
}, Pn = function() {
|
|
851
|
+
var e = Nn();
|
|
840
852
|
return function(n, t) {
|
|
841
853
|
m.useEffect(function() {
|
|
842
854
|
return e.add(n), function() {
|
|
@@ -844,40 +856,40 @@ var wn = function() {
|
|
|
844
856
|
};
|
|
845
857
|
}, [n && t]);
|
|
846
858
|
};
|
|
847
|
-
},
|
|
848
|
-
var e =
|
|
859
|
+
}, dt = function() {
|
|
860
|
+
var e = Pn(), n = function(t) {
|
|
849
861
|
var o = t.styles, a = t.dynamic;
|
|
850
862
|
return e(o, a), null;
|
|
851
863
|
};
|
|
852
864
|
return n;
|
|
853
|
-
},
|
|
865
|
+
}, An = {
|
|
854
866
|
left: 0,
|
|
855
867
|
top: 0,
|
|
856
868
|
right: 0,
|
|
857
869
|
gap: 0
|
|
858
|
-
},
|
|
870
|
+
}, Se = function(e) {
|
|
859
871
|
return parseInt(e || "", 10) || 0;
|
|
860
|
-
},
|
|
872
|
+
}, Tn = function(e) {
|
|
861
873
|
var n = window.getComputedStyle(document.body), t = n[e === "padding" ? "paddingLeft" : "marginLeft"], o = n[e === "padding" ? "paddingTop" : "marginTop"], a = n[e === "padding" ? "paddingRight" : "marginRight"];
|
|
862
|
-
return [
|
|
863
|
-
},
|
|
874
|
+
return [Se(t), Se(o), Se(a)];
|
|
875
|
+
}, Dn = function(e) {
|
|
864
876
|
if (e === void 0 && (e = "margin"), typeof window > "u")
|
|
865
|
-
return
|
|
866
|
-
var n =
|
|
877
|
+
return An;
|
|
878
|
+
var n = Tn(e), t = document.documentElement.clientWidth, o = window.innerWidth;
|
|
867
879
|
return {
|
|
868
880
|
left: n[0],
|
|
869
881
|
top: n[1],
|
|
870
882
|
right: n[2],
|
|
871
883
|
gap: Math.max(0, o - t + n[2] - n[0])
|
|
872
884
|
};
|
|
873
|
-
},
|
|
885
|
+
}, Ln = dt(), Y = "data-scroll-locked", In = function(e, n, t, o) {
|
|
874
886
|
var a = e.left, r = e.top, i = e.right, c = e.gap;
|
|
875
887
|
return t === void 0 && (t = "margin"), `
|
|
876
|
-
.`.concat(
|
|
888
|
+
.`.concat(hn, ` {
|
|
877
889
|
overflow: hidden `).concat(o, `;
|
|
878
890
|
padding-right: `).concat(c, "px ").concat(o, `;
|
|
879
891
|
}
|
|
880
|
-
body {
|
|
892
|
+
body[`).concat(Y, `] {
|
|
881
893
|
overflow: hidden `).concat(o, `;
|
|
882
894
|
overscroll-behavior: contain;
|
|
883
895
|
`).concat([
|
|
@@ -894,265 +906,280 @@ var wn = function() {
|
|
|
894
906
|
].filter(Boolean).join(""), `
|
|
895
907
|
}
|
|
896
908
|
|
|
897
|
-
.`).concat(
|
|
909
|
+
.`).concat(ve, ` {
|
|
898
910
|
right: `).concat(c, "px ").concat(o, `;
|
|
899
911
|
}
|
|
900
912
|
|
|
901
|
-
.`).concat(
|
|
913
|
+
.`).concat(he, ` {
|
|
902
914
|
margin-right: `).concat(c, "px ").concat(o, `;
|
|
903
915
|
}
|
|
904
916
|
|
|
905
|
-
.`).concat(
|
|
917
|
+
.`).concat(ve, " .").concat(ve, ` {
|
|
906
918
|
right: 0 `).concat(o, `;
|
|
907
919
|
}
|
|
908
920
|
|
|
909
|
-
.`).concat(
|
|
921
|
+
.`).concat(he, " .").concat(he, ` {
|
|
910
922
|
margin-right: 0 `).concat(o, `;
|
|
911
923
|
}
|
|
912
924
|
|
|
913
|
-
body {
|
|
914
|
-
`).concat(
|
|
925
|
+
body[`).concat(Y, `] {
|
|
926
|
+
`).concat(mn, ": ").concat(c, `px;
|
|
915
927
|
}
|
|
916
928
|
`);
|
|
917
|
-
},
|
|
918
|
-
var
|
|
919
|
-
|
|
929
|
+
}, Ke = function() {
|
|
930
|
+
var e = parseInt(document.body.getAttribute(Y) || "0", 10);
|
|
931
|
+
return isFinite(e) ? e : 0;
|
|
932
|
+
}, Rn = function() {
|
|
933
|
+
m.useEffect(function() {
|
|
934
|
+
return document.body.setAttribute(Y, (Ke() + 1).toString()), function() {
|
|
935
|
+
var e = Ke() - 1;
|
|
936
|
+
e <= 0 ? document.body.removeAttribute(Y) : document.body.setAttribute(Y, e.toString());
|
|
937
|
+
};
|
|
938
|
+
}, []);
|
|
939
|
+
}, Mn = function(e) {
|
|
940
|
+
var n = e.noRelative, t = e.noImportant, o = e.gapMode, a = o === void 0 ? "margin" : o;
|
|
941
|
+
Rn();
|
|
942
|
+
var r = m.useMemo(function() {
|
|
943
|
+
return Dn(a);
|
|
920
944
|
}, [a]);
|
|
921
|
-
return m.createElement(
|
|
922
|
-
},
|
|
945
|
+
return m.createElement(Ln, { styles: In(r, !n, a, t ? "" : "!important") });
|
|
946
|
+
}, Te = !1;
|
|
923
947
|
if (typeof window < "u")
|
|
924
948
|
try {
|
|
925
|
-
var
|
|
949
|
+
var ue = Object.defineProperty({}, "passive", {
|
|
926
950
|
get: function() {
|
|
927
|
-
return
|
|
951
|
+
return Te = !0, !0;
|
|
928
952
|
}
|
|
929
953
|
});
|
|
930
|
-
window.addEventListener("test",
|
|
954
|
+
window.addEventListener("test", ue, ue), window.removeEventListener("test", ue, ue);
|
|
931
955
|
} catch {
|
|
932
|
-
|
|
956
|
+
Te = !1;
|
|
933
957
|
}
|
|
934
|
-
var
|
|
958
|
+
var K = Te ? { passive: !1 } : !1, kn = function(e) {
|
|
935
959
|
return e.tagName === "TEXTAREA";
|
|
936
|
-
},
|
|
960
|
+
}, pt = function(e, n) {
|
|
937
961
|
var t = window.getComputedStyle(e);
|
|
938
962
|
return (
|
|
939
963
|
// not-not-scrollable
|
|
940
964
|
t[n] !== "hidden" && // contains scroll inside self
|
|
941
|
-
!(t.overflowY === t.overflowX && !
|
|
965
|
+
!(t.overflowY === t.overflowX && !kn(e) && t[n] === "visible")
|
|
942
966
|
);
|
|
943
|
-
},
|
|
944
|
-
return
|
|
945
|
-
},
|
|
946
|
-
return
|
|
947
|
-
},
|
|
967
|
+
}, Fn = function(e) {
|
|
968
|
+
return pt(e, "overflowY");
|
|
969
|
+
}, jn = function(e) {
|
|
970
|
+
return pt(e, "overflowX");
|
|
971
|
+
}, Xe = function(e, n) {
|
|
948
972
|
var t = n;
|
|
949
973
|
do {
|
|
950
974
|
typeof ShadowRoot < "u" && t instanceof ShadowRoot && (t = t.host);
|
|
951
|
-
var o =
|
|
975
|
+
var o = ft(e, t);
|
|
952
976
|
if (o) {
|
|
953
|
-
var a =
|
|
977
|
+
var a = vt(e, t), r = a[1], i = a[2];
|
|
954
978
|
if (r > i)
|
|
955
979
|
return !0;
|
|
956
980
|
}
|
|
957
981
|
t = t.parentNode;
|
|
958
982
|
} while (t && t !== document.body);
|
|
959
983
|
return !1;
|
|
960
|
-
},
|
|
984
|
+
}, Bn = function(e) {
|
|
961
985
|
var n = e.scrollTop, t = e.scrollHeight, o = e.clientHeight;
|
|
962
986
|
return [
|
|
963
987
|
n,
|
|
964
988
|
t,
|
|
965
989
|
o
|
|
966
990
|
];
|
|
967
|
-
},
|
|
991
|
+
}, Un = function(e) {
|
|
968
992
|
var n = e.scrollLeft, t = e.scrollWidth, o = e.clientWidth;
|
|
969
993
|
return [
|
|
970
994
|
n,
|
|
971
995
|
t,
|
|
972
996
|
o
|
|
973
997
|
];
|
|
974
|
-
},
|
|
975
|
-
return e === "v" ?
|
|
976
|
-
},
|
|
977
|
-
return e === "v" ?
|
|
978
|
-
},
|
|
998
|
+
}, ft = function(e, n) {
|
|
999
|
+
return e === "v" ? Fn(n) : jn(n);
|
|
1000
|
+
}, vt = function(e, n) {
|
|
1001
|
+
return e === "v" ? Bn(n) : Un(n);
|
|
1002
|
+
}, Wn = function(e, n) {
|
|
979
1003
|
return e === "h" && n === "rtl" ? -1 : 1;
|
|
980
|
-
},
|
|
981
|
-
var r =
|
|
1004
|
+
}, zn = function(e, n, t, o, a) {
|
|
1005
|
+
var r = Wn(e, window.getComputedStyle(n).direction), i = r * o, c = t.target, s = n.contains(c), d = !1, p = i > 0, l = 0, v = 0;
|
|
982
1006
|
do {
|
|
983
|
-
var f =
|
|
984
|
-
(E ||
|
|
1007
|
+
var f = vt(e, c), E = f[0], u = f[1], h = f[2], g = u - h - r * E;
|
|
1008
|
+
(E || g) && ft(e, c) && (l += g, v += E), c = c.parentNode;
|
|
985
1009
|
} while (
|
|
986
1010
|
// portaled content
|
|
987
1011
|
!s && c !== document.body || // self content
|
|
988
1012
|
s && (n.contains(c) || n === c)
|
|
989
1013
|
);
|
|
990
|
-
return (p && (l === 0 || !a) || !p && (
|
|
991
|
-
},
|
|
1014
|
+
return (p && (l === 0 || !a) || !p && (v === 0 || !a)) && (d = !0), d;
|
|
1015
|
+
}, se = function(e) {
|
|
992
1016
|
return "changedTouches" in e ? [e.changedTouches[0].clientX, e.changedTouches[0].clientY] : [0, 0];
|
|
993
|
-
},
|
|
1017
|
+
}, Ge = function(e) {
|
|
994
1018
|
return [e.deltaX, e.deltaY];
|
|
995
|
-
},
|
|
1019
|
+
}, Ye = function(e) {
|
|
996
1020
|
return e && "current" in e ? e.current : e;
|
|
997
|
-
},
|
|
1021
|
+
}, qn = function(e, n) {
|
|
998
1022
|
return e[0] === n[0] && e[1] === n[1];
|
|
999
|
-
},
|
|
1023
|
+
}, Hn = function(e) {
|
|
1000
1024
|
return `
|
|
1001
1025
|
.block-interactivity-`.concat(e, ` {pointer-events: none;}
|
|
1002
1026
|
.allow-interactivity-`).concat(e, ` {pointer-events: all;}
|
|
1003
1027
|
`);
|
|
1004
|
-
},
|
|
1005
|
-
function
|
|
1006
|
-
var n = m.useRef([]), t = m.useRef([0, 0]), o = m.useRef(), a = m.useState(
|
|
1007
|
-
return
|
|
1028
|
+
}, Vn = 0, X = [];
|
|
1029
|
+
function Kn(e) {
|
|
1030
|
+
var n = m.useRef([]), t = m.useRef([0, 0]), o = m.useRef(), a = m.useState(Vn++)[0], r = m.useState(function() {
|
|
1031
|
+
return dt();
|
|
1008
1032
|
})[0], i = m.useRef(e);
|
|
1009
1033
|
m.useEffect(function() {
|
|
1010
1034
|
i.current = e;
|
|
1011
1035
|
}, [e]), m.useEffect(function() {
|
|
1012
1036
|
if (e.inert) {
|
|
1013
1037
|
document.body.classList.add("block-interactivity-".concat(a));
|
|
1014
|
-
var u =
|
|
1015
|
-
return u.forEach(function(
|
|
1016
|
-
return
|
|
1038
|
+
var u = vn([e.lockRef.current], (e.shards || []).map(Ye), !0).filter(Boolean);
|
|
1039
|
+
return u.forEach(function(h) {
|
|
1040
|
+
return h.classList.add("allow-interactivity-".concat(a));
|
|
1017
1041
|
}), function() {
|
|
1018
|
-
document.body.classList.remove("block-interactivity-".concat(a)), u.forEach(function(
|
|
1019
|
-
return
|
|
1042
|
+
document.body.classList.remove("block-interactivity-".concat(a)), u.forEach(function(h) {
|
|
1043
|
+
return h.classList.remove("allow-interactivity-".concat(a));
|
|
1020
1044
|
});
|
|
1021
1045
|
};
|
|
1022
1046
|
}
|
|
1023
1047
|
}, [e.inert, e.lockRef.current, e.shards]);
|
|
1024
|
-
var c = m.useCallback(function(u,
|
|
1048
|
+
var c = m.useCallback(function(u, h) {
|
|
1025
1049
|
if ("touches" in u && u.touches.length === 2)
|
|
1026
1050
|
return !i.current.allowPinchZoom;
|
|
1027
|
-
var
|
|
1051
|
+
var g = se(u), C = t.current, y = "deltaX" in u ? u.deltaX : C[0] - g[0], $ = "deltaY" in u ? u.deltaY : C[1] - g[1], x, z = u.target, D = Math.abs(y) > Math.abs($) ? "h" : "v";
|
|
1028
1052
|
if ("touches" in u && D === "h" && z.type === "range")
|
|
1029
1053
|
return !1;
|
|
1030
|
-
var
|
|
1031
|
-
if (!
|
|
1054
|
+
var w = Xe(D, z);
|
|
1055
|
+
if (!w)
|
|
1032
1056
|
return !0;
|
|
1033
|
-
if (
|
|
1057
|
+
if (w ? x = D : (x = D === "v" ? "h" : "v", w = Xe(D, z)), !w)
|
|
1034
1058
|
return !1;
|
|
1035
|
-
if (!o.current && "changedTouches" in u && (y || $) && (o.current =
|
|
1059
|
+
if (!o.current && "changedTouches" in u && (y || $) && (o.current = x), !x)
|
|
1036
1060
|
return !0;
|
|
1037
|
-
var
|
|
1038
|
-
return
|
|
1061
|
+
var L = o.current || x;
|
|
1062
|
+
return zn(L, h, u, L === "h" ? y : $, !0);
|
|
1039
1063
|
}, []), s = m.useCallback(function(u) {
|
|
1040
|
-
var
|
|
1041
|
-
if (!(!
|
|
1042
|
-
var
|
|
1043
|
-
return
|
|
1064
|
+
var h = u;
|
|
1065
|
+
if (!(!X.length || X[X.length - 1] !== r)) {
|
|
1066
|
+
var g = "deltaY" in h ? Ge(h) : se(h), C = n.current.filter(function(x) {
|
|
1067
|
+
return x.name === h.type && x.target === h.target && qn(x.delta, g);
|
|
1044
1068
|
})[0];
|
|
1045
1069
|
if (C && C.should) {
|
|
1046
|
-
|
|
1070
|
+
h.cancelable && h.preventDefault();
|
|
1047
1071
|
return;
|
|
1048
1072
|
}
|
|
1049
1073
|
if (!C) {
|
|
1050
|
-
var y = (i.current.shards || []).map(
|
|
1051
|
-
return
|
|
1052
|
-
}), $ = y.length > 0 ? c(
|
|
1053
|
-
$ &&
|
|
1074
|
+
var y = (i.current.shards || []).map(Ye).filter(Boolean).filter(function(x) {
|
|
1075
|
+
return x.contains(h.target);
|
|
1076
|
+
}), $ = y.length > 0 ? c(h, y[0]) : !i.current.noIsolation;
|
|
1077
|
+
$ && h.cancelable && h.preventDefault();
|
|
1054
1078
|
}
|
|
1055
1079
|
}
|
|
1056
|
-
}, []), d = m.useCallback(function(u,
|
|
1057
|
-
var y = { name: u, delta:
|
|
1080
|
+
}, []), d = m.useCallback(function(u, h, g, C) {
|
|
1081
|
+
var y = { name: u, delta: h, target: g, should: C };
|
|
1058
1082
|
n.current.push(y), setTimeout(function() {
|
|
1059
1083
|
n.current = n.current.filter(function($) {
|
|
1060
1084
|
return $ !== y;
|
|
1061
1085
|
});
|
|
1062
1086
|
}, 1);
|
|
1063
1087
|
}, []), p = m.useCallback(function(u) {
|
|
1064
|
-
t.current =
|
|
1088
|
+
t.current = se(u), o.current = void 0;
|
|
1065
1089
|
}, []), l = m.useCallback(function(u) {
|
|
1066
|
-
d(u.type,
|
|
1067
|
-
}, []),
|
|
1068
|
-
d(u.type,
|
|
1090
|
+
d(u.type, Ge(u), u.target, c(u, e.lockRef.current));
|
|
1091
|
+
}, []), v = m.useCallback(function(u) {
|
|
1092
|
+
d(u.type, se(u), u.target, c(u, e.lockRef.current));
|
|
1069
1093
|
}, []);
|
|
1070
1094
|
m.useEffect(function() {
|
|
1071
|
-
return
|
|
1095
|
+
return X.push(r), e.setCallbacks({
|
|
1072
1096
|
onScrollCapture: l,
|
|
1073
1097
|
onWheelCapture: l,
|
|
1074
|
-
onTouchMoveCapture:
|
|
1075
|
-
}), document.addEventListener("wheel", s,
|
|
1076
|
-
|
|
1098
|
+
onTouchMoveCapture: v
|
|
1099
|
+
}), document.addEventListener("wheel", s, K), document.addEventListener("touchmove", s, K), document.addEventListener("touchstart", p, K), function() {
|
|
1100
|
+
X = X.filter(function(u) {
|
|
1077
1101
|
return u !== r;
|
|
1078
|
-
}), document.removeEventListener("wheel", s,
|
|
1102
|
+
}), document.removeEventListener("wheel", s, K), document.removeEventListener("touchmove", s, K), document.removeEventListener("touchstart", p, K);
|
|
1079
1103
|
};
|
|
1080
1104
|
}, []);
|
|
1081
1105
|
var f = e.removeScrollBar, E = e.inert;
|
|
1082
1106
|
return m.createElement(
|
|
1083
1107
|
m.Fragment,
|
|
1084
1108
|
null,
|
|
1085
|
-
E ? m.createElement(r, { styles:
|
|
1086
|
-
f ? m.createElement(
|
|
1109
|
+
E ? m.createElement(r, { styles: Hn(a) }) : null,
|
|
1110
|
+
f ? m.createElement(Mn, { gapMode: "margin" }) : null
|
|
1087
1111
|
);
|
|
1088
1112
|
}
|
|
1089
|
-
const
|
|
1090
|
-
var
|
|
1091
|
-
return m.createElement(
|
|
1113
|
+
const Xn = wn(lt, Kn);
|
|
1114
|
+
var ht = m.forwardRef(function(e, n) {
|
|
1115
|
+
return m.createElement(_e, k({}, e, { ref: n, sideCar: Xn }));
|
|
1092
1116
|
});
|
|
1093
|
-
|
|
1094
|
-
var
|
|
1117
|
+
ht.classNames = _e.classNames;
|
|
1118
|
+
var Gn = function(e) {
|
|
1095
1119
|
if (typeof document > "u")
|
|
1096
1120
|
return null;
|
|
1097
1121
|
var n = Array.isArray(e) ? e[0] : e;
|
|
1098
1122
|
return n.ownerDocument.body;
|
|
1099
|
-
},
|
|
1100
|
-
return e && (e.host ||
|
|
1101
|
-
},
|
|
1123
|
+
}, G = /* @__PURE__ */ new WeakMap(), le = /* @__PURE__ */ new WeakMap(), de = {}, Ce = 0, mt = function(e) {
|
|
1124
|
+
return e && (e.host || mt(e.parentNode));
|
|
1125
|
+
}, Yn = function(e, n) {
|
|
1102
1126
|
return n.map(function(t) {
|
|
1103
1127
|
if (e.contains(t))
|
|
1104
1128
|
return t;
|
|
1105
|
-
var o =
|
|
1129
|
+
var o = mt(t);
|
|
1106
1130
|
return o && e.contains(o) ? o : (console.error("aria-hidden", t, "in not contained inside", e, ". Doing nothing"), null);
|
|
1107
1131
|
}).filter(function(t) {
|
|
1108
1132
|
return !!t;
|
|
1109
1133
|
});
|
|
1110
|
-
},
|
|
1111
|
-
var a =
|
|
1112
|
-
|
|
1113
|
-
var r =
|
|
1134
|
+
}, Zn = function(e, n, t, o) {
|
|
1135
|
+
var a = Yn(n, Array.isArray(e) ? e : [e]);
|
|
1136
|
+
de[t] || (de[t] = /* @__PURE__ */ new WeakMap());
|
|
1137
|
+
var r = de[t], i = [], c = /* @__PURE__ */ new Set(), s = new Set(a), d = function(l) {
|
|
1114
1138
|
!l || c.has(l) || (c.add(l), d(l.parentNode));
|
|
1115
1139
|
};
|
|
1116
1140
|
a.forEach(d);
|
|
1117
1141
|
var p = function(l) {
|
|
1118
|
-
!l || s.has(l) || Array.prototype.forEach.call(l.children, function(
|
|
1119
|
-
if (c.has(
|
|
1120
|
-
p(
|
|
1121
|
-
else
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1142
|
+
!l || s.has(l) || Array.prototype.forEach.call(l.children, function(v) {
|
|
1143
|
+
if (c.has(v))
|
|
1144
|
+
p(v);
|
|
1145
|
+
else
|
|
1146
|
+
try {
|
|
1147
|
+
var f = v.getAttribute(o), E = f !== null && f !== "false", u = (G.get(v) || 0) + 1, h = (r.get(v) || 0) + 1;
|
|
1148
|
+
G.set(v, u), r.set(v, h), i.push(v), u === 1 && E && le.set(v, !0), h === 1 && v.setAttribute(t, "true"), E || v.setAttribute(o, "true");
|
|
1149
|
+
} catch (g) {
|
|
1150
|
+
console.error("aria-hidden: cannot operate on ", v, g);
|
|
1151
|
+
}
|
|
1125
1152
|
});
|
|
1126
1153
|
};
|
|
1127
|
-
return p(n), c.clear(),
|
|
1154
|
+
return p(n), c.clear(), Ce++, function() {
|
|
1128
1155
|
i.forEach(function(l) {
|
|
1129
|
-
var
|
|
1130
|
-
|
|
1131
|
-
}),
|
|
1156
|
+
var v = G.get(l) - 1, f = r.get(l) - 1;
|
|
1157
|
+
G.set(l, v), r.set(l, f), v || (le.has(l) || l.removeAttribute(o), le.delete(l)), f || l.removeAttribute(t);
|
|
1158
|
+
}), Ce--, Ce || (G = /* @__PURE__ */ new WeakMap(), G = /* @__PURE__ */ new WeakMap(), le = /* @__PURE__ */ new WeakMap(), de = {});
|
|
1132
1159
|
};
|
|
1133
|
-
},
|
|
1160
|
+
}, Qn = function(e, n, t) {
|
|
1134
1161
|
t === void 0 && (t = "data-aria-hidden");
|
|
1135
|
-
var o = Array.from(Array.isArray(e) ? e : [e]), a =
|
|
1136
|
-
return a ? (o.push.apply(o, Array.from(a.querySelectorAll("[aria-live]"))),
|
|
1162
|
+
var o = Array.from(Array.isArray(e) ? e : [e]), a = Gn(e);
|
|
1163
|
+
return a ? (o.push.apply(o, Array.from(a.querySelectorAll("[aria-live]"))), Zn(o, a, t, "aria-hidden")) : function() {
|
|
1137
1164
|
return null;
|
|
1138
1165
|
};
|
|
1139
1166
|
};
|
|
1140
|
-
const
|
|
1141
|
-
const { __scopeDialog: n, children: t, open: o, defaultOpen: a, onOpenChange: r, modal: i = !0 } = e, c = N(null), s = N(null), [d = !1, p] =
|
|
1167
|
+
const gt = "Dialog", [_t, wo] = Ft(gt), [Jn, M] = _t(gt), er = (e) => {
|
|
1168
|
+
const { __scopeDialog: n, children: t, open: o, defaultOpen: a, onOpenChange: r, modal: i = !0 } = e, c = N(null), s = N(null), [d = !1, p] = Wt({
|
|
1142
1169
|
prop: o,
|
|
1143
1170
|
defaultProp: a,
|
|
1144
1171
|
onChange: r
|
|
1145
1172
|
});
|
|
1146
|
-
return /* @__PURE__ */
|
|
1173
|
+
return /* @__PURE__ */ _(Jn, {
|
|
1147
1174
|
scope: n,
|
|
1148
1175
|
triggerRef: c,
|
|
1149
1176
|
contentRef: s,
|
|
1150
|
-
contentId:
|
|
1151
|
-
titleId:
|
|
1152
|
-
descriptionId:
|
|
1177
|
+
contentId: be(),
|
|
1178
|
+
titleId: be(),
|
|
1179
|
+
descriptionId: be(),
|
|
1153
1180
|
open: d,
|
|
1154
1181
|
onOpenChange: p,
|
|
1155
|
-
onOpenToggle:
|
|
1182
|
+
onOpenToggle: Q(
|
|
1156
1183
|
() => p(
|
|
1157
1184
|
(l) => !l
|
|
1158
1185
|
),
|
|
@@ -1162,54 +1189,54 @@ const ft = "Dialog", [vt, _o] = Lt(ft), [Gn, M] = vt(ft), Vn = (e) => {
|
|
|
1162
1189
|
),
|
|
1163
1190
|
modal: i
|
|
1164
1191
|
}, t);
|
|
1165
|
-
},
|
|
1166
|
-
const { __scopeDialog: t, ...o } = e, a = M(
|
|
1167
|
-
return /* @__PURE__ */
|
|
1192
|
+
}, tr = "DialogTrigger", nr = /* @__PURE__ */ S((e, n) => {
|
|
1193
|
+
const { __scopeDialog: t, ...o } = e, a = M(tr, t), r = J(n, a.triggerRef);
|
|
1194
|
+
return /* @__PURE__ */ _(W.button, P({
|
|
1168
1195
|
type: "button",
|
|
1169
1196
|
"aria-haspopup": "dialog",
|
|
1170
1197
|
"aria-expanded": a.open,
|
|
1171
1198
|
"aria-controls": a.contentId,
|
|
1172
|
-
"data-state":
|
|
1199
|
+
"data-state": Me(a.open)
|
|
1173
1200
|
}, o, {
|
|
1174
1201
|
ref: r,
|
|
1175
1202
|
onClick: B(e.onClick, a.onOpenToggle)
|
|
1176
1203
|
}));
|
|
1177
|
-
}),
|
|
1204
|
+
}), bt = "DialogPortal", [rr, $t] = _t(bt, {
|
|
1178
1205
|
forceMount: void 0
|
|
1179
|
-
}),
|
|
1180
|
-
const { __scopeDialog: n, forceMount: t, children: o, container: a } = e, r = M(
|
|
1181
|
-
return /* @__PURE__ */
|
|
1206
|
+
}), or = (e) => {
|
|
1207
|
+
const { __scopeDialog: n, forceMount: t, children: o, container: a } = e, r = M(bt, n);
|
|
1208
|
+
return /* @__PURE__ */ _(rr, {
|
|
1182
1209
|
scope: n,
|
|
1183
1210
|
forceMount: t
|
|
1184
|
-
},
|
|
1211
|
+
}, I.map(
|
|
1185
1212
|
o,
|
|
1186
|
-
(i) => /* @__PURE__ */
|
|
1213
|
+
(i) => /* @__PURE__ */ _(ge, {
|
|
1187
1214
|
present: t || r.open
|
|
1188
|
-
}, /* @__PURE__ */
|
|
1215
|
+
}, /* @__PURE__ */ _(ln, {
|
|
1189
1216
|
asChild: !0,
|
|
1190
1217
|
container: a
|
|
1191
1218
|
}, i))
|
|
1192
1219
|
));
|
|
1193
|
-
},
|
|
1194
|
-
const t =
|
|
1195
|
-
return r.modal ? /* @__PURE__ */
|
|
1220
|
+
}, De = "DialogOverlay", ar = /* @__PURE__ */ S((e, n) => {
|
|
1221
|
+
const t = $t(De, e.__scopeDialog), { forceMount: o = t.forceMount, ...a } = e, r = M(De, e.__scopeDialog);
|
|
1222
|
+
return r.modal ? /* @__PURE__ */ _(ge, {
|
|
1196
1223
|
present: o || r.open
|
|
1197
|
-
}, /* @__PURE__ */
|
|
1224
|
+
}, /* @__PURE__ */ _(ir, P({}, a, {
|
|
1198
1225
|
ref: n
|
|
1199
1226
|
}))) : null;
|
|
1200
|
-
}),
|
|
1201
|
-
const { __scopeDialog: t, ...o } = e, a = M(
|
|
1227
|
+
}), ir = /* @__PURE__ */ S((e, n) => {
|
|
1228
|
+
const { __scopeDialog: t, ...o } = e, a = M(De, t);
|
|
1202
1229
|
return (
|
|
1203
1230
|
// Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
|
|
1204
1231
|
// ie. when `Overlay` and `Content` are siblings
|
|
1205
|
-
/* @__PURE__ */
|
|
1206
|
-
as:
|
|
1232
|
+
/* @__PURE__ */ _(ht, {
|
|
1233
|
+
as: Re,
|
|
1207
1234
|
allowPinchZoom: !0,
|
|
1208
1235
|
shards: [
|
|
1209
1236
|
a.contentRef
|
|
1210
1237
|
]
|
|
1211
|
-
}, /* @__PURE__ */
|
|
1212
|
-
"data-state":
|
|
1238
|
+
}, /* @__PURE__ */ _(W.div, P({
|
|
1239
|
+
"data-state": Me(a.open)
|
|
1213
1240
|
}, o, {
|
|
1214
1241
|
ref: n,
|
|
1215
1242
|
style: {
|
|
@@ -1218,21 +1245,21 @@ const ft = "Dialog", [vt, _o] = Lt(ft), [Gn, M] = vt(ft), Vn = (e) => {
|
|
|
1218
1245
|
}
|
|
1219
1246
|
})))
|
|
1220
1247
|
);
|
|
1221
|
-
}),
|
|
1222
|
-
const t =
|
|
1223
|
-
return /* @__PURE__ */
|
|
1248
|
+
}), oe = "DialogContent", cr = /* @__PURE__ */ S((e, n) => {
|
|
1249
|
+
const t = $t(oe, e.__scopeDialog), { forceMount: o = t.forceMount, ...a } = e, r = M(oe, e.__scopeDialog);
|
|
1250
|
+
return /* @__PURE__ */ _(ge, {
|
|
1224
1251
|
present: o || r.open
|
|
1225
|
-
}, r.modal ? /* @__PURE__ */
|
|
1252
|
+
}, r.modal ? /* @__PURE__ */ _(ur, P({}, a, {
|
|
1226
1253
|
ref: n
|
|
1227
|
-
})) : /* @__PURE__ */
|
|
1254
|
+
})) : /* @__PURE__ */ _(sr, P({}, a, {
|
|
1228
1255
|
ref: n
|
|
1229
1256
|
})));
|
|
1230
|
-
}),
|
|
1231
|
-
const t = M(
|
|
1257
|
+
}), ur = /* @__PURE__ */ S((e, n) => {
|
|
1258
|
+
const t = M(oe, e.__scopeDialog), o = N(null), a = J(n, t.contentRef, o);
|
|
1232
1259
|
return A(() => {
|
|
1233
1260
|
const r = o.current;
|
|
1234
|
-
if (r) return
|
|
1235
|
-
}, []), /* @__PURE__ */
|
|
1261
|
+
if (r) return Qn(r);
|
|
1262
|
+
}, []), /* @__PURE__ */ _(yt, P({}, e, {
|
|
1236
1263
|
ref: a,
|
|
1237
1264
|
trapFocus: t.open,
|
|
1238
1265
|
disableOutsidePointerEvents: !0,
|
|
@@ -1249,9 +1276,9 @@ const ft = "Dialog", [vt, _o] = Lt(ft), [Gn, M] = vt(ft), Vn = (e) => {
|
|
|
1249
1276
|
(r) => r.preventDefault()
|
|
1250
1277
|
)
|
|
1251
1278
|
}));
|
|
1252
|
-
}),
|
|
1253
|
-
const t = M(
|
|
1254
|
-
return /* @__PURE__ */
|
|
1279
|
+
}), sr = /* @__PURE__ */ S((e, n) => {
|
|
1280
|
+
const t = M(oe, e.__scopeDialog), o = N(!1), a = N(!1);
|
|
1281
|
+
return /* @__PURE__ */ _(yt, P({}, e, {
|
|
1255
1282
|
ref: n,
|
|
1256
1283
|
trapFocus: !1,
|
|
1257
1284
|
disableOutsidePointerEvents: !1,
|
|
@@ -1270,41 +1297,41 @@ const ft = "Dialog", [vt, _o] = Lt(ft), [Gn, M] = vt(ft), Vn = (e) => {
|
|
|
1270
1297
|
((c = t.triggerRef.current) === null || c === void 0 ? void 0 : c.contains(s)) && r.preventDefault(), r.detail.originalEvent.type === "focusin" && a.current && r.preventDefault();
|
|
1271
1298
|
}
|
|
1272
1299
|
}));
|
|
1273
|
-
}),
|
|
1274
|
-
const { __scopeDialog: t, trapFocus: o, onOpenAutoFocus: a, onCloseAutoFocus: r, ...i } = e, c = M(
|
|
1275
|
-
return
|
|
1300
|
+
}), yt = /* @__PURE__ */ S((e, n) => {
|
|
1301
|
+
const { __scopeDialog: t, trapFocus: o, onOpenAutoFocus: a, onCloseAutoFocus: r, ...i } = e, c = M(oe, t), s = N(null), d = J(n, s);
|
|
1302
|
+
return fn(), /* @__PURE__ */ _(Ie, null, /* @__PURE__ */ _(nn, {
|
|
1276
1303
|
asChild: !0,
|
|
1277
1304
|
loop: !0,
|
|
1278
1305
|
trapped: o,
|
|
1279
1306
|
onMountAutoFocus: a,
|
|
1280
1307
|
onUnmountAutoFocus: r
|
|
1281
|
-
}, /* @__PURE__ */
|
|
1308
|
+
}, /* @__PURE__ */ _(Jt, P({
|
|
1282
1309
|
role: "dialog",
|
|
1283
1310
|
id: c.contentId,
|
|
1284
1311
|
"aria-describedby": c.descriptionId,
|
|
1285
1312
|
"aria-labelledby": c.titleId,
|
|
1286
|
-
"data-state":
|
|
1313
|
+
"data-state": Me(c.open)
|
|
1287
1314
|
}, i, {
|
|
1288
1315
|
ref: d,
|
|
1289
1316
|
onDismiss: () => c.onOpenChange(!1)
|
|
1290
1317
|
}))), !1);
|
|
1291
|
-
}),
|
|
1292
|
-
const { __scopeDialog: t, ...o } = e, a = M(
|
|
1293
|
-
return /* @__PURE__ */
|
|
1318
|
+
}), lr = "DialogTitle", dr = /* @__PURE__ */ S((e, n) => {
|
|
1319
|
+
const { __scopeDialog: t, ...o } = e, a = M(lr, t);
|
|
1320
|
+
return /* @__PURE__ */ _(W.h2, P({
|
|
1294
1321
|
id: a.titleId
|
|
1295
1322
|
}, o, {
|
|
1296
1323
|
ref: n
|
|
1297
1324
|
}));
|
|
1298
|
-
}),
|
|
1299
|
-
const { __scopeDialog: t, ...o } = e, a = M(
|
|
1300
|
-
return /* @__PURE__ */
|
|
1325
|
+
}), pr = "DialogDescription", fr = /* @__PURE__ */ S((e, n) => {
|
|
1326
|
+
const { __scopeDialog: t, ...o } = e, a = M(pr, t);
|
|
1327
|
+
return /* @__PURE__ */ _(W.p, P({
|
|
1301
1328
|
id: a.descriptionId
|
|
1302
1329
|
}, o, {
|
|
1303
1330
|
ref: n
|
|
1304
1331
|
}));
|
|
1305
|
-
}),
|
|
1306
|
-
const { __scopeDialog: t, ...o } = e, a = M(
|
|
1307
|
-
return /* @__PURE__ */
|
|
1332
|
+
}), vr = "DialogClose", hr = /* @__PURE__ */ S((e, n) => {
|
|
1333
|
+
const { __scopeDialog: t, ...o } = e, a = M(vr, t);
|
|
1334
|
+
return /* @__PURE__ */ _(W.button, P({
|
|
1308
1335
|
type: "button"
|
|
1309
1336
|
}, o, {
|
|
1310
1337
|
ref: n,
|
|
@@ -1314,18 +1341,18 @@ const ft = "Dialog", [vt, _o] = Lt(ft), [Gn, M] = vt(ft), Vn = (e) => {
|
|
|
1314
1341
|
)
|
|
1315
1342
|
}));
|
|
1316
1343
|
});
|
|
1317
|
-
function
|
|
1344
|
+
function Me(e) {
|
|
1318
1345
|
return e ? "open" : "closed";
|
|
1319
1346
|
}
|
|
1320
|
-
const
|
|
1347
|
+
const mr = er, gr = nr, _r = or, br = ar, $r = cr, yr = dr, Ze = fr, Er = hr, wr = {
|
|
1321
1348
|
SM: "sm",
|
|
1322
1349
|
MD: "md",
|
|
1323
1350
|
LG: "lg"
|
|
1324
1351
|
};
|
|
1325
|
-
function
|
|
1352
|
+
function xr(e) {
|
|
1326
1353
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1327
1354
|
}
|
|
1328
|
-
var
|
|
1355
|
+
var Et = { exports: {} };
|
|
1329
1356
|
/*!
|
|
1330
1357
|
Copyright (c) 2018 Jed Watson.
|
|
1331
1358
|
Licensed under the MIT License (MIT), see
|
|
@@ -1360,44 +1387,44 @@ var _t = { exports: {} };
|
|
|
1360
1387
|
}
|
|
1361
1388
|
e.exports ? (t.default = t, e.exports = t) : window.classNames = t;
|
|
1362
1389
|
})();
|
|
1363
|
-
})(
|
|
1364
|
-
var
|
|
1365
|
-
const
|
|
1390
|
+
})(Et);
|
|
1391
|
+
var Sr = Et.exports;
|
|
1392
|
+
const Qe = /* @__PURE__ */ xr(Sr), Cr = "_rotate_1xozj_1", Or = "_dash_1xozj_1", ee = {
|
|
1366
1393
|
"purpur-spinner": "_purpur-spinner_1xozj_1",
|
|
1367
|
-
rotate:
|
|
1394
|
+
rotate: Cr,
|
|
1368
1395
|
"purpur-spinner--xxs": "_purpur-spinner--xxs_1xozj_4",
|
|
1369
1396
|
"purpur-spinner--xs": "_purpur-spinner--xs_1xozj_8",
|
|
1370
1397
|
"purpur-spinner--sm": "_purpur-spinner--sm_1xozj_12",
|
|
1371
1398
|
"purpur-spinner--md": "_purpur-spinner--md_1xozj_16",
|
|
1372
1399
|
"purpur-spinner--lg": "_purpur-spinner--lg_1xozj_20",
|
|
1373
1400
|
"purpur-spinner__circle": "_purpur-spinner__circle_1xozj_24",
|
|
1374
|
-
dash:
|
|
1401
|
+
dash: Or,
|
|
1375
1402
|
"purpur-spinner__circle--disabled": "_purpur-spinner__circle--disabled_1xozj_33",
|
|
1376
1403
|
"purpur-spinner__circle--negative": "_purpur-spinner__circle--negative_1xozj_36"
|
|
1377
|
-
},
|
|
1404
|
+
}, te = "purpur-spinner", Nr = {
|
|
1378
1405
|
XXS: "xxs",
|
|
1379
1406
|
XS: "xs",
|
|
1380
1407
|
SM: "sm",
|
|
1381
1408
|
MD: "md",
|
|
1382
1409
|
LG: "lg"
|
|
1383
|
-
},
|
|
1410
|
+
}, Pr = ({
|
|
1384
1411
|
["data-testid"]: e,
|
|
1385
1412
|
disabled: n = !1,
|
|
1386
1413
|
negative: t = !1,
|
|
1387
|
-
size: o =
|
|
1414
|
+
size: o = Nr.SM,
|
|
1388
1415
|
...a
|
|
1389
|
-
}) => /* @__PURE__ */
|
|
1416
|
+
}) => /* @__PURE__ */ b(
|
|
1390
1417
|
"div",
|
|
1391
1418
|
{
|
|
1392
|
-
className:
|
|
1419
|
+
className: Qe([ee[te], ee[`${te}--${o}`]]),
|
|
1393
1420
|
"data-testid": e,
|
|
1394
1421
|
...a,
|
|
1395
|
-
children: /* @__PURE__ */
|
|
1422
|
+
children: /* @__PURE__ */ b("svg", { viewBox: "0 0 50 50", children: /* @__PURE__ */ b(
|
|
1396
1423
|
"circle",
|
|
1397
1424
|
{
|
|
1398
|
-
className:
|
|
1399
|
-
[
|
|
1400
|
-
[
|
|
1425
|
+
className: Qe(ee[`${te}__circle`], {
|
|
1426
|
+
[ee[`${te}__circle--disabled`]]: n,
|
|
1427
|
+
[ee[`${te}__circle--negative`]]: t
|
|
1401
1428
|
}),
|
|
1402
1429
|
cx: "25",
|
|
1403
1430
|
cy: "25",
|
|
@@ -1406,10 +1433,10 @@ const Ge = /* @__PURE__ */ br($r), yr = "_rotate_1xozj_1", Er = "_dash_1xozj_1",
|
|
|
1406
1433
|
) })
|
|
1407
1434
|
}
|
|
1408
1435
|
);
|
|
1409
|
-
function
|
|
1436
|
+
function Ar(e) {
|
|
1410
1437
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1411
1438
|
}
|
|
1412
|
-
var
|
|
1439
|
+
var wt = { exports: {} };
|
|
1413
1440
|
/*!
|
|
1414
1441
|
Copyright (c) 2018 Jed Watson.
|
|
1415
1442
|
Licensed under the MIT License (MIT), see
|
|
@@ -1444,9 +1471,9 @@ var bt = { exports: {} };
|
|
|
1444
1471
|
}
|
|
1445
1472
|
e.exports ? (t.default = t, e.exports = t) : window.classNames = t;
|
|
1446
1473
|
})();
|
|
1447
|
-
})(
|
|
1448
|
-
var
|
|
1449
|
-
const
|
|
1474
|
+
})(wt);
|
|
1475
|
+
var Tr = wt.exports;
|
|
1476
|
+
const Dr = /* @__PURE__ */ Ar(Tr), Lr = {
|
|
1450
1477
|
"purpur-button": "_purpur-button_1acxn_1",
|
|
1451
1478
|
"purpur-button--sm": "_purpur-button--sm_1acxn_33",
|
|
1452
1479
|
"purpur-button--icon-only": "_purpur-button--icon-only_1acxn_36",
|
|
@@ -1467,7 +1494,7 @@ const Or = /* @__PURE__ */ Sr(Cr), Nr = {
|
|
|
1467
1494
|
"purpur-button--tertiary-purple-negative": "_purpur-button--tertiary-purple-negative_1acxn_160",
|
|
1468
1495
|
"purpur-button--text-negative": "_purpur-button--text-negative_1acxn_175",
|
|
1469
1496
|
"purpur-button--text": "_purpur-button--text_1acxn_175"
|
|
1470
|
-
},
|
|
1497
|
+
}, Ir = Dr.bind(Lr), q = "purpur-button", Rr = ({
|
|
1471
1498
|
children: e,
|
|
1472
1499
|
className: n,
|
|
1473
1500
|
["data-testid"]: t,
|
|
@@ -1480,11 +1507,11 @@ const Or = /* @__PURE__ */ Sr(Cr), Nr = {
|
|
|
1480
1507
|
size: d = "md",
|
|
1481
1508
|
variant: p,
|
|
1482
1509
|
type: l = "button",
|
|
1483
|
-
...
|
|
1510
|
+
...v
|
|
1484
1511
|
}, f) => {
|
|
1485
1512
|
if (r && p === "destructive")
|
|
1486
1513
|
return null;
|
|
1487
|
-
const E =
|
|
1514
|
+
const E = Ir(
|
|
1488
1515
|
[
|
|
1489
1516
|
q,
|
|
1490
1517
|
`${q}--${c ? `${p}-negative` : p}`,
|
|
@@ -1497,9 +1524,9 @@ const Or = /* @__PURE__ */ Sr(Cr), Nr = {
|
|
|
1497
1524
|
[`${q}--disabled`]: o || i
|
|
1498
1525
|
},
|
|
1499
1526
|
n
|
|
1500
|
-
), u = (
|
|
1501
|
-
o || i ?
|
|
1502
|
-
},
|
|
1527
|
+
), u = (g) => {
|
|
1528
|
+
o || i ? g.preventDefault() : s && s(g);
|
|
1529
|
+
}, h = !!v["aria-disabled"] || o || i;
|
|
1503
1530
|
return /* @__PURE__ */ j(
|
|
1504
1531
|
"button",
|
|
1505
1532
|
{
|
|
@@ -1507,22 +1534,22 @@ const Or = /* @__PURE__ */ Sr(Cr), Nr = {
|
|
|
1507
1534
|
"data-testid": t,
|
|
1508
1535
|
type: l,
|
|
1509
1536
|
ref: f,
|
|
1510
|
-
"aria-disabled":
|
|
1537
|
+
"aria-disabled": h,
|
|
1511
1538
|
onClick: u,
|
|
1512
|
-
...
|
|
1539
|
+
...v,
|
|
1513
1540
|
children: [
|
|
1514
|
-
i && /* @__PURE__ */
|
|
1541
|
+
i && /* @__PURE__ */ b(Pr, { size: d === wr.LG ? "xs" : "xxs", negative: c, disabled: h }),
|
|
1515
1542
|
" ",
|
|
1516
1543
|
e
|
|
1517
1544
|
]
|
|
1518
1545
|
}
|
|
1519
1546
|
);
|
|
1520
|
-
},
|
|
1521
|
-
|
|
1522
|
-
function
|
|
1547
|
+
}, ke = S(Rr);
|
|
1548
|
+
ke.displayName = "Button";
|
|
1549
|
+
function Mr(e) {
|
|
1523
1550
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1524
1551
|
}
|
|
1525
|
-
var
|
|
1552
|
+
var xt = { exports: {} };
|
|
1526
1553
|
/*!
|
|
1527
1554
|
Copyright (c) 2018 Jed Watson.
|
|
1528
1555
|
Licensed under the MIT License (MIT), see
|
|
@@ -1557,9 +1584,9 @@ var $t = { exports: {} };
|
|
|
1557
1584
|
}
|
|
1558
1585
|
e.exports ? (t.default = t, e.exports = t) : window.classNames = t;
|
|
1559
1586
|
})();
|
|
1560
|
-
})(
|
|
1561
|
-
var
|
|
1562
|
-
const
|
|
1587
|
+
})(xt);
|
|
1588
|
+
var kr = xt.exports;
|
|
1589
|
+
const Fr = /* @__PURE__ */ Mr(kr), pe = {
|
|
1563
1590
|
"purpur-heading": "_purpur-heading_k9fhq_1",
|
|
1564
1591
|
"purpur-heading--hyphens": "_purpur-heading--hyphens_k9fhq_8",
|
|
1565
1592
|
"purpur-heading--negative": "_purpur-heading--negative_k9fhq_11",
|
|
@@ -1575,7 +1602,7 @@ const Ir = /* @__PURE__ */ Tr(Dr), de = {
|
|
|
1575
1602
|
"purpur-heading--display-50": "_purpur-heading--display-50_k9fhq_68",
|
|
1576
1603
|
"purpur-heading--display-100": "_purpur-heading--display-100_k9fhq_74",
|
|
1577
1604
|
"purpur-heading--display-200": "_purpur-heading--display-200_k9fhq_80"
|
|
1578
|
-
},
|
|
1605
|
+
}, jr = {
|
|
1579
1606
|
TITLE100: "title-100",
|
|
1580
1607
|
TITLE200: "title-200",
|
|
1581
1608
|
TITLE300: "title-300",
|
|
@@ -1584,32 +1611,32 @@ const Ir = /* @__PURE__ */ Tr(Dr), de = {
|
|
|
1584
1611
|
TITLE600: "title-600",
|
|
1585
1612
|
TITLE700: "title-700",
|
|
1586
1613
|
SUBSECTION100: "subsection-100"
|
|
1587
|
-
},
|
|
1614
|
+
}, fe = "purpur-heading", St = ({
|
|
1588
1615
|
["data-testid"]: e,
|
|
1589
1616
|
children: n,
|
|
1590
1617
|
className: t = "",
|
|
1591
1618
|
enableHyphenation: o = !1,
|
|
1592
1619
|
negative: a = !1,
|
|
1593
1620
|
tag: r,
|
|
1594
|
-
variant: i =
|
|
1621
|
+
variant: i = jr.TITLE100,
|
|
1595
1622
|
...c
|
|
1596
1623
|
}) => {
|
|
1597
|
-
const s = r, d =
|
|
1624
|
+
const s = r, d = Fr([
|
|
1598
1625
|
t,
|
|
1599
|
-
|
|
1600
|
-
|
|
1626
|
+
pe[fe],
|
|
1627
|
+
pe[`${fe}--${i}`],
|
|
1601
1628
|
{
|
|
1602
|
-
[
|
|
1603
|
-
[
|
|
1629
|
+
[pe[`${fe}--hyphens`]]: o,
|
|
1630
|
+
[pe[`${fe}--negative`]]: a
|
|
1604
1631
|
}
|
|
1605
1632
|
]);
|
|
1606
|
-
return /* @__PURE__ */
|
|
1633
|
+
return /* @__PURE__ */ b(s, { ...c, className: d, "data-testid": e, children: n });
|
|
1607
1634
|
};
|
|
1608
|
-
|
|
1609
|
-
function
|
|
1635
|
+
St.displayName = "Heading";
|
|
1636
|
+
function Br(e) {
|
|
1610
1637
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1611
1638
|
}
|
|
1612
|
-
var
|
|
1639
|
+
var Ct = { exports: {} };
|
|
1613
1640
|
/*!
|
|
1614
1641
|
Copyright (c) 2018 Jed Watson.
|
|
1615
1642
|
Licensed under the MIT License (MIT), see
|
|
@@ -1644,9 +1671,9 @@ var Et = { exports: {} };
|
|
|
1644
1671
|
}
|
|
1645
1672
|
e.exports ? (t.default = t, e.exports = t) : window.classNames = t;
|
|
1646
1673
|
})();
|
|
1647
|
-
})(
|
|
1648
|
-
var
|
|
1649
|
-
const
|
|
1674
|
+
})(Ct);
|
|
1675
|
+
var Ur = Ct.exports;
|
|
1676
|
+
const Wr = /* @__PURE__ */ Br(Ur), zr = {
|
|
1650
1677
|
"purpur-icon": "_purpur-icon_8u1lq_1",
|
|
1651
1678
|
"purpur-icon--xxs": "_purpur-icon--xxs_8u1lq_4",
|
|
1652
1679
|
"purpur-icon--xs": "_purpur-icon--xs_8u1lq_8",
|
|
@@ -1654,40 +1681,40 @@ const kr = /* @__PURE__ */ Rr(Mr), Fr = {
|
|
|
1654
1681
|
"purpur-icon--md": "_purpur-icon--md_8u1lq_16",
|
|
1655
1682
|
"purpur-icon--lg": "_purpur-icon--lg_8u1lq_20",
|
|
1656
1683
|
"purpur-icon--xl": "_purpur-icon--xl_8u1lq_24"
|
|
1657
|
-
},
|
|
1684
|
+
}, qr = {
|
|
1658
1685
|
name: "close",
|
|
1659
1686
|
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>',
|
|
1660
1687
|
keywords: ["close"],
|
|
1661
1688
|
category: "utility"
|
|
1662
|
-
},
|
|
1663
|
-
|
|
1689
|
+
}, Ot = (e) => /* @__PURE__ */ b(
|
|
1690
|
+
Yr,
|
|
1664
1691
|
{
|
|
1665
1692
|
...e,
|
|
1666
|
-
svg:
|
|
1693
|
+
svg: qr
|
|
1667
1694
|
}
|
|
1668
1695
|
);
|
|
1669
|
-
|
|
1670
|
-
const
|
|
1696
|
+
Ot.displayName = "IconClose";
|
|
1697
|
+
const Hr = Wr.bind(zr), Je = "purpur-icon", Vr = "md", Kr = (e) => e.filter((n) => Object.keys(n).length >= 1).map((n) => `${n.name}="${n.value}"`).join(" "), Xr = ({ content: e = "", title: n } = {}) => {
|
|
1671
1698
|
const t = [
|
|
1672
1699
|
{ name: "xmlns", value: "http://www.w3.org/2000/svg" },
|
|
1673
1700
|
{ name: "fill", value: "currentColor" },
|
|
1674
1701
|
{ name: "viewBox", value: "0 0 24 24" },
|
|
1675
1702
|
n ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
|
|
1676
1703
|
], o = n ? `<title>${n}</title>` : "";
|
|
1677
|
-
return `<svg ${
|
|
1678
|
-
},
|
|
1704
|
+
return `<svg ${Kr(t)}>${o}${e}</svg>`;
|
|
1705
|
+
}, Gr = (e) => e.replace(/<(\/?)svg([^>]*)>/g, "").trim(), Yr = ({
|
|
1679
1706
|
["data-testid"]: e,
|
|
1680
1707
|
svg: n,
|
|
1681
1708
|
allyTitle: t,
|
|
1682
1709
|
className: o,
|
|
1683
|
-
size: a =
|
|
1710
|
+
size: a = Vr,
|
|
1684
1711
|
...r
|
|
1685
1712
|
}) => {
|
|
1686
|
-
const i =
|
|
1687
|
-
content:
|
|
1713
|
+
const i = Xr({
|
|
1714
|
+
content: Gr(n.svg),
|
|
1688
1715
|
title: t
|
|
1689
|
-
}), c =
|
|
1690
|
-
return /* @__PURE__ */
|
|
1716
|
+
}), c = Hr(o, Je, `${Je}--${a}`);
|
|
1717
|
+
return /* @__PURE__ */ b(
|
|
1691
1718
|
"span",
|
|
1692
1719
|
{
|
|
1693
1720
|
"aria-label": t,
|
|
@@ -1698,10 +1725,10 @@ const Br = kr.bind(Fr), Ve = "purpur-icon", Ur = "md", Wr = (e) => e.filter((n)
|
|
|
1698
1725
|
}
|
|
1699
1726
|
);
|
|
1700
1727
|
};
|
|
1701
|
-
function
|
|
1728
|
+
function Zr(e) {
|
|
1702
1729
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1703
1730
|
}
|
|
1704
|
-
var
|
|
1731
|
+
var Nt = { exports: {} };
|
|
1705
1732
|
/*!
|
|
1706
1733
|
Copyright (c) 2018 Jed Watson.
|
|
1707
1734
|
Licensed under the MIT License (MIT), see
|
|
@@ -1736,9 +1763,9 @@ var wt = { exports: {} };
|
|
|
1736
1763
|
}
|
|
1737
1764
|
e.exports ? (t.default = t, e.exports = t) : window.classNames = t;
|
|
1738
1765
|
})();
|
|
1739
|
-
})(
|
|
1740
|
-
var
|
|
1741
|
-
const
|
|
1766
|
+
})(Nt);
|
|
1767
|
+
var Qr = Nt.exports;
|
|
1768
|
+
const Jr = /* @__PURE__ */ Zr(Qr), ne = {
|
|
1742
1769
|
"purpur-paragraph": "_purpur-paragraph_1rh57_1",
|
|
1743
1770
|
"purpur-paragraph--disabled": "_purpur-paragraph--disabled_1rh57_7",
|
|
1744
1771
|
"purpur-paragraph--hyphens": "_purpur-paragraph--hyphens_1rh57_10",
|
|
@@ -1753,7 +1780,7 @@ const Gr = /* @__PURE__ */ Kr(Xr), te = {
|
|
|
1753
1780
|
"purpur-paragraph--additional-100-medium": "_purpur-paragraph--additional-100-medium_1rh57_60",
|
|
1754
1781
|
"purpur-paragraph--overline-100": "_purpur-paragraph--overline-100_1rh57_67",
|
|
1755
1782
|
"purpur-paragraph--overline-200": "_purpur-paragraph--overline-200_1rh57_75"
|
|
1756
|
-
},
|
|
1783
|
+
}, eo = {
|
|
1757
1784
|
PARAGRAPH100: "paragraph-100",
|
|
1758
1785
|
PARAGRAPH100MEDIUM: "paragraph-100-medium",
|
|
1759
1786
|
PARAGRAPH100BOLD: "paragraph-100-bold",
|
|
@@ -1764,73 +1791,72 @@ const Gr = /* @__PURE__ */ Kr(Xr), te = {
|
|
|
1764
1791
|
ADDITIONAL100MEDIUM: "additional-100-medium",
|
|
1765
1792
|
OVERLINE100: "overline-100",
|
|
1766
1793
|
OVERLINE200: "overline-200"
|
|
1767
|
-
},
|
|
1794
|
+
}, re = "purpur-paragraph", Pt = ({
|
|
1768
1795
|
["data-testid"]: e,
|
|
1769
1796
|
children: n,
|
|
1770
1797
|
className: t,
|
|
1771
1798
|
disabled: o,
|
|
1772
1799
|
enableHyphenation: a = !1,
|
|
1773
1800
|
negative: r = !1,
|
|
1774
|
-
variant: i =
|
|
1801
|
+
variant: i = eo.PARAGRAPH100,
|
|
1775
1802
|
...c
|
|
1776
1803
|
}) => {
|
|
1777
|
-
const s =
|
|
1804
|
+
const s = Jr([
|
|
1778
1805
|
t,
|
|
1779
|
-
|
|
1780
|
-
|
|
1806
|
+
ne[re],
|
|
1807
|
+
ne[`${re}--${i}`],
|
|
1781
1808
|
{
|
|
1782
|
-
[
|
|
1783
|
-
[
|
|
1784
|
-
[
|
|
1809
|
+
[ne[`${re}--hyphens`]]: a,
|
|
1810
|
+
[ne[`${re}--disabled`]]: o,
|
|
1811
|
+
[ne[`${re}--negative`]]: r
|
|
1785
1812
|
}
|
|
1786
1813
|
]);
|
|
1787
|
-
return /* @__PURE__ */
|
|
1814
|
+
return /* @__PURE__ */ b("p", { ...c, className: s, "data-testid": e, children: n });
|
|
1788
1815
|
};
|
|
1789
|
-
|
|
1790
|
-
function
|
|
1791
|
-
return
|
|
1816
|
+
Pt.displayName = "Paragraph";
|
|
1817
|
+
function Z() {
|
|
1818
|
+
return Z = Object.assign ? Object.assign.bind() : function(e) {
|
|
1792
1819
|
for (var n = 1; n < arguments.length; n++) {
|
|
1793
1820
|
var t = arguments[n];
|
|
1794
|
-
for (var o in t)
|
|
1795
|
-
Object.prototype.hasOwnProperty.call(t, o) && (e[o] = t[o]);
|
|
1821
|
+
for (var o in t) ({}).hasOwnProperty.call(t, o) && (e[o] = t[o]);
|
|
1796
1822
|
}
|
|
1797
1823
|
return e;
|
|
1798
|
-
},
|
|
1824
|
+
}, Z.apply(null, arguments);
|
|
1799
1825
|
}
|
|
1800
|
-
function
|
|
1826
|
+
function to(e, n) {
|
|
1801
1827
|
typeof e == "function" ? e(n) : e != null && (e.current = n);
|
|
1802
1828
|
}
|
|
1803
|
-
function
|
|
1829
|
+
function no(...e) {
|
|
1804
1830
|
return (n) => e.forEach(
|
|
1805
|
-
(t) =>
|
|
1831
|
+
(t) => to(t, n)
|
|
1806
1832
|
);
|
|
1807
1833
|
}
|
|
1808
|
-
const
|
|
1809
|
-
const { children: t, ...o } = e, a =
|
|
1834
|
+
const At = /* @__PURE__ */ S((e, n) => {
|
|
1835
|
+
const { children: t, ...o } = e, a = I.toArray(t), r = a.find(oo);
|
|
1810
1836
|
if (r) {
|
|
1811
|
-
const i = r.props.children, c = a.map((s) => s === r ?
|
|
1812
|
-
return /* @__PURE__ */
|
|
1837
|
+
const i = r.props.children, c = a.map((s) => s === r ? I.count(i) > 1 ? I.only(null) : /* @__PURE__ */ U(i) ? i.props.children : null : s);
|
|
1838
|
+
return /* @__PURE__ */ _(Le, Z({}, o, {
|
|
1813
1839
|
ref: n
|
|
1814
|
-
}), /* @__PURE__ */ U(i) ? /* @__PURE__ */
|
|
1840
|
+
}), /* @__PURE__ */ U(i) ? /* @__PURE__ */ ae(i, void 0, c) : null);
|
|
1815
1841
|
}
|
|
1816
|
-
return /* @__PURE__ */
|
|
1842
|
+
return /* @__PURE__ */ _(Le, Z({}, o, {
|
|
1817
1843
|
ref: n
|
|
1818
1844
|
}), t);
|
|
1819
1845
|
});
|
|
1820
|
-
|
|
1821
|
-
const
|
|
1846
|
+
At.displayName = "Slot";
|
|
1847
|
+
const Le = /* @__PURE__ */ S((e, n) => {
|
|
1822
1848
|
const { children: t, ...o } = e;
|
|
1823
|
-
return /* @__PURE__ */ U(t) ? /* @__PURE__ */
|
|
1824
|
-
...
|
|
1825
|
-
ref: n ?
|
|
1826
|
-
}) :
|
|
1849
|
+
return /* @__PURE__ */ U(t) ? /* @__PURE__ */ ae(t, {
|
|
1850
|
+
...ao(o, t.props),
|
|
1851
|
+
ref: n ? no(n, t.ref) : t.ref
|
|
1852
|
+
}) : I.count(t) > 1 ? I.only(null) : null;
|
|
1827
1853
|
});
|
|
1828
|
-
|
|
1829
|
-
const
|
|
1830
|
-
function
|
|
1831
|
-
return /* @__PURE__ */ U(e) && e.type ===
|
|
1854
|
+
Le.displayName = "SlotClone";
|
|
1855
|
+
const ro = ({ children: e }) => /* @__PURE__ */ _(Ie, null, e);
|
|
1856
|
+
function oo(e) {
|
|
1857
|
+
return /* @__PURE__ */ U(e) && e.type === ro;
|
|
1832
1858
|
}
|
|
1833
|
-
function
|
|
1859
|
+
function ao(e, n) {
|
|
1834
1860
|
const t = {
|
|
1835
1861
|
...n
|
|
1836
1862
|
};
|
|
@@ -1851,7 +1877,7 @@ function eo(e, n) {
|
|
|
1851
1877
|
...t
|
|
1852
1878
|
};
|
|
1853
1879
|
}
|
|
1854
|
-
const
|
|
1880
|
+
const io = [
|
|
1855
1881
|
"a",
|
|
1856
1882
|
"button",
|
|
1857
1883
|
"div",
|
|
@@ -1868,12 +1894,12 @@ const to = [
|
|
|
1868
1894
|
"span",
|
|
1869
1895
|
"svg",
|
|
1870
1896
|
"ul"
|
|
1871
|
-
],
|
|
1897
|
+
], co = io.reduce((e, n) => {
|
|
1872
1898
|
const t = /* @__PURE__ */ S((o, a) => {
|
|
1873
|
-
const { asChild: r, ...i } = o, c = r ?
|
|
1899
|
+
const { asChild: r, ...i } = o, c = r ? At : n;
|
|
1874
1900
|
return A(() => {
|
|
1875
1901
|
window[Symbol.for("radix-ui")] = !0;
|
|
1876
|
-
}, []), /* @__PURE__ */
|
|
1902
|
+
}, []), /* @__PURE__ */ _(c, Z({}, i, {
|
|
1877
1903
|
ref: a
|
|
1878
1904
|
}));
|
|
1879
1905
|
});
|
|
@@ -1881,7 +1907,7 @@ const to = [
|
|
|
1881
1907
|
...e,
|
|
1882
1908
|
[n]: t
|
|
1883
1909
|
};
|
|
1884
|
-
}, {}),
|
|
1910
|
+
}, {}), uo = /* @__PURE__ */ S((e, n) => /* @__PURE__ */ _(co.span, Z({}, e, {
|
|
1885
1911
|
ref: n,
|
|
1886
1912
|
style: {
|
|
1887
1913
|
// See: https://github.com/twbs/bootstrap/blob/master/scss/mixins/_screen-reader.scss
|
|
@@ -1897,16 +1923,16 @@ const to = [
|
|
|
1897
1923
|
wordWrap: "normal",
|
|
1898
1924
|
...e.style
|
|
1899
1925
|
}
|
|
1900
|
-
}))),
|
|
1926
|
+
}))), so = uo, lo = ({
|
|
1901
1927
|
asChild: e,
|
|
1902
1928
|
children: n,
|
|
1903
1929
|
className: t = "",
|
|
1904
1930
|
["data-testid"]: o
|
|
1905
|
-
}) => /* @__PURE__ */
|
|
1906
|
-
function
|
|
1931
|
+
}) => /* @__PURE__ */ b(so, { asChild: e, "data-testid": o, className: t, children: n });
|
|
1932
|
+
function po(e) {
|
|
1907
1933
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1908
1934
|
}
|
|
1909
|
-
var
|
|
1935
|
+
var Tt = { exports: {} };
|
|
1910
1936
|
/*!
|
|
1911
1937
|
Copyright (c) 2018 Jed Watson.
|
|
1912
1938
|
Licensed under the MIT License (MIT), see
|
|
@@ -1941,11 +1967,11 @@ var Ot = { exports: {} };
|
|
|
1941
1967
|
}
|
|
1942
1968
|
e.exports ? (t.default = t, e.exports = t) : window.classNames = t;
|
|
1943
1969
|
})();
|
|
1944
|
-
})(
|
|
1945
|
-
var
|
|
1946
|
-
const
|
|
1970
|
+
})(Tt);
|
|
1971
|
+
var fo = Tt.exports;
|
|
1972
|
+
const vo = /* @__PURE__ */ po(fo), ho = "_fadeIn_1ifm3_1", mo = {
|
|
1947
1973
|
"purpur-modal-content": "_purpur-modal-content_1ifm3_1",
|
|
1948
|
-
fadeIn:
|
|
1974
|
+
fadeIn: ho,
|
|
1949
1975
|
"purpur-modal-content__overlay": "_purpur-modal-content__overlay_1ifm3_30",
|
|
1950
1976
|
"purpur-modal-content__close-button": "_purpur-modal-content__close-button_1ifm3_37",
|
|
1951
1977
|
"purpur-modal-content__wrapper": "_purpur-modal-content__wrapper_1ifm3_48",
|
|
@@ -1964,7 +1990,7 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
1964
1990
|
"purpur-modal-content__actions": "_purpur-modal-content__actions_1ifm3_124",
|
|
1965
1991
|
"purpur-modal-content__actions-separator": "_purpur-modal-content__actions-separator_1ifm3_181",
|
|
1966
1992
|
"purpur-modal-content--sticky-footer": "_purpur-modal-content--sticky-footer_1ifm3_191"
|
|
1967
|
-
},
|
|
1993
|
+
}, et = (e) => e.showCloseButton === !0, T = vo.bind(mo), O = "purpur-modal-content", go = S(
|
|
1968
1994
|
({
|
|
1969
1995
|
["data-testid"]: e,
|
|
1970
1996
|
actions: n,
|
|
@@ -1978,73 +2004,73 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
1978
2004
|
stickyButtons: d = !0,
|
|
1979
2005
|
title: p,
|
|
1980
2006
|
notification: l = void 0,
|
|
1981
|
-
zIndex:
|
|
2007
|
+
zIndex: v,
|
|
1982
2008
|
...f
|
|
1983
2009
|
}, E) => {
|
|
1984
|
-
const { closeButtonAllyLabel: u, showCloseButton:
|
|
2010
|
+
const { closeButtonAllyLabel: u, showCloseButton: h, ...g } = f, [C, y] = H(!1), $ = N(null), x = N(null), z = T([
|
|
1985
2011
|
O,
|
|
1986
2012
|
{ [`${O}--with-image`]: !!c },
|
|
1987
2013
|
{ [`${O}--overflow`]: C },
|
|
1988
2014
|
{ [`${O}--sticky-footer`]: d },
|
|
1989
2015
|
o
|
|
1990
|
-
]), D = (R) => e ? `${e} ${R}` : void 0,
|
|
2016
|
+
]), D = (R) => e ? `${e} ${R}` : void 0, w = (R) => {
|
|
1991
2017
|
r && R.preventDefault();
|
|
1992
|
-
},
|
|
1993
|
-
if (!$.current || !
|
|
2018
|
+
}, L = Q(() => {
|
|
2019
|
+
if (!$.current || !x.current)
|
|
1994
2020
|
return;
|
|
1995
|
-
const R = window.getComputedStyle($.current, null),
|
|
1996
|
-
y(
|
|
1997
|
-
}, []),
|
|
1998
|
-
r && !
|
|
2021
|
+
const R = window.getComputedStyle($.current, null), Dt = parseFloat(R.getPropertyValue("height")), Lt = x.current.offsetHeight;
|
|
2022
|
+
y(Dt < Lt);
|
|
2023
|
+
}, []), ie = (R) => {
|
|
2024
|
+
r && !h && R.preventDefault();
|
|
1999
2025
|
};
|
|
2000
|
-
return A(() => (window.addEventListener("resize",
|
|
2001
|
-
window.removeEventListener("resize",
|
|
2002
|
-
}), [
|
|
2003
|
-
|
|
2004
|
-
}, [l,
|
|
2005
|
-
/* @__PURE__ */
|
|
2026
|
+
return A(() => (window.addEventListener("resize", L), () => {
|
|
2027
|
+
window.removeEventListener("resize", L);
|
|
2028
|
+
}), [L]), A(() => {
|
|
2029
|
+
L();
|
|
2030
|
+
}, [l, t, L]), /* @__PURE__ */ j(_r, { children: [
|
|
2031
|
+
/* @__PURE__ */ b(br, { className: T(`${O}__overlay`), style: { zIndex: v } }),
|
|
2006
2032
|
/* @__PURE__ */ j(
|
|
2007
|
-
|
|
2033
|
+
$r,
|
|
2008
2034
|
{
|
|
2009
|
-
...
|
|
2035
|
+
...g,
|
|
2010
2036
|
className: z,
|
|
2011
2037
|
"data-testid": e,
|
|
2012
2038
|
ref: E,
|
|
2013
2039
|
...!a && { "aria-describedby": void 0 },
|
|
2014
|
-
onPointerDownOutside:
|
|
2015
|
-
onOpenAutoFocus:
|
|
2016
|
-
onEscapeKeyDown:
|
|
2017
|
-
style: { zIndex: `calc(${
|
|
2040
|
+
onPointerDownOutside: w,
|
|
2041
|
+
onOpenAutoFocus: L,
|
|
2042
|
+
onEscapeKeyDown: ie,
|
|
2043
|
+
style: { zIndex: `calc(${v} + 1)` },
|
|
2018
2044
|
children: [
|
|
2019
2045
|
/* @__PURE__ */ j("div", { ref: $, className: T(`${O}__wrapper`), children: [
|
|
2020
|
-
|
|
2021
|
-
|
|
2046
|
+
et(f) && u && c && /* @__PURE__ */ b(
|
|
2047
|
+
tt,
|
|
2022
2048
|
{
|
|
2023
2049
|
allyLabel: u,
|
|
2024
2050
|
hasImage: !0,
|
|
2025
2051
|
"data-testid": D("close-button")
|
|
2026
2052
|
}
|
|
2027
2053
|
),
|
|
2028
|
-
/* @__PURE__ */ j("div", { ref:
|
|
2054
|
+
/* @__PURE__ */ j("div", { ref: x, className: T(`${O}__wrapper-inner`), children: [
|
|
2029
2055
|
/* @__PURE__ */ j("div", { className: T(`${O}__header`), children: [
|
|
2030
|
-
|
|
2031
|
-
|
|
2056
|
+
et(f) && u && !c && /* @__PURE__ */ b(
|
|
2057
|
+
tt,
|
|
2032
2058
|
{
|
|
2033
2059
|
allyLabel: u,
|
|
2034
2060
|
"data-testid": D("close-button")
|
|
2035
2061
|
}
|
|
2036
2062
|
),
|
|
2037
|
-
/* @__PURE__ */
|
|
2038
|
-
|
|
2063
|
+
/* @__PURE__ */ b(
|
|
2064
|
+
yr,
|
|
2039
2065
|
{
|
|
2040
2066
|
asChild: !0,
|
|
2041
2067
|
className: T(`${O}__title`),
|
|
2042
2068
|
"data-testid": D("title"),
|
|
2043
|
-
children: /* @__PURE__ */
|
|
2069
|
+
children: /* @__PURE__ */ b(St, { tag: "h2", variant: "title-200", children: p })
|
|
2044
2070
|
}
|
|
2045
2071
|
)
|
|
2046
2072
|
] }),
|
|
2047
|
-
c && /* @__PURE__ */
|
|
2073
|
+
c && /* @__PURE__ */ b(
|
|
2048
2074
|
"div",
|
|
2049
2075
|
{
|
|
2050
2076
|
className: T(`${O}__image-wrapper`),
|
|
@@ -2052,20 +2078,20 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2052
2078
|
children: c
|
|
2053
2079
|
}
|
|
2054
2080
|
),
|
|
2055
|
-
/* @__PURE__ */
|
|
2056
|
-
a && i && /* @__PURE__ */
|
|
2057
|
-
a && !i && /* @__PURE__ */
|
|
2058
|
-
|
|
2081
|
+
/* @__PURE__ */ b("div", { className: T(`${O}__body`), children: /* @__PURE__ */ j("div", { className: T(`${O}__body-inner`), children: [
|
|
2082
|
+
a && i && /* @__PURE__ */ b(lo, { asChild: !0, children: /* @__PURE__ */ b(Ze, { "data-testid": D("description"), children: a }) }),
|
|
2083
|
+
a && !i && /* @__PURE__ */ b(
|
|
2084
|
+
Ze,
|
|
2059
2085
|
{
|
|
2060
2086
|
asChild: !0,
|
|
2061
2087
|
className: T(`${O}__description`),
|
|
2062
2088
|
"data-testid": D("description"),
|
|
2063
|
-
children: /* @__PURE__ */
|
|
2089
|
+
children: /* @__PURE__ */ b(Pt, { variant: "paragraph-100", children: a })
|
|
2064
2090
|
}
|
|
2065
2091
|
),
|
|
2066
|
-
/* @__PURE__ */
|
|
2067
|
-
!d && /* @__PURE__ */
|
|
2068
|
-
|
|
2092
|
+
/* @__PURE__ */ b("div", { children: t }),
|
|
2093
|
+
!d && /* @__PURE__ */ b(
|
|
2094
|
+
nt,
|
|
2069
2095
|
{
|
|
2070
2096
|
actions: n,
|
|
2071
2097
|
primaryActionVariant: s,
|
|
@@ -2075,8 +2101,8 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2075
2101
|
] }) })
|
|
2076
2102
|
] })
|
|
2077
2103
|
] }),
|
|
2078
|
-
d && /* @__PURE__ */
|
|
2079
|
-
|
|
2104
|
+
d && /* @__PURE__ */ b(
|
|
2105
|
+
nt,
|
|
2080
2106
|
{
|
|
2081
2107
|
actions: n,
|
|
2082
2108
|
primaryActionVariant: s,
|
|
@@ -2088,12 +2114,12 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2088
2114
|
)
|
|
2089
2115
|
] });
|
|
2090
2116
|
}
|
|
2091
|
-
),
|
|
2117
|
+
), tt = ({
|
|
2092
2118
|
allyLabel: e,
|
|
2093
2119
|
hasImage: n,
|
|
2094
2120
|
["data-testid"]: t
|
|
2095
|
-
}) => /* @__PURE__ */
|
|
2096
|
-
|
|
2121
|
+
}) => /* @__PURE__ */ b(Er, { asChild: !0, children: /* @__PURE__ */ b(
|
|
2122
|
+
ke,
|
|
2097
2123
|
{
|
|
2098
2124
|
variant: n ? "primary" : "tertiary-purple",
|
|
2099
2125
|
negative: n,
|
|
@@ -2102,9 +2128,9 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2102
2128
|
"aria-label": e,
|
|
2103
2129
|
className: T(`${O}__close-button`),
|
|
2104
2130
|
"data-testid": t,
|
|
2105
|
-
children: /* @__PURE__ */
|
|
2131
|
+
children: /* @__PURE__ */ b(Ot, {})
|
|
2106
2132
|
}
|
|
2107
|
-
) }),
|
|
2133
|
+
) }), _o = 3, nt = ({
|
|
2108
2134
|
actions: e,
|
|
2109
2135
|
primaryActionVariant: n,
|
|
2110
2136
|
notification: t
|
|
@@ -2114,8 +2140,8 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2114
2140
|
var r, i;
|
|
2115
2141
|
t && ((i = (r = o == null ? void 0 : o.current) == null ? void 0 : r.scrollIntoView) == null || i.call(r, !1));
|
|
2116
2142
|
}, [t]), e && e.length > 0 ? /* @__PURE__ */ j("div", { className: T(`${O}__actions`), children: [
|
|
2117
|
-
/* @__PURE__ */
|
|
2118
|
-
|
|
2143
|
+
/* @__PURE__ */ b("div", { className: T(`${O}__actions-buttons`), "data-testid": "modal actions", children: e.slice(0, _o).map(({ label: r, onClick: i, disabled: c, loading: s }, d) => /* @__PURE__ */ b(
|
|
2144
|
+
ke,
|
|
2119
2145
|
{
|
|
2120
2146
|
"data-testid": "modal actions button",
|
|
2121
2147
|
variant: a[d] || "",
|
|
@@ -2127,12 +2153,12 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2127
2153
|
},
|
|
2128
2154
|
r
|
|
2129
2155
|
)) }),
|
|
2130
|
-
t && /* @__PURE__ */
|
|
2131
|
-
/* @__PURE__ */
|
|
2156
|
+
t && /* @__PURE__ */ b("div", { className: T(`${O}__notification`), ref: o, children: t }),
|
|
2157
|
+
/* @__PURE__ */ b("span", { className: T(`${O}__actions-separator`) })
|
|
2132
2158
|
] }) : null;
|
|
2133
|
-
},
|
|
2134
|
-
({ ["data-testid"]: e, children: n, className: t, ...o }, a) => /* @__PURE__ */
|
|
2135
|
-
|
|
2159
|
+
}, bo = S(
|
|
2160
|
+
({ ["data-testid"]: e, children: n, className: t, ...o }, a) => /* @__PURE__ */ b(
|
|
2161
|
+
gr,
|
|
2136
2162
|
{
|
|
2137
2163
|
asChild: !0,
|
|
2138
2164
|
ref: a,
|
|
@@ -2142,16 +2168,16 @@ const uo = /* @__PURE__ */ io(co), so = "_fadeIn_1ifm3_1", lo = {
|
|
|
2142
2168
|
children: n
|
|
2143
2169
|
}
|
|
2144
2170
|
)
|
|
2145
|
-
),
|
|
2171
|
+
), Fe = ({
|
|
2146
2172
|
["data-testid"]: e,
|
|
2147
2173
|
children: n,
|
|
2148
2174
|
open: t,
|
|
2149
2175
|
onOpenChange: o
|
|
2150
|
-
}) => /* @__PURE__ */
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2176
|
+
}) => /* @__PURE__ */ b(mr, { open: t, onOpenChange: o, "data-testid": e, children: n });
|
|
2177
|
+
Fe.Trigger = bo;
|
|
2178
|
+
Fe.Content = go;
|
|
2179
|
+
Fe.displayName = "Modal";
|
|
2154
2180
|
export {
|
|
2155
|
-
|
|
2181
|
+
Fe as Modal
|
|
2156
2182
|
};
|
|
2157
2183
|
//# sourceMappingURL=modal.es.js.map
|