pdap-design-system 2.7.0-beta.5 → 2.7.0-beta.6
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/components/Dropdown/types.d.ts +1 -0
- package/dist/index.cjs +2 -2
- package/dist/index.js +225 -224
- package/package.json +1 -1
package/dist/index.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import { defineComponent as C, reactive as
|
1
|
+
import { defineComponent as C, reactive as B, openBlock as y, createElementBlock as h, normalizeClass as ee, renderSlot as J, ref as N, onErrorCaptured as ut, createBlock as E, resolveDynamicComponent as it, withCtx as T, createElementVNode as f, createTextVNode as D, inject as ae, resolveComponent as Ue, Fragment as W, renderList as le, unref as L, toDisplayString as z, createCommentVNode as k, getCurrentInstance as lt, onBeforeMount as Ve, watch as X, isRef as pe, onBeforeUnmount as fe, computed as v, isReactive as ct, isReadonly as dt, provide as De, nextTick as se, mergeProps as F, normalizeProps as Lt, watchEffect as Te, withModifiers as je, normalizeStyle as Mt, onMounted as Be, createVNode as U, withDirectives as Ce, withKeys as xe, toHandlers as gt, Transition as ye, vShow as pt, TransitionGroup as jt } from "vue";
|
2
2
|
import { RouterLink as oe, useRouter as yt, useRoute as mt } from "vue-router";
|
3
3
|
const ft = {
|
4
4
|
name: "PdapButton"
|
@@ -9,12 +9,12 @@ const ft = {
|
|
9
9
|
isLoading: { type: Boolean, default: !1 }
|
10
10
|
},
|
11
11
|
setup(e) {
|
12
|
-
const t = e, r =
|
12
|
+
const t = e, r = B({
|
13
13
|
"pdap-button": !0,
|
14
14
|
[`pdap-button-${t.intent}`]: !!t.intent,
|
15
15
|
"pdap-button-loading": t.isLoading
|
16
16
|
});
|
17
|
-
return (n, a) => (
|
17
|
+
return (n, a) => (y(), h("button", {
|
18
18
|
class: ee(r)
|
19
19
|
}, [
|
20
20
|
J(n.$slots, "default")
|
@@ -46,7 +46,7 @@ const wt = /* @__PURE__ */ f("h1", null, "Oops, something went wrong!", -1), ht
|
|
46
46
|
}
|
47
47
|
return ut((u, l, c) => {
|
48
48
|
i(u, l, c);
|
49
|
-
}), (u, l) => a.value ? (
|
49
|
+
}), (u, l) => a.value ? (y(), E(it(u.component), {
|
50
50
|
key: 1,
|
51
51
|
class: "pdap-flex-container-center h-[full]",
|
52
52
|
"v-bind": u.params
|
@@ -105,21 +105,21 @@ const wt = /* @__PURE__ */ f("h1", null, "Oops, something went wrong!", -1), ht
|
|
105
105
|
]), n = t.logoImageAnchorPath.startsWith("/");
|
106
106
|
return (a, s) => {
|
107
107
|
const i = Ue("router-link");
|
108
|
-
return
|
108
|
+
return y(), h("footer", Nt, [
|
109
109
|
f("div", Dt, [
|
110
110
|
f("ul", Tt, [
|
111
|
-
(
|
111
|
+
(y(!0), h(W, null, le(L(r), (u) => (y(), h("li", {
|
112
112
|
key: u.text,
|
113
113
|
class: "pdap-footer-link-container"
|
114
114
|
}, [
|
115
|
-
u.href ? (
|
115
|
+
u.href ? (y(), h("a", {
|
116
116
|
key: 0,
|
117
117
|
class: "pdap-footer-social-link",
|
118
118
|
href: u.href,
|
119
119
|
target: "_blank",
|
120
120
|
referrerpolicy: "no-referrer"
|
121
|
-
}, z(u.text), 9, Ct)) :
|
122
|
-
u.path ? (
|
121
|
+
}, z(u.text), 9, Ct)) : k("", !0),
|
122
|
+
u.path ? (y(), E(i, {
|
123
123
|
key: 1,
|
124
124
|
"active-class": "pdap-footer-social-link-current",
|
125
125
|
"exact-active-class": "pdap-footer-social-link-current-exact",
|
@@ -130,7 +130,7 @@ const wt = /* @__PURE__ */ f("h1", null, "Oops, something went wrong!", -1), ht
|
|
130
130
|
D(z(u.text), 1)
|
131
131
|
]),
|
132
132
|
_: 2
|
133
|
-
}, 1032, ["to"])) :
|
133
|
+
}, 1032, ["to"])) : k("", !0)
|
134
134
|
]))), 128))
|
135
135
|
]),
|
136
136
|
f("p", xt, [
|
@@ -140,7 +140,7 @@ const wt = /* @__PURE__ */ f("h1", null, "Oops, something went wrong!", -1), ht
|
|
140
140
|
St,
|
141
141
|
f("div", Et, [
|
142
142
|
zt,
|
143
|
-
L(n) ? (
|
143
|
+
L(n) ? (y(), E(i, {
|
144
144
|
key: 1,
|
145
145
|
to: a.logoImageAnchorPath,
|
146
146
|
class: "pdap-footer-logo"
|
@@ -154,7 +154,7 @@ const wt = /* @__PURE__ */ f("h1", null, "Oops, something went wrong!", -1), ht
|
|
154
154
|
}, null, 8, bt)
|
155
155
|
]),
|
156
156
|
_: 1
|
157
|
-
}, 8, ["to"])) : (
|
157
|
+
}, 8, ["to"])) : (y(), h("a", {
|
158
158
|
key: 0,
|
159
159
|
href: a.logoImageAnchorPath,
|
160
160
|
class: "pdap-footer-logo"
|
@@ -182,7 +182,7 @@ function Ie(e, t) {
|
|
182
182
|
}
|
183
183
|
return r;
|
184
184
|
}
|
185
|
-
function
|
185
|
+
function A(e) {
|
186
186
|
for (var t = 1; t < arguments.length; t++) {
|
187
187
|
var r = arguments[t] != null ? arguments[t] : {};
|
188
188
|
t % 2 ? Ie(Object(r), !0).forEach(function(n) {
|
@@ -244,11 +244,11 @@ function Yt(e, t, r, n, a, s, i) {
|
|
244
244
|
let {
|
245
245
|
$lazy: u,
|
246
246
|
$rewardEarly: l
|
247
|
-
} = a, c = arguments.length > 7 && arguments[7] !== void 0 ? arguments[7] : [], M = arguments.length > 8 ? arguments[8] : void 0,
|
247
|
+
} = a, c = arguments.length > 7 && arguments[7] !== void 0 ? arguments[7] : [], M = arguments.length > 8 ? arguments[8] : void 0, j = arguments.length > 9 ? arguments[9] : void 0, m = arguments.length > 10 ? arguments[10] : void 0;
|
248
248
|
const p = N(!!n.value), o = N(0);
|
249
249
|
r.value = !1;
|
250
|
-
const d = X([t, n].concat(c,
|
251
|
-
if (u && !n.value || l && !
|
250
|
+
const d = X([t, n].concat(c, m), () => {
|
251
|
+
if (u && !n.value || l && !j.value && !r.value)
|
252
252
|
return;
|
253
253
|
let g;
|
254
254
|
try {
|
@@ -275,47 +275,47 @@ function Qt(e, t, r, n, a, s, i, u) {
|
|
275
275
|
$lazy: l,
|
276
276
|
$rewardEarly: c
|
277
277
|
} = n;
|
278
|
-
const M = () => ({}),
|
278
|
+
const M = () => ({}), j = v(() => {
|
279
279
|
if (l && !r.value || c && !u.value)
|
280
280
|
return !1;
|
281
|
-
let
|
281
|
+
let m = !0;
|
282
282
|
try {
|
283
283
|
const p = Ge(e, t, i, s);
|
284
|
-
a.value = p,
|
284
|
+
a.value = p, m = Ze(p);
|
285
285
|
} catch (p) {
|
286
286
|
a.value = p;
|
287
287
|
}
|
288
|
-
return
|
288
|
+
return m;
|
289
289
|
});
|
290
290
|
return {
|
291
291
|
$unwatch: M,
|
292
|
-
$invalid:
|
292
|
+
$invalid: j
|
293
293
|
};
|
294
294
|
}
|
295
295
|
function Rt(e, t, r, n, a, s, i, u, l, c, M) {
|
296
|
-
const
|
296
|
+
const j = N(!1), m = e.$params || {}, p = N(null);
|
297
297
|
let o, d;
|
298
298
|
e.$async ? {
|
299
299
|
$invalid: o,
|
300
300
|
$unwatch: d
|
301
|
-
} = Yt(e.$validator, t,
|
301
|
+
} = Yt(e.$validator, t, j, r, n, p, a, e.$watchTargets, l, c, M) : {
|
302
302
|
$invalid: o,
|
303
303
|
$unwatch: d
|
304
304
|
} = Qt(e.$validator, t, r, n, p, a, l, c);
|
305
305
|
const g = e.$message;
|
306
306
|
return {
|
307
307
|
$message: ue(g) ? v(() => g(Se({
|
308
|
-
$pending:
|
308
|
+
$pending: j,
|
309
309
|
$invalid: o,
|
310
|
-
$params: Se(
|
310
|
+
$params: Se(m),
|
311
311
|
$model: t,
|
312
312
|
$response: p,
|
313
313
|
$validator: s,
|
314
314
|
$propertyPath: u,
|
315
315
|
$property: i
|
316
316
|
}))) : g || "",
|
317
|
-
$params:
|
318
|
-
$pending:
|
317
|
+
$params: m,
|
318
|
+
$pending: j,
|
319
319
|
$invalid: o,
|
320
320
|
$response: p,
|
321
321
|
$unwatch: d
|
@@ -354,26 +354,26 @@ function Ut() {
|
|
354
354
|
}
|
355
355
|
const Vt = "__root";
|
356
356
|
function Bt(e, t, r, n, a, s, i, u, l) {
|
357
|
-
const c = Object.keys(e), M = n.get(a, e),
|
357
|
+
const c = Object.keys(e), M = n.get(a, e), j = N(!1), m = N(!1), p = N(0);
|
358
358
|
if (M) {
|
359
359
|
if (!M.$partial)
|
360
360
|
return M;
|
361
|
-
M.$unwatch(),
|
361
|
+
M.$unwatch(), j.value = M.$dirty.value;
|
362
362
|
}
|
363
363
|
const o = {
|
364
|
-
$dirty:
|
364
|
+
$dirty: j,
|
365
365
|
$path: a,
|
366
366
|
$touch: () => {
|
367
|
-
|
367
|
+
j.value || (j.value = !0);
|
368
368
|
},
|
369
369
|
$reset: () => {
|
370
|
-
|
370
|
+
j.value && (j.value = !1);
|
371
371
|
},
|
372
372
|
$commit: () => {
|
373
373
|
}
|
374
374
|
};
|
375
375
|
return c.length ? (c.forEach((d) => {
|
376
|
-
o[d] = Rt(e[d], t, o.$dirty, s, i, d, r, a, l,
|
376
|
+
o[d] = Rt(e[d], t, o.$dirty, s, i, d, r, a, l, m, p);
|
377
377
|
}), o.$externalResults = v(() => u.value ? [].concat(u.value).map((d, g) => ({
|
378
378
|
$propertyPath: a,
|
379
379
|
$property: r,
|
@@ -385,10 +385,10 @@ function Bt(e, t, r, n, a, s, i, u, l) {
|
|
385
385
|
$pending: !1
|
386
386
|
})) : []), o.$invalid = v(() => {
|
387
387
|
const d = c.some((g) => L(o[g].$invalid));
|
388
|
-
return
|
388
|
+
return m.value = d, !!o.$externalResults.value.length || d;
|
389
389
|
}), o.$pending = v(() => c.some((d) => L(o[d].$pending))), o.$error = v(() => o.$dirty.value ? o.$pending.value || o.$invalid.value : !1), o.$silentErrors = v(() => c.filter((d) => L(o[d].$invalid)).map((d) => {
|
390
390
|
const g = o[d];
|
391
|
-
return
|
391
|
+
return B({
|
392
392
|
$propertyPath: a,
|
393
393
|
$property: r,
|
394
394
|
$validator: d,
|
@@ -401,7 +401,7 @@ function Bt(e, t, r, n, a, s, i, u, l) {
|
|
401
401
|
}).concat(o.$externalResults.value)), o.$errors = v(() => o.$dirty.value ? o.$silentErrors.value : []), o.$unwatch = () => c.forEach((d) => {
|
402
402
|
o[d].$unwatch();
|
403
403
|
}), o.$commit = () => {
|
404
|
-
|
404
|
+
m.value = !0, p.value = Date.now();
|
405
405
|
}, n.set(a, e, o), o) : (M && n.set(a, e, o), o);
|
406
406
|
}
|
407
407
|
function Wt(e, t, r, n, a, s, i) {
|
@@ -431,11 +431,11 @@ function Ft(e, t, r) {
|
|
431
431
|
}), i = v(() => {
|
432
432
|
const o = L(e.$errors) || [], d = n.value.filter((g) => (L(g).$errors || []).length).reduce((g, w) => g.concat(...w.$errors), []);
|
433
433
|
return o.concat(d);
|
434
|
-
}), u = v(() => n.value.some((o) => o.$invalid) || L(e.$invalid) || !1), l = v(() => n.value.some((o) => L(o.$pending)) || L(e.$pending) || !1), c = v(() => n.value.some((o) => o.$dirty) || n.value.some((o) => o.$anyDirty) || a.value), M = v(() => a.value ? l.value || u.value : !1),
|
434
|
+
}), u = v(() => n.value.some((o) => o.$invalid) || L(e.$invalid) || !1), l = v(() => n.value.some((o) => L(o.$pending)) || L(e.$pending) || !1), c = v(() => n.value.some((o) => o.$dirty) || n.value.some((o) => o.$anyDirty) || a.value), M = v(() => a.value ? l.value || u.value : !1), j = () => {
|
435
435
|
e.$touch(), n.value.forEach((o) => {
|
436
436
|
o.$touch();
|
437
437
|
});
|
438
|
-
},
|
438
|
+
}, m = () => {
|
439
439
|
e.$commit(), n.value.forEach((o) => {
|
440
440
|
o.$commit();
|
441
441
|
});
|
@@ -444,17 +444,17 @@ function Ft(e, t, r) {
|
|
444
444
|
o.$reset();
|
445
445
|
});
|
446
446
|
};
|
447
|
-
return n.value.length && n.value.every((o) => o.$dirty) &&
|
447
|
+
return n.value.length && n.value.every((o) => o.$dirty) && j(), {
|
448
448
|
$dirty: a,
|
449
449
|
$errors: i,
|
450
450
|
$invalid: u,
|
451
451
|
$anyDirty: c,
|
452
452
|
$error: M,
|
453
453
|
$pending: l,
|
454
|
-
$touch:
|
454
|
+
$touch: j,
|
455
455
|
$reset: p,
|
456
456
|
$silentErrors: s,
|
457
|
-
$commit:
|
457
|
+
$commit: m
|
458
458
|
};
|
459
459
|
}
|
460
460
|
function me(e) {
|
@@ -470,29 +470,29 @@ function me(e) {
|
|
470
470
|
externalResults: c
|
471
471
|
} = e;
|
472
472
|
const M = a ? `${a}.${n}` : n, {
|
473
|
-
rules:
|
474
|
-
nestedValidators:
|
473
|
+
rules: j,
|
474
|
+
nestedValidators: m,
|
475
475
|
config: p,
|
476
476
|
validationGroups: o
|
477
|
-
} = Ut(t), d =
|
477
|
+
} = Ut(t), d = A(A({}, u), p), g = n ? v(() => {
|
478
478
|
const $ = L(r);
|
479
479
|
return $ ? L($[n]) : void 0;
|
480
|
-
}) : r, w =
|
480
|
+
}) : r, w = A({}, L(c) || {}), I = v(() => {
|
481
481
|
const $ = L(c);
|
482
482
|
return n ? $ ? L($[n]) : void 0 : $;
|
483
|
-
}),
|
483
|
+
}), H = Bt(j, g, n, i, M, d, l, I, r), S = Wt(m, g, M, i, d, l, I), Q = {};
|
484
484
|
o && Object.entries(o).forEach(($) => {
|
485
|
-
let [
|
486
|
-
R
|
487
|
-
$invalid: ge(
|
488
|
-
$error: ge(
|
489
|
-
$pending: ge(
|
490
|
-
$errors: Ee(
|
491
|
-
$silentErrors: Ee(
|
485
|
+
let [R, b] = $;
|
486
|
+
Q[R] = {
|
487
|
+
$invalid: ge(b, S, "$invalid"),
|
488
|
+
$error: ge(b, S, "$error"),
|
489
|
+
$pending: ge(b, S, "$pending"),
|
490
|
+
$errors: Ee(b, S, "$errors"),
|
491
|
+
$silentErrors: Ee(b, S, "$silentErrors")
|
492
492
|
};
|
493
493
|
});
|
494
494
|
const {
|
495
|
-
$dirty:
|
495
|
+
$dirty: _,
|
496
496
|
$errors: te,
|
497
497
|
$invalid: de,
|
498
498
|
$anyDirty: qe,
|
@@ -502,16 +502,16 @@ function me(e) {
|
|
502
502
|
$reset: tt,
|
503
503
|
$silentErrors: rt,
|
504
504
|
$commit: Ne
|
505
|
-
} = Ft(
|
505
|
+
} = Ft(H, S, s), nt = n ? v({
|
506
506
|
get: () => L(g),
|
507
507
|
set: ($) => {
|
508
|
-
|
509
|
-
const
|
510
|
-
|
508
|
+
_.value = !0;
|
509
|
+
const R = L(r), b = L(c);
|
510
|
+
b && (b[n] = w[n]), pe(R[n]) ? R[n].value = $ : R[n] = $;
|
511
511
|
}
|
512
512
|
}) : null;
|
513
513
|
n && d.$autoDirty && X(g, () => {
|
514
|
-
|
514
|
+
_.value || Me();
|
515
515
|
const $ = L(c);
|
516
516
|
$ && ($[n] = w[n]);
|
517
517
|
}, {
|
@@ -521,8 +521,8 @@ function me(e) {
|
|
521
521
|
return Me(), d.$rewardEarly && (Ne(), await se()), await se(), new Promise(($) => {
|
522
522
|
if (!Le.value)
|
523
523
|
return $(!de.value);
|
524
|
-
const
|
525
|
-
$(!de.value),
|
524
|
+
const R = X(Le, () => {
|
525
|
+
$(!de.value), R();
|
526
526
|
});
|
527
527
|
});
|
528
528
|
}
|
@@ -534,9 +534,9 @@ function me(e) {
|
|
534
534
|
delete c[$];
|
535
535
|
}) : Object.assign(c, w);
|
536
536
|
}
|
537
|
-
return
|
537
|
+
return B(A(A(A({}, H), {}, {
|
538
538
|
$model: nt,
|
539
|
-
$dirty:
|
539
|
+
$dirty: _,
|
540
540
|
$error: et,
|
541
541
|
$errors: te,
|
542
542
|
$invalid: de,
|
@@ -551,7 +551,7 @@ function me(e) {
|
|
551
551
|
}, s && {
|
552
552
|
$getResultsForChild: st,
|
553
553
|
$clearExternalResults: ot,
|
554
|
-
$validationGroups:
|
554
|
+
$validationGroups: Q
|
555
555
|
}), S));
|
556
556
|
}
|
557
557
|
class Gt {
|
@@ -592,18 +592,18 @@ function Zt(e) {
|
|
592
592
|
$scope: t,
|
593
593
|
instance: r
|
594
594
|
} = e;
|
595
|
-
const n = {}, a = N([]), s = v(() => a.value.reduce((M,
|
596
|
-
function i(M,
|
595
|
+
const n = {}, a = N([]), s = v(() => a.value.reduce((M, j) => (M[j] = L(n[j]), M), {}));
|
596
|
+
function i(M, j) {
|
597
597
|
let {
|
598
|
-
$registerAs:
|
598
|
+
$registerAs: m,
|
599
599
|
$scope: p,
|
600
600
|
$stopPropagation: o
|
601
|
-
} =
|
602
|
-
o || t === re.COLLECT_NONE || p === re.COLLECT_NONE || t !== re.COLLECT_ALL && t !== p || (n[
|
601
|
+
} = j;
|
602
|
+
o || t === re.COLLECT_NONE || p === re.COLLECT_NONE || t !== re.COLLECT_ALL && t !== p || (n[m] = M, a.value.push(m));
|
603
603
|
}
|
604
604
|
r.__vuelidateInjectInstances = [].concat(r.__vuelidateInjectInstances || [], i);
|
605
605
|
function u(M) {
|
606
|
-
a.value = a.value.filter((
|
606
|
+
a.value = a.value.filter((j) => j !== M), delete n[M];
|
607
607
|
}
|
608
608
|
r.__vuelidateRemoveInstances = [].concat(r.__vuelidateRemoveInstances || [], u);
|
609
609
|
const l = ae(ze, []);
|
@@ -636,7 +636,7 @@ function Ht(e, t) {
|
|
636
636
|
} = n;
|
637
637
|
const c = l || ((r = lt()) === null || r === void 0 ? void 0 : r.proxy), M = c ? c.$options : {};
|
638
638
|
a || (_e += 1, a = `_vuelidate_${_e}`);
|
639
|
-
const
|
639
|
+
const j = N({}), m = new Gt(), {
|
640
640
|
childResults: p,
|
641
641
|
sendValidationResultsToParent: o,
|
642
642
|
removeValidationResultsFromParent: d
|
@@ -650,11 +650,11 @@ function Ht(e, t) {
|
|
650
650
|
const g = M.validations;
|
651
651
|
t = N({}), Ve(() => {
|
652
652
|
t.value = c, X(() => ue(g) ? g.call(t.value, new He(t.value)) : g, (w) => {
|
653
|
-
|
653
|
+
j.value = me({
|
654
654
|
validations: w,
|
655
655
|
state: t,
|
656
656
|
childResults: p,
|
657
|
-
resultsCache:
|
657
|
+
resultsCache: m,
|
658
658
|
globalConfig: n,
|
659
659
|
instance: c,
|
660
660
|
externalResults: u || c.vuelidateExternalResults
|
@@ -664,13 +664,13 @@ function Ht(e, t) {
|
|
664
664
|
});
|
665
665
|
}), n = M.validationsConfig || n;
|
666
666
|
} else {
|
667
|
-
const g = pe(e) || Pt(e) ? e :
|
667
|
+
const g = pe(e) || Pt(e) ? e : B(e || {});
|
668
668
|
X(g, (w) => {
|
669
|
-
|
669
|
+
j.value = me({
|
670
670
|
validations: w,
|
671
671
|
state: t,
|
672
672
|
childResults: p,
|
673
|
-
resultsCache:
|
673
|
+
resultsCache: m,
|
674
674
|
globalConfig: n,
|
675
675
|
instance: c ?? {},
|
676
676
|
externalResults: u
|
@@ -679,11 +679,11 @@ function Ht(e, t) {
|
|
679
679
|
immediate: !0
|
680
680
|
});
|
681
681
|
}
|
682
|
-
return c && (o.forEach((g) => g(
|
682
|
+
return c && (o.forEach((g) => g(j, {
|
683
683
|
$registerAs: a,
|
684
684
|
$scope: s,
|
685
685
|
$stopPropagation: i
|
686
|
-
})), fe(() => d.forEach((g) => g(a)))), v(() =>
|
686
|
+
})), fe(() => d.forEach((g) => g(a)))), v(() => A(A({}, L(j.value)), p.value));
|
687
687
|
}
|
688
688
|
var O = /* @__PURE__ */ ((e) => (e.CHECKBOX = "checkbox", e.TEXT = "text", e.PASSWORD = "password", e))(O || {});
|
689
689
|
const Jt = ["id", "type", "name", "placeholder", "value"], Xt = /* @__PURE__ */ C({
|
@@ -704,7 +704,7 @@ const Jt = ["id", "type", "name", "placeholder", "value"], Xt = /* @__PURE__ */
|
|
704
704
|
}, a = (s) => {
|
705
705
|
r("input", s);
|
706
706
|
};
|
707
|
-
return (s, i) => (
|
707
|
+
return (s, i) => (y(), h("input", F({
|
708
708
|
id: s.id,
|
709
709
|
type: s.type,
|
710
710
|
name: s.name,
|
@@ -732,7 +732,7 @@ const Jt = ["id", "type", "name", "placeholder", "value"], Xt = /* @__PURE__ */
|
|
732
732
|
const r = t, n = (a) => {
|
733
733
|
r("change", a);
|
734
734
|
};
|
735
|
-
return (a, s) => (
|
735
|
+
return (a, s) => (y(), h("input", F({
|
736
736
|
id: a.id,
|
737
737
|
name: a.name,
|
738
738
|
checked: a.value === "true",
|
@@ -757,7 +757,7 @@ const Jt = ["id", "type", "name", "placeholder", "value"], Xt = /* @__PURE__ */
|
|
757
757
|
const t = e, r = v(() => `pdap-${t.name}-input-error`);
|
758
758
|
return (n, a) => {
|
759
759
|
var s;
|
760
|
-
return
|
760
|
+
return y(), h("div", {
|
761
761
|
class: ee({
|
762
762
|
"pdap-input": !0,
|
763
763
|
[`pdap-input-${n.type}`]: !0,
|
@@ -765,15 +765,15 @@ const Jt = ["id", "type", "name", "placeholder", "value"], Xt = /* @__PURE__ */
|
|
765
765
|
"pdap-input-error": Number((s = n.error) == null ? void 0 : s.length) >= 1
|
766
766
|
})
|
767
767
|
}, [
|
768
|
-
n.type === L(O).CHECKBOX ? (
|
768
|
+
n.type === L(O).CHECKBOX ? (y(), E(qt, F({
|
769
769
|
key: 0,
|
770
770
|
class: "pdap-input-checkbox"
|
771
|
-
}, { ...n.$attrs, ...t }), null, 16)) : (
|
772
|
-
n.error ? (
|
771
|
+
}, { ...n.$attrs, ...t }), null, 16)) : (y(), E(Xt, Lt(F({ key: 1 }, { ...n.$attrs, ...n.$props })), null, 16)),
|
772
|
+
n.error ? (y(), h("div", {
|
773
773
|
key: 2,
|
774
774
|
id: r.value,
|
775
775
|
class: "pdap-input-error-message"
|
776
|
-
}, z(n.error), 9, er)) :
|
776
|
+
}, z(n.error), 9, er)) : k("", !0),
|
777
777
|
f("label", {
|
778
778
|
class: "pdap-input-label",
|
779
779
|
for: n.id
|
@@ -792,7 +792,7 @@ function be(e, t) {
|
|
792
792
|
}
|
793
793
|
return r;
|
794
794
|
}
|
795
|
-
function
|
795
|
+
function G(e) {
|
796
796
|
for (var t = 1; t < arguments.length; t++) {
|
797
797
|
var r = arguments[t] != null ? arguments[t] : {};
|
798
798
|
t % 2 ? be(Object(r), !0).forEach(function(n) {
|
@@ -818,17 +818,17 @@ function ie(e) {
|
|
818
818
|
return e !== null && typeof e == "object" && !Array.isArray(e);
|
819
819
|
}
|
820
820
|
function ce(e) {
|
821
|
-
return K(e.$validator) ?
|
821
|
+
return K(e.$validator) ? G({}, e) : {
|
822
822
|
$validator: e
|
823
823
|
};
|
824
824
|
}
|
825
825
|
function ar(e) {
|
826
826
|
return ie(e) && K(e.then);
|
827
827
|
}
|
828
|
-
function
|
828
|
+
function P(e) {
|
829
829
|
return typeof e == "object" ? e.$valid : e;
|
830
830
|
}
|
831
|
-
function
|
831
|
+
function V(e) {
|
832
832
|
return e.$validator || e;
|
833
833
|
}
|
834
834
|
function we(e, t) {
|
@@ -837,7 +837,7 @@ function we(e, t) {
|
|
837
837
|
if (!ie(t) && !K(t))
|
838
838
|
throw new Error("[@vuelidate/validators]: Validator must be a function or object with $validator parameter");
|
839
839
|
const r = ce(t);
|
840
|
-
return r.$params =
|
840
|
+
return r.$params = G(G({}, r.$params || {}), e), r;
|
841
841
|
}
|
842
842
|
function q(e, t) {
|
843
843
|
if (!K(e) && typeof L(e) != "string")
|
@@ -850,7 +850,7 @@ function q(e, t) {
|
|
850
850
|
function sr(e) {
|
851
851
|
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [];
|
852
852
|
const r = ce(e);
|
853
|
-
return
|
853
|
+
return G(G({}, r), {}, {
|
854
854
|
$async: !0,
|
855
855
|
$watchTargets: t
|
856
856
|
});
|
@@ -862,31 +862,31 @@ function or(e) {
|
|
862
862
|
n[a - 1] = arguments[a];
|
863
863
|
return L(t).reduce((s, i, u) => {
|
864
864
|
const l = Object.entries(i).reduce((c, M) => {
|
865
|
-
let [
|
866
|
-
const p = e[
|
865
|
+
let [j, m] = M;
|
866
|
+
const p = e[j] || {}, o = Object.entries(p).reduce((d, g) => {
|
867
867
|
let [w, I] = g;
|
868
|
-
const S =
|
869
|
-
if (d.$data[w] = S, d.$data.$invalid = !
|
870
|
-
let
|
868
|
+
const S = V(I).call(this, m, i, u, ...n), Q = P(S);
|
869
|
+
if (d.$data[w] = S, d.$data.$invalid = !Q || !!d.$data.$invalid, d.$data.$error = d.$data.$invalid, !Q) {
|
870
|
+
let _ = I.$message || "";
|
871
871
|
const te = I.$params || {};
|
872
|
-
typeof
|
872
|
+
typeof _ == "function" && (_ = _({
|
873
873
|
$pending: !1,
|
874
|
-
$invalid: !
|
874
|
+
$invalid: !Q,
|
875
875
|
$params: te,
|
876
|
-
$model:
|
876
|
+
$model: m,
|
877
877
|
$response: S
|
878
878
|
})), d.$errors.push({
|
879
|
-
$property:
|
880
|
-
$message:
|
879
|
+
$property: j,
|
880
|
+
$message: _,
|
881
881
|
$params: te,
|
882
882
|
$response: S,
|
883
|
-
$model:
|
883
|
+
$model: m,
|
884
884
|
$pending: !1,
|
885
885
|
$validator: w
|
886
886
|
});
|
887
887
|
}
|
888
888
|
return {
|
889
|
-
$valid: d.$valid &&
|
889
|
+
$valid: d.$valid && Q,
|
890
890
|
$data: d.$data,
|
891
891
|
$errors: d.$errors
|
892
892
|
};
|
@@ -895,7 +895,7 @@ function or(e) {
|
|
895
895
|
$data: {},
|
896
896
|
$errors: []
|
897
897
|
});
|
898
|
-
return c.$data[
|
898
|
+
return c.$data[j] = o.$data, c.$errors[j] = o.$errors, {
|
899
899
|
$valid: c.$valid && o.$valid,
|
900
900
|
$data: c.$data,
|
901
901
|
$errors: c.$errors
|
@@ -940,37 +940,37 @@ const x = (e) => {
|
|
940
940
|
}
|
941
941
|
return !!String(e).length;
|
942
942
|
}, he = (e) => (e = L(e), Array.isArray(e) ? e.length : typeof e == "object" ? Object.keys(e).length : String(e).length);
|
943
|
-
function
|
943
|
+
function Y() {
|
944
944
|
for (var e = arguments.length, t = new Array(e), r = 0; r < e; r++)
|
945
945
|
t[r] = arguments[r];
|
946
946
|
return (n) => (n = L(n), !x(n) || t.every((a) => (a.lastIndex = 0, a.test(n))));
|
947
947
|
}
|
948
|
-
var
|
948
|
+
var Z = /* @__PURE__ */ Object.freeze({
|
949
949
|
__proto__: null,
|
950
950
|
forEach: or,
|
951
951
|
len: he,
|
952
952
|
normalizeValidatorObject: ce,
|
953
|
-
regex:
|
953
|
+
regex: Y,
|
954
954
|
req: x,
|
955
955
|
unwrap: L,
|
956
|
-
unwrapNormalizedValidator:
|
957
|
-
unwrapValidatorResponse:
|
956
|
+
unwrapNormalizedValidator: V,
|
957
|
+
unwrapValidatorResponse: P,
|
958
958
|
withAsync: sr,
|
959
959
|
withMessage: q,
|
960
960
|
withParams: we
|
961
|
-
}), ur =
|
961
|
+
}), ur = Y(/^[a-zA-Z]*$/), ir = {
|
962
962
|
$validator: ur,
|
963
963
|
$message: "The value is not alphabetical",
|
964
964
|
$params: {
|
965
965
|
type: "alpha"
|
966
966
|
}
|
967
|
-
}, lr =
|
967
|
+
}, lr = Y(/^[a-zA-Z0-9]*$/), cr = {
|
968
968
|
$validator: lr,
|
969
969
|
$message: "The value must be alpha-numeric",
|
970
970
|
$params: {
|
971
971
|
type: "alphaNum"
|
972
972
|
}
|
973
|
-
}, dr =
|
973
|
+
}, dr = Y(/^\d*(\.\d+)?$/), Lr = {
|
974
974
|
$validator: dr,
|
975
975
|
$message: "Value must be numeric",
|
976
976
|
$params: {
|
@@ -997,7 +997,7 @@ function gr(e, t) {
|
|
997
997
|
};
|
998
998
|
}
|
999
999
|
const pr = /^(?:[A-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[A-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9]{2,}(?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])$/i;
|
1000
|
-
var jr =
|
1000
|
+
var jr = Y(pr), ve = {
|
1001
1001
|
$validator: jr,
|
1002
1002
|
$message: "Value is not a valid email address",
|
1003
1003
|
$params: {
|
@@ -1146,7 +1146,7 @@ function Or(e) {
|
|
1146
1146
|
};
|
1147
1147
|
}
|
1148
1148
|
const _r = /^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i;
|
1149
|
-
var br =
|
1149
|
+
var br = Y(_r), Ar = {
|
1150
1150
|
$validator: br,
|
1151
1151
|
$message: "The value is not a valid URL address",
|
1152
1152
|
$params: {
|
@@ -1157,7 +1157,7 @@ function kr(e) {
|
|
1157
1157
|
return function() {
|
1158
1158
|
for (var t = arguments.length, r = new Array(t), n = 0; n < t; n++)
|
1159
1159
|
r[n] = arguments[n];
|
1160
|
-
return e.reduce((a, s) =>
|
1160
|
+
return e.reduce((a, s) => P(a) ? a : V(s).apply(this, r), !1);
|
1161
1161
|
};
|
1162
1162
|
}
|
1163
1163
|
function Pr(e) {
|
@@ -1166,7 +1166,7 @@ function Pr(e) {
|
|
1166
1166
|
r[n] = arguments[n];
|
1167
1167
|
return e.reduce(async (a, s) => {
|
1168
1168
|
const i = await a;
|
1169
|
-
return
|
1169
|
+
return P(i) ? i : V(s).apply(this, r);
|
1170
1170
|
}, Promise.resolve(!1));
|
1171
1171
|
};
|
1172
1172
|
}
|
@@ -1190,7 +1190,7 @@ function Rr(e) {
|
|
1190
1190
|
return function() {
|
1191
1191
|
for (var t = arguments.length, r = new Array(t), n = 0; n < t; n++)
|
1192
1192
|
r[n] = arguments[n];
|
1193
|
-
return e.reduce((a, s) =>
|
1193
|
+
return e.reduce((a, s) => P(a) ? V(s).apply(this, r) : a, !0);
|
1194
1194
|
};
|
1195
1195
|
}
|
1196
1196
|
function Ur(e) {
|
@@ -1199,7 +1199,7 @@ function Ur(e) {
|
|
1199
1199
|
r[n] = arguments[n];
|
1200
1200
|
return e.reduce(async (a, s) => {
|
1201
1201
|
const i = await a;
|
1202
|
-
return
|
1202
|
+
return P(i) ? V(s).apply(this, r) : i;
|
1203
1203
|
}, Promise.resolve(!0));
|
1204
1204
|
};
|
1205
1205
|
}
|
@@ -1223,8 +1223,8 @@ function Wr(e) {
|
|
1223
1223
|
return function(t, r) {
|
1224
1224
|
if (!x(t))
|
1225
1225
|
return !0;
|
1226
|
-
const n =
|
1227
|
-
return ar(n) ? n.then((a) => !
|
1226
|
+
const n = V(e).call(this, t, r);
|
1227
|
+
return ar(n) ? n.then((a) => !P(a)) : !P(n);
|
1228
1228
|
};
|
1229
1229
|
}
|
1230
1230
|
function Fr(e) {
|
@@ -1269,13 +1269,13 @@ var Jr = (e) => ({
|
|
1269
1269
|
max: e,
|
1270
1270
|
type: "maxValue"
|
1271
1271
|
}
|
1272
|
-
}), Xr =
|
1272
|
+
}), Xr = Y(/(^[0-9]*$)|(^-[0-9]+$)/), Kr = {
|
1273
1273
|
$validator: Xr,
|
1274
1274
|
$message: "Value is not an integer",
|
1275
1275
|
$params: {
|
1276
1276
|
type: "integer"
|
1277
1277
|
}
|
1278
|
-
}, qr =
|
1278
|
+
}, qr = Y(/^[-]?\d*(\.\d+)?$/), en = {
|
1279
1279
|
$validator: qr,
|
1280
1280
|
$message: "Value must be decimal",
|
1281
1281
|
$params: {
|
@@ -1300,7 +1300,7 @@ function tn(e) {
|
|
1300
1300
|
messageParams: l = n
|
1301
1301
|
} = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
1302
1302
|
function c(M) {
|
1303
|
-
return t(u(M), l(
|
1303
|
+
return t(u(M), l(G({
|
1304
1304
|
model: M.$model,
|
1305
1305
|
property: M.$property,
|
1306
1306
|
pending: M.$pending,
|
@@ -1324,7 +1324,7 @@ const Je = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1324
1324
|
createI18nMessage: tn,
|
1325
1325
|
decimal: en,
|
1326
1326
|
email: ve,
|
1327
|
-
helpers:
|
1327
|
+
helpers: Z,
|
1328
1328
|
integer: Kr,
|
1329
1329
|
ipAddress: fr,
|
1330
1330
|
macAddress: vr,
|
@@ -1340,7 +1340,7 @@ const Je = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1340
1340
|
requiredUnless: Er,
|
1341
1341
|
sameAs: Or,
|
1342
1342
|
url: Ar
|
1343
|
-
}, Symbol.toStringTag, { value: "Module" })), Xe =
|
1343
|
+
}, Symbol.toStringTag, { value: "Module" })), Xe = Z.regex(
|
1344
1344
|
/^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[#?!@$ %^&*-]).{8,}$/
|
1345
1345
|
);
|
1346
1346
|
function Pe(e) {
|
@@ -1362,7 +1362,7 @@ function rn(e, t) {
|
|
1362
1362
|
}
|
1363
1363
|
function nn(e, t, r) {
|
1364
1364
|
return {
|
1365
|
-
[e]:
|
1365
|
+
[e]: Z.withMessage(r, Je[e](t))
|
1366
1366
|
};
|
1367
1367
|
}
|
1368
1368
|
function an() {
|
@@ -1370,7 +1370,7 @@ function an() {
|
|
1370
1370
|
}
|
1371
1371
|
function sn(e) {
|
1372
1372
|
return {
|
1373
|
-
required:
|
1373
|
+
required: Z.withMessage(e, $e)
|
1374
1374
|
};
|
1375
1375
|
}
|
1376
1376
|
function on() {
|
@@ -1378,7 +1378,7 @@ function on() {
|
|
1378
1378
|
}
|
1379
1379
|
function un(e) {
|
1380
1380
|
return {
|
1381
|
-
email:
|
1381
|
+
email: Z.withMessage(e, ve)
|
1382
1382
|
};
|
1383
1383
|
}
|
1384
1384
|
function ln() {
|
@@ -1386,7 +1386,7 @@ function ln() {
|
|
1386
1386
|
}
|
1387
1387
|
function cn(e) {
|
1388
1388
|
return {
|
1389
|
-
password:
|
1389
|
+
password: Z.withMessage(e, Xe)
|
1390
1390
|
};
|
1391
1391
|
}
|
1392
1392
|
function dn(e, t) {
|
@@ -1428,22 +1428,22 @@ const Ln = ["id", "name"], Mn = {
|
|
1428
1428
|
emits: ["submit", "change"],
|
1429
1429
|
setup(e, { emit: t }) {
|
1430
1430
|
const r = e, n = t, a = v(
|
1431
|
-
() => r.schema.map((
|
1432
|
-
const p = { ...
|
1431
|
+
() => r.schema.map((m) => {
|
1432
|
+
const p = { ...m };
|
1433
1433
|
return delete p.validators, p;
|
1434
1434
|
})
|
1435
1435
|
), s = N(
|
1436
|
-
a.value.reduce((
|
1436
|
+
a.value.reduce((m, p) => {
|
1437
1437
|
switch (p.type) {
|
1438
1438
|
case O.CHECKBOX:
|
1439
|
-
return { ...
|
1439
|
+
return { ...m, [p.name]: String(p.defaultChecked) };
|
1440
1440
|
case O.TEXT:
|
1441
1441
|
case O.PASSWORD:
|
1442
1442
|
default:
|
1443
|
-
return { ...
|
1443
|
+
return { ...m, [p.name]: p.value };
|
1444
1444
|
}
|
1445
1445
|
}, {})
|
1446
|
-
), i = r.schema.reduce((
|
1446
|
+
), i = r.schema.reduce((m, p) => {
|
1447
1447
|
const o = Object.entries(p.validators ?? {}).reduce(
|
1448
1448
|
(d, [g, w]) => ({
|
1449
1449
|
...d,
|
@@ -1452,15 +1452,15 @@ const Ln = ["id", "name"], Mn = {
|
|
1452
1452
|
{}
|
1453
1453
|
);
|
1454
1454
|
return {
|
1455
|
-
...
|
1455
|
+
...m,
|
1456
1456
|
[p.name]: {
|
1457
1457
|
...o
|
1458
1458
|
}
|
1459
1459
|
};
|
1460
1460
|
}, {}), u = Ht(i, s, { $autoDirty: !1, $lazy: !0 }), l = N(r.error);
|
1461
|
-
function c(
|
1461
|
+
function c(m, p) {
|
1462
1462
|
const o = p.target, d = o.type === O.CHECKBOX && typeof o.checked == "boolean" ? o.checked.toString() : o.value;
|
1463
|
-
s.value[
|
1463
|
+
s.value[m] = d, M();
|
1464
1464
|
}
|
1465
1465
|
Te(() => {
|
1466
1466
|
r.error ? l.value = r.error : l.value && u.value.$errors.length === 0 ? l.value = null : !l.value && u.value.$errors.length > 0 && (l.value = "Please update this form to correct the errors");
|
@@ -1469,30 +1469,30 @@ const Ln = ["id", "name"], Mn = {
|
|
1469
1469
|
function M() {
|
1470
1470
|
n("change", { ...s.value });
|
1471
1471
|
}
|
1472
|
-
async function
|
1472
|
+
async function j(m) {
|
1473
1473
|
if (await u.value.$validate()) {
|
1474
|
-
n("submit", { ...s.value }), u.value.$reset(),
|
1474
|
+
n("submit", { ...s.value }), u.value.$reset(), m.target.reset(), s.value = Object.entries(s).reduce((d, [g]) => ({ ...d, [g]: "" }), {});
|
1475
1475
|
return;
|
1476
1476
|
}
|
1477
1477
|
}
|
1478
|
-
return (
|
1479
|
-
id:
|
1480
|
-
name:
|
1478
|
+
return (m, p) => (y(), h("form", {
|
1479
|
+
id: m.id,
|
1480
|
+
name: m.name,
|
1481
1481
|
class: "pdap-form",
|
1482
1482
|
onChange: M,
|
1483
|
-
onSubmit: p[0] || (p[0] = je((o) =>
|
1483
|
+
onSubmit: p[0] || (p[0] = je((o) => j(o), ["prevent"]))
|
1484
1484
|
}, [
|
1485
|
-
typeof l.value == "string" ? (
|
1486
|
-
(
|
1485
|
+
typeof l.value == "string" ? (y(), h("div", Mn, z(l.value), 1)) : k("", !0),
|
1486
|
+
(y(!0), h(W, null, le(a.value, (o) => {
|
1487
1487
|
var d, g, w, I;
|
1488
|
-
return
|
1488
|
+
return y(), E(rr, F(o, {
|
1489
1489
|
key: o.name,
|
1490
1490
|
error: (d = L(u)[o.name]) != null && d.$error ? (I = (w = (g = L(u)[o.name]) == null ? void 0 : g.$errors) == null ? void 0 : w[0]) == null ? void 0 : I.$message : "",
|
1491
1491
|
value: s.value[o.name],
|
1492
|
-
onChange: (
|
1492
|
+
onChange: (H) => c(o.name, H)
|
1493
1493
|
}), null, 16, ["error", "value", "onChange"]);
|
1494
1494
|
}), 128)),
|
1495
|
-
J(
|
1495
|
+
J(m.$slots, "default")
|
1496
1496
|
], 40, Ln));
|
1497
1497
|
}
|
1498
1498
|
});
|
@@ -1517,10 +1517,10 @@ const jn = /* @__PURE__ */ f("svg", {
|
|
1517
1517
|
`,
|
1518
1518
|
"Did you forget to inject some linkData for the Nav component?"
|
1519
1519
|
));
|
1520
|
-
const r =
|
1520
|
+
const r = B({
|
1521
1521
|
isExpanded: !1,
|
1522
1522
|
isMobile: !0
|
1523
|
-
}), n =
|
1523
|
+
}), n = B({
|
1524
1524
|
"pdap-nav": !0
|
1525
1525
|
});
|
1526
1526
|
Ve(() => {
|
@@ -1536,7 +1536,7 @@ const jn = /* @__PURE__ */ f("svg", {
|
|
1536
1536
|
const i = document.querySelector("body");
|
1537
1537
|
!r.isExpanded && r.isMobile ? (r.isExpanded = !0, i != null && i.classList.contains("lock-scroll") || (u = document.querySelector("body")) == null || u.classList.add("lock-scroll")) : r.isExpanded && r.isMobile && (r.isExpanded = !1, (l = document.querySelector("body")) == null || l.classList.remove("lock-scroll")), await se();
|
1538
1538
|
}
|
1539
|
-
return (i, u) => (
|
1539
|
+
return (i, u) => (y(), h(W, null, [
|
1540
1540
|
f("div", {
|
1541
1541
|
"aria-controls": "nav",
|
1542
1542
|
class: "pdap-nav-open-button",
|
@@ -1549,19 +1549,19 @@ const jn = /* @__PURE__ */ f("svg", {
|
|
1549
1549
|
class: ee(n),
|
1550
1550
|
style: Mt(r.isMobile ? { top: `${i.topPosition}px` } : {})
|
1551
1551
|
}, [
|
1552
|
-
(
|
1552
|
+
(y(!0), h(W, null, le(L(t), (l) => (y(), h("li", {
|
1553
1553
|
key: l.text,
|
1554
1554
|
class: "pdap-nav-link-container"
|
1555
1555
|
}, [
|
1556
|
-
l.href ? (
|
1556
|
+
l.href ? (y(), h("a", {
|
1557
1557
|
key: 0,
|
1558
1558
|
class: "pdap-nav-link",
|
1559
1559
|
href: l.href,
|
1560
1560
|
target: "_blank",
|
1561
1561
|
referrerpolicy: "no-referrer",
|
1562
1562
|
onClick: s
|
1563
|
-
}, z(l.text), 9, fn)) :
|
1564
|
-
l.path ? (
|
1563
|
+
}, z(l.text), 9, fn)) : k("", !0),
|
1564
|
+
l.path ? (y(), E(L(oe), {
|
1565
1565
|
key: 1,
|
1566
1566
|
"active-class": "pdap-nav-link-current",
|
1567
1567
|
"exact-active-class": "pdap-nav-link-current-exact",
|
@@ -1573,7 +1573,7 @@ const jn = /* @__PURE__ */ f("svg", {
|
|
1573
1573
|
D(z(l.text), 1)
|
1574
1574
|
]),
|
1575
1575
|
_: 2
|
1576
|
-
}, 1032, ["to"])) :
|
1576
|
+
}, 1032, ["to"])) : k("", !0)
|
1577
1577
|
]))), 128))
|
1578
1578
|
], 14, mn)
|
1579
1579
|
], 64));
|
@@ -1597,12 +1597,12 @@ const vn = "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idX
|
|
1597
1597
|
function s() {
|
1598
1598
|
n.value && (r.value = n.value.offsetHeight);
|
1599
1599
|
}
|
1600
|
-
return (i, u) => (
|
1600
|
+
return (i, u) => (y(), h("header", {
|
1601
1601
|
ref_key: "el",
|
1602
1602
|
ref: n,
|
1603
1603
|
class: "pdap-header"
|
1604
1604
|
}, [
|
1605
|
-
L(a) ? (
|
1605
|
+
L(a) ? (y(), E(L(oe), {
|
1606
1606
|
key: 1,
|
1607
1607
|
to: i.logoImageAnchorPath,
|
1608
1608
|
class: "logo"
|
@@ -1616,7 +1616,7 @@ const vn = "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idX
|
|
1616
1616
|
}, null, 8, Dn)
|
1617
1617
|
]),
|
1618
1618
|
_: 1
|
1619
|
-
}, 8, ["to"])) : (
|
1619
|
+
}, 8, ["to"])) : (y(), h("a", {
|
1620
1620
|
key: 0,
|
1621
1621
|
href: i.logoImageAnchorPath,
|
1622
1622
|
class: "logo"
|
@@ -1628,7 +1628,7 @@ const vn = "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idX
|
|
1628
1628
|
alt: "Police Data Accessibility Project Logo"
|
1629
1629
|
}, null, 8, Nn)
|
1630
1630
|
], 8, $n)),
|
1631
|
-
|
1631
|
+
U(hn, { "top-position": r.value }, null, 8, ["top-position"])
|
1632
1632
|
], 512));
|
1633
1633
|
}
|
1634
1634
|
});
|
@@ -1668,7 +1668,7 @@ const Cn = /* @__PURE__ */ f("div", { class: "pdap-flex-container" }, [
|
|
1668
1668
|
a.value && Object.values(l).some(Boolean) && (a.value = void 0);
|
1669
1669
|
}
|
1670
1670
|
function u(l) {
|
1671
|
-
if (Object.values(l).every((
|
1671
|
+
if (Object.values(l).every((j) => !j)) {
|
1672
1672
|
a.value = "Either a search term or a location is required.";
|
1673
1673
|
return;
|
1674
1674
|
}
|
@@ -1677,10 +1677,10 @@ const Cn = /* @__PURE__ */ f("div", { class: "pdap-flex-container" }, [
|
|
1677
1677
|
`${r.baseUrlForRedirect}/search/${M}/${c}`
|
1678
1678
|
);
|
1679
1679
|
}
|
1680
|
-
return (l, c) => (
|
1680
|
+
return (l, c) => (y(), h(W, null, [
|
1681
1681
|
Cn,
|
1682
1682
|
f("div", xn, [
|
1683
|
-
|
1683
|
+
U(pn, {
|
1684
1684
|
id: "quick-search-form",
|
1685
1685
|
class: "flex flex-wrap gap-x-4",
|
1686
1686
|
error: a.value,
|
@@ -1690,7 +1690,7 @@ const Cn = /* @__PURE__ */ f("div", { class: "pdap-flex-container" }, [
|
|
1690
1690
|
onSubmit: u
|
1691
1691
|
}, {
|
1692
1692
|
default: T(() => [
|
1693
|
-
|
1693
|
+
U(We, {
|
1694
1694
|
type: "submit",
|
1695
1695
|
class: "flex-grow-0 flex-shrink-0 basis-full max-w-[unset] mt-4"
|
1696
1696
|
}, {
|
@@ -1704,7 +1704,7 @@ const Cn = /* @__PURE__ */ f("div", { class: "pdap-flex-container" }, [
|
|
1704
1704
|
}, 8, ["error"]),
|
1705
1705
|
f("p", In, [
|
1706
1706
|
D(" For example, you could search for "),
|
1707
|
-
L(s) ? (
|
1707
|
+
L(s) ? (y(), E(L(oe), {
|
1708
1708
|
key: 0,
|
1709
1709
|
to: "/search/stops/pittsburgh"
|
1710
1710
|
}, {
|
@@ -1712,14 +1712,14 @@ const Cn = /* @__PURE__ */ f("div", { class: "pdap-flex-container" }, [
|
|
1712
1712
|
D(" stops in Pittsburgh ")
|
1713
1713
|
]),
|
1714
1714
|
_: 1
|
1715
|
-
})) : (
|
1715
|
+
})) : (y(), h("a", {
|
1716
1716
|
key: 1,
|
1717
1717
|
target: "_blank",
|
1718
1718
|
rel: "noreferrer",
|
1719
1719
|
href: `${r.baseUrlForRedirect}/search/stops/pittsburgh`
|
1720
1720
|
}, " stops in Pittsburgh ", 8, Sn)),
|
1721
1721
|
D(" or "),
|
1722
|
-
L(s) ? (
|
1722
|
+
L(s) ? (y(), E(L(oe), {
|
1723
1723
|
key: 2,
|
1724
1724
|
to: "/search/complaints/all"
|
1725
1725
|
}, {
|
@@ -1727,7 +1727,7 @@ const Cn = /* @__PURE__ */ f("div", { class: "pdap-flex-container" }, [
|
|
1727
1727
|
D(" complaints everywhere ")
|
1728
1728
|
]),
|
1729
1729
|
_: 1
|
1730
|
-
})) : (
|
1730
|
+
})) : (y(), h("a", {
|
1731
1731
|
key: 3,
|
1732
1732
|
target: "_blank",
|
1733
1733
|
rel: "noreferrer",
|
@@ -1748,7 +1748,7 @@ const On = ["alt", "src"], _n = {
|
|
1748
1748
|
imgSrc: {}
|
1749
1749
|
},
|
1750
1750
|
setup(e) {
|
1751
|
-
return (t, r) => (
|
1751
|
+
return (t, r) => (y(), h("img", {
|
1752
1752
|
class: "pdap-tile-icon",
|
1753
1753
|
alt: t.imgAltText,
|
1754
1754
|
src: t.imgSrc
|
@@ -1766,97 +1766,98 @@ const bn = {
|
|
1766
1766
|
unmounted(e) {
|
1767
1767
|
e.clickOutsideEvent && (document.removeEventListener("click", e.clickOutsideEvent), document.removeEventListener("keyup", e.clickOutsideEvent));
|
1768
1768
|
}
|
1769
|
-
}, An = ["onKeydown"], kn = ["aria-hidden"], Pn = {
|
1769
|
+
}, An = ["onKeydown"], kn = ["id", "aria-hidden"], Pn = {
|
1770
1770
|
name: "PdapButton"
|
1771
1771
|
}, na = /* @__PURE__ */ C({
|
1772
1772
|
...Pn,
|
1773
1773
|
props: {
|
1774
1774
|
defaultOpen: { type: Boolean, default: !1 },
|
1775
1775
|
disabled: { type: Boolean, default: !1 },
|
1776
|
+
dropdownId: {},
|
1776
1777
|
triggerOn: { default: ne.PRESS }
|
1777
1778
|
},
|
1778
1779
|
emits: ["update:open", "press"],
|
1779
1780
|
setup(e, { emit: t }) {
|
1780
|
-
const r = e, n = t, a =
|
1781
|
+
const r = e, n = t, a = N(null), s = N(null), i = N(r.defaultOpen), u = v(
|
1781
1782
|
() => r.triggerOn === ne.HOVER
|
1782
1783
|
);
|
1783
|
-
function
|
1784
|
-
n("press",
|
1784
|
+
function l(o) {
|
1785
|
+
n("press", o), r.triggerOn === ne.PRESS && c();
|
1785
1786
|
}
|
1786
|
-
const
|
1787
|
-
r.disabled || (
|
1787
|
+
const c = () => {
|
1788
|
+
r.disabled || (i.value = !i.value, n("update:open", i.value));
|
1788
1789
|
};
|
1789
|
-
function
|
1790
|
-
|
1790
|
+
function M() {
|
1791
|
+
i.value = !0, n("update:open", !0);
|
1791
1792
|
}
|
1792
1793
|
function j() {
|
1793
|
-
|
1794
|
+
i.value = !1, n("update:open", !1);
|
1794
1795
|
}
|
1795
|
-
function
|
1796
|
-
var
|
1797
|
-
if (!
|
1796
|
+
function m() {
|
1797
|
+
var w, I;
|
1798
|
+
if (!a.value)
|
1798
1799
|
return;
|
1799
|
-
|
1800
|
-
const
|
1801
|
-
|
1802
|
-
const
|
1800
|
+
a.value.style.display = "flex", a.value.style.setProperty("max-height", "max-content");
|
1801
|
+
const o = a.value.scrollHeight;
|
1802
|
+
a.value.style.display = "none", a.value.style.removeProperty("max-height");
|
1803
|
+
const d = document == null ? void 0 : document.querySelector(":root"), g = (w = d == null ? void 0 : d.style) == null ? void 0 : w.getPropertyValue(
|
1803
1804
|
"--dropdown-content-max-height"
|
1804
1805
|
);
|
1805
|
-
Number((
|
1806
|
+
Number((I = g == null ? void 0 : g.match(/\d+/)) == null ? void 0 : I.join("")) >= o || a.value && d && d.style.setProperty("--dropdown-content-max-height", `${o + 16}px`);
|
1806
1807
|
}
|
1807
|
-
const
|
1808
|
-
mouseenter:
|
1809
|
-
focus:
|
1810
|
-
focusin:
|
1811
|
-
focusout:
|
1812
|
-
mouseleave:
|
1813
|
-
blur:
|
1808
|
+
const p = {
|
1809
|
+
mouseenter: u.value ? M : void 0,
|
1810
|
+
focus: u.value ? M : void 0,
|
1811
|
+
focusin: u.value ? M : void 0,
|
1812
|
+
focusout: u.value ? j : void 0,
|
1813
|
+
mouseleave: u.value ? j : void 0,
|
1814
|
+
blur: u.value ? j : void 0
|
1814
1815
|
};
|
1815
1816
|
return Be(() => {
|
1816
|
-
|
1817
|
-
}), (
|
1817
|
+
m();
|
1818
|
+
}), (o, d) => Ce((y(), h("div", F({
|
1818
1819
|
ref_key: "dropdownRef",
|
1819
|
-
ref:
|
1820
|
+
ref: s,
|
1820
1821
|
class: "pdap-dropdown",
|
1821
1822
|
onKeydown: xe(j, ["escape"])
|
1822
|
-
}, gt(
|
1823
|
-
|
1824
|
-
"aria-controls":
|
1825
|
-
"aria-expanded":
|
1826
|
-
disabled:
|
1823
|
+
}, gt(p, !0)), [
|
1824
|
+
U(L(We), {
|
1825
|
+
"aria-controls": o.dropdownId,
|
1826
|
+
"aria-expanded": i.value,
|
1827
|
+
disabled: o.disabled,
|
1827
1828
|
"aria-haspopup": "true",
|
1828
1829
|
intent: "tertiary",
|
1829
1830
|
class: ee({
|
1830
1831
|
"pdap-dropdown-trigger": !0,
|
1831
|
-
"pointer-events-none":
|
1832
|
-
"cursor-not-allowed":
|
1832
|
+
"pointer-events-none": o.disabled,
|
1833
|
+
"cursor-not-allowed": o.disabled
|
1833
1834
|
}),
|
1834
1835
|
"data-test": "dropdown-trigger",
|
1835
|
-
onClick: je(
|
1836
|
-
onKeydown: xe(je(
|
1836
|
+
onClick: je(l, ["prevent", "stop"]),
|
1837
|
+
onKeydown: xe(je(l, ["prevent", "stop"]), ["enter", "space"])
|
1837
1838
|
}, {
|
1838
1839
|
default: T(() => [
|
1839
|
-
J(
|
1840
|
+
J(o.$slots, "trigger")
|
1840
1841
|
]),
|
1841
1842
|
_: 3
|
1842
|
-
}, 8, ["aria-expanded", "disabled", "class", "onClick", "onKeydown"]),
|
1843
|
-
|
1843
|
+
}, 8, ["aria-controls", "aria-expanded", "disabled", "class", "onClick", "onKeydown"]),
|
1844
|
+
U(ye, {
|
1844
1845
|
name: "dropdown",
|
1845
1846
|
appear: ""
|
1846
1847
|
}, {
|
1847
1848
|
default: T(() => [
|
1848
1849
|
Ce(f("div", {
|
1849
|
-
id:
|
1850
|
+
id: o.dropdownId,
|
1850
1851
|
ref_key: "contentRef",
|
1851
|
-
ref:
|
1852
|
-
"aria-hidden": !
|
1852
|
+
ref: a,
|
1853
|
+
"aria-hidden": !i.value,
|
1853
1854
|
class: "pdap-dropdown-content",
|
1854
1855
|
"data-test": "dropdown-content",
|
1855
1856
|
role: "menu"
|
1856
1857
|
}, [
|
1857
|
-
J(
|
1858
|
+
J(o.$slots, "content")
|
1858
1859
|
], 8, kn), [
|
1859
|
-
[pt,
|
1860
|
+
[pt, i.value]
|
1860
1861
|
])
|
1861
1862
|
]),
|
1862
1863
|
_: 3
|
@@ -1886,18 +1887,18 @@ const Qn = { "aria-label": "Breadcrumb" }, Rn = { key: 1 }, Un = {
|
|
1886
1887
|
const t = mt(), r = v(() => Yn(t));
|
1887
1888
|
return (n, a) => {
|
1888
1889
|
const s = Ue("router-link");
|
1889
|
-
return
|
1890
|
-
|
1890
|
+
return y(), h("nav", Qn, [
|
1891
|
+
U(jt, {
|
1891
1892
|
class: "pdap-breadcrumbs",
|
1892
1893
|
name: "pdap-breadcrumbs",
|
1893
1894
|
tag: "ul"
|
1894
1895
|
}, {
|
1895
1896
|
default: T(() => [
|
1896
|
-
(
|
1897
|
+
(y(!0), h(W, null, le(r.value, (i) => (y(), h("li", {
|
1897
1898
|
key: i.text,
|
1898
1899
|
class: ee({ "is-active": i.active })
|
1899
1900
|
}, [
|
1900
|
-
i.active ? (
|
1901
|
+
i.active ? (y(), h("span", Rn, z(i.text), 1)) : (y(), E(s, {
|
1901
1902
|
key: 0,
|
1902
1903
|
to: i.path
|
1903
1904
|
}, {
|
@@ -1931,10 +1932,10 @@ const Ke = (e, t) => {
|
|
1931
1932
|
show: { type: Boolean, default: !1 }
|
1932
1933
|
},
|
1933
1934
|
setup(e) {
|
1934
|
-
return (t, r) => (
|
1935
|
-
|
1935
|
+
return (t, r) => (y(), h("div", Bn, [
|
1936
|
+
U(ye, { appear: "" }, {
|
1936
1937
|
default: T(() => [
|
1937
|
-
t.show ? (
|
1938
|
+
t.show ? (y(), h("svg", {
|
1938
1939
|
key: 0,
|
1939
1940
|
width: t.size,
|
1940
1941
|
height: t.size,
|
@@ -1953,17 +1954,17 @@ const Ke = (e, t) => {
|
|
1953
1954
|
stroke: t.color,
|
1954
1955
|
fill: t.color
|
1955
1956
|
}, null, 8, Gn)
|
1956
|
-
], 8, Wn)) :
|
1957
|
+
], 8, Wn)) : k("", !0)
|
1957
1958
|
]),
|
1958
1959
|
_: 1
|
1959
1960
|
}),
|
1960
|
-
(
|
1961
|
+
(y(), E(ye, {
|
1961
1962
|
key: t.text,
|
1962
1963
|
appear: "",
|
1963
1964
|
mode: "out-in"
|
1964
1965
|
}, {
|
1965
1966
|
default: T(() => [
|
1966
|
-
t.text && t.show ? (
|
1967
|
+
t.text && t.show ? (y(), h("p", Zn, z(t.text), 1)) : k("", !0)
|
1967
1968
|
]),
|
1968
1969
|
_: 1
|
1969
1970
|
}))
|