@formio/js 5.1.0-dev.6056.ba6432d → 5.1.0-dev.6059.845a6e3
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/Changelog.md +13 -131
- package/README.md +1 -28
- package/dist/formio.builder.css +17 -19
- package/dist/formio.builder.min.css +1 -1
- package/dist/formio.embed.js +1 -1
- package/dist/formio.embed.min.js +1 -1
- package/dist/formio.embed.min.js.LICENSE.txt +1 -1
- package/dist/formio.form.css +17 -19
- package/dist/formio.form.js +176 -102
- package/dist/formio.form.min.css +1 -1
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.form.min.js.LICENSE.txt +3 -3
- package/dist/formio.full.css +17 -19
- package/dist/formio.full.js +101 -123
- package/dist/formio.full.min.css +2 -2
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.full.min.js.LICENSE.txt +3 -3
- package/dist/formio.js +10 -10
- package/dist/formio.min.js +1 -1
- package/dist/formio.min.js.LICENSE.txt +1 -1
- package/dist/formio.utils.js +3 -3
- package/dist/formio.utils.min.js +1 -1
- package/dist/formio.utils.min.js.LICENSE.txt +1 -1
- package/lib/cjs/CDN.d.ts +1 -1
- package/lib/cjs/CDN.js +2 -2
- package/lib/cjs/Embed.js +1 -1
- package/lib/cjs/Form.d.ts +6 -4
- package/lib/cjs/Form.js +8 -16
- package/lib/cjs/Formio.js +1 -1
- package/lib/cjs/PDFBuilder.js +4 -4
- package/lib/cjs/Webform.d.ts +13 -16
- package/lib/cjs/Webform.js +148 -162
- package/lib/cjs/WebformBuilder.js +28 -17
- package/lib/cjs/Wizard.js +1 -1
- package/lib/cjs/WizardBuilder.js +2 -15
- package/lib/cjs/components/Components.d.ts +0 -3
- package/lib/cjs/components/_classes/component/Component.d.ts +0 -1
- package/lib/cjs/components/_classes/component/Component.js +11 -38
- package/lib/cjs/components/_classes/component/editForm/Component.edit.conditional.js +1 -1
- package/lib/cjs/components/_classes/component/editForm/Component.edit.data.d.ts +0 -37
- package/lib/cjs/components/_classes/component/editForm/Component.edit.data.js +2 -13
- package/lib/cjs/components/_classes/component/editForm/utils.d.ts +0 -1
- package/lib/cjs/components/_classes/component/editForm/utils.js +0 -3
- package/lib/cjs/components/_classes/input/Input.js +1 -23
- package/lib/cjs/components/_classes/list/ListComponent.js +4 -4
- package/lib/cjs/components/_classes/multivalue/Multivalue.d.ts +1 -1
- package/lib/cjs/components/_classes/multivalue/Multivalue.js +3 -10
- package/lib/cjs/components/_classes/nested/NestedComponent.form.js +0 -13
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +0 -2
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.js +31 -52
- package/lib/cjs/components/address/Address.js +1 -1
- package/lib/cjs/components/button/Button.js +6 -6
- package/lib/cjs/components/checkbox/Checkbox.d.ts +1 -1
- package/lib/cjs/components/checkbox/Checkbox.js +2 -2
- package/lib/cjs/components/content/editForm/Content.edit.display.js +0 -8
- package/lib/cjs/components/currency/editForm/Currency.edit.display.js +0 -12
- package/lib/cjs/components/datagrid/DataGrid.d.ts +0 -2
- package/lib/cjs/components/datagrid/DataGrid.js +26 -41
- package/lib/cjs/components/day/Day.js +7 -9
- package/lib/cjs/components/day/editForm/Day.edit.display.js +0 -8
- package/lib/cjs/components/editgrid/EditGrid.d.ts +1 -1
- package/lib/cjs/components/editgrid/EditGrid.js +8 -26
- package/lib/cjs/components/email/editForm/Email.edit.display.js +0 -12
- package/lib/cjs/components/fieldset/editForm/Fieldset.edit.display.js +0 -8
- package/lib/cjs/components/file/File.d.ts +1 -1
- package/lib/cjs/components/file/File.js +17 -23
- package/lib/cjs/components/form/Form.d.ts +1 -1
- package/lib/cjs/components/form/Form.js +5 -9
- package/lib/cjs/components/form/editForm/Form.edit.form.js +3 -3
- package/lib/cjs/components/hidden/Hidden.d.ts +1 -0
- package/lib/cjs/components/hidden/Hidden.js +1 -1
- package/lib/cjs/components/hidden/editForm/Hidden.edit.display.js +0 -8
- package/lib/cjs/components/html/editForm/HTML.edit.display.js +0 -8
- package/lib/cjs/components/number/Number.js +5 -12
- package/lib/cjs/components/number/editForm/Number.edit.display.js +0 -12
- package/lib/cjs/components/password/editForm/Password.edit.display.js +1 -13
- package/lib/cjs/components/phonenumber/PhoneNumber.form.js +1 -9
- package/lib/cjs/components/radio/Radio.js +0 -10
- package/lib/cjs/components/recaptcha/ReCaptcha.js +2 -2
- package/lib/cjs/components/select/Select.d.ts +1 -0
- package/lib/cjs/components/select/Select.js +33 -12
- package/lib/cjs/components/select/editForm/Select.edit.data.d.ts +1 -1
- package/lib/cjs/components/select/editForm/Select.edit.data.js +2 -3
- package/lib/cjs/components/selectboxes/SelectBoxes.js +2 -2
- package/lib/cjs/components/signature/Signature.d.ts +1 -1
- package/lib/cjs/components/signature/Signature.js +3 -5
- package/lib/cjs/components/signature/editForm/Signature.edit.display.d.ts +6 -0
- package/lib/cjs/components/signature/editForm/Signature.edit.display.js +1 -0
- package/lib/cjs/components/survey/Survey.js +2 -2
- package/lib/cjs/components/tabs/editForm/Tabs.edit.display.js +0 -8
- package/lib/cjs/components/tags/Tags.d.ts +1 -1
- package/lib/cjs/components/tags/Tags.js +2 -2
- package/lib/cjs/components/textarea/TextArea.js +6 -6
- package/lib/cjs/components/textarea/editForm/TextArea.edit.display.js +0 -12
- package/lib/cjs/components/url/editForm/Url.edit.display.js +0 -12
- package/lib/cjs/components/well/editForm/Well.edit.display.js +0 -8
- package/lib/cjs/formio.form.js +0 -5
- package/lib/cjs/providers/storage/googleDrive.js +2 -3
- package/lib/cjs/providers/storage/s3.js +3 -3
- package/lib/cjs/providers/storage/xhr.d.ts +0 -1
- package/lib/cjs/providers/storage/xhr.js +1 -6
- package/lib/cjs/translations/en.d.ts +81 -234
- package/lib/cjs/translations/en.js +81 -8
- package/lib/cjs/utils/ChoicesWrapper.d.ts +25 -4
- package/lib/cjs/utils/ChoicesWrapper.js +124 -47
- package/lib/cjs/utils/formUtils.d.ts +2 -2
- package/lib/cjs/utils/i18n.d.ts +2 -5
- package/lib/cjs/utils/i18n.js +5 -32
- package/lib/cjs/widgets/CalendarWidget.js +27 -27
- package/lib/mjs/CDN.d.ts +1 -1
- package/lib/mjs/CDN.js +2 -2
- package/lib/mjs/Embed.js +1 -1
- package/lib/mjs/Form.d.ts +6 -4
- package/lib/mjs/Form.js +9 -17
- package/lib/mjs/Formio.js +1 -1
- package/lib/mjs/PDFBuilder.js +4 -4
- package/lib/mjs/Webform.d.ts +13 -16
- package/lib/mjs/Webform.js +158 -171
- package/lib/mjs/WebformBuilder.js +28 -17
- package/lib/mjs/Wizard.js +1 -1
- package/lib/mjs/WizardBuilder.js +2 -15
- package/lib/mjs/components/Components.d.ts +0 -3
- package/lib/mjs/components/_classes/component/Component.d.ts +0 -1
- package/lib/mjs/components/_classes/component/Component.js +11 -27
- package/lib/mjs/components/_classes/component/editForm/Component.edit.conditional.js +1 -1
- package/lib/mjs/components/_classes/component/editForm/Component.edit.data.d.ts +0 -37
- package/lib/mjs/components/_classes/component/editForm/Component.edit.data.js +2 -13
- package/lib/mjs/components/_classes/component/editForm/utils.d.ts +0 -1
- package/lib/mjs/components/_classes/component/editForm/utils.js +0 -3
- package/lib/mjs/components/_classes/input/Input.js +1 -22
- package/lib/mjs/components/_classes/list/ListComponent.js +4 -4
- package/lib/mjs/components/_classes/multivalue/Multivalue.d.ts +1 -1
- package/lib/mjs/components/_classes/multivalue/Multivalue.js +3 -10
- package/lib/mjs/components/_classes/nested/NestedComponent.form.js +0 -13
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +0 -2
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.js +31 -53
- package/lib/mjs/components/address/Address.js +1 -1
- package/lib/mjs/components/button/Button.js +6 -6
- package/lib/mjs/components/checkbox/Checkbox.d.ts +1 -1
- package/lib/mjs/components/checkbox/Checkbox.js +2 -2
- package/lib/mjs/components/content/editForm/Content.edit.display.js +0 -8
- package/lib/mjs/components/currency/editForm/Currency.edit.display.js +0 -12
- package/lib/mjs/components/datagrid/DataGrid.d.ts +0 -2
- package/lib/mjs/components/datagrid/DataGrid.js +26 -41
- package/lib/mjs/components/day/Day.js +7 -9
- package/lib/mjs/components/day/editForm/Day.edit.display.js +0 -8
- package/lib/mjs/components/editgrid/EditGrid.d.ts +1 -1
- package/lib/mjs/components/editgrid/EditGrid.js +7 -25
- package/lib/mjs/components/email/editForm/Email.edit.display.js +0 -12
- package/lib/mjs/components/fieldset/editForm/Fieldset.edit.display.js +0 -8
- package/lib/mjs/components/file/File.d.ts +1 -1
- package/lib/mjs/components/file/File.js +17 -23
- package/lib/mjs/components/form/Form.d.ts +1 -1
- package/lib/mjs/components/form/Form.js +5 -8
- package/lib/mjs/components/form/editForm/Form.edit.form.js +3 -3
- package/lib/mjs/components/hidden/Hidden.d.ts +1 -0
- package/lib/mjs/components/hidden/Hidden.js +1 -1
- package/lib/mjs/components/hidden/editForm/Hidden.edit.display.js +0 -8
- package/lib/mjs/components/html/editForm/HTML.edit.display.js +0 -8
- package/lib/mjs/components/number/Number.js +5 -12
- package/lib/mjs/components/number/editForm/Number.edit.display.js +0 -12
- package/lib/mjs/components/password/editForm/Password.edit.display.js +1 -13
- package/lib/mjs/components/phonenumber/PhoneNumber.form.js +1 -9
- package/lib/mjs/components/radio/Radio.js +0 -10
- package/lib/mjs/components/recaptcha/ReCaptcha.js +2 -2
- package/lib/mjs/components/select/Select.d.ts +1 -0
- package/lib/mjs/components/select/Select.js +34 -14
- package/lib/mjs/components/select/editForm/Select.edit.data.d.ts +1 -1
- package/lib/mjs/components/select/editForm/Select.edit.data.js +2 -3
- package/lib/mjs/components/selectboxes/SelectBoxes.js +2 -2
- package/lib/mjs/components/signature/Signature.d.ts +1 -1
- package/lib/mjs/components/signature/Signature.js +3 -5
- package/lib/mjs/components/signature/editForm/Signature.edit.display.d.ts +6 -0
- package/lib/mjs/components/signature/editForm/Signature.edit.display.js +1 -0
- package/lib/mjs/components/survey/Survey.js +2 -2
- package/lib/mjs/components/tabs/editForm/Tabs.edit.display.js +0 -8
- package/lib/mjs/components/tags/Tags.d.ts +1 -1
- package/lib/mjs/components/tags/Tags.js +2 -2
- package/lib/mjs/components/textarea/TextArea.js +6 -6
- package/lib/mjs/components/textarea/editForm/TextArea.edit.display.js +0 -12
- package/lib/mjs/components/url/editForm/Url.edit.display.js +0 -12
- package/lib/mjs/components/well/editForm/Well.edit.display.js +0 -8
- package/lib/mjs/formio.form.js +0 -5
- package/lib/mjs/providers/storage/googleDrive.js +2 -3
- package/lib/mjs/providers/storage/s3.js +3 -3
- package/lib/mjs/providers/storage/xhr.d.ts +0 -1
- package/lib/mjs/providers/storage/xhr.js +1 -6
- package/lib/mjs/translations/en.d.ts +81 -234
- package/lib/mjs/translations/en.js +1 -87
- package/lib/mjs/utils/ChoicesWrapper.d.ts +25 -4
- package/lib/mjs/utils/ChoicesWrapper.js +119 -26
- package/lib/mjs/utils/formUtils.d.ts +2 -2
- package/lib/mjs/utils/i18n.d.ts +2 -5
- package/lib/mjs/utils/i18n.js +5 -32
- package/lib/mjs/widgets/CalendarWidget.js +27 -27
- package/package.json +11 -27
@@ -20,7 +20,7 @@
|
|
20
20
|
|
21
21
|
/*! @license DOMPurify 3.2.4 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.4/LICENSE */
|
22
22
|
|
23
|
-
/*! formiojs v5.1.0-
|
23
|
+
/*! formiojs v5.1.0-rc.26 | https://unpkg.com/formiojs@5.1.0-rc.26/LICENSE.txt */
|
24
24
|
|
25
25
|
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
|
26
26
|
|
package/lib/cjs/CDN.d.ts
CHANGED
package/lib/cjs/CDN.js
CHANGED
@@ -17,8 +17,8 @@ class CDN {
|
|
17
17
|
'bootswatch': '5.3.3',
|
18
18
|
'bootstrap-icons': '1.11.1',
|
19
19
|
'ckeditor': '19.0.0',
|
20
|
-
'
|
21
|
-
'flatpickr': '4.6.13',
|
20
|
+
'flatpickr': '4.6.8',
|
21
|
+
'flatpickr-formio': '4.6.13-formio.3',
|
22
22
|
'font-awesome': '4.7.0',
|
23
23
|
'grid': 'latest',
|
24
24
|
'moment-timezone': 'latest',
|
package/lib/cjs/Embed.js
CHANGED
@@ -418,7 +418,7 @@ Formio.formioReady = new Promise((ready, reject) => {
|
|
418
418
|
_a._formioReady = ready;
|
419
419
|
_a._formioReadyReject = reject;
|
420
420
|
});
|
421
|
-
Formio.version = '5.1.0-
|
421
|
+
Formio.version = '5.1.0-rc.26';
|
422
422
|
// Create a report.
|
423
423
|
Formio.Report = {
|
424
424
|
create: (element, submission, options = {}) => __awaiter(void 0, void 0, void 0, function* () {
|
package/lib/cjs/Form.d.ts
CHANGED
@@ -48,7 +48,7 @@ export default class Form extends Element {
|
|
48
48
|
* @property {number} [saveDraftThrottle] - The throttle for the save draft feature.
|
49
49
|
* @property {boolean} [readOnly] - Set this form to readOnly.
|
50
50
|
* @property {boolean} [noAlerts] - Disable the alerts dialog.
|
51
|
-
* @property {
|
51
|
+
* @property {{[key: string]: string}} [i18n] - The translation file for this rendering.
|
52
52
|
* @property {string} [template] - Custom logic for creation of elements.
|
53
53
|
* @property {boolean} [noDefaults] - Exclude default values from the settings.
|
54
54
|
* @property {any} [fileService] - The file service for this form.
|
@@ -117,7 +117,9 @@ export default class Form extends Element {
|
|
117
117
|
/**
|
118
118
|
* - The translation file for this rendering.
|
119
119
|
*/
|
120
|
-
i18n?:
|
120
|
+
i18n?: {
|
121
|
+
[key: string]: string;
|
122
|
+
} | undefined;
|
121
123
|
/**
|
122
124
|
* - Custom logic for creation of elements.
|
123
125
|
*/
|
@@ -396,10 +398,10 @@ export default class Form extends Element {
|
|
396
398
|
getFormInitOptions(url: string, form: import('@formio/core').Form): object;
|
397
399
|
/**
|
398
400
|
* Sets the form to the JSON schema of a form.
|
399
|
-
* @param {import('@formio/core').Form
|
401
|
+
* @param {import('@formio/core').Form} formParam - The form JSON to set this form to.
|
400
402
|
* @returns {Promise<Webform|Wizard|PDF>} - The webform instance that was created.
|
401
403
|
*/
|
402
|
-
setForm(formParam: import('@formio/core').Form
|
404
|
+
setForm(formParam: import('@formio/core').Form): Promise<Webform | Wizard | PDF>;
|
403
405
|
_form: any;
|
404
406
|
getSubmission(formio: any, opts: any): any;
|
405
407
|
/**
|
package/lib/cjs/Form.js
CHANGED
@@ -195,7 +195,7 @@ class Form extends Element_1.default {
|
|
195
195
|
}
|
196
196
|
/**
|
197
197
|
* Sets the form to the JSON schema of a form.
|
198
|
-
* @param {import('@formio/core').Form
|
198
|
+
* @param {import('@formio/core').Form} formParam - The form JSON to set this form to.
|
199
199
|
* @returns {Promise<Webform|Wizard|PDF>} - The webform instance that was created.
|
200
200
|
*/
|
201
201
|
setForm(formParam) {
|
@@ -222,14 +222,8 @@ class Form extends Element_1.default {
|
|
222
222
|
}
|
223
223
|
this.loading = false;
|
224
224
|
this.instance = this.instance || this.create(form.display);
|
225
|
-
|
226
|
-
|
227
|
-
const options = this.getFormInitOptions(formParam, form);
|
228
|
-
this.instance.setUrl(formParam, options);
|
229
|
-
}
|
230
|
-
else {
|
231
|
-
this.instance.url = formParam;
|
232
|
-
}
|
225
|
+
const options = this.getFormInitOptions(formParam, form);
|
226
|
+
this.instance.setUrl(formParam, options);
|
233
227
|
this.instance.nosubmit = false;
|
234
228
|
this._form = this.instance.form = form;
|
235
229
|
if (submission) {
|
@@ -281,9 +275,7 @@ class Form extends Element_1.default {
|
|
281
275
|
this.form.display = display;
|
282
276
|
this.instance.destroy();
|
283
277
|
this.instance = this.create(display);
|
284
|
-
return this.setForm(this.form)
|
285
|
-
this.instance.emit('setDisplay', this.form.display);
|
286
|
-
});
|
278
|
+
return this.setForm(this.form);
|
287
279
|
}
|
288
280
|
empty() {
|
289
281
|
if (this.element) {
|
@@ -339,10 +331,10 @@ class Form extends Element_1.default {
|
|
339
331
|
*/
|
340
332
|
build() {
|
341
333
|
if (!this.instance) {
|
342
|
-
return Promise.reject(
|
334
|
+
return Promise.reject('Form not ready. Use form.ready promise');
|
343
335
|
}
|
344
336
|
if (!this.element) {
|
345
|
-
return Promise.reject(
|
337
|
+
return Promise.reject('No DOM element for form.');
|
346
338
|
}
|
347
339
|
// Add temporary loader.
|
348
340
|
const template = (this.options && this.options.template) ? this.options.template : 'bootstrap';
|
@@ -359,7 +351,7 @@ class Form extends Element_1.default {
|
|
359
351
|
}
|
360
352
|
render() {
|
361
353
|
if (!this.instance) {
|
362
|
-
return Promise.reject(
|
354
|
+
return Promise.reject('Form not ready. Use form.ready promise');
|
363
355
|
}
|
364
356
|
return Promise.resolve(this.instance.render())
|
365
357
|
.then((param) => {
|
@@ -369,7 +361,7 @@ class Form extends Element_1.default {
|
|
369
361
|
}
|
370
362
|
attach(element) {
|
371
363
|
if (!this.instance) {
|
372
|
-
return Promise.reject(
|
364
|
+
return Promise.reject('Form not ready. Use form.ready promise');
|
373
365
|
}
|
374
366
|
if (this.element) {
|
375
367
|
delete this.element.component;
|
package/lib/cjs/Formio.js
CHANGED
@@ -11,7 +11,7 @@ const CDN_1 = __importDefault(require("./CDN"));
|
|
11
11
|
const providers_1 = __importDefault(require("./providers"));
|
12
12
|
sdk_1.Formio.cdn = new CDN_1.default();
|
13
13
|
sdk_1.Formio.Providers = providers_1.default;
|
14
|
-
sdk_1.Formio.version = '5.1.0-
|
14
|
+
sdk_1.Formio.version = '5.1.0-rc.26';
|
15
15
|
CDN_1.default.defaultCDN = sdk_1.Formio.version.includes('rc') ? 'https://cdn.test-form.io' : 'https://cdn.form.io';
|
16
16
|
const isNil = (val) => val === null || val === undefined;
|
17
17
|
sdk_1.Formio.prototype.uploadFile = function (storage, file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, uploadStartCallback, abortCallback, multipartOptions) {
|
package/lib/cjs/PDFBuilder.js
CHANGED
@@ -201,10 +201,10 @@ class PDFBuilder extends WebformBuilder_1.default {
|
|
201
201
|
const progress = Math.floor((event.loaded / event.total) * 100);
|
202
202
|
this.refs.uploadProgress.style.width = `${progress}%`;
|
203
203
|
if (progress > 98) {
|
204
|
-
this.refs.uploadProgress.innerHTML = this.t('
|
204
|
+
this.refs.uploadProgress.innerHTML = this.t('Converting PDF. Please wait.');
|
205
205
|
}
|
206
206
|
else {
|
207
|
-
this.refs.uploadProgress.innerHTML = `${this.t('
|
207
|
+
this.refs.uploadProgress.innerHTML = `${this.t('Uploading')} ${progress}%`;
|
208
208
|
}
|
209
209
|
}
|
210
210
|
}, `${this.projectUrl}/upload`, {}, 'file')
|
@@ -242,7 +242,7 @@ class PDFBuilder extends WebformBuilder_1.default {
|
|
242
242
|
return;
|
243
243
|
}
|
244
244
|
this.refs.uploadError.style.display = message ? '' : 'none';
|
245
|
-
this.refs.uploadError.innerHTML =
|
245
|
+
this.refs.uploadError.innerHTML = message;
|
246
246
|
}
|
247
247
|
createForm(options) {
|
248
248
|
// Instantiate the webform from the PDF class instead of Webform
|
@@ -471,7 +471,7 @@ class PDFBuilder extends WebformBuilder_1.default {
|
|
471
471
|
name: 'showBuilderErrors',
|
472
472
|
data: {
|
473
473
|
compId: comp.component.id,
|
474
|
-
errorMessage:
|
474
|
+
errorMessage: `API Key is not unique: ${comp.key}`,
|
475
475
|
}
|
476
476
|
});
|
477
477
|
}
|
package/lib/cjs/Webform.d.ts
CHANGED
@@ -34,10 +34,10 @@
|
|
34
34
|
*/
|
35
35
|
/**
|
36
36
|
* @typedef {object} ButtonSettings
|
37
|
-
* @property {boolean} [showPrevious] - Show the
|
38
|
-
* @property {boolean} [showNext] - Show the
|
39
|
-
* @property {boolean} [showCancel] - Show the
|
40
|
-
* @property {boolean} [showSubmit] - Show the
|
37
|
+
* @property {boolean} [showPrevious] - Show the "Previous" button.
|
38
|
+
* @property {boolean} [showNext] - Show the "Next" button.
|
39
|
+
* @property {boolean} [showCancel] - Show the "Cancel" button.
|
40
|
+
* @property {boolean} [showSubmit] - Show the "Submit" button.
|
41
41
|
*/
|
42
42
|
/**
|
43
43
|
* @typedef {object} FormOptions
|
@@ -190,10 +190,7 @@ declare class Webform extends NestedDataComponent {
|
|
190
190
|
get language(): string;
|
191
191
|
root: this;
|
192
192
|
localRoot: this;
|
193
|
-
beforeInit(): void;
|
194
|
-
executeFormController: any;
|
195
193
|
get emptyValue(): null;
|
196
|
-
get shouldCallFormController(): any;
|
197
194
|
get shadowRoot(): any;
|
198
195
|
/**
|
199
196
|
* Add a language for translations
|
@@ -260,7 +257,7 @@ declare class Webform extends NestedDataComponent {
|
|
260
257
|
get ready(): Promise<any>;
|
261
258
|
/**
|
262
259
|
* Set the loading state for this form, and also show the loader spinner.
|
263
|
-
* @param {boolean} loading - If this form should be
|
260
|
+
* @param {boolean} loading - If this form should be "loading" or not.
|
264
261
|
*/
|
265
262
|
set loading(loading: boolean);
|
266
263
|
/**
|
@@ -363,7 +360,7 @@ declare class Webform extends NestedDataComponent {
|
|
363
360
|
* @returns {Promise} - The promise that is triggered when the form is built.
|
364
361
|
*/
|
365
362
|
init(): Promise<any>;
|
366
|
-
|
363
|
+
executeFormController(): false | undefined;
|
367
364
|
build(element: any): Promise<any>;
|
368
365
|
getClassName(): string;
|
369
366
|
render(): string;
|
@@ -372,7 +369,7 @@ declare class Webform extends NestedDataComponent {
|
|
372
369
|
hasRequiredFields(): boolean;
|
373
370
|
/**
|
374
371
|
* Sets a new alert to display in the error dialog of the form.
|
375
|
-
* @param {string} type - The type of alert to display.
|
372
|
+
* @param {string} type - The type of alert to display. "danger", "success", "warning", etc.
|
376
373
|
* @param {string} message - The message to show in the alert.
|
377
374
|
* @param {object} options - The options for the alert.
|
378
375
|
*/
|
@@ -550,19 +547,19 @@ export type SanitizeConfig = {
|
|
550
547
|
};
|
551
548
|
export type ButtonSettings = {
|
552
549
|
/**
|
553
|
-
* - Show the
|
550
|
+
* - Show the "Previous" button.
|
554
551
|
*/
|
555
552
|
showPrevious?: boolean | undefined;
|
556
553
|
/**
|
557
|
-
* - Show the
|
554
|
+
* - Show the "Next" button.
|
558
555
|
*/
|
559
556
|
showNext?: boolean | undefined;
|
560
557
|
/**
|
561
|
-
* - Show the
|
558
|
+
* - Show the "Cancel" button.
|
562
559
|
*/
|
563
560
|
showCancel?: boolean | undefined;
|
564
561
|
/**
|
565
|
-
* - Show the
|
562
|
+
* - Show the "Submit" button.
|
566
563
|
*/
|
567
564
|
showSubmit?: boolean | undefined;
|
568
565
|
};
|
@@ -742,5 +739,5 @@ export type FormOptions = {
|
|
742
739
|
*/
|
743
740
|
zoom?: number | undefined;
|
744
741
|
};
|
745
|
-
import NestedDataComponent from
|
746
|
-
import EventEmitter from
|
742
|
+
import NestedDataComponent from "./components/_classes/nesteddata/NestedDataComponent";
|
743
|
+
import EventEmitter from "./EventEmitter";
|