@formio/js 5.0.0-rc.59 → 5.0.0-rc.60

Sign up to get free protection for your applications and to get access to all the features.
Files changed (228) hide show
  1. package/dist/formio.builder.css +8 -8
  2. package/dist/formio.builder.min.css +1 -1
  3. package/dist/formio.embed.js +1 -1
  4. package/dist/formio.embed.min.js +1 -1
  5. package/dist/formio.embed.min.js.LICENSE.txt +1 -1
  6. package/dist/formio.form.css +8 -8
  7. package/dist/formio.form.js +24 -24
  8. package/dist/formio.form.min.css +1 -1
  9. package/dist/formio.form.min.js +1 -1
  10. package/dist/formio.form.min.js.LICENSE.txt +1 -1
  11. package/dist/formio.full.css +8 -8
  12. package/dist/formio.full.js +64 -64
  13. package/dist/formio.full.min.css +1 -1
  14. package/dist/formio.full.min.js +1 -1
  15. package/dist/formio.full.min.js.LICENSE.txt +1 -1
  16. package/dist/formio.js +4 -4
  17. package/dist/formio.min.js +1 -1
  18. package/dist/formio.min.js.LICENSE.txt +1 -1
  19. package/dist/formio.utils.js +2 -2
  20. package/dist/formio.utils.min.js +1 -1
  21. package/dist/formio.utils.min.js.LICENSE.txt +1 -1
  22. package/lib/cjs/Element.d.ts +1 -1
  23. package/lib/cjs/Embed.d.ts +2 -2
  24. package/lib/cjs/Embed.js +10 -10
  25. package/lib/cjs/Form.d.ts +3 -3
  26. package/lib/cjs/FormBuilder.d.ts +42 -3
  27. package/lib/cjs/InlineEmbed.js +2 -2
  28. package/lib/cjs/PDF.d.ts +1 -1
  29. package/lib/cjs/Webform.d.ts +4 -3
  30. package/lib/cjs/Webform.js +2 -1
  31. package/lib/cjs/WebformBuilder.d.ts +1 -1
  32. package/lib/cjs/WebformBuilder.js +8 -2
  33. package/lib/cjs/components/_classes/component/Component.form.d.ts +1 -1
  34. package/lib/cjs/components/_classes/component/Component.form.js +1 -1
  35. package/lib/cjs/components/_classes/component/Component.js +2 -5
  36. package/lib/cjs/components/_classes/component/fixtures/comp6.d.ts +77 -0
  37. package/lib/cjs/components/_classes/component/fixtures/comp6.js +59 -0
  38. package/lib/cjs/components/_classes/component/fixtures/index.d.ts +2 -1
  39. package/lib/cjs/components/_classes/component/fixtures/index.js +3 -1
  40. package/lib/cjs/components/_classes/input/Input.js +6 -4
  41. package/lib/cjs/components/_classes/list/ListComponent.form.d.ts +1 -1
  42. package/lib/cjs/components/_classes/list/ListComponent.form.js +1 -1
  43. package/lib/cjs/components/_classes/nested/NestedComponent.d.ts +7 -7
  44. package/lib/cjs/components/_classes/nested/NestedComponent.form.d.ts +1 -1
  45. package/lib/cjs/components/_classes/nested/NestedComponent.form.js +1 -1
  46. package/lib/cjs/components/address/Address.form.d.ts +1 -1
  47. package/lib/cjs/components/address/Address.form.js +1 -1
  48. package/lib/cjs/components/button/Button.form.d.ts +1 -1
  49. package/lib/cjs/components/button/Button.form.js +1 -1
  50. package/lib/cjs/components/checkbox/Checkbox.form.d.ts +1 -1
  51. package/lib/cjs/components/checkbox/Checkbox.form.js +1 -1
  52. package/lib/cjs/components/columns/Columns.form.d.ts +1 -1
  53. package/lib/cjs/components/columns/Columns.form.js +1 -1
  54. package/lib/cjs/components/container/Container.form.d.ts +1 -1
  55. package/lib/cjs/components/container/Container.form.js +1 -1
  56. package/lib/cjs/components/content/Content.form.d.ts +1 -1
  57. package/lib/cjs/components/content/Content.form.js +1 -1
  58. package/lib/cjs/components/currency/Currency.form.d.ts +1 -1
  59. package/lib/cjs/components/currency/Currency.form.js +1 -1
  60. package/lib/cjs/components/datagrid/DataGrid.form.d.ts +1 -1
  61. package/lib/cjs/components/datagrid/DataGrid.form.js +1 -1
  62. package/lib/cjs/components/datagrid/fixtures/comp-with-checkboxes.d.ts +29 -0
  63. package/lib/cjs/components/datagrid/fixtures/comp-with-checkboxes.js +36 -0
  64. package/lib/cjs/components/datagrid/fixtures/index.d.ts +2 -1
  65. package/lib/cjs/components/datagrid/fixtures/index.js +3 -1
  66. package/lib/cjs/components/datamap/DataMap.form.d.ts +1 -1
  67. package/lib/cjs/components/datamap/DataMap.form.js +1 -1
  68. package/lib/cjs/components/datetime/DateTime.form.d.ts +1 -1
  69. package/lib/cjs/components/datetime/DateTime.form.js +1 -1
  70. package/lib/cjs/components/day/Day.d.ts +1 -1
  71. package/lib/cjs/components/day/Day.form.d.ts +1 -1
  72. package/lib/cjs/components/day/Day.form.js +1 -1
  73. package/lib/cjs/components/day/Day.js +1 -1
  74. package/lib/cjs/components/day/fixtures/comp7.d.ts +109 -0
  75. package/lib/cjs/components/day/fixtures/comp7.js +109 -0
  76. package/lib/cjs/components/day/fixtures/index.d.ts +2 -1
  77. package/lib/cjs/components/day/fixtures/index.js +3 -1
  78. package/lib/cjs/components/editgrid/EditGrid.form.d.ts +1 -1
  79. package/lib/cjs/components/editgrid/EditGrid.form.js +1 -1
  80. package/lib/cjs/components/email/Email.form.d.ts +1 -1
  81. package/lib/cjs/components/email/Email.form.js +1 -1
  82. package/lib/cjs/components/fieldset/Fieldset.form.d.ts +1 -1
  83. package/lib/cjs/components/fieldset/Fieldset.form.js +1 -1
  84. package/lib/cjs/components/file/File.form.d.ts +1 -1
  85. package/lib/cjs/components/file/File.form.js +1 -1
  86. package/lib/cjs/components/file/File.js +1 -2
  87. package/lib/cjs/components/form/Form.form.d.ts +1 -1
  88. package/lib/cjs/components/form/Form.form.js +1 -1
  89. package/lib/cjs/components/form/Form.js +7 -6
  90. package/lib/cjs/components/hidden/Hidden.form.d.ts +1 -1
  91. package/lib/cjs/components/hidden/Hidden.form.js +1 -1
  92. package/lib/cjs/components/html/HTML.form.d.ts +1 -1
  93. package/lib/cjs/components/html/HTML.form.js +1 -1
  94. package/lib/cjs/components/number/Number.form.d.ts +1 -1
  95. package/lib/cjs/components/number/Number.form.js +1 -1
  96. package/lib/cjs/components/panel/Panel.form.d.ts +1 -1
  97. package/lib/cjs/components/panel/Panel.form.js +1 -1
  98. package/lib/cjs/components/password/Password.form.d.ts +1 -1
  99. package/lib/cjs/components/password/Password.form.js +1 -1
  100. package/lib/cjs/components/phonenumber/PhoneNumber.form.d.ts +1 -1
  101. package/lib/cjs/components/phonenumber/PhoneNumber.form.js +1 -1
  102. package/lib/cjs/components/radio/Radio.form.d.ts +1 -1
  103. package/lib/cjs/components/radio/Radio.form.js +1 -1
  104. package/lib/cjs/components/radio/Radio.js +3 -2
  105. package/lib/cjs/components/recaptcha/ReCaptcha.form.d.ts +1 -1
  106. package/lib/cjs/components/recaptcha/ReCaptcha.form.js +1 -1
  107. package/lib/cjs/components/select/Select.form.d.ts +1 -1
  108. package/lib/cjs/components/select/Select.form.js +1 -1
  109. package/lib/cjs/components/select/Select.js +1 -1
  110. package/lib/cjs/components/selectboxes/SelectBoxes.form.d.ts +1 -1
  111. package/lib/cjs/components/selectboxes/SelectBoxes.form.js +1 -1
  112. package/lib/cjs/components/signature/Signature.form.d.ts +1 -1
  113. package/lib/cjs/components/signature/Signature.form.js +1 -1
  114. package/lib/cjs/components/survey/Survey.form.d.ts +1 -1
  115. package/lib/cjs/components/survey/Survey.form.js +1 -1
  116. package/lib/cjs/components/table/Table.form.d.ts +1 -1
  117. package/lib/cjs/components/table/Table.form.js +1 -1
  118. package/lib/cjs/components/tabs/Tabs.form.d.ts +1 -1
  119. package/lib/cjs/components/tabs/Tabs.form.js +1 -1
  120. package/lib/cjs/components/tags/Tags.form.d.ts +1 -1
  121. package/lib/cjs/components/tags/Tags.form.js +1 -1
  122. package/lib/cjs/components/textarea/TextArea.form.d.ts +1 -1
  123. package/lib/cjs/components/textarea/TextArea.form.js +1 -1
  124. package/lib/cjs/components/textfield/TextField.form.d.ts +1 -1
  125. package/lib/cjs/components/textfield/TextField.form.js +1 -1
  126. package/lib/cjs/components/textfield/TextField.js +3 -1
  127. package/lib/cjs/components/time/Time.form.d.ts +1 -1
  128. package/lib/cjs/components/time/Time.form.js +1 -1
  129. package/lib/cjs/components/unknown/Unknown.form.js +1 -1
  130. package/lib/cjs/components/url/Url.form.d.ts +1 -1
  131. package/lib/cjs/components/url/Url.form.js +1 -1
  132. package/lib/cjs/components/well/Well.form.d.ts +1 -1
  133. package/lib/cjs/components/well/Well.form.js +1 -1
  134. package/lib/cjs/formio.form.js +3 -3
  135. package/lib/cjs/providers/address/AzureAddressProvider.d.ts +1 -1
  136. package/lib/cjs/providers/address/GoogleAddressProvider.js +1 -1
  137. package/lib/cjs/providers/storage/util.js +3 -4
  138. package/lib/cjs/templates/index.d.ts +14 -14
  139. package/lib/cjs/translations/en.d.ts +2 -0
  140. package/lib/cjs/translations/en.js +3 -1
  141. package/lib/cjs/utils/ChoicesWrapper.d.ts +1 -1
  142. package/lib/cjs/utils/ChoicesWrapper.js +13 -2
  143. package/lib/cjs/utils/calendarUtils.js +3 -3
  144. package/lib/cjs/utils/formUtils.d.ts +3 -3
  145. package/lib/cjs/utils/formUtils.js +2 -2
  146. package/lib/cjs/utils/utils.d.ts +20 -14
  147. package/lib/cjs/utils/utils.js +82 -72
  148. package/lib/mjs/Element.d.ts +1 -1
  149. package/lib/mjs/Embed.d.ts +2 -2
  150. package/lib/mjs/Form.d.ts +3 -3
  151. package/lib/mjs/FormBuilder.d.ts +42 -3
  152. package/lib/mjs/PDF.d.ts +1 -1
  153. package/lib/mjs/Webform.d.ts +4 -3
  154. package/lib/mjs/Webform.js +2 -1
  155. package/lib/mjs/WebformBuilder.d.ts +1 -1
  156. package/lib/mjs/WebformBuilder.js +8 -2
  157. package/lib/mjs/components/_classes/component/Component.form.d.ts +1 -1
  158. package/lib/mjs/components/_classes/component/Component.js +2 -5
  159. package/lib/mjs/components/_classes/component/fixtures/comp6.d.ts +77 -0
  160. package/lib/mjs/components/_classes/component/fixtures/comp6.js +57 -0
  161. package/lib/mjs/components/_classes/component/fixtures/index.d.ts +2 -1
  162. package/lib/mjs/components/_classes/component/fixtures/index.js +2 -1
  163. package/lib/mjs/components/_classes/input/Input.js +6 -4
  164. package/lib/mjs/components/_classes/list/ListComponent.form.d.ts +1 -1
  165. package/lib/mjs/components/_classes/nested/NestedComponent.d.ts +7 -7
  166. package/lib/mjs/components/_classes/nested/NestedComponent.form.d.ts +1 -1
  167. package/lib/mjs/components/address/Address.form.d.ts +1 -1
  168. package/lib/mjs/components/button/Button.form.d.ts +1 -1
  169. package/lib/mjs/components/checkbox/Checkbox.form.d.ts +1 -1
  170. package/lib/mjs/components/columns/Columns.form.d.ts +1 -1
  171. package/lib/mjs/components/container/Container.form.d.ts +1 -1
  172. package/lib/mjs/components/content/Content.form.d.ts +1 -1
  173. package/lib/mjs/components/currency/Currency.form.d.ts +1 -1
  174. package/lib/mjs/components/datagrid/DataGrid.form.d.ts +1 -1
  175. package/lib/mjs/components/datagrid/fixtures/comp-with-checkboxes.d.ts +29 -0
  176. package/lib/mjs/components/datagrid/fixtures/comp-with-checkboxes.js +34 -0
  177. package/lib/mjs/components/datagrid/fixtures/index.d.ts +2 -1
  178. package/lib/mjs/components/datagrid/fixtures/index.js +2 -1
  179. package/lib/mjs/components/datamap/DataMap.form.d.ts +1 -1
  180. package/lib/mjs/components/datetime/DateTime.form.d.ts +1 -1
  181. package/lib/mjs/components/day/Day.d.ts +1 -1
  182. package/lib/mjs/components/day/Day.form.d.ts +1 -1
  183. package/lib/mjs/components/day/Day.js +1 -1
  184. package/lib/mjs/components/day/fixtures/comp7.d.ts +109 -0
  185. package/lib/mjs/components/day/fixtures/comp7.js +107 -0
  186. package/lib/mjs/components/day/fixtures/index.d.ts +2 -1
  187. package/lib/mjs/components/day/fixtures/index.js +2 -1
  188. package/lib/mjs/components/editgrid/EditGrid.form.d.ts +1 -1
  189. package/lib/mjs/components/email/Email.form.d.ts +1 -1
  190. package/lib/mjs/components/fieldset/Fieldset.form.d.ts +1 -1
  191. package/lib/mjs/components/file/File.form.d.ts +1 -1
  192. package/lib/mjs/components/file/File.js +1 -2
  193. package/lib/mjs/components/form/Form.form.d.ts +1 -1
  194. package/lib/mjs/components/form/Form.js +5 -4
  195. package/lib/mjs/components/hidden/Hidden.form.d.ts +1 -1
  196. package/lib/mjs/components/html/HTML.form.d.ts +1 -1
  197. package/lib/mjs/components/number/Number.form.d.ts +1 -1
  198. package/lib/mjs/components/panel/Panel.form.d.ts +1 -1
  199. package/lib/mjs/components/password/Password.form.d.ts +1 -1
  200. package/lib/mjs/components/phonenumber/PhoneNumber.form.d.ts +1 -1
  201. package/lib/mjs/components/radio/Radio.form.d.ts +1 -1
  202. package/lib/mjs/components/radio/Radio.js +3 -2
  203. package/lib/mjs/components/recaptcha/ReCaptcha.form.d.ts +1 -1
  204. package/lib/mjs/components/select/Select.form.d.ts +1 -1
  205. package/lib/mjs/components/select/Select.js +2 -2
  206. package/lib/mjs/components/selectboxes/SelectBoxes.form.d.ts +1 -1
  207. package/lib/mjs/components/signature/Signature.form.d.ts +1 -1
  208. package/lib/mjs/components/survey/Survey.form.d.ts +1 -1
  209. package/lib/mjs/components/table/Table.form.d.ts +1 -1
  210. package/lib/mjs/components/tabs/Tabs.form.d.ts +1 -1
  211. package/lib/mjs/components/tags/Tags.form.d.ts +1 -1
  212. package/lib/mjs/components/textarea/TextArea.form.d.ts +1 -1
  213. package/lib/mjs/components/textfield/TextField.form.d.ts +1 -1
  214. package/lib/mjs/components/textfield/TextField.js +3 -1
  215. package/lib/mjs/components/time/Time.form.d.ts +1 -1
  216. package/lib/mjs/components/url/Url.form.d.ts +1 -1
  217. package/lib/mjs/components/well/Well.form.d.ts +1 -1
  218. package/lib/mjs/providers/address/AzureAddressProvider.d.ts +1 -1
  219. package/lib/mjs/providers/address/GoogleAddressProvider.js +1 -1
  220. package/lib/mjs/templates/index.d.ts +14 -14
  221. package/lib/mjs/translations/en.d.ts +2 -0
  222. package/lib/mjs/translations/en.js +3 -1
  223. package/lib/mjs/utils/ChoicesWrapper.d.ts +1 -1
  224. package/lib/mjs/utils/ChoicesWrapper.js +13 -2
  225. package/lib/mjs/utils/formUtils.d.ts +3 -3
  226. package/lib/mjs/utils/utils.d.ts +20 -14
  227. package/lib/mjs/utils/utils.js +12 -2
  228. package/package.json +11 -11
