@formio/js 5.0.0-rc.19 → 5.0.0-rc.21

Sign up to get free protection for your applications and to get access to all the features.
Files changed (370) hide show
  1. package/README.md +1 -1
  2. package/dist/formio.builder.css +14 -22
  3. package/dist/formio.builder.min.css +1 -1
  4. package/dist/formio.embed.css +1 -40
  5. package/dist/formio.embed.js +2 -90
  6. package/dist/formio.embed.min.css +1 -1
  7. package/dist/formio.embed.min.js +1 -1
  8. package/dist/formio.embed.min.js.LICENSE.txt +1 -1
  9. package/dist/formio.form.css +10 -2
  10. package/dist/formio.form.js +1267 -1103
  11. package/dist/formio.form.min.css +1 -1
  12. package/dist/formio.form.min.js +1 -1
  13. package/dist/formio.form.min.js.LICENSE.txt +3 -8
  14. package/dist/formio.full.css +14 -22
  15. package/dist/formio.full.js +1302 -1127
  16. package/dist/formio.full.min.css +1 -1
  17. package/dist/formio.full.min.js +1 -1
  18. package/dist/formio.full.min.js.LICENSE.txt +3 -8
  19. package/dist/formio.js +713 -626
  20. package/dist/formio.min.js +1 -1
  21. package/dist/formio.min.js.LICENSE.txt +2 -7
  22. package/dist/formio.utils.js +220 -13
  23. package/dist/formio.utils.min.js +1 -1
  24. package/dist/formio.utils.min.js.LICENSE.txt +2 -7
  25. package/lib/cjs/CDN.d.ts +1 -0
  26. package/lib/cjs/CDN.js +2 -1
  27. package/lib/cjs/Element.js +7 -2
  28. package/lib/cjs/Embed.d.ts +21 -1
  29. package/lib/cjs/Embed.js +211 -308
  30. package/lib/cjs/Form.d.ts +9 -6
  31. package/lib/cjs/Form.js +53 -11
  32. package/lib/cjs/PDF.d.ts +11 -3
  33. package/lib/cjs/PDF.js +4 -5
  34. package/lib/cjs/PDFBuilder.js +2 -3
  35. package/lib/cjs/Webform.d.ts +10 -13
  36. package/lib/cjs/Webform.js +46 -125
  37. package/lib/cjs/WebformBuilder.d.ts +6 -1
  38. package/lib/cjs/WebformBuilder.js +105 -65
  39. package/lib/cjs/Wizard.d.ts +8 -5
  40. package/lib/cjs/Wizard.js +12 -12
  41. package/lib/cjs/WizardBuilder.d.ts +6 -4
  42. package/lib/cjs/WizardBuilder.js +20 -3
  43. package/lib/cjs/addons/FormioAddon.d.ts +1 -1
  44. package/lib/cjs/addons/FormioAddon.js +1 -2
  45. package/lib/cjs/components/_classes/component/Component.d.ts +24 -8
  46. package/lib/cjs/components/_classes/component/Component.js +44 -14
  47. package/lib/cjs/components/_classes/input/Input.d.ts +1 -1
  48. package/lib/cjs/components/_classes/input/Input.js +1 -2
  49. package/lib/cjs/components/_classes/list/ListComponent.d.ts +4 -0
  50. package/lib/cjs/components/_classes/list/ListComponent.js +43 -6
  51. package/lib/cjs/components/_classes/multivalue/Multivalue.d.ts +1 -0
  52. package/lib/cjs/components/_classes/multivalue/Multivalue.js +10 -4
  53. package/lib/cjs/components/_classes/nested/NestedComponent.d.ts +5 -2
  54. package/lib/cjs/components/_classes/nested/NestedComponent.js +9 -10
  55. package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +1 -0
  56. package/lib/cjs/components/_classes/nestedarray/NestedArrayComponent.js +4 -0
  57. package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.d.ts +1 -0
  58. package/lib/cjs/components/_classes/nesteddata/NestedDataComponent.js +4 -0
  59. package/lib/cjs/components/address/Address.d.ts +8 -0
  60. package/lib/cjs/components/address/Address.js +5 -0
  61. package/lib/cjs/components/button/Button.d.ts +1 -0
  62. package/lib/cjs/components/button/Button.js +5 -3
  63. package/lib/cjs/components/checkbox/Checkbox.d.ts +41 -0
  64. package/lib/cjs/components/checkbox/Checkbox.js +32 -5
  65. package/lib/cjs/components/columns/Columns.d.ts +2 -0
  66. package/lib/cjs/components/columns/Columns.js +4 -0
  67. package/lib/cjs/components/container/Container.d.ts +1 -0
  68. package/lib/cjs/components/container/Container.js +4 -0
  69. package/lib/cjs/components/content/Content.d.ts +2 -0
  70. package/lib/cjs/components/content/Content.js +4 -2
  71. package/lib/cjs/components/currency/editForm/Currency.edit.data.d.ts +14 -2
  72. package/lib/cjs/components/currency/editForm/Currency.edit.data.js +4 -0
  73. package/lib/cjs/components/currency/editForm/Currency.edit.display.js +4 -0
  74. package/lib/cjs/components/datagrid/DataGrid.d.ts +1 -0
  75. package/lib/cjs/components/datagrid/DataGrid.js +8 -1
  76. package/lib/cjs/components/datamap/DataMap.d.ts +1 -0
  77. package/lib/cjs/components/datamap/DataMap.js +4 -0
  78. package/lib/cjs/components/datetime/DateTime.d.ts +23 -0
  79. package/lib/cjs/components/datetime/DateTime.js +20 -1
  80. package/lib/cjs/components/day/Day.d.ts +22 -1
  81. package/lib/cjs/components/day/Day.js +20 -6
  82. package/lib/cjs/components/day/fixtures/comp3.js +2 -2
  83. package/lib/cjs/components/editgrid/EditGrid.d.ts +4 -3
  84. package/lib/cjs/components/editgrid/EditGrid.js +11 -6
  85. package/lib/cjs/components/editgrid/fixtures/comp-with-custom-default-value.d.ts +190 -0
  86. package/lib/cjs/components/editgrid/fixtures/comp-with-custom-default-value.js +227 -0
  87. package/lib/cjs/components/editgrid/fixtures/comp15.d.ts +54 -0
  88. package/lib/cjs/components/editgrid/fixtures/comp15.js +51 -0
  89. package/lib/cjs/components/editgrid/fixtures/index.d.ts +3 -1
  90. package/lib/cjs/components/editgrid/fixtures/index.js +5 -1
  91. package/lib/cjs/components/fieldset/Fieldset.d.ts +2 -0
  92. package/lib/cjs/components/fieldset/Fieldset.js +4 -0
  93. package/lib/cjs/components/file/File.d.ts +28 -6
  94. package/lib/cjs/components/file/File.js +40 -15
  95. package/lib/cjs/components/file/editForm/File.edit.file.d.ts +62 -0
  96. package/lib/cjs/components/file/editForm/File.edit.file.js +29 -2
  97. package/lib/cjs/components/form/Form.d.ts +4 -0
  98. package/lib/cjs/components/form/Form.js +12 -10
  99. package/lib/cjs/components/hidden/Hidden.d.ts +1 -0
  100. package/lib/cjs/components/hidden/Hidden.js +1 -0
  101. package/lib/cjs/components/html/HTML.d.ts +2 -0
  102. package/lib/cjs/components/html/HTML.js +4 -0
  103. package/lib/cjs/components/number/Number.d.ts +24 -1
  104. package/lib/cjs/components/number/Number.js +18 -6
  105. package/lib/cjs/components/panel/Panel.d.ts +1 -0
  106. package/lib/cjs/components/panel/Panel.js +3 -0
  107. package/lib/cjs/components/phonenumber/PhoneNumber.form.js +9 -0
  108. package/lib/cjs/components/radio/Radio.d.ts +24 -3
  109. package/lib/cjs/components/radio/Radio.js +89 -18
  110. package/lib/cjs/components/recaptcha/ReCaptcha.d.ts +2 -1
  111. package/lib/cjs/components/recaptcha/ReCaptcha.js +7 -5
  112. package/lib/cjs/components/resource/Resource.d.ts +7 -0
  113. package/lib/cjs/components/resource/Resource.js +0 -1
  114. package/lib/cjs/components/resource/editForm/Resource.edit.display.js +1 -1
  115. package/lib/cjs/components/select/Select.d.ts +25 -5
  116. package/lib/cjs/components/select/Select.js +51 -51
  117. package/lib/cjs/components/selectboxes/SelectBoxes.d.ts +37 -0
  118. package/lib/cjs/components/selectboxes/SelectBoxes.js +60 -25
  119. package/lib/cjs/components/selectboxes/fixtures/comp4.d.ts +30 -27
  120. package/lib/cjs/components/selectboxes/fixtures/comp4.js +47 -32
  121. package/lib/cjs/components/selectboxes/fixtures/comp6.d.ts +14 -0
  122. package/lib/cjs/components/selectboxes/fixtures/comp6.js +15 -0
  123. package/lib/cjs/components/selectboxes/fixtures/index.d.ts +2 -1
  124. package/lib/cjs/components/selectboxes/fixtures/index.js +3 -1
  125. package/lib/cjs/components/signature/Signature.d.ts +22 -1
  126. package/lib/cjs/components/signature/Signature.js +16 -3
  127. package/lib/cjs/components/survey/Survey.d.ts +21 -0
  128. package/lib/cjs/components/survey/Survey.js +9 -0
  129. package/lib/cjs/components/table/Table.d.ts +2 -0
  130. package/lib/cjs/components/table/Table.js +4 -0
  131. package/lib/cjs/components/tabs/Tabs.d.ts +2 -0
  132. package/lib/cjs/components/tabs/Tabs.js +4 -0
  133. package/lib/cjs/components/tags/Tags.d.ts +21 -0
  134. package/lib/cjs/components/tags/Tags.js +11 -0
  135. package/lib/cjs/components/textarea/TextArea.d.ts +3 -2
  136. package/lib/cjs/components/textarea/TextArea.js +4 -5
  137. package/lib/cjs/components/textarea/fixtures/comp4.d.ts +30 -0
  138. package/lib/cjs/components/textarea/fixtures/comp4.js +27 -0
  139. package/lib/cjs/components/textarea/fixtures/index.d.ts +2 -1
  140. package/lib/cjs/components/textarea/fixtures/index.js +3 -1
  141. package/lib/cjs/components/textfield/TextField.d.ts +22 -0
  142. package/lib/cjs/components/textfield/TextField.js +11 -3
  143. package/lib/cjs/components/time/Time.d.ts +11 -0
  144. package/lib/cjs/components/time/Time.js +6 -1
  145. package/lib/cjs/components/tree/Tree.d.ts +5 -4
  146. package/lib/cjs/components/tree/Tree.form.js +5 -0
  147. package/lib/cjs/components/tree/Tree.js +8 -9
  148. package/lib/cjs/components/tree/editForm/Tree.edit.display.d.ts +9 -0
  149. package/lib/cjs/components/tree/editForm/Tree.edit.display.js +12 -0
  150. package/lib/cjs/components/well/Well.d.ts +2 -0
  151. package/lib/cjs/components/well/Well.js +4 -0
  152. package/lib/cjs/formio.embed.d.ts +2 -1
  153. package/lib/cjs/formio.embed.js +96 -1
  154. package/lib/cjs/formio.form.d.ts +4 -3
  155. package/lib/cjs/formio.form.js +17 -8
  156. package/lib/cjs/licenses/Licenses.d.ts +7 -0
  157. package/lib/cjs/licenses/Licenses.js +22 -0
  158. package/lib/cjs/licenses/index.d.ts +2 -0
  159. package/lib/cjs/licenses/index.js +7 -0
  160. package/lib/cjs/providers/Providers.d.ts +31 -11
  161. package/lib/cjs/providers/address/GoogleAddressProvider.d.ts +2 -2
  162. package/lib/cjs/providers/address/GoogleAddressProvider.js +2 -3
  163. package/lib/cjs/providers/processor/fileProcessor.d.ts +1 -1
  164. package/lib/cjs/providers/processor/fileProcessor.js +1 -5
  165. package/lib/cjs/providers/storage/azure.d.ts +10 -1
  166. package/lib/cjs/providers/storage/azure.js +7 -2
  167. package/lib/cjs/providers/storage/base64.d.ts +2 -2
  168. package/lib/cjs/providers/storage/base64.js +2 -6
  169. package/lib/cjs/providers/storage/dropbox.d.ts +2 -2
  170. package/lib/cjs/providers/storage/dropbox.js +2 -6
  171. package/lib/cjs/providers/storage/googleDrive.d.ts +3 -2
  172. package/lib/cjs/providers/storage/googleDrive.js +6 -6
  173. package/lib/cjs/providers/storage/indexeddb.d.ts +3 -3
  174. package/lib/cjs/providers/storage/indexeddb.js +9 -13
  175. package/lib/cjs/providers/storage/s3.d.ts +11 -1
  176. package/lib/cjs/providers/storage/s3.js +5 -2
  177. package/lib/cjs/providers/storage/uploadAdapter.js +1 -5
  178. package/lib/cjs/providers/storage/url.d.ts +2 -2
  179. package/lib/cjs/providers/storage/url.js +12 -8
  180. package/lib/cjs/providers/storage/xhr.d.ts +1 -1
  181. package/lib/cjs/providers/storage/xhr.js +1 -2
  182. package/lib/cjs/templates/index.d.ts +226 -1
  183. package/lib/cjs/utils/Evaluator.js +4 -33
  184. package/lib/cjs/utils/i18n.d.ts +16 -0
  185. package/lib/cjs/utils/i18n.js +88 -0
  186. package/lib/cjs/utils/utils.d.ts +11 -1
  187. package/lib/cjs/utils/utils.js +29 -10
  188. package/lib/cjs/validator/Validator.d.ts +30 -2
  189. package/lib/cjs/validator/Validator.js +32 -9
  190. package/lib/cjs/validator/rules/Select.js +1 -2
  191. package/lib/cjs/validator/rules/Unique.d.ts +1 -1
  192. package/lib/cjs/validator/rules/Unique.js +1 -2
  193. package/lib/cjs/widgets/CalendarWidget.d.ts +1 -0
  194. package/lib/cjs/widgets/InputWidget.d.ts +1 -1
  195. package/lib/cjs/widgets/InputWidget.js +1 -2
  196. package/lib/mjs/CDN.d.ts +1 -0
  197. package/lib/mjs/CDN.js +2 -1
  198. package/lib/mjs/Element.js +6 -2
  199. package/lib/mjs/Embed.d.ts +21 -1
  200. package/lib/mjs/Embed.js +208 -319
  201. package/lib/mjs/Form.d.ts +9 -6
  202. package/lib/mjs/Form.js +53 -11
  203. package/lib/mjs/PDF.d.ts +11 -3
  204. package/lib/mjs/PDF.js +4 -5
  205. package/lib/mjs/PDFBuilder.js +2 -3
  206. package/lib/mjs/Webform.d.ts +10 -13
  207. package/lib/mjs/Webform.js +46 -128
  208. package/lib/mjs/WebformBuilder.d.ts +6 -1
  209. package/lib/mjs/WebformBuilder.js +103 -65
  210. package/lib/mjs/Wizard.d.ts +8 -5
  211. package/lib/mjs/Wizard.js +12 -12
  212. package/lib/mjs/WizardBuilder.d.ts +6 -4
  213. package/lib/mjs/WizardBuilder.js +20 -3
  214. package/lib/mjs/addons/FormioAddon.d.ts +1 -1
  215. package/lib/mjs/addons/FormioAddon.js +1 -2
  216. package/lib/mjs/components/_classes/component/Component.d.ts +24 -8
  217. package/lib/mjs/components/_classes/component/Component.js +44 -14
  218. package/lib/mjs/components/_classes/input/Input.d.ts +1 -1
  219. package/lib/mjs/components/_classes/input/Input.js +1 -2
  220. package/lib/mjs/components/_classes/list/ListComponent.d.ts +4 -0
  221. package/lib/mjs/components/_classes/list/ListComponent.js +43 -5
  222. package/lib/mjs/components/_classes/multivalue/Multivalue.d.ts +1 -0
  223. package/lib/mjs/components/_classes/multivalue/Multivalue.js +10 -4
  224. package/lib/mjs/components/_classes/nested/NestedComponent.d.ts +5 -2
  225. package/lib/mjs/components/_classes/nested/NestedComponent.js +9 -10
  226. package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.d.ts +1 -0
  227. package/lib/mjs/components/_classes/nestedarray/NestedArrayComponent.js +4 -0
  228. package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.d.ts +1 -0
  229. package/lib/mjs/components/_classes/nesteddata/NestedDataComponent.js +4 -0
  230. package/lib/mjs/components/address/Address.d.ts +8 -0
  231. package/lib/mjs/components/address/Address.js +5 -0
  232. package/lib/mjs/components/button/Button.d.ts +1 -0
  233. package/lib/mjs/components/button/Button.js +6 -4
  234. package/lib/mjs/components/checkbox/Checkbox.d.ts +41 -0
  235. package/lib/mjs/components/checkbox/Checkbox.js +36 -5
  236. package/lib/mjs/components/columns/Columns.d.ts +2 -0
  237. package/lib/mjs/components/columns/Columns.js +4 -0
  238. package/lib/mjs/components/container/Container.d.ts +1 -0
  239. package/lib/mjs/components/container/Container.js +5 -1
  240. package/lib/mjs/components/content/Content.d.ts +2 -0
  241. package/lib/mjs/components/content/Content.js +4 -2
  242. package/lib/mjs/components/currency/editForm/Currency.edit.data.d.ts +14 -2
  243. package/lib/mjs/components/currency/editForm/Currency.edit.data.js +4 -0
  244. package/lib/mjs/components/currency/editForm/Currency.edit.display.js +4 -0
  245. package/lib/mjs/components/datagrid/DataGrid.d.ts +1 -0
  246. package/lib/mjs/components/datagrid/DataGrid.js +8 -1
  247. package/lib/mjs/components/datamap/DataMap.d.ts +1 -0
  248. package/lib/mjs/components/datamap/DataMap.js +5 -1
  249. package/lib/mjs/components/datetime/DateTime.d.ts +23 -0
  250. package/lib/mjs/components/datetime/DateTime.js +27 -1
  251. package/lib/mjs/components/day/Day.d.ts +22 -1
  252. package/lib/mjs/components/day/Day.js +24 -7
  253. package/lib/mjs/components/day/fixtures/comp3.js +2 -2
  254. package/lib/mjs/components/editgrid/EditGrid.d.ts +4 -3
  255. package/lib/mjs/components/editgrid/EditGrid.js +11 -6
  256. package/lib/mjs/components/editgrid/fixtures/comp-with-custom-default-value.d.ts +190 -0
  257. package/lib/mjs/components/editgrid/fixtures/comp-with-custom-default-value.js +225 -0
  258. package/lib/mjs/components/editgrid/fixtures/comp15.d.ts +54 -0
  259. package/lib/mjs/components/editgrid/fixtures/comp15.js +49 -0
  260. package/lib/mjs/components/editgrid/fixtures/index.d.ts +3 -1
  261. package/lib/mjs/components/editgrid/fixtures/index.js +3 -1
  262. package/lib/mjs/components/fieldset/Fieldset.d.ts +2 -0
  263. package/lib/mjs/components/fieldset/Fieldset.js +4 -0
  264. package/lib/mjs/components/file/File.d.ts +28 -6
  265. package/lib/mjs/components/file/File.js +44 -16
  266. package/lib/mjs/components/file/editForm/File.edit.file.d.ts +62 -0
  267. package/lib/mjs/components/file/editForm/File.edit.file.js +29 -2
  268. package/lib/mjs/components/form/Form.d.ts +4 -0
  269. package/lib/mjs/components/form/Form.js +13 -11
  270. package/lib/mjs/components/hidden/Hidden.d.ts +1 -0
  271. package/lib/mjs/components/hidden/Hidden.js +1 -0
  272. package/lib/mjs/components/html/HTML.d.ts +2 -0
  273. package/lib/mjs/components/html/HTML.js +4 -0
  274. package/lib/mjs/components/number/Number.d.ts +24 -1
  275. package/lib/mjs/components/number/Number.js +23 -7
  276. package/lib/mjs/components/panel/Panel.d.ts +1 -0
  277. package/lib/mjs/components/panel/Panel.js +3 -0
  278. package/lib/mjs/components/phonenumber/PhoneNumber.form.js +9 -0
  279. package/lib/mjs/components/radio/Radio.d.ts +24 -3
  280. package/lib/mjs/components/radio/Radio.js +93 -19
  281. package/lib/mjs/components/recaptcha/ReCaptcha.d.ts +2 -1
  282. package/lib/mjs/components/recaptcha/ReCaptcha.js +7 -5
  283. package/lib/mjs/components/resource/Resource.d.ts +7 -0
  284. package/lib/mjs/components/resource/Resource.js +0 -1
  285. package/lib/mjs/components/resource/editForm/Resource.edit.display.js +1 -1
  286. package/lib/mjs/components/select/Select.d.ts +25 -5
  287. package/lib/mjs/components/select/Select.js +55 -52
  288. package/lib/mjs/components/selectboxes/SelectBoxes.d.ts +37 -0
  289. package/lib/mjs/components/selectboxes/SelectBoxes.js +63 -25
  290. package/lib/mjs/components/selectboxes/fixtures/comp4.d.ts +30 -27
  291. package/lib/mjs/components/selectboxes/fixtures/comp4.js +47 -32
  292. package/lib/mjs/components/selectboxes/fixtures/comp6.d.ts +14 -0
  293. package/lib/mjs/components/selectboxes/fixtures/comp6.js +13 -0
  294. package/lib/mjs/components/selectboxes/fixtures/index.d.ts +2 -1
  295. package/lib/mjs/components/selectboxes/fixtures/index.js +2 -1
  296. package/lib/mjs/components/signature/Signature.d.ts +22 -1
  297. package/lib/mjs/components/signature/Signature.js +19 -3
  298. package/lib/mjs/components/survey/Survey.d.ts +21 -0
  299. package/lib/mjs/components/survey/Survey.js +13 -1
  300. package/lib/mjs/components/table/Table.d.ts +2 -0
  301. package/lib/mjs/components/table/Table.js +4 -0
  302. package/lib/mjs/components/tabs/Tabs.d.ts +2 -0
  303. package/lib/mjs/components/tabs/Tabs.js +4 -0
  304. package/lib/mjs/components/tags/Tags.d.ts +21 -0
  305. package/lib/mjs/components/tags/Tags.js +14 -0
  306. package/lib/mjs/components/textarea/TextArea.d.ts +3 -2
  307. package/lib/mjs/components/textarea/TextArea.js +4 -5
  308. package/lib/mjs/components/textarea/fixtures/comp4.d.ts +30 -0
  309. package/lib/mjs/components/textarea/fixtures/comp4.js +25 -0
  310. package/lib/mjs/components/textarea/fixtures/index.d.ts +2 -1
  311. package/lib/mjs/components/textarea/fixtures/index.js +2 -1
  312. package/lib/mjs/components/textfield/TextField.d.ts +22 -0
  313. package/lib/mjs/components/textfield/TextField.js +14 -3
  314. package/lib/mjs/components/time/Time.d.ts +11 -0
  315. package/lib/mjs/components/time/Time.js +12 -1
  316. package/lib/mjs/components/tree/Tree.d.ts +5 -4
  317. package/lib/mjs/components/tree/Tree.form.js +5 -0
  318. package/lib/mjs/components/tree/Tree.js +8 -9
  319. package/lib/mjs/components/tree/editForm/Tree.edit.display.d.ts +9 -0
  320. package/lib/mjs/components/tree/editForm/Tree.edit.display.js +10 -0
  321. package/lib/mjs/components/well/Well.d.ts +2 -0
  322. package/lib/mjs/components/well/Well.js +4 -0
  323. package/lib/mjs/formio.embed.d.ts +2 -1
  324. package/lib/mjs/formio.embed.js +96 -2
  325. package/lib/mjs/formio.form.d.ts +4 -3
  326. package/lib/mjs/formio.form.js +16 -8
  327. package/lib/mjs/licenses/Licenses.d.ts +7 -0
  328. package/lib/mjs/licenses/Licenses.js +17 -0
  329. package/lib/mjs/licenses/index.d.ts +2 -0
  330. package/lib/mjs/licenses/index.js +2 -0
  331. package/lib/mjs/providers/Providers.d.ts +31 -11
  332. package/lib/mjs/providers/address/GoogleAddressProvider.d.ts +2 -2
  333. package/lib/mjs/providers/address/GoogleAddressProvider.js +2 -3
  334. package/lib/mjs/providers/processor/fileProcessor.d.ts +1 -1
  335. package/lib/mjs/providers/processor/fileProcessor.js +1 -2
  336. package/lib/mjs/providers/storage/azure.d.ts +10 -1
  337. package/lib/mjs/providers/storage/azure.js +7 -2
  338. package/lib/mjs/providers/storage/base64.d.ts +2 -2
  339. package/lib/mjs/providers/storage/base64.js +2 -3
  340. package/lib/mjs/providers/storage/dropbox.d.ts +2 -2
  341. package/lib/mjs/providers/storage/dropbox.js +2 -3
  342. package/lib/mjs/providers/storage/googleDrive.d.ts +3 -2
  343. package/lib/mjs/providers/storage/googleDrive.js +6 -3
  344. package/lib/mjs/providers/storage/indexeddb.d.ts +3 -3
  345. package/lib/mjs/providers/storage/indexeddb.js +9 -10
  346. package/lib/mjs/providers/storage/s3.d.ts +11 -1
  347. package/lib/mjs/providers/storage/s3.js +5 -2
  348. package/lib/mjs/providers/storage/uploadAdapter.js +1 -2
  349. package/lib/mjs/providers/storage/url.d.ts +2 -2
  350. package/lib/mjs/providers/storage/url.js +12 -5
  351. package/lib/mjs/providers/storage/xhr.d.ts +1 -1
  352. package/lib/mjs/providers/storage/xhr.js +1 -2
  353. package/lib/mjs/templates/index.d.ts +226 -1
  354. package/lib/mjs/utils/Evaluator.js +4 -33
  355. package/lib/mjs/utils/i18n.d.ts +16 -0
  356. package/lib/mjs/utils/i18n.js +81 -0
  357. package/lib/mjs/utils/utils.d.ts +11 -1
  358. package/lib/mjs/utils/utils.js +27 -9
  359. package/lib/mjs/validator/Validator.d.ts +30 -2
  360. package/lib/mjs/validator/Validator.js +31 -9
  361. package/lib/mjs/validator/rules/Select.js +1 -2
  362. package/lib/mjs/validator/rules/Unique.d.ts +1 -1
  363. package/lib/mjs/validator/rules/Unique.js +1 -2
  364. package/lib/mjs/widgets/CalendarWidget.d.ts +1 -0
  365. package/lib/mjs/widgets/InputWidget.d.ts +1 -1
  366. package/lib/mjs/widgets/InputWidget.js +1 -2
  367. package/package.json +18 -15
  368. package/types/index.d.ts +1 -0
  369. package/types/licenses.d.ts +7 -0
  370. package/types/utils.d.ts +2 -0
