@formio/js 5.0.0-dev.5610.da13e39 → 5.0.0-dev.5613.3476921
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.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.js +1199 -651
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.form.min.js.LICENSE.txt +11 -3
- package/dist/formio.full.js +919 -691
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.full.min.js.LICENSE.txt +11 -3
- package/dist/formio.js +16 -16
- package/dist/formio.min.js +1 -1
- package/dist/formio.min.js.LICENSE.txt +1 -1
- package/dist/formio.utils.js +493 -1861
- package/dist/formio.utils.min.js +1 -1
- package/dist/formio.utils.min.js.LICENSE.txt +2 -12
- package/lib/cjs/Element.d.ts +96 -86
- package/lib/cjs/Element.js +78 -68
- package/lib/cjs/Form.d.ts +36 -365
- package/lib/cjs/Form.js +64 -50
- package/lib/cjs/FormBuilder.d.ts +2 -187
- package/lib/cjs/FormBuilder.js +8 -30
- package/lib/cjs/PDF.d.ts +13 -11
- package/lib/cjs/PDF.js +8 -6
- package/lib/cjs/Webform.d.ts +139 -180
- package/lib/cjs/Webform.js +298 -313
- package/lib/cjs/WebformBuilder.d.ts +14 -16
- package/lib/cjs/WebformBuilder.js +11 -17
- package/lib/cjs/Wizard.d.ts +21 -31
- package/lib/cjs/Wizard.js +19 -42
- package/lib/cjs/WizardBuilder.d.ts +1 -1
- package/lib/cjs/addons/PasswordStrength/PasswordStrengthAddon.d.ts +5 -8
- package/lib/cjs/addons/PasswordStrength/PasswordStrengthAddon.js +3 -6
- package/lib/cjs/components/Components.d.ts +4 -4
- package/lib/cjs/components/Components.js +3 -3
- package/lib/cjs/components/_classes/component/Component.d.ts +269 -502
- package/lib/cjs/components/_classes/component/Component.form.d.ts +3 -6
- package/lib/cjs/components/_classes/component/Component.form.js +0 -5
- package/lib/cjs/components/_classes/component/Component.js +189 -433
- package/lib/cjs/components/_classes/component/editForm/Component.edit.display.js +8 -0
- package/lib/cjs/components/_classes/component/editForm/Component.edit.validation.js +2 -2
- package/lib/cjs/components/_classes/component/editForm/utils.js +2 -2
- package/lib/cjs/components/_classes/field/Field.d.ts +2 -11
- package/lib/cjs/components/_classes/field/Field.js +1 -13
- package/lib/cjs/components/_classes/input/Input.d.ts +3 -4
- package/lib/cjs/components/_classes/input/Input.js +2 -2
- package/lib/cjs/components/_classes/list/ListComponent.d.ts +2 -2
- package/lib/cjs/components/_classes/list/ListComponent.form.d.ts +3 -6
- package/lib/cjs/components/_classes/list/ListComponent.form.js +0 -5
- package/lib/cjs/components/_classes/multivalue/Multivalue.d.ts +12 -43
- package/lib/cjs/components/_classes/multivalue/Multivalue.js +3 -37
- package/lib/cjs/components/_classes/nested/NestedComponent.d.ts +67 -163
- package/lib/cjs/components/_classes/nested/NestedComponent.form.d.ts +3 -6
- package/lib/cjs/components/_classes/nested/NestedComponent.form.js +0 -5
- package/lib/cjs/components/_classes/nested/NestedComponent.js +54 -175
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +2 -2
- package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.js +1 -1
- package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.d.ts +1 -7
- package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.js +3 -2
- package/lib/cjs/components/address/Address.d.ts +2 -4
- package/lib/cjs/components/address/Address.form.d.ts +3 -6
- package/lib/cjs/components/address/Address.form.js +0 -5
- package/lib/cjs/components/button/Button.d.ts +12 -3
- package/lib/cjs/components/button/Button.form.d.ts +3 -6
- package/lib/cjs/components/button/Button.form.js +0 -5
- package/lib/cjs/components/button/Button.js +0 -5
- package/lib/cjs/components/checkbox/Checkbox.d.ts +27 -4
- package/lib/cjs/components/checkbox/Checkbox.form.d.ts +3 -6
- package/lib/cjs/components/checkbox/Checkbox.form.js +0 -5
- package/lib/cjs/components/columns/Columns.d.ts +2 -3
- package/lib/cjs/components/columns/Columns.form.d.ts +3 -6
- package/lib/cjs/components/columns/Columns.form.js +0 -5
- package/lib/cjs/components/columns/Columns.js +1 -1
- package/lib/cjs/components/container/Container.form.d.ts +3 -6
- package/lib/cjs/components/container/Container.form.js +0 -5
- package/lib/cjs/components/content/Content.d.ts +1 -2
- package/lib/cjs/components/content/Content.form.d.ts +3 -6
- package/lib/cjs/components/content/Content.form.js +0 -5
- package/lib/cjs/components/currency/Currency.form.d.ts +3 -6
- package/lib/cjs/components/currency/Currency.form.js +0 -5
- package/lib/cjs/components/currency/Currency.js +2 -1
- package/lib/cjs/components/datagrid/DataGrid.d.ts +7 -8
- package/lib/cjs/components/datagrid/DataGrid.form.d.ts +3 -6
- package/lib/cjs/components/datagrid/DataGrid.form.js +0 -5
- package/lib/cjs/components/datagrid/DataGrid.js +5 -5
- package/lib/cjs/components/datamap/DataMap.d.ts +0 -1
- package/lib/cjs/components/datamap/DataMap.form.d.ts +3 -6
- package/lib/cjs/components/datamap/DataMap.form.js +0 -5
- package/lib/cjs/components/datetime/DateTime.d.ts +14 -0
- package/lib/cjs/components/datetime/DateTime.form.d.ts +3 -6
- package/lib/cjs/components/datetime/DateTime.form.js +0 -5
- package/lib/cjs/components/datetime/editForm/DateTime.edit.date.js +2 -2
- package/lib/cjs/components/day/Day.d.ts +48 -22
- package/lib/cjs/components/day/Day.form.d.ts +3 -6
- package/lib/cjs/components/day/Day.form.js +0 -5
- package/lib/cjs/components/day/Day.js +20 -15
- package/lib/cjs/components/editgrid/EditGrid.d.ts +3 -7
- package/lib/cjs/components/editgrid/EditGrid.form.d.ts +3 -6
- package/lib/cjs/components/editgrid/EditGrid.form.js +0 -5
- package/lib/cjs/components/editgrid/EditGrid.js +3 -3
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.display.js +5 -2
- package/lib/cjs/components/editgrid/editForm/EditGrid.edit.templates.js +9 -6
- package/lib/cjs/components/email/Email.form.d.ts +3 -6
- package/lib/cjs/components/email/Email.form.js +0 -5
- package/lib/cjs/components/fieldset/Fieldset.form.d.ts +3 -6
- package/lib/cjs/components/fieldset/Fieldset.form.js +0 -5
- package/lib/cjs/components/file/File.d.ts +22 -9
- package/lib/cjs/components/file/File.form.d.ts +3 -6
- package/lib/cjs/components/file/File.form.js +0 -5
- package/lib/cjs/components/form/Form.d.ts +20 -31
- package/lib/cjs/components/form/Form.form.d.ts +3 -6
- package/lib/cjs/components/form/Form.form.js +0 -5
- package/lib/cjs/components/form/Form.js +10 -13
- package/lib/cjs/components/hidden/Hidden.d.ts +11 -1
- package/lib/cjs/components/hidden/Hidden.form.d.ts +3 -6
- package/lib/cjs/components/hidden/Hidden.form.js +0 -5
- package/lib/cjs/components/hidden/Hidden.js +2 -1
- package/lib/cjs/components/html/HTML.d.ts +1 -2
- package/lib/cjs/components/html/HTML.form.d.ts +3 -6
- package/lib/cjs/components/html/HTML.form.js +0 -5
- package/lib/cjs/components/number/Number.d.ts +17 -3
- package/lib/cjs/components/number/Number.form.d.ts +3 -6
- package/lib/cjs/components/number/Number.form.js +0 -5
- package/lib/cjs/components/number/Number.js +2 -1
- package/lib/cjs/components/panel/Panel.form.d.ts +3 -6
- package/lib/cjs/components/panel/Panel.form.js +0 -5
- package/lib/cjs/components/panel/Panel.js +1 -0
- package/lib/cjs/components/password/Password.form.d.ts +3 -6
- package/lib/cjs/components/password/Password.form.js +0 -5
- package/lib/cjs/components/phonenumber/PhoneNumber.form.d.ts +3 -6
- package/lib/cjs/components/phonenumber/PhoneNumber.form.js +0 -5
- package/lib/cjs/components/radio/Radio.d.ts +26 -3
- package/lib/cjs/components/radio/Radio.form.d.ts +3 -6
- package/lib/cjs/components/radio/Radio.form.js +0 -5
- package/lib/cjs/components/radio/Radio.js +4 -3
- package/lib/cjs/components/recaptcha/ReCaptcha.d.ts +1 -1
- package/lib/cjs/components/recaptcha/ReCaptcha.form.d.ts +3 -5
- package/lib/cjs/components/recaptcha/ReCaptcha.form.js +0 -4
- package/lib/cjs/components/select/Select.d.ts +39 -16
- package/lib/cjs/components/select/Select.form.d.ts +3 -6
- package/lib/cjs/components/select/Select.form.js +0 -5
- package/lib/cjs/components/select/Select.js +16 -13
- package/lib/cjs/components/selectboxes/SelectBoxes.d.ts +17 -2
- package/lib/cjs/components/selectboxes/SelectBoxes.form.d.ts +3 -6
- package/lib/cjs/components/selectboxes/SelectBoxes.form.js +0 -5
- package/lib/cjs/components/selectboxes/SelectBoxes.js +9 -7
- package/lib/cjs/components/signature/Signature.d.ts +14 -1
- package/lib/cjs/components/signature/Signature.form.d.ts +3 -6
- package/lib/cjs/components/signature/Signature.form.js +0 -5
- package/lib/cjs/components/survey/Survey.d.ts +15 -3
- package/lib/cjs/components/survey/Survey.form.d.ts +3 -6
- package/lib/cjs/components/survey/Survey.form.js +0 -5
- package/lib/cjs/components/table/Table.d.ts +1 -2
- package/lib/cjs/components/table/Table.form.d.ts +3 -6
- package/lib/cjs/components/table/Table.form.js +0 -5
- package/lib/cjs/components/tabs/Tabs.d.ts +4 -4
- package/lib/cjs/components/tabs/Tabs.form.d.ts +3 -6
- package/lib/cjs/components/tabs/Tabs.form.js +0 -5
- package/lib/cjs/components/tabs/Tabs.js +2 -1
- package/lib/cjs/components/tags/Tags.d.ts +14 -0
- package/lib/cjs/components/tags/Tags.form.d.ts +3 -6
- package/lib/cjs/components/tags/Tags.form.js +0 -5
- package/lib/cjs/components/textarea/TextArea.d.ts +9 -4
- package/lib/cjs/components/textarea/TextArea.form.d.ts +3 -6
- package/lib/cjs/components/textarea/TextArea.form.js +0 -5
- package/lib/cjs/components/textarea/TextArea.js +2 -2
- package/lib/cjs/components/textfield/TextField.d.ts +30 -14
- package/lib/cjs/components/textfield/TextField.form.d.ts +3 -6
- package/lib/cjs/components/textfield/TextField.form.js +0 -5
- package/lib/cjs/components/textfield/TextField.js +16 -13
- package/lib/cjs/components/time/Time.form.d.ts +3 -6
- package/lib/cjs/components/time/Time.form.js +0 -5
- package/lib/cjs/components/unknown/Unknown.form.d.ts +34 -5
- package/lib/cjs/components/unknown/Unknown.form.js +0 -4
- package/lib/cjs/components/url/Url.form.d.ts +3 -6
- package/lib/cjs/components/url/Url.form.js +0 -5
- package/lib/cjs/components/well/Well.form.d.ts +3 -6
- package/lib/cjs/components/well/Well.form.js +0 -5
- package/lib/cjs/formio.embed.d.ts +2 -1
- package/lib/cjs/formio.embed.js +100 -2
- package/lib/cjs/formio.form.d.ts +4 -11
- package/lib/cjs/formio.form.js +5 -13
- package/lib/cjs/providers/Providers.d.ts +5 -36
- package/lib/cjs/providers/Providers.js +0 -29
- package/lib/cjs/providers/address/AddressProvider.d.ts +12 -131
- package/lib/cjs/providers/address/AddressProvider.js +2 -88
- package/lib/cjs/providers/address/AzureAddressProvider.d.ts +1 -48
- package/lib/cjs/providers/address/AzureAddressProvider.js +0 -37
- package/lib/cjs/providers/address/CustomAddressProvider.d.ts +4 -27
- package/lib/cjs/providers/address/CustomAddressProvider.js +0 -34
- package/lib/cjs/providers/address/GoogleAddressProvider.d.ts +6 -130
- package/lib/cjs/providers/address/GoogleAddressProvider.js +0 -72
- package/lib/cjs/providers/address/NominatimAddressProvider.d.ts +7 -32
- package/lib/cjs/providers/address/NominatimAddressProvider.js +0 -33
- package/lib/cjs/providers/address/index.d.ts +1 -3
- package/lib/cjs/providers/processor/fileProcessor.d.ts +1 -7
- package/lib/cjs/providers/processor/fileProcessor.js +0 -6
- package/lib/cjs/providers/storage/azure.d.ts +13 -6
- package/lib/cjs/providers/storage/azure.js +0 -5
- package/lib/cjs/providers/storage/base64.d.ts +6 -5
- package/lib/cjs/providers/storage/base64.js +0 -4
- package/lib/cjs/providers/storage/dropbox.d.ts +4 -6
- package/lib/cjs/providers/storage/dropbox.js +0 -5
- package/lib/cjs/providers/storage/googleDrive.d.ts +5 -7
- package/lib/cjs/providers/storage/googleDrive.js +0 -6
- package/lib/cjs/providers/storage/indexeddb.d.ts +7 -5
- package/lib/cjs/providers/storage/indexeddb.js +0 -4
- package/lib/cjs/providers/storage/s3.d.ts +20 -6
- package/lib/cjs/providers/storage/s3.js +0 -5
- package/lib/cjs/providers/storage/url.d.ts +7 -6
- package/lib/cjs/providers/storage/url.js +0 -10
- package/lib/cjs/providers/storage/util.d.ts +1 -24
- package/lib/cjs/providers/storage/util.js +0 -18
- package/lib/cjs/templates/Templates.d.ts +0 -1
- package/lib/cjs/translations/en.d.ts +1 -0
- package/lib/cjs/translations/en.js +1 -0
- package/lib/cjs/utils/Evaluator.d.ts +3 -6
- package/lib/cjs/utils/Evaluator.js +20 -11
- package/lib/cjs/utils/builder.d.ts +7 -9
- package/lib/cjs/utils/builder.js +5 -10
- package/lib/cjs/utils/calendarUtils.d.ts +13 -7
- package/lib/cjs/utils/calendarUtils.js +17 -10
- package/lib/cjs/utils/formUtils.d.ts +171 -43
- package/lib/cjs/utils/formUtils.js +569 -38
- package/lib/cjs/utils/utils.d.ts +216 -362
- package/lib/cjs/utils/utils.js +224 -331
- package/lib/cjs/widgets/CalendarWidget.d.ts +10 -9
- package/lib/cjs/widgets/CalendarWidget.js +11 -9
- package/lib/mjs/Element.d.ts +96 -86
- package/lib/mjs/Element.js +78 -68
- package/lib/mjs/Form.d.ts +36 -365
- package/lib/mjs/Form.js +57 -140
- package/lib/mjs/FormBuilder.d.ts +2 -187
- package/lib/mjs/FormBuilder.js +8 -32
- package/lib/mjs/PDF.d.ts +13 -11
- package/lib/mjs/PDF.js +8 -6
- package/lib/mjs/Webform.d.ts +139 -180
- package/lib/mjs/Webform.js +310 -325
- package/lib/mjs/WebformBuilder.d.ts +14 -16
- package/lib/mjs/WebformBuilder.js +11 -16
- package/lib/mjs/Wizard.d.ts +21 -31
- package/lib/mjs/Wizard.js +18 -41
- package/lib/mjs/WizardBuilder.d.ts +1 -1
- package/lib/mjs/addons/PasswordStrength/PasswordStrengthAddon.d.ts +5 -8
- package/lib/mjs/addons/PasswordStrength/PasswordStrengthAddon.js +3 -6
- package/lib/mjs/components/Components.d.ts +4 -4
- package/lib/mjs/components/Components.js +3 -3
- package/lib/mjs/components/_classes/component/Component.d.ts +269 -502
- package/lib/mjs/components/_classes/component/Component.form.d.ts +3 -6
- package/lib/mjs/components/_classes/component/Component.form.js +0 -5
- package/lib/mjs/components/_classes/component/Component.js +189 -433
- package/lib/mjs/components/_classes/component/editForm/Component.edit.display.js +8 -0
- package/lib/mjs/components/_classes/component/editForm/Component.edit.validation.js +1 -1
- package/lib/mjs/components/_classes/component/editForm/utils.js +1 -1
- package/lib/mjs/components/_classes/field/Field.d.ts +2 -11
- package/lib/mjs/components/_classes/field/Field.js +1 -13
- package/lib/mjs/components/_classes/input/Input.d.ts +3 -4
- package/lib/mjs/components/_classes/input/Input.js +2 -2
- package/lib/mjs/components/_classes/list/ListComponent.d.ts +2 -2
- package/lib/mjs/components/_classes/list/ListComponent.form.d.ts +3 -6
- package/lib/mjs/components/_classes/list/ListComponent.form.js +0 -5
- package/lib/mjs/components/_classes/multivalue/Multivalue.d.ts +12 -43
- package/lib/mjs/components/_classes/multivalue/Multivalue.js +3 -37
- package/lib/mjs/components/_classes/nested/NestedComponent.d.ts +67 -163
- package/lib/mjs/components/_classes/nested/NestedComponent.form.d.ts +3 -6
- package/lib/mjs/components/_classes/nested/NestedComponent.form.js +0 -5
- package/lib/mjs/components/_classes/nested/NestedComponent.js +54 -175
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +2 -2
- package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.js +1 -1
- package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.d.ts +1 -7
- package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.js +3 -2
- package/lib/mjs/components/address/Address.d.ts +2 -4
- package/lib/mjs/components/address/Address.form.d.ts +3 -6
- package/lib/mjs/components/address/Address.form.js +0 -5
- package/lib/mjs/components/button/Button.d.ts +12 -3
- package/lib/mjs/components/button/Button.form.d.ts +3 -6
- package/lib/mjs/components/button/Button.form.js +0 -5
- package/lib/mjs/components/button/Button.js +0 -5
- package/lib/mjs/components/checkbox/Checkbox.d.ts +27 -4
- package/lib/mjs/components/checkbox/Checkbox.form.d.ts +3 -6
- package/lib/mjs/components/checkbox/Checkbox.form.js +0 -5
- package/lib/mjs/components/columns/Columns.d.ts +2 -3
- package/lib/mjs/components/columns/Columns.form.d.ts +3 -6
- package/lib/mjs/components/columns/Columns.form.js +0 -5
- package/lib/mjs/components/columns/Columns.js +1 -1
- package/lib/mjs/components/container/Container.form.d.ts +3 -6
- package/lib/mjs/components/container/Container.form.js +0 -5
- package/lib/mjs/components/content/Content.d.ts +1 -2
- package/lib/mjs/components/content/Content.form.d.ts +3 -6
- package/lib/mjs/components/content/Content.form.js +0 -5
- package/lib/mjs/components/currency/Currency.form.d.ts +3 -6
- package/lib/mjs/components/currency/Currency.form.js +0 -5
- package/lib/mjs/components/currency/Currency.js +2 -1
- package/lib/mjs/components/datagrid/DataGrid.d.ts +7 -8
- package/lib/mjs/components/datagrid/DataGrid.form.d.ts +3 -6
- package/lib/mjs/components/datagrid/DataGrid.form.js +0 -5
- package/lib/mjs/components/datagrid/DataGrid.js +5 -5
- package/lib/mjs/components/datamap/DataMap.d.ts +0 -1
- package/lib/mjs/components/datamap/DataMap.form.d.ts +3 -6
- package/lib/mjs/components/datamap/DataMap.form.js +0 -5
- package/lib/mjs/components/datetime/DateTime.d.ts +14 -0
- package/lib/mjs/components/datetime/DateTime.form.d.ts +3 -6
- package/lib/mjs/components/datetime/DateTime.form.js +0 -5
- package/lib/mjs/components/datetime/editForm/DateTime.edit.date.js +1 -1
- package/lib/mjs/components/day/Day.d.ts +48 -22
- package/lib/mjs/components/day/Day.form.d.ts +3 -6
- package/lib/mjs/components/day/Day.form.js +0 -5
- package/lib/mjs/components/day/Day.js +20 -15
- package/lib/mjs/components/editgrid/EditGrid.d.ts +3 -7
- package/lib/mjs/components/editgrid/EditGrid.form.d.ts +3 -6
- package/lib/mjs/components/editgrid/EditGrid.form.js +0 -5
- package/lib/mjs/components/editgrid/EditGrid.js +3 -3
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.display.js +1 -1
- package/lib/mjs/components/editgrid/editForm/EditGrid.edit.templates.js +1 -1
- package/lib/mjs/components/email/Email.form.d.ts +3 -6
- package/lib/mjs/components/email/Email.form.js +0 -5
- package/lib/mjs/components/fieldset/Fieldset.form.d.ts +3 -6
- package/lib/mjs/components/fieldset/Fieldset.form.js +0 -5
- package/lib/mjs/components/file/File.d.ts +22 -9
- package/lib/mjs/components/file/File.form.d.ts +3 -6
- package/lib/mjs/components/file/File.form.js +0 -5
- package/lib/mjs/components/form/Form.d.ts +20 -31
- package/lib/mjs/components/form/Form.form.d.ts +3 -6
- package/lib/mjs/components/form/Form.form.js +0 -5
- package/lib/mjs/components/form/Form.js +10 -13
- package/lib/mjs/components/hidden/Hidden.d.ts +11 -1
- package/lib/mjs/components/hidden/Hidden.form.d.ts +3 -6
- package/lib/mjs/components/hidden/Hidden.form.js +0 -5
- package/lib/mjs/components/hidden/Hidden.js +2 -1
- package/lib/mjs/components/html/HTML.d.ts +1 -2
- package/lib/mjs/components/html/HTML.form.d.ts +3 -6
- package/lib/mjs/components/html/HTML.form.js +0 -5
- package/lib/mjs/components/number/Number.d.ts +17 -3
- package/lib/mjs/components/number/Number.form.d.ts +3 -6
- package/lib/mjs/components/number/Number.form.js +0 -5
- package/lib/mjs/components/number/Number.js +2 -1
- package/lib/mjs/components/panel/Panel.form.d.ts +3 -6
- package/lib/mjs/components/panel/Panel.form.js +0 -5
- package/lib/mjs/components/panel/Panel.js +1 -0
- package/lib/mjs/components/password/Password.form.d.ts +3 -6
- package/lib/mjs/components/password/Password.form.js +0 -5
- package/lib/mjs/components/phonenumber/PhoneNumber.form.d.ts +3 -6
- package/lib/mjs/components/phonenumber/PhoneNumber.form.js +0 -5
- package/lib/mjs/components/radio/Radio.d.ts +26 -3
- package/lib/mjs/components/radio/Radio.form.d.ts +3 -6
- package/lib/mjs/components/radio/Radio.form.js +0 -5
- package/lib/mjs/components/radio/Radio.js +4 -3
- package/lib/mjs/components/recaptcha/ReCaptcha.d.ts +1 -1
- package/lib/mjs/components/recaptcha/ReCaptcha.form.d.ts +3 -5
- package/lib/mjs/components/recaptcha/ReCaptcha.form.js +0 -4
- package/lib/mjs/components/select/Select.d.ts +39 -16
- package/lib/mjs/components/select/Select.form.d.ts +3 -6
- package/lib/mjs/components/select/Select.form.js +0 -5
- package/lib/mjs/components/select/Select.js +16 -13
- package/lib/mjs/components/selectboxes/SelectBoxes.d.ts +17 -2
- package/lib/mjs/components/selectboxes/SelectBoxes.form.d.ts +3 -6
- package/lib/mjs/components/selectboxes/SelectBoxes.form.js +0 -5
- package/lib/mjs/components/selectboxes/SelectBoxes.js +9 -7
- package/lib/mjs/components/signature/Signature.d.ts +14 -1
- package/lib/mjs/components/signature/Signature.form.d.ts +3 -6
- package/lib/mjs/components/signature/Signature.form.js +0 -5
- package/lib/mjs/components/survey/Survey.d.ts +15 -3
- package/lib/mjs/components/survey/Survey.form.d.ts +3 -6
- package/lib/mjs/components/survey/Survey.form.js +0 -5
- package/lib/mjs/components/table/Table.d.ts +1 -2
- package/lib/mjs/components/table/Table.form.d.ts +3 -6
- package/lib/mjs/components/table/Table.form.js +0 -5
- package/lib/mjs/components/tabs/Tabs.d.ts +4 -4
- package/lib/mjs/components/tabs/Tabs.form.d.ts +3 -6
- package/lib/mjs/components/tabs/Tabs.form.js +0 -5
- package/lib/mjs/components/tabs/Tabs.js +2 -1
- package/lib/mjs/components/tags/Tags.d.ts +14 -0
- package/lib/mjs/components/tags/Tags.form.d.ts +3 -6
- package/lib/mjs/components/tags/Tags.form.js +0 -5
- package/lib/mjs/components/textarea/TextArea.d.ts +9 -4
- package/lib/mjs/components/textarea/TextArea.form.d.ts +3 -6
- package/lib/mjs/components/textarea/TextArea.form.js +0 -5
- package/lib/mjs/components/textarea/TextArea.js +2 -2
- package/lib/mjs/components/textfield/TextField.d.ts +30 -14
- package/lib/mjs/components/textfield/TextField.form.d.ts +3 -6
- package/lib/mjs/components/textfield/TextField.form.js +0 -5
- package/lib/mjs/components/textfield/TextField.js +16 -13
- package/lib/mjs/components/time/Time.form.d.ts +3 -6
- package/lib/mjs/components/time/Time.form.js +0 -5
- package/lib/mjs/components/unknown/Unknown.form.d.ts +34 -5
- package/lib/mjs/components/unknown/Unknown.form.js +0 -4
- package/lib/mjs/components/url/Url.form.d.ts +3 -6
- package/lib/mjs/components/url/Url.form.js +0 -5
- package/lib/mjs/components/well/Well.form.d.ts +3 -6
- package/lib/mjs/components/well/Well.form.js +0 -5
- package/lib/mjs/formio.embed.d.ts +2 -1
- package/lib/mjs/formio.embed.js +99 -2
- package/lib/mjs/formio.form.d.ts +4 -11
- package/lib/mjs/formio.form.js +3 -10
- package/lib/mjs/providers/Providers.d.ts +5 -36
- package/lib/mjs/providers/Providers.js +0 -29
- package/lib/mjs/providers/address/AddressProvider.d.ts +12 -131
- package/lib/mjs/providers/address/AddressProvider.js +2 -88
- package/lib/mjs/providers/address/AzureAddressProvider.d.ts +1 -48
- package/lib/mjs/providers/address/AzureAddressProvider.js +0 -37
- package/lib/mjs/providers/address/CustomAddressProvider.d.ts +4 -27
- package/lib/mjs/providers/address/CustomAddressProvider.js +0 -34
- package/lib/mjs/providers/address/GoogleAddressProvider.d.ts +6 -130
- package/lib/mjs/providers/address/GoogleAddressProvider.js +0 -72
- package/lib/mjs/providers/address/NominatimAddressProvider.d.ts +7 -32
- package/lib/mjs/providers/address/NominatimAddressProvider.js +0 -33
- package/lib/mjs/providers/address/index.d.ts +1 -3
- package/lib/mjs/providers/processor/fileProcessor.d.ts +1 -7
- package/lib/mjs/providers/processor/fileProcessor.js +0 -6
- package/lib/mjs/providers/storage/azure.d.ts +13 -6
- package/lib/mjs/providers/storage/azure.js +0 -5
- package/lib/mjs/providers/storage/base64.d.ts +6 -5
- package/lib/mjs/providers/storage/base64.js +0 -4
- package/lib/mjs/providers/storage/dropbox.d.ts +4 -6
- package/lib/mjs/providers/storage/dropbox.js +0 -5
- package/lib/mjs/providers/storage/googleDrive.d.ts +5 -7
- package/lib/mjs/providers/storage/googleDrive.js +0 -6
- package/lib/mjs/providers/storage/indexeddb.d.ts +7 -5
- package/lib/mjs/providers/storage/indexeddb.js +0 -4
- package/lib/mjs/providers/storage/s3.d.ts +20 -6
- package/lib/mjs/providers/storage/s3.js +0 -5
- package/lib/mjs/providers/storage/url.d.ts +7 -6
- package/lib/mjs/providers/storage/url.js +0 -10
- package/lib/mjs/providers/storage/util.d.ts +1 -24
- package/lib/mjs/providers/storage/util.js +0 -18
- package/lib/mjs/templates/Templates.d.ts +0 -1
- package/lib/mjs/translations/en.d.ts +1 -0
- package/lib/mjs/translations/en.js +1 -0
- package/lib/mjs/utils/Evaluator.d.ts +3 -6
- package/lib/mjs/utils/Evaluator.js +20 -9
- package/lib/mjs/utils/builder.d.ts +7 -9
- package/lib/mjs/utils/builder.js +5 -10
- package/lib/mjs/utils/calendarUtils.d.ts +13 -7
- package/lib/mjs/utils/calendarUtils.js +17 -10
- package/lib/mjs/utils/formUtils.d.ts +171 -43
- package/lib/mjs/utils/formUtils.js +554 -6
- package/lib/mjs/utils/utils.d.ts +216 -362
- package/lib/mjs/utils/utils.js +218 -325
- package/lib/mjs/widgets/CalendarWidget.d.ts +10 -9
- package/lib/mjs/widgets/CalendarWidget.js +11 -9
- package/package.json +22 -22
- package/embed.d.ts +0 -1
- package/form.d.ts +0 -1
- package/lib/cjs/InlineEmbed.d.ts +0 -7
- package/lib/cjs/InlineEmbed.js +0 -109
- package/lib/mjs/InlineEmbed.d.ts +0 -7
- package/lib/mjs/InlineEmbed.js +0 -105
- package/sdk.d.ts +0 -1
- package/utils.d.ts +0 -1
|
@@ -1,142 +1,18 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @typedef {object} AutocompleteOptions
|
|
3
|
-
* @property {string[]} fields - The fields to include in the autocomplete response.
|
|
4
|
-
* @property {object} componentRestrictions - The component restrictions for the autocomplete response.
|
|
5
|
-
* @property {string[]} componentRestrictions.country - The country codes to restrict the autocomplete response to.
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* @typedef {object} ProviderOptions
|
|
9
|
-
* @property {string} region - The region to restrict the autocomplete response to.
|
|
10
|
-
* @property {string} key - The API key for Google Maps.
|
|
11
|
-
* @property {AutocompleteOptions} autocompleteOptions - The options for the autocomplete functionality.
|
|
12
|
-
*/
|
|
13
|
-
/**
|
|
14
|
-
* @typedef {object} Place
|
|
15
|
-
* @property {object} address_components - The address components of the place.
|
|
16
|
-
* @property {string} formatted_address - The formatted address of the place.
|
|
17
|
-
* @property {object} geometry - The geometry information of the place.
|
|
18
|
-
* @property {string} place_id - The place ID of the place.
|
|
19
|
-
* @property {object} plus_code - The plus code of the place.
|
|
20
|
-
* @property {string[]} types - The types of the place.
|
|
21
|
-
* @property {string} formattedPlace - The formatted place value.
|
|
22
|
-
*/
|
|
23
|
-
/**
|
|
24
|
-
* @class GoogleAddressProvider
|
|
25
|
-
* @augments AddressProvider
|
|
26
|
-
*/
|
|
27
1
|
export class GoogleAddressProvider extends AddressProvider {
|
|
28
|
-
/**
|
|
29
|
-
|
|
30
|
-
* @param {ProviderOptions} options - The options for the provider.
|
|
31
|
-
*/
|
|
32
|
-
constructor(options?: ProviderOptions);
|
|
33
|
-
/**
|
|
34
|
-
* get display value property
|
|
35
|
-
* @returns {string} The property to use for display value.
|
|
36
|
-
*/
|
|
37
2
|
get displayValueProperty(): string;
|
|
38
|
-
/**
|
|
39
|
-
* @returns {string} The alternative property to use for display value.
|
|
40
|
-
*/
|
|
41
3
|
get alternativeDisplayValueProperty(): string;
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
set autocompleteOptions(options: AutocompleteOptions);
|
|
46
|
-
/**
|
|
47
|
-
* @returns {AutocompleteOptions} The autocomplete options.
|
|
48
|
-
*/
|
|
49
|
-
get autocompleteOptions(): AutocompleteOptions;
|
|
50
|
-
_autocompleteOptions: AutocompleteOptions | undefined;
|
|
51
|
-
/**
|
|
52
|
-
* Sets the autocomplete options based on the provider options.
|
|
53
|
-
|
|
54
|
-
*/
|
|
4
|
+
set autocompleteOptions(options: any);
|
|
5
|
+
get autocompleteOptions(): any;
|
|
6
|
+
_autocompleteOptions: any;
|
|
55
7
|
setAutocompleteOptions(): void;
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
* Converts the region to autocomplete option if it exists.
|
|
59
|
-
* @param {ProviderOptions} options - The provider options.
|
|
60
|
-
*/
|
|
61
|
-
beforeMergeOptions(options: ProviderOptions): void;
|
|
62
|
-
/**
|
|
63
|
-
* @returns {string} The name of the library.
|
|
64
|
-
*/
|
|
8
|
+
beforeMergeOptions(options: any): void;
|
|
65
9
|
getLibraryName(): string;
|
|
66
|
-
|
|
67
|
-
* Converts the region to autocomplete option.
|
|
68
|
-
* @param {ProviderOptions} options - The provider options.
|
|
69
|
-
*/
|
|
70
|
-
convertRegionToAutocompleteOption(options: ProviderOptions): void;
|
|
71
|
-
/**
|
|
72
|
-
* @returns {string[]} The required address properties.
|
|
73
|
-
*/
|
|
10
|
+
convertRegionToAutocompleteOption(options: any): void;
|
|
74
11
|
getRequiredAddressProperties(): string[];
|
|
75
|
-
|
|
76
|
-
* Adds the required provider options to the options.
|
|
77
|
-
* @param {AutocompleteOptions} options - The autocomplete options.
|
|
78
|
-
*/
|
|
79
|
-
addRequiredProviderOptions(options: AutocompleteOptions): void;
|
|
12
|
+
addRequiredProviderOptions(options: any): void;
|
|
80
13
|
filterPlace(place: any): {};
|
|
81
14
|
attachAutocomplete(elem: any, index: any, onSelectAddress: any): void;
|
|
82
15
|
search(): Promise<void>;
|
|
83
16
|
makeRequest(): Promise<void>;
|
|
84
|
-
getDisplayValue(address: any): any;
|
|
85
17
|
}
|
|
86
|
-
export type AutocompleteOptions = {
|
|
87
|
-
/**
|
|
88
|
-
* - The fields to include in the autocomplete response.
|
|
89
|
-
*/
|
|
90
|
-
fields: string[];
|
|
91
|
-
/**
|
|
92
|
-
* - The component restrictions for the autocomplete response.
|
|
93
|
-
*/
|
|
94
|
-
componentRestrictions: {
|
|
95
|
-
country: string[];
|
|
96
|
-
};
|
|
97
|
-
};
|
|
98
|
-
export type ProviderOptions = {
|
|
99
|
-
/**
|
|
100
|
-
* - The region to restrict the autocomplete response to.
|
|
101
|
-
*/
|
|
102
|
-
region: string;
|
|
103
|
-
/**
|
|
104
|
-
* - The API key for Google Maps.
|
|
105
|
-
*/
|
|
106
|
-
key: string;
|
|
107
|
-
/**
|
|
108
|
-
* - The options for the autocomplete functionality.
|
|
109
|
-
*/
|
|
110
|
-
autocompleteOptions: AutocompleteOptions;
|
|
111
|
-
};
|
|
112
|
-
export type Place = {
|
|
113
|
-
/**
|
|
114
|
-
* - The address components of the place.
|
|
115
|
-
*/
|
|
116
|
-
address_components: object;
|
|
117
|
-
/**
|
|
118
|
-
* - The formatted address of the place.
|
|
119
|
-
*/
|
|
120
|
-
formatted_address: string;
|
|
121
|
-
/**
|
|
122
|
-
* - The geometry information of the place.
|
|
123
|
-
*/
|
|
124
|
-
geometry: object;
|
|
125
|
-
/**
|
|
126
|
-
* - The place ID of the place.
|
|
127
|
-
*/
|
|
128
|
-
place_id: string;
|
|
129
|
-
/**
|
|
130
|
-
* - The plus code of the place.
|
|
131
|
-
*/
|
|
132
|
-
plus_code: object;
|
|
133
|
-
/**
|
|
134
|
-
* - The types of the place.
|
|
135
|
-
*/
|
|
136
|
-
types: string[];
|
|
137
|
-
/**
|
|
138
|
-
* - The formatted place value.
|
|
139
|
-
*/
|
|
140
|
-
formattedPlace: string;
|
|
141
|
-
};
|
|
142
18
|
import { AddressProvider } from './AddressProvider';
|
|
@@ -2,49 +2,13 @@
|
|
|
2
2
|
import { Formio } from '../../Formio';
|
|
3
3
|
import _ from 'lodash';
|
|
4
4
|
import { AddressProvider } from './AddressProvider';
|
|
5
|
-
/**
|
|
6
|
-
* @typedef {object} AutocompleteOptions
|
|
7
|
-
* @property {string[]} fields - The fields to include in the autocomplete response.
|
|
8
|
-
* @property {object} componentRestrictions - The component restrictions for the autocomplete response.
|
|
9
|
-
* @property {string[]} componentRestrictions.country - The country codes to restrict the autocomplete response to.
|
|
10
|
-
*/
|
|
11
|
-
/**
|
|
12
|
-
* @typedef {object} ProviderOptions
|
|
13
|
-
* @property {string} region - The region to restrict the autocomplete response to.
|
|
14
|
-
* @property {string} key - The API key for Google Maps.
|
|
15
|
-
* @property {AutocompleteOptions} autocompleteOptions - The options for the autocomplete functionality.
|
|
16
|
-
*/
|
|
17
|
-
/**
|
|
18
|
-
* @typedef {object} Place
|
|
19
|
-
* @property {object} address_components - The address components of the place.
|
|
20
|
-
* @property {string} formatted_address - The formatted address of the place.
|
|
21
|
-
* @property {object} geometry - The geometry information of the place.
|
|
22
|
-
* @property {string} place_id - The place ID of the place.
|
|
23
|
-
* @property {object} plus_code - The plus code of the place.
|
|
24
|
-
* @property {string[]} types - The types of the place.
|
|
25
|
-
* @property {string} formattedPlace - The formatted place value.
|
|
26
|
-
*/
|
|
27
|
-
/**
|
|
28
|
-
* @class GoogleAddressProvider
|
|
29
|
-
* @augments AddressProvider
|
|
30
|
-
*/
|
|
31
5
|
export class GoogleAddressProvider extends AddressProvider {
|
|
32
|
-
/**
|
|
33
|
-
* @returns {string} The name of the provider.
|
|
34
|
-
*/
|
|
35
6
|
static get name() {
|
|
36
7
|
return 'google';
|
|
37
8
|
}
|
|
38
|
-
/**
|
|
39
|
-
* @returns {string} The display name of the provider.
|
|
40
|
-
*/
|
|
41
9
|
static get displayName() {
|
|
42
10
|
return 'Google Maps';
|
|
43
11
|
}
|
|
44
|
-
/**
|
|
45
|
-
|
|
46
|
-
* @param {ProviderOptions} options - The options for the provider.
|
|
47
|
-
*/
|
|
48
12
|
constructor(options = {}) {
|
|
49
13
|
super(options);
|
|
50
14
|
this.setAutocompleteOptions();
|
|
@@ -54,35 +18,18 @@ export class GoogleAddressProvider extends AddressProvider {
|
|
|
54
18
|
}
|
|
55
19
|
Formio.requireLibrary(this.getLibraryName(), 'google.maps.places', src);
|
|
56
20
|
}
|
|
57
|
-
/**
|
|
58
|
-
* get display value property
|
|
59
|
-
* @returns {string} The property to use for display value.
|
|
60
|
-
*/
|
|
61
21
|
get displayValueProperty() {
|
|
62
22
|
return 'formattedPlace';
|
|
63
23
|
}
|
|
64
|
-
/**
|
|
65
|
-
* @returns {string} The alternative property to use for display value.
|
|
66
|
-
*/
|
|
67
24
|
get alternativeDisplayValueProperty() {
|
|
68
25
|
return 'formatted_address';
|
|
69
26
|
}
|
|
70
|
-
/**
|
|
71
|
-
* @param {AutocompleteOptions} options - The autocomplete options.
|
|
72
|
-
*/
|
|
73
27
|
set autocompleteOptions(options) {
|
|
74
28
|
this._autocompleteOptions = options;
|
|
75
29
|
}
|
|
76
|
-
/**
|
|
77
|
-
* @returns {AutocompleteOptions} The autocomplete options.
|
|
78
|
-
*/
|
|
79
30
|
get autocompleteOptions() {
|
|
80
31
|
return this._autocompleteOptions;
|
|
81
32
|
}
|
|
82
|
-
/**
|
|
83
|
-
* Sets the autocomplete options based on the provider options.
|
|
84
|
-
|
|
85
|
-
*/
|
|
86
33
|
setAutocompleteOptions() {
|
|
87
34
|
let options = _.get(this.options, 'params.autocompleteOptions', {});
|
|
88
35
|
if (!_.isObject(options)) {
|
|
@@ -91,25 +38,13 @@ export class GoogleAddressProvider extends AddressProvider {
|
|
|
91
38
|
this.addRequiredProviderOptions(options);
|
|
92
39
|
this.autocompleteOptions = options;
|
|
93
40
|
}
|
|
94
|
-
/**
|
|
95
|
-
|
|
96
|
-
* Converts the region to autocomplete option if it exists.
|
|
97
|
-
* @param {ProviderOptions} options - The provider options.
|
|
98
|
-
*/
|
|
99
41
|
beforeMergeOptions(options) {
|
|
100
42
|
// providing support of old Google Provider option
|
|
101
43
|
this.convertRegionToAutocompleteOption(options);
|
|
102
44
|
}
|
|
103
|
-
/**
|
|
104
|
-
* @returns {string} The name of the library.
|
|
105
|
-
*/
|
|
106
45
|
getLibraryName() {
|
|
107
46
|
return 'googleMaps';
|
|
108
47
|
}
|
|
109
|
-
/**
|
|
110
|
-
* Converts the region to autocomplete option.
|
|
111
|
-
* @param {ProviderOptions} options - The provider options.
|
|
112
|
-
*/
|
|
113
48
|
convertRegionToAutocompleteOption(options) {
|
|
114
49
|
const providerOptions = options;
|
|
115
50
|
let region = _.get(providerOptions, 'params.region', '');
|
|
@@ -123,16 +58,9 @@ export class GoogleAddressProvider extends AddressProvider {
|
|
|
123
58
|
_.set(providerOptions, 'params.autocompleteOptions.componentRestrictions.country', [region]);
|
|
124
59
|
}
|
|
125
60
|
}
|
|
126
|
-
/**
|
|
127
|
-
* @returns {string[]} The required address properties.
|
|
128
|
-
*/
|
|
129
61
|
getRequiredAddressProperties() {
|
|
130
62
|
return ['address_components', 'formatted_address', 'geometry', 'place_id', 'plus_code', 'types'];
|
|
131
63
|
}
|
|
132
|
-
/**
|
|
133
|
-
* Adds the required provider options to the options.
|
|
134
|
-
* @param {AutocompleteOptions} options - The autocomplete options.
|
|
135
|
-
*/
|
|
136
64
|
addRequiredProviderOptions(options) {
|
|
137
65
|
const addressProperties = this.getRequiredAddressProperties();
|
|
138
66
|
if (_.isArray(options.fields) && options.fields.length > 0) {
|
|
@@ -1,36 +1,11 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @typedef {object} NominatimAddressProviderOptionsParams
|
|
3
|
-
* @property {{ addressdetails: string, format: string } } params - The parameters for the Nominatim API request.
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* Represents an Nominatim address provider.
|
|
7
|
-
* {extends AddressProvider}
|
|
8
|
-
*/
|
|
9
1
|
export class NominatimAddressProvider extends AddressProvider {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
* Gets the display value property for the address provider.
|
|
17
|
-
* @returns {string} The property to use for display value.
|
|
18
|
-
*/
|
|
2
|
+
get defaultOptions(): {
|
|
3
|
+
params: {
|
|
4
|
+
addressdetails: string;
|
|
5
|
+
format: string;
|
|
6
|
+
};
|
|
7
|
+
};
|
|
19
8
|
get displayValueProperty(): string;
|
|
20
|
-
|
|
21
|
-
* Generates the request URL for the address provider with options.
|
|
22
|
-
* @param {NominatimAddressProviderOptionsParams} options - The request options.
|
|
23
|
-
* @returns {string} The formatted Url.
|
|
24
|
-
*/
|
|
25
|
-
getRequestUrl(options?: NominatimAddressProviderOptionsParams): string;
|
|
9
|
+
getRequestUrl(options?: {}): string;
|
|
26
10
|
}
|
|
27
|
-
export type NominatimAddressProviderOptionsParams = {
|
|
28
|
-
/**
|
|
29
|
-
* - The parameters for the Nominatim API request.
|
|
30
|
-
*/
|
|
31
|
-
params: {
|
|
32
|
-
addressdetails: string;
|
|
33
|
-
format: string;
|
|
34
|
-
};
|
|
35
|
-
};
|
|
36
11
|
import { AddressProvider } from './AddressProvider';
|
|
@@ -1,31 +1,11 @@
|
|
|
1
1
|
import { AddressProvider } from './AddressProvider';
|
|
2
|
-
/**
|
|
3
|
-
* @typedef {object} NominatimAddressProviderOptionsParams
|
|
4
|
-
* @property {{ addressdetails: string, format: string } } params - The parameters for the Nominatim API request.
|
|
5
|
-
*/
|
|
6
|
-
/**
|
|
7
|
-
* Represents an Nominatim address provider.
|
|
8
|
-
* {extends AddressProvider}
|
|
9
|
-
*/
|
|
10
2
|
export class NominatimAddressProvider extends AddressProvider {
|
|
11
|
-
/**
|
|
12
|
-
* Gets the name of the address provider.
|
|
13
|
-
* @type {string}
|
|
14
|
-
*/
|
|
15
3
|
static get name() {
|
|
16
4
|
return 'nominatim';
|
|
17
5
|
}
|
|
18
|
-
/**
|
|
19
|
-
* Gets the display name of the address provider.
|
|
20
|
-
* @type {string}
|
|
21
|
-
*/
|
|
22
6
|
static get displayName() {
|
|
23
7
|
return 'OpenStreetMap Nominatim';
|
|
24
8
|
}
|
|
25
|
-
/**
|
|
26
|
-
* Gets the default options for the address provider.
|
|
27
|
-
* @returns {NominatimAddressProviderOptionsParams} The default options.
|
|
28
|
-
*/
|
|
29
9
|
get defaultOptions() {
|
|
30
10
|
return {
|
|
31
11
|
params: {
|
|
@@ -34,25 +14,12 @@ export class NominatimAddressProvider extends AddressProvider {
|
|
|
34
14
|
},
|
|
35
15
|
};
|
|
36
16
|
}
|
|
37
|
-
/**
|
|
38
|
-
* Gets the response property for the address provider.
|
|
39
|
-
* @type {string}
|
|
40
|
-
*/
|
|
41
17
|
get queryProperty() {
|
|
42
18
|
return 'q';
|
|
43
19
|
}
|
|
44
|
-
/**
|
|
45
|
-
* Gets the display value property for the address provider.
|
|
46
|
-
* @returns {string} The property to use for display value.
|
|
47
|
-
*/
|
|
48
20
|
get displayValueProperty() {
|
|
49
21
|
return 'display_name';
|
|
50
22
|
}
|
|
51
|
-
/**
|
|
52
|
-
* Generates the request URL for the address provider with options.
|
|
53
|
-
* @param {NominatimAddressProviderOptionsParams} options - The request options.
|
|
54
|
-
* @returns {string} The formatted Url.
|
|
55
|
-
*/
|
|
56
23
|
getRequestUrl(options = {}) {
|
|
57
24
|
const { params } = options;
|
|
58
25
|
return `https://nominatim.openstreetmap.org/search?${this.serialize(params)}`;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
|
-
[x: string]: typeof
|
|
2
|
+
[x: string]: typeof CustomAddressProvider | typeof GoogleAddressProvider;
|
|
3
3
|
};
|
|
4
4
|
export default _default;
|
|
5
|
-
import { AzureAddressProvider } from './AzureAddressProvider';
|
|
6
5
|
import { CustomAddressProvider } from './CustomAddressProvider';
|
|
7
6
|
import { GoogleAddressProvider } from './GoogleAddressProvider';
|
|
8
|
-
import { NominatimAddressProvider } from './NominatimAddressProvider';
|
|
@@ -1,8 +1,2 @@
|
|
|
1
1
|
export default fileProcessor;
|
|
2
|
-
|
|
3
|
-
* Creates a file processor function.
|
|
4
|
-
* @param {Formio} formio - The Formio instance.
|
|
5
|
-
* @param {object} config - The configuration object.
|
|
6
|
-
* @returns {function(File, object): Promise<FormData>} A function that takes a file and options, and returns a Promise that resolves with the processed file.
|
|
7
|
-
*/
|
|
8
|
-
declare function fileProcessor(formio: Formio, config: object): (arg0: File, arg1: object) => Promise<FormData>;
|
|
2
|
+
declare function fileProcessor(formio: any, config: any): (file: any, options: any) => Promise<any>;
|
|
@@ -1,9 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Creates a file processor function.
|
|
3
|
-
* @param {Formio} formio - The Formio instance.
|
|
4
|
-
* @param {object} config - The configuration object.
|
|
5
|
-
* @returns {function(File, object): Promise<FormData>} A function that takes a file and options, and returns a Promise that resolves with the processed file.
|
|
6
|
-
*/
|
|
7
1
|
const fileProcessor = (formio, config) => (file, options) => new Promise((resolve, reject) => {
|
|
8
2
|
const xhr = new XMLHttpRequest();
|
|
9
3
|
// Fire on network error.
|
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
export default azure;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
declare function azure(formio: any): {
|
|
3
|
+
uploadFile(file: any, fileName: any, dir: any, progressCallback: any, url: any, options: any, fileKey: any, groupPermissions: any, groupId: any, abortCallback: any): Promise<{
|
|
4
|
+
storage: string;
|
|
5
|
+
name: any;
|
|
6
|
+
size: any;
|
|
7
|
+
type: any;
|
|
8
|
+
groupPermissions: any;
|
|
9
|
+
groupId: any;
|
|
10
|
+
key: any;
|
|
11
|
+
}>;
|
|
12
|
+
downloadFile(file: any): any;
|
|
13
|
+
deleteFile: (fileInfo: any) => any;
|
|
14
|
+
};
|
|
8
15
|
declare namespace azure {
|
|
9
16
|
let title: string;
|
|
10
17
|
}
|
|
@@ -1,9 +1,4 @@
|
|
|
1
1
|
import XHR from './xhr';
|
|
2
|
-
/**
|
|
3
|
-
* Azure File Services provider for file storage.
|
|
4
|
-
* @param {object} formio formio instance
|
|
5
|
-
* @returns {import('./typedefs').FileProvider} The FileProvider interface defined in index.js.
|
|
6
|
-
*/
|
|
7
2
|
function azure(formio) {
|
|
8
3
|
return {
|
|
9
4
|
uploadFile(file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, abortCallback) {
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
export default base64;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
declare function base64(): {
|
|
3
|
+
title: string;
|
|
4
|
+
name: string;
|
|
5
|
+
uploadFile(file: any, fileName: any): Promise<any>;
|
|
6
|
+
downloadFile(file: any): Promise<any>;
|
|
7
|
+
};
|
|
7
8
|
declare namespace base64 {
|
|
8
9
|
let title: string;
|
|
9
10
|
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
export default dropbox;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
*/
|
|
7
|
-
declare function dropbox(formio: object): any;
|
|
2
|
+
declare function dropbox(formio: any): {
|
|
3
|
+
uploadFile(file: any, fileName: any, dir: any, progressCallback: any, url: any, options: any, fileKey: any, groupPermissions: any, groupId: any, abortCallback: any): Promise<any>;
|
|
4
|
+
downloadFile(file: any): Promise<any>;
|
|
5
|
+
};
|
|
8
6
|
declare namespace dropbox {
|
|
9
7
|
let title: string;
|
|
10
8
|
}
|
|
@@ -1,9 +1,4 @@
|
|
|
1
1
|
import { setXhrHeaders } from './xhr';
|
|
2
|
-
/**
|
|
3
|
-
* Dropbox provider for file storage.
|
|
4
|
-
* @param {object} formio formio instance
|
|
5
|
-
* @returns {import('./typedefs').FileProvider} The FileProvider interface defined in index.js.
|
|
6
|
-
*/
|
|
7
2
|
function dropbox(formio) {
|
|
8
3
|
return {
|
|
9
4
|
uploadFile(file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, abortCallback) {
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
export default googledrive;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
*/
|
|
8
|
-
declare function googledrive(formio: object): any;
|
|
2
|
+
declare function googledrive(formio: any): {
|
|
3
|
+
uploadFile(file: any, fileName: any, dir: any, progressCallback: any, url: any, options: any, fileKey: any, groupPermissions: any, groupId: any, abortCallback: any): Promise<any>;
|
|
4
|
+
downloadFile(file: any): Promise<any>;
|
|
5
|
+
deleteFile: (fileInfo: any) => any;
|
|
6
|
+
};
|
|
9
7
|
declare namespace googledrive {
|
|
10
8
|
let title: string;
|
|
11
9
|
}
|
|
@@ -1,10 +1,4 @@
|
|
|
1
1
|
import { setXhrHeaders } from './xhr';
|
|
2
|
-
/**
|
|
3
|
-
*
|
|
4
|
-
* Google Drive provider for file storage.
|
|
5
|
-
* @param {object} formio - formio instance
|
|
6
|
-
* @returns {import('./typedefs').FileProvider} The FileProvider interface defined in index.js.
|
|
7
|
-
*/
|
|
8
2
|
function googledrive(formio) {
|
|
9
3
|
return {
|
|
10
4
|
uploadFile(file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, abortCallback) {
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
export default indexeddb;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
declare function indexeddb(): {
|
|
3
|
+
title: string;
|
|
4
|
+
name: string;
|
|
5
|
+
uploadFile(file: any, fileName: any, dir: any, progressCallback: any, url: any, options: any): Promise<any> | undefined;
|
|
6
|
+
downloadFile(file: any, options: any): Promise<any>;
|
|
7
|
+
deleteFile(file: any, options: any): Promise<any>;
|
|
8
|
+
};
|
|
7
9
|
declare namespace indexeddb {
|
|
8
10
|
let title: string;
|
|
9
11
|
}
|
|
@@ -1,10 +1,24 @@
|
|
|
1
1
|
export default s3;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
declare function s3(formio: any): {
|
|
3
|
+
uploadFile(file: any, fileName: any, dir: any, progressCallback: any, url: any, options: any, fileKey: any, groupPermissions: any, groupId: any, abortCallback: any, multipartOptions: any): Promise<{
|
|
4
|
+
storage: string;
|
|
5
|
+
name: any;
|
|
6
|
+
bucket: any;
|
|
7
|
+
key: any;
|
|
8
|
+
url: any;
|
|
9
|
+
acl: any;
|
|
10
|
+
size: any;
|
|
11
|
+
type: any;
|
|
12
|
+
}>;
|
|
13
|
+
completeMultipartUpload(serverResponse: any, parts: any, multipart: any): Promise<void>;
|
|
14
|
+
abortMultipartUpload(serverResponse: any): void;
|
|
15
|
+
uploadParts(file: any, urls: any, headers: any, partSize: any, multipart: any, abortSignal: any): Promise<{
|
|
16
|
+
ETag: string;
|
|
17
|
+
PartNumber: number;
|
|
18
|
+
}[]>;
|
|
19
|
+
downloadFile(file: any): any;
|
|
20
|
+
deleteFile(fileInfo: any): any;
|
|
21
|
+
};
|
|
8
22
|
declare namespace s3 {
|
|
9
23
|
let title: string;
|
|
10
24
|
}
|
|
@@ -5,11 +5,6 @@ const loadAbortControllerPolyfill = async () => {
|
|
|
5
5
|
await import('abortcontroller-polyfill/dist/polyfill-patch-fetch');
|
|
6
6
|
}
|
|
7
7
|
};
|
|
8
|
-
/**
|
|
9
|
-
* S3 File Services provider for file storage.
|
|
10
|
-
* @param {object} formio formio instance
|
|
11
|
-
* @returns {import('./typedefs').FileProvider} The FileProvider interface defined in index.js.
|
|
12
|
-
*/
|
|
13
8
|
function s3(formio) {
|
|
14
9
|
return {
|
|
15
10
|
async uploadFile(file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, abortCallback, multipartOptions) {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
export default url;
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
declare function url(formio: any): {
|
|
3
|
+
title: string;
|
|
4
|
+
name: string;
|
|
5
|
+
uploadFile(file: any, name: any, dir: any, progressCallback: any, url: any, options: any, fileKey: any, groupPermissions: any, groupId: any, abortCallback: any): any;
|
|
6
|
+
deleteFile(fileInfo: any, options: any): Promise<any>;
|
|
7
|
+
downloadFile(file: any): Promise<any>;
|
|
8
|
+
};
|
|
8
9
|
declare namespace url {
|
|
9
10
|
let title: string;
|
|
10
11
|
}
|
|
@@ -1,14 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {object} formio - formio instance
|
|
4
|
-
* @returns {import('./typedefs').FileProvider} The FileProvider interface defined in index.js.
|
|
5
|
-
*/
|
|
6
1
|
function url(formio) {
|
|
7
|
-
/**
|
|
8
|
-
*
|
|
9
|
-
* @param {object} options - options to set on the xhr
|
|
10
|
-
* @param {object} xhr - the xhr object
|
|
11
|
-
*/
|
|
12
2
|
function setOptions(options, xhr) {
|
|
13
3
|
const parsedOptions = typeof options === 'string' ? JSON.parse(options) : options;
|
|
14
4
|
for (const prop in parsedOptions) {
|
|
@@ -1,24 +1 @@
|
|
|
1
|
-
|
|
2
|
-
* @typedef {any[]} Args
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* Function to be retried
|
|
6
|
-
* @callback RetryFunction
|
|
7
|
-
* @param {...Args} args
|
|
8
|
-
* @returns {Promise<any>}
|
|
9
|
-
*/
|
|
10
|
-
/**
|
|
11
|
-
* Executes a function with retries in case of failure.
|
|
12
|
-
* @param {RetryFunction} fn - The function to be executed.
|
|
13
|
-
* @param {Args} args - The arguments to be passed to the function.
|
|
14
|
-
* @param {number} [retries] - The number of retries in case of failure.
|
|
15
|
-
* @param {string} [err] - The error message to be thrown after all retries have failed.
|
|
16
|
-
* @returns {Promise<any>} The result of the function execution.
|
|
17
|
-
* @throws {Error} When all retries have failed.
|
|
18
|
-
*/
|
|
19
|
-
export function withRetries(fn: RetryFunction, args: Args, retries?: number | undefined, err?: string | undefined): Promise<any>;
|
|
20
|
-
export type Args = any[];
|
|
21
|
-
/**
|
|
22
|
-
* Function to be retried
|
|
23
|
-
*/
|
|
24
|
-
export type RetryFunction = (...args: Args[]) => Promise<any>;
|
|
1
|
+
export function withRetries(fn: any, args: any, retries?: number, err?: null): Promise<any>;
|