@@ -17,7 +17,7 @@ export class AzureAddressProvider extends AddressProvider {
17
17
  */
18
18
  get defaultOptions(): {
19
19
  params: {
20
- 'api-version': string;
20
+ "api-version": string;
21
21
  typeahead: string;
22
22
  };
23
23
  };
@@ -55,7 +55,7 @@ class GoogleAddressProvider extends AddressProvider_1.AddressProvider {
55
55
  var _a;
56
56
  super(options);
57
57
  this.setAutocompleteOptions();
58
- let src = 'https://maps.googleapis.com/maps/api/js?v=quarterly&libraries=places&callback=googleMapsCallback';
58
+ let src = 'https://maps.googleapis.com/maps/api/js?v=quarterly&libraries=places&loading=async&callback=googleMapsCallback';
59
59
  if ((_a = options.params) === null || _a === void 0 ? void 0 : _a.key) {
60
60
  src += `&key=${options.params.key}`;
61
61
  }
@@ -12,7 +12,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
12
12
  });
13
13
  };
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.withRetries = void 0;
15
+ exports.withRetries = withRetries;
16
16
  /**
17
17
  * Function to be retried
18
18
  * @callback RetryFunction
@@ -28,12 +28,11 @@ exports.withRetries = void 0;
28
28
  * @returns {Promise<any>} The result of the function execution.
29
29
  * @throws {Error} When all retries have failed.
30
30
  */
