@vergelijkdirect/comparison-forms 2.0.0-rc.28 → 2.0.0-rc.29
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 +668 -658
- package/dist/wc/comparison-forms.js +3259 -3247
- package/dist/wc-forms/{VdInput-DIZJ3f4p.cjs → VdInput-CQMUZonZ.cjs} +1 -1
- package/dist/wc-forms/{VdPopover-DX8Yz0nF.cjs → VdPopover-B7iU4v7L.cjs} +1 -1
- package/dist/wc-forms/VdRadioGroup-CliXOc0N.cjs +1 -0
- package/dist/wc-forms/VdSearchableSelect-BOOYo1Cc.cjs +3 -0
- package/dist/wc-forms/VdSelect-BsnfIWYl.cjs +1 -0
- package/dist/wc-forms/bike.cjs +1 -1
- package/dist/wc-forms/{birthdate.schema-BX7jH5_E.cjs → birthdate.schema-BfwwF4DI.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-Dhzxphqu.cjs +1 -0
- package/dist/wc-forms/{familyComposition.schema-Bq42dgie.cjs → familyComposition.schema-CnbmDFbc.cjs} +1 -1
- package/dist/wc-forms/house.cjs +1 -1
- package/dist/wc-forms/{houseOwnedBuilding.model-CjVlYLv7.cjs → houseOwnedBuilding.model-o7WWXt3D.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-CXkkOdoP.cjs → rules-GF6hc_di.cjs} +1 -1
- package/dist/wc-forms/travel.cjs +1 -1
- package/dist/wc-forms/{useAddress-DLjA-MGq.cjs → useAddress-CNccyKT4.cjs} +1 -1
- package/dist/wc-forms/{useLicensePlate-Ay8mEkK5.cjs → useLicensePlate-Ct8T-GYB.cjs} +1 -1
- package/dist/wc-forms/{useValidator-BNxCJIHn.cjs → useValidator-C2pny0oV.cjs} +1 -1
- package/dist/wc-noitc/comparison-forms.umd.cjs +2 -2
- package/package.json +1 -1
- package/dist/wc-forms/VdRadioGroup-QlkhemVR.cjs +0 -1
- package/dist/wc-forms/VdSearchableSelect-CrZndVz-.cjs +0 -3
- package/dist/wc-forms/VdSelect-CM4305fY.cjs +0 -1
- package/dist/wc-forms/company.schema-DguVLe_t.cjs +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Fragment as e, computed as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createElementVNode as a, createSlots as o, createTextVNode as s, createVNode as c, defineComponent as l, inject as u, isRef as d, mergeDefaults as f, mergeModels as p, mergeProps as m, nextTick as h, normalizeClass as g, normalizeStyle as _, onMounted as v, openBlock as y, provide as b, ref as x, renderList as S, renderSlot as C, resolveDynamicComponent as w, toDisplayString as T, unref as E, useAttrs as D, useId as O, useModel as k, useSlots as A, vModelRadio as j, vModelSelect as M, watch as N, withCtx as P, withDirectives as F, withModifiers as I } from "vue";
|
|
2
2
|
import { vMaska as L } from "maska/vue";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { ComboboxCancel as ee, ComboboxContent as te, ComboboxEmpty as ne, ComboboxInput as re, ComboboxItem as ie, ComboboxItemIndicator as ae, ComboboxRoot as oe, ComboboxTrigger as se, ComboboxViewport as ce, ComboboxVirtualizer as le, Label as ue, useForwardProps as de } from "reka-ui";
|
|
4
|
+
import { cloneDeep as fe, isEqual as pe } from "es-toolkit";
|
|
5
|
+
import { reactivePick as me, refDebounced as he, useAsyncState as ge } from "@vueuse/core";
|
|
6
6
|
import { autoUpdate as _e, flip as ve, offset as ye, shift as be, useFloating as xe } from "@floating-ui/vue";
|
|
7
7
|
import { mixed as Se, number as Ce, object as R, string as z } from "yup";
|
|
8
8
|
import { ComparisonService as we, DataService as Te, DataValidationService as Ee, HomeService as De, User as Oe } from "@vergelijkdirect/insurance-transmission-client";
|
|
@@ -22,20 +22,14 @@ var je = Object.defineProperty, B = (e, t) => {
|
|
|
22
22
|
return e.FamilyWithChildren = "I", e.FamilyWithoutChildren = "H", e.SingleWithoutChildren = "A", e.SingleWithChildren = "K", e;
|
|
23
23
|
}({}), U = /* @__PURE__ */ function(e) {
|
|
24
24
|
return e.Yes = "J", e.No = "N", e;
|
|
25
|
-
}({}), Me =
|
|
26
|
-
"href",
|
|
27
|
-
"target",
|
|
28
|
-
"tabindex"
|
|
29
|
-
], Ne = {
|
|
25
|
+
}({}), Me = {
|
|
30
26
|
key: 1,
|
|
31
27
|
class: "vd-btn-new__label"
|
|
32
|
-
},
|
|
33
|
-
key: 1,
|
|
34
|
-
class: "vd-btn-new__label"
|
|
35
|
-
}, Ie = /* @__PURE__ */ l({
|
|
28
|
+
}, Ne = /* @__PURE__ */ l({
|
|
36
29
|
__name: "VdButton",
|
|
37
30
|
props: {
|
|
38
31
|
buttonType: { default: "primary" },
|
|
32
|
+
type: { default: "button" },
|
|
39
33
|
label: { default: "" },
|
|
40
34
|
disabled: {
|
|
41
35
|
type: Boolean,
|
|
@@ -61,74 +55,82 @@ var je = Object.defineProperty, B = (e, t) => {
|
|
|
61
55
|
type: Boolean,
|
|
62
56
|
default: !1
|
|
63
57
|
},
|
|
64
|
-
tabindex: { default:
|
|
58
|
+
tabindex: { default: null }
|
|
65
59
|
},
|
|
66
60
|
emits: ["click"],
|
|
67
|
-
setup(e, { emit:
|
|
68
|
-
let
|
|
69
|
-
|
|
61
|
+
setup(e, { emit: o }) {
|
|
62
|
+
let c = e, l = o, u = A(), d = t(() => !!c.href), f = t(() => c.disabled || c.isLoading), p = t(() => !!c.label || !!u.default), h = t(() => d.value ? "a" : "button"), _ = t(() => [
|
|
63
|
+
"vd-btn-new",
|
|
64
|
+
...c.buttonType.split("-").map((e) => `vd-btn-new--${e}`),
|
|
65
|
+
{
|
|
66
|
+
"vd-btn-new--link-type": d.value,
|
|
67
|
+
"vd-btn-new--full-width": c.block,
|
|
68
|
+
"vd-btn-new--loading": c.isLoading,
|
|
69
|
+
"vd-btn-new--hide-label": c.hideLabelOnResize,
|
|
70
|
+
"vd-btn-new--disabled": f.value
|
|
71
|
+
},
|
|
72
|
+
c.size ? `vd-btn-new--${c.size}` : ""
|
|
73
|
+
]), v = t(() => {
|
|
74
|
+
let e = {
|
|
75
|
+
"aria-busy": c.isLoading || void 0,
|
|
76
|
+
"aria-label": c.hideLabelOnResize && c.label || void 0
|
|
77
|
+
};
|
|
78
|
+
return d.value ? {
|
|
79
|
+
...e,
|
|
80
|
+
href: f.value ? void 0 : c.href,
|
|
81
|
+
target: c.target,
|
|
82
|
+
rel: c.target === "_blank" ? "noopener noreferrer" : void 0,
|
|
83
|
+
"aria-disabled": f.value || void 0,
|
|
84
|
+
tabindex: f.value ? -1 : c.tabindex ?? void 0
|
|
85
|
+
} : {
|
|
86
|
+
...e,
|
|
87
|
+
type: c.type,
|
|
88
|
+
disabled: f.value,
|
|
89
|
+
tabindex: c.tabindex ?? void 0
|
|
90
|
+
};
|
|
91
|
+
}), b = (e) => {
|
|
92
|
+
if (f.value) {
|
|
93
|
+
e.preventDefault(), e.stopPropagation();
|
|
94
|
+
return;
|
|
95
|
+
}
|
|
96
|
+
l("click", e);
|
|
70
97
|
};
|
|
71
|
-
return (t,
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
"
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
key: 1,
|
|
100
|
-
class: g(["vd-btn-new", [
|
|
101
|
-
...o(),
|
|
102
|
-
{
|
|
103
|
-
"vd-btn-new--full-width": e.block,
|
|
104
|
-
"vd-btn-new--loading": e.isLoading,
|
|
105
|
-
"vd-btn-new--hide-label": e.hideLabelOnResize
|
|
106
|
-
},
|
|
107
|
-
e.size ? `vd-btn-new--${e.size}` : ""
|
|
108
|
-
]]),
|
|
109
|
-
disabled: e.disabled || e.isLoading,
|
|
110
|
-
tabindex: e.tabindex,
|
|
111
|
-
onClick: c
|
|
112
|
-
}, [
|
|
113
|
-
e.icon && e.iconLeft ? (y(), i("i", {
|
|
114
|
-
key: 0,
|
|
115
|
-
class: g(["vd-btn-new__icon", [e.icon, { "vd-btn-new__icon--non-label": !e.label }]])
|
|
116
|
-
}, null, 2)) : r("", !0),
|
|
117
|
-
e.label ? (y(), i("span", Fe, T(e.label), 1)) : r("", !0),
|
|
118
|
-
e.icon && !e.iconLeft ? (y(), i("i", {
|
|
119
|
-
key: 2,
|
|
120
|
-
class: g(["vd-btn-new__icon", [e.icon, { "vd-btn-new__icon--non-label": !e.label }]])
|
|
121
|
-
}, null, 2)) : r("", !0),
|
|
122
|
-
n[1] ||= a("div", { class: "loader-circle" }, null, -1)
|
|
123
|
-
], 10, Pe));
|
|
98
|
+
return (t, o) => (y(), n(w(h.value), m({ class: _.value }, v.value, { onClick: b }), {
|
|
99
|
+
default: P(() => [
|
|
100
|
+
e.icon && e.iconLeft ? (y(), i("i", {
|
|
101
|
+
key: 0,
|
|
102
|
+
class: g([
|
|
103
|
+
"vd-btn-new__icon",
|
|
104
|
+
e.icon,
|
|
105
|
+
{ "vd-btn-new__icon--non-label": !p.value }
|
|
106
|
+
]),
|
|
107
|
+
"aria-hidden": "true"
|
|
108
|
+
}, null, 2)) : r("", !0),
|
|
109
|
+
p.value ? (y(), i("span", Me, [C(t.$slots, "default", {}, () => [s(T(e.label), 1)])])) : r("", !0),
|
|
110
|
+
e.icon && !e.iconLeft ? (y(), i("i", {
|
|
111
|
+
key: 2,
|
|
112
|
+
class: g([
|
|
113
|
+
"vd-btn-new__icon",
|
|
114
|
+
e.icon,
|
|
115
|
+
{ "vd-btn-new__icon--non-label": !p.value }
|
|
116
|
+
]),
|
|
117
|
+
"aria-hidden": "true"
|
|
118
|
+
}, null, 2)) : r("", !0),
|
|
119
|
+
o[0] ||= a("div", {
|
|
120
|
+
class: "loader-circle",
|
|
121
|
+
"aria-hidden": "true"
|
|
122
|
+
}, null, -1)
|
|
123
|
+
]),
|
|
124
|
+
_: 3
|
|
125
|
+
}, 16, ["class"]));
|
|
124
126
|
}
|
|
125
|
-
}),
|
|
127
|
+
}), Pe = { class: "vd-field" }, Fe = {
|
|
126
128
|
key: 0,
|
|
127
129
|
class: "vd-field__asterisk"
|
|
128
|
-
},
|
|
130
|
+
}, Ie = {
|
|
129
131
|
key: 1,
|
|
130
132
|
class: "vd-field__popover"
|
|
131
|
-
},
|
|
133
|
+
}, Le = [
|
|
132
134
|
"id",
|
|
133
135
|
"value",
|
|
134
136
|
"type",
|
|
@@ -138,22 +140,22 @@ var je = Object.defineProperty, B = (e, t) => {
|
|
|
138
140
|
"disabled",
|
|
139
141
|
"readonly",
|
|
140
142
|
"autocomplete"
|
|
141
|
-
],
|
|
143
|
+
], Re = {
|
|
142
144
|
key: 0,
|
|
143
145
|
class: "vd-field__icon-and-loader"
|
|
144
|
-
},
|
|
146
|
+
}, ze = {
|
|
145
147
|
key: 0,
|
|
146
148
|
class: "vd-field__icon vd-field__icon--with-loader"
|
|
147
|
-
},
|
|
149
|
+
}, Be = { key: 1 }, Ve = {
|
|
148
150
|
key: 0,
|
|
149
151
|
class: "vd-field__loader-circle"
|
|
150
|
-
},
|
|
152
|
+
}, He = {
|
|
151
153
|
key: 0,
|
|
152
154
|
class: "vd-field__message vd-field__message--error"
|
|
153
|
-
},
|
|
155
|
+
}, Ue = {
|
|
154
156
|
key: 1,
|
|
155
157
|
class: "vd-field__message vd-field__message--information"
|
|
156
|
-
},
|
|
158
|
+
}, We = /* @__PURE__ */ l({
|
|
157
159
|
__name: "VdInput",
|
|
158
160
|
props: /*@__PURE__*/ p({
|
|
159
161
|
id: { default: null },
|
|
@@ -207,26 +209,29 @@ var je = Object.defineProperty, B = (e, t) => {
|
|
|
207
209
|
modelModifiers: {}
|
|
208
210
|
}),
|
|
209
211
|
emits: /*@__PURE__*/ p(["blur", "change"], ["update:modelValue"]),
|
|
210
|
-
setup(e, { emit:
|
|
211
|
-
let
|
|
212
|
-
|
|
213
|
-
}, b = (e) => {
|
|
214
|
-
l("blur", f(e.target.value));
|
|
212
|
+
setup(e, { emit: o }) {
|
|
213
|
+
let c = e, l = k(e, "modelValue"), u = o, d = A(), f = c.id ?? O(), p = (e) => c.capitalize ? e.toUpperCase() : e, m = t(() => !c.errorMessage && !c.verified && !c.hasError), h = t(() => !!l.value && !c.errorMessage && c.verified && !c.hasError && !c.loading), _ = t(() => !!c.errorMessage || !!c.hasError), v = t(() => !!c.errorMessage || !!d.errorMessage), b = (e) => {
|
|
214
|
+
l.value = p(e.target.value);
|
|
215
215
|
}, x = (e) => {
|
|
216
|
-
|
|
216
|
+
u("blur", p(e.target.value));
|
|
217
|
+
}, S = (e) => {
|
|
218
|
+
u("change", p(e.target.value));
|
|
217
219
|
};
|
|
218
|
-
return (t,
|
|
220
|
+
return (t, o) => (y(), i("div", Pe, [
|
|
219
221
|
a("div", {
|
|
220
222
|
class: g(["vd-field__label-wrapper", { "vd-field__label-wrapper--disabled": e.disabled }]),
|
|
221
|
-
onClick:
|
|
222
|
-
}, [e.label || E(
|
|
223
|
+
onClick: o[0] ||= I(() => {}, ["prevent"])
|
|
224
|
+
}, [e.label || E(d).label ? (y(), n(E(ue), {
|
|
223
225
|
key: 0,
|
|
224
|
-
for:
|
|
226
|
+
for: E(f),
|
|
225
227
|
class: "vd-field__label"
|
|
226
|
-
},
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
228
|
+
}, {
|
|
229
|
+
default: P(() => [a("span", null, [C(t.$slots, "label", {}, () => [s(T(e.label), 1)]), e.required ? (y(), i("span", Fe, "*")) : r("", !0)])]),
|
|
230
|
+
_: 3
|
|
231
|
+
}, 8, ["for"])) : r("", !0), E(d).popover ? (y(), i("span", Ie, [C(t.$slots, "popover")])) : r("", !0)], 2),
|
|
232
|
+
a("div", { class: g(["vd-field__wrapper", { "vd-field__wrapper-checkmark": h.value && !(e.icon || E(d).icon) }]) }, [F(a("input", {
|
|
233
|
+
id: E(f),
|
|
234
|
+
value: l.value,
|
|
230
235
|
type: e.type,
|
|
231
236
|
name: e.name,
|
|
232
237
|
inputmode: e.inputmode,
|
|
@@ -235,54 +240,54 @@ var je = Object.defineProperty, B = (e, t) => {
|
|
|
235
240
|
readonly: e.readonly,
|
|
236
241
|
autocomplete: e.autocomplete ? "off" : "on",
|
|
237
242
|
class: g(["vd-field__input", {
|
|
238
|
-
"vd-field__input--verified":
|
|
239
|
-
"vd-field__input--default":
|
|
240
|
-
"vd-field__input--error":
|
|
241
|
-
"vd-field__input--icon-left": (e.icon || E(
|
|
242
|
-
"vd-field__input--icon-right": (e.icon || E(
|
|
243
|
+
"vd-field__input--verified": h.value,
|
|
244
|
+
"vd-field__input--default": m.value,
|
|
245
|
+
"vd-field__input--error": _.value,
|
|
246
|
+
"vd-field__input--icon-left": (e.icon || E(d).icon) && e.iconLeft,
|
|
247
|
+
"vd-field__input--icon-right": (e.icon || E(d).icon) && !e.iconLeft,
|
|
243
248
|
"vd-field__input--loading": e.loading,
|
|
244
|
-
"vd-field__input--loading vd-field__input--icon": e.loading && !e.iconLeft && (e.icon || E(
|
|
249
|
+
"vd-field__input--loading vd-field__input--icon": e.loading && !e.iconLeft && (e.icon || E(d).icon)
|
|
245
250
|
}]),
|
|
246
|
-
onInput:
|
|
247
|
-
onChange:
|
|
248
|
-
onBlur:
|
|
249
|
-
}, null, 42,
|
|
251
|
+
onInput: b,
|
|
252
|
+
onChange: S,
|
|
253
|
+
onBlur: x
|
|
254
|
+
}, null, 42, Le), [[E(L), e.mask || void 0]]), e.loading && e.icon && !e.iconLeft ? (y(), i("div", Re, [o[1] ||= a("div", { class: "vd-field__loader-circle vd-field__loader-circle--and-icon" }, null, -1), e.icon || E(d).icon ? (y(), i("span", ze, [C(t.$slots, "icon", {}, () => [a("i", { class: g(e.icon) }, null, 2)])])) : r("", !0)])) : (y(), i("div", Be, [e.loading ? (y(), i("div", Ve)) : r("", !0), e.icon || E(d).icon ? (y(), i("span", {
|
|
250
255
|
key: 1,
|
|
251
256
|
class: g(["vd-field__icon", {
|
|
252
257
|
"vd-field__icon--left": e.iconLeft,
|
|
253
258
|
"vd-field__icon--disabled": e.disabled
|
|
254
259
|
}])
|
|
255
260
|
}, [C(t.$slots, "icon", {}, () => [a("i", { class: g(e.icon) }, null, 2)])], 2)) : r("", !0)]))], 2),
|
|
256
|
-
|
|
257
|
-
e.infoMessage || E(
|
|
261
|
+
v.value || E(d).errorMessage ? (y(), i("div", He, [C(t.$slots, "errorMessage", {}, () => [o[2] ||= a("i", { class: "fas fa-exclamation-circle vd-field__message-icon" }, null, -1), s(" " + T(e.errorMessage), 1)])])) : r("", !0),
|
|
262
|
+
e.infoMessage || E(d).information ? (y(), i("div", Ue, [C(t.$slots, "information", {}, () => [o[3] ||= a("i", { class: "fas fa-info-circle vd-field__message-icon" }, null, -1), s(" " + T(e.infoMessage), 1)])])) : r("", !0)
|
|
258
263
|
]));
|
|
259
264
|
}
|
|
260
|
-
}),
|
|
265
|
+
}), Ge = { class: "vd-field" }, Ke = {
|
|
261
266
|
key: 0,
|
|
262
267
|
class: "vd-field__asterisk"
|
|
263
|
-
},
|
|
268
|
+
}, qe = {
|
|
264
269
|
key: 1,
|
|
265
270
|
class: "vd-field__popover"
|
|
266
|
-
},
|
|
271
|
+
}, Je = { class: "vd-field__wrapper" }, Ye = [
|
|
267
272
|
"id",
|
|
268
273
|
"name",
|
|
269
274
|
"disabled"
|
|
270
|
-
],
|
|
275
|
+
], Xe = {
|
|
271
276
|
key: 0,
|
|
272
277
|
value: "",
|
|
273
278
|
disabled: "",
|
|
274
279
|
selected: ""
|
|
275
|
-
},
|
|
280
|
+
}, Ze = [
|
|
276
281
|
"value",
|
|
277
282
|
"selected",
|
|
278
283
|
"disabled"
|
|
279
|
-
],
|
|
284
|
+
], Qe = {
|
|
280
285
|
key: 0,
|
|
281
286
|
class: "vd-field__icon-and-loader"
|
|
282
|
-
},
|
|
287
|
+
}, $e = {
|
|
283
288
|
key: 0,
|
|
284
289
|
class: "vd-field__message vd-field__message--error"
|
|
285
|
-
},
|
|
290
|
+
}, et = {
|
|
286
291
|
key: 1,
|
|
287
292
|
class: "vd-field__message vd-field__message--information"
|
|
288
293
|
}, W = /* @__PURE__ */ l({
|
|
@@ -316,76 +321,79 @@ var je = Object.defineProperty, B = (e, t) => {
|
|
|
316
321
|
modelModifiers: {}
|
|
317
322
|
}),
|
|
318
323
|
emits: /*@__PURE__*/ p(["blur", "select"], ["update:modelValue"]),
|
|
319
|
-
setup(
|
|
320
|
-
let
|
|
321
|
-
get: () =>
|
|
324
|
+
setup(o, { emit: c }) {
|
|
325
|
+
let l = o, u = k(o, "modelValue"), d = c, f = A(), p = l.id ?? O(), m = t({
|
|
326
|
+
get: () => u.value ?? "",
|
|
322
327
|
set: (e) => {
|
|
323
|
-
|
|
328
|
+
u.value = e === "" ? null : e;
|
|
324
329
|
}
|
|
325
|
-
}),
|
|
326
|
-
|
|
327
|
-
},
|
|
328
|
-
|
|
330
|
+
}), h = x(!0), _ = t(() => !l.errorMessage && l.verified && !l.disabled && !l.loading), v = t(() => !l.errorMessage && !_.value), b = t(() => !!l.errorMessage), w = () => `vd-field__select--placeholder-${!u.value && h.value ? "shown" : "hidden"}`, D = (e) => {
|
|
331
|
+
d("select", e.target.value), h.value = !1;
|
|
332
|
+
}, j = (e) => {
|
|
333
|
+
d("blur", e.target.value);
|
|
329
334
|
};
|
|
330
|
-
return (t,
|
|
331
|
-
a("div", { class: g(["vd-field__label-wrapper", { "vd-field__label-wrapper--disabled":
|
|
335
|
+
return (t, c) => (y(), i("div", Ge, [
|
|
336
|
+
a("div", { class: g(["vd-field__label-wrapper", { "vd-field__label-wrapper--disabled": o.disabled }]) }, [o.label || E(f).label ? (y(), n(E(ue), {
|
|
332
337
|
key: 0,
|
|
333
|
-
for:
|
|
338
|
+
for: E(p),
|
|
334
339
|
class: "vd-field__label"
|
|
335
|
-
},
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
"vd-
|
|
340
|
+
}, {
|
|
341
|
+
default: P(() => [a("span", null, [C(t.$slots, "label", {}, () => [s(T(o.label), 1)]), o.required ? (y(), i("span", Ke, "*")) : r("", !0)])]),
|
|
342
|
+
_: 3
|
|
343
|
+
}, 8, ["for"])) : r("", !0), E(f).popover ? (y(), i("span", qe, [C(t.$slots, "popover")])) : r("", !0)], 2),
|
|
344
|
+
a("div", Je, [F(a("select", {
|
|
345
|
+
id: E(p),
|
|
346
|
+
"onUpdate:modelValue": c[0] ||= (e) => m.value = e,
|
|
347
|
+
name: o.name,
|
|
348
|
+
disabled: o.disabled,
|
|
349
|
+
class: g(["vd-field__input vd-field__select", [w(), {
|
|
350
|
+
"vd-field__input--error": b.value,
|
|
351
|
+
"vd-field__input--verified": _.value,
|
|
352
|
+
"vd-field__input--default": v.value,
|
|
353
|
+
"vd-field__select--placeholder-with-loader-and-icon-shown": o.loading
|
|
346
354
|
}]]),
|
|
347
|
-
onChange:
|
|
348
|
-
onBlur:
|
|
349
|
-
}, [
|
|
355
|
+
onChange: D,
|
|
356
|
+
onBlur: j
|
|
357
|
+
}, [o.placeholder ? (y(), i("option", Xe, T(o.placeholder), 1)) : r("", !0), (y(!0), i(e, null, S(o.options, (e, t) => (y(), i("option", {
|
|
350
358
|
key: e.value + "_" + t,
|
|
351
359
|
value: e.value,
|
|
352
360
|
selected: e.selected || !1,
|
|
353
361
|
disabled: e.disabled || !1
|
|
354
|
-
}, T(e.title), 9,
|
|
362
|
+
}, T(e.title), 9, Ze))), 128))], 42, Ye), [[M, m.value]]), o.loading ? (y(), i("div", Qe, [...c[1] ||= [a("div", { class: "vd-field__loader-circle vd-field__loader-circle--and-icon" }, null, -1), a("span", { class: "vd-field__icon vd-field__icon--with-loader" }, [a("i", { class: "fas vd-field__select-icon--with-loader" })], -1)]])) : (y(), n(E(ue), {
|
|
355
363
|
key: 1,
|
|
356
|
-
for: E(
|
|
364
|
+
for: E(p),
|
|
357
365
|
class: "vd-field__select-icon"
|
|
358
|
-
}, null, 8,
|
|
359
|
-
|
|
360
|
-
|
|
366
|
+
}, null, 8, ["for"]))]),
|
|
367
|
+
b.value || E(f).errorMessage ? (y(), i("div", $e, [C(t.$slots, "errorMessage", {}, () => [c[2] ||= a("i", { class: "fas fa-exclamation-circle vd-field__message-icon" }, null, -1), s(" " + T(o.errorMessage), 1)])])) : r("", !0),
|
|
368
|
+
o.infoMessage || E(f).information ? (y(), i("div", et, [C(t.$slots, "information", {}, () => [c[3] ||= a("i", { class: "fas fa-info-circle vd-field__message-icon" }, null, -1), s(" " + T(o.infoMessage), 1)])])) : r("", !0)
|
|
361
369
|
]));
|
|
362
370
|
}
|
|
363
371
|
});
|
|
364
372
|
//#endregion
|
|
365
373
|
//#region node_modules/es-toolkit/dist/_internal/isEqualsSameValueZero.mjs
|
|
366
|
-
function
|
|
374
|
+
function tt(e, t) {
|
|
367
375
|
return e === t || Number.isNaN(e) && Number.isNaN(t);
|
|
368
376
|
}
|
|
369
377
|
//#endregion
|
|
370
378
|
//#region node_modules/es-toolkit/dist/compat/util/toString.mjs
|
|
371
|
-
function
|
|
379
|
+
function nt(e) {
|
|
372
380
|
if (e == null) return "";
|
|
373
381
|
if (typeof e == "string") return e;
|
|
374
|
-
if (Array.isArray(e)) return e.map(
|
|
382
|
+
if (Array.isArray(e)) return e.map(nt).join(",");
|
|
375
383
|
let t = String(e);
|
|
376
384
|
return t === "0" && Object.is(Number(e), -0) ? "-0" : t;
|
|
377
385
|
}
|
|
378
386
|
//#endregion
|
|
379
387
|
//#region node_modules/es-toolkit/dist/compat/_internal/toKey.mjs
|
|
380
|
-
function
|
|
388
|
+
function rt(e) {
|
|
381
389
|
return typeof e == "string" || typeof e == "symbol" ? e : Object.is(e?.valueOf?.(), -0) ? "-0" : String(e);
|
|
382
390
|
}
|
|
383
391
|
//#endregion
|
|
384
392
|
//#region node_modules/es-toolkit/dist/compat/util/toPath.mjs
|
|
385
|
-
function
|
|
386
|
-
if (Array.isArray(e)) return e.map(
|
|
393
|
+
function it(e) {
|
|
394
|
+
if (Array.isArray(e)) return e.map(rt);
|
|
387
395
|
if (typeof e == "symbol") return [e];
|
|
388
|
-
e =
|
|
396
|
+
e = nt(e);
|
|
389
397
|
let t = [], n = e.length;
|
|
390
398
|
if (n === 0) return t;
|
|
391
399
|
let r = 0, i = "", a = "", o = !1;
|
|
@@ -405,12 +413,12 @@ function ut(e) {
|
|
|
405
413
|
}
|
|
406
414
|
//#endregion
|
|
407
415
|
//#region node_modules/es-toolkit/dist/_internal/isUnsafeProperty.mjs
|
|
408
|
-
function
|
|
416
|
+
function at(e) {
|
|
409
417
|
return e === "__proto__";
|
|
410
418
|
}
|
|
411
419
|
//#endregion
|
|
412
420
|
//#region node_modules/es-toolkit/dist/compat/_internal/isDeepKey.mjs
|
|
413
|
-
function
|
|
421
|
+
function ot(e) {
|
|
414
422
|
switch (typeof e) {
|
|
415
423
|
case "number":
|
|
416
424
|
case "symbol": return !1;
|
|
@@ -419,112 +427,112 @@ function ft(e) {
|
|
|
419
427
|
}
|
|
420
428
|
//#endregion
|
|
421
429
|
//#region node_modules/es-toolkit/dist/compat/object/get.mjs
|
|
422
|
-
function
|
|
430
|
+
function st(e, t, n) {
|
|
423
431
|
if (e == null) return n;
|
|
424
432
|
switch (typeof t) {
|
|
425
433
|
case "string": {
|
|
426
|
-
if (
|
|
434
|
+
if (at(t)) return n;
|
|
427
435
|
let r = e[t];
|
|
428
|
-
return r === void 0 ?
|
|
436
|
+
return r === void 0 ? ot(t) && !Object.hasOwn(e, t) ? st(e, it(t), n) : n : r;
|
|
429
437
|
}
|
|
430
438
|
case "number":
|
|
431
439
|
case "symbol": {
|
|
432
|
-
typeof t == "number" && (t =
|
|
440
|
+
typeof t == "number" && (t = rt(t));
|
|
433
441
|
let r = e[t];
|
|
434
442
|
return r === void 0 ? n : r;
|
|
435
443
|
}
|
|
436
444
|
default: {
|
|
437
|
-
if (Array.isArray(t)) return
|
|
438
|
-
if (t = Object.is(t?.valueOf(), -0) ? "-0" : String(t),
|
|
445
|
+
if (Array.isArray(t)) return ct(e, t, n);
|
|
446
|
+
if (t = Object.is(t?.valueOf(), -0) ? "-0" : String(t), at(t)) return n;
|
|
439
447
|
let r = e[t];
|
|
440
448
|
return r === void 0 ? n : r;
|
|
441
449
|
}
|
|
442
450
|
}
|
|
443
451
|
}
|
|
444
|
-
function
|
|
452
|
+
function ct(e, t, n) {
|
|
445
453
|
if (t.length === 0) return n;
|
|
446
454
|
let r = e;
|
|
447
455
|
for (let e = 0; e < t.length; e++) {
|
|
448
|
-
if (r == null ||
|
|
456
|
+
if (r == null || at(t[e])) return n;
|
|
449
457
|
r = r[t[e]];
|
|
450
458
|
}
|
|
451
459
|
return r === void 0 ? n : r;
|
|
452
460
|
}
|
|
453
461
|
//#endregion
|
|
454
462
|
//#region node_modules/es-toolkit/dist/compat/predicate/isObject.mjs
|
|
455
|
-
function
|
|
463
|
+
function lt(e) {
|
|
456
464
|
return e !== null && (typeof e == "object" || typeof e == "function");
|
|
457
465
|
}
|
|
458
466
|
//#endregion
|
|
459
467
|
//#region node_modules/es-toolkit/dist/compat/_internal/isIndex.mjs
|
|
460
|
-
var
|
|
461
|
-
function
|
|
468
|
+
var ut = /^(?:0|[1-9]\d*)$/;
|
|
469
|
+
function dt(e, t = 2 ** 53 - 1) {
|
|
462
470
|
switch (typeof e) {
|
|
463
471
|
case "number": return Number.isInteger(e) && e >= 0 && e < t;
|
|
464
472
|
case "symbol": return !1;
|
|
465
|
-
case "string": return
|
|
473
|
+
case "string": return ut.test(e);
|
|
466
474
|
}
|
|
467
475
|
}
|
|
468
476
|
//#endregion
|
|
469
477
|
//#region node_modules/es-toolkit/dist/compat/predicate/isSymbol.mjs
|
|
470
|
-
function
|
|
478
|
+
function ft(e) {
|
|
471
479
|
return typeof e == "symbol" || e instanceof Symbol;
|
|
472
480
|
}
|
|
473
481
|
//#endregion
|
|
474
482
|
//#region node_modules/es-toolkit/dist/compat/_internal/isKey.mjs
|
|
475
|
-
var
|
|
476
|
-
function
|
|
477
|
-
return Array.isArray(e) ? !1 : typeof e == "number" || typeof e == "boolean" || e == null ||
|
|
483
|
+
var pt = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, mt = /^\w*$/;
|
|
484
|
+
function ht(e, t) {
|
|
485
|
+
return Array.isArray(e) ? !1 : typeof e == "number" || typeof e == "boolean" || e == null || ft(e) ? !0 : typeof e == "string" && (mt.test(e) || !pt.test(e)) || t != null && Object.hasOwn(t, e);
|
|
478
486
|
}
|
|
479
487
|
//#endregion
|
|
480
488
|
//#region node_modules/es-toolkit/dist/compat/_internal/assignValue.mjs
|
|
481
|
-
var
|
|
489
|
+
var gt = (e, t, n) => {
|
|
482
490
|
let r = e[t];
|
|
483
|
-
(!(Object.hasOwn(e, t) &&
|
|
491
|
+
(!(Object.hasOwn(e, t) && tt(r, n)) || n === void 0 && !(t in e)) && (e[t] = n);
|
|
484
492
|
};
|
|
485
493
|
//#endregion
|
|
486
494
|
//#region node_modules/es-toolkit/dist/compat/object/updateWith.mjs
|
|
487
|
-
function
|
|
488
|
-
if (e == null && !
|
|
495
|
+
function _t(e, t, n, r) {
|
|
496
|
+
if (e == null && !lt(e)) return e;
|
|
489
497
|
let i;
|
|
490
|
-
i =
|
|
491
|
-
let a = n(
|
|
498
|
+
i = ht(t, e) ? [t] : Array.isArray(t) ? t : it(t);
|
|
499
|
+
let a = n(st(e, i)), o = e;
|
|
492
500
|
for (let t = 0; t < i.length && o != null; t++) {
|
|
493
|
-
let n =
|
|
494
|
-
if (
|
|
501
|
+
let n = rt(i[t]);
|
|
502
|
+
if (at(n)) continue;
|
|
495
503
|
let s;
|
|
496
504
|
if (t === i.length - 1) s = a;
|
|
497
505
|
else {
|
|
498
506
|
let a = o[n], c = r?.(a, n, e);
|
|
499
|
-
s = c === void 0 ?
|
|
507
|
+
s = c === void 0 ? lt(a) ? a : dt(i[t + 1]) ? [] : {} : c;
|
|
500
508
|
}
|
|
501
|
-
|
|
509
|
+
gt(o, n, s), o = o[n];
|
|
502
510
|
}
|
|
503
511
|
return e;
|
|
504
512
|
}
|
|
505
513
|
//#endregion
|
|
506
514
|
//#region node_modules/es-toolkit/dist/compat/object/set.mjs
|
|
507
|
-
function
|
|
508
|
-
return
|
|
515
|
+
function vt(e, t, n) {
|
|
516
|
+
return _t(e, t, () => n, () => void 0);
|
|
509
517
|
}
|
|
510
518
|
//#endregion
|
|
511
519
|
//#region src/components/ui/VdSearchableSelect.vue?vue&type=script&setup=true&lang.ts
|
|
512
|
-
var
|
|
520
|
+
var yt = {
|
|
513
521
|
key: 0,
|
|
514
522
|
class: "vd-field__asterisk"
|
|
515
|
-
},
|
|
523
|
+
}, bt = {
|
|
516
524
|
key: 1,
|
|
517
525
|
class: "vd-field__popover"
|
|
518
|
-
},
|
|
526
|
+
}, xt = { class: "vd-field__wrapper" }, St = {
|
|
519
527
|
key: 1,
|
|
520
528
|
class: "vd-field__loader-circle"
|
|
521
|
-
},
|
|
529
|
+
}, Ct = {
|
|
522
530
|
key: 0,
|
|
523
531
|
class: "vd-field__message vd-field__message--error"
|
|
524
|
-
},
|
|
532
|
+
}, wt = {
|
|
525
533
|
key: 1,
|
|
526
534
|
class: "vd-field__message vd-field__message--information"
|
|
527
|
-
},
|
|
535
|
+
}, Tt = /* @__PURE__ */ l({
|
|
528
536
|
__name: "VdSearchableSelect",
|
|
529
537
|
props: /*@__PURE__*/ p({
|
|
530
538
|
id: {},
|
|
@@ -580,17 +588,17 @@ var Tt = {
|
|
|
580
588
|
"update:searchTerm"
|
|
581
589
|
]),
|
|
582
590
|
setup(o, { emit: l }) {
|
|
583
|
-
let u = o, d =
|
|
591
|
+
let u = o, d = de(me(u, "name", "disabled", "by", "ignoreFilter")), f = k(o, "modelValue"), p = k(o, "open"), h = k(o, "searchTerm"), _ = l, v = A(), b = u.id ?? O(), x = t(() => !!u.icon || !!v.icon), w = (e) => typeof e == "object" && !!e, D = (e) => w(e) ? st(e, u.labelKey) ?? e.title ?? "" : String(e), j = (e) => w(e) ? u.valueKey === null ? e : st(e, u.valueKey) : e, M = (e) => w(e) ? e.disabled : void 0, N = (e, t) => e === void 0 || t === void 0 ? !1 : !w(e) || !w(t) ? e === t : typeof u.by == "function" ? u.by(e, t) : typeof u.by == "string" ? st(e, u.by) === st(t, u.by) : pe(e, t), F = (e) => e == null || e === "", I = t(() => !F(f.value)), L = t(() => u.errorMessage ? "error" : I.value && u.verified && !u.loading ? "verified" : "default"), fe = (e) => {
|
|
584
592
|
if (F(e)) return "";
|
|
585
593
|
if (u.displayValue) return u.displayValue(e);
|
|
586
594
|
let t = u.options.find((t) => N(j(t), e));
|
|
587
595
|
return D(t ?? e);
|
|
588
|
-
},
|
|
596
|
+
}, he = (e) => {
|
|
589
597
|
_("select", e);
|
|
590
|
-
},
|
|
598
|
+
}, ge = () => {
|
|
591
599
|
f.value = void 0, _("clear");
|
|
592
600
|
};
|
|
593
|
-
return (t, l) => (y(), n(E(
|
|
601
|
+
return (t, l) => (y(), n(E(oe), m({
|
|
594
602
|
modelValue: f.value,
|
|
595
603
|
"onUpdate:modelValue": l[3] ||= (e) => f.value = e,
|
|
596
604
|
open: p.value,
|
|
@@ -600,20 +608,20 @@ var Tt = {
|
|
|
600
608
|
"open-on-focus": ""
|
|
601
609
|
}, E(d)), {
|
|
602
610
|
default: P(() => [
|
|
603
|
-
a("div", { class: g(["vd-field__label-wrapper", { "vd-field__label-wrapper--disabled": o.disabled }]) }, [o.label || v.label ? (y(), n(E(
|
|
611
|
+
a("div", { class: g(["vd-field__label-wrapper", { "vd-field__label-wrapper--disabled": o.disabled }]) }, [o.label || v.label ? (y(), n(E(ue), {
|
|
604
612
|
key: 0,
|
|
605
613
|
for: E(b),
|
|
606
614
|
class: "vd-field__label"
|
|
607
615
|
}, {
|
|
608
|
-
default: P(() => [a("span", null, [C(t.$slots, "label", {}, () => [s(T(o.label), 1)]), o.required ? (y(), i("span",
|
|
616
|
+
default: P(() => [a("span", null, [C(t.$slots, "label", {}, () => [s(T(o.label), 1)]), o.required ? (y(), i("span", yt, "*")) : r("", !0)])]),
|
|
609
617
|
_: 3
|
|
610
|
-
}, 8, ["for"])) : r("", !0), v.popover ? (y(), i("span",
|
|
611
|
-
a("div",
|
|
612
|
-
c(E(
|
|
618
|
+
}, 8, ["for"])) : r("", !0), v.popover ? (y(), i("span", bt, [C(t.$slots, "popover")])) : r("", !0)], 2),
|
|
619
|
+
a("div", xt, [
|
|
620
|
+
c(E(re), {
|
|
613
621
|
id: E(b),
|
|
614
622
|
modelValue: h.value,
|
|
615
623
|
"onUpdate:modelValue": l[0] ||= (e) => h.value = e,
|
|
616
|
-
"display-value":
|
|
624
|
+
"display-value": fe,
|
|
617
625
|
placeholder: o.placeholder,
|
|
618
626
|
class: g(["vd-field__input vd-field__input--icon-right", [`vd-field__input--${L.value}`, { "vd-field__input--icon-left": x.value }]]),
|
|
619
627
|
onInput: l[1] ||= (e) => _("search", e.target.value),
|
|
@@ -628,15 +636,15 @@ var Tt = {
|
|
|
628
636
|
key: 0,
|
|
629
637
|
class: g(["vd-field__icon vd-field__icon--left", { "vd-field__icon--disabled": o.disabled }])
|
|
630
638
|
}, [C(t.$slots, "icon", {}, () => [a("i", { class: g(o.icon) }, null, 2)])], 2)) : r("", !0),
|
|
631
|
-
o.loading ? (y(), i("div",
|
|
639
|
+
o.loading ? (y(), i("div", St)) : o.clearable && I.value ? (y(), n(E(ee), {
|
|
632
640
|
key: 2,
|
|
633
641
|
as: "span",
|
|
634
642
|
class: "vd-field__icon",
|
|
635
|
-
onClick:
|
|
643
|
+
onClick: ge
|
|
636
644
|
}, {
|
|
637
645
|
default: P(() => [...l[5] ||= [a("i", { class: "far fa-times vd-field__icon--clickable" }, null, -1)]]),
|
|
638
646
|
_: 1
|
|
639
|
-
})) : (y(), n(E(
|
|
647
|
+
})) : (y(), n(E(se), {
|
|
640
648
|
key: 3,
|
|
641
649
|
as: "span",
|
|
642
650
|
class: "vd-field__icon"
|
|
@@ -644,23 +652,23 @@ var Tt = {
|
|
|
644
652
|
default: P(() => [a("i", { class: g(p.value ? "far fa-chevron-up" : "far fa-chevron-down") }, null, 2)]),
|
|
645
653
|
_: 1
|
|
646
654
|
})),
|
|
647
|
-
c(E(
|
|
648
|
-
default: P(() => [c(E(
|
|
649
|
-
default: P(() => [o.virtual ? (y(), n(E(
|
|
655
|
+
c(E(te), { class: "vd-combobox" }, {
|
|
656
|
+
default: P(() => [c(E(ce), { class: "vd-combobox__list" }, {
|
|
657
|
+
default: P(() => [o.virtual ? (y(), n(E(le), {
|
|
650
658
|
key: 0,
|
|
651
659
|
options: o.options,
|
|
652
660
|
"estimate-size": o.estimateSize,
|
|
653
661
|
overscan: o.overscan,
|
|
654
662
|
"text-content": D
|
|
655
663
|
}, {
|
|
656
|
-
default: P(({ option: e }) => [c(E(
|
|
664
|
+
default: P(({ option: e }) => [c(E(ie), {
|
|
657
665
|
value: j(e),
|
|
658
666
|
"text-value": D(e),
|
|
659
667
|
disabled: M(e),
|
|
660
668
|
class: "vd-combobox__item",
|
|
661
|
-
onSelect: (t) =>
|
|
669
|
+
onSelect: (t) => he(j(e))
|
|
662
670
|
}, {
|
|
663
|
-
default: P(() => [C(t.$slots, "item", { option: e }, () => [s(T(D(e)), 1)]), c(E(
|
|
671
|
+
default: P(() => [C(t.$slots, "item", { option: e }, () => [s(T(D(e)), 1)]), c(E(ae), { class: "vd-combobox__check" }, {
|
|
664
672
|
default: P(() => [...l[6] ||= [a("i", { class: "far fa-check" }, null, -1)]]),
|
|
665
673
|
_: 1
|
|
666
674
|
})]),
|
|
@@ -676,15 +684,15 @@ var Tt = {
|
|
|
676
684
|
"options",
|
|
677
685
|
"estimate-size",
|
|
678
686
|
"overscan"
|
|
679
|
-
])) : (y(!0), i(e, { key: 1 }, S(o.options, (e, r) => (y(), n(E(
|
|
687
|
+
])) : (y(!0), i(e, { key: 1 }, S(o.options, (e, r) => (y(), n(E(ie), {
|
|
680
688
|
key: r,
|
|
681
689
|
value: j(e),
|
|
682
690
|
"text-value": D(e),
|
|
683
691
|
disabled: M(e),
|
|
684
692
|
class: "vd-combobox__item",
|
|
685
|
-
onSelect: (t) =>
|
|
693
|
+
onSelect: (t) => he(j(e))
|
|
686
694
|
}, {
|
|
687
|
-
default: P(() => [C(t.$slots, "item", { option: e }, () => [s(T(D(e)), 1)]), c(E(
|
|
695
|
+
default: P(() => [C(t.$slots, "item", { option: e }, () => [s(T(D(e)), 1)]), c(E(ae), { class: "vd-combobox__check" }, {
|
|
688
696
|
default: P(() => [...l[7] ||= [a("i", { class: "far fa-check" }, null, -1)]]),
|
|
689
697
|
_: 1
|
|
690
698
|
})]),
|
|
@@ -694,7 +702,7 @@ var Tt = {
|
|
|
694
702
|
"text-value",
|
|
695
703
|
"disabled",
|
|
696
704
|
"onSelect"
|
|
697
|
-
]))), 128)), c(E(
|
|
705
|
+
]))), 128)), c(E(ne), { class: "vd-combobox__empty" }, {
|
|
698
706
|
default: P(() => [s(T(o.noResultsText), 1)]),
|
|
699
707
|
_: 1
|
|
700
708
|
})]),
|
|
@@ -703,18 +711,18 @@ var Tt = {
|
|
|
703
711
|
_: 3
|
|
704
712
|
})
|
|
705
713
|
]),
|
|
706
|
-
L.value === "error" || v.errorMessage ? (y(), i("div",
|
|
707
|
-
o.infoMessage || v.information ? (y(), i("div",
|
|
714
|
+
L.value === "error" || v.errorMessage ? (y(), i("div", Ct, [C(t.$slots, "errorMessage", {}, () => [l[8] ||= a("i", { class: "fas fa-exclamation-circle vd-field__message-icon" }, null, -1), s(" " + T(o.errorMessage), 1)])])) : r("", !0),
|
|
715
|
+
o.infoMessage || v.information ? (y(), i("div", wt, [C(t.$slots, "information", {}, () => [l[9] ||= a("i", { class: "fas fa-info-circle vd-field__message-icon" }, null, -1), s(" " + T(o.infoMessage), 1)])])) : r("", !0)
|
|
708
716
|
]),
|
|
709
717
|
_: 3
|
|
710
718
|
}, 16, ["modelValue", "open"]));
|
|
711
719
|
}
|
|
712
|
-
}),
|
|
720
|
+
}), Et = { class: "vd-radio-field" }, Dt = { class: "vd-radio-field__input" }, Ot = [
|
|
713
721
|
"id",
|
|
714
722
|
"disabled",
|
|
715
723
|
"name",
|
|
716
724
|
"value"
|
|
717
|
-
],
|
|
725
|
+
], kt = ["for"], At = /* @__PURE__ */ l({
|
|
718
726
|
__name: "VdRadio",
|
|
719
727
|
props: /*@__PURE__*/ p({
|
|
720
728
|
name: {},
|
|
@@ -760,8 +768,8 @@ var Tt = {
|
|
|
760
768
|
}, f = (e) => {
|
|
761
769
|
c("blur", n.value, e.target.value);
|
|
762
770
|
};
|
|
763
|
-
return (t, n) => (y(), i("div",
|
|
764
|
-
a("div",
|
|
771
|
+
return (t, n) => (y(), i("div", Et, [
|
|
772
|
+
a("div", Dt, [F(a("input", {
|
|
765
773
|
id: E(u),
|
|
766
774
|
"onUpdate:modelValue": n[0] ||= (e) => o.value = e,
|
|
767
775
|
disabled: e.disabled,
|
|
@@ -774,28 +782,28 @@ var Tt = {
|
|
|
774
782
|
type: "radio",
|
|
775
783
|
onChange: d,
|
|
776
784
|
onBlur: f
|
|
777
|
-
}, null, 42,
|
|
785
|
+
}, null, 42, Ot), [[j, o.value]])]),
|
|
778
786
|
e.label || E(l).label ? (y(), i("label", {
|
|
779
787
|
key: 0,
|
|
780
788
|
class: "vd-radio-field__label",
|
|
781
789
|
for: E(u)
|
|
782
|
-
}, [C(t.$slots, "label", {}, () => [s(T(e.label), 1)])], 8,
|
|
790
|
+
}, [C(t.$slots, "label", {}, () => [s(T(e.label), 1)])], 8, kt)) : r("", !0),
|
|
783
791
|
C(t.$slots, "popover")
|
|
784
792
|
]));
|
|
785
793
|
}
|
|
786
|
-
}),
|
|
794
|
+
}), jt = ["disabled"], Mt = { class: "vd-field__label" }, Nt = {
|
|
787
795
|
key: 0,
|
|
788
796
|
class: "vd-field__asterisk"
|
|
789
|
-
},
|
|
797
|
+
}, Pt = {
|
|
790
798
|
key: 0,
|
|
791
799
|
class: "vd-field__popover"
|
|
792
|
-
},
|
|
800
|
+
}, Ft = {
|
|
793
801
|
key: 1,
|
|
794
802
|
class: "vd-field__message vd-field__message--error"
|
|
795
|
-
},
|
|
803
|
+
}, It = {
|
|
796
804
|
key: 2,
|
|
797
805
|
class: "vd-field__message vd-field__message--information"
|
|
798
|
-
},
|
|
806
|
+
}, Lt = /* @__PURE__ */ l({
|
|
799
807
|
__name: "VdRadioGroup",
|
|
800
808
|
props: /*@__PURE__*/ p({
|
|
801
809
|
name: {},
|
|
@@ -842,8 +850,8 @@ var Tt = {
|
|
|
842
850
|
o.legend || E(f).legend ? (y(), i("legend", {
|
|
843
851
|
key: 0,
|
|
844
852
|
class: g(["vd-field__label-wrapper", { "vd-field__label-wrapper--disabled": o.disabled }])
|
|
845
|
-
}, [a("div",
|
|
846
|
-
a("div", { class: g(["vd-radio-group__list", o.groupClass]) }, [(y(!0), i(e, null, S(o.options, (e) => (y(), n(
|
|
853
|
+
}, [a("div", Mt, [C(t.$slots, "legend", {}, () => [s(T(o.legend), 1)]), o.required ? (y(), i("span", Nt, "*")) : r("", !0)]), E(f).popover ? (y(), i("span", Pt, [C(t.$slots, "popover")])) : r("", !0)], 2)) : r("", !0),
|
|
854
|
+
a("div", { class: g(["vd-radio-group__list", o.groupClass]) }, [(y(!0), i(e, null, S(o.options, (e) => (y(), n(At, {
|
|
847
855
|
key: e.value,
|
|
848
856
|
modelValue: u.value,
|
|
849
857
|
"onUpdate:modelValue": c[0] ||= (e) => u.value = e,
|
|
@@ -866,14 +874,14 @@ var Tt = {
|
|
|
866
874
|
"disabled",
|
|
867
875
|
"invalid"
|
|
868
876
|
]))), 128))], 2),
|
|
869
|
-
p.value ? (y(), i("div",
|
|
870
|
-
o.infoMessage || E(f).information ? (y(), i("div",
|
|
871
|
-
], 10,
|
|
877
|
+
p.value ? (y(), i("div", Ft, [c[1] ||= a("i", { class: "fas fa-exclamation-circle vd-field__message-icon" }, null, -1), s(" " + T(o.errorMessage), 1)])) : r("", !0),
|
|
878
|
+
o.infoMessage || E(f).information ? (y(), i("div", It, [C(t.$slots, "information", {}, () => [c[2] ||= a("i", { class: "fas fa-info-circle vd-field__message-icon" }, null, -1), s(" " + T(o.infoMessage), 1)])])) : r("", !0)
|
|
879
|
+
], 10, jt));
|
|
872
880
|
}
|
|
873
|
-
}),
|
|
881
|
+
}), Rt = { class: "vd-notification__content" }, zt = {
|
|
874
882
|
key: 0,
|
|
875
883
|
class: "vd-notification__title"
|
|
876
|
-
},
|
|
884
|
+
}, Bt = /* @__PURE__ */ l({
|
|
877
885
|
__name: "VdNotification",
|
|
878
886
|
props: {
|
|
879
887
|
type: { default: "warning" },
|
|
@@ -892,12 +900,12 @@ var Tt = {
|
|
|
892
900
|
success: "fas fa-check-circle",
|
|
893
901
|
error: "fas fa-times-circle"
|
|
894
902
|
};
|
|
895
|
-
return (n, o) => (y(), i("div", { class: g(["vd-notification", [`vd-notification--${e.type}`, { "vd-notification--small": e.small }]]) }, [a("i", { class: g([e.icon || t[e.type], "vd-notification__icon"]) }, null, 2), a("p",
|
|
903
|
+
return (n, o) => (y(), i("div", { class: g(["vd-notification", [`vd-notification--${e.type}`, { "vd-notification--small": e.small }]]) }, [a("i", { class: g([e.icon || t[e.type], "vd-notification__icon"]) }, null, 2), a("p", Rt, [e.title ? (y(), i("span", zt, T(e.title), 1)) : r("", !0), C(n.$slots, "default", {}, () => [s(T(e.text), 1)])])], 2));
|
|
896
904
|
}
|
|
897
|
-
}),
|
|
905
|
+
}), Vt = { class: "vd-popover__title" }, Ht = {
|
|
898
906
|
key: 0,
|
|
899
907
|
class: "vd-popover__title-icon"
|
|
900
|
-
},
|
|
908
|
+
}, Ut = { key: 1 }, Wt = /* @__PURE__ */ l({
|
|
901
909
|
__name: "VdPopoverHeader",
|
|
902
910
|
props: {
|
|
903
911
|
title: { default: "" },
|
|
@@ -908,12 +916,12 @@ var Tt = {
|
|
|
908
916
|
let n = t, o = () => {
|
|
909
917
|
n("close");
|
|
910
918
|
};
|
|
911
|
-
return (t, n) => (y(), i("div", { class: g(["vd-popover__header", { "vd-popover__header--only-close-icon": !e.title }]) }, [e.title ? C(t.$slots, "default", { key: 0 }, () => [a("div",
|
|
919
|
+
return (t, n) => (y(), i("div", { class: g(["vd-popover__header", { "vd-popover__header--only-close-icon": !e.title }]) }, [e.title ? C(t.$slots, "default", { key: 0 }, () => [a("div", Vt, [e.icon ? (y(), i("div", Ht, [a("i", { class: g(e.icon) }, null, 2)])) : r("", !0), e.title ? (y(), i("span", Ut, T(e.title), 1)) : r("", !0)])]) : r("", !0), a("button", {
|
|
912
920
|
class: "vd-popover__close-btn",
|
|
913
921
|
onClick: o
|
|
914
922
|
}, [...n[0] ||= [a("i", { class: "far fa-times vd-popover__close-btn-icon" }, null, -1)]])], 2));
|
|
915
923
|
}
|
|
916
|
-
}),
|
|
924
|
+
}), Gt = ["innerHTML"], Kt = /* @__PURE__ */ l({
|
|
917
925
|
__name: "VdPopoverTooltip",
|
|
918
926
|
props: {
|
|
919
927
|
content: { default: () => ({
|
|
@@ -936,7 +944,7 @@ var Tt = {
|
|
|
936
944
|
return (t, a) => (y(), i("div", {
|
|
937
945
|
class: g(["vd-popover__tooltip", [e.size ? `vd-popover__tooltip--${e.size}` : "", e.variant ? `vd-popover__tooltip--${e.variant}` : ""]]),
|
|
938
946
|
onPointerdown: a[0] ||= I(() => {}, ["prevent"])
|
|
939
|
-
}, [e.hideHeaderTooltip ? r("", !0) : (y(), n(
|
|
947
|
+
}, [e.hideHeaderTooltip ? r("", !0) : (y(), n(Wt, {
|
|
940
948
|
key: 0,
|
|
941
949
|
title: e.content.title,
|
|
942
950
|
icon: e.headerIconTooltip,
|
|
@@ -945,9 +953,9 @@ var Tt = {
|
|
|
945
953
|
key: 1,
|
|
946
954
|
class: "vd-popover__description",
|
|
947
955
|
innerHTML: e.content.description
|
|
948
|
-
}, null, 8,
|
|
956
|
+
}, null, 8, Gt)) : r("", !0)], 34));
|
|
949
957
|
}
|
|
950
|
-
}),
|
|
958
|
+
}), qt = { key: 1 }, Jt = /* @__PURE__ */ l({
|
|
951
959
|
__name: "VdPopoverReference",
|
|
952
960
|
props: {
|
|
953
961
|
label: { default: "" },
|
|
@@ -964,7 +972,7 @@ var Tt = {
|
|
|
964
972
|
key: 0,
|
|
965
973
|
class: g(e.icon)
|
|
966
974
|
}, null, 2)) : r("", !0),
|
|
967
|
-
e.label ? (y(), i("span",
|
|
975
|
+
e.label ? (y(), i("span", qt, T(e.label), 1)) : r("", !0),
|
|
968
976
|
e.iconLeft ? r("", !0) : (y(), i("i", {
|
|
969
977
|
key: 2,
|
|
970
978
|
class: g(e.icon)
|
|
@@ -1056,7 +1064,7 @@ var Tt = {
|
|
|
1056
1064
|
onMousedown: m,
|
|
1057
1065
|
isOpen: l.value,
|
|
1058
1066
|
close: f
|
|
1059
|
-
}, () => [c(
|
|
1067
|
+
}, () => [c(Jt, {
|
|
1060
1068
|
variant: e.refVariant,
|
|
1061
1069
|
label: e.label,
|
|
1062
1070
|
icon: e.iconRef,
|
|
@@ -1073,7 +1081,7 @@ var Tt = {
|
|
|
1073
1081
|
style: _(E(s)),
|
|
1074
1082
|
class: g(["vd-popover__floating", t.fullWidth ? "vd-popover__floating--full-width" : ""]),
|
|
1075
1083
|
onPointerdown: d[0] ||= I(() => {}, ["prevent"])
|
|
1076
|
-
}, [C(u.$slots, "tooltip", { close: f }, () => [c(
|
|
1084
|
+
}, [C(u.$slots, "tooltip", { close: f }, () => [c(Kt, {
|
|
1077
1085
|
content: e.content,
|
|
1078
1086
|
variant: e.tooltipVariant,
|
|
1079
1087
|
size: e.tooltipSize,
|
|
@@ -1098,21 +1106,21 @@ var Tt = {
|
|
|
1098
1106
|
fullWidth: !1,
|
|
1099
1107
|
submitLabel: "Vergelijken",
|
|
1100
1108
|
submitDisabled: !1
|
|
1101
|
-
},
|
|
1109
|
+
}, Yt = Object.keys(K);
|
|
1102
1110
|
function q(e) {
|
|
1103
|
-
return
|
|
1111
|
+
return me(e, ...Yt);
|
|
1104
1112
|
}
|
|
1105
1113
|
//#endregion
|
|
1106
1114
|
//#region \0plugin-vue:export-helper
|
|
1107
|
-
var
|
|
1115
|
+
var Xt = (e, t) => {
|
|
1108
1116
|
let n = e.__vccOpts || e;
|
|
1109
1117
|
for (let [e, r] of t) n[e] = r;
|
|
1110
1118
|
return n;
|
|
1111
|
-
},
|
|
1112
|
-
function
|
|
1113
|
-
return y(), i("div",
|
|
1119
|
+
}, Zt = {}, Qt = { class: "vd-form__row" };
|
|
1120
|
+
function $t(e, t) {
|
|
1121
|
+
return y(), i("div", Qt, [C(e.$slots, "default")]);
|
|
1114
1122
|
}
|
|
1115
|
-
var
|
|
1123
|
+
var en = /*#__PURE__*/ Xt(Zt, [["render", $t]]), J = /* @__PURE__ */ l({
|
|
1116
1124
|
__name: "VdFormCol",
|
|
1117
1125
|
props: {
|
|
1118
1126
|
span: { default: null },
|
|
@@ -1127,16 +1135,16 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1127
1135
|
]);
|
|
1128
1136
|
return (e, t) => (y(), i("div", { class: g(r.value) }, [C(e.$slots, "default")], 2));
|
|
1129
1137
|
}
|
|
1130
|
-
}),
|
|
1138
|
+
}), tn = {
|
|
1131
1139
|
key: 0,
|
|
1132
1140
|
class: "vd-form__banner"
|
|
1133
|
-
},
|
|
1141
|
+
}, nn = ["innerHTML"], rn = {
|
|
1134
1142
|
key: 1,
|
|
1135
1143
|
class: "vd-form__header"
|
|
1136
|
-
},
|
|
1144
|
+
}, an = {
|
|
1137
1145
|
key: 0,
|
|
1138
1146
|
class: "vd-form__title"
|
|
1139
|
-
},
|
|
1147
|
+
}, on = {
|
|
1140
1148
|
key: 1,
|
|
1141
1149
|
class: "vd-form__description"
|
|
1142
1150
|
}, Y = /* @__PURE__ */ l({
|
|
@@ -1173,15 +1181,16 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1173
1181
|
class: g(u.value),
|
|
1174
1182
|
onSubmit: I(d, ["prevent", "stop"])
|
|
1175
1183
|
}, [
|
|
1176
|
-
E(l).banner || e.banner ? (y(), i("div",
|
|
1177
|
-
E(l).header || e.title || e.description ? (y(), i("div",
|
|
1178
|
-
c(
|
|
1184
|
+
E(l).banner || e.banner ? (y(), i("div", tn, [C(t.$slots, "banner", {}, () => [a("span", { innerHTML: e.banner }, null, 8, nn)])])) : r("", !0),
|
|
1185
|
+
E(l).header || e.title || e.description ? (y(), i("div", rn, [C(t.$slots, "header", {}, () => [e.title ? (y(), i("h2", an, T(e.title), 1)) : r("", !0), e.description ? (y(), i("p", on, T(e.description), 1)) : r("", !0)])])) : r("", !0),
|
|
1186
|
+
c(en, null, {
|
|
1179
1187
|
default: P(() => [C(t.$slots, "default"), c(J, {
|
|
1180
1188
|
class: "vd-form__action",
|
|
1181
1189
|
span: e.actionSpan,
|
|
1182
1190
|
md: e.actionMd
|
|
1183
1191
|
}, {
|
|
1184
|
-
default: P(() => [C(t.$slots, "action", {}, () => [c(
|
|
1192
|
+
default: P(() => [C(t.$slots, "action", {}, () => [c(Ne, {
|
|
1193
|
+
type: "submit",
|
|
1185
1194
|
label: e.submitLabel,
|
|
1186
1195
|
"button-type": "green",
|
|
1187
1196
|
size: "big",
|
|
@@ -1195,7 +1204,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1195
1204
|
})
|
|
1196
1205
|
], 34));
|
|
1197
1206
|
}
|
|
1198
|
-
}),
|
|
1207
|
+
}), sn = /* @__PURE__ */ l({
|
|
1199
1208
|
__name: "VdFormGroup",
|
|
1200
1209
|
props: {
|
|
1201
1210
|
span: { default: null },
|
|
@@ -1228,7 +1237,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1228
1237
|
emits: ["update:modelValue"],
|
|
1229
1238
|
setup(e) {
|
|
1230
1239
|
let t = A(), r = k(e, "modelValue");
|
|
1231
|
-
return (i, a) => (y(), n(
|
|
1240
|
+
return (i, a) => (y(), n(We, m({
|
|
1232
1241
|
modelValue: r.value,
|
|
1233
1242
|
"onUpdate:modelValue": a[0] ||= (e) => r.value = e,
|
|
1234
1243
|
label: e.label,
|
|
@@ -1250,7 +1259,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1250
1259
|
"required"
|
|
1251
1260
|
]));
|
|
1252
1261
|
}
|
|
1253
|
-
}),
|
|
1262
|
+
}), cn = /* @__PURE__ */ l({
|
|
1254
1263
|
inheritAttrs: !1,
|
|
1255
1264
|
__name: "VdFamilyCompositionSelect",
|
|
1256
1265
|
props: /*@__PURE__*/ p({
|
|
@@ -1303,21 +1312,21 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1303
1312
|
"required"
|
|
1304
1313
|
]));
|
|
1305
1314
|
}
|
|
1306
|
-
}),
|
|
1307
|
-
let n =
|
|
1315
|
+
}), ln = (e) => e.replace(/\["(\d+)"\]/g, "[$1]"), un = (e, t) => `${e}${t}`, dn = (e) => (e.inner || []).reduce((e, t) => {
|
|
1316
|
+
let n = ln(t.path);
|
|
1308
1317
|
return e[n] || (e[n] = t.message), e;
|
|
1309
|
-
}, {}),
|
|
1318
|
+
}, {}), fn = (e) => {
|
|
1310
1319
|
if (!e.inner) throw e;
|
|
1311
|
-
return
|
|
1312
|
-
},
|
|
1320
|
+
return dn(e);
|
|
1321
|
+
}, pn = { isValidating: !1 }, mn = {
|
|
1313
1322
|
validateAt: "blur",
|
|
1314
1323
|
strict: !0,
|
|
1315
1324
|
abortEarly: !1
|
|
1316
|
-
},
|
|
1325
|
+
}, hn = Symbol("useValidator"), Z = (e, n, r) => {
|
|
1317
1326
|
let i = {
|
|
1318
|
-
...
|
|
1327
|
+
...mn,
|
|
1319
1328
|
...r
|
|
1320
|
-
}, a =
|
|
1329
|
+
}, a = fe(n), o = x(fe(a)), s = x({}), c = x(!1), l = x(!1), u = x({}), d = (e) => t({
|
|
1321
1330
|
get: () => v(e),
|
|
1322
1331
|
set: (t) => y(e, t)
|
|
1323
1332
|
}), f = (e, n) => t(() => ({
|
|
@@ -1328,15 +1337,15 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1328
1337
|
isValid: !N(e),
|
|
1329
1338
|
isValidating: u.value[e]?.isValidating ?? !1
|
|
1330
1339
|
})), g = (e, t) => {
|
|
1331
|
-
let n = t && "value" in t ? t.value :
|
|
1332
|
-
y(e,
|
|
1340
|
+
let n = t && "value" in t ? t.value : st(a, e), r = { isValidating: t?.isValidating ?? !1 }, i = t?.error ?? "";
|
|
1341
|
+
y(e, fe(n)), _(e, r), i ? M({ [e]: i }) : P(e);
|
|
1333
1342
|
}, _ = (e, t) => {
|
|
1334
1343
|
u.value[e] = {
|
|
1335
1344
|
...u.value[e],
|
|
1336
1345
|
...t
|
|
1337
1346
|
};
|
|
1338
|
-
}, v = (e) =>
|
|
1339
|
-
|
|
1347
|
+
}, v = (e) => st(o.value, e), y = (e, t) => {
|
|
1348
|
+
vt(o.value, e, t);
|
|
1340
1349
|
}, S = (e, t) => {
|
|
1341
1350
|
t === "blur" && j(e);
|
|
1342
1351
|
}, C = (e, t) => {
|
|
@@ -1345,7 +1354,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1345
1354
|
t === "input" && h(() => j(e));
|
|
1346
1355
|
}, T = (e, t) => {
|
|
1347
1356
|
let n = t?.validateAt ?? i.validateAt;
|
|
1348
|
-
return _(e,
|
|
1357
|
+
return _(e, pn), [
|
|
1349
1358
|
d(e),
|
|
1350
1359
|
f(e, n),
|
|
1351
1360
|
p(e),
|
|
@@ -1353,10 +1362,10 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1353
1362
|
];
|
|
1354
1363
|
}, E = (e) => {
|
|
1355
1364
|
let t = d(e), n = (t, n) => {
|
|
1356
|
-
let r = n?.validateAt ?? i.validateAt, a =
|
|
1365
|
+
let r = n?.validateAt ?? i.validateAt, a = un(e, t);
|
|
1357
1366
|
return f(a, r).value;
|
|
1358
1367
|
}, r = (t) => {
|
|
1359
|
-
let n =
|
|
1368
|
+
let n = un(e, t);
|
|
1360
1369
|
return N(n);
|
|
1361
1370
|
};
|
|
1362
1371
|
return {
|
|
@@ -1364,7 +1373,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1364
1373
|
getAttrs: n,
|
|
1365
1374
|
getError: r,
|
|
1366
1375
|
getMeta: (t) => {
|
|
1367
|
-
let n =
|
|
1376
|
+
let n = un(e, t);
|
|
1368
1377
|
return m(n);
|
|
1369
1378
|
},
|
|
1370
1379
|
arrayError: r(e),
|
|
@@ -1373,7 +1382,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1373
1382
|
console.warn(`Fields at path "${e}" is not initialized`);
|
|
1374
1383
|
return;
|
|
1375
1384
|
}
|
|
1376
|
-
for (let e = 0; e < r; e++) t.value.push(
|
|
1385
|
+
for (let e = 0; e < r; e++) t.value.push(fe(n));
|
|
1377
1386
|
P(e);
|
|
1378
1387
|
},
|
|
1379
1388
|
pop: (n = 1) => {
|
|
@@ -1394,7 +1403,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1394
1403
|
t.startsWith(e) && P(t);
|
|
1395
1404
|
});
|
|
1396
1405
|
}, k = async (e, t) => {
|
|
1397
|
-
|
|
1406
|
+
ee(!0);
|
|
1398
1407
|
try {
|
|
1399
1408
|
let n = await A();
|
|
1400
1409
|
if (n && typeof e == "function") return await e(n);
|
|
@@ -1402,7 +1411,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1402
1411
|
} catch (e) {
|
|
1403
1412
|
console.error(e);
|
|
1404
1413
|
} finally {
|
|
1405
|
-
|
|
1414
|
+
ee(!1);
|
|
1406
1415
|
}
|
|
1407
1416
|
}, A = async () => {
|
|
1408
1417
|
L(!0), I();
|
|
@@ -1412,7 +1421,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1412
1421
|
abortEarly: i.abortEarly
|
|
1413
1422
|
}), o.value;
|
|
1414
1423
|
} catch (e) {
|
|
1415
|
-
let t =
|
|
1424
|
+
let t = fn(e);
|
|
1416
1425
|
M(t);
|
|
1417
1426
|
return;
|
|
1418
1427
|
} finally {
|
|
@@ -1426,7 +1435,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1426
1435
|
abortEarly: i.abortEarly
|
|
1427
1436
|
});
|
|
1428
1437
|
} catch (e) {
|
|
1429
|
-
let t =
|
|
1438
|
+
let t = fn(e);
|
|
1430
1439
|
M(t);
|
|
1431
1440
|
} finally {
|
|
1432
1441
|
_(t, { isValidating: !1 });
|
|
@@ -1443,9 +1452,9 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1443
1452
|
s.value = {};
|
|
1444
1453
|
}, L = (e) => {
|
|
1445
1454
|
l.value = e;
|
|
1446
|
-
},
|
|
1455
|
+
}, ee = (e) => {
|
|
1447
1456
|
c.value = e;
|
|
1448
|
-
},
|
|
1457
|
+
}, te = {
|
|
1449
1458
|
formData: o,
|
|
1450
1459
|
errors: t(() => s.value),
|
|
1451
1460
|
isValid: t(() => Object.keys(s.value).length === 0),
|
|
@@ -1464,18 +1473,18 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1464
1473
|
validateForm: A,
|
|
1465
1474
|
validateField: j
|
|
1466
1475
|
};
|
|
1467
|
-
return b(
|
|
1468
|
-
},
|
|
1469
|
-
let e = u(
|
|
1476
|
+
return b(hn, te), te;
|
|
1477
|
+
}, gn = () => {
|
|
1478
|
+
let e = u(hn);
|
|
1470
1479
|
if (!e) throw Error("useValidatorContext must be used within a component that has called useValidator");
|
|
1471
1480
|
return e;
|
|
1472
|
-
},
|
|
1481
|
+
}, _n = { class: "vd-field" }, vn = {
|
|
1473
1482
|
key: 0,
|
|
1474
1483
|
class: "vd-field__message vd-field__message--error"
|
|
1475
|
-
},
|
|
1484
|
+
}, yn = {
|
|
1476
1485
|
key: 1,
|
|
1477
1486
|
class: "vd-field__message vd-field__message--information"
|
|
1478
|
-
},
|
|
1487
|
+
}, bn = /* @__PURE__ */ l({
|
|
1479
1488
|
__name: "VdAddress",
|
|
1480
1489
|
props: /*@__PURE__*/ p({
|
|
1481
1490
|
path: { default: "address" },
|
|
@@ -1486,7 +1495,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1486
1495
|
}),
|
|
1487
1496
|
emits: ["update:resolvedAddress"],
|
|
1488
1497
|
setup(e) {
|
|
1489
|
-
let n = e, o = k(e, "resolvedAddress"), { path: l } = n, { defineField: u, validateField: f, getFieldMeta: p, getError: m, removeError: g } =
|
|
1498
|
+
let n = e, o = k(e, "resolvedAddress"), { path: l } = n, { defineField: u, validateField: f, getFieldMeta: p, getError: m, removeError: g } = gn(), [_, , b] = u(`${l}.zipCode`), [x, , S] = u(`${l}.houseNumber`), [C, , w] = u(`${l}.houseNumberAddition`), D = async () => {
|
|
1490
1499
|
await f(l), C.value || g(`${l}.houseNumberAddition`);
|
|
1491
1500
|
}, O = (e) => {
|
|
1492
1501
|
_.value && x.value ? D() : f(e);
|
|
@@ -1497,12 +1506,12 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1497
1506
|
o.value = null;
|
|
1498
1507
|
}), v(() => {
|
|
1499
1508
|
_.value && x.value && D();
|
|
1500
|
-
}), (t, n) => (y(), i("div",
|
|
1509
|
+
}), (t, n) => (y(), i("div", _n, [c(en, null, {
|
|
1501
1510
|
default: P(() => [c(J, {
|
|
1502
1511
|
span: "5",
|
|
1503
1512
|
md: "3"
|
|
1504
1513
|
}, {
|
|
1505
|
-
default: P(() => [c(
|
|
1514
|
+
default: P(() => [c(We, {
|
|
1506
1515
|
modelValue: E(_),
|
|
1507
1516
|
"onUpdate:modelValue": n[0] ||= (e) => d(_) ? _.value = e : null,
|
|
1508
1517
|
modelModifiers: { trim: !0 },
|
|
@@ -1524,11 +1533,11 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1524
1533
|
"loading"
|
|
1525
1534
|
])]),
|
|
1526
1535
|
_: 1
|
|
1527
|
-
}), c(
|
|
1536
|
+
}), c(sn, {
|
|
1528
1537
|
span: "7",
|
|
1529
1538
|
md: "3"
|
|
1530
1539
|
}, {
|
|
1531
|
-
default: P(() => [c(
|
|
1540
|
+
default: P(() => [c(We, {
|
|
1532
1541
|
modelValue: E(x),
|
|
1533
1542
|
"onUpdate:modelValue": n[1] ||= (e) => d(x) ? x.value = e : null,
|
|
1534
1543
|
modelModifiers: { trim: !0 },
|
|
@@ -1570,9 +1579,9 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1570
1579
|
_: 1
|
|
1571
1580
|
})]),
|
|
1572
1581
|
_: 1
|
|
1573
|
-
}), I.value ? (y(), i("div",
|
|
1582
|
+
}), I.value ? (y(), i("div", vn, [n[3] ||= a("i", { class: "fas fa-exclamation-circle vd-field__message-icon" }, null, -1), s(" " + T(I.value), 1)])) : o.value ? (y(), i("div", yn, [n[4] ||= a("i", { class: "fas fa-info-circle vd-field__message-icon" }, null, -1), s(" " + T(o.value.street) + ", " + T(o.value.city), 1)])) : r("", !0)]));
|
|
1574
1583
|
}
|
|
1575
|
-
}),
|
|
1584
|
+
}), xn = {
|
|
1576
1585
|
vd: { url: "http://master.dev.vergelijkdirect.com/index.php" },
|
|
1577
1586
|
mijn: { url: "http://master.mijn-api.vergelijkdirect.com" },
|
|
1578
1587
|
api: { url: "http://master.api.vergelijkdirect.com/" },
|
|
@@ -1582,7 +1591,7 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1582
1591
|
currentItemId: "6622695672245691fb02ce02",
|
|
1583
1592
|
nextItemId: "65e342a01f2b9e9db1060335"
|
|
1584
1593
|
}
|
|
1585
|
-
},
|
|
1594
|
+
}, Sn = class e {
|
|
1586
1595
|
values;
|
|
1587
1596
|
cached;
|
|
1588
1597
|
static instance = new e();
|
|
@@ -1595,22 +1604,22 @@ var sn = /*#__PURE__*/ nn(rn, [["render", on]]), J = /* @__PURE__ */ l({
|
|
|
1595
1604
|
get(e) {
|
|
1596
1605
|
return e in this.cached ? this.cached[e] : e in this.values ? this.cached[e] = this.values[e](this) : (`${e}`, !1);
|
|
1597
1606
|
}
|
|
1598
|
-
},
|
|
1607
|
+
}, Cn = class {
|
|
1599
1608
|
static configure(e) {
|
|
1600
|
-
let t =
|
|
1609
|
+
let t = Sn.instance;
|
|
1601
1610
|
e.api && e.api.url && t.constant("vd-api-url", e.api.url), e.mijn && e.mijn.url && t.constant("mijn-api-url", e.mijn.url), e.qa && e.qa.url && t.constant("qa-api-url", e.qa.url);
|
|
1602
1611
|
}
|
|
1603
1612
|
static getApiUrl() {
|
|
1604
|
-
return
|
|
1613
|
+
return Sn.instance.get("vd-api-url") || xn.api.url;
|
|
1605
1614
|
}
|
|
1606
1615
|
static getMijnUrl() {
|
|
1607
|
-
return
|
|
1616
|
+
return Sn.instance.get("mijn-api-url") || xn.mijn.url;
|
|
1608
1617
|
}
|
|
1609
1618
|
static getQAUrl() {
|
|
1610
|
-
return
|
|
1619
|
+
return Sn.instance.get("qa-api-url") || xn.qa.url;
|
|
1611
1620
|
}
|
|
1612
|
-
},
|
|
1613
|
-
function
|
|
1621
|
+
}, wn = () => Cn.getQAUrl(), Tn;
|
|
1622
|
+
function En() {
|
|
1614
1623
|
return {
|
|
1615
1624
|
dataService: new Te(),
|
|
1616
1625
|
dataValidationService: new Ee(),
|
|
@@ -1618,62 +1627,62 @@ function Mn() {
|
|
|
1618
1627
|
comparisonService: new we()
|
|
1619
1628
|
};
|
|
1620
1629
|
}
|
|
1621
|
-
function
|
|
1622
|
-
return
|
|
1630
|
+
function Dn() {
|
|
1631
|
+
return Tn ||= En(), Tn;
|
|
1623
1632
|
}
|
|
1624
1633
|
//#endregion
|
|
1625
1634
|
//#region src/components/fields/address/address.presenter.ts
|
|
1626
|
-
var
|
|
1635
|
+
var On = (e) => ({
|
|
1627
1636
|
zipCode: e.ZipCode,
|
|
1628
1637
|
houseNumber: String(e.HouseNumber),
|
|
1629
1638
|
houseNumberAddition: e.HouseNumberAddition,
|
|
1630
1639
|
city: e.Place,
|
|
1631
1640
|
street: e.Street
|
|
1632
|
-
}),
|
|
1641
|
+
}), kn = /^\d{4}\s?[a-zA-Z]{2}$/, An = /^\d+$/, jn = {
|
|
1633
1642
|
"needs-addition": "Een toevoeging is verplicht",
|
|
1634
1643
|
"not-found": "Postcode en huisnummer combinatie onbekend.",
|
|
1635
1644
|
error: "Adres ophalen is mislukt. Probeer het opnieuw."
|
|
1636
1645
|
};
|
|
1637
|
-
function
|
|
1646
|
+
function Mn(e) {
|
|
1638
1647
|
return e.replace(/\s/g, "").toUpperCase();
|
|
1639
1648
|
}
|
|
1640
|
-
var
|
|
1641
|
-
function
|
|
1642
|
-
return e ===
|
|
1649
|
+
var Nn = "NO_ADDITION";
|
|
1650
|
+
function Pn(e) {
|
|
1651
|
+
return e === Nn ? "" : e.replace("-", "");
|
|
1643
1652
|
}
|
|
1644
|
-
var
|
|
1645
|
-
if (
|
|
1653
|
+
var Fn = (e) => e instanceof Error, In = (e) => {
|
|
1654
|
+
if (Fn(e)) throw e;
|
|
1646
1655
|
return null;
|
|
1647
|
-
},
|
|
1656
|
+
}, Ln = (e, t, n) => Dn().dataValidationService.validateZipCode(e, t, n).then((e) => e).catch(In), Rn = (e, t) => Dn().homeService.getAddition({
|
|
1648
1657
|
zipcode: e,
|
|
1649
1658
|
houseNumber: t
|
|
1650
|
-
}).then((e) => e ?? []).catch(
|
|
1651
|
-
let [n, r] = await Promise.all([
|
|
1659
|
+
}).then((e) => e ?? []).catch(In), zn = async (e, t) => {
|
|
1660
|
+
let [n, r] = await Promise.all([Ln(e, t), Rn(e, t)]);
|
|
1652
1661
|
return !n && !r?.length ? null : {
|
|
1653
1662
|
validWithoutAddition: !!n,
|
|
1654
1663
|
template: n,
|
|
1655
1664
|
additions: r ?? []
|
|
1656
1665
|
};
|
|
1657
|
-
},
|
|
1666
|
+
}, Bn = (e) => {
|
|
1658
1667
|
let t = e.additions.map((e) => ({
|
|
1659
1668
|
title: e,
|
|
1660
|
-
value:
|
|
1669
|
+
value: Pn(e)
|
|
1661
1670
|
}));
|
|
1662
1671
|
return e.validWithoutAddition && t.length ? [{
|
|
1663
1672
|
title: "Geen toevoeging",
|
|
1664
|
-
value:
|
|
1673
|
+
value: Nn
|
|
1665
1674
|
}, ...t] : t;
|
|
1666
|
-
},
|
|
1675
|
+
}, Vn = (e) => ({
|
|
1667
1676
|
zipCode: e?.zipCode ?? "",
|
|
1668
1677
|
houseNumber: e?.houseNumber ?? "",
|
|
1669
|
-
houseNumberAddition: e ? e.houseNumberAddition ||
|
|
1670
|
-
}),
|
|
1671
|
-
let t = e?.path ?? "address", n =
|
|
1672
|
-
let t =
|
|
1678
|
+
houseNumberAddition: e ? e.houseNumberAddition || Nn : ""
|
|
1679
|
+
}), Hn = (e) => {
|
|
1680
|
+
let t = e?.path ?? "address", n = Vn(e?.initial), r = x(null), i = x([]), a = 0, o = null, s = async (e) => {
|
|
1681
|
+
let t = Mn(e.zipCode), n = e.houseNumber.trim(), r = Pn(e.houseNumberAddition), i = `${t}:${n}`;
|
|
1673
1682
|
try {
|
|
1674
1683
|
let a = o?.key === i ? o : null;
|
|
1675
1684
|
if (!a) {
|
|
1676
|
-
let e = await
|
|
1685
|
+
let e = await zn(t, n);
|
|
1677
1686
|
if (!e) return {
|
|
1678
1687
|
status: "not-found",
|
|
1679
1688
|
options: [],
|
|
@@ -1684,14 +1693,14 @@ var Vn = (e) => e instanceof Error, Hn = (e) => {
|
|
|
1684
1693
|
verdict: e
|
|
1685
1694
|
};
|
|
1686
1695
|
}
|
|
1687
|
-
let s =
|
|
1696
|
+
let s = Bn(a.verdict);
|
|
1688
1697
|
if (a.verdict.additions.length && !e.houseNumberAddition) return {
|
|
1689
1698
|
status: "needs-addition",
|
|
1690
1699
|
options: s,
|
|
1691
1700
|
address: null
|
|
1692
1701
|
};
|
|
1693
1702
|
if (!a.verdict.template) {
|
|
1694
|
-
let e = await
|
|
1703
|
+
let e = await Ln(t, n, r);
|
|
1695
1704
|
if (!e) return {
|
|
1696
1705
|
status: "not-found",
|
|
1697
1706
|
options: [],
|
|
@@ -1716,7 +1725,7 @@ var Vn = (e) => e instanceof Error, Hn = (e) => {
|
|
|
1716
1725
|
}
|
|
1717
1726
|
}, c = async (e) => {
|
|
1718
1727
|
let t = ++a, n = await s(e), o = t !== a;
|
|
1719
|
-
return o || (i.value = n.options, r.value = n.address ?
|
|
1728
|
+
return o || (i.value = n.options, r.value = n.address ? On(n.address) : null), {
|
|
1720
1729
|
...n,
|
|
1721
1730
|
stale: o
|
|
1722
1731
|
};
|
|
@@ -1724,23 +1733,23 @@ var Vn = (e) => e instanceof Error, Hn = (e) => {
|
|
|
1724
1733
|
return {
|
|
1725
1734
|
path: t,
|
|
1726
1735
|
addressSchema: R({
|
|
1727
|
-
zipCode: z().required("Vul je postcode in").matches(
|
|
1728
|
-
houseNumber: z().required("Huisnummer is verplicht").matches(
|
|
1736
|
+
zipCode: z().required("Vul je postcode in").matches(kn, "Postcode is incorrect"),
|
|
1737
|
+
houseNumber: z().required("Huisnummer is verplicht").matches(An, "Huisnummer is incorrect"),
|
|
1729
1738
|
houseNumberAddition: z().defined()
|
|
1730
1739
|
}).test("address-lookup", async (e, t) => {
|
|
1731
|
-
let n =
|
|
1732
|
-
if (!
|
|
1740
|
+
let n = Mn(e.zipCode ?? ""), r = String(e.houseNumber ?? "").trim();
|
|
1741
|
+
if (!kn.test(n) || !An.test(r)) return !0;
|
|
1733
1742
|
let { status: i, stale: a } = await c(e);
|
|
1734
1743
|
return a || i === "resolved" ? !0 : i === "needs-addition" ? t.createError({
|
|
1735
1744
|
path: `${t.path}.houseNumberAddition`,
|
|
1736
|
-
message:
|
|
1737
|
-
}) : t.createError({ message:
|
|
1745
|
+
message: jn[i]
|
|
1746
|
+
}) : t.createError({ message: jn[i] });
|
|
1738
1747
|
}),
|
|
1739
1748
|
draft: n,
|
|
1740
1749
|
resolvedAddress: r,
|
|
1741
1750
|
additionOptions: i
|
|
1742
1751
|
};
|
|
1743
|
-
},
|
|
1752
|
+
}, Un = {
|
|
1744
1753
|
[V.Car]: {
|
|
1745
1754
|
apiTypes: ["Car", "Van"],
|
|
1746
1755
|
dutch: "auto",
|
|
@@ -1761,14 +1770,14 @@ var Vn = (e) => e instanceof Error, Hn = (e) => {
|
|
|
1761
1770
|
dutch: "caravan",
|
|
1762
1771
|
icon: "fa-caravan-alt"
|
|
1763
1772
|
}
|
|
1764
|
-
},
|
|
1773
|
+
}, Wn = Object.fromEntries(Object.values(Un).flatMap(({ apiTypes: e, icon: t }) => e.map((e) => [e.toLowerCase(), t]))), Gn = {
|
|
1765
1774
|
brommobiel: "fa-car-side",
|
|
1766
1775
|
"speed pedelec": "fa-bicycle"
|
|
1767
|
-
},
|
|
1776
|
+
}, Kn = (e) => !!e?.Brand && !!e.Model && !!e.ManufacturingYear, qn = (e) => {
|
|
1768
1777
|
if (!e) return "";
|
|
1769
1778
|
let t = String(e.Model ?? "").toLowerCase().trim(), n = String(e.VehicleType ?? "").toLowerCase();
|
|
1770
|
-
return
|
|
1771
|
-
},
|
|
1779
|
+
return Gn[t] ?? Wn[n] ?? "";
|
|
1780
|
+
}, Jn = (e) => e ? `${e.Brand} ${e.Model} (${e.ManufacturingYear})` : "", Yn = [
|
|
1772
1781
|
"@@-##-@@",
|
|
1773
1782
|
"##-##-@@",
|
|
1774
1783
|
"##-@@-@@",
|
|
@@ -1786,22 +1795,22 @@ var Vn = (e) => e instanceof Error, Hn = (e) => {
|
|
|
1786
1795
|
];
|
|
1787
1796
|
//#endregion
|
|
1788
1797
|
//#region src/components/fields/licensePlate/licensePlate.util.ts
|
|
1789
|
-
function
|
|
1798
|
+
function Xn(e) {
|
|
1790
1799
|
return e.replace(/[\s\\-]/g, "");
|
|
1791
1800
|
}
|
|
1792
|
-
var
|
|
1793
|
-
function
|
|
1794
|
-
let t =
|
|
1795
|
-
if (t.length < 6) return
|
|
1796
|
-
let n = [...t].map((e) => /[0-9]/.test(e) ? "#" : "@").join(""), r =
|
|
1797
|
-
return r === -1 ?
|
|
1801
|
+
var Zn = "*".repeat(6), Qn = Yn.map((e) => e.replace(/-/g, ""));
|
|
1802
|
+
function $n(e) {
|
|
1803
|
+
let t = Xn(e).slice(0, 6);
|
|
1804
|
+
if (t.length < 6) return Zn;
|
|
1805
|
+
let n = [...t].map((e) => /[0-9]/.test(e) ? "#" : "@").join(""), r = Qn.indexOf(n);
|
|
1806
|
+
return r === -1 ? Zn : Yn[r];
|
|
1798
1807
|
}
|
|
1799
1808
|
//#endregion
|
|
1800
1809
|
//#region src/components/fields/licensePlate/VdLicensePlate.vue?vue&type=script&setup=true&lang.ts
|
|
1801
|
-
var
|
|
1810
|
+
var er = {
|
|
1802
1811
|
key: 0,
|
|
1803
1812
|
class: "vd-input-license-plate__loading-information"
|
|
1804
|
-
},
|
|
1813
|
+
}, tr = ["src"], nr = /* @__PURE__ */ l({
|
|
1805
1814
|
inheritAttrs: !1,
|
|
1806
1815
|
__name: "VdLicensePlate",
|
|
1807
1816
|
props: /*@__PURE__*/ p({
|
|
@@ -1824,17 +1833,17 @@ var or = {
|
|
|
1824
1833
|
}),
|
|
1825
1834
|
emits: /*@__PURE__*/ p(["input"], ["update:modelValue", "update:vehicleData"]),
|
|
1826
1835
|
setup(c, { emit: l }) {
|
|
1827
|
-
let u = { mask:
|
|
1836
|
+
let u = { mask: $n }, d = c, f = k(c, "modelValue"), p = k(c, "vehicleData"), h = l, g = D(), _ = A(), v = t({
|
|
1828
1837
|
get: () => f.value ?? "",
|
|
1829
1838
|
set: (e) => {
|
|
1830
1839
|
f.value = e, h("input", e);
|
|
1831
1840
|
}
|
|
1832
|
-
}), b = (e, t) =>
|
|
1841
|
+
}), b = (e, t) => Xn(e).toUpperCase() === Xn(t).toUpperCase();
|
|
1833
1842
|
N(f, (e) => {
|
|
1834
1843
|
p.value && !b(e, p.value.LicensePlate) && (p.value = null);
|
|
1835
1844
|
});
|
|
1836
|
-
let x = t(() =>
|
|
1837
|
-
return (t, l) => (y(), n(
|
|
1845
|
+
let x = t(() => Kn(p.value) ? p.value : null), S = t(() => d.loading || !!x.value && !d.errorMessage), w = t(() => qn(x.value)), O = t(() => Jn(x.value));
|
|
1846
|
+
return (t, l) => (y(), n(We, m(E(g), {
|
|
1838
1847
|
modelValue: v.value,
|
|
1839
1848
|
"onUpdate:modelValue": l[0] ||= (e) => v.value = e,
|
|
1840
1849
|
capitalize: "",
|
|
@@ -1859,12 +1868,12 @@ var or = {
|
|
|
1859
1868
|
} : void 0,
|
|
1860
1869
|
S.value ? {
|
|
1861
1870
|
name: "information",
|
|
1862
|
-
fn: P(() => [c.loading ? (y(), i("div",
|
|
1871
|
+
fn: P(() => [c.loading ? (y(), i("div", er, [...l[1] ||= [a("i", { class: "fas fa-circle-notch vd-input-license-plate__loading-icon" }, null, -1), s(" Voertuig gegevens ophalen... ", -1)]])) : x.value ? (y(), i(e, { key: 1 }, [w.value ? (y(), i("img", {
|
|
1863
1872
|
key: 0,
|
|
1864
1873
|
src: `https://d12bmfj3oyxu0t.cloudfront.net/vergelijkdirect/icons/${w.value}.svg`,
|
|
1865
1874
|
class: "vd-field__svg-message-icon",
|
|
1866
1875
|
alt: "vehicle-icon"
|
|
1867
|
-
}, null, 8,
|
|
1876
|
+
}, null, 8, tr)) : r("", !0), s(" " + T(O.value), 1)], 64)) : r("", !0)]),
|
|
1868
1877
|
key: "2"
|
|
1869
1878
|
} : void 0
|
|
1870
1879
|
]), 1040, [
|
|
@@ -1876,56 +1885,56 @@ var or = {
|
|
|
1876
1885
|
"loading"
|
|
1877
1886
|
]));
|
|
1878
1887
|
}
|
|
1879
|
-
}),
|
|
1880
|
-
"wrong-type": (e) => `Het ingevoerde kenteken is geen ${
|
|
1888
|
+
}), rr = /* @__PURE__ */ new Map(), ir = (e, t) => `${t}:${e}`, ar = {
|
|
1889
|
+
"wrong-type": (e) => `Het ingevoerde kenteken is geen ${Un[e].dutch}`,
|
|
1881
1890
|
unknown: () => "Voertuig onbekend - Voer ander kenteken in of neem contact op",
|
|
1882
1891
|
"not-found": () => "Kenteken onbekend",
|
|
1883
1892
|
error: () => "Kenteken is incorrect"
|
|
1884
|
-
},
|
|
1893
|
+
}, or = async (e, t) => {
|
|
1885
1894
|
try {
|
|
1886
|
-
let n = await
|
|
1895
|
+
let n = await Dn().dataService.findVehicle(e, t);
|
|
1887
1896
|
if (Array.isArray(n) || !n || !Object.keys(n).length) return { status: "not-found" };
|
|
1888
1897
|
let r = n;
|
|
1889
|
-
return r.VehicleType ?
|
|
1898
|
+
return r.VehicleType ? Un[t].apiTypes.includes(r.VehicleType) ? {
|
|
1890
1899
|
status: "found",
|
|
1891
1900
|
data: r
|
|
1892
1901
|
} : { status: "wrong-type" } : { status: "unknown" };
|
|
1893
1902
|
} catch (e) {
|
|
1894
1903
|
return console.error("Error on ITC findVehicle", e), { status: "error" };
|
|
1895
1904
|
}
|
|
1896
|
-
},
|
|
1897
|
-
let n =
|
|
1898
|
-
return r || (r =
|
|
1899
|
-
e === "error" &&
|
|
1900
|
-
}, () =>
|
|
1901
|
-
},
|
|
1905
|
+
}, sr = (e, t) => {
|
|
1906
|
+
let n = ir(e, t), r = rr.get(n);
|
|
1907
|
+
return r || (r = or(e, t), rr.set(n, r), r.then(({ status: e }) => {
|
|
1908
|
+
e === "error" && rr.delete(n);
|
|
1909
|
+
}, () => rr.delete(n))), r;
|
|
1910
|
+
}, cr = (e, t = {}) => {
|
|
1902
1911
|
let n = x(t.initialData ?? null), r = 0;
|
|
1903
|
-
t.initialData?.LicensePlate &&
|
|
1912
|
+
t.initialData?.LicensePlate && rr.set(ir(Xn(t.initialData.LicensePlate), e), Promise.resolve({
|
|
1904
1913
|
status: "found",
|
|
1905
1914
|
data: t.initialData
|
|
1906
1915
|
}));
|
|
1907
1916
|
let i = async (t) => {
|
|
1908
|
-
let i =
|
|
1917
|
+
let i = Xn(t), a = ++r, o = await sr(i, e);
|
|
1909
1918
|
return a === r && (n.value = o.status === "found" ? o.data : null), o;
|
|
1910
1919
|
};
|
|
1911
1920
|
return {
|
|
1912
1921
|
vehicleData: n,
|
|
1913
1922
|
licensePlateSchema: z().required("Dit veld is verplicht").test("license-plate-lookup", async (t, n) => {
|
|
1914
1923
|
if (!t) return !0;
|
|
1915
|
-
let r =
|
|
1924
|
+
let r = Xn(t);
|
|
1916
1925
|
if (r.length < 6) return n.createError({ message: "Kenteken is incorrect" });
|
|
1917
1926
|
let { status: a } = await i(r);
|
|
1918
|
-
return a === "found" || n.createError({ message:
|
|
1927
|
+
return a === "found" || n.createError({ message: ar[a](e) });
|
|
1919
1928
|
})
|
|
1920
1929
|
};
|
|
1921
|
-
},
|
|
1930
|
+
}, lr = (e) => /^\d{8}$/.test(e), ur = (e) => lr(e) ? {
|
|
1922
1931
|
companyName: "",
|
|
1923
1932
|
kvkNumber: e
|
|
1924
1933
|
} : {
|
|
1925
1934
|
companyName: e,
|
|
1926
1935
|
kvkNumber: ""
|
|
1927
|
-
},
|
|
1928
|
-
let t =
|
|
1936
|
+
}, dr = "bezoekadres", fr = (e) => e._embedded?.hoofdvestiging?.adressen?.find((e) => e.type === dr), pr = (e) => {
|
|
1937
|
+
let t = fr(e), { huisnummer: n = 0, huisletter: r = "", huisnummerToevoeging: i = "", toevoegingAdres: a = "", plaats: o = "", postcode: s = "", straatnaam: c = "", volledigAdres: l = "" } = t ?? {};
|
|
1929
1938
|
return {
|
|
1930
1939
|
houseNumber: n,
|
|
1931
1940
|
houseNumberAddition: r || i || a,
|
|
@@ -1935,7 +1944,7 @@ var or = {
|
|
|
1935
1944
|
fullAddress: l,
|
|
1936
1945
|
hasVisitingAddress: !!t
|
|
1937
1946
|
};
|
|
1938
|
-
},
|
|
1947
|
+
}, mr = (e = []) => {
|
|
1939
1948
|
let [t, n, r] = e.reduce(([e, t, n], r) => {
|
|
1940
1949
|
let i = {
|
|
1941
1950
|
isMainActivity: r.indHoofdactiviteit,
|
|
@@ -1958,20 +1967,20 @@ var or = {
|
|
|
1958
1967
|
firstSBIs: t,
|
|
1959
1968
|
secondSBIs: n
|
|
1960
1969
|
};
|
|
1961
|
-
},
|
|
1970
|
+
}, hr = (e) => ({
|
|
1962
1971
|
kvkNumber: e.kvkNummer,
|
|
1963
1972
|
name: e.naam,
|
|
1964
1973
|
city: e.adres?.binnenlandsAdres?.plaats ?? "",
|
|
1965
1974
|
street: e.adres?.binnenlandsAdres?.straatnaam ?? ""
|
|
1966
|
-
}),
|
|
1975
|
+
}), gr = (e) => ({
|
|
1967
1976
|
name: e.naam,
|
|
1968
1977
|
kvkNumber: e.kvkNummer,
|
|
1969
1978
|
industry: e.sbiIndustryId,
|
|
1970
1979
|
numberOfEmployees: e.totaalWerkzamePersonen,
|
|
1971
1980
|
legalForm: e._embedded?.eigenaar?.rechtsvorm ?? "",
|
|
1972
|
-
...
|
|
1973
|
-
...
|
|
1974
|
-
}),
|
|
1981
|
+
...pr(e),
|
|
1982
|
+
...mr(e.sbiActiviteiten)
|
|
1983
|
+
}), _r = 30, vr = ["hoofdvestiging", "nevenvestiging"], yr = "IPD5200", br = (e) => {
|
|
1975
1984
|
let t = e, n = t?.response?.data?.fout;
|
|
1976
1985
|
if (Array.isArray(n)) return n;
|
|
1977
1986
|
if (Array.isArray(t?.fout)) return t.fout;
|
|
@@ -1979,24 +1988,24 @@ var or = {
|
|
|
1979
1988
|
let e = JSON.parse(t.message);
|
|
1980
1989
|
if (Array.isArray(e?.fout)) return e.fout;
|
|
1981
1990
|
} catch {}
|
|
1982
|
-
},
|
|
1991
|
+
}, xr = (e) => br(e)?.some((e) => e.code === yr) ?? !1, Sr = () => ({
|
|
1983
1992
|
search: async (e) => {
|
|
1984
1993
|
try {
|
|
1985
|
-
return ((await
|
|
1994
|
+
return ((await Dn().dataService.searchBusinessInfoV2(ur(e), 1, _r))?.resultaten ?? []).filter((e) => vr.includes(e.type)).map(hr);
|
|
1986
1995
|
} catch (e) {
|
|
1987
1996
|
let t = await e;
|
|
1988
|
-
if (
|
|
1997
|
+
if (xr(t)) return [];
|
|
1989
1998
|
throw t;
|
|
1990
1999
|
}
|
|
1991
2000
|
},
|
|
1992
2001
|
getDetails: async (e) => {
|
|
1993
|
-
let t = await
|
|
2002
|
+
let t = await Dn().dataService.getProfileInfo(e);
|
|
1994
2003
|
return {
|
|
1995
|
-
presenter:
|
|
2004
|
+
presenter: gr(t),
|
|
1996
2005
|
raw: t
|
|
1997
2006
|
};
|
|
1998
2007
|
}
|
|
1999
|
-
}),
|
|
2008
|
+
}), Cr = { class: "vd-combobox__multiline" }, wr = { class: "vd-combobox__title" }, Tr = { class: "vd-combobox__subtext" }, Er = { class: "vd-combobox__subtext" }, Dr = 400, Or = 3, kr = "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.", Ar = "Typ je bedrijfsnaam of KvK-nummer", jr = "Aan het zoeken…", Mr = "Er ging iets mis bij het ophalen van de gegevens. Probeer het later opnieuw.", Nr = /* @__PURE__ */ l({
|
|
2000
2009
|
inheritAttrs: !1,
|
|
2001
2010
|
__name: "VdCompanySelect",
|
|
2002
2011
|
props: /*@__PURE__*/ p({
|
|
@@ -2015,7 +2024,7 @@ var or = {
|
|
|
2015
2024
|
"raw"
|
|
2016
2025
|
], ["update:modelValue"]),
|
|
2017
2026
|
setup(e, { emit: r }) {
|
|
2018
|
-
let i = r, s = D(), c = A(), l = k(e, "modelValue"), { search: u, getDetails: d } =
|
|
2027
|
+
let i = r, s = D(), c = A(), l = k(e, "modelValue"), { search: u, getDetails: d } = Sr(), f = x(), p = x(), h = x(), g = x(""), _ = he(g, Dr, { maxWait: 2e3 }), v = x(!0), { state: b, isLoading: S, execute: w } = ge(async (e) => {
|
|
2019
2028
|
try {
|
|
2020
2029
|
return {
|
|
2021
2030
|
results: await u(e),
|
|
@@ -2033,33 +2042,33 @@ var or = {
|
|
|
2033
2042
|
}, {
|
|
2034
2043
|
immediate: !1,
|
|
2035
2044
|
resetOnExecute: !1
|
|
2036
|
-
}), { isLoading: O, execute: j } =
|
|
2045
|
+
}), { isLoading: O, execute: j } = ge(async (e) => {
|
|
2037
2046
|
try {
|
|
2038
2047
|
let { presenter: t, raw: n } = await d(e);
|
|
2039
2048
|
return l.value = t, i("raw", n), i("error", null), t;
|
|
2040
2049
|
} catch (e) {
|
|
2041
|
-
throw l.value = null, i("raw", null), h.value = void 0, f.value = void 0, i("error",
|
|
2050
|
+
throw l.value = null, i("raw", null), h.value = void 0, f.value = void 0, i("error", Mr), e;
|
|
2042
2051
|
}
|
|
2043
2052
|
}, null, {
|
|
2044
2053
|
immediate: !1,
|
|
2045
2054
|
resetOnExecute: !0
|
|
2046
|
-
}), M = t(() => g.value.length >=
|
|
2055
|
+
}), M = t(() => g.value.length >= Or), F = t(() => M.value ? S.value || g.value !== _.value ? "searching" : b.value.failed ? "error" : b.value.results.length ? "idle" : "no-results" : "idle"), I = t(() => F.value === "searching" ? [] : M.value ? b.value.results : v.value && h.value ? [h.value] : []), L = t(() => F.value === "searching" || O.value), ee = t(() => !!l.value && !L.value), te = t(() => {
|
|
2047
2056
|
let e = l.value;
|
|
2048
2057
|
return !e || L.value ? "" : e.fullAddress ? `Kvk: ${e.kvkNumber} ${e.fullAddress}` : `Kvk: ${e.kvkNumber}`;
|
|
2049
2058
|
}), ne = t(() => {
|
|
2050
2059
|
switch (F.value) {
|
|
2051
|
-
case "searching": return
|
|
2052
|
-
case "error": return
|
|
2053
|
-
case "no-results": return
|
|
2054
|
-
default: return
|
|
2060
|
+
case "searching": return jr;
|
|
2061
|
+
case "error": return Mr;
|
|
2062
|
+
case "no-results": return kr;
|
|
2063
|
+
default: return Ar;
|
|
2055
2064
|
}
|
|
2056
|
-
}),
|
|
2065
|
+
}), re = (e) => {
|
|
2057
2066
|
h.value = e, v.value = !0, e.kvkNumber === l.value?.kvkNumber ? i("error", null) : j(0, e.kvkNumber);
|
|
2058
|
-
},
|
|
2067
|
+
}, ie = (e) => {
|
|
2059
2068
|
i("blur", e);
|
|
2060
|
-
},
|
|
2069
|
+
}, ae = (e) => {
|
|
2061
2070
|
g.value = e.trim(), v.value = !1;
|
|
2062
|
-
},
|
|
2071
|
+
}, oe = (e) => e.kvkNumber === l.value?.kvkNumber ? l.value.name : e.name, se = (e) => ({
|
|
2063
2072
|
kvkNumber: e.kvkNumber,
|
|
2064
2073
|
name: e.name,
|
|
2065
2074
|
city: e.city,
|
|
@@ -2069,10 +2078,10 @@ var or = {
|
|
|
2069
2078
|
return N(p, (e) => {
|
|
2070
2079
|
e || (g.value = "", v.value = !0);
|
|
2071
2080
|
}), N(_, (e) => {
|
|
2072
|
-
e && e.length >=
|
|
2081
|
+
e && e.length >= Or && w(0, e);
|
|
2073
2082
|
}), N(l, (e) => {
|
|
2074
|
-
f.value = e ?
|
|
2075
|
-
}, { immediate: !0 }), (t, r) => (y(), n(
|
|
2083
|
+
f.value = e ? se(e) : void 0, v.value = !0, e || (h.value = void 0, i("raw", null));
|
|
2084
|
+
}, { immediate: !0 }), (t, r) => (y(), n(Tt, m(E(s), {
|
|
2076
2085
|
modelValue: f.value,
|
|
2077
2086
|
"onUpdate:modelValue": r[0] ||= (e) => f.value = e,
|
|
2078
2087
|
open: p.value,
|
|
@@ -2084,7 +2093,7 @@ var or = {
|
|
|
2084
2093
|
options: I.value,
|
|
2085
2094
|
"value-key": null,
|
|
2086
2095
|
"label-key": "name",
|
|
2087
|
-
"display-value":
|
|
2096
|
+
"display-value": oe,
|
|
2088
2097
|
by: "kvkNumber",
|
|
2089
2098
|
loading: L.value,
|
|
2090
2099
|
verified: ee.value,
|
|
@@ -2093,14 +2102,14 @@ var or = {
|
|
|
2093
2102
|
"error-message": e.errorMessage,
|
|
2094
2103
|
"info-message": te.value,
|
|
2095
2104
|
"ignore-filter": "",
|
|
2096
|
-
onSelect:
|
|
2097
|
-
onBlur:
|
|
2098
|
-
onSearch:
|
|
2105
|
+
onSelect: re,
|
|
2106
|
+
onBlur: ie,
|
|
2107
|
+
onSearch: ae
|
|
2099
2108
|
}), o({
|
|
2100
|
-
item: P(({ option: e }) => [a("div",
|
|
2101
|
-
a("div",
|
|
2102
|
-
a("span",
|
|
2103
|
-
a("span",
|
|
2109
|
+
item: P(({ option: e }) => [a("div", Cr, [
|
|
2110
|
+
a("div", wr, T(e.name), 1),
|
|
2111
|
+
a("span", Tr, "Kvk: " + T(e.kvkNumber), 1),
|
|
2112
|
+
a("span", Er, T(e.city) + ", " + T(e.street), 1)
|
|
2104
2113
|
])]),
|
|
2105
2114
|
_: 2
|
|
2106
2115
|
}, [E(c).popover ? {
|
|
@@ -2126,30 +2135,30 @@ var or = {
|
|
|
2126
2135
|
"info-message"
|
|
2127
2136
|
]));
|
|
2128
2137
|
}
|
|
2129
|
-
}),
|
|
2138
|
+
}), Pr = (e = "Bedrijfsnaam of KVK-nummer is verplicht") => Se().nullable().required(e).test("has-kvk-number", e, (e) => !!e?.kvkNumber), Fr = {
|
|
2130
2139
|
min: 18,
|
|
2131
2140
|
max: 99
|
|
2132
|
-
},
|
|
2141
|
+
}, Ir = "DD-MM-YYYY", Lr = [
|
|
2133
2142
|
H.SingleWithoutChildren,
|
|
2134
2143
|
H.FamilyWithoutChildren,
|
|
2135
2144
|
H.SingleWithChildren,
|
|
2136
2145
|
H.FamilyWithChildren
|
|
2137
|
-
],
|
|
2146
|
+
], Rr = [U.Yes, U.No];
|
|
2138
2147
|
//#endregion
|
|
2139
2148
|
//#region src/utils/date.util.ts
|
|
2140
2149
|
ke.extend(Ae);
|
|
2141
|
-
function
|
|
2150
|
+
function zr() {
|
|
2142
2151
|
return ke().startOf("day");
|
|
2143
2152
|
}
|
|
2144
|
-
function
|
|
2145
|
-
return
|
|
2153
|
+
function Br() {
|
|
2154
|
+
return zr().year();
|
|
2146
2155
|
}
|
|
2147
|
-
function
|
|
2156
|
+
function Vr(e, t) {
|
|
2148
2157
|
let n = ke(e ?? "", t, !0);
|
|
2149
2158
|
return n.isValid() ? n.startOf("day") : null;
|
|
2150
2159
|
}
|
|
2151
|
-
function
|
|
2152
|
-
let n =
|
|
2160
|
+
function Hr(e, t) {
|
|
2161
|
+
let n = zr();
|
|
2153
2162
|
return {
|
|
2154
2163
|
today: n,
|
|
2155
2164
|
earliest: n.subtract(t.value + 1, t.unit).add(1, "day"),
|
|
@@ -2158,28 +2167,28 @@ function Jr(e, t) {
|
|
|
2158
2167
|
}
|
|
2159
2168
|
//#endregion
|
|
2160
2169
|
//#region src/utils/familyComposition.util.ts
|
|
2161
|
-
var
|
|
2162
|
-
function
|
|
2163
|
-
return
|
|
2170
|
+
var Ur = [H.FamilyWithChildren, H.FamilyWithoutChildren];
|
|
2171
|
+
function Wr(e) {
|
|
2172
|
+
return Ur.includes(e);
|
|
2164
2173
|
}
|
|
2165
2174
|
//#endregion
|
|
2166
2175
|
//#region src/utils/url.util.ts
|
|
2167
|
-
var
|
|
2176
|
+
var Gr = (e, t) => {
|
|
2168
2177
|
let [n, r = ""] = e.split("?"), i = new URLSearchParams(r);
|
|
2169
2178
|
return Object.entries(t).forEach(([e, t]) => i.set(e, t)), `${n}?${i.toString()}`;
|
|
2170
|
-
},
|
|
2179
|
+
}, Kr = (e, t) => {
|
|
2171
2180
|
let n = e.indexOf("#");
|
|
2172
|
-
return n === -1 ?
|
|
2181
|
+
return n === -1 ? Gr(e, t) : `${e.slice(0, n + 1)}${Gr(e.slice(n + 1), t)}`;
|
|
2173
2182
|
};
|
|
2174
2183
|
//#endregion
|
|
2175
2184
|
//#region src/schemas/birthdateRange.ts
|
|
2176
|
-
function
|
|
2185
|
+
function qr(e, t, n = "ageRange") {
|
|
2177
2186
|
return {
|
|
2178
2187
|
name: n,
|
|
2179
2188
|
test(n, r) {
|
|
2180
|
-
let i =
|
|
2189
|
+
let i = Vr(n, Ir);
|
|
2181
2190
|
if (!i) return !0;
|
|
2182
|
-
let { today: a, earliest: o, latest: s } =
|
|
2191
|
+
let { today: a, earliest: o, latest: s } = Hr(e.min, e.max), c = {
|
|
2183
2192
|
earliest: o,
|
|
2184
2193
|
latest: s
|
|
2185
2194
|
};
|
|
@@ -2228,11 +2237,11 @@ var Q = {
|
|
|
2228
2237
|
};
|
|
2229
2238
|
//#endregion
|
|
2230
2239
|
//#region src/schemas/birthdate.schema.ts
|
|
2231
|
-
function
|
|
2232
|
-
return
|
|
2240
|
+
function Jr(e) {
|
|
2241
|
+
return Vr(e, Ir) !== null;
|
|
2233
2242
|
}
|
|
2234
|
-
function $(e =
|
|
2235
|
-
return z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat,
|
|
2243
|
+
function $(e = Fr) {
|
|
2244
|
+
return z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat, Jr).test(qr({
|
|
2236
2245
|
min: {
|
|
2237
2246
|
value: e.min,
|
|
2238
2247
|
unit: "year"
|
|
@@ -2248,39 +2257,39 @@ function $(e = Vr) {
|
|
|
2248
2257
|
}
|
|
2249
2258
|
//#endregion
|
|
2250
2259
|
//#region src/schemas/rules.ts
|
|
2251
|
-
function
|
|
2260
|
+
function Yr(e, t) {
|
|
2252
2261
|
return z().required(t).oneOf(e, t);
|
|
2253
2262
|
}
|
|
2254
|
-
function
|
|
2263
|
+
function Xr(e) {
|
|
2255
2264
|
return z().required(e);
|
|
2256
2265
|
}
|
|
2257
|
-
function
|
|
2266
|
+
function Zr(e) {
|
|
2258
2267
|
return Ce().typeError(e).required(e);
|
|
2259
2268
|
}
|
|
2260
2269
|
//#endregion
|
|
2261
2270
|
//#region src/schemas/familyComposition.schema.ts
|
|
2262
|
-
function
|
|
2263
|
-
return
|
|
2271
|
+
function Qr(e = Q.familyComposition.required) {
|
|
2272
|
+
return Yr(Lr, e);
|
|
2264
2273
|
}
|
|
2265
|
-
var
|
|
2274
|
+
var $r = Qr(), ei = Yr(Rr, Q.ownedBuilding.required), ti = [1, 7], ni = [3, 4], ri = {
|
|
2266
2275
|
raceOrMtb: 15e3,
|
|
2267
2276
|
default: 9999
|
|
2268
|
-
},
|
|
2277
|
+
}, ii = (e, t) => e.test("max-value", Q.bike.priceMax(t), (e) => {
|
|
2269
2278
|
let n = Number(e);
|
|
2270
2279
|
return Number.isNaN(n) || n <= t;
|
|
2271
|
-
}),
|
|
2272
|
-
kind:
|
|
2273
|
-
condition:
|
|
2280
|
+
}), ai = R({
|
|
2281
|
+
kind: Zr(Q.bike.kindRequired),
|
|
2282
|
+
condition: Zr(Q.bike.conditionRequired),
|
|
2274
2283
|
price: z().required(Q.bike.priceRequired).when("kind", {
|
|
2275
|
-
is: (e) =>
|
|
2276
|
-
then: (e) =>
|
|
2277
|
-
otherwise: (e) =>
|
|
2284
|
+
is: (e) => ni.includes(Number(e)),
|
|
2285
|
+
then: (e) => ii(e, ri.raceOrMtb),
|
|
2286
|
+
otherwise: (e) => ii(e, ri.default)
|
|
2278
2287
|
}),
|
|
2279
2288
|
brand: z().when("kind", {
|
|
2280
|
-
is: (e) =>
|
|
2289
|
+
is: (e) => ti.includes(Number(e)),
|
|
2281
2290
|
then: (e) => e.required(Q.bike.brandRequired)
|
|
2282
2291
|
})
|
|
2283
|
-
}),
|
|
2292
|
+
}), oi = [
|
|
2284
2293
|
{
|
|
2285
2294
|
value: 4,
|
|
2286
2295
|
title: "ATB / Mountainbike",
|
|
@@ -2347,13 +2356,13 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
2347
2356
|
name: "Vouwfiets",
|
|
2348
2357
|
isEBike: !1
|
|
2349
2358
|
}
|
|
2350
|
-
],
|
|
2359
|
+
], si = [{
|
|
2351
2360
|
value: 1,
|
|
2352
2361
|
label: "Nieuw"
|
|
2353
2362
|
}, {
|
|
2354
2363
|
value: 0,
|
|
2355
2364
|
label: "Tweedehands"
|
|
2356
|
-
}],
|
|
2365
|
+
}], ci = [
|
|
2357
2366
|
{
|
|
2358
2367
|
id: "Ander merk",
|
|
2359
2368
|
name: "Ander merk"
|
|
@@ -3774,7 +3783,7 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3774
3783
|
id: "Zündapp",
|
|
3775
3784
|
name: "Zündapp"
|
|
3776
3785
|
}
|
|
3777
|
-
],
|
|
3786
|
+
], li = /* @__PURE__ */ l({
|
|
3778
3787
|
__name: "BikeForm",
|
|
3779
3788
|
props: /*@__PURE__*/ f({
|
|
3780
3789
|
initialData: {},
|
|
@@ -3793,14 +3802,14 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3793
3802
|
}),
|
|
3794
3803
|
emits: ["submitted"],
|
|
3795
3804
|
setup(e, { emit: i }) {
|
|
3796
|
-
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, resetField: p } = Z(
|
|
3805
|
+
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, resetField: p } = Z(ai, {
|
|
3797
3806
|
kind: a.initialData?.kind ?? null,
|
|
3798
3807
|
condition: a.initialData?.condition ?? 1,
|
|
3799
3808
|
price: a.initialData?.price ?? "",
|
|
3800
3809
|
brand: a.initialData?.brand ?? ""
|
|
3801
|
-
}), [h, g, _] = f("kind", { validateAt: "change" }), [v, b, x] = f("brand", { validateAt: "change" }), [S, C, w] = f("condition"), [T, D, O] = f("price"), k = t(() =>
|
|
3810
|
+
}), [h, g, _] = f("kind", { validateAt: "change" }), [v, b, x] = f("brand", { validateAt: "change" }), [S, C, w] = f("condition"), [T, D, O] = f("price"), k = t(() => ti.includes(Number(h.value)));
|
|
3802
3811
|
N(h, (e) => {
|
|
3803
|
-
|
|
3812
|
+
ti.includes(Number(e)) || p("brand", { value: "" });
|
|
3804
3813
|
}, { immediate: !0 });
|
|
3805
3814
|
function A() {
|
|
3806
3815
|
u((e) => {
|
|
@@ -3821,7 +3830,7 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3821
3830
|
"onUpdate:modelValue": i[0] ||= (e) => d(h) ? h.value = e : null,
|
|
3822
3831
|
modelModifiers: { number: !0 },
|
|
3823
3832
|
label: "Soort fiets",
|
|
3824
|
-
options: E(
|
|
3833
|
+
options: E(oi),
|
|
3825
3834
|
name: "kind",
|
|
3826
3835
|
required: !1,
|
|
3827
3836
|
"error-message": E(_)
|
|
@@ -3837,12 +3846,12 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3837
3846
|
span: "2",
|
|
3838
3847
|
md: "6"
|
|
3839
3848
|
}, {
|
|
3840
|
-
default: P(() => [c(E(
|
|
3849
|
+
default: P(() => [c(E(Tt), m({
|
|
3841
3850
|
modelValue: E(v),
|
|
3842
3851
|
"onUpdate:modelValue": i[1] ||= (e) => d(v) ? v.value = e : null,
|
|
3843
3852
|
label: "Merk fiets",
|
|
3844
3853
|
placeholder: "Typ of kies je merk",
|
|
3845
|
-
options: E(
|
|
3854
|
+
options: E(ci),
|
|
3846
3855
|
"label-key": "name",
|
|
3847
3856
|
"value-key": "id",
|
|
3848
3857
|
name: "brand",
|
|
@@ -3859,12 +3868,12 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3859
3868
|
span: "4",
|
|
3860
3869
|
md: "6"
|
|
3861
3870
|
}, {
|
|
3862
|
-
default: P(() => [c(E(
|
|
3871
|
+
default: P(() => [c(E(Lt), m({
|
|
3863
3872
|
modelValue: E(S),
|
|
3864
3873
|
"onUpdate:modelValue": i[2] ||= (e) => d(S) ? S.value = e : null,
|
|
3865
3874
|
legend: "Gekocht als",
|
|
3866
3875
|
name: "condition",
|
|
3867
|
-
options: E(
|
|
3876
|
+
options: E(si),
|
|
3868
3877
|
variant: "boxed",
|
|
3869
3878
|
required: !1,
|
|
3870
3879
|
"error-message": E(w)
|
|
@@ -3879,7 +3888,7 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3879
3888
|
span: "2",
|
|
3880
3889
|
md: "6"
|
|
3881
3890
|
}, {
|
|
3882
|
-
default: P(() => [c(E(
|
|
3891
|
+
default: P(() => [c(E(We), m({
|
|
3883
3892
|
modelValue: E(T),
|
|
3884
3893
|
"onUpdate:modelValue": i[3] ||= (e) => d(T) ? T.value = e : null,
|
|
3885
3894
|
label: "Aankoopprijs",
|
|
@@ -3899,7 +3908,7 @@ var ai = ii(), oi = ti(Wr, Q.ownedBuilding.required), si = [1, 7], ci = [3, 4],
|
|
|
3899
3908
|
});
|
|
3900
3909
|
//#endregion
|
|
3901
3910
|
//#region src/comparisons/bike/bike.presenter.ts
|
|
3902
|
-
function
|
|
3911
|
+
function ui(e) {
|
|
3903
3912
|
return {
|
|
3904
3913
|
comparison: V.Bike,
|
|
3905
3914
|
detail: { bike: {
|
|
@@ -3913,27 +3922,27 @@ function gi(e) {
|
|
|
3913
3922
|
}
|
|
3914
3923
|
//#endregion
|
|
3915
3924
|
//#region src/comparisons/pet/constants.ts
|
|
3916
|
-
var
|
|
3925
|
+
var di = {
|
|
3917
3926
|
min: 0,
|
|
3918
3927
|
max: 99
|
|
3919
|
-
},
|
|
3928
|
+
}, fi = R({
|
|
3920
3929
|
kind: z().required(Q.pet.kindRequired),
|
|
3921
|
-
age: z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat,
|
|
3930
|
+
age: z().required(Q.birthdate.required).test("date_format", Q.birthdate.dateFormat, Jr).test(qr({
|
|
3922
3931
|
min: {
|
|
3923
3932
|
value: 7,
|
|
3924
3933
|
unit: "week"
|
|
3925
3934
|
},
|
|
3926
3935
|
max: {
|
|
3927
|
-
value:
|
|
3936
|
+
value: di.max,
|
|
3928
3937
|
unit: "year"
|
|
3929
3938
|
}
|
|
3930
3939
|
}, {
|
|
3931
|
-
future: () => Q.birthdate.tooYoung(
|
|
3932
|
-
tooYoung: ({ earliest: e, latest: t }) => Q.pet.outOfRange(e.format(
|
|
3933
|
-
tooOld: () => Q.birthdate.tooOld(
|
|
3940
|
+
future: () => Q.birthdate.tooYoung(di.min),
|
|
3941
|
+
tooYoung: ({ earliest: e, latest: t }) => Q.pet.outOfRange(e.format(Ir), t.format(Ir)),
|
|
3942
|
+
tooOld: () => Q.birthdate.tooOld(di.max)
|
|
3934
3943
|
}, "birthdate_range")),
|
|
3935
3944
|
zipCode: z().required(Q.pet.zipCodeRequired).matches(/^\d{4}\s?[a-zA-Z]{2}$/, Q.pet.zipCodeInvalid)
|
|
3936
|
-
}),
|
|
3945
|
+
}), pi = [
|
|
3937
3946
|
{
|
|
3938
3947
|
title: "Hond",
|
|
3939
3948
|
value: "dog"
|
|
@@ -3950,7 +3959,7 @@ var _i = {
|
|
|
3950
3959
|
title: "Vogel",
|
|
3951
3960
|
value: "bird"
|
|
3952
3961
|
}
|
|
3953
|
-
],
|
|
3962
|
+
], mi = /* @__PURE__ */ l({
|
|
3954
3963
|
__name: "PetForm",
|
|
3955
3964
|
props: /*@__PURE__*/ f({
|
|
3956
3965
|
initialData: {},
|
|
@@ -3969,7 +3978,7 @@ var _i = {
|
|
|
3969
3978
|
}),
|
|
3970
3979
|
emits: ["submitted"],
|
|
3971
3980
|
setup(e, { emit: t }) {
|
|
3972
|
-
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(
|
|
3981
|
+
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(fi, {
|
|
3973
3982
|
kind: r.initialData?.kind ?? "dog",
|
|
3974
3983
|
age: r.initialData?.age ?? "",
|
|
3975
3984
|
zipCode: r.initialData?.zipCode ?? ""
|
|
@@ -3993,7 +4002,7 @@ var _i = {
|
|
|
3993
4002
|
"onUpdate:modelValue": r[0] ||= (e) => d(u) ? u.value = e : null,
|
|
3994
4003
|
label: "Wat voor huisdier wil je verzekeren?",
|
|
3995
4004
|
placeholder: "",
|
|
3996
|
-
options: E(
|
|
4005
|
+
options: E(pi),
|
|
3997
4006
|
name: "kind",
|
|
3998
4007
|
required: !1,
|
|
3999
4008
|
"error-message": E(p)
|
|
@@ -4031,7 +4040,7 @@ var _i = {
|
|
|
4031
4040
|
span: "2",
|
|
4032
4041
|
md: "6"
|
|
4033
4042
|
}, {
|
|
4034
|
-
default: P(() => [c(E(
|
|
4043
|
+
default: P(() => [c(E(We), m({
|
|
4035
4044
|
modelValue: E(v),
|
|
4036
4045
|
"onUpdate:modelValue": r[2] ||= (e) => d(v) ? v.value = e : null,
|
|
4037
4046
|
label: "Postcode",
|
|
@@ -4062,7 +4071,7 @@ var _i = {
|
|
|
4062
4071
|
});
|
|
4063
4072
|
//#endregion
|
|
4064
4073
|
//#region src/comparisons/pet/pet.presenter.ts
|
|
4065
|
-
function
|
|
4074
|
+
function hi(e) {
|
|
4066
4075
|
return {
|
|
4067
4076
|
comparison: V.Pet,
|
|
4068
4077
|
detail: { pet: {
|
|
@@ -4074,11 +4083,11 @@ function xi(e) {
|
|
|
4074
4083
|
}
|
|
4075
4084
|
//#endregion
|
|
4076
4085
|
//#region src/comparisons/caravan/caravan.schema.ts
|
|
4077
|
-
var
|
|
4078
|
-
TypeOfCaravan:
|
|
4079
|
-
NewOrOccasion:
|
|
4080
|
-
BuildYear:
|
|
4081
|
-
}),
|
|
4086
|
+
var gi = R({
|
|
4087
|
+
TypeOfCaravan: Xr(Q.caravan.typeOfCaravanRequired),
|
|
4088
|
+
NewOrOccasion: Yr(Rr, Q.caravan.newOrOccasionRequired),
|
|
4089
|
+
BuildYear: Xr(Q.caravan.buildYearRequired)
|
|
4090
|
+
}), _i = [
|
|
4082
4091
|
{
|
|
4083
4092
|
value: "CS",
|
|
4084
4093
|
title: "Stacaravan"
|
|
@@ -4091,7 +4100,7 @@ var Si = R({
|
|
|
4091
4100
|
value: "CV",
|
|
4092
4101
|
title: "Vouwwagen"
|
|
4093
4102
|
}
|
|
4094
|
-
],
|
|
4103
|
+
], vi = [{
|
|
4095
4104
|
value: U.Yes,
|
|
4096
4105
|
label: "Nieuw"
|
|
4097
4106
|
}, {
|
|
@@ -4100,8 +4109,8 @@ var Si = R({
|
|
|
4100
4109
|
}];
|
|
4101
4110
|
//#endregion
|
|
4102
4111
|
//#region src/comparisons/caravan/models/buildYears.model.ts
|
|
4103
|
-
function
|
|
4104
|
-
let e =
|
|
4112
|
+
function yi() {
|
|
4113
|
+
let e = Br();
|
|
4105
4114
|
return Array.from({ length: 126 }, (t, n) => ({
|
|
4106
4115
|
title: String(e - n),
|
|
4107
4116
|
value: String(e - n)
|
|
@@ -4109,7 +4118,7 @@ function Ti() {
|
|
|
4109
4118
|
}
|
|
4110
4119
|
//#endregion
|
|
4111
4120
|
//#region src/comparisons/caravan/CaravanForm.vue
|
|
4112
|
-
var
|
|
4121
|
+
var bi = /* @__PURE__ */ l({
|
|
4113
4122
|
__name: "CaravanForm",
|
|
4114
4123
|
props: /*@__PURE__*/ f({
|
|
4115
4124
|
initialData: {},
|
|
@@ -4128,7 +4137,7 @@ var Ei = /* @__PURE__ */ l({
|
|
|
4128
4137
|
}),
|
|
4129
4138
|
emits: ["submitted"],
|
|
4130
4139
|
setup(e, { emit: t }) {
|
|
4131
|
-
let r = e, i = q(r), a = t, o =
|
|
4140
|
+
let r = e, i = q(r), a = t, o = yi(), { isSubmitting: s, handleSubmit: l, defineField: u } = Z(gi, {
|
|
4132
4141
|
TypeOfCaravan: r.initialData?.TypeOfCaravan ?? null,
|
|
4133
4142
|
NewOrOccasion: r.initialData?.NewOrOccasion ?? U.Yes,
|
|
4134
4143
|
BuildYear: r.initialData?.BuildYear ?? null
|
|
@@ -4151,7 +4160,7 @@ var Ei = /* @__PURE__ */ l({
|
|
|
4151
4160
|
modelValue: E(f),
|
|
4152
4161
|
"onUpdate:modelValue": r[0] ||= (e) => d(f) ? f.value = e : null,
|
|
4153
4162
|
label: "Soort caravan",
|
|
4154
|
-
options: E(
|
|
4163
|
+
options: E(_i),
|
|
4155
4164
|
name: "typeOfCaravan",
|
|
4156
4165
|
required: !1,
|
|
4157
4166
|
"error-message": E(h)
|
|
@@ -4166,12 +4175,12 @@ var Ei = /* @__PURE__ */ l({
|
|
|
4166
4175
|
span: "4",
|
|
4167
4176
|
md: "6"
|
|
4168
4177
|
}, {
|
|
4169
|
-
default: P(() => [c(E(
|
|
4178
|
+
default: P(() => [c(E(Lt), m({
|
|
4170
4179
|
modelValue: E(g),
|
|
4171
4180
|
"onUpdate:modelValue": r[1] ||= (e) => d(g) ? g.value = e : null,
|
|
4172
4181
|
legend: "Gekocht als",
|
|
4173
4182
|
name: "newOrOccasion",
|
|
4174
|
-
options: E(
|
|
4183
|
+
options: E(vi),
|
|
4175
4184
|
variant: "boxed",
|
|
4176
4185
|
required: !1,
|
|
4177
4186
|
"error-message": E(v)
|
|
@@ -4208,7 +4217,7 @@ var Ei = /* @__PURE__ */ l({
|
|
|
4208
4217
|
});
|
|
4209
4218
|
//#endregion
|
|
4210
4219
|
//#region src/comparisons/caravan/caravan.presenter.ts
|
|
4211
|
-
function
|
|
4220
|
+
function xi(e) {
|
|
4212
4221
|
return {
|
|
4213
4222
|
comparison: V.Caravan,
|
|
4214
4223
|
detail: { caravan: {
|
|
@@ -4221,18 +4230,18 @@ function Di(e) {
|
|
|
4221
4230
|
}
|
|
4222
4231
|
//#endregion
|
|
4223
4232
|
//#region src/comparisons/travel/paymentTerm.enum.ts
|
|
4224
|
-
var
|
|
4233
|
+
var Si = /* @__PURE__ */ function(e) {
|
|
4225
4234
|
return e.Continuous = "L", e.ShortTerm = "S", e;
|
|
4226
|
-
}({}),
|
|
4227
|
-
PaymentTerm:
|
|
4235
|
+
}({}), Ci = R({
|
|
4236
|
+
PaymentTerm: Yr([Si.Continuous, Si.ShortTerm], Q.travel.paymentTermRequired),
|
|
4228
4237
|
birthdate: $()
|
|
4229
|
-
}),
|
|
4230
|
-
value:
|
|
4238
|
+
}), wi = [{
|
|
4239
|
+
value: Si.Continuous,
|
|
4231
4240
|
label: "Doorlopend"
|
|
4232
4241
|
}, {
|
|
4233
|
-
value:
|
|
4242
|
+
value: Si.ShortTerm,
|
|
4234
4243
|
label: "Kortlopend"
|
|
4235
|
-
}],
|
|
4244
|
+
}], Ti = /* @__PURE__ */ l({
|
|
4236
4245
|
__name: "TravelForm",
|
|
4237
4246
|
props: /*@__PURE__*/ f({
|
|
4238
4247
|
initialData: {},
|
|
@@ -4251,8 +4260,8 @@ var Oi = /* @__PURE__ */ function(e) {
|
|
|
4251
4260
|
}),
|
|
4252
4261
|
emits: ["submitted"],
|
|
4253
4262
|
setup(e, { emit: t }) {
|
|
4254
|
-
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(
|
|
4255
|
-
PaymentTerm: r.initialData?.PaymentTerm ??
|
|
4263
|
+
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(Ci, {
|
|
4264
|
+
PaymentTerm: r.initialData?.PaymentTerm ?? Si.Continuous,
|
|
4256
4265
|
birthdate: r.initialData?.birthdate ?? ""
|
|
4257
4266
|
}), [u, f, p] = l("PaymentTerm", { validateAt: "change" }), [h, g, _] = l("birthdate");
|
|
4258
4267
|
function v() {
|
|
@@ -4268,12 +4277,12 @@ var Oi = /* @__PURE__ */ function(e) {
|
|
|
4268
4277
|
span: "5",
|
|
4269
4278
|
md: "6"
|
|
4270
4279
|
}, {
|
|
4271
|
-
default: P(() => [c(E(
|
|
4280
|
+
default: P(() => [c(E(Lt), m({
|
|
4272
4281
|
modelValue: E(u),
|
|
4273
4282
|
"onUpdate:modelValue": r[0] ||= (e) => d(u) ? u.value = e : null,
|
|
4274
4283
|
legend: "Kies je dekking",
|
|
4275
4284
|
name: "PaymentTerm",
|
|
4276
|
-
options: E(
|
|
4285
|
+
options: E(wi),
|
|
4277
4286
|
variant: "boxed",
|
|
4278
4287
|
required: !1,
|
|
4279
4288
|
"error-message": E(p)
|
|
@@ -4311,7 +4320,7 @@ var Oi = /* @__PURE__ */ function(e) {
|
|
|
4311
4320
|
});
|
|
4312
4321
|
//#endregion
|
|
4313
4322
|
//#region src/comparisons/travel/travel.presenter.ts
|
|
4314
|
-
function
|
|
4323
|
+
function Ei(e) {
|
|
4315
4324
|
return {
|
|
4316
4325
|
comparison: V.Travel,
|
|
4317
4326
|
detail: { comparison: { PaymentTerm: e.PaymentTerm } },
|
|
@@ -4320,11 +4329,11 @@ function Mi(e) {
|
|
|
4320
4329
|
}
|
|
4321
4330
|
//#endregion
|
|
4322
4331
|
//#region src/comparisons/liability/liability.schema.ts
|
|
4323
|
-
var
|
|
4332
|
+
var Di = (e) => R({
|
|
4324
4333
|
address: e,
|
|
4325
4334
|
birthdate: $(),
|
|
4326
|
-
familyComposition:
|
|
4327
|
-
}),
|
|
4335
|
+
familyComposition: $r
|
|
4336
|
+
}), Oi = /* @__PURE__ */ l({
|
|
4328
4337
|
__name: "LiabilityForm",
|
|
4329
4338
|
props: /*@__PURE__*/ f({
|
|
4330
4339
|
initialData: {},
|
|
@@ -4343,7 +4352,7 @@ var Ni = (e) => R({
|
|
|
4343
4352
|
}),
|
|
4344
4353
|
emits: ["submitted"],
|
|
4345
4354
|
setup(e, { emit: t }) {
|
|
4346
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
4355
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Hn({ initial: r.initialData?.address }), { isSubmitting: f, handleSubmit: p, defineField: h } = Z(Di(o), {
|
|
4347
4356
|
birthdate: r.initialData?.birthdate ?? "",
|
|
4348
4357
|
familyComposition: r.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4349
4358
|
address: s
|
|
@@ -4366,7 +4375,7 @@ var Ni = (e) => R({
|
|
|
4366
4375
|
span: "5",
|
|
4367
4376
|
md: "6"
|
|
4368
4377
|
}, {
|
|
4369
|
-
default: P(() => [c(E(
|
|
4378
|
+
default: P(() => [c(E(bn), {
|
|
4370
4379
|
"resolved-address": E(l),
|
|
4371
4380
|
"onUpdate:resolvedAddress": r[0] ||= (e) => d(l) ? l.value = e : null,
|
|
4372
4381
|
"addition-options": E(u)
|
|
@@ -4388,7 +4397,7 @@ var Ni = (e) => R({
|
|
|
4388
4397
|
span: "3",
|
|
4389
4398
|
md: "6"
|
|
4390
4399
|
}, {
|
|
4391
|
-
default: P(() => [c(E(
|
|
4400
|
+
default: P(() => [c(E(cn), m({
|
|
4392
4401
|
modelValue: E(b),
|
|
4393
4402
|
"onUpdate:modelValue": r[2] ||= (e) => d(b) ? b.value = e : null,
|
|
4394
4403
|
"error-message": E(S)
|
|
@@ -4402,7 +4411,7 @@ var Ni = (e) => R({
|
|
|
4402
4411
|
});
|
|
4403
4412
|
//#endregion
|
|
4404
4413
|
//#region src/comparisons/liability/liability.presenter.ts
|
|
4405
|
-
function
|
|
4414
|
+
function ki(e) {
|
|
4406
4415
|
return {
|
|
4407
4416
|
comparison: V.Liability,
|
|
4408
4417
|
detail: { liability: {
|
|
@@ -4422,17 +4431,17 @@ function Fi(e) {
|
|
|
4422
4431
|
}
|
|
4423
4432
|
//#endregion
|
|
4424
4433
|
//#region src/models/houseOwnedBuilding.model.ts
|
|
4425
|
-
var
|
|
4434
|
+
var Ai = [{
|
|
4426
4435
|
value: U.Yes,
|
|
4427
4436
|
label: "Gekocht"
|
|
4428
4437
|
}, {
|
|
4429
4438
|
value: U.No,
|
|
4430
4439
|
label: "Verhuurd"
|
|
4431
|
-
}],
|
|
4440
|
+
}], ji = (e) => R({
|
|
4432
4441
|
address: e,
|
|
4433
|
-
ownedBuilding:
|
|
4434
|
-
familyComposition:
|
|
4435
|
-
}),
|
|
4442
|
+
ownedBuilding: ei,
|
|
4443
|
+
familyComposition: Qr(Q.house.familyCompositionRequired)
|
|
4444
|
+
}), Mi = /* @__PURE__ */ l({
|
|
4436
4445
|
__name: "HouseForm",
|
|
4437
4446
|
props: /*@__PURE__*/ f({
|
|
4438
4447
|
initialData: {},
|
|
@@ -4451,7 +4460,7 @@ var Ii = [{
|
|
|
4451
4460
|
}),
|
|
4452
4461
|
emits: ["submitted"],
|
|
4453
4462
|
setup(e, { emit: t }) {
|
|
4454
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
4463
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Hn({ initial: r.initialData?.address }), { isSubmitting: f, handleSubmit: p, defineField: h } = Z(ji(o), {
|
|
4455
4464
|
ownedBuilding: r.initialData?.ownedBuilding ?? U.Yes,
|
|
4456
4465
|
familyComposition: r.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4457
4466
|
address: s
|
|
@@ -4474,7 +4483,7 @@ var Ii = [{
|
|
|
4474
4483
|
span: "4",
|
|
4475
4484
|
md: "6"
|
|
4476
4485
|
}, {
|
|
4477
|
-
default: P(() => [c(E(
|
|
4486
|
+
default: P(() => [c(E(bn), {
|
|
4478
4487
|
"resolved-address": E(l),
|
|
4479
4488
|
"onUpdate:resolvedAddress": r[0] ||= (e) => d(l) ? l.value = e : null,
|
|
4480
4489
|
"addition-options": E(u)
|
|
@@ -4485,12 +4494,12 @@ var Ii = [{
|
|
|
4485
4494
|
span: "3",
|
|
4486
4495
|
md: "3"
|
|
4487
4496
|
}, {
|
|
4488
|
-
default: P(() => [c(E(
|
|
4497
|
+
default: P(() => [c(E(Lt), m({
|
|
4489
4498
|
modelValue: E(g),
|
|
4490
4499
|
"onUpdate:modelValue": r[1] ||= (e) => d(g) ? g.value = e : null,
|
|
4491
4500
|
legend: "Jouw woning is...",
|
|
4492
4501
|
name: "ownedBuilding",
|
|
4493
|
-
options: E(
|
|
4502
|
+
options: E(Ai),
|
|
4494
4503
|
variant: "boxed",
|
|
4495
4504
|
required: !1,
|
|
4496
4505
|
"error-message": E(v)
|
|
@@ -4505,7 +4514,7 @@ var Ii = [{
|
|
|
4505
4514
|
span: "3",
|
|
4506
4515
|
md: "3"
|
|
4507
4516
|
}, {
|
|
4508
|
-
default: P(() => [c(E(
|
|
4517
|
+
default: P(() => [c(E(cn), m({
|
|
4509
4518
|
modelValue: E(b),
|
|
4510
4519
|
"onUpdate:modelValue": r[2] ||= (e) => d(b) ? b.value = e : null,
|
|
4511
4520
|
"error-message": E(S)
|
|
@@ -4519,7 +4528,7 @@ var Ii = [{
|
|
|
4519
4528
|
});
|
|
4520
4529
|
//#endregion
|
|
4521
4530
|
//#region src/comparisons/house/house.presenter.ts
|
|
4522
|
-
function
|
|
4531
|
+
function Ni(e) {
|
|
4523
4532
|
return {
|
|
4524
4533
|
comparison: V.Housing,
|
|
4525
4534
|
detail: { house: { ownedBuilding: e.ownedBuilding } },
|
|
@@ -4535,22 +4544,22 @@ function zi(e) {
|
|
|
4535
4544
|
}
|
|
4536
4545
|
//#endregion
|
|
4537
4546
|
//#region src/comparisons/legal/constants.ts
|
|
4538
|
-
var
|
|
4547
|
+
var Pi = H.SingleWithChildren, Fi = (e) => R({
|
|
4539
4548
|
address: e,
|
|
4540
|
-
ownedBuilding:
|
|
4549
|
+
ownedBuilding: ei,
|
|
4541
4550
|
birthdate: $(),
|
|
4542
|
-
familyComposition:
|
|
4551
|
+
familyComposition: $r,
|
|
4543
4552
|
familySize: z().defined().when("familyComposition", {
|
|
4544
|
-
is:
|
|
4553
|
+
is: Pi,
|
|
4545
4554
|
then: (e) => e.required(Q.legal.familySizeRequired)
|
|
4546
4555
|
})
|
|
4547
|
-
}),
|
|
4556
|
+
}), Ii = [{
|
|
4548
4557
|
title: "Alleenstaande met 1 kind",
|
|
4549
4558
|
value: "2"
|
|
4550
4559
|
}, {
|
|
4551
4560
|
title: "Alleenstaande met 2 of meer kinderen",
|
|
4552
4561
|
value: "3"
|
|
4553
|
-
}],
|
|
4562
|
+
}], Li = /* @__PURE__ */ l({
|
|
4554
4563
|
__name: "LegalForm",
|
|
4555
4564
|
props: /*@__PURE__*/ f({
|
|
4556
4565
|
initialData: {},
|
|
@@ -4569,15 +4578,15 @@ var Bi = H.SingleWithChildren, Vi = (e) => R({
|
|
|
4569
4578
|
}),
|
|
4570
4579
|
emits: ["submitted"],
|
|
4571
4580
|
setup(e, { emit: i }) {
|
|
4572
|
-
let a = e, o = q(a), s = i, { addressSchema: l, draft: u, resolvedAddress: f, additionOptions: p } =
|
|
4581
|
+
let a = e, o = q(a), s = i, { addressSchema: l, draft: u, resolvedAddress: f, additionOptions: p } = Hn({ initial: a.initialData?.address }), { isSubmitting: h, handleSubmit: g, defineField: _, resetField: v } = Z(Fi(l), {
|
|
4573
4582
|
ownedBuilding: a.initialData?.ownedBuilding ?? U.Yes,
|
|
4574
4583
|
birthdate: a.initialData?.birthdate ?? "",
|
|
4575
4584
|
familyComposition: a.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4576
4585
|
familySize: a.initialData?.familySize ?? "",
|
|
4577
4586
|
address: u
|
|
4578
|
-
}), [b, x, S] = _("ownedBuilding"), [C, w, T] = _("birthdate"), [D, O, k] = _("familyComposition", { validateAt: "change" }), [A, j, M] = _("familySize", { validateAt: "change" }), F = t(() => D.value ===
|
|
4587
|
+
}), [b, x, S] = _("ownedBuilding"), [C, w, T] = _("birthdate"), [D, O, k] = _("familyComposition", { validateAt: "change" }), [A, j, M] = _("familySize", { validateAt: "change" }), F = t(() => D.value === Pi);
|
|
4579
4588
|
N(D, (e) => {
|
|
4580
|
-
e !==
|
|
4589
|
+
e !== Pi && v("familySize", { value: "" });
|
|
4581
4590
|
}, { immediate: !0 });
|
|
4582
4591
|
function I() {
|
|
4583
4592
|
g(({ ownedBuilding: e, birthdate: t, familyComposition: n, familySize: r }) => {
|
|
@@ -4599,7 +4608,7 @@ var Bi = H.SingleWithChildren, Vi = (e) => R({
|
|
|
4599
4608
|
span: "3",
|
|
4600
4609
|
md: "6"
|
|
4601
4610
|
}, {
|
|
4602
|
-
default: P(() => [c(E(
|
|
4611
|
+
default: P(() => [c(E(bn), {
|
|
4603
4612
|
"resolved-address": E(f),
|
|
4604
4613
|
"onUpdate:resolvedAddress": i[0] ||= (e) => d(f) ? f.value = e : null,
|
|
4605
4614
|
"addition-options": E(p)
|
|
@@ -4610,12 +4619,12 @@ var Bi = H.SingleWithChildren, Vi = (e) => R({
|
|
|
4610
4619
|
span: "3",
|
|
4611
4620
|
md: "6"
|
|
4612
4621
|
}, {
|
|
4613
|
-
default: P(() => [c(E(
|
|
4622
|
+
default: P(() => [c(E(Lt), m({
|
|
4614
4623
|
modelValue: E(b),
|
|
4615
4624
|
"onUpdate:modelValue": i[1] ||= (e) => d(b) ? b.value = e : null,
|
|
4616
4625
|
legend: "Jouw woning is...",
|
|
4617
4626
|
name: "ownedBuilding",
|
|
4618
|
-
options: E(
|
|
4627
|
+
options: E(Ai),
|
|
4619
4628
|
variant: "boxed",
|
|
4620
4629
|
required: !1,
|
|
4621
4630
|
"error-message": E(S)
|
|
@@ -4641,7 +4650,7 @@ var Bi = H.SingleWithChildren, Vi = (e) => R({
|
|
|
4641
4650
|
span: "2",
|
|
4642
4651
|
md: "6"
|
|
4643
4652
|
}, {
|
|
4644
|
-
default: P(() => [c(E(
|
|
4653
|
+
default: P(() => [c(E(cn), m({
|
|
4645
4654
|
modelValue: E(D),
|
|
4646
4655
|
"onUpdate:modelValue": i[3] ||= (e) => d(D) ? D.value = e : null,
|
|
4647
4656
|
"error-message": E(k)
|
|
@@ -4658,7 +4667,7 @@ var Bi = H.SingleWithChildren, Vi = (e) => R({
|
|
|
4658
4667
|
"onUpdate:modelValue": i[4] ||= (e) => d(A) ? A.value = e : null,
|
|
4659
4668
|
label: "Aantal kinderen",
|
|
4660
4669
|
placeholder: "Maak een keuze",
|
|
4661
|
-
options: E(
|
|
4670
|
+
options: E(Ii),
|
|
4662
4671
|
name: "familySize",
|
|
4663
4672
|
required: !1,
|
|
4664
4673
|
"error-message": E(M)
|
|
@@ -4676,11 +4685,11 @@ var Bi = H.SingleWithChildren, Vi = (e) => R({
|
|
|
4676
4685
|
});
|
|
4677
4686
|
//#endregion
|
|
4678
4687
|
//#region src/comparisons/legal/legal.presenter.ts
|
|
4679
|
-
function
|
|
4688
|
+
function Ri(e) {
|
|
4680
4689
|
return {
|
|
4681
4690
|
comparison: V.LegalAssistance,
|
|
4682
4691
|
detail: { comparison: {
|
|
4683
|
-
familySize: e.familyComposition ===
|
|
4692
|
+
familySize: e.familyComposition === Pi ? e.familySize : "",
|
|
4684
4693
|
deductables: 300,
|
|
4685
4694
|
ownedBuilding: e.ownedBuilding
|
|
4686
4695
|
} },
|
|
@@ -4697,15 +4706,15 @@ function Wi(e) {
|
|
|
4697
4706
|
}
|
|
4698
4707
|
//#endregion
|
|
4699
4708
|
//#region src/comparisons/package/package.schema.ts
|
|
4700
|
-
var
|
|
4709
|
+
var zi = (e) => R({
|
|
4701
4710
|
address: e,
|
|
4702
4711
|
birthdate: $(),
|
|
4703
|
-
familyComposition:
|
|
4712
|
+
familyComposition: $r,
|
|
4704
4713
|
partnerBirthdate: z().defined().when("familyComposition", {
|
|
4705
|
-
is:
|
|
4714
|
+
is: Wr,
|
|
4706
4715
|
then: () => $()
|
|
4707
4716
|
})
|
|
4708
|
-
}),
|
|
4717
|
+
}), Bi = /* @__PURE__ */ l({
|
|
4709
4718
|
__name: "PackageForm",
|
|
4710
4719
|
props: /*@__PURE__*/ f({
|
|
4711
4720
|
initialData: {},
|
|
@@ -4724,14 +4733,14 @@ var Gi = (e) => R({
|
|
|
4724
4733
|
}),
|
|
4725
4734
|
emits: ["submitted"],
|
|
4726
4735
|
setup(e, { emit: i }) {
|
|
4727
|
-
let a = e, o = q(a), s = i, { addressSchema: l, draft: u, resolvedAddress: f, additionOptions: p } =
|
|
4736
|
+
let a = e, o = q(a), s = i, { addressSchema: l, draft: u, resolvedAddress: f, additionOptions: p } = Hn({ initial: a.initialData?.address }), { isSubmitting: h, handleSubmit: g, defineField: _, resetField: v } = Z(zi(l), {
|
|
4728
4737
|
birthdate: a.initialData?.birthdate ?? "",
|
|
4729
4738
|
familyComposition: a.initialData?.familyComposition ?? H.SingleWithoutChildren,
|
|
4730
4739
|
partnerBirthdate: a.initialData?.partnerBirthdate ?? "",
|
|
4731
4740
|
address: u
|
|
4732
|
-
}), [b, x, S] = _("birthdate"), [C, w, T] = _("familyComposition", { validateAt: "change" }), [D, O, k] = _("partnerBirthdate"), A = t(() =>
|
|
4741
|
+
}), [b, x, S] = _("birthdate"), [C, w, T] = _("familyComposition", { validateAt: "change" }), [D, O, k] = _("partnerBirthdate"), A = t(() => Wr(C.value));
|
|
4733
4742
|
N(C, (e) => {
|
|
4734
|
-
|
|
4743
|
+
Wr(e) || v("partnerBirthdate", { value: "" });
|
|
4735
4744
|
}, { immediate: !0 });
|
|
4736
4745
|
function j() {
|
|
4737
4746
|
g(({ birthdate: e, familyComposition: t, partnerBirthdate: n }) => {
|
|
@@ -4752,7 +4761,7 @@ var Gi = (e) => R({
|
|
|
4752
4761
|
span: "4",
|
|
4753
4762
|
md: "6"
|
|
4754
4763
|
}, {
|
|
4755
|
-
default: P(() => [c(E(
|
|
4764
|
+
default: P(() => [c(E(bn), {
|
|
4756
4765
|
"resolved-address": E(f),
|
|
4757
4766
|
"onUpdate:resolvedAddress": i[0] ||= (e) => d(f) ? f.value = e : null,
|
|
4758
4767
|
"addition-options": E(p)
|
|
@@ -4775,7 +4784,7 @@ var Gi = (e) => R({
|
|
|
4775
4784
|
span: A.value ? 2 : 3,
|
|
4776
4785
|
md: "6"
|
|
4777
4786
|
}, {
|
|
4778
|
-
default: P(() => [c(E(
|
|
4787
|
+
default: P(() => [c(E(cn), m({
|
|
4779
4788
|
modelValue: E(C),
|
|
4780
4789
|
"onUpdate:modelValue": i[2] ||= (e) => d(C) ? C.value = e : null,
|
|
4781
4790
|
"error-message": E(T)
|
|
@@ -4803,7 +4812,7 @@ var Gi = (e) => R({
|
|
|
4803
4812
|
});
|
|
4804
4813
|
//#endregion
|
|
4805
4814
|
//#region src/comparisons/package/package.presenter.ts
|
|
4806
|
-
function
|
|
4815
|
+
function Vi(e) {
|
|
4807
4816
|
return {
|
|
4808
4817
|
comparison: V.Package,
|
|
4809
4818
|
detail: { partner: { birthdate: e.partnerBirthdate } },
|
|
@@ -4820,18 +4829,18 @@ function qi(e) {
|
|
|
4820
4829
|
}
|
|
4821
4830
|
//#endregion
|
|
4822
4831
|
//#region src/comparisons/loan/constants.ts
|
|
4823
|
-
var
|
|
4832
|
+
var Hi = {
|
|
4824
4833
|
min: 21,
|
|
4825
4834
|
max: 74
|
|
4826
|
-
},
|
|
4835
|
+
}, Ui = {
|
|
4827
4836
|
min: 3500,
|
|
4828
4837
|
max: 75e3
|
|
4829
|
-
},
|
|
4838
|
+
}, Wi = R({
|
|
4830
4839
|
LoanPurpose: z().required(Q.loan.purposeRequired),
|
|
4831
|
-
LoanAmount:
|
|
4832
|
-
birthdate: $(
|
|
4833
|
-
familyComposition:
|
|
4834
|
-
}),
|
|
4840
|
+
LoanAmount: Zr(Q.loan.amountRequired).min(Ui.min, Q.loan.amountMin(Ui.min)).max(Ui.max, Q.loan.amountMax(Ui.max)),
|
|
4841
|
+
birthdate: $(Hi),
|
|
4842
|
+
familyComposition: $r
|
|
4843
|
+
}), Gi = [
|
|
4835
4844
|
{
|
|
4836
4845
|
title: "Aankoop auto",
|
|
4837
4846
|
value: "02"
|
|
@@ -4880,7 +4889,7 @@ var Ji = {
|
|
|
4880
4889
|
title: "Anders",
|
|
4881
4890
|
value: "99"
|
|
4882
4891
|
}
|
|
4883
|
-
],
|
|
4892
|
+
], Ki = /* @__PURE__ */ l({
|
|
4884
4893
|
__name: "LoanForm",
|
|
4885
4894
|
props: /*@__PURE__*/ f({
|
|
4886
4895
|
initialData: {},
|
|
@@ -4899,7 +4908,7 @@ var Ji = {
|
|
|
4899
4908
|
}),
|
|
4900
4909
|
emits: ["submitted"],
|
|
4901
4910
|
setup(e, { emit: t }) {
|
|
4902
|
-
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(
|
|
4911
|
+
let r = e, i = q(r), a = t, { isSubmitting: o, handleSubmit: s, defineField: l } = Z(Wi, {
|
|
4903
4912
|
LoanPurpose: r.initialData?.LoanPurpose ?? "",
|
|
4904
4913
|
LoanAmount: r.initialData?.LoanAmount ?? null,
|
|
4905
4914
|
birthdate: r.initialData?.birthdate ?? "",
|
|
@@ -4924,7 +4933,7 @@ var Ji = {
|
|
|
4924
4933
|
"onUpdate:modelValue": r[0] ||= (e) => d(u) ? u.value = e : null,
|
|
4925
4934
|
label: "Leendoel",
|
|
4926
4935
|
placeholder: "Maak een keuze",
|
|
4927
|
-
options: E(
|
|
4936
|
+
options: E(Gi),
|
|
4928
4937
|
name: "LoanPurpose",
|
|
4929
4938
|
required: !1,
|
|
4930
4939
|
"error-message": E(p)
|
|
@@ -4939,7 +4948,7 @@ var Ji = {
|
|
|
4939
4948
|
span: "2",
|
|
4940
4949
|
md: "6"
|
|
4941
4950
|
}, {
|
|
4942
|
-
default: P(() => [c(E(
|
|
4951
|
+
default: P(() => [c(E(We), m({
|
|
4943
4952
|
modelValue: E(h),
|
|
4944
4953
|
"onUpdate:modelValue": r[1] ||= (e) => d(h) ? h.value = e : null,
|
|
4945
4954
|
modelModifiers: { number: !0 },
|
|
@@ -4969,7 +4978,7 @@ var Ji = {
|
|
|
4969
4978
|
span: "3",
|
|
4970
4979
|
md: "6"
|
|
4971
4980
|
}, {
|
|
4972
|
-
default: P(() => [c(E(
|
|
4981
|
+
default: P(() => [c(E(cn), m({
|
|
4973
4982
|
modelValue: E(S),
|
|
4974
4983
|
"onUpdate:modelValue": r[3] ||= (e) => d(S) ? S.value = e : null,
|
|
4975
4984
|
"error-message": E(w)
|
|
@@ -4983,19 +4992,19 @@ var Ji = {
|
|
|
4983
4992
|
});
|
|
4984
4993
|
//#endregion
|
|
4985
4994
|
//#region src/comparisons/loan/loan.presenter.ts
|
|
4986
|
-
function
|
|
4987
|
-
let t =
|
|
4995
|
+
function qi(e) {
|
|
4996
|
+
let t = Vr(e, Ir);
|
|
4988
4997
|
if (!t) return 120;
|
|
4989
4998
|
let n = t.add(76, "year").diff(ke(), "month", !0), r = Math.floor(n / 12) * 12;
|
|
4990
4999
|
return Math.min(r, 120);
|
|
4991
5000
|
}
|
|
4992
|
-
function
|
|
5001
|
+
function Ji(e) {
|
|
4993
5002
|
return {
|
|
4994
5003
|
comparison: V.Loan,
|
|
4995
5004
|
detail: { loan: {
|
|
4996
5005
|
LoanPurpose: e.LoanPurpose,
|
|
4997
5006
|
LoanAmount: e.LoanAmount,
|
|
4998
|
-
MaxDurationByLegalLimit:
|
|
5007
|
+
MaxDurationByLegalLimit: qi(e.birthdate)
|
|
4999
5008
|
} },
|
|
5000
5009
|
user: {
|
|
5001
5010
|
birthdate: e.birthdate,
|
|
@@ -5005,14 +5014,14 @@ function ea(e) {
|
|
|
5005
5014
|
}
|
|
5006
5015
|
//#endregion
|
|
5007
5016
|
//#region src/comparisons/moped/constants.ts
|
|
5008
|
-
var
|
|
5017
|
+
var Yi = {
|
|
5009
5018
|
min: 16,
|
|
5010
5019
|
max: 99
|
|
5011
|
-
},
|
|
5020
|
+
}, Xi = (e, t) => R({
|
|
5012
5021
|
licensePlate: e,
|
|
5013
5022
|
address: t,
|
|
5014
|
-
birthdate: $(
|
|
5015
|
-
}),
|
|
5023
|
+
birthdate: $(Yi)
|
|
5024
|
+
}), Zi = /* @__PURE__ */ l({
|
|
5016
5025
|
__name: "MopedForm",
|
|
5017
5026
|
props: /*@__PURE__*/ f({
|
|
5018
5027
|
initialData: {},
|
|
@@ -5031,7 +5040,7 @@ var ta = {
|
|
|
5031
5040
|
}),
|
|
5032
5041
|
emits: ["submitted"],
|
|
5033
5042
|
setup(e, { emit: t }) {
|
|
5034
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
5043
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Hn({ initial: r.initialData?.address }), { vehicleData: f, licensePlateSchema: p } = cr(V.Moped, { initialData: r.initialData?.vehicle ?? void 0 }), { isSubmitting: h, handleSubmit: g, defineField: _ } = Z(Xi(p, o), {
|
|
5035
5044
|
licensePlate: r.initialData?.licensePlate ?? "",
|
|
5036
5045
|
birthdate: r.initialData?.birthdate ?? "",
|
|
5037
5046
|
address: s
|
|
@@ -5055,7 +5064,7 @@ var ta = {
|
|
|
5055
5064
|
span: "3",
|
|
5056
5065
|
md: "6"
|
|
5057
5066
|
}, {
|
|
5058
|
-
default: P(() => [c(E(
|
|
5067
|
+
default: P(() => [c(E(nr), m({
|
|
5059
5068
|
modelValue: E(v),
|
|
5060
5069
|
"onUpdate:modelValue": r[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5061
5070
|
"vehicle-data": E(f),
|
|
@@ -5086,7 +5095,7 @@ var ta = {
|
|
|
5086
5095
|
span: "4",
|
|
5087
5096
|
md: "6"
|
|
5088
5097
|
}, {
|
|
5089
|
-
default: P(() => [c(E(
|
|
5098
|
+
default: P(() => [c(E(bn), {
|
|
5090
5099
|
"resolved-address": E(l),
|
|
5091
5100
|
"onUpdate:resolvedAddress": r[2] ||= (e) => d(l) ? l.value = e : null,
|
|
5092
5101
|
"addition-options": E(u)
|
|
@@ -5112,7 +5121,7 @@ var ta = {
|
|
|
5112
5121
|
});
|
|
5113
5122
|
//#endregion
|
|
5114
5123
|
//#region src/comparisons/moped/moped.presenter.ts
|
|
5115
|
-
function
|
|
5124
|
+
function Qi(e) {
|
|
5116
5125
|
return {
|
|
5117
5126
|
comparison: V.Moped,
|
|
5118
5127
|
detail: { moped: { ...e.vehicle } },
|
|
@@ -5129,11 +5138,11 @@ function ia(e) {
|
|
|
5129
5138
|
}
|
|
5130
5139
|
//#endregion
|
|
5131
5140
|
//#region src/comparisons/motor/motor.schema.ts
|
|
5132
|
-
var
|
|
5141
|
+
var $i = (e, t) => R({
|
|
5133
5142
|
licensePlate: e,
|
|
5134
5143
|
address: t,
|
|
5135
5144
|
birthdate: $()
|
|
5136
|
-
}),
|
|
5145
|
+
}), ea = /* @__PURE__ */ l({
|
|
5137
5146
|
__name: "MotorForm",
|
|
5138
5147
|
props: /*@__PURE__*/ f({
|
|
5139
5148
|
initialData: {},
|
|
@@ -5152,7 +5161,7 @@ var aa = (e, t) => R({
|
|
|
5152
5161
|
}),
|
|
5153
5162
|
emits: ["submitted"],
|
|
5154
5163
|
setup(e, { emit: t }) {
|
|
5155
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
5164
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Hn({ initial: r.initialData?.address }), { vehicleData: f, licensePlateSchema: p } = cr(V.Motor, { initialData: r.initialData?.vehicle ?? void 0 }), { isSubmitting: h, handleSubmit: g, defineField: _ } = Z($i(p, o), {
|
|
5156
5165
|
licensePlate: r.initialData?.licensePlate ?? "",
|
|
5157
5166
|
birthdate: r.initialData?.birthdate ?? "",
|
|
5158
5167
|
address: s
|
|
@@ -5176,7 +5185,7 @@ var aa = (e, t) => R({
|
|
|
5176
5185
|
span: "3",
|
|
5177
5186
|
md: "6"
|
|
5178
5187
|
}, {
|
|
5179
|
-
default: P(() => [c(E(
|
|
5188
|
+
default: P(() => [c(E(nr), m({
|
|
5180
5189
|
modelValue: E(v),
|
|
5181
5190
|
"onUpdate:modelValue": r[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5182
5191
|
"vehicle-data": E(f),
|
|
@@ -5207,7 +5216,7 @@ var aa = (e, t) => R({
|
|
|
5207
5216
|
span: "4",
|
|
5208
5217
|
md: "6"
|
|
5209
5218
|
}, {
|
|
5210
|
-
default: P(() => [c(E(
|
|
5219
|
+
default: P(() => [c(E(bn), {
|
|
5211
5220
|
"resolved-address": E(l),
|
|
5212
5221
|
"onUpdate:resolvedAddress": r[2] ||= (e) => d(l) ? l.value = e : null,
|
|
5213
5222
|
"addition-options": E(u)
|
|
@@ -5233,7 +5242,7 @@ var aa = (e, t) => R({
|
|
|
5233
5242
|
});
|
|
5234
5243
|
//#endregion
|
|
5235
5244
|
//#region src/comparisons/motor/motor.presenter.ts
|
|
5236
|
-
function
|
|
5245
|
+
function ta(e) {
|
|
5237
5246
|
return {
|
|
5238
5247
|
comparison: V.Motor,
|
|
5239
5248
|
detail: { motor: { ...e.vehicle } },
|
|
@@ -5250,11 +5259,11 @@ function sa(e) {
|
|
|
5250
5259
|
}
|
|
5251
5260
|
//#endregion
|
|
5252
5261
|
//#region src/comparisons/car/car.schema.ts
|
|
5253
|
-
var
|
|
5262
|
+
var na = (e, t) => R({
|
|
5254
5263
|
licensePlate: e,
|
|
5255
5264
|
address: t,
|
|
5256
5265
|
birthdate: $()
|
|
5257
|
-
}),
|
|
5266
|
+
}), ra = /* @__PURE__ */ l({
|
|
5258
5267
|
__name: "CarForm",
|
|
5259
5268
|
props: /*@__PURE__*/ f({
|
|
5260
5269
|
initialData: {},
|
|
@@ -5273,7 +5282,7 @@ var ca = (e, t) => R({
|
|
|
5273
5282
|
}),
|
|
5274
5283
|
emits: ["submitted"],
|
|
5275
5284
|
setup(e, { emit: t }) {
|
|
5276
|
-
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } =
|
|
5285
|
+
let r = e, i = q(r), a = t, { addressSchema: o, draft: s, resolvedAddress: l, additionOptions: u } = Hn({ initial: r.initialData?.address }), { vehicleData: f, licensePlateSchema: p } = cr(V.Car, { initialData: r.initialData?.vehicle ?? void 0 }), { isSubmitting: h, handleSubmit: g, defineField: _ } = Z(na(p, o), {
|
|
5277
5286
|
licensePlate: r.initialData?.licensePlate ?? "",
|
|
5278
5287
|
birthdate: r.initialData?.birthdate ?? "",
|
|
5279
5288
|
address: s
|
|
@@ -5297,7 +5306,7 @@ var ca = (e, t) => R({
|
|
|
5297
5306
|
span: "3",
|
|
5298
5307
|
md: "6"
|
|
5299
5308
|
}, {
|
|
5300
|
-
default: P(() => [c(E(
|
|
5309
|
+
default: P(() => [c(E(nr), m({
|
|
5301
5310
|
modelValue: E(v),
|
|
5302
5311
|
"onUpdate:modelValue": r[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5303
5312
|
"vehicle-data": E(f),
|
|
@@ -5328,7 +5337,7 @@ var ca = (e, t) => R({
|
|
|
5328
5337
|
span: "4",
|
|
5329
5338
|
md: "6"
|
|
5330
5339
|
}, {
|
|
5331
|
-
default: P(() => [c(E(
|
|
5340
|
+
default: P(() => [c(E(bn), {
|
|
5332
5341
|
"resolved-address": E(l),
|
|
5333
5342
|
"onUpdate:resolvedAddress": r[2] ||= (e) => d(l) ? l.value = e : null,
|
|
5334
5343
|
"addition-options": E(u)
|
|
@@ -5354,7 +5363,7 @@ var ca = (e, t) => R({
|
|
|
5354
5363
|
});
|
|
5355
5364
|
//#endregion
|
|
5356
5365
|
//#region src/comparisons/car/car.presenter.ts
|
|
5357
|
-
function
|
|
5366
|
+
function ia(e) {
|
|
5358
5367
|
return {
|
|
5359
5368
|
comparison: V.Car,
|
|
5360
5369
|
detail: { car: { ...e.vehicle } },
|
|
@@ -5371,10 +5380,10 @@ function ua(e) {
|
|
|
5371
5380
|
}
|
|
5372
5381
|
//#endregion
|
|
5373
5382
|
//#region src/comparisons/car-business/businessCar.schema.ts
|
|
5374
|
-
var
|
|
5383
|
+
var aa = (e) => R({
|
|
5375
5384
|
licensePlate: e,
|
|
5376
|
-
company:
|
|
5377
|
-
}),
|
|
5385
|
+
company: Pr()
|
|
5386
|
+
}), oa = /* @__PURE__ */ l({
|
|
5378
5387
|
__name: "BusinessCarForm",
|
|
5379
5388
|
props: /*@__PURE__*/ f({
|
|
5380
5389
|
initialData: {},
|
|
@@ -5393,7 +5402,7 @@ var da = (e) => R({
|
|
|
5393
5402
|
}),
|
|
5394
5403
|
emits: ["submitted"],
|
|
5395
5404
|
setup(e, { emit: i }) {
|
|
5396
|
-
let a = e, o = q(a), s = i, { vehicleData: l, licensePlateSchema: u } =
|
|
5405
|
+
let a = e, o = q(a), s = i, { vehicleData: l, licensePlateSchema: u } = cr(V.Car, { initialData: a.initialData?.vehicle ?? void 0 }), { isSubmitting: f, handleSubmit: p, defineField: h, setErrors: g, removeError: _ } = Z(aa(u), {
|
|
5397
5406
|
licensePlate: a.initialData?.licensePlate ?? "",
|
|
5398
5407
|
company: a.initialData?.company ?? null
|
|
5399
5408
|
}), [v, b, x, S] = h("licensePlate"), [C, w, T] = h("company"), D = (e) => e ? g({ company: e }) : _("company"), O = t(() => !!C.value && !C.value.hasVisitingAddress);
|
|
@@ -5414,7 +5423,7 @@ var da = (e) => R({
|
|
|
5414
5423
|
span: "5",
|
|
5415
5424
|
md: "6"
|
|
5416
5425
|
}, {
|
|
5417
|
-
default: P(() => [c(E(
|
|
5426
|
+
default: P(() => [c(E(nr), m({
|
|
5418
5427
|
modelValue: E(v),
|
|
5419
5428
|
"onUpdate:modelValue": i[0] ||= (e) => d(v) ? v.value = e : null,
|
|
5420
5429
|
"vehicle-data": E(l),
|
|
@@ -5444,7 +5453,7 @@ var da = (e) => R({
|
|
|
5444
5453
|
span: "5",
|
|
5445
5454
|
md: "6"
|
|
5446
5455
|
}, {
|
|
5447
|
-
default: P(() => [c(E(
|
|
5456
|
+
default: P(() => [c(E(Nr), m({
|
|
5448
5457
|
modelValue: E(C),
|
|
5449
5458
|
"onUpdate:modelValue": i[2] ||= (e) => d(C) ? C.value = e : null,
|
|
5450
5459
|
name: "company",
|
|
@@ -5460,7 +5469,7 @@ var da = (e) => R({
|
|
|
5460
5469
|
}
|
|
5461
5470
|
})]),
|
|
5462
5471
|
_: 1
|
|
5463
|
-
}, 16, ["modelValue", "error-message"]), O.value ? (y(), n(E(
|
|
5472
|
+
}, 16, ["modelValue", "error-message"]), O.value ? (y(), n(E(Bt), {
|
|
5464
5473
|
key: 0,
|
|
5465
5474
|
style: { "margin-top": "12px" },
|
|
5466
5475
|
text: "Dit bedrijf heeft geen geregistreerd bezoekadres. Voeg dit toe bij de KvK om door te gaan met de aanvraag."
|
|
@@ -5473,7 +5482,7 @@ var da = (e) => R({
|
|
|
5473
5482
|
});
|
|
5474
5483
|
//#endregion
|
|
5475
5484
|
//#region src/comparisons/car-business/businessCar.presenter.ts
|
|
5476
|
-
function
|
|
5485
|
+
function sa(e) {
|
|
5477
5486
|
return {
|
|
5478
5487
|
comparison: V.CarBusiness,
|
|
5479
5488
|
detail: {
|
|
@@ -5485,7 +5494,7 @@ function pa(e) {
|
|
|
5485
5494
|
}
|
|
5486
5495
|
//#endregion
|
|
5487
5496
|
//#region src/comparisons/businessLiability/businessLiability.schema.ts
|
|
5488
|
-
var
|
|
5497
|
+
var ca = R({ company: Pr() }), la = /* @__PURE__ */ l({
|
|
5489
5498
|
__name: "BusinessLiabilityForm",
|
|
5490
5499
|
props: /*@__PURE__*/ f({
|
|
5491
5500
|
initialData: {},
|
|
@@ -5506,7 +5515,7 @@ var ma = R({ company: Br() }), ha = /* @__PURE__ */ l({
|
|
|
5506
5515
|
}),
|
|
5507
5516
|
emits: ["submitted"],
|
|
5508
5517
|
setup(e, { emit: i }) {
|
|
5509
|
-
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(
|
|
5518
|
+
let a = e, o = q(a), s = i, { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(ca, { company: a.initialData?.company ?? null }), [g, _, v] = f("company"), b = (e) => e ? p({ company: e }) : h("company"), x = t(() => !!g.value && !g.value.hasVisitingAddress);
|
|
5510
5519
|
function S() {
|
|
5511
5520
|
u(({ company: e }) => {
|
|
5512
5521
|
s("submitted", { company: e });
|
|
@@ -5521,7 +5530,7 @@ var ma = R({ company: Br() }), ha = /* @__PURE__ */ l({
|
|
|
5521
5530
|
span: "8",
|
|
5522
5531
|
md: "6"
|
|
5523
5532
|
}, {
|
|
5524
|
-
default: P(() => [c(E(
|
|
5533
|
+
default: P(() => [c(E(Nr), m({
|
|
5525
5534
|
modelValue: E(g),
|
|
5526
5535
|
"onUpdate:modelValue": t[0] ||= (e) => d(g) ? g.value = e : null,
|
|
5527
5536
|
name: "company",
|
|
@@ -5537,7 +5546,7 @@ var ma = R({ company: Br() }), ha = /* @__PURE__ */ l({
|
|
|
5537
5546
|
}
|
|
5538
5547
|
})]),
|
|
5539
5548
|
_: 1
|
|
5540
|
-
}, 16, ["modelValue", "error-message"]), x.value ? (y(), n(E(
|
|
5549
|
+
}, 16, ["modelValue", "error-message"]), x.value ? (y(), n(E(Bt), {
|
|
5541
5550
|
key: 0,
|
|
5542
5551
|
style: { "margin-top": "12px" },
|
|
5543
5552
|
text: "Dit bedrijf heeft geen geregistreerd bezoekadres. Voeg dit toe bij de KvK om door te gaan met de aanvraag."
|
|
@@ -5550,7 +5559,7 @@ var ma = R({ company: Br() }), ha = /* @__PURE__ */ l({
|
|
|
5550
5559
|
});
|
|
5551
5560
|
//#endregion
|
|
5552
5561
|
//#region src/comparisons/businessLiability/businessLiability.presenter.ts
|
|
5553
|
-
function
|
|
5562
|
+
function ua(e) {
|
|
5554
5563
|
return {
|
|
5555
5564
|
comparison: V.BusinessLiability,
|
|
5556
5565
|
detail: { companyData: { ...e.company } },
|
|
@@ -5559,9 +5568,9 @@ function ga(e) {
|
|
|
5559
5568
|
}
|
|
5560
5569
|
//#endregion
|
|
5561
5570
|
//#region src/flow/useComparisonSubmit.ts
|
|
5562
|
-
var
|
|
5571
|
+
var da = { [V.Travel]: "/tarieven/" }, fa = (e, t, n) => `${e}#/${n}${da[t] ?? ""}`, pa = (e) => {
|
|
5563
5572
|
window.location.href = e;
|
|
5564
|
-
},
|
|
5573
|
+
}, ma = ({ user: e, detail: t }) => new Oe({
|
|
5565
5574
|
email: e.email || null,
|
|
5566
5575
|
name: e.firstName || null,
|
|
5567
5576
|
zip_code: e.zipCode || null,
|
|
@@ -5575,14 +5584,14 @@ var _a = { [V.Travel]: "/tarieven/" }, va = (e, t, n) => `${e}#/${n}${_a[t] ?? "
|
|
|
5575
5584
|
...e.city && { city: e.city }
|
|
5576
5585
|
}
|
|
5577
5586
|
});
|
|
5578
|
-
function
|
|
5587
|
+
function ha(e) {
|
|
5579
5588
|
let t = x(!1), n = x(null);
|
|
5580
5589
|
return {
|
|
5581
5590
|
submit: async (r) => {
|
|
5582
5591
|
t.value = !0, n.value = null;
|
|
5583
5592
|
try {
|
|
5584
|
-
let t = await
|
|
5585
|
-
e.onRedirect ? e.onRedirect(n) :
|
|
5593
|
+
let t = await Dn().comparisonService.create(r.comparison, ma(r)), n = fa(e.link, r.comparison, t.getId());
|
|
5594
|
+
e.onRedirect ? e.onRedirect(n) : pa(n);
|
|
5586
5595
|
} catch (t) {
|
|
5587
5596
|
n.value = t, e.onError?.(t, r);
|
|
5588
5597
|
} finally {
|
|
@@ -5595,66 +5604,66 @@ function xa(e) {
|
|
|
5595
5604
|
}
|
|
5596
5605
|
//#endregion
|
|
5597
5606
|
//#region src/comparisons/bike/index.ts
|
|
5598
|
-
var
|
|
5599
|
-
Form: () =>
|
|
5600
|
-
presenter: () =>
|
|
5601
|
-
}),
|
|
5607
|
+
var ga = /* @__PURE__ */ B({
|
|
5608
|
+
Form: () => li,
|
|
5609
|
+
presenter: () => ui
|
|
5610
|
+
}), _a = /* @__PURE__ */ B({
|
|
5611
|
+
Form: () => mi,
|
|
5612
|
+
presenter: () => hi
|
|
5613
|
+
}), va = /* @__PURE__ */ B({
|
|
5602
5614
|
Form: () => bi,
|
|
5603
5615
|
presenter: () => xi
|
|
5616
|
+
}), ya = /* @__PURE__ */ B({
|
|
5617
|
+
Form: () => Ti,
|
|
5618
|
+
presenter: () => Ei
|
|
5619
|
+
}), ba = /* @__PURE__ */ B({
|
|
5620
|
+
Form: () => Oi,
|
|
5621
|
+
presenter: () => ki
|
|
5622
|
+
}), xa = /* @__PURE__ */ B({
|
|
5623
|
+
Form: () => Mi,
|
|
5624
|
+
presenter: () => Ni
|
|
5625
|
+
}), Sa = /* @__PURE__ */ B({
|
|
5626
|
+
Form: () => Li,
|
|
5627
|
+
presenter: () => Ri
|
|
5628
|
+
}), Ca = /* @__PURE__ */ B({
|
|
5629
|
+
Form: () => Bi,
|
|
5630
|
+
presenter: () => Vi
|
|
5604
5631
|
}), wa = /* @__PURE__ */ B({
|
|
5605
|
-
Form: () =>
|
|
5606
|
-
presenter: () =>
|
|
5632
|
+
Form: () => Ki,
|
|
5633
|
+
presenter: () => Ji
|
|
5607
5634
|
}), Ta = /* @__PURE__ */ B({
|
|
5608
|
-
Form: () =>
|
|
5609
|
-
presenter: () =>
|
|
5635
|
+
Form: () => Zi,
|
|
5636
|
+
presenter: () => Qi
|
|
5610
5637
|
}), Ea = /* @__PURE__ */ B({
|
|
5611
|
-
Form: () =>
|
|
5612
|
-
presenter: () =>
|
|
5638
|
+
Form: () => ea,
|
|
5639
|
+
presenter: () => ta
|
|
5613
5640
|
}), Da = /* @__PURE__ */ B({
|
|
5614
|
-
Form: () => Ri,
|
|
5615
|
-
presenter: () => zi
|
|
5616
|
-
}), Oa = /* @__PURE__ */ B({
|
|
5617
|
-
Form: () => Ui,
|
|
5618
|
-
presenter: () => Wi
|
|
5619
|
-
}), ka = /* @__PURE__ */ B({
|
|
5620
|
-
Form: () => Ki,
|
|
5621
|
-
presenter: () => qi
|
|
5622
|
-
}), Aa = /* @__PURE__ */ B({
|
|
5623
|
-
Form: () => Qi,
|
|
5624
|
-
presenter: () => ea
|
|
5625
|
-
}), ja = /* @__PURE__ */ B({
|
|
5626
5641
|
Form: () => ra,
|
|
5627
5642
|
presenter: () => ia
|
|
5628
|
-
}),
|
|
5643
|
+
}), Oa = /* @__PURE__ */ B({
|
|
5629
5644
|
Form: () => oa,
|
|
5630
5645
|
presenter: () => sa
|
|
5631
|
-
}),
|
|
5646
|
+
}), ka = /* @__PURE__ */ B({
|
|
5632
5647
|
Form: () => la,
|
|
5633
5648
|
presenter: () => ua
|
|
5634
|
-
}),
|
|
5635
|
-
|
|
5636
|
-
|
|
5637
|
-
|
|
5638
|
-
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
|
|
5642
|
-
[V.
|
|
5643
|
-
[V.
|
|
5644
|
-
[V.
|
|
5645
|
-
[V.
|
|
5646
|
-
[V.
|
|
5647
|
-
|
|
5648
|
-
[V.
|
|
5649
|
-
|
|
5650
|
-
[V.
|
|
5651
|
-
|
|
5652
|
-
[V.Motor]: Ma,
|
|
5653
|
-
[V.Car]: Na,
|
|
5654
|
-
[V.CarBusiness]: Pa,
|
|
5655
|
-
"business-car": Pa,
|
|
5656
|
-
[V.BusinessLiability]: Fa
|
|
5657
|
-
}, La = /* @__PURE__ */ l({
|
|
5649
|
+
}), Aa = {
|
|
5650
|
+
[V.Bike]: ga,
|
|
5651
|
+
[V.Pet]: _a,
|
|
5652
|
+
[V.Caravan]: va,
|
|
5653
|
+
[V.Travel]: ya,
|
|
5654
|
+
[V.Liability]: ba,
|
|
5655
|
+
[V.Housing]: xa,
|
|
5656
|
+
house: xa,
|
|
5657
|
+
[V.LegalAssistance]: Sa,
|
|
5658
|
+
[V.Package]: Ca,
|
|
5659
|
+
[V.Loan]: wa,
|
|
5660
|
+
[V.Moped]: Ta,
|
|
5661
|
+
[V.Motor]: Ea,
|
|
5662
|
+
[V.Car]: Da,
|
|
5663
|
+
[V.CarBusiness]: Oa,
|
|
5664
|
+
"business-car": Oa,
|
|
5665
|
+
[V.BusinessLiability]: ka
|
|
5666
|
+
}, ja = /* @__PURE__ */ l({
|
|
5658
5667
|
__name: "ComparisonFormFlow",
|
|
5659
5668
|
props: {
|
|
5660
5669
|
form: {},
|
|
@@ -5685,7 +5694,7 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5685
5694
|
},
|
|
5686
5695
|
emits: ["submitted", "error"],
|
|
5687
5696
|
setup(e, { emit: i }) {
|
|
5688
|
-
let a = e, o = i, s = q(a), c = t(() =>
|
|
5697
|
+
let a = e, o = i, s = q(a), c = t(() => Aa[a.form]), { submit: l, isSubmitting: u } = ha({
|
|
5689
5698
|
link: a.link,
|
|
5690
5699
|
onRedirect: (e) => {
|
|
5691
5700
|
o("submitted", e), a.redirect ? a.redirect(e) : window.location.href = e;
|
|
@@ -5701,16 +5710,16 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5701
5710
|
onSubmitted: d
|
|
5702
5711
|
}), null, 16, ["initial-data", "submit-disabled"])) : r("", !0);
|
|
5703
5712
|
}
|
|
5704
|
-
}),
|
|
5713
|
+
}), Ma = { class: "vd-form vd-form--vertical vd-form--card" }, Na = {
|
|
5705
5714
|
key: 0,
|
|
5706
5715
|
class: "vd-form__header"
|
|
5707
|
-
},
|
|
5716
|
+
}, Pa = {
|
|
5708
5717
|
key: 0,
|
|
5709
5718
|
class: "vd-form__title"
|
|
5710
|
-
},
|
|
5719
|
+
}, Fa = {
|
|
5711
5720
|
key: 1,
|
|
5712
5721
|
class: "vd-form__description"
|
|
5713
|
-
},
|
|
5722
|
+
}, Ia = /* @__PURE__ */ l({
|
|
5714
5723
|
__name: "QuestionnaireForm",
|
|
5715
5724
|
props: {
|
|
5716
5725
|
link: {},
|
|
@@ -5725,11 +5734,11 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5725
5734
|
}
|
|
5726
5735
|
},
|
|
5727
5736
|
setup(e) {
|
|
5728
|
-
let n = e, a = t(() =>
|
|
5737
|
+
let n = e, a = t(() => Kr(n.link, {
|
|
5729
5738
|
qaId: n.qaId,
|
|
5730
5739
|
template: n.thankyouPageTemplate
|
|
5731
5740
|
}));
|
|
5732
|
-
return (t, n) => (y(), i("div",
|
|
5741
|
+
return (t, n) => (y(), i("div", Ma, [e.showTitle && e.title || e.description ? (y(), i("div", Na, [e.showTitle && e.title ? (y(), i("h2", Pa, T(e.title), 1)) : r("", !0), e.description ? (y(), i("p", Fa, T(e.description), 1)) : r("", !0)])) : r("", !0), c(E(Ne), {
|
|
5733
5742
|
href: a.value,
|
|
5734
5743
|
label: e.buttonText,
|
|
5735
5744
|
"button-type": "green",
|
|
@@ -5738,16 +5747,16 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5738
5747
|
block: ""
|
|
5739
5748
|
}, null, 8, ["href", "label"])]));
|
|
5740
5749
|
}
|
|
5741
|
-
}),
|
|
5750
|
+
}), La = {
|
|
5742
5751
|
key: 0,
|
|
5743
5752
|
class: "vd-form__header"
|
|
5744
|
-
},
|
|
5753
|
+
}, Ra = {
|
|
5745
5754
|
key: 0,
|
|
5746
5755
|
class: "vd-form__title"
|
|
5747
|
-
},
|
|
5756
|
+
}, za = {
|
|
5748
5757
|
key: 1,
|
|
5749
5758
|
class: "vd-form__description"
|
|
5750
|
-
},
|
|
5759
|
+
}, Ba = { class: "vd-form__row" }, Va = { class: "vd-form__col-10 vd-form__col-md-6" }, Ha = { class: "vd-form__col-2 vd-form__action" }, Ua = /* @__PURE__ */ l({
|
|
5751
5760
|
__name: "RiskScannerForm",
|
|
5752
5761
|
props: {
|
|
5753
5762
|
qaUrl: { default: "" },
|
|
@@ -5765,9 +5774,9 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5765
5774
|
}
|
|
5766
5775
|
},
|
|
5767
5776
|
setup(e) {
|
|
5768
|
-
let o = e, s = x(null), { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(R({ company:
|
|
5777
|
+
let o = e, s = x(null), { isSubmitting: l, handleSubmit: u, defineField: f, setErrors: p, removeError: h } = Z(R({ company: Pr() }), { company: null }), [g, _, v] = f("company"), b = (e) => e ? p({ company: e }) : h("company"), S = t(() => !!g.value && !g.value.hasVisitingAddress);
|
|
5769
5778
|
async function C(e) {
|
|
5770
|
-
let t = o.qaUrl ||
|
|
5779
|
+
let t = o.qaUrl || wn(), n = t.endsWith("/") ? t : `${t}/`, r = await fetch(`${n}api/v1/active-questionnaire/${o.qaId}/start`, {
|
|
5771
5780
|
method: "POST",
|
|
5772
5781
|
headers: { "Content-Type": "application/json" },
|
|
5773
5782
|
body: JSON.stringify({
|
|
@@ -5781,7 +5790,7 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5781
5790
|
});
|
|
5782
5791
|
if (!r.ok) throw Error(`Failed to start the questionnaire (${r.status})`);
|
|
5783
5792
|
let { leadId: i } = await r.json();
|
|
5784
|
-
return
|
|
5793
|
+
return Kr(o.link, {
|
|
5785
5794
|
leadid: i,
|
|
5786
5795
|
qaId: o.qaId,
|
|
5787
5796
|
template: o.thankyouPageTemplate
|
|
@@ -5801,18 +5810,19 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5801
5810
|
return (t, o) => (y(), i("form", {
|
|
5802
5811
|
class: "vd-form vd-form--vertical vd-form--card",
|
|
5803
5812
|
onSubmit: I(w, ["prevent", "stop"])
|
|
5804
|
-
}, [e.showTitle && e.title || e.description ? (y(), i("div",
|
|
5813
|
+
}, [e.showTitle && e.title || e.description ? (y(), i("div", La, [e.showTitle && e.title ? (y(), i("h2", Ra, T(e.title), 1)) : r("", !0), e.description ? (y(), i("p", za, T(e.description), 1)) : r("", !0)])) : r("", !0), a("div", Ba, [a("div", Va, [c(E(Nr), m({
|
|
5805
5814
|
modelValue: E(g),
|
|
5806
5815
|
"onUpdate:modelValue": o[0] ||= (e) => d(g) ? g.value = e : null
|
|
5807
5816
|
}, E(_), {
|
|
5808
5817
|
"error-message": E(v),
|
|
5809
5818
|
onError: b,
|
|
5810
5819
|
onRaw: o[1] ||= (e) => s.value = e
|
|
5811
|
-
}), null, 16, ["modelValue", "error-message"]), S.value ? (y(), n(E(
|
|
5820
|
+
}), null, 16, ["modelValue", "error-message"]), S.value ? (y(), n(E(Bt), {
|
|
5812
5821
|
key: 0,
|
|
5813
5822
|
style: { "margin-top": "12px" },
|
|
5814
5823
|
text: "Dit bedrijf heeft geen geregistreerd bezoekadres. Voeg dit toe bij de KvK om door te gaan met de aanvraag."
|
|
5815
|
-
})) : r("", !0)]), a("div",
|
|
5824
|
+
})) : r("", !0)]), a("div", Ha, [c(E(Ne), {
|
|
5825
|
+
type: "submit",
|
|
5816
5826
|
label: e.buttonText,
|
|
5817
5827
|
"is-loading": E(l),
|
|
5818
5828
|
disabled: S.value,
|
|
@@ -5828,4 +5838,4 @@ var Sa = /* @__PURE__ */ B({
|
|
|
5828
5838
|
}
|
|
5829
5839
|
});
|
|
5830
5840
|
//#endregion
|
|
5831
|
-
export {
|
|
5841
|
+
export { li as BikeForm, oa as BusinessCarForm, la as BusinessLiabilityForm, ra as CarForm, bi as CaravanForm, ja as ComparisonFormFlow, V as ComparisonName, Mi as HouseForm, Li as LegalForm, Oi as LiabilityForm, Ki as LoanForm, Zi as MopedForm, ea as MotorForm, Bi as PackageForm, mi as PetForm, Ia as QuestionnaireForm, Ua as RiskScannerForm, Ti as TravelForm, ui as bikePresenter, sa as businessCarPresenter, ua as businessLiabilityPresenter, ia as carPresenter, xi as caravanPresenter, Ni as housePresenter, Ri as legalPresenter, ki as liabilityPresenter, Ji as loanPresenter, Qi as mopedPresenter, ta as motorPresenter, Vi as packagePresenter, hi as petPresenter, Ei as travelPresenter, ha as useComparisonSubmit };
|