@vergelijkdirect/comparison-forms 2.0.3-VER-9366.1 → 2.0.3-VER-9366.3
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/vue/comparison-forms.js +367 -365
- package/dist/wc/comparison-forms.js +676 -674
- package/dist/wc-forms/{VdInput-FV0L9B45.cjs → VdInput-FmcCel8k.cjs} +1 -1
- package/dist/wc-forms/{VdPopover-DztGFjWu.cjs → VdPopover-C8VbyCPM.cjs} +1 -1
- package/dist/wc-forms/{VdRadioGroup-CyxKi0s8.cjs → VdRadioGroup-BEcdb06g.cjs} +1 -1
- package/dist/wc-forms/{VdSearchableSelect-CFK59ffc.cjs → VdSearchableSelect-qIA9BFsQ.cjs} +1 -1
- package/dist/wc-forms/{VdSelect-Ct1Q_1S-.cjs → VdSelect-B4j-cyY6.cjs} +1 -1
- package/dist/wc-forms/bike.cjs +1 -1
- package/dist/wc-forms/{birthdate.schema-DdKmY-Zl.cjs → birthdate.schema-CuT2Aqpe.cjs} +1 -1
- package/dist/wc-forms/business-car.cjs +1 -1
- package/dist/wc-forms/business-liability.cjs +1 -1
- package/dist/wc-forms/car.cjs +1 -1
- package/dist/wc-forms/caravan.cjs +1 -1
- package/dist/wc-forms/{company.schema-q4xkCOzK.cjs → company.schema-DpWPXhO4.cjs} +1 -1
- package/dist/wc-forms/{familyComposition.schema-EG-0badX.cjs → familyComposition.schema-u1IYRIgy.cjs} +1 -1
- package/dist/wc-forms/house.cjs +1 -1
- package/dist/wc-forms/{houseOwnedBuilding.model-DXAXbpgh.cjs → houseOwnedBuilding.model-35rOS2XM.cjs} +1 -1
- package/dist/wc-forms/legal.cjs +1 -1
- package/dist/wc-forms/liability.cjs +1 -1
- package/dist/wc-forms/loan.cjs +1 -1
- package/dist/wc-forms/moped.cjs +1 -1
- package/dist/wc-forms/motor.cjs +1 -1
- package/dist/wc-forms/package.cjs +1 -1
- package/dist/wc-forms/pet.cjs +1 -1
- package/dist/wc-forms/{rules-B02tT9fM.cjs → rules-CezVc6vy.cjs} +1 -1
- package/dist/wc-forms/travel.cjs +1 -1
- package/dist/wc-forms/{useAddress-WM42C9IO.cjs → useAddress-DkDIySDc.cjs} +1 -1
- package/dist/wc-forms/{useLicensePlate-APOK4sXp.cjs → useLicensePlate-o3oR17m3.cjs} +1 -1
- package/dist/wc-forms/{useValidator-Ck2oPjtx.cjs → useValidator-DIKzHROh.cjs} +1 -1
- package/dist/wc-noitc/comparison-forms.umd.cjs +1 -1
- package/package.json +1 -1
|
@@ -1135,27 +1135,27 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1135
1135
|
]);
|
|
1136
1136
|
return (e, t) => (b(), i("div", { class: g(r.value) }, [w(e.$slots, "default")], 2));
|
|
1137
1137
|
}
|
|
1138
|
-
}), nn, rn, an = () => ({
|
|
1138
|
+
}), nn, rn, an = !1, on = () => ({
|
|
1139
1139
|
dataService: new we(),
|
|
1140
1140
|
dataValidationService: new Te(),
|
|
1141
1141
|
homeService: new Ee(),
|
|
1142
1142
|
comparisonService: new Ce()
|
|
1143
|
-
}),
|
|
1143
|
+
}), sn = () => (nn ||= on(), nn), cn = async () => {
|
|
1144
1144
|
if (!rn) throw Error("ITC client is not initialized.");
|
|
1145
1145
|
return rn;
|
|
1146
|
-
},
|
|
1146
|
+
}, ln = () => an, un = {
|
|
1147
1147
|
key: 0,
|
|
1148
1148
|
class: "vd-form__banner"
|
|
1149
|
-
},
|
|
1149
|
+
}, dn = ["innerHTML"], fn = {
|
|
1150
1150
|
key: 1,
|
|
1151
1151
|
class: "vd-form__header"
|
|
1152
|
-
},
|
|
1152
|
+
}, pn = {
|
|
1153
1153
|
key: 0,
|
|
1154
1154
|
class: "vd-form__title"
|
|
1155
|
-
},
|
|
1155
|
+
}, mn = {
|
|
1156
1156
|
key: 1,
|
|
1157
1157
|
class: "vd-form__description"
|
|
1158
|
-
},
|
|
1158
|
+
}, hn = {
|
|
1159
1159
|
key: 2,
|
|
1160
1160
|
class: "vd-afm"
|
|
1161
1161
|
}, Y = /* @__PURE__ */ l({
|
|
@@ -1189,14 +1189,16 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1189
1189
|
u("submit", e);
|
|
1190
1190
|
};
|
|
1191
1191
|
return v(async () => {
|
|
1192
|
-
|
|
1193
|
-
|
|
1192
|
+
if (ln()) {
|
|
1193
|
+
let e = (await cn()).getConfigurations().getAfmLicenseNumber();
|
|
1194
|
+
o.value = !!e;
|
|
1195
|
+
}
|
|
1194
1196
|
}), (t, n) => (b(), i("div", null, [a("form", {
|
|
1195
1197
|
class: g(f.value),
|
|
1196
1198
|
onSubmit: L(p, ["prevent", "stop"])
|
|
1197
1199
|
}, [
|
|
1198
|
-
D(d).banner || e.banner ? (b(), i("div",
|
|
1199
|
-
D(d).header || e.title || e.description ? (b(), i("div",
|
|
1200
|
+
D(d).banner || e.banner ? (b(), i("div", un, [w(t.$slots, "banner", {}, () => [a("span", { innerHTML: e.banner }, null, 8, dn)])])) : r("", !0),
|
|
1201
|
+
D(d).header || e.title || e.description ? (b(), i("div", fn, [w(t.$slots, "header", {}, () => [e.title ? (b(), i("h2", pn, E(e.title), 1)) : r("", !0), e.description ? (b(), i("p", mn, E(e.description), 1)) : r("", !0)])])) : r("", !0),
|
|
1200
1202
|
c(tn, null, {
|
|
1201
1203
|
default: F(() => [w(t.$slots, "default"), c(J, {
|
|
1202
1204
|
class: "vd-form__action",
|
|
@@ -1216,14 +1218,14 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1216
1218
|
}, 8, ["span", "md"])]),
|
|
1217
1219
|
_: 3
|
|
1218
1220
|
}),
|
|
1219
|
-
o.value ? r("", !0) : (b(), i("div",
|
|
1221
|
+
o.value ? r("", !0) : (b(), i("div", hn, [...n[0] ||= [a("p", { class: "vd-afm__text" }, [
|
|
1220
1222
|
s(" Bovenstaande vergelijkingsmodule beheerd door "),
|
|
1221
1223
|
a("a", { href: "https://vergelijkdirect.com" }, " Vergelijkdirect.com BV. "),
|
|
1222
1224
|
s(" Execution Only, geen advies. AFM-vergunning 12044269 ")
|
|
1223
1225
|
], -1)]]))
|
|
1224
1226
|
], 34)]));
|
|
1225
1227
|
}
|
|
1226
|
-
}),
|
|
1228
|
+
}), gn = /* @__PURE__ */ l({
|
|
1227
1229
|
__name: "VdFormGroup",
|
|
1228
1230
|
props: {
|
|
1229
1231
|
span: { default: null },
|
|
@@ -1278,7 +1280,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1278
1280
|
"required"
|
|
1279
1281
|
]));
|
|
1280
1282
|
}
|
|
1281
|
-
}),
|
|
1283
|
+
}), _n = /* @__PURE__ */ l({
|
|
1282
1284
|
inheritAttrs: !1,
|
|
1283
1285
|
__name: "VdFamilyCompositionSelect",
|
|
1284
1286
|
props: /*@__PURE__*/ p({
|
|
@@ -1331,19 +1333,19 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1331
1333
|
"required"
|
|
1332
1334
|
]));
|
|
1333
1335
|
}
|
|
1334
|
-
}),
|
|
1335
|
-
let n =
|
|
1336
|
+
}), vn = (e) => e.replace(/\["(\d+)"\]/g, "[$1]"), yn = (e, t) => `${e}${t}`, bn = (e) => (e.inner || []).reduce((e, t) => {
|
|
1337
|
+
let n = vn(t.path);
|
|
1336
1338
|
return e[n] || (e[n] = t.message), e;
|
|
1337
|
-
}, {}),
|
|
1339
|
+
}, {}), xn = (e) => {
|
|
1338
1340
|
if (!e.inner) throw e;
|
|
1339
|
-
return
|
|
1340
|
-
},
|
|
1341
|
+
return bn(e);
|
|
1342
|
+
}, Sn = { isValidating: !1 }, Cn = {
|
|
1341
1343
|
validateAt: "blur",
|
|
1342
1344
|
strict: !0,
|
|
1343
1345
|
abortEarly: !1
|
|
1344
|
-
},
|
|
1346
|
+
}, wn = Symbol("useValidator"), Z = (e, n, r) => {
|
|
1345
1347
|
let i = {
|
|
1346
|
-
...
|
|
1348
|
+
...Cn,
|
|
1347
1349
|
...r
|
|
1348
1350
|
}, a = pe(n), o = S(pe(a)), s = S({}), c = S(!1), l = S(!1), u = S({}), d = (e) => t({
|
|
1349
1351
|
get: () => v(e),
|
|
@@ -1373,7 +1375,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1373
1375
|
t === "input" && h(() => j(e));
|
|
1374
1376
|
}, T = (e, t) => {
|
|
1375
1377
|
let n = t?.validateAt ?? i.validateAt;
|
|
1376
|
-
return _(e,
|
|
1378
|
+
return _(e, Sn), [
|
|
1377
1379
|
d(e),
|
|
1378
1380
|
f(e, n),
|
|
1379
1381
|
p(e),
|
|
@@ -1381,10 +1383,10 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1381
1383
|
];
|
|
1382
1384
|
}, E = (e) => {
|
|
1383
1385
|
let t = d(e), n = (t, n) => {
|
|
1384
|
-
let r = n?.validateAt ?? i.validateAt, a =
|
|
1386
|
+
let r = n?.validateAt ?? i.validateAt, a = yn(e, t);
|
|
1385
1387
|
return f(a, r).value;
|
|
1386
1388
|
}, r = (t) => {
|
|
1387
|
-
let n =
|
|
1389
|
+
let n = yn(e, t);
|
|
1388
1390
|
return N(n);
|
|
1389
1391
|
};
|
|
1390
1392
|
return {
|
|
@@ -1392,7 +1394,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1392
1394
|
getAttrs: n,
|
|
1393
1395
|
getError: r,
|
|
1394
1396
|
getMeta: (t) => {
|
|
1395
|
-
let n =
|
|
1397
|
+
let n = yn(e, t);
|
|
1396
1398
|
return m(n);
|
|
1397
1399
|
},
|
|
1398
1400
|
arrayError: r(e),
|
|
@@ -1440,7 +1442,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1440
1442
|
abortEarly: i.abortEarly
|
|
1441
1443
|
}), o.value;
|
|
1442
1444
|
} catch (e) {
|
|
1443
|
-
let t =
|
|
1445
|
+
let t = xn(e);
|
|
1444
1446
|
M(t);
|
|
1445
1447
|
return;
|
|
1446
1448
|
} finally {
|
|
@@ -1454,7 +1456,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1454
1456
|
abortEarly: i.abortEarly
|
|
1455
1457
|
});
|
|
1456
1458
|
} catch (e) {
|
|
1457
|
-
let t =
|
|
1459
|
+
let t = xn(e);
|
|
1458
1460
|
M(t);
|
|
1459
1461
|
} finally {
|
|
1460
1462
|
_(t, { isValidating: !1 });
|
|
@@ -1492,18 +1494,18 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1492
1494
|
validateForm: A,
|
|
1493
1495
|
validateField: j
|
|
1494
1496
|
};
|
|
1495
|
-
return x(
|
|
1496
|
-
},
|
|
1497
|
-
let e = u(
|
|
1497
|
+
return x(wn, te), te;
|
|
1498
|
+
}, Tn = () => {
|
|
1499
|
+
let e = u(wn);
|
|
1498
1500
|
if (!e) throw Error("useValidatorContext must be used within a component that has called useValidator");
|
|
1499
1501
|
return e;
|
|
1500
|
-
},
|
|
1502
|
+
}, En = { class: "vd-field" }, Dn = {
|
|
1501
1503
|
key: 0,
|
|
1502
1504
|
class: "vd-field__message vd-field__message--error"
|
|
1503
|
-
},
|
|
1505
|
+
}, On = {
|
|
1504
1506
|
key: 1,
|
|
1505
1507
|
class: "vd-field__message vd-field__message--information"
|
|
1506
|
-
},
|
|
1508
|
+
}, kn = /* @__PURE__ */ l({
|
|
1507
1509
|
__name: "VdAddress",
|
|
1508
1510
|
props: /*@__PURE__*/ p({
|
|
1509
1511
|
path: { default: "address" },
|
|
@@ -1514,7 +1516,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1514
1516
|
}),
|
|
1515
1517
|
emits: ["update:resolvedAddress"],
|
|
1516
1518
|
setup(e) {
|
|
1517
|
-
let n = e, o = A(e, "resolvedAddress"), { path: l } = n, { defineField: u, validateField: f, getFieldMeta: p, getError: m, removeError: g } =
|
|
1519
|
+
let n = e, o = A(e, "resolvedAddress"), { path: l } = n, { defineField: u, validateField: f, getFieldMeta: p, getError: m, removeError: g } = Tn(), [_, , v] = u(`${l}.zipCode`), [x, , S] = u(`${l}.houseNumber`), [C, , w] = u(`${l}.houseNumberAddition`), T = async () => {
|
|
1518
1520
|
await f(l), C.value || g(`${l}.houseNumberAddition`);
|
|
1519
1521
|
}, O = (e) => {
|
|
1520
1522
|
_.value && x.value ? T() : f(e);
|
|
@@ -1525,7 +1527,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1525
1527
|
o.value = null;
|
|
1526
1528
|
}), y(() => {
|
|
1527
1529
|
_.value && x.value && T();
|
|
1528
|
-
}), (t, n) => (b(), i("div",
|
|
1530
|
+
}), (t, n) => (b(), i("div", En, [c(tn, null, {
|
|
1529
1531
|
default: F(() => [c(J, {
|
|
1530
1532
|
span: "5",
|
|
1531
1533
|
md: "3"
|
|
@@ -1552,7 +1554,7 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1552
1554
|
"loading"
|
|
1553
1555
|
])]),
|
|
1554
1556
|
_: 1
|
|
1555
|
-
}), c(
|
|
1557
|
+
}), c(gn, {
|
|
1556
1558
|
span: "7",
|
|
1557
1559
|
md: "3"
|
|
1558
1560
|
}, {
|
|
@@ -1598,59 +1600,59 @@ var tn = /*#__PURE__*/ Zt(Qt, [["render", en]]), J = /* @__PURE__ */ l({
|
|
|
1598
1600
|
_: 1
|
|
1599
1601
|
})]),
|
|
1600
1602
|
_: 1
|
|
1601
|
-
}), I.value ? (b(), i("div",
|
|
1603
|
+
}), I.value ? (b(), i("div", Dn, [n[3] ||= a("i", { class: "fas fa-exclamation-circle vd-field__message-icon" }, null, -1), s(" " + E(I.value), 1)])) : o.value ? (b(), i("div", On, [n[4] ||= a("i", { class: "fas fa-info-circle vd-field__message-icon" }, null, -1), s(" " + E(o.value.street) + ", " + E(o.value.city), 1)])) : r("", !0)]));
|
|
1602
1604
|
}
|
|
1603
|
-
}),
|
|
1605
|
+
}), An = (e) => ({
|
|
1604
1606
|
zipCode: e.ZipCode,
|
|
1605
1607
|
houseNumber: String(e.HouseNumber),
|
|
1606
1608
|
houseNumberAddition: e.HouseNumberAddition,
|
|
1607
1609
|
city: e.Place,
|
|
1608
1610
|
street: e.Street
|
|
1609
|
-
}),
|
|
1611
|
+
}), jn = /^\d{4}\s?[a-zA-Z]{2}$/, Mn = /^\d+$/, Nn = {
|
|
1610
1612
|
"needs-addition": "Een toevoeging is verplicht",
|
|
1611
1613
|
"not-found": "Postcode en huisnummer combinatie onbekend.",
|
|
1612
1614
|
error: "Adres ophalen is mislukt. Probeer het opnieuw."
|
|
1613
1615
|
};
|
|
1614
|
-
function
|
|
1616
|
+
function Pn(e) {
|
|
1615
1617
|
return e.replace(/\s/g, "").toUpperCase();
|
|
1616
1618
|
}
|
|
1617
|
-
var
|
|
1618
|
-
function
|
|
1619
|
-
return e ===
|
|
1619
|
+
var Fn = "NO_ADDITION";
|
|
1620
|
+
function In(e) {
|
|
1621
|
+
return e === Fn ? "" : e.replace("-", "");
|
|
1620
1622
|
}
|
|
1621
|
-
var
|
|
1622
|
-
if (
|
|
1623
|
+
var Ln = (e) => e instanceof Error, Rn = (e) => {
|
|
1624
|
+
if (Ln(e)) throw e;
|
|
1623
1625
|
return null;
|
|
1624
|
-
},
|
|
1626
|
+
}, zn = (e, t, n) => sn().dataValidationService.validateZipCode(e, t, n).then((e) => e).catch(Rn), Bn = (e, t) => sn().homeService.getAddition({
|
|
1625
1627
|
zipcode: e,
|
|
1626
1628
|
houseNumber: t
|
|
1627
|
-
}).then((e) => e ?? []).catch(
|
|
1628
|
-
let [n, r] = await Promise.all([
|
|
1629
|
+
}).then((e) => e ?? []).catch(Rn), Vn = async (e, t) => {
|
|
1630
|
+
let [n, r] = await Promise.all([zn(e, t), Bn(e, t)]);
|
|
1629
1631
|
return !n && !r?.length ? null : {
|
|
1630
1632
|
validWithoutAddition: !!n,
|
|
1631
1633
|
template: n,
|
|
1632
1634
|
additions: r ?? []
|
|
1633
1635
|
};
|
|
1634
|
-
},
|
|
1636
|
+
}, Hn = (e) => {
|
|
1635
1637
|
let t = e.additions.map((e) => ({
|
|
1636
1638
|
title: e,
|
|
1637
|
-
value:
|
|
1639
|
+
value: In(e)
|
|
1638
1640
|
}));
|
|
1639
1641
|
return e.validWithoutAddition && t.length ? [{
|
|
1640
1642
|
title: "Geen toevoeging",
|
|
1641
|
-
value:
|
|
1643
|
+
value: Fn
|
|
1642
1644
|
}, ...t] : t;
|
|
1643
|
-
},
|
|
1645
|
+
}, Un = (e) => ({
|
|
1644
1646
|
zipCode: e?.zipCode ?? "",
|
|
1645
1647
|
houseNumber: e?.houseNumber ?? "",
|
|
1646
|
-
houseNumberAddition: e ? e.houseNumberAddition ||
|
|
1647
|
-
}),
|
|
1648
|
-
let t = e?.path ?? "address", n =
|
|
1649
|
-
let t =
|
|
1648
|
+
houseNumberAddition: e ? e.houseNumberAddition || Fn : ""
|
|
1649
|
+
}), Wn = (e) => {
|
|
1650
|
+
let t = e?.path ?? "address", n = Un(e?.initial), r = S(null), i = S([]), a = 0, o = null, s = async (e) => {
|
|
1651
|
+
let t = Pn(e.zipCode), n = e.houseNumber.trim(), r = In(e.houseNumberAddition), i = `${t}:${n}`;
|
|
1650
1652
|
try {
|
|
1651
1653
|
let a = o?.key === i ? o : null;
|
|
1652
1654
|
if (!a) {
|
|
1653
|
-
let e = await
|
|
1655
|
+
let e = await Vn(t, n);
|
|
1654
1656
|
if (!e) return {
|
|
1655
1657
|
status: "not-found",
|
|
1656
1658
|
options: [],
|
|
@@ -1661,14 +1663,14 @@ var Fn = (e) => e instanceof Error, In = (e) => {
|
|
|
1661
1663
|
verdict: e
|
|
1662
1664
|
};
|
|
1663
1665
|
}
|
|
1664
|
-
let s =
|
|
1666
|
+
let s = Hn(a.verdict);
|
|
1665
1667
|
if (a.verdict.additions.length && !e.houseNumberAddition) return {
|
|
1666
1668
|
status: "needs-addition",
|
|
1667
1669
|
options: s,
|
|
1668
1670
|
address: null
|
|
1669
1671
|
};
|
|
1670
1672
|
if (!a.verdict.template) {
|
|
1671
|
-
let e = await
|
|
1673
|
+
let e = await zn(t, n, r);
|
|
1672
1674
|
if (!e) return {
|
|
1673
1675
|
status: "not-found",
|
|
1674
1676
|
options: [],
|
|
@@ -1693,7 +1695,7 @@ var Fn = (e) => e instanceof Error, In = (e) => {
|
|
|
1693
1695
|
}
|
|
1694
1696
|
}, c = async (e) => {
|
|
1695
1697
|
let t = ++a, n = await s(e), o = t !== a;
|
|
1696
|
-
return o || (i.value = n.options, r.value = n.address ?
|
|
1698
|
+
return o || (i.value = n.options, r.value = n.address ? An(n.address) : null), {
|
|
1697
1699
|
...n,
|
|
1698
1700
|
stale: o
|
|
1699
1701
|
};
|
|
@@ -1701,23 +1703,23 @@ var Fn = (e) => e instanceof Error, In = (e) => {
|
|
|
1701
1703
|
return {
|
|
1702
1704
|
path: t,
|
|
1703
1705
|
addressSchema: R({
|
|
1704
|
-
zipCode: z().required("Vul je postcode in").matches(
|
|
1705
|
-
houseNumber: z().required("Huisnummer is verplicht").matches(
|
|
1706
|
+
zipCode: z().required("Vul je postcode in").matches(jn, "Postcode is incorrect"),
|
|
1707
|
+
houseNumber: z().required("Huisnummer is verplicht").matches(Mn, "Huisnummer is incorrect"),
|
|
1706
1708
|
houseNumberAddition: z().defined()
|
|
1707
1709
|
}).test("address-lookup", async (e, t) => {
|
|
1708
|
-
let n =
|
|
1709
|
-
if (!
|
|
1710
|
+
let n = Pn(e.zipCode ?? ""), r = String(e.houseNumber ?? "").trim();
|
|
1711
|
+
if (!jn.test(n) || !Mn.test(r)) return !0;
|
|
1710
1712
|
let { status: i, stale: a } = await c(e);
|
|
1711
1713
|
return a || i === "resolved" ? !0 : i === "needs-addition" ? t.createError({
|
|
1712
1714
|
path: `${t.path}.houseNumberAddition`,
|
|
1713
|
-
message:
|
|
1714
|
-
}) : t.createError({ message:
|
|
1715
|
+
message: Nn[i]
|
|
1716
|
+
}) : t.createError({ message: Nn[i] });
|
|
1715
1717
|
}),
|
|
1716
1718
|
draft: n,
|
|
1717
1719
|
resolvedAddress: r,
|
|
1718
1720
|
additionOptions: i
|
|
1719
1721
|
};
|
|
1720
|
-
},
|
|
1722
|
+
}, Gn = {
|
|
1721
1723
|
[V.Car]: {
|
|
1722
1724
|
apiTypes: ["Car", "Van"],
|
|
1723
1725
|
dutch: "auto",
|
|
@@ -1738,14 +1740,14 @@ var Fn = (e) => e instanceof Error, In = (e) => {
|
|
|
1738
1740
|
dutch: "caravan",
|
|
1739
1741
|
icon: "fa-caravan-alt"
|
|
1740
1742
|
}
|
|
1741
|
-
},
|
|
1743
|
+
}, Kn = Object.fromEntries(Object.values(Gn).flatMap(({ apiTypes: e, icon: t }) => e.map((e) => [e.toLowerCase(), t]))), qn = {
|
|
1742
1744
|
brommobiel: "fa-car-side",
|
|
1743
1745
|
"speed pedelec": "fa-bicycle"
|
|
1744
|
-
},
|
|
1746
|
+
}, Jn = (e) => !!e?.Brand && !!e.Model && !!e.ManufacturingYear, Yn = (e) => {
|
|
1745
1747
|
if (!e) return "";
|
|
1746
1748
|
let t = String(e.Model ?? "").toLowerCase().trim(), n = String(e.VehicleType ?? "").toLowerCase();
|
|
1747
|
-
return
|
|
1748
|
-
},
|
|
1749
|
+
return qn[t] ?? Kn[n] ?? "";
|
|
1750
|
+
}, Xn = (e) => e ? `${e.Brand} ${e.Model} (${e.ManufacturingYear})` : "", Zn = [
|
|
1749
1751
|
"@@-##-@@",
|
|
1750
1752
|
"##-##-@@",
|
|
1751
1753
|
"##-@@-@@",
|
|
@@ -1763,22 +1765,22 @@ var Fn = (e) => e instanceof Error, In = (e) => {
|
|
|
1763
1765
|
];
|
|
1764
1766
|
//#endregion
|
|
1765
1767
|
//#region src/components/fields/licensePlate/licensePlate.util.ts
|
|
1766
|
-
function
|
|
1768
|
+
function Qn(e) {
|
|
1767
1769
|
return e.replace(/[\s\\-]/g, "");
|
|
1768
1770
|
}
|
|
1769
|
-
var
|
|
1770
|
-
function
|
|
1771
|
-
let t =
|
|
1772
|
-
if (t.length < 6) return
|
|
1773
|
-
let n = [...t].map((e) => /[0-9]/.test(e) ? "#" : "@").join(""), r =
|
|
1774
|
-
return r === -1 ?
|
|
1771
|
+
var $n = "*".repeat(6), er = Zn.map((e) => e.replace(/-/g, ""));
|
|
1772
|
+
function tr(e) {
|
|
1773
|
+
let t = Qn(e).slice(0, 6);
|
|
1774
|
+
if (t.length < 6) return $n;
|
|
1775
|
+
let n = [...t].map((e) => /[0-9]/.test(e) ? "#" : "@").join(""), r = er.indexOf(n);
|
|
1776
|
+
return r === -1 ? $n : Zn[r];
|
|
1775
1777
|
}
|
|
1776
1778
|
//#endregion
|
|
1777
1779
|
//#region src/components/fields/licensePlate/VdLicensePlate.vue?vue&type=script&setup=true&lang.ts
|
|
1778
|
-
var
|
|
1780
|
+
var nr = {
|
|
1779
1781
|
key: 0,
|
|
1780
1782
|
class: "vd-input-license-plate__loading-information"
|
|
1781
|
-
},
|
|
1783
|
+
}, rr = ["src"], ir = /* @__PURE__ */ l({
|
|
1782
1784
|
inheritAttrs: !1,
|
|
1783
1785
|
__name: "VdLicensePlate",
|
|
1784
1786
|
props: /*@__PURE__*/ p({
|
|
@@ -1801,16 +1803,16 @@ var er = {
|
|
|
1801
1803
|
}),
|
|
1802
1804
|
emits: /*@__PURE__*/ p(["input"], ["update:modelValue", "update:vehicleData"]),
|
|
1803
1805
|
setup(c, { emit: l }) {
|
|
1804
|
-
let u = { mask:
|
|
1806
|
+
let u = { mask: tr }, d = c, f = A(c, "modelValue"), p = A(c, "vehicleData"), h = l, g = O(), _ = j(), v = t({
|
|
1805
1807
|
get: () => f.value ?? "",
|
|
1806
1808
|
set: (e) => {
|
|
1807
1809
|
f.value = e, h("input", e);
|
|
1808
1810
|
}
|
|
1809
|
-
}), y = (e, t) =>
|
|
1811
|
+
}), y = (e, t) => Qn(e).toUpperCase() === Qn(t).toUpperCase();
|
|
1810
1812
|
P(f, (e) => {
|
|
1811
1813
|
p.value && !y(e, p.value.LicensePlate) && (p.value = null);
|
|
1812
1814
|
});
|
|
1813
|
-
let x = t(() =>
|
|
1815
|
+
let x = t(() => Jn(p.value) ? p.value : null), S = t(() => d.loading || !!x.value && !d.errorMessage), C = t(() => Yn(x.value)), T = t(() => Xn(x.value));
|
|
1814
1816
|
return (t, l) => (b(), n(Ge, m(D(g), {
|
|
1815
1817
|
modelValue: v.value,
|
|
1816
1818
|
"onUpdate:modelValue": l[0] ||= (e) => v.value = e,
|
|
@@ -1836,12 +1838,12 @@ var er = {
|
|
|
1836
1838
|
} : void 0,
|
|
1837
1839
|
S.value ? {
|
|
1838
1840
|
name: "information",
|
|
1839
|
-
fn: F(() => [c.loading ? (b(), i("div",
|
|
1841
|
+
fn: F(() => [c.loading ? (b(), i("div", nr, [...l[1] ||= [a("i", { class: "fas fa-circle-notch vd-input-license-plate__loading-icon" }, null, -1), s(" Voertuig gegevens ophalen... ", -1)]])) : x.value ? (b(), i(e, { key: 1 }, [C.value ? (b(), i("img", {
|
|
1840
1842
|
key: 0,
|
|
1841
1843
|
src: `https://d12bmfj3oyxu0t.cloudfront.net/vergelijkdirect/icons/${C.value}.svg`,
|
|
1842
1844
|
class: "vd-field__svg-message-icon",
|
|
1843
1845
|
alt: "vehicle-icon"
|
|
1844
|
-
}, null, 8,
|
|
1846
|
+
}, null, 8, rr)) : r("", !0), s(" " + E(T.value), 1)], 64)) : r("", !0)]),
|
|
1845
1847
|
key: "2"
|
|
1846
1848
|
} : void 0
|
|
1847
1849
|
]), 1040, [
|
|
@@ -1853,56 +1855,56 @@ var er = {
|
|
|
1853
1855
|
"loading"
|
|
1854
1856
|
]));
|
|
1855
1857
|
}
|
|
1856
|
-
}),
|
|
1857
|
-
"wrong-type": (e) => `Het ingevoerde kenteken is geen ${
|
|
1858
|
+
}), ar = /* @__PURE__ */ new Map(), or = (e, t) => `${t}:${e}`, sr = {
|
|
1859
|
+
"wrong-type": (e) => `Het ingevoerde kenteken is geen ${Gn[e].dutch}`,
|
|
1858
1860
|
unknown: () => "Voertuig onbekend - Voer ander kenteken in of neem contact op",
|
|
1859
1861
|
"not-found": () => "Kenteken onbekend",
|
|
1860
1862
|
error: () => "Kenteken is incorrect"
|
|
1861
|
-
},
|
|
1863
|
+
}, cr = async (e, t) => {
|
|
1862
1864
|
try {
|
|
1863
|
-
let n = await
|
|
1865
|
+
let n = await sn().dataService.findVehicle(e, t);
|
|
1864
1866
|
if (Array.isArray(n) || !n || !Object.keys(n).length) return { status: "not-found" };
|
|
1865
1867
|
let r = n;
|
|
1866
|
-
return r.VehicleType ?
|
|
1868
|
+
return r.VehicleType ? Gn[t].apiTypes.includes(r.VehicleType) ? {
|
|
1867
1869
|
status: "found",
|
|
1868
1870
|
data: r
|
|
1869
1871
|
} : { status: "wrong-type" } : { status: "unknown" };
|
|
1870
1872
|
} catch (e) {
|
|
1871
1873
|
return console.error("Error on ITC findVehicle", e), { status: "error" };
|
|
1872
1874
|
}
|
|
1873
|
-
},
|
|
1874
|
-
let n =
|
|
1875
|
-
return r || (r =
|
|
1876
|
-
e === "error" &&
|
|
1877
|
-
}, () =>
|
|
1878
|
-
},
|
|
1875
|
+
}, lr = (e, t) => {
|
|
1876
|
+
let n = or(e, t), r = ar.get(n);
|
|
1877
|
+
return r || (r = cr(e, t), ar.set(n, r), r.then(({ status: e }) => {
|
|
1878
|
+
e === "error" && ar.delete(n);
|
|
1879
|
+
}, () => ar.delete(n))), r;
|
|
1880
|
+
}, ur = (e, t = {}) => {
|
|
1879
1881
|
let n = S(t.initialData ?? null), r = 0;
|
|
1880
|
-
t.initialData?.LicensePlate &&
|
|
1882
|
+
t.initialData?.LicensePlate && ar.set(or(Qn(t.initialData.LicensePlate), e), Promise.resolve({
|
|
1881
1883
|
status: "found",
|
|
1882
1884
|
data: t.initialData
|
|
1883
1885
|
}));
|
|
1884
1886
|
let i = async (t) => {
|
|
1885
|
-
let i =
|
|
1887
|
+
let i = Qn(t), a = ++r, o = await lr(i, e);
|
|
1886
1888
|
return a === r && (n.value = o.status === "found" ? o.data : null), o;
|
|
1887
1889
|
};
|
|
1888
1890
|
return {
|
|
1889
1891
|
vehicleData: n,
|
|
1890
1892
|
licensePlateSchema: z().required("Dit veld is verplicht").test("license-plate-lookup", async (t, n) => {
|
|
1891
1893
|
if (!t) return !0;
|
|
1892
|
-
let r =
|
|
1894
|
+
let r = Qn(t);
|
|
1893
1895
|
if (r.length < 6) return n.createError({ message: "Kenteken is incorrect" });
|
|
1894
1896
|
let { status: a } = await i(r);
|
|
1895
|
-
return a === "found" || n.createError({ message:
|
|
1897
|
+
return a === "found" || n.createError({ message: sr[a](e) });
|
|
1896
1898
|
})
|
|
1897
1899
|
};
|
|
1898
|
-
},
|
|
1900
|
+
}, dr = (e) => /^\d{8}$/.test(e), fr = (e) => dr(e) ? {
|
|
1899
1901
|
companyName: "",
|
|
1900
1902
|
kvkNumber: e
|
|
1901
1903
|
} : {
|
|
1902
1904
|
companyName: e,
|
|
1903
1905
|
kvkNumber: ""
|
|
1904
|
-
},
|
|
1905
|
-
let t =
|
|
1906
|
+
}, pr = "bezoekadres", mr = (e) => e._embedded?.hoofdvestiging?.adressen?.find((e) => e.type === pr), hr = (e) => {
|
|
1907
|
+
let t = mr(e), { huisnummer: n = 0, huisletter: r = "", huisnummerToevoeging: i = "", toevoegingAdres: a = "", plaats: o = "", postcode: s = "", straatnaam: c = "", volledigAdres: l = "" } = t ?? {};
|
|
1906
1908
|
return {
|
|
1907
1909
|
houseNumber: n,
|
|
1908
1910
|
houseNumberAddition: r || i || a,
|
|
@@ -1912,7 +1914,7 @@ var er = {
|
|
|
1912
1914
|
fullAddress: l,
|
|
1913
1915
|
hasVisitingAddress: !!t
|
|
1914
1916
|
};
|
|
1915
|
-
},
|
|
1917
|
+
}, gr = (e = []) => {
|
|
1916
1918
|
let [t, n, r] = e.reduce(([e, t, n], r) => {
|
|
1917
1919
|
let i = {
|
|
1918
1920
|
isMainActivity: r.indHoofdactiviteit,
|
|
@@ -1935,20 +1937,20 @@ var er = {
|
|
|
1935
1937
|
firstSBIs: t,
|
|
1936
1938
|
secondSBIs: n
|
|
1937
1939
|
};
|
|
1938
|
-
},
|
|
1940
|
+
}, _r = (e) => ({
|
|
1939
1941
|
kvkNumber: e.kvkNummer,
|
|
1940
1942
|
name: e.naam,
|
|
1941
1943
|
city: e.adres?.binnenlandsAdres?.plaats ?? "",
|
|
1942
1944
|
street: e.adres?.binnenlandsAdres?.straatnaam ?? ""
|
|
1943
|
-
}),
|
|
1945
|
+
}), vr = (e) => ({
|
|
1944
1946
|
name: e.naam,
|
|
1945
1947
|
kvkNumber: e.kvkNummer,
|
|
1946
1948
|
industry: e.sbiIndustryId,
|
|
1947
1949
|
numberOfEmployees: e.totaalWerkzamePersonen,
|
|
1948
1950
|
legalForm: e._embedded?.eigenaar?.rechtsvorm ?? "",
|
|
1949
|
-
...
|
|
1950
|
-
...
|
|
1951
|
-
}),
|
|
1951
|
+
...hr(e),
|
|
1952
|
+
...gr(e.sbiActiviteiten)
|
|
1953
|
+
}), yr = 30, br = ["hoofdvestiging", "nevenvestiging"], xr = "IPD5200", Sr = (e) => {
|
|
1952
1954
|
let t = e, n = t?.response?.data?.fout;
|
|
1953
1955
|
if (Array.isArray(n)) return n;
|
|
1954
1956
|
if (Array.isArray(t?.fout)) return t.fout;
|
|
@@ -1956,24 +1958,24 @@ var er = {
|
|
|
1956
1958
|
let e = JSON.parse(t.message);
|
|
1957
1959
|
if (Array.isArray(e?.fout)) return e.fout;
|
|
1958
1960
|
} catch {}
|
|
1959
|
-
},
|
|
1961
|
+
}, Cr = (e) => Sr(e)?.some((e) => e.code === xr) ?? !1, wr = () => ({
|
|
1960
1962
|
search: async (e) => {
|
|
1961
1963
|
try {
|
|
1962
|
-
return ((await
|
|
1964
|
+
return ((await sn().dataService.searchBusinessInfoV2(fr(e), 1, yr))?.resultaten ?? []).filter((e) => br.includes(e.type)).map(_r);
|
|
1963
1965
|
} catch (e) {
|
|
1964
1966
|
let t = await e;
|
|
1965
|
-
if (
|
|
1967
|
+
if (Cr(t)) return [];
|
|
1966
1968
|
throw t;
|
|
1967
1969
|
}
|
|
1968
1970
|
},
|
|
1969
1971
|
getDetails: async (e) => {
|
|
1970
|
-
let t = await
|
|
1972
|
+
let t = await sn().dataService.getProfileInfo(e);
|
|
1971
1973
|
return {
|
|
1972
|
-
presenter:
|
|
1974
|
+
presenter: vr(t),
|
|
1973
1975
|
raw: t
|
|
1974
1976
|
};
|
|
1975
1977
|
}
|
|
1976
|
-
}),
|
|
1978
|
+
}), Tr = { class: "vd-combobox__multiline" }, Er = { class: "vd-combobox__title" }, Dr = { class: "vd-combobox__subtext" }, Or = { class: "vd-combobox__subtext" }, kr = 400, Ar = 3, jr = "Helaas, we hebben geen resultaten gevonden. Probeer te zoeken op de exacte naam waarmee je bedrijf is geregistreerd bij de Kamer van Koophandel, of gebruik je volledige KvK-nummer.", Mr = "Typ je bedrijfsnaam of KvK-nummer", Nr = "Aan het zoeken…", Pr = "Er ging iets mis bij het ophalen van de gegevens. Probeer het later opnieuw.", Fr = /* @__PURE__ */ l({
|
|
1977
1979
|
inheritAttrs: !1,
|
|
1978
1980
|
__name: "VdCompanySelect",
|
|
1979
1981
|
props: /*@__PURE__*/ p({
|
|
@@ -1992,7 +1994,7 @@ var er = {
|
|
|
1992
1994
|
"raw"
|
|
1993
1995
|
], ["update:modelValue"]),
|
|
1994
1996
|
setup(e, { emit: r }) {
|
|
1995
|
-
let i = r, s = O(), c = j(), l = A(e, "modelValue"), { search: u, getDetails: d } =
|
|
1997
|
+
let i = r, s = O(), c = j(), l = A(e, "modelValue"), { search: u, getDetails: d } = wr(), f = S(), p = S(), h = S(), g = S(""), _ = ge(g, kr, { maxWait: 2e3 }), v = S(!0), { state: y, isLoading: x, execute: C } = _e(async (e) => {
|
|
1996
1998
|
try {
|
|
1997
1999
|
return {
|
|
1998
2000
|
results: await u(e),
|
|
@@ -2015,20 +2017,20 @@ var er = {
|
|
|
2015
2017
|
let { presenter: t, raw: n } = await d(e);
|
|
2016
2018
|
return l.value = t, i("raw", n), i("error", null), t;
|
|
2017
2019
|
} catch (e) {
|
|
2018
|
-
throw l.value = null, i("raw", null), h.value = void 0, f.value = void 0, i("error",
|
|
2020
|
+
throw l.value = null, i("raw", null), h.value = void 0, f.value = void 0, i("error", Pr), e;
|
|
2019
2021
|
}
|
|
2020
2022
|
}, null, {
|
|
2021
2023
|
immediate: !1,
|
|
2022
2024
|
resetOnExecute: !0
|
|
2023
|
-
}), M = t(() => g.value.length >=
|
|
2025
|
+
}), M = t(() => g.value.length >= Ar), N = t(() => M.value ? x.value || g.value !== _.value ? "searching" : y.value.failed ? "error" : y.value.results.length ? "idle" : "no-results" : "idle"), I = t(() => N.value === "searching" ? [] : M.value ? y.value.results : v.value && h.value ? [h.value] : []), L = t(() => N.value === "searching" || T.value), ee = t(() => !!l.value && !L.value), te = t(() => {
|
|
2024
2026
|
let e = l.value;
|
|
2025
2027
|
return !e || L.value ? "" : e.fullAddress ? `Kvk: ${e.kvkNumber} ${e.fullAddress}` : `Kvk: ${e.kvkNumber}`;
|
|
2026
2028
|
}), ne = t(() => {
|
|
2027
2029
|
switch (N.value) {
|
|
2028
|
-
case "searching": return
|
|
2029
|
-
case "error": return
|
|
2030
|
-
case "no-results": return
|
|
2031
|
-
default: return
|
|
2030
|
+
case "searching": return Nr;
|
|
2031
|
+
case "error": return Pr;
|
|
2032
|
+
case "no-results": return jr;
|
|
2033
|
+
default: return Mr;
|
|
2032
2034
|
}
|
|
2033
2035
|
}), re = (e) => {
|
|
2034
2036
|
h.value = e, v.value = !0, e.kvkNumber === l.value?.kvkNumber ? i("error", null) : k(0, e.kvkNumber);
|
|
@@ -2046,7 +2048,7 @@ var er = {
|
|
|
2046
2048
|
return P(p, (e) => {
|
|
2047
2049
|
e || (g.value = "", v.value = !0);
|
|
2048
2050
|
}), P(_, (e) => {
|
|
2049
|
-
e && e.length >=
|
|
2051
|
+
e && e.length >= Ar && C(0, e);
|
|
2050
2052
|
}), P(l, (e) => {
|
|
2051
2053
|
f.value = e ? se(e) : void 0, v.value = !0, e || (h.value = void 0, i("raw", null));
|
|
2052
2054
|
}, { immediate: !0 }), (t, r) => (b(), n(Et, m(D(s), {
|
|
@@ -2074,10 +2076,10 @@ var er = {
|
|
|
2074
2076
|
onBlur: ie,
|
|
2075
2077
|
onSearch: ae
|
|
2076
2078
|
}), o({
|
|
2077
|
-
item: F(({ option: e }) => [a("div",
|
|
2078
|
-
a("div",
|
|
2079
|
-
a("span",
|
|
2080
|
-
a("span",
|
|
2079
|
+
item: F(({ option: e }) => [a("div", Tr, [
|
|
2080
|
+
a("div", Er, E(e.name), 1),
|
|
2081
|
+
a("span", Dr, "Kvk: " + E(e.kvkNumber), 1),
|
|
2082
|
+
a("span", Or, E(e.city) + ", " + E(e.street), 1)
|
|
2081
2083
|
])]),
|
|
2082
2084
|
_: 2
|
|
2083
2085
|
}, [D(c).popover ? {
|
|
@@ -2103,30 +2105,30 @@ var er = {
|
|
|
2103
2105
|
"info-message"
|
|
2104
2106
|
]));
|
|
2105
2107
|
}
|
|
2106
|
-
}),
|
|
2108
|
+
}), Ir = (e = "Bedrijfsnaam of KVK-nummer is verplicht") => Oe().nullable().required(e).test("has-kvk-number", e, (e) => !!e?.kvkNumber), Lr = {
|
|
2107
2109
|
min: 18,
|
|
2108
2110
|
max: 99
|
|
2109
|
-
},
|
|
2111
|
+
}, Rr = "DD-MM-YYYY", zr = [
|
|
2110
2112
|
H.SingleWithoutChildren,
|
|
2111
2113
|
H.FamilyWithoutChildren,
|
|
2112
2114
|
H.SingleWithChildren,
|
|
2113
2115
|
H.FamilyWithChildren
|
|
2114
|
-
],
|
|
2116
|
+
], Br = [U.Yes, U.No];
|
|
2115
2117
|
//#endregion
|
|
2116
2118
|
//#region src/utils/date.util.ts
|
|
2117
2119
|
Ae.extend(je);
|
|
2118
|
-
function
|
|
2120
|
+
function Vr() {
|
|
2119
2121
|
return Ae().startOf("day");
|
|
2120
2122
|
}
|
|
2121
|
-
function
|
|
2122
|
-
return
|
|
2123
|
+
function Hr() {
|
|
2124
|
+
return Vr().year();
|
|
2123
2125
|
}
|
|
2124
|
-
function
|
|
2126
|
+
function Ur(e, t) {
|
|
2125
2127
|
let n = Ae(e ?? "", t, !0);
|
|
2126
2128
|
return n.isValid() ? n.startOf("day") : null;
|
|
2127
2129
|
}
|
|
2128
|
-
function
|
|
2129
|
-
let n =
|
|
2130
|
+
function Wr(e, t) {
|
|
2131
|
+
let n = Vr();
|
|
2130
2132
|
return {
|
|
2131
2133
|
today: n,
|
|
2132
2134
|
earliest: n.subtract(t.value + 1, t.unit).add(1, "day"),
|
|
@@ -2135,28 +2137,28 @@ function Hr(e, t) {
|
|
|
2135
2137
|
}
|
|
2136
2138
|
//#endregion
|
|
2137
2139
|
//#region src/utils/familyComposition.util.ts
|
|
2138
|
-
var
|
|
2139
|
-
function
|
|
2140
|
-
return
|
|
2140
|
+
var Gr = [H.FamilyWithChildren, H.FamilyWithoutChildren];
|
|
2141
|
+
function Kr(e) {
|
|
2142
|
+
return Gr.includes(e);
|
|
2141
2143
|
}
|
|
2142
2144
|
//#endregion
|
|
2143
2145
|
//#region src/utils/url.util.ts
|
|
2144
|
-
var
|
|
2146
|
+
var qr = (e, t) => {
|
|
2145
2147
|
let [n, r = ""] = e.split("?"), i = new URLSearchParams(r);
|
|
2146
2148
|
return Object.entries(t).forEach(([e, t]) => i.set(e, t)), `${n}?${i.toString()}`;
|
|
2147
|
-
},
|
|
2149
|
+
}, Jr = (e, t) => {
|
|
2148
2150
|
let n = e.indexOf("#");
|
|
2149
|
-
return n === -1 ?
|
|
2151
|
+
return n === -1 ? qr(e, t) : `${e.slice(0, n + 1)}${qr(e.slice(n + 1), t)}`;
|
|
2150
2152
|
};
|
|
2151
2153
|
//#endregion
|
|
2152
2154
|
//#region src/schemas/birthdateRange.ts
|
|
2153
|
-
function
|
|
2155
|
+
function Yr(e, t, n = "ageRange") {
|
|
2154
2156
|
return {
|
|
2155
2157
|
name: n,
|
|
2156
2158
|
test(n, r) {
|
|
2157
|
-
let i =
|
|
2159
|
+
let i = Ur(n, Rr);
|
|
2158
2160
|
if (!i) return !0;
|
|
2159
|
-
let { today: a, earliest: o, latest: s } =
|
|
2161
|
+
let { today: a, earliest: o, latest: s } = Wr(e.min, e.max), c = {
|
|
2160
2162
|
earliest: o,
|
|
2161
2163
|
latest: s
|
|
2162
2164
|
};
|
|
@@ -2205,11 +2207,11 @@ var Q = {
|
|
|
2205
2207
|
};
|
|
2206
2208
|
//#endregion
|
|
2207
2209
|
//#region src/schemas/birthdate.schema.ts
|
|
2208
|
-
function
|
|
2209
|
-
return
|
|
2210
|
+
function Xr(e) {
|
|
2211
|
+
return Ur(e, Rr) !== null;
|
|
2210
2212
|
}
|
|
2211
|
-
function $(e =
|
|
2212
|
-
return z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat,
|
|
2213
|
+
function $(e = Lr) {
|
|
2214
|
+
return z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat, Xr).test(Yr({
|
|
2213
2215
|
min: {
|
|
2214
2216
|
value: e.min,
|
|
2215
2217
|
unit: "year"
|
|
@@ -2225,46 +2227,46 @@ function $(e = Fr) {
|
|
|
2225
2227
|
}
|
|
2226
2228
|
//#endregion
|
|
2227
2229
|
//#region src/schemas/rules.ts
|
|
2228
|
-
function
|
|
2230
|
+
function Zr(e, t) {
|
|
2229
2231
|
return z().required(t).oneOf(e, t);
|
|
2230
2232
|
}
|
|
2231
|
-
function
|
|
2233
|
+
function Qr(e) {
|
|
2232
2234
|
return z().required(e);
|
|
2233
2235
|
}
|
|
2234
|
-
function
|
|
2236
|
+
function $r(e) {
|
|
2235
2237
|
return ke().typeError(e).required(e);
|
|
2236
2238
|
}
|
|
2237
2239
|
//#endregion
|
|
2238
2240
|
//#region src/schemas/familyComposition.schema.ts
|
|
2239
|
-
function
|
|
2240
|
-
return
|
|
2241
|
+
function ei(e = Q.familyComposition.required) {
|
|
2242
|
+
return Zr(zr, e);
|
|
2241
2243
|
}
|
|
2242
|
-
var
|
|
2244
|
+
var ti = ei(), ni = Zr(Br, Q.ownedBuilding.required), ri = [1, 7], ii = [3, 4], ai = {
|
|
2243
2245
|
raceOrMtb: 15e3,
|
|
2244
2246
|
default: 9999
|
|
2245
|
-
},
|
|
2247
|
+
}, oi = {
|
|
2246
2248
|
mask: "N####",
|
|
2247
2249
|
tokens: { N: { pattern: /[1-9]/ } }
|
|
2248
|
-
},
|
|
2250
|
+
}, si = (e, t) => e.test("max-value", Q.bike.priceMax(t), (e) => {
|
|
2249
2251
|
let n = Number(e);
|
|
2250
2252
|
return Number.isNaN(n) || n <= t;
|
|
2251
|
-
}),
|
|
2252
|
-
kind:
|
|
2253
|
-
condition:
|
|
2253
|
+
}), ci = R({
|
|
2254
|
+
kind: $r(Q.bike.kindRequired),
|
|
2255
|
+
condition: $r(Q.bike.conditionRequired),
|
|
2254
2256
|
price: z().required(Q.bike.priceRequired).test("min-value", Q.bike.priceMin, (e) => {
|
|
2255
2257
|
if (!e) return !0;
|
|
2256
2258
|
let t = Number(e);
|
|
2257
2259
|
return Number.isNaN(t) || t > 0;
|
|
2258
2260
|
}).when("kind", {
|
|
2259
|
-
is: (e) =>
|
|
2260
|
-
then: (e) =>
|
|
2261
|
-
otherwise: (e) =>
|
|
2261
|
+
is: (e) => ii.includes(Number(e)),
|
|
2262
|
+
then: (e) => si(e, ai.raceOrMtb),
|
|
2263
|
+
otherwise: (e) => si(e, ai.default)
|
|
2262
2264
|
}),
|
|
2263
2265
|
brand: z().when("kind", {
|
|
2264
|
-
is: (e) =>
|
|
2266
|
+
is: (e) => ri.includes(Number(e)),
|
|
2265
2267
|
then: (e) => e.required(Q.bike.brandRequired)
|
|
2266
2268
|
})
|
|
2267
|
-
}),
|
|
2269
|
+
}), li = [
|
|
2268
2270
|
{
|
|
2269
2271
|
value: 4,
|
|
2270
2272
|
title: "ATB / Mountainbike",
|
|
@@ -2331,13 +2333,13 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
2331
2333
|
name: "Vouwfiets",
|
|
2332
2334
|
isEBike: !1
|
|
2333
2335
|
}
|
|
2334
|
-
],
|
|
2336
|
+
], ui = [{
|
|
2335
2337
|
value: 1,
|
|
2336
2338
|
label: "Nieuw"
|
|
2337
2339
|
}, {
|
|
2338
2340
|
value: 0,
|
|
2339
2341
|
label: "Tweedehands"
|
|
2340
|
-
}],
|
|
2342
|
+
}], di = [
|
|
2341
2343
|
{
|
|
2342
2344
|
id: "Ander merk",
|
|
2343
2345
|
name: "Ander merk"
|
|
@@ -3758,7 +3760,7 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3758
3760
|
id: "Zündapp",
|
|
3759
3761
|
name: "Zündapp"
|
|
3760
3762
|
}
|
|
3761
|
-
],
|
|
3763
|
+
], fi = /* @__PURE__ */ l({
|
|
3762
3764
|
__name: "BikeForm",
|
|
3763
3765
|
props: /*@__PURE__*/ f({
|
|
3764
3766
|
initialData: {},
|
|
@@ -3777,14 +3779,14 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3777
3779
|
}),
|
|
3778
3780
|
emits: ["submitted"],
|
|
3779
3781
|
setup(e, { emit: i }) {
|
|
3780
|
-
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, resetField: p } = Z(
|
|
3782
|
+
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, resetField: p } = Z(ci, {
|
|
3781
3783
|
kind: a.initialData?.kind ?? null,
|
|
3782
3784
|
condition: a.initialData?.condition ?? 1,
|
|
3783
3785
|
price: a.initialData?.price ?? "",
|
|
3784
3786
|
brand: a.initialData?.brand ?? ""
|
|
3785
|
-
}), [h, g, _] = f("kind", { validateAt: "change" }), [v, y, x] = f("brand", { validateAt: "change" }), [S, C, w] = f("condition"), [T, E, O] = f("price"), k = t(() =>
|
|
3787
|
+
}), [h, g, _] = f("kind", { validateAt: "change" }), [v, y, x] = f("brand", { validateAt: "change" }), [S, C, w] = f("condition"), [T, E, O] = f("price"), k = t(() => ri.includes(Number(h.value)));
|
|
3786
3788
|
P(h, (e) => {
|
|
3787
|
-
|
|
3789
|
+
ri.includes(Number(e)) || p("brand", { value: "" });
|
|
3788
3790
|
}, { immediate: !0 });
|
|
3789
3791
|
function A() {
|
|
3790
3792
|
u((e) => {
|
|
@@ -3805,7 +3807,7 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3805
3807
|
"onUpdate:modelValue": i[0] ||= (e) => d(h) ? h.value = e : null,
|
|
3806
3808
|
modelModifiers: { number: !0 },
|
|
3807
3809
|
label: "Soort fiets",
|
|
3808
|
-
options: D(
|
|
3810
|
+
options: D(li),
|
|
3809
3811
|
name: "kind",
|
|
3810
3812
|
required: !1,
|
|
3811
3813
|
"error-message": D(_)
|
|
@@ -3826,7 +3828,7 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3826
3828
|
"onUpdate:modelValue": i[1] ||= (e) => d(v) ? v.value = e : null,
|
|
3827
3829
|
label: "Merk fiets",
|
|
3828
3830
|
placeholder: "Typ of kies je merk",
|
|
3829
|
-
options: D(
|
|
3831
|
+
options: D(di),
|
|
3830
3832
|
"label-key": "name",
|
|
3831
3833
|
"value-key": "id",
|
|
3832
3834
|
name: "brand",
|
|
@@ -3848,7 +3850,7 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3848
3850
|
"onUpdate:modelValue": i[2] ||= (e) => d(S) ? S.value = e : null,
|
|
3849
3851
|
legend: "Gekocht als",
|
|
3850
3852
|
name: "condition",
|
|
3851
|
-
options: D(
|
|
3853
|
+
options: D(ui),
|
|
3852
3854
|
variant: "boxed",
|
|
3853
3855
|
required: !1,
|
|
3854
3856
|
"error-message": D(w)
|
|
@@ -3870,7 +3872,7 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3870
3872
|
placeholder: "bv. 1 000",
|
|
3871
3873
|
icon: "far fa-euro-sign",
|
|
3872
3874
|
name: "price",
|
|
3873
|
-
mask: D(
|
|
3875
|
+
mask: D(oi),
|
|
3874
3876
|
inputmode: "numeric",
|
|
3875
3877
|
required: !1,
|
|
3876
3878
|
"error-message": D(O)
|
|
@@ -3888,7 +3890,7 @@ var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4],
|
|
|
3888
3890
|
});
|
|
3889
3891
|
//#endregion
|
|
3890
3892
|
//#region src/comparisons/bike/bike.presenter.ts
|
|
3891
|
-
function
|
|
3893
|
+
function pi(e) {
|
|
3892
3894
|
return {
|
|
3893
3895
|
comparison: V.Bike,
|
|
3894
3896
|
detail: { bike: {
|
|
@@ -3902,27 +3904,27 @@ function di(e) {
|
|
|
3902
3904
|
}
|
|
3903
3905
|
//#endregion
|
|
3904
3906
|
//#region src/comparisons/pet/constants.ts
|
|
3905
|
-
var
|
|
3907
|
+
var mi = {
|
|
3906
3908
|
min: 0,
|
|
3907
3909
|
max: 99
|
|
3908
|
-
},
|
|
3910
|
+
}, hi = R({
|
|
3909
3911
|
kind: z().required(Q.pet.kindRequired),
|
|
3910
|
-
age: z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat,
|
|
3912
|
+
age: z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat, Xr).test(Yr({
|
|
3911
3913
|
min: {
|
|
3912
3914
|
value: 7,
|
|
3913
3915
|
unit: "week"
|
|
3914
3916
|
},
|
|
3915
3917
|
max: {
|
|
3916
|
-
value:
|
|
3918
|
+
value: mi.max,
|
|
3917
3919
|
unit: "year"
|
|
3918
3920
|
}
|
|
3919
3921
|
}, {
|
|
3920
|
-
future: () => Q.birthdate.tooYoung(
|
|
3921
|
-
tooYoung: ({ earliest: e, latest: t }) => Q.pet.outOfRange(e.format(
|
|
3922
|
-
tooOld: () => Q.birthdate.tooOld(
|
|
3922
|
+
future: () => Q.birthdate.tooYoung(mi.min),
|
|
3923
|
+
tooYoung: ({ earliest: e, latest: t }) => Q.pet.outOfRange(e.format(Rr), t.format(Rr)),
|
|
3924
|
+
tooOld: () => Q.birthdate.tooOld(mi.max)
|
|
3923
3925
|
}, "birthdate_range")),
|
|
3924
3926
|
zipCode: z().required(Q.pet.zipCodeRequired).matches(/^\d{4}\s?[a-zA-Z]{2}$/, Q.pet.zipCodeInvalid)
|
|
3925
|
-
}),
|
|
3927
|
+
}), gi = [
|
|
3926
3928
|
{
|
|
3927
3929
|
title: "Hond",
|
|
3928
3930
|
value: "dog"
|
|
@@ -3939,7 +3941,7 @@ var fi = {
|
|
|
3939
3941
|
title: "Vogel",
|
|
3940
3942
|
value: "bird"
|
|
3941
3943
|
}
|
|
3942
|
-
],
|
|
3944
|
+
], _i = /* @__PURE__ */ l({
|
|
3943
3945
|
__name: "PetForm",
|
|
3944
3946
|
props: /*@__PURE__*/ f({
|
|
3945
3947
|
initialData: {},
|
|
@@ -3958,7 +3960,7 @@ var fi = {
|
|
|
3958
3960
|
}),
|
|
3959
3961
|
emits: ["submitted"],
|
|
3960
3962
|
setup(e, { emit: t }) {
|
|
3961
|
-
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(
|
|
3963
|
+
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(hi, {
|
|
3962
3964
|
kind: r.initialData?.kind ?? "dog",
|
|
3963
3965
|
age: r.initialData?.age ?? "",
|
|
3964
3966
|
zipCode: r.initialData?.zipCode ?? ""
|
|
@@ -3982,7 +3984,7 @@ var fi = {
|
|
|
3982
3984
|
"onUpdate:modelValue": r[0] ||= (e) => d(u) ? u.value = e : null,
|
|
3983
3985
|
label: "Wat voor huisdier wil je verzekeren?",
|
|
3984
3986
|
placeholder: "",
|
|
3985
|
-
options: D(
|
|
3987
|
+
options: D(gi),
|
|
3986
3988
|
name: "kind",
|
|
3987
3989
|
required: !1,
|
|
3988
3990
|
"error-message": D(p)
|
|
@@ -4051,7 +4053,7 @@ var fi = {
|
|
|
4051
4053
|
});
|
|
4052
4054
|
//#endregion
|
|
4053
4055
|
//#region src/comparisons/pet/pet.presenter.ts
|
|
4054
|
-
function
|
|
4056
|
+
function vi(e) {
|
|
4055
4057
|
return {
|
|
4056
4058
|
comparison: V.Pet,
|
|
4057
4059
|
detail: { pet: {
|
|
@@ -4063,11 +4065,11 @@ function gi(e) {
|
|
|
4063
4065
|
}
|
|
4064
4066
|
//#endregion
|
|
4065
4067
|
//#region src/comparisons/caravan/caravan.schema.ts
|
|
4066
|
-
var
|
|
4067
|
-
TypeOfCaravan:
|
|
4068
|
-
NewOrOccasion:
|
|
4069
|
-
BuildYear:
|
|
4070
|
-
}),
|
|
4068
|
+
var yi = R({
|
|
4069
|
+
TypeOfCaravan: Qr(Q.caravan.typeOfCaravanRequired),
|
|
4070
|
+
NewOrOccasion: Zr(Br, Q.caravan.newOrOccasionRequired),
|
|
4071
|
+
BuildYear: Qr(Q.caravan.buildYearRequired)
|
|
4072
|
+
}), bi = [
|
|
4071
4073
|
{
|
|
4072
4074
|
value: "CS",
|
|
4073
4075
|
title: "Stacaravan"
|
|
@@ -4080,7 +4082,7 @@ var _i = R({
|
|
|
4080
4082
|
value: "CV",
|
|
4081
4083
|
title: "Vouwwagen"
|
|
4082
4084
|
}
|
|
4083
|
-
],
|
|
4085
|
+
], xi = [{
|
|
4084
4086
|
value: U.Yes,
|
|
4085
4087
|
label: "Nieuw"
|
|
4086
4088
|
}, {
|
|
@@ -4089,8 +4091,8 @@ var _i = R({
|
|
|
4089
4091
|
}];
|
|
4090
4092
|
//#endregion
|
|
4091
4093
|
//#region src/comparisons/caravan/models/buildYears.model.ts
|
|
4092
|
-
function
|
|
4093
|
-
let e =
|
|
4094
|
+
function Si() {
|
|
4095
|
+
let e = Hr();
|
|
4094
4096
|
return Array.from({ length: 126 }, (t, n) => ({
|
|
4095
4097
|
title: String(e - n),
|
|
4096
4098
|
value: String(e - n)
|
|
@@ -4098,7 +4100,7 @@ function bi() {
|
|
|
4098
4100
|
}
|
|
4099
4101
|
//#endregion
|
|
4100
4102
|
//#region src/comparisons/caravan/CaravanForm.vue
|
|
4101
|
-
var
|
|
4103
|
+
var Ci = /* @__PURE__ */ l({
|
|
4102
4104
|
__name: "CaravanForm",
|
|
4103
4105
|
props: /*@__PURE__*/ f({
|
|
4104
4106
|
initialData: {},
|
|
@@ -4117,7 +4119,7 @@ var xi = /* @__PURE__ */ l({
|
|
|
4117
4119
|
}),
|
|
4118
4120
|
emits: ["submitted"],
|
|
4119
4121
|
setup(e, { emit: t }) {
|
|
4120
|
-
let r = e, i = q(r), a = t, o =
|
|
4122
|
+
let r = e, i = q(r), a = t, o = Si(), { isSubmitting: s, handleSubmit: l, defineField: u } = Z(yi, {
|
|
4121
4123
|
TypeOfCaravan: r.initialData?.TypeOfCaravan ?? null,
|
|
4122
4124
|
NewOrOccasion: r.initialData?.NewOrOccasion ?? U.Yes,
|
|
4123
4125
|
BuildYear: r.initialData?.BuildYear ?? null
|
|
@@ -4140,7 +4142,7 @@ var xi = /* @__PURE__ */ l({
|
|
|
4140
4142
|
modelValue: D(f),
|
|
4141
4143
|
"onUpdate:modelValue": r[0] ||= (e) => d(f) ? f.value = e : null,
|
|
4142
4144
|
label: "Soort caravan",
|
|
4143
|
-
options: D(
|
|
4145
|
+
options: D(bi),
|
|
4144
4146
|
name: "typeOfCaravan",
|
|
4145
4147
|
required: !1,
|
|
4146
4148
|
"error-message": D(h)
|
|
@@ -4160,7 +4162,7 @@ var xi = /* @__PURE__ */ l({
|
|
|
4160
4162
|
"onUpdate:modelValue": r[1] ||= (e) => d(g) ? g.value = e : null,
|
|
4161
4163
|
legend: "Gekocht als",
|
|
4162
4164
|
name: "newOrOccasion",
|
|
4163
|
-
options: D(
|
|
4165
|
+
options: D(xi),
|
|
4164
4166
|
variant: "boxed",
|
|
4165
4167
|
required: !1,
|
|
4166
4168
|
"error-message": D(v)
|
|
@@ -4197,7 +4199,7 @@ var xi = /* @__PURE__ */ l({
|
|
|
4197
4199
|
});
|
|
4198
4200
|
//#endregion
|
|
4199
4201
|
//#region src/comparisons/caravan/caravan.presenter.ts
|
|
4200
|
-
function
|
|
4202
|
+
function wi(e) {
|
|
4201
4203
|
return {
|
|
4202
4204
|
comparison: V.Caravan,
|
|
4203
4205
|
detail: { caravan: {
|
|
@@ -4210,18 +4212,18 @@ function Si(e) {
|
|
|
4210
4212
|
}
|
|
4211
4213
|
//#endregion
|
|
4212
4214
|
//#region src/comparisons/travel/paymentTerm.enum.ts
|
|
4213
|
-
var
|
|
4215
|
+
var Ti = /* @__PURE__ */ function(e) {
|
|
4214
4216
|
return e.Continuous = "L", e.ShortTerm = "S", e;
|
|
4215
|
-
}({}),
|
|
4216
|
-
PaymentTerm:
|
|
4217
|
+
}({}), Ei = R({
|
|
4218
|
+
PaymentTerm: Zr([Ti.Continuous, Ti.ShortTerm], Q.travel.paymentTermRequired),
|
|
4217
4219
|
birthdate: $()
|
|
4218
|
-
}),
|
|
4219
|
-
value:
|
|
4220
|
+
}), Di = [{
|
|
4221
|
+
value: Ti.Continuous,
|
|
4220
4222
|
label: "Doorlopend"
|
|
4221
4223
|
}, {
|
|
4222
|
-
value:
|
|
4224
|
+
value: Ti.ShortTerm,
|
|
4223
4225
|
label: "Kortlopend"
|
|
4224
|
-
}],
|
|
4226
|
+
}], Oi = /* @__PURE__ */ l({
|
|
4225
4227
|
__name: "TravelForm",
|
|
4226
4228
|
props: /*@__PURE__*/ f({
|
|
4227
4229
|
initialData: {},
|
|
@@ -4240,8 +4242,8 @@ var Ci = /* @__PURE__ */ function(e) {
|
|
|
4240
4242
|
}),
|
|
4241
4243
|
emits: ["submitted"],
|
|
4242
4244
|
setup(e, { emit: t }) {
|
|
4243
|
-
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(
|
|
4244
|
-
PaymentTerm: r.initialData?.PaymentTerm ??
|
|
4245
|
+
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(Ei, {
|
|
4246
|
+
PaymentTerm: r.initialData?.PaymentTerm ?? Ti.Continuous,
|
|
4245
4247
|
birthdate: r.initialData?.birthdate ?? ""
|
|
4246
4248
|
}), [u, f, p] = l("PaymentTerm", { validateAt: "change" }), [h, g, _] = l("birthdate");
|
|
4247
4249
|
function v() {
|
|
@@ -4262,7 +4264,7 @@ var Ci = /* @__PURE__ */ function(e) {
|
|
|
4262
4264
|
"onUpdate:modelValue": r[0] ||= (e) => d(u) ? u.value = e : null,
|
|
4263
4265
|
legend: "Kies je dekking",
|
|
4264
4266
|
name: "PaymentTerm",
|
|
4265
|
-
options: D(
|
|
4267
|
+
options: D(Di),
|
|
4266
4268
|
variant: "boxed",
|
|
4267
4269
|
required: !1,
|
|
4268
4270
|
"error-message": D(p)
|
|
@@ -4300,7 +4302,7 @@ var Ci = /* @__PURE__ */ function(e) {
|
|
|
4300
4302
|
});
|
|
4301
4303
|
//#endregion
|
|
4302
4304
|
//#region src/comparisons/travel/travel.presenter.ts
|
|
4303
|
-
function
|
|
4305
|
+
function ki(e) {
|
|
4304
4306
|
return {
|
|
4305
4307
|
comparison: V.Travel,
|
|
4306
4308
|
detail: { comparison: { PaymentTerm: e.PaymentTerm } },
|
|
@@ -4309,11 +4311,11 @@ function Di(e) {
|
|
|
4309
4311
|
}
|
|
4310
4312
|
//#endregion
|
|
4311
4313
|
//#region src/comparisons/liability/liability.schema.ts
|
|
4312
|
-
var
|
|
4314
|
+
var Ai = (e) => R({
|
|
4313
4315
|
address: e,
|
|
4314
4316
|
birthdate: $(),
|
|
4315
|
-
familyComposition:
|
|
4316
|
-
}),
|
|
4317
|
+
familyComposition: ti
|
|
4318
|
+
}), ji = /* @__PURE__ */ l({
|
|
4317
4319
|
__name: "LiabilityForm",
|
|
4318
4320
|
props: /*@__PURE__*/ f({
|
|
4319
4321
|
initialData: {},
|
|
@@ -4332,7 +4334,7 @@ var Oi = (e) => R({
|
|
|
4332
4334
|
}),
|
|
4333
4335
|
emits: ["submitted"],
|
|
4334
4336
|
setup(e, { emit: t }) {
|
|
4335
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
4337
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Wn({ initial: r.initialData?.address }), { isSubmitting: f, handleSubmit: p, defineField: h } = Z(Ai(o), {
|
|
4336
4338
|
birthdate: r.initialData?.birthdate ?? "",
|
|
4337
4339
|
familyComposition: r.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4338
4340
|
address: s
|
|
@@ -4355,7 +4357,7 @@ var Oi = (e) => R({
|
|
|
4355
4357
|
span: "5",
|
|
4356
4358
|
md: "6"
|
|
4357
4359
|
}, {
|
|
4358
|
-
default: F(() => [c(D(
|
|
4360
|
+
default: F(() => [c(D(kn), {
|
|
4359
4361
|
"resolved-address": D(l),
|
|
4360
4362
|
"onUpdate:resolvedAddress": r[0] ||= (e) => d(l) ? l.value = e : null,
|
|
4361
4363
|
"addition-options": D(u)
|
|
@@ -4377,7 +4379,7 @@ var Oi = (e) => R({
|
|
|
4377
4379
|
span: "3",
|
|
4378
4380
|
md: "6"
|
|
4379
4381
|
}, {
|
|
4380
|
-
default: F(() => [c(D(
|
|
4382
|
+
default: F(() => [c(D(_n), m({
|
|
4381
4383
|
modelValue: D(y),
|
|
4382
4384
|
"onUpdate:modelValue": r[2] ||= (e) => d(y) ? y.value = e : null,
|
|
4383
4385
|
"error-message": D(S)
|
|
@@ -4391,7 +4393,7 @@ var Oi = (e) => R({
|
|
|
4391
4393
|
});
|
|
4392
4394
|
//#endregion
|
|
4393
4395
|
//#region src/comparisons/liability/liability.presenter.ts
|
|
4394
|
-
function
|
|
4396
|
+
function Mi(e) {
|
|
4395
4397
|
return {
|
|
4396
4398
|
comparison: V.Liability,
|
|
4397
4399
|
detail: { liability: {
|
|
@@ -4411,17 +4413,17 @@ function Ai(e) {
|
|
|
4411
4413
|
}
|
|
4412
4414
|
//#endregion
|
|
4413
4415
|
//#region src/models/houseOwnedBuilding.model.ts
|
|
4414
|
-
var
|
|
4416
|
+
var Ni = [{
|
|
4415
4417
|
value: U.Yes,
|
|
4416
4418
|
label: "Gekocht"
|
|
4417
4419
|
}, {
|
|
4418
4420
|
value: U.No,
|
|
4419
4421
|
label: "Gehuurd"
|
|
4420
|
-
}],
|
|
4422
|
+
}], Pi = (e) => R({
|
|
4421
4423
|
address: e,
|
|
4422
|
-
ownedBuilding:
|
|
4423
|
-
familyComposition:
|
|
4424
|
-
}),
|
|
4424
|
+
ownedBuilding: ni,
|
|
4425
|
+
familyComposition: ei(Q.house.familyCompositionRequired)
|
|
4426
|
+
}), Fi = /* @__PURE__ */ l({
|
|
4425
4427
|
__name: "HouseForm",
|
|
4426
4428
|
props: /*@__PURE__*/ f({
|
|
4427
4429
|
initialData: {},
|
|
@@ -4440,7 +4442,7 @@ var ji = [{
|
|
|
4440
4442
|
}),
|
|
4441
4443
|
emits: ["submitted"],
|
|
4442
4444
|
setup(e, { emit: t }) {
|
|
4443
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
4445
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Wn({ initial: r.initialData?.address }), { isSubmitting: f, handleSubmit: p, defineField: h } = Z(Pi(o), {
|
|
4444
4446
|
ownedBuilding: r.initialData?.ownedBuilding ?? U.Yes,
|
|
4445
4447
|
familyComposition: r.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4446
4448
|
address: s
|
|
@@ -4463,7 +4465,7 @@ var ji = [{
|
|
|
4463
4465
|
span: "4",
|
|
4464
4466
|
md: "6"
|
|
4465
4467
|
}, {
|
|
4466
|
-
default: F(() => [c(D(
|
|
4468
|
+
default: F(() => [c(D(kn), {
|
|
4467
4469
|
"resolved-address": D(l),
|
|
4468
4470
|
"onUpdate:resolvedAddress": r[0] ||= (e) => d(l) ? l.value = e : null,
|
|
4469
4471
|
"addition-options": D(u)
|
|
@@ -4479,7 +4481,7 @@ var ji = [{
|
|
|
4479
4481
|
"onUpdate:modelValue": r[1] ||= (e) => d(g) ? g.value = e : null,
|
|
4480
4482
|
legend: "Jouw woning is...",
|
|
4481
4483
|
name: "ownedBuilding",
|
|
4482
|
-
options: D(
|
|
4484
|
+
options: D(Ni),
|
|
4483
4485
|
variant: "boxed",
|
|
4484
4486
|
required: !1,
|
|
4485
4487
|
"error-message": D(v)
|
|
@@ -4494,7 +4496,7 @@ var ji = [{
|
|
|
4494
4496
|
span: "3",
|
|
4495
4497
|
md: "3"
|
|
4496
4498
|
}, {
|
|
4497
|
-
default: F(() => [c(D(
|
|
4499
|
+
default: F(() => [c(D(_n), m({
|
|
4498
4500
|
modelValue: D(y),
|
|
4499
4501
|
"onUpdate:modelValue": r[2] ||= (e) => d(y) ? y.value = e : null,
|
|
4500
4502
|
"error-message": D(S)
|
|
@@ -4508,7 +4510,7 @@ var ji = [{
|
|
|
4508
4510
|
});
|
|
4509
4511
|
//#endregion
|
|
4510
4512
|
//#region src/comparisons/house/house.presenter.ts
|
|
4511
|
-
function
|
|
4513
|
+
function Ii(e) {
|
|
4512
4514
|
return {
|
|
4513
4515
|
comparison: V.Housing,
|
|
4514
4516
|
detail: { house: { ownedBuilding: e.ownedBuilding } },
|
|
@@ -4524,10 +4526,10 @@ function Pi(e) {
|
|
|
4524
4526
|
}
|
|
4525
4527
|
//#endregion
|
|
4526
4528
|
//#region src/comparisons/legal/legal.schema.ts
|
|
4527
|
-
var
|
|
4529
|
+
var Li = (e) => R({
|
|
4528
4530
|
address: e,
|
|
4529
|
-
ownedBuilding:
|
|
4530
|
-
}),
|
|
4531
|
+
ownedBuilding: ni
|
|
4532
|
+
}), Ri = /* @__PURE__ */ l({
|
|
4531
4533
|
__name: "LegalForm",
|
|
4532
4534
|
props: /*@__PURE__*/ f({
|
|
4533
4535
|
initialData: {},
|
|
@@ -4546,7 +4548,7 @@ var Fi = (e) => R({
|
|
|
4546
4548
|
}),
|
|
4547
4549
|
emits: ["submitted"],
|
|
4548
4550
|
setup(e, { emit: t }) {
|
|
4549
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
4551
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Wn({ initial: r.initialData?.address }), { isSubmitting: f, handleSubmit: p, defineField: h } = Z(Li(o), {
|
|
4550
4552
|
ownedBuilding: r.initialData?.ownedBuilding ?? U.Yes,
|
|
4551
4553
|
address: s
|
|
4552
4554
|
}), [g, _, v] = h("ownedBuilding");
|
|
@@ -4566,7 +4568,7 @@ var Fi = (e) => R({
|
|
|
4566
4568
|
span: "5",
|
|
4567
4569
|
md: "6"
|
|
4568
4570
|
}, {
|
|
4569
|
-
default: F(() => [c(D(
|
|
4571
|
+
default: F(() => [c(D(kn), {
|
|
4570
4572
|
"resolved-address": D(l),
|
|
4571
4573
|
"onUpdate:resolvedAddress": r[0] ||= (e) => d(l) ? l.value = e : null,
|
|
4572
4574
|
"addition-options": D(u)
|
|
@@ -4581,7 +4583,7 @@ var Fi = (e) => R({
|
|
|
4581
4583
|
"onUpdate:modelValue": r[1] ||= (e) => d(g) ? g.value = e : null,
|
|
4582
4584
|
legend: "Jouw woning is...",
|
|
4583
4585
|
name: "ownedBuilding",
|
|
4584
|
-
options: D(
|
|
4586
|
+
options: D(Ni),
|
|
4585
4587
|
variant: "boxed",
|
|
4586
4588
|
required: !1,
|
|
4587
4589
|
"error-message": D(v)
|
|
@@ -4598,7 +4600,7 @@ var Fi = (e) => R({
|
|
|
4598
4600
|
});
|
|
4599
4601
|
//#endregion
|
|
4600
4602
|
//#region src/comparisons/legal/legal.presenter.ts
|
|
4601
|
-
function
|
|
4603
|
+
function zi(e) {
|
|
4602
4604
|
return {
|
|
4603
4605
|
comparison: V.LegalAssistance,
|
|
4604
4606
|
detail: { comparison: {
|
|
@@ -4616,15 +4618,15 @@ function Li(e) {
|
|
|
4616
4618
|
}
|
|
4617
4619
|
//#endregion
|
|
4618
4620
|
//#region src/comparisons/package/package.schema.ts
|
|
4619
|
-
var
|
|
4621
|
+
var Bi = (e) => R({
|
|
4620
4622
|
address: e,
|
|
4621
4623
|
birthdate: $(),
|
|
4622
|
-
familyComposition:
|
|
4624
|
+
familyComposition: ti,
|
|
4623
4625
|
partnerBirthdate: z().defined().when("familyComposition", {
|
|
4624
|
-
is:
|
|
4626
|
+
is: Kr,
|
|
4625
4627
|
then: () => $()
|
|
4626
4628
|
})
|
|
4627
|
-
}),
|
|
4629
|
+
}), Vi = /* @__PURE__ */ l({
|
|
4628
4630
|
__name: "PackageForm",
|
|
4629
4631
|
props: /*@__PURE__*/ f({
|
|
4630
4632
|
initialData: {},
|
|
@@ -4643,14 +4645,14 @@ var Ri = (e) => R({
|
|
|
4643
4645
|
}),
|
|
4644
4646
|
emits: ["submitted"],
|
|
4645
4647
|
setup(e, { emit: i }) {
|
|
4646
|
-
let a = e, o = q(a), s = i, { addressSchema: l, draft: u, resolvedAddress: f, additionOptions: p } =
|
|
4648
|
+
let a = e, o = q(a), s = i, { addressSchema: l, draft: u, resolvedAddress: f, additionOptions: p } = Wn({ initial: a.initialData?.address }), { isSubmitting: h, handleSubmit: g, defineField: _, resetField: v } = Z(Bi(l), {
|
|
4647
4649
|
birthdate: a.initialData?.birthdate ?? "",
|
|
4648
4650
|
familyComposition: a.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4649
4651
|
partnerBirthdate: a.initialData?.partnerBirthdate ?? "",
|
|
4650
4652
|
address: u
|
|
4651
|
-
}), [y, x, S] = _("birthdate"), [C, w, T] = _("familyComposition", { validateAt: "change" }), [E, O, k] = _("partnerBirthdate"), A = t(() =>
|
|
4653
|
+
}), [y, x, S] = _("birthdate"), [C, w, T] = _("familyComposition", { validateAt: "change" }), [E, O, k] = _("partnerBirthdate"), A = t(() => Kr(C.value));
|
|
4652
4654
|
P(C, (e) => {
|
|
4653
|
-
|
|
4655
|
+
Kr(e) || v("partnerBirthdate", { value: "" });
|
|
4654
4656
|
}, { immediate: !0 });
|
|
4655
4657
|
function j() {
|
|
4656
4658
|
g(({ birthdate: e, familyComposition: t, partnerBirthdate: n }) => {
|
|
@@ -4671,7 +4673,7 @@ var Ri = (e) => R({
|
|
|
4671
4673
|
span: "4",
|
|
4672
4674
|
md: "6"
|
|
4673
4675
|
}, {
|
|
4674
|
-
default: F(() => [c(D(
|
|
4676
|
+
default: F(() => [c(D(kn), {
|
|
4675
4677
|
"resolved-address": D(f),
|
|
4676
4678
|
"onUpdate:resolvedAddress": i[0] ||= (e) => d(f) ? f.value = e : null,
|
|
4677
4679
|
"addition-options": D(p)
|
|
@@ -4694,7 +4696,7 @@ var Ri = (e) => R({
|
|
|
4694
4696
|
span: A.value ? 2 : 3,
|
|
4695
4697
|
md: "6"
|
|
4696
4698
|
}, {
|
|
4697
|
-
default: F(() => [c(D(
|
|
4699
|
+
default: F(() => [c(D(_n), m({
|
|
4698
4700
|
modelValue: D(C),
|
|
4699
4701
|
"onUpdate:modelValue": i[2] ||= (e) => d(C) ? C.value = e : null,
|
|
4700
4702
|
"error-message": D(T)
|
|
@@ -4722,7 +4724,7 @@ var Ri = (e) => R({
|
|
|
4722
4724
|
});
|
|
4723
4725
|
//#endregion
|
|
4724
4726
|
//#region src/comparisons/package/package.presenter.ts
|
|
4725
|
-
function
|
|
4727
|
+
function Hi(e) {
|
|
4726
4728
|
return {
|
|
4727
4729
|
comparison: V.Package,
|
|
4728
4730
|
detail: { partner: { birthdate: e.partnerBirthdate } },
|
|
@@ -4739,18 +4741,18 @@ function Bi(e) {
|
|
|
4739
4741
|
}
|
|
4740
4742
|
//#endregion
|
|
4741
4743
|
//#region src/comparisons/loan/constants.ts
|
|
4742
|
-
var
|
|
4744
|
+
var Ui = {
|
|
4743
4745
|
min: 21,
|
|
4744
4746
|
max: 74
|
|
4745
|
-
},
|
|
4747
|
+
}, Wi = {
|
|
4746
4748
|
min: 3500,
|
|
4747
4749
|
max: 75e3
|
|
4748
|
-
},
|
|
4750
|
+
}, Gi = R({
|
|
4749
4751
|
LoanPurpose: z().required(Q.loan.purposeRequired),
|
|
4750
|
-
LoanAmount:
|
|
4751
|
-
birthdate: $(
|
|
4752
|
-
familyComposition:
|
|
4753
|
-
}),
|
|
4752
|
+
LoanAmount: $r(Q.loan.amountRequired).min(Wi.min, Q.loan.amountMin(Wi.min)).max(Wi.max, Q.loan.amountMax(Wi.max)),
|
|
4753
|
+
birthdate: $(Ui),
|
|
4754
|
+
familyComposition: ti
|
|
4755
|
+
}), Ki = [
|
|
4754
4756
|
{
|
|
4755
4757
|
title: "Aankoop auto",
|
|
4756
4758
|
value: "02"
|
|
@@ -4799,7 +4801,7 @@ var Vi = {
|
|
|
4799
4801
|
title: "Anders",
|
|
4800
4802
|
value: "99"
|
|
4801
4803
|
}
|
|
4802
|
-
],
|
|
4804
|
+
], qi = /* @__PURE__ */ l({
|
|
4803
4805
|
__name: "LoanForm",
|
|
4804
4806
|
props: /*@__PURE__*/ f({
|
|
4805
4807
|
initialData: {},
|
|
@@ -4818,7 +4820,7 @@ var Vi = {
|
|
|
4818
4820
|
}),
|
|
4819
4821
|
emits: ["submitted"],
|
|
4820
4822
|
setup(e, { emit: t }) {
|
|
4821
|
-
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(
|
|
4823
|
+
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(Gi, {
|
|
4822
4824
|
LoanPurpose: r.initialData?.LoanPurpose ?? "",
|
|
4823
4825
|
LoanAmount: r.initialData?.LoanAmount ?? null,
|
|
4824
4826
|
birthdate: r.initialData?.birthdate ?? "",
|
|
@@ -4843,7 +4845,7 @@ var Vi = {
|
|
|
4843
4845
|
"onUpdate:modelValue": r[0] ||= (e) => d(u) ? u.value = e : null,
|
|
4844
4846
|
label: "Leendoel",
|
|
4845
4847
|
placeholder: "Maak een keuze",
|
|
4846
|
-
options: D(
|
|
4848
|
+
options: D(Ki),
|
|
4847
4849
|
name: "LoanPurpose",
|
|
4848
4850
|
required: !1,
|
|
4849
4851
|
"error-message": D(p)
|
|
@@ -4888,7 +4890,7 @@ var Vi = {
|
|
|
4888
4890
|
span: "3",
|
|
4889
4891
|
md: "6"
|
|
4890
4892
|
}, {
|
|
4891
|
-
default: F(() => [c(D(
|
|
4893
|
+
default: F(() => [c(D(_n), m({
|
|
4892
4894
|
modelValue: D(S),
|
|
4893
4895
|
"onUpdate:modelValue": r[3] ||= (e) => d(S) ? S.value = e : null,
|
|
4894
4896
|
"error-message": D(w)
|
|
@@ -4902,19 +4904,19 @@ var Vi = {
|
|
|
4902
4904
|
});
|
|
4903
4905
|
//#endregion
|
|
4904
4906
|
//#region src/comparisons/loan/loan.presenter.ts
|
|
4905
|
-
function
|
|
4906
|
-
let t =
|
|
4907
|
+
function Ji(e) {
|
|
4908
|
+
let t = Ur(e, Rr);
|
|
4907
4909
|
if (!t) return 120;
|
|
4908
4910
|
let n = t.add(76, "year").diff(Ae(), "month", !0), r = Math.floor(n / 12) * 12;
|
|
4909
4911
|
return Math.min(r, 120);
|
|
4910
4912
|
}
|
|
4911
|
-
function
|
|
4913
|
+
function Yi(e) {
|
|
4912
4914
|
return {
|
|
4913
4915
|
comparison: V.Loan,
|
|
4914
4916
|
detail: { loan: {
|
|
4915
4917
|
LoanPurpose: e.LoanPurpose,
|
|
4916
4918
|
LoanAmount: e.LoanAmount,
|
|
4917
|
-
MaxDurationByLegalLimit:
|
|
4919
|
+
MaxDurationByLegalLimit: Ji(e.birthdate)
|
|
4918
4920
|
} },
|
|
4919
4921
|
user: {
|
|
4920
4922
|
birthdate: e.birthdate,
|
|
@@ -4924,14 +4926,14 @@ function qi(e) {
|
|
|
4924
4926
|
}
|
|
4925
4927
|
//#endregion
|
|
4926
4928
|
//#region src/comparisons/moped/constants.ts
|
|
4927
|
-
var
|
|
4929
|
+
var Xi = {
|
|
4928
4930
|
min: 16,
|
|
4929
4931
|
max: 99
|
|
4930
|
-
},
|
|
4932
|
+
}, Zi = (e, t) => R({
|
|
4931
4933
|
licensePlate: e,
|
|
4932
4934
|
address: t,
|
|
4933
|
-
birthdate: $(
|
|
4934
|
-
}),
|
|
4935
|
+
birthdate: $(Xi)
|
|
4936
|
+
}), Qi = /* @__PURE__ */ l({
|
|
4935
4937
|
__name: "MopedForm",
|
|
4936
4938
|
props: /*@__PURE__*/ f({
|
|
4937
4939
|
initialData: {},
|
|
@@ -4950,7 +4952,7 @@ var Ji = {
|
|
|
4950
4952
|
}),
|
|
4951
4953
|
emits: ["submitted"],
|
|
4952
4954
|
setup(e, { emit: t }) {
|
|
4953
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
4955
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Wn({ initial: r.initialData?.address }), { vehicleData: f, licensePlateSchema: p } = ur(V.Moped, { initialData: r.initialData?.vehicle ?? void 0 }), { isSubmitting: h, handleSubmit: g, defineField: _ } = Z(Zi(p, o), {
|
|
4954
4956
|
licensePlate: r.initialData?.licensePlate ?? "",
|
|
4955
4957
|
birthdate: r.initialData?.birthdate ?? "",
|
|
4956
4958
|
address: s
|
|
@@ -4974,7 +4976,7 @@ var Ji = {
|
|
|
4974
4976
|
span: "3",
|
|
4975
4977
|
md: "6"
|
|
4976
4978
|
}, {
|
|
4977
|
-
default: F(() => [c(D(
|
|
4979
|
+
default: F(() => [c(D(ir), m({
|
|
4978
4980
|
modelValue: D(v),
|
|
4979
4981
|
"onUpdate:modelValue": r[0] ||= (e) => d(v) ? v.value = e : null,
|
|
4980
4982
|
"vehicle-data": D(f),
|
|
@@ -5005,7 +5007,7 @@ var Ji = {
|
|
|
5005
5007
|
span: "4",
|
|
5006
5008
|
md: "6"
|
|
5007
5009
|
}, {
|
|
5008
|
-
default: F(() => [c(D(
|
|
5010
|
+
default: F(() => [c(D(kn), {
|
|
5009
5011
|
"resolved-address": D(l),
|
|
5010
5012
|
"onUpdate:resolvedAddress": r[2] ||= (e) => d(l) ? l.value = e : null,
|
|
5011
5013
|
"addition-options": D(u)
|
|
@@ -5031,7 +5033,7 @@ var Ji = {
|
|
|
5031
5033
|
});
|
|
5032
5034
|
//#endregion
|
|
5033
5035
|
//#region src/comparisons/moped/moped.presenter.ts
|
|
5034
|
-
function
|
|
5036
|
+
function $i(e) {
|
|
5035
5037
|
return {
|
|
5036
5038
|
comparison: V.Moped,
|
|
5037
5039
|
detail: { moped: { ...e.vehicle } },
|
|
@@ -5048,11 +5050,11 @@ function Zi(e) {
|
|
|
5048
5050
|
}
|
|
5049
5051
|
//#endregion
|
|
5050
5052
|
//#region src/comparisons/motor/motor.schema.ts
|
|
5051
|
-
var
|
|
5053
|
+
var ea = (e, t) => R({
|
|
5052
5054
|
licensePlate: e,
|
|
5053
5055
|
address: t,
|
|
5054
5056
|
birthdate: $()
|
|
5055
|
-
}),
|
|
5057
|
+
}), ta = /* @__PURE__ */ l({
|
|
5056
5058
|
__name: "MotorForm",
|
|
5057
5059
|
props: /*@__PURE__*/ f({
|
|
5058
5060
|
initialData: {},
|
|
@@ -5071,7 +5073,7 @@ var Qi = (e, t) => R({
|
|
|
5071
5073
|
}),
|
|
5072
5074
|
emits: ["submitted"],
|
|
5073
5075
|
setup(e, { emit: t }) {
|
|
5074
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
5076
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Wn({ initial: r.initialData?.address }), { vehicleData: f, licensePlateSchema: p } = ur(V.Motor, { initialData: r.initialData?.vehicle ?? void 0 }), { isSubmitting: h, handleSubmit: g, defineField: _ } = Z(ea(p, o), {
|
|
5075
5077
|
licensePlate: r.initialData?.licensePlate ?? "",
|
|
5076
5078
|
birthdate: r.initialData?.birthdate ?? "",
|
|
5077
5079
|
address: s
|
|
@@ -5095,7 +5097,7 @@ var Qi = (e, t) => R({
|
|
|
5095
5097
|
span: "3",
|
|
5096
5098
|
md: "6"
|
|
5097
5099
|
}, {
|
|
5098
|
-
default: F(() => [c(D(
|
|
5100
|
+
default: F(() => [c(D(ir), m({
|
|
5099
5101
|
modelValue: D(v),
|
|
5100
5102
|
"onUpdate:modelValue": r[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5101
5103
|
"vehicle-data": D(f),
|
|
@@ -5126,7 +5128,7 @@ var Qi = (e, t) => R({
|
|
|
5126
5128
|
span: "4",
|
|
5127
5129
|
md: "6"
|
|
5128
5130
|
}, {
|
|
5129
|
-
default: F(() => [c(D(
|
|
5131
|
+
default: F(() => [c(D(kn), {
|
|
5130
5132
|
"resolved-address": D(l),
|
|
5131
5133
|
"onUpdate:resolvedAddress": r[2] ||= (e) => d(l) ? l.value = e : null,
|
|
5132
5134
|
"addition-options": D(u)
|
|
@@ -5152,7 +5154,7 @@ var Qi = (e, t) => R({
|
|
|
5152
5154
|
});
|
|
5153
5155
|
//#endregion
|
|
5154
5156
|
//#region src/comparisons/motor/motor.presenter.ts
|
|
5155
|
-
function
|
|
5157
|
+
function na(e) {
|
|
5156
5158
|
return {
|
|
5157
5159
|
comparison: V.Motor,
|
|
5158
5160
|
detail: { motor: { ...e.vehicle } },
|
|
@@ -5169,11 +5171,11 @@ function ea(e) {
|
|
|
5169
5171
|
}
|
|
5170
5172
|
//#endregion
|
|
5171
5173
|
//#region src/comparisons/car/car.schema.ts
|
|
5172
|
-
var
|
|
5174
|
+
var ra = (e, t) => R({
|
|
5173
5175
|
licensePlate: e,
|
|
5174
5176
|
address: t,
|
|
5175
5177
|
birthdate: $()
|
|
5176
|
-
}),
|
|
5178
|
+
}), ia = /* @__PURE__ */ l({
|
|
5177
5179
|
__name: "CarForm",
|
|
5178
5180
|
props: /*@__PURE__*/ f({
|
|
5179
5181
|
initialData: {},
|
|
@@ -5192,7 +5194,7 @@ var ta = (e, t) => R({
|
|
|
5192
5194
|
}),
|
|
5193
5195
|
emits: ["submitted"],
|
|
5194
5196
|
setup(e, { emit: t }) {
|
|
5195
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
5197
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Wn({ initial: r.initialData?.address }), { vehicleData: f, licensePlateSchema: p } = ur(V.Car, { initialData: r.initialData?.vehicle ?? void 0 }), { isSubmitting: h, handleSubmit: g, defineField: _ } = Z(ra(p, o), {
|
|
5196
5198
|
licensePlate: r.initialData?.licensePlate ?? "",
|
|
5197
5199
|
birthdate: r.initialData?.birthdate ?? "",
|
|
5198
5200
|
address: s
|
|
@@ -5216,7 +5218,7 @@ var ta = (e, t) => R({
|
|
|
5216
5218
|
span: "3",
|
|
5217
5219
|
md: "6"
|
|
5218
5220
|
}, {
|
|
5219
|
-
default: F(() => [c(D(
|
|
5221
|
+
default: F(() => [c(D(ir), m({
|
|
5220
5222
|
modelValue: D(v),
|
|
5221
5223
|
"onUpdate:modelValue": r[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5222
5224
|
"vehicle-data": D(f),
|
|
@@ -5247,7 +5249,7 @@ var ta = (e, t) => R({
|
|
|
5247
5249
|
span: "4",
|
|
5248
5250
|
md: "6"
|
|
5249
5251
|
}, {
|
|
5250
|
-
default: F(() => [c(D(
|
|
5252
|
+
default: F(() => [c(D(kn), {
|
|
5251
5253
|
"resolved-address": D(l),
|
|
5252
5254
|
"onUpdate:resolvedAddress": r[2] ||= (e) => d(l) ? l.value = e : null,
|
|
5253
5255
|
"addition-options": D(u)
|
|
@@ -5273,7 +5275,7 @@ var ta = (e, t) => R({
|
|
|
5273
5275
|
});
|
|
5274
5276
|
//#endregion
|
|
5275
5277
|
//#region src/comparisons/car/car.presenter.ts
|
|
5276
|
-
function
|
|
5278
|
+
function aa(e) {
|
|
5277
5279
|
return {
|
|
5278
5280
|
comparison: V.Car,
|
|
5279
5281
|
detail: { car: { ...e.vehicle } },
|
|
@@ -5290,10 +5292,10 @@ function ra(e) {
|
|
|
5290
5292
|
}
|
|
5291
5293
|
//#endregion
|
|
5292
5294
|
//#region src/comparisons/car-business/businessCar.schema.ts
|
|
5293
|
-
var
|
|
5295
|
+
var oa = (e) => R({
|
|
5294
5296
|
licensePlate: e,
|
|
5295
|
-
company:
|
|
5296
|
-
}),
|
|
5297
|
+
company: Ir()
|
|
5298
|
+
}), sa = /* @__PURE__ */ l({
|
|
5297
5299
|
__name: "BusinessCarForm",
|
|
5298
5300
|
props: /*@__PURE__*/ f({
|
|
5299
5301
|
initialData: {},
|
|
@@ -5312,7 +5314,7 @@ var ia = (e) => R({
|
|
|
5312
5314
|
}),
|
|
5313
5315
|
emits: ["submitted"],
|
|
5314
5316
|
setup(e, { emit: i }) {
|
|
5315
|
-
let a = e, o = q(a), s = i, { vehicleData: l, licensePlateSchema: u } =
|
|
5317
|
+
let a = e, o = q(a), s = i, { vehicleData: l, licensePlateSchema: u } = ur(V.Car, { initialData: a.initialData?.vehicle ?? void 0 }), { isSubmitting: f, handleSubmit: p, defineField: h, setErrors: g, removeError: _ } = Z(oa(u), {
|
|
5316
5318
|
licensePlate: a.initialData?.licensePlate ?? "",
|
|
5317
5319
|
company: a.initialData?.company ?? null
|
|
5318
5320
|
}), [v, y, x, S] = h("licensePlate"), [C, w, T] = h("company"), E = (e) => e ? g({ company: e }) : _("company"), O = t(() => !!C.value && !C.value.hasVisitingAddress);
|
|
@@ -5333,7 +5335,7 @@ var ia = (e) => R({
|
|
|
5333
5335
|
span: "5",
|
|
5334
5336
|
md: "6"
|
|
5335
5337
|
}, {
|
|
5336
|
-
default: F(() => [c(D(
|
|
5338
|
+
default: F(() => [c(D(ir), m({
|
|
5337
5339
|
modelValue: D(v),
|
|
5338
5340
|
"onUpdate:modelValue": i[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5339
5341
|
"vehicle-data": D(l),
|
|
@@ -5363,7 +5365,7 @@ var ia = (e) => R({
|
|
|
5363
5365
|
span: "5",
|
|
5364
5366
|
md: "6"
|
|
5365
5367
|
}, {
|
|
5366
|
-
default: F(() => [c(D(
|
|
5368
|
+
default: F(() => [c(D(Fr), m({
|
|
5367
5369
|
modelValue: D(C),
|
|
5368
5370
|
"onUpdate:modelValue": i[2] ||= (e) => d(C) ? C.value = e : null,
|
|
5369
5371
|
name: "company",
|
|
@@ -5392,7 +5394,7 @@ var ia = (e) => R({
|
|
|
5392
5394
|
});
|
|
5393
5395
|
//#endregion
|
|
5394
5396
|
//#region src/comparisons/car-business/businessCar.presenter.ts
|
|
5395
|
-
function
|
|
5397
|
+
function ca(e) {
|
|
5396
5398
|
return {
|
|
5397
5399
|
comparison: V.CarBusiness,
|
|
5398
5400
|
detail: {
|
|
@@ -5404,7 +5406,7 @@ function oa(e) {
|
|
|
5404
5406
|
}
|
|
5405
5407
|
//#endregion
|
|
5406
5408
|
//#region src/comparisons/businessLiability/businessLiability.schema.ts
|
|
5407
|
-
var
|
|
5409
|
+
var la = R({ company: Ir() }), ua = /* @__PURE__ */ l({
|
|
5408
5410
|
__name: "BusinessLiabilityForm",
|
|
5409
5411
|
props: /*@__PURE__*/ f({
|
|
5410
5412
|
initialData: {},
|
|
@@ -5425,7 +5427,7 @@ var sa = R({ company: Pr() }), ca = /* @__PURE__ */ l({
|
|
|
5425
5427
|
}),
|
|
5426
5428
|
emits: ["submitted"],
|
|
5427
5429
|
setup(e, { emit: i }) {
|
|
5428
|
-
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(
|
|
5430
|
+
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(la, { company: a.initialData?.company ?? null }), [g, _, v] = f("company"), y = (e) => e ? p({ company: e }) : h("company"), x = t(() => !!g.value && !g.value.hasVisitingAddress);
|
|
5429
5431
|
function S() {
|
|
5430
5432
|
u(({ company: e }) => {
|
|
5431
5433
|
s("submitted", { company: e });
|
|
@@ -5440,7 +5442,7 @@ var sa = R({ company: Pr() }), ca = /* @__PURE__ */ l({
|
|
|
5440
5442
|
span: "8",
|
|
5441
5443
|
md: "6"
|
|
5442
5444
|
}, {
|
|
5443
|
-
default: F(() => [c(D(
|
|
5445
|
+
default: F(() => [c(D(Fr), m({
|
|
5444
5446
|
modelValue: D(g),
|
|
5445
5447
|
"onUpdate:modelValue": t[0] ||= (e) => d(g) ? g.value = e : null,
|
|
5446
5448
|
name: "company",
|
|
@@ -5469,7 +5471,7 @@ var sa = R({ company: Pr() }), ca = /* @__PURE__ */ l({
|
|
|
5469
5471
|
});
|
|
5470
5472
|
//#endregion
|
|
5471
5473
|
//#region src/comparisons/businessLiability/businessLiability.presenter.ts
|
|
5472
|
-
function
|
|
5474
|
+
function da(e) {
|
|
5473
5475
|
return {
|
|
5474
5476
|
comparison: V.BusinessLiability,
|
|
5475
5477
|
detail: { companyData: { ...e.company } },
|
|
@@ -5478,9 +5480,9 @@ function la(e) {
|
|
|
5478
5480
|
}
|
|
5479
5481
|
//#endregion
|
|
5480
5482
|
//#region src/flow/useComparisonSubmit.ts
|
|
5481
|
-
var
|
|
5483
|
+
var fa = { [V.Travel]: "/tarieven/" }, pa = (e, t, n) => `${e}#/${n}${fa[t] ?? ""}`, ma = (e) => {
|
|
5482
5484
|
window.location.href = e;
|
|
5483
|
-
},
|
|
5485
|
+
}, ha = ({ user: e, detail: t }) => new De({
|
|
5484
5486
|
email: e.email || null,
|
|
5485
5487
|
name: e.firstName || null,
|
|
5486
5488
|
zip_code: e.zipCode || null,
|
|
@@ -5494,14 +5496,14 @@ var ua = { [V.Travel]: "/tarieven/" }, da = (e, t, n) => `${e}#/${n}${ua[t] ?? "
|
|
|
5494
5496
|
...e.city && { city: e.city }
|
|
5495
5497
|
}
|
|
5496
5498
|
});
|
|
5497
|
-
function
|
|
5499
|
+
function ga(e) {
|
|
5498
5500
|
let t = S(!1), n = S(null);
|
|
5499
5501
|
return {
|
|
5500
5502
|
submit: async (r) => {
|
|
5501
5503
|
t.value = !0, n.value = null;
|
|
5502
5504
|
try {
|
|
5503
|
-
let t = await
|
|
5504
|
-
e.onRedirect ? e.onRedirect(n) :
|
|
5505
|
+
let t = await sn().comparisonService.create(r.comparison, ha(r)), n = pa(e.link, r.comparison, t.getId());
|
|
5506
|
+
e.onRedirect ? e.onRedirect(n) : ma(n);
|
|
5505
5507
|
} catch (t) {
|
|
5506
5508
|
n.value = t, e.onError?.(t, r);
|
|
5507
5509
|
} finally {
|
|
@@ -5514,66 +5516,66 @@ function ma(e) {
|
|
|
5514
5516
|
}
|
|
5515
5517
|
//#endregion
|
|
5516
5518
|
//#region src/comparisons/bike/index.ts
|
|
5517
|
-
var
|
|
5518
|
-
Form: () =>
|
|
5519
|
-
presenter: () =>
|
|
5520
|
-
}), ga = /* @__PURE__ */ B({
|
|
5521
|
-
Form: () => hi,
|
|
5522
|
-
presenter: () => gi
|
|
5523
|
-
}), _a = /* @__PURE__ */ B({
|
|
5524
|
-
Form: () => xi,
|
|
5525
|
-
presenter: () => Si
|
|
5519
|
+
var _a = /* @__PURE__ */ B({
|
|
5520
|
+
Form: () => fi,
|
|
5521
|
+
presenter: () => pi
|
|
5526
5522
|
}), va = /* @__PURE__ */ B({
|
|
5527
|
-
Form: () =>
|
|
5528
|
-
presenter: () =>
|
|
5523
|
+
Form: () => _i,
|
|
5524
|
+
presenter: () => vi
|
|
5529
5525
|
}), ya = /* @__PURE__ */ B({
|
|
5530
|
-
Form: () =>
|
|
5531
|
-
presenter: () =>
|
|
5526
|
+
Form: () => Ci,
|
|
5527
|
+
presenter: () => wi
|
|
5532
5528
|
}), ba = /* @__PURE__ */ B({
|
|
5533
|
-
Form: () =>
|
|
5534
|
-
presenter: () =>
|
|
5529
|
+
Form: () => Oi,
|
|
5530
|
+
presenter: () => ki
|
|
5535
5531
|
}), xa = /* @__PURE__ */ B({
|
|
5536
|
-
Form: () =>
|
|
5537
|
-
presenter: () =>
|
|
5532
|
+
Form: () => ji,
|
|
5533
|
+
presenter: () => Mi
|
|
5538
5534
|
}), Sa = /* @__PURE__ */ B({
|
|
5539
|
-
Form: () =>
|
|
5540
|
-
presenter: () =>
|
|
5535
|
+
Form: () => Fi,
|
|
5536
|
+
presenter: () => Ii
|
|
5541
5537
|
}), Ca = /* @__PURE__ */ B({
|
|
5542
|
-
Form: () =>
|
|
5543
|
-
presenter: () =>
|
|
5538
|
+
Form: () => Ri,
|
|
5539
|
+
presenter: () => zi
|
|
5544
5540
|
}), wa = /* @__PURE__ */ B({
|
|
5545
|
-
Form: () =>
|
|
5546
|
-
presenter: () =>
|
|
5541
|
+
Form: () => Vi,
|
|
5542
|
+
presenter: () => Hi
|
|
5547
5543
|
}), Ta = /* @__PURE__ */ B({
|
|
5548
|
-
Form: () =>
|
|
5549
|
-
presenter: () =>
|
|
5544
|
+
Form: () => qi,
|
|
5545
|
+
presenter: () => Yi
|
|
5550
5546
|
}), Ea = /* @__PURE__ */ B({
|
|
5551
|
-
Form: () =>
|
|
5552
|
-
presenter: () =>
|
|
5547
|
+
Form: () => Qi,
|
|
5548
|
+
presenter: () => $i
|
|
5553
5549
|
}), Da = /* @__PURE__ */ B({
|
|
5554
|
-
Form: () =>
|
|
5555
|
-
presenter: () =>
|
|
5550
|
+
Form: () => ta,
|
|
5551
|
+
presenter: () => na
|
|
5556
5552
|
}), Oa = /* @__PURE__ */ B({
|
|
5557
|
-
Form: () =>
|
|
5558
|
-
presenter: () =>
|
|
5559
|
-
}), ka = {
|
|
5560
|
-
|
|
5561
|
-
|
|
5562
|
-
|
|
5563
|
-
|
|
5564
|
-
|
|
5565
|
-
|
|
5566
|
-
|
|
5567
|
-
[V.
|
|
5568
|
-
[V.
|
|
5569
|
-
[V.
|
|
5570
|
-
[V.
|
|
5571
|
-
[V.
|
|
5572
|
-
|
|
5573
|
-
[V.
|
|
5574
|
-
|
|
5575
|
-
[V.
|
|
5576
|
-
|
|
5553
|
+
Form: () => ia,
|
|
5554
|
+
presenter: () => aa
|
|
5555
|
+
}), ka = /* @__PURE__ */ B({
|
|
5556
|
+
Form: () => sa,
|
|
5557
|
+
presenter: () => ca
|
|
5558
|
+
}), Aa = /* @__PURE__ */ B({
|
|
5559
|
+
Form: () => ua,
|
|
5560
|
+
presenter: () => da
|
|
5561
|
+
}), ja = {
|
|
5562
|
+
[V.Bike]: _a,
|
|
5563
|
+
[V.Pet]: va,
|
|
5564
|
+
[V.Caravan]: ya,
|
|
5565
|
+
[V.Travel]: ba,
|
|
5566
|
+
[V.Liability]: xa,
|
|
5567
|
+
[V.Housing]: Sa,
|
|
5568
|
+
house: Sa,
|
|
5569
|
+
[V.LegalAssistance]: Ca,
|
|
5570
|
+
[V.Package]: wa,
|
|
5571
|
+
[V.Loan]: Ta,
|
|
5572
|
+
[V.Moped]: Ea,
|
|
5573
|
+
[V.Motor]: Da,
|
|
5574
|
+
[V.Car]: Oa,
|
|
5575
|
+
[V.CarBusiness]: ka,
|
|
5576
|
+
"business-car": ka,
|
|
5577
|
+
[V.BusinessLiability]: Aa
|
|
5578
|
+
}, Ma = /* @__PURE__ */ l({
|
|
5577
5579
|
__name: "ComparisonFormFlow",
|
|
5578
5580
|
props: {
|
|
5579
5581
|
form: {},
|
|
@@ -5604,7 +5606,7 @@ var ha = /* @__PURE__ */ B({
|
|
|
5604
5606
|
},
|
|
5605
5607
|
emits: ["submitted", "error"],
|
|
5606
5608
|
setup(e, { emit: i }) {
|
|
5607
|
-
let a = e, o = i, s = q(a), c = t(() =>
|
|
5609
|
+
let a = e, o = i, s = q(a), c = t(() => ja[a.form]), { submit: l, isSubmitting: u } = ga({
|
|
5608
5610
|
link: a.link,
|
|
5609
5611
|
onRedirect: (e) => {
|
|
5610
5612
|
o("submitted", e), a.redirect ? a.redirect(e) : window.location.href = e;
|
|
@@ -5620,18 +5622,18 @@ var ha = /* @__PURE__ */ B({
|
|
|
5620
5622
|
onSubmitted: d
|
|
5621
5623
|
}), null, 16, ["initial-data", "submit-disabled"])) : r("", !0);
|
|
5622
5624
|
}
|
|
5623
|
-
}),
|
|
5624
|
-
|
|
5625
|
-
},
|
|
5625
|
+
}), Na, Pa = (e) => {
|
|
5626
|
+
Na = e;
|
|
5627
|
+
}, Fa = () => Na?.url, Ia = { class: "vd-form vd-form--vertical vd-form--card" }, La = {
|
|
5626
5628
|
key: 0,
|
|
5627
5629
|
class: "vd-form__header"
|
|
5628
|
-
},
|
|
5630
|
+
}, Ra = {
|
|
5629
5631
|
key: 0,
|
|
5630
5632
|
class: "vd-form__title"
|
|
5631
|
-
},
|
|
5633
|
+
}, za = {
|
|
5632
5634
|
key: 1,
|
|
5633
5635
|
class: "vd-form__description"
|
|
5634
|
-
},
|
|
5636
|
+
}, Ba = /* @__PURE__ */ l({
|
|
5635
5637
|
__name: "QuestionnaireForm",
|
|
5636
5638
|
props: {
|
|
5637
5639
|
link: {},
|
|
@@ -5646,11 +5648,11 @@ var ha = /* @__PURE__ */ B({
|
|
|
5646
5648
|
}
|
|
5647
5649
|
},
|
|
5648
5650
|
setup(e) {
|
|
5649
|
-
let n = e, a = t(() =>
|
|
5651
|
+
let n = e, a = t(() => Jr(n.link, {
|
|
5650
5652
|
qaId: n.qaId,
|
|
5651
5653
|
template: n.thankyouPageTemplate
|
|
5652
5654
|
}));
|
|
5653
|
-
return (t, n) => (b(), i("div",
|
|
5655
|
+
return (t, n) => (b(), i("div", Ia, [e.showTitle && e.title || e.description ? (b(), i("div", La, [e.showTitle && e.title ? (b(), i("h2", Ra, E(e.title), 1)) : r("", !0), e.description ? (b(), i("p", za, E(e.description), 1)) : r("", !0)])) : r("", !0), c(D(Pe), {
|
|
5654
5656
|
href: a.value,
|
|
5655
5657
|
label: e.buttonText,
|
|
5656
5658
|
"button-type": "green",
|
|
@@ -5659,16 +5661,16 @@ var ha = /* @__PURE__ */ B({
|
|
|
5659
5661
|
block: ""
|
|
5660
5662
|
}, null, 8, ["href", "label"])]));
|
|
5661
5663
|
}
|
|
5662
|
-
}),
|
|
5664
|
+
}), Va = {
|
|
5663
5665
|
key: 0,
|
|
5664
5666
|
class: "vd-form__header"
|
|
5665
|
-
},
|
|
5667
|
+
}, Ha = {
|
|
5666
5668
|
key: 0,
|
|
5667
5669
|
class: "vd-form__title"
|
|
5668
|
-
},
|
|
5670
|
+
}, Ua = {
|
|
5669
5671
|
key: 1,
|
|
5670
5672
|
class: "vd-form__description"
|
|
5671
|
-
},
|
|
5673
|
+
}, Wa = { class: "vd-form__row" }, Ga = { class: "vd-form__col-10 vd-form__col-md-6" }, Ka = { class: "vd-form__col-2 vd-form__action" }, qa = /* @__PURE__ */ l({
|
|
5672
5674
|
__name: "RiskScannerForm",
|
|
5673
5675
|
props: {
|
|
5674
5676
|
qaUrl: { default: "" },
|
|
@@ -5686,9 +5688,9 @@ var ha = /* @__PURE__ */ B({
|
|
|
5686
5688
|
}
|
|
5687
5689
|
},
|
|
5688
5690
|
setup(e) {
|
|
5689
|
-
let o = e, s = S(null), { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(R({ company:
|
|
5691
|
+
let o = e, s = S(null), { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(R({ company: Ir() }), { company: null }), [g, _, v] = f("company"), y = (e) => e ? p({ company: e }) : h("company"), x = t(() => !!g.value && !g.value.hasVisitingAddress);
|
|
5690
5692
|
async function C(e) {
|
|
5691
|
-
let t = o.qaUrl ||
|
|
5693
|
+
let t = o.qaUrl || Fa();
|
|
5692
5694
|
if (!t) throw Error("QA api url is required — set the qa-url attribute, or call configureQa({ url }) once at bootstrap.");
|
|
5693
5695
|
let n = t.endsWith("/") ? t : `${t}/`, r = await fetch(`${n}api/v1/active-questionnaire/${o.qaId}/start`, {
|
|
5694
5696
|
method: "POST",
|
|
@@ -5704,7 +5706,7 @@ var ha = /* @__PURE__ */ B({
|
|
|
5704
5706
|
});
|
|
5705
5707
|
if (!r.ok) throw Error(`Failed to start the questionnaire (${r.status})`);
|
|
5706
5708
|
let { leadId: i } = await r.json();
|
|
5707
|
-
return
|
|
5709
|
+
return Jr(o.link, {
|
|
5708
5710
|
leadid: i,
|
|
5709
5711
|
qaId: o.qaId,
|
|
5710
5712
|
template: o.thankyouPageTemplate
|
|
@@ -5724,7 +5726,7 @@ var ha = /* @__PURE__ */ B({
|
|
|
5724
5726
|
return (t, o) => (b(), i("form", {
|
|
5725
5727
|
class: "vd-form vd-form--vertical vd-form--card",
|
|
5726
5728
|
onSubmit: L(w, ["prevent", "stop"])
|
|
5727
|
-
}, [e.showTitle && e.title || e.description ? (b(), i("div",
|
|
5729
|
+
}, [e.showTitle && e.title || e.description ? (b(), i("div", Va, [e.showTitle && e.title ? (b(), i("h2", Ha, E(e.title), 1)) : r("", !0), e.description ? (b(), i("p", Ua, E(e.description), 1)) : r("", !0)])) : r("", !0), a("div", Wa, [a("div", Ga, [c(D(Fr), m({
|
|
5728
5730
|
modelValue: D(g),
|
|
5729
5731
|
"onUpdate:modelValue": o[0] ||= (e) => d(g) ? g.value = e : null
|
|
5730
5732
|
}, D(_), {
|
|
@@ -5735,7 +5737,7 @@ var ha = /* @__PURE__ */ B({
|
|
|
5735
5737
|
key: 0,
|
|
5736
5738
|
style: { "margin-top": "12px" },
|
|
5737
5739
|
text: "Dit bedrijf heeft geen geregistreerd bezoekadres. Voeg dit toe bij de KvK om door te gaan met de aanvraag."
|
|
5738
|
-
})) : r("", !0)]), a("div",
|
|
5740
|
+
})) : r("", !0)]), a("div", Ka, [c(D(Pe), {
|
|
5739
5741
|
type: "submit",
|
|
5740
5742
|
label: e.buttonText,
|
|
5741
5743
|
"is-loading": D(l),
|
|
@@ -5752,4 +5754,4 @@ var ha = /* @__PURE__ */ B({
|
|
|
5752
5754
|
}
|
|
5753
5755
|
});
|
|
5754
5756
|
//#endregion
|
|
5755
|
-
export {
|
|
5757
|
+
export { fi as BikeForm, sa as BusinessCarForm, ua as BusinessLiabilityForm, ia as CarForm, Ci as CaravanForm, Ma as ComparisonFormFlow, V as ComparisonName, Fi as HouseForm, Ri as LegalForm, ji as LiabilityForm, qi as LoanForm, Qi as MopedForm, ta as MotorForm, Vi as PackageForm, _i as PetForm, Ba as QuestionnaireForm, qa as RiskScannerForm, Oi as TravelForm, pi as bikePresenter, ca as businessCarPresenter, da as businessLiabilityPresenter, aa as carPresenter, wi as caravanPresenter, Pa as configureQa, Ii as housePresenter, zi as legalPresenter, Mi as liabilityPresenter, Yi as loanPresenter, $i as mopedPresenter, na as motorPresenter, Hi as packagePresenter, vi as petPresenter, ki as travelPresenter, ga as useComparisonSubmit };
|