@vergelijkdirect/comparison-forms 1.2.32-rc.5 → 1.2.32-rc.7
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.
|
@@ -17335,8 +17335,8 @@ xe.default = xe;
|
|
|
17335
17335
|
const tt = (t) => {
|
|
17336
17336
|
const {
|
|
17337
17337
|
generateComparisonId: e
|
|
17338
|
-
} = gR(), r = (p) => {
|
|
17339
|
-
t("emit-event", p);
|
|
17338
|
+
} = gR(), r = (p, f) => {
|
|
17339
|
+
t("emit-event-hub", { event: p, data: f });
|
|
17340
17340
|
}, n = (p, f) => {
|
|
17341
17341
|
t("redirect-page", { link: p, data: f });
|
|
17342
17342
|
}, a = (p) => {
|
|
@@ -17367,7 +17367,7 @@ const tt = (t) => {
|
|
|
17367
17367
|
}
|
|
17368
17368
|
}), u = (p, f) => p.replace("<<COMPARISONID>>", f);
|
|
17369
17369
|
return {
|
|
17370
|
-
|
|
17370
|
+
emitEvent: r,
|
|
17371
17371
|
submitFormAndRedirect: n,
|
|
17372
17372
|
submitFormAndUpdateFormData: a,
|
|
17373
17373
|
submitFormAndCreateComparison: i,
|
|
@@ -30192,22 +30192,23 @@ var ob = /* @__PURE__ */ E(
|
|
|
30192
30192
|
);
|
|
30193
30193
|
ob.options.__file = "/Users/mac/Work/comparison-forms/src/components/common/inputs/DefaultTextArea.vue";
|
|
30194
30194
|
const HI = ob.exports, zI = (t) => {
|
|
30195
|
-
|
|
30195
|
+
tt(t);
|
|
30196
|
+
let e = we({
|
|
30196
30197
|
howToContact: [],
|
|
30197
30198
|
whenToContact: [],
|
|
30198
30199
|
whatToHelpWith: "alreadyHasContract",
|
|
30199
30200
|
userQuestion: ""
|
|
30200
|
-
}),
|
|
30201
|
-
const
|
|
30201
|
+
}), r = k("idle");
|
|
30202
|
+
const n = ie(() => [{
|
|
30202
30203
|
rule: "required",
|
|
30203
30204
|
text: "Voornaam is verplicht"
|
|
30204
|
-
}]),
|
|
30205
|
-
|
|
30205
|
+
}]), a = (p) => {
|
|
30206
|
+
r.value = p;
|
|
30207
|
+
}, i = () => {
|
|
30208
|
+
e.howToContact = [], e.whenToContact = [], e.whatToHelpWith = "alreadyHasContract", e.userQuestion = "";
|
|
30206
30209
|
}, o = () => {
|
|
30207
|
-
r.howToContact = [], r.whenToContact = [], r.whatToHelpWith = "alreadyHasContract", r.userQuestion = "";
|
|
30208
|
-
}, u = () => {
|
|
30209
30210
|
S.email = "", S.firstName = "", S.phoneNumber = "";
|
|
30210
|
-
},
|
|
30211
|
+
}, u = (p) => p.join(","), c = () => N(void 0, null, function* () {
|
|
30211
30212
|
return yield ze([
|
|
30212
30213
|
"name",
|
|
30213
30214
|
"phonenumber",
|
|
@@ -30215,32 +30216,35 @@ const HI = ob.exports, zI = (t) => {
|
|
|
30215
30216
|
"whenToContact",
|
|
30216
30217
|
"emailInput"
|
|
30217
30218
|
]);
|
|
30218
|
-
}),
|
|
30219
|
+
}), l = () => {
|
|
30220
|
+
window.dispatchEvent(new CustomEvent("close-tab"));
|
|
30221
|
+
}, s = () => N(void 0, null, function* () {
|
|
30219
30222
|
const { data: p } = yield xe.post(Dn.getMijnUrl() + "/api/communication/contact", {
|
|
30220
30223
|
email: S.email,
|
|
30221
30224
|
name: S.firstName,
|
|
30222
30225
|
phone_number: S.phoneNumber,
|
|
30223
|
-
message:
|
|
30224
|
-
how_to_contact:
|
|
30225
|
-
when_to_contact:
|
|
30226
|
-
what_to_help_with:
|
|
30226
|
+
message: e.userQuestion,
|
|
30227
|
+
how_to_contact: u(e.howToContact),
|
|
30228
|
+
when_to_contact: u(e.whenToContact),
|
|
30229
|
+
what_to_help_with: e.whatToHelpWith,
|
|
30227
30230
|
type: "callback"
|
|
30228
30231
|
});
|
|
30229
30232
|
return p.response === "success";
|
|
30230
30233
|
});
|
|
30231
30234
|
return {
|
|
30232
|
-
requestStatus:
|
|
30233
|
-
nameInputErrorsData:
|
|
30234
|
-
callbackRequestQuestionsData:
|
|
30235
|
+
requestStatus: r,
|
|
30236
|
+
nameInputErrorsData: n,
|
|
30237
|
+
callbackRequestQuestionsData: e,
|
|
30238
|
+
closeTab: l,
|
|
30235
30239
|
validateBeforeSubmit: () => N(void 0, null, function* () {
|
|
30236
30240
|
try {
|
|
30237
|
-
if (yield
|
|
30241
|
+
if (yield c()) {
|
|
30238
30242
|
j.value = !0;
|
|
30239
30243
|
const p = yield s();
|
|
30240
|
-
|
|
30244
|
+
a(p ? "success" : "failed"), i(), o(), yield Um(), l(), j.value = !1;
|
|
30241
30245
|
}
|
|
30242
30246
|
} catch (p) {
|
|
30243
|
-
|
|
30247
|
+
a("failed"), console.error(p);
|
|
30244
30248
|
} finally {
|
|
30245
30249
|
j.value = !1;
|
|
30246
30250
|
}
|
|
@@ -30261,14 +30265,16 @@ const HI = ob.exports, zI = (t) => {
|
|
|
30261
30265
|
const {
|
|
30262
30266
|
nameInputErrorsData: r,
|
|
30263
30267
|
callbackRequestQuestionsData: n,
|
|
30264
|
-
|
|
30268
|
+
closeTab: a,
|
|
30269
|
+
validateBeforeSubmit: i
|
|
30265
30270
|
} = zI(e);
|
|
30266
30271
|
return {
|
|
30267
30272
|
userState: S,
|
|
30268
30273
|
callbackRequestQuestions: aN,
|
|
30269
30274
|
nameInputErrorsData: r,
|
|
30270
30275
|
callbackRequestQuestionsData: n,
|
|
30271
|
-
|
|
30276
|
+
closeTab: a,
|
|
30277
|
+
validateBeforeSubmit: i
|
|
30272
30278
|
};
|
|
30273
30279
|
}
|
|
30274
30280
|
});
|
|
@@ -30290,7 +30296,7 @@ var sb = function() {
|
|
|
30290
30296
|
e.$set(e.callbackRequestQuestionsData, "whatToHelpWith", n);
|
|
30291
30297
|
}, expression: "callbackRequestQuestionsData.whatToHelpWith" } }), r("ErrorHandler", { attrs: { "errors-data": [{ rule: "required", text: "Selecteer een dekking" }] } })], 1), r("h6", [e._v("Wil je ons alvast meer informatie geven over je vraag? (optioneel)")]), r("default-text-area", { attrs: { id: "userQuestions", placeholder: "Geef hier een korte beschrijving van je vraag of verzoek...", name: "userQuestion" }, model: { value: e.callbackRequestQuestionsData.userQuestion, callback: function(n) {
|
|
30292
30298
|
e.$set(e.callbackRequestQuestionsData, "userQuestion", n);
|
|
30293
|
-
}, expression: "callbackRequestQuestionsData.userQuestion" } }), r("button", { staticClass: "vd-btn vd-btn-primary-alt", on: { click: e.validateBeforeSubmit } }, [e._v("Bel me terug")]), r("button", { staticClass: "vd-btn vd-btn-return" }, [e._v("Sluit formulier")])], 1)]);
|
|
30299
|
+
}, expression: "callbackRequestQuestionsData.userQuestion" } }), r("button", { staticClass: "vd-btn vd-btn-primary-alt", on: { click: e.validateBeforeSubmit } }, [e._v("Bel me terug")]), r("button", { staticClass: "vd-btn vd-btn-return", on: { click: e.closeTab } }, [e._v("Sluit formulier")])], 1)]);
|
|
30294
30300
|
}, YI = [function() {
|
|
30295
30301
|
var t = this, e = t._self._c;
|
|
30296
30302
|
return t._self._setupProxy, e("h6", { staticClass: "vd-contact-slider__checkboxes-title" }, [t._v("Hoe wil je dat we contact met je opnemen? (meerdere opties mogelijk) "), e("span", { staticClass: "text-danger ml-1 mt-2" }, [t._v("*")])]);
|