@formio/js 5.2.3 → 5.2.4-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/formio.builder.css +161 -50
- 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 +158 -49
- package/dist/formio.form.js +152 -108
- package/dist/formio.form.min.css +1 -1
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.form.min.js.LICENSE.txt +1 -1
- package/dist/formio.full.css +161 -50
- package/dist/formio.full.js +401 -227
- package/dist/formio.full.min.css +1 -1
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.full.min.js.LICENSE.txt +1 -1
- package/dist/formio.js +51 -18
- package/dist/formio.min.js +1 -1
- package/dist/formio.min.js.LICENSE.txt +1 -1
- package/dist/formio.utils.js +47 -14
- package/dist/formio.utils.min.js +1 -1
- package/dist/formio.utils.min.js.LICENSE.txt +1 -1
- package/lib/cjs/CDN.js +12 -12
- package/lib/cjs/Element.d.ts +3 -2
- package/lib/cjs/Element.js +27 -21
- package/lib/cjs/Embed.js +74 -40
- package/lib/cjs/EventEmitter.js +1 -1
- package/lib/cjs/Form.d.ts +371 -341
- package/lib/cjs/Form.js +153 -39
- package/lib/cjs/FormBuilder.d.ts +3 -3
- package/lib/cjs/FormBuilder.js +2 -3
- package/lib/cjs/Formio.js +26 -23
- package/lib/cjs/InlineEmbed.js +23 -17
- package/lib/cjs/PDF.d.ts +1 -0
- package/lib/cjs/PDF.js +18 -15
- package/lib/cjs/PDFBuilder.js +51 -36
- package/lib/cjs/Webform.d.ts +8 -366
- package/lib/cjs/Webform.js +176 -235
- package/lib/cjs/WebformBuilder.js +217 -144
- package/lib/cjs/Wizard.js +92 -62
- package/lib/cjs/WizardBuilder.js +27 -19
- package/lib/cjs/addons/FormioAddon.js +1 -1
- package/lib/cjs/addons/PasswordStrength/PasswordStrengthAddon.form.js +59 -57
- package/lib/cjs/addons/PasswordStrength/PasswordStrengthAddon.js +24 -16
- package/lib/cjs/addons/index.js +3 -3
- package/lib/cjs/components/Components.js +0 -4
- package/lib/cjs/components/_classes/component/Component.form.js +11 -11
- package/lib/cjs/components/_classes/component/Component.js +298 -179
- package/lib/cjs/components/_classes/component/editForm/Component.edit.addons.js +2 -4
- package/lib/cjs/components/_classes/component/editForm/Component.edit.api.js +5 -5
- package/lib/cjs/components/_classes/component/editForm/Component.edit.conditional.js +9 -11
- package/lib/cjs/components/_classes/component/editForm/Component.edit.data.d.ts +37 -0
- package/lib/cjs/components/_classes/component/editForm/Component.edit.data.js +39 -25
- package/lib/cjs/components/_classes/component/editForm/Component.edit.display.js +47 -29
- package/lib/cjs/components/_classes/component/editForm/Component.edit.layout.js +9 -9
- package/lib/cjs/components/_classes/component/editForm/Component.edit.logic.js +5 -7
- package/lib/cjs/components/_classes/component/editForm/Component.edit.validation.js +37 -34
- package/lib/cjs/components/_classes/component/editForm/utils.js +12 -16
- package/lib/cjs/components/_classes/componentModal/ComponentModal.js +6 -6
- package/lib/cjs/components/_classes/field/Field.js +7 -1
- package/lib/cjs/components/_classes/input/Input.js +30 -26
- package/lib/cjs/components/_classes/list/ListComponent.form.js +1 -1
- package/lib/cjs/components/_classes/list/ListComponent.js +27 -18
- package/lib/cjs/components/_classes/list/editForm/ListComponent.edit.data.js +36 -9
- package/lib/cjs/components/_classes/multivalue/Multivalue.js +32 -13
- package/lib/cjs/components/_classes/nested/NestedComponent.form.js +3 -3
- package/lib/cjs/components/_classes/nested/NestedComponent.js +36 -32
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.js +19 -14
- package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.js +19 -17
- package/lib/cjs/components/address/Address.js +52 -45
- package/lib/cjs/components/address/editForm/Address.edit.data.js +2 -2
- package/lib/cjs/components/address/editForm/Address.edit.display.js +2 -2
- package/lib/cjs/components/address/editForm/Address.edit.provider.js +53 -11
- package/lib/cjs/components/alert/Alert.js +21 -15
- package/lib/cjs/components/button/Button.form.js +1 -1
- package/lib/cjs/components/button/Button.js +50 -27
- package/lib/cjs/components/button/editForm/Button.edit.display.js +49 -9
- package/lib/cjs/components/checkbox/Checkbox.d.ts +1 -1
- package/lib/cjs/components/checkbox/Checkbox.form.js +3 -3
- package/lib/cjs/components/checkbox/Checkbox.js +28 -20
- package/lib/cjs/components/checkbox/editForm/Checkbox.edit.data.js +1 -1
- package/lib/cjs/components/checkbox/editForm/Checkbox.edit.display.js +13 -3
- package/lib/cjs/components/checkbox/editForm/Checkbox.edit.validation.js +2 -2
- package/lib/cjs/components/columns/Columns.form.js +1 -1
- package/lib/cjs/components/columns/Columns.js +24 -12
- package/lib/cjs/components/columns/editForm/Columns.edit.display.js +17 -17
- package/lib/cjs/components/container/Container.form.js +2 -2
- package/lib/cjs/components/container/Container.js +6 -4
- package/lib/cjs/components/container/editForm/Container.edit.data.js +3 -3
- package/lib/cjs/components/container/editForm/Container.edit.display.js +4 -4
- package/lib/cjs/components/content/Content.form.js +4 -2
- package/lib/cjs/components/content/Content.js +10 -8
- package/lib/cjs/components/content/editForm/Content.edit.display.js +10 -10
- package/lib/cjs/components/currency/Currency.form.js +3 -3
- package/lib/cjs/components/currency/Currency.js +19 -10
- package/lib/cjs/components/currency/editForm/Currency.edit.data.js +5 -5
- package/lib/cjs/components/currency/editForm/Currency.edit.display.js +8 -8
- package/lib/cjs/components/datagrid/DataGrid.form.js +3 -3
- package/lib/cjs/components/datagrid/DataGrid.js +89 -38
- package/lib/cjs/components/datagrid/editForm/DataGrid.edit.data.js +1 -1
- package/lib/cjs/components/datagrid/editForm/DataGrid.edit.display.js +14 -14
- package/lib/cjs/components/datagrid/editForm/DataGrid.edit.validation.js +3 -3
- package/lib/cjs/components/datamap/DataMap.form.js +2 -2
- package/lib/cjs/components/datamap/DataMap.js +44 -31
- package/lib/cjs/components/datamap/editForm/DataMap.edit.data.js +1 -1
- package/lib/cjs/components/datamap/editForm/DataMap.edit.display.js +8 -8
- package/lib/cjs/components/datetime/DateTime.form.js +5 -5
- package/lib/cjs/components/datetime/DateTime.js +30 -15
- package/lib/cjs/components/datetime/editForm/DateTime.edit.data.js +4 -3
- package/lib/cjs/components/datetime/editForm/DateTime.edit.date.js +10 -10
- package/lib/cjs/components/datetime/editForm/DateTime.edit.display.js +22 -17
- package/lib/cjs/components/datetime/editForm/DateTime.edit.time.js +5 -5
- package/lib/cjs/components/datetime/editForm/DateTime.edit.validation.js +3 -3
- package/lib/cjs/components/day/Day.form.js +5 -5
- package/lib/cjs/components/day/Day.js +146 -56
- package/lib/cjs/components/day/editForm/Day.edit.day.js +13 -9
- package/lib/cjs/components/day/editForm/Day.edit.display.js +7 -7
- package/lib/cjs/components/day/editForm/Day.edit.month.js +12 -8
- package/lib/cjs/components/day/editForm/Day.edit.validation.js +7 -7
- package/lib/cjs/components/day/editForm/Day.edit.year.js +8 -8
- package/lib/cjs/components/editgrid/EditGrid.form.js +2 -2
- package/lib/cjs/components/editgrid/EditGrid.js +137 -89
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.data.js +2 -2
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.display.js +7 -2
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.templates.js +16 -16
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.validation.js +3 -3
- package/lib/cjs/components/email/Email.js +4 -4
- package/lib/cjs/components/email/editForm/Email.edit.display.js +3 -3
- package/lib/cjs/components/email/editForm/Email.edit.validation.js +6 -6
- package/lib/cjs/components/fieldset/Fieldset.form.js +1 -1
- package/lib/cjs/components/fieldset/Fieldset.js +2 -2
- package/lib/cjs/components/fieldset/editForm/Fieldset.edit.display.js +8 -8
- package/lib/cjs/components/file/File.form.js +4 -4
- package/lib/cjs/components/file/File.js +126 -80
- package/lib/cjs/components/file/editForm/File.edit.display.js +9 -5
- package/lib/cjs/components/file/editForm/File.edit.file.d.ts +37 -16
- package/lib/cjs/components/file/editForm/File.edit.file.js +169 -72
- package/lib/cjs/components/file/editForm/File.edit.validation.js +2 -2
- package/lib/cjs/components/form/Form.form.js +3 -3
- package/lib/cjs/components/form/Form.js +67 -51
- package/lib/cjs/components/form/editForm/Form.edit.data.js +1 -3
- package/lib/cjs/components/form/editForm/Form.edit.display.js +6 -7
- package/lib/cjs/components/form/editForm/Form.edit.form.js +11 -9
- package/lib/cjs/components/hidden/Hidden.form.js +4 -4
- package/lib/cjs/components/hidden/Hidden.js +2 -2
- package/lib/cjs/components/hidden/editForm/Hidden.edit.data.js +3 -3
- package/lib/cjs/components/hidden/editForm/Hidden.edit.display.js +10 -10
- package/lib/cjs/components/html/HTML.js +23 -17
- package/lib/cjs/components/html/editForm/HTML.edit.display.js +17 -17
- package/lib/cjs/components/html/editForm/HTML.edit.logic.js +2 -2
- package/lib/cjs/components/number/Number.form.js +3 -3
- package/lib/cjs/components/number/Number.js +27 -11
- package/lib/cjs/components/number/editForm/Number.edit.data.js +3 -3
- package/lib/cjs/components/number/editForm/Number.edit.display.js +4 -4
- package/lib/cjs/components/number/editForm/Number.edit.validation.js +9 -9
- package/lib/cjs/components/panel/Panel.form.js +1 -1
- package/lib/cjs/components/panel/Panel.js +2 -2
- package/lib/cjs/components/panel/editForm/Panel.edit.conditional.js +5 -7
- package/lib/cjs/components/panel/editForm/Panel.edit.display.js +55 -29
- package/lib/cjs/components/password/Password.form.js +3 -3
- package/lib/cjs/components/password/Password.js +5 -2
- package/lib/cjs/components/password/editForm/Password.edit.data.js +11 -11
- package/lib/cjs/components/password/editForm/Password.edit.display.js +3 -3
- package/lib/cjs/components/password/editForm/Password.edit.validation.js +3 -3
- package/lib/cjs/components/phonenumber/PhoneNumber.form.js +8 -8
- package/lib/cjs/components/phonenumber/PhoneNumber.js +3 -3
- package/lib/cjs/components/phonenumber/editForm/PhoneNumber.edit.validation.js +6 -6
- package/lib/cjs/components/radio/Radio.form.js +3 -3
- package/lib/cjs/components/radio/Radio.js +55 -26
- package/lib/cjs/components/radio/editForm/Radio.edit.data.js +23 -9
- package/lib/cjs/components/radio/editForm/Radio.edit.display.js +6 -6
- package/lib/cjs/components/radio/editForm/Radio.edit.validation.js +2 -2
- package/lib/cjs/components/recaptcha/ReCaptcha.form.js +5 -5
- package/lib/cjs/components/recaptcha/ReCaptcha.js +7 -5
- package/lib/cjs/components/recaptcha/editForm/ReCaptcha.edit.display.js +24 -24
- package/lib/cjs/components/select/Select.form.js +3 -3
- package/lib/cjs/components/select/Select.js +235 -129
- package/lib/cjs/components/select/editForm/Select.edit.data.d.ts +1 -1
- package/lib/cjs/components/select/editForm/Select.edit.data.js +191 -57
- package/lib/cjs/components/select/editForm/Select.edit.display.js +2 -2
- package/lib/cjs/components/select/editForm/Select.edit.validation.js +4 -4
- package/lib/cjs/components/selectboxes/SelectBoxes.form.js +3 -3
- package/lib/cjs/components/selectboxes/SelectBoxes.js +31 -15
- package/lib/cjs/components/selectboxes/editForm/SelectBoxes.edit.validation.js +5 -5
- package/lib/cjs/components/signature/Signature.form.js +3 -3
- package/lib/cjs/components/signature/Signature.js +25 -15
- package/lib/cjs/components/signature/editForm/Signature.edit.display.js +19 -10
- package/lib/cjs/components/survey/Survey.form.js +3 -3
- package/lib/cjs/components/survey/Survey.js +30 -17
- package/lib/cjs/components/survey/editForm/Survey.edit.data.js +23 -11
- package/lib/cjs/components/survey/editForm/Survey.edit.display.js +1 -1
- package/lib/cjs/components/survey/editForm/Survey.edit.validation.js +1 -1
- package/lib/cjs/components/table/Table.form.js +1 -1
- package/lib/cjs/components/table/Table.js +7 -5
- package/lib/cjs/components/table/editForm/Table.edit.display.js +22 -22
- package/lib/cjs/components/tabs/Tabs.form.js +1 -1
- package/lib/cjs/components/tabs/Tabs.js +26 -8
- package/lib/cjs/components/tabs/editForm/Tabs.edit.display.js +21 -17
- package/lib/cjs/components/tags/Tags.form.js +1 -1
- package/lib/cjs/components/tags/Tags.js +28 -12
- package/lib/cjs/components/tags/editForm/Tags.edit.data.js +7 -7
- package/lib/cjs/components/textarea/TextArea.form.js +2 -2
- package/lib/cjs/components/textarea/TextArea.js +63 -45
- package/lib/cjs/components/textarea/editForm/TextArea.edit.display.js +96 -72
- package/lib/cjs/components/textarea/editForm/TextArea.edit.validation.js +3 -3
- package/lib/cjs/components/textfield/TextField.form.js +3 -3
- package/lib/cjs/components/textfield/TextField.js +32 -21
- package/lib/cjs/components/textfield/editForm/TextField.edit.data.js +15 -13
- package/lib/cjs/components/textfield/editForm/TextField.edit.display.js +31 -21
- package/lib/cjs/components/textfield/editForm/TextField.edit.validation.js +6 -6
- package/lib/cjs/components/time/Time.js +17 -10
- package/lib/cjs/components/time/editForm/Time.edit.display.js +2 -2
- package/lib/cjs/components/unknown/Unknown.form.js +5 -5
- package/lib/cjs/components/unknown/Unknown.js +2 -2
- package/lib/cjs/components/unknown/editForm/Unknown.edit.display.js +3 -3
- package/lib/cjs/components/url/Url.form.js +3 -3
- package/lib/cjs/components/url/Url.js +2 -2
- package/lib/cjs/components/url/editForm/Url.edit.display.js +3 -3
- package/lib/cjs/components/url/editForm/Url.edit.validation.js +1 -1
- package/lib/cjs/components/well/Well.form.js +1 -1
- package/lib/cjs/components/well/Well.js +2 -2
- package/lib/cjs/components/well/editForm/Well.edit.display.js +10 -10
- package/lib/cjs/formio.form.d.ts +2 -1
- package/lib/cjs/formio.form.js +38 -12
- package/lib/cjs/i18n.d.ts +4 -0
- package/lib/cjs/i18n.js +7 -3
- package/lib/cjs/package.json +1 -1
- package/lib/cjs/providers/address/AddressProvider.js +8 -5
- package/lib/cjs/providers/address/GoogleAddressProvider.d.ts +3 -3
- package/lib/cjs/providers/address/GoogleAddressProvider.js +24 -13
- package/lib/cjs/providers/processor/fileProcessor.js +3 -1
- package/lib/cjs/providers/storage/azure.js +5 -2
- package/lib/cjs/providers/storage/dropbox.js +4 -5
- package/lib/cjs/providers/storage/googleDrive.js +3 -4
- package/lib/cjs/providers/storage/index.js +1 -1
- package/lib/cjs/providers/storage/indexeddb.js +16 -6
- package/lib/cjs/providers/storage/s3.js +17 -6
- package/lib/cjs/providers/storage/uploadAdapter.js +17 -11
- package/lib/cjs/providers/storage/url.js +13 -11
- package/lib/cjs/providers/storage/xhr.js +17 -9
- package/lib/cjs/templates/index.js +1 -1
- package/lib/cjs/translations/de.d.ts +80 -0
- package/lib/cjs/translations/de.js +81 -0
- package/lib/cjs/translations/en.d.ts +0 -2
- package/lib/cjs/translations/en.js +7 -9
- package/lib/cjs/utils/ChoicesWrapper.js +2 -2
- package/lib/cjs/utils/builder.js +31 -7
- package/lib/cjs/utils/calendarUtils.js +7 -5
- package/lib/cjs/utils/conditionOperators/ConditionOperator.js +1 -1
- package/lib/cjs/utils/conditionOperators/DateGreaterThan.js +12 -4
- package/lib/cjs/utils/conditionOperators/IsEmptyValue.js +3 -1
- package/lib/cjs/utils/conditionOperators/IsEqualTo.js +10 -6
- package/lib/cjs/utils/conditionOperators/index.js +1 -1
- package/lib/cjs/utils/formUtils.js +1 -1
- package/lib/cjs/utils/i18n.js +7 -1
- package/lib/cjs/utils/index.d.ts +2 -1
- package/lib/cjs/utils/index.js +2 -2
- package/lib/cjs/utils/utils.d.ts +10 -1
- package/lib/cjs/utils/utils.js +175 -92
- package/lib/cjs/widgets/CalendarWidget.js +66 -49
- package/lib/cjs/widgets/InputWidget.js +6 -4
- package/lib/cjs/widgets/index.js +1 -1
- package/lib/mjs/CDN.js +12 -12
- package/lib/mjs/Element.d.ts +3 -2
- package/lib/mjs/Element.js +27 -21
- package/lib/mjs/Embed.js +76 -42
- package/lib/mjs/EventEmitter.js +1 -1
- package/lib/mjs/Form.d.ts +371 -341
- package/lib/mjs/Form.js +142 -126
- package/lib/mjs/FormBuilder.d.ts +3 -3
- package/lib/mjs/FormBuilder.js +2 -3
- package/lib/mjs/Formio.js +26 -23
- package/lib/mjs/InlineEmbed.js +23 -17
- package/lib/mjs/PDF.d.ts +1 -0
- package/lib/mjs/PDF.js +18 -15
- package/lib/mjs/PDFBuilder.js +51 -36
- package/lib/mjs/Webform.d.ts +8 -366
- package/lib/mjs/Webform.js +183 -250
- package/lib/mjs/WebformBuilder.js +220 -147
- package/lib/mjs/Wizard.js +93 -63
- package/lib/mjs/WizardBuilder.js +27 -19
- package/lib/mjs/addons/FormioAddon.js +1 -1
- package/lib/mjs/addons/PasswordStrength/PasswordStrengthAddon.form.js +59 -57
- package/lib/mjs/addons/PasswordStrength/PasswordStrengthAddon.js +24 -16
- package/lib/mjs/addons/index.js +3 -3
- package/lib/mjs/components/Components.js +0 -4
- package/lib/mjs/components/_classes/component/Component.form.js +11 -11
- package/lib/mjs/components/_classes/component/Component.js +303 -184
- package/lib/mjs/components/_classes/component/editForm/Component.edit.addons.js +2 -4
- package/lib/mjs/components/_classes/component/editForm/Component.edit.api.js +5 -5
- package/lib/mjs/components/_classes/component/editForm/Component.edit.conditional.js +9 -11
- package/lib/mjs/components/_classes/component/editForm/Component.edit.data.d.ts +37 -0
- package/lib/mjs/components/_classes/component/editForm/Component.edit.data.js +39 -25
- package/lib/mjs/components/_classes/component/editForm/Component.edit.display.js +47 -29
- package/lib/mjs/components/_classes/component/editForm/Component.edit.layout.js +9 -9
- package/lib/mjs/components/_classes/component/editForm/Component.edit.logic.js +5 -7
- package/lib/mjs/components/_classes/component/editForm/Component.edit.validation.js +37 -34
- package/lib/mjs/components/_classes/component/editForm/utils.js +12 -16
- package/lib/mjs/components/_classes/componentModal/ComponentModal.js +2 -2
- package/lib/mjs/components/_classes/field/Field.js +8 -2
- package/lib/mjs/components/_classes/input/Input.js +27 -23
- package/lib/mjs/components/_classes/list/ListComponent.form.js +1 -1
- package/lib/mjs/components/_classes/list/ListComponent.js +27 -18
- package/lib/mjs/components/_classes/list/editForm/ListComponent.edit.data.js +36 -9
- package/lib/mjs/components/_classes/multivalue/Multivalue.js +32 -13
- package/lib/mjs/components/_classes/nested/NestedComponent.form.js +3 -3
- package/lib/mjs/components/_classes/nested/NestedComponent.js +32 -28
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.js +20 -15
- package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.js +19 -17
- package/lib/mjs/components/address/Address.js +57 -46
- package/lib/mjs/components/address/editForm/Address.edit.data.js +2 -2
- package/lib/mjs/components/address/editForm/Address.edit.display.js +2 -2
- package/lib/mjs/components/address/editForm/Address.edit.provider.js +53 -11
- package/lib/mjs/components/alert/Alert.js +22 -16
- package/lib/mjs/components/button/Button.form.js +1 -1
- package/lib/mjs/components/button/Button.js +51 -28
- package/lib/mjs/components/button/editForm/Button.edit.display.js +49 -9
- package/lib/mjs/components/checkbox/Checkbox.d.ts +1 -1
- package/lib/mjs/components/checkbox/Checkbox.form.js +3 -3
- package/lib/mjs/components/checkbox/Checkbox.js +29 -21
- package/lib/mjs/components/checkbox/editForm/Checkbox.edit.data.js +1 -1
- package/lib/mjs/components/checkbox/editForm/Checkbox.edit.display.js +13 -3
- package/lib/mjs/components/checkbox/editForm/Checkbox.edit.validation.js +2 -2
- package/lib/mjs/components/columns/Columns.form.js +1 -1
- package/lib/mjs/components/columns/Columns.js +24 -12
- package/lib/mjs/components/columns/editForm/Columns.edit.display.js +17 -17
- package/lib/mjs/components/container/Container.form.js +2 -2
- package/lib/mjs/components/container/Container.js +6 -4
- package/lib/mjs/components/container/editForm/Container.edit.data.js +3 -3
- package/lib/mjs/components/container/editForm/Container.edit.display.js +4 -4
- package/lib/mjs/components/content/Content.form.js +4 -2
- package/lib/mjs/components/content/Content.js +10 -8
- package/lib/mjs/components/content/editForm/Content.edit.display.js +10 -10
- package/lib/mjs/components/currency/Currency.form.js +3 -3
- package/lib/mjs/components/currency/Currency.js +19 -10
- package/lib/mjs/components/currency/editForm/Currency.edit.data.js +5 -5
- package/lib/mjs/components/currency/editForm/Currency.edit.display.js +8 -8
- package/lib/mjs/components/datagrid/DataGrid.form.js +3 -3
- package/lib/mjs/components/datagrid/DataGrid.js +90 -39
- package/lib/mjs/components/datagrid/editForm/DataGrid.edit.data.js +1 -1
- package/lib/mjs/components/datagrid/editForm/DataGrid.edit.display.js +14 -14
- package/lib/mjs/components/datagrid/editForm/DataGrid.edit.validation.js +3 -3
- package/lib/mjs/components/datamap/DataMap.form.js +2 -2
- package/lib/mjs/components/datamap/DataMap.js +44 -31
- package/lib/mjs/components/datamap/editForm/DataMap.edit.data.js +1 -1
- package/lib/mjs/components/datamap/editForm/DataMap.edit.display.js +8 -8
- package/lib/mjs/components/datetime/DateTime.form.js +5 -5
- package/lib/mjs/components/datetime/DateTime.js +31 -16
- package/lib/mjs/components/datetime/editForm/DateTime.edit.data.js +4 -3
- package/lib/mjs/components/datetime/editForm/DateTime.edit.date.js +10 -10
- package/lib/mjs/components/datetime/editForm/DateTime.edit.display.js +22 -17
- package/lib/mjs/components/datetime/editForm/DateTime.edit.time.js +5 -5
- package/lib/mjs/components/datetime/editForm/DateTime.edit.validation.js +3 -3
- package/lib/mjs/components/day/Day.form.js +5 -5
- package/lib/mjs/components/day/Day.js +147 -57
- package/lib/mjs/components/day/editForm/Day.edit.day.js +13 -9
- package/lib/mjs/components/day/editForm/Day.edit.display.js +7 -7
- package/lib/mjs/components/day/editForm/Day.edit.month.js +12 -8
- package/lib/mjs/components/day/editForm/Day.edit.validation.js +7 -7
- package/lib/mjs/components/day/editForm/Day.edit.year.js +8 -8
- package/lib/mjs/components/editgrid/EditGrid.form.js +2 -2
- package/lib/mjs/components/editgrid/EditGrid.js +138 -90
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.data.js +2 -2
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.display.js +7 -2
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.templates.js +16 -16
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.validation.js +3 -3
- package/lib/mjs/components/email/Email.js +4 -4
- package/lib/mjs/components/email/editForm/Email.edit.display.js +3 -3
- package/lib/mjs/components/email/editForm/Email.edit.validation.js +6 -6
- package/lib/mjs/components/fieldset/Fieldset.form.js +1 -1
- package/lib/mjs/components/fieldset/Fieldset.js +2 -2
- package/lib/mjs/components/fieldset/editForm/Fieldset.edit.display.js +8 -8
- package/lib/mjs/components/file/File.form.js +4 -4
- package/lib/mjs/components/file/File.js +131 -84
- package/lib/mjs/components/file/editForm/File.edit.display.js +9 -5
- package/lib/mjs/components/file/editForm/File.edit.file.d.ts +37 -16
- package/lib/mjs/components/file/editForm/File.edit.file.js +169 -72
- package/lib/mjs/components/file/editForm/File.edit.validation.js +2 -2
- package/lib/mjs/components/form/Form.form.js +3 -3
- package/lib/mjs/components/form/Form.js +67 -51
- package/lib/mjs/components/form/editForm/Form.edit.data.js +1 -3
- package/lib/mjs/components/form/editForm/Form.edit.display.js +6 -7
- package/lib/mjs/components/form/editForm/Form.edit.form.js +10 -8
- package/lib/mjs/components/hidden/Hidden.form.js +4 -4
- package/lib/mjs/components/hidden/Hidden.js +2 -2
- package/lib/mjs/components/hidden/editForm/Hidden.edit.data.js +3 -3
- package/lib/mjs/components/hidden/editForm/Hidden.edit.display.js +10 -10
- package/lib/mjs/components/html/HTML.js +23 -17
- package/lib/mjs/components/html/editForm/HTML.edit.display.js +17 -17
- package/lib/mjs/components/html/editForm/HTML.edit.logic.js +2 -2
- package/lib/mjs/components/number/Number.form.js +3 -3
- package/lib/mjs/components/number/Number.js +28 -12
- package/lib/mjs/components/number/editForm/Number.edit.data.js +3 -3
- package/lib/mjs/components/number/editForm/Number.edit.display.js +4 -4
- package/lib/mjs/components/number/editForm/Number.edit.validation.js +9 -9
- package/lib/mjs/components/panel/Panel.form.js +1 -1
- package/lib/mjs/components/panel/Panel.js +2 -2
- package/lib/mjs/components/panel/editForm/Panel.edit.conditional.js +6 -8
- package/lib/mjs/components/panel/editForm/Panel.edit.display.js +55 -29
- package/lib/mjs/components/password/Password.form.js +3 -3
- package/lib/mjs/components/password/Password.js +5 -2
- package/lib/mjs/components/password/editForm/Password.edit.data.js +11 -11
- package/lib/mjs/components/password/editForm/Password.edit.display.js +3 -3
- package/lib/mjs/components/password/editForm/Password.edit.validation.js +3 -3
- package/lib/mjs/components/phonenumber/PhoneNumber.form.js +8 -8
- package/lib/mjs/components/phonenumber/PhoneNumber.js +3 -3
- package/lib/mjs/components/phonenumber/editForm/PhoneNumber.edit.validation.js +6 -6
- package/lib/mjs/components/radio/Radio.form.js +3 -3
- package/lib/mjs/components/radio/Radio.js +56 -27
- package/lib/mjs/components/radio/editForm/Radio.edit.data.js +23 -9
- package/lib/mjs/components/radio/editForm/Radio.edit.display.js +6 -6
- package/lib/mjs/components/radio/editForm/Radio.edit.validation.js +2 -2
- package/lib/mjs/components/recaptcha/ReCaptcha.form.js +5 -5
- package/lib/mjs/components/recaptcha/ReCaptcha.js +7 -5
- package/lib/mjs/components/recaptcha/editForm/ReCaptcha.edit.display.js +24 -24
- package/lib/mjs/components/select/Select.form.js +3 -3
- package/lib/mjs/components/select/Select.js +240 -134
- package/lib/mjs/components/select/editForm/Select.edit.data.d.ts +1 -1
- package/lib/mjs/components/select/editForm/Select.edit.data.js +191 -57
- package/lib/mjs/components/select/editForm/Select.edit.display.js +2 -2
- package/lib/mjs/components/select/editForm/Select.edit.validation.js +4 -4
- package/lib/mjs/components/selectboxes/SelectBoxes.form.js +3 -3
- package/lib/mjs/components/selectboxes/SelectBoxes.js +32 -16
- package/lib/mjs/components/selectboxes/editForm/SelectBoxes.edit.validation.js +5 -5
- package/lib/mjs/components/signature/Signature.form.js +3 -3
- package/lib/mjs/components/signature/Signature.js +25 -15
- package/lib/mjs/components/signature/editForm/Signature.edit.display.js +19 -10
- package/lib/mjs/components/survey/Survey.form.js +3 -3
- package/lib/mjs/components/survey/Survey.js +30 -17
- package/lib/mjs/components/survey/editForm/Survey.edit.data.js +23 -11
- package/lib/mjs/components/survey/editForm/Survey.edit.display.js +1 -1
- package/lib/mjs/components/survey/editForm/Survey.edit.validation.js +1 -1
- package/lib/mjs/components/table/Table.form.js +1 -1
- package/lib/mjs/components/table/Table.js +7 -5
- package/lib/mjs/components/table/editForm/Table.edit.display.js +22 -22
- package/lib/mjs/components/tabs/Tabs.form.js +1 -1
- package/lib/mjs/components/tabs/Tabs.js +26 -8
- package/lib/mjs/components/tabs/editForm/Tabs.edit.display.js +21 -17
- package/lib/mjs/components/tags/Tags.form.js +1 -1
- package/lib/mjs/components/tags/Tags.js +28 -12
- package/lib/mjs/components/tags/editForm/Tags.edit.data.js +7 -7
- package/lib/mjs/components/textarea/TextArea.form.js +2 -2
- package/lib/mjs/components/textarea/TextArea.js +75 -51
- package/lib/mjs/components/textarea/editForm/TextArea.edit.display.js +96 -72
- package/lib/mjs/components/textarea/editForm/TextArea.edit.validation.js +3 -3
- package/lib/mjs/components/textfield/TextField.form.js +3 -3
- package/lib/mjs/components/textfield/TextField.js +34 -23
- package/lib/mjs/components/textfield/editForm/TextField.edit.data.js +15 -13
- package/lib/mjs/components/textfield/editForm/TextField.edit.display.js +31 -21
- package/lib/mjs/components/textfield/editForm/TextField.edit.validation.js +6 -6
- package/lib/mjs/components/time/Time.js +17 -10
- package/lib/mjs/components/time/editForm/Time.edit.display.js +2 -2
- package/lib/mjs/components/unknown/Unknown.form.js +5 -5
- package/lib/mjs/components/unknown/Unknown.js +2 -2
- package/lib/mjs/components/unknown/editForm/Unknown.edit.display.js +3 -3
- package/lib/mjs/components/url/Url.form.js +3 -3
- package/lib/mjs/components/url/Url.js +2 -2
- package/lib/mjs/components/url/editForm/Url.edit.display.js +3 -3
- package/lib/mjs/components/url/editForm/Url.edit.validation.js +1 -1
- package/lib/mjs/components/well/Well.form.js +1 -1
- package/lib/mjs/components/well/Well.js +2 -2
- package/lib/mjs/components/well/editForm/Well.edit.display.js +10 -10
- package/lib/mjs/formio.form.d.ts +2 -1
- package/lib/mjs/formio.form.js +10 -8
- package/lib/mjs/i18n.d.ts +4 -0
- package/lib/mjs/i18n.js +7 -3
- package/lib/mjs/package.json +1 -1
- package/lib/mjs/providers/address/AddressProvider.js +8 -5
- package/lib/mjs/providers/address/GoogleAddressProvider.d.ts +3 -3
- package/lib/mjs/providers/address/GoogleAddressProvider.js +24 -13
- package/lib/mjs/providers/processor/fileProcessor.js +3 -1
- package/lib/mjs/providers/storage/azure.js +5 -2
- package/lib/mjs/providers/storage/dropbox.js +4 -5
- package/lib/mjs/providers/storage/googleDrive.js +3 -4
- package/lib/mjs/providers/storage/index.js +1 -1
- package/lib/mjs/providers/storage/indexeddb.js +16 -6
- package/lib/mjs/providers/storage/s3.js +19 -8
- package/lib/mjs/providers/storage/uploadAdapter.js +17 -11
- package/lib/mjs/providers/storage/url.js +13 -11
- package/lib/mjs/providers/storage/xhr.js +17 -9
- package/lib/mjs/templates/index.js +1 -1
- package/lib/mjs/translations/de.d.ts +80 -0
- package/lib/mjs/translations/de.js +79 -0
- package/lib/mjs/translations/en.d.ts +0 -2
- package/lib/mjs/translations/en.js +7 -9
- package/lib/mjs/utils/ChoicesWrapper.js +2 -2
- package/lib/mjs/utils/builder.js +31 -7
- package/lib/mjs/utils/calendarUtils.js +7 -5
- package/lib/mjs/utils/conditionOperators/ConditionOperator.js +1 -1
- package/lib/mjs/utils/conditionOperators/DateGreaterThan.js +16 -5
- package/lib/mjs/utils/conditionOperators/IsEmptyValue.js +3 -1
- package/lib/mjs/utils/conditionOperators/IsEqualTo.js +10 -6
- package/lib/mjs/utils/conditionOperators/index.js +1 -1
- package/lib/mjs/utils/formUtils.js +2 -2
- package/lib/mjs/utils/i18n.js +7 -1
- package/lib/mjs/utils/index.d.ts +2 -1
- package/lib/mjs/utils/index.js +3 -3
- package/lib/mjs/utils/utils.d.ts +10 -1
- package/lib/mjs/utils/utils.js +178 -91
- package/lib/mjs/widgets/CalendarWidget.js +67 -50
- package/lib/mjs/widgets/InputWidget.js +6 -4
- package/lib/mjs/widgets/index.js +1 -1
- package/package.json +3 -3
- package/lib/cjs/pdf.image.d.ts +0 -2
- package/lib/cjs/pdf.image.js +0 -94
- package/lib/cjs/utils/jsonlogic/operators.d.ts +0 -1
- package/lib/cjs/utils/jsonlogic/operators.js +0 -265
- package/lib/mjs/pdf.image.d.ts +0 -2
- package/lib/mjs/pdf.image.js +0 -94
- package/lib/mjs/utils/jsonlogic/operators.d.ts +0 -1
- package/lib/mjs/utils/jsonlogic/operators.js +0 -262
package/lib/cjs/Form.d.ts
CHANGED
|
@@ -1,89 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Represents a JSON value.
|
|
3
|
+
* @typedef {(string | number | boolean | null | JSONArray | JSONObject)} JSON
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Represents a JSON array.
|
|
7
|
+
* @typedef {Array<JSON>} JSONArray
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Represents a JSON object.
|
|
11
|
+
* @typedef {{[key: string]: JSON}} JSONObject
|
|
12
|
+
*/
|
|
13
|
+
/**
|
|
14
|
+
* @typedef {object} FormioHooks
|
|
15
|
+
* @property {Function} [beforeSubmit] - Called before a submission is made.
|
|
16
|
+
* @property {Function} [beforeCancel] - Called before a cancel is made.
|
|
17
|
+
* @property {Function} [beforeNext] - Called before the next page is navigated to.
|
|
18
|
+
* @property {Function} [beforePrev] - Called before the previous page is navigated to.
|
|
19
|
+
* @property {Function} [attachComponent] - Called when a component is attached.
|
|
20
|
+
* @property {Function} [setDataValue] - Called when a data value is set.
|
|
21
|
+
* @property {Function} [addComponents] - Called when components are added.
|
|
22
|
+
* @property {Function} [addComponent] - Called when a component is added.
|
|
23
|
+
* @property {Function} [customValidation] - Called when a custom validation is made.
|
|
24
|
+
* @property {Function} [attachWebform] - Called when a webform is attached.
|
|
25
|
+
*/
|
|
26
|
+
/**
|
|
27
|
+
* @typedef {object} SanitizeConfig
|
|
28
|
+
* @property {string[]} [addAttr] - The html attributes to allow with sanitization.
|
|
29
|
+
* @property {string[]} [addTags] - The html tags to allow with sanitization.
|
|
30
|
+
* @property {string[]} [allowedAttrs] - The html attributes to allow with sanitization.
|
|
31
|
+
* @property {string[]} [allowedTags] - The html tags to allow with sanitization.
|
|
32
|
+
* @property {string[]} [allowedUriRegex] - The regex for allowed URIs.
|
|
33
|
+
* @property {string[]} [addUriSafeAttr] - The URI attributes to allow with sanitization.
|
|
34
|
+
*/
|
|
35
|
+
/**
|
|
36
|
+
* @typedef {object} ButtonSettings
|
|
37
|
+
* @property {boolean} [showPrevious] - Show the previous button in wizard forms.
|
|
38
|
+
* @property {boolean} [showNext] - Show the next button in wizard forms.
|
|
39
|
+
* @property {boolean} [showCancel] - Show the cancel button in wizard forms.
|
|
40
|
+
* @property {boolean} [showSubmit] - Show the submit button in wizard forms.
|
|
41
|
+
*/
|
|
42
|
+
/**
|
|
43
|
+
* @typedef {object} FormOptions
|
|
44
|
+
* @property {boolean} [saveDraft] - Enable the save draft feature.
|
|
45
|
+
* @property {number} [saveDraftThrottle] - The throttle for the save draft feature.
|
|
46
|
+
* @property {boolean} [readOnly] - Set this form to readOnly.
|
|
47
|
+
* @property {boolean} [noAlerts] - Disable the alerts dialog.
|
|
48
|
+
* @property {{[key: string]: string}} [i18n] - The translation file for this rendering.
|
|
49
|
+
* @property {string} [template] - Custom logic for creation of elements.
|
|
50
|
+
* @property {boolean} [noDefaults] - Exclude default values from the settings.
|
|
51
|
+
* @property {any} [fileService] - The file service for this form.
|
|
52
|
+
* @property {EventEmitter} [events] - The EventEmitter for this form.
|
|
53
|
+
* @property {string} [language] - The language to render this form in.
|
|
54
|
+
* @property {{[key: string]: string}} [i18next] - The i18next configuration for this form.
|
|
55
|
+
* @property {boolean} [viewAsHtml] - View the form as raw HTML.
|
|
56
|
+
* @property {'form' | 'html' | 'flat' | 'builder' | 'pdf'} [renderMode] - The render mode for this form.
|
|
57
|
+
* @property {boolean} [highlightErrors] - Highlight any errors on the form.
|
|
58
|
+
* @property {string} [componentErrorClass] - The error class for components.
|
|
59
|
+
* @property {any} [templates] - The templates for this form.
|
|
60
|
+
* @property {string} [iconset] - The iconset for this form.
|
|
61
|
+
* @property {import('@formio/core').Component[]} [components] - The components for this form.
|
|
62
|
+
* @property {{[key: string]: boolean}} [disabled] - Disabled components for this form.
|
|
63
|
+
* @property {boolean} [showHiddenFields] - Show hidden fields.
|
|
64
|
+
* @property {{[key: string]: boolean}} [hide] - Hidden components for this form.
|
|
65
|
+
* @property {{[key: string]: boolean}} [show] - Components to show for this form.
|
|
66
|
+
* @property {Formio} [formio] - The Formio instance for this form.
|
|
67
|
+
* @property {string} [decimalSeparator] - The decimal separator for this form.
|
|
68
|
+
* @property {string} [thousandsSeparator] - The thousands separator for this form.
|
|
69
|
+
* @property {FormioHooks} [hooks] - The hooks for this form.
|
|
70
|
+
* @property {boolean} [alwaysDirty] - Always be dirty.
|
|
71
|
+
* @property {boolean} [skipDraftRestore] - Skip restoring a draft.
|
|
72
|
+
* @property {'form' | 'wizard' | 'pdf'} [display] - The display for this form.
|
|
73
|
+
* @property {string} [cdnUrl] - The CDN url for this form.
|
|
74
|
+
* @property {boolean} [flatten] - Flatten the form.
|
|
75
|
+
* @property {boolean} [sanitize] - Sanitize the form.
|
|
76
|
+
* @property {SanitizeConfig} [sanitizeConfig] - The sanitize configuration for this form.
|
|
77
|
+
* @property {ButtonSettings} [buttonSettings] - The button settings for this form.
|
|
78
|
+
* @property {object} [breadcrumbSettings] - The breadcrumb settings for this form.
|
|
79
|
+
* @property {boolean} [allowPrevious] - Allow the previous button (for Wizard forms).
|
|
80
|
+
* @property {string[]} [wizardButtonOrder] - The order of the buttons (for Wizard forms).
|
|
81
|
+
* @property {boolean} [showCheckboxBackground] - Show the checkbox background.
|
|
82
|
+
* @property {number} [zoom] - The zoom for PDF forms.
|
|
83
|
+
* @property {boolean} [building] - Whether the form is in builder mode.
|
|
84
|
+
* @property {boolean} [inputsOnly] - Whether to render inputs only (for PDF forms).
|
|
85
|
+
*/
|
|
86
|
+
/**
|
|
87
|
+
* Form class for rendering webforms, pdfs, and wizards.
|
|
88
|
+
* @property {FormOptions} options - The options for this Form instance.
|
|
89
|
+
*/
|
|
1
90
|
export default class Form extends Element {
|
|
2
91
|
static embed(embed: any): Promise<any>;
|
|
3
|
-
constructor(elementOrForm: any, formOrOptions: any, options?: {});
|
|
4
|
-
/**
|
|
5
|
-
* Represents a JSON value.
|
|
6
|
-
* @typedef {(string | number | boolean | null | JSONArray | JSONObject)} JSON
|
|
7
|
-
*/
|
|
8
|
-
/**
|
|
9
|
-
* Represents a JSON array.
|
|
10
|
-
* @typedef {Array<JSON>} JSONArray
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
* Represents a JSON object.
|
|
14
|
-
* @typedef {{[key: string]: JSON}} JSONObject
|
|
15
|
-
*/
|
|
16
|
-
/**
|
|
17
|
-
* @typedef {object} FormioHooks
|
|
18
|
-
* @property {Function} [beforeSubmit] - Called before a submission is made.
|
|
19
|
-
* @property {Function} [beforeCancel] - Called before a cancel is made.
|
|
20
|
-
* @property {Function} [beforeNext] - Called before the next page is navigated to.
|
|
21
|
-
* @property {Function} [beforePrev] - Called before the previous page is navigated to.
|
|
22
|
-
* @property {Function} [attachComponent] - Called when a component is attached.
|
|
23
|
-
* @property {Function} [setDataValue] - Called when a data value is set.
|
|
24
|
-
* @property {Function} [addComponents] - Called when components are added.
|
|
25
|
-
* @property {Function} [addComponent] - Called when a component is added.
|
|
26
|
-
* @property {Function} [customValidation] - Called when a custom validation is made.
|
|
27
|
-
* @property {Function} [attachWebform] - Called when a webform is attached.
|
|
28
|
-
*/
|
|
29
|
-
/**
|
|
30
|
-
* @typedef {object} SanitizeConfig
|
|
31
|
-
* @property {string[]} [addAttr] - The html attributes to allow with sanitization.
|
|
32
|
-
* @property {string[]} [addTags] - The html tags to allow with sanitization.
|
|
33
|
-
* @property {string[]} [allowedAttrs] - The html attributes to allow with sanitization.
|
|
34
|
-
* @property {string[]} [allowedTags] - The html tags to allow with sanitization.
|
|
35
|
-
* @property {string[]} [allowedUriRegex] - The regex for allowed URIs.
|
|
36
|
-
* @property {string[]} [addUriSafeAttr] - The URI attributes to allow with sanitization.
|
|
37
|
-
*/
|
|
38
|
-
/**
|
|
39
|
-
* @typedef {object} ButtonSettings
|
|
40
|
-
* @property {boolean} [showPrevious] - Show the previous button in wizard forms.
|
|
41
|
-
* @property {boolean} [showNext] - Show the next button in wizard forms.
|
|
42
|
-
* @property {boolean} [showCancel] - Show the cancel button in wizard forms.
|
|
43
|
-
* @property {boolean} [showSubmit] - Show the submit button in wizard forms.
|
|
44
|
-
*/
|
|
45
|
-
/**
|
|
46
|
-
* @typedef {object} FormOptions
|
|
47
|
-
* @property {boolean} [saveDraft] - Enable the save draft feature.
|
|
48
|
-
* @property {number} [saveDraftThrottle] - The throttle for the save draft feature.
|
|
49
|
-
* @property {boolean} [readOnly] - Set this form to readOnly.
|
|
50
|
-
* @property {boolean} [noAlerts] - Disable the alerts dialog.
|
|
51
|
-
* @property {{[key: string]: string}} [i18n] - The translation file for this rendering.
|
|
52
|
-
* @property {string} [template] - Custom logic for creation of elements.
|
|
53
|
-
* @property {boolean} [noDefaults] - Exclude default values from the settings.
|
|
54
|
-
* @property {any} [fileService] - The file service for this form.
|
|
55
|
-
* @property {EventEmitter} [events] - The EventEmitter for this form.
|
|
56
|
-
* @property {string} [language] - The language to render this form in.
|
|
57
|
-
* @property {{[key: string]: string}} [i18next] - The i18next configuration for this form.
|
|
58
|
-
* @property {boolean} [viewAsHtml] - View the form as raw HTML.
|
|
59
|
-
* @property {'form' | 'html' | 'flat' | 'builder' | 'pdf'} [renderMode] - The render mode for this form.
|
|
60
|
-
* @property {boolean} [highlightErrors] - Highlight any errors on the form.
|
|
61
|
-
* @property {string} [componentErrorClass] - The error class for components.
|
|
62
|
-
* @property {any} [templates] - The templates for this form.
|
|
63
|
-
* @property {string} [iconset] - The iconset for this form.
|
|
64
|
-
* @property {import('@formio/core').Component[]} [components] - The components for this form.
|
|
65
|
-
* @property {{[key: string]: boolean}} [disabled] - Disabled components for this form.
|
|
66
|
-
* @property {boolean} [showHiddenFields] - Show hidden fields.
|
|
67
|
-
* @property {{[key: string]: boolean}} [hide] - Hidden components for this form.
|
|
68
|
-
* @property {{[key: string]: boolean}} [show] - Components to show for this form.
|
|
69
|
-
* @property {Formio} [formio] - The Formio instance for this form.
|
|
70
|
-
* @property {string} [decimalSeparator] - The decimal separator for this form.
|
|
71
|
-
* @property {string} [thousandsSeparator] - The thousands separator for this form.
|
|
72
|
-
* @property {FormioHooks} [hooks] - The hooks for this form.
|
|
73
|
-
* @property {boolean} [alwaysDirty] - Always be dirty.
|
|
74
|
-
* @property {boolean} [skipDraftRestore] - Skip restoring a draft.
|
|
75
|
-
* @property {'form' | 'wizard' | 'pdf'} [display] - The display for this form.
|
|
76
|
-
* @property {string} [cdnUrl] - The CDN url for this form.
|
|
77
|
-
* @property {boolean} [flatten] - Flatten the form.
|
|
78
|
-
* @property {boolean} [sanitize] - Sanitize the form.
|
|
79
|
-
* @property {SanitizeConfig} [sanitizeConfig] - The sanitize configuration for this form.
|
|
80
|
-
* @property {ButtonSettings} [buttonSettings] - The button settings for this form.
|
|
81
|
-
* @property {object} [breadcrumbSettings] - The breadcrumb settings for this form.
|
|
82
|
-
* @property {boolean} [allowPrevious] - Allow the previous button (for Wizard forms).
|
|
83
|
-
* @property {string[]} [wizardButtonOrder] - The order of the buttons (for Wizard forms).
|
|
84
|
-
* @property {boolean} [showCheckboxBackground] - Show the checkbox background.
|
|
85
|
-
* @property {number} [zoom] - The zoom for PDF forms.
|
|
86
|
-
*/
|
|
87
92
|
/**
|
|
88
93
|
* Creates an easy to use interface for embedding webforms, pdfs, and wizards into your application.
|
|
89
94
|
* @param {object} elementOrForm - The DOM element you wish to render this form within, or the form definition.
|
|
@@ -94,265 +99,13 @@ export default class Form extends Element {
|
|
|
94
99
|
* const form = new Form(document.getElementById('formio'), 'https://examples.form.io/example');
|
|
95
100
|
* form.build();
|
|
96
101
|
*/
|
|
97
|
-
|
|
98
|
-
* @type {FormOptions} - the options for this Form.
|
|
99
|
-
*/
|
|
100
|
-
options: {
|
|
101
|
-
/**
|
|
102
|
-
* - Enable the save draft feature.
|
|
103
|
-
*/
|
|
104
|
-
saveDraft?: boolean | undefined;
|
|
105
|
-
/**
|
|
106
|
-
* - The throttle for the save draft feature.
|
|
107
|
-
*/
|
|
108
|
-
saveDraftThrottle?: number | undefined;
|
|
109
|
-
/**
|
|
110
|
-
* - Set this form to readOnly.
|
|
111
|
-
*/
|
|
112
|
-
readOnly?: boolean | undefined;
|
|
113
|
-
/**
|
|
114
|
-
* - Disable the alerts dialog.
|
|
115
|
-
*/
|
|
116
|
-
noAlerts?: boolean | undefined;
|
|
117
|
-
/**
|
|
118
|
-
* - The translation file for this rendering.
|
|
119
|
-
*/
|
|
120
|
-
i18n?: {
|
|
121
|
-
[key: string]: string;
|
|
122
|
-
} | undefined;
|
|
123
|
-
/**
|
|
124
|
-
* - Custom logic for creation of elements.
|
|
125
|
-
*/
|
|
126
|
-
template?: string | undefined;
|
|
127
|
-
/**
|
|
128
|
-
* - Exclude default values from the settings.
|
|
129
|
-
*/
|
|
130
|
-
noDefaults?: boolean | undefined;
|
|
131
|
-
/**
|
|
132
|
-
* - The file service for this form.
|
|
133
|
-
*/
|
|
134
|
-
fileService?: any;
|
|
135
|
-
/**
|
|
136
|
-
* - The EventEmitter for this form.
|
|
137
|
-
*/
|
|
138
|
-
events?: any;
|
|
139
|
-
/**
|
|
140
|
-
* - The language to render this form in.
|
|
141
|
-
*/
|
|
142
|
-
language?: string | undefined;
|
|
143
|
-
/**
|
|
144
|
-
* - The i18next configuration for this form.
|
|
145
|
-
*/
|
|
146
|
-
i18next?: {
|
|
147
|
-
[key: string]: string;
|
|
148
|
-
} | undefined;
|
|
149
|
-
/**
|
|
150
|
-
* - View the form as raw HTML.
|
|
151
|
-
*/
|
|
152
|
-
viewAsHtml?: boolean | undefined;
|
|
153
|
-
/**
|
|
154
|
-
* - The render mode for this form.
|
|
155
|
-
*/
|
|
156
|
-
renderMode?: "builder" | "form" | "html" | "flat" | "pdf" | undefined;
|
|
157
|
-
/**
|
|
158
|
-
* - Highlight any errors on the form.
|
|
159
|
-
*/
|
|
160
|
-
highlightErrors?: boolean | undefined;
|
|
161
|
-
/**
|
|
162
|
-
* - The error class for components.
|
|
163
|
-
*/
|
|
164
|
-
componentErrorClass?: string | undefined;
|
|
165
|
-
/**
|
|
166
|
-
* - The templates for this form.
|
|
167
|
-
*/
|
|
168
|
-
templates?: any;
|
|
169
|
-
/**
|
|
170
|
-
* - The iconset for this form.
|
|
171
|
-
*/
|
|
172
|
-
iconset?: string | undefined;
|
|
173
|
-
/**
|
|
174
|
-
* - The components for this form.
|
|
175
|
-
*/
|
|
176
|
-
components?: import("@formio/core").Component[] | undefined;
|
|
177
|
-
/**
|
|
178
|
-
* - Disabled components for this form.
|
|
179
|
-
*/
|
|
180
|
-
disabled?: {
|
|
181
|
-
[key: string]: boolean;
|
|
182
|
-
} | undefined;
|
|
183
|
-
/**
|
|
184
|
-
* - Show hidden fields.
|
|
185
|
-
*/
|
|
186
|
-
showHiddenFields?: boolean | undefined;
|
|
187
|
-
/**
|
|
188
|
-
* - Hidden components for this form.
|
|
189
|
-
*/
|
|
190
|
-
hide?: {
|
|
191
|
-
[key: string]: boolean;
|
|
192
|
-
} | undefined;
|
|
193
|
-
/**
|
|
194
|
-
* - Components to show for this form.
|
|
195
|
-
*/
|
|
196
|
-
show?: {
|
|
197
|
-
[key: string]: boolean;
|
|
198
|
-
} | undefined;
|
|
199
|
-
/**
|
|
200
|
-
* - The Formio instance for this form.
|
|
201
|
-
*/
|
|
202
|
-
formio?: any;
|
|
203
|
-
/**
|
|
204
|
-
* - The decimal separator for this form.
|
|
205
|
-
*/
|
|
206
|
-
decimalSeparator?: string | undefined;
|
|
207
|
-
/**
|
|
208
|
-
* - The thousands separator for this form.
|
|
209
|
-
*/
|
|
210
|
-
thousandsSeparator?: string | undefined;
|
|
211
|
-
/**
|
|
212
|
-
* - The hooks for this form.
|
|
213
|
-
*/
|
|
214
|
-
hooks?: {
|
|
215
|
-
/**
|
|
216
|
-
* - Called before a submission is made.
|
|
217
|
-
*/
|
|
218
|
-
beforeSubmit?: Function | undefined;
|
|
219
|
-
/**
|
|
220
|
-
* - Called before a cancel is made.
|
|
221
|
-
*/
|
|
222
|
-
beforeCancel?: Function | undefined;
|
|
223
|
-
/**
|
|
224
|
-
* - Called before the next page is navigated to.
|
|
225
|
-
*/
|
|
226
|
-
beforeNext?: Function | undefined;
|
|
227
|
-
/**
|
|
228
|
-
* - Called before the previous page is navigated to.
|
|
229
|
-
*/
|
|
230
|
-
beforePrev?: Function | undefined;
|
|
231
|
-
/**
|
|
232
|
-
* - Called when a component is attached.
|
|
233
|
-
*/
|
|
234
|
-
attachComponent?: Function | undefined;
|
|
235
|
-
/**
|
|
236
|
-
* - Called when a data value is set.
|
|
237
|
-
*/
|
|
238
|
-
setDataValue?: Function | undefined;
|
|
239
|
-
/**
|
|
240
|
-
* - Called when components are added.
|
|
241
|
-
*/
|
|
242
|
-
addComponents?: Function | undefined;
|
|
243
|
-
/**
|
|
244
|
-
* - Called when a component is added.
|
|
245
|
-
*/
|
|
246
|
-
addComponent?: Function | undefined;
|
|
247
|
-
/**
|
|
248
|
-
* - Called when a custom validation is made.
|
|
249
|
-
*/
|
|
250
|
-
customValidation?: Function | undefined;
|
|
251
|
-
/**
|
|
252
|
-
* - Called when a webform is attached.
|
|
253
|
-
*/
|
|
254
|
-
attachWebform?: Function | undefined;
|
|
255
|
-
} | undefined;
|
|
256
|
-
/**
|
|
257
|
-
* - Always be dirty.
|
|
258
|
-
*/
|
|
259
|
-
alwaysDirty?: boolean | undefined;
|
|
260
|
-
/**
|
|
261
|
-
* - Skip restoring a draft.
|
|
262
|
-
*/
|
|
263
|
-
skipDraftRestore?: boolean | undefined;
|
|
264
|
-
/**
|
|
265
|
-
* - The display for this form.
|
|
266
|
-
*/
|
|
267
|
-
display?: "form" | "pdf" | "wizard" | undefined;
|
|
268
|
-
/**
|
|
269
|
-
* - The CDN url for this form.
|
|
270
|
-
*/
|
|
271
|
-
cdnUrl?: string | undefined;
|
|
272
|
-
/**
|
|
273
|
-
* - Flatten the form.
|
|
274
|
-
*/
|
|
275
|
-
flatten?: boolean | undefined;
|
|
276
|
-
/**
|
|
277
|
-
* - Sanitize the form.
|
|
278
|
-
*/
|
|
279
|
-
sanitize?: boolean | undefined;
|
|
280
|
-
/**
|
|
281
|
-
* - The sanitize configuration for this form.
|
|
282
|
-
*/
|
|
283
|
-
sanitizeConfig?: {
|
|
284
|
-
/**
|
|
285
|
-
* - The html attributes to allow with sanitization.
|
|
286
|
-
*/
|
|
287
|
-
addAttr?: string[] | undefined;
|
|
288
|
-
/**
|
|
289
|
-
* - The html tags to allow with sanitization.
|
|
290
|
-
*/
|
|
291
|
-
addTags?: string[] | undefined;
|
|
292
|
-
/**
|
|
293
|
-
* - The html attributes to allow with sanitization.
|
|
294
|
-
*/
|
|
295
|
-
allowedAttrs?: string[] | undefined;
|
|
296
|
-
/**
|
|
297
|
-
* - The html tags to allow with sanitization.
|
|
298
|
-
*/
|
|
299
|
-
allowedTags?: string[] | undefined;
|
|
300
|
-
/**
|
|
301
|
-
* - The regex for allowed URIs.
|
|
302
|
-
*/
|
|
303
|
-
allowedUriRegex?: string[] | undefined;
|
|
304
|
-
/**
|
|
305
|
-
* - The URI attributes to allow with sanitization.
|
|
306
|
-
*/
|
|
307
|
-
addUriSafeAttr?: string[] | undefined;
|
|
308
|
-
} | undefined;
|
|
309
|
-
/**
|
|
310
|
-
* - The button settings for this form.
|
|
311
|
-
*/
|
|
312
|
-
buttonSettings?: {
|
|
313
|
-
/**
|
|
314
|
-
* - Show the previous button in wizard forms.
|
|
315
|
-
*/
|
|
316
|
-
showPrevious?: boolean | undefined;
|
|
317
|
-
/**
|
|
318
|
-
* - Show the next button in wizard forms.
|
|
319
|
-
*/
|
|
320
|
-
showNext?: boolean | undefined;
|
|
321
|
-
/**
|
|
322
|
-
* - Show the cancel button in wizard forms.
|
|
323
|
-
*/
|
|
324
|
-
showCancel?: boolean | undefined;
|
|
325
|
-
/**
|
|
326
|
-
* - Show the submit button in wizard forms.
|
|
327
|
-
*/
|
|
328
|
-
showSubmit?: boolean | undefined;
|
|
329
|
-
} | undefined;
|
|
330
|
-
/**
|
|
331
|
-
* - The breadcrumb settings for this form.
|
|
332
|
-
*/
|
|
333
|
-
breadcrumbSettings?: object | undefined;
|
|
334
|
-
/**
|
|
335
|
-
* - Allow the previous button (for Wizard forms).
|
|
336
|
-
*/
|
|
337
|
-
allowPrevious?: boolean | undefined;
|
|
338
|
-
/**
|
|
339
|
-
* - The order of the buttons (for Wizard forms).
|
|
340
|
-
*/
|
|
341
|
-
wizardButtonOrder?: string[] | undefined;
|
|
342
|
-
/**
|
|
343
|
-
* - Show the checkbox background.
|
|
344
|
-
*/
|
|
345
|
-
showCheckboxBackground?: boolean | undefined;
|
|
346
|
-
/**
|
|
347
|
-
* - The zoom for PDF forms.
|
|
348
|
-
*/
|
|
349
|
-
zoom?: number | undefined;
|
|
350
|
-
};
|
|
102
|
+
constructor(elementOrForm: object, formOrOptions: object | string | FormOptions, options?: FormOptions | undefined);
|
|
351
103
|
ready: Promise<any>;
|
|
352
104
|
readyResolve: (value: any) => void;
|
|
353
105
|
readyReject: (reason?: any) => void;
|
|
354
106
|
instance: any;
|
|
355
|
-
element:
|
|
107
|
+
element: object | null;
|
|
108
|
+
options: any;
|
|
356
109
|
display: string;
|
|
357
110
|
createElement(tag: any, attrs: any, children: any): any;
|
|
358
111
|
set loading(load: any);
|
|
@@ -398,10 +151,10 @@ export default class Form extends Element {
|
|
|
398
151
|
getFormInitOptions(url: string, form: import('@formio/core').Form): object;
|
|
399
152
|
/**
|
|
400
153
|
* Sets the form to the JSON schema of a form.
|
|
401
|
-
* @param {import('@formio/core').Form} formParam - The form JSON to set this form to.
|
|
154
|
+
* @param {import('@formio/core').Form | string} formParam - The form JSON to set this form to.
|
|
402
155
|
* @returns {Promise<Webform|Wizard|PDF>} - The webform instance that was created.
|
|
403
156
|
*/
|
|
404
|
-
setForm(formParam: import('@formio/core').Form): Promise<Webform | Wizard | PDF>;
|
|
157
|
+
setForm(formParam: import('@formio/core').Form | string): Promise<Webform | Wizard | PDF>;
|
|
405
158
|
_form: any;
|
|
406
159
|
getSubmission(formio: any, opts: any): any;
|
|
407
160
|
/**
|
|
@@ -427,4 +180,281 @@ export default class Form extends Element {
|
|
|
427
180
|
render(): Promise<any>;
|
|
428
181
|
attach(element: any): any;
|
|
429
182
|
}
|
|
183
|
+
export type FormOptions = {
|
|
184
|
+
/**
|
|
185
|
+
* - Enable the save draft feature.
|
|
186
|
+
*/
|
|
187
|
+
saveDraft?: boolean | undefined;
|
|
188
|
+
/**
|
|
189
|
+
* - The throttle for the save draft feature.
|
|
190
|
+
*/
|
|
191
|
+
saveDraftThrottle?: number | undefined;
|
|
192
|
+
/**
|
|
193
|
+
* - Set this form to readOnly.
|
|
194
|
+
*/
|
|
195
|
+
readOnly?: boolean | undefined;
|
|
196
|
+
/**
|
|
197
|
+
* - Disable the alerts dialog.
|
|
198
|
+
*/
|
|
199
|
+
noAlerts?: boolean | undefined;
|
|
200
|
+
/**
|
|
201
|
+
* - The translation file for this rendering.
|
|
202
|
+
*/
|
|
203
|
+
i18n?: {
|
|
204
|
+
[key: string]: string;
|
|
205
|
+
} | undefined;
|
|
206
|
+
/**
|
|
207
|
+
* - Custom logic for creation of elements.
|
|
208
|
+
*/
|
|
209
|
+
template?: string | undefined;
|
|
210
|
+
/**
|
|
211
|
+
* - Exclude default values from the settings.
|
|
212
|
+
*/
|
|
213
|
+
noDefaults?: boolean | undefined;
|
|
214
|
+
/**
|
|
215
|
+
* - The file service for this form.
|
|
216
|
+
*/
|
|
217
|
+
fileService?: any;
|
|
218
|
+
/**
|
|
219
|
+
* - The EventEmitter for this form.
|
|
220
|
+
*/
|
|
221
|
+
events?: any;
|
|
222
|
+
/**
|
|
223
|
+
* - The language to render this form in.
|
|
224
|
+
*/
|
|
225
|
+
language?: string | undefined;
|
|
226
|
+
/**
|
|
227
|
+
* - The i18next configuration for this form.
|
|
228
|
+
*/
|
|
229
|
+
i18next?: {
|
|
230
|
+
[key: string]: string;
|
|
231
|
+
} | undefined;
|
|
232
|
+
/**
|
|
233
|
+
* - View the form as raw HTML.
|
|
234
|
+
*/
|
|
235
|
+
viewAsHtml?: boolean | undefined;
|
|
236
|
+
/**
|
|
237
|
+
* - The render mode for this form.
|
|
238
|
+
*/
|
|
239
|
+
renderMode?: "builder" | "form" | "html" | "flat" | "pdf" | undefined;
|
|
240
|
+
/**
|
|
241
|
+
* - Highlight any errors on the form.
|
|
242
|
+
*/
|
|
243
|
+
highlightErrors?: boolean | undefined;
|
|
244
|
+
/**
|
|
245
|
+
* - The error class for components.
|
|
246
|
+
*/
|
|
247
|
+
componentErrorClass?: string | undefined;
|
|
248
|
+
/**
|
|
249
|
+
* - The templates for this form.
|
|
250
|
+
*/
|
|
251
|
+
templates?: any;
|
|
252
|
+
/**
|
|
253
|
+
* - The iconset for this form.
|
|
254
|
+
*/
|
|
255
|
+
iconset?: string | undefined;
|
|
256
|
+
/**
|
|
257
|
+
* - The components for this form.
|
|
258
|
+
*/
|
|
259
|
+
components?: import("@formio/core").Component[] | undefined;
|
|
260
|
+
/**
|
|
261
|
+
* - Disabled components for this form.
|
|
262
|
+
*/
|
|
263
|
+
disabled?: {
|
|
264
|
+
[key: string]: boolean;
|
|
265
|
+
} | undefined;
|
|
266
|
+
/**
|
|
267
|
+
* - Show hidden fields.
|
|
268
|
+
*/
|
|
269
|
+
showHiddenFields?: boolean | undefined;
|
|
270
|
+
/**
|
|
271
|
+
* - Hidden components for this form.
|
|
272
|
+
*/
|
|
273
|
+
hide?: {
|
|
274
|
+
[key: string]: boolean;
|
|
275
|
+
} | undefined;
|
|
276
|
+
/**
|
|
277
|
+
* - Components to show for this form.
|
|
278
|
+
*/
|
|
279
|
+
show?: {
|
|
280
|
+
[key: string]: boolean;
|
|
281
|
+
} | undefined;
|
|
282
|
+
/**
|
|
283
|
+
* - The Formio instance for this form.
|
|
284
|
+
*/
|
|
285
|
+
formio?: any;
|
|
286
|
+
/**
|
|
287
|
+
* - The decimal separator for this form.
|
|
288
|
+
*/
|
|
289
|
+
decimalSeparator?: string | undefined;
|
|
290
|
+
/**
|
|
291
|
+
* - The thousands separator for this form.
|
|
292
|
+
*/
|
|
293
|
+
thousandsSeparator?: string | undefined;
|
|
294
|
+
/**
|
|
295
|
+
* - The hooks for this form.
|
|
296
|
+
*/
|
|
297
|
+
hooks?: FormioHooks | undefined;
|
|
298
|
+
/**
|
|
299
|
+
* - Always be dirty.
|
|
300
|
+
*/
|
|
301
|
+
alwaysDirty?: boolean | undefined;
|
|
302
|
+
/**
|
|
303
|
+
* - Skip restoring a draft.
|
|
304
|
+
*/
|
|
305
|
+
skipDraftRestore?: boolean | undefined;
|
|
306
|
+
/**
|
|
307
|
+
* - The display for this form.
|
|
308
|
+
*/
|
|
309
|
+
display?: "form" | "pdf" | "wizard" | undefined;
|
|
310
|
+
/**
|
|
311
|
+
* - The CDN url for this form.
|
|
312
|
+
*/
|
|
313
|
+
cdnUrl?: string | undefined;
|
|
314
|
+
/**
|
|
315
|
+
* - Flatten the form.
|
|
316
|
+
*/
|
|
317
|
+
flatten?: boolean | undefined;
|
|
318
|
+
/**
|
|
319
|
+
* - Sanitize the form.
|
|
320
|
+
*/
|
|
321
|
+
sanitize?: boolean | undefined;
|
|
322
|
+
/**
|
|
323
|
+
* - The sanitize configuration for this form.
|
|
324
|
+
*/
|
|
325
|
+
sanitizeConfig?: SanitizeConfig | undefined;
|
|
326
|
+
/**
|
|
327
|
+
* - The button settings for this form.
|
|
328
|
+
*/
|
|
329
|
+
buttonSettings?: ButtonSettings | undefined;
|
|
330
|
+
/**
|
|
331
|
+
* - The breadcrumb settings for this form.
|
|
332
|
+
*/
|
|
333
|
+
breadcrumbSettings?: object | undefined;
|
|
334
|
+
/**
|
|
335
|
+
* - Allow the previous button (for Wizard forms).
|
|
336
|
+
*/
|
|
337
|
+
allowPrevious?: boolean | undefined;
|
|
338
|
+
/**
|
|
339
|
+
* - The order of the buttons (for Wizard forms).
|
|
340
|
+
*/
|
|
341
|
+
wizardButtonOrder?: string[] | undefined;
|
|
342
|
+
/**
|
|
343
|
+
* - Show the checkbox background.
|
|
344
|
+
*/
|
|
345
|
+
showCheckboxBackground?: boolean | undefined;
|
|
346
|
+
/**
|
|
347
|
+
* - The zoom for PDF forms.
|
|
348
|
+
*/
|
|
349
|
+
zoom?: number | undefined;
|
|
350
|
+
/**
|
|
351
|
+
* - Whether the form is in builder mode.
|
|
352
|
+
*/
|
|
353
|
+
building?: boolean | undefined;
|
|
354
|
+
/**
|
|
355
|
+
* - Whether to render inputs only (for PDF forms).
|
|
356
|
+
*/
|
|
357
|
+
inputsOnly?: boolean | undefined;
|
|
358
|
+
};
|
|
359
|
+
/**
|
|
360
|
+
* Represents a JSON value.
|
|
361
|
+
*/
|
|
362
|
+
export type JSON = (string | number | boolean | null | JSON[] | JSONObject);
|
|
363
|
+
/**
|
|
364
|
+
* Represents a JSON array.
|
|
365
|
+
*/
|
|
366
|
+
export type JSONArray = Array<JSON>;
|
|
367
|
+
/**
|
|
368
|
+
* Represents a JSON object.
|
|
369
|
+
*/
|
|
370
|
+
export type JSONObject = {
|
|
371
|
+
[key: string]: JSON;
|
|
372
|
+
};
|
|
373
|
+
export type FormioHooks = {
|
|
374
|
+
/**
|
|
375
|
+
* - Called before a submission is made.
|
|
376
|
+
*/
|
|
377
|
+
beforeSubmit?: Function | undefined;
|
|
378
|
+
/**
|
|
379
|
+
* - Called before a cancel is made.
|
|
380
|
+
*/
|
|
381
|
+
beforeCancel?: Function | undefined;
|
|
382
|
+
/**
|
|
383
|
+
* - Called before the next page is navigated to.
|
|
384
|
+
*/
|
|
385
|
+
beforeNext?: Function | undefined;
|
|
386
|
+
/**
|
|
387
|
+
* - Called before the previous page is navigated to.
|
|
388
|
+
*/
|
|
389
|
+
beforePrev?: Function | undefined;
|
|
390
|
+
/**
|
|
391
|
+
* - Called when a component is attached.
|
|
392
|
+
*/
|
|
393
|
+
attachComponent?: Function | undefined;
|
|
394
|
+
/**
|
|
395
|
+
* - Called when a data value is set.
|
|
396
|
+
*/
|
|
397
|
+
setDataValue?: Function | undefined;
|
|
398
|
+
/**
|
|
399
|
+
* - Called when components are added.
|
|
400
|
+
*/
|
|
401
|
+
addComponents?: Function | undefined;
|
|
402
|
+
/**
|
|
403
|
+
* - Called when a component is added.
|
|
404
|
+
*/
|
|
405
|
+
addComponent?: Function | undefined;
|
|
406
|
+
/**
|
|
407
|
+
* - Called when a custom validation is made.
|
|
408
|
+
*/
|
|
409
|
+
customValidation?: Function | undefined;
|
|
410
|
+
/**
|
|
411
|
+
* - Called when a webform is attached.
|
|
412
|
+
*/
|
|
413
|
+
attachWebform?: Function | undefined;
|
|
414
|
+
};
|
|
415
|
+
export type SanitizeConfig = {
|
|
416
|
+
/**
|
|
417
|
+
* - The html attributes to allow with sanitization.
|
|
418
|
+
*/
|
|
419
|
+
addAttr?: string[] | undefined;
|
|
420
|
+
/**
|
|
421
|
+
* - The html tags to allow with sanitization.
|
|
422
|
+
*/
|
|
423
|
+
addTags?: string[] | undefined;
|
|
424
|
+
/**
|
|
425
|
+
* - The html attributes to allow with sanitization.
|
|
426
|
+
*/
|
|
427
|
+
allowedAttrs?: string[] | undefined;
|
|
428
|
+
/**
|
|
429
|
+
* - The html tags to allow with sanitization.
|
|
430
|
+
*/
|
|
431
|
+
allowedTags?: string[] | undefined;
|
|
432
|
+
/**
|
|
433
|
+
* - The regex for allowed URIs.
|
|
434
|
+
*/
|
|
435
|
+
allowedUriRegex?: string[] | undefined;
|
|
436
|
+
/**
|
|
437
|
+
* - The URI attributes to allow with sanitization.
|
|
438
|
+
*/
|
|
439
|
+
addUriSafeAttr?: string[] | undefined;
|
|
440
|
+
};
|
|
441
|
+
export type ButtonSettings = {
|
|
442
|
+
/**
|
|
443
|
+
* - Show the previous button in wizard forms.
|
|
444
|
+
*/
|
|
445
|
+
showPrevious?: boolean | undefined;
|
|
446
|
+
/**
|
|
447
|
+
* - Show the next button in wizard forms.
|
|
448
|
+
*/
|
|
449
|
+
showNext?: boolean | undefined;
|
|
450
|
+
/**
|
|
451
|
+
* - Show the cancel button in wizard forms.
|
|
452
|
+
*/
|
|
453
|
+
showCancel?: boolean | undefined;
|
|
454
|
+
/**
|
|
455
|
+
* - Show the submit button in wizard forms.
|
|
456
|
+
*/
|
|
457
|
+
showSubmit?: boolean | undefined;
|
|
458
|
+
};
|
|
430
459
|
import Element from './Element';
|
|
460
|
+
export const FormOptions: undefined;
|