31
- function withRetries(fn, args, retries = 3, err = null) {
32
- return __awaiter(this, void 0, void 0, function* () {
31
+ function withRetries(fn_1, args_1) {
32
+ return __awaiter(this, arguments, void 0, function* (fn, args, retries = 3, err = null) {
33
33
  if (!retries) {
34
34
  throw new Error(err);
35
35
  }
36
36
  return fn(...args).catch(() => withRetries(fn, args, retries - 1, err));
37
37
  });
38
38
  }
39
- exports.withRetries = withRetries;
@@ -39,20 +39,20 @@ declare namespace _default {
39
39
  defaultIconset: string;
40
40
  iconClass: (iconset: any, name: any, spinning: any) => string;
41
41
  cssClasses: {
42
- 'border-default': string;
43
- 'formio-tab-panel-active': string;
44
- 'formio-tab-link-active': string;
45
- 'formio-tab-link-container-active': string;
46
- 'formio-form-error': string;
47
- 'formio-form-alert': string;
48
- 'formio-label-error': string;
49
- 'formio-input-error': string;
50
- 'formio-alert-danger': string;
51
- 'formio-alert-success': string;
52
- 'formio-alert-warning': string;
53
- 'formio-modal-cancel-button': string;
54
- 'formio-modal-confirm-button': string;
55
- 'form-group': string;
42
+ "border-default": string;
43
+ "formio-tab-panel-active": string;
44
+ "formio-tab-link-active": string;
45
+ "formio-tab-link-container-active": string;
46
+ "formio-form-error": string;
47
+ "formio-form-alert": string;
48
+ "formio-label-error": string;
49
+ "formio-input-error": string;
50
+ "formio-alert-danger": string;
51
+ "formio-alert-success": string;
52
+ "formio-alert-warning": string;
53
+ "formio-modal-cancel-button": string;
54
+ "formio-modal-confirm-button": string;
55
+ "form-group": string;
56
56
  };
57
57
  address: {
58
58
  form: string;
@@ -72,5 +72,7 @@ declare namespace _default {
72
72
  let reCaptchaTokenValidationError: string;
73
73
  let reCaptchaTokenNotSpecifiedError: string;
74
74
  let apiKey: string;
75
+ let typeRemaining: string;
76
+ let typeCount: string;
75
77
  }
76
78
  export default _default;
@@ -73,5 +73,7 @@ exports.default = {
73
73
  submitButtonAriaLabel: 'Submit Form button. Click to submit the form',
74
74
  reCaptchaTokenValidationError: 'ReCAPTCHA: Token validation error',
75
75
  reCaptchaTokenNotSpecifiedError: 'ReCAPTCHA: Token is not specified in submission',
76
- apiKey: 'API Key is not unique: {{key}}'
76
+ apiKey: 'API Key is not unique: {{key}}',
77
+ typeRemaining: '{{ remaining }} {{ type }} remaining.',
78
+ typeCount: '{{ count }} {{ type }}'
77
79
  };
@@ -24,7 +24,7 @@ declare class ChoicesWrapper extends Choices {
24
24
  _onEnterKey(args: any): void;
25
25
  _onDirectionKey(...args: any[]): void;
26
26
  timeout: NodeJS.Timeout | undefined;
27
- _selectHighlightedChoice(activeItems: any): void;
27
+ _selectHighlightedChoice(): void;
28
28
  _onKeyDown(event: any): void;
29
29
  onSelectValue({ event, activeItems, hasActiveDropdown }: {
30
30
  event: any;
@@ -105,10 +105,21 @@ class ChoicesWrapper extends choices_js_1.default {
105
105
  this._selectHighlightedChoice(activeItems);
106
106
  }
107
107
  }
108
- _selectHighlightedChoice(activeItems) {
108
+ _selectHighlightedChoice() {
109
109
  const highlightedChoice = this.dropdown.getChild(`.${this.config.classNames.highlightedState}`);
110
110
  if (highlightedChoice) {
111
- this._handleChoiceAction(activeItems, highlightedChoice);
111
+ const id = highlightedChoice.dataset.id;
112
+ const choice = id && this._store.getChoiceById(id);
113
+ this._addItem({
114
+ value: choice.value,
115
+ label: choice.label,
116
+ choiceId: choice.id,
117
+ groupId: choice.groupId,
118
+ customProperties: choice.customProperties,
119
+ placeholder: choice.placeholder,
120
+ keyCode: choice.keyCode
121
+ });
122
+ this._triggerChange(choice.value);
112
123
  }
113
124
  event.preventDefault();
114
125
  }
@@ -3,7 +3,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.checkInvalidDate = exports.lessOrGreater = exports.CALENDAR_ERROR_MESSAGES = void 0;
6
+ exports.CALENDAR_ERROR_MESSAGES = void 0;
7
+ exports.lessOrGreater = lessOrGreater;
8
+ exports.checkInvalidDate = checkInvalidDate;
7
9
  const moment_1 = __importDefault(require("moment"));
8
10
  const lodash_1 = __importDefault(require("lodash"));
9
11
  exports.CALENDAR_ERROR_MESSAGES = {
@@ -64,7 +66,6 @@ function lessOrGreater(value, format, maxDate, minDate) {
64
66
  result
65
67
  };
66
68
  }
67
- exports.lessOrGreater = lessOrGreater;
68
69
  /**
69
70
  * Checks the entered date for validity.
70
71
  * @param {string} value - The value to check.
@@ -126,4 +127,3 @@ function checkInvalidDate(value, format, minDate, maxDate) {
126
127
  }
127
128
  return buildResponse('', true);
128
129
  }
129
- exports.checkInvalidDate = checkInvalidDate;
@@ -4,7 +4,7 @@
4
4
  * @param {object} query - The query to use when searching for the components.
5
5
  * @returns {import('@formio/core').Component[]} - The result of the component that is found.
6
6
  */
7
- export function findComponents(components: import('@formio/core').Component[], query: object): import('@formio/core').Component[];
7
+ export function findComponents(components: import("@formio/core").Component[], query: object): import("@formio/core").Component[];
8
8
  export const flattenComponents: typeof Utils.flattenComponents;
9
9
  export const guid: typeof Utils.guid;
10
10
  export const uniqueName: typeof Utils.uniqueName;
@@ -16,8 +16,8 @@ export const isComponentModelType: typeof Utils.isComponentModelType;
16
16
  export const isComponentNestedDataType: typeof Utils.isComponentNestedDataType;
17
17
  export const componentPath: typeof Utils.componentPath;
18
18
  export const componentChildPath: any;
19
- export const eachComponentDataAsync: (components: Component[], data: DataObject, fn: AsyncComponentDataCallback, path?: string | undefined, index?: number | undefined, parent?: any, includeAll?: boolean | undefined) => Promise<void>;
20
- export const eachComponentData: (components: Component[], data: DataObject, fn: ComponentDataCallback, path?: string | undefined, index?: number | undefined, parent?: any, includeAll?: boolean | undefined) => void;
19
+ export const eachComponentDataAsync: (components: Component[], data: DataObject, fn: AsyncComponentDataCallback, path?: string, index?: number, parent?: any, includeAll?: boolean) => Promise<void>;
20
+ export const eachComponentData: (components: Component[], data: DataObject, fn: ComponentDataCallback, path?: string, index?: number, parent?: any, includeAll?: boolean) => void;
21
21
  export const getComponentKey: typeof Utils.getComponentKey;
22
22
  export const getContextualRowPath: typeof Utils.getContextualRowPath;
23
23
  export const getContextualRowData: typeof Utils.getContextualRowData;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.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;
3
+ exports.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 = void 0;
4
+ exports.findComponents = findComponents;
4
5
  const core_1 = require("@formio/core");
5
6
  const { 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;
6
7
  exports.flattenComponents = flattenComponents;
@@ -50,4 +51,3 @@ function findComponents(components, query) {
50
51
  console.warn('formio.js/utils findComponents is deprecated. Use searchComponents instead.');
51
52
  return searchComponents(components, query);
52
53
  }
53
- exports.findComponents = findComponents;
@@ -7,7 +7,7 @@
7
7
  * @param {import('@formio/core').EvaluatorOptions} options - The evaluator options.
8
8
  * @returns {*} - The result of the evaluation.
9
9
  */
10
- export function evaluate(func: Function | string | object, args: any, ret: string, interpolate: boolean, options?: import('@formio/core').EvaluatorOptions): any;
10
+ export function evaluate(func: Function | string | object, args: any, ret: string, interpolate: boolean, options?: import("@formio/core").EvaluatorOptions): any;
11
11
  /**
12
12
  * Returns a random compoennt ID.
13
13
  * @returns {string} - A random component ID.
@@ -55,7 +55,7 @@ export function isMongoId(text: string): boolean;
55
55
  * @param {import('@formio/core').Submission} submission - A submission object.
56
56
  * @param {*} rowData - The contextual row data for the component.
57
57
  */
58
- export function checkCalculated(component: import('@formio/core').Component, submission: import('@formio/core').Submission, rowData: any): void;
58
+ export function checkCalculated(component: import("@formio/core").Component, submission: import("@formio/core").Submission, rowData: any): void;
59
59
  /**
60
60
  * Check if a simple conditional evaluates to true.
61
61
  * @param {import('@formio/core').Component} component - The component to check for the conditional.
@@ -65,7 +65,7 @@ export function checkCalculated(component: import('@formio/core').Component, sub
65
65
  * @param {import('../../src/components/_classes/component/Component').Component} instance - The instance of the component.
66
66
  * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.
67
67
  */
68
- export function checkSimpleConditional(component: import('@formio/core').Component, condition: import('@formio/core').SimpleConditional, row: any, data: any, instance: any): boolean;
68
+ export function checkSimpleConditional(component: import("@formio/core").Component, condition: import("@formio/core").SimpleConditional, row: any, data: any, instance: import("../../src/components/_classes/component/Component").Component): boolean;
69
69
  /**
70
70
  * Returns a components normalized value.
71
71
  * @param {string} compPath - The full path to the component.
@@ -86,7 +86,7 @@ export function getComponentActualValue(compPath: string, data: any, row: any):
86
86
  * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.
87
87
  * @returns {*} - The result of the evaulation.
88
88
  */
89
- export function checkCustomConditional(component: import('@formio/core').Component, custom: string, row: any, data: any, form: import('@formio/core').Form, variable: string, onError: any, instance: any): any;
89
+ export function checkCustomConditional(component: import("@formio/core").Component, custom: string, row: any, data: any, form: import("@formio/core").Form, variable: string, onError: any, instance: import("../../src/components/_classes/component/Component").Component): any;
90
90
  /**
91
91
  * Check a component for JSON conditionals.
92
92
  * @param {import('@formio/core').Component} component - The component
@@ -97,7 +97,7 @@ export function checkCustomConditional(component: import('@formio/core').Compone
97
97
  * @param {*} onError - Custom return value if there is an error.
98
98
  * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.
99
99
  */
100
- export function checkJsonConditional(component: import('@formio/core').Component, json: import('@formio/core').JSONConditional, row: any, data: any, form: import('@formio/core').Form, onError: any): boolean;
100
+ export function checkJsonConditional(component: import("@formio/core").Component, json: import("@formio/core").JSONConditional, row: any, data: any, form: import("@formio/core").Form, onError: any): boolean;
101
101
  /**
102
102
  * Checks the conditions for a provided component and data.
103
103
  * @param {import('@formio/core').Component} component - The component to check for the condition.
@@ -107,7 +107,7 @@ export function checkJsonConditional(component: import('@formio/core').Component
107
107
  * @param {import('../../src/components/_classes/component/Component').Component} instance - The component instance.
108
108
  * @returns {boolean} - TRUE if the condition is true; FALSE otherwise.
109
109
  */
110
- export function checkCondition(component: import('@formio/core').Component, row: any, data: any, form: import('@formio/core').Form, instance: any): boolean;
110
+ export function checkCondition(component: import("@formio/core").Component, row: any, data: any, form: import("@formio/core").Form, instance: import("../../src/components/_classes/component/Component").Component): boolean;
111
111
  /**
112
112
  * Test a trigger on a component.
113
113
  * @param {import('@formio/core').Component} component - The component to test the trigger against.
@@ -118,7 +118,7 @@ export function checkCondition(component: import('@formio/core').Component, row:
118
118
  * @param {any} instance - The component that is performing the trigger.
119
119
  * @returns {boolean} - TRUE if the trigger should fire; FALSE otherwise.
120
120
  */
121
- export function checkTrigger(component: import('@formio/core').Component, trigger: any, row: import('@formio/core').DataObject, data: import('@formio/core').DataObject, form: import('@formio/core').Form, instance: any): boolean;
121
+ export function checkTrigger(component: import("@formio/core").Component, trigger: import("@formio/core").LogicTrigger, row: import("@formio/core").DataObject, data: import("@formio/core").DataObject, form: import("@formio/core").Form, instance: any): boolean;
122
122
  /**
123
123
  * Sets a property on a component via an executed Logic action.
124
124
  * @param {import('@formio/core').Component} component - The component to set the property on.
@@ -129,7 +129,13 @@ export function checkTrigger(component: import('@formio/core').Component, trigge
129
129
  * @param {any} instance - The component instance.
130
130
  * @returns {import('@formio/core').Component} - The modified component.
131
131
  */
132
- export function setActionProperty(component: import('@formio/core').Component, action: any, result: string, row: import('@formio/core').DataObject, data: import('@formio/core').DataObject, instance: any): import('@formio/core').Component;
132
+ export function setActionProperty(component: import("@formio/core").Component, action: import("@formio/core").LogicAction, result: string, row: import("@formio/core").DataObject, data: import("@formio/core").DataObject, instance: any): import("@formio/core").Component;
133
+ /**
134
+ * Removes HTML tags from string e.g. <div>Hello World</div> => Hello World
135
+ * @param {string} str - The string to remove HTML tags from.
136
+ * @returns {string} - The string without HTML tags.
137
+ */
138
+ export function removeHTML(str: string): string;
133
139
  /**
134
140
  * Unescape HTML characters like &lt, &gt, &amp and etc.
135
141
  * @param {string} str - The string to unescape.
@@ -287,7 +293,7 @@ export function getNumberSeparators(lang?: string): {
287
293
  * @param {number} defaultLimit - The default limit to use if none is provided in the component.
288
294
  * @returns {number} - The number of decimal places allowed.
289
295
  */
290
- export function getNumberDecimalLimit(component: import('@formio/core').Component, defaultLimit: number): number;
296
+ export function getNumberDecimalLimit(component: import("@formio/core").Component, defaultLimit: number): number;
291
297
  /**
292
298
  * Returns the currency affixes for a specific language.
293
299
  * @param {object} arg0 - The arguments object.
@@ -312,7 +318,7 @@ export function getCurrencyAffixes({ currency, decimalLimit, decimalSeparator, l
312
318
  * @param {import('@formio/core').Component} component - The component to fetch the field data for.
313
319
  * @returns {*} - The field data.
314
320
  */
315
- export function fieldData(data: import('@formio/core').DataObject, component: import('@formio/core').Component): any;
321
+ export function fieldData(data: import("@formio/core").DataObject, component: import("@formio/core").Component): any;
316
322
  /**
317
323
  * Delays function execution with possibility to execute function synchronously or cancel it.
318
324
  * @param {Function} fn - Function to delay
@@ -410,7 +416,7 @@ export function fastCloneDeep(obj: any): any;
410
416
  * @param {import('@formio/core').Component} componentJson - The JSON of a component.
411
417
  * @returns {bool} - TRUE if the component is an input component; FALSE otherwise.
412
418
  */
413
- export function isInputComponent(componentJson: import('@formio/core').Component): bool;
419
+ export function isInputComponent(componentJson: import("@formio/core").Component): bool;
414
420
  /**
415
421
  * Takes a component path, and returns a component path array.
416
422
  * @param {string} pathStr - The path string to convert to an array.
@@ -460,7 +466,7 @@ export function getComponentPathWithoutIndicies(path?: string): string;
460
466
  * @param {string} path - Path to the component
461
467
  * @returns {string} - Path to the component
462
468
  */
463
- export function getComponentPath(component: import('@formio/core').Component, path?: string): string;
469
+ export function getComponentPath(component: import("@formio/core").Component, path?: string): string;
464
470
  /**
465
471
  * Returns a parent component of the passed component instance skipping all the Layout components
466
472
  * @param {Component} componentInstance - The component to check for the parent.
@@ -492,7 +498,7 @@ export function getFocusableElements(element: HTMLElement): NodeList<HTMLElement
492
498
  * @param {import('@formio/core').Component} fullSchema - The component schema
493
499
  * @returns {Array<string>|null} - The saved types for the component
494
500
  */
495
- export function getComponentSavedTypes(fullSchema: import('@formio/core').Component): Array<string> | null;
501
+ export function getComponentSavedTypes(fullSchema: import("@formio/core").Component): Array<string> | null;
496
502
  /**
497
503
  * Returns the template keys inside the template code.
498
504
  * @param {string} template - The template to get the keys from.
@@ -504,7 +510,7 @@ export function getItemTemplateKeys(template: string): Array<string>;
504
510
  * @param {import('@formio/core').Component} comp - The component to check.
505
511
  * @returns {boolean} - TRUE if the component is a select resource with an object for its value; FALSE otherwise.
506
512
  */
507
- export function isSelectResourceWithObjectValue(comp?: import('@formio/core').Component): boolean;
513
+ export function isSelectResourceWithObjectValue(comp?: import("@formio/core").Component): boolean;
508
514
  export * from "./formUtils";
509
515
  /**
510
516
  * Map values through unfold and return first non-nil value.