@@ -4,6 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const lodash_1 = __importDefault(require("lodash"));
7
+ const utils_1 = require("../../utils/utils");
7
8
  const Radio_1 = __importDefault(require("../radio/Radio"));
8
9
  class SelectBoxesComponent extends Radio_1.default {
9
10
  static schema(...extend) {
@@ -24,6 +25,25 @@ class SelectBoxesComponent extends Radio_1.default {
24
25
  schema: SelectBoxesComponent.schema()
25
26
  };
26
27
  }
28
+ static get serverConditionSettings() {
29
+ return SelectBoxesComponent.conditionOperatorsSettings;
30
+ }
31
+ static get conditionOperatorsSettings() {
32
+ return Object.assign(Object.assign({}, super.conditionOperatorsSettings), { valueComponent(classComp) {
33
+ return {
34
+ type: 'select',
35
+ dataSrc: 'custom',
36
+ valueProperty: 'value',
37
+ valueType: 'string',
38
+ data: {
39
+ custom: `values = ${classComp && classComp.values ? JSON.stringify(classComp.values) : []}`
40
+ },
41
+ };
42
+ } });
43
+ }
44
+ static savedValueTypes(schema) {
45
+ return (0, utils_1.getComponentSavedTypes)(schema) || [utils_1.componentValueTypes.object];
46
+ }
27
47
  constructor(...args) {
28
48
  super(...args);
29
49
  this.validators = this.validators.concat('minSelectedCount', 'maxSelectedCount', 'availableValueProperty');
@@ -109,6 +129,16 @@ class SelectBoxesComponent extends Radio_1.default {
109
129
  value[val] = true;
110
130
  });
111
131
  }
