kwikid-forms 0.6.12 → 0.6.14
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/bundles/kwikid-forms.umd.js +1165 -679
- package/bundles/kwikid-forms.umd.js.map +1 -1
- package/esm2015/lib/renderer/config-converter/config-converter.js +52 -48
- package/esm2015/lib/renderer/form-view/definitions/form-view.actions.definition.js +7 -1
- package/esm2015/lib/renderer/form-view/definitions/form-view.apis.definition.js +1 -1
- package/esm2015/lib/renderer/form-view/definitions/form-view.fields.definition.js +1 -1
- package/esm2015/lib/renderer/form-view/definitions/from-view.logs.definition.js +5 -0
- package/esm2015/lib/renderer/form-view/form-view.component.js +170 -10
- package/esm2015/lib/renderer/form-view/form-view.service.js +12 -2
- package/esm2015/lib/renderer/form-view/helpers/form-view.apis.helper.js +81 -7
- package/esm2015/lib/renderer/form-view/helpers/form-view.defaults.helper.js +31 -1
- package/esm2015/lib/renderer/renderer.component.js +12 -3
- package/fesm2015/kwikid-forms.js +359 -62
- package/fesm2015/kwikid-forms.js.map +1 -1
- package/lib/renderer/form-view/definitions/form-view.actions.definition.d.ts +7 -1
- package/lib/renderer/form-view/definitions/form-view.apis.definition.d.ts +3 -3
- package/lib/renderer/form-view/definitions/form-view.fields.definition.d.ts +6 -0
- package/lib/renderer/form-view/definitions/from-view.logs.definition.d.ts +3 -0
- package/lib/renderer/form-view/form-view.component.d.ts +9 -2
- package/lib/renderer/form-view/helpers/form-view.defaults.helper.d.ts +1 -0
- package/lib/renderer/renderer.component.d.ts +3 -1
- package/package.json +1 -1
package/fesm2015/kwikid-forms.js
CHANGED
|
@@ -726,7 +726,8 @@ class Converter {
|
|
|
726
726
|
logo: {
|
|
727
727
|
src: "",
|
|
728
728
|
alt: "Logo",
|
|
729
|
-
hidden: false
|
|
729
|
+
hidden: false,
|
|
730
|
+
styles: ""
|
|
730
731
|
},
|
|
731
732
|
backButton: {
|
|
732
733
|
mode: "TABBED",
|
|
@@ -735,10 +736,12 @@ class Converter {
|
|
|
735
736
|
},
|
|
736
737
|
title: {
|
|
737
738
|
hidden: false,
|
|
738
|
-
label: (_b = (_a = formConfig === null || formConfig === void 0 ? void 0 : formConfig.title) !== null && _a !== void 0 ? _a : formConfig === null || formConfig === void 0 ? void 0 : formConfig.props.title) !== null && _b !== void 0 ? _b : "Form"
|
|
739
|
+
label: (_b = (_a = formConfig === null || formConfig === void 0 ? void 0 : formConfig.title) !== null && _a !== void 0 ? _a : formConfig === null || formConfig === void 0 ? void 0 : formConfig.props.title) !== null && _b !== void 0 ? _b : "Form",
|
|
740
|
+
styles: ""
|
|
739
741
|
},
|
|
740
742
|
steps: {
|
|
741
|
-
hidden: false
|
|
743
|
+
hidden: false,
|
|
744
|
+
styles: ""
|
|
742
745
|
}
|
|
743
746
|
},
|
|
744
747
|
main: {
|
|
@@ -1161,49 +1164,6 @@ class Converter {
|
|
|
1161
1164
|
return field;
|
|
1162
1165
|
};
|
|
1163
1166
|
const updateFieldDefaultValue = (field) => {
|
|
1164
|
-
const defaultValue = {
|
|
1165
|
-
value: {
|
|
1166
|
-
is_found: false,
|
|
1167
|
-
value: "",
|
|
1168
|
-
sources: [
|
|
1169
|
-
{
|
|
1170
|
-
key: "OBJECT",
|
|
1171
|
-
props: {
|
|
1172
|
-
object: {
|
|
1173
|
-
key: "FORM_DATA",
|
|
1174
|
-
path: `$.${field.key}`
|
|
1175
|
-
}
|
|
1176
|
-
},
|
|
1177
|
-
value: "",
|
|
1178
|
-
validation: {
|
|
1179
|
-
is_valid: false,
|
|
1180
|
-
triggers: ["ON_INIT"],
|
|
1181
|
-
rules: [],
|
|
1182
|
-
actions: [
|
|
1183
|
-
{
|
|
1184
|
-
id: "1",
|
|
1185
|
-
key: "SET_FIELD_DEFAULT_VALUE",
|
|
1186
|
-
condition: "1",
|
|
1187
|
-
props: {
|
|
1188
|
-
value: {
|
|
1189
|
-
source: {
|
|
1190
|
-
key: "OBJECT",
|
|
1191
|
-
props: {
|
|
1192
|
-
object: {
|
|
1193
|
-
key: "FORM_DATA",
|
|
1194
|
-
path: `$.${field.key}`
|
|
1195
|
-
}
|
|
1196
|
-
}
|
|
1197
|
-
}
|
|
1198
|
-
}
|
|
1199
|
-
}
|
|
1200
|
-
}
|
|
1201
|
-
]
|
|
1202
|
-
}
|
|
1203
|
-
}
|
|
1204
|
-
]
|
|
1205
|
-
}
|
|
1206
|
-
};
|
|
1207
1167
|
if (field.isFormElement) {
|
|
1208
1168
|
if (checkObjectKeyExists(field, "defaultValue")) {
|
|
1209
1169
|
return field;
|
|
@@ -1212,7 +1172,48 @@ class Converter {
|
|
|
1212
1172
|
return field;
|
|
1213
1173
|
}
|
|
1214
1174
|
else if (!checkObjectPathExists(field, "default.value.sources")) {
|
|
1215
|
-
|
|
1175
|
+
const defaultValue = {
|
|
1176
|
+
is_found: false,
|
|
1177
|
+
value: "",
|
|
1178
|
+
sources: [
|
|
1179
|
+
{
|
|
1180
|
+
key: "OBJECT",
|
|
1181
|
+
props: {
|
|
1182
|
+
object: {
|
|
1183
|
+
key: "FORM_DATA",
|
|
1184
|
+
path: `$.${field.key}`
|
|
1185
|
+
}
|
|
1186
|
+
},
|
|
1187
|
+
value: "",
|
|
1188
|
+
validation: {
|
|
1189
|
+
is_valid: false,
|
|
1190
|
+
triggers: ["ON_INIT"],
|
|
1191
|
+
rules: [],
|
|
1192
|
+
actions: [
|
|
1193
|
+
{
|
|
1194
|
+
id: "1",
|
|
1195
|
+
key: "SET_FIELD_DEFAULT_VALUE",
|
|
1196
|
+
condition: "1",
|
|
1197
|
+
props: {
|
|
1198
|
+
value: {
|
|
1199
|
+
source: {
|
|
1200
|
+
key: "OBJECT",
|
|
1201
|
+
props: {
|
|
1202
|
+
object: {
|
|
1203
|
+
key: "FORM_DATA",
|
|
1204
|
+
path: `$.${field.key}`
|
|
1205
|
+
}
|
|
1206
|
+
}
|
|
1207
|
+
}
|
|
1208
|
+
}
|
|
1209
|
+
}
|
|
1210
|
+
}
|
|
1211
|
+
]
|
|
1212
|
+
}
|
|
1213
|
+
}
|
|
1214
|
+
]
|
|
1215
|
+
};
|
|
1216
|
+
field = setValueToObjectPath(field, "default.value", defaultValue);
|
|
1216
1217
|
return field;
|
|
1217
1218
|
}
|
|
1218
1219
|
delete field["defaultVal"];
|
|
@@ -1272,7 +1273,10 @@ class Converter {
|
|
|
1272
1273
|
field = formatOnFieldType(field);
|
|
1273
1274
|
field = updateFieldDisability(field);
|
|
1274
1275
|
fieldGroups = updateFormFieldGroups(fieldGroups, field);
|
|
1276
|
+
console.log("sadssadasdsdda");
|
|
1277
|
+
console.log(getObjectDeepCopy(field));
|
|
1275
1278
|
field = updateFieldDefaultValue(field);
|
|
1279
|
+
console.log(getObjectDeepCopy(field));
|
|
1276
1280
|
field = updateFieldValidators(field);
|
|
1277
1281
|
field = updateFieldResetButton(field);
|
|
1278
1282
|
field = updateFieldMessages(field);
|
|
@@ -2237,6 +2241,12 @@ var EActionKey;
|
|
|
2237
2241
|
(function (EActionKey) {
|
|
2238
2242
|
EActionKey["SET_VALUE"] = "SET_VALUE";
|
|
2239
2243
|
EActionKey["SET_FIELD_DEFAULT_VALUE"] = "SET_FIELD_DEFAULT_VALUE";
|
|
2244
|
+
EActionKey["SET_API_STATUS"] = "SET_API_STATUS";
|
|
2245
|
+
EActionKey["SET_API_HEADER_VALUE"] = "SET_API_HEADER_VALUE";
|
|
2246
|
+
EActionKey["SET_API_HEADER_VALIDITY"] = "SET_API_HEADER_VALIDITY";
|
|
2247
|
+
EActionKey["SET_API_BODY_VALUE"] = "SET_API_BODY_VALUE";
|
|
2248
|
+
EActionKey["SET_API_BODY_VALIDITY"] = "SET_API_BODY_VALIDITY";
|
|
2249
|
+
EActionKey["SET_FIELD_VALIDITY"] = "SET_FIELD_VALIDITY";
|
|
2240
2250
|
EActionKey["FIELD_MESSAGE_SHOW"] = "FIELD_MESSAGE_SHOW";
|
|
2241
2251
|
EActionKey["FIELD_MESSAGES_HIDE"] = "FIELD_MESSAGES_HIDE";
|
|
2242
2252
|
EActionKey["FIELD_ERROR_SHOW"] = "FIELD_ERROR_SHOW";
|
|
@@ -2359,6 +2369,33 @@ class Defaults {
|
|
|
2359
2369
|
return defaultValue;
|
|
2360
2370
|
});
|
|
2361
2371
|
}
|
|
2372
|
+
getFormFieldApiValue() {
|
|
2373
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2374
|
+
const apiConfig = this._field.default.api;
|
|
2375
|
+
const rules = apiConfig.rules;
|
|
2376
|
+
const actions = apiConfig.actions;
|
|
2377
|
+
const rulesMapping = new Rule(rules, {
|
|
2378
|
+
FIELD_CONFIG: this._field,
|
|
2379
|
+
FORM_FIELDS: this._formFields,
|
|
2380
|
+
FORM_DATA: this._formData,
|
|
2381
|
+
PREVIOUS_FORM_DATA: this._previousFormData,
|
|
2382
|
+
ALL_FORMS_DATA: this._allFormsData
|
|
2383
|
+
}).mapping();
|
|
2384
|
+
for (let action of actions) {
|
|
2385
|
+
const conditionEvaluation = new Condition(action.condition, rulesMapping).evaluate();
|
|
2386
|
+
if (conditionEvaluation) {
|
|
2387
|
+
const actions = new Action(action, rulesMapping, {
|
|
2388
|
+
FIELD_CONFIG: this._field,
|
|
2389
|
+
FORM_FIELDS: this._formFields,
|
|
2390
|
+
FORM_DATA: this._formData,
|
|
2391
|
+
PREVIOUS_FORM_DATA: this._previousFormData,
|
|
2392
|
+
ALL_FORMS_DATA: this._allFormsData
|
|
2393
|
+
}, this._takeAction);
|
|
2394
|
+
yield actions.execute();
|
|
2395
|
+
}
|
|
2396
|
+
}
|
|
2397
|
+
});
|
|
2398
|
+
}
|
|
2362
2399
|
getFormFieldOptions() {
|
|
2363
2400
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2364
2401
|
const optionsConfig = this._field.default.options;
|
|
@@ -2390,6 +2427,9 @@ class Defaults {
|
|
|
2390
2427
|
__decorate([
|
|
2391
2428
|
logMethod
|
|
2392
2429
|
], Defaults.prototype, "getFormFieldValue", null);
|
|
2430
|
+
__decorate([
|
|
2431
|
+
logMethod
|
|
2432
|
+
], Defaults.prototype, "getFormFieldApiValue", null);
|
|
2393
2433
|
__decorate([
|
|
2394
2434
|
logMethod
|
|
2395
2435
|
], Defaults.prototype, "getFormFieldOptions", null);
|
|
@@ -2521,6 +2561,16 @@ class KwikIDFormViewService {
|
|
|
2521
2561
|
value = yield defaults.getFormFieldValue();
|
|
2522
2562
|
}
|
|
2523
2563
|
}
|
|
2564
|
+
console.log("sdasgdjsgsadaghas");
|
|
2565
|
+
console.log("sdasgdjsgsadaghas1");
|
|
2566
|
+
if (checkObjectKeyExists(field, "default")) {
|
|
2567
|
+
console.log("sdasgdjsgsadaghas2");
|
|
2568
|
+
console.log(getObjectDeepCopy(field));
|
|
2569
|
+
if (checkObjectKeyExists(field.default, "api")) {
|
|
2570
|
+
console.log("sdasgdjsgsadaghas3");
|
|
2571
|
+
yield defaults.getFormFieldApiValue();
|
|
2572
|
+
}
|
|
2573
|
+
}
|
|
2524
2574
|
if (checkObjectKeyExists(field, "default")) {
|
|
2525
2575
|
if (checkObjectKeyExists(field.default, "options")) {
|
|
2526
2576
|
if (field.default.options.triggers.includes("ON_INIT")) {
|
|
@@ -2569,7 +2619,7 @@ class Apis {
|
|
|
2569
2619
|
});
|
|
2570
2620
|
}
|
|
2571
2621
|
setRequestBody() {
|
|
2572
|
-
var _a, _b, _c, _d;
|
|
2622
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2573
2623
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2574
2624
|
if (checkObjectKeyExists(this._request, "body")) {
|
|
2575
2625
|
if (checkObjectKeyExists(this._request.body, "params")) {
|
|
@@ -2601,6 +2651,21 @@ class Apis {
|
|
|
2601
2651
|
}
|
|
2602
2652
|
return this._object.API_CONFIG;
|
|
2603
2653
|
}
|
|
2654
|
+
else if (checkObjectKeyExists(this._request.body, "rules") &&
|
|
2655
|
+
checkObjectKeyExists(this._request.body, "actions")) {
|
|
2656
|
+
const triggers = (_f = (_e = this._request.body) === null || _e === void 0 ? void 0 : _e.triggers) !== null && _f !== void 0 ? _f : [];
|
|
2657
|
+
const rules = (_h = (_g = this._request.body) === null || _g === void 0 ? void 0 : _g.rules) !== null && _h !== void 0 ? _h : [];
|
|
2658
|
+
const actions = (_k = (_j = this._request.body) === null || _j === void 0 ? void 0 : _j.actions) !== null && _k !== void 0 ? _k : [];
|
|
2659
|
+
const rulesMapping = new Rule(rules, this._object).mapping();
|
|
2660
|
+
for (let action of actions) {
|
|
2661
|
+
const conditionEvaluation = new Condition(action.condition, rulesMapping).evaluate();
|
|
2662
|
+
if (conditionEvaluation) {
|
|
2663
|
+
const actions = new Action(action, rulesMapping, this._object, this._takeAction);
|
|
2664
|
+
yield actions.execute();
|
|
2665
|
+
}
|
|
2666
|
+
}
|
|
2667
|
+
return this._object.API_CONFIG;
|
|
2668
|
+
}
|
|
2604
2669
|
else {
|
|
2605
2670
|
return this._object.API_CONFIG;
|
|
2606
2671
|
}
|
|
@@ -2611,7 +2676,7 @@ class Apis {
|
|
|
2611
2676
|
});
|
|
2612
2677
|
}
|
|
2613
2678
|
validateRequestBody() {
|
|
2614
|
-
var _a, _b, _c, _d;
|
|
2679
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2615
2680
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2616
2681
|
if (checkObjectKeyExists(this._request, "body")) {
|
|
2617
2682
|
if (checkObjectKeyExists(this._request.body, "validation")) {
|
|
@@ -2630,6 +2695,21 @@ class Apis {
|
|
|
2630
2695
|
}
|
|
2631
2696
|
return this._object.API_CONFIG;
|
|
2632
2697
|
}
|
|
2698
|
+
else if (checkObjectPathExists(this._request.body, "rules") &&
|
|
2699
|
+
checkObjectPathExists(this._request.body, "actions")) {
|
|
2700
|
+
const triggers = (_f = (_e = this._request.body) === null || _e === void 0 ? void 0 : _e.triggers) !== null && _f !== void 0 ? _f : [];
|
|
2701
|
+
const rules = (_h = (_g = this._request.body) === null || _g === void 0 ? void 0 : _g.rules) !== null && _h !== void 0 ? _h : [];
|
|
2702
|
+
const actions = (_k = (_j = this._request.body) === null || _j === void 0 ? void 0 : _j.actions) !== null && _k !== void 0 ? _k : [];
|
|
2703
|
+
const rulesMapping = new Rule(rules, this._object).mapping();
|
|
2704
|
+
for (let action of actions) {
|
|
2705
|
+
const conditionSuccess = new Condition(action.condition, rulesMapping).evaluate();
|
|
2706
|
+
if (conditionSuccess) {
|
|
2707
|
+
const actions = new Action(action, rulesMapping, this._object, this._takeAction);
|
|
2708
|
+
yield actions.execute();
|
|
2709
|
+
}
|
|
2710
|
+
}
|
|
2711
|
+
return this._object.API_CONFIG;
|
|
2712
|
+
}
|
|
2633
2713
|
else {
|
|
2634
2714
|
this._object = setValueToObjectPath(this._object, "API_CONFIG.request.validation.body.is_valid", true);
|
|
2635
2715
|
return this._object.API_CONFIG;
|
|
@@ -2642,7 +2722,7 @@ class Apis {
|
|
|
2642
2722
|
});
|
|
2643
2723
|
}
|
|
2644
2724
|
setRequestHeaders() {
|
|
2645
|
-
var _a, _b, _c, _d;
|
|
2725
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2646
2726
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2647
2727
|
if (checkObjectKeyExists(this._request, "headers")) {
|
|
2648
2728
|
if (checkObjectKeyExists(this._request.headers, "params")) {
|
|
@@ -2674,6 +2754,21 @@ class Apis {
|
|
|
2674
2754
|
}
|
|
2675
2755
|
return this._object.API_CONFIG;
|
|
2676
2756
|
}
|
|
2757
|
+
else if (checkObjectKeyExists(this._request.headers, "rules") &&
|
|
2758
|
+
checkObjectKeyExists(this._request.headers, "actions")) {
|
|
2759
|
+
const triggers = (_f = (_e = this._request.headers) === null || _e === void 0 ? void 0 : _e.triggers) !== null && _f !== void 0 ? _f : [];
|
|
2760
|
+
const rules = (_h = (_g = this._request.headers) === null || _g === void 0 ? void 0 : _g.rules) !== null && _h !== void 0 ? _h : [];
|
|
2761
|
+
const actions = (_k = (_j = this._request.headers) === null || _j === void 0 ? void 0 : _j.actions) !== null && _k !== void 0 ? _k : [];
|
|
2762
|
+
const rulesMapping = new Rule(rules, this._object).mapping();
|
|
2763
|
+
for (let action of actions) {
|
|
2764
|
+
const conditionEvaluation = new Condition(action.condition, rulesMapping).evaluate();
|
|
2765
|
+
if (conditionEvaluation) {
|
|
2766
|
+
const actions = new Action(action, rulesMapping, this._object, this._takeAction);
|
|
2767
|
+
yield actions.execute();
|
|
2768
|
+
}
|
|
2769
|
+
}
|
|
2770
|
+
return this._object.API_CONFIG;
|
|
2771
|
+
}
|
|
2677
2772
|
else {
|
|
2678
2773
|
return this._object.API_CONFIG;
|
|
2679
2774
|
}
|
|
@@ -2684,7 +2779,7 @@ class Apis {
|
|
|
2684
2779
|
});
|
|
2685
2780
|
}
|
|
2686
2781
|
validateRequestHeaders() {
|
|
2687
|
-
var _a, _b, _c, _d;
|
|
2782
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
2688
2783
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2689
2784
|
const headers = this._request.headers;
|
|
2690
2785
|
if (checkObjectKeyExists(this._request, "headers")) {
|
|
@@ -2703,6 +2798,21 @@ class Apis {
|
|
|
2703
2798
|
}
|
|
2704
2799
|
return this._object.API_CONFIG;
|
|
2705
2800
|
}
|
|
2801
|
+
else if (checkObjectPathExists(this._request.headers, "rules") &&
|
|
2802
|
+
checkObjectPathExists(this._request.headers, "actions")) {
|
|
2803
|
+
const triggers = (_e = headers === null || headers === void 0 ? void 0 : headers.triggers) !== null && _e !== void 0 ? _e : [];
|
|
2804
|
+
const rules = (_f = headers === null || headers === void 0 ? void 0 : headers.rules) !== null && _f !== void 0 ? _f : [];
|
|
2805
|
+
const actions = (_h = (_g = headers) === null || _g === void 0 ? void 0 : _g.actions) !== null && _h !== void 0 ? _h : [];
|
|
2806
|
+
const rulesMapping = new Rule(rules, this._object).mapping();
|
|
2807
|
+
for (let action of actions) {
|
|
2808
|
+
const conditionSuccess = new Condition(action.condition, rulesMapping).evaluate();
|
|
2809
|
+
if (conditionSuccess) {
|
|
2810
|
+
const actions = new Action(action, rulesMapping, this._object, this._takeAction);
|
|
2811
|
+
yield actions.execute();
|
|
2812
|
+
}
|
|
2813
|
+
}
|
|
2814
|
+
return this._object.API_CONFIG;
|
|
2815
|
+
}
|
|
2706
2816
|
else {
|
|
2707
2817
|
this._object = setValueToObjectPath(this._object, "API_CONFIG.request.validation.headers.is_valid", true);
|
|
2708
2818
|
return this._object.API_CONFIG;
|
|
@@ -2715,7 +2825,7 @@ class Apis {
|
|
|
2715
2825
|
});
|
|
2716
2826
|
}
|
|
2717
2827
|
validateResponse() {
|
|
2718
|
-
var _a, _b, _c, _d;
|
|
2828
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
2719
2829
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2720
2830
|
if (checkObjectKeyExists(this._response, "validation")) {
|
|
2721
2831
|
const validation = this._response.validation;
|
|
@@ -2731,6 +2841,20 @@ class Apis {
|
|
|
2731
2841
|
}
|
|
2732
2842
|
}
|
|
2733
2843
|
}
|
|
2844
|
+
else if (checkObjectKeyExists(this._response, "rules") &&
|
|
2845
|
+
checkObjectKeyExists(this._response, "actions")) {
|
|
2846
|
+
const triggers = (_f = (_e = this._response) === null || _e === void 0 ? void 0 : _e.triggers) !== null && _f !== void 0 ? _f : [];
|
|
2847
|
+
const rules = (_h = (_g = this._response) === null || _g === void 0 ? void 0 : _g.rules) !== null && _h !== void 0 ? _h : [];
|
|
2848
|
+
const actions = (_k = (_j = this._response) === null || _j === void 0 ? void 0 : _j.actions) !== null && _k !== void 0 ? _k : [];
|
|
2849
|
+
const rulesMapping = new Rule(rules, this._object).mapping();
|
|
2850
|
+
for (let action of actions) {
|
|
2851
|
+
const conditionSuccess = new Condition(action.condition, rulesMapping).evaluate();
|
|
2852
|
+
if (conditionSuccess) {
|
|
2853
|
+
const actions = new Action(action, rulesMapping, this._object, this._takeAction);
|
|
2854
|
+
yield actions.execute();
|
|
2855
|
+
}
|
|
2856
|
+
}
|
|
2857
|
+
}
|
|
2734
2858
|
return this._object.API_CONFIG;
|
|
2735
2859
|
});
|
|
2736
2860
|
}
|
|
@@ -2799,6 +2923,11 @@ __decorate([
|
|
|
2799
2923
|
logMethod
|
|
2800
2924
|
], Tasks.prototype, "execute", null);
|
|
2801
2925
|
|
|
2926
|
+
var ETypeLogs;
|
|
2927
|
+
(function (ETypeLogs) {
|
|
2928
|
+
ETypeLogs["API"] = "API";
|
|
2929
|
+
})(ETypeLogs || (ETypeLogs = {}));
|
|
2930
|
+
|
|
2802
2931
|
class StyleSanitizerPipe {
|
|
2803
2932
|
constructor(sanitizer) {
|
|
2804
2933
|
this.sanitizer = sanitizer;
|
|
@@ -2832,6 +2961,7 @@ class KwikIDFormViewComponent {
|
|
|
2832
2961
|
this.getUnsavedDataState = new EventEmitter();
|
|
2833
2962
|
this.onClickSaveForm = new EventEmitter();
|
|
2834
2963
|
this.onClickApiCall = new EventEmitter();
|
|
2964
|
+
this.getLogs = new EventEmitter();
|
|
2835
2965
|
this.onActionShowPopupForm = new EventEmitter();
|
|
2836
2966
|
this.onClickFormFieldButton = new EventEmitter();
|
|
2837
2967
|
this.fieldGroups = {};
|
|
@@ -3640,7 +3770,7 @@ class KwikIDFormViewComponent {
|
|
|
3640
3770
|
});
|
|
3641
3771
|
}
|
|
3642
3772
|
executeApiCall(api, object) {
|
|
3643
|
-
var _a, _b, _c, _d, _e, _f, _g;
|
|
3773
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
3644
3774
|
return __awaiter(this, void 0, void 0, function* () {
|
|
3645
3775
|
const apis = new Apis(object, this.takeAction.bind(this));
|
|
3646
3776
|
api = yield apis.setUrl();
|
|
@@ -3658,12 +3788,13 @@ class KwikIDFormViewComponent {
|
|
|
3658
3788
|
resolve(api.request.url.props.mockedData);
|
|
3659
3789
|
}, 1000); // 1000 ms = 1 sec
|
|
3660
3790
|
});
|
|
3791
|
+
apiCallResponseStatusCode = (_b = (_a = api.request.url.props) === null || _a === void 0 ? void 0 : _a.statusCode) !== null && _b !== void 0 ? _b : 200; // Default Status Code for Mocked APIs
|
|
3661
3792
|
}
|
|
3662
3793
|
else {
|
|
3663
3794
|
const url = api.request.url.value;
|
|
3664
|
-
const method = (
|
|
3665
|
-
const headers = Object.assign({ "Content-Type": "application/json" }, (((
|
|
3666
|
-
const body = (
|
|
3795
|
+
const method = (_d = (_c = api.request) === null || _c === void 0 ? void 0 : _c.method) !== null && _d !== void 0 ? _d : "POST";
|
|
3796
|
+
const headers = Object.assign({ "Content-Type": "application/json" }, (((_f = (_e = api.request) === null || _e === void 0 ? void 0 : _e.headers) === null || _f === void 0 ? void 0 : _f.value) || {}));
|
|
3797
|
+
const body = (_j = (_h = (_g = api.request) === null || _g === void 0 ? void 0 : _g.body) === null || _h === void 0 ? void 0 : _h.value) !== null && _j !== void 0 ? _j : null;
|
|
3667
3798
|
if (method === "GET") {
|
|
3668
3799
|
try {
|
|
3669
3800
|
const response = yield fetch(url, {
|
|
@@ -3694,13 +3825,29 @@ class KwikIDFormViewComponent {
|
|
|
3694
3825
|
}
|
|
3695
3826
|
api.response = setValueToObjectPath(api.response, "value", apiCallResponse);
|
|
3696
3827
|
api.response = setValueToObjectPath(api.response, "status", apiCallResponseStatusCode);
|
|
3828
|
+
this.getLogs.emit({
|
|
3829
|
+
type: ETypeLogs.API,
|
|
3830
|
+
timestamp: new Date().getTime(),
|
|
3831
|
+
data: {
|
|
3832
|
+
request: api.request,
|
|
3833
|
+
response: api.response
|
|
3834
|
+
}
|
|
3835
|
+
});
|
|
3697
3836
|
}
|
|
3698
3837
|
return api;
|
|
3699
3838
|
});
|
|
3700
3839
|
}
|
|
3701
3840
|
isValidRequestHeadersAndBody(api) {
|
|
3702
|
-
|
|
3703
|
-
|
|
3841
|
+
var _a, _b;
|
|
3842
|
+
const bodyValidation = ((_a = api.request.body) === null || _a === void 0 ? void 0 : _a.validation) ||
|
|
3843
|
+
api.request.body;
|
|
3844
|
+
const headersValidation = ((_b = api.request.headers) === null || _b === void 0 ? void 0 : _b.validation) ||
|
|
3845
|
+
api.request.headers;
|
|
3846
|
+
if (!bodyValidation && !headersValidation) {
|
|
3847
|
+
return false;
|
|
3848
|
+
}
|
|
3849
|
+
return (((bodyValidation === null || bodyValidation === void 0 ? void 0 : bodyValidation.is_valid) || false) &&
|
|
3850
|
+
((headersValidation === null || headersValidation === void 0 ? void 0 : headersValidation.is_valid) || false));
|
|
3704
3851
|
}
|
|
3705
3852
|
showApiLoader() {
|
|
3706
3853
|
this.loaderService.show({
|
|
@@ -4109,6 +4256,109 @@ class KwikIDFormViewComponent {
|
|
|
4109
4256
|
this.previousFormData = source.object.PREVIOUS_FORM_DATA;
|
|
4110
4257
|
});
|
|
4111
4258
|
}
|
|
4259
|
+
setApiStatus(action, object) {
|
|
4260
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4261
|
+
const source = new Source(object);
|
|
4262
|
+
const sourceValue = action.props.status;
|
|
4263
|
+
source.setValueToSource({
|
|
4264
|
+
key: ESourceKey.OBJECT,
|
|
4265
|
+
props: {
|
|
4266
|
+
object: {
|
|
4267
|
+
key: "FIELD_CONFIG",
|
|
4268
|
+
path: "api.status.value"
|
|
4269
|
+
}
|
|
4270
|
+
}
|
|
4271
|
+
}, sourceValue);
|
|
4272
|
+
object.FIELD_CONFIG = source.object.FIELD_CONFIG;
|
|
4273
|
+
console.log("PRINT0", getObjectDeepCopy(source), sourceValue);
|
|
4274
|
+
});
|
|
4275
|
+
}
|
|
4276
|
+
setApiHeaderValue(action, object) {
|
|
4277
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4278
|
+
const source = new Source(object);
|
|
4279
|
+
const sourceValue = yield source.getValueFromSource(action.props.source);
|
|
4280
|
+
source.setValueToSource({
|
|
4281
|
+
key: ESourceKey.OBJECT,
|
|
4282
|
+
props: {
|
|
4283
|
+
object: {
|
|
4284
|
+
key: "API_CONFIG",
|
|
4285
|
+
path: `request.headers.value.${action.props.key}`
|
|
4286
|
+
}
|
|
4287
|
+
}
|
|
4288
|
+
}, sourceValue);
|
|
4289
|
+
object.API_CONFIG = source.object.API_CONFIG;
|
|
4290
|
+
console.log("PRINT1", getObjectDeepCopy(source), sourceValue);
|
|
4291
|
+
});
|
|
4292
|
+
}
|
|
4293
|
+
setApiHeaderValidity(action, object) {
|
|
4294
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4295
|
+
const source = new Source(object);
|
|
4296
|
+
const sourceValue = action.props.valid;
|
|
4297
|
+
source.setValueToSource({
|
|
4298
|
+
key: ESourceKey.OBJECT,
|
|
4299
|
+
props: {
|
|
4300
|
+
object: {
|
|
4301
|
+
key: "API_CONFIG",
|
|
4302
|
+
path: "request.headers.is_valid"
|
|
4303
|
+
}
|
|
4304
|
+
}
|
|
4305
|
+
}, sourceValue);
|
|
4306
|
+
object.API_CONFIG = source.object.API_CONFIG;
|
|
4307
|
+
console.log("PRINT2", getObjectDeepCopy(source), sourceValue);
|
|
4308
|
+
});
|
|
4309
|
+
}
|
|
4310
|
+
setApiBodyValue(action, object) {
|
|
4311
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4312
|
+
const source = new Source(object);
|
|
4313
|
+
const sourceValue = yield source.getValueFromSource(action.props.source);
|
|
4314
|
+
source.setValueToSource({
|
|
4315
|
+
key: ESourceKey.OBJECT,
|
|
4316
|
+
props: {
|
|
4317
|
+
object: {
|
|
4318
|
+
key: "API_CONFIG",
|
|
4319
|
+
path: `request.body.value.${action.props.key}`
|
|
4320
|
+
}
|
|
4321
|
+
}
|
|
4322
|
+
}, sourceValue);
|
|
4323
|
+
object.API_CONFIG = source.object.API_CONFIG;
|
|
4324
|
+
console.log("PRINT3", getObjectDeepCopy(source), sourceValue);
|
|
4325
|
+
});
|
|
4326
|
+
}
|
|
4327
|
+
setApiBodyValidity(action, object) {
|
|
4328
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4329
|
+
const source = new Source(object);
|
|
4330
|
+
const sourceValue = action.props.valid;
|
|
4331
|
+
source.setValueToSource({
|
|
4332
|
+
key: ESourceKey.OBJECT,
|
|
4333
|
+
props: {
|
|
4334
|
+
object: {
|
|
4335
|
+
key: "API_CONFIG",
|
|
4336
|
+
path: "request.body.is_valid"
|
|
4337
|
+
}
|
|
4338
|
+
}
|
|
4339
|
+
}, sourceValue);
|
|
4340
|
+
object.API_CONFIG = source.object.API_CONFIG;
|
|
4341
|
+
console.log("PRINT4", getObjectDeepCopy(source), sourceValue);
|
|
4342
|
+
});
|
|
4343
|
+
}
|
|
4344
|
+
setFieldValidity(action, object) {
|
|
4345
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4346
|
+
const source = new Source(object);
|
|
4347
|
+
console.log(getObjectDeepCopy(object));
|
|
4348
|
+
const sourceValue = action.props.valid;
|
|
4349
|
+
source.setValueToSource({
|
|
4350
|
+
key: ESourceKey.OBJECT,
|
|
4351
|
+
props: {
|
|
4352
|
+
object: {
|
|
4353
|
+
key: "FIELD_CONFIG",
|
|
4354
|
+
path: "validation.is_valid"
|
|
4355
|
+
}
|
|
4356
|
+
}
|
|
4357
|
+
}, sourceValue);
|
|
4358
|
+
object.API_CONFIG = source.object.API_CONFIG;
|
|
4359
|
+
console.log("PRINT5", getObjectDeepCopy(source), sourceValue);
|
|
4360
|
+
});
|
|
4361
|
+
}
|
|
4112
4362
|
setDropdownOptions(action, object) {
|
|
4113
4363
|
return __awaiter(this, void 0, void 0, function* () {
|
|
4114
4364
|
const source = new Source(object);
|
|
@@ -4480,9 +4730,27 @@ class KwikIDFormViewComponent {
|
|
|
4480
4730
|
case EActionKey.SET_FIELD_DEFAULT_VALUE:
|
|
4481
4731
|
yield this.setFieldDefaultValue(action, object);
|
|
4482
4732
|
break;
|
|
4733
|
+
case EActionKey.SET_API_STATUS:
|
|
4734
|
+
yield this.setApiStatus(action, object);
|
|
4735
|
+
break;
|
|
4736
|
+
case EActionKey.SET_API_HEADER_VALUE:
|
|
4737
|
+
yield this.setApiHeaderValue(action, object);
|
|
4738
|
+
break;
|
|
4739
|
+
case EActionKey.SET_API_HEADER_VALIDITY:
|
|
4740
|
+
yield this.setApiHeaderValidity(action, object);
|
|
4741
|
+
break;
|
|
4742
|
+
case EActionKey.SET_API_BODY_VALUE:
|
|
4743
|
+
yield this.setApiBodyValue(action, object);
|
|
4744
|
+
break;
|
|
4745
|
+
case EActionKey.SET_API_BODY_VALIDITY:
|
|
4746
|
+
yield this.setApiBodyValidity(action, object);
|
|
4747
|
+
break;
|
|
4483
4748
|
case EActionKey.SET_DROPDOWN_OPTIONS:
|
|
4484
4749
|
yield this.setDropdownOptions(action, object);
|
|
4485
4750
|
break;
|
|
4751
|
+
case EActionKey.SET_FIELD_VALIDITY:
|
|
4752
|
+
yield this.setFieldValidity(action, object);
|
|
4753
|
+
break;
|
|
4486
4754
|
case EActionKey.HANDLE_CONNECTED_ELEMENTS:
|
|
4487
4755
|
this.handleConnectedElements({ key: action.props.fieldKey }, "ON_ACTION");
|
|
4488
4756
|
break;
|
|
@@ -4574,7 +4842,7 @@ class KwikIDFormViewComponent {
|
|
|
4574
4842
|
}
|
|
4575
4843
|
}
|
|
4576
4844
|
/** @nocollapse */ KwikIDFormViewComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: KwikIDFormViewComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: KwikIDFormViewService }, { token: TuiPushService }, { token: TuiAlertService }, { token: TuiPreviewDialogService }, { token: TuiDialogService }, { token: i2.KwikUILoaderService }], target: i0.ɵɵFactoryTarget.Component });
|
|
4577
|
-
/** @nocollapse */ KwikIDFormViewComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: { formConfig: "formConfig", formData: "formData", isMobileView: "isMobileView", allFormsData: "allFormsData", userConfig: "userConfig", apiCallResponse: "apiCallResponse", buttonClickResponse: "buttonClickResponse", popupFormCallback: "popupFormCallback" }, outputs: { onClickGoBack: "onClickGoBack", onClickViewForms: "onClickViewForms", getUnsavedDataState: "getUnsavedDataState", onClickSaveForm: "onClickSaveForm", onClickApiCall: "onClickApiCall", onActionShowPopupForm: "onActionShowPopupForm", onClickFormFieldButton: "onClickFormFieldButton" }, providers: [KwikIDFormViewService], viewQueries: [{ propertyName: "preview", first: true, predicate: ["preview"], descendants: true }, { propertyName: "dialog", first: true, predicate: ["dialog"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"kwikid-form-container\"\n *ngIf=\"!loading\"\n>\n <div\n id=\"uf-form-fields-header-container\"\n *ngIf=\"\n !formConfig.properties?.header?.title?.hidden ||\n !formConfig.properties?.header?.steps?.hidden ||\n !formConfig.properties?.header?.backButton?.hidden\n \"\n >\n <img\n id=\"uf-header-logo\"\n *ngIf=\"!formConfig.properties?.header?.logo?.hidden && isMobileView\"\n [src]=\"formConfig.properties?.header?.logo?.src\"\n [alt]=\"formConfig.properties?.header?.logo?.alt\"\n />\n <div id=\"uf-form-fields-header-main\">\n <div id=\"uf-form-fields-header-left\">\n <kwikui-button\n *ngIf=\"\n !formConfig.properties?.header.backButton.hidden && isMobileView\n \"\n [disabled]=\"backButton.disabled\"\n [showLoader]=\"backButton.showLoader\"\n appearance=\"mono\"\n icon=\"tuiIconArrowLeft\"\n shape=\"rounded\"\n (onClick)=\"\n handleOnClickGoBack(\n $event,\n formConfig.properties?.header.backButton.mode\n )\n \"\n ></kwikui-button>\n </div>\n <div id=\"uf-form-fields-header-right\">\n <div\n id=\"uf-form-fields-title\"\n *ngIf=\"!formConfig.properties?.header.title.hidden\"\n >{{ formConfig.properties?.header.title.label }}</div\n >\n <div\n id=\"uf-form-fields-steps\"\n *ngIf=\"!formConfig.properties?.header.steps.hidden\"\n >Step {{ formConfig.sequenceNo }} of\n {{ formConfig.formsListLength }}</div\n >\n </div>\n </div>\n <hr\n *ngIf=\"\n !formConfig.properties?.header.title.hidden ||\n !formConfig.properties?.header.steps.hidden ||\n !formConfig.properties?.header.backButton.hidden\n \"\n />\n </div>\n <form\n class=\"kwikid-form show\"\n [style]=\"formConfig.properties?.main?.styles | styleSanitizer\"\n [formGroup]=\"formGroup\"\n >\n <ng-container\n *ngFor=\"\n let field of formFields;\n let i = index;\n trackBy: getUniqueIdentifier\n \"\n >\n <ng-container [ngSwitch]=\"field.type\">\n <!-- HTML Content -->\n <ng-container *ngSwitchCase=\"'html'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <div [innerHtml]=\"field.html | kwikuiSafeHtml\"></div>\n </div>\n </ng-container>\n <!-- Form Title -->\n <ng-container *ngSwitchCase=\"'title'\">\n <div\n class=\"title\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n [class.hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <div>\n {{ field.label }}\n </div>\n <kwikui-button\n *ngIf=\"field?.reset\"\n appearance=\"whiteblock\"\n size=\"s\"\n label=\"Reset\"\n (onClick)=\"handleOnClickResetFormFields($event, field)\"\n ></kwikui-button>\n </div>\n </ng-container>\n <!-- Button -->\n <ng-container *ngSwitchCase=\"'button'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-button\n [appearance]=\"field?.properties?.appearance ?? 'primary'\"\n [class]=\"field?.properties?.class\"\n [disabled]=\"field?.disabled\"\n [icon]=\"field?.properties?.icon\"\n [iconRight]=\"field?.properties?.iconRight\"\n [id]=\"field?.key\"\n [label]=\"field?.label\"\n [shape]=\"field?.properties?.shape\"\n [showLoader]=\"field?.properties?.loading ?? false\"\n [size]=\"field?.properties?.size\"\n [styles]=\"field?.properties?.styles\"\n [type]=\"'button'\"\n (onClick)=\"handleOnClickFormFieldButton(field)\"\n ></kwikui-button>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Text -->\n <ng-container *ngSwitchCase=\"'text'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input\n [case]=\"field?.properties?.case\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [type]=\"'text'\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Email -->\n <ng-container *ngSwitchCase=\"'email'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-email\n [case]=\"field?.properties?.case\"\n [disabled]=\"field?.disabled\"\n [domains]=\"field?.properties?.domains\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-email>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Password -->\n <ng-container *ngSwitchCase=\"'password'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-password\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [hintContent]=\"field?.properties?.hintContent\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-password>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Textarea -->\n <ng-container *ngSwitchCase=\"'textarea'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-textarea\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-textarea>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Checkbox -->\n <ng-container *ngSwitchCase=\"'checkbox'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-checkbox\n [contentAlign]=\"field?.properties?.contentAlign ?? 'left'\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.properties?.placeholder\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size ?? 'l'\"\n [validators]=\"field?.validators\"\n [variant]=\"field?.properties?.variant ?? 'block'\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-checkbox>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Number -->\n <ng-container *ngSwitchCase=\"'number'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-number\n [decimal]=\"field?.properties?.decimal\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [min]=\"field?.properties?.min\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix ?? ''\"\n [precision]=\"field?.properties?.precision\"\n [prefix]=\"field?.properties?.prefix ?? ''\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-number>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Date -->\n <ng-container *ngSwitchCase=\"'date'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-date\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [maxCalculatedFromToday]=\"\n field?.properties?.maxCalculatedFromToday\n \"\n [min]=\"field?.properties?.min\"\n [minCalculatedFromToday]=\"\n field?.properties?.minCalculatedFromToday\n \"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-date>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Phone -->\n <ng-container *ngSwitchCase=\"'phone'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-phone\n [countryCode]=\"field?.properties?.countryCode\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [phoneMaskAfterCountryCode]=\"\n field?.properties?.phoneMaskAfterCountryCode\n \"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [removeCountryCodeFromValue]=\"\n field?.properties?.removeCountryCodeFromValue\n \"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-phone>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Radio -->\n <ng-container *ngSwitchCase=\"'radio'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n [tuiLabel]=\"labelTemplate\"\n style=\"min-height: auto; padding: 0px 0.5rem\"\n >\n <kwikui-input-radio\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [items]=\"field?.options\"\n [label]=\"field?.label\"\n [orientation]=\"field?.properties?.orientation\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-radio>\n </label>\n <ng-template #labelTemplate>\n <p\n class=\"tui-space_bottom-2\"\n [hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <b>\n {{ field.label }}\n <span *ngIf=\"field.validators?.required\">*</span>\n </b>\n </p>\n </ng-template>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Dropdown -->\n <ng-container *ngSwitchCase=\"'select'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-select\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [options]=\"field.options\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [searchable]=\"field?.properties?.searchable\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-select>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Slider -->\n <ng-container *ngSwitchCase=\"'slider'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-slider\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [min]=\"field?.properties?.min\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [quantum]=\"field?.properties?.quantum\"\n [size]=\"field?.properties?.size\"\n [steps]=\"field?.properties?.steps\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-slider>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- API Call -->\n <ng-container *ngSwitchCase=\"'api'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-button-api-call\n [apiStatus]=\"field?.api?.status?.value\"\n [class]=\"field?.class\"\n [disabled]=\"field?.disabled\"\n [id]=\"field.key\"\n [label]=\"field?.api?.status?.labels[field?.api?.status?.value]\"\n [showLoader]=\"field?.disabled === 'loading'\"\n styles=\"width: fit-content\"\n (onClick)=\"handleOnClickApiCall($event)\"\n ></kwikui-button-api-call>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Mobile OTP -->\n <ng-container *ngSwitchCase=\"'otp'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-otp\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [mask]=\"field?.properties?.mask\"\n [mode]=\"field?.properties?.mode\"\n [otpLength]=\"field?.properties?.otpLength\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-otp>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Aadhaar Number -->\n <ng-container *ngSwitchCase=\"'aadhaar-number'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-aadhaar\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [mask]=\"field?.properties?.mask\"\n [placeholder]=\"field?.placeholder\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-aadhaar>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Preview Image -->\n <ng-container *ngSwitchCase=\"'image'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-image\n [altText]=\"field?.properties?.altText\"\n [class]=\"field?.properties?.class\"\n [html]=\"field?.properties?.html\"\n [id]=\"field.key\"\n [imageSrc]=\"field?.default?.value?.value ?? ''\"\n [imageType]=\"field?.properties?.imageType\"\n [loadingType]=\"field?.properties?.loadingType\"\n [styles]=\"field?.properties?.styles\"\n ></kwikui-image>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- File Upload -->\n <ng-container *ngSwitchCase=\"'file'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n [tuiLabel]=\"labelTemplate\"\n style=\"min-height: auto\"\n >\n <kwikui-input-files\n [accept]=\"field?.properties?.accept\"\n [class]=\"field?.properties?.class\"\n [disabled]=\"field?.disabled\"\n [files]=\"files[field.key]\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field?.key\"\n [label]=\"field?.properties?.label\"\n [link]=\"field?.properties?.link\"\n [maxFileSize]=\"field?.properties?.maxFileSize\"\n [multiple]=\"field?.properties?.multiple\"\n [setFileTypesToForm]=\"['NORMAL']\"\n [styles]=\"field?.properties?.styles\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValueFile($event)\"\n (getRemovedFile)=\"handleRemovedFile($event)\"\n ></kwikui-input-files>\n </label>\n <ng-template #labelTemplate>\n <p\n style=\"padding: 0px 0.25rem; margin-bottom: 0.25rem\"\n [hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <b>\n {{ field.label }}\n <span *ngIf=\"field.validators?.required\">*</span>\n </b>\n </p>\n </ng-template>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Camera Capture -->\n <ng-container *ngSwitchCase=\"'capture'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n *ngIf=\"\n field?.label !== '' &&\n field?.label !== undefined &&\n field?.label !== null\n \"\n style=\"min-height: auto\"\n >\n <p\n *ngIf=\"field?.label !== ''\"\n style=\"padding: 0px 0.25rem; margin-bottom: 0.5rem\"\n [hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <b>\n {{ field.label }}\n <span *ngIf=\"field.validators?.required\">*</span>\n </b>\n </p>\n </label>\n <kwikui-input-camera\n [buttonText]=\"field?.properties?.buttonText\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [icon]=\"field?.properties?.icon\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [mediaFiles]=\"mediaFiles[field.key]\"\n [properties]=\"field?.properties\"\n [showMediaFiles]=\"field?.properties?.showMediaFiles\"\n [type]=\"'CAPTURE'\"\n [validators]=\"field?.validators\"\n (onClick)=\"handleOnClickInputCamera($event, field)\"\n (getRemovedFile)=\"handleOnClickGetRemovedMediaFile($event)\"\n ></kwikui-input-camera>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Star Rating -->\n <ng-container *ngSwitchCase=\"'star-rating'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n [tuiLabel]=\"labelTemplate\"\n style=\"min-height: auto; padding: 0px 0.5rem\"\n >\n <kwikui-star-rating\n [color]=\"field?.properties?.color\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [icon]=\"field?.properties?.icon\"\n [iconMarked]=\"field?.properties?.iconMarked\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [min]=\"field?.properties?.min\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-star-rating>\n </label>\n <ng-template #labelTemplate>\n <p>\n <b\n >{{ field?.properties?.placeholder }}\n <span *ngIf=\"field.validators?.required\">*</span></b\n >\n </p>\n </ng-template>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n </ng-container>\n </ng-container>\n </form>\n <div\n class=\"kwikid-form-buttons\"\n *ngIf=\"\n !formConfig.properties.footer.viewFormsButton.hidden ||\n !formConfig.properties.footer.saveButton.hidden\n \"\n >\n <kwikui-button\n *ngIf=\"\n !formConfig.properties.footer.viewFormsButton.hidden && isMobileView\n \"\n [appearance]=\"'secondary'\"\n [disabled]=\"viewFormsButton.disabled\"\n [label]=\"formConfig.properties.footer.viewFormsButton.label\"\n [showLoader]=\"viewFormsButton.showLoader\"\n [styles]=\"'width: 100%'\"\n (onClick)=\"handleOnClickViewForms($event)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"!formConfig.properties.footer.saveButton.hidden\"\n [disabled]=\"saveFormButton.disabled\"\n [label]=\"formConfig.properties.footer.saveButton.label\"\n [showLoader]=\"saveFormButton.showLoader\"\n [styles]=\"'width: 100%'\"\n (onClick)=\"handleOnClickSaveForm($event)\"\n ></kwikui-button>\n </div>\n</div>\n<div\n class=\"kwikid-form-container-loading\"\n *ngIf=\"loading\"\n>\n <div\n *ngFor=\"let item of [].constructor(7); let i = index\"\n class=\"large-wrapper tui-skeleton tui-skeleton_rounded\"\n >\n </div>\n</div>\n\n<kwikui-loader></kwikui-loader>\n\n<tui-push\n id=\"field-error-notification\"\n *tuiPush=\"showErrorNotification\"\n heading=\"Missing/Incorrect Fields!\"\n type=\"Error\"\n (close)=\"toggleErrorNotification(false)\"\n>\n <tui-svg\n src=\"tuiIconXCircle\"\n style=\"color: #fff !important\"\n >\n </tui-svg>\n</tui-push>\n\n<ng-template\n #preview\n let-preview\n>\n <tui-preview\n [rotatable]=\"false\"\n [zoomable]=\"false\"\n class=\"preview-container\"\n >\n <tui-preview-title *ngIf=\"previewProperties.title !== ''\">{{\n previewProperties.title\n }}</tui-preview-title>\n\n <ng-container *ngIf=\"!previewProperties.unavailable\">\n <div\n *ngIf=\"previewProperties?.html?.before !== ''\"\n class=\"preview-html preview-html-before\"\n [style]=\"previewProperties?.html?.beforeStyles\"\n [innerHtml]=\"previewProperties.html.before | kwikuiSafeHtml\"\n ></div>\n\n <!-- Content within the iframe -->\n <div\n class=\"preview-iframe-content\"\n [style]=\"previewProperties?.iframe?.containerStyles\"\n *ngIf=\"previewProperties.iframe.src !== ''\"\n >\n <!-- Your HTML content here -->\n <iframe\n [src]=\"previewProperties.iframe.src | kwikuiSafeUrl\"\n frameborder=\"0\"\n allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\"\n allowfullscreen\n [title]=\"previewProperties.iframe.title\"\n class=\"preview-iframe\"\n scrolling=\"auto\"\n ></iframe>\n </div>\n\n <div\n *ngIf=\"previewProperties?.html?.after !== ''\"\n class=\"preview-html preview-html-after\"\n [style]=\"previewProperties?.html?.afterStyles\"\n [innerHtml]=\"previewProperties.html.after | kwikuiSafeHtml\"\n ></div>\n </ng-container>\n\n <ng-container *ngIf=\"previewProperties.unavailable\">\n <div class=\"preview-unavailable\">\n <tui-svg\n src=\"tuiIconFileLarge\"\n class=\"t-icon\"\n ></tui-svg>\n <div>Preview unavailable</div>\n </div>\n </ng-container>\n\n <button\n tuiIconButton\n tuiPreviewAction\n icon=\"tuiIconCloseLarge\"\n title=\"Close\"\n type=\"button\"\n (click)=\"preview.complete()\"\n ></button>\n </tui-preview>\n</ng-template>\n\n<ng-template\n #dialog\n let-dialog\n>\n <div class=\"preview-container\">\n <ng-container *ngIf=\"!previewProperties.unavailable\">\n <div\n *ngIf=\"previewProperties?.html?.before !== ''\"\n class=\"preview-html preview-html-before\"\n [style]=\"previewProperties?.html?.beforeStyles\"\n [innerHtml]=\"previewProperties.html.before | kwikuiSafeHtml\"\n ></div>\n\n <!-- Content within the iframe -->\n <div\n class=\"preview-iframe-content\"\n [style]=\"previewProperties?.iframe?.containerStyles\"\n *ngIf=\"previewProperties.iframe.src !== ''\"\n >\n <!-- Your HTML content here -->\n <iframe\n [src]=\"previewProperties.iframe.src | kwikuiSafeUrl\"\n frameborder=\"0\"\n allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\"\n allowfullscreen\n [title]=\"previewProperties.iframe.title\"\n class=\"preview-iframe\"\n scrolling=\"auto\"\n ></iframe>\n </div>\n\n <div\n *ngIf=\"previewProperties?.html?.after !== ''\"\n class=\"preview-html preview-html-after\"\n [style]=\"previewProperties?.html?.afterStyles\"\n [innerHtml]=\"previewProperties.html.after | kwikuiSafeHtml\"\n ></div>\n </ng-container>\n\n <ng-container *ngIf=\"previewProperties.unavailable\">\n <div class=\"preview-unavailable\">\n <tui-svg\n src=\"tuiIconFileLarge\"\n class=\"t-icon\"\n ></tui-svg>\n <div>Preview unavailable</div>\n </div>\n </ng-container>\n </div>\n</ng-template>\n\n<div\n id=\"kwikid-camera-container\"\n *ngIf=\"isShowCameraCapture\"\n>\n <div\n id=\"kwikid-camera-wrapper\"\n [class.fullscreen]=\"isShowCameraFullscreen\"\n >\n <kwikid-camera\n [type]=\"'CAPTURE'\"\n [image]=\"cameraCaptureImage\"\n [config]=\"cameraCaptureConfig\"\n (getImage)=\"handleGetImage($event)\"\n (onClickSave)=\"handleOnClickSaveCameraCapture($event)\"\n >\n <ng-container slot=\"header\">\n <div style=\"display: flex; width: 100%; max-width: 100%; padding: 0rem\">\n <div style=\"flex: 1; text-align: left\"> </div>\n <kwikui-button\n *ngIf=\"cameraCaptureConfig?.header?.title !== ''\"\n appearance=\"whiteblock\"\n [label]=\"cameraCaptureConfig?.header?.title\"\n shape=\"rounded\"\n style=\"\n flex: 1;\n width: 100%;\n min-width: max-content;\n text-align: center;\n margin: auto;\n \"\n size=\"s\"\n ></kwikui-button>\n <div\n style=\"\n flex: 1;\n text-align: right;\n display: flex;\n justify-content: flex-end;\n gap: 1rem;\n \"\n >\n <kwikui-button\n *ngIf=\"cameraCaptureConfig?.header?.isExpand\"\n id=\"kwikid-camera-header-enlarge-button\"\n appearance=\"whiteblock\"\n [icon]=\"\n isShowCameraFullscreen ? 'tuiIconMinimize2' : 'tuiIconMaximize2'\n \"\n shape=\"rounded\"\n size=\"s\"\n (click)=\"isShowCameraFullscreen = !isShowCameraFullscreen\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"cameraCaptureConfig?.header?.isClose\"\n id=\"kwikid-camera-header-close-button\"\n appearance=\"whiteblock\"\n icon=\"tuiIconCloseLarge\"\n shape=\"rounded\"\n size=\"s\"\n (click)=\"handleOnClickCloseCamera($event)\"\n ></kwikui-button>\n </div>\n </div>\n </ng-container>\n </kwikid-camera>\n </div>\n</div>\n", styles: [".kwikid-form-container{width:100%;height:100%;margin:0 auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center}.kwikid-form.show{width:100%;height:100%;padding:1rem;overflow-y:auto;display:flex;flex-direction:column;align-content:center;justify-content:flex-start;align-items:stretch}.kwikid-form.show>*:not(:last-child){margin-bottom:1rem}.kwikid-form-buttons{width:100%;bottom:0px;padding:1rem;display:flex;flex-direction:row;align-content:center;justify-content:center;align-items:center}.kwikid-form-buttons>*:not(:last-child){margin-right:1rem}.kwikid-form-buttons *{flex-grow:1}#uf-form-fields-header-container{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:flex-start;padding:1rem 1rem 0}#uf-form-fields-header-container>*:not(:last-child){margin-bottom:.5rem}#uf-form-fields-header-container #uf-header-logo{width:-moz-fit-content;width:fit-content;height:50px}#uf-form-fields-header-container #uf-form-fields-header-main{display:flex;flex-direction:row;align-content:center;justify-content:flex-start;align-items:center;width:100%}#uf-form-fields-header-container #uf-form-fields-header-main>*:not(:last-child){margin-right:.25rem}#uf-form-fields-header-container #uf-form-fields-header-main #uf-form-fields-header-right{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:flex-start}#uf-form-fields-header-container #uf-form-fields-header-main #uf-form-fields-header-right>*{margin-bottom:.5rem}#uf-form-fields-header-container hr{width:100%}#uf-form-fields-title{color:#000;font-size:1.75em;font-weight:bold}#uf-form-fields-steps{color:var(--color-on-secondary-container);font-size:1rem}.title{border-left:.25rem solid var(--tui-primary);padding:.75rem;font-size:1.4em;font-weight:bold;background-color:var(--tui-secondary);display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center}.title>*:not(:last-child){margin-right:.5rem}.title:not(:first-child){margin-top:.5rem}.title.hidden{display:none}.large-wrapper{width:100%;height:60px}.large-wrapper:first-child{margin-bottom:auto}.large-wrapper:last-child{margin-top:auto}.kwikid-form-container-loading{width:100%;height:100%;margin:0 auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;padding:1rem}.kwikid-form-container-loading>* :not(:last-child){margin-bottom:1rem}#field-error-notification{background-color:var(--tui-error-fill);color:#fff!important}#field-error-notification .t-top{color:#fff!important}#field-error-notification .t-close{color:#fff!important}.preview-container{display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;align-content:center;height:calc(100vh - 3rem)}.preview-container>*:not(:last-child){margin-bottom:1rem}.preview-container .preview-html{flex-grow:1}.preview-container .preview-iframe-content{height:100%;flex-grow:1}.preview-container .preview-iframe-content .preview-iframe{width:100%;height:100%}.preview-container .preview-unavailable{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:center;color:#fff;font-size:1.2rem;top:50%;left:50%;width:100%;height:100vh}.preview-container .preview-unavailable>*:not(:last-child){margin-bottom:1rem}#kwikid-camera-container{width:100%;height:100%;position:fixed;top:50%;left:50%;background-color:#0000008f;transform:translate(-50%,-50%);z-index:100}#kwikid-camera-container #kwikid-camera-wrapper{width:min(80%);height:max(85%);box-shadow:#0000008f 0 22px 70px 4px;overflow:hidden;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);border-radius:1rem;background-color:#000;transition:5s linear ease}#kwikid-camera-container #kwikid-camera-wrapper.fullscreen{width:100%;height:100%;border-radius:0;transition:5s linear ease}@media only screen and (max-width: 600px){#kwikid-camera-container #kwikid-camera-wrapper{width:100%;height:100%;border-radius:0;transition:5s linear ease}#kwikid-camera-container #kwikid-camera-wrapper #kwikid-camera-header-enlarge-button{display:none}}\n", "::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i2.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }, { type: i2.KwikUIMessagesComponent, selector: "kwikui-messages", inputs: ["id", "messages"] }, { type: i2.KwikUIInputComponent, selector: "kwikui-input", inputs: ["case", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "type", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputEmailComponent, selector: "kwikui-input-email", inputs: ["case", "disabled", "domains", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputPasswordComponent, selector: "kwikui-input-password", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUITextareaComponent, selector: "kwikui-textarea", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "placeholder", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUICheckboxComponent, selector: "kwikui-checkbox", inputs: ["contentAlign", "disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "placeholder", "properties", "size", "validators", "variant"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputNumberComponent, selector: "kwikui-input-number", inputs: ["decimal", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "min", "placeholder", "postfix", "precision", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputDateComponent, selector: "kwikui-input-date", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "maxCalculatedFromToday", "min", "minCalculatedFromToday", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputPhoneComponent, selector: "kwikui-input-phone", inputs: ["countryCode", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "phoneMaskAfterCountryCode", "placeholder", "postfix", "prefix", "properties", "removeCountryCodeFromValue", "size", "validators"], outputs: ["getKeyValue"] }, { type: i3.TuiLabelComponent, selector: "label[tuiLabel]", inputs: ["tuiLabel", "context"] }, { type: i2.KwikUIInputRadioComponent, selector: "kwikui-input-radio", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "items", "label", "orientation", "placeholder", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputSelectComponent, selector: "kwikui-input-select", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "options", "placeholder", "properties", "searchable", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputSliderComponent, selector: "kwikui-input-slider", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "min", "placeholder", "postfix", "prefix", "properties", "quantum", "size", "steps", "type", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIButtonApiCallComponent, selector: "kwikui-button-api-call", inputs: ["apiStatus", "class", "disabled", "id", "label", "shape", "showLoader", "size", "styles"], outputs: ["onClick"] }, { type: i2.KwikUIInputOtpComponent, selector: "kwikui-input-otp", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "mask", "mode", "otpLength", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputAadhaarComponent, selector: "kwikui-input-aadhaar", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "mask", "placeholder", "properties", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIImageComponent, selector: "kwikui-image", inputs: ["altText", "class", "html", "id", "imageSrc", "imageType", "loadingType", "styles"], outputs: ["onClick"] }, { type: i2.KwikUIInputFilesComponent, selector: "kwikui-input-files", inputs: ["accept", "class", "disabled", "files", "formControl", "formControlName", "icon", "id", "label", "link", "maxFileSize", "multiple", "setFileTypesToForm", "showAddedFiles", "size", "styles", "validators"], outputs: ["getKeyValue", "getRemovedFile"] }, { type: i4.KwikUIInputCameraComponent, selector: "kwikui-input-camera", inputs: ["buttonText", "disabled", "focus", "formControl", "formControlName", "icon", "id", "invalid", "mediaFiles", "properties", "showMediaFiles", "size", "type", "validators"], outputs: ["onClick", "getRemovedFile"] }, { type: i2.KwikUIStarRatingComponent, selector: "kwikui-star-rating", inputs: ["color", "disabled", "focus", "formControl", "formControlName", "icon", "iconMarked", "id", "invalid", "label", "max", "min", "placeholder", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUILoaderComponent, selector: "kwikui-loader" }, { type: i5.TuiPushComponent, selector: "tui-push", inputs: ["heading", "type", "timestamp"], outputs: ["close"] }, { type: i3.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }, { type: i6.TuiPreviewComponent, selector: "tui-preview", inputs: ["zoomable", "rotatable"] }, { type: i6.TuiPreviewTitleComponent, selector: "tui-preview-title" }, { type: i3.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { type: i4.KwikIDCameraComponent, selector: "kwikid-camera", inputs: ["type", "config", "data", "image"], outputs: ["getImage", "onClickSave"] }], directives: [{ type: i3$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i3$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i3$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i3$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3$2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i3$2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i3$1.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i5.TuiPushAlertDirective, selector: "[tuiPush]", inputs: ["tuiPush"] }, { type: i5.TuiPushDirective, selector: "tui-push" }, { type: i6.TuiPreviewActionDirective, selector: "[tuiPreviewAction]" }], pipes: { "styleSanitizer": StyleSanitizerPipe, "kwikuiSafeHtml": i2.KwikUISafeHtmlPipe, "kwikuiSafeUrl": i2.KwikUISafeUrlPipe } });
|
|
4845
|
+
/** @nocollapse */ KwikIDFormViewComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: { formConfig: "formConfig", formData: "formData", isMobileView: "isMobileView", allFormsData: "allFormsData", userConfig: "userConfig", apiCallResponse: "apiCallResponse", buttonClickResponse: "buttonClickResponse", popupFormCallback: "popupFormCallback" }, outputs: { onClickGoBack: "onClickGoBack", onClickViewForms: "onClickViewForms", getUnsavedDataState: "getUnsavedDataState", onClickSaveForm: "onClickSaveForm", onClickApiCall: "onClickApiCall", getLogs: "getLogs", onActionShowPopupForm: "onActionShowPopupForm", onClickFormFieldButton: "onClickFormFieldButton" }, providers: [KwikIDFormViewService], viewQueries: [{ propertyName: "preview", first: true, predicate: ["preview"], descendants: true }, { propertyName: "dialog", first: true, predicate: ["dialog"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"kwikid-form-container\"\n *ngIf=\"!loading\"\n>\n <div\n id=\"uf-form-fields-header-container\"\n *ngIf=\"\n !formConfig.properties?.header?.title?.hidden ||\n !formConfig.properties?.header?.logo?.hidden ||\n !formConfig.properties?.header?.steps?.hidden ||\n !formConfig.properties?.header?.backButton?.hidden\n \"\n >\n <img\n id=\"uf-header-logo\"\n *ngIf=\"!formConfig.properties?.header?.logo?.hidden && isMobileView\"\n [src]=\"formConfig.properties?.header?.logo?.src\"\n [alt]=\"formConfig.properties?.header?.logo?.alt\"\n [style]=\"\n formConfig.properties?.header?.logo?.styles ?? '' | styleSanitizer\n \"\n />\n <div id=\"uf-form-fields-header-main\">\n <div id=\"uf-form-fields-header-left\">\n <kwikui-button\n *ngIf=\"\n !formConfig.properties?.header.backButton.hidden && isMobileView\n \"\n [disabled]=\"backButton.disabled\"\n [showLoader]=\"backButton.showLoader\"\n appearance=\"mono\"\n icon=\"tuiIconArrowLeft\"\n shape=\"rounded\"\n (onClick)=\"\n handleOnClickGoBack(\n $event,\n formConfig.properties?.header.backButton.mode\n )\n \"\n ></kwikui-button>\n </div>\n <div id=\"uf-form-fields-header-right\">\n <div\n id=\"uf-form-fields-title\"\n *ngIf=\"!formConfig.properties?.header.title.hidden\"\n >{{ formConfig.properties?.header.title.label }}</div\n >\n <div\n id=\"uf-form-fields-steps\"\n *ngIf=\"!formConfig.properties?.header.steps.hidden\"\n >\n Step {{ formConfig.sequenceNo }} of {{ formConfig.formsListLength }}\n </div>\n </div>\n </div>\n <hr\n *ngIf=\"\n !formConfig.properties?.header.title.hidden ||\n !formConfig.properties?.header.steps.hidden ||\n !formConfig.properties?.header.backButton.hidden\n \"\n />\n </div>\n <form\n class=\"kwikid-form show\"\n [style]=\"formConfig.properties?.main?.styles ?? '' | styleSanitizer\"\n [formGroup]=\"formGroup\"\n >\n <ng-container\n *ngFor=\"\n let field of formFields;\n let i = index;\n trackBy: getUniqueIdentifier\n \"\n >\n <ng-container [ngSwitch]=\"field.type\">\n <!-- HTML Content -->\n <ng-container *ngSwitchCase=\"'html'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <div [innerHtml]=\"field.html | kwikuiSafeHtml\"></div>\n </div>\n </ng-container>\n <!-- Form Title -->\n <ng-container *ngSwitchCase=\"'title'\">\n <div\n class=\"title\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n [class.hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <div>\n {{ field.label }}\n </div>\n <kwikui-button\n *ngIf=\"field?.reset\"\n appearance=\"whiteblock\"\n size=\"s\"\n label=\"Reset\"\n (onClick)=\"handleOnClickResetFormFields($event, field)\"\n ></kwikui-button>\n </div>\n </ng-container>\n <!-- Button -->\n <ng-container *ngSwitchCase=\"'button'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-button\n [appearance]=\"field?.properties?.appearance ?? 'primary'\"\n [class]=\"field?.properties?.class\"\n [disabled]=\"field?.disabled\"\n [icon]=\"field?.properties?.icon\"\n [iconRight]=\"field?.properties?.iconRight\"\n [id]=\"field?.key\"\n [label]=\"field?.label\"\n [shape]=\"field?.properties?.shape\"\n [showLoader]=\"field?.properties?.loading ?? false\"\n [size]=\"field?.properties?.size\"\n [styles]=\"field?.properties?.styles\"\n [type]=\"'button'\"\n (onClick)=\"handleOnClickFormFieldButton(field)\"\n ></kwikui-button>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Text -->\n <ng-container *ngSwitchCase=\"'text'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input\n [case]=\"field?.properties?.case\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [type]=\"'text'\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Email -->\n <ng-container *ngSwitchCase=\"'email'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-email\n [case]=\"field?.properties?.case\"\n [disabled]=\"field?.disabled\"\n [domains]=\"field?.properties?.domains\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-email>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Password -->\n <ng-container *ngSwitchCase=\"'password'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-password\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [hintContent]=\"field?.properties?.hintContent\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-password>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Textarea -->\n <ng-container *ngSwitchCase=\"'textarea'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-textarea\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-textarea>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Checkbox -->\n <ng-container *ngSwitchCase=\"'checkbox'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-checkbox\n [contentAlign]=\"field?.properties?.contentAlign ?? 'left'\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.properties?.placeholder\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size ?? 'l'\"\n [validators]=\"field?.validators\"\n [variant]=\"field?.properties?.variant ?? 'block'\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-checkbox>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Number -->\n <ng-container *ngSwitchCase=\"'number'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-number\n [decimal]=\"field?.properties?.decimal\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [min]=\"field?.properties?.min\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix ?? ''\"\n [precision]=\"field?.properties?.precision\"\n [prefix]=\"field?.properties?.prefix ?? ''\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-number>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Date -->\n <ng-container *ngSwitchCase=\"'date'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-date\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [maxCalculatedFromToday]=\"\n field?.properties?.maxCalculatedFromToday\n \"\n [min]=\"field?.properties?.min\"\n [minCalculatedFromToday]=\"\n field?.properties?.minCalculatedFromToday\n \"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-date>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Phone -->\n <ng-container *ngSwitchCase=\"'phone'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-phone\n [countryCode]=\"field?.properties?.countryCode\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [phoneMaskAfterCountryCode]=\"\n field?.properties?.phoneMaskAfterCountryCode\n \"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [removeCountryCodeFromValue]=\"\n field?.properties?.removeCountryCodeFromValue\n \"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-phone>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Radio -->\n <ng-container *ngSwitchCase=\"'radio'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n [tuiLabel]=\"labelTemplate\"\n style=\"min-height: auto; padding: 0px 0.5rem\"\n >\n <kwikui-input-radio\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [items]=\"field?.options\"\n [label]=\"field?.label\"\n [orientation]=\"field?.properties?.orientation\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-radio>\n </label>\n <ng-template #labelTemplate>\n <p\n class=\"tui-space_bottom-2\"\n [hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <b>\n {{ field.label }}\n <span *ngIf=\"field.validators?.required\">*</span>\n </b>\n </p>\n </ng-template>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Dropdown -->\n <ng-container *ngSwitchCase=\"'select'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-select\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [options]=\"field.options\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [searchable]=\"field?.properties?.searchable\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-select>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Input Slider -->\n <ng-container *ngSwitchCase=\"'slider'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-slider\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [min]=\"field?.properties?.min\"\n [placeholder]=\"field?.properties?.placeholder\"\n [postfix]=\"field?.properties?.postfix\"\n [prefix]=\"field?.properties?.prefix\"\n [properties]=\"field?.properties\"\n [quantum]=\"field?.properties?.quantum\"\n [size]=\"field?.properties?.size\"\n [steps]=\"field?.properties?.steps\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-slider>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- API Call -->\n <ng-container *ngSwitchCase=\"'api'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-button-api-call\n [apiStatus]=\"field?.api?.status?.value\"\n [class]=\"field?.class\"\n [disabled]=\"field?.disabled\"\n [id]=\"field.key\"\n [label]=\"field?.api?.status?.labels[field?.api?.status?.value]\"\n [showLoader]=\"field?.disabled === 'loading'\"\n styles=\"width: fit-content\"\n (onClick)=\"handleOnClickApiCall($event)\"\n ></kwikui-button-api-call>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Mobile OTP -->\n <ng-container *ngSwitchCase=\"'otp'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-otp\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [mask]=\"field?.properties?.mask\"\n [mode]=\"field?.properties?.mode\"\n [otpLength]=\"field?.properties?.otpLength\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-otp>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Aadhaar Number -->\n <ng-container *ngSwitchCase=\"'aadhaar-number'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-input-aadhaar\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [mask]=\"field?.properties?.mask\"\n [placeholder]=\"field?.placeholder\"\n [properties]=\"field?.properties\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-input-aadhaar>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Preview Image -->\n <ng-container *ngSwitchCase=\"'image'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <kwikui-image\n [altText]=\"field?.properties?.altText\"\n [class]=\"field?.properties?.class\"\n [html]=\"field?.properties?.html\"\n [id]=\"field.key\"\n [imageSrc]=\"field?.default?.value?.value ?? ''\"\n [imageType]=\"field?.properties?.imageType\"\n [loadingType]=\"field?.properties?.loadingType\"\n [styles]=\"field?.properties?.styles\"\n ></kwikui-image>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- File Upload -->\n <ng-container *ngSwitchCase=\"'file'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n [tuiLabel]=\"labelTemplate\"\n style=\"min-height: auto\"\n >\n <kwikui-input-files\n [accept]=\"field?.properties?.accept\"\n [class]=\"field?.properties?.class\"\n [disabled]=\"field?.disabled\"\n [files]=\"files[field.key]\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [id]=\"field?.key\"\n [label]=\"field?.properties?.label\"\n [link]=\"field?.properties?.link\"\n [maxFileSize]=\"field?.properties?.maxFileSize\"\n [multiple]=\"field?.properties?.multiple\"\n [setFileTypesToForm]=\"['NORMAL']\"\n [styles]=\"field?.properties?.styles\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValueFile($event)\"\n (getRemovedFile)=\"handleRemovedFile($event)\"\n ></kwikui-input-files>\n </label>\n <ng-template #labelTemplate>\n <p\n style=\"padding: 0px 0.25rem; margin-bottom: 0.25rem\"\n [hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <b>\n {{ field.label }}\n <span *ngIf=\"field.validators?.required\">*</span>\n </b>\n </p>\n </ng-template>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Camera Capture -->\n <ng-container *ngSwitchCase=\"'capture'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n *ngIf=\"\n field?.label !== '' &&\n field?.label !== undefined &&\n field?.label !== null\n \"\n style=\"min-height: auto\"\n >\n <p\n *ngIf=\"field?.label !== ''\"\n style=\"padding: 0px 0.25rem; margin-bottom: 0.5rem\"\n [hidden]=\"field?.hidden\"\n id=\"field_{{ field.key }}\"\n >\n <b>\n {{ field.label }}\n <span *ngIf=\"field.validators?.required\">*</span>\n </b>\n </p>\n </label>\n <kwikui-input-camera\n [buttonText]=\"field?.properties?.buttonText\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [icon]=\"field?.properties?.icon\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [mediaFiles]=\"mediaFiles[field.key]\"\n [properties]=\"field?.properties\"\n [showMediaFiles]=\"field?.properties?.showMediaFiles\"\n [type]=\"'CAPTURE'\"\n [validators]=\"field?.validators\"\n (onClick)=\"handleOnClickInputCamera($event, field)\"\n (getRemovedFile)=\"handleOnClickGetRemovedMediaFile($event)\"\n ></kwikui-input-camera>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n <!-- Star Rating -->\n <ng-container *ngSwitchCase=\"'star-rating'\">\n <div\n [hidden]=\"field?.hidden\"\n [style]=\"field?.properties?.containerStyles ?? '' | styleSanitizer\"\n id=\"field_{{ field.key }}\"\n >\n <label\n [tuiLabel]=\"labelTemplate\"\n style=\"min-height: auto; padding: 0px 0.5rem\"\n >\n <kwikui-star-rating\n [color]=\"field?.properties?.color\"\n [disabled]=\"field?.disabled\"\n [focus]=\"field?.focus\"\n [formControl]=\"formGroup.controls[field.key]\"\n [formControlName]=\"field.key\"\n [icon]=\"field?.properties?.icon\"\n [iconMarked]=\"field?.properties?.iconMarked\"\n [id]=\"field.key\"\n [invalid]=\"field?.invalid\"\n [label]=\"field?.label\"\n [max]=\"field?.properties?.max\"\n [min]=\"field?.properties?.min\"\n [placeholder]=\"field?.properties?.placeholder\"\n [properties]=\"field?.properties\"\n [size]=\"field?.properties?.size\"\n [validators]=\"field?.validators\"\n (getKeyValue)=\"handleGetKeyValue($event)\"\n ></kwikui-star-rating>\n </label>\n <ng-template #labelTemplate>\n <p>\n <b\n >{{ field?.properties?.placeholder }}\n <span *ngIf=\"field.validators?.required\">*</span></b\n >\n </p>\n </ng-template>\n <kwikui-messages\n [messages]=\"field.messages\"\n [id]=\"field.key\"\n ></kwikui-messages>\n </div>\n </ng-container>\n </ng-container>\n </ng-container>\n </form>\n <div\n class=\"kwikid-form-buttons\"\n *ngIf=\"\n !formConfig.properties.footer.viewFormsButton.hidden ||\n !formConfig.properties.footer.saveButton.hidden\n \"\n >\n <kwikui-button\n *ngIf=\"\n !formConfig.properties.footer.viewFormsButton.hidden && isMobileView\n \"\n [appearance]=\"'secondary'\"\n [disabled]=\"viewFormsButton.disabled\"\n [label]=\"formConfig.properties.footer.viewFormsButton.label\"\n [showLoader]=\"viewFormsButton.showLoader\"\n [styles]=\"'width: 100%'\"\n (onClick)=\"handleOnClickViewForms($event)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"!formConfig.properties.footer.saveButton.hidden\"\n [disabled]=\"saveFormButton.disabled\"\n [label]=\"formConfig.properties.footer.saveButton.label\"\n [showLoader]=\"saveFormButton.showLoader\"\n [styles]=\"'width: 100%'\"\n (onClick)=\"handleOnClickSaveForm($event)\"\n ></kwikui-button>\n </div>\n</div>\n<div\n class=\"kwikid-form-container-loading\"\n *ngIf=\"loading\"\n>\n <div\n *ngFor=\"let item of [].constructor(7); let i = index\"\n class=\"large-wrapper tui-skeleton tui-skeleton_rounded\"\n >\n </div>\n</div>\n\n<kwikui-loader></kwikui-loader>\n\n<tui-push\n id=\"field-error-notification\"\n *tuiPush=\"showErrorNotification\"\n heading=\"Missing/Incorrect Fields!\"\n type=\"Error\"\n (close)=\"toggleErrorNotification(false)\"\n>\n <tui-svg\n src=\"tuiIconXCircle\"\n style=\"color: #fff !important\"\n >\n </tui-svg>\n</tui-push>\n\n<ng-template\n #preview\n let-preview\n>\n <tui-preview\n [rotatable]=\"false\"\n [zoomable]=\"false\"\n class=\"preview-container\"\n >\n <tui-preview-title *ngIf=\"previewProperties.title !== ''\">{{\n previewProperties.title\n }}</tui-preview-title>\n\n <ng-container *ngIf=\"!previewProperties.unavailable\">\n <div\n *ngIf=\"previewProperties?.html?.before !== ''\"\n class=\"preview-html preview-html-before\"\n [style]=\"previewProperties?.html?.beforeStyles ?? '' | styleSanitizer\"\n [innerHtml]=\"previewProperties.html.before | kwikuiSafeHtml\"\n ></div>\n\n <!-- Content within the iframe -->\n <div\n class=\"preview-iframe-content\"\n [style]=\"\n previewProperties?.iframe?.containerStyles ?? '' | styleSanitizer\n \"\n *ngIf=\"previewProperties.iframe.src !== ''\"\n >\n <!-- Your HTML content here -->\n <iframe\n [src]=\"previewProperties.iframe.src | kwikuiSafeUrl\"\n frameborder=\"0\"\n allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\"\n allowfullscreen\n [title]=\"previewProperties.iframe.title\"\n class=\"preview-iframe\"\n scrolling=\"auto\"\n ></iframe>\n </div>\n\n <div\n *ngIf=\"previewProperties?.html?.after !== ''\"\n class=\"preview-html preview-html-after\"\n [style]=\"previewProperties?.html?.afterStyles ?? '' | styleSanitizer\"\n [innerHtml]=\"previewProperties.html.after | kwikuiSafeHtml\"\n ></div>\n </ng-container>\n\n <ng-container *ngIf=\"previewProperties.unavailable\">\n <div class=\"preview-unavailable\">\n <tui-svg\n src=\"tuiIconFileLarge\"\n class=\"t-icon\"\n ></tui-svg>\n <div>Preview unavailable</div>\n </div>\n </ng-container>\n\n <button\n tuiIconButton\n tuiPreviewAction\n icon=\"tuiIconCloseLarge\"\n title=\"Close\"\n type=\"button\"\n (click)=\"preview.complete()\"\n ></button>\n </tui-preview>\n</ng-template>\n\n<ng-template\n #dialog\n let-dialog\n>\n <div class=\"preview-container\">\n <ng-container *ngIf=\"!previewProperties.unavailable\">\n <div\n *ngIf=\"previewProperties?.html?.before !== ''\"\n class=\"preview-html preview-html-before\"\n [style]=\"previewProperties?.html?.beforeStyles ?? '' | styleSanitizer\"\n [innerHtml]=\"previewProperties.html.before | kwikuiSafeHtml\"\n ></div>\n\n <!-- Content within the iframe -->\n <div\n class=\"preview-iframe-content\"\n [style]=\"\n previewProperties?.iframe?.containerStyles ?? '' | styleSanitizer\n \"\n *ngIf=\"previewProperties.iframe.src !== ''\"\n >\n <!-- Your HTML content here -->\n <iframe\n [src]=\"previewProperties.iframe.src | kwikuiSafeUrl\"\n frameborder=\"0\"\n allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\"\n allowfullscreen\n [title]=\"previewProperties.iframe.title\"\n class=\"preview-iframe\"\n scrolling=\"auto\"\n ></iframe>\n </div>\n\n <div\n *ngIf=\"previewProperties?.html?.after !== ''\"\n class=\"preview-html preview-html-after\"\n [style]=\"previewProperties?.html?.afterStyles ?? '' | styleSanitizer\"\n [innerHtml]=\"previewProperties.html.after | kwikuiSafeHtml\"\n ></div>\n </ng-container>\n\n <ng-container *ngIf=\"previewProperties.unavailable\">\n <div class=\"preview-unavailable\">\n <tui-svg\n src=\"tuiIconFileLarge\"\n class=\"t-icon\"\n ></tui-svg>\n <div>Preview unavailable</div>\n </div>\n </ng-container>\n </div>\n</ng-template>\n\n<div\n id=\"kwikid-camera-container\"\n *ngIf=\"isShowCameraCapture\"\n>\n <div\n id=\"kwikid-camera-wrapper\"\n [class.fullscreen]=\"isShowCameraFullscreen\"\n >\n <kwikid-camera\n [type]=\"'CAPTURE'\"\n [image]=\"cameraCaptureImage\"\n [config]=\"cameraCaptureConfig\"\n (getImage)=\"handleGetImage($event)\"\n (onClickSave)=\"handleOnClickSaveCameraCapture($event)\"\n >\n <ng-container slot=\"header\">\n <div style=\"display: flex; width: 100%; max-width: 100%; padding: 0rem\">\n <div style=\"flex: 1; text-align: left\"> </div>\n <kwikui-button\n *ngIf=\"cameraCaptureConfig?.header?.title !== ''\"\n appearance=\"whiteblock\"\n [label]=\"cameraCaptureConfig?.header?.title\"\n shape=\"rounded\"\n style=\"\n flex: 1;\n width: 100%;\n min-width: max-content;\n text-align: center;\n margin: auto;\n \"\n size=\"s\"\n ></kwikui-button>\n <div\n style=\"\n flex: 1;\n text-align: right;\n display: flex;\n justify-content: flex-end;\n gap: 1rem;\n \"\n >\n <kwikui-button\n *ngIf=\"cameraCaptureConfig?.header?.isExpand\"\n id=\"kwikid-camera-header-enlarge-button\"\n appearance=\"whiteblock\"\n [icon]=\"\n isShowCameraFullscreen ? 'tuiIconMinimize2' : 'tuiIconMaximize2'\n \"\n shape=\"rounded\"\n size=\"s\"\n (click)=\"isShowCameraFullscreen = !isShowCameraFullscreen\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"cameraCaptureConfig?.header?.isClose\"\n id=\"kwikid-camera-header-close-button\"\n appearance=\"whiteblock\"\n icon=\"tuiIconCloseLarge\"\n shape=\"rounded\"\n size=\"s\"\n (click)=\"handleOnClickCloseCamera($event)\"\n ></kwikui-button>\n </div>\n </div>\n </ng-container>\n </kwikid-camera>\n </div>\n</div>\n", styles: [".kwikid-form-container{width:100%;height:100%;margin:0 auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center}.kwikid-form.show{width:100%;height:100%;padding:1rem;overflow-y:auto;display:flex;flex-direction:column;align-content:center;justify-content:flex-start;align-items:stretch}.kwikid-form.show>*:not(:last-child){margin-bottom:1rem}.kwikid-form-buttons{width:100%;bottom:0px;padding:1rem;display:flex;flex-direction:row;align-content:center;justify-content:center;align-items:center}.kwikid-form-buttons>*:not(:last-child){margin-right:1rem}.kwikid-form-buttons *{flex-grow:1}#uf-form-fields-header-container{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:flex-start;padding:1rem 1rem 0}#uf-form-fields-header-container>*:not(:last-child){margin-bottom:.5rem}#uf-form-fields-header-container #uf-header-logo{width:-moz-fit-content;width:fit-content;height:50px}#uf-form-fields-header-container #uf-form-fields-header-main{display:flex;flex-direction:row;align-content:center;justify-content:flex-start;align-items:center;width:100%}#uf-form-fields-header-container #uf-form-fields-header-main>*:not(:last-child){margin-right:.25rem}#uf-form-fields-header-container #uf-form-fields-header-main #uf-form-fields-header-right{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:flex-start}#uf-form-fields-header-container #uf-form-fields-header-main #uf-form-fields-header-right>*{margin-bottom:.5rem}#uf-form-fields-header-container hr{width:100%}#uf-form-fields-title{color:#000;font-size:1.75em;font-weight:bold}#uf-form-fields-steps{color:var(--color-on-secondary-container);font-size:1rem}.title{border-left:.25rem solid var(--tui-primary);padding:.75rem;font-size:1.4em;font-weight:bold;background-color:var(--tui-secondary);display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center}.title>*:not(:last-child){margin-right:.5rem}.title:not(:first-child){margin-top:.5rem}.title.hidden{display:none}.large-wrapper{width:100%;height:60px}.large-wrapper:first-child{margin-bottom:auto}.large-wrapper:last-child{margin-top:auto}.kwikid-form-container-loading{width:100%;height:100%;margin:0 auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;padding:1rem}.kwikid-form-container-loading>* :not(:last-child){margin-bottom:1rem}#field-error-notification{background-color:var(--tui-error-fill);color:#fff!important}#field-error-notification .t-top{color:#fff!important}#field-error-notification .t-close{color:#fff!important}.preview-container{display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;align-content:center;height:calc(100vh - 3rem)}.preview-container>*:not(:last-child){margin-bottom:1rem}.preview-container .preview-html{flex-grow:1}.preview-container .preview-iframe-content{height:100%;flex-grow:1}.preview-container .preview-iframe-content .preview-iframe{width:100%;height:100%}.preview-container .preview-unavailable{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:center;color:#fff;font-size:1.2rem;top:50%;left:50%;width:100%;height:100vh}.preview-container .preview-unavailable>*:not(:last-child){margin-bottom:1rem}#kwikid-camera-container{width:100%;height:100%;position:fixed;top:50%;left:50%;background-color:#0000008f;transform:translate(-50%,-50%);z-index:100}#kwikid-camera-container #kwikid-camera-wrapper{width:min(80%);height:max(85%);box-shadow:#0000008f 0 22px 70px 4px;overflow:hidden;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);border-radius:1rem;background-color:#000;transition:5s linear ease}#kwikid-camera-container #kwikid-camera-wrapper.fullscreen{width:100%;height:100%;border-radius:0;transition:5s linear ease}@media only screen and (max-width: 600px){#kwikid-camera-container #kwikid-camera-wrapper{width:100%;height:100%;border-radius:0;transition:5s linear ease}#kwikid-camera-container #kwikid-camera-wrapper #kwikid-camera-header-enlarge-button{display:none}}\n", "::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i2.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }, { type: i2.KwikUIMessagesComponent, selector: "kwikui-messages", inputs: ["id", "messages"] }, { type: i2.KwikUIInputComponent, selector: "kwikui-input", inputs: ["case", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "type", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputEmailComponent, selector: "kwikui-input-email", inputs: ["case", "disabled", "domains", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputPasswordComponent, selector: "kwikui-input-password", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUITextareaComponent, selector: "kwikui-textarea", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "placeholder", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUICheckboxComponent, selector: "kwikui-checkbox", inputs: ["contentAlign", "disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "placeholder", "properties", "size", "validators", "variant"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputNumberComponent, selector: "kwikui-input-number", inputs: ["decimal", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "min", "placeholder", "postfix", "precision", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputDateComponent, selector: "kwikui-input-date", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "maxCalculatedFromToday", "min", "minCalculatedFromToday", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputPhoneComponent, selector: "kwikui-input-phone", inputs: ["countryCode", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "phoneMaskAfterCountryCode", "placeholder", "postfix", "prefix", "properties", "removeCountryCodeFromValue", "size", "validators"], outputs: ["getKeyValue"] }, { type: i3.TuiLabelComponent, selector: "label[tuiLabel]", inputs: ["tuiLabel", "context"] }, { type: i2.KwikUIInputRadioComponent, selector: "kwikui-input-radio", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "items", "label", "orientation", "placeholder", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputSelectComponent, selector: "kwikui-input-select", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "options", "placeholder", "properties", "searchable", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputSliderComponent, selector: "kwikui-input-slider", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "min", "placeholder", "postfix", "prefix", "properties", "quantum", "size", "steps", "type", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIButtonApiCallComponent, selector: "kwikui-button-api-call", inputs: ["apiStatus", "class", "disabled", "id", "label", "shape", "showLoader", "size", "styles"], outputs: ["onClick"] }, { type: i2.KwikUIInputOtpComponent, selector: "kwikui-input-otp", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "mask", "mode", "otpLength", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIInputAadhaarComponent, selector: "kwikui-input-aadhaar", inputs: ["disabled", "focus", "formControl", "formControlName", "id", "invalid", "label", "mask", "placeholder", "properties", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUIImageComponent, selector: "kwikui-image", inputs: ["altText", "class", "html", "id", "imageSrc", "imageType", "loadingType", "styles"], outputs: ["onClick"] }, { type: i2.KwikUIInputFilesComponent, selector: "kwikui-input-files", inputs: ["accept", "class", "disabled", "files", "formControl", "formControlName", "icon", "id", "label", "link", "maxFileSize", "multiple", "setFileTypesToForm", "showAddedFiles", "size", "styles", "validators"], outputs: ["getKeyValue", "getRemovedFile"] }, { type: i4.KwikUIInputCameraComponent, selector: "kwikui-input-camera", inputs: ["buttonText", "disabled", "focus", "formControl", "formControlName", "icon", "id", "invalid", "mediaFiles", "properties", "showMediaFiles", "size", "type", "validators"], outputs: ["onClick", "getRemovedFile"] }, { type: i2.KwikUIStarRatingComponent, selector: "kwikui-star-rating", inputs: ["color", "disabled", "focus", "formControl", "formControlName", "icon", "iconMarked", "id", "invalid", "label", "max", "min", "placeholder", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i2.KwikUILoaderComponent, selector: "kwikui-loader" }, { type: i5.TuiPushComponent, selector: "tui-push", inputs: ["heading", "type", "timestamp"], outputs: ["close"] }, { type: i3.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }, { type: i6.TuiPreviewComponent, selector: "tui-preview", inputs: ["zoomable", "rotatable"] }, { type: i6.TuiPreviewTitleComponent, selector: "tui-preview-title" }, { type: i3.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { type: i4.KwikIDCameraComponent, selector: "kwikid-camera", inputs: ["type", "config", "data", "image"], outputs: ["getImage", "onClickSave"] }], directives: [{ type: i3$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i3$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i3$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i3$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3$2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i3$2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i3$1.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i5.TuiPushAlertDirective, selector: "[tuiPush]", inputs: ["tuiPush"] }, { type: i5.TuiPushDirective, selector: "tui-push" }, { type: i6.TuiPreviewActionDirective, selector: "[tuiPreviewAction]" }], pipes: { "styleSanitizer": StyleSanitizerPipe, "kwikuiSafeHtml": i2.KwikUISafeHtmlPipe, "kwikuiSafeUrl": i2.KwikUISafeUrlPipe } });
|
|
4578
4846
|
__decorate([
|
|
4579
4847
|
logMethod
|
|
4580
4848
|
], KwikIDFormViewComponent.prototype, "ngOnInit", null);
|
|
@@ -4722,6 +4990,24 @@ __decorate([
|
|
|
4722
4990
|
__decorate([
|
|
4723
4991
|
logMethod
|
|
4724
4992
|
], KwikIDFormViewComponent.prototype, "setFieldDefaultValue", null);
|
|
4993
|
+
__decorate([
|
|
4994
|
+
logMethod
|
|
4995
|
+
], KwikIDFormViewComponent.prototype, "setApiStatus", null);
|
|
4996
|
+
__decorate([
|
|
4997
|
+
logMethod
|
|
4998
|
+
], KwikIDFormViewComponent.prototype, "setApiHeaderValue", null);
|
|
4999
|
+
__decorate([
|
|
5000
|
+
logMethod
|
|
5001
|
+
], KwikIDFormViewComponent.prototype, "setApiHeaderValidity", null);
|
|
5002
|
+
__decorate([
|
|
5003
|
+
logMethod
|
|
5004
|
+
], KwikIDFormViewComponent.prototype, "setApiBodyValue", null);
|
|
5005
|
+
__decorate([
|
|
5006
|
+
logMethod
|
|
5007
|
+
], KwikIDFormViewComponent.prototype, "setApiBodyValidity", null);
|
|
5008
|
+
__decorate([
|
|
5009
|
+
logMethod
|
|
5010
|
+
], KwikIDFormViewComponent.prototype, "setFieldValidity", null);
|
|
4725
5011
|
__decorate([
|
|
4726
5012
|
logMethod
|
|
4727
5013
|
], KwikIDFormViewComponent.prototype, "setDropdownOptions", null);
|
|
@@ -4843,11 +5129,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
4843
5129
|
type: Output
|
|
4844
5130
|
}], onClickApiCall: [{
|
|
4845
5131
|
type: Output
|
|
5132
|
+
}], getLogs: [{
|
|
5133
|
+
type: Output
|
|
4846
5134
|
}], onActionShowPopupForm: [{
|
|
4847
5135
|
type: Output
|
|
4848
5136
|
}], onClickFormFieldButton: [{
|
|
4849
5137
|
type: Output
|
|
4850
|
-
}], ngOnInit: [], ngAfterViewInit: [], ngOnChanges: [], initFormConfig: [], setFormFieldsFromFormConfig: [], setFormFieldGroupsFromFormConfig: [], setFormDataFromAllFormsData: [], handleConnectedElementFieldGroupActions: [], handleConnectedElementFieldGroup: [], handleConnectedElementFieldActions: [], handleConnectedElementFields: [], handleConnectedElements: [], handleRemovedFile: [], handleGetKeyValueFile: [], handleOnClickGetRemovedMediaFile: [], handleOnClickInputCamera: [], setImage: [], handleOnClickSaveCameraCapture: [], handleGetImage: [], handleOnClickCloseCamera: [], updateFiles: [], uploadFile: [], handleOnClickFormFieldButton: [], handleGetKeyValue: [], handleOnClickResetFormFields: [], handleFieldApiCall: [], handleApiCall: [], executeApiCall: [], isValidRequestHeadersAndBody: [], handleOnClickApiCall: [], handleOnClickGoBack: [], handleOnClickViewForms: [], handleOnClickSaveForm: [], toggleErrorNotification: [], fieldHide: [], fieldGroupHide: [], fieldShow: [], fieldGroupShow: [], fieldDisable: [], fieldGroupDisable: [], fieldEnable: [], fieldGroupEnable: [], fieldReset: [], fieldErrorShow: [], fieldErrorHide: [], fieldMessageShow: [], fieldMessageHide: [], setValue: [], setFieldDefaultValue: [], setDropdownOptions: [], apiCall: [], fieldApiCall: [], fieldMultipleApiCalls: [], fieldMultipleApiCallsEnd: [], taskApiCall: [], taskMultipleApiCalls: [], taskMultipleApiCallsEnd: [], dialogShow: [], dialogHide: [], redirectToUrl: [], patchFieldControlValue: [], setFieldControlValue: [], patchFormGroup: [], isFieldValid: [], isFieldEnabled: [], getFormGroupRawValues: [], showPreview: [], showErrorPreview: [], showPopupForm: [], alertShow: [], takeActionOnFieldGroup: [], takeAction: [] } });
|
|
5138
|
+
}], ngOnInit: [], ngAfterViewInit: [], ngOnChanges: [], initFormConfig: [], setFormFieldsFromFormConfig: [], setFormFieldGroupsFromFormConfig: [], setFormDataFromAllFormsData: [], handleConnectedElementFieldGroupActions: [], handleConnectedElementFieldGroup: [], handleConnectedElementFieldActions: [], handleConnectedElementFields: [], handleConnectedElements: [], handleRemovedFile: [], handleGetKeyValueFile: [], handleOnClickGetRemovedMediaFile: [], handleOnClickInputCamera: [], setImage: [], handleOnClickSaveCameraCapture: [], handleGetImage: [], handleOnClickCloseCamera: [], updateFiles: [], uploadFile: [], handleOnClickFormFieldButton: [], handleGetKeyValue: [], handleOnClickResetFormFields: [], handleFieldApiCall: [], handleApiCall: [], executeApiCall: [], isValidRequestHeadersAndBody: [], handleOnClickApiCall: [], handleOnClickGoBack: [], handleOnClickViewForms: [], handleOnClickSaveForm: [], toggleErrorNotification: [], fieldHide: [], fieldGroupHide: [], fieldShow: [], fieldGroupShow: [], fieldDisable: [], fieldGroupDisable: [], fieldEnable: [], fieldGroupEnable: [], fieldReset: [], fieldErrorShow: [], fieldErrorHide: [], fieldMessageShow: [], fieldMessageHide: [], setValue: [], setFieldDefaultValue: [], setApiStatus: [], setApiHeaderValue: [], setApiHeaderValidity: [], setApiBodyValue: [], setApiBodyValidity: [], setFieldValidity: [], setDropdownOptions: [], apiCall: [], fieldApiCall: [], fieldMultipleApiCalls: [], fieldMultipleApiCallsEnd: [], taskApiCall: [], taskMultipleApiCalls: [], taskMultipleApiCallsEnd: [], dialogShow: [], dialogHide: [], redirectToUrl: [], patchFieldControlValue: [], setFieldControlValue: [], patchFormGroup: [], isFieldValid: [], isFieldEnabled: [], getFormGroupRawValues: [], showPreview: [], showErrorPreview: [], showPopupForm: [], alertShow: [], takeActionOnFieldGroup: [], takeAction: [] } });
|
|
4851
5139
|
|
|
4852
5140
|
var EFormType;
|
|
4853
5141
|
(function (EFormType) {
|
|
@@ -5093,6 +5381,7 @@ class KwikIDFormsRendererComponent {
|
|
|
5093
5381
|
this.onClickSubmit = new EventEmitter();
|
|
5094
5382
|
this.getFormData = new EventEmitter();
|
|
5095
5383
|
this.onClickApiCall = new EventEmitter();
|
|
5384
|
+
this.getLogs = new EventEmitter();
|
|
5096
5385
|
this.onClickFormFieldButton = new EventEmitter();
|
|
5097
5386
|
this.loading = false;
|
|
5098
5387
|
this.showErrorNotification = false;
|
|
@@ -5845,6 +6134,9 @@ class KwikIDFormsRendererComponent {
|
|
|
5845
6134
|
this.onClickSubmit.emit(e);
|
|
5846
6135
|
});
|
|
5847
6136
|
}
|
|
6137
|
+
handleGetLogs(event) {
|
|
6138
|
+
this.getLogs.emit(event);
|
|
6139
|
+
}
|
|
5848
6140
|
/**
|
|
5849
6141
|
* Miscellaneous Methods
|
|
5850
6142
|
*/
|
|
@@ -5871,7 +6163,7 @@ class KwikIDFormsRendererComponent {
|
|
|
5871
6163
|
}
|
|
5872
6164
|
}
|
|
5873
6165
|
/** @nocollapse */ KwikIDFormsRendererComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: KwikIDFormsRendererComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: TuiPreviewDialogService }, { token: i2.KwikUILoaderService }, { token: TuiDialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
5874
|
-
/** @nocollapse */ KwikIDFormsRendererComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDFormsRendererComponent, selector: "kwikid-forms-renderer", inputs: { stepConfig: "stepConfig", userConfig: "userConfig", formsData: "formsData", activeFormData: "activeFormData", apiCallResponse: "apiCallResponse", buttonClickResponse: "buttonClickResponse" }, outputs: { onClickSubmit: "onClickSubmit", getFormData: "getFormData", onClickApiCall: "onClickApiCall", onClickFormFieldButton: "onClickFormFieldButton" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, viewQueries: [{ propertyName: "preview", first: true, predicate: ["preview"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div ngClass=\"kwikid-renderer\">\n <div\n ngClass=\"kwikid-layout-container\"\n *ngIf=\"!loading\"\n >\n <div\n ngClass=\"kwikid-sections-container\"\n *ngIf=\"showFormSections\"\n class=\"active\"\n [class.active]=\"showFormSections\"\n [class.mobile]=\"isMobileView\"\n >\n <kwikid-forms-list\n [showFormFields]=\"this.showFormFields\"\n [activeFormConfig]=\"this.activeFormConfig\"\n [userConfig]=\"this.userConfig\"\n [formsList]=\"this.formsList\"\n [stepConfig]=\"this.stepConfig\"\n [isUnsavedData]=\"this.isUnsavedData\"\n [formsListCompleted]=\"this.formsListCompleted\"\n [isMobileView]=\"this.isMobileView\"\n (onClickSetActiveForm)=\"this.handleOnClickSetActiveForm($event)\"\n (onClickSubmitForms)=\"this.handleOnClickSubmitForms($event)\"\n ></kwikid-forms-list>\n </div>\n <div\n ngClass=\"kwikid-forms-container\"\n *ngIf=\"\n this.showForm &&\n this.showFormFields &&\n this.activeFormConfig !== undefined\n \"\n [class.active]=\"showFormFields\"\n [class.mobile]=\"isMobileView\"\n [@panelInOut]\n >\n <kwikid-form-view\n *ngIf=\"this.activeFormConfig.type === 'FORM'\"\n [formConfig]=\"this.activeFormConfig\"\n [allFormsData]=\"this.allFormsData\"\n [isMobileView]=\"this.isMobileView\"\n [userConfig]=\"this.userConfig\"\n [popupFormCallback]=\"this.popupFormCallback\"\n [apiCallResponse]=\"this.apiCallResponse\"\n [buttonClickResponse]=\"this.buttonClickResponse\"\n (onClickFormFieldButton)=\"handleOnClickFormFieldButton($event)\"\n (getUnsavedDataState)=\"handleGetUnsavedState($event)\"\n (onClickApiCall)=\"handleOnClickApiCall($event)\"\n (onActionShowPopupForm)=\"\n this.handleOnActionShowPopupForm($event, content)\n \"\n (onClickGoBack)=\"this.handleOnClickGoBack($event)\"\n (onClickViewForms)=\"this.handleOnClickViewForms($event)\"\n (onClickSaveForm)=\"\n this.handleOnClickSaveForm($event, 'FORM', undefined)\n \"\n ></kwikid-form-view>\n </div>\n </div>\n</div>\n\n<kwikui-loader></kwikui-loader>\n\n<tui-push\n id=\"error-notification\"\n *tuiPush=\"showErrorNotification\"\n heading=\"Please complete the required Forms!\"\n type=\"Error\"\n (close)=\"toggleErrorNotification(false)\"\n>\n <tui-svg\n src=\"tuiIconXCircle\"\n style=\"color: #fff !important\"\n >\n </tui-svg>\n</tui-push>\n<ng-template\n #preview\n let-preview\n>\n <tui-preview\n [rotatable]=\"false\"\n [zoomable]=\"false\"\n class=\"preview-container\"\n *ngIf=\"popupFormConfig\"\n >\n <tui-preview-title *ngIf=\"previewProperties.title !== ''\">{{\n previewProperties.title\n }}</tui-preview-title>\n\n <div class=\"kwikid-form-view-popup-container\">\n <kwikid-form-view\n [formData]=\"activePopupFormData\"\n [formConfig]=\"popupFormConfig\"\n [allFormsData]=\"allFormsData\"\n [userConfig]=\"this.userConfig\"\n [isMobileView]=\"this.isMobileView\"\n [apiCallResponse]=\"this.apiCallResponse\"\n [buttonClickResponse]=\"this.buttonClickResponse\"\n (onClickFormFieldButton)=\"handleOnClickFormFieldButton($event)\"\n (getSavedState)=\"handleGetUnsavedState($event)\"\n (onClickApiCall)=\"handleOnClickApiCall($event)\"\n (onClickSaveForm)=\"\n this.handleOnClickSaveForm($event, 'POPUP_FORM', undefined)\n \"\n ></kwikid-form-view>\n </div>\n\n <button\n tuiIconButton\n tuiPreviewAction\n icon=\"tuiIconCloseLarge\"\n title=\"Close\"\n type=\"button\"\n (click)=\"preview.complete()\"\n ></button>\n </tui-preview>\n</ng-template>\n<ng-template\n #content\n let-context\n>\n <div class=\"kwikid-form-view-popup-container\">\n <kwikid-form-view\n [formData]=\"activePopupFormData\"\n [formConfig]=\"popupFormConfig\"\n [allFormsData]=\"allFormsData\"\n [userConfig]=\"this.userConfig\"\n [isMobileView]=\"this.isMobileView\"\n [apiCallResponse]=\"this.apiCallResponse\"\n [buttonClickResponse]=\"this.buttonClickResponse\"\n (onClickFormFieldButton)=\"handleOnClickFormFieldButton($event)\"\n (getSavedState)=\"handleGetUnsavedState($event)\"\n (onClickApiCall)=\"handleOnClickApiCall($event)\"\n (onClickSaveForm)=\"\n this.handleOnClickSaveForm($event, 'POPUP_FORM', context)\n \"\n ></kwikid-form-view>\n </div>\n</ng-template>\n", styles: [":host{position:relative;height:100%}.kwikid-root{width:100%;height:100%}.kwikid-renderer{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%}.kwikid-layout-container{display:flex;flex-direction:row;padding:0 1rem;height:100%;justify-content:center;align-items:stretch;background:var(--tui-secondary-active);position:relative}.kwikid-sections-container{display:block;width:100%;max-width:400px;height:calc(100% - 2rem);padding:.25rem .5rem 0;border-radius:1rem;background-color:var(--tui-base-01);margin:auto 1rem auto 0;box-shadow:0 0 12px -8px var(--tui-secondary)}.kwikid-sections-container.mobile{position:absolute;top:0;left:0;z-index:5;opacity:1;visibility:visible;transition:all 1s;height:100%;border-radius:0;max-width:unset}.kwikid-forms-container{display:block;width:100%;max-width:min(50%,600px);margin:auto 0;height:calc(100% - 2rem);padding:.25rem .5rem 0;border-radius:1rem;background-color:var(--tui-base-01);box-shadow:0 0 12px -8px var(--tui-primary)}.kwikid-forms-container.mobile{position:absolute;top:0;left:0;z-index:5;opacity:1;visibility:visible;transition:all 1s;height:100%;border-radius:0;max-width:unset}@media screen and (max-width: 600px){.kwikid-layout-container{padding:0;background:transparent}.kwikid-sections-container{position:absolute;max-width:100%;bottom:-10000px;left:-10000px;opacity:0;padding:0;visibility:hidden}.kwikid-sections-container.active{visibility:visible}.kwikid-sections-container.mobile{height:100%;opacity:1;visibility:visible;transition:all 2s;border-radius:0;box-shadow:none;top:0px;margin:0;position:absolute}.kwikid-forms-container{display:none;max-width:100%;height:100%;padding:0;border-radius:0;box-shadow:none}.kwikid-forms-container.mobile{height:100%;opacity:1;visibility:visible;transition:all 2s;border-radius:0;box-shadow:none;top:0px;margin:0;position:absolute}.kwikid-forms-container.active{display:block}}#error-notification{background-color:var(--tui-error-fill);color:#fff!important}#error-notification .t-top{color:#fff!important}#error-notification .t-close{color:#fff!important}.preview-container{display:flex!important;flex-grow:1!important;flex-direction:column!important;align-content:center!important;justify-content:space-between!important;align-items:stretch!important}.preview-container .preview-iframe{width:100vw;height:100vh}.preview-container .preview-unavailable{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:center;color:#fff;font-size:1.2rem;top:50%;left:50%;width:100%;height:100vh}.preview-container .preview-unavailable>*:not(:last-child){margin-bottom:1rem}.kwikid-form-view-popup-container{border-radius:1rem;background:var(--tui-base-01)}\n", "::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: KwikIDFormsListComponent, selector: "kwikid-forms-list", inputs: ["showFormFields", "userConfig", "stepConfig", "activeFormConfig", "formsList", "formsListCompleted", "isMobileView", "isUnsavedData"], outputs: ["onClickSetActiveForm", "onClickHideFormsList", "onClickSubmitForms"] }, { type: KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: ["formConfig", "formData", "isMobileView", "allFormsData", "userConfig", "apiCallResponse", "buttonClickResponse", "popupFormCallback"], outputs: ["onClickGoBack", "onClickViewForms", "getUnsavedDataState", "onClickSaveForm", "onClickApiCall", "onActionShowPopupForm", "onClickFormFieldButton"] }, { type: i2.KwikUILoaderComponent, selector: "kwikui-loader" }, { type: i5.TuiPushComponent, selector: "tui-push", inputs: ["heading", "type", "timestamp"], outputs: ["close"] }, { type: i3.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }, { type: i6.TuiPreviewComponent, selector: "tui-preview", inputs: ["zoomable", "rotatable"] }, { type: i6.TuiPreviewTitleComponent, selector: "tui-preview-title" }, { type: i3.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }], directives: [{ type: i3$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.TuiPushAlertDirective, selector: "[tuiPush]", inputs: ["tuiPush"] }, { type: i5.TuiPushDirective, selector: "tui-push" }, { type: i6.TuiPreviewActionDirective, selector: "[tuiPreviewAction]" }], animations: [
|
|
6166
|
+
/** @nocollapse */ KwikIDFormsRendererComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDFormsRendererComponent, selector: "kwikid-forms-renderer", inputs: { stepConfig: "stepConfig", userConfig: "userConfig", formsData: "formsData", activeFormData: "activeFormData", apiCallResponse: "apiCallResponse", buttonClickResponse: "buttonClickResponse" }, outputs: { onClickSubmit: "onClickSubmit", getFormData: "getFormData", onClickApiCall: "onClickApiCall", getLogs: "getLogs", onClickFormFieldButton: "onClickFormFieldButton" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, viewQueries: [{ propertyName: "preview", first: true, predicate: ["preview"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div ngClass=\"kwikid-renderer\">\n <div\n ngClass=\"kwikid-layout-container\"\n *ngIf=\"!loading\"\n >\n <div\n ngClass=\"kwikid-sections-container\"\n *ngIf=\"showFormSections\"\n class=\"active\"\n [class.active]=\"showFormSections\"\n [class.mobile]=\"isMobileView\"\n >\n <kwikid-forms-list\n [showFormFields]=\"this.showFormFields\"\n [activeFormConfig]=\"this.activeFormConfig\"\n [userConfig]=\"this.userConfig\"\n [formsList]=\"this.formsList\"\n [stepConfig]=\"this.stepConfig\"\n [isUnsavedData]=\"this.isUnsavedData\"\n [formsListCompleted]=\"this.formsListCompleted\"\n [isMobileView]=\"this.isMobileView\"\n (onClickSetActiveForm)=\"this.handleOnClickSetActiveForm($event)\"\n (onClickSubmitForms)=\"this.handleOnClickSubmitForms($event)\"\n ></kwikid-forms-list>\n </div>\n <div\n ngClass=\"kwikid-forms-container\"\n *ngIf=\"\n this.showForm &&\n this.showFormFields &&\n this.activeFormConfig !== undefined\n \"\n [class.active]=\"showFormFields\"\n [class.mobile]=\"isMobileView\"\n [@panelInOut]\n >\n <kwikid-form-view\n *ngIf=\"this.activeFormConfig.type === 'FORM'\"\n [formConfig]=\"this.activeFormConfig\"\n [allFormsData]=\"this.allFormsData\"\n [isMobileView]=\"this.isMobileView\"\n [userConfig]=\"this.userConfig\"\n [popupFormCallback]=\"this.popupFormCallback\"\n [apiCallResponse]=\"this.apiCallResponse\"\n [buttonClickResponse]=\"this.buttonClickResponse\"\n (onClickFormFieldButton)=\"handleOnClickFormFieldButton($event)\"\n (getUnsavedDataState)=\"handleGetUnsavedState($event)\"\n (onClickApiCall)=\"handleOnClickApiCall($event)\"\n (onActionShowPopupForm)=\"\n this.handleOnActionShowPopupForm($event, content)\n \"\n (onClickGoBack)=\"this.handleOnClickGoBack($event)\"\n (onClickViewForms)=\"this.handleOnClickViewForms($event)\"\n (getLogs)=\"handleGetLogs($event)\"\n (onClickSaveForm)=\"\n this.handleOnClickSaveForm($event, 'FORM', undefined)\n \"\n ></kwikid-form-view>\n </div>\n </div>\n</div>\n\n<kwikui-loader></kwikui-loader>\n\n<tui-push\n id=\"error-notification\"\n *tuiPush=\"showErrorNotification\"\n heading=\"Please complete the required Forms!\"\n type=\"Error\"\n (close)=\"toggleErrorNotification(false)\"\n>\n <tui-svg\n src=\"tuiIconXCircle\"\n style=\"color: #fff !important\"\n >\n </tui-svg>\n</tui-push>\n<ng-template\n #preview\n let-preview\n>\n <tui-preview\n [rotatable]=\"false\"\n [zoomable]=\"false\"\n class=\"preview-container\"\n *ngIf=\"popupFormConfig\"\n >\n <tui-preview-title *ngIf=\"previewProperties.title !== ''\">{{\n previewProperties.title\n }}</tui-preview-title>\n\n <div class=\"kwikid-form-view-popup-container\">\n <kwikid-form-view\n [formData]=\"activePopupFormData\"\n [formConfig]=\"popupFormConfig\"\n [allFormsData]=\"allFormsData\"\n [userConfig]=\"this.userConfig\"\n [isMobileView]=\"this.isMobileView\"\n [apiCallResponse]=\"this.apiCallResponse\"\n [buttonClickResponse]=\"this.buttonClickResponse\"\n (onClickFormFieldButton)=\"handleOnClickFormFieldButton($event)\"\n (getSavedState)=\"handleGetUnsavedState($event)\"\n (onClickApiCall)=\"handleOnClickApiCall($event)\"\n (getLogs)=\"handleGetLogs($event)\"\n (onClickSaveForm)=\"\n this.handleOnClickSaveForm($event, 'POPUP_FORM', undefined)\n \"\n ></kwikid-form-view>\n </div>\n\n <button\n tuiIconButton\n tuiPreviewAction\n icon=\"tuiIconCloseLarge\"\n title=\"Close\"\n type=\"button\"\n (click)=\"preview.complete()\"\n ></button>\n </tui-preview>\n</ng-template>\n<ng-template\n #content\n let-context\n>\n <div class=\"kwikid-form-view-popup-container\">\n <kwikid-form-view\n [formData]=\"activePopupFormData\"\n [formConfig]=\"popupFormConfig\"\n [allFormsData]=\"allFormsData\"\n [userConfig]=\"this.userConfig\"\n [isMobileView]=\"this.isMobileView\"\n [apiCallResponse]=\"this.apiCallResponse\"\n [buttonClickResponse]=\"this.buttonClickResponse\"\n (onClickFormFieldButton)=\"handleOnClickFormFieldButton($event)\"\n (getSavedState)=\"handleGetUnsavedState($event)\"\n (onClickApiCall)=\"handleOnClickApiCall($event)\"\n (getLogs)=\"handleGetLogs($event)\"\n (onClickSaveForm)=\"\n this.handleOnClickSaveForm($event, 'POPUP_FORM', context)\n \"\n ></kwikid-form-view>\n </div>\n</ng-template>\n", styles: [":host{position:relative;height:100%}.kwikid-root{width:100%;height:100%}.kwikid-renderer{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%}.kwikid-layout-container{display:flex;flex-direction:row;padding:0 1rem;height:100%;justify-content:center;align-items:stretch;background:var(--tui-secondary-active);position:relative}.kwikid-sections-container{display:block;width:100%;max-width:400px;height:calc(100% - 2rem);padding:.25rem .5rem 0;border-radius:1rem;background-color:var(--tui-base-01);margin:auto 1rem auto 0;box-shadow:0 0 12px -8px var(--tui-secondary)}.kwikid-sections-container.mobile{position:absolute;top:0;left:0;z-index:5;opacity:1;visibility:visible;transition:all 1s;height:100%;border-radius:0;max-width:unset}.kwikid-forms-container{display:block;width:100%;max-width:min(50%,600px);margin:auto 0;height:calc(100% - 2rem);padding:.25rem .5rem 0;border-radius:1rem;background-color:var(--tui-base-01);box-shadow:0 0 12px -8px var(--tui-primary)}.kwikid-forms-container.mobile{position:absolute;top:0;left:0;z-index:5;opacity:1;visibility:visible;transition:all 1s;height:100%;border-radius:0;max-width:unset}@media screen and (max-width: 600px){.kwikid-layout-container{padding:0;background:transparent}.kwikid-sections-container{position:absolute;max-width:100%;bottom:-10000px;left:-10000px;opacity:0;padding:0;visibility:hidden}.kwikid-sections-container.active{visibility:visible}.kwikid-sections-container.mobile{height:100%;opacity:1;visibility:visible;transition:all 2s;border-radius:0;box-shadow:none;top:0px;margin:0;position:absolute}.kwikid-forms-container{display:none;max-width:100%;height:100%;padding:0;border-radius:0;box-shadow:none}.kwikid-forms-container.mobile{height:100%;opacity:1;visibility:visible;transition:all 2s;border-radius:0;box-shadow:none;top:0px;margin:0;position:absolute}.kwikid-forms-container.active{display:block}}#error-notification{background-color:var(--tui-error-fill);color:#fff!important}#error-notification .t-top{color:#fff!important}#error-notification .t-close{color:#fff!important}.preview-container{display:flex!important;flex-grow:1!important;flex-direction:column!important;align-content:center!important;justify-content:space-between!important;align-items:stretch!important}.preview-container .preview-iframe{width:100vw;height:100vh}.preview-container .preview-unavailable{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:center;color:#fff;font-size:1.2rem;top:50%;left:50%;width:100%;height:100vh}.preview-container .preview-unavailable>*:not(:last-child){margin-bottom:1rem}.kwikid-form-view-popup-container{border-radius:1rem;background:var(--tui-base-01)}\n", "::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: KwikIDFormsListComponent, selector: "kwikid-forms-list", inputs: ["showFormFields", "userConfig", "stepConfig", "activeFormConfig", "formsList", "formsListCompleted", "isMobileView", "isUnsavedData"], outputs: ["onClickSetActiveForm", "onClickHideFormsList", "onClickSubmitForms"] }, { type: KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: ["formConfig", "formData", "isMobileView", "allFormsData", "userConfig", "apiCallResponse", "buttonClickResponse", "popupFormCallback"], outputs: ["onClickGoBack", "onClickViewForms", "getUnsavedDataState", "onClickSaveForm", "onClickApiCall", "getLogs", "onActionShowPopupForm", "onClickFormFieldButton"] }, { type: i2.KwikUILoaderComponent, selector: "kwikui-loader" }, { type: i5.TuiPushComponent, selector: "tui-push", inputs: ["heading", "type", "timestamp"], outputs: ["close"] }, { type: i3.TuiSvgComponent, selector: "tui-svg", inputs: ["src"] }, { type: i6.TuiPreviewComponent, selector: "tui-preview", inputs: ["zoomable", "rotatable"] }, { type: i6.TuiPreviewTitleComponent, selector: "tui-preview-title" }, { type: i3.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }], directives: [{ type: i3$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.TuiPushAlertDirective, selector: "[tuiPush]", inputs: ["tuiPush"] }, { type: i5.TuiPushDirective, selector: "tui-push" }, { type: i6.TuiPreviewActionDirective, selector: "[tuiPreviewAction]" }], animations: [
|
|
5875
6167
|
trigger("panelInOut", [
|
|
5876
6168
|
transition(":enter", [
|
|
5877
6169
|
style({ transform: "translateY(100%)" }),
|
|
@@ -5948,6 +6240,9 @@ __decorate([
|
|
|
5948
6240
|
__decorate([
|
|
5949
6241
|
logMethod
|
|
5950
6242
|
], KwikIDFormsRendererComponent.prototype, "handleOnClickSubmitForms", null);
|
|
6243
|
+
__decorate([
|
|
6244
|
+
logMethod
|
|
6245
|
+
], KwikIDFormsRendererComponent.prototype, "handleGetLogs", null);
|
|
5951
6246
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: KwikIDFormsRendererComponent, decorators: [{
|
|
5952
6247
|
type: Component,
|
|
5953
6248
|
args: [{
|
|
@@ -5996,9 +6291,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
5996
6291
|
type: Output
|
|
5997
6292
|
}], onClickApiCall: [{
|
|
5998
6293
|
type: Output
|
|
6294
|
+
}], getLogs: [{
|
|
6295
|
+
type: Output
|
|
5999
6296
|
}], onClickFormFieldButton: [{
|
|
6000
6297
|
type: Output
|
|
6001
|
-
}], toggleLoader: [], fetchFormConfig: [], convertFormListConfig: [], assignSequenceNoToForm: [], findCompletedFormsList: [], markFormInFormsListAsCompleted: [], markFormInFormsListAsDisabled: [], filterAllFormsData: [], checkIfFormsStatusCompleted: [], findActiveFormConfig: [], updateFormsList: [], showPreview: [], formHide: [], formShow: [], findFormsListLength: [], handleOnClickSetActiveForm: [], handleGetUnsavedState: [], handleOnClickFormFieldButton: [], handleOnActionShowPopupForm: [], handleOnClickSaveForm: [], handleOnClickGoBack: [], handleOnClickSubmitForms: [] } });
|
|
6298
|
+
}], toggleLoader: [], fetchFormConfig: [], convertFormListConfig: [], assignSequenceNoToForm: [], findCompletedFormsList: [], markFormInFormsListAsCompleted: [], markFormInFormsListAsDisabled: [], filterAllFormsData: [], checkIfFormsStatusCompleted: [], findActiveFormConfig: [], updateFormsList: [], showPreview: [], formHide: [], formShow: [], findFormsListLength: [], handleOnClickSetActiveForm: [], handleGetUnsavedState: [], handleOnClickFormFieldButton: [], handleOnActionShowPopupForm: [], handleOnClickSaveForm: [], handleOnClickGoBack: [], handleOnClickSubmitForms: [], handleGetLogs: [] } });
|
|
6002
6299
|
|
|
6003
6300
|
class JsonFormatPipe {
|
|
6004
6301
|
transform(value) {
|