@formio/js 5.0.0-rc.60 → 5.0.0-rc.63
Sign up to get free protection for your applications and to get access to all the features.
- 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 +8 -8
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.form.min.js.LICENSE.txt +1 -1
- package/dist/formio.full.js +47 -47
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.full.min.js.LICENSE.txt +1 -1
- package/dist/formio.js +3 -3
- package/dist/formio.min.js +1 -1
- package/dist/formio.min.js.LICENSE.txt +1 -1
- package/dist/formio.utils.js +2 -2
- package/dist/formio.utils.min.js +1 -1
- package/dist/formio.utils.min.js.LICENSE.txt +1 -1
- package/lib/cjs/Element.d.ts +1 -1
- package/lib/cjs/Embed.d.ts +2 -2
- package/lib/cjs/Embed.js +10 -10
- package/lib/cjs/Form.d.ts +3 -3
- package/lib/cjs/FormBuilder.d.ts +3 -42
- package/lib/cjs/Formio.js +1 -0
- package/lib/cjs/InlineEmbed.js +2 -2
- package/lib/cjs/PDF.d.ts +1 -1
- package/lib/cjs/Webform.d.ts +3 -4
- package/lib/cjs/WebformBuilder.d.ts +1 -1
- package/lib/cjs/components/_classes/component/Component.form.d.ts +1 -1
- package/lib/cjs/components/_classes/component/Component.form.js +1 -1
- package/lib/cjs/components/_classes/list/ListComponent.form.d.ts +1 -1
- package/lib/cjs/components/_classes/list/ListComponent.form.js +1 -1
- package/lib/cjs/components/_classes/nested/NestedComponent.d.ts +7 -7
- package/lib/cjs/components/_classes/nested/NestedComponent.form.d.ts +1 -1
- package/lib/cjs/components/_classes/nested/NestedComponent.form.js +1 -1
- package/lib/cjs/components/address/Address.form.d.ts +1 -1
- package/lib/cjs/components/address/Address.form.js +1 -1
- package/lib/cjs/components/button/Button.form.d.ts +1 -1
- package/lib/cjs/components/button/Button.form.js +1 -1
- package/lib/cjs/components/checkbox/Checkbox.form.d.ts +1 -1
- package/lib/cjs/components/checkbox/Checkbox.form.js +1 -1
- package/lib/cjs/components/columns/Columns.form.d.ts +1 -1
- package/lib/cjs/components/columns/Columns.form.js +1 -1
- package/lib/cjs/components/container/Container.form.d.ts +1 -1
- package/lib/cjs/components/container/Container.form.js +1 -1
- package/lib/cjs/components/content/Content.form.d.ts +1 -1
- package/lib/cjs/components/content/Content.form.js +1 -1
- package/lib/cjs/components/currency/Currency.form.d.ts +1 -1
- package/lib/cjs/components/currency/Currency.form.js +1 -1
- package/lib/cjs/components/datagrid/DataGrid.form.d.ts +1 -1
- package/lib/cjs/components/datagrid/DataGrid.form.js +1 -1
- package/lib/cjs/components/datamap/DataMap.form.d.ts +1 -1
- package/lib/cjs/components/datamap/DataMap.form.js +1 -1
- package/lib/cjs/components/datetime/DateTime.form.d.ts +1 -1
- package/lib/cjs/components/datetime/DateTime.form.js +1 -1
- package/lib/cjs/components/day/Day.form.d.ts +1 -1
- package/lib/cjs/components/day/Day.form.js +1 -1
- package/lib/cjs/components/editgrid/EditGrid.form.d.ts +1 -1
- package/lib/cjs/components/editgrid/EditGrid.form.js +1 -1
- package/lib/cjs/components/email/Email.form.d.ts +1 -1
- package/lib/cjs/components/email/Email.form.js +1 -1
- package/lib/cjs/components/fieldset/Fieldset.form.d.ts +1 -1
- package/lib/cjs/components/fieldset/Fieldset.form.js +1 -1
- package/lib/cjs/components/file/File.form.d.ts +1 -1
- package/lib/cjs/components/file/File.form.js +1 -1
- package/lib/cjs/components/form/Form.form.d.ts +1 -1
- package/lib/cjs/components/form/Form.form.js +1 -1
- package/lib/cjs/components/hidden/Hidden.form.d.ts +1 -1
- package/lib/cjs/components/hidden/Hidden.form.js +1 -1
- package/lib/cjs/components/html/HTML.form.d.ts +1 -1
- package/lib/cjs/components/html/HTML.form.js +1 -1
- package/lib/cjs/components/number/Number.form.d.ts +1 -1
- package/lib/cjs/components/number/Number.form.js +1 -1
- package/lib/cjs/components/panel/Panel.form.d.ts +1 -1
- package/lib/cjs/components/panel/Panel.form.js +1 -1
- package/lib/cjs/components/password/Password.form.d.ts +1 -1
- package/lib/cjs/components/password/Password.form.js +1 -1
- package/lib/cjs/components/phonenumber/PhoneNumber.form.d.ts +1 -1
- package/lib/cjs/components/phonenumber/PhoneNumber.form.js +1 -1
- package/lib/cjs/components/radio/Radio.form.d.ts +1 -1
- package/lib/cjs/components/radio/Radio.form.js +1 -1
- package/lib/cjs/components/recaptcha/ReCaptcha.form.d.ts +1 -1
- package/lib/cjs/components/recaptcha/ReCaptcha.form.js +1 -1
- package/lib/cjs/components/select/Select.form.d.ts +1 -1
- package/lib/cjs/components/select/Select.form.js +1 -1
- package/lib/cjs/components/selectboxes/SelectBoxes.form.d.ts +1 -1
- package/lib/cjs/components/selectboxes/SelectBoxes.form.js +1 -1
- package/lib/cjs/components/signature/Signature.form.d.ts +1 -1
- package/lib/cjs/components/signature/Signature.form.js +1 -1
- package/lib/cjs/components/survey/Survey.form.d.ts +1 -1
- package/lib/cjs/components/survey/Survey.form.js +1 -1
- package/lib/cjs/components/table/Table.form.d.ts +1 -1
- package/lib/cjs/components/table/Table.form.js +1 -1
- package/lib/cjs/components/tabs/Tabs.form.d.ts +1 -1
- package/lib/cjs/components/tabs/Tabs.form.js +1 -1
- package/lib/cjs/components/tags/Tags.form.d.ts +1 -1
- package/lib/cjs/components/tags/Tags.form.js +1 -1
- package/lib/cjs/components/textarea/TextArea.form.d.ts +1 -1
- package/lib/cjs/components/textarea/TextArea.form.js +1 -1
- package/lib/cjs/components/textfield/TextField.form.d.ts +1 -1
- package/lib/cjs/components/textfield/TextField.form.js +1 -1
- package/lib/cjs/components/time/Time.form.d.ts +1 -1
- package/lib/cjs/components/time/Time.form.js +1 -1
- package/lib/cjs/components/unknown/Unknown.form.js +1 -1
- package/lib/cjs/components/url/Url.form.d.ts +1 -1
- package/lib/cjs/components/url/Url.form.js +1 -1
- package/lib/cjs/components/well/Well.form.d.ts +1 -1
- package/lib/cjs/components/well/Well.form.js +1 -1
- package/lib/cjs/formio.form.js +3 -3
- package/lib/cjs/providers/address/AzureAddressProvider.d.ts +1 -1
- package/lib/cjs/providers/storage/util.js +4 -3
- package/lib/cjs/templates/index.d.ts +14 -14
- package/lib/cjs/utils/calendarUtils.js +3 -3
- package/lib/cjs/utils/formUtils.d.ts +3 -3
- package/lib/cjs/utils/formUtils.js +2 -2
- package/lib/cjs/utils/utils.d.ts +14 -14
- package/lib/cjs/utils/utils.js +71 -70
- package/lib/mjs/Element.d.ts +1 -1
- package/lib/mjs/Embed.d.ts +2 -2
- package/lib/mjs/Form.d.ts +3 -3
- package/lib/mjs/FormBuilder.d.ts +3 -42
- package/lib/mjs/Formio.js +1 -0
- package/lib/mjs/PDF.d.ts +1 -1
- package/lib/mjs/Webform.d.ts +3 -4
- package/lib/mjs/WebformBuilder.d.ts +1 -1
- package/lib/mjs/components/_classes/component/Component.form.d.ts +1 -1
- package/lib/mjs/components/_classes/list/ListComponent.form.d.ts +1 -1
- package/lib/mjs/components/_classes/nested/NestedComponent.d.ts +7 -7
- package/lib/mjs/components/_classes/nested/NestedComponent.form.d.ts +1 -1
- package/lib/mjs/components/address/Address.form.d.ts +1 -1
- package/lib/mjs/components/button/Button.form.d.ts +1 -1
- package/lib/mjs/components/checkbox/Checkbox.form.d.ts +1 -1
- package/lib/mjs/components/columns/Columns.form.d.ts +1 -1
- package/lib/mjs/components/container/Container.form.d.ts +1 -1
- package/lib/mjs/components/content/Content.form.d.ts +1 -1
- package/lib/mjs/components/currency/Currency.form.d.ts +1 -1
- package/lib/mjs/components/datagrid/DataGrid.form.d.ts +1 -1
- package/lib/mjs/components/datamap/DataMap.form.d.ts +1 -1
- package/lib/mjs/components/datetime/DateTime.form.d.ts +1 -1
- package/lib/mjs/components/day/Day.form.d.ts +1 -1
- package/lib/mjs/components/editgrid/EditGrid.form.d.ts +1 -1
- package/lib/mjs/components/email/Email.form.d.ts +1 -1
- package/lib/mjs/components/fieldset/Fieldset.form.d.ts +1 -1
- package/lib/mjs/components/file/File.form.d.ts +1 -1
- package/lib/mjs/components/form/Form.form.d.ts +1 -1
- package/lib/mjs/components/hidden/Hidden.form.d.ts +1 -1
- package/lib/mjs/components/html/HTML.form.d.ts +1 -1
- package/lib/mjs/components/number/Number.form.d.ts +1 -1
- package/lib/mjs/components/panel/Panel.form.d.ts +1 -1
- package/lib/mjs/components/password/Password.form.d.ts +1 -1
- package/lib/mjs/components/phonenumber/PhoneNumber.form.d.ts +1 -1
- package/lib/mjs/components/radio/Radio.form.d.ts +1 -1
- package/lib/mjs/components/recaptcha/ReCaptcha.form.d.ts +1 -1
- package/lib/mjs/components/select/Select.form.d.ts +1 -1
- package/lib/mjs/components/selectboxes/SelectBoxes.form.d.ts +1 -1
- package/lib/mjs/components/signature/Signature.form.d.ts +1 -1
- package/lib/mjs/components/survey/Survey.form.d.ts +1 -1
- package/lib/mjs/components/table/Table.form.d.ts +1 -1
- package/lib/mjs/components/tabs/Tabs.form.d.ts +1 -1
- package/lib/mjs/components/tags/Tags.form.d.ts +1 -1
- package/lib/mjs/components/textarea/TextArea.form.d.ts +1 -1
- package/lib/mjs/components/textfield/TextField.form.d.ts +1 -1
- package/lib/mjs/components/time/Time.form.d.ts +1 -1
- package/lib/mjs/components/url/Url.form.d.ts +1 -1
- package/lib/mjs/components/well/Well.form.d.ts +1 -1
- package/lib/mjs/providers/address/AzureAddressProvider.d.ts +1 -1
- package/lib/mjs/templates/index.d.ts +14 -14
- package/lib/mjs/utils/formUtils.d.ts +3 -3
- package/lib/mjs/utils/utils.d.ts +14 -14
- package/package.json +10 -10
package/dist/formio.full.js
CHANGED
@@ -5435,7 +5435,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5435
5435
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5436
5436
|
|
5437
5437
|
"use strict";
|
5438
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5438
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst lodash_1 = __importDefault(__webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\"));\nconst Component_edit_conditional_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.conditional */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.conditional.js\"));\nconst Component_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.data */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.data.js\"));\nconst Component_edit_api_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.api */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.api.js\"));\nconst Component_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.display */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.display.js\"));\nconst Component_edit_logic_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.logic */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.logic.js\"));\nconst Component_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.validation */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.validation.js\"));\nconst Component_edit_layout_1 = __importDefault(__webpack_require__(/*! ./editForm/Component.edit.layout */ \"./lib/cjs/components/_classes/component/editForm/Component.edit.layout.js\"));\nconst utils_1 = __importDefault(__webpack_require__(/*! ./editForm/utils */ \"./lib/cjs/components/_classes/component/editForm/utils.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n const components = lodash_1.default.cloneDeep([\n {\n type: 'tabs',\n key: 'tabs',\n components: [\n {\n label: 'Display',\n key: 'display',\n weight: 0,\n components: Component_edit_display_1.default\n },\n {\n label: 'Data',\n key: 'data',\n weight: 10,\n components: Component_edit_data_1.default\n },\n {\n label: 'Validation',\n key: 'validation',\n weight: 20,\n components: Component_edit_validation_1.default\n },\n {\n label: 'API',\n key: 'api',\n weight: 30,\n components: Component_edit_api_1.default\n },\n {\n label: 'Conditional',\n key: 'conditional',\n weight: 40,\n components: Component_edit_conditional_1.default\n },\n {\n label: 'Logic',\n key: 'logic',\n weight: 50,\n components: Component_edit_logic_1.default\n },\n {\n label: 'Layout',\n key: 'layout',\n weight: 60,\n components: Component_edit_layout_1.default\n },\n ]\n }\n ]).concat(extend.map((items) => ({\n type: 'tabs',\n key: 'tabs',\n components: lodash_1.default.cloneDeep(items),\n })));\n return {\n components: lodash_1.default.unionWith(components, utils_1.default.unifyComponents).concat({\n type: 'hidden',\n key: 'type'\n })\n };\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/_classes/component/Component.form.js?");
|
5439
5439
|
|
5440
5440
|
/***/ }),
|
5441
5441
|
|
@@ -5578,7 +5578,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5578
5578
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5579
5579
|
|
5580
5580
|
"use strict";
|
5581
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5581
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../../Components */ \"./lib/cjs/components/Components.js\"));\nconst ListComponent_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/ListComponent.edit.data */ \"./lib/cjs/components/_classes/list/editForm/ListComponent.edit.data.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'data',\n components: ListComponent_edit_data_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/_classes/list/ListComponent.form.js?");
|
5582
5582
|
|
5583
5583
|
/***/ }),
|
5584
5584
|
|
@@ -5622,7 +5622,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5622
5622
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5623
5623
|
|
5624
5624
|
"use strict";
|
5625
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5625
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../../Components */ \"./lib/cjs/components/Components.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'data',\n ignore: true\n },\n {\n key: 'validation',\n ignore: true\n }\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/_classes/nested/NestedComponent.form.js?");
|
5626
5626
|
|
5627
5627
|
/***/ }),
|
5628
5628
|
|
@@ -5666,7 +5666,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5666
5666
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5667
5667
|
|
5668
5668
|
"use strict";
|
5669
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5669
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Address_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Address.edit.data */ \"./lib/cjs/components/address/editForm/Address.edit.data.js\"));\nconst Address_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Address.edit.display */ \"./lib/cjs/components/address/editForm/Address.edit.display.js\"));\nconst Address_edit_provider_1 = __importDefault(__webpack_require__(/*! ./editForm/Address.edit.provider */ \"./lib/cjs/components/address/editForm/Address.edit.provider.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'data',\n components: Address_edit_data_1.default,\n },\n {\n key: 'display',\n components: Address_edit_display_1.default,\n },\n {\n label: 'Provider',\n key: 'provider',\n weight: 15,\n components: Address_edit_provider_1.default,\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/address/Address.form.js?");
|
5670
5670
|
|
5671
5671
|
/***/ }),
|
5672
5672
|
|
@@ -5743,7 +5743,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5743
5743
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5744
5744
|
|
5745
5745
|
"use strict";
|
5746
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5746
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Button_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Button.edit.display */ \"./lib/cjs/components/button/editForm/Button.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Button_edit_display_1.default\n },\n {\n key: 'data',\n ignore: true,\n },\n {\n key: 'validation',\n ignore: true,\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/button/Button.form.js?");
|
5747
5747
|
|
5748
5748
|
/***/ }),
|
5749
5749
|
|
@@ -5776,7 +5776,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5776
5776
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5777
5777
|
|
5778
5778
|
"use strict";
|
5779
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5779
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Checkbox_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Checkbox.edit.data */ \"./lib/cjs/components/checkbox/editForm/Checkbox.edit.data.js\"));\nconst Checkbox_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Checkbox.edit.display */ \"./lib/cjs/components/checkbox/editForm/Checkbox.edit.display.js\"));\nconst Checkbox_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Checkbox.edit.validation */ \"./lib/cjs/components/checkbox/editForm/Checkbox.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'data',\n components: Checkbox_edit_data_1.default\n },\n {\n key: 'display',\n components: Checkbox_edit_display_1.default\n },\n {\n key: 'validation',\n components: Checkbox_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/checkbox/Checkbox.form.js?");
|
5780
5780
|
|
5781
5781
|
/***/ }),
|
5782
5782
|
|
@@ -5831,7 +5831,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
5831
5831
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5832
5832
|
|
5833
5833
|
"use strict";
|
5834
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5834
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Columns_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Columns.edit.display */ \"./lib/cjs/components/columns/editForm/Columns.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Columns_edit_display_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/columns/Columns.form.js?");
|
5835
5835
|
|
5836
5836
|
/***/ }),
|
5837
5837
|
|
@@ -5864,7 +5864,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
5864
5864
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5865
5865
|
|
5866
5866
|
"use strict";
|
5867
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5867
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Container_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Container.edit.display */ \"./lib/cjs/components/container/editForm/Container.edit.display.js\"));\nconst Container_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Container.edit.data */ \"./lib/cjs/components/container/editForm/Container.edit.data.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Container_edit_display_1.default\n },\n {\n key: 'data',\n components: Container_edit_data_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/container/Container.form.js?");
|
5868
5868
|
|
5869
5869
|
/***/ }),
|
5870
5870
|
|
@@ -5908,7 +5908,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
5908
5908
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5909
5909
|
|
5910
5910
|
"use strict";
|
5911
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5911
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Content_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Content.edit.display */ \"./lib/cjs/components/content/editForm/Content.edit.display.js\"));\nconst Content_edit_logic_1 = __importDefault(__webpack_require__(/*! ./editForm/Content.edit.logic */ \"./lib/cjs/components/content/editForm/Content.edit.logic.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n const editForm = Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Content_edit_display_1.default,\n },\n {\n key: 'data',\n ignore: true,\n },\n {\n key: 'validation',\n ignore: true,\n },\n {\n key: 'logic',\n components: Content_edit_logic_1.default,\n },\n ], ...extend);\n // Add content as full width above the settings.\n editForm.components = [{\n weight: 0,\n type: 'textarea',\n editor: 'ckeditor',\n label: 'Content',\n hideLabel: true,\n input: true,\n key: 'html',\n as: 'html',\n rows: 3,\n tooltip: 'The HTML template for the result data items.',\n }].concat(editForm.components);\n return editForm;\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/content/Content.form.js?");
|
5912
5912
|
|
5913
5913
|
/***/ }),
|
5914
5914
|
|
@@ -5952,7 +5952,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
5952
5952
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5953
5953
|
|
5954
5954
|
"use strict";
|
5955
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5955
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst Currency_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Currency.edit.display */ \"./lib/cjs/components/currency/editForm/Currency.edit.display.js\"));\nconst Currency_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Currency.edit.data */ \"./lib/cjs/components/currency/editForm/Currency.edit.data.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'display',\n components: Currency_edit_display_1.default\n },\n {\n key: 'data',\n components: Currency_edit_data_1.default\n },\n {\n key: 'validation',\n components: [\n {\n key: 'validate.minLength',\n ignore: true,\n },\n {\n key: 'validate.maxLength',\n ignore: true,\n },\n {\n key: 'validate.minWords',\n ignore: true,\n },\n {\n key: 'validate.maxWords',\n ignore: true,\n },\n {\n key: 'validate.pattern',\n ignore: true,\n },\n ]\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/currency/Currency.form.js?");
|
5956
5956
|
|
5957
5957
|
/***/ }),
|
5958
5958
|
|
@@ -5996,7 +5996,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
5996
5996
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
5997
5997
|
|
5998
5998
|
"use strict";
|
5999
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
5999
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst DataGrid_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/DataGrid.edit.data */ \"./lib/cjs/components/datagrid/editForm/DataGrid.edit.data.js\"));\nconst DataGrid_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/DataGrid.edit.display */ \"./lib/cjs/components/datagrid/editForm/DataGrid.edit.display.js\"));\nconst DataGrid_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/DataGrid.edit.validation */ \"./lib/cjs/components/datagrid/editForm/DataGrid.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: DataGrid_edit_display_1.default\n },\n {\n key: 'data',\n components: DataGrid_edit_data_1.default\n },\n {\n key: 'validation',\n components: DataGrid_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/datagrid/DataGrid.form.js?");
|
6000
6000
|
|
6001
6001
|
/***/ }),
|
6002
6002
|
|
@@ -6051,7 +6051,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6051
6051
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6052
6052
|
|
6053
6053
|
"use strict";
|
6054
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6054
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst DataMap_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/DataMap.edit.data */ \"./lib/cjs/components/datamap/editForm/DataMap.edit.data.js\"));\nconst DataMap_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/DataMap.edit.display */ \"./lib/cjs/components/datamap/editForm/DataMap.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: DataMap_edit_display_1.default\n },\n {\n key: 'data',\n components: DataMap_edit_data_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/datamap/DataMap.form.js?");
|
6055
6055
|
|
6056
6056
|
/***/ }),
|
6057
6057
|
|
@@ -6095,7 +6095,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6095
6095
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6096
6096
|
|
6097
6097
|
"use strict";
|
6098
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6098
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst DateTime_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/DateTime.edit.data */ \"./lib/cjs/components/datetime/editForm/DateTime.edit.data.js\"));\nconst DateTime_edit_date_1 = __importDefault(__webpack_require__(/*! ./editForm/DateTime.edit.date */ \"./lib/cjs/components/datetime/editForm/DateTime.edit.date.js\"));\nconst DateTime_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/DateTime.edit.display */ \"./lib/cjs/components/datetime/editForm/DateTime.edit.display.js\"));\nconst DateTime_edit_time_1 = __importDefault(__webpack_require__(/*! ./editForm/DateTime.edit.time */ \"./lib/cjs/components/datetime/editForm/DateTime.edit.time.js\"));\nconst DateTime_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/DateTime.edit.validation */ \"./lib/cjs/components/datetime/editForm/DateTime.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: DateTime_edit_display_1.default\n },\n {\n label: 'Date',\n key: 'date',\n weight: 1,\n components: DateTime_edit_date_1.default\n },\n {\n label: 'Time',\n key: 'time',\n weight: 2,\n components: DateTime_edit_time_1.default\n },\n {\n key: 'data',\n components: DateTime_edit_data_1.default\n },\n {\n key: 'validation',\n components: DateTime_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/datetime/DateTime.form.js?");
|
6099
6099
|
|
6100
6100
|
/***/ }),
|
6101
6101
|
|
@@ -6172,7 +6172,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6172
6172
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6173
6173
|
|
6174
6174
|
"use strict";
|
6175
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6175
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Day_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Day.edit.data */ \"./lib/cjs/components/day/editForm/Day.edit.data.js\"));\nconst Day_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Day.edit.display */ \"./lib/cjs/components/day/editForm/Day.edit.display.js\"));\nconst Day_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Day.edit.validation */ \"./lib/cjs/components/day/editForm/Day.edit.validation.js\"));\nconst Day_edit_day_1 = __importDefault(__webpack_require__(/*! ./editForm/Day.edit.day */ \"./lib/cjs/components/day/editForm/Day.edit.day.js\"));\nconst Day_edit_month_1 = __importDefault(__webpack_require__(/*! ./editForm/Day.edit.month */ \"./lib/cjs/components/day/editForm/Day.edit.month.js\"));\nconst Day_edit_year_1 = __importDefault(__webpack_require__(/*! ./editForm/Day.edit.year */ \"./lib/cjs/components/day/editForm/Day.edit.year.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Day_edit_display_1.default\n },\n {\n key: 'data',\n components: Day_edit_data_1.default,\n },\n {\n key: 'validation',\n components: Day_edit_validation_1.default\n },\n {\n key: 'day',\n label: 'Day',\n weight: 3,\n components: Day_edit_day_1.default\n },\n {\n key: 'month',\n label: 'Month',\n weight: 3,\n components: Day_edit_month_1.default\n },\n {\n key: 'year',\n label: 'Year',\n weight: 3,\n components: Day_edit_year_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/day/Day.form.js?");
|
6176
6176
|
|
6177
6177
|
/***/ }),
|
6178
6178
|
|
@@ -6260,7 +6260,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6260
6260
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6261
6261
|
|
6262
6262
|
"use strict";
|
6263
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6263
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst EditGrid_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/EditGrid.edit.data */ \"./lib/cjs/components/editgrid/editForm/EditGrid.edit.data.js\"));\nconst EditGrid_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/EditGrid.edit.display */ \"./lib/cjs/components/editgrid/editForm/EditGrid.edit.display.js\"));\nconst EditGrid_edit_templates_1 = __importDefault(__webpack_require__(/*! ./editForm/EditGrid.edit.templates */ \"./lib/cjs/components/editgrid/editForm/EditGrid.edit.templates.js\"));\nconst EditGrid_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/EditGrid.edit.validation */ \"./lib/cjs/components/editgrid/editForm/EditGrid.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n label: 'Templates',\n key: 'templates',\n weight: 5,\n components: EditGrid_edit_templates_1.default\n },\n {\n key: 'display',\n components: EditGrid_edit_display_1.default,\n },\n {\n key: 'data',\n components: EditGrid_edit_data_1.default,\n },\n {\n key: 'validation',\n components: EditGrid_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/editgrid/EditGrid.form.js?");
|
6264
6264
|
|
6265
6265
|
/***/ }),
|
6266
6266
|
|
@@ -6326,7 +6326,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6326
6326
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6327
6327
|
|
6328
6328
|
"use strict";
|
6329
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6329
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst Email_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Email.edit.display */ \"./lib/cjs/components/email/editForm/Email.edit.display.js\"));\nconst Email_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Email.edit.validation */ \"./lib/cjs/components/email/editForm/Email.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'display',\n components: Email_edit_display_1.default,\n },\n {\n key: 'validation',\n components: Email_edit_validation_1.default,\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/email/Email.form.js?");
|
6330
6330
|
|
6331
6331
|
/***/ }),
|
6332
6332
|
|
@@ -6370,7 +6370,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6370
6370
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6371
6371
|
|
6372
6372
|
"use strict";
|
6373
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6373
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Fieldset_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Fieldset.edit.display */ \"./lib/cjs/components/fieldset/editForm/Fieldset.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Fieldset_edit_display_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/fieldset/Fieldset.form.js?");
|
6374
6374
|
|
6375
6375
|
/***/ }),
|
6376
6376
|
|
@@ -6403,7 +6403,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6403
6403
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6404
6404
|
|
6405
6405
|
"use strict";
|
6406
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6406
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst File_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/File.edit.data */ \"./lib/cjs/components/file/editForm/File.edit.data.js\"));\nconst File_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/File.edit.display */ \"./lib/cjs/components/file/editForm/File.edit.display.js\"));\nconst File_edit_file_1 = __importDefault(__webpack_require__(/*! ./editForm/File.edit.file */ \"./lib/cjs/components/file/editForm/File.edit.file.js\"));\nconst File_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/File.edit.validation */ \"./lib/cjs/components/file/editForm/File.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: File_edit_display_1.default\n },\n {\n key: 'data',\n components: File_edit_data_1.default\n },\n {\n label: 'File',\n key: 'file',\n weight: 5,\n components: File_edit_file_1.default\n },\n {\n key: 'validation',\n components: File_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/file/File.form.js?");
|
6407
6407
|
|
6408
6408
|
/***/ }),
|
6409
6409
|
|
@@ -6469,7 +6469,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6469
6469
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6470
6470
|
|
6471
6471
|
"use strict";
|
6472
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6472
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Form_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Form.edit.display */ \"./lib/cjs/components/form/editForm/Form.edit.display.js\"));\nconst Form_edit_form_1 = __importDefault(__webpack_require__(/*! ./editForm/Form.edit.form */ \"./lib/cjs/components/form/editForm/Form.edit.form.js\"));\nconst Form_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Form.edit.data */ \"./lib/cjs/components/form/editForm/Form.edit.data.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Form_edit_display_1.default\n },\n {\n label: 'Form',\n key: 'form',\n weight: 10,\n components: Form_edit_form_1.default\n },\n {\n label: 'Data',\n key: 'data',\n weight: 10,\n components: Form_edit_data_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/form/Form.form.js?");
|
6473
6473
|
|
6474
6474
|
/***/ }),
|
6475
6475
|
|
@@ -6524,7 +6524,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6524
6524
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6525
6525
|
|
6526
6526
|
"use strict";
|
6527
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6527
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Hidden_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Hidden.edit.display */ \"./lib/cjs/components/hidden/editForm/Hidden.edit.display.js\"));\nconst Hidden_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Hidden.edit.data */ \"./lib/cjs/components/hidden/editForm/Hidden.edit.data.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Hidden_edit_display_1.default\n },\n {\n key: 'data',\n components: Hidden_edit_data_1.default\n },\n {\n key: 'validation',\n ignore: true\n },\n {\n key: 'conditional',\n ignore: true\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/hidden/Hidden.form.js?");
|
6528
6528
|
|
6529
6529
|
/***/ }),
|
6530
6530
|
|
@@ -6568,7 +6568,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6568
6568
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6569
6569
|
|
6570
6570
|
"use strict";
|
6571
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6571
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst HTML_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/HTML.edit.display */ \"./lib/cjs/components/html/editForm/HTML.edit.display.js\"));\nconst HTML_edit_logic_1 = __importDefault(__webpack_require__(/*! ./editForm/HTML.edit.logic */ \"./lib/cjs/components/html/editForm/HTML.edit.logic.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: HTML_edit_display_1.default,\n },\n {\n key: 'data',\n ignore: true,\n },\n {\n key: 'validation',\n ignore: true,\n },\n {\n key: 'logic',\n components: HTML_edit_logic_1.default,\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/html/HTML.form.js?");
|
6572
6572
|
|
6573
6573
|
/***/ }),
|
6574
6574
|
|
@@ -6623,7 +6623,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
6623
6623
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6624
6624
|
|
6625
6625
|
"use strict";
|
6626
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6626
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst Number_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Number.edit.display */ \"./lib/cjs/components/number/editForm/Number.edit.display.js\"));\nconst Number_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Number.edit.data */ \"./lib/cjs/components/number/editForm/Number.edit.data.js\"));\nconst Number_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Number.edit.validation */ \"./lib/cjs/components/number/editForm/Number.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'display',\n components: Number_edit_display_1.default\n },\n {\n key: 'data',\n components: Number_edit_data_1.default\n },\n {\n key: 'validation',\n components: Number_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/number/Number.form.js?");
|
6627
6627
|
|
6628
6628
|
/***/ }),
|
6629
6629
|
|
@@ -6678,7 +6678,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6678
6678
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6679
6679
|
|
6680
6680
|
"use strict";
|
6681
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6681
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Panel_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Panel.edit.display */ \"./lib/cjs/components/panel/editForm/Panel.edit.display.js\"));\nconst Panel_edit_conditional_1 = __importDefault(__webpack_require__(/*! ./editForm/Panel.edit.conditional */ \"./lib/cjs/components/panel/editForm/Panel.edit.conditional.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Panel_edit_display_1.default\n },\n {\n key: 'conditional',\n components: Panel_edit_conditional_1.default,\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/panel/Panel.form.js?");
|
6682
6682
|
|
6683
6683
|
/***/ }),
|
6684
6684
|
|
@@ -6722,7 +6722,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
6722
6722
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6723
6723
|
|
6724
6724
|
"use strict";
|
6725
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6725
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst Password_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Password.edit.display */ \"./lib/cjs/components/password/editForm/Password.edit.display.js\"));\nconst Password_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Password.edit.data */ \"./lib/cjs/components/password/editForm/Password.edit.data.js\"));\nconst Password_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Password.edit.validation */ \"./lib/cjs/components/password/editForm/Password.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'data',\n components: Password_edit_data_1.default\n },\n {\n key: 'display',\n components: Password_edit_display_1.default\n },\n {\n key: 'validation',\n components: Password_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/password/Password.form.js?");
|
6726
6726
|
|
6727
6727
|
/***/ }),
|
6728
6728
|
|
@@ -6777,7 +6777,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6777
6777
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6778
6778
|
|
6779
6779
|
"use strict";
|
6780
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6780
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst PhoneNumber_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/PhoneNumber.edit.validation */ \"./lib/cjs/components/phonenumber/editForm/PhoneNumber.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'display',\n components: [\n {\n key: 'showWordCount',\n ignore: true\n },\n {\n key: 'showCharCount',\n ignore: true\n }\n ]\n },\n {\n key: 'data',\n components: [\n {\n key: 'case',\n ignore: true\n }\n ]\n },\n {\n key: 'validation',\n components: PhoneNumber_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/phonenumber/PhoneNumber.form.js?");
|
6781
6781
|
|
6782
6782
|
/***/ }),
|
6783
6783
|
|
@@ -6810,7 +6810,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6810
6810
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6811
6811
|
|
6812
6812
|
"use strict";
|
6813
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6813
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst ListComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/list/ListComponent.form */ \"./lib/cjs/components/_classes/list/ListComponent.form.js\"));\nconst Radio_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Radio.edit.data */ \"./lib/cjs/components/radio/editForm/Radio.edit.data.js\"));\nconst Radio_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Radio.edit.display */ \"./lib/cjs/components/radio/editForm/Radio.edit.display.js\"));\nconst Radio_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Radio.edit.validation */ \"./lib/cjs/components/radio/editForm/Radio.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, ListComponent_form_1.default)([\n {\n key: 'display',\n components: Radio_edit_display_1.default\n },\n {\n key: 'data',\n components: Radio_edit_data_1.default\n },\n {\n key: 'validation',\n components: Radio_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/radio/Radio.form.js?");
|
6814
6814
|
|
6815
6815
|
/***/ }),
|
6816
6816
|
|
@@ -6865,7 +6865,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6865
6865
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6866
6866
|
|
6867
6867
|
"use strict";
|
6868
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6868
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst ReCaptcha_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/ReCaptcha.edit.display */ \"./lib/cjs/components/recaptcha/editForm/ReCaptcha.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: ReCaptcha_edit_display_1.default\n },\n {\n key: 'data',\n ignore: true\n },\n {\n key: 'validation',\n ignore: true\n },\n {\n key: 'conditional',\n ignore: true\n },\n {\n key: 'logic',\n ignore: true\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/recaptcha/ReCaptcha.form.js?");
|
6869
6869
|
|
6870
6870
|
/***/ }),
|
6871
6871
|
|
@@ -6898,7 +6898,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\ncons
|
|
6898
6898
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6899
6899
|
|
6900
6900
|
"use strict";
|
6901
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6901
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst ListComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/list/ListComponent.form */ \"./lib/cjs/components/_classes/list/ListComponent.form.js\"));\nconst Select_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Select.edit.data */ \"./lib/cjs/components/select/editForm/Select.edit.data.js\"));\nconst Select_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Select.edit.display */ \"./lib/cjs/components/select/editForm/Select.edit.display.js\"));\nconst Select_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Select.edit.validation */ \"./lib/cjs/components/select/editForm/Select.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, ListComponent_form_1.default)([\n {\n key: 'display',\n components: Select_edit_display_1.default\n },\n {\n key: 'data',\n components: Select_edit_data_1.default\n },\n {\n key: 'validation',\n components: Select_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/select/Select.form.js?");
|
6902
6902
|
|
6903
6903
|
/***/ }),
|
6904
6904
|
|
@@ -6953,7 +6953,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6953
6953
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6954
6954
|
|
6955
6955
|
"use strict";
|
6956
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6956
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Radio_form_1 = __importDefault(__webpack_require__(/*! ../radio/Radio.form */ \"./lib/cjs/components/radio/Radio.form.js\"));\nconst SelectBoxes_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/SelectBoxes.edit.validation */ \"./lib/cjs/components/selectboxes/editForm/SelectBoxes.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, Radio_form_1.default)([\n {\n key: 'data',\n components: [\n {\n key: 'dataType',\n ignore: true,\n }\n ]\n },\n {\n key: 'validation',\n components: SelectBoxes_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/selectboxes/SelectBoxes.form.js?");
|
6957
6957
|
|
6958
6958
|
/***/ }),
|
6959
6959
|
|
@@ -6986,7 +6986,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
6986
6986
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
6987
6987
|
|
6988
6988
|
"use strict";
|
6989
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
6989
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Signature_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Signature.edit.data */ \"./lib/cjs/components/signature/editForm/Signature.edit.data.js\"));\nconst Signature_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Signature.edit.display */ \"./lib/cjs/components/signature/editForm/Signature.edit.display.js\"));\nconst Signature_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Signature.edit.validation */ \"./lib/cjs/components/signature/editForm/Signature.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Signature_edit_display_1.default\n },\n {\n key: 'data',\n components: Signature_edit_data_1.default\n },\n {\n key: 'validation',\n components: Signature_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/signature/Signature.form.js?");
|
6990
6990
|
|
6991
6991
|
/***/ }),
|
6992
6992
|
|
@@ -7041,7 +7041,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7041
7041
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7042
7042
|
|
7043
7043
|
"use strict";
|
7044
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7044
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Survey_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Survey.edit.data */ \"./lib/cjs/components/survey/editForm/Survey.edit.data.js\"));\nconst Survey_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Survey.edit.display */ \"./lib/cjs/components/survey/editForm/Survey.edit.display.js\"));\nconst Survey_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Survey.edit.validation */ \"./lib/cjs/components/survey/editForm/Survey.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: Survey_edit_display_1.default\n },\n {\n key: 'data',\n components: Survey_edit_data_1.default\n },\n {\n key: 'validation',\n components: Survey_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/survey/Survey.form.js?");
|
7045
7045
|
|
7046
7046
|
/***/ }),
|
7047
7047
|
|
@@ -7096,7 +7096,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7096
7096
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7097
7097
|
|
7098
7098
|
"use strict";
|
7099
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7099
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Table_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Table.edit.display */ \"./lib/cjs/components/table/editForm/Table.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Table_edit_display_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/table/Table.form.js?");
|
7100
7100
|
|
7101
7101
|
/***/ }),
|
7102
7102
|
|
@@ -7129,7 +7129,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7129
7129
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7130
7130
|
|
7131
7131
|
"use strict";
|
7132
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7132
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Tabs_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Tabs.edit.display */ \"./lib/cjs/components/tabs/editForm/Tabs.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Tabs_edit_display_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/tabs/Tabs.form.js?");
|
7133
7133
|
|
7134
7134
|
/***/ }),
|
7135
7135
|
|
@@ -7162,7 +7162,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7162
7162
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7163
7163
|
|
7164
7164
|
"use strict";
|
7165
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7165
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst Tags_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Tags.edit.data */ \"./lib/cjs/components/tags/editForm/Tags.edit.data.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'data',\n components: Tags_edit_data_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/tags/Tags.form.js?");
|
7166
7166
|
|
7167
7167
|
/***/ }),
|
7168
7168
|
|
@@ -7195,7 +7195,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7195
7195
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7196
7196
|
|
7197
7197
|
"use strict";
|
7198
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7198
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst TextArea_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/TextArea.edit.display */ \"./lib/cjs/components/textarea/editForm/TextArea.edit.display.js\"));\nconst TextArea_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/TextArea.edit.validation */ \"./lib/cjs/components/textarea/editForm/TextArea.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'display',\n components: TextArea_edit_display_1.default\n },\n {\n key: 'validation',\n components: TextArea_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/textarea/TextArea.form.js?");
|
7199
7199
|
|
7200
7200
|
/***/ }),
|
7201
7201
|
|
@@ -7239,7 +7239,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7239
7239
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7240
7240
|
|
7241
7241
|
"use strict";
|
7242
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7242
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Components_1 = __importDefault(__webpack_require__(/*! ../Components */ \"./lib/cjs/components/Components.js\"));\nconst TextField_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/TextField.edit.data */ \"./lib/cjs/components/textfield/editForm/TextField.edit.data.js\"));\nconst TextField_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/TextField.edit.display */ \"./lib/cjs/components/textfield/editForm/TextField.edit.display.js\"));\nconst TextField_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/TextField.edit.validation */ \"./lib/cjs/components/textfield/editForm/TextField.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return Components_1.default.baseEditForm([\n {\n key: 'display',\n components: TextField_edit_display_1.default\n },\n {\n key: 'data',\n components: TextField_edit_data_1.default\n },\n {\n key: 'validation',\n components: TextField_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/textfield/TextField.form.js?");
|
7243
7243
|
|
7244
7244
|
/***/ }),
|
7245
7245
|
|
@@ -7294,7 +7294,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7294
7294
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7295
7295
|
|
7296
7296
|
"use strict";
|
7297
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7297
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Component_form_1 = __importDefault(__webpack_require__(/*! ../_classes/component/Component.form */ \"./lib/cjs/components/_classes/component/Component.form.js\"));\nconst Time_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Time.edit.data */ \"./lib/cjs/components/time/editForm/Time.edit.data.js\"));\nconst Time_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Time.edit.display */ \"./lib/cjs/components/time/editForm/Time.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, Component_form_1.default)([\n {\n key: 'data',\n components: Time_edit_data_1.default,\n },\n {\n key: 'display',\n components: Time_edit_display_1.default,\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/time/Time.form.js?");
|
7298
7298
|
|
7299
7299
|
/***/ }),
|
7300
7300
|
|
@@ -7338,7 +7338,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7338
7338
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7339
7339
|
|
7340
7340
|
"use strict";
|
7341
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7341
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst Unknown_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Unknown.edit.display */ \"./lib/cjs/components/unknown/editForm/Unknown.edit.display.js\"));\n/**\n * Unknown Component schema.\n * @returns {object} - The Unknown Component edit form.\n */\nfunction default_1() {\n return {\n components: [\n {\n type: 'tabs',\n key: 'tabs',\n components: [\n {\n label: 'Custom',\n key: 'display',\n weight: 0,\n components: Unknown_edit_display_1.default\n }\n ]\n }\n ]\n };\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/unknown/Unknown.form.js?");
|
7342
7342
|
|
7343
7343
|
/***/ }),
|
7344
7344
|
|
@@ -7371,7 +7371,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7371
7371
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7372
7372
|
|
7373
7373
|
"use strict";
|
7374
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7374
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst TextField_form_1 = __importDefault(__webpack_require__(/*! ../textfield/TextField.form */ \"./lib/cjs/components/textfield/TextField.form.js\"));\nconst Url_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Url.edit.display */ \"./lib/cjs/components/url/editForm/Url.edit.display.js\"));\nconst Url_edit_data_1 = __importDefault(__webpack_require__(/*! ./editForm/Url.edit.data */ \"./lib/cjs/components/url/editForm/Url.edit.data.js\"));\nconst Url_edit_validation_1 = __importDefault(__webpack_require__(/*! ./editForm/Url.edit.validation */ \"./lib/cjs/components/url/editForm/Url.edit.validation.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, TextField_form_1.default)([\n {\n key: 'display',\n components: Url_edit_display_1.default\n },\n {\n key: 'data',\n components: Url_edit_data_1.default\n },\n {\n key: 'validation',\n components: Url_edit_validation_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/url/Url.form.js?");
|
7375
7375
|
|
7376
7376
|
/***/ }),
|
7377
7377
|
|
@@ -7426,7 +7426,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
7426
7426
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7427
7427
|
|
7428
7428
|
"use strict";
|
7429
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\
|
7429
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nconst NestedComponent_form_1 = __importDefault(__webpack_require__(/*! ../_classes/nested/NestedComponent.form */ \"./lib/cjs/components/_classes/nested/NestedComponent.form.js\"));\nconst Well_edit_display_1 = __importDefault(__webpack_require__(/*! ./editForm/Well.edit.display */ \"./lib/cjs/components/well/editForm/Well.edit.display.js\"));\n/**\n * The Edit Form function.\n * @param {...any} extend - The components that extend the edit form.\n * @returns {import('@formio/core').Component[]} - The edit form components.\n */\nfunction default_1(...extend) {\n return (0, NestedComponent_form_1.default)([\n {\n key: 'display',\n components: Well_edit_display_1.default\n },\n ], ...extend);\n}\nexports[\"default\"] = default_1;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/components/well/Well.form.js?");
|
7430
7430
|
|
7431
7431
|
/***/ }),
|
7432
7432
|
|
@@ -7481,7 +7481,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7481
7481
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
7482
7482
|
|
7483
7483
|
"use strict";
|
7484
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.Webform = exports.EventEmitter = exports.Licenses = exports.Formio = exports.Form = exports.Utils = exports.Templates = exports.Widgets = exports.Providers = exports.Displays = exports.Components = exports.FormioCore =
|
7484
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.Webform = exports.EventEmitter = exports.Licenses = exports.Formio = exports.Form = exports.Utils = exports.Templates = exports.Widgets = exports.Providers = exports.Displays = exports.Components = exports.FormioCore = exports.useModule = exports.registerModule = void 0;\nconst lodash_1 = __importDefault(__webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\"));\nconst Formio_1 = __webpack_require__(/*! ./Formio */ \"./lib/cjs/Formio.js\");\nObject.defineProperty(exports, \"Formio\", ({ enumerable: true, get: function () { return Formio_1.Formio; } }));\nconst components_1 = __importDefault(__webpack_require__(/*! ./components */ \"./lib/cjs/components/index.js\"));\nconst Components_1 = __importDefault(__webpack_require__(/*! ./components/Components */ \"./lib/cjs/components/Components.js\"));\nexports.Components = Components_1.default;\nconst Displays_1 = __importDefault(__webpack_require__(/*! ./displays/Displays */ \"./lib/cjs/displays/Displays.js\"));\nexports.Displays = Displays_1.default;\nconst Templates_1 = __importDefault(__webpack_require__(/*! ./templates/Templates */ \"./lib/cjs/templates/Templates.js\"));\nexports.Templates = Templates_1.default;\nconst providers_1 = __importDefault(__webpack_require__(/*! ./providers */ \"./lib/cjs/providers/index.js\"));\nexports.Providers = providers_1.default;\nconst widgets_1 = __importDefault(__webpack_require__(/*! ./widgets */ \"./lib/cjs/widgets/index.js\"));\nexports.Widgets = widgets_1.default;\nconst Form_1 = __importDefault(__webpack_require__(/*! ./Form */ \"./lib/cjs/Form.js\"));\nexports.Form = Form_1.default;\nconst utils_1 = __importDefault(__webpack_require__(/*! ./utils */ \"./lib/cjs/utils/index.js\"));\nexports.Utils = utils_1.default;\nconst Evaluator_1 = __webpack_require__(/*! ./utils/Evaluator */ \"./lib/cjs/utils/Evaluator.js\");\nconst licenses_1 = __importDefault(__webpack_require__(/*! ./licenses */ \"./lib/cjs/licenses/index.js\"));\nexports.Licenses = licenses_1.default;\nconst EventEmitter_1 = __importDefault(__webpack_require__(/*! ./EventEmitter */ \"./lib/cjs/EventEmitter.js\"));\nexports.EventEmitter = EventEmitter_1.default;\nconst Webform_1 = __importDefault(__webpack_require__(/*! ./Webform */ \"./lib/cjs/Webform.js\"));\nexports.Webform = Webform_1.default;\nFormio_1.Formio.loadModules = (path = `${Formio_1.Formio.getApiUrl()}/externalModules.js`, name = 'externalModules') => {\n Formio_1.Formio.requireLibrary(name, name, path, true)\n .then((modules) => {\n Formio_1.Formio.use(modules);\n });\n};\n// This is needed to maintain correct imports using the \"dist\" file.\nFormio_1.Formio.isRenderer = true;\nFormio_1.Formio.Components = Components_1.default;\nFormio_1.Formio.Templates = Templates_1.default;\nFormio_1.Formio.Utils = utils_1.default;\nFormio_1.Formio.Form = Form_1.default;\nFormio_1.Formio.Displays = Displays_1.default;\nFormio_1.Formio.Providers = providers_1.default;\nFormio_1.Formio.Widgets = widgets_1.default;\nFormio_1.Formio.Evaluator = Evaluator_1.Evaluator;\nFormio_1.Formio.AllComponents = components_1.default;\nFormio_1.Formio.Licenses = licenses_1.default;\n// This is strange, but is needed for \"premium\" components to import correctly.\nFormio_1.Formio.Formio = Formio_1.Formio;\nFormio_1.Formio.Components.setComponents(components_1.default);\n/**\n * Register a module\n * @param {any} mod - The module object to register. This can also be a function which accepts Formio as an argument.\n * @param {Function|null} [defaultFn] - The default function to call if the module does not have a known key.\n * @param {any} options - Options for the module.\n * @returns {void}\n */\nfunction registerModule(mod, defaultFn = null, options = {}) {\n if (typeof mod === 'function') {\n return registerModule(mod(Formio_1.Formio), defaultFn, options);\n }\n if (typeof mod !== 'object') {\n return;\n }\n for (const key of Object.keys(mod)) {\n const current = mod.framework || Formio_1.Formio.Templates.framework || 'bootstrap';\n switch (key) {\n case 'options':\n Formio_1.Formio.options = lodash_1.default.merge(Formio_1.Formio.options, mod.options);\n break;\n case 'templates':\n for (const framework of Object.keys(mod.templates)) {\n Formio_1.Formio.Templates.extendTemplate(framework, mod.templates[framework]);\n }\n if (mod.templates[current]) {\n Formio_1.Formio.Templates.current = mod.templates[current];\n }\n break;\n case 'components':\n Formio_1.Formio.Components.setComponents(mod.components);\n break;\n case 'framework':\n Formio_1.Formio.Templates.framework = mod.framework;\n break;\n case 'fetch':\n for (const name of Object.keys(mod.fetch)) {\n Formio_1.Formio.registerPlugin(mod.fetch[name], name);\n }\n break;\n case 'providers':\n for (const type of Object.keys(mod.providers)) {\n Formio_1.Formio.Providers.addProviders(type, mod.providers[type]);\n }\n break;\n case 'displays':\n Formio_1.Formio.Displays.addDisplays(mod.displays);\n break;\n case 'evaluator':\n Formio_1.Formio.Evaluator.registerEvaluator(mod.evaluator);\n break;\n case 'library':\n options.license\n ? Formio_1.Formio.Licenses.addLicense(mod.library, options.license)\n : Formio_1.Formio.Licenses.removeLicense(mod.library);\n break;\n default:\n if (defaultFn) {\n if (!defaultFn(key, mod)) {\n console.warn('Unknown module option', key);\n }\n break;\n }\n console.log('Unknown module option', key);\n }\n }\n}\nexports.registerModule = registerModule;\n/**\n * @param {Function|null} defaultFn - The default function to call if the module does not have a known key.\n * @returns {void}\n */\nfunction useModule(defaultFn = null) {\n return (plugins, options = {}) => {\n plugins = lodash_1.default.isArray(plugins) ? plugins : [plugins];\n plugins.forEach((plugin) => {\n if (Array.isArray(plugin)) {\n plugin.forEach(p => registerModule(p, defaultFn, options));\n }\n else {\n registerModule(plugin, defaultFn, options);\n }\n });\n };\n}\nexports.useModule = useModule;\n/**\n * Allows passing in plugins as an array of plugins or a single plugin.\n *\n * Formio.plugins(plugin1, options);\n * Formio.plugins([plugin1, plugin2, etc], options);\n */\nFormio_1.Formio.use = useModule();\nvar Formio_2 = __webpack_require__(/*! ./Formio */ \"./lib/cjs/Formio.js\");\nObject.defineProperty(exports, \"FormioCore\", ({ enumerable: true, get: function () { return Formio_2.Formio; } }));\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/formio.form.js?");
|
7485
7485
|
|
7486
7486
|
/***/ }),
|
7487
7487
|
|
@@ -7734,7 +7734,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\n/**\
|
|
7734
7734
|
/***/ (function(__unused_webpack_module, exports) {
|
7735
7735
|
|
7736
7736
|
"use strict";
|
7737
|
-
eval("\n/**\n * @typedef {any[]} Args\n */\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.withRetries =
|
7737
|
+
eval("\n/**\n * @typedef {any[]} Args\n */\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.withRetries = void 0;\n/**\n * Function to be retried\n * @callback RetryFunction\n * @param {...Args} args\n * @returns {Promise<any>}\n */\n/**\n * Executes a function with retries in case of failure.\n * @param {RetryFunction} fn - The function to be executed.\n * @param {Args} args - The arguments to be passed to the function.\n * @param {number} [retries] - The number of retries in case of failure.\n * @param {string} [err] - The error message to be thrown after all retries have failed.\n * @returns {Promise<any>} The result of the function execution.\n * @throws {Error} When all retries have failed.\n */\nfunction withRetries(fn, args, retries = 3, err = null) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!retries) {\n throw new Error(err);\n }\n return fn(...args).catch(() => withRetries(fn, args, retries - 1, err));\n });\n}\nexports.withRetries = withRetries;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/providers/storage/util.js?");
|
7738
7738
|
|
7739
7739
|
/***/ }),
|
7740
7740
|
|
@@ -8042,7 +8042,7 @@ eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {
|
|
8042
8042
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
8043
8043
|
|
8044
8044
|
"use strict";
|
8045
|
-
eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.isComponentDataEmpty = exports.getEmptyValue = exports.findComponent = exports.applyFormChanges = exports.generateFormChange = exports.getStrings = exports.getValue = exports.escapeRegExCharacters = exports.formatAsCurrency = exports.parseFloatExt = exports.hasCondition = exports.removeComponent = exports.searchComponents = exports.getComponent = exports.matchComponent = exports.isLayoutComponent = exports.getComponentActualValue = exports.getComponentData = exports.eachComponentAsync = exports.eachComponent = exports.componentInfo = exports.getContextualRowData = exports.getContextualRowPath = exports.getComponentKey = exports.eachComponentData = exports.eachComponentDataAsync = exports.componentChildPath = exports.componentPath = exports.isComponentNestedDataType = exports.isComponentModelType = exports.getComponentPath = exports.getComponentAbsolutePath = exports.getModelType = exports.MODEL_TYPES = exports.uniqueName = exports.guid = exports.flattenComponents =
|
8045
|
+
eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.isComponentDataEmpty = exports.getEmptyValue = exports.findComponent = exports.applyFormChanges = exports.generateFormChange = exports.getStrings = exports.getValue = exports.escapeRegExCharacters = exports.formatAsCurrency = exports.parseFloatExt = exports.hasCondition = exports.removeComponent = exports.searchComponents = exports.getComponent = exports.matchComponent = exports.isLayoutComponent = exports.getComponentActualValue = exports.getComponentData = exports.eachComponentAsync = exports.eachComponent = exports.componentInfo = exports.getContextualRowData = exports.getContextualRowPath = exports.getComponentKey = exports.eachComponentData = exports.eachComponentDataAsync = exports.componentChildPath = exports.componentPath = exports.isComponentNestedDataType = exports.isComponentModelType = exports.getComponentPath = exports.getComponentAbsolutePath = exports.getModelType = exports.MODEL_TYPES = exports.uniqueName = exports.guid = exports.flattenComponents = exports.findComponents = void 0;\nconst core_1 = __webpack_require__(/*! @formio/core */ \"./node_modules/@formio/core/lib/index.js\");\nconst { flattenComponents, guid, uniqueName, MODEL_TYPES, getModelType, getComponentAbsolutePath, getComponentPath, isComponentModelType, isComponentNestedDataType, componentPath, componentChildPath, eachComponentDataAsync, eachComponentData, getComponentKey, getContextualRowPath, getContextualRowData, componentInfo, eachComponent, eachComponentAsync, getComponentData, getComponentActualValue, isLayoutComponent, matchComponent, getComponent, searchComponents, removeComponent, hasCondition, parseFloatExt, formatAsCurrency, escapeRegExCharacters, getValue, getStrings, generateFormChange, applyFormChanges, findComponent, getEmptyValue, isComponentDataEmpty } = core_1.Utils;\nexports.flattenComponents = flattenComponents;\nexports.guid = guid;\nexports.uniqueName = uniqueName;\nexports.MODEL_TYPES = MODEL_TYPES;\nexports.getModelType = getModelType;\nexports.getComponentAbsolutePath = getComponentAbsolutePath;\nexports.getComponentPath = getComponentPath;\nexports.isComponentModelType = isComponentModelType;\nexports.isComponentNestedDataType = isComponentNestedDataType;\nexports.componentPath = componentPath;\nexports.componentChildPath = componentChildPath;\nexports.eachComponentDataAsync = eachComponentDataAsync;\nexports.eachComponentData = eachComponentData;\nexports.getComponentKey = getComponentKey;\nexports.getContextualRowPath = getContextualRowPath;\nexports.getContextualRowData = getContextualRowData;\nexports.componentInfo = componentInfo;\nexports.eachComponent = eachComponent;\nexports.eachComponentAsync = eachComponentAsync;\nexports.getComponentData = getComponentData;\nexports.getComponentActualValue = getComponentActualValue;\nexports.isLayoutComponent = isLayoutComponent;\nexports.matchComponent = matchComponent;\nexports.getComponent = getComponent;\nexports.searchComponents = searchComponents;\nexports.removeComponent = removeComponent;\nexports.hasCondition = hasCondition;\nexports.parseFloatExt = parseFloatExt;\nexports.formatAsCurrency = formatAsCurrency;\nexports.escapeRegExCharacters = escapeRegExCharacters;\nexports.getValue = getValue;\nexports.getStrings = getStrings;\nexports.generateFormChange = generateFormChange;\nexports.applyFormChanges = applyFormChanges;\nexports.findComponent = findComponent;\nexports.getEmptyValue = getEmptyValue;\nexports.isComponentDataEmpty = isComponentDataEmpty;\n/**\n * Deprecated version of findComponents. Renamed to searchComponents.\n * @param {import('@formio/core').Component[]} components - The components to find components within.\n * @param {object} query - The query to use when searching for the components.\n * @returns {import('@formio/core').Component[]} - The result of the component that is found.\n */\nfunction findComponents(components, query) {\n console.warn('formio.js/utils findComponents is deprecated. Use searchComponents instead.');\n return searchComponents(components, query);\n}\nexports.findComponents = findComponents;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/utils/formUtils.js?");
|
8046
8046
|
|
8047
8047
|
/***/ }),
|
8048
8048
|
|
@@ -8086,7 +8086,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexpo
|
|
8086
8086
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
8087
8087
|
|
8088
8088
|
"use strict";
|
8089
|
-
eval("\n/* global jQuery */\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __exportStar = (this && this.__exportStar) || function(m, exports) {\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);\n};\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.interpolateErrors = exports.componentValueTypes = exports._ = exports.interpolate = exports.Evaluator = exports.firstNonNil = exports.moment = exports.ConditionOperators = exports.jsonLogic = void 0;\nexports.evaluate = evaluate;\nexports.getRandomComponentId = getRandomComponentId;\nexports.getPropertyValue = getPropertyValue;\nexports.getElementRect = getElementRect;\nexports.getScriptPlugin = getScriptPlugin;\nexports.boolValue = boolValue;\nexports.isMongoId = isMongoId;\nexports.checkCalculated = checkCalculated;\nexports.checkSimpleConditional = checkSimpleConditional;\nexports.getComponentActualValue = getComponentActualValue;\nexports.checkCustomConditional = checkCustomConditional;\nexports.checkJsonConditional = checkJsonConditional;\nexports.checkCondition = checkCondition;\nexports.checkTrigger = checkTrigger;\nexports.setActionProperty = setActionProperty;\nexports.removeHTML = removeHTML;\nexports.unescapeHTML = unescapeHTML;\nexports.convertStringToHTMLElement = convertStringToHTMLElement;\nexports.uniqueName = uniqueName;\nexports.guid = guid;\nexports.getDateSetting = getDateSetting;\nexports.isValidDate = isValidDate;\nexports.currentTimezone = currentTimezone;\nexports.offsetDate = offsetDate;\nexports.zonesLoaded = zonesLoaded;\nexports.shouldLoadZones = shouldLoadZones;\nexports.loadZones = loadZones;\nexports.momentDate = momentDate;\nexports.formatDate = formatDate;\nexports.formatOffset = formatOffset;\nexports.getLocaleDateFormatInfo = getLocaleDateFormatInfo;\nexports.convertFormatToFlatpickr = convertFormatToFlatpickr;\nexports.convertFormatToMoment = convertFormatToMoment;\nexports.convertFormatToMask = convertFormatToMask;\nexports.getInputMask = getInputMask;\nexports.unmaskValue = unmaskValue;\nexports.matchInputMask = matchInputMask;\nexports.getNumberSeparators = getNumberSeparators;\nexports.getNumberDecimalLimit = getNumberDecimalLimit;\nexports.getCurrencyAffixes = getCurrencyAffixes;\nexports.fieldData = fieldData;\nexports.delay = delay;\nexports.iterateKey = iterateKey;\nexports.uniqueKey = uniqueKey;\nexports.bootstrapVersion = bootstrapVersion;\nexports.unfold = unfold;\nexports.withSwitch = withSwitch;\nexports.observeOverload = observeOverload;\nexports.getContextComponents = getContextComponents;\nexports.getContextButtons = getContextButtons;\nexports.translateHTMLTemplate = translateHTMLTemplate;\nexports.sanitize = sanitize;\nexports.fastCloneDeep = fastCloneDeep;\nexports.isInputComponent = isInputComponent;\nexports.getArrayFromComponentPath = getArrayFromComponentPath;\nexports.isChildOf = isChildOf;\nexports.getStringFromComponentPath = getStringFromComponentPath;\nexports.round = round;\nexports.getIEBrowserVersion = getIEBrowserVersion;\nexports.getBrowserInfo = getBrowserInfo;\nexports.getComponentPathWithoutIndicies = getComponentPathWithoutIndicies;\nexports.getComponentPath = getComponentPath;\nexports.getDataParentComponent = getDataParentComponent;\nexports.isPromise = isPromise;\nexports.isInsideScopingComponent = isInsideScopingComponent;\nexports.getFocusableElements = getFocusableElements;\nexports.getComponentSavedTypes = getComponentSavedTypes;\nexports.getItemTemplateKeys = getItemTemplateKeys;\nexports.isSelectResourceWithObjectValue = isSelectResourceWithObjectValue;\nconst lodash_1 = __importDefault(__webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\"));\nexports._ = lodash_1.default;\nconst fetch_ponyfill_1 = __importDefault(__webpack_require__(/*! fetch-ponyfill */ \"./node_modules/fetch-ponyfill/build/fetch-browser.js\"));\nconst json_logic_js_1 = __importDefault(__webpack_require__(/*! json-logic-js */ \"./node_modules/json-logic-js/logic.js\"));\nexports.jsonLogic = json_logic_js_1.default;\nconst moment_timezone_1 = __importDefault(__webpack_require__(/*! moment-timezone/moment-timezone */ \"./node_modules/moment-timezone/moment-timezone.js\"));\nconst jstimezonedetect_1 = __importDefault(__webpack_require__(/*! jstimezonedetect */ \"./node_modules/jstimezonedetect/dist/jstz.min.js\"));\nconst operators_1 = __webpack_require__(/*! ./jsonlogic/operators */ \"./lib/cjs/utils/jsonlogic/operators.js\");\nconst dompurify_1 = __importDefault(__webpack_require__(/*! dompurify */ \"./node_modules/dompurify/dist/purify.js\"));\nconst formUtils_1 = __webpack_require__(/*! ./formUtils */ \"./lib/cjs/utils/formUtils.js\");\nconst Evaluator_1 = __webpack_require__(/*! ./Evaluator */ \"./lib/cjs/utils/Evaluator.js\");\nObject.defineProperty(exports, \"Evaluator\", ({ enumerable: true, get: function () { return Evaluator_1.Evaluator; } }));\nconst conditionOperators_1 = __importDefault(__webpack_require__(/*! ./conditionOperators */ \"./lib/cjs/utils/conditionOperators/index.js\"));\nexports.ConditionOperators = conditionOperators_1.default;\nconst interpolate = Evaluator_1.Evaluator.interpolate;\nexports.interpolate = interpolate;\nconst { fetch } = (0, fetch_ponyfill_1.default)({\n Promise: Promise\n});\n__exportStar(__webpack_require__(/*! ./formUtils */ \"./lib/cjs/utils/formUtils.js\"), exports);\n// Configure JsonLogic\noperators_1.lodashOperators.forEach((name) => json_logic_js_1.default.add_operation(`_${name}`, lodash_1.default[name]));\n// Retrieve Any Date\njson_logic_js_1.default.add_operation('getDate', (date) => {\n return (0, moment_timezone_1.default)(date).toISOString();\n});\n// Set Relative Minimum Date\njson_logic_js_1.default.add_operation('relativeMinDate', (relativeMinDate) => {\n return (0, moment_timezone_1.default)().subtract(relativeMinDate, 'days').toISOString();\n});\n// Set Relative Maximum Date\njson_logic_js_1.default.add_operation('relativeMaxDate', (relativeMaxDate) => {\n return (0, moment_timezone_1.default)().add(relativeMaxDate, 'days').toISOString();\n});\nexports.moment = __importStar(__webpack_require__(/*! moment-timezone/moment-timezone */ \"./node_modules/moment-timezone/moment-timezone.js\"));\n/**\n * Sets the path to the component and parent schema.\n * @param {import('@formio/core').Component} component - The component to set the path for.\n */\nfunction setPathToComponentAndPerentSchema(component) {\n component.path = getComponentPath(component);\n const dataParent = getDataParentComponent(component);\n if (dataParent && typeof dataParent === 'object') {\n dataParent.path = getComponentPath(dataParent);\n }\n}\n/**\n * Evaluate a method.\n * @param {Function|string|object} func - The function to evaluate.\n * @param {*} args - A map of arguments to pass to the function.\n * @param {string} ret - The name of the \"return\" variable in the script.\n * @param {boolean} interpolate - True if the script should be interpolated before being executed.\n * @param {import('@formio/core').EvaluatorOptions} options - The evaluator options.\n * @returns {*} - The result of the evaluation.\n */\nfunction evaluate(func, args, ret, interpolate, options = {}) {\n return Evaluator_1.Evaluator.evaluate(func, args, ret, interpolate, undefined, options);\n}\n/**\n * Returns a random compoennt ID.\n * @returns {string} - A random component ID.\n */\nfunction getRandomComponentId() {\n return `e${Math.random().toString(36).substring(7)}`;\n}\n/**\n * Get a property value of an element.\n * @param {CSSStyleDeclaration} style - The style element to get the property value from.\n * @param {string} prop - The property to get the value for.\n * @returns {number} - The value of the property.\n */\nfunction getPropertyValue(style, prop) {\n let value = style.getPropertyValue(prop);\n value = value ? value.replace(/[^0-9.]/g, '') : '0';\n return parseFloat(value);\n}\n/**\n * Get an elements bounding rectagle.\n * @param {HTMLElement} element - A DOM element to get the bounding rectangle for.\n * @returns {{x: number, y: number, width: number, height: number}} - The bounding rectangle.\n */\nfunction getElementRect(element) {\n const style = window.getComputedStyle(element, null);\n return {\n x: getPropertyValue(style, 'left'),\n y: getPropertyValue(style, 'top'),\n width: getPropertyValue(style, 'width'),\n height: getPropertyValue(style, 'height')\n };\n}\n/**\n * Get non HTMLElement property in the window object\n * @param {string} property - The window property to fetch the script plugin from.\n * @returns {any | undefined} - The HTML Element property on the window object.\n */\nfunction getScriptPlugin(property) {\n const obj = window[property];\n if (typeof HTMLElement === 'object' ? obj instanceof HTMLElement : //DOM2\n obj && typeof obj === 'object' && true && obj.nodeType === 1 && typeof obj.nodeName === 'string') {\n return undefined;\n }\n return obj;\n}\n/**\n * Determines the boolean value of a setting.\n * @param {string|boolean} value - A string or boolean value to convert to boolean.\n * @returns {boolean} - The boolean value of the setting.\n */\nfunction boolValue(value) {\n if (lodash_1.default.isBoolean(value)) {\n return value;\n }\n else if (lodash_1.default.isString(value)) {\n return (value.toLowerCase() === 'true');\n }\n else {\n return !!value;\n }\n}\n/**\n * Check to see if an ID is a mongoID.\n * @param {string} text - The text to check if it is a mongoID.\n * @returns {boolean} - TRUE if the text is a mongoID; FALSE otherwise.\n */\nfunction isMongoId(text) {\n return !!text.toString().match(/^[0-9a-fA-F]{24}$/);\n}\n/**\n * Checks the calculated value for a provided component and data.\n * @param {import('@formio/core').Component} component - The component to check for the calculated value.\n * @param {import('@formio/core').Submission} submission - A submission object.\n * @param {*} rowData - The contextual row data for the component.\n */\nfunction checkCalculated(component, submission, rowData) {\n // Process calculated value stuff if present.\n if (component.calculateValue) {\n lodash_1.default.set(rowData, component.key, evaluate(component.calculateValue, {\n value: undefined,\n data: submission ? submission.data : rowData,\n row: rowData,\n util: this,\n component\n }, 'value'));\n }\n}\n/**\n * Check if a simple conditional evaluates to true.\n * @param {import('@formio/core').Component} component - The component to check for the conditional.\n * @param {import('@formio/core').SimpleConditional} condition - The condition to check.\n * @param {*} row - The row data for the component.\n * @param {*} data - The full submission data.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The instance of the component.\n * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.\n */\nfunction checkSimpleConditional(component, condition, row, data, instance) {\n if (condition.when) {\n const value = getComponentActualValue(condition.when, data, row);\n const eq = String(condition.eq);\n const show = String(condition.show);\n // Special check for selectboxes component.\n if (lodash_1.default.isObject(value) && lodash_1.default.has(value, condition.eq)) {\n return String(value[condition.eq]) === show;\n }\n // FOR-179 - Check for multiple values.\n if (Array.isArray(value) && value.map(String).includes(eq)) {\n return show === 'true';\n }\n return (String(value) === eq) === (show === 'true');\n }\n else {\n const { conditions = [], conjunction = 'all', show = true } = condition;\n if (!conditions.length) {\n return true;\n }\n const conditionsResult = lodash_1.default.map(conditions, (cond) => {\n const { value: comparedValue, operator, component: conditionComponentPath } = cond;\n if (!conditionComponentPath) {\n return true;\n }\n const value = getComponentActualValue(conditionComponentPath, data, row);\n const ConditionOperator = conditionOperators_1.default[operator];\n return ConditionOperator\n ? new ConditionOperator().getResult({ value, comparedValue, instance, component, conditionComponentPath })\n : true;\n });\n let result = false;\n switch (conjunction) {\n case 'any':\n result = lodash_1.default.some(conditionsResult, res => !!res);\n break;\n default:\n result = lodash_1.default.every(conditionsResult, res => !!res);\n }\n return show ? result : !result;\n }\n}\n/**\n * Returns a components normalized value.\n * @param {string} compPath - The full path to the component.\n * @param {*} data - The data object to get the value from.\n * @param {*} row - The contextual row data for the component.\n * @returns {*} - The normalized value of the component.\n */\nfunction getComponentActualValue(compPath, data, row) {\n let value = null;\n if (row) {\n value = (0, formUtils_1.getValue)({ data: row }, compPath);\n }\n if (data && lodash_1.default.isNil(value)) {\n value = (0, formUtils_1.getValue)({ data }, compPath);\n }\n // FOR-400 - Fix issue where falsey values were being evaluated as show=true\n if (lodash_1.default.isNil(value) || (lodash_1.default.isObject(value) && lodash_1.default.isEmpty(value))) {\n value = '';\n }\n return value;\n}\n/**\n * Check custom javascript conditional.\n * @param {import('@formio/core').Component} component - The component to check for the conditional.\n * @param {string} custom - The custom conditional string to evaluate.\n * @param {*} row - The row data for the component.\n * @param {*} data - The full submission data.\n * @param {import('@formio/core').Form} form - The form object.\n * @param {string} variable - The variable name for the result of the custom conditional.\n * @param {*} onError - A custom return if there is an error or the value is null from the evaluation.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.\n * @returns {*} - The result of the evaulation.\n */\nfunction checkCustomConditional(component, custom, row, data, form, variable, onError, instance) {\n if (typeof custom === 'string') {\n custom = `var ${variable} = true; ${custom}; return ${variable};`;\n }\n const value = (instance && instance.evaluate) ?\n instance.evaluate(custom, { row, data, form }) :\n evaluate(custom, { row, data, form });\n if (value === null) {\n return onError;\n }\n return value;\n}\n/**\n * Check a component for JSON conditionals.\n * @param {import('@formio/core').Component} component - The component\n * @param {import('@formio/core').JSONConditional} json - The json conditional to check.\n * @param {*} row - The contextual row data for the component.\n * @param {*} data - The full submission data.\n * @param {import('@formio/core').Form} form - The Form JSON of the form.\n * @param {*} onError - Custom return value if there is an error.\n * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.\n */\nfunction checkJsonConditional(component, json, row, data, form, onError) {\n try {\n return json_logic_js_1.default.apply(json, {\n data,\n row,\n form,\n _: lodash_1.default,\n });\n }\n catch (err) {\n console.warn(`An error occurred in jsonLogic advanced condition for ${component.key}`, err);\n return onError;\n }\n}\n/**\n * Returns the contextual row data for a component.\n * @param {import('@formio/core').Component} component - The component to get the row data for.\n * @param {*} row - The row data for the component.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.\n * @param {*} conditional - The component conditional.\n * @returns {*} - The contextual row data for the component.\n */\nfunction getRow(component, row, instance, conditional) {\n var _a;\n const condition = conditional || component.conditional;\n // If no component's instance passed (happens only in 6.x server), calculate its path based on the schema\n if (!instance) {\n instance = lodash_1.default.cloneDeep(component);\n setPathToComponentAndPerentSchema(instance);\n }\n const dataParent = getDataParentComponent(instance);\n const parentPath = dataParent ? getComponentPath(dataParent) : null;\n const isTriggerCondtionComponentPath = condition.when || !condition.conditions\n ? (_a = condition.when) === null || _a === void 0 ? void 0 : _a.startsWith(parentPath)\n : lodash_1.default.some(condition.conditions, cond => cond.component.startsWith(parentPath));\n if (dataParent && isTriggerCondtionComponentPath) {\n const newRow = {};\n lodash_1.default.set(newRow, parentPath, row);\n row = newRow;\n }\n return row;\n}\n/**\n * Checks the conditions for a provided component and data.\n * @param {import('@formio/core').Component} component - The component to check for the condition.\n * @param {*} row - The data within a row\n * @param {*} data - The full submission data.\n * @param {import('@formio/core').Form} form - The form object.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.\n * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.\n */\nfunction checkCondition(component, row, data, form, instance) {\n const { customConditional, conditional } = component;\n if (customConditional) {\n return checkCustomConditional(component, customConditional, row, data, form, 'show', true, instance);\n }\n else if (conditional && (conditional.when || lodash_1.default.some(conditional.conditions || [], condition => condition.component && condition.operator))) {\n row = getRow(component, row, instance);\n return checkSimpleConditional(component, conditional, row, data, instance);\n }\n else if (conditional && conditional.json) {\n return checkJsonConditional(component, conditional.json, row, data, form, true);\n }\n // Default to show.\n return true;\n}\n/**\n * Test a trigger on a component.\n * @param {import('@formio/core').Component} component - The component to test the trigger against.\n * @param {import('@formio/core').LogicTrigger} trigger - The trigger configuration.\n * @param {import('@formio/core').DataObject} row - The contextual row data.\n * @param {import('@formio/core').DataObject} data - The root data object.\n * @param {import('@formio/core').Form} form - The form object.\n * @param {any} instance - The component that is performing the trigger.\n * @returns {boolean} - TRUE if the trigger should fire; FALSE otherwise.\n */\nfunction checkTrigger(component, trigger, row, data, form, instance) {\n // If trigger is empty, don't fire it\n if (!trigger || !trigger[trigger.type]) {\n return false;\n }\n switch (trigger.type) {\n case 'simple':\n row = getRow(component, row, instance, trigger.simple);\n return checkSimpleConditional(component, trigger.simple, row, data, instance);\n case 'javascript':\n return checkCustomConditional(component, trigger.javascript, row, data, form, 'result', false, instance);\n case 'json':\n return checkJsonConditional(component, trigger.json, row, data, form, false);\n }\n // If none of the types matched, don't fire the trigger.\n return false;\n}\n/**\n * Sets a property on a component via an executed Logic action.\n * @param {import('@formio/core').Component} component - The component to set the property on.\n * @param {import('@formio/core').LogicAction} action - The action to perform on the component.\n * @param {string} result - The name of the variable in the evaulation to use as the result.\n * @param {import('@formio/core').DataObject} row - The contextual row data.\n * @param {import('@formio/core').DataObject} data - The full submission data.\n * @param {any} instance - The component instance.\n * @returns {import('@formio/core').Component} - The modified component.\n */\nfunction setActionProperty(component, action, result, row, data, instance) {\n const property = action.property.value;\n switch (action.property.type) {\n case 'boolean': {\n const currentValue = lodash_1.default.get(component, property, false).toString();\n const newValue = action.state.toString();\n if (currentValue !== newValue) {\n lodash_1.default.set(component, property, newValue === 'true');\n }\n break;\n }\n case 'string': {\n const evalData = {\n data,\n row,\n component,\n result,\n };\n const textValue = action.property.component ? action[action.property.component] : action.text;\n const currentValue = lodash_1.default.get(component, property, '');\n const newValue = (instance && instance.interpolate)\n ? instance.interpolate(textValue, evalData)\n : Evaluator_1.Evaluator.interpolate(textValue, evalData);\n if (newValue !== currentValue) {\n lodash_1.default.set(component, property, newValue);\n }\n break;\n }\n }\n return component;\n}\n/**\n * Removes HTML tags from string e.g. <div>Hello World</div> => Hello World\n * @param {string} str - The string to remove HTML tags from.\n * @returns {string} - The string without HTML tags.\n */\nfunction removeHTML(str) {\n const doc = new window.DOMParser().parseFromString(str, 'text/html');\n return (doc.body.textContent || '').trim();\n}\n/**\n * Unescape HTML characters like <, >, & and etc.\n * @param {string} str - The string to unescape.\n * @returns {string} - The unescaped string.\n */\nfunction unescapeHTML(str) {\n if (typeof window === 'undefined' || !('DOMParser' in window)) {\n return str;\n }\n const elem = document.createElement('textarea');\n elem.innerHTML = str;\n return elem.value;\n}\n/**\n * Make HTML element from string\n * @param {string} str - The string to convert to an HTML element.\n * @param {string} selector - The selector to use to get the element once it is created.\n * @returns {HTMLElement} - The HTML element that was created.\n */\nfunction convertStringToHTMLElement(str, selector) {\n const doc = new window.DOMParser().parseFromString(str, 'text/html');\n return doc.body.querySelector(selector);\n}\n/**\n * Make a filename guaranteed to be unique.\n * @param {string} name - The original name of the file.\n * @param {string} template - The template to use for the unique name.\n * @param {object} evalContext - The context to use for the evaluation.\n * @returns {string} - A unique filename.\n */\nfunction uniqueName(name, template, evalContext) {\n template = template || '{{fileName}}-{{guid}}';\n //include guid in template anyway, to prevent overwriting issue if filename matches existing file\n if (!template.includes('{{guid}}')) {\n template = `${template}-{{guid}}`;\n }\n const parts = name.split('.');\n let fileName = parts.slice(0, parts.length - 1).join('.');\n const extension = parts.length > 1\n ? `.${lodash_1.default.last(parts)}`\n : '';\n //allow only 100 characters from original name to avoid issues with filename length restrictions\n fileName = fileName.substr(0, 100);\n evalContext = Object.assign(evalContext || {}, {\n fileName,\n guid: guid()\n });\n //only letters, numbers, dots, dashes, underscores and spaces are allowed. Anything else will be replaced with dash\n const uniqueName = `${Evaluator_1.Evaluator.interpolate(template, evalContext)}${extension}`.replace(/[^0-9a-zA-Z.\\-_ ]/g, '-');\n return uniqueName;\n}\n/**\n * Returns a GUID\n * @returns {string} - A GUID.\n */\nfunction guid() {\n return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {\n const r = Math.random() * 16 | 0;\n const v = c === 'x'\n ? r\n : (r & 0x3 | 0x8);\n return v.toString(16);\n });\n}\n/**\n * Return a translated date setting.\n * @param {string|Date} date - The date to translate.\n * @returns {(null|Date)} - The translated date.\n */\nfunction getDateSetting(date) {\n if (lodash_1.default.isNil(date) || lodash_1.default.isNaN(date) || date === '') {\n return null;\n }\n if (date instanceof Date) {\n return date;\n }\n else if (typeof date.toDate === 'function') {\n return date.isValid() ? date.toDate() : null;\n }\n let dateSetting = ((typeof date !== 'string') || (date.indexOf('moment(') === -1)) ? (0, moment_timezone_1.default)(date) : null;\n if (dateSetting && dateSetting.isValid()) {\n return dateSetting.toDate();\n }\n dateSetting = null;\n try {\n const value = Evaluator_1.Evaluator.evaluator(`return ${date};`, 'moment')(moment_timezone_1.default);\n if (typeof value === 'string') {\n dateSetting = (0, moment_timezone_1.default)(value);\n }\n else if (typeof value.toDate === 'function') {\n dateSetting = (0, moment_timezone_1.default)(value.toDate().toUTCString());\n }\n else if (value instanceof Date) {\n dateSetting = (0, moment_timezone_1.default)(value);\n }\n }\n catch (e) {\n return null;\n }\n if (!dateSetting) {\n return null;\n }\n // Ensure this is a date.\n if (!dateSetting.isValid()) {\n return null;\n }\n return dateSetting.toDate();\n}\n/**\n * Returns true if the date is a valid date. False otherwise.\n * @param {Date|string} date - The date to check for validity.\n * @returns {boolean} - TRUE if the date is valid; FALSE otherwise.\n */\nfunction isValidDate(date) {\n return lodash_1.default.isDate(date) && !lodash_1.default.isNaN(date.getDate());\n}\n/**\n * Get the current timezone string.\n * @returns {string} - The current timezone.\n */\nfunction currentTimezone() {\n if (moment_timezone_1.default.currentTimezone) {\n return moment_timezone_1.default.currentTimezone;\n }\n moment_timezone_1.default.currentTimezone = jstimezonedetect_1.default.determine().name();\n return moment_timezone_1.default.currentTimezone;\n}\n/**\n * Get an offset date provided a date object and timezone object.\n * @param {Date} date - The date to offset.\n * @param {string} timezone - The timezone to offset the date to.\n * @returns {Date} - The offset date.\n */\nfunction offsetDate(date, timezone) {\n if (timezone === 'UTC') {\n return {\n date: new Date(date.getTime() + (date.getTimezoneOffset() * 60000)),\n abbr: 'UTC'\n };\n }\n const dateMoment = (0, moment_timezone_1.default)(date).tz(timezone);\n return {\n date: new Date(date.getTime() + ((dateMoment.utcOffset() + date.getTimezoneOffset()) * 60000)),\n abbr: dateMoment.format('z')\n };\n}\n/**\n * Returns if the zones are loaded.\n * @returns {boolean} - TRUE if the zones are loaded; FALSE otherwise.\n */\nfunction zonesLoaded() {\n return moment_timezone_1.default.zonesLoaded;\n}\n/**\n * Returns if we should load the zones.\n * @param {string} timezone - The timezone to check if we should load the zones.\n * @returns {boolean} - TRUE if we should load the zones; FALSE otherwise.\n */\nfunction shouldLoadZones(timezone) {\n if (timezone === currentTimezone() || timezone === 'UTC') {\n return false;\n }\n return true;\n}\n/**\n * Externally load the timezone data.\n * @param {string} url - The URL to load the timezone data from.\n * @param {string} timezone - The timezone to load.\n * @returns {Promise<any> | *} - Resolves when the zones for this timezone are loaded.\n */\nfunction loadZones(url, timezone) {\n if (timezone && !shouldLoadZones(timezone)) {\n // Return non-resolving promise.\n return new Promise(lodash_1.default.noop);\n }\n if (moment_timezone_1.default.zonesPromise) {\n return moment_timezone_1.default.zonesPromise;\n }\n return moment_timezone_1.default.zonesPromise = fetch(url)\n .then(resp => resp.json().then(zones => {\n moment_timezone_1.default.tz.load(zones);\n moment_timezone_1.default.zonesLoaded = true;\n // Trigger a global event that the timezones have finished loading.\n if (document && document.createEvent && document.body && document.body.dispatchEvent) {\n var event = document.createEvent('Event');\n event.initEvent('zonesLoaded', true, true);\n document.body.dispatchEvent(event);\n }\n }));\n}\n/**\n * Get the moment date object for translating dates with timezones.\n * @param {string|Date} value - The value to convert into a moment date.\n * @param {string} format - The format to convert the date to.\n * @param {string} timezone - The timezone to convert the date to.\n * @returns {Date} - The moment date object.\n */\nfunction momentDate(value, format, timezone) {\n const momentDate = (0, moment_timezone_1.default)(value);\n if (!timezone) {\n return momentDate;\n }\n if (timezone === 'UTC') {\n timezone = 'Etc/UTC';\n }\n if ((timezone !== currentTimezone() || (format && format.match(/\\s(z$|z\\s)/))) && moment_timezone_1.default.zonesLoaded) {\n return momentDate.tz(timezone);\n }\n return momentDate;\n}\n/**\n * Format a date provided a value, format, and timezone object.\n * @param {string} timezonesUrl - The URL to load the timezone data from.\n * @param {string|Date} value - The value to format.\n * @param {string} format - The format to format the date to.\n * @param {string} timezone - The timezone to format the date to.\n * @param {string} flatPickrInputFormat - The format to use for flatpickr input.\n * @returns {string} - The formatted date.\n */\nfunction formatDate(timezonesUrl, value, format, timezone, flatPickrInputFormat) {\n const momentDate = (0, moment_timezone_1.default)(value, flatPickrInputFormat || undefined);\n if (timezone === currentTimezone()) {\n // See if our format contains a \"z\" timezone character.\n if (format.match(/\\s(z$|z\\s)/)) {\n loadZones(timezonesUrl);\n if (moment_timezone_1.default.zonesLoaded) {\n return momentDate.tz(timezone).format(convertFormatToMoment(format));\n }\n else {\n return momentDate.format(convertFormatToMoment(format.replace(/\\s(z$|z\\s)/, '')));\n }\n }\n // Return the standard format.\n return momentDate.format(convertFormatToMoment(format));\n }\n if (timezone === 'UTC') {\n const offset = offsetDate(momentDate.toDate(), 'UTC');\n return `${(0, moment_timezone_1.default)(offset.date).format(convertFormatToMoment(format))} UTC`;\n }\n // Load the zones since we need timezone information.\n loadZones(timezonesUrl);\n if (moment_timezone_1.default.zonesLoaded && timezone) {\n return momentDate.tz(timezone).format(`${convertFormatToMoment(format)} z`);\n }\n else {\n return momentDate.format(convertFormatToMoment(format));\n }\n}\n/**\n * Pass a format function to format within a timezone.\n * @param {string} timezonesUrl - The URL to load the timezone data from.\n * @param {Function} formatFn - The format function to use.\n * @param {Date|string} date - The date to format.\n * @param {string} format - The format to format the date to.\n * @param {string} timezone - The timezone to format the date to.\n * @returns {string} - The formatted date.\n */\nfunction formatOffset(timezonesUrl, formatFn, date, format, timezone) {\n if (timezone === currentTimezone()) {\n return formatFn(date, format);\n }\n if (timezone === 'UTC') {\n return `${formatFn(offsetDate(date, 'UTC').date, format)} UTC`;\n }\n // Load the zones since we need timezone information.\n loadZones(timezonesUrl);\n if (moment_timezone_1.default.zonesLoaded) {\n const offset = offsetDate(date, timezone);\n return `${formatFn(offset.date, format)} ${offset.abbr}`;\n }\n else {\n return formatFn(date, format);\n }\n}\n/**\n * Returns the local date format information.\n * @param {Intl.LocalesArgument} locale - The locale to get the date format for.\n * @returns {object} - The local date format information.\n */\nfunction getLocaleDateFormatInfo(locale) {\n const formatInfo = {};\n const day = 21;\n const exampleDate = new Date(2017, 11, day);\n const localDateString = exampleDate.toLocaleDateString(locale);\n formatInfo.dayFirst = localDateString.slice(0, 2) === day.toString();\n return formatInfo;\n}\n/**\n * Convert the format from the angular-datepicker module to flatpickr format.\n * @param {string} format - The format to convert.\n * @returns {string} - The converted format.\n */\nfunction convertFormatToFlatpickr(format) {\n return format\n // Remove the Z timezone offset, not supported by flatpickr.\n .replace(/Z/g, '')\n // Year conversion.\n .replace(/y/g, 'Y')\n .replace('YYYY', 'Y')\n .replace('YY', 'y')\n // Month conversion.\n .replace('MMMM', 'F')\n .replace(/M/g, 'n')\n .replace('nnn', 'M')\n .replace('nn', 'm')\n // Day in month.\n .replace(/d/g, 'j')\n .replace(/jj/g, 'd')\n // Day in week.\n .replace('EEEE', 'l')\n .replace('EEE', 'D')\n // Hours, minutes, seconds\n .replace('HH', 'H')\n .replace('hh', 'G')\n .replace('mm', 'i')\n .replace('ss', 'S')\n .replace(/a/g, 'K');\n}\n/**\n * Convert the format from the angular-datepicker module to moment format.\n * @param {string} format - The format to convert.\n * @returns {string} - The converted format.\n */\nfunction convertFormatToMoment(format) {\n return format\n // Year conversion.\n .replace(/y/g, 'Y')\n // Day in month.\n .replace(/d/g, 'D')\n // Day in week.\n .replace(/E/g, 'd')\n // AM/PM marker\n .replace(/a/g, 'A')\n // Unix Timestamp\n .replace(/U/g, 'X');\n}\n/**\n * Convert the format from the angular-datepicker module to mask format.\n * @param {string} format - The format to convert.\n * @returns {string} - The converted format.\n */\nfunction convertFormatToMask(format) {\n return format\n // Long month replacement.\n .replace(/M{4}/g, 'MM')\n // Initial short month conversion.\n .replace(/M{3}/g, '***')\n // Short month conversion if input as text.\n .replace(/e/g, 'Q')\n // Month number conversion.\n .replace(/W/g, '99')\n // Year conversion.\n .replace(/[ydhmswHMG]/g, '9')\n // AM/PM conversion.\n .replace(/a/g, 'AA');\n}\n/**\n * Returns an input mask that is compatible with the input mask library.\n * @param {string} mask - The Form.io input mask.\n * @param {string} placeholderChar - Char which is used as a placeholder.\n * @returns {Array} - The input mask for the mask library.\n */\nfunction getInputMask(mask, placeholderChar) {\n if (mask instanceof Array) {\n return mask;\n }\n const maskArray = [];\n maskArray.numeric = true;\n for (let i = 0; i < mask.length; i++) {\n switch (mask[i]) {\n case '9':\n maskArray.push(/\\d/);\n break;\n case 'A':\n maskArray.numeric = false;\n maskArray.push(/[a-zA-Z]/);\n break;\n case 'a':\n maskArray.numeric = false;\n maskArray.push(/[a-z]/);\n break;\n case '*':\n maskArray.numeric = false;\n maskArray.push(/[a-zA-Z0-9]/);\n break;\n // If char which is used inside mask placeholder was used in the mask, replace it with space to prevent errors\n case placeholderChar:\n maskArray.numeric = false;\n maskArray.push(' ');\n break;\n default:\n maskArray.numeric = false;\n maskArray.push(mask[i]);\n break;\n }\n }\n return maskArray;\n}\n/**\n * Unmasks a value using the provided mask and placeholder characters.\n * @param {string} value - The value to unmask.\n * @param {string} mask - The mask to use for unmasking.\n * @param {string} placeholderChar - The placeholder character to use for unmasking.\n * @returns {string} - The unmasked value.\n */\nfunction unmaskValue(value, mask, placeholderChar) {\n if (!mask || !value || value.length > mask.length) {\n return value;\n }\n let unmaskedValue = value.split('');\n for (let i = 0; i < mask.length; i++) {\n const char = value[i] || '';\n const charPart = mask[i];\n if (!lodash_1.default.isRegExp(charPart) && char === charPart) {\n unmaskedValue[i] = '';\n }\n }\n unmaskedValue = unmaskedValue.join('').replace(placeholderChar, '');\n return unmaskedValue;\n}\n/**\n * Returns true if the value matches the input mask format.\n * @param {string} value - The value to check.\n * @param {string} inputMask - The input mask to check against.\n * @returns {boolean} - TRUE if the value matches the input mask; FALSE otherwise.\n */\nfunction matchInputMask(value, inputMask) {\n if (!inputMask) {\n return true;\n }\n // If value is longer than mask, it isn't valid.\n if (value.length > inputMask.length) {\n return false;\n }\n for (let i = 0; i < inputMask.length; i++) {\n const char = value[i] || '';\n const charPart = inputMask[i];\n if (!(lodash_1.default.isRegExp(charPart) && charPart.test(char) || charPart === char)) {\n return false;\n }\n }\n return true;\n}\n/**\n * Returns the number separators (i.e. 1,000) for the provided language.\n * @param {string} lang - The language code to get the number separators for.\n * @returns {{delimiter: string, decimalSeparator: string}} - The number separators.\n */\nfunction getNumberSeparators(lang = 'en') {\n const formattedNumberString = (12345.6789).toLocaleString(lang);\n const delimeters = formattedNumberString.match(/..(.)...(.)../);\n if (!delimeters) {\n return {\n delimiter: ',',\n decimalSeparator: '.'\n };\n }\n return {\n delimiter: (delimeters.length > 1) ? delimeters[1] : ',',\n decimalSeparator: (delimeters.length > 2) ? delimeters[2] : '.',\n };\n}\n/**\n * Returns the number for the maximum amount of decimal places for a number.\n * @param {import('@formio/core').Component} component - The component to check for decimal limits.\n * @param {number} defaultLimit - The default limit to use if none is provided in the component.\n * @returns {number} - The number of decimal places allowed.\n */\nfunction getNumberDecimalLimit(component, defaultLimit) {\n if (lodash_1.default.has(component, 'decimalLimit')) {\n return lodash_1.default.get(component, 'decimalLimit');\n }\n // Determine the decimal limit. Defaults to 20 but can be overridden by validate.step or decimalLimit settings.\n let decimalLimit = defaultLimit || 20;\n const step = lodash_1.default.get(component, 'validate.step', 'any');\n if (step !== 'any') {\n const parts = step.toString().split('.');\n if (parts.length > 1) {\n decimalLimit = parts[1].length;\n }\n }\n return decimalLimit;\n}\n/**\n * Returns the currency affixes for a specific language.\n * @param {object} arg0 - The arguments object.\n * @param {string} arg0.currency - The currency code to get the affixes for.\n * @param {number} arg0.decimalLimit - The number of decimal places to use.\n * @param {string} arg0.decimalSeparator - The decimal separator to use.\n * @param {string} arg0.lang - The language code to use.\n * @returns {{prefix: string, suffix: string}} - The currency affixes.\n */\nfunction getCurrencyAffixes({ currency, decimalLimit, decimalSeparator, lang, }) {\n // Get the prefix and suffix from the localized string.\n let regex = `(.*)?${(100).toLocaleString(lang)}`;\n if (decimalLimit) {\n regex += `${decimalSeparator === '.' ? '\\\\.' : decimalSeparator}${(0).toLocaleString(lang)}{${decimalLimit}}`;\n }\n regex += '(.*)?';\n const parts = (100).toLocaleString(lang, {\n style: 'currency',\n currency: currency ? currency : 'USD',\n useGrouping: true,\n maximumFractionDigits: decimalLimit || 0,\n minimumFractionDigits: decimalLimit || 0\n }).replace('.', decimalSeparator).match(new RegExp(regex));\n return {\n prefix: (parts === null || parts === void 0 ? void 0 : parts[1]) || '',\n suffix: (parts === null || parts === void 0 ? void 0 : parts[2]) || ''\n };\n}\n/**\n * Fetch the field data provided a component.\n * @param {import('@formio/core').DataObject} data - The data object to fetch the field data from.\n * @param {import('@formio/core').Component} component - The component to fetch the field data for.\n * @returns {*} - The field data.\n */\nfunction fieldData(data, component) {\n if (!data) {\n return '';\n }\n if (!component || !component.key) {\n return data;\n }\n if (component.key.includes('.')) {\n let value = data;\n const parts = component.key.split('.');\n let key = '';\n for (let i = 0; i < parts.length; i++) {\n key = parts[i];\n // Handle nested resources\n if (value.hasOwnProperty('_id')) {\n value = value.data;\n }\n // Return if the key is not found on the value.\n if (!value.hasOwnProperty(key)) {\n return;\n }\n // Convert old single field data in submissions to multiple\n if (key === parts[parts.length - 1] && component.multiple && !Array.isArray(value[key])) {\n value[key] = [value[key]];\n }\n // Set the value of this key.\n value = value[key];\n }\n return value;\n }\n else {\n // Convert old single field data in submissions to multiple\n if (component.multiple && !Array.isArray(data[component.key])) {\n data[component.key] = [data[component.key]];\n }\n // Fix for checkbox type radio submission values in tableView\n if (component.type === 'checkbox' && component.inputType === 'radio') {\n return data[component.name] === component.value;\n }\n return data[component.key];\n }\n}\n/**\n * Delays function execution with possibility to execute function synchronously or cancel it.\n * @param {Function} fn - Function to delay\n * @param {number} delay - Delay time\n * @param {...any} args - Arguments to pass to the function\n * @returns {*} - Function to cancel the delay\n */\nfunction delay(fn, delay = 0, ...args) {\n const timer = setTimeout(fn, delay, ...args);\n /**\n *\n */\n function cancel() {\n clearTimeout(timer);\n }\n /**\n * Execute the function early.\n * @returns {*} - The result of the function.\n */\n function earlyCall() {\n cancel();\n return fn(...args);\n }\n earlyCall.timer = timer;\n earlyCall.cancel = cancel;\n return earlyCall;\n}\n/**\n * Iterate the given key to make it unique.\n * @param {string} key\n * Modify the component key to be unique.\n * @returns {string}\n * The new component key.\n */\nfunction iterateKey(key) {\n if (!key.match(/(\\d+)$/)) {\n return `${key}1`;\n }\n return key.replace(/(\\d+)$/, function (suffix) {\n return Number(suffix) + 1;\n });\n}\n/**\n * Determines a unique key within a map provided the base key.\n * @param {Record<string, string>} map - The map to check for uniqueness.\n * @param {string} base - The base path of the key.\n * @returns {string} - The unique key.\n */\nfunction uniqueKey(map, base) {\n let newKey = base;\n while (map.hasOwnProperty(newKey)) {\n newKey = iterateKey(newKey);\n }\n return newKey;\n}\n/**\n * Determines the major version number of bootstrap.\n * @param {object} options - The options to check for bootstrap version.\n * @param {string} options.bootstrap - The bootstrap version to use.\n * @returns {number} - The bootstrap version.\n */\nfunction bootstrapVersion(options) {\n if (options.bootstrap) {\n return options.bootstrap;\n }\n if ((typeof jQuery === 'function') && (typeof jQuery().collapse === 'function')) {\n return parseInt(jQuery.fn.collapse.Constructor.VERSION.split('.')[0], 10);\n }\n if (window.bootstrap && window.bootstrap.Collapse) {\n return parseInt(window.bootstrap.Collapse.VERSION.split('.')[0], 10);\n }\n return 0;\n}\n/**\n * Retrun provided argument.\n * If argument is a function, returns the result of a function call.\n * @param {Function|any} e - The argument to check if a function and call if so.\n * @returns {any} - Either the result of the function call (e) or e if it is not a function.\n */\nfunction unfold(e) {\n if (typeof e === 'function') {\n return e();\n }\n return e;\n}\n/**\n * Map values through unfold and return first non-nil value.\n * @param {Array<T>} collection - The collection to map through unfold.;\n * @returns {T} - The first non-nil value.\n */\nexports.firstNonNil = lodash_1.default.flow([\n lodash_1.default.partialRight(lodash_1.default.map, unfold),\n lodash_1.default.partialRight(lodash_1.default.find, v => !lodash_1.default.isUndefined(v))\n]);\n/**\n * Create enclosed state. Returns functions to getting and cycling between states.\n * @param {*} a - initial state.\n * @param {*} b - next state.\n * @returns {Functions[]} -- [get, toggle];\n */\nfunction withSwitch(a, b) {\n let state = a;\n let next = b;\n /**\n * Returns the state of the switch.\n * @returns {*} - The current state.\n */\n function get() {\n return state;\n }\n /**\n * Toggles the state of the switch.\n */\n function toggle() {\n const prev = state;\n state = next;\n next = prev;\n }\n return [get, toggle];\n}\n/**\n * Create a function that will call the provided function only the provided limit.\n * @param {Function} callback - The callback to call.\n * @param {object} options - The options to use.\n * @param {number} options.limit - The limit to call the callback.\n * @param {number} options.delay - The delay to wait before resetting the call count.\n * @returns {Function} - The function that will call the callback only the provided limit.\n */\nfunction observeOverload(callback, options = {}) {\n const { limit = 50, delay = 500 } = options;\n let callCount = 0;\n let timeoutID = 0;\n const reset = () => callCount = 0;\n return () => {\n if (timeoutID !== 0) {\n clearTimeout(timeoutID);\n timeoutID = 0;\n }\n timeoutID = setTimeout(reset, delay);\n callCount += 1;\n if (callCount >= limit) {\n clearTimeout(timeoutID);\n reset();\n return callback();\n }\n };\n}\n/**\n * Returns the components that are provided within an evaluation context.\n * @param {any} context - The evaluation context to get the components from.\n * @param {boolean} excludeNested - Exclude nested components.\n * @param {Array<string>} excludedTypes - The types of components to exclude.\n * @returns {Array} - The components within the evaluation context.\n */\nfunction getContextComponents(context, excludeNested, excludedTypes = []) {\n const values = [];\n context.utils.eachComponent(context.instance.options.editForm.components, (component, path) => {\n const addToContextComponents = excludeNested ? !component.tree : true;\n if (component.key !== context.data.key && addToContextComponents && !lodash_1.default.includes(excludedTypes, component.type)) {\n values.push({\n label: `${component.label || component.key} (${path})`,\n value: path,\n });\n }\n });\n return values;\n}\n/**\n * Returns the button components that are within an evaluation context.\n * @param {any} context - The evaluation context to get the components from.\n * @returns {Array} - The button components within the evaluation context.\n */\nfunction getContextButtons(context) {\n const values = [];\n context.utils.eachComponent(context.instance.options.editForm.components, (component) => {\n if (component.type === 'button') {\n values.push({\n label: `${component.key} (${component.label})`,\n value: component.key,\n });\n }\n });\n return values;\n}\n// Tags that could be in text, that should be ommited or handled in a special way\nconst inTextTags = ['#text', 'A', 'B', 'EM', 'I', 'SMALL', 'STRONG', 'SUB', 'SUP', 'INS', 'DEL', 'MARK', 'CODE'];\n/**\n * Helper function for 'translateHTMLTemplate'. Translates text value of the passed html element.\n * @param {HTMLElement} elem - The element to translate.\n * @param {Function} translate - The translation function.\n * @returns {string} - Translated element template.\n */\nfunction translateElemValue(elem, translate) {\n if (!elem.innerText) {\n return elem.innerHTML;\n }\n const elemValue = elem.innerText.replace(Evaluator_1.Evaluator.templateSettings.interpolate, '').replace(/\\s\\s+/g, ' ').trim();\n const translatedValue = translate(elemValue);\n if (elemValue !== translatedValue) {\n const links = elem.innerHTML.match(/<a[^>]*>(.*?)<\\/a>/g);\n if (links && links.length) {\n if (links.length === 1 && links[0].length === elem.innerHTML.length) {\n return elem.innerHTML.replace(elemValue, translatedValue);\n }\n const translatedLinks = links.map(link => {\n const linkElem = document.createElement('a');\n linkElem.innerHTML = link;\n return translateElemValue(linkElem, translate);\n });\n return `${translatedValue} (${translatedLinks.join(', ')})`;\n }\n else {\n return elem.innerText.replace(elemValue, translatedValue);\n }\n }\n else {\n return elem.innerHTML;\n }\n}\n/**\n * Helper function for 'translateHTMLTemplate'. Goes deep through html tag children and calls function to translate their text values.\n * @param {HTMLElement} tag - The tag to translate.\n * @param {Function} translate - The translation function.\n * @returns {void}\n */\nfunction translateDeepTag(tag, translate) {\n const children = tag.children.length && [...tag.children];\n const shouldTranslateEntireContent = children && children.every(child => child.children.length === 0\n && inTextTags.some(tag => child.nodeName === tag));\n if (!children || shouldTranslateEntireContent) {\n tag.innerHTML = translateElemValue(tag, translate);\n }\n else {\n children.forEach(child => translateDeepTag(child, translate));\n }\n}\n/**\n * Translates text values in html template.\n * @param {string} template - The template to translate.\n * @param {Function} translate - The translation function.\n * @returns {string} - Html template with translated values.\n */\nfunction translateHTMLTemplate(template, translate) {\n const isHTML = /<[^>]*>/.test(template);\n if (!isHTML) {\n return translate(template);\n }\n const tempElem = document.createElement('div');\n tempElem.innerHTML = template;\n if (tempElem.innerText && tempElem.children.length) {\n translateDeepTag(tempElem, translate);\n return tempElem.innerHTML;\n }\n return template;\n}\n/**\n * Sanitize an html string.\n * @param {string} string - The string to sanitize.\n * @param {any} options - The options to use for sanitization.\n * @returns {string} - The sanitized html string.\n */\nfunction sanitize(string, options) {\n if (typeof dompurify_1.default.sanitize !== 'function') {\n return string;\n }\n // Dompurify configuration\n const sanitizeOptions = {\n ADD_ATTR: ['ref', 'target'],\n USE_PROFILES: { html: true }\n };\n // Use profiles\n if (options.sanitizeConfig && options.sanitizeConfig.useProfiles) {\n Object.keys(options.sanitizeConfig.useProfiles).forEach(key => {\n sanitizeOptions.USE_PROFILES[key] = options.sanitizeConfig.useProfiles[key];\n });\n }\n // Add attrs\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.addAttr) && options.sanitizeConfig.addAttr.length > 0) {\n options.sanitizeConfig.addAttr.forEach((attr) => {\n sanitizeOptions.ADD_ATTR.push(attr);\n });\n }\n // Add tags\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.addTags) && options.sanitizeConfig.addTags.length > 0) {\n sanitizeOptions.ADD_TAGS = options.sanitizeConfig.addTags;\n }\n // Allow tags\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.allowedTags) && options.sanitizeConfig.allowedTags.length > 0) {\n sanitizeOptions.ALLOWED_TAGS = options.sanitizeConfig.allowedTags;\n }\n // Allow attributes\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.allowedAttrs) && options.sanitizeConfig.allowedAttrs.length > 0) {\n sanitizeOptions.ALLOWED_ATTR = options.sanitizeConfig.allowedAttrs;\n }\n // Allowd URI Regex\n if (options.sanitizeConfig && options.sanitizeConfig.allowedUriRegex) {\n const allowedUriRegex = options.sanitizeConfig.allowedUriRegex;\n sanitizeOptions.ALLOWED_URI_REGEXP = lodash_1.default.isString(allowedUriRegex) ? new RegExp(allowedUriRegex) : allowedUriRegex;\n }\n // Allow to extend the existing array of elements that are safe for URI-like values\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.addUriSafeAttr) && options.sanitizeConfig.addUriSafeAttr.length > 0) {\n sanitizeOptions.ADD_URI_SAFE_ATTR = options.sanitizeConfig.addUriSafeAttr;\n }\n return dompurify_1.default.sanitize(string, sanitizeOptions);\n}\n/**\n * Fast cloneDeep for JSON objects only.\n * @param {any} obj - The object to perform a fast clone deep against.\n * @returns {any} - The cloned object.\n */\nfunction fastCloneDeep(obj) {\n return obj ? JSON.parse(JSON.stringify(obj)) : obj;\n}\n/**\n * Returns if the component is an input component.\n * @param {import('@formio/core').Component} componentJson - The JSON of a component.\n * @returns {bool} - TRUE if the component is an input component; FALSE otherwise.\n */\nfunction isInputComponent(componentJson) {\n if (componentJson.input === false || componentJson.input === true) {\n return componentJson.input;\n }\n switch (componentJson.type) {\n case 'htmlelement':\n case 'content':\n case 'columns':\n case 'fieldset':\n case 'panel':\n case 'table':\n case 'tabs':\n case 'well':\n case 'button':\n return false;\n default:\n return true;\n }\n}\n/**\n * Takes a component path, and returns a component path array.\n * @param {string} pathStr - The path string to convert to an array.\n * @returns {Arryay<number>} - The array of paths.\n */\nfunction getArrayFromComponentPath(pathStr) {\n if (!pathStr || !lodash_1.default.isString(pathStr)) {\n if (!lodash_1.default.isArray(pathStr)) {\n return [pathStr];\n }\n return pathStr;\n }\n return pathStr.replace(/[[\\]]/g, '.')\n .replace(/\\.\\./g, '.')\n .replace(/(^\\.)|(\\.$)/g, '')\n .split('.')\n .map(part => lodash_1.default.defaultTo(lodash_1.default.toNumber(part), part));\n}\n/**\n * Returns true if the component is a child of the parent.\n * @param {any} child - The child component to check.\n * @param {any} parent - The parent component to check.\n * @returns {boolean} - TRUE if the child is a child of the parent; FALSE otherwise.\n */\nfunction isChildOf(child, parent) {\n while (child && child.parent) {\n if (child.parent === parent) {\n return true;\n }\n child = child.parent;\n }\n return false;\n}\n/**\n * Takes an array of component path indexes, and returns a string version of that array.\n * @param {Array<number>} path - The path array to convert to a string.\n * @returns {string} - The string version of the path.\n */\nfunction getStringFromComponentPath(path) {\n if (!lodash_1.default.isArray(path)) {\n return path;\n }\n let strPath = '';\n path.forEach((part, i) => {\n if (lodash_1.default.isNumber(part)) {\n strPath += `[${part}]`;\n }\n else {\n strPath += i === 0 ? part : `.${part}`;\n }\n });\n return strPath;\n}\n/**\n * Takes a number and rounds it to the provided precision amount.\n * @param {number} number - The number to round.\n * @param {number} precision - The precision to round the number to.\n * @returns {string} - The rounded number.\n */\nfunction round(number, precision) {\n if (lodash_1.default.isNumber(number)) {\n return number.toFixed(precision);\n }\n return number.toString();\n}\n/**\n * Check for Internet Explorer browser version\n * @returns {(number|null)} - The IE browser version or null if not IE\n */\nfunction getIEBrowserVersion() {\n const { ie, version } = getBrowserInfo();\n return ie ? version : null;\n}\n/**\n * Get browser name and version (modified from 'jquery-browser-plugin')\n * @returns {object} -- {{browser name, version, isWebkit?}}\n * Possible browser names: chrome, safari, ie, edge, opera, mozilla, yabrowser\n */\nfunction getBrowserInfo() {\n const browser = {};\n if (typeof window === 'undefined') {\n return browser;\n }\n const ua = window.navigator.userAgent.toLowerCase();\n const match = /(edge|edg)\\/([\\w.]+)/.exec(ua) ||\n /(opr)[/]([\\w.]+)/.exec(ua) ||\n /(yabrowser)[ /]([\\w.]+)/.exec(ua) ||\n /(chrome)[ /]([\\w.]+)/.exec(ua) ||\n /(iemobile)[/]([\\w.]+)/.exec(ua) ||\n /(version)(applewebkit)[ /]([\\w.]+).*(safari)[ /]([\\w.]+)/.exec(ua) ||\n /(webkit)[ /]([\\w.]+).*(version)[ /]([\\w.]+).*(safari)[ /]([\\w.]+)/.exec(ua) ||\n /(webkit)[ /]([\\w.]+)/.exec(ua) ||\n /(opera)(?:.*version|)[ /]([\\w.]+)/.exec(ua) ||\n /(msie) ([\\w.]+)/.exec(ua) ||\n ua.indexOf('trident') >= 0 && /(rv)(?::| )([\\w.]+)/.exec(ua) ||\n ua.indexOf('compatible') < 0 && /(mozilla)(?:.*? rv:([\\w.]+)|)/.exec(ua) ||\n [];\n const matched = {\n browser: match[5] || match[3] || match[1] || '',\n version: match[4] || match[2] || '0'\n };\n if (matched.browser) {\n browser[matched.browser] = true;\n browser.version = parseInt(matched.version, 10);\n }\n // Chrome, Opera 15+, Safari and Yandex.Browser are webkit based browsers\n if (browser.chrome || browser.opr || browser.safari || browser.edg || browser.yabrowser) {\n browser.isWebkit = true;\n }\n // IE11 has a new token so we will assign it ie to avoid breaking changes\n if (browser.rv || browser.iemobile) {\n browser.ie = true;\n }\n // Edge has a new token since it became webkit based\n if (browser.edg) {\n browser.edge = true;\n }\n // Opera 15+ are identified as opr\n if (browser.opr) {\n browser.opera = true;\n }\n return browser;\n}\n/**\n * Takes a component path, which may include array indicies (i.e. [0][1]), and returns the compoennt path without the indicies.\n * @param {string} path - The path to remove the indicies from.\n * @returns {string} - The path without the indicies.\n */\nfunction getComponentPathWithoutIndicies(path = '') {\n return path.replace(/\\[\\d+\\]/, '');\n}\n/**\n * Returns a path to the component which based on its schema\n * @param {import('@formio/core').Component} component - Component containing link to its parent's schema in the 'parent' property\n * @param {string} path - Path to the component\n * @returns {string} - Path to the component\n */\nfunction getComponentPath(component, path = '') {\n var _a;\n if (!component || !component.key || ((_a = component === null || component === void 0 ? void 0 : component._form) === null || _a === void 0 ? void 0 : _a.display) === 'wizard') { // unlike the Webform, the Wizard has the key and it is a duplicate of the panel key\n return path;\n }\n path = component.isInputComponent || component.input === true ? `${component.key}${path ? '.' : ''}${path}` : path;\n return getComponentPath(component.parent, path);\n}\n/**\n * Returns a parent component of the passed component instance skipping all the Layout components\n * @param {Component} componentInstance - The component to check for the parent.\n * @returns {Component|undefined} - The parent data component.\n */\nfunction getDataParentComponent(componentInstance) {\n if (!componentInstance) {\n return;\n }\n const { parent } = componentInstance;\n if (parent && (parent.isInputComponent || parent.input)) {\n return parent;\n }\n else {\n return getDataParentComponent(parent);\n }\n}\n/**\n * Returns whether the value is a promise\n * @param {any} value - The value to check\n * @returns {boolean} - TRUE if the value is a promise; FALSE otherwise\n */\nfunction isPromise(value) {\n return value\n && value.then\n && typeof value.then === 'function'\n && Object.prototype.toString.call(value) === '[object Promise]';\n}\n/**\n * Determines if the component has a scoping parent in tree (a component which scopes its children and manages its\n * changes by itself, e.g. EditGrid)\n * @param {Component} componentInstance - The component to check for the scoping parent.\n * @param {boolean} firstPass - Whether it is the first pass of the function\n * @returns {boolean|*} - TRUE if the component has a scoping parent; FALSE otherwise\n */\nfunction isInsideScopingComponent(componentInstance, firstPass = true) {\n if (!firstPass && (componentInstance === null || componentInstance === void 0 ? void 0 : componentInstance.hasScopedChildren)) {\n return true;\n }\n const dataParent = getDataParentComponent(componentInstance);\n if (dataParent === null || dataParent === void 0 ? void 0 : dataParent.hasScopedChildren) {\n return true;\n }\n else if (dataParent === null || dataParent === void 0 ? void 0 : dataParent.parent) {\n return isInsideScopingComponent(dataParent.parent, false);\n }\n return false;\n}\n/**\n * Returns all the focusable elements within the provided dom element.\n * @param {HTMLElement} element - The element to get the focusable elements from.\n * @returns {NodeList<HTMLElement>} - The focusable elements within the provided element.\n */\nfunction getFocusableElements(element) {\n const focusableSelector = `button:not([disabled]), input:not([disabled]), select:not([disabled]),\n textarea:not([disabled]), button:not([disabled]), [href]`;\n return element.querySelectorAll(focusableSelector);\n}\nexports.componentValueTypes = {\n number: 'number',\n string: 'string',\n boolean: 'boolean',\n array: 'array',\n object: 'object',\n date: 'date',\n any: 'any',\n};\n/**\n * Returns the saved types for the component\n * @param {import('@formio/core').Component} fullSchema - The component schema\n * @returns {Array<string>|null} - The saved types for the component\n */\nfunction getComponentSavedTypes(fullSchema) {\n const schema = fullSchema || {};\n if (schema.persistent !== true) {\n return [];\n }\n if (schema.multiple) {\n return [exports.componentValueTypes.array];\n }\n return null;\n}\n/**\n * Interpolates @formio/core errors so that they are compatible with the renderer\n * @param {Component} component - The component to interpolate the errors for\n * @param {FieldError[]} errors - The errors to interpolate\n * @param {Function} interpolateFn - The interpolation function\n * @returns {[]} - The interpolated errors\n */\nconst interpolateErrors = (component, errors, interpolateFn) => {\n return errors.map((error) => {\n error.component = component;\n const { errorKeyOrMessage, context } = error;\n const toInterpolate = component.errors && component.errors[errorKeyOrMessage] ? component.errors[errorKeyOrMessage] : errorKeyOrMessage;\n return Object.assign(Object.assign({}, error), { message: unescapeHTML(interpolateFn(toInterpolate, context)), context: Object.assign({}, context) });\n });\n};\nexports.interpolateErrors = interpolateErrors;\n/**\n * Returns the template keys inside the template code.\n * @param {string} template - The template to get the keys from.\n * @returns {Array<string>} - The keys inside the template.\n */\nfunction getItemTemplateKeys(template) {\n const templateKeys = [];\n if (!template) {\n return templateKeys;\n }\n const keys = template.match(/({{\\s*(.*?)\\s*}})/g);\n if (keys) {\n keys.forEach((key) => {\n const propKey = key.match(/{{\\s*item\\.(.*?)\\s*}}/);\n if (propKey && propKey.length > 1) {\n templateKeys.push(propKey[1]);\n }\n });\n }\n return templateKeys;\n}\n/**\n * Returns if the component is a select resource with an object for its value.\n * @param {import('@formio/core').Component} comp - The component to check.\n * @returns {boolean} - TRUE if the component is a select resource with an object for its value; FALSE otherwise.\n */\nfunction isSelectResourceWithObjectValue(comp = {}) {\n const { reference, dataSrc, valueProperty } = comp;\n return reference || (dataSrc === 'resource' && (!valueProperty || valueProperty === 'data'));\n}\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/utils/utils.js?");
|
8089
|
+
eval("\n/* global jQuery */\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __exportStar = (this && this.__exportStar) || function(m, exports) {\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);\n};\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.firstNonNil = exports.unfold = exports.bootstrapVersion = exports.uniqueKey = exports.iterateKey = exports.delay = exports.fieldData = exports.getCurrencyAffixes = exports.getNumberDecimalLimit = exports.getNumberSeparators = exports.matchInputMask = exports.unmaskValue = exports.getInputMask = exports.convertFormatToMask = exports.convertFormatToMoment = exports.convertFormatToFlatpickr = exports.getLocaleDateFormatInfo = exports.formatOffset = exports.formatDate = exports.momentDate = exports.loadZones = exports.shouldLoadZones = exports.zonesLoaded = exports.offsetDate = exports.currentTimezone = exports.isValidDate = exports.getDateSetting = exports.guid = exports.uniqueName = exports.convertStringToHTMLElement = exports.unescapeHTML = exports.removeHTML = exports.setActionProperty = exports.checkTrigger = exports.checkCondition = exports.checkJsonConditional = exports.checkCustomConditional = exports.getComponentActualValue = exports.checkSimpleConditional = exports.checkCalculated = exports.isMongoId = exports.boolValue = exports.getScriptPlugin = exports.getElementRect = exports.getPropertyValue = exports.getRandomComponentId = exports.evaluate = exports.moment = exports.ConditionOperators = exports.jsonLogic = void 0;\nexports.isSelectResourceWithObjectValue = exports.getItemTemplateKeys = exports.interpolateErrors = exports.getComponentSavedTypes = exports.componentValueTypes = exports._ = exports.getFocusableElements = exports.isInsideScopingComponent = exports.isPromise = exports.getDataParentComponent = exports.getComponentPath = exports.getComponentPathWithoutIndicies = exports.getBrowserInfo = exports.getIEBrowserVersion = exports.round = exports.getStringFromComponentPath = exports.isChildOf = exports.getArrayFromComponentPath = exports.isInputComponent = exports.interpolate = exports.Evaluator = exports.fastCloneDeep = exports.sanitize = exports.translateHTMLTemplate = exports.getContextButtons = exports.getContextComponents = exports.observeOverload = exports.withSwitch = void 0;\nconst lodash_1 = __importDefault(__webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\"));\nexports._ = lodash_1.default;\nconst fetch_ponyfill_1 = __importDefault(__webpack_require__(/*! fetch-ponyfill */ \"./node_modules/fetch-ponyfill/build/fetch-browser.js\"));\nconst json_logic_js_1 = __importDefault(__webpack_require__(/*! json-logic-js */ \"./node_modules/json-logic-js/logic.js\"));\nexports.jsonLogic = json_logic_js_1.default;\nconst moment_timezone_1 = __importDefault(__webpack_require__(/*! moment-timezone/moment-timezone */ \"./node_modules/moment-timezone/moment-timezone.js\"));\nconst jstimezonedetect_1 = __importDefault(__webpack_require__(/*! jstimezonedetect */ \"./node_modules/jstimezonedetect/dist/jstz.min.js\"));\nconst operators_1 = __webpack_require__(/*! ./jsonlogic/operators */ \"./lib/cjs/utils/jsonlogic/operators.js\");\nconst dompurify_1 = __importDefault(__webpack_require__(/*! dompurify */ \"./node_modules/dompurify/dist/purify.js\"));\nconst formUtils_1 = __webpack_require__(/*! ./formUtils */ \"./lib/cjs/utils/formUtils.js\");\nconst Evaluator_1 = __webpack_require__(/*! ./Evaluator */ \"./lib/cjs/utils/Evaluator.js\");\nObject.defineProperty(exports, \"Evaluator\", ({ enumerable: true, get: function () { return Evaluator_1.Evaluator; } }));\nconst conditionOperators_1 = __importDefault(__webpack_require__(/*! ./conditionOperators */ \"./lib/cjs/utils/conditionOperators/index.js\"));\nexports.ConditionOperators = conditionOperators_1.default;\nconst interpolate = Evaluator_1.Evaluator.interpolate;\nexports.interpolate = interpolate;\nconst { fetch } = (0, fetch_ponyfill_1.default)({\n Promise: Promise\n});\n__exportStar(__webpack_require__(/*! ./formUtils */ \"./lib/cjs/utils/formUtils.js\"), exports);\n// Configure JsonLogic\noperators_1.lodashOperators.forEach((name) => json_logic_js_1.default.add_operation(`_${name}`, lodash_1.default[name]));\n// Retrieve Any Date\njson_logic_js_1.default.add_operation('getDate', (date) => {\n return (0, moment_timezone_1.default)(date).toISOString();\n});\n// Set Relative Minimum Date\njson_logic_js_1.default.add_operation('relativeMinDate', (relativeMinDate) => {\n return (0, moment_timezone_1.default)().subtract(relativeMinDate, 'days').toISOString();\n});\n// Set Relative Maximum Date\njson_logic_js_1.default.add_operation('relativeMaxDate', (relativeMaxDate) => {\n return (0, moment_timezone_1.default)().add(relativeMaxDate, 'days').toISOString();\n});\nexports.moment = __importStar(__webpack_require__(/*! moment-timezone/moment-timezone */ \"./node_modules/moment-timezone/moment-timezone.js\"));\n/**\n * Sets the path to the component and parent schema.\n * @param {import('@formio/core').Component} component - The component to set the path for.\n */\nfunction setPathToComponentAndPerentSchema(component) {\n component.path = getComponentPath(component);\n const dataParent = getDataParentComponent(component);\n if (dataParent && typeof dataParent === 'object') {\n dataParent.path = getComponentPath(dataParent);\n }\n}\n/**\n * Evaluate a method.\n * @param {Function|string|object} func - The function to evaluate.\n * @param {*} args - A map of arguments to pass to the function.\n * @param {string} ret - The name of the \"return\" variable in the script.\n * @param {boolean} interpolate - True if the script should be interpolated before being executed.\n * @param {import('@formio/core').EvaluatorOptions} options - The evaluator options.\n * @returns {*} - The result of the evaluation.\n */\nfunction evaluate(func, args, ret, interpolate, options = {}) {\n return Evaluator_1.Evaluator.evaluate(func, args, ret, interpolate, undefined, options);\n}\nexports.evaluate = evaluate;\n/**\n * Returns a random compoennt ID.\n * @returns {string} - A random component ID.\n */\nfunction getRandomComponentId() {\n return `e${Math.random().toString(36).substring(7)}`;\n}\nexports.getRandomComponentId = getRandomComponentId;\n/**\n * Get a property value of an element.\n * @param {CSSStyleDeclaration} style - The style element to get the property value from.\n * @param {string} prop - The property to get the value for.\n * @returns {number} - The value of the property.\n */\nfunction getPropertyValue(style, prop) {\n let value = style.getPropertyValue(prop);\n value = value ? value.replace(/[^0-9.]/g, '') : '0';\n return parseFloat(value);\n}\nexports.getPropertyValue = getPropertyValue;\n/**\n * Get an elements bounding rectagle.\n * @param {HTMLElement} element - A DOM element to get the bounding rectangle for.\n * @returns {{x: number, y: number, width: number, height: number}} - The bounding rectangle.\n */\nfunction getElementRect(element) {\n const style = window.getComputedStyle(element, null);\n return {\n x: getPropertyValue(style, 'left'),\n y: getPropertyValue(style, 'top'),\n width: getPropertyValue(style, 'width'),\n height: getPropertyValue(style, 'height')\n };\n}\nexports.getElementRect = getElementRect;\n/**\n * Get non HTMLElement property in the window object\n * @param {string} property - The window property to fetch the script plugin from.\n * @returns {any | undefined} - The HTML Element property on the window object.\n */\nfunction getScriptPlugin(property) {\n const obj = window[property];\n if (typeof HTMLElement === 'object' ? obj instanceof HTMLElement : //DOM2\n obj && typeof obj === 'object' && true && obj.nodeType === 1 && typeof obj.nodeName === 'string') {\n return undefined;\n }\n return obj;\n}\nexports.getScriptPlugin = getScriptPlugin;\n/**\n * Determines the boolean value of a setting.\n * @param {string|boolean} value - A string or boolean value to convert to boolean.\n * @returns {boolean} - The boolean value of the setting.\n */\nfunction boolValue(value) {\n if (lodash_1.default.isBoolean(value)) {\n return value;\n }\n else if (lodash_1.default.isString(value)) {\n return (value.toLowerCase() === 'true');\n }\n else {\n return !!value;\n }\n}\nexports.boolValue = boolValue;\n/**\n * Check to see if an ID is a mongoID.\n * @param {string} text - The text to check if it is a mongoID.\n * @returns {boolean} - TRUE if the text is a mongoID; FALSE otherwise.\n */\nfunction isMongoId(text) {\n return !!text.toString().match(/^[0-9a-fA-F]{24}$/);\n}\nexports.isMongoId = isMongoId;\n/**\n * Checks the calculated value for a provided component and data.\n * @param {import('@formio/core').Component} component - The component to check for the calculated value.\n * @param {import('@formio/core').Submission} submission - A submission object.\n * @param {*} rowData - The contextual row data for the component.\n */\nfunction checkCalculated(component, submission, rowData) {\n // Process calculated value stuff if present.\n if (component.calculateValue) {\n lodash_1.default.set(rowData, component.key, evaluate(component.calculateValue, {\n value: undefined,\n data: submission ? submission.data : rowData,\n row: rowData,\n util: this,\n component\n }, 'value'));\n }\n}\nexports.checkCalculated = checkCalculated;\n/**\n * Check if a simple conditional evaluates to true.\n * @param {import('@formio/core').Component} component - The component to check for the conditional.\n * @param {import('@formio/core').SimpleConditional} condition - The condition to check.\n * @param {*} row - The row data for the component.\n * @param {*} data - The full submission data.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The instance of the component.\n * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.\n */\nfunction checkSimpleConditional(component, condition, row, data, instance) {\n if (condition.when) {\n const value = getComponentActualValue(condition.when, data, row);\n const eq = String(condition.eq);\n const show = String(condition.show);\n // Special check for selectboxes component.\n if (lodash_1.default.isObject(value) && lodash_1.default.has(value, condition.eq)) {\n return String(value[condition.eq]) === show;\n }\n // FOR-179 - Check for multiple values.\n if (Array.isArray(value) && value.map(String).includes(eq)) {\n return show === 'true';\n }\n return (String(value) === eq) === (show === 'true');\n }\n else {\n const { conditions = [], conjunction = 'all', show = true } = condition;\n if (!conditions.length) {\n return true;\n }\n const conditionsResult = lodash_1.default.map(conditions, (cond) => {\n const { value: comparedValue, operator, component: conditionComponentPath } = cond;\n if (!conditionComponentPath) {\n return true;\n }\n const value = getComponentActualValue(conditionComponentPath, data, row);\n const ConditionOperator = conditionOperators_1.default[operator];\n return ConditionOperator\n ? new ConditionOperator().getResult({ value, comparedValue, instance, component, conditionComponentPath })\n : true;\n });\n let result = false;\n switch (conjunction) {\n case 'any':\n result = lodash_1.default.some(conditionsResult, res => !!res);\n break;\n default:\n result = lodash_1.default.every(conditionsResult, res => !!res);\n }\n return show ? result : !result;\n }\n}\nexports.checkSimpleConditional = checkSimpleConditional;\n/**\n * Returns a components normalized value.\n * @param {string} compPath - The full path to the component.\n * @param {*} data - The data object to get the value from.\n * @param {*} row - The contextual row data for the component.\n * @returns {*} - The normalized value of the component.\n */\nfunction getComponentActualValue(compPath, data, row) {\n let value = null;\n if (row) {\n value = (0, formUtils_1.getValue)({ data: row }, compPath);\n }\n if (data && lodash_1.default.isNil(value)) {\n value = (0, formUtils_1.getValue)({ data }, compPath);\n }\n // FOR-400 - Fix issue where falsey values were being evaluated as show=true\n if (lodash_1.default.isNil(value) || (lodash_1.default.isObject(value) && lodash_1.default.isEmpty(value))) {\n value = '';\n }\n return value;\n}\nexports.getComponentActualValue = getComponentActualValue;\n/**\n * Check custom javascript conditional.\n * @param {import('@formio/core').Component} component - The component to check for the conditional.\n * @param {string} custom - The custom conditional string to evaluate.\n * @param {*} row - The row data for the component.\n * @param {*} data - The full submission data.\n * @param {import('@formio/core').Form} form - The form object.\n * @param {string} variable - The variable name for the result of the custom conditional.\n * @param {*} onError - A custom return if there is an error or the value is null from the evaluation.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.\n * @returns {*} - The result of the evaulation.\n */\nfunction checkCustomConditional(component, custom, row, data, form, variable, onError, instance) {\n if (typeof custom === 'string') {\n custom = `var ${variable} = true; ${custom}; return ${variable};`;\n }\n const value = (instance && instance.evaluate) ?\n instance.evaluate(custom, { row, data, form }) :\n evaluate(custom, { row, data, form });\n if (value === null) {\n return onError;\n }\n return value;\n}\nexports.checkCustomConditional = checkCustomConditional;\n/**\n * Check a component for JSON conditionals.\n * @param {import('@formio/core').Component} component - The component\n * @param {import('@formio/core').JSONConditional} json - The json conditional to check.\n * @param {*} row - The contextual row data for the component.\n * @param {*} data - The full submission data.\n * @param {import('@formio/core').Form} form - The Form JSON of the form.\n * @param {*} onError - Custom return value if there is an error.\n * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.\n */\nfunction checkJsonConditional(component, json, row, data, form, onError) {\n try {\n return json_logic_js_1.default.apply(json, {\n data,\n row,\n form,\n _: lodash_1.default,\n });\n }\n catch (err) {\n console.warn(`An error occurred in jsonLogic advanced condition for ${component.key}`, err);\n return onError;\n }\n}\nexports.checkJsonConditional = checkJsonConditional;\n/**\n * Returns the contextual row data for a component.\n * @param {import('@formio/core').Component} component - The component to get the row data for.\n * @param {*} row - The row data for the component.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.\n * @param {*} conditional - The component conditional.\n * @returns {*} - The contextual row data for the component.\n */\nfunction getRow(component, row, instance, conditional) {\n var _a;\n const condition = conditional || component.conditional;\n // If no component's instance passed (happens only in 6.x server), calculate its path based on the schema\n if (!instance) {\n instance = lodash_1.default.cloneDeep(component);\n setPathToComponentAndPerentSchema(instance);\n }\n const dataParent = getDataParentComponent(instance);\n const parentPath = dataParent ? getComponentPath(dataParent) : null;\n const isTriggerCondtionComponentPath = condition.when || !condition.conditions\n ? (_a = condition.when) === null || _a === void 0 ? void 0 : _a.startsWith(parentPath)\n : lodash_1.default.some(condition.conditions, cond => cond.component.startsWith(parentPath));\n if (dataParent && isTriggerCondtionComponentPath) {\n const newRow = {};\n lodash_1.default.set(newRow, parentPath, row);\n row = newRow;\n }\n return row;\n}\n/**\n * Checks the conditions for a provided component and data.\n * @param {import('@formio/core').Component} component - The component to check for the condition.\n * @param {*} row - The data within a row\n * @param {*} data - The full submission data.\n * @param {import('@formio/core').Form} form - The form object.\n * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.\n * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.\n */\nfunction checkCondition(component, row, data, form, instance) {\n const { customConditional, conditional } = component;\n if (customConditional) {\n return checkCustomConditional(component, customConditional, row, data, form, 'show', true, instance);\n }\n else if (conditional && (conditional.when || lodash_1.default.some(conditional.conditions || [], condition => condition.component && condition.operator))) {\n row = getRow(component, row, instance);\n return checkSimpleConditional(component, conditional, row, data, instance);\n }\n else if (conditional && conditional.json) {\n return checkJsonConditional(component, conditional.json, row, data, form, true);\n }\n // Default to show.\n return true;\n}\nexports.checkCondition = checkCondition;\n/**\n * Test a trigger on a component.\n * @param {import('@formio/core').Component} component - The component to test the trigger against.\n * @param {import('@formio/core').LogicTrigger} trigger - The trigger configuration.\n * @param {import('@formio/core').DataObject} row - The contextual row data.\n * @param {import('@formio/core').DataObject} data - The root data object.\n * @param {import('@formio/core').Form} form - The form object.\n * @param {any} instance - The component that is performing the trigger.\n * @returns {boolean} - TRUE if the trigger should fire; FALSE otherwise.\n */\nfunction checkTrigger(component, trigger, row, data, form, instance) {\n // If trigger is empty, don't fire it\n if (!trigger || !trigger[trigger.type]) {\n return false;\n }\n switch (trigger.type) {\n case 'simple':\n row = getRow(component, row, instance, trigger.simple);\n return checkSimpleConditional(component, trigger.simple, row, data, instance);\n case 'javascript':\n return checkCustomConditional(component, trigger.javascript, row, data, form, 'result', false, instance);\n case 'json':\n return checkJsonConditional(component, trigger.json, row, data, form, false);\n }\n // If none of the types matched, don't fire the trigger.\n return false;\n}\nexports.checkTrigger = checkTrigger;\n/**\n * Sets a property on a component via an executed Logic action.\n * @param {import('@formio/core').Component} component - The component to set the property on.\n * @param {import('@formio/core').LogicAction} action - The action to perform on the component.\n * @param {string} result - The name of the variable in the evaulation to use as the result.\n * @param {import('@formio/core').DataObject} row - The contextual row data.\n * @param {import('@formio/core').DataObject} data - The full submission data.\n * @param {any} instance - The component instance.\n * @returns {import('@formio/core').Component} - The modified component.\n */\nfunction setActionProperty(component, action, result, row, data, instance) {\n const property = action.property.value;\n switch (action.property.type) {\n case 'boolean': {\n const currentValue = lodash_1.default.get(component, property, false).toString();\n const newValue = action.state.toString();\n if (currentValue !== newValue) {\n lodash_1.default.set(component, property, newValue === 'true');\n }\n break;\n }\n case 'string': {\n const evalData = {\n data,\n row,\n component,\n result,\n };\n const textValue = action.property.component ? action[action.property.component] : action.text;\n const currentValue = lodash_1.default.get(component, property, '');\n const newValue = (instance && instance.interpolate)\n ? instance.interpolate(textValue, evalData)\n : Evaluator_1.Evaluator.interpolate(textValue, evalData);\n if (newValue !== currentValue) {\n lodash_1.default.set(component, property, newValue);\n }\n break;\n }\n }\n return component;\n}\nexports.setActionProperty = setActionProperty;\n/**\n * Removes HTML tags from string e.g. <div>Hello World</div> => Hello World\n * @param {string} str - The string to remove HTML tags from.\n * @returns {string} - The string without HTML tags.\n */\nfunction removeHTML(str) {\n const doc = new window.DOMParser().parseFromString(str, 'text/html');\n return (doc.body.textContent || '').trim();\n}\nexports.removeHTML = removeHTML;\n/**\n * Unescape HTML characters like <, >, & and etc.\n * @param {string} str - The string to unescape.\n * @returns {string} - The unescaped string.\n */\nfunction unescapeHTML(str) {\n if (typeof window === 'undefined' || !('DOMParser' in window)) {\n return str;\n }\n const elem = document.createElement('textarea');\n elem.innerHTML = str;\n return elem.value;\n}\nexports.unescapeHTML = unescapeHTML;\n/**\n * Make HTML element from string\n * @param {string} str - The string to convert to an HTML element.\n * @param {string} selector - The selector to use to get the element once it is created.\n * @returns {HTMLElement} - The HTML element that was created.\n */\nfunction convertStringToHTMLElement(str, selector) {\n const doc = new window.DOMParser().parseFromString(str, 'text/html');\n return doc.body.querySelector(selector);\n}\nexports.convertStringToHTMLElement = convertStringToHTMLElement;\n/**\n * Make a filename guaranteed to be unique.\n * @param {string} name - The original name of the file.\n * @param {string} template - The template to use for the unique name.\n * @param {object} evalContext - The context to use for the evaluation.\n * @returns {string} - A unique filename.\n */\nfunction uniqueName(name, template, evalContext) {\n template = template || '{{fileName}}-{{guid}}';\n //include guid in template anyway, to prevent overwriting issue if filename matches existing file\n if (!template.includes('{{guid}}')) {\n template = `${template}-{{guid}}`;\n }\n const parts = name.split('.');\n let fileName = parts.slice(0, parts.length - 1).join('.');\n const extension = parts.length > 1\n ? `.${lodash_1.default.last(parts)}`\n : '';\n //allow only 100 characters from original name to avoid issues with filename length restrictions\n fileName = fileName.substr(0, 100);\n evalContext = Object.assign(evalContext || {}, {\n fileName,\n guid: guid()\n });\n //only letters, numbers, dots, dashes, underscores and spaces are allowed. Anything else will be replaced with dash\n const uniqueName = `${Evaluator_1.Evaluator.interpolate(template, evalContext)}${extension}`.replace(/[^0-9a-zA-Z.\\-_ ]/g, '-');\n return uniqueName;\n}\nexports.uniqueName = uniqueName;\n/**\n * Returns a GUID\n * @returns {string} - A GUID.\n */\nfunction guid() {\n return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {\n const r = Math.random() * 16 | 0;\n const v = c === 'x'\n ? r\n : (r & 0x3 | 0x8);\n return v.toString(16);\n });\n}\nexports.guid = guid;\n/**\n * Return a translated date setting.\n * @param {string|Date} date - The date to translate.\n * @returns {(null|Date)} - The translated date.\n */\nfunction getDateSetting(date) {\n if (lodash_1.default.isNil(date) || lodash_1.default.isNaN(date) || date === '') {\n return null;\n }\n if (date instanceof Date) {\n return date;\n }\n else if (typeof date.toDate === 'function') {\n return date.isValid() ? date.toDate() : null;\n }\n let dateSetting = ((typeof date !== 'string') || (date.indexOf('moment(') === -1)) ? (0, moment_timezone_1.default)(date) : null;\n if (dateSetting && dateSetting.isValid()) {\n return dateSetting.toDate();\n }\n dateSetting = null;\n try {\n const value = Evaluator_1.Evaluator.evaluator(`return ${date};`, 'moment')(moment_timezone_1.default);\n if (typeof value === 'string') {\n dateSetting = (0, moment_timezone_1.default)(value);\n }\n else if (typeof value.toDate === 'function') {\n dateSetting = (0, moment_timezone_1.default)(value.toDate().toUTCString());\n }\n else if (value instanceof Date) {\n dateSetting = (0, moment_timezone_1.default)(value);\n }\n }\n catch (e) {\n return null;\n }\n if (!dateSetting) {\n return null;\n }\n // Ensure this is a date.\n if (!dateSetting.isValid()) {\n return null;\n }\n return dateSetting.toDate();\n}\nexports.getDateSetting = getDateSetting;\n/**\n * Returns true if the date is a valid date. False otherwise.\n * @param {Date|string} date - The date to check for validity.\n * @returns {boolean} - TRUE if the date is valid; FALSE otherwise.\n */\nfunction isValidDate(date) {\n return lodash_1.default.isDate(date) && !lodash_1.default.isNaN(date.getDate());\n}\nexports.isValidDate = isValidDate;\n/**\n * Get the current timezone string.\n * @returns {string} - The current timezone.\n */\nfunction currentTimezone() {\n if (moment_timezone_1.default.currentTimezone) {\n return moment_timezone_1.default.currentTimezone;\n }\n moment_timezone_1.default.currentTimezone = jstimezonedetect_1.default.determine().name();\n return moment_timezone_1.default.currentTimezone;\n}\nexports.currentTimezone = currentTimezone;\n/**\n * Get an offset date provided a date object and timezone object.\n * @param {Date} date - The date to offset.\n * @param {string} timezone - The timezone to offset the date to.\n * @returns {Date} - The offset date.\n */\nfunction offsetDate(date, timezone) {\n if (timezone === 'UTC') {\n return {\n date: new Date(date.getTime() + (date.getTimezoneOffset() * 60000)),\n abbr: 'UTC'\n };\n }\n const dateMoment = (0, moment_timezone_1.default)(date).tz(timezone);\n return {\n date: new Date(date.getTime() + ((dateMoment.utcOffset() + date.getTimezoneOffset()) * 60000)),\n abbr: dateMoment.format('z')\n };\n}\nexports.offsetDate = offsetDate;\n/**\n * Returns if the zones are loaded.\n * @returns {boolean} - TRUE if the zones are loaded; FALSE otherwise.\n */\nfunction zonesLoaded() {\n return moment_timezone_1.default.zonesLoaded;\n}\nexports.zonesLoaded = zonesLoaded;\n/**\n * Returns if we should load the zones.\n * @param {string} timezone - The timezone to check if we should load the zones.\n * @returns {boolean} - TRUE if we should load the zones; FALSE otherwise.\n */\nfunction shouldLoadZones(timezone) {\n if (timezone === currentTimezone() || timezone === 'UTC') {\n return false;\n }\n return true;\n}\nexports.shouldLoadZones = shouldLoadZones;\n/**\n * Externally load the timezone data.\n * @param {string} url - The URL to load the timezone data from.\n * @param {string} timezone - The timezone to load.\n * @returns {Promise<any> | *} - Resolves when the zones for this timezone are loaded.\n */\nfunction loadZones(url, timezone) {\n if (timezone && !shouldLoadZones(timezone)) {\n // Return non-resolving promise.\n return new Promise(lodash_1.default.noop);\n }\n if (moment_timezone_1.default.zonesPromise) {\n return moment_timezone_1.default.zonesPromise;\n }\n return moment_timezone_1.default.zonesPromise = fetch(url)\n .then(resp => resp.json().then(zones => {\n moment_timezone_1.default.tz.load(zones);\n moment_timezone_1.default.zonesLoaded = true;\n // Trigger a global event that the timezones have finished loading.\n if (document && document.createEvent && document.body && document.body.dispatchEvent) {\n var event = document.createEvent('Event');\n event.initEvent('zonesLoaded', true, true);\n document.body.dispatchEvent(event);\n }\n }));\n}\nexports.loadZones = loadZones;\n/**\n * Get the moment date object for translating dates with timezones.\n * @param {string|Date} value - The value to convert into a moment date.\n * @param {string} format - The format to convert the date to.\n * @param {string} timezone - The timezone to convert the date to.\n * @returns {Date} - The moment date object.\n */\nfunction momentDate(value, format, timezone) {\n const momentDate = (0, moment_timezone_1.default)(value);\n if (!timezone) {\n return momentDate;\n }\n if (timezone === 'UTC') {\n timezone = 'Etc/UTC';\n }\n if ((timezone !== currentTimezone() || (format && format.match(/\\s(z$|z\\s)/))) && moment_timezone_1.default.zonesLoaded) {\n return momentDate.tz(timezone);\n }\n return momentDate;\n}\nexports.momentDate = momentDate;\n/**\n * Format a date provided a value, format, and timezone object.\n * @param {string} timezonesUrl - The URL to load the timezone data from.\n * @param {string|Date} value - The value to format.\n * @param {string} format - The format to format the date to.\n * @param {string} timezone - The timezone to format the date to.\n * @param {string} flatPickrInputFormat - The format to use for flatpickr input.\n * @returns {string} - The formatted date.\n */\nfunction formatDate(timezonesUrl, value, format, timezone, flatPickrInputFormat) {\n const momentDate = (0, moment_timezone_1.default)(value, flatPickrInputFormat || undefined);\n if (timezone === currentTimezone()) {\n // See if our format contains a \"z\" timezone character.\n if (format.match(/\\s(z$|z\\s)/)) {\n loadZones(timezonesUrl);\n if (moment_timezone_1.default.zonesLoaded) {\n return momentDate.tz(timezone).format(convertFormatToMoment(format));\n }\n else {\n return momentDate.format(convertFormatToMoment(format.replace(/\\s(z$|z\\s)/, '')));\n }\n }\n // Return the standard format.\n return momentDate.format(convertFormatToMoment(format));\n }\n if (timezone === 'UTC') {\n const offset = offsetDate(momentDate.toDate(), 'UTC');\n return `${(0, moment_timezone_1.default)(offset.date).format(convertFormatToMoment(format))} UTC`;\n }\n // Load the zones since we need timezone information.\n loadZones(timezonesUrl);\n if (moment_timezone_1.default.zonesLoaded && timezone) {\n return momentDate.tz(timezone).format(`${convertFormatToMoment(format)} z`);\n }\n else {\n return momentDate.format(convertFormatToMoment(format));\n }\n}\nexports.formatDate = formatDate;\n/**\n * Pass a format function to format within a timezone.\n * @param {string} timezonesUrl - The URL to load the timezone data from.\n * @param {Function} formatFn - The format function to use.\n * @param {Date|string} date - The date to format.\n * @param {string} format - The format to format the date to.\n * @param {string} timezone - The timezone to format the date to.\n * @returns {string} - The formatted date.\n */\nfunction formatOffset(timezonesUrl, formatFn, date, format, timezone) {\n if (timezone === currentTimezone()) {\n return formatFn(date, format);\n }\n if (timezone === 'UTC') {\n return `${formatFn(offsetDate(date, 'UTC').date, format)} UTC`;\n }\n // Load the zones since we need timezone information.\n loadZones(timezonesUrl);\n if (moment_timezone_1.default.zonesLoaded) {\n const offset = offsetDate(date, timezone);\n return `${formatFn(offset.date, format)} ${offset.abbr}`;\n }\n else {\n return formatFn(date, format);\n }\n}\nexports.formatOffset = formatOffset;\n/**\n * Returns the local date format information.\n * @param {Intl.LocalesArgument} locale - The locale to get the date format for.\n * @returns {object} - The local date format information.\n */\nfunction getLocaleDateFormatInfo(locale) {\n const formatInfo = {};\n const day = 21;\n const exampleDate = new Date(2017, 11, day);\n const localDateString = exampleDate.toLocaleDateString(locale);\n formatInfo.dayFirst = localDateString.slice(0, 2) === day.toString();\n return formatInfo;\n}\nexports.getLocaleDateFormatInfo = getLocaleDateFormatInfo;\n/**\n * Convert the format from the angular-datepicker module to flatpickr format.\n * @param {string} format - The format to convert.\n * @returns {string} - The converted format.\n */\nfunction convertFormatToFlatpickr(format) {\n return format\n // Remove the Z timezone offset, not supported by flatpickr.\n .replace(/Z/g, '')\n // Year conversion.\n .replace(/y/g, 'Y')\n .replace('YYYY', 'Y')\n .replace('YY', 'y')\n // Month conversion.\n .replace('MMMM', 'F')\n .replace(/M/g, 'n')\n .replace('nnn', 'M')\n .replace('nn', 'm')\n // Day in month.\n .replace(/d/g, 'j')\n .replace(/jj/g, 'd')\n // Day in week.\n .replace('EEEE', 'l')\n .replace('EEE', 'D')\n // Hours, minutes, seconds\n .replace('HH', 'H')\n .replace('hh', 'G')\n .replace('mm', 'i')\n .replace('ss', 'S')\n .replace(/a/g, 'K');\n}\nexports.convertFormatToFlatpickr = convertFormatToFlatpickr;\n/**\n * Convert the format from the angular-datepicker module to moment format.\n * @param {string} format - The format to convert.\n * @returns {string} - The converted format.\n */\nfunction convertFormatToMoment(format) {\n return format\n // Year conversion.\n .replace(/y/g, 'Y')\n // Day in month.\n .replace(/d/g, 'D')\n // Day in week.\n .replace(/E/g, 'd')\n // AM/PM marker\n .replace(/a/g, 'A')\n // Unix Timestamp\n .replace(/U/g, 'X');\n}\nexports.convertFormatToMoment = convertFormatToMoment;\n/**\n * Convert the format from the angular-datepicker module to mask format.\n * @param {string} format - The format to convert.\n * @returns {string} - The converted format.\n */\nfunction convertFormatToMask(format) {\n return format\n // Long month replacement.\n .replace(/M{4}/g, 'MM')\n // Initial short month conversion.\n .replace(/M{3}/g, '***')\n // Short month conversion if input as text.\n .replace(/e/g, 'Q')\n // Month number conversion.\n .replace(/W/g, '99')\n // Year conversion.\n .replace(/[ydhmswHMG]/g, '9')\n // AM/PM conversion.\n .replace(/a/g, 'AA');\n}\nexports.convertFormatToMask = convertFormatToMask;\n/**\n * Returns an input mask that is compatible with the input mask library.\n * @param {string} mask - The Form.io input mask.\n * @param {string} placeholderChar - Char which is used as a placeholder.\n * @returns {Array} - The input mask for the mask library.\n */\nfunction getInputMask(mask, placeholderChar) {\n if (mask instanceof Array) {\n return mask;\n }\n const maskArray = [];\n maskArray.numeric = true;\n for (let i = 0; i < mask.length; i++) {\n switch (mask[i]) {\n case '9':\n maskArray.push(/\\d/);\n break;\n case 'A':\n maskArray.numeric = false;\n maskArray.push(/[a-zA-Z]/);\n break;\n case 'a':\n maskArray.numeric = false;\n maskArray.push(/[a-z]/);\n break;\n case '*':\n maskArray.numeric = false;\n maskArray.push(/[a-zA-Z0-9]/);\n break;\n // If char which is used inside mask placeholder was used in the mask, replace it with space to prevent errors\n case placeholderChar:\n maskArray.numeric = false;\n maskArray.push(' ');\n break;\n default:\n maskArray.numeric = false;\n maskArray.push(mask[i]);\n break;\n }\n }\n return maskArray;\n}\nexports.getInputMask = getInputMask;\n/**\n * Unmasks a value using the provided mask and placeholder characters.\n * @param {string} value - The value to unmask.\n * @param {string} mask - The mask to use for unmasking.\n * @param {string} placeholderChar - The placeholder character to use for unmasking.\n * @returns {string} - The unmasked value.\n */\nfunction unmaskValue(value, mask, placeholderChar) {\n if (!mask || !value || value.length > mask.length) {\n return value;\n }\n let unmaskedValue = value.split('');\n for (let i = 0; i < mask.length; i++) {\n const char = value[i] || '';\n const charPart = mask[i];\n if (!lodash_1.default.isRegExp(charPart) && char === charPart) {\n unmaskedValue[i] = '';\n }\n }\n unmaskedValue = unmaskedValue.join('').replace(placeholderChar, '');\n return unmaskedValue;\n}\nexports.unmaskValue = unmaskValue;\n/**\n * Returns true if the value matches the input mask format.\n * @param {string} value - The value to check.\n * @param {string} inputMask - The input mask to check against.\n * @returns {boolean} - TRUE if the value matches the input mask; FALSE otherwise.\n */\nfunction matchInputMask(value, inputMask) {\n if (!inputMask) {\n return true;\n }\n // If value is longer than mask, it isn't valid.\n if (value.length > inputMask.length) {\n return false;\n }\n for (let i = 0; i < inputMask.length; i++) {\n const char = value[i] || '';\n const charPart = inputMask[i];\n if (!(lodash_1.default.isRegExp(charPart) && charPart.test(char) || charPart === char)) {\n return false;\n }\n }\n return true;\n}\nexports.matchInputMask = matchInputMask;\n/**\n * Returns the number separators (i.e. 1,000) for the provided language.\n * @param {string} lang - The language code to get the number separators for.\n * @returns {{delimiter: string, decimalSeparator: string}} - The number separators.\n */\nfunction getNumberSeparators(lang = 'en') {\n const formattedNumberString = (12345.6789).toLocaleString(lang);\n const delimeters = formattedNumberString.match(/..(.)...(.)../);\n if (!delimeters) {\n return {\n delimiter: ',',\n decimalSeparator: '.'\n };\n }\n return {\n delimiter: (delimeters.length > 1) ? delimeters[1] : ',',\n decimalSeparator: (delimeters.length > 2) ? delimeters[2] : '.',\n };\n}\nexports.getNumberSeparators = getNumberSeparators;\n/**\n * Returns the number for the maximum amount of decimal places for a number.\n * @param {import('@formio/core').Component} component - The component to check for decimal limits.\n * @param {number} defaultLimit - The default limit to use if none is provided in the component.\n * @returns {number} - The number of decimal places allowed.\n */\nfunction getNumberDecimalLimit(component, defaultLimit) {\n if (lodash_1.default.has(component, 'decimalLimit')) {\n return lodash_1.default.get(component, 'decimalLimit');\n }\n // Determine the decimal limit. Defaults to 20 but can be overridden by validate.step or decimalLimit settings.\n let decimalLimit = defaultLimit || 20;\n const step = lodash_1.default.get(component, 'validate.step', 'any');\n if (step !== 'any') {\n const parts = step.toString().split('.');\n if (parts.length > 1) {\n decimalLimit = parts[1].length;\n }\n }\n return decimalLimit;\n}\nexports.getNumberDecimalLimit = getNumberDecimalLimit;\n/**\n * Returns the currency affixes for a specific language.\n * @param {object} arg0 - The arguments object.\n * @param {string} arg0.currency - The currency code to get the affixes for.\n * @param {number} arg0.decimalLimit - The number of decimal places to use.\n * @param {string} arg0.decimalSeparator - The decimal separator to use.\n * @param {string} arg0.lang - The language code to use.\n * @returns {{prefix: string, suffix: string}} - The currency affixes.\n */\nfunction getCurrencyAffixes({ currency, decimalLimit, decimalSeparator, lang, }) {\n // Get the prefix and suffix from the localized string.\n let regex = `(.*)?${(100).toLocaleString(lang)}`;\n if (decimalLimit) {\n regex += `${decimalSeparator === '.' ? '\\\\.' : decimalSeparator}${(0).toLocaleString(lang)}{${decimalLimit}}`;\n }\n regex += '(.*)?';\n const parts = (100).toLocaleString(lang, {\n style: 'currency',\n currency: currency ? currency : 'USD',\n useGrouping: true,\n maximumFractionDigits: decimalLimit || 0,\n minimumFractionDigits: decimalLimit || 0\n }).replace('.', decimalSeparator).match(new RegExp(regex));\n return {\n prefix: (parts === null || parts === void 0 ? void 0 : parts[1]) || '',\n suffix: (parts === null || parts === void 0 ? void 0 : parts[2]) || ''\n };\n}\nexports.getCurrencyAffixes = getCurrencyAffixes;\n/**\n * Fetch the field data provided a component.\n * @param {import('@formio/core').DataObject} data - The data object to fetch the field data from.\n * @param {import('@formio/core').Component} component - The component to fetch the field data for.\n * @returns {*} - The field data.\n */\nfunction fieldData(data, component) {\n if (!data) {\n return '';\n }\n if (!component || !component.key) {\n return data;\n }\n if (component.key.includes('.')) {\n let value = data;\n const parts = component.key.split('.');\n let key = '';\n for (let i = 0; i < parts.length; i++) {\n key = parts[i];\n // Handle nested resources\n if (value.hasOwnProperty('_id')) {\n value = value.data;\n }\n // Return if the key is not found on the value.\n if (!value.hasOwnProperty(key)) {\n return;\n }\n // Convert old single field data in submissions to multiple\n if (key === parts[parts.length - 1] && component.multiple && !Array.isArray(value[key])) {\n value[key] = [value[key]];\n }\n // Set the value of this key.\n value = value[key];\n }\n return value;\n }\n else {\n // Convert old single field data in submissions to multiple\n if (component.multiple && !Array.isArray(data[component.key])) {\n data[component.key] = [data[component.key]];\n }\n // Fix for checkbox type radio submission values in tableView\n if (component.type === 'checkbox' && component.inputType === 'radio') {\n return data[component.name] === component.value;\n }\n return data[component.key];\n }\n}\nexports.fieldData = fieldData;\n/**\n * Delays function execution with possibility to execute function synchronously or cancel it.\n * @param {Function} fn - Function to delay\n * @param {number} delay - Delay time\n * @param {...any} args - Arguments to pass to the function\n * @returns {*} - Function to cancel the delay\n */\nfunction delay(fn, delay = 0, ...args) {\n const timer = setTimeout(fn, delay, ...args);\n /**\n *\n */\n function cancel() {\n clearTimeout(timer);\n }\n /**\n * Execute the function early.\n * @returns {*} - The result of the function.\n */\n function earlyCall() {\n cancel();\n return fn(...args);\n }\n earlyCall.timer = timer;\n earlyCall.cancel = cancel;\n return earlyCall;\n}\nexports.delay = delay;\n/**\n * Iterate the given key to make it unique.\n * @param {string} key\n * Modify the component key to be unique.\n * @returns {string}\n * The new component key.\n */\nfunction iterateKey(key) {\n if (!key.match(/(\\d+)$/)) {\n return `${key}1`;\n }\n return key.replace(/(\\d+)$/, function (suffix) {\n return Number(suffix) + 1;\n });\n}\nexports.iterateKey = iterateKey;\n/**\n * Determines a unique key within a map provided the base key.\n * @param {Record<string, string>} map - The map to check for uniqueness.\n * @param {string} base - The base path of the key.\n * @returns {string} - The unique key.\n */\nfunction uniqueKey(map, base) {\n let newKey = base;\n while (map.hasOwnProperty(newKey)) {\n newKey = iterateKey(newKey);\n }\n return newKey;\n}\nexports.uniqueKey = uniqueKey;\n/**\n * Determines the major version number of bootstrap.\n * @param {object} options - The options to check for bootstrap version.\n * @param {string} options.bootstrap - The bootstrap version to use.\n * @returns {number} - The bootstrap version.\n */\nfunction bootstrapVersion(options) {\n if (options.bootstrap) {\n return options.bootstrap;\n }\n if ((typeof jQuery === 'function') && (typeof jQuery().collapse === 'function')) {\n return parseInt(jQuery.fn.collapse.Constructor.VERSION.split('.')[0], 10);\n }\n if (window.bootstrap && window.bootstrap.Collapse) {\n return parseInt(window.bootstrap.Collapse.VERSION.split('.')[0], 10);\n }\n return 0;\n}\nexports.bootstrapVersion = bootstrapVersion;\n/**\n * Retrun provided argument.\n * If argument is a function, returns the result of a function call.\n * @param {Function|any} e - The argument to check if a function and call if so.\n * @returns {any} - Either the result of the function call (e) or e if it is not a function.\n */\nfunction unfold(e) {\n if (typeof e === 'function') {\n return e();\n }\n return e;\n}\nexports.unfold = unfold;\n/**\n * Map values through unfold and return first non-nil value.\n * @param {Array<T>} collection - The collection to map through unfold.;\n * @returns {T} - The first non-nil value.\n */\nexports.firstNonNil = lodash_1.default.flow([\n lodash_1.default.partialRight(lodash_1.default.map, unfold),\n lodash_1.default.partialRight(lodash_1.default.find, v => !lodash_1.default.isUndefined(v))\n]);\n/**\n * Create enclosed state. Returns functions to getting and cycling between states.\n * @param {*} a - initial state.\n * @param {*} b - next state.\n * @returns {Functions[]} -- [get, toggle];\n */\nfunction withSwitch(a, b) {\n let state = a;\n let next = b;\n /**\n * Returns the state of the switch.\n * @returns {*} - The current state.\n */\n function get() {\n return state;\n }\n /**\n * Toggles the state of the switch.\n */\n function toggle() {\n const prev = state;\n state = next;\n next = prev;\n }\n return [get, toggle];\n}\nexports.withSwitch = withSwitch;\n/**\n * Create a function that will call the provided function only the provided limit.\n * @param {Function} callback - The callback to call.\n * @param {object} options - The options to use.\n * @param {number} options.limit - The limit to call the callback.\n * @param {number} options.delay - The delay to wait before resetting the call count.\n * @returns {Function} - The function that will call the callback only the provided limit.\n */\nfunction observeOverload(callback, options = {}) {\n const { limit = 50, delay = 500 } = options;\n let callCount = 0;\n let timeoutID = 0;\n const reset = () => callCount = 0;\n return () => {\n if (timeoutID !== 0) {\n clearTimeout(timeoutID);\n timeoutID = 0;\n }\n timeoutID = setTimeout(reset, delay);\n callCount += 1;\n if (callCount >= limit) {\n clearTimeout(timeoutID);\n reset();\n return callback();\n }\n };\n}\nexports.observeOverload = observeOverload;\n/**\n * Returns the components that are provided within an evaluation context.\n * @param {any} context - The evaluation context to get the components from.\n * @param {boolean} excludeNested - Exclude nested components.\n * @param {Array<string>} excludedTypes - The types of components to exclude.\n * @returns {Array} - The components within the evaluation context.\n */\nfunction getContextComponents(context, excludeNested, excludedTypes = []) {\n const values = [];\n context.utils.eachComponent(context.instance.options.editForm.components, (component, path) => {\n const addToContextComponents = excludeNested ? !component.tree : true;\n if (component.key !== context.data.key && addToContextComponents && !lodash_1.default.includes(excludedTypes, component.type)) {\n values.push({\n label: `${component.label || component.key} (${path})`,\n value: path,\n });\n }\n });\n return values;\n}\nexports.getContextComponents = getContextComponents;\n/**\n * Returns the button components that are within an evaluation context.\n * @param {any} context - The evaluation context to get the components from.\n * @returns {Array} - The button components within the evaluation context.\n */\nfunction getContextButtons(context) {\n const values = [];\n context.utils.eachComponent(context.instance.options.editForm.components, (component) => {\n if (component.type === 'button') {\n values.push({\n label: `${component.key} (${component.label})`,\n value: component.key,\n });\n }\n });\n return values;\n}\nexports.getContextButtons = getContextButtons;\n// Tags that could be in text, that should be ommited or handled in a special way\nconst inTextTags = ['#text', 'A', 'B', 'EM', 'I', 'SMALL', 'STRONG', 'SUB', 'SUP', 'INS', 'DEL', 'MARK', 'CODE'];\n/**\n * Helper function for 'translateHTMLTemplate'. Translates text value of the passed html element.\n * @param {HTMLElement} elem - The element to translate.\n * @param {Function} translate - The translation function.\n * @returns {string} - Translated element template.\n */\nfunction translateElemValue(elem, translate) {\n if (!elem.innerText) {\n return elem.innerHTML;\n }\n const elemValue = elem.innerText.replace(Evaluator_1.Evaluator.templateSettings.interpolate, '').replace(/\\s\\s+/g, ' ').trim();\n const translatedValue = translate(elemValue);\n if (elemValue !== translatedValue) {\n const links = elem.innerHTML.match(/<a[^>]*>(.*?)<\\/a>/g);\n if (links && links.length) {\n if (links.length === 1 && links[0].length === elem.innerHTML.length) {\n return elem.innerHTML.replace(elemValue, translatedValue);\n }\n const translatedLinks = links.map(link => {\n const linkElem = document.createElement('a');\n linkElem.innerHTML = link;\n return translateElemValue(linkElem, translate);\n });\n return `${translatedValue} (${translatedLinks.join(', ')})`;\n }\n else {\n return elem.innerText.replace(elemValue, translatedValue);\n }\n }\n else {\n return elem.innerHTML;\n }\n}\n/**\n * Helper function for 'translateHTMLTemplate'. Goes deep through html tag children and calls function to translate their text values.\n * @param {HTMLElement} tag - The tag to translate.\n * @param {Function} translate - The translation function.\n * @returns {void}\n */\nfunction translateDeepTag(tag, translate) {\n const children = tag.children.length && [...tag.children];\n const shouldTranslateEntireContent = children && children.every(child => child.children.length === 0\n && inTextTags.some(tag => child.nodeName === tag));\n if (!children || shouldTranslateEntireContent) {\n tag.innerHTML = translateElemValue(tag, translate);\n }\n else {\n children.forEach(child => translateDeepTag(child, translate));\n }\n}\n/**\n * Translates text values in html template.\n * @param {string} template - The template to translate.\n * @param {Function} translate - The translation function.\n * @returns {string} - Html template with translated values.\n */\nfunction translateHTMLTemplate(template, translate) {\n const isHTML = /<[^>]*>/.test(template);\n if (!isHTML) {\n return translate(template);\n }\n const tempElem = document.createElement('div');\n tempElem.innerHTML = template;\n if (tempElem.innerText && tempElem.children.length) {\n translateDeepTag(tempElem, translate);\n return tempElem.innerHTML;\n }\n return template;\n}\nexports.translateHTMLTemplate = translateHTMLTemplate;\n/**\n * Sanitize an html string.\n * @param {string} string - The string to sanitize.\n * @param {any} options - The options to use for sanitization.\n * @returns {string} - The sanitized html string.\n */\nfunction sanitize(string, options) {\n if (typeof dompurify_1.default.sanitize !== 'function') {\n return string;\n }\n // Dompurify configuration\n const sanitizeOptions = {\n ADD_ATTR: ['ref', 'target'],\n USE_PROFILES: { html: true }\n };\n // Use profiles\n if (options.sanitizeConfig && options.sanitizeConfig.useProfiles) {\n Object.keys(options.sanitizeConfig.useProfiles).forEach(key => {\n sanitizeOptions.USE_PROFILES[key] = options.sanitizeConfig.useProfiles[key];\n });\n }\n // Add attrs\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.addAttr) && options.sanitizeConfig.addAttr.length > 0) {\n options.sanitizeConfig.addAttr.forEach((attr) => {\n sanitizeOptions.ADD_ATTR.push(attr);\n });\n }\n // Add tags\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.addTags) && options.sanitizeConfig.addTags.length > 0) {\n sanitizeOptions.ADD_TAGS = options.sanitizeConfig.addTags;\n }\n // Allow tags\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.allowedTags) && options.sanitizeConfig.allowedTags.length > 0) {\n sanitizeOptions.ALLOWED_TAGS = options.sanitizeConfig.allowedTags;\n }\n // Allow attributes\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.allowedAttrs) && options.sanitizeConfig.allowedAttrs.length > 0) {\n sanitizeOptions.ALLOWED_ATTR = options.sanitizeConfig.allowedAttrs;\n }\n // Allowd URI Regex\n if (options.sanitizeConfig && options.sanitizeConfig.allowedUriRegex) {\n const allowedUriRegex = options.sanitizeConfig.allowedUriRegex;\n sanitizeOptions.ALLOWED_URI_REGEXP = lodash_1.default.isString(allowedUriRegex) ? new RegExp(allowedUriRegex) : allowedUriRegex;\n }\n // Allow to extend the existing array of elements that are safe for URI-like values\n if (options.sanitizeConfig && Array.isArray(options.sanitizeConfig.addUriSafeAttr) && options.sanitizeConfig.addUriSafeAttr.length > 0) {\n sanitizeOptions.ADD_URI_SAFE_ATTR = options.sanitizeConfig.addUriSafeAttr;\n }\n return dompurify_1.default.sanitize(string, sanitizeOptions);\n}\nexports.sanitize = sanitize;\n/**\n * Fast cloneDeep for JSON objects only.\n * @param {any} obj - The object to perform a fast clone deep against.\n * @returns {any} - The cloned object.\n */\nfunction fastCloneDeep(obj) {\n return obj ? JSON.parse(JSON.stringify(obj)) : obj;\n}\nexports.fastCloneDeep = fastCloneDeep;\n/**\n * Returns if the component is an input component.\n * @param {import('@formio/core').Component} componentJson - The JSON of a component.\n * @returns {bool} - TRUE if the component is an input component; FALSE otherwise.\n */\nfunction isInputComponent(componentJson) {\n if (componentJson.input === false || componentJson.input === true) {\n return componentJson.input;\n }\n switch (componentJson.type) {\n case 'htmlelement':\n case 'content':\n case 'columns':\n case 'fieldset':\n case 'panel':\n case 'table':\n case 'tabs':\n case 'well':\n case 'button':\n return false;\n default:\n return true;\n }\n}\nexports.isInputComponent = isInputComponent;\n/**\n * Takes a component path, and returns a component path array.\n * @param {string} pathStr - The path string to convert to an array.\n * @returns {Arryay<number>} - The array of paths.\n */\nfunction getArrayFromComponentPath(pathStr) {\n if (!pathStr || !lodash_1.default.isString(pathStr)) {\n if (!lodash_1.default.isArray(pathStr)) {\n return [pathStr];\n }\n return pathStr;\n }\n return pathStr.replace(/[[\\]]/g, '.')\n .replace(/\\.\\./g, '.')\n .replace(/(^\\.)|(\\.$)/g, '')\n .split('.')\n .map(part => lodash_1.default.defaultTo(lodash_1.default.toNumber(part), part));\n}\nexports.getArrayFromComponentPath = getArrayFromComponentPath;\n/**\n * Returns true if the component is a child of the parent.\n * @param {any} child - The child component to check.\n * @param {any} parent - The parent component to check.\n * @returns {boolean} - TRUE if the child is a child of the parent; FALSE otherwise.\n */\nfunction isChildOf(child, parent) {\n while (child && child.parent) {\n if (child.parent === parent) {\n return true;\n }\n child = child.parent;\n }\n return false;\n}\nexports.isChildOf = isChildOf;\n/**\n * Takes an array of component path indexes, and returns a string version of that array.\n * @param {Array<number>} path - The path array to convert to a string.\n * @returns {string} - The string version of the path.\n */\nfunction getStringFromComponentPath(path) {\n if (!lodash_1.default.isArray(path)) {\n return path;\n }\n let strPath = '';\n path.forEach((part, i) => {\n if (lodash_1.default.isNumber(part)) {\n strPath += `[${part}]`;\n }\n else {\n strPath += i === 0 ? part : `.${part}`;\n }\n });\n return strPath;\n}\nexports.getStringFromComponentPath = getStringFromComponentPath;\n/**\n * Takes a number and rounds it to the provided precision amount.\n * @param {number} number - The number to round.\n * @param {number} precision - The precision to round the number to.\n * @returns {string} - The rounded number.\n */\nfunction round(number, precision) {\n if (lodash_1.default.isNumber(number)) {\n return number.toFixed(precision);\n }\n return number.toString();\n}\nexports.round = round;\n/**\n * Check for Internet Explorer browser version\n * @returns {(number|null)} - The IE browser version or null if not IE\n */\nfunction getIEBrowserVersion() {\n const { ie, version } = getBrowserInfo();\n return ie ? version : null;\n}\nexports.getIEBrowserVersion = getIEBrowserVersion;\n/**\n * Get browser name and version (modified from 'jquery-browser-plugin')\n * @returns {object} -- {{browser name, version, isWebkit?}}\n * Possible browser names: chrome, safari, ie, edge, opera, mozilla, yabrowser\n */\nfunction getBrowserInfo() {\n const browser = {};\n if (typeof window === 'undefined') {\n return browser;\n }\n const ua = window.navigator.userAgent.toLowerCase();\n const match = /(edge|edg)\\/([\\w.]+)/.exec(ua) ||\n /(opr)[/]([\\w.]+)/.exec(ua) ||\n /(yabrowser)[ /]([\\w.]+)/.exec(ua) ||\n /(chrome)[ /]([\\w.]+)/.exec(ua) ||\n /(iemobile)[/]([\\w.]+)/.exec(ua) ||\n /(version)(applewebkit)[ /]([\\w.]+).*(safari)[ /]([\\w.]+)/.exec(ua) ||\n /(webkit)[ /]([\\w.]+).*(version)[ /]([\\w.]+).*(safari)[ /]([\\w.]+)/.exec(ua) ||\n /(webkit)[ /]([\\w.]+)/.exec(ua) ||\n /(opera)(?:.*version|)[ /]([\\w.]+)/.exec(ua) ||\n /(msie) ([\\w.]+)/.exec(ua) ||\n ua.indexOf('trident') >= 0 && /(rv)(?::| )([\\w.]+)/.exec(ua) ||\n ua.indexOf('compatible') < 0 && /(mozilla)(?:.*? rv:([\\w.]+)|)/.exec(ua) ||\n [];\n const matched = {\n browser: match[5] || match[3] || match[1] || '',\n version: match[4] || match[2] || '0'\n };\n if (matched.browser) {\n browser[matched.browser] = true;\n browser.version = parseInt(matched.version, 10);\n }\n // Chrome, Opera 15+, Safari and Yandex.Browser are webkit based browsers\n if (browser.chrome || browser.opr || browser.safari || browser.edg || browser.yabrowser) {\n browser.isWebkit = true;\n }\n // IE11 has a new token so we will assign it ie to avoid breaking changes\n if (browser.rv || browser.iemobile) {\n browser.ie = true;\n }\n // Edge has a new token since it became webkit based\n if (browser.edg) {\n browser.edge = true;\n }\n // Opera 15+ are identified as opr\n if (browser.opr) {\n browser.opera = true;\n }\n return browser;\n}\nexports.getBrowserInfo = getBrowserInfo;\n/**\n * Takes a component path, which may include array indicies (i.e. [0][1]), and returns the compoennt path without the indicies.\n * @param {string} path - The path to remove the indicies from.\n * @returns {string} - The path without the indicies.\n */\nfunction getComponentPathWithoutIndicies(path = '') {\n return path.replace(/\\[\\d+\\]/, '');\n}\nexports.getComponentPathWithoutIndicies = getComponentPathWithoutIndicies;\n/**\n * Returns a path to the component which based on its schema\n * @param {import('@formio/core').Component} component - Component containing link to its parent's schema in the 'parent' property\n * @param {string} path - Path to the component\n * @returns {string} - Path to the component\n */\nfunction getComponentPath(component, path = '') {\n var _a;\n if (!component || !component.key || ((_a = component === null || component === void 0 ? void 0 : component._form) === null || _a === void 0 ? void 0 : _a.display) === 'wizard') { // unlike the Webform, the Wizard has the key and it is a duplicate of the panel key\n return path;\n }\n path = component.isInputComponent || component.input === true ? `${component.key}${path ? '.' : ''}${path}` : path;\n return getComponentPath(component.parent, path);\n}\nexports.getComponentPath = getComponentPath;\n/**\n * Returns a parent component of the passed component instance skipping all the Layout components\n * @param {Component} componentInstance - The component to check for the parent.\n * @returns {Component|undefined} - The parent data component.\n */\nfunction getDataParentComponent(componentInstance) {\n if (!componentInstance) {\n return;\n }\n const { parent } = componentInstance;\n if (parent && (parent.isInputComponent || parent.input)) {\n return parent;\n }\n else {\n return getDataParentComponent(parent);\n }\n}\nexports.getDataParentComponent = getDataParentComponent;\n/**\n * Returns whether the value is a promise\n * @param {any} value - The value to check\n * @returns {boolean} - TRUE if the value is a promise; FALSE otherwise\n */\nfunction isPromise(value) {\n return value\n && value.then\n && typeof value.then === 'function'\n && Object.prototype.toString.call(value) === '[object Promise]';\n}\nexports.isPromise = isPromise;\n/**\n * Determines if the component has a scoping parent in tree (a component which scopes its children and manages its\n * changes by itself, e.g. EditGrid)\n * @param {Component} componentInstance - The component to check for the scoping parent.\n * @param {boolean} firstPass - Whether it is the first pass of the function\n * @returns {boolean|*} - TRUE if the component has a scoping parent; FALSE otherwise\n */\nfunction isInsideScopingComponent(componentInstance, firstPass = true) {\n if (!firstPass && (componentInstance === null || componentInstance === void 0 ? void 0 : componentInstance.hasScopedChildren)) {\n return true;\n }\n const dataParent = getDataParentComponent(componentInstance);\n if (dataParent === null || dataParent === void 0 ? void 0 : dataParent.hasScopedChildren) {\n return true;\n }\n else if (dataParent === null || dataParent === void 0 ? void 0 : dataParent.parent) {\n return isInsideScopingComponent(dataParent.parent, false);\n }\n return false;\n}\nexports.isInsideScopingComponent = isInsideScopingComponent;\n/**\n * Returns all the focusable elements within the provided dom element.\n * @param {HTMLElement} element - The element to get the focusable elements from.\n * @returns {NodeList<HTMLElement>} - The focusable elements within the provided element.\n */\nfunction getFocusableElements(element) {\n const focusableSelector = `button:not([disabled]), input:not([disabled]), select:not([disabled]),\n textarea:not([disabled]), button:not([disabled]), [href]`;\n return element.querySelectorAll(focusableSelector);\n}\nexports.getFocusableElements = getFocusableElements;\nexports.componentValueTypes = {\n number: 'number',\n string: 'string',\n boolean: 'boolean',\n array: 'array',\n object: 'object',\n date: 'date',\n any: 'any',\n};\n/**\n * Returns the saved types for the component\n * @param {import('@formio/core').Component} fullSchema - The component schema\n * @returns {Array<string>|null} - The saved types for the component\n */\nfunction getComponentSavedTypes(fullSchema) {\n const schema = fullSchema || {};\n if (schema.persistent !== true) {\n return [];\n }\n if (schema.multiple) {\n return [exports.componentValueTypes.array];\n }\n return null;\n}\nexports.getComponentSavedTypes = getComponentSavedTypes;\n/**\n * Interpolates @formio/core errors so that they are compatible with the renderer\n * @param {Component} component - The component to interpolate the errors for\n * @param {FieldError[]} errors - The errors to interpolate\n * @param {Function} interpolateFn - The interpolation function\n * @returns {[]} - The interpolated errors\n */\nconst interpolateErrors = (component, errors, interpolateFn) => {\n return errors.map((error) => {\n error.component = component;\n const { errorKeyOrMessage, context } = error;\n const toInterpolate = component.errors && component.errors[errorKeyOrMessage] ? component.errors[errorKeyOrMessage] : errorKeyOrMessage;\n return Object.assign(Object.assign({}, error), { message: unescapeHTML(interpolateFn(toInterpolate, context)), context: Object.assign({}, context) });\n });\n};\nexports.interpolateErrors = interpolateErrors;\n/**\n * Returns the template keys inside the template code.\n * @param {string} template - The template to get the keys from.\n * @returns {Array<string>} - The keys inside the template.\n */\nfunction getItemTemplateKeys(template) {\n const templateKeys = [];\n if (!template) {\n return templateKeys;\n }\n const keys = template.match(/({{\\s*(.*?)\\s*}})/g);\n if (keys) {\n keys.forEach((key) => {\n const propKey = key.match(/{{\\s*item\\.(.*?)\\s*}}/);\n if (propKey && propKey.length > 1) {\n templateKeys.push(propKey[1]);\n }\n });\n }\n return templateKeys;\n}\nexports.getItemTemplateKeys = getItemTemplateKeys;\n/**\n * Returns if the component is a select resource with an object for its value.\n * @param {import('@formio/core').Component} comp - The component to check.\n * @returns {boolean} - TRUE if the component is a select resource with an object for its value; FALSE otherwise.\n */\nfunction isSelectResourceWithObjectValue(comp = {}) {\n const { reference, dataSrc, valueProperty } = comp;\n return reference || (dataSrc === 'resource' && (!valueProperty || valueProperty === 'data'));\n}\nexports.isSelectResourceWithObjectValue = isSelectResourceWithObjectValue;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/utils/utils.js?");
|
8090
8090
|
|
8091
8091
|
/***/ }),
|
8092
8092
|
|
@@ -8810,7 +8810,7 @@ eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\ncons
|
|
8810
8810
|
/***/ (function(__unused_webpack_module, exports) {
|
8811
8811
|
|
8812
8812
|
"use strict";
|
8813
|
-
eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports[\"default\"] = (iconset, name, spinning) => {\n let biName = name;\n switch (name) {\n case 'cog':\n biName = 'gear';\n break;\n case 'copy':\n biName = 'back';\n break;\n case 'bars':\n biName = 'list';\n break;\n case 'remove':\n biName = 'trash';\n break;\n case 'font':\n biName = 'type';\n break;\n case 'hashtag':\n biName = 'hash';\n break;\n case 'th-list':\n biName = 'menu-button-wide';\n break;\n case 'dot-circle-o':\n biName = 'ui-radios';\n break;\n case 'plus-square-o':\n biName = 'plus-square';\n break;\n case 'minus-square-o':\n biName = 'dash-square';\n break;\n case 'plus-square':\n biName = 'ui-checks';\n break;\n case 'phone-square':\n biName = 'phone';\n break;\n case 'home':\n biName = 'house';\n break;\n case 'clock-o':\n biName = 'clock';\n break;\n case 'usd':\n biName = 'currency-dollar';\n break;\n case 'html5':\n biName = 'file-richtext';\n break;\n case 'pencil-square-o':\n biName = 'pencil-square';\n break;\n case 'columns':\n biName = 'layout-three-columns';\n break;\n case 'list-alt':\n biName = 'window';\n break;\n case 'th-large':\n biName = 'grid-fill';\n break;\n case 'folder-o':\n biName = 'folder';\n break;\n case 'square-o':\n biName = 'square';\n break;\n case 'user-secret':\n biName = 'person-fill-slash';\n break;\n case 'folder-open':\n biName = 'folder2-open';\n break;\n case 'th':\n biName = 'grid-3x3-gap-fill';\n break;\n case 'tasks':\n biName = 'view-stacked';\n break;\n case 'indent':\n biName = 'text-indent-left';\n break;\n case 'refresh':\n biName = 'arrow-repeat';\n break;\n case 'files-o':\n biName = 'files';\n break;\n case 'wpforms':\n biName = 'window-stack';\n break;\n case 'cube':\n biName = 'box';\n break;\n case 'cubes':\n biName = 'boxes';\n break;\n case 'check-square-o':\n biName = 'check-square';\n break;\n case 'plus':\n biName = 'plus-lg';\n break;\n case 'question-sign':\n biName = 'question-circle';\n break;\n case 'remove-circle':\n biName = 'x-circle';\n break;\n case 'new-window':\n biName = 'window-plus';\n break;\n case 'move':\n biName = 'arrows-move';\n break;\n case 'edit':\n biName = 'pencil';\n break;\n case 'time':\n biName = 'clock';\n break;\n case 'video':\n biName = 'camera-video';\n break;\n case 'microphone':\n biName = 'mic';\n break;\n case 'folder-open':\n biName = 'folder2-open';\n break;\n }\n return spinning ? 'spinner-border spinner-border-sm' : `fa fa-${name} bi bi-${biName}`;\n};\n\n\n//# sourceURL=webpack://Formio/./node_modules/@formio/bootstrap/lib/cjs/templates/bootstrap5/iconClass.js?");
|
8813
|
+
eval("\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports[\"default\"] = (iconset, name, spinning) => {\n let biName = name;\n switch (name) {\n case 'cog':\n biName = 'gear';\n break;\n case 'copy':\n biName = 'back';\n break;\n case 'bars':\n biName = 'list';\n break;\n case 'remove':\n biName = 'trash';\n break;\n case 'font':\n biName = 'type';\n break;\n case 'hashtag':\n biName = 'hash';\n break;\n case 'th-list':\n biName = 'menu-button-wide';\n break;\n case 'dot-circle-o':\n biName = 'ui-radios';\n break;\n case 'plus-square-o':\n biName = 'plus-square';\n break;\n case 'minus-square-o':\n biName = 'dash-square';\n break;\n case 'plus-square':\n biName = 'ui-checks';\n break;\n case 'phone-square':\n biName = 'phone';\n break;\n case 'home':\n biName = 'house';\n break;\n case 'clock-o':\n biName = 'clock';\n break;\n case 'usd':\n biName = 'currency-dollar';\n break;\n case 'html5':\n biName = 'file-richtext';\n break;\n case 'pencil-square-o':\n biName = 'pencil-square';\n break;\n case 'columns':\n biName = 'layout-three-columns';\n break;\n case 'list-alt':\n biName = 'window';\n break;\n case 'th-large':\n biName = 'grid-fill';\n break;\n case 'folder-o':\n biName = 'folder';\n break;\n case 'square-o':\n biName = 'square';\n break;\n case 'user-secret':\n biName = 'person-fill-slash';\n break;\n case 'folder-open':\n biName = 'folder2-open';\n break;\n case 'th':\n biName = 'grid-3x3-gap-fill';\n break;\n case 'tasks':\n biName = 'view-stacked';\n break;\n case 'indent':\n biName = 'text-indent-left';\n break;\n case 'refresh':\n biName = 'arrow-repeat';\n break;\n case 'files-o':\n biName = 'files';\n break;\n case 'wpforms':\n biName = 'window-stack';\n break;\n case 'cube':\n biName = 'box';\n break;\n case 'cubes':\n biName = 'boxes';\n break;\n case 'check-square-o':\n biName = 'check-square';\n break;\n case 'plus':\n biName = 'plus-lg';\n break;\n case 'question-sign':\n biName = 'question-circle';\n break;\n case 'remove-circle':\n biName = 'x-circle';\n break;\n case 'new-window':\n biName = 'window-plus';\n break;\n case 'move':\n biName = 'arrows-move';\n break;\n case 'edit':\n biName = 'pencil';\n break;\n case 'time':\n biName = 'clock';\n break;\n case 'video':\n biName = 'camera-video';\n break;\n case 'microphone':\n biName = 'mic';\n break;\n case 'folder-open':\n biName = 'folder2-open';\n break;\n case 'check-circle':\n biName = 'check-circle-fill';\n break;\n case 'times-circle':\n biName = 'x-circle-fill';\n break;\n }\n return spinning ? 'spinner-border spinner-border-sm' : `fa fa-${name} bi bi-${biName}`;\n};\n\n\n//# sourceURL=webpack://Formio/./node_modules/@formio/bootstrap/lib/cjs/templates/bootstrap5/iconClass.js?");
|
8814
8814
|
|
8815
8815
|
/***/ }),
|
8816
8816
|
|
@@ -10821,7 +10821,7 @@ eval("\nvar parent = __webpack_require__(/*! ../../es/object/from-entries */ \".
|
|
10821
10821
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
10822
10822
|
|
10823
10823
|
"use strict";
|
10824
|
-
eval("\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nvar _a;\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.FormBuilder = exports.Form = exports.Formio = void 0;\nconst CDN_js_1 = __importDefault(__webpack_require__(/*! ./CDN.js */ \"./lib/cjs/CDN.js\"));\nclass Formio {\n static setLicense(license, norecurse = false) {\n _a.license = license;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setLicense(license);\n }\n }\n static setBaseUrl(url, norecurse = false) {\n _a.baseUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setBaseUrl(url);\n }\n }\n static setApiUrl(url, norecurse = false) {\n _a.baseUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setApiUrl(url);\n }\n }\n static setProjectUrl(url, norecurse = false) {\n _a.projectUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setProjectUrl(url);\n }\n }\n static setAppUrl(url, norecurse = false) {\n _a.projectUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setAppUrl(url);\n }\n }\n static setPathType(type, norecurse = false) {\n _a.pathType = type;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setPathType(type);\n }\n }\n static debug(...args) {\n if (_a.config.debug) {\n console.log(...args);\n }\n }\n static clearCache() {\n if (_a.FormioClass) {\n _a.FormioClass.clearCache();\n }\n }\n static global(prop, flag = '') {\n const globalValue = window[prop];\n if (flag && globalValue && !globalValue[flag]) {\n return null;\n }\n _a.debug(`Getting global ${prop}`, globalValue);\n return globalValue;\n }\n static use(module) {\n if (_a.FormioClass && _a.FormioClass.isRenderer) {\n _a.FormioClass.use(module);\n }\n else {\n _a.modules.push(module);\n }\n }\n static createElement(type, attrs, children) {\n const element = document.createElement(type);\n if (!attrs) {\n return element;\n }\n Object.keys(attrs).forEach(key => {\n element.setAttribute(key, attrs[key]);\n });\n (children || []).forEach(child => {\n element.appendChild(_a.createElement(child.tag, child.attrs, child.children));\n });\n return element;\n }\n static addScript(wrapper_1, src_1, name_1) {\n return __awaiter(this, arguments, void 0, function* (wrapper, src, name, flag = '') {\n if (!src) {\n return Promise.resolve();\n }\n if (typeof src !== 'string' && src.length) {\n return Promise.all(src.map(ref => _a.addScript(wrapper, ref)));\n }\n if (name && _a.global(name, flag)) {\n _a.debug(`${name} already loaded.`);\n return Promise.resolve(_a.global(name));\n }\n _a.debug('Adding Script', src);\n try {\n wrapper.appendChild(_a.createElement('script', {\n src\n }));\n }\n catch (err) {\n _a.debug(err);\n return Promise.resolve();\n }\n if (!name) {\n return Promise.resolve();\n }\n return new Promise((resolve) => {\n _a.debug(`Waiting to load ${name}`);\n const wait = setInterval(() => {\n if (_a.global(name, flag)) {\n clearInterval(wait);\n _a.debug(`${name} loaded.`);\n resolve(_a.global(name));\n }\n }, 100);\n });\n });\n }\n static addStyles(wrapper, href) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!href) {\n return;\n }\n if (typeof href !== 'string' && href.length) {\n href.forEach(ref => _a.addStyles(wrapper, ref));\n return;\n }\n _a.debug('Adding Styles', href);\n wrapper.appendChild(_a.createElement('link', {\n rel: 'stylesheet',\n href\n }));\n });\n }\n static submitDone(instance, submission) {\n return __awaiter(this, void 0, void 0, function* () {\n _a.debug('Submision Complete', submission);\n if (_a.config.submitDone) {\n _a.config.submitDone(submission, instance);\n }\n const successMessage = (_a.config.success || '').toString();\n if (successMessage && successMessage.toLowerCase() !== 'false' && instance.element) {\n instance.element.innerHTML = `<div class=\"alert-success\" role=\"alert\">${successMessage}</div>`;\n }\n let returnUrl = _a.config.redirect;\n // Allow form based configuration for return url.\n if (!returnUrl &&\n (instance._form &&\n instance._form.settings &&\n (instance._form.settings.returnUrl ||\n instance._form.settings.redirect))) {\n _a.debug('Return url found in form configuration');\n returnUrl = instance._form.settings.returnUrl || instance._form.settings.redirect;\n }\n if (returnUrl) {\n const formSrc = instance.formio ? instance.formio.formUrl : '';\n const hasQuery = !!returnUrl.match(/\\?/);\n const isOrigin = returnUrl.indexOf(location.origin) === 0;\n returnUrl += hasQuery ? '&' : '?';\n returnUrl += `sub=${submission._id}`;\n if (!isOrigin && formSrc) {\n returnUrl += `&form=${encodeURIComponent(formSrc)}`;\n }\n _a.debug('Return URL', returnUrl);\n window.location.href = returnUrl;\n if (isOrigin) {\n window.location.reload();\n }\n }\n });\n }\n // Return the full script if the builder is being used.\n static formioScript(script, builder) {\n builder = builder || _a.config.includeBuilder;\n if (_a.fullAdded || builder) {\n _a.fullAdded = true;\n return script.replace('formio.form', 'formio.full');\n }\n return script;\n }\n static addLibrary(libWrapper, lib, name) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!lib) {\n return;\n }\n if (lib.dependencies) {\n for (let i = 0; i < lib.dependencies.length; i++) {\n const libName = lib.dependencies[i];\n yield _a.addLibrary(libWrapper, _a.config.libs[libName], libName);\n }\n }\n if (lib.css) {\n yield _a.addStyles((lib.global ? document.body : libWrapper), lib.css);\n }\n if (lib.js) {\n const module = yield _a.addScript((lib.global ? document.body : libWrapper), lib.js, lib.use ? name : false);\n if (lib.use) {\n _a.debug(`Using ${name}`);\n const options = lib.options || {};\n if (!options.license && _a.license) {\n options.license = _a.license;\n }\n _a.use((typeof lib.use === 'function' ? lib.use(module) : module), options);\n }\n }\n if (lib.globalStyle) {\n const style = _a.createElement('style');\n style.type = 'text/css';\n style.innerHTML = lib.globalStyle;\n document.body.appendChild(style);\n }\n });\n }\n static addLoader(wrapper) {\n return __awaiter(this, void 0, void 0, function* () {\n wrapper.appendChild(_a.createElement('div', {\n 'class': 'formio-loader'\n }, [{\n tag: 'div',\n attrs: {\n class: 'loader-wrapper'\n },\n children: [{\n tag: 'div',\n attrs: {\n class: 'loader text-center'\n }\n }]\n }]));\n });\n }\n // eslint-disable-next-line max-statements\n static init(element_1) {\n return __awaiter(this, arguments, void 0, function* (element, options = {}, builder = false) {\n _a.cdn = new CDN_js_1.default(_a.config.cdn, _a.config.cdnUrls || {});\n _a.config.libs = _a.config.libs || {\n uswds: {\n dependencies: ['fontawesome'],\n js: `${_a.cdn.uswds}/uswds.min.js`,\n css: `${_a.cdn.uswds}/uswds.min.css`,\n use: true\n },\n fontawesome: {\n // Due to an issue with font-face not loading in the shadowdom (https://issues.chromium.org/issues/41085401), we need\n // to do 2 things. 1.) Load the fonts from the global cdn, and 2.) add the font-face to the global styles on the page.\n css: `https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css`,\n globalStyle: `@font-face {\n font-family: 'FontAwesome';\n src: url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.eot?v=4.7.0');\n src: url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.eot?#iefix&v=4.7.0') format('embedded-opentype'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.woff2?v=4.7.0') format('woff2'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.woff?v=4.7.0') format('woff'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.ttf?v=4.7.0') format('truetype'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular') format('svg');\n font-weight: normal;\n font-style: normal;\n }`\n },\n bootstrap4: {\n dependencies: ['fontawesome'],\n css: `${_a.cdn.bootstrap4}/css/bootstrap.min.css`\n },\n bootstrap: {\n dependencies: ['bootstrap-icons'],\n css: `${_a.cdn.bootstrap}/css/bootstrap.min.css`\n },\n 'bootstrap-icons': {\n // Due to an issue with font-face not loading in the shadowdom (https://issues.chromium.org/issues/41085401), we need\n // to do 2 things. 1.) Load the fonts from the global cdn, and 2.) add the font-face to the global styles on the page.\n css: 'https://cdn.jsdelivr.net/npm/bootstrap-icons/font/bootstrap-icons.min.css',\n globalStyle: `@font-face {\n font-display: block;\n font-family: \"bootstrap-icons\";\n src: url(\"https://cdn.jsdelivr.net/npm/bootstrap-icons/font/fonts/bootstrap-icons.woff2?dd67030699838ea613ee6dbda90effa6\") format(\"woff2\"),\n url(\"https://cdn.jsdelivr.net/npm/bootstrap-icons/font/fonts/bootstrap-icons.woff?dd67030699838ea613ee6dbda90effa6\") format(\"woff\");\n }`\n }\n };\n // Add all bootswatch templates.\n ['cerulean', 'cosmo', 'cyborg', 'darkly', 'flatly', 'journal', 'litera', 'lumen', 'lux', 'materia', 'minty', 'pulse', 'sandstone', 'simplex', 'sketchy', 'slate', 'solar', 'spacelab', 'superhero', 'united', 'yeti'].forEach((template) => {\n _a.config.libs[template] = {\n dependencies: ['bootstrap-icons'],\n css: `${_a.cdn.bootswatch}/dist/${template}/bootstrap.min.css`\n };\n });\n const id = _a.config.id || `formio-${Math.random().toString(36).substring(7)}`;\n // Create a new wrapper and add the element inside of a new wrapper.\n let wrapper = _a.createElement('div', {\n 'id': `${id}-wrapper`\n });\n element.parentNode.insertBefore(wrapper, element);\n // If we include the libraries, then we will attempt to run this in shadow dom.\n const useShadowDom = _a.config.includeLibs && !_a.config.noshadow && (typeof wrapper.attachShadow === 'function');\n if (useShadowDom) {\n wrapper = wrapper.attachShadow({\n mode: 'open'\n });\n options.shadowRoot = wrapper;\n }\n element.parentNode.removeChild(element);\n wrapper.appendChild(element);\n // If this is inside of shadow dom, then we need to add the styles and scripts to the shadow dom.\n const libWrapper = useShadowDom ? wrapper : document.body;\n // Load the renderer styles.\n yield _a.addStyles(libWrapper, _a.config.embedCSS || `${_a.cdn.js}/formio.embed.css`);\n // Add a loader.\n _a.addLoader(wrapper);\n const formioSrc = _a.config.full ? 'formio.full' : 'formio.form';\n const renderer = _a.config.debug ? formioSrc : `${formioSrc}.min`;\n _a.FormioClass = yield _a.addScript(libWrapper, _a.formioScript(_a.config.script || `${_a.cdn.js}/${renderer}.js`, builder), 'Formio', builder ? 'isBuilder' : 'isRenderer');\n _a.FormioClass.cdn = _a.cdn;\n _a.FormioClass.setBaseUrl(options.baseUrl || _a.baseUrl || _a.config.base);\n _a.FormioClass.setProjectUrl(options.projectUrl || _a.projectUrl || _a.config.project);\n _a.FormioClass.language = _a.language;\n _a.setLicense(_a.license || _a.config.license || false);\n _a.modules.forEach((module) => {\n _a.FormioClass.use(module);\n });\n if (_a.icons) {\n _a.FormioClass.icons = _a.icons;\n }\n if (_a.pathType) {\n _a.FormioClass.setPathType(_a.pathType);\n }\n // Add libraries if they wish to include the libs.\n if (_a.config.template && _a.config.includeLibs) {\n yield _a.addLibrary(libWrapper, _a.config.libs[_a.config.template], _a.config.template);\n }\n if (!_a.config.libraries) {\n _a.config.libraries = _a.config.modules || {};\n }\n // Adding premium if it is provided via the config.\n if (_a.config.premium) {\n _a.config.libraries.premium = _a.config.premium;\n }\n // Allow adding dynamic modules.\n if (_a.config.libraries) {\n for (const name in _a.config.libraries) {\n const lib = _a.config.libraries[name];\n lib.use = lib.use || true;\n yield _a.addLibrary(libWrapper, lib, name);\n }\n }\n yield _a.addStyles(libWrapper, _a.formioScript(_a.config.style || `${_a.cdn.js}/${renderer}.css`, builder));\n if (_a.config.before) {\n yield _a.config.before(_a.FormioClass, element, _a.config);\n }\n _a.FormioClass.license = true;\n _a._formioReady(_a.FormioClass);\n return wrapper;\n });\n }\n // Called after an instance has been created.\n static afterCreate(instance, wrapper, readyEvent) {\n return __awaiter(this, void 0, void 0, function* () {\n const loader = wrapper.querySelector('.formio-loader');\n if (loader) {\n wrapper.removeChild(loader);\n }\n _a.FormioClass.events.emit(readyEvent, instance);\n if (_a.config.after) {\n _a.debug('Calling ready callback');\n _a.config.after(instance, _a.config);\n }\n return instance;\n });\n }\n // Create a new form.\n static createForm(element_1, form_1) {\n return __awaiter(this, arguments, void 0, function* (element, form, options = {}) {\n if (_a.FormioClass) {\n return _a.FormioClass.createForm(element, form, Object.assign(Object.assign({}, options), { noLoader: true }));\n }\n const wrapper = yield _a.init(element, options);\n return _a.FormioClass.createForm(element, form, Object.assign(Object.assign({}, options), { noLoader: true })).then((instance) => {\n // Set the default submission data.\n if (_a.config.submission) {\n _a.debug('Setting submission', _a.config.submission);\n instance.submission = _a.config.submission;\n }\n // Call the after create method.\n _a.afterCreate(instance, wrapper, 'formEmbedded');\n return instance;\n });\n });\n }\n // Create a form builder.\n static builder(element_1, form_1) {\n return __awaiter(this, arguments, void 0, function* (element, form, options = {}) {\n var _b;\n if ((_b = _a.FormioClass) === null || _b === void 0 ? void 0 : _b.builder) {\n return _a.FormioClass.builder(element, form, options);\n }\n const wrapper = yield _a.init(element, options, true);\n return _a.FormioClass.builder(element, form, options).then((instance) => {\n _a.afterCreate(instance, wrapper, 'builderEmbedded');\n return instance;\n });\n });\n }\n}\nexports.Formio = Formio;\n_a = Formio;\nFormio.FormioClass = null;\nFormio.config = {};\nFormio.modules = [];\nFormio.icons = '';\nFormio.license = '';\nFormio.formioReady = new Promise((ready, reject) => {\n _a._formioReady = ready;\n _a._formioReadyReject = reject;\n});\nFormio.version = '5.0.0-rc.60';\n// Create a report.\nFormio.Report = {\n create: (element_1, submission_1, ...args_1) => __awaiter(void 0, [element_1, submission_1, ...args_1], void 0, function* (element, submission, options = {}) {\n var _b;\n if ((_b = _a.FormioClass) === null || _b === void 0 ? void 0 : _b.Report) {\n return _a.FormioClass.Report.create(element, submission, options);\n }\n const wrapper = yield _a.init(element, options, true);\n return _a.FormioClass.Report.create(element, submission, options).then((instance) => {\n _a.afterCreate(instance, wrapper, 'reportEmbedded');\n return instance;\n });\n })\n};\nCDN_js_1.default.defaultCDN = Formio.version.includes('rc') ? 'https://cdn.test-form.io' : 'https://cdn.form.io';\nclass Form {\n constructor(element, form, options) {\n this.form = form;\n this.element = element;\n this.options = options || {};\n this.init();\n this.instance = {\n proxy: true,\n ready: this.ready,\n destroy: () => { }\n };\n }\n init() {\n if (this.instance && !this.instance.proxy) {\n this.instance.destroy();\n }\n this.element.innerHTML = '';\n this.ready = this.create().then((instance) => {\n this.instance = instance;\n this.form = instance.form;\n return instance;\n });\n }\n create() {\n return Formio.createForm(this.element, this.form, this.options);\n }\n setForm(form) {\n this.form = form;\n if (this.instance) {\n this.instance.setForm(form);\n }\n }\n setDisplay(display) {\n if (this.instance.proxy) {\n return this.ready;\n }\n this.form.display = display;\n this.instance.destroy();\n this.ready = this.create().then((instance) => {\n this.instance = instance;\n this.setForm(this.form);\n });\n return this.ready;\n }\n}\nexports.Form = Form;\nclass FormBuilder extends Form {\n create() {\n return Formio.builder(this.element, this.form, this.options);\n }\n}\nexports.FormBuilder = FormBuilder;\nFormio.Form = Form;\nFormio.FormBuilder = FormBuilder;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/Embed.js?");
|
10824
|
+
eval("\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nvar _a;\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.FormBuilder = exports.Form = exports.Formio = void 0;\nconst CDN_js_1 = __importDefault(__webpack_require__(/*! ./CDN.js */ \"./lib/cjs/CDN.js\"));\nclass Formio {\n static setLicense(license, norecurse = false) {\n _a.license = license;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setLicense(license);\n }\n }\n static setBaseUrl(url, norecurse = false) {\n _a.baseUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setBaseUrl(url);\n }\n }\n static setApiUrl(url, norecurse = false) {\n _a.baseUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setApiUrl(url);\n }\n }\n static setProjectUrl(url, norecurse = false) {\n _a.projectUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setProjectUrl(url);\n }\n }\n static setAppUrl(url, norecurse = false) {\n _a.projectUrl = url;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setAppUrl(url);\n }\n }\n static setPathType(type, norecurse = false) {\n _a.pathType = type;\n if (!norecurse && _a.FormioClass) {\n _a.FormioClass.setPathType(type);\n }\n }\n static debug(...args) {\n if (_a.config.debug) {\n console.log(...args);\n }\n }\n static clearCache() {\n if (_a.FormioClass) {\n _a.FormioClass.clearCache();\n }\n }\n static global(prop, flag = '') {\n const globalValue = window[prop];\n if (flag && globalValue && !globalValue[flag]) {\n return null;\n }\n _a.debug(`Getting global ${prop}`, globalValue);\n return globalValue;\n }\n static use(module) {\n if (_a.FormioClass && _a.FormioClass.isRenderer) {\n _a.FormioClass.use(module);\n }\n else {\n _a.modules.push(module);\n }\n }\n static createElement(type, attrs, children) {\n const element = document.createElement(type);\n if (!attrs) {\n return element;\n }\n Object.keys(attrs).forEach(key => {\n element.setAttribute(key, attrs[key]);\n });\n (children || []).forEach(child => {\n element.appendChild(_a.createElement(child.tag, child.attrs, child.children));\n });\n return element;\n }\n static addScript(wrapper, src, name, flag = '') {\n return __awaiter(this, void 0, void 0, function* () {\n if (!src) {\n return Promise.resolve();\n }\n if (typeof src !== 'string' && src.length) {\n return Promise.all(src.map(ref => _a.addScript(wrapper, ref)));\n }\n if (name && _a.global(name, flag)) {\n _a.debug(`${name} already loaded.`);\n return Promise.resolve(_a.global(name));\n }\n _a.debug('Adding Script', src);\n try {\n wrapper.appendChild(_a.createElement('script', {\n src\n }));\n }\n catch (err) {\n _a.debug(err);\n return Promise.resolve();\n }\n if (!name) {\n return Promise.resolve();\n }\n return new Promise((resolve) => {\n _a.debug(`Waiting to load ${name}`);\n const wait = setInterval(() => {\n if (_a.global(name, flag)) {\n clearInterval(wait);\n _a.debug(`${name} loaded.`);\n resolve(_a.global(name));\n }\n }, 100);\n });\n });\n }\n static addStyles(wrapper, href) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!href) {\n return;\n }\n if (typeof href !== 'string' && href.length) {\n href.forEach(ref => _a.addStyles(wrapper, ref));\n return;\n }\n _a.debug('Adding Styles', href);\n wrapper.appendChild(_a.createElement('link', {\n rel: 'stylesheet',\n href\n }));\n });\n }\n static submitDone(instance, submission) {\n return __awaiter(this, void 0, void 0, function* () {\n _a.debug('Submision Complete', submission);\n if (_a.config.submitDone) {\n _a.config.submitDone(submission, instance);\n }\n const successMessage = (_a.config.success || '').toString();\n if (successMessage && successMessage.toLowerCase() !== 'false' && instance.element) {\n instance.element.innerHTML = `<div class=\"alert-success\" role=\"alert\">${successMessage}</div>`;\n }\n let returnUrl = _a.config.redirect;\n // Allow form based configuration for return url.\n if (!returnUrl &&\n (instance._form &&\n instance._form.settings &&\n (instance._form.settings.returnUrl ||\n instance._form.settings.redirect))) {\n _a.debug('Return url found in form configuration');\n returnUrl = instance._form.settings.returnUrl || instance._form.settings.redirect;\n }\n if (returnUrl) {\n const formSrc = instance.formio ? instance.formio.formUrl : '';\n const hasQuery = !!returnUrl.match(/\\?/);\n const isOrigin = returnUrl.indexOf(location.origin) === 0;\n returnUrl += hasQuery ? '&' : '?';\n returnUrl += `sub=${submission._id}`;\n if (!isOrigin && formSrc) {\n returnUrl += `&form=${encodeURIComponent(formSrc)}`;\n }\n _a.debug('Return URL', returnUrl);\n window.location.href = returnUrl;\n if (isOrigin) {\n window.location.reload();\n }\n }\n });\n }\n // Return the full script if the builder is being used.\n static formioScript(script, builder) {\n builder = builder || _a.config.includeBuilder;\n if (_a.fullAdded || builder) {\n _a.fullAdded = true;\n return script.replace('formio.form', 'formio.full');\n }\n return script;\n }\n static addLibrary(libWrapper, lib, name) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!lib) {\n return;\n }\n if (lib.dependencies) {\n for (let i = 0; i < lib.dependencies.length; i++) {\n const libName = lib.dependencies[i];\n yield _a.addLibrary(libWrapper, _a.config.libs[libName], libName);\n }\n }\n if (lib.css) {\n yield _a.addStyles((lib.global ? document.body : libWrapper), lib.css);\n }\n if (lib.js) {\n const module = yield _a.addScript((lib.global ? document.body : libWrapper), lib.js, lib.use ? name : false);\n if (lib.use) {\n _a.debug(`Using ${name}`);\n const options = lib.options || {};\n if (!options.license && _a.license) {\n options.license = _a.license;\n }\n _a.use((typeof lib.use === 'function' ? lib.use(module) : module), options);\n }\n }\n if (lib.globalStyle) {\n const style = _a.createElement('style');\n style.type = 'text/css';\n style.innerHTML = lib.globalStyle;\n document.body.appendChild(style);\n }\n });\n }\n static addLoader(wrapper) {\n return __awaiter(this, void 0, void 0, function* () {\n wrapper.appendChild(_a.createElement('div', {\n 'class': 'formio-loader'\n }, [{\n tag: 'div',\n attrs: {\n class: 'loader-wrapper'\n },\n children: [{\n tag: 'div',\n attrs: {\n class: 'loader text-center'\n }\n }]\n }]));\n });\n }\n // eslint-disable-next-line max-statements\n static init(element, options = {}, builder = false) {\n return __awaiter(this, void 0, void 0, function* () {\n _a.cdn = new CDN_js_1.default(_a.config.cdn, _a.config.cdnUrls || {});\n _a.config.libs = _a.config.libs || {\n uswds: {\n dependencies: ['fontawesome'],\n js: `${_a.cdn.uswds}/uswds.min.js`,\n css: `${_a.cdn.uswds}/uswds.min.css`,\n use: true\n },\n fontawesome: {\n // Due to an issue with font-face not loading in the shadowdom (https://issues.chromium.org/issues/41085401), we need\n // to do 2 things. 1.) Load the fonts from the global cdn, and 2.) add the font-face to the global styles on the page.\n css: `https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css`,\n globalStyle: `@font-face {\n font-family: 'FontAwesome';\n src: url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.eot?v=4.7.0');\n src: url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.eot?#iefix&v=4.7.0') format('embedded-opentype'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.woff2?v=4.7.0') format('woff2'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.woff?v=4.7.0') format('woff'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.ttf?v=4.7.0') format('truetype'), url('https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular') format('svg');\n font-weight: normal;\n font-style: normal;\n }`\n },\n bootstrap4: {\n dependencies: ['fontawesome'],\n css: `${_a.cdn.bootstrap4}/css/bootstrap.min.css`\n },\n bootstrap: {\n dependencies: ['bootstrap-icons'],\n css: `${_a.cdn.bootstrap}/css/bootstrap.min.css`\n },\n 'bootstrap-icons': {\n // Due to an issue with font-face not loading in the shadowdom (https://issues.chromium.org/issues/41085401), we need\n // to do 2 things. 1.) Load the fonts from the global cdn, and 2.) add the font-face to the global styles on the page.\n css: 'https://cdn.jsdelivr.net/npm/bootstrap-icons/font/bootstrap-icons.min.css',\n globalStyle: `@font-face {\n font-display: block;\n font-family: \"bootstrap-icons\";\n src: url(\"https://cdn.jsdelivr.net/npm/bootstrap-icons/font/fonts/bootstrap-icons.woff2?dd67030699838ea613ee6dbda90effa6\") format(\"woff2\"),\n url(\"https://cdn.jsdelivr.net/npm/bootstrap-icons/font/fonts/bootstrap-icons.woff?dd67030699838ea613ee6dbda90effa6\") format(\"woff\");\n }`\n }\n };\n // Add all bootswatch templates.\n ['cerulean', 'cosmo', 'cyborg', 'darkly', 'flatly', 'journal', 'litera', 'lumen', 'lux', 'materia', 'minty', 'pulse', 'sandstone', 'simplex', 'sketchy', 'slate', 'solar', 'spacelab', 'superhero', 'united', 'yeti'].forEach((template) => {\n _a.config.libs[template] = {\n dependencies: ['bootstrap-icons'],\n css: `${_a.cdn.bootswatch}/dist/${template}/bootstrap.min.css`\n };\n });\n const id = _a.config.id || `formio-${Math.random().toString(36).substring(7)}`;\n // Create a new wrapper and add the element inside of a new wrapper.\n let wrapper = _a.createElement('div', {\n 'id': `${id}-wrapper`\n });\n element.parentNode.insertBefore(wrapper, element);\n // If we include the libraries, then we will attempt to run this in shadow dom.\n const useShadowDom = _a.config.includeLibs && !_a.config.noshadow && (typeof wrapper.attachShadow === 'function');\n if (useShadowDom) {\n wrapper = wrapper.attachShadow({\n mode: 'open'\n });\n options.shadowRoot = wrapper;\n }\n element.parentNode.removeChild(element);\n wrapper.appendChild(element);\n // If this is inside of shadow dom, then we need to add the styles and scripts to the shadow dom.\n const libWrapper = useShadowDom ? wrapper : document.body;\n // Load the renderer styles.\n yield _a.addStyles(libWrapper, _a.config.embedCSS || `${_a.cdn.js}/formio.embed.css`);\n // Add a loader.\n _a.addLoader(wrapper);\n const formioSrc = _a.config.full ? 'formio.full' : 'formio.form';\n const renderer = _a.config.debug ? formioSrc : `${formioSrc}.min`;\n _a.FormioClass = yield _a.addScript(libWrapper, _a.formioScript(_a.config.script || `${_a.cdn.js}/${renderer}.js`, builder), 'Formio', builder ? 'isBuilder' : 'isRenderer');\n _a.FormioClass.cdn = _a.cdn;\n _a.FormioClass.setBaseUrl(options.baseUrl || _a.baseUrl || _a.config.base);\n _a.FormioClass.setProjectUrl(options.projectUrl || _a.projectUrl || _a.config.project);\n _a.FormioClass.language = _a.language;\n _a.setLicense(_a.license || _a.config.license || false);\n _a.modules.forEach((module) => {\n _a.FormioClass.use(module);\n });\n if (_a.icons) {\n _a.FormioClass.icons = _a.icons;\n }\n if (_a.pathType) {\n _a.FormioClass.setPathType(_a.pathType);\n }\n // Add libraries if they wish to include the libs.\n if (_a.config.template && _a.config.includeLibs) {\n yield _a.addLibrary(libWrapper, _a.config.libs[_a.config.template], _a.config.template);\n }\n if (!_a.config.libraries) {\n _a.config.libraries = _a.config.modules || {};\n }\n // Adding premium if it is provided via the config.\n if (_a.config.premium) {\n _a.config.libraries.premium = _a.config.premium;\n }\n // Allow adding dynamic modules.\n if (_a.config.libraries) {\n for (const name in _a.config.libraries) {\n const lib = _a.config.libraries[name];\n lib.use = lib.use || true;\n yield _a.addLibrary(libWrapper, lib, name);\n }\n }\n yield _a.addStyles(libWrapper, _a.formioScript(_a.config.style || `${_a.cdn.js}/${renderer}.css`, builder));\n if (_a.config.before) {\n yield _a.config.before(_a.FormioClass, element, _a.config);\n }\n _a.FormioClass.license = true;\n _a._formioReady(_a.FormioClass);\n return wrapper;\n });\n }\n // Called after an instance has been created.\n static afterCreate(instance, wrapper, readyEvent) {\n return __awaiter(this, void 0, void 0, function* () {\n const loader = wrapper.querySelector('.formio-loader');\n if (loader) {\n wrapper.removeChild(loader);\n }\n _a.FormioClass.events.emit(readyEvent, instance);\n if (_a.config.after) {\n _a.debug('Calling ready callback');\n _a.config.after(instance, _a.config);\n }\n return instance;\n });\n }\n // Create a new form.\n static createForm(element, form, options = {}) {\n return __awaiter(this, void 0, void 0, function* () {\n if (_a.FormioClass) {\n return _a.FormioClass.createForm(element, form, Object.assign(Object.assign({}, options), { noLoader: true }));\n }\n const wrapper = yield _a.init(element, options);\n return _a.FormioClass.createForm(element, form, Object.assign(Object.assign({}, options), { noLoader: true })).then((instance) => {\n // Set the default submission data.\n if (_a.config.submission) {\n _a.debug('Setting submission', _a.config.submission);\n instance.submission = _a.config.submission;\n }\n // Call the after create method.\n _a.afterCreate(instance, wrapper, 'formEmbedded');\n return instance;\n });\n });\n }\n // Create a form builder.\n static builder(element, form, options = {}) {\n var _b;\n return __awaiter(this, void 0, void 0, function* () {\n if ((_b = _a.FormioClass) === null || _b === void 0 ? void 0 : _b.builder) {\n return _a.FormioClass.builder(element, form, options);\n }\n const wrapper = yield _a.init(element, options, true);\n return _a.FormioClass.builder(element, form, options).then((instance) => {\n _a.afterCreate(instance, wrapper, 'builderEmbedded');\n return instance;\n });\n });\n }\n}\nexports.Formio = Formio;\n_a = Formio;\nFormio.FormioClass = null;\nFormio.config = {};\nFormio.modules = [];\nFormio.icons = '';\nFormio.license = '';\nFormio.formioReady = new Promise((ready, reject) => {\n _a._formioReady = ready;\n _a._formioReadyReject = reject;\n});\nFormio.version = '5.0.0-rc.63';\n// Create a report.\nFormio.Report = {\n create: (element, submission, options = {}) => __awaiter(void 0, void 0, void 0, function* () {\n var _b;\n if ((_b = _a.FormioClass) === null || _b === void 0 ? void 0 : _b.Report) {\n return _a.FormioClass.Report.create(element, submission, options);\n }\n const wrapper = yield _a.init(element, options, true);\n return _a.FormioClass.Report.create(element, submission, options).then((instance) => {\n _a.afterCreate(instance, wrapper, 'reportEmbedded');\n return instance;\n });\n })\n};\nCDN_js_1.default.defaultCDN = Formio.version.includes('rc') ? 'https://cdn.test-form.io' : 'https://cdn.form.io';\nclass Form {\n constructor(element, form, options) {\n this.form = form;\n this.element = element;\n this.options = options || {};\n this.init();\n this.instance = {\n proxy: true,\n ready: this.ready,\n destroy: () => { }\n };\n }\n init() {\n if (this.instance && !this.instance.proxy) {\n this.instance.destroy();\n }\n this.element.innerHTML = '';\n this.ready = this.create().then((instance) => {\n this.instance = instance;\n this.form = instance.form;\n return instance;\n });\n }\n create() {\n return Formio.createForm(this.element, this.form, this.options);\n }\n setForm(form) {\n this.form = form;\n if (this.instance) {\n this.instance.setForm(form);\n }\n }\n setDisplay(display) {\n if (this.instance.proxy) {\n return this.ready;\n }\n this.form.display = display;\n this.instance.destroy();\n this.ready = this.create().then((instance) => {\n this.instance = instance;\n this.setForm(this.form);\n });\n return this.ready;\n }\n}\nexports.Form = Form;\nclass FormBuilder extends Form {\n create() {\n return Formio.builder(this.element, this.form, this.options);\n }\n}\nexports.FormBuilder = FormBuilder;\nFormio.Form = Form;\nFormio.FormBuilder = FormBuilder;\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/Embed.js?");
|
10825
10825
|
|
10826
10826
|
/***/ }),
|
10827
10827
|
|
@@ -10832,7 +10832,7 @@ eval("\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _argument
|
|
10832
10832
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
10833
10833
|
|
10834
10834
|
"use strict";
|
10835
|
-
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.Formio = void 0;\nconst sdk_1 = __webpack_require__(/*! @formio/core/sdk */ \"./node_modules/@formio/core/lib/sdk/index.js\");\nObject.defineProperty(exports, \"Formio\", ({ enumerable: true, get: function () { return sdk_1.Formio; } }));\nconst Embed_1 = __webpack_require__(/*! ./Embed */ \"./lib/cjs/Embed.js\");\nconst CDN_1 = __importDefault(__webpack_require__(/*! ./CDN */ \"./lib/cjs/CDN.js\"));\nconst providers_1 = __importDefault(__webpack_require__(/*! ./providers */ \"./lib/cjs/providers/index.js\"));\nsdk_1.Formio.cdn = new CDN_1.default();\nsdk_1.Formio.Providers = providers_1.default;\nsdk_1.Formio.version = '5.0.0-rc.
|
10835
|
+
eval("\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\nexports.Formio = void 0;\nconst sdk_1 = __webpack_require__(/*! @formio/core/sdk */ \"./node_modules/@formio/core/lib/sdk/index.js\");\nObject.defineProperty(exports, \"Formio\", ({ enumerable: true, get: function () { return sdk_1.Formio; } }));\nconst Embed_1 = __webpack_require__(/*! ./Embed */ \"./lib/cjs/Embed.js\");\nconst CDN_1 = __importDefault(__webpack_require__(/*! ./CDN */ \"./lib/cjs/CDN.js\"));\nconst providers_1 = __importDefault(__webpack_require__(/*! ./providers */ \"./lib/cjs/providers/index.js\"));\nsdk_1.Formio.cdn = new CDN_1.default();\nsdk_1.Formio.Providers = providers_1.default;\nsdk_1.Formio.version = '5.0.0-rc.63';\nCDN_1.default.defaultCDN = sdk_1.Formio.version.includes('rc') ? 'https://cdn.test-form.io' : 'https://cdn.form.io';\nconst isNil = (val) => val === null || val === undefined;\nsdk_1.Formio.prototype.uploadFile = function (storage, file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, uploadStartCallback, abortCallback, multipartOptions) {\n const requestArgs = {\n provider: storage,\n method: 'upload',\n file: file,\n fileName: fileName,\n dir: dir\n };\n fileKey = fileKey || 'file';\n const request = sdk_1.Formio.pluginWait('preRequest', requestArgs)\n .then(() => {\n return sdk_1.Formio.pluginGet('fileRequest', requestArgs)\n .then((result) => {\n if (storage && isNil(result)) {\n const Provider = providers_1.default.getProvider('storage', storage);\n if (Provider) {\n const provider = new Provider(this);\n if (uploadStartCallback) {\n uploadStartCallback();\n }\n return provider.uploadFile(file, fileName, dir, progressCallback, url, options, fileKey, groupPermissions, groupId, abortCallback, multipartOptions);\n }\n else {\n throw ('Storage provider not found');\n }\n }\n return result || { url: '' };\n });\n });\n return sdk_1.Formio.pluginAlter('wrapFileRequestPromise', request, requestArgs);\n};\nsdk_1.Formio.prototype.downloadFile = function (file, options) {\n const requestArgs = {\n method: 'download',\n file: file\n };\n const request = sdk_1.Formio.pluginWait('preRequest', requestArgs)\n .then(() => {\n return sdk_1.Formio.pluginGet('fileRequest', requestArgs)\n .then((result) => {\n if (file.storage && isNil(result)) {\n const Provider = providers_1.default.getProvider('storage', file.storage);\n if (Provider) {\n const provider = new Provider(this);\n return provider.downloadFile(file, options);\n }\n else {\n throw ('Storage provider not found');\n }\n }\n return result || { url: '' };\n });\n });\n return sdk_1.Formio.pluginAlter('wrapFileRequestPromise', request, requestArgs);\n};\nsdk_1.Formio.prototype.deleteFile = function (file, options) {\n const requestArgs = {\n method: 'delete',\n file: file\n };\n const request = sdk_1.Formio.pluginWait('preRequest', requestArgs)\n .then(() => {\n return sdk_1.Formio.pluginGet('fileRequest', requestArgs)\n .then((result) => {\n if (file.storage && isNil(result)) {\n const Provider = providers_1.default.getProvider('storage', file.storage);\n if (Provider) {\n const provider = new Provider(this);\n return provider.deleteFile(file, options);\n }\n else {\n throw ('Storage provider not found');\n }\n }\n return result || { url: '' };\n });\n });\n return sdk_1.Formio.pluginAlter('wrapFileRequestPromise', request, requestArgs);\n};\n// Esnure we proxy the following methods to the FormioEmbed class.\n['setBaseUrl', 'setApiUrl', 'setAppUrl', 'setProjectUrl', 'setPathType', 'setLicense'].forEach((fn) => {\n const baseFn = sdk_1.Formio[fn];\n sdk_1.Formio[fn] = function (arg) {\n const retVal = Embed_1.Formio[fn](arg, true);\n return baseFn ? baseFn.call(this, arg) : retVal;\n };\n});\n// For reverse compatability.\nsdk_1.Formio.Promise = Promise;\nsdk_1.Formio.formioReady = Embed_1.Formio.formioReady;\nsdk_1.Formio.config = Embed_1.Formio.config;\nsdk_1.Formio.builder = Embed_1.Formio.builder;\nsdk_1.Formio.Report = Embed_1.Formio.Report;\nsdk_1.Formio.Form = Embed_1.Formio.Form;\nsdk_1.Formio.FormBuilder = Embed_1.Formio.FormBuilder;\nsdk_1.Formio.use = Embed_1.Formio.use;\nsdk_1.Formio.createForm = Embed_1.Formio.createForm;\nsdk_1.Formio.submitDone = Embed_1.Formio.submitDone;\nsdk_1.Formio.addLibrary = Embed_1.Formio.addLibrary;\nsdk_1.Formio.addLoader = Embed_1.Formio.addLoader;\nsdk_1.Formio.addToGlobal = (global) => {\n if (typeof global === 'object' && !global.Formio) {\n global.Formio = sdk_1.Formio;\n }\n};\nif (typeof __webpack_require__.g !== 'undefined') {\n sdk_1.Formio.addToGlobal(__webpack_require__.g);\n}\nif (typeof window !== 'undefined') {\n sdk_1.Formio.addToGlobal(window);\n}\nEmbed_1.Formio._formioReady(sdk_1.Formio);\n\n\n//# sourceURL=webpack://Formio/./lib/cjs/Formio.js?");
|
10836
10836
|
|
10837
10837
|
/***/ }),
|
10838
10838
|
|