132
+ const checkedValues = lodash_1.default.keys(lodash_1.default.pickBy(value, (val) => val));
133
+ if (this.isSelectURL && this.templateData && lodash_1.default.every(checkedValues, (val) => this.templateData[val])) {
134
+ const submission = this.root.submission;
135
+ if (!submission.metadata.selectData) {
136
+ submission.metadata.selectData = {};
137
+ }
138
+ const selectData = [];
139
+ checkedValues.forEach((value) => selectData.push(this.templateData[value]));
140
+ lodash_1.default.set(submission.metadata.selectData, this.path, selectData);
141
+ }
112
142
  return value;
113
143
  }
114
144
  /**
@@ -139,6 +169,9 @@ class SelectBoxesComponent extends Radio_1.default {
139
169
  if (!value) {
140
170
  return '';
141
171
  }
172
+ if (this.isSelectURL) {
173
+ return (0, lodash_1.default)(value).pickBy((val) => val).keys().join(', ');
174
+ }
142
175
  return (0, lodash_1.default)(this.component.values || [])
143
176
  .filter((v) => value[v.value])
144
177
  .map('label')
@@ -156,7 +189,7 @@ class SelectBoxesComponent extends Radio_1.default {
156
189
  key = valuesKeys.find((k) => (input === null || input === void 0 ? void 0 : input.value.toString()) === k);
157
190
  }
158
191
  const isChecked = value[key];
159
- if (isChecked && key) {
192
+ if ((isChecked && key) || (this.isSelectURL && !this.shouldLoad && this.listData && lodash_1.default.findIndex(this.selectData, this.listData[index]) !== -1)) {
160
193
  //add class to container when selected
161
194
  this.addClass(wrapper, this.optionSelectedClass);
162
195
  //change "checked" attribute
@@ -181,31 +214,33 @@ class SelectBoxesComponent extends Radio_1.default {
181
214
  checkComponentValidity(data, dirty, rowData, options) {
182
215
  const minCount = this.component.validate.minSelectedCount;
183
216
  const maxCount = this.component.validate.maxSelectedCount;
184
- const isValid = this.isValid(data, dirty);
185
- if ((maxCount || minCount) && !this.shouldSkipValidation(data, dirty, rowData)) {
186
- const count = Object.keys(this.validationValue).reduce((total, key) => {
187
- if (this.validationValue[key]) {
188
- total++;
217
+ if (!this.shouldSkipValidation(data, dirty, rowData)) {
218
+ const isValid = this.isValid(data, dirty);
219
+ if ((maxCount || minCount)) {
220
+ const count = Object.keys(this.validationValue).reduce((total, key) => {
221
+ if (this.validationValue[key]) {
222
+ total++;
223
+ }
224
+ return total;
225
+ }, 0);
226
+ // Disable the rest of inputs if the max amount is already checked
227
+ if (maxCount && count >= maxCount) {
228
+ this.setInputsDisabled(true, true);
229
+ }
230
+ else if (maxCount && !this.shouldDisabled) {
231
+ this.setInputsDisabled(false);
232
+ }
233
+ if (!isValid && maxCount && count > maxCount) {
234
+ const message = this.t(this.component.maxSelectedCountMessage || 'You can only select up to {{maxCount}} items.', { maxCount });
235
+ this.setCustomValidity(message, dirty);
236
+ return false;
237
+ }
238
+ else if (!isValid && minCount && count < minCount) {
239
+ this.setInputsDisabled(false);
240
+ const message = this.t(this.component.minSelectedCountMessage || 'You must select at least {{minCount}} items.', { minCount });
241
+ this.setCustomValidity(message, dirty);
242
+ return false;
189
243
  }
190
- return total;
191
- }, 0);
192
- // Disable the rest of inputs if the max amount is already checked
193
- if (maxCount && count >= maxCount) {
194
- this.setInputsDisabled(true, true);
195
- }
196
- else if (maxCount && !this.shouldDisabled) {
197
- this.setInputsDisabled(false);
198
- }
199
- if (!isValid && maxCount && count > maxCount) {
200
- const message = this.t(this.component.maxSelectedCountMessage || 'You can only select up to {{maxCount}} items.', { maxCount });
201
- this.setCustomValidity(message, dirty);
202
- return false;
203
- }
204
- else if (!isValid && minCount && count < minCount) {
205
- this.setInputsDisabled(false);
206
- const message = this.t(this.component.minSelectedCountMessage || 'You must select at least {{minCount}} items.', { minCount });
207
- this.setCustomValidity(message, dirty);
208
- return false;
209
244
  }
210
245
  }
211
246
  return super.checkComponentValidity(data, dirty, rowData, options);
@@ -11,39 +11,46 @@ declare namespace _default {
11
11
  key: string;
12
12
  type: string;
13
13
  input: boolean;
14
- optionsLabelPosition?: undefined;
15
- defaultValue?: undefined;
16
- values?: undefined;
17
- validate?: undefined;
18
14
  conditional?: undefined;
19
- inputType?: undefined;
15
+ components?: undefined;
20
16
  disableOnInvalid?: undefined;
21
17
  } | {
22
18
  label: string;
23
- optionsLabelPosition: string;
24
19
  tableView: boolean;
25
- defaultValue: {
26
- '1': boolean;
27
- '2': boolean;
28
- '3': boolean;
29
- };
30
- values: {
31
- label: string;
32
- value: string;
33
- shortcut: string;
34
- }[];
35
- validate: {
36
- minSelectedCount: number;
37
- };
38
20
  key: string;
39
21
  conditional: {
40
22
  show: boolean;
41
- when: string;
42
- eq: boolean;
23
+ conjunction: string;
24
+ conditions: {
25
+ component: string;
26
+ operator: string;
27
+ value: boolean;
28
+ }[];
43
29
  };
44
30
  type: string;
45
31
  input: boolean;
46
- inputType: string;
32
+ components: {
33
+ label: string;
34
+ optionsLabelPosition: string;
35
+ tableView: boolean;
36
+ defaultValue: {
37
+ '1': boolean;
38
+ '2': boolean;
39
+ '3': boolean;
40
+ };
41
+ values: {
42
+ label: string;
43
+ value: string;
44
+ shortcut: string;
45
+ }[];
46
+ validate: {
47
+ minSelectedCount: number;
48
+ };
49
+ key: string;
50
+ type: string;
51
+ input: boolean;
52
+ inputType: string;
53
+ }[];
47
54
  disableOnInvalid?: undefined;
48
55
  } | {
49
56
  type: string;
@@ -52,12 +59,8 @@ declare namespace _default {
52
59
  disableOnInvalid: boolean;
53
60
  input: boolean;
54
61
  tableView: boolean;
55
- optionsLabelPosition?: undefined;
56
- defaultValue?: undefined;
57
- values?: undefined;
58
- validate?: undefined;
59
62
  conditional?: undefined;
60
- inputType?: undefined;
63
+ components?: undefined;
61
64
  })[];
62
65
  }
63
66
  export default _default;
@@ -16,43 +16,58 @@ exports.default = {
16
16
  input: true
17
17
  },
18
18
  {
19
- label: 'Select Boxes',
20
- optionsLabelPosition: 'right',
19
+ label: 'Container',
21
20
  tableView: false,
22
- defaultValue: {
23
- '1': false,
24
- '2': false,
25
- '3': false
26
- },
27
- values: [
28
- {
29
- label: '1',
30
- value: '1',
31
- shortcut: ''
32
- },
33
- {
34
- label: '2',
35
- value: '2',
36
- shortcut: ''
37
- },
38
- {
39
- label: '3',
40
- value: '3',
41
- shortcut: ''
42
- }
43
- ],
44
- validate: {
45
- minSelectedCount: 1
46
- },
47
- key: 'selectBoxes1',
21
+ key: 'container',
48
22
  conditional: {
49
23
  show: true,
50
- when: 'checkbox',
51
- eq: true
24
+ conjunction: 'all',
25
+ conditions: [
26
+ {
27
+ component: 'checkbox',
28
+ operator: 'isEqual',
29
+ value: true
30
+ }
31
+ ]
52
32
  },
53
- type: 'selectboxes',
33
+ type: 'container',
54
34
  input: true,
55
- inputType: 'checkbox'
35
+ components: [
36
+ {
37
+ label: 'Select Boxes',
38
+ optionsLabelPosition: 'right',
39
+ tableView: false,
40
+ defaultValue: {
41
+ '1': false,
42
+ '2': false,
43
+ '3': false
44
+ },
45
+ values: [
46
+ {
47
+ label: '1',
48
+ value: '1',
49
+ shortcut: ''
50
+ },
51
+ {
52
+ label: '2',
53
+ value: '2',
54
+ shortcut: ''
55
+ },
56
+ {
57
+ label: '3',
58
+ value: '3',
59
+ shortcut: ''
60
+ }
61
+ ],
62
+ validate: {
63
+ minSelectedCount: 1
64
+ },
65
+ key: 'selectBoxes',
66
+ type: 'selectboxes',
67
+ input: true,
68
+ inputType: 'checkbox'
69
+ }
70
+ ]
56
71
  },
57
72
  {
58
73
  type: 'button',
@@ -0,0 +1,14 @@
1
+ declare namespace _default {
2
+ const label: string;
3
+ const dataSrc: string;
4
+ namespace data {
5
+ const url: string;
6
+ }
7
+ const valueProperty: string;
8
+ const template: string;
9
+ const key: string;
10
+ const type: string;
11
+ const input: boolean;
12
+ const inputType: string;
13
+ }
14
+ export default _default;
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = {
4
+ label: 'Select Boxes',
5
+ dataSrc: 'url',
6
+ data: {
7
+ url: 'https://cdn.rawgit.com/mshafrir/2646763/raw/states_titlecase.json'
8
+ },
9
+ valueProperty: 'abbreviation',
10
+ template: '<span>{{ item.name }}</span>',
11
+ key: 'selectBoxes',
12
+ type: 'selectboxes',
13
+ input: true,
14
+ inputType: 'checkbox',
15
+ };
@@ -3,4 +3,5 @@ import comp2 from './comp2';
3
3
  import comp3 from './comp3';
4
4
  import comp4 from './comp4';
5
5
  import comp5 from './comp5';
6
- export { comp1, comp2, comp3, comp4, comp5 };
6
+ import comp6 from './comp6';
7
+ export { comp1, comp2, comp3, comp4, comp5, comp6 };
@@ -3,7 +3,7 @@ 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.comp5 = exports.comp4 = exports.comp3 = exports.comp2 = exports.comp1 = void 0;
6
+ exports.comp6 = exports.comp5 = exports.comp4 = exports.comp3 = exports.comp2 = exports.comp1 = void 0;
7
7
  const comp1_1 = __importDefault(require("./comp1"));
8
8
  exports.comp1 = comp1_1.default;
9
9
  const comp2_1 = __importDefault(require("./comp2"));
@@ -14,3 +14,5 @@ const comp4_1 = __importDefault(require("./comp4"));
14
14
  exports.comp4 = comp4_1.default;
15
15
  const comp5_1 = __importDefault(require("./comp5"));
16
16
  exports.comp5 = comp5_1.default;
17
+ const comp6_1 = __importDefault(require("./comp6"));
18
+ exports.comp6 = comp6_1.default;
@@ -7,6 +7,27 @@ export default class SignatureComponent extends Input {
7
7
  documentation: string;
8
8
  schema: any;
9
9
  };
10
+ static get serverConditionSettings(): {
11
+ operators: string[];
12
+ constructor: Function;
13
+ toString(): string;
14
+ toLocaleString(): string;
15
+ valueOf(): Object;
16
+ hasOwnProperty(v: PropertyKey): boolean;
17
+ isPrototypeOf(v: Object): boolean;
18
+ propertyIsEnumerable(v: PropertyKey): boolean;
19
+ };
20
+ static get conditionOperatorsSettings(): {
21
+ operators: string[];
22
+ constructor: Function;
23
+ toString(): string;
24
+ toLocaleString(): string;
25
+ valueOf(): Object;
26
+ hasOwnProperty(v: PropertyKey): boolean;
27
+ isPrototypeOf(v: Object): boolean;
28
+ propertyIsEnumerable(v: PropertyKey): boolean;
29
+ };
30
+ static savedValueTypes(schema: any): string[];
10
31
  currentWidth: any;
11
32
  scale: any;
12
33
  ratio: number | undefined;
@@ -17,7 +38,7 @@ export default class SignatureComponent extends Input {
17
38
  checkSize(force: any, scale: any): void;
18
39
  signaturePad: SignaturePad | null | undefined;
19
40
  observer: _ResizeObserver | null | undefined;
20
- getValueAsString(value: any): "Yes" | "No";
41
+ getValueAsString(value: any): "" | "Yes" | "No";
21
42
  focus(): void;
22
43
  setDataToSigaturePad(): void;
23
44
  }
@@ -7,6 +7,7 @@ const signature_pad_1 = __importDefault(require("signature_pad"));
7
7
  const resize_observer_polyfill_1 = __importDefault(require("resize-observer-polyfill"));
8
8
  const Input_1 = __importDefault(require("../_classes/input/Input"));
9
9
  const lodash_1 = __importDefault(require("lodash"));
10
+ const utils_1 = require("../../utils/utils");
10
11
  class SignatureComponent extends Input_1.default {
11
12
  static schema(...extend) {
12
13
  return Input_1.default.schema({
@@ -33,12 +34,21 @@ class SignatureComponent extends Input_1.default {
33
34
  schema: SignatureComponent.schema()
34
35
  };
35
36
  }
37
+ static get serverConditionSettings() {
38
+ return SignatureComponent.conditionOperatorsSettings;
39
+ }
40
+ static get conditionOperatorsSettings() {
41
+ return Object.assign(Object.assign({}, super.conditionOperatorsSettings), { operators: ['isEmpty', 'isNotEmpty'] });
42
+ }
43
+ static savedValueTypes(schema) {
44
+ schema = schema || {};
45
+ return (0, utils_1.getComponentSavedTypes)(schema) || [utils_1.componentValueTypes.string];
46
+ }
36
47
  init() {
37
48
  var _a, _b, _c, _d, _e;
38
49
  super.init();
39
50
  this.currentWidth = 0;
40
51
  this.scale = 1;
41
- this.ratio = 1;
42
52
  if (!this.component.width) {
43
53
  this.component.width = '100%';
44
54
  }
@@ -135,9 +145,9 @@ class SignatureComponent extends Input_1.default {
135
145
  this.scale = force ? scale : this.scale;
136
146
  this.currentWidth = this.refs.padBody.offsetWidth;
137
147
  const width = this.currentWidth * this.scale;
138
- this.refs.canvas.width = width;
139
148
  const height = this.ratio ? width / this.ratio : this.refs.padBody.offsetHeight * this.scale;
140
- const maxHeight = this.refs.padBody.offsetHeight * this.scale;
149
+ const maxHeight = this.ratio ? height : this.refs.padBody.offsetHeight * this.scale;
150
+ this.refs.canvas.width = width;
141
151
  this.refs.canvas.height = height > maxHeight ? maxHeight : height;
142
152
  this.refs.canvas.style.maxWidth = `${this.currentWidth * this.scale}px`;
143
153
  this.refs.canvas.style.maxHeight = `${maxHeight}px`;
@@ -231,6 +241,9 @@ class SignatureComponent extends Input_1.default {
231
241
  super.detach();
232
242
  }
233
243
  getValueAsString(value) {
244
+ if (lodash_1.default.isUndefined(value) && this.inDataTable) {
245
+ return '';
246
+ }
234
247
  return value ? 'Yes' : 'No';
235
248
  }
236
249
  focus() {
@@ -7,6 +7,27 @@ export default class SurveyComponent extends Field {
7
7
  documentation: string;
8
8
  schema: any;
9
9
  };
10
+ static get serverConditionSettings(): {
11
+ operators: string[];
12
+ constructor: Function;
13
+ toString(): string;
14
+ toLocaleString(): string;
15
+ valueOf(): Object;
16
+ hasOwnProperty(v: PropertyKey): boolean;
17
+ isPrototypeOf(v: Object): boolean;
18
+ propertyIsEnumerable(v: PropertyKey): boolean;
19
+ };
20
+ static get conditionOperatorsSettings(): {
21
+ operators: string[];
22
+ constructor: Function;
23
+ toString(): string;
24
+ toLocaleString(): string;
25
+ valueOf(): Object;
26
+ hasOwnProperty(v: PropertyKey): boolean;
27
+ isPrototypeOf(v: Object): boolean;
28
+ propertyIsEnumerable(v: PropertyKey): boolean;
29
+ };
30
+ static savedValueTypes(schema: any): string[];
10
31
  render(): any;
11
32
  setValue(value: any, flags?: {}): boolean;
12
33
  get emptyValue(): {};
@@ -26,6 +26,15 @@ class SurveyComponent extends Field_1.default {
26
26
  schema: SurveyComponent.schema()
27
27
  };
28
28
  }
29
+ static get serverConditionSettings() {
30
+ return SurveyComponent.conditionOperatorsSettings;
31
+ }
32
+ static get conditionOperatorsSettings() {
33
+ return Object.assign(Object.assign({}, super.conditionOperatorsSettings), { operators: ['isEmpty', 'isNotEmpty'] });
34
+ }
35
+ static savedValueTypes(schema) {
36
+ return (0, utils_1.getComponentSavedTypes)(schema) || [utils_1.componentValueTypes.object];
37
+ }
29
38
  get defaultSchema() {
30
39
  return SurveyComponent.schema();
31
40
  }
@@ -8,8 +8,10 @@ export default class TableComponent extends NestedComponent {
8
8
  icon: string;
9
9
  weight: number;
10
10
  documentation: string;
11
+ showPreview: boolean;
11
12
  schema: any;
12
13
  };
14
+ static savedValueTypes(): never[];
13
15
  constructor(...args: any[]);
14
16
  get cellClassName(): string;
15
17
  get tableKey(): string;
@@ -44,9 +44,13 @@ class TableComponent extends NestedComponent_1.default {
44
44
  icon: 'table',
45
45
  weight: 40,
46
46
  documentation: '/userguide/form-building/layout-components#table',
47
+ showPreview: false,
47
48
  schema: TableComponent.schema()
48
49
  };
49
50
  }
51
+ static savedValueTypes() {
52
+ return [];
53
+ }
50
54
  get defaultSchema() {
51
55
  return TableComponent.schema();
52
56
  }
@@ -5,8 +5,10 @@ export default class TabsComponent extends NestedComponent {
5
5
  icon: string;
6
6
  weight: number;
7
7
  documentation: string;
8
+ showPreview: boolean;
8
9
  schema: any;
9
10
  };
11
+ static savedValueTypes(): never[];
10
12
  constructor(...args: any[]);
11
13
  get tabKey(): string;
12
14
  get tabLikey(): string;
@@ -31,9 +31,13 @@ class TabsComponent extends NestedComponent_1.default {
31
31
  icon: 'folder-o',
32
32
  weight: 50,
33
33
  documentation: '/userguide/form-building/layout-components#tabs',
34
+ showPreview: false,
34
35
  schema: TabsComponent.schema(),
35
36
  };
36
37
  }
38
+ static savedValueTypes() {
39
+ return [];
40
+ }
37
41
  get defaultSchema() {
38
42
  return TabsComponent.schema();
39
43
  }
@@ -7,6 +7,27 @@ export default class TagsComponent extends Input {
7
7
  weight: number;
8
8
  schema: any;
9
9
  };
10
+ static get serverConditionSettings(): {
11
+ operators: any[];
12
+ constructor: Function;
13
+ toString(): string;
14
+ toLocaleString(): string;
15
+ valueOf(): Object;
16
+ hasOwnProperty(v: PropertyKey): boolean;
17
+ isPrototypeOf(v: Object): boolean;
18
+ propertyIsEnumerable(v: PropertyKey): boolean;
19
+ };
20
+ static get conditionOperatorsSettings(): {
21
+ operators: any[];
22
+ constructor: Function;
23
+ toString(): string;
24
+ toLocaleString(): string;
25
+ valueOf(): Object;
26
+ hasOwnProperty(v: PropertyKey): boolean;
27
+ isPrototypeOf(v: Object): boolean;
28
+ propertyIsEnumerable(v: PropertyKey): boolean;
29
+ };
30
+ static savedValueTypes(schema: any): any[];
10
31
  get emptyValue(): "" | never[];
11
32
  get delimiter(): any;
12
33
  attachElement(element: any, index: any): void;
@@ -3,6 +3,7 @@ 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
+ const utils_1 = require("../../utils/utils");
6
7
  const Input_1 = __importDefault(require("../_classes/input/Input"));
7
8
  const choices_js_1 = __importDefault(require("@formio/choices.js"));
8
9
  class TagsComponent extends Input_1.default {
@@ -26,6 +27,16 @@ class TagsComponent extends Input_1.default {
26
27
  schema: TagsComponent.schema()
27
28
  };
28
29
  }
30
+ static get serverConditionSettings() {
31
+ return TagsComponent.conditionOperatorsSettings;
32
+ }
33
+ static get conditionOperatorsSettings() {
34
+ return Object.assign(Object.assign({}, super.conditionOperatorsSettings), { operators: [...super.conditionOperatorsSettings.operators, 'includes', 'notIncludes'] });
35
+ }
36
+ static savedValueTypes(schema) {
37
+ schema = schema || {};
38
+ return (0, utils_1.getComponentSavedTypes)(schema) || [utils_1.componentValueTypes[schema.storeas] || utils_1.componentValueTypes.string];
39
+ }
29
40
  init() {
30
41
  super.init();
31
42
  }
@@ -10,6 +10,7 @@ export default class TextAreaComponent extends TextFieldComponent {
10
10
  */
11
11
  updateEditorValue(index: any, newValue: any): void;
12
12
  autoModified: boolean | undefined;
13
+ attachElement(element: any, index: any): any;
13
14
  imageHandler(moduleInstance: any, range: any, files: any): void;
14
15
  get isPlain(): boolean;
15
16
  get htmlView(): any;
@@ -19,8 +20,8 @@ export default class TextAreaComponent extends TextFieldComponent {
19
20
  setReadOnlyValue(value: any, index: any): void;
20
21
  get isJsonValue(): any;
21
22
  setConvertedValue(value: any, index: any): any;
22
- setAsyncConvertedValue(value: any): any;
23
- setImagesUrl(images: any): any;
23
+ setAsyncConvertedValue(value: any): Promise<any>;
24
+ setImagesUrl(images: any): Promise<any>;
24
25
  addAutoExpanding(textarea: any, index: any): void;
25
26
  trimBlanks(value: any): any;
26
27
  onChange(flags: any, fromRoot: any): {
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  /* global Quill */
7
7
  const TextField_1 = __importDefault(require("../textfield/TextField"));
8
8
  const lodash_1 = __importDefault(require("lodash"));
9
- const native_promise_only_1 = __importDefault(require("native-promise-only"));
10
9
  const utils_1 = require("../../utils/utils");
11
10
  class TextAreaComponent extends TextField_1.default {
12
11
  static schema(...extend) {
@@ -117,7 +116,7 @@ class TextAreaComponent extends TextField_1.default {
117
116
  this.wysiwygDefault[this.component.editor] || this.wysiwygDefault.default
118
117
  : this.component.wysiwyg;
119
118
  // Keep track of when this editor is ready.
120
- this.editorsReady[index] = new native_promise_only_1.default((editorReady) => {
119
+ this.editorsReady[index] = new Promise((editorReady) => {
121
120
  // Attempt to add a wysiwyg editor. In order to add one, it must be included on the global scope.
122
121
  switch (this.component.editor) {
123
122
  case 'ace':
@@ -285,7 +284,7 @@ class TextAreaComponent extends TextField_1.default {
285
284
  this.setConvertedValue(value);
286
285
  return super.setValue(value, flags);
287
286
  }
288
- flags.skipWysiwyg = lodash_1.default.isEqual(value, this.getValue());
287
+ flags.skipWysiwyg = value === '' && flags.resetValue ? false : lodash_1.default.isEqual(value, this.getValue());
289
288
  return super.setValue(value, flags);
290
289
  }
291
290
  setContent(element, content, forceSanitize) {
@@ -347,11 +346,11 @@ class TextAreaComponent extends TextField_1.default {
347
346
  });
348
347
  }
349
348
  else {
350
- return native_promise_only_1.default.resolve(value);
349
+ return Promise.resolve(value);
351
350
  }
352
351
  }
353
352
  setImagesUrl(images) {
354
- return native_promise_only_1.default.all(lodash_1.default.map(images, image => {
353
+ return Promise.all(lodash_1.default.map(images, image => {
355
354
  let requestData;
356
355
  try {
357
356
  requestData = JSON.parse(image.getAttribute('alt'));