@beinformed/ui 1.24.0 → 1.24.1-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1092) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/constants/package.json +8 -0
  3. package/esm/builder/index.js +0 -1
  4. package/esm/builder/index.js.map +1 -1
  5. package/esm/constants/Constants.js +0 -1
  6. package/esm/constants/Constants.js.map +1 -1
  7. package/esm/constants/LayoutHintConfig.js +0 -1
  8. package/esm/constants/LayoutHintConfig.js.map +1 -1
  9. package/esm/constants/LayoutHints.js +0 -1
  10. package/esm/constants/LayoutHints.js.map +1 -1
  11. package/esm/constants/index.js +0 -1
  12. package/esm/constants/index.js.map +1 -1
  13. package/esm/exceptions/ConfigurationException.js +0 -2
  14. package/esm/exceptions/ConfigurationException.js.map +1 -1
  15. package/esm/exceptions/FetchException.js +1 -1
  16. package/esm/exceptions/FetchException.js.map +1 -1
  17. package/esm/exceptions/IllegalArgumentException.js +0 -1
  18. package/esm/exceptions/IllegalArgumentException.js.map +1 -1
  19. package/esm/exceptions/IllegalReturnException.js +0 -1
  20. package/esm/exceptions/IllegalReturnException.js.map +1 -1
  21. package/esm/exceptions/IllegalStateException.js +0 -1
  22. package/esm/exceptions/IllegalStateException.js.map +1 -1
  23. package/esm/exceptions/JsonParseException.js +0 -1
  24. package/esm/exceptions/JsonParseException.js.map +1 -1
  25. package/esm/exceptions/MissingPropertyException.js +0 -1
  26. package/esm/exceptions/MissingPropertyException.js.map +1 -1
  27. package/esm/exceptions/NotAllowedUriException.js +0 -1
  28. package/esm/exceptions/NotAllowedUriException.js.map +1 -1
  29. package/esm/exceptions/ServerRequestException.js +0 -1
  30. package/esm/exceptions/ServerRequestException.js.map +1 -1
  31. package/esm/exceptions/ThemePropertyException.js +0 -1
  32. package/esm/exceptions/ThemePropertyException.js.map +1 -1
  33. package/esm/exceptions/TimeoutException.js +0 -1
  34. package/esm/exceptions/TimeoutException.js.map +1 -1
  35. package/esm/exceptions/UnauthorizedException.js +0 -1
  36. package/esm/exceptions/UnauthorizedException.js.map +1 -1
  37. package/esm/exceptions/UnsupportedOperationException.js +0 -1
  38. package/esm/exceptions/UnsupportedOperationException.js.map +1 -1
  39. package/esm/exceptions/index.js +0 -1
  40. package/esm/exceptions/index.js.map +1 -1
  41. package/esm/hooks/index.js +0 -1
  42. package/esm/hooks/index.js.map +1 -1
  43. package/esm/hooks/useAuthentication.js +4 -5
  44. package/esm/hooks/useAuthentication.js.map +1 -1
  45. package/esm/hooks/useDeepCompareEffect.js +0 -1
  46. package/esm/hooks/useDeepCompareEffect.js.map +1 -1
  47. package/esm/hooks/useForm.js +1 -2
  48. package/esm/hooks/useForm.js.map +1 -1
  49. package/esm/hooks/useModelCatalog.js +1 -1
  50. package/esm/hooks/useModelCatalog.js.map +1 -1
  51. package/esm/hooks/useModels.js +0 -1
  52. package/esm/hooks/useModels.js.map +1 -1
  53. package/esm/hooks/useModularUI.js +0 -1
  54. package/esm/hooks/useModularUI.js.map +1 -1
  55. package/esm/hooks/useModularUIBasic.js +3 -3
  56. package/esm/hooks/useModularUIBasic.js.map +1 -1
  57. package/esm/hooks/useModularUIModel.js +0 -1
  58. package/esm/hooks/useModularUIModel.js.map +1 -1
  59. package/esm/hooks/useModularUIRequest.js +0 -1
  60. package/esm/hooks/useModularUIRequest.js.map +1 -1
  61. package/esm/hooks/useNotification.js +0 -1
  62. package/esm/hooks/useNotification.js.map +1 -1
  63. package/esm/hooks/usePreference.js +0 -1
  64. package/esm/hooks/usePreference.js.map +1 -1
  65. package/esm/hooks/useProgressIndicator.js +0 -1
  66. package/esm/hooks/useProgressIndicator.js.map +1 -1
  67. package/esm/hooks/useRouter.js +3 -13
  68. package/esm/hooks/useRouter.js.map +1 -1
  69. package/esm/i18n/Message.js +0 -1
  70. package/esm/i18n/Message.js.map +1 -1
  71. package/esm/i18n/index.js +0 -1
  72. package/esm/i18n/index.js.map +1 -1
  73. package/esm/i18n/languages.js +0 -1
  74. package/esm/i18n/languages.js.map +1 -1
  75. package/esm/i18n/translations/beinformed_error_messages_en.nl.js +0 -1
  76. package/esm/i18n/translations/beinformed_error_messages_en.nl.js.map +1 -1
  77. package/esm/i18n/translations/beinformed_error_messages_nl.nl.js +0 -1
  78. package/esm/i18n/translations/beinformed_error_messages_nl.nl.js.map +1 -1
  79. package/esm/index.js +0 -1
  80. package/esm/index.js.map +1 -1
  81. package/esm/models/application/ApplicationModel.js +2 -4
  82. package/esm/models/application/ApplicationModel.js.map +1 -1
  83. package/esm/models/attributes/AttributeCollection.js +3 -8
  84. package/esm/models/attributes/AttributeCollection.js.map +1 -1
  85. package/esm/models/attributes/AttributeContent.js +4 -7
  86. package/esm/models/attributes/AttributeContent.js.map +1 -1
  87. package/esm/models/attributes/AttributeDataHelper.js +1 -2
  88. package/esm/models/attributes/AttributeDataHelper.js.map +1 -1
  89. package/esm/models/attributes/AttributeModel.js +2 -4
  90. package/esm/models/attributes/AttributeModel.js.map +1 -1
  91. package/esm/models/attributes/CaptchaAttributeModel.js +0 -1
  92. package/esm/models/attributes/CaptchaAttributeModel.js.map +1 -1
  93. package/esm/models/attributes/ChoiceAttributeModel.js +2 -4
  94. package/esm/models/attributes/ChoiceAttributeModel.js.map +1 -1
  95. package/esm/models/attributes/ChoiceAttributeOptionModel.js +2 -3
  96. package/esm/models/attributes/ChoiceAttributeOptionModel.js.map +1 -1
  97. package/esm/models/attributes/CompositeAttributeChildCollection.js +2 -5
  98. package/esm/models/attributes/CompositeAttributeChildCollection.js.map +1 -1
  99. package/esm/models/attributes/CompositeAttributeModel.js +3 -5
  100. package/esm/models/attributes/CompositeAttributeModel.js.map +1 -1
  101. package/esm/models/attributes/HelptextAttributeModel.js +1 -2
  102. package/esm/models/attributes/HelptextAttributeModel.js.map +1 -1
  103. package/esm/models/attributes/LabelAttributeModel.js +1 -1
  104. package/esm/models/attributes/LabelAttributeModel.js.map +1 -1
  105. package/esm/models/attributes/MemoAttributeModel.js +1 -2
  106. package/esm/models/attributes/MemoAttributeModel.js.map +1 -1
  107. package/esm/models/attributes/MoneyAttributeModel.js +1 -1
  108. package/esm/models/attributes/MoneyAttributeModel.js.map +1 -1
  109. package/esm/models/attributes/PasswordAttributeModel.js +1 -1
  110. package/esm/models/attributes/PasswordAttributeModel.js.map +1 -1
  111. package/esm/models/attributes/StringAttributeModel.js +1 -1
  112. package/esm/models/attributes/StringAttributeModel.js.map +1 -1
  113. package/esm/models/attributes/XMLAttributeModel.js +1 -1
  114. package/esm/models/attributes/XMLAttributeModel.js.map +1 -1
  115. package/esm/models/attributes/_createAttribute.js +2 -3
  116. package/esm/models/attributes/_createAttribute.js.map +1 -1
  117. package/esm/models/attributes/input-constraints/BSNConstraint.js +0 -2
  118. package/esm/models/attributes/input-constraints/BSNConstraint.js.map +1 -1
  119. package/esm/models/attributes/input-constraints/FileExtensionConstraint.js +0 -1
  120. package/esm/models/attributes/input-constraints/FileExtensionConstraint.js.map +1 -1
  121. package/esm/models/attributes/input-constraints/IBANConstraint.js +0 -1
  122. package/esm/models/attributes/input-constraints/IBANConstraint.js.map +1 -1
  123. package/esm/models/attributes/input-constraints/MandatoryConstraint.js +0 -2
  124. package/esm/models/attributes/input-constraints/MandatoryConstraint.js.map +1 -1
  125. package/esm/models/attributes/input-constraints/MandatoryRangeConstraint.js +0 -1
  126. package/esm/models/attributes/input-constraints/MandatoryRangeConstraint.js.map +1 -1
  127. package/esm/models/attributes/input-constraints/PasswordConfirmConstraint.js +0 -1
  128. package/esm/models/attributes/input-constraints/PasswordConfirmConstraint.js.map +1 -1
  129. package/esm/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.js +0 -2
  130. package/esm/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.js.map +1 -1
  131. package/esm/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.js +0 -1
  132. package/esm/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.js.map +1 -1
  133. package/esm/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.js +0 -1
  134. package/esm/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.js.map +1 -1
  135. package/esm/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.js +0 -1
  136. package/esm/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.js.map +1 -1
  137. package/esm/models/attributes/input-constraints/RegexConstraint.js +0 -1
  138. package/esm/models/attributes/input-constraints/RegexConstraint.js.map +1 -1
  139. package/esm/models/attributes/input-constraints/StringLengthConstraint.js +0 -1
  140. package/esm/models/attributes/input-constraints/StringLengthConstraint.js.map +1 -1
  141. package/esm/models/attributes/input-constraints/XMLConstraint.js +0 -2
  142. package/esm/models/attributes/input-constraints/XMLConstraint.js.map +1 -1
  143. package/esm/models/attributes/layouthint-rules/BaseLayoutHintRule.js +0 -1
  144. package/esm/models/attributes/layouthint-rules/BaseLayoutHintRule.js.map +1 -1
  145. package/esm/models/attributes/layouthint-rules/DependentAttribute.js +2 -2
  146. package/esm/models/attributes/layouthint-rules/DependentAttribute.js.map +1 -1
  147. package/esm/models/attributes/layouthint-rules/LayoutHintRuleCollection.js +0 -1
  148. package/esm/models/attributes/layouthint-rules/LayoutHintRuleCollection.js.map +1 -1
  149. package/esm/models/attributes/layouthint-rules/RemainingTotalUploadSize.js +0 -1
  150. package/esm/models/attributes/layouthint-rules/RemainingTotalUploadSize.js.map +1 -1
  151. package/esm/models/base/ResourceCollection.js +1 -2
  152. package/esm/models/base/ResourceCollection.js.map +1 -1
  153. package/esm/models/concepts/BusinessScenarioModel.js +4 -12
  154. package/esm/models/concepts/BusinessScenarioModel.js.map +1 -1
  155. package/esm/models/concepts/ConceptDetailModel.js +1 -2
  156. package/esm/models/concepts/ConceptDetailModel.js.map +1 -1
  157. package/esm/models/concepts/ConceptIndexModel.js +1 -2
  158. package/esm/models/concepts/ConceptIndexModel.js.map +1 -1
  159. package/esm/models/concepts/ConceptLinkModel.js +2 -3
  160. package/esm/models/concepts/ConceptLinkModel.js.map +1 -1
  161. package/esm/models/concepts/ConceptTypeDetailModel.js +0 -1
  162. package/esm/models/concepts/ConceptTypeDetailModel.js.map +1 -1
  163. package/esm/models/content/ContentIndexModel.js +3 -8
  164. package/esm/models/content/ContentIndexModel.js.map +1 -1
  165. package/esm/models/content/ContentLinkModel.js +1 -1
  166. package/esm/models/content/ContentLinkModel.js.map +1 -1
  167. package/esm/models/content/ContentModel.js +2 -4
  168. package/esm/models/content/ContentModel.js.map +1 -1
  169. package/esm/models/content/ContentTOCModel.js +2 -4
  170. package/esm/models/content/ContentTOCModel.js.map +1 -1
  171. package/esm/models/content/ContentTypeModel.js +0 -1
  172. package/esm/models/content/ContentTypeModel.js.map +1 -1
  173. package/esm/models/content/SectionModel.js +1 -2
  174. package/esm/models/content/SectionModel.js.map +1 -1
  175. package/esm/models/contentconfiguration/ContentConfigurationResults.js +1 -1
  176. package/esm/models/contentconfiguration/ContentConfigurationResults.js.map +1 -1
  177. package/esm/models/detail/DetailModel.js +2 -2
  178. package/esm/models/detail/DetailModel.js.map +1 -1
  179. package/esm/models/error/ErrorModel.js +0 -1
  180. package/esm/models/error/ErrorModel.js.map +1 -1
  181. package/esm/models/error/ErrorResponse.js +11 -22
  182. package/esm/models/error/ErrorResponse.js.map +1 -1
  183. package/esm/models/filters/BaseFilterModel.js +2 -4
  184. package/esm/models/filters/BaseFilterModel.js.map +1 -1
  185. package/esm/models/filters/FilterCollection.js +2 -4
  186. package/esm/models/filters/FilterCollection.js.map +1 -1
  187. package/esm/models/filters/FilterModel.js +0 -1
  188. package/esm/models/filters/FilterModel.js.map +1 -1
  189. package/esm/models/form/FormModel.js +13 -28
  190. package/esm/models/form/FormModel.js.map +1 -1
  191. package/esm/models/form/FormObjectModel.js +6 -11
  192. package/esm/models/form/FormObjectModel.js.map +1 -1
  193. package/esm/models/grouping/GroupingModel.js +1 -1
  194. package/esm/models/grouping/GroupingModel.js.map +1 -1
  195. package/esm/models/index.js +0 -1
  196. package/esm/models/index.js.map +1 -1
  197. package/esm/models/list/ListDetailModel.js +4 -6
  198. package/esm/models/list/ListDetailModel.js.map +1 -1
  199. package/esm/models/list/ListModel.js +2 -2
  200. package/esm/models/list/ListModel.js.map +1 -1
  201. package/esm/models/lookup/LookupOptionCollection.js +0 -1
  202. package/esm/models/lookup/LookupOptionCollection.js.map +1 -1
  203. package/esm/models/modelcatalog/ModelCatalogModel.js +0 -1
  204. package/esm/models/modelcatalog/ModelCatalogModel.js.map +1 -1
  205. package/esm/models/process/ProcessStatusSettingsModel.js +0 -1
  206. package/esm/models/process/ProcessStatusSettingsModel.js.map +1 -1
  207. package/esm/models/sorting/SortOptionModel.js +0 -1
  208. package/esm/models/sorting/SortOptionModel.js.map +1 -1
  209. package/esm/models/sorting/SortingModel.js +1 -1
  210. package/esm/models/sorting/SortingModel.js.map +1 -1
  211. package/esm/models/tab/TabModel.js +1 -2
  212. package/esm/models/tab/TabModel.js.map +1 -1
  213. package/esm/models/taskgroup/TaskGroupCollection.js +0 -1
  214. package/esm/models/taskgroup/TaskGroupCollection.js.map +1 -1
  215. package/esm/models/user/UserModel.js +0 -1
  216. package/esm/models/user/UserModel.js.map +1 -1
  217. package/esm/modularui/ModularUIRequest.js +4 -9
  218. package/esm/modularui/ModularUIRequest.js.map +1 -1
  219. package/esm/modularui/ModularUIResponse.js +2 -3
  220. package/esm/modularui/ModularUIResponse.js.map +1 -1
  221. package/esm/modularui/index.js +0 -1
  222. package/esm/modularui/index.js.map +1 -1
  223. package/esm/react/ErrorBoundaryFallback.js +0 -1
  224. package/esm/react/ErrorBoundaryFallback.js.map +1 -1
  225. package/esm/react/index.js +0 -1
  226. package/esm/react/index.js.map +1 -1
  227. package/esm/react/utils.js +0 -2
  228. package/esm/react/utils.js.map +1 -1
  229. package/esm/react-client/Init.js +0 -1
  230. package/esm/react-client/Init.js.map +1 -1
  231. package/esm/react-client/contextPath.js +0 -1
  232. package/esm/react-client/contextPath.js.map +1 -1
  233. package/esm/react-client/index.js +0 -1
  234. package/esm/react-client/index.js.map +1 -1
  235. package/esm/react-client/rehydrate.js +1 -1
  236. package/esm/react-client/rehydrate.js.map +1 -1
  237. package/esm/react-server/contextPath.js +0 -1
  238. package/esm/react-server/contextPath.js.map +1 -1
  239. package/esm/react-server/htmlpage.js +1 -1
  240. package/esm/react-server/htmlpage.js.map +1 -1
  241. package/esm/react-server/index.js +0 -1
  242. package/esm/react-server/index.js.map +1 -1
  243. package/esm/react-server/renderSSRComplete.js +0 -1
  244. package/esm/react-server/renderSSRComplete.js.map +1 -1
  245. package/esm/react-server/renderSSRMinimal.js +0 -1
  246. package/esm/react-server/renderSSRMinimal.js.map +1 -1
  247. package/esm/react-server/requestInformation.js +0 -1
  248. package/esm/react-server/requestInformation.js.map +1 -1
  249. package/esm/react-server/serverNoSSR.js +1 -3
  250. package/esm/react-server/serverNoSSR.js.map +1 -1
  251. package/esm/react-server/serverSSR.js +0 -1
  252. package/esm/react-server/serverSSR.js.map +1 -1
  253. package/esm/react-theme/ThemeProvider.js +0 -1
  254. package/esm/react-theme/ThemeProvider.js.map +1 -1
  255. package/esm/react-theme/index.js +0 -1
  256. package/esm/react-theme/index.js.map +1 -1
  257. package/esm/react-theme/useTheme.js +0 -1
  258. package/esm/react-theme/useTheme.js.map +1 -1
  259. package/esm/react-theme/utils/background.js +0 -1
  260. package/esm/react-theme/utils/background.js.map +1 -1
  261. package/esm/react-theme/utils/colors.js +0 -1
  262. package/esm/react-theme/utils/colors.js.map +1 -1
  263. package/esm/react-theme/utils/contrast.js +1 -3
  264. package/esm/react-theme/utils/contrast.js.map +1 -1
  265. package/esm/react-theme/utils/corners.js +0 -1
  266. package/esm/react-theme/utils/corners.js.map +1 -1
  267. package/esm/react-theme/utils/themeProps.js +0 -1
  268. package/esm/react-theme/utils/themeProps.js.map +1 -1
  269. package/esm/redux/_i18n/actions.js +0 -1
  270. package/esm/redux/_i18n/actions.js.map +1 -1
  271. package/esm/redux/_i18n/index.js +0 -1
  272. package/esm/redux/_i18n/index.js.map +1 -1
  273. package/esm/redux/_i18n/reducer.js +0 -1
  274. package/esm/redux/_i18n/reducer.js.map +1 -1
  275. package/esm/redux/_modularui/actions.js +7 -7
  276. package/esm/redux/_modularui/actions.js.map +1 -1
  277. package/esm/redux/_modularui/connector.js +2 -4
  278. package/esm/redux/_modularui/connector.js.map +1 -1
  279. package/esm/redux/_modularui/index.js +0 -1
  280. package/esm/redux/_modularui/index.js.map +1 -1
  281. package/esm/redux/_modularui/modularuiUtils.js +2 -2
  282. package/esm/redux/_modularui/modularuiUtils.js.map +1 -1
  283. package/esm/redux/_modularui/reducer.js +1 -2
  284. package/esm/redux/_modularui/reducer.js.map +1 -1
  285. package/esm/redux/_modularui/selectors.js +7 -13
  286. package/esm/redux/_modularui/selectors.js.map +1 -1
  287. package/esm/redux/_modularui/withModularUI.js +0 -1
  288. package/esm/redux/_modularui/withModularUI.js.map +1 -1
  289. package/esm/redux/_router/actions.js +0 -2
  290. package/esm/redux/_router/actions.js.map +1 -1
  291. package/esm/redux/_router/connectors.js +9 -19
  292. package/esm/redux/_router/connectors.js.map +1 -1
  293. package/esm/redux/_router/index.js +0 -1
  294. package/esm/redux/_router/index.js.map +1 -1
  295. package/esm/redux/_router/middleware.js +0 -2
  296. package/esm/redux/_router/middleware.js.map +1 -1
  297. package/esm/redux/_router/reducer.js +0 -2
  298. package/esm/redux/_router/reducer.js.map +1 -1
  299. package/esm/redux/actions/Application.js +0 -1
  300. package/esm/redux/actions/Application.js.map +1 -1
  301. package/esm/redux/actions/Authorization.js +4 -7
  302. package/esm/redux/actions/Authorization.js.map +1 -1
  303. package/esm/redux/actions/Error.js +0 -1
  304. package/esm/redux/actions/Error.js.map +1 -1
  305. package/esm/redux/actions/Form.js +0 -1
  306. package/esm/redux/actions/Form.js.map +1 -1
  307. package/esm/redux/actions/FormAttributeSet.js +2 -4
  308. package/esm/redux/actions/FormAttributeSet.js.map +1 -1
  309. package/esm/redux/actions/FormAttributeSetRepeatable.js +0 -1
  310. package/esm/redux/actions/FormAttributeSetRepeatable.js.map +1 -1
  311. package/esm/redux/actions/FormAutosave.js +0 -1
  312. package/esm/redux/actions/FormAutosave.js.map +1 -1
  313. package/esm/redux/actions/FormAutosubmit.js +0 -1
  314. package/esm/redux/actions/FormAutosubmit.js.map +1 -1
  315. package/esm/redux/actions/FormValidations.js +0 -1
  316. package/esm/redux/actions/FormValidations.js.map +1 -1
  317. package/esm/redux/actions/Modals.js +0 -2
  318. package/esm/redux/actions/Modals.js.map +1 -1
  319. package/esm/redux/actions/Notification.js +0 -1
  320. package/esm/redux/actions/Notification.js.map +1 -1
  321. package/esm/redux/actions/Preferences.js +5 -5
  322. package/esm/redux/actions/Preferences.js.map +1 -1
  323. package/esm/redux/actions/ProgressIndicator.js +0 -2
  324. package/esm/redux/actions/ProgressIndicator.js.map +1 -1
  325. package/esm/redux/actions/SignIn.js +2 -3
  326. package/esm/redux/actions/SignIn.js.map +1 -1
  327. package/esm/redux/actions/SignOut.js +0 -1
  328. package/esm/redux/actions/SignOut.js.map +1 -1
  329. package/esm/redux/actions/index.js +0 -1
  330. package/esm/redux/actions/index.js.map +1 -1
  331. package/esm/redux/connectors/Application.js +0 -1
  332. package/esm/redux/connectors/Application.js.map +1 -1
  333. package/esm/redux/connectors/Breadcrumb.js +0 -1
  334. package/esm/redux/connectors/Breadcrumb.js.map +1 -1
  335. package/esm/redux/connectors/CaseView.js +0 -1
  336. package/esm/redux/connectors/CaseView.js.map +1 -1
  337. package/esm/redux/connectors/ConceptDetail.js +0 -1
  338. package/esm/redux/connectors/ConceptDetail.js.map +1 -1
  339. package/esm/redux/connectors/ContentBrowser.js +0 -1
  340. package/esm/redux/connectors/ContentBrowser.js.map +1 -1
  341. package/esm/redux/connectors/ContentDetail.js +0 -1
  342. package/esm/redux/connectors/ContentDetail.js.map +1 -1
  343. package/esm/redux/connectors/ContentDetailSection.js +0 -1
  344. package/esm/redux/connectors/ContentDetailSection.js.map +1 -1
  345. package/esm/redux/connectors/Form.js +3 -7
  346. package/esm/redux/connectors/Form.js.map +1 -1
  347. package/esm/redux/connectors/FormAttributeSet.js +0 -1
  348. package/esm/redux/connectors/FormAttributeSet.js.map +1 -1
  349. package/esm/redux/connectors/ListDetail.js +0 -1
  350. package/esm/redux/connectors/ListDetail.js.map +1 -1
  351. package/esm/redux/connectors/ModelCatalog.js +0 -1
  352. package/esm/redux/connectors/ModelCatalog.js.map +1 -1
  353. package/esm/redux/connectors/Notification.js +0 -1
  354. package/esm/redux/connectors/Notification.js.map +1 -1
  355. package/esm/redux/connectors/PanelRenderer.js +0 -1
  356. package/esm/redux/connectors/PanelRenderer.js.map +1 -1
  357. package/esm/redux/connectors/Preferences.js +0 -1
  358. package/esm/redux/connectors/Preferences.js.map +1 -1
  359. package/esm/redux/connectors/Progress.js +0 -1
  360. package/esm/redux/connectors/Progress.js.map +1 -1
  361. package/esm/redux/connectors/ProgressIndicator.js +0 -1
  362. package/esm/redux/connectors/ProgressIndicator.js.map +1 -1
  363. package/esm/redux/connectors/QuickSearch.js +0 -1
  364. package/esm/redux/connectors/QuickSearch.js.map +1 -1
  365. package/esm/redux/connectors/SignIn.js +1 -2
  366. package/esm/redux/connectors/SignIn.js.map +1 -1
  367. package/esm/redux/connectors/SignOut.js +3 -7
  368. package/esm/redux/connectors/SignOut.js.map +1 -1
  369. package/esm/redux/connectors/Tab.js +0 -1
  370. package/esm/redux/connectors/Tab.js.map +1 -1
  371. package/esm/redux/connectors/index.js +0 -1
  372. package/esm/redux/connectors/index.js.map +1 -1
  373. package/esm/redux/index.js +0 -2
  374. package/esm/redux/index.js.map +1 -1
  375. package/esm/redux/reducers/AuthReducer.js +0 -2
  376. package/esm/redux/reducers/AuthReducer.js.map +1 -1
  377. package/esm/redux/reducers/ErrorReducer.js +0 -2
  378. package/esm/redux/reducers/ErrorReducer.js.map +1 -1
  379. package/esm/redux/reducers/ModalsReducer.js +0 -1
  380. package/esm/redux/reducers/ModalsReducer.js.map +1 -1
  381. package/esm/redux/reducers/NotificationReducer.js +0 -2
  382. package/esm/redux/reducers/NotificationReducer.js.map +1 -1
  383. package/esm/redux/reducers/PreferencesReducer.js +2 -4
  384. package/esm/redux/reducers/PreferencesReducer.js.map +1 -1
  385. package/esm/redux/reducers/ProgressIndicatorReducer.js +1 -4
  386. package/esm/redux/reducers/ProgressIndicatorReducer.js.map +1 -1
  387. package/esm/redux/reducers/createReducer.js +0 -1
  388. package/esm/redux/reducers/createReducer.js.map +1 -1
  389. package/esm/redux/reducers/index.js +0 -1
  390. package/esm/redux/reducers/index.js.map +1 -1
  391. package/esm/redux/selectors/i18n.js +1 -4
  392. package/esm/redux/selectors/i18n.js.map +1 -1
  393. package/esm/redux/selectors/index.js +0 -1
  394. package/esm/redux/selectors/index.js.map +1 -1
  395. package/esm/redux/store/beforeRenderHooks.js +0 -2
  396. package/esm/redux/store/beforeRenderHooks.js.map +1 -1
  397. package/esm/redux/store/configureStore.js +0 -1
  398. package/esm/redux/store/configureStore.js.map +1 -1
  399. package/esm/utils/browser/Cache.js +0 -1
  400. package/esm/utils/browser/Cache.js.map +1 -1
  401. package/esm/utils/browser/Cookies.js +3 -4
  402. package/esm/utils/browser/Cookies.js.map +1 -1
  403. package/esm/utils/helpers/createHash.js +0 -2
  404. package/esm/utils/helpers/createHash.js.map +1 -1
  405. package/esm/utils/helpers/createUUID.js +0 -1
  406. package/esm/utils/helpers/createUUID.js.map +1 -1
  407. package/esm/utils/helpers/objects.js +0 -1
  408. package/esm/utils/helpers/objects.js.map +1 -1
  409. package/esm/utils/helpers/sanitizeHtml.js +0 -1
  410. package/esm/utils/helpers/sanitizeHtml.js.map +1 -1
  411. package/esm/utils/helpers/text.js +0 -1
  412. package/esm/utils/helpers/text.js.map +1 -1
  413. package/esm/utils/index.js +0 -2
  414. package/esm/utils/index.js.map +1 -1
  415. package/esm/utils/number/formatValue.js +0 -1
  416. package/esm/utils/number/formatValue.js.map +1 -1
  417. package/esm/utils/number/parseNumbers.js +0 -1
  418. package/esm/utils/number/parseNumbers.js.map +1 -1
  419. package/lib/constants/LayoutHints.js +0 -1
  420. package/lib/constants/LayoutHints.js.map +1 -1
  421. package/lib/constants/Settings.js +0 -1
  422. package/lib/constants/Settings.js.map +1 -1
  423. package/lib/exceptions/ConfigurationException.js +0 -1
  424. package/lib/exceptions/ConfigurationException.js.map +1 -1
  425. package/lib/exceptions/FetchException.js +1 -2
  426. package/lib/exceptions/FetchException.js.map +1 -1
  427. package/lib/exceptions/UnauthorizedException.js +0 -1
  428. package/lib/exceptions/UnauthorizedException.js.map +1 -1
  429. package/lib/hooks/useAllFormsOnModel.js +0 -1
  430. package/lib/hooks/useAllFormsOnModel.js.map +1 -1
  431. package/lib/hooks/useAuthentication.js +4 -5
  432. package/lib/hooks/useAuthentication.js.map +1 -1
  433. package/lib/hooks/useContent.js +0 -1
  434. package/lib/hooks/useContent.js.map +1 -1
  435. package/lib/hooks/useDeepCompareEffect.js +0 -1
  436. package/lib/hooks/useDeepCompareEffect.js.map +1 -1
  437. package/lib/hooks/useForm.js +1 -2
  438. package/lib/hooks/useForm.js.map +1 -1
  439. package/lib/hooks/useI18n.js +0 -1
  440. package/lib/hooks/useI18n.js.map +1 -1
  441. package/lib/hooks/useModal.js +0 -1
  442. package/lib/hooks/useModal.js.map +1 -1
  443. package/lib/hooks/useModelCatalog.js +1 -2
  444. package/lib/hooks/useModelCatalog.js.map +1 -1
  445. package/lib/hooks/useModels.js +0 -1
  446. package/lib/hooks/useModels.js.map +1 -1
  447. package/lib/hooks/useModularUI.js +0 -1
  448. package/lib/hooks/useModularUI.js.map +1 -1
  449. package/lib/hooks/useModularUIBasic.js +3 -4
  450. package/lib/hooks/useModularUIBasic.js.map +1 -1
  451. package/lib/hooks/useModularUIModel.js +0 -1
  452. package/lib/hooks/useModularUIModel.js.map +1 -1
  453. package/lib/hooks/useModularUIRequest.js +0 -1
  454. package/lib/hooks/useModularUIRequest.js.map +1 -1
  455. package/lib/hooks/useNotification.js +0 -1
  456. package/lib/hooks/useNotification.js.map +1 -1
  457. package/lib/hooks/usePreference.js +0 -1
  458. package/lib/hooks/usePreference.js.map +1 -1
  459. package/lib/hooks/useProgressIndicator.js +0 -1
  460. package/lib/hooks/useProgressIndicator.js.map +1 -1
  461. package/lib/hooks/useRouter.js +3 -13
  462. package/lib/hooks/useRouter.js.map +1 -1
  463. package/lib/i18n/Locale.js +0 -1
  464. package/lib/i18n/Locale.js.map +1 -1
  465. package/lib/i18n/Locales.js +0 -1
  466. package/lib/i18n/Locales.js.map +1 -1
  467. package/lib/i18n/Message.js +0 -1
  468. package/lib/i18n/Message.js.map +1 -1
  469. package/lib/i18n/withMessage.js +0 -1
  470. package/lib/i18n/withMessage.js.map +1 -1
  471. package/lib/models/actions/ActionCollection.js +0 -1
  472. package/lib/models/actions/ActionCollection.js.map +1 -1
  473. package/lib/models/actions/ActionModel.js +0 -1
  474. package/lib/models/actions/ActionModel.js.map +1 -1
  475. package/lib/models/application/ApplicationModel.js +2 -5
  476. package/lib/models/application/ApplicationModel.js.map +1 -1
  477. package/lib/models/attributes/AttributeCollection.js +3 -9
  478. package/lib/models/attributes/AttributeCollection.js.map +1 -1
  479. package/lib/models/attributes/AttributeContent.js +4 -8
  480. package/lib/models/attributes/AttributeContent.js.map +1 -1
  481. package/lib/models/attributes/AttributeDataHelper.js +1 -3
  482. package/lib/models/attributes/AttributeDataHelper.js.map +1 -1
  483. package/lib/models/attributes/AttributeModel.js +2 -5
  484. package/lib/models/attributes/AttributeModel.js.map +1 -1
  485. package/lib/models/attributes/AttributeSetModel.js +0 -1
  486. package/lib/models/attributes/AttributeSetModel.js.map +1 -1
  487. package/lib/models/attributes/BooleanAttributeModel.js +0 -1
  488. package/lib/models/attributes/BooleanAttributeModel.js.map +1 -1
  489. package/lib/models/attributes/CaptchaAttributeModel.js +0 -1
  490. package/lib/models/attributes/CaptchaAttributeModel.js.map +1 -1
  491. package/lib/models/attributes/ChoiceAttributeModel.js +2 -5
  492. package/lib/models/attributes/ChoiceAttributeModel.js.map +1 -1
  493. package/lib/models/attributes/ChoiceAttributeOptionCollection.js +0 -1
  494. package/lib/models/attributes/ChoiceAttributeOptionCollection.js.map +1 -1
  495. package/lib/models/attributes/ChoiceAttributeOptionModel.js +2 -4
  496. package/lib/models/attributes/ChoiceAttributeOptionModel.js.map +1 -1
  497. package/lib/models/attributes/CompositeAttributeChildCollection.js +2 -6
  498. package/lib/models/attributes/CompositeAttributeChildCollection.js.map +1 -1
  499. package/lib/models/attributes/CompositeAttributeModel.js +3 -6
  500. package/lib/models/attributes/CompositeAttributeModel.js.map +1 -1
  501. package/lib/models/attributes/DatetimeAttributeModel.js +0 -1
  502. package/lib/models/attributes/DatetimeAttributeModel.js.map +1 -1
  503. package/lib/models/attributes/HelptextAttributeModel.js +1 -2
  504. package/lib/models/attributes/HelptextAttributeModel.js.map +1 -1
  505. package/lib/models/attributes/LabelAttributeModel.js +1 -2
  506. package/lib/models/attributes/LabelAttributeModel.js.map +1 -1
  507. package/lib/models/attributes/MemoAttributeModel.js +1 -2
  508. package/lib/models/attributes/MemoAttributeModel.js.map +1 -1
  509. package/lib/models/attributes/MoneyAttributeModel.js +1 -2
  510. package/lib/models/attributes/MoneyAttributeModel.js.map +1 -1
  511. package/lib/models/attributes/NumberAttributeModel.js +0 -1
  512. package/lib/models/attributes/NumberAttributeModel.js.map +1 -1
  513. package/lib/models/attributes/PasswordAttributeModel.js +1 -2
  514. package/lib/models/attributes/PasswordAttributeModel.js.map +1 -1
  515. package/lib/models/attributes/StringAttributeModel.js +1 -2
  516. package/lib/models/attributes/StringAttributeModel.js.map +1 -1
  517. package/lib/models/attributes/UploadAttributeModel.js +0 -1
  518. package/lib/models/attributes/UploadAttributeModel.js.map +1 -1
  519. package/lib/models/attributes/XMLAttributeModel.js +1 -2
  520. package/lib/models/attributes/XMLAttributeModel.js.map +1 -1
  521. package/lib/models/attributes/_createAttribute.js +2 -4
  522. package/lib/models/attributes/_createAttribute.js.map +1 -1
  523. package/lib/models/attributes/input-constraints/BSNConstraint.js +0 -1
  524. package/lib/models/attributes/input-constraints/BSNConstraint.js.map +1 -1
  525. package/lib/models/attributes/input-constraints/ConstraintCollection.js +0 -1
  526. package/lib/models/attributes/input-constraints/ConstraintCollection.js.map +1 -1
  527. package/lib/models/attributes/input-constraints/ConstraintModel.js +0 -1
  528. package/lib/models/attributes/input-constraints/ConstraintModel.js.map +1 -1
  529. package/lib/models/attributes/input-constraints/DateBoundaryConstraint.js +0 -1
  530. package/lib/models/attributes/input-constraints/DateBoundaryConstraint.js.map +1 -1
  531. package/lib/models/attributes/input-constraints/DateTimeDateFormatConstraint.js +0 -1
  532. package/lib/models/attributes/input-constraints/DateTimeDateFormatConstraint.js.map +1 -1
  533. package/lib/models/attributes/input-constraints/DateTimeTimeFormatConstraint.js +0 -1
  534. package/lib/models/attributes/input-constraints/DateTimeTimeFormatConstraint.js.map +1 -1
  535. package/lib/models/attributes/input-constraints/DatetimeFormatConstraint.js +0 -1
  536. package/lib/models/attributes/input-constraints/DatetimeFormatConstraint.js.map +1 -1
  537. package/lib/models/attributes/input-constraints/FileExtensionConstraint.js +0 -1
  538. package/lib/models/attributes/input-constraints/FileExtensionConstraint.js.map +1 -1
  539. package/lib/models/attributes/input-constraints/FileSizeConstraint.js +0 -1
  540. package/lib/models/attributes/input-constraints/FileSizeConstraint.js.map +1 -1
  541. package/lib/models/attributes/input-constraints/IBANConstraint.js +0 -1
  542. package/lib/models/attributes/input-constraints/IBANConstraint.js.map +1 -1
  543. package/lib/models/attributes/input-constraints/MandatoryConstraint.js +0 -1
  544. package/lib/models/attributes/input-constraints/MandatoryConstraint.js.map +1 -1
  545. package/lib/models/attributes/input-constraints/MandatoryRangeConstraint.js +0 -1
  546. package/lib/models/attributes/input-constraints/MandatoryRangeConstraint.js.map +1 -1
  547. package/lib/models/attributes/input-constraints/NumberBoundaryConstraint.js +0 -1
  548. package/lib/models/attributes/input-constraints/NumberBoundaryConstraint.js.map +1 -1
  549. package/lib/models/attributes/input-constraints/NumberFormatConstraint.js +0 -1
  550. package/lib/models/attributes/input-constraints/NumberFormatConstraint.js.map +1 -1
  551. package/lib/models/attributes/input-constraints/NumberGroupingConstraint.js +0 -1
  552. package/lib/models/attributes/input-constraints/NumberGroupingConstraint.js.map +1 -1
  553. package/lib/models/attributes/input-constraints/PasswordConfirmConstraint.js +0 -1
  554. package/lib/models/attributes/input-constraints/PasswordConfirmConstraint.js.map +1 -1
  555. package/lib/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.js +0 -1
  556. package/lib/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.js.map +1 -1
  557. package/lib/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.js +0 -1
  558. package/lib/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.js.map +1 -1
  559. package/lib/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.js +0 -1
  560. package/lib/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.js.map +1 -1
  561. package/lib/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.js +0 -1
  562. package/lib/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.js.map +1 -1
  563. package/lib/models/attributes/input-constraints/RangeConstraint.js +0 -1
  564. package/lib/models/attributes/input-constraints/RangeConstraint.js.map +1 -1
  565. package/lib/models/attributes/input-constraints/RegexConstraint.js +0 -1
  566. package/lib/models/attributes/input-constraints/RegexConstraint.js.map +1 -1
  567. package/lib/models/attributes/input-constraints/StringLengthConstraint.js +0 -1
  568. package/lib/models/attributes/input-constraints/StringLengthConstraint.js.map +1 -1
  569. package/lib/models/attributes/input-constraints/XMLConstraint.js +0 -1
  570. package/lib/models/attributes/input-constraints/XMLConstraint.js.map +1 -1
  571. package/lib/models/attributes/layouthint-rules/BaseLayoutHintRule.js +0 -1
  572. package/lib/models/attributes/layouthint-rules/BaseLayoutHintRule.js.map +1 -1
  573. package/lib/models/attributes/layouthint-rules/DependentAttribute.js +2 -3
  574. package/lib/models/attributes/layouthint-rules/DependentAttribute.js.map +1 -1
  575. package/lib/models/attributes/layouthint-rules/LayoutHintRuleCollection.js +0 -1
  576. package/lib/models/attributes/layouthint-rules/LayoutHintRuleCollection.js.map +1 -1
  577. package/lib/models/attributes/layouthint-rules/RemainingTotalUploadSize.js +0 -1
  578. package/lib/models/attributes/layouthint-rules/RemainingTotalUploadSize.js.map +1 -1
  579. package/lib/models/base/BaseCollection.js +0 -1
  580. package/lib/models/base/BaseCollection.js.map +1 -1
  581. package/lib/models/base/BaseModel.js +0 -1
  582. package/lib/models/base/BaseModel.js.map +1 -1
  583. package/lib/models/base/ResourceCollection.js +1 -2
  584. package/lib/models/base/ResourceCollection.js.map +1 -1
  585. package/lib/models/base/ResourceModel.js +0 -1
  586. package/lib/models/base/ResourceModel.js.map +1 -1
  587. package/lib/models/caseview/CaseViewModel.js +0 -1
  588. package/lib/models/caseview/CaseViewModel.js.map +1 -1
  589. package/lib/models/concepts/BusinessScenarioModel.js +4 -13
  590. package/lib/models/concepts/BusinessScenarioModel.js.map +1 -1
  591. package/lib/models/concepts/ConceptDetailModel.js +1 -3
  592. package/lib/models/concepts/ConceptDetailModel.js.map +1 -1
  593. package/lib/models/concepts/ConceptIndexModel.js +1 -3
  594. package/lib/models/concepts/ConceptIndexModel.js.map +1 -1
  595. package/lib/models/concepts/ConceptLinkModel.js +2 -4
  596. package/lib/models/concepts/ConceptLinkModel.js.map +1 -1
  597. package/lib/models/concepts/ConceptRelationCollection.js +0 -1
  598. package/lib/models/concepts/ConceptRelationCollection.js.map +1 -1
  599. package/lib/models/concepts/ConceptRelationModel.js +0 -1
  600. package/lib/models/concepts/ConceptRelationModel.js.map +1 -1
  601. package/lib/models/concepts/ConceptTypeDetailModel.js +0 -1
  602. package/lib/models/concepts/ConceptTypeDetailModel.js.map +1 -1
  603. package/lib/models/concepts/SourceReferenceCollection.js +0 -1
  604. package/lib/models/concepts/SourceReferenceCollection.js.map +1 -1
  605. package/lib/models/concepts/SourceReferenceModel.js +0 -1
  606. package/lib/models/concepts/SourceReferenceModel.js.map +1 -1
  607. package/lib/models/content/ContentIndexModel.js +3 -9
  608. package/lib/models/content/ContentIndexModel.js.map +1 -1
  609. package/lib/models/content/ContentLinkModel.js +1 -2
  610. package/lib/models/content/ContentLinkModel.js.map +1 -1
  611. package/lib/models/content/ContentModel.js +2 -5
  612. package/lib/models/content/ContentModel.js.map +1 -1
  613. package/lib/models/content/ContentTOCModel.js +2 -5
  614. package/lib/models/content/ContentTOCModel.js.map +1 -1
  615. package/lib/models/content/ContentTypeModel.js +0 -1
  616. package/lib/models/content/ContentTypeModel.js.map +1 -1
  617. package/lib/models/content/SectionModel.js +1 -3
  618. package/lib/models/content/SectionModel.js.map +1 -1
  619. package/lib/models/content/SubSectionModel.js +0 -1
  620. package/lib/models/content/SubSectionModel.js.map +1 -1
  621. package/lib/models/contentconfiguration/ContentConfiguration.js +0 -1
  622. package/lib/models/contentconfiguration/ContentConfiguration.js.map +1 -1
  623. package/lib/models/contentconfiguration/ContentConfigurationElements.js +0 -1
  624. package/lib/models/contentconfiguration/ContentConfigurationElements.js.map +1 -1
  625. package/lib/models/contentconfiguration/ContentConfigurationEndResults.js +0 -1
  626. package/lib/models/contentconfiguration/ContentConfigurationEndResults.js.map +1 -1
  627. package/lib/models/contentconfiguration/ContentConfigurationQuestions.js +0 -1
  628. package/lib/models/contentconfiguration/ContentConfigurationQuestions.js.map +1 -1
  629. package/lib/models/contentconfiguration/ContentConfigurationResults.js +1 -2
  630. package/lib/models/contentconfiguration/ContentConfigurationResults.js.map +1 -1
  631. package/lib/models/detail/DetailModel.js +2 -3
  632. package/lib/models/detail/DetailModel.js.map +1 -1
  633. package/lib/models/error/ErrorCollection.js +0 -1
  634. package/lib/models/error/ErrorCollection.js.map +1 -1
  635. package/lib/models/error/ErrorModel.js +0 -1
  636. package/lib/models/error/ErrorModel.js.map +1 -1
  637. package/lib/models/error/ErrorResponse.js +11 -23
  638. package/lib/models/error/ErrorResponse.js.map +1 -1
  639. package/lib/models/filters/AssignmentFilterModel.js +0 -1
  640. package/lib/models/filters/AssignmentFilterModel.js.map +1 -1
  641. package/lib/models/filters/BaseFilterModel.js +2 -5
  642. package/lib/models/filters/BaseFilterModel.js.map +1 -1
  643. package/lib/models/filters/ConceptIndexFilterModel.js +0 -1
  644. package/lib/models/filters/ConceptIndexFilterModel.js.map +1 -1
  645. package/lib/models/filters/FilterCollection.js +2 -5
  646. package/lib/models/filters/FilterCollection.js.map +1 -1
  647. package/lib/models/filters/FilterModel.js +0 -1
  648. package/lib/models/filters/FilterModel.js.map +1 -1
  649. package/lib/models/filters/RangeFilterModel.js +0 -1
  650. package/lib/models/filters/RangeFilterModel.js.map +1 -1
  651. package/lib/models/form/FormModel.js +13 -29
  652. package/lib/models/form/FormModel.js.map +1 -1
  653. package/lib/models/form/FormObjectModel.js +6 -12
  654. package/lib/models/form/FormObjectModel.js.map +1 -1
  655. package/lib/models/grouping/GroupingModel.js +1 -2
  656. package/lib/models/grouping/GroupingModel.js.map +1 -1
  657. package/lib/models/href/Href.js +0 -1
  658. package/lib/models/href/Href.js.map +1 -1
  659. package/lib/models/href/ListHref.js +0 -1
  660. package/lib/models/href/ListHref.js.map +1 -1
  661. package/lib/models/layouthint/LayoutHintCollection.js +0 -1
  662. package/lib/models/layouthint/LayoutHintCollection.js.map +1 -1
  663. package/lib/models/links/LinkCollection.js +0 -1
  664. package/lib/models/links/LinkCollection.js.map +1 -1
  665. package/lib/models/links/LinkModel.js +0 -1
  666. package/lib/models/links/LinkModel.js.map +1 -1
  667. package/lib/models/list/ListDetailModel.js +4 -7
  668. package/lib/models/list/ListDetailModel.js.map +1 -1
  669. package/lib/models/list/ListHeaderModel.js +0 -1
  670. package/lib/models/list/ListHeaderModel.js.map +1 -1
  671. package/lib/models/list/ListItemCollection.js +0 -1
  672. package/lib/models/list/ListItemCollection.js.map +1 -1
  673. package/lib/models/list/ListItemModel.js +0 -1
  674. package/lib/models/list/ListItemModel.js.map +1 -1
  675. package/lib/models/list/ListModel.js +2 -3
  676. package/lib/models/list/ListModel.js.map +1 -1
  677. package/lib/models/lookup/LookupOptionCollection.js +0 -1
  678. package/lib/models/lookup/LookupOptionCollection.js.map +1 -1
  679. package/lib/models/lookup/LookupOptionsModel.js +0 -1
  680. package/lib/models/lookup/LookupOptionsModel.js.map +1 -1
  681. package/lib/models/modelcatalog/ModelCatalogModel.js +0 -1
  682. package/lib/models/modelcatalog/ModelCatalogModel.js.map +1 -1
  683. package/lib/models/paging/PagingModel.js +0 -1
  684. package/lib/models/paging/PagingModel.js.map +1 -1
  685. package/lib/models/panels/GroupingPanelModel.js +0 -1
  686. package/lib/models/panels/GroupingPanelModel.js.map +1 -1
  687. package/lib/models/parameter/Parameter.js +0 -1
  688. package/lib/models/parameter/Parameter.js.map +1 -1
  689. package/lib/models/process/ProcessStatusSettingsModel.js +0 -1
  690. package/lib/models/process/ProcessStatusSettingsModel.js.map +1 -1
  691. package/lib/models/resolveModel.js +0 -1
  692. package/lib/models/resolveModel.js.map +1 -1
  693. package/lib/models/search/CaseSearchModel.js +0 -1
  694. package/lib/models/search/CaseSearchModel.js.map +1 -1
  695. package/lib/models/sorting/SortOptionModel.js +0 -1
  696. package/lib/models/sorting/SortOptionModel.js.map +1 -1
  697. package/lib/models/sorting/SortingModel.js +1 -2
  698. package/lib/models/sorting/SortingModel.js.map +1 -1
  699. package/lib/models/tab/TabModel.js +1 -3
  700. package/lib/models/tab/TabModel.js.map +1 -1
  701. package/lib/models/taskgroup/TaskGroupCollection.js +0 -1
  702. package/lib/models/taskgroup/TaskGroupCollection.js.map +1 -1
  703. package/lib/models/taskgroup/TaskGroupModel.js +0 -1
  704. package/lib/models/taskgroup/TaskGroupModel.js.map +1 -1
  705. package/lib/models/user/UserModel.js +0 -1
  706. package/lib/models/user/UserModel.js.map +1 -1
  707. package/lib/models/user/UserProfileModel.js +0 -1
  708. package/lib/models/user/UserProfileModel.js.map +1 -1
  709. package/lib/models/user/UserServicesModel.js +0 -1
  710. package/lib/models/user/UserServicesModel.js.map +1 -1
  711. package/lib/modularui/Authenticate.js +0 -1
  712. package/lib/modularui/Authenticate.js.map +1 -1
  713. package/lib/modularui/ModularUIRequest.js +4 -10
  714. package/lib/modularui/ModularUIRequest.js.map +1 -1
  715. package/lib/modularui/ModularUIResponse.js +2 -4
  716. package/lib/modularui/ModularUIResponse.js.map +1 -1
  717. package/lib/react/ErrorBoundary.js +0 -1
  718. package/lib/react/ErrorBoundary.js.map +1 -1
  719. package/lib/react/ErrorBoundaryFallback.js +0 -1
  720. package/lib/react/ErrorBoundaryFallback.js.map +1 -1
  721. package/lib/react/utils.js +0 -1
  722. package/lib/react/utils.js.map +1 -1
  723. package/lib/react-client/Init.js +0 -1
  724. package/lib/react-client/Init.js.map +1 -1
  725. package/lib/react-client/client.js +0 -1
  726. package/lib/react-client/client.js.map +1 -1
  727. package/lib/react-client/rehydrate.js +1 -2
  728. package/lib/react-client/rehydrate.js.map +1 -1
  729. package/lib/react-server/contextPath.js +0 -1
  730. package/lib/react-server/contextPath.js.map +1 -1
  731. package/lib/react-server/createSSRComplete.js +0 -1
  732. package/lib/react-server/createSSRComplete.js.map +1 -1
  733. package/lib/react-server/htmlpage.js +1 -2
  734. package/lib/react-server/htmlpage.js.map +1 -1
  735. package/lib/react-server/renderSSRComplete.js +0 -1
  736. package/lib/react-server/renderSSRComplete.js.map +1 -1
  737. package/lib/react-server/renderSSRMinimal.js +0 -1
  738. package/lib/react-server/renderSSRMinimal.js.map +1 -1
  739. package/lib/react-server/requestInformation.js +0 -1
  740. package/lib/react-server/requestInformation.js.map +1 -1
  741. package/lib/react-server/serverNoSSR.js +1 -3
  742. package/lib/react-server/serverNoSSR.js.map +1 -1
  743. package/lib/react-server/serverSSR.js +0 -1
  744. package/lib/react-server/serverSSR.js.map +1 -1
  745. package/lib/react-server/serverUtil.js +0 -1
  746. package/lib/react-server/serverUtil.js.map +1 -1
  747. package/lib/react-theme/ThemeProvider.js +0 -1
  748. package/lib/react-theme/ThemeProvider.js.map +1 -1
  749. package/lib/react-theme/createTheme.js +0 -1
  750. package/lib/react-theme/createTheme.js.map +1 -1
  751. package/lib/react-theme/useTheme.js +0 -1
  752. package/lib/react-theme/useTheme.js.map +1 -1
  753. package/lib/react-theme/utils/background.js +0 -1
  754. package/lib/react-theme/utils/background.js.map +1 -1
  755. package/lib/react-theme/utils/colors.js +0 -1
  756. package/lib/react-theme/utils/colors.js.map +1 -1
  757. package/lib/react-theme/utils/contrast.js +1 -3
  758. package/lib/react-theme/utils/contrast.js.map +1 -1
  759. package/lib/react-theme/utils/corners.js +0 -1
  760. package/lib/react-theme/utils/corners.js.map +1 -1
  761. package/lib/react-theme/utils/spacers.js +0 -1
  762. package/lib/react-theme/utils/spacers.js.map +1 -1
  763. package/lib/react-theme/utils/themeProps.js +0 -1
  764. package/lib/react-theme/utils/themeProps.js.map +1 -1
  765. package/lib/redux/_i18n/actions.js +0 -1
  766. package/lib/redux/_i18n/actions.js.map +1 -1
  767. package/lib/redux/_i18n/reducer.js +0 -1
  768. package/lib/redux/_i18n/reducer.js.map +1 -1
  769. package/lib/redux/_modularui/actions.js +7 -8
  770. package/lib/redux/_modularui/actions.js.map +1 -1
  771. package/lib/redux/_modularui/connector.js +2 -4
  772. package/lib/redux/_modularui/connector.js.map +1 -1
  773. package/lib/redux/_modularui/middleware.js +0 -1
  774. package/lib/redux/_modularui/middleware.js.map +1 -1
  775. package/lib/redux/_modularui/modularuiUtils.js +2 -3
  776. package/lib/redux/_modularui/modularuiUtils.js.map +1 -1
  777. package/lib/redux/_modularui/reducer.js +1 -3
  778. package/lib/redux/_modularui/reducer.js.map +1 -1
  779. package/lib/redux/_modularui/selectors.js +7 -14
  780. package/lib/redux/_modularui/selectors.js.map +1 -1
  781. package/lib/redux/_modularui/withModularUI.js +0 -1
  782. package/lib/redux/_modularui/withModularUI.js.map +1 -1
  783. package/lib/redux/_router/actions.js +0 -1
  784. package/lib/redux/_router/actions.js.map +1 -1
  785. package/lib/redux/_router/connectors.js +9 -19
  786. package/lib/redux/_router/connectors.js.map +1 -1
  787. package/lib/redux/_router/middleware.js +0 -1
  788. package/lib/redux/_router/middleware.js.map +1 -1
  789. package/lib/redux/_router/reducer.js +0 -1
  790. package/lib/redux/_router/reducer.js.map +1 -1
  791. package/lib/redux/actions/Application.js +0 -1
  792. package/lib/redux/actions/Application.js.map +1 -1
  793. package/lib/redux/actions/Authorization.js +4 -7
  794. package/lib/redux/actions/Authorization.js.map +1 -1
  795. package/lib/redux/actions/Error.js +0 -1
  796. package/lib/redux/actions/Error.js.map +1 -1
  797. package/lib/redux/actions/Form.js +0 -1
  798. package/lib/redux/actions/Form.js.map +1 -1
  799. package/lib/redux/actions/FormAttributeSet.js +2 -4
  800. package/lib/redux/actions/FormAttributeSet.js.map +1 -1
  801. package/lib/redux/actions/FormAttributeSetRepeatable.js +0 -1
  802. package/lib/redux/actions/FormAttributeSetRepeatable.js.map +1 -1
  803. package/lib/redux/actions/FormAutosave.js +0 -1
  804. package/lib/redux/actions/FormAutosave.js.map +1 -1
  805. package/lib/redux/actions/FormAutosubmit.js +0 -1
  806. package/lib/redux/actions/FormAutosubmit.js.map +1 -1
  807. package/lib/redux/actions/FormValidations.js +0 -1
  808. package/lib/redux/actions/FormValidations.js.map +1 -1
  809. package/lib/redux/actions/Modals.js +0 -1
  810. package/lib/redux/actions/Modals.js.map +1 -1
  811. package/lib/redux/actions/Notification.js +0 -1
  812. package/lib/redux/actions/Notification.js.map +1 -1
  813. package/lib/redux/actions/Preferences.js +5 -6
  814. package/lib/redux/actions/Preferences.js.map +1 -1
  815. package/lib/redux/actions/ProgressIndicator.js +0 -1
  816. package/lib/redux/actions/ProgressIndicator.js.map +1 -1
  817. package/lib/redux/actions/SignIn.js +2 -4
  818. package/lib/redux/actions/SignIn.js.map +1 -1
  819. package/lib/redux/actions/SignOut.js +0 -1
  820. package/lib/redux/actions/SignOut.js.map +1 -1
  821. package/lib/redux/connectors/Application.js +0 -1
  822. package/lib/redux/connectors/Application.js.map +1 -1
  823. package/lib/redux/connectors/Breadcrumb.js +0 -1
  824. package/lib/redux/connectors/Breadcrumb.js.map +1 -1
  825. package/lib/redux/connectors/CaseView.js +0 -1
  826. package/lib/redux/connectors/CaseView.js.map +1 -1
  827. package/lib/redux/connectors/ConceptDetail.js +0 -1
  828. package/lib/redux/connectors/ConceptDetail.js.map +1 -1
  829. package/lib/redux/connectors/ContentBrowser.js +0 -1
  830. package/lib/redux/connectors/ContentBrowser.js.map +1 -1
  831. package/lib/redux/connectors/ContentDetail.js +0 -1
  832. package/lib/redux/connectors/ContentDetail.js.map +1 -1
  833. package/lib/redux/connectors/ContentDetailSection.js +0 -1
  834. package/lib/redux/connectors/ContentDetailSection.js.map +1 -1
  835. package/lib/redux/connectors/Form.js +3 -7
  836. package/lib/redux/connectors/Form.js.map +1 -1
  837. package/lib/redux/connectors/FormAttributeSet.js +0 -1
  838. package/lib/redux/connectors/FormAttributeSet.js.map +1 -1
  839. package/lib/redux/connectors/ListDetail.js +0 -1
  840. package/lib/redux/connectors/ListDetail.js.map +1 -1
  841. package/lib/redux/connectors/Modal.js +0 -1
  842. package/lib/redux/connectors/Modal.js.map +1 -1
  843. package/lib/redux/connectors/ModelCatalog.js +0 -1
  844. package/lib/redux/connectors/ModelCatalog.js.map +1 -1
  845. package/lib/redux/connectors/Notification.js +0 -1
  846. package/lib/redux/connectors/Notification.js.map +1 -1
  847. package/lib/redux/connectors/PanelRenderer.js +0 -1
  848. package/lib/redux/connectors/PanelRenderer.js.map +1 -1
  849. package/lib/redux/connectors/Preferences.js +0 -1
  850. package/lib/redux/connectors/Preferences.js.map +1 -1
  851. package/lib/redux/connectors/Progress.js +0 -1
  852. package/lib/redux/connectors/Progress.js.map +1 -1
  853. package/lib/redux/connectors/ProgressIndicator.js +0 -1
  854. package/lib/redux/connectors/ProgressIndicator.js.map +1 -1
  855. package/lib/redux/connectors/QuickSearch.js +0 -1
  856. package/lib/redux/connectors/QuickSearch.js.map +1 -1
  857. package/lib/redux/connectors/SignIn.js +1 -2
  858. package/lib/redux/connectors/SignIn.js.map +1 -1
  859. package/lib/redux/connectors/SignOut.js +3 -7
  860. package/lib/redux/connectors/SignOut.js.map +1 -1
  861. package/lib/redux/connectors/Tab.js +0 -1
  862. package/lib/redux/connectors/Tab.js.map +1 -1
  863. package/lib/redux/reducers/AuthReducer.js +0 -1
  864. package/lib/redux/reducers/AuthReducer.js.map +1 -1
  865. package/lib/redux/reducers/ErrorReducer.js +0 -1
  866. package/lib/redux/reducers/ErrorReducer.js.map +1 -1
  867. package/lib/redux/reducers/ModalsReducer.js +0 -1
  868. package/lib/redux/reducers/ModalsReducer.js.map +1 -1
  869. package/lib/redux/reducers/NotificationReducer.js +0 -1
  870. package/lib/redux/reducers/NotificationReducer.js.map +1 -1
  871. package/lib/redux/reducers/PreferencesReducer.js +2 -3
  872. package/lib/redux/reducers/PreferencesReducer.js.map +1 -1
  873. package/lib/redux/reducers/ProgressIndicatorReducer.js +1 -3
  874. package/lib/redux/reducers/ProgressIndicatorReducer.js.map +1 -1
  875. package/lib/redux/reducers/createReducer.js +0 -1
  876. package/lib/redux/reducers/createReducer.js.map +1 -1
  877. package/lib/redux/selectors/i18n.js +1 -3
  878. package/lib/redux/selectors/i18n.js.map +1 -1
  879. package/lib/redux/store/beforeRenderHooks.js +0 -1
  880. package/lib/redux/store/beforeRenderHooks.js.map +1 -1
  881. package/lib/redux/store/configureStore.js +0 -1
  882. package/lib/redux/store/configureStore.js.map +1 -1
  883. package/lib/utils/browser/Cache.js +0 -1
  884. package/lib/utils/browser/Cache.js.map +1 -1
  885. package/lib/utils/browser/Cookies.js +3 -4
  886. package/lib/utils/browser/Cookies.js.map +1 -1
  887. package/lib/utils/datetime/DateTimeUtil.js +0 -1
  888. package/lib/utils/datetime/DateTimeUtil.js.map +1 -1
  889. package/lib/utils/fetch/serverFetch.js +0 -1
  890. package/lib/utils/fetch/serverFetch.js.map +1 -1
  891. package/lib/utils/fetch/universalFetch.js +0 -1
  892. package/lib/utils/fetch/universalFetch.js.map +1 -1
  893. package/lib/utils/fetch/xhr.js +0 -1
  894. package/lib/utils/fetch/xhr.js.map +1 -1
  895. package/lib/utils/helpers/checkResource.js +0 -1
  896. package/lib/utils/helpers/checkResource.js.map +1 -1
  897. package/lib/utils/helpers/createHash.js +0 -1
  898. package/lib/utils/helpers/createHash.js.map +1 -1
  899. package/lib/utils/helpers/objects.js +0 -1
  900. package/lib/utils/helpers/objects.js.map +1 -1
  901. package/lib/utils/helpers/sanitizeHtml.js +0 -1
  902. package/lib/utils/helpers/sanitizeHtml.js.map +1 -1
  903. package/lib/utils/helpers/text.js +0 -1
  904. package/lib/utils/helpers/text.js.map +1 -1
  905. package/lib/utils/number/formatValue.js +0 -1
  906. package/lib/utils/number/formatValue.js.map +1 -1
  907. package/lib/utils/number/parseNumbers.js +0 -1
  908. package/lib/utils/number/parseNumbers.js.map +1 -1
  909. package/package.json +18 -13
  910. package/types/constants/Constants.d.ts +151 -0
  911. package/types/constants/LayoutHintConfig.d.ts +241 -0
  912. package/types/constants/LayoutHints.d.ts +78 -0
  913. package/types/constants/Settings.d.ts +16 -0
  914. package/types/constants/index.d.ts +3 -0
  915. package/types/exceptions/ConfigurationException.d.ts +6 -0
  916. package/types/exceptions/FetchException.d.ts +31 -0
  917. package/types/exceptions/IllegalArgumentException.d.ts +6 -0
  918. package/types/exceptions/IllegalReturnException.d.ts +5 -0
  919. package/types/exceptions/IllegalStateException.d.ts +6 -0
  920. package/types/exceptions/JsonParseException.d.ts +6 -0
  921. package/types/exceptions/MissingPropertyException.d.ts +6 -0
  922. package/types/exceptions/NetworkException.d.ts +9 -0
  923. package/types/exceptions/NotAllowedUriException.d.ts +6 -0
  924. package/types/exceptions/NotFoundException.d.ts +10 -0
  925. package/types/exceptions/ServerRequestException.d.ts +6 -0
  926. package/types/exceptions/ThemePropertyException.d.ts +6 -0
  927. package/types/exceptions/TimeoutException.d.ts +7 -0
  928. package/types/exceptions/UnauthorizedException.d.ts +11 -0
  929. package/types/exceptions/UnsupportedOperationException.d.ts +6 -0
  930. package/types/exceptions/index.d.ts +15 -0
  931. package/types/hooks/useI18n.d.ts +9 -0
  932. package/types/i18n/Locale.d.ts +53 -0
  933. package/types/i18n/Locales.d.ts +55 -0
  934. package/types/i18n/Message.d.ts +6 -0
  935. package/types/i18n/index.d.ts +5 -0
  936. package/types/i18n/languages.d.ts +215 -0
  937. package/types/i18n/translations/beinformed_error_messages_en.nl.d.ts +97 -0
  938. package/types/i18n/translations/beinformed_error_messages_nl.nl.d.ts +97 -0
  939. package/types/i18n/types.d.ts +11 -0
  940. package/types/i18n/withMessage.d.ts +3 -0
  941. package/types/index.d.ts +6 -0
  942. package/types/models/actions/ActionCollection.d.ts +29 -0
  943. package/types/models/actions/ActionModel.d.ts +84 -0
  944. package/types/models/application/ApplicationModel.d.ts +41 -0
  945. package/types/models/attributes/AttributeCollection.d.ts +96 -0
  946. package/types/models/attributes/AttributeContent.d.ts +64 -0
  947. package/types/models/attributes/AttributeDataHelper.d.ts +67 -0
  948. package/types/models/attributes/AttributeModel.d.ts +395 -0
  949. package/types/models/attributes/AttributeSetModel.d.ts +28 -0
  950. package/types/models/attributes/BooleanAttributeModel.d.ts +65 -0
  951. package/types/models/attributes/CaptchaAttributeModel.d.ts +10 -0
  952. package/types/models/attributes/ChoiceAttributeModel.d.ts +76 -0
  953. package/types/models/attributes/ChoiceAttributeOptionCollection.d.ts +82 -0
  954. package/types/models/attributes/ChoiceAttributeOptionModel.d.ts +133 -0
  955. package/types/models/attributes/CompositeAttributeChildCollection.d.ts +56 -0
  956. package/types/models/attributes/CompositeAttributeModel.d.ts +44 -0
  957. package/types/models/attributes/DatetimeAttributeModel.d.ts +111 -0
  958. package/types/models/attributes/HelptextAttributeModel.d.ts +16 -0
  959. package/types/models/attributes/LabelAttributeModel.d.ts +12 -0
  960. package/types/models/attributes/MemoAttributeModel.d.ts +14 -0
  961. package/types/models/attributes/MoneyAttributeModel.d.ts +14 -0
  962. package/types/models/attributes/NumberAttributeModel.d.ts +49 -0
  963. package/types/models/attributes/PasswordAttributeModel.d.ts +62 -0
  964. package/types/models/attributes/StringAttributeModel.d.ts +62 -0
  965. package/types/models/attributes/UploadAttributeModel.d.ts +54 -0
  966. package/types/models/attributes/XMLAttributeModel.d.ts +10 -0
  967. package/types/models/attributes/_createAttribute.d.ts +6 -0
  968. package/types/models/attributes/input-constraints/BSNConstraint.d.ts +26 -0
  969. package/types/models/attributes/input-constraints/ConstraintCollection.d.ts +24 -0
  970. package/types/models/attributes/input-constraints/ConstraintModel.d.ts +34 -0
  971. package/types/models/attributes/input-constraints/DateBoundaryConstraint.d.ts +109 -0
  972. package/types/models/attributes/input-constraints/DateTimeDateFormatConstraint.d.ts +36 -0
  973. package/types/models/attributes/input-constraints/DateTimeTimeFormatConstraint.d.ts +36 -0
  974. package/types/models/attributes/input-constraints/DatetimeFormatConstraint.d.ts +92 -0
  975. package/types/models/attributes/input-constraints/FileExtensionConstraint.d.ts +33 -0
  976. package/types/models/attributes/input-constraints/FileSizeConstraint.d.ts +42 -0
  977. package/types/models/attributes/input-constraints/IBANConstraint.d.ts +23 -0
  978. package/types/models/attributes/input-constraints/MandatoryConstraint.d.ts +23 -0
  979. package/types/models/attributes/input-constraints/MandatoryRangeConstraint.d.ts +36 -0
  980. package/types/models/attributes/input-constraints/NumberBoundaryConstraint.d.ts +61 -0
  981. package/types/models/attributes/input-constraints/NumberFormatConstraint.d.ts +52 -0
  982. package/types/models/attributes/input-constraints/NumberGroupingConstraint.d.ts +46 -0
  983. package/types/models/attributes/input-constraints/PasswordConfirmConstraint.d.ts +36 -0
  984. package/types/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.d.ts +23 -0
  985. package/types/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.d.ts +32 -0
  986. package/types/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.d.ts +32 -0
  987. package/types/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.d.ts +35 -0
  988. package/types/models/attributes/input-constraints/RangeConstraint.d.ts +97 -0
  989. package/types/models/attributes/input-constraints/RegexConstraint.d.ts +37 -0
  990. package/types/models/attributes/input-constraints/StringLengthConstraint.d.ts +46 -0
  991. package/types/models/attributes/input-constraints/XMLConstraint.d.ts +26 -0
  992. package/types/models/attributes/layouthint-rules/BaseLayoutHintRule.d.ts +46 -0
  993. package/types/models/attributes/layouthint-rules/DependentAttribute.d.ts +57 -0
  994. package/types/models/attributes/layouthint-rules/LayoutHintRuleCollection.d.ts +27 -0
  995. package/types/models/attributes/layouthint-rules/RemainingTotalUploadSize.d.ts +17 -0
  996. package/types/models/base/BaseCollection.d.ts +89 -0
  997. package/types/models/base/BaseModel.d.ts +58 -0
  998. package/types/models/base/ResourceCollection.d.ts +19 -0
  999. package/types/models/base/ResourceModel.d.ts +93 -0
  1000. package/types/models/caseview/CaseViewModel.d.ts +45 -0
  1001. package/types/models/concepts/BusinessScenarioModel.d.ts +20 -0
  1002. package/types/models/concepts/ConceptDetailModel.d.ts +69 -0
  1003. package/types/models/concepts/ConceptIndexModel.d.ts +36 -0
  1004. package/types/models/concepts/ConceptLinkModel.d.ts +65 -0
  1005. package/types/models/concepts/ConceptRelationCollection.d.ts +34 -0
  1006. package/types/models/concepts/ConceptRelationModel.d.ts +43 -0
  1007. package/types/models/concepts/ConceptTypeDetailModel.d.ts +39 -0
  1008. package/types/models/concepts/SourceReferenceCollection.d.ts +13 -0
  1009. package/types/models/concepts/SourceReferenceModel.d.ts +30 -0
  1010. package/types/models/content/ContentIndexModel.d.ts +34 -0
  1011. package/types/models/content/ContentLinkModel.d.ts +81 -0
  1012. package/types/models/content/ContentModel.d.ts +74 -0
  1013. package/types/models/content/ContentTOCModel.d.ts +37 -0
  1014. package/types/models/content/ContentTypeModel.d.ts +26 -0
  1015. package/types/models/content/SectionModel.d.ts +75 -0
  1016. package/types/models/content/SubSectionModel.d.ts +64 -0
  1017. package/types/models/contentconfiguration/ContentConfiguration.d.ts +28 -0
  1018. package/types/models/contentconfiguration/ContentConfigurationElements.d.ts +47 -0
  1019. package/types/models/contentconfiguration/ContentConfigurationEndResults.d.ts +16 -0
  1020. package/types/models/contentconfiguration/ContentConfigurationQuestions.d.ts +22 -0
  1021. package/types/models/contentconfiguration/ContentConfigurationResults.d.ts +39 -0
  1022. package/types/models/detail/DetailModel.d.ts +72 -0
  1023. package/types/models/error/ErrorCollection.d.ts +51 -0
  1024. package/types/models/error/ErrorModel.d.ts +36 -0
  1025. package/types/models/error/ErrorResponse.d.ts +148 -0
  1026. package/types/models/filters/AssignmentFilterModel.d.ts +35 -0
  1027. package/types/models/filters/BaseFilterModel.d.ts +85 -0
  1028. package/types/models/filters/ConceptIndexFilterModel.d.ts +6 -0
  1029. package/types/models/filters/FilterCollection.d.ts +48 -0
  1030. package/types/models/filters/FilterModel.d.ts +5 -0
  1031. package/types/models/filters/RangeFilterModel.d.ts +6 -0
  1032. package/types/models/form/FormModel.d.ts +309 -0
  1033. package/types/models/form/FormObjectModel.d.ts +168 -0
  1034. package/types/models/grouping/GroupingModel.d.ts +85 -0
  1035. package/types/models/href/Href.d.ts +17 -0
  1036. package/types/models/href/ListHref.d.ts +64 -0
  1037. package/types/models/index.d.ts +94 -0
  1038. package/types/models/layouthint/LayoutHintCollection.d.ts +43 -0
  1039. package/types/models/links/LinkCollection.d.ts +62 -0
  1040. package/types/models/links/LinkModel.d.ts +92 -0
  1041. package/types/models/links/normalizeLinkJSON.d.ts +9 -0
  1042. package/types/models/list/ListDetailModel.d.ts +69 -0
  1043. package/types/models/list/ListHeaderModel.d.ts +64 -0
  1044. package/types/models/list/ListItemCollection.d.ts +21 -0
  1045. package/types/models/list/ListItemModel.d.ts +34 -0
  1046. package/types/models/list/ListModel.d.ts +135 -0
  1047. package/types/models/lookup/LookupOptionCollection.d.ts +11 -0
  1048. package/types/models/lookup/LookupOptionsModel.d.ts +19 -0
  1049. package/types/models/modelcatalog/ModelCatalogModel.d.ts +18 -0
  1050. package/types/models/paging/PagesizeModel.d.ts +25 -0
  1051. package/types/models/paging/PagingModel.d.ts +49 -0
  1052. package/types/models/panels/GroupingPanelModel.d.ts +39 -0
  1053. package/types/models/parameter/Parameter.d.ts +40 -0
  1054. package/types/models/process/ProcessStatusSettingsModel.d.ts +38 -0
  1055. package/types/models/resolveModel.d.ts +7 -0
  1056. package/types/models/search/CaseSearchModel.d.ts +14 -0
  1057. package/types/models/sorting/SortOptionModel.d.ts +48 -0
  1058. package/types/models/sorting/SortingModel.d.ts +42 -0
  1059. package/types/models/tab/TabModel.d.ts +44 -0
  1060. package/types/models/taskgroup/TaskGroupCollection.d.ts +12 -0
  1061. package/types/models/taskgroup/TaskGroupModel.d.ts +15 -0
  1062. package/types/models/types.d.ts +147 -0
  1063. package/types/models/user/UserModel.d.ts +14 -0
  1064. package/types/models/user/UserProfileModel.d.ts +12 -0
  1065. package/types/models/user/UserServicesModel.d.ts +28 -0
  1066. package/types/modularui/Authenticate.d.ts +42 -0
  1067. package/types/modularui/ModularUIError.d.ts +10 -0
  1068. package/types/modularui/ModularUIRequest.d.ts +170 -0
  1069. package/types/modularui/ModularUIResponse.d.ts +56 -0
  1070. package/types/modularui/index.d.ts +3 -0
  1071. package/types/redux/_i18n/types.d.ts +13 -0
  1072. package/types/redux/_modularui/types.d.ts +49 -0
  1073. package/types/redux/_router/types.d.ts +35 -0
  1074. package/types/redux/selectors/i18n.d.ts +4 -0
  1075. package/types/redux/types.d.ts +105 -0
  1076. package/types/utils/browser/Cache.d.ts +45 -0
  1077. package/types/utils/browser/Cookies.d.ts +15 -0
  1078. package/types/utils/datetime/DateTimeUtil.d.ts +164 -0
  1079. package/types/utils/fetch/serverFetch.d.ts +5 -0
  1080. package/types/utils/fetch/types.d.ts +38 -0
  1081. package/types/utils/fetch/universalFetch.d.ts +7 -0
  1082. package/types/utils/fetch/xhr.d.ts +5 -0
  1083. package/types/utils/helpers/checkResource.d.ts +3 -0
  1084. package/types/utils/helpers/createHash.d.ts +8 -0
  1085. package/types/utils/helpers/createUUID.d.ts +4 -0
  1086. package/types/utils/helpers/objects.d.ts +3 -0
  1087. package/types/utils/helpers/sanitizeHtml.d.ts +9 -0
  1088. package/types/utils/helpers/text.d.ts +7 -0
  1089. package/types/utils/index.d.ts +16 -0
  1090. package/types/utils/number/DecimalFormat.d.ts +90 -0
  1091. package/types/utils/number/formatValue.d.ts +4 -0
  1092. package/types/utils/number/parseNumbers.d.ts +9 -0
@@ -1 +1 @@
1
- {"version":3,"file":"NumberFormatConstraint.js","names":["INVALID_INTEGER_ID","NumberFormatConstraint","constructor","groupingSeparator","decimalSeparator","format","_decimalSeparator","_groupingSeparator","_format","id","maxDigits","DecimalFormat","maxFrac","hasValidation","defaultMessage","parameters","isInteger","value","getNumberOfDigits","Math","floor","stringValue","parseNumberToString","split","length","isValidDecimal","isNaN","numberOfDigits","parseFloat","isFinite","validate","toString","parsedNumber","parseToNumber","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/NumberFormatConstraint.js"],"sourcesContent":["// @flow\nimport DecimalFormat from \"../../../utils/number/DecimalFormat\";\nimport {\n parseNumberToString,\n parseToNumber,\n} from \"../../../utils/number/parseNumbers\";\n\nimport type { IConstraintModel } from \"../../types\";\n\nconst INVALID_INTEGER_ID = \"Constraint.Number.InvalidInteger\";\n\n/**\n */\nclass NumberFormatConstraint implements IConstraintModel {\n _decimalSeparator: string = \",\";\n _groupingSeparator: string = \".\";\n _format: string = \"0\";\n\n /**\n */\n constructor(\n groupingSeparator: string,\n decimalSeparator: string,\n format: string | null\n ) {\n this._decimalSeparator = decimalSeparator;\n this._groupingSeparator = groupingSeparator;\n this._format = format ?? \"0\";\n }\n\n /**\n */\n get id(): string {\n if (this.maxDigits === 0) {\n return INVALID_INTEGER_ID;\n }\n\n return \"Constraint.Number.InvalidDecimal\";\n }\n\n /**\n */\n get decimalSeparator(): string {\n return this._decimalSeparator;\n }\n\n /**\n */\n get groupingSeparator(): string {\n return this._groupingSeparator;\n }\n\n /**\n */\n get format(): string {\n return this._format;\n }\n\n /**\n */\n get maxDigits(): number {\n return this.format ? new DecimalFormat(this.format).maxFrac : 0;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n if (this.id === INVALID_INTEGER_ID) {\n return \"Must be a whole number\";\n }\n\n return \"The value is not correct numeric format\";\n }\n\n /**\n */\n get parameters(): { \"max-digits\": number } {\n return {\n \"max-digits\": this.maxDigits,\n };\n }\n\n /**\n */\n isInteger(value: number): boolean {\n return Number.isInteger(value);\n }\n\n /**\n */\n getNumberOfDigits(value: number): number {\n if (Math.floor(value) === value) {\n return 0;\n }\n\n const stringValue = parseNumberToString(value);\n return stringValue.split(\".\")[1].length;\n }\n\n /**\n */\n isValidDecimal(value: number): boolean {\n if (isNaN(value)) {\n return false;\n }\n\n const numberOfDigits = this.getNumberOfDigits(value);\n\n return (\n !isNaN(parseFloat(value)) &&\n isFinite(value) &&\n numberOfDigits <= this.maxDigits\n );\n }\n\n /**\n */\n validate(value: string | number): boolean {\n if (\n this.maxDigits === 0 &&\n this.decimalSeparator !== \"\" &&\n value.toString().includes(this.decimalSeparator)\n ) {\n return false;\n }\n\n const parsedNumber = parseToNumber(\n value,\n this.groupingSeparator,\n this.decimalSeparator\n );\n\n if (this.id === INVALID_INTEGER_ID) {\n return this.isInteger(parsedNumber);\n }\n\n return this.isValidDecimal(parsedNumber);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default NumberFormatConstraint;\n"],"mappings":";;;;;;;;;;AACA;AACA;;AAOA,MAAMA,kBAAkB,GAAG,kCAAkC;;AAE7D;AACA;AACA,MAAMC,sBAAsB,CAA6B;EAKvD;AACF;EACEC,WAAW,CACTC,iBAAyB,EACzBC,gBAAwB,EACxBC,MAAqB,EACrB;IAAA,yDAV0B,GAAG;IAAA,0DACF,GAAG;IAAA,+CACd,GAAG;IASnB,IAAI,CAACC,iBAAiB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CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAACC,MAAM;EACzC;;EAEA;AACF;EACEC,cAAc,CAACR,KAAa,EAAW;IACrC,IAAIS,KAAK,CAACT,KAAK,CAAC,EAAE;MAChB,OAAO,KAAK;IACd;IAEA,MAAMU,cAAc,GAAG,IAAI,CAACT,iBAAiB,CAACD,KAAK,CAAC;IAEpD,OACE,CAACS,KAAK,CAACE,UAAU,CAACX,KAAK,CAAC,CAAC,IACzBY,QAAQ,CAACZ,KAAK,CAAC,IACfU,cAAc,IAAI,IAAI,CAACjB,SAAS;EAEpC;;EAEA;AACF;EACEoB,QAAQ,CAACb,KAAsB,EAAW;IAAA;IACxC,IACE,IAAI,CAACP,SAAS,KAAK,CAAC,IACpB,IAAI,CAACN,gBAAgB,KAAK,EAAE,IAC5B,kCAAAa,KAAK,CAACc,QAAQ,EAAE,iBAAU,IAAI,CAAC3B,gBAAgB,CAAC,EAChD;MACA,OAAO,KAAK;IACd;IAEA,MAAM4B,YAAY,GAAG,IAAAC,2BAAa,EAChChB,KAAK,EACL,IAAI,CAACd,iBAAiB,EACtB,IAAI,CAACC,gBAAgB,CACtB;IAED,IAAI,IAAI,CAACK,EAAE,KAAKT,kBAAkB,EAAE;MAClC,OAAO,IAAI,CAACgB,SAAS,CAACgB,YAAY,CAAC;IACrC;IAEA,OAAO,IAAI,CAACP,cAAc,CAACO,YAAY,CAAC;EAC1C;;EAEA;AACF;EACE,IAAIE,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcjC,sBAAsB;AAAA"}
1
+ {"version":3,"file":"NumberFormatConstraint.js","names":["INVALID_INTEGER_ID","NumberFormatConstraint","constructor","groupingSeparator","decimalSeparator","format","_decimalSeparator","_groupingSeparator","_format","id","maxDigits","DecimalFormat","maxFrac","hasValidation","defaultMessage","parameters","isInteger","value","getNumberOfDigits","Math","floor","stringValue","parseNumberToString","split","length","isValidDecimal","isNaN","numberOfDigits","parseFloat","isFinite","validate","toString","parsedNumber","parseToNumber","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/NumberFormatConstraint.js"],"sourcesContent":["// @flow\nimport DecimalFormat from \"../../../utils/number/DecimalFormat\";\nimport {\n parseNumberToString,\n parseToNumber,\n} from \"../../../utils/number/parseNumbers\";\n\nimport type { IConstraintModel } from \"../../types\";\n\nconst INVALID_INTEGER_ID = \"Constraint.Number.InvalidInteger\";\n\n/**\n */\nclass NumberFormatConstraint implements IConstraintModel {\n _decimalSeparator: string = \",\";\n _groupingSeparator: string = \".\";\n _format: string = \"0\";\n\n /**\n */\n constructor(\n groupingSeparator: string,\n decimalSeparator: string,\n format: string | null\n ) {\n this._decimalSeparator = decimalSeparator;\n this._groupingSeparator = groupingSeparator;\n this._format = format ?? \"0\";\n }\n\n /**\n */\n get id(): string {\n if (this.maxDigits === 0) {\n return INVALID_INTEGER_ID;\n }\n\n return \"Constraint.Number.InvalidDecimal\";\n }\n\n /**\n */\n get decimalSeparator(): string {\n return this._decimalSeparator;\n }\n\n /**\n */\n get groupingSeparator(): string {\n return this._groupingSeparator;\n }\n\n /**\n */\n get format(): string {\n return this._format;\n }\n\n /**\n */\n get maxDigits(): number {\n return this.format ? new DecimalFormat(this.format).maxFrac : 0;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n if (this.id === INVALID_INTEGER_ID) {\n return \"Must be a whole number\";\n }\n\n return \"The value is not correct numeric format\";\n }\n\n /**\n */\n get parameters(): { \"max-digits\": number } {\n return {\n \"max-digits\": this.maxDigits,\n };\n }\n\n /**\n */\n isInteger(value: number): boolean {\n return Number.isInteger(value);\n }\n\n /**\n */\n getNumberOfDigits(value: number): number {\n if (Math.floor(value) === value) {\n return 0;\n }\n\n const stringValue = parseNumberToString(value);\n return stringValue.split(\".\")[1].length;\n }\n\n /**\n */\n isValidDecimal(value: number): boolean {\n if (isNaN(value)) {\n return false;\n }\n\n const numberOfDigits = this.getNumberOfDigits(value);\n\n return (\n !isNaN(parseFloat(value)) &&\n isFinite(value) &&\n numberOfDigits <= this.maxDigits\n );\n }\n\n /**\n */\n validate(value: string | number): boolean {\n if (\n this.maxDigits === 0 &&\n this.decimalSeparator !== \"\" &&\n value.toString().includes(this.decimalSeparator)\n ) {\n return false;\n }\n\n const parsedNumber = parseToNumber(\n value,\n this.groupingSeparator,\n this.decimalSeparator\n );\n\n if (this.id === INVALID_INTEGER_ID) {\n return this.isInteger(parsedNumber);\n }\n\n return this.isValidDecimal(parsedNumber);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default NumberFormatConstraint;\n"],"mappings":";;;;;;;;;;AACA;AACA;AAOA,MAAMA,kBAAkB,GAAG,kCAAkC;;AAE7D;AACA;AACA,MAAMC,sBAAsB,CAA6B;EAKvD;AACF;EACEC,WAAW,CACTC,iBAAyB,EACzBC,gBAAwB,EACxBC,MAAqB,EACrB;IAAA,yDAV0B,GAAG;IAAA,0DACF,GAAG;IAAA,+CACd,GAAG;IASnB,IAAI,CAACC,iBAAiB,GAAGF,gBAAgB;IACzC,IAAI,CAACG,kBAAkB,GAAGJ,iBAAiB;IAC3C,IAAI,CAACK,OAAO,GAAGH,MAAM,IAAI,GAAG;EAC9B;;EAEA;AACF;EACE,IAAII,EAAE,GAAW;IACf,IAAI,IAAI,CAACC,SAAS,KAAK,CAAC,EAAE;MACxB,OAAOV,kBAAkB;IAC3B;IAEA,OAAO,kCAAkC;EAC3C;;EAEA;AACF;EACE,IAAII,gBAAgB,GAAW;IAC7B,OAAO,IAAI,CAACE,iBAAiB;EAC/B;;EAEA;AACF;EACE,IAAIH,iBAAiB,GAAW;IAC9B,OAAO,IAAI,CAACI,kBAAkB;EAChC;;EAEA;AACF;EACE,IAAIF,MAAM,GAAW;IACnB,OAAO,IAAI,CAACG,OAAO;EACrB;;EAEA;AACF;EACE,IAAIE,SAAS,GAAW;IACtB,OAAO,IAAI,CAACL,MAAM,GAAG,IAAIM,sBAA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AC,EAChD;MACA,OAAO,KAAK;IACd;IAEA,MAAM4B,YAAY,GAAG,IAAAC,2BAAa,EAChChB,KAAK,EACL,IAAI,CAACd,iBAAiB,EACtB,IAAI,CAACC,gBAAgB,CACtB;IAED,IAAI,IAAI,CAACK,EAAE,KAAKT,kBAAkB,EAAE;MAClC,OAAO,IAAI,CAACgB,SAAS,CAACgB,YAAY,CAAC;IACrC;IAEA,OAAO,IAAI,CAACP,cAAc,CAACO,YAAY,CAAC;EAC1C;;EAEA;AACF;EACE,IAAIE,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcjC,sBAAsB;AAAA"}
@@ -9,7 +9,6 @@ var _includes = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-s
9
9
  var _slice = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/slice"));
10
10
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
11
11
  var _DecimalFormat = _interopRequireDefault(require("../../../utils/number/DecimalFormat"));
12
-
13
12
  const DEFAULT_GROUPING_SIZE = 3;
14
13
 
15
14
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"NumberGroupingConstraint.js","names":["DEFAULT_GROUPING_SIZE","NumberGroupingConstraint","constructor","groupingSeparator","decimalSeparator","format","_decimalSeparator","_groupingSeparator","_format","id","groupSize","fromFormat","DecimalFormat","comma","hasValidation","defaultMessage","parameters","hasCorrectGrouping","value","absStringValue","replace","integer","indexOf","substring","groups","split","length","every","group","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/NumberGroupingConstraint.js"],"sourcesContent":["// @flow\nimport DecimalFormat from \"../../../utils/number/DecimalFormat\";\n\nimport type { IConstraintModel } from \"../../types\";\n\nconst DEFAULT_GROUPING_SIZE = 3;\n\n/**\n */\nclass NumberGroupingConstraint implements IConstraintModel {\n _decimalSeparator: string;\n _groupingSeparator: string;\n _format: string;\n\n /**\n */\n constructor(\n groupingSeparator: string = \",\",\n decimalSeparator: string = \".\",\n format: ?string = \"0\"\n ) {\n this._decimalSeparator = decimalSeparator;\n this._groupingSeparator = groupingSeparator;\n this._format = format ?? \"0\";\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Number.GroupingSeparator\";\n }\n\n /**\n */\n get decimalSeparator(): string {\n return this._decimalSeparator;\n }\n\n /**\n */\n get groupingSeparator(): string {\n return this._groupingSeparator;\n }\n\n /**\n */\n get format(): string {\n return this._format;\n }\n\n /**\n */\n get groupSize(): number {\n if (this.format) {\n const fromFormat = new DecimalFormat(this.format).comma;\n if (fromFormat > 0) {\n return fromFormat;\n }\n }\n\n return DEFAULT_GROUPING_SIZE;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Group divider '${group-divider}' must be correctly placed\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { \"group-divider\": string } {\n return { \"group-divider\": this.groupingSeparator };\n }\n\n /**\n */\n // $FlowFixMe\n hasCorrectGrouping(value: string) {\n // A negative or a negative value may cause an incorrect group length compared to groupSize. To avoid this, the negative or positive sign must be removed from the value.\n const absStringValue = value.replace(\"-\", \"\").replace(\"+\", \"\");\n\n if (!absStringValue.includes(this.groupingSeparator)) {\n return true;\n }\n\n let integer = absStringValue;\n if (\n this.decimalSeparator !== \"\" &&\n absStringValue.includes(this.decimalSeparator)\n ) {\n // decimal before grouping\n if (\n absStringValue.indexOf(this.decimalSeparator) <\n absStringValue.indexOf(this.groupingSeparator)\n ) {\n return false;\n }\n\n integer = absStringValue.substring(\n 0,\n absStringValue.indexOf(this.decimalSeparator)\n );\n }\n\n let groups = integer.split(this.groupingSeparator);\n\n // when the first item is smaller than group size, remove it from check\n if (groups[0].length < this.groupSize) {\n groups = groups.slice(1);\n }\n\n return groups.every((group) => group.length === this.groupSize);\n }\n\n /**\n */\n validate(value: string | number): boolean {\n return (\n this.groupingSeparator === \"\" ||\n typeof value !== \"string\" ||\n !value.includes(this.groupingSeparator) ||\n this.hasCorrectGrouping(value)\n );\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default NumberGroupingConstraint;\n"],"mappings":";;;;;;;;;;AACA;;AAIA,MAAMA,qBAAqB,GAAG,CAAC;;AAE/B;AACA;AACA,MAAMC,wBAAwB,CAA6B;EAKzD;AACF;EACEC,WAAW,GAIT;IAAA,IAHAC,iBAAyB,uEAAG,GAAG;IAAA,IAC/BC,gBAAwB,uEAAG,GAAG;IAAA,IAC9BC,MAAe,uEAAG,GAAG;IAAA;IAAA;IAAA;IAErB,IAAI,CAACC,iBAAiB,GAAGF,gBAAgB;IACzC,IAAI,CAACG,kBAAkB,GAAGJ,iBAAiB;IAC3C,IAAI,CAACK,OAAO,GAAGH,MAAM,IAAI,GAAG;EAC9B;;EAEA;AACF;EACE,IAAII,EAAE,GAAW;IACf,OAAO,qCAAqC;EAC9C;;EAEA;AACF;EACE,IAAIL,gBAAgB,GAAW;IAC7B,OAAO,IAAI,CAACE,iBAAiB;EAC/B;;EAEA;AACF;EACE,IAAIH,iBAAiB,GAAW;IAC9B,OAAO,IAAI,CAACI,kBAAkB;EAChC;;EAEA;AACF;EACE,IAAIF,MAAM,GAAW;IACnB,OAAO,IAAI,CAACG,OAAO;EACrB;;EAEA;AACF;EACE,IAAIE,SAAS,GAAW;IACtB,IAAI,IAAI,CAACL,MAAM,EAAE;MACf,MAAMM,UAAU,GAAG,IAAIC,sBAAa,CAAC,IAAI,CAACP,MAAM,CAAC,CAACQ,KAAK;MACvD,IAAIF,UAAU,GAAG,CAAC,EAAE;QAClB,OAAOA,UAAU;MACnB;IACF;IAEA,OAAOX,qBAAqB;EAC9B;;EAEA;AACF;EACEc,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,2DAA2D,CAAC,CAAC;EACtE;;EAEA;AACF;EACE,IAAIC,UAAU,GAAgC;IAC5C,OAAO;MAAE,eA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C,uBAAAA,KAAK,OAALA,KAAK,EAAU,IAAI,CAACf,iBAAiB,CAAC,IACvC,IAAI,CAACc,kBAAkB,CAACC,KAAK,CAAC;EAElC;;EAEA;AACF;EACE,IAAIY,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEc7B,wBAAwB;AAAA"}
1
+ {"version":3,"file":"NumberGroupingConstraint.js","names":["DEFAULT_GROUPING_SIZE","NumberGroupingConstraint","constructor","groupingSeparator","decimalSeparator","format","_decimalSeparator","_groupingSeparator","_format","id","groupSize","fromFormat","DecimalFormat","comma","hasValidation","defaultMessage","parameters","hasCorrectGrouping","value","absStringValue","replace","integer","indexOf","substring","groups","split","length","every","group","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/NumberGroupingConstraint.js"],"sourcesContent":["// @flow\nimport DecimalFormat from \"../../../utils/number/DecimalFormat\";\n\nimport type { IConstraintModel } from \"../../types\";\n\nconst DEFAULT_GROUPING_SIZE = 3;\n\n/**\n */\nclass NumberGroupingConstraint implements IConstraintModel {\n _decimalSeparator: string;\n _groupingSeparator: string;\n _format: string;\n\n /**\n */\n constructor(\n groupingSeparator: string = \",\",\n decimalSeparator: string = \".\",\n format: ?string = \"0\"\n ) {\n this._decimalSeparator = decimalSeparator;\n this._groupingSeparator = groupingSeparator;\n this._format = format ?? \"0\";\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Number.GroupingSeparator\";\n }\n\n /**\n */\n get decimalSeparator(): string {\n return this._decimalSeparator;\n }\n\n /**\n */\n get groupingSeparator(): string {\n return this._groupingSeparator;\n }\n\n /**\n */\n get format(): string {\n return this._format;\n }\n\n /**\n */\n get groupSize(): number {\n if (this.format) {\n const fromFormat = new DecimalFormat(this.format).comma;\n if (fromFormat > 0) {\n return fromFormat;\n }\n }\n\n return DEFAULT_GROUPING_SIZE;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Group divider '${group-divider}' must be correctly placed\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { \"group-divider\": string } {\n return { \"group-divider\": this.groupingSeparator };\n }\n\n /**\n */\n // $FlowFixMe\n hasCorrectGrouping(value: string) {\n // A negative or a negative value may cause an incorrect group length compared to groupSize. To avoid this, the negative or positive sign must be removed from the value.\n const absStringValue = value.replace(\"-\", \"\").replace(\"+\", \"\");\n\n if (!absStringValue.includes(this.groupingSeparator)) {\n return true;\n }\n\n let integer = absStringValue;\n if (\n this.decimalSeparator !== \"\" &&\n absStringValue.includes(this.decimalSeparator)\n ) {\n // decimal before grouping\n if (\n absStringValue.indexOf(this.decimalSeparator) <\n absStringValue.indexOf(this.groupingSeparator)\n ) {\n return false;\n }\n\n integer = absStringValue.substring(\n 0,\n absStringValue.indexOf(this.decimalSeparator)\n );\n }\n\n let groups = integer.split(this.groupingSeparator);\n\n // when the first item is smaller than group size, remove it from check\n if (groups[0].length < this.groupSize) {\n groups = groups.slice(1);\n }\n\n return groups.every((group) => group.length === this.groupSize);\n }\n\n /**\n */\n validate(value: string | number): boolean {\n return (\n this.groupingSeparator === \"\" ||\n typeof value !== \"string\" ||\n !value.includes(this.groupingSeparator) ||\n this.hasCorrectGrouping(value)\n );\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default NumberGroupingConstraint;\n"],"mappings":";;;;;;;;;;AACA;AAIA,MAAMA,qBAAqB,GAAG,CAAC;;AAE/B;AACA;AACA,MAAMC,wBAAwB,CAA6B;EAKzD;AACF;EACEC,WAAW,GAIT;IAAA,IAHAC,iBAAyB,uEAAG,GAAG;IAAA,IAC/BC,gBAAwB,uEAAG,GAAG;IAAA,IAC9BC,MAAe,uEAAG,GAAG;IAAA;IAAA;IAAA;IAErB,IAAI,CAACC,iBAAiB,GAAGF,gBAAgB;IACzC,IAAI,CAACG,kBAAkB,GAAGJ,iBAAiB;IAC3C,IAAI,CAACK,OAAO,GAAGH,MAAM,IAAI,GAAG;EAC9B;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AAO,CAAC,IAAI,CAAClB,gBAAgB,CAAC,GAC7Ce,cAAc,CAACG,OAAO,CAAC,IAAI,CAACnB,iBAAiB,CAAC,EAC9C;QACA,OAAO,KAAK;MACd;MAEAkB,OAAO,GAAGF,cAAc,CAACI,SAAS,CAChC,CAAC,EACDJ,cAAc,CAACG,OAAO,CAAC,IAAI,CAAClB,gBAAgB,CAAC,CAC9C;IACH;IAEA,IAAIoB,MAAM,GAAGH,OAAO,CAACI,KAAK,CAAC,IAAI,CAACtB,iBAAiB,CAAC;;IAElD;IACA,IAAIqB,MAAM,CAAC,CAAC,CAAC,CAACE,MAAM,GAAG,IAAI,CAAChB,SAAS,EAAE;MACrCc,MAAM,GAAG,oBAAAA,MAAM,OAANA,MAAM,EAAO,CAAC,CAAC;IAC1B;IAEA,OAAOA,MAAM,CAACG,KAAK,CAAEC,KAAK,IAAKA,KAAK,CAACF,MAAM,KAAK,IAAI,CAAChB,SAAS,CAAC;EACjE;;EAEA;AACF;EACEmB,QAAQ,CAACX,KAAsB,EAAW;IACxC,OACE,IAAI,CAACf,iBAAiB,KAAK,EAAE,IAC7B,OAAOe,KAAK,KAAK,QAAQ,IACzB,CAAC,uBAAAA,KAAK,OAALA,KAAK,EAAU,IAAI,CAACf,iBAAiB,CAAC,IACvC,IAAI,CAACc,kBAAkB,CAACC,KAAK,CAAC;EAElC;;EAEA;AACF;EACE,IAAIY,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEc7B,wBAAwB;AAAA"}
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
-
10
9
  /**
11
10
  */
12
11
  class PasswordConfirmConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordConfirmConstraint.js","names":["PasswordConfirmConstraint","constructor","otherPasswordValue","otherPasswordLabel","_otherPasswordLabel","_otherPasswordValue","id","hasValidation","defaultMessage","parameters","other","validate","value","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordConfirmConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordConfirmConstraint implements IConstraintModel {\n _otherPasswordLabel: string;\n _otherPasswordValue: string;\n\n /**\n */\n constructor(otherPasswordValue: string, otherPasswordLabel: string) {\n this._otherPasswordLabel = otherPasswordLabel;\n this._otherPasswordValue = otherPasswordValue;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.ConfirmMismatch\";\n }\n\n /**\n */\n get otherPasswordLabel(): string {\n return this._otherPasswordLabel;\n }\n\n /**\n */\n get otherPasswordValue(): string {\n return this._otherPasswordValue;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must match ${other} field\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { other: string } {\n return {\n other: this.otherPasswordLabel,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n return value === this.otherPasswordValue;\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordConfirmConstraint;\n"],"mappings":";;;;;;;;;AAGA;AACA;AACA,MAAMA,yBAAyB,CAA6B;EAI1D;AACF;EACEC,WAAW,CAACC,kBAA0B,EAAEC,kBAA0B,EAAE;IAAA;IAAA;IAClE,IAAI,CAACC,mBAAmB,GAAGD,kBAAkB;IAC7C,IAAI,CAACE,mBAAmB,GAAGH,kBAAkB;EAC/C;;EAEA;AACF;EACE,IAAII,EAAE,GAAW;IACf,OAAO,qCAAqC;EAC9C;;EAEA;AACF;EACE,IAAIH,kBAAkB,GAAW;IAC/B,OAAO,IAAI,CAACC,mBAAmB;EACjC;;EAEA;AACF;EACE,IAAIF,kBAAkB,GAAW;IAC/B,OAAO,IAAI,CAACG,mBAAmB;EACjC;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,2BAA2B,CAAC,CAAC;EACtC;;EAEA;AACF;EACE,IAAIC,UAAU,GAAsB;IAClC,OAAO;MACLC,KAAK,EAAE,IAAI,CAACP;IACd,CAAC;EACH;;EAEA;AACF;EACEQ,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAOA,KAAK,KAAK,IAAI,CAACV,kBAAkB;EAC1C;;EAEA;AACF;EACE,IAAIW,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcb,yBAAyB;AAAA"}
1
+ {"version":3,"file":"PasswordConfirmConstraint.js","names":["PasswordConfirmConstraint","constructor","otherPasswordValue","otherPasswordLabel","_otherPasswordLabel","_otherPasswordValue","id","hasValidation","defaultMessage","parameters","other","validate","value","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordConfirmConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordConfirmConstraint implements IConstraintModel {\n _otherPasswordLabel: string;\n _otherPasswordValue: string;\n\n /**\n */\n constructor(otherPasswordValue: string, otherPasswordLabel: string) {\n this._otherPasswordLabel = otherPasswordLabel;\n this._otherPasswordValue = otherPasswordValue;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.ConfirmMismatch\";\n }\n\n /**\n */\n get otherPasswordLabel(): string {\n return this._otherPasswordLabel;\n }\n\n /**\n */\n get otherPasswordValue(): string {\n return this._otherPasswordValue;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must match ${other} field\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { other: string } {\n return {\n other: this.otherPasswordLabel,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n return value === this.otherPasswordValue;\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordConfirmConstraint;\n"],"mappings":";;;;;;;;AAGA;AACA;AACA,MAAMA,yBAAyB,CAA6B;EAI1D;AACF;EACEC,WAAW,CAACC,kBAA0B,EAAEC,kBAA0B,EAAE;IAAA;IAAA;IAClE,IAAI,CAACC,mBAAmB,GAAGD,kBAAkB;IAC7C,IAAI,CAACE,mBAAmB,GAAGH,kBAAkB;EAC/C;;EAEA;AACF;EACE,IAAII,EAAE,GAAW;IACf,OAAO,qCAAqC;EAC9C;;EAEA;AACF;EACE,IAAIH,kBAAkB,GAAW;IAC/B,OAAO,IAAI,CAACC,mBAAmB;EACjC;;EAEA;AACF;EACE,IAAIF,kBAAkB,GAAW;IAC/B,OAAO,IAAI,CAACG,mBAAmB;EACjC;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,2BAA2B,CAAC,CAAC;EACtC;;EAEA;AACF;EACE,IAAIC,UAAU,GAAsB;IAClC,OAAO;MACLC,KAAK,EAAE,IAAI,CAACP;IACd,CAAC;EACH;;EAEA;AACF;EACEQ,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAOA,KAAK,KAAK,IAAI,CAACV,kBAAkB;EAC1C;;EAEA;AACF;EACE,IAAIW,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcb,yBAAyB;AAAA"}
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  /**
9
8
  */
10
9
  class PasswordLowerAndUpperCaseConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordLowerAndUpperCaseConstraint.js","names":["PasswordLowerAndUpperCaseConstraint","id","hasValidation","defaultMessage","parameters","validate","value","test","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordLowerAndUpperCaseConstraint implements IConstraintModel {\n /**\n */\n get id(): string {\n return \"Constraint.Password.LowerAndUpperCaseMandatory\";\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must contain both upper and lowercase characters\";\n }\n\n /**\n */\n get parameters(): { ... } {\n return {};\n }\n\n /**\n */\n validate(value: string): boolean {\n return /[a-z]/u.test(value) && /[A-Z]/u.test(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordLowerAndUpperCaseConstraint;\n"],"mappings":";;;;;;;AAGA;AACA;AACA,MAAMA,mCAAmC,CAA6B;EACpE;AACF;EACE,IAAIC,EAAE,GAAW;IACf,OAAO,gDAAgD;EACzD;;EAEA;AACF;EACEC,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,kDAAkD;EAC3D;;EAEA;AACF;EACE,IAAIC,UAAU,GAAY;IACxB,OAAO,CAAC,CAAC;EACX;;EAEA;AACF;EACEC,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAO,QAAQ,CAACC,IAAI,CAACD,KAAK,CAAC,IAAI,QAAQ,CAACC,IAAI,CAACD,KAAK,CAAC;EACrD;;EAEA;AACF;EACE,IAAIE,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcR,mCAAmC;AAAA"}
1
+ {"version":3,"file":"PasswordLowerAndUpperCaseConstraint.js","names":["PasswordLowerAndUpperCaseConstraint","id","hasValidation","defaultMessage","parameters","validate","value","test","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordLowerAndUpperCaseConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordLowerAndUpperCaseConstraint implements IConstraintModel {\n /**\n */\n get id(): string {\n return \"Constraint.Password.LowerAndUpperCaseMandatory\";\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must contain both upper and lowercase characters\";\n }\n\n /**\n */\n get parameters(): { ... } {\n return {};\n }\n\n /**\n */\n validate(value: string): boolean {\n return /[a-z]/u.test(value) && /[A-Z]/u.test(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordLowerAndUpperCaseConstraint;\n"],"mappings":";;;;;;AAGA;AACA;AACA,MAAMA,mCAAmC,CAA6B;EACpE;AACF;EACE,IAAIC,EAAE,GAAW;IACf,OAAO,gDAAgD;EACzD;;EAEA;AACF;EACEC,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,kDAAkD;EAC3D;;EAEA;AACF;EACE,IAAIC,UAAU,GAAY;IACxB,OAAO,CAAC,CAAC;EACX;;EAEA;AACF;EACEC,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAO,QAAQ,CAACC,IAAI,CAACD,KAAK,CAAC,IAAI,QAAQ,CAACC,IAAI,CAACD,KAAK,CAAC;EACrD;;EAEA;AACF;EACE,IAAIE,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcR,mCAAmC;AAAA"}
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
-
10
9
  /**
11
10
  */
12
11
  class PasswordMinNumericCharactersConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordMinNumericCharactersConstraint.js","names":["PasswordMinNumericCharactersConstraint","constructor","minNumeric","_minNumeric","id","hasValidation","defaultMessage","parameters","validate","value","replace","length","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordMinNumericCharactersConstraint implements IConstraintModel {\n _minNumeric: number;\n\n /**\n */\n constructor(minNumeric: number) {\n this._minNumeric = minNumeric;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.MinNumericCharactersMandatory\";\n }\n\n /**\n */\n get minNumeric(): number {\n return this._minNumeric;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must contain ${min-numeric} or more numerical characters\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { \"min-numeric\": number } {\n return {\n \"min-numeric\": this.minNumeric,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n return value.replace(/\\D/gu, \"\").length >= this.minNumeric;\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordMinNumericCharactersConstraint;\n"],"mappings":";;;;;;;;;AAGA;AACA;AACA,MAAMA,sCAAsC,CAA6B;EAGvE;AACF;EACEC,WAAW,CAACC,UAAkB,EAAE;IAAA;IAC9B,IAAI,CAACC,WAAW,GAAGD,UAAU;EAC/B;;EAEA;AACF;EACE,IAAIE,EAAE,GAAW;IACf,OAAO,mDAAmD;EAC5D;;EAEA;AACF;EACE,IAAIF,UAAU,GAAW;IACvB,OAAO,IAAI,CAACC,WAAW;EACzB;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,0DAA0D,CAAC,CAAC;EACrE;;EAEA;AACF;EACE,IAAIC,UAAU,GAA8B;IAC1C,OAAO;MACL,aAAa,EAAE,IAAI,CAACL;IACtB,CAAC;EACH;;EAEA;AACF;EACEM,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAOA,KAAK,CAACC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAACC,MAAM,IAAI,IAAI,CAACT,UAAU;EAC5D;;EAEA;AACF;EACE,IAAIU,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcZ,sCAAsC;AAAA"}
1
+ {"version":3,"file":"PasswordMinNumericCharactersConstraint.js","names":["PasswordMinNumericCharactersConstraint","constructor","minNumeric","_minNumeric","id","hasValidation","defaultMessage","parameters","validate","value","replace","length","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordMinNumericCharactersConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordMinNumericCharactersConstraint implements IConstraintModel {\n _minNumeric: number;\n\n /**\n */\n constructor(minNumeric: number) {\n this._minNumeric = minNumeric;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.MinNumericCharactersMandatory\";\n }\n\n /**\n */\n get minNumeric(): number {\n return this._minNumeric;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must contain ${min-numeric} or more numerical characters\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { \"min-numeric\": number } {\n return {\n \"min-numeric\": this.minNumeric,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n return value.replace(/\\D/gu, \"\").length >= this.minNumeric;\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordMinNumericCharactersConstraint;\n"],"mappings":";;;;;;;;AAGA;AACA;AACA,MAAMA,sCAAsC,CAA6B;EAGvE;AACF;EACEC,WAAW,CAACC,UAAkB,EAAE;IAAA;IAC9B,IAAI,CAACC,WAAW,GAAGD,UAAU;EAC/B;;EAEA;AACF;EACE,IAAIE,EAAE,GAAW;IACf,OAAO,mDAAmD;EAC5D;;EAEA;AACF;EACE,IAAIF,UAAU,GAAW;IACvB,OAAO,IAAI,CAACC,WAAW;EACzB;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,0DAA0D,CAAC,CAAC;EACrE;;EAEA;AACF;EACE,IAAIC,UAAU,GAA8B;IAC1C,OAAO;MACL,aAAa,EAAE,IAAI,CAACL;IACtB,CAAC;EACH;;EAEA;AACF;EACEM,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAOA,KAAK,CAACC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAACC,MAAM,IAAI,IAAI,CAACT,UAAU;EAC5D;;EAEA;AACF;EACE,IAAIU,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcZ,sCAAsC;AAAA"}
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
-
10
9
  /**
11
10
  */
12
11
  class PasswordMinSpecialCharactersConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordMinSpecialCharactersConstraint.js","names":["PasswordMinSpecialCharactersConstraint","constructor","minSpecial","_minSpecial","id","hasValidation","defaultMessage","parameters","validate","value","replace","length","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordMinSpecialCharactersConstraint implements IConstraintModel {\n _minSpecial: number;\n\n /**\n */\n constructor(minSpecial: number) {\n this._minSpecial = minSpecial;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.MinSpecialCharactersMandatory\";\n }\n\n /**\n */\n get minSpecial(): number {\n return this._minSpecial;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must contain ${min-special} or more special characters\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { \"min-special\": number } {\n return {\n \"min-special\": this.minSpecial,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n return value.replace(/[\\da-z]/giu, \"\").length >= this.minSpecial;\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordMinSpecialCharactersConstraint;\n"],"mappings":";;;;;;;;;AAGA;AACA;AACA,MAAMA,sCAAsC,CAA6B;EAGvE;AACF;EACEC,WAAW,CAACC,UAAkB,EAAE;IAAA;IAC9B,IAAI,CAACC,WAAW,GAAGD,UAAU;EAC/B;;EAEA;AACF;EACE,IAAIE,EAAE,GAAW;IACf,OAAO,mDAAmD;EAC5D;;EAEA;AACF;EACE,IAAIF,UAAU,GAAW;IACvB,OAAO,IAAI,CAACC,WAAW;EACzB;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,wDAAwD,CAAC,CAAC;EACnE;;EAEA;AACF;EACE,IAAIC,UAAU,GAA8B;IAC1C,OAAO;MACL,aAAa,EAAE,IAAI,CAACL;IACtB,CAAC;EACH;;EAEA;AACF;EACEM,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAOA,KAAK,CAACC,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC,CAACC,MAAM,IAAI,IAAI,CAACT,UAAU;EAClE;;EAEA;AACF;EACE,IAAIU,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcZ,sCAAsC;AAAA"}
1
+ {"version":3,"file":"PasswordMinSpecialCharactersConstraint.js","names":["PasswordMinSpecialCharactersConstraint","constructor","minSpecial","_minSpecial","id","hasValidation","defaultMessage","parameters","validate","value","replace","length","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordMinSpecialCharactersConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordMinSpecialCharactersConstraint implements IConstraintModel {\n _minSpecial: number;\n\n /**\n */\n constructor(minSpecial: number) {\n this._minSpecial = minSpecial;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.MinSpecialCharactersMandatory\";\n }\n\n /**\n */\n get minSpecial(): number {\n return this._minSpecial;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must contain ${min-special} or more special characters\"; // NOSONAR\n }\n\n /**\n */\n get parameters(): { \"min-special\": number } {\n return {\n \"min-special\": this.minSpecial,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n return value.replace(/[\\da-z]/giu, \"\").length >= this.minSpecial;\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordMinSpecialCharactersConstraint;\n"],"mappings":";;;;;;;;AAGA;AACA;AACA,MAAMA,sCAAsC,CAA6B;EAGvE;AACF;EACEC,WAAW,CAACC,UAAkB,EAAE;IAAA;IAC9B,IAAI,CAACC,WAAW,GAAGD,UAAU;EAC/B;;EAEA;AACF;EACE,IAAIE,EAAE,GAAW;IACf,OAAO,mDAAmD;EAC5D;;EAEA;AACF;EACE,IAAIF,UAAU,GAAW;IACvB,OAAO,IAAI,CAACC,WAAW;EACzB;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,wDAAwD,CAAC,CAAC;EACnE;;EAEA;AACF;EACE,IAAIC,UAAU,GAA8B;IAC1C,OAAO;MACL,aAAa,EAAE,IAAI,CAACL;IACtB,CAAC;EACH;;EAEA;AACF;EACEM,QAAQ,CAACC,KAAa,EAAW;IAC/B,OAAOA,KAAK,CAACC,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC,CAACC,MAAM,IAAI,IAAI,CAACT,UAAU;EAClE;;EAEA;AACF;EACE,IAAIU,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcZ,sCAAsC;AAAA"}
@@ -9,7 +9,6 @@ var _filter = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-sta
9
9
  var _repeat = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/repeat"));
10
10
  var _includes = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/includes"));
11
11
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
12
-
13
12
  /**
14
13
  */
15
14
  class PasswordThreeConsecutiveCharactersNotAllowedConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordThreeConsecutiveCharactersNotAllowedConstraint.js","names":["PasswordThreeConsecutiveCharactersNotAllowedConstraint","constructor","maxSequence","_maxSequence","id","hasValidation","defaultMessage","parameters","hasNoSequenceOfIdenticalCharacters","value","split","char","i","indexOf","some","sequence","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordThreeConsecutiveCharactersNotAllowedConstraint\n implements IConstraintModel\n{\n _maxSequence: number;\n\n /**\n */\n constructor(maxSequence: number = 2) {\n this._maxSequence = maxSequence;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.ThreeConsecutiveCharactersNotAllowed\";\n }\n\n /**\n */\n get maxSequence(): number {\n return this._maxSequence;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must not contain any character more than twice consecutively\";\n }\n\n /**\n */\n get parameters(): { \"max-sequence\": number } {\n return {\n \"max-sequence\": this.maxSequence,\n };\n }\n\n /**\n */\n hasNoSequenceOfIdenticalCharacters(value: string): boolean {\n return !value\n .split(\"\")\n .filter((char, i) => value.indexOf(char) === i)\n .some((char) => {\n const sequence = char.repeat(this.maxSequence + 1);\n return value.includes(sequence);\n });\n }\n\n /**\n */\n validate(value: string): boolean {\n return this.hasNoSequenceOfIdenticalCharacters(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordThreeConsecutiveCharactersNotAllowedConstraint;\n"],"mappings":";;;;;;;;;;;;AAGA;AACA;AACA,MAAMA,sDAAsD,CAE5D;EAGE;AACF;EACEC,WAAW,GAA0B;IAAA,IAAzBC,WAAmB,uEAAG,CAAC;IAAA;IACjC,IAAI,CAACC,YAAY,GAAGD,WAAW;EACjC;;EAEA;AACF;EACE,IAAIE,EAAE,GAAW;IACf,OAAO,0DAA0D;EACnE;;EAEA;AACF;EACE,IAAIF,WAAW,GAAW;IACxB,OAAO,IAAI,CAACC,YAAY;EAC1B;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,8DAA8D;EACvE;;EAEA;AACF;EACE,IAAIC,UAAU,GAA+B;IAC3C,OAAO;MACL,cAAc,EAAE,IAAI,CAACL;IACvB,CAAC;EACH;;EAEA;AACF;EACEM,kCAAkC,CAACC,KAAa,EAAW;IAAA;IACzD,OAAO,CAAC,gCAAAA,KAAK,CACVC,KAAK,CAAC,EAAE,CAAC,iBACF,CAACC,IAAI,EAAEC,CAAC,KAAKH,KAAK,CAACI,OAAO,CAACF,IAAI,CAAC,KAAKC,CAAC,CAAC,CAC9CE,IAAI,CAAEH,IAAI,IAAK;MACd,MAAMI,QAAQ,GAAG,qBAAAJ,IAAI,OAAJA,IAAI,EAAQ,IAAI,CAACT,WAAW,GAAG,CAAC,CAAC;MAClD,OAAO,uBAAAO,KAAK,OAALA,KAAK,EAAUM,QAAQ,CAAC;IACjC,CAAC,CAAC;EACN;;EAEA;AACF;EACEC,QAAQ,CAACP,KAAa,EAAW;IAC/B,OAAO,IAAI,CAACD,kCAAkC,CAACC,KAAK,CAAC;EACvD;;EAEA;AACF;EACE,IAAIQ,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcjB,sDAAsD;AAAA"}
1
+ {"version":3,"file":"PasswordThreeConsecutiveCharactersNotAllowedConstraint.js","names":["PasswordThreeConsecutiveCharactersNotAllowedConstraint","constructor","maxSequence","_maxSequence","id","hasValidation","defaultMessage","parameters","hasNoSequenceOfIdenticalCharacters","value","split","char","i","indexOf","some","sequence","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/PasswordThreeConsecutiveCharactersNotAllowedConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass PasswordThreeConsecutiveCharactersNotAllowedConstraint\n implements IConstraintModel\n{\n _maxSequence: number;\n\n /**\n */\n constructor(maxSequence: number = 2) {\n this._maxSequence = maxSequence;\n }\n\n /**\n */\n get id(): string {\n return \"Constraint.Password.ThreeConsecutiveCharactersNotAllowed\";\n }\n\n /**\n */\n get maxSequence(): number {\n return this._maxSequence;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must not contain any character more than twice consecutively\";\n }\n\n /**\n */\n get parameters(): { \"max-sequence\": number } {\n return {\n \"max-sequence\": this.maxSequence,\n };\n }\n\n /**\n */\n hasNoSequenceOfIdenticalCharacters(value: string): boolean {\n return !value\n .split(\"\")\n .filter((char, i) => value.indexOf(char) === i)\n .some((char) => {\n const sequence = char.repeat(this.maxSequence + 1);\n return value.includes(sequence);\n });\n }\n\n /**\n */\n validate(value: string): boolean {\n return this.hasNoSequenceOfIdenticalCharacters(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default PasswordThreeConsecutiveCharactersNotAllowedConstraint;\n"],"mappings":";;;;;;;;;;;AAGA;AACA;AACA,MAAMA,sDAAsD,CAE5D;EAGE;AACF;EACEC,WAAW,GAA0B;IAAA,IAAzBC,WAAmB,uEAAG,CAAC;IAAA;IACjC,IAAI,CAACC,YAAY,GAAGD,WAAW;EACjC;;EAEA;AACF;EACE,IAAIE,EAAE,GAAW;IACf,OAAO,0DAA0D;EACnE;;EAEA;AACF;EACE,IAAIF,WAAW,GAAW;IACxB,OAAO,IAAI,CAACC,YAAY;EAC1B;;EAEA;AACF;EACEE,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,8DAA8D;EACvE;;EAEA;AACF;EACE,IAAIC,UAAU,GAA+B;IAC3C,OAAO;MACL,cAAc,EAAE,IAAI,CAACL;IACvB,CAAC;EACH;;EAEA;AACF;EACEM,kCAAkC,CAACC,KAAa,EAAW;IAAA;IACzD,OAAO,CAAC,gCAAAA,KAAK,CACVC,KAAK,CAAC,EAAE,CAAC,iBACF,CAACC,IAAI,EAAEC,CAAC,KAAKH,KAAK,CAACI,OAAO,CAACF,IAAI,CAAC,KAAKC,CAAC,CAAC,CAC9CE,IAAI,CAAEH,IAAI,IAAK;MACd,MAAMI,QAAQ,GAAG,qBAAAJ,IAAI,OAAJA,IAAI,EAAQ,IAAI,CAACT,WAAW,GAAG,CAAC,CAAC;MAClD,OAAO,uBAAAO,KAAK,OAALA,KAAK,EAAUM,QAAQ,CAAC;IACjC,CAAC,CAAC;EACN;;EAEA;AACF;EACEC,QAAQ,CAACP,KAAa,EAAW;IAC/B,OAAO,IAAI,CAACD,kCAAkC,CAACC,KAAK,CAAC;EACvD;;EAEA;AACF;EACE,IAAIQ,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcjB,sDAAsD;AAAA"}
@@ -7,7 +7,6 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
9
  var _DateTimeUtil = require("../../../utils/datetime/DateTimeUtil");
10
-
11
10
  /**
12
11
  */
13
12
  class RangeConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"RangeConstraint.js","names":["RangeConstraint","constructor","startAttribute","endAttribute","_start","_end","id","hasInclusiveBounds","rangeType","defaultMessage","inclusivePart","hasValidation","parameters","start","end","type","operator","util","TimeUtil","DateUtil","DateTimeUtil","TimestampUtil","doValidate","startValue","endValue","isSameOrBefore","isBefore","validate","inError","value","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/RangeConstraint.js"],"sourcesContent":["// @flow\nimport {\n DateUtil,\n DateTimeUtil,\n TimestampUtil,\n TimeUtil,\n} from \"../../../utils/datetime/DateTimeUtil\";\n\nimport type { AttributeType } from \"../../types\";\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass RangeConstraint implements IConstraintModel {\n _start: AttributeType;\n _end: AttributeType;\n\n /**\n */\n constructor(startAttribute: AttributeType, endAttribute: AttributeType) {\n this._start = startAttribute;\n this._end = endAttribute;\n }\n\n /**\n */\n get id(): string {\n const id = this.hasInclusiveBounds\n ? \"InvalidRangeInclusive\"\n : \"InvalidRange\";\n\n switch (this.rangeType) {\n case \"time\":\n return `Constraint.TimeRange.${id}`;\n case \"date\":\n return `Constraint.DateRange.${id}`;\n case \"datetime\":\n return `Constraint.DateTimeRange.${id}`;\n case \"timestamp\":\n return `Constraint.TimeStampRange.${id}`;\n default:\n return `Constraint.NumberRange.${id}`;\n }\n }\n\n /**\n */\n get defaultMessage(): string {\n const inclusivePart = this.hasInclusiveBounds ? \" or equal to the\" : \"\";\n\n switch (this.rangeType) {\n case \"time\":\n return `Start time must be before${inclusivePart} end time`;\n case \"date\":\n return `Start date must be before${inclusivePart} end date`;\n case \"datetime\":\n return `Start value must be before${inclusivePart} end value`;\n case \"timestamp\":\n return `Start value must be before${inclusivePart} end value`;\n default:\n return `Start value must be less than${inclusivePart} the end value`;\n }\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get parameters(): { ... } {\n return {};\n }\n\n /**\n */\n get start(): AttributeType {\n return this._start;\n }\n\n /**\n */\n get end(): AttributeType {\n return this._end;\n }\n\n /**\n */\n get rangeType(): string {\n return this.start.type;\n }\n\n /**\n */\n get hasInclusiveBounds(): boolean {\n return (\n this.start.operator === \"greaterThanOrEqualTo\" &&\n this.end.operator === \"lessThanOrEqualTo\"\n );\n }\n\n /**\n */\n get util():\n | typeof TimeUtil\n | typeof DateUtil\n | typeof DateTimeUtil\n | typeof TimestampUtil\n | null {\n switch (this.rangeType) {\n case \"time\":\n return TimeUtil;\n case \"date\":\n return DateUtil;\n case \"datetime\":\n return DateTimeUtil;\n case \"timestamp\":\n return TimestampUtil;\n default:\n return null;\n }\n }\n\n /**\n */\n doValidate(startValue: string, endValue: string): boolean {\n if (this.hasInclusiveBounds) {\n if (!this.util) {\n return startValue <= endValue;\n }\n return this.util.isSameOrBefore(startValue, endValue);\n }\n\n if (!this.util) {\n return startValue < endValue;\n }\n\n return this.util.isBefore(startValue, endValue);\n }\n\n /**\n */\n validate(): boolean {\n // only validate range when both attributes are valid\n if (this.start.inError() || this.end.inError()) {\n return true;\n }\n\n return this.doValidate(this.start.value, this.end.value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default RangeConstraint;\n"],"mappings":";;;;;;;;AACA;;AAUA;AACA;AACA,MAAMA,eAAe,CAA6B;EAIhD;AACF;EACEC,WAAW,CAACC,cAA6B,EAAEC,YAA2B,EAAE;IAAA;IAAA;IACtE,IAAI,CAACC,MAAM,GAAGF,cAAc;IAC5B,IAAI,CAACG,IAAI,GAAGF,YAAY;EAC1B;;EAEA;AACF;EACE,IAAIG,EAAE,GAAW;IACf,MAAMA,EAAE,GAAG,IAAI,CAACC,kBAAkB,GAC9B,uBAAuB,GACvB,cAAc;IAElB,QAAQ,IAAI,CAACC,SAAS;MACpB,KAAK,MAAM;QACT,OAAQ,wBAAuBF,EAAG,EAAC;MACrC,KAAK,MAAM;QACT,OAAQ,wBAAuBA,EAAG,EAAC;MACrC,KAAK,UAAU;QACb,OAAQ,4BAA2BA,EAAG,EAAC;MACzC,KAAK,WAAW;QACd,OAAQ,6BAA4BA,EAAG,EAAC;MAC1C;QACE,OAAQ,0BAAyBA,EAAG,EAAC;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AW;IACxD,IAAI,IAAI,CAACjB,kBAAkB,EAAE;MAC3B,IAAI,CAAC,IAAI,CAACU,IAAI,EAAE;QACd,OAAOM,UAAU,IAAIC,QAAQ;MAC/B;MACA,OAAO,IAAI,CAACP,IAAI,CAACQ,cAAc,CAACF,UAAU,EAAEC,QAAQ,CAAC;IACvD;IAEA,IAAI,CAAC,IAAI,CAACP,IAAI,EAAE;MACd,OAAOM,UAAU,GAAGC,QAAQ;IAC9B;IAEA,OAAO,IAAI,CAACP,IAAI,CAACS,QAAQ,CAACH,UAAU,EAAEC,QAAQ,CAAC;EACjD;;EAEA;AACF;EACEG,QAAQ,GAAY;IAClB;IACA,IAAI,IAAI,CAACd,KAAK,CAACe,OAAO,EAAE,IAAI,IAAI,CAACd,GAAG,CAACc,OAAO,EAAE,EAAE;MAC9C,OAAO,IAAI;IACb;IAEA,OAAO,IAAI,CAACN,UAAU,CAAC,IAAI,CAACT,KAAK,CAACgB,KAAK,EAAE,IAAI,CAACf,GAAG,CAACe,KAAK,CAAC;EAC1D;;EAEA;AACF;EACE,IAAIC,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEc9B,eAAe;AAAA"}
1
+ {"version":3,"file":"RangeConstraint.js","names":["RangeConstraint","constructor","startAttribute","endAttribute","_start","_end","id","hasInclusiveBounds","rangeType","defaultMessage","inclusivePart","hasValidation","parameters","start","end","type","operator","util","TimeUtil","DateUtil","DateTimeUtil","TimestampUtil","doValidate","startValue","endValue","isSameOrBefore","isBefore","validate","inError","value","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/RangeConstraint.js"],"sourcesContent":["// @flow\nimport {\n DateUtil,\n DateTimeUtil,\n TimestampUtil,\n TimeUtil,\n} from \"../../../utils/datetime/DateTimeUtil\";\n\nimport type { AttributeType } from \"../../types\";\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass RangeConstraint implements IConstraintModel {\n _start: AttributeType;\n _end: AttributeType;\n\n /**\n */\n constructor(startAttribute: AttributeType, endAttribute: AttributeType) {\n this._start = startAttribute;\n this._end = endAttribute;\n }\n\n /**\n */\n get id(): string {\n const id = this.hasInclusiveBounds\n ? \"InvalidRangeInclusive\"\n : \"InvalidRange\";\n\n switch (this.rangeType) {\n case \"time\":\n return `Constraint.TimeRange.${id}`;\n case \"date\":\n return `Constraint.DateRange.${id}`;\n case \"datetime\":\n return `Constraint.DateTimeRange.${id}`;\n case \"timestamp\":\n return `Constraint.TimeStampRange.${id}`;\n default:\n return `Constraint.NumberRange.${id}`;\n }\n }\n\n /**\n */\n get defaultMessage(): string {\n const inclusivePart = this.hasInclusiveBounds ? \" or equal to the\" : \"\";\n\n switch (this.rangeType) {\n case \"time\":\n return `Start time must be before${inclusivePart} end time`;\n case \"date\":\n return `Start date must be before${inclusivePart} end date`;\n case \"datetime\":\n return `Start value must be before${inclusivePart} end value`;\n case \"timestamp\":\n return `Start value must be before${inclusivePart} end value`;\n default:\n return `Start value must be less than${inclusivePart} the end value`;\n }\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get parameters(): { ... } {\n return {};\n }\n\n /**\n */\n get start(): AttributeType {\n return this._start;\n }\n\n /**\n */\n get end(): AttributeType {\n return this._end;\n }\n\n /**\n */\n get rangeType(): string {\n return this.start.type;\n }\n\n /**\n */\n get hasInclusiveBounds(): boolean {\n return (\n this.start.operator === \"greaterThanOrEqualTo\" &&\n this.end.operator === \"lessThanOrEqualTo\"\n );\n }\n\n /**\n */\n get util():\n | typeof TimeUtil\n | typeof DateUtil\n | typeof DateTimeUtil\n | typeof TimestampUtil\n | null {\n switch (this.rangeType) {\n case \"time\":\n return TimeUtil;\n case \"date\":\n return DateUtil;\n case \"datetime\":\n return DateTimeUtil;\n case \"timestamp\":\n return TimestampUtil;\n default:\n return null;\n }\n }\n\n /**\n */\n doValidate(startValue: string, endValue: string): boolean {\n if (this.hasInclusiveBounds) {\n if (!this.util) {\n return startValue <= endValue;\n }\n return this.util.isSameOrBefore(startValue, endValue);\n }\n\n if (!this.util) {\n return startValue < endValue;\n }\n\n return this.util.isBefore(startValue, endValue);\n }\n\n /**\n */\n validate(): boolean {\n // only validate range when both attributes are valid\n if (this.start.inError() || this.end.inError()) {\n return true;\n }\n\n return this.doValidate(this.start.value, this.end.value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default RangeConstraint;\n"],"mappings":";;;;;;;;AACA;AAUA;AACA;AACA,MAAMA,eAAe,CAA6B;EAIhD;AACF;EACEC,WAAW,CAACC,cAA6B,EAAEC,YAA2B,EAAE;IAAA;IAAA;IACtE,IAAI,CAACC,MAAM,GAAGF,cAAc;IAC5B,IAAI,CAACG,IAAI,GAAGF,YAAY;EAC1B;;EAEA;AACF;EACE,IAAIG,EAAE,GAAW;IACf,MAAMA,EAAE,GAAG,IAAI,CAACC,kBAAkB,GAC9B,uBAAuB,GACvB,cAAc;IAElB,QAAQ,IAAI,CAACC,SAAS;MACpB,KAAK,MAAM;QACT,OAAQ,wBAAuBF,EAAG,EAAC;MACrC,KAAK,MAAM;QACT,OAAQ,wBAAuBA,EAAG,EAAC;MACrC,KAAK,UAAU;QACb,OAAQ,4BAA2BA,EAAG,EAAC;MACzC,KAAK,WAAW;QACd,OAAQ,6BAA4BA,EAAG,EAAC;MAC1C;QACE,OAAQ,0BAAyBA,EAAG,EAAC;IAAC;EAE5C;;EAEA;AACF;EACE,IAAIG,cAAc,GAAW;IAC3B,MAAMC,aAAa,GAAG,IAAI,CAACH,kBAAkB,GAAG,kBAAkB,GAAG,EAAE;IAEvE,QAAQ,IAAI,CAACC,SAAS;MACpB,KAAK,MAAM;QACT,OAAQ,4BAA2BE,aAAc,WAAU;MAC7D,KAAK,MAAM;QACT,OAAQ,4BAA2BA,aAAc,WAAU;MAC7D,KAAK,UAAU;QACb,OAAQ,6BAA4BA,aAAc,YAAW;MAC/D,KAAK,WAAW;QACd,OAAQ,6BAA4BA,aAAc,YAAW;MAC/D;Q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EA;AACF;EACEG,QAAQ,GAAY;IAClB;IACA,IAAI,IAAI,CAACd,KAAK,CAACe,OAAO,EAAE,IAAI,IAAI,CAACd,GAAG,CAACc,OAAO,EAAE,EAAE;MAC9C,OAAO,IAAI;IACb;IAEA,OAAO,IAAI,CAACN,UAAU,CAAC,IAAI,CAACT,KAAK,CAACgB,KAAK,EAAE,IAAI,CAACf,GAAG,CAACe,KAAK,CAAC;EAC1D;;EAEA;AACF;EACE,IAAIC,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEc9B,eAAe;AAAA"}
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
-
10
9
  /**
11
10
  */
12
11
  class RegexConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"RegexConstraint.js","names":["RegexConstraint","constructor","regexConstraint","_regexConstraint","id","messageKey","hasValidation","defaultMessage","parameters","regex","validate","value","RegExp","test","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/RegexConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\nexport type RegexObject = {\n messageKey: string,\n defaultMessage: string | null,\n regex: string | RegExp,\n};\n\n/**\n */\nclass RegexConstraint implements IConstraintModel {\n _regexConstraint: Object;\n\n /**\n */\n constructor(regexConstraint: RegexObject) {\n this._regexConstraint = regexConstraint;\n }\n\n /**\n */\n get id(): any {\n return this.regexConstraint.messageKey;\n }\n\n /**\n */\n get regexConstraint(): any {\n return this._regexConstraint;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): any {\n return (\n this.regexConstraint.defaultMessage || this.regexConstraint.messageKey\n );\n }\n\n /**\n */\n get parameters(): { regex: any } {\n return {\n regex: this.regexConstraint.regex,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n if (this.regexConstraint.regex instanceof RegExp) {\n return this.regexConstraint.regex.test(value);\n }\n\n return new RegExp(this.regexConstraint.regex).test(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default RegexConstraint;\n"],"mappings":";;;;;;;;;AASA;AACA;AACA,MAAMA,eAAe,CAA6B;EAGhD;AACF;EACEC,WAAW,CAACC,eAA4B,EAAE;IAAA;IACxC,IAAI,CAACC,gBAAgB,GAAGD,eAAe;EACzC;;EAEA;AACF;EACE,IAAIE,EAAE,GAAQ;IACZ,OAAO,IAAI,CAACF,eAAe,CAACG,UAAU;EACxC;;EAEA;AACF;EACE,IAAIH,eAAe,GAAQ;IACzB,OAAO,IAAI,CAACC,gBAAgB;EAC9B;;EAEA;AACF;EACEG,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAQ;IACxB,OACE,IAAI,CAACL,eAAe,CAACK,cAAc,IAAI,IAAI,CAACL,eAAe,CAACG,UAAU;EAE1E;;EAEA;AACF;EACE,IAAIG,UAAU,GAAmB;IAC/B,OAAO;MACLC,KAAK,EAAE,IAAI,CAACP,eAAe,CAACO;IAC9B,CAAC;EACH;;EAEA;AACF;EACEC,QAAQ,CAACC,KAAa,EAAW;IAC/B,IAAI,IAAI,CAACT,eAAe,CAACO,KAAK,YAAYG,MAAM,EAAE;MAChD,OAAO,IAAI,CAACV,eAAe,CAACO,KAAK,CAACI,IAAI,CAACF,KAAK,CAAC;IAC/C;IAEA,OAAO,IAAIC,MAAM,CAAC,IAAI,CAACV,eAAe,CAACO,KAAK,CAAC,CAACI,IAAI,CAACF,KAAK,CAAC;EAC3D;;EAEA;AACF;EACE,IAAIG,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcd,eAAe;AAAA"}
1
+ {"version":3,"file":"RegexConstraint.js","names":["RegexConstraint","constructor","regexConstraint","_regexConstraint","id","messageKey","hasValidation","defaultMessage","parameters","regex","validate","value","RegExp","test","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/RegexConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\nexport type RegexObject = {\n messageKey: string,\n defaultMessage: string | null,\n regex: string | RegExp,\n};\n\n/**\n */\nclass RegexConstraint implements IConstraintModel {\n _regexConstraint: Object;\n\n /**\n */\n constructor(regexConstraint: RegexObject) {\n this._regexConstraint = regexConstraint;\n }\n\n /**\n */\n get id(): any {\n return this.regexConstraint.messageKey;\n }\n\n /**\n */\n get regexConstraint(): any {\n return this._regexConstraint;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): any {\n return (\n this.regexConstraint.defaultMessage || this.regexConstraint.messageKey\n );\n }\n\n /**\n */\n get parameters(): { regex: any } {\n return {\n regex: this.regexConstraint.regex,\n };\n }\n\n /**\n */\n validate(value: string): boolean {\n if (this.regexConstraint.regex instanceof RegExp) {\n return this.regexConstraint.regex.test(value);\n }\n\n return new RegExp(this.regexConstraint.regex).test(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default RegexConstraint;\n"],"mappings":";;;;;;;;AASA;AACA;AACA,MAAMA,eAAe,CAA6B;EAGhD;AACF;EACEC,WAAW,CAACC,eAA4B,EAAE;IAAA;IACxC,IAAI,CAACC,gBAAgB,GAAGD,eAAe;EACzC;;EAEA;AACF;EACE,IAAIE,EAAE,GAAQ;IACZ,OAAO,IAAI,CAACF,eAAe,CAACG,UAAU;EACxC;;EAEA;AACF;EACE,IAAIH,eAAe,GAAQ;IACzB,OAAO,IAAI,CAACC,gBAAgB;EAC9B;;EAEA;AACF;EACEG,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAQ;IACxB,OACE,IAAI,CAACL,eAAe,CAACK,cAAc,IAAI,IAAI,CAACL,eAAe,CAACG,UAAU;EAE1E;;EAEA;AACF;EACE,IAAIG,UAAU,GAAmB;IAC/B,OAAO;MACLC,KAAK,EAAE,IAAI,CAACP,eAAe,CAACO;IAC9B,CAAC;EACH;;EAEA;AACF;EACEC,QAAQ,CAACC,KAAa,EAAW;IAC/B,IAAI,IAAI,CAACT,eAAe,CAACO,KAAK,YAAYG,MAAM,EAAE;MAChD,OAAO,IAAI,CAACV,eAAe,CAACO,KAAK,CAACI,IAAI,CAACF,KAAK,CAAC;IAC/C;IAEA,OAAO,IAAIC,MAAM,CAAC,IAAI,CAACV,eAAe,CAACO,KAAK,CAAC,CAACI,IAAI,CAACF,KAAK,CAAC;EAC3D;;EAEA;AACF;EACE,IAAIG,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcd,eAAe;AAAA"}
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
-
10
9
  const INVALID_LENGTH_ID = "Constraint.InvalidLengthExact";
11
10
  const INVALID_LENGTH_BETWEEN_ID = "Constraint.InvalidLengthBetween";
12
11
  const INVALID_LENGTH_TOO_SHORT_ID = "Constraint.InvalidLengthTooShort";
@@ -1 +1 @@
1
- {"version":3,"file":"StringLengthConstraint.js","names":["INVALID_LENGTH_ID","INVALID_LENGTH_BETWEEN_ID","INVALID_LENGTH_TOO_SHORT_ID","INVALID_LENGTH_TOO_LONG_ID","StringLengthConstraint","constructor","minLength","maxLength","_minLength","_maxLength","id","hasValidation","isExactLength","value","TypeError","Error","length","isBetween","isLongEnough","isSmallEnough","defaultMessage","parameters","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/StringLengthConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\nconst INVALID_LENGTH_ID = \"Constraint.InvalidLengthExact\";\nconst INVALID_LENGTH_BETWEEN_ID = \"Constraint.InvalidLengthBetween\";\nconst INVALID_LENGTH_TOO_SHORT_ID = \"Constraint.InvalidLengthTooShort\";\nconst INVALID_LENGTH_TOO_LONG_ID = \"Constraint.InvalidLengthTooLong\";\n\n/**\n */\nclass StringLengthConstraint implements IConstraintModel {\n _minLength: number | null;\n _maxLength: number | null;\n\n /**\n */\n constructor(minLength: number | null, maxLength: number | null) {\n this._minLength = minLength;\n this._maxLength = maxLength;\n }\n\n /**\n */\n get id(): string {\n if (this.minLength && this.maxLength && this.minLength === this.maxLength) {\n return INVALID_LENGTH_ID;\n } else if (this.minLength && this.maxLength) {\n return INVALID_LENGTH_BETWEEN_ID;\n } else if (this.minLength) {\n return INVALID_LENGTH_TOO_SHORT_ID;\n } else if (this.maxLength) {\n return INVALID_LENGTH_TOO_LONG_ID;\n }\n\n return \"Constraint.NoLengthConstraint\";\n }\n\n /**\n */\n get minLength(): null | number {\n return this._minLength;\n }\n\n /**\n */\n get maxLength(): null | number {\n return this._maxLength;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n isExactLength(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isExactLength: Not comparing to string\");\n }\n\n if (this.minLength === null) {\n throw new Error(\"isExactLength: Min and max length not set\");\n }\n\n return value.length === this.minLength;\n }\n\n /**\n */\n isBetween(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isBetween: Not comparing to string\");\n }\n\n if (this.minLength === null || this.maxLength === null) {\n throw new Error(\"isBetween: Min or max length not set\");\n }\n\n return this.isLongEnough(value) && this.isSmallEnough(value);\n }\n\n /**\n */\n isLongEnough(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isLongEnough: Not comparing to string\");\n }\n\n if (this.minLength === null) {\n throw new Error(\"isLongEnough: Min length not set\");\n }\n\n return value.length >= this.minLength;\n }\n\n /**\n */\n isSmallEnough(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isSmallEnough: Not comparing to string\");\n }\n\n if (this.maxLength === null) {\n throw new Error(\"isSmallEnough: Max length not set\");\n }\n\n return value.length <= this.maxLength;\n }\n\n /**\n */\n get defaultMessage(): string {\n switch (this.id) {\n case INVALID_LENGTH_ID:\n return \"Length must be precisely ${length} characters\"; // NOSONAR\n case INVALID_LENGTH_BETWEEN_ID:\n return \"Length must be between ${min-length} and ${max-length} characters\"; // NOSONAR\n case INVALID_LENGTH_TOO_SHORT_ID:\n return \"The length of the value must be larger than ${min-length}\"; // NOSONAR\n case INVALID_LENGTH_TOO_LONG_ID:\n return \"The length of the value must be smaller than ${max-length}\"; // NOSONAR\n default:\n return \"\";\n }\n }\n\n /**\n */\n get parameters(): { ... } {\n switch (this.id) {\n case INVALID_LENGTH_ID:\n return {\n length: this.minLength,\n };\n case INVALID_LENGTH_BETWEEN_ID:\n return {\n \"min-length\": this.minLength,\n \"max-length\": this.maxLength,\n };\n case INVALID_LENGTH_TOO_SHORT_ID:\n return {\n \"min-length\": this.minLength,\n };\n case INVALID_LENGTH_TOO_LONG_ID:\n return {\n \"max-length\": this.maxLength,\n };\n default:\n return {};\n }\n }\n\n /**\n */\n validate(value: string): boolean {\n switch (this.id) {\n case INVALID_LENGTH_ID:\n return this.isExactLength(value);\n case INVALID_LENGTH_BETWEEN_ID:\n return this.isBetween(value);\n case INVALID_LENGTH_TOO_SHORT_ID:\n return this.isLongEnough(value);\n case INVALID_LENGTH_TOO_LONG_ID:\n return this.isSmallEnough(value);\n default:\n return true;\n }\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default StringLengthConstraint;\n"],"mappings":";;;;;;;;;AAGA,MAAMA,iBAAiB,GAAG,+BAA+B;AACzD,MAAMC,yBAAyB,GAAG,iCAAiC;AACnE,MAAMC,2BAA2B,GAAG,kCAAkC;AACtE,MAAMC,0BAA0B,GAAG,iCAAiC;;AAEpE;AACA;AACA,MAAMC,sBAAsB,CAA6B;EAIvD;AACF;EACEC,WAAW,CAACC,SAAwB,EAAEC,SAAwB,E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,CAAC;MACH,KAAKL,yBAAyB;QAC5B,OAAO;UACL,YAAY,EAAE,IAAI,CAACK,SAAS;UAC5B,YAAY,EAAE,IAAI,CAACC;QACrB,CAAC;MACH,KAAKL,2BAA2B;QAC9B,OAAO;UACL,YAAY,EAAE,IAAI,CAACI;QACrB,CAAC;MACH,KAAKH,0BAA0B;QAC7B,OAAO;UACL,YAAY,EAAE,IAAI,CAACI;QACrB,CAAC;MACH;QACE,OAAO,CAAC,CAAC;IAAC;EAEhB;;EAEA;AACF;EACEe,QAAQ,CAACT,KAAa,EAAW;IAC/B,QAAQ,IAAI,CAACH,EAAE;MACb,KAAKV,iBAAiB;QACpB,OAAO,IAAI,CAACY,aAAa,CAACC,KAAK,CAAC;MAClC,KAAKZ,yBAAyB;QAC5B,OAAO,IAAI,CAACgB,SAAS,CAACJ,KAAK,CAAC;MAC9B,KAAKX,2BAA2B;QAC9B,OAAO,IAAI,CAACgB,YAAY,CAACL,KAAK,CAAC;MACjC,KAAKV,0BAA0B;QAC7B,OAAO,IAAI,CAACgB,aAAa,CAACN,KAAK,CAAC;MAClC;QACE,OAAO,IAAI;IAAC;EAElB;;EAEA;AACF;EACE,IAAIU,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcnB,sBAAsB;AAAA"}
1
+ {"version":3,"file":"StringLengthConstraint.js","names":["INVALID_LENGTH_ID","INVALID_LENGTH_BETWEEN_ID","INVALID_LENGTH_TOO_SHORT_ID","INVALID_LENGTH_TOO_LONG_ID","StringLengthConstraint","constructor","minLength","maxLength","_minLength","_maxLength","id","hasValidation","isExactLength","value","TypeError","Error","length","isBetween","isLongEnough","isSmallEnough","defaultMessage","parameters","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/StringLengthConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\nconst INVALID_LENGTH_ID = \"Constraint.InvalidLengthExact\";\nconst INVALID_LENGTH_BETWEEN_ID = \"Constraint.InvalidLengthBetween\";\nconst INVALID_LENGTH_TOO_SHORT_ID = \"Constraint.InvalidLengthTooShort\";\nconst INVALID_LENGTH_TOO_LONG_ID = \"Constraint.InvalidLengthTooLong\";\n\n/**\n */\nclass StringLengthConstraint implements IConstraintModel {\n _minLength: number | null;\n _maxLength: number | null;\n\n /**\n */\n constructor(minLength: number | null, maxLength: number | null) {\n this._minLength = minLength;\n this._maxLength = maxLength;\n }\n\n /**\n */\n get id(): string {\n if (this.minLength && this.maxLength && this.minLength === this.maxLength) {\n return INVALID_LENGTH_ID;\n } else if (this.minLength && this.maxLength) {\n return INVALID_LENGTH_BETWEEN_ID;\n } else if (this.minLength) {\n return INVALID_LENGTH_TOO_SHORT_ID;\n } else if (this.maxLength) {\n return INVALID_LENGTH_TOO_LONG_ID;\n }\n\n return \"Constraint.NoLengthConstraint\";\n }\n\n /**\n */\n get minLength(): null | number {\n return this._minLength;\n }\n\n /**\n */\n get maxLength(): null | number {\n return this._maxLength;\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n isExactLength(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isExactLength: Not comparing to string\");\n }\n\n if (this.minLength === null) {\n throw new Error(\"isExactLength: Min and max length not set\");\n }\n\n return value.length === this.minLength;\n }\n\n /**\n */\n isBetween(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isBetween: Not comparing to string\");\n }\n\n if (this.minLength === null || this.maxLength === null) {\n throw new Error(\"isBetween: Min or max length not set\");\n }\n\n return this.isLongEnough(value) && this.isSmallEnough(value);\n }\n\n /**\n */\n isLongEnough(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isLongEnough: Not comparing to string\");\n }\n\n if (this.minLength === null) {\n throw new Error(\"isLongEnough: Min length not set\");\n }\n\n return value.length >= this.minLength;\n }\n\n /**\n */\n isSmallEnough(value: string): boolean {\n if (typeof value !== \"string\") {\n throw new TypeError(\"isSmallEnough: Not comparing to string\");\n }\n\n if (this.maxLength === null) {\n throw new Error(\"isSmallEnough: Max length not set\");\n }\n\n return value.length <= this.maxLength;\n }\n\n /**\n */\n get defaultMessage(): string {\n switch (this.id) {\n case INVALID_LENGTH_ID:\n return \"Length must be precisely ${length} characters\"; // NOSONAR\n case INVALID_LENGTH_BETWEEN_ID:\n return \"Length must be between ${min-length} and ${max-length} characters\"; // NOSONAR\n case INVALID_LENGTH_TOO_SHORT_ID:\n return \"The length of the value must be larger than ${min-length}\"; // NOSONAR\n case INVALID_LENGTH_TOO_LONG_ID:\n return \"The length of the value must be smaller than ${max-length}\"; // NOSONAR\n default:\n return \"\";\n }\n }\n\n /**\n */\n get parameters(): { ... } {\n switch (this.id) {\n case INVALID_LENGTH_ID:\n return {\n length: this.minLength,\n };\n case INVALID_LENGTH_BETWEEN_ID:\n return {\n \"min-length\": this.minLength,\n \"max-length\": this.maxLength,\n };\n case INVALID_LENGTH_TOO_SHORT_ID:\n return {\n \"min-length\": this.minLength,\n };\n case INVALID_LENGTH_TOO_LONG_ID:\n return {\n \"max-length\": this.maxLength,\n };\n default:\n return {};\n }\n }\n\n /**\n */\n validate(value: string): boolean {\n switch (this.id) {\n case INVALID_LENGTH_ID:\n return this.isExactLength(value);\n case INVALID_LENGTH_BETWEEN_ID:\n return this.isBetween(value);\n case INVALID_LENGTH_TOO_SHORT_ID:\n return this.isLongEnough(value);\n case INVALID_LENGTH_TOO_LONG_ID:\n return this.isSmallEnough(value);\n default:\n return true;\n }\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default StringLengthConstraint;\n"],"mappings":";;;;;;;;AAGA,MAAMA,iBAAiB,GAAG,+BAA+B;AACzD,MAAMC,yBAAyB,GAAG,iCAAiC;AACnE,MAAMC,2BAA2B,GAAG,kCAAkC;AACtE,MAAMC,0BAA0B,GAAG,iCAAiC;;AAEpE;AACA;AACA,MAAMC,sBAAsB,CAA6B;EAIvD;AACF;EACEC,WAAW,CAACC,SA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AAE,IAAI,CAACV;QACf,CAAC;MACH,KAAKL,yBAAyB;QAC5B,OAAO;UACL,YAAY,EAAE,IAAI,CAACK,SAAS;UAC5B,YAAY,EAAE,IAAI,CAACC;QACrB,CAAC;MACH,KAAKL,2BAA2B;QAC9B,OAAO;UACL,YAAY,EAAE,IAAI,CAACI;QACrB,CAAC;MACH,KAAKH,0BAA0B;QAC7B,OAAO;UACL,YAAY,EAAE,IAAI,CAACI;QACrB,CAAC;MACH;QACE,OAAO,CAAC,CAAC;IAAC;EAEhB;;EAEA;AACF;EACEe,QAAQ,CAACT,KAAa,EAAW;IAC/B,QAAQ,IAAI,CAACH,EAAE;MACb,KAAKV,iBAAiB;QACpB,OAAO,IAAI,CAACY,aAAa,CAACC,KAAK,CAAC;MAClC,KAAKZ,yBAAyB;QAC5B,OAAO,IAAI,CAACgB,SAAS,CAACJ,KAAK,CAAC;MAC9B,KAAKX,2BAA2B;QAC9B,OAAO,IAAI,CAACgB,YAAY,CAACL,KAAK,CAAC;MACjC,KAAKV,0BAA0B;QAC7B,OAAO,IAAI,CAACgB,aAAa,CAACN,KAAK,CAAC;MAClC;QACE,OAAO,IAAI;IAAC;EAElB;;EAEA;AACF;EACE,IAAIU,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcnB,sBAAsB;AAAA"}
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  /**
9
8
  */
10
9
  class XMLConstraint {
@@ -1 +1 @@
1
- {"version":3,"file":"XMLConstraint.js","names":["XMLConstraint","id","hasValidation","defaultMessage","parameters","isValidXML","value","oParser","DOMParser","oDom","parseFromString","querySelectorAll","length","error","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/XMLConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass XMLConstraint implements IConstraintModel {\n /**\n */\n get id(): string {\n return \"Constraint.XML.InvalidFormat\";\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must be well-formed XML\";\n }\n\n /**\n */\n get parameters(): { ... } {\n return {};\n }\n\n /**\n */\n isValidXML(value: string): boolean {\n const oParser = new DOMParser();\n\n try {\n const oDom = oParser.parseFromString(value, \"text/xml\");\n\n if (oDom.querySelectorAll(\"parsererror\").length > 0) {\n return false;\n }\n } catch (error) {\n return false;\n }\n\n return true;\n }\n\n /**\n */\n validate(value: string): boolean {\n return this.isValidXML(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default XMLConstraint;\n"],"mappings":";;;;;;;AAGA;AACA;AACA,MAAMA,aAAa,CAA6B;EAC9C;AACF;EACE,IAAIC,EAAE,GAAW;IACf,OAAO,8BAA8B;EACvC;;EAEA;AACF;EACEC,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,yBAAyB;EAClC;;EAEA;AACF;EACE,IAAIC,UAAU,GAAY;IACxB,OAAO,CAAC,CAAC;EACX;;EAEA;AACF;EACEC,UAAU,CAACC,KAAa,EAAW;IACjC,MAAMC,OAAO,GAAG,IAAIC,SAAS,EAAE;IAE/B,IAAI;MACF,MAAMC,IAAI,GAAGF,OAAO,CAACG,eAAe,CAACJ,KAAK,EAAE,UAAU,CAAC;MAEvD,IAAIG,IAAI,CAACE,gBAAgB,CAAC,aAAa,CAAC,CAACC,MAAM,GAAG,CAAC,EAAE;QACnD,OAAO,KAAK;MACd;IACF,CAAC,CAAC,OAAOC,KAAK,EAAE;MACd,OAAO,KAAK;IACd;IAEA,OAAO,IAAI;EACb;;EAEA;AACF;EACEC,QAAQ,CAACR,KAAa,EAAW;IAC/B,OAAO,IAAI,CAACD,UAAU,CAACC,KAAK,CAAC;EAC/B;;EAEA;AACF;EACE,IAAIS,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcf,aAAa;AAAA"}
1
+ {"version":3,"file":"XMLConstraint.js","names":["XMLConstraint","id","hasValidation","defaultMessage","parameters","isValidXML","value","oParser","DOMParser","oDom","parseFromString","querySelectorAll","length","error","validate","isMandatoryConstraint"],"sources":["../../../../src/models/attributes/input-constraints/XMLConstraint.js"],"sourcesContent":["// @flow\nimport type { IConstraintModel } from \"../../types\";\n\n/**\n */\nclass XMLConstraint implements IConstraintModel {\n /**\n */\n get id(): string {\n return \"Constraint.XML.InvalidFormat\";\n }\n\n /**\n */\n hasValidation(): boolean {\n return true;\n }\n\n /**\n */\n get defaultMessage(): string {\n return \"Must be well-formed XML\";\n }\n\n /**\n */\n get parameters(): { ... } {\n return {};\n }\n\n /**\n */\n isValidXML(value: string): boolean {\n const oParser = new DOMParser();\n\n try {\n const oDom = oParser.parseFromString(value, \"text/xml\");\n\n if (oDom.querySelectorAll(\"parsererror\").length > 0) {\n return false;\n }\n } catch (error) {\n return false;\n }\n\n return true;\n }\n\n /**\n */\n validate(value: string): boolean {\n return this.isValidXML(value);\n }\n\n /**\n */\n get isMandatoryConstraint(): boolean {\n return false;\n }\n}\n\nexport default XMLConstraint;\n"],"mappings":";;;;;;AAGA;AACA;AACA,MAAMA,aAAa,CAA6B;EAC9C;AACF;EACE,IAAIC,EAAE,GAAW;IACf,OAAO,8BAA8B;EACvC;;EAEA;AACF;EACEC,aAAa,GAAY;IACvB,OAAO,IAAI;EACb;;EAEA;AACF;EACE,IAAIC,cAAc,GAAW;IAC3B,OAAO,yBAAyB;EAClC;;EAEA;AACF;EACE,IAAIC,UAAU,GAAY;IACxB,OAAO,CAAC,CAAC;EACX;;EAEA;AACF;EACEC,UAAU,CAACC,KAAa,EAAW;IACjC,MAAMC,OAAO,GAAG,IAAIC,SAAS,EAAE;IAE/B,IAAI;MACF,MAAMC,IAAI,GAAGF,OAAO,CAACG,eAAe,CAACJ,KAAK,EAAE,UAAU,CAAC;MAEvD,IAAIG,IAAI,CAACE,gBAAgB,CAAC,aAAa,CAAC,CAACC,MAAM,GAAG,CAAC,EAAE;QACnD,OAAO,KAAK;MACd;IACF,CAAC,CAAC,OAAOC,KAAK,EAAE;MACd,OAAO,KAAK;IACd;IAEA,OAAO,IAAI;EACb;;EAEA;AACF;EACEC,QAAQ,CAACR,KAAa,EAAW;IAC/B,OAAO,IAAI,CAACD,UAAU,CAACC,KAAK,CAAC;EAC/B;;EAEA;AACF;EACE,IAAIS,qBAAqB,GAAY;IACnC,OAAO,KAAK;EACd;AACF;AAAC,eAEcf,aAAa;AAAA"}
@@ -8,7 +8,6 @@ exports.default = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
9
9
  var _exceptions = require("../../../exceptions");
10
10
  /* eslint-disable no-unused-vars */
11
-
12
11
  /**
13
12
  * Abstract class for layout hint rules
14
13
  * @abstract
@@ -1 +1 @@
1
- {"version":3,"file":"BaseLayoutHintRule.js","names":["BaseLayoutHintRule","isApplicableForAttribute","attribute","isApplicableForHint","hint","IllegalStateException","initAttribute","initHint","process","attributes"],"sources":["../../../../src/models/attributes/layouthint-rules/BaseLayoutHintRule.js"],"sourcesContent":["// @flow\n/* eslint-disable no-unused-vars */\n\nimport { IllegalStateException } from \"../../../exceptions\";\n\nimport type { ILayoutHintRule, AttributeType } from \"../../types\";\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type AttributeModel from \"../AttributeModel\";\n\n/**\n * Abstract class for layout hint rules\n * @abstract\n */\nclass BaseLayoutHintRule implements ILayoutHintRule {\n /**\n * Indicates if the rule implements the isApplicableForHint method\n * @type {boolean}\n * @default false\n */\n static checkHintApplicability: boolean = false;\n\n /**\n * Indicates if the rule instance is applicable for a specific attribute<br>\n * @default true\n */\n static isApplicableForAttribute(attribute: AttributeType): boolean {\n return true;\n }\n\n /**\n * Indicates if the rule instance is applicable for a specific hint<br>\n * Is required when checkHintApplicability is true\n * @abstract\n */\n static isApplicableForHint(hint: string): boolean {\n throw new IllegalStateException(\n `Missing isApplicableForHint implementation on layout hint rule`\n );\n }\n\n /**\n * Initialize the rule when isApplicableForAttribute is true and checkHintApplicability is false\n * @abstract\n */\n static initAttribute(attribute: AttributeType): ILayoutHintRule {\n throw new IllegalStateException(\n `Missing initAttribute implementation on layout hint rule`\n );\n }\n\n /**\n * Initialize the rule when isApplicableForAttribute and isApplicableForHint are both true,\n * it receives the hint. Allows a rule to be instantiated multiple times for an attribute,\n * but once for each hint entry\n * @abstract\n */\n static initHint(hint: string): ILayoutHintRule {\n throw new IllegalStateException(\n `Missing initHint implementation on layout hint rule`\n );\n }\n\n /**\n * Abstract method, implements process of layout hint rule,\n * use this to enhance the applicable attribute or the attribute collection\n * @abstract\n */\n process(attribute: AttributeModel, attributes: AttributeCollection) {\n throw new IllegalStateException(\n `Missing process implementation on layout hint rule`\n );\n }\n}\n\nexport default BaseLayoutHintRule;\n"],"mappings":";;;;;;;;AAGA;AAFA;;AAQA;AACA;AACA;AACA;AACA,MAAMA,kBAAkB,CAA4B;EAClD;AACF;AACA;AACA;AACA;;EAGE;AACF;AACA;AACA;EACE,OAAOC,wBAAwB,CAACC,SAAwB,EAAW;IACjE,OAAO,IAAI;EACb;;EAEA;AACF;AACA;AACA;AACA;EACE,OAAOC,mBAAmB,CAACC,IAAY,EAAW;IAChD,MAAM,IAAIC,iCAAqB,CAC5B,gEAA+D,CACjE;EACH;;EAEA;AACF;AACA;AACA;EACE,OAAOC,aAAa,CAACJ,SAAwB,EAAmB;IAC9D,MAAM,IAAIG,iCAAqB,CAC5B,0DAAyD,CAC3D;EACH;;EAEA;AACF;AACA;AACA;AACA;AACA;EACE,OAAOE,QAAQ,CAACH,IAAY,EAAmB;IAC7C,MAAM,IAAIC,iCAAqB,CAC5B,qDAAoD,CACtD;EACH;;EAEA;AACF;AACA;AACA;AACA;EACEG,OAAO,CAACN,SAAyB,EAAEO,UAA+B,EAAE;IAClE,MAAM,IAAIJ,iCAAqB,CAC5B,oDAAmD,CACrD;EACH;AACF;AAAC,8BA3DKL,kBAAkB,4BAMmB,KAAK;AAAA,eAuDjCA,kBAAkB;AAAA"}
1
+ {"version":3,"file":"BaseLayoutHintRule.js","names":["BaseLayoutHintRule","isApplicableForAttribute","attribute","isApplicableForHint","hint","IllegalStateException","initAttribute","initHint","process","attributes"],"sources":["../../../../src/models/attributes/layouthint-rules/BaseLayoutHintRule.js"],"sourcesContent":["// @flow\n/* eslint-disable no-unused-vars */\n\nimport { IllegalStateException } from \"../../../exceptions\";\n\nimport type { ILayoutHintRule, AttributeType } from \"../../types\";\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type AttributeModel from \"../AttributeModel\";\n\n/**\n * Abstract class for layout hint rules\n * @abstract\n */\nclass BaseLayoutHintRule implements ILayoutHintRule {\n /**\n * Indicates if the rule implements the isApplicableForHint method\n * @type {boolean}\n * @default false\n */\n static checkHintApplicability: boolean = false;\n\n /**\n * Indicates if the rule instance is applicable for a specific attribute<br>\n * @default true\n */\n static isApplicableForAttribute(attribute: AttributeType): boolean {\n return true;\n }\n\n /**\n * Indicates if the rule instance is applicable for a specific hint<br>\n * Is required when checkHintApplicability is true\n * @abstract\n */\n static isApplicableForHint(hint: string): boolean {\n throw new IllegalStateException(\n `Missing isApplicableForHint implementation on layout hint rule`\n );\n }\n\n /**\n * Initialize the rule when isApplicableForAttribute is true and checkHintApplicability is false\n * @abstract\n */\n static initAttribute(attribute: AttributeType): ILayoutHintRule {\n throw new IllegalStateException(\n `Missing initAttribute implementation on layout hint rule`\n );\n }\n\n /**\n * Initialize the rule when isApplicableForAttribute and isApplicableForHint are both true,\n * it receives the hint. Allows a rule to be instantiated multiple times for an attribute,\n * but once for each hint entry\n * @abstract\n */\n static initHint(hint: string): ILayoutHintRule {\n throw new IllegalStateException(\n `Missing initHint implementation on layout hint rule`\n );\n }\n\n /**\n * Abstract method, implements process of layout hint rule,\n * use this to enhance the applicable attribute or the attribute collection\n * @abstract\n */\n process(attribute: AttributeModel, attributes: AttributeCollection) {\n throw new IllegalStateException(\n `Missing process implementation on layout hint rule`\n );\n }\n}\n\nexport default BaseLayoutHintRule;\n"],"mappings":";;;;;;;;AAGA;AAFA;AAQA;AACA;AACA;AACA;AACA,MAAMA,kBAAkB,CAA4B;EAClD;AACF;AACA;AACA;AACA;;EAGE;AACF;AACA;AACA;EACE,OAAOC,wBAAwB,CAACC,SAAwB,EAAW;IACjE,OAAO,IAAI;EACb;;EAEA;AACF;AACA;AACA;AACA;EACE,OAAOC,mBAAmB,CAACC,IAAY,EAAW;IAChD,MAAM,IAAIC,iCAAqB,CAC5B,gEAA+D,CACjE;EACH;;EAEA;AACF;AACA;AACA;EACE,OAAOC,aAAa,CAACJ,SAAwB,EAAmB;IAC9D,MAAM,IAAIG,iCAAqB,CAC5B,0DAAyD,CAC3D;EACH;;EAEA;AACF;AACA;AACA;AACA;AACA;EACE,OAAOE,QAAQ,CAACH,IAAY,EAAmB;IAC7C,MAAM,IAAIC,iCAAqB,CAC5B,qDAAoD,CACtD;EACH;;EAEA;AACF;AACA;AACA;AACA;EACEG,OAAO,CAACN,SAAyB,EAAEO,UAA+B,EAAE;IAClE,MAAM,IAAIJ,iCAAqB,CAC5B,oDAAmD,CACrD;EACH;AACF;AAAC,8BA3DKL,kBAAkB,4BAMmB,KAAK;AAAA,eAuDjCA,kBAAkB;AAAA"}
@@ -14,7 +14,6 @@ var _constants = require("../../../constants");
14
14
  var _ChoiceAttributeModel = _interopRequireDefault(require("../ChoiceAttributeModel"));
15
15
  var _BooleanAttributeModel = _interopRequireDefault(require("../BooleanAttributeModel"));
16
16
  var _exceptions = require("../../../exceptions");
17
-
18
17
  const EQUALS = "equals";
19
18
  const INCLUDES = "includes";
20
19
  const NOT_EQUALS = "notEquals";
@@ -154,9 +153,9 @@ class DependentAttribute extends _BaseLayoutHintRule.default {
154
153
  case NOT_INCLUDES:
155
154
  return !this.processIncludesOptions(controlAttribute);
156
155
  case NOT_IS_EMPTY:
157
- return (controlAttribute === null || controlAttribute === void 0 ? void 0 : controlAttribute.selected.length) !== 0;
156
+ return controlAttribute?.selected.length !== 0;
158
157
  case IS_EMPTY:
159
- return (controlAttribute === null || controlAttribute === void 0 ? void 0 : controlAttribute.selected.length) === 0;
158
+ return controlAttribute?.selected.length === 0;
160
159
  default:
161
160
  throw new _exceptions.ConfigurationException(`Unsupported operator for dependent question: ${this.operator}`);
162
161
  }
@@ -1 +1 @@
1
- {"version":3,"file":"DependentAttribute.js","names":["EQUALS","INCLUDES","NOT_EQUALS","NOT_INCLUDES","NOT_IS_EMPTY","IS_EMPTY","SHOW","HIDE","DependentAttribute","BaseLayoutHintRule","isApplicableForHint","hint","regex","RegExp","DEPENDENT_ATTRIBUTE","test","getRuleInstance","initHint","rule","OPERATORS","DEPENDENT_ATTRIBUTE_CONTROL","isEmpyNotIsEmptRegex","result","match","action","control","operator","options","ConfigurationException","_action","_control","_operator","_options","split","option","processEqualsOptions","controlAttribute","ChoiceAttributeModel","BooleanAttributeModel","every","selected","processIncludesOptions","some","handleOperator","length","getControlAttribute","attributes","attribute","getAttributeByLayoutHint","process","processLayoutHintRules","isHidden","hide","label"],"sources":["../../../../src/models/attributes/layouthint-rules/DependentAttribute.js"],"sourcesContent":["// @flow\nimport BaseLayoutHintRule from \"./BaseLayoutHintRule\";\n\nimport {\n DEPENDENT_ATTRIBUTE_CONTROL,\n DEPENDENT_ATTRIBUTE,\n} from \"../../../constants\";\n\nimport ChoiceAttributeModel from \"../ChoiceAttributeModel\";\nimport BooleanAttributeModel from \"../BooleanAttributeModel\";\n\nimport { ConfigurationException } from \"../../../exceptions\";\n\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type AttributeModel from \"../AttributeModel\";\n\nconst EQUALS = \"equals\";\nconst INCLUDES = \"includes\";\nconst NOT_EQUALS = \"notEquals\";\nconst NOT_INCLUDES = \"notIncludes\";\nconst NOT_IS_EMPTY = \"notIsEmpty\";\nconst IS_EMPTY = \"isEmpty\";\n\nconst SHOW = \"show\";\nconst HIDE = \"hide\";\n\n/**\n * Depending attributes hint logic\n */\nclass DependentAttribute extends BaseLayoutHintRule {\n _action: string;\n _control: string;\n _operator: string;\n _options: Array<string>;\n\n /**\n */\n static checkHintApplicability: boolean = true;\n\n /**\n */\n static isApplicableForHint(hint: string): boolean {\n const regex = new RegExp(\n `^${DEPENDENT_ATTRIBUTE}\\\\s?(${SHOW}|${HIDE})`,\n \"i\"\n );\n\n return regex.test(hint);\n }\n\n /**\n * Used on initHint to create an instance of this rule\n */\n static getRuleInstance(): DependentAttribute {\n return new DependentAttribute();\n }\n\n /**\n */\n static initHint(hint: string): any {\n const rule = this.getRuleInstance();\n\n const OPERATORS = `${EQUALS}|${INCLUDES}|${NOT_EQUALS}|${NOT_INCLUDES}|${NOT_IS_EMPTY}|${IS_EMPTY}`;\n const regex = new RegExp(\n `${DEPENDENT_ATTRIBUTE}\\\\s?(\\\\S*)\\\\swhen ${DEPENDENT_ATTRIBUTE_CONTROL}:\\\\s?(.*?)\\\\s*(${OPERATORS})\\\\s(.*)`,\n \"i\"\n );\n const isEmpyNotIsEmptRegex = new RegExp(\n `${DEPENDENT_ATTRIBUTE}\\\\s?(\\\\S*)\\\\swhen ${DEPENDENT_ATTRIBUTE_CONTROL}:\\\\s?(.*?)\\\\s*(${OPERATORS})`,\n \"i\"\n );\n\n const result = hint.match(regex)\n ? hint.match(regex)\n : hint.match(isEmpyNotIsEmptRegex);\n\n if (result) {\n rule.action = result[1];\n rule.control = result[2];\n rule.operator = result[3];\n rule.options = !result[4] ? \"\" : result[4];\n } else {\n throw new ConfigurationException(\n `No dependent information found on layout hint: ${hint}`\n );\n }\n\n return rule;\n }\n\n /**\n */\n get action(): string {\n return this._action;\n }\n\n /**\n */\n set action(action: string) {\n this._action = action;\n }\n\n /**\n */\n get control(): string {\n return this._control;\n }\n\n /**\n */\n set control(control: string) {\n this._control = control;\n }\n\n /**\n */\n get operator(): string {\n return this._operator;\n }\n\n /**\n */\n set operator(operator: string) {\n this._operator = operator;\n }\n\n /**\n */\n get options(): Array<string> {\n return this._options;\n }\n\n /**\n */\n set options(options: string): void {\n this._options = options.split(\"|\").map((option) => option.trim());\n }\n\n /**\n */\n processEqualsOptions(\n controlAttribute: ChoiceAttributeModel | BooleanAttributeModel\n ): boolean {\n if (\n controlAttribute instanceof ChoiceAttributeModel ||\n controlAttribute instanceof BooleanAttributeModel\n ) {\n return this.options.every((option) =>\n controlAttribute.selected.includes(option)\n );\n }\n\n throw new ConfigurationException(\n \"Dependent control in combination with equals operator must be a choice, string or number attribute\"\n );\n }\n\n /**\n */\n processIncludesOptions(\n controlAttribute: ChoiceAttributeModel | BooleanAttributeModel\n ): boolean {\n if (controlAttribute instanceof ChoiceAttributeModel) {\n return this.options.some((option) =>\n controlAttribute.selected.includes(option)\n );\n }\n\n throw new ConfigurationException(\n \"Dependent control in combination with includes operator must be a choice attribute\"\n );\n }\n\n /**\n */\n handleOperator(\n controlAttribute: ChoiceAttributeModel | BooleanAttributeModel\n ): boolean {\n switch (this.operator) {\n case EQUALS:\n return this.processEqualsOptions(controlAttribute);\n case INCLUDES:\n return this.processIncludesOptions(controlAttribute);\n case NOT_EQUALS:\n return !this.processEqualsOptions(controlAttribute);\n case NOT_INCLUDES:\n return !this.processIncludesOptions(controlAttribute);\n case NOT_IS_EMPTY:\n return controlAttribute?.selected.length !== 0;\n case IS_EMPTY:\n return controlAttribute?.selected.length === 0;\n default:\n throw new ConfigurationException(\n `Unsupported operator for dependent question: ${this.operator}`\n );\n }\n }\n\n /**\n */\n getControlAttribute(\n attributes: AttributeCollection\n ): ChoiceAttributeModel | BooleanAttributeModel | null {\n const attribute = attributes.getAttributeByLayoutHint(\n `${DEPENDENT_ATTRIBUTE_CONTROL}:${this.control}`,\n `${DEPENDENT_ATTRIBUTE_CONTROL}: ${this.control}`\n );\n\n if (\n attribute instanceof ChoiceAttributeModel ||\n attribute instanceof BooleanAttributeModel\n ) {\n return attribute;\n }\n\n return null;\n }\n\n /**\n */\n process(attribute: AttributeModel, attributes: AttributeCollection) {\n const controlAttribute = this.getControlAttribute(attributes);\n if (!controlAttribute) {\n return;\n }\n\n controlAttribute.processLayoutHintRules(attributes);\n if (controlAttribute.isHidden) {\n attribute.hide();\n return;\n }\n\n const result = this.handleOperator(controlAttribute);\n if (this.action === SHOW) {\n attribute.isHidden = !result;\n } else if (this.action === HIDE) {\n attribute.isHidden = result;\n } else {\n throw new ConfigurationException(\n `Unsupported action ${this.action} for dependent question on attribute: ${attribute.label}`\n );\n }\n }\n}\n\nexport default DependentAttribute;\n"],"mappings":";;;;;;;;;;;AACA;AAEA;AAKA;AACA;AAEA;;AAKA,MAAMA,MAAM,GAAG,QAAQ;AACvB,MAAMC,QAAQ,GAAG,UAAU;AAC3B,MAAMC,UAAU,GAAG,WAAW;AAC9B,MAAMC,YAAY,GAAG,aAAa;AAClC,MAAMC,YAAY,GAAG,YAAY;AACjC,MAAMC,QAAQ,GAAG,SAAS;AAE1B,MAAMC,IAAI,GAAG,MAAM;AACnB,MAAMC,IAAI,GAAG,MAAM;;AAEnB;AACA;AACA;AACA,MAAMC,kBAAkB,SAASC,2BAAkB,CAAC;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAUlD;AACF;EACE,OAAOC,mBAAmB,CAACC,IAAY,EAAW;IAChD,MAAMC,KAAK,GAAG,IAAIC,MAAM,CACrB,IAAGC,8BAAoB,QAAOR,IAAK,IAAGC,IAAK,GAAE,EAC9C,GAAG,CACJ;IAED,OAAOK,KAAK,CAACG,IAAI,CAACJ,IAAI,CAAC;EACzB;;EAEA;AACF;AACA;EACE,OAAOK,eAAe,GAAuB;IAC3C,OAAO,IAAIR,kBAAkB,EAAE;EACjC;;EAEA;AACF;EACE,OAAOS,QAAQ,CAACN,IAAY,EAAO;IACjC,MAAMO,IAAI,GAAG,IAAI,CAACF,eAAe,EAAE;IAEnC,MAAMG,SAAS,GAAI,GAAEnB,MAAO,IAAGC,QAAS,IAAGC,UAAW,IAAGC,YAAa,IAAGC,Y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,GAAG,CAAC7B,MAAM;IAC9B,CAAC,MAAM,IAAI,IAAI,CAACE,MAAM,KAAKjB,IAAI,EAAE;MAC/BwC,SAAS,CAACI,QAAQ,GAAG7B,MAAM;IAC7B,CAAC,MAAM;MACL,MAAM,IAAIM,kCAAsB,CAC7B,sBAAqB,IAAI,CAACJ,MAAO,yCAAwCuB,SAAS,CAACM,KAAM,EAAC,CAC5F;IACH;EACF;AACF;AAAC,8BAtNK7C,kBAAkB,4BAQmB,IAAI;AAAA,eAgNhCA,kBAAkB;AAAA"}
1
+ {"version":3,"file":"DependentAttribute.js","names":["EQUALS","INCLUDES","NOT_EQUALS","NOT_INCLUDES","NOT_IS_EMPTY","IS_EMPTY","SHOW","HIDE","DependentAttribute","BaseLayoutHintRule","isApplicableForHint","hint","regex","RegExp","DEPENDENT_ATTRIBUTE","test","getRuleInstance","initHint","rule","OPERATORS","DEPENDENT_ATTRIBUTE_CONTROL","isEmpyNotIsEmptRegex","result","match","action","control","operator","options","ConfigurationException","_action","_control","_operator","_options","split","option","processEqualsOptions","controlAttribute","ChoiceAttributeModel","BooleanAttributeModel","every","selected","processIncludesOptions","some","handleOperator","length","getControlAttribute","attributes","attribute","getAttributeByLayoutHint","process","processLayoutHintRules","isHidden","hide","label"],"sources":["../../../../src/models/attributes/layouthint-rules/DependentAttribute.js"],"sourcesContent":["// @flow\nimport BaseLayoutHintRule from \"./BaseLayoutHintRule\";\n\nimport {\n DEPENDENT_ATTRIBUTE_CONTROL,\n DEPENDENT_ATTRIBUTE,\n} from \"../../../constants\";\n\nimport ChoiceAttributeModel from \"../ChoiceAttributeModel\";\nimport BooleanAttributeModel from \"../BooleanAttributeModel\";\n\nimport { ConfigurationException } from \"../../../exceptions\";\n\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type AttributeModel from \"../AttributeModel\";\n\nconst EQUALS = \"equals\";\nconst INCLUDES = \"includes\";\nconst NOT_EQUALS = \"notEquals\";\nconst NOT_INCLUDES = \"notIncludes\";\nconst NOT_IS_EMPTY = \"notIsEmpty\";\nconst IS_EMPTY = \"isEmpty\";\n\nconst SHOW = \"show\";\nconst HIDE = \"hide\";\n\n/**\n * Depending attributes hint logic\n */\nclass DependentAttribute extends BaseLayoutHintRule {\n _action: string;\n _control: string;\n _operator: string;\n _options: Array<string>;\n\n /**\n */\n static checkHintApplicability: boolean = true;\n\n /**\n */\n static isApplicableForHint(hint: string): boolean {\n const regex = new RegExp(\n `^${DEPENDENT_ATTRIBUTE}\\\\s?(${SHOW}|${HIDE})`,\n \"i\"\n );\n\n return regex.test(hint);\n }\n\n /**\n * Used on initHint to create an instance of this rule\n */\n static getRuleInstance(): DependentAttribute {\n return new DependentAttribute();\n }\n\n /**\n */\n static initHint(hint: string): any {\n const rule = this.getRuleInstance();\n\n const OPERATORS = `${EQUALS}|${INCLUDES}|${NOT_EQUALS}|${NOT_INCLUDES}|${NOT_IS_EMPTY}|${IS_EMPTY}`;\n const regex = new RegExp(\n `${DEPENDENT_ATTRIBUTE}\\\\s?(\\\\S*)\\\\swhen ${DEPENDENT_ATTRIBUTE_CONTROL}:\\\\s?(.*?)\\\\s*(${OPERATORS})\\\\s(.*)`,\n \"i\"\n );\n const isEmpyNotIsEmptRegex = new RegExp(\n `${DEPENDENT_ATTRIBUTE}\\\\s?(\\\\S*)\\\\swhen ${DEPENDENT_ATTRIBUTE_CONTROL}:\\\\s?(.*?)\\\\s*(${OPERATORS})`,\n \"i\"\n );\n\n const result = hint.match(regex)\n ? hint.match(regex)\n : hint.match(isEmpyNotIsEmptRegex);\n\n if (result) {\n rule.action = result[1];\n rule.control = result[2];\n rule.operator = result[3];\n rule.options = !result[4] ? \"\" : result[4];\n } else {\n throw new ConfigurationException(\n `No dependent information found on layout hint: ${hint}`\n );\n }\n\n return rule;\n }\n\n /**\n */\n get action(): string {\n return this._action;\n }\n\n /**\n */\n set action(action: string) {\n this._action = action;\n }\n\n /**\n */\n get control(): string {\n return this._control;\n }\n\n /**\n */\n set control(control: string) {\n this._control = control;\n }\n\n /**\n */\n get operator(): string {\n return this._operator;\n }\n\n /**\n */\n set operator(operator: string) {\n this._operator = operator;\n }\n\n /**\n */\n get options(): Array<string> {\n return this._options;\n }\n\n /**\n */\n set options(options: string): void {\n this._options = options.split(\"|\").map((option) => option.trim());\n }\n\n /**\n */\n processEqualsOptions(\n controlAttribute: ChoiceAttributeModel | BooleanAttributeModel\n ): boolean {\n if (\n controlAttribute instanceof ChoiceAttributeModel ||\n controlAttribute instanceof BooleanAttributeModel\n ) {\n return this.options.every((option) =>\n controlAttribute.selected.includes(option)\n );\n }\n\n throw new ConfigurationException(\n \"Dependent control in combination with equals operator must be a choice, string or number attribute\"\n );\n }\n\n /**\n */\n processIncludesOptions(\n controlAttribute: ChoiceAttributeModel | BooleanAttributeModel\n ): boolean {\n if (controlAttribute instanceof ChoiceAttributeModel) {\n return this.options.some((option) =>\n controlAttribute.selected.includes(option)\n );\n }\n\n throw new ConfigurationException(\n \"Dependent control in combination with includes operator must be a choice attribute\"\n );\n }\n\n /**\n */\n handleOperator(\n controlAttribute: ChoiceAttributeModel | BooleanAttributeModel\n ): boolean {\n switch (this.operator) {\n case EQUALS:\n return this.processEqualsOptions(controlAttribute);\n case INCLUDES:\n return this.processIncludesOptions(controlAttribute);\n case NOT_EQUALS:\n return !this.processEqualsOptions(controlAttribute);\n case NOT_INCLUDES:\n return !this.processIncludesOptions(controlAttribute);\n case NOT_IS_EMPTY:\n return controlAttribute?.selected.length !== 0;\n case IS_EMPTY:\n return controlAttribute?.selected.length === 0;\n default:\n throw new ConfigurationException(\n `Unsupported operator for dependent question: ${this.operator}`\n );\n }\n }\n\n /**\n */\n getControlAttribute(\n attributes: AttributeCollection\n ): ChoiceAttributeModel | BooleanAttributeModel | null {\n const attribute = attributes.getAttributeByLayoutHint(\n `${DEPENDENT_ATTRIBUTE_CONTROL}:${this.control}`,\n `${DEPENDENT_ATTRIBUTE_CONTROL}: ${this.control}`\n );\n\n if (\n attribute instanceof ChoiceAttributeModel ||\n attribute instanceof BooleanAttributeModel\n ) {\n return attribute;\n }\n\n return null;\n }\n\n /**\n */\n process(attribute: AttributeModel, attributes: AttributeCollection) {\n const controlAttribute = this.getControlAttribute(attributes);\n if (!controlAttribute) {\n return;\n }\n\n controlAttribute.processLayoutHintRules(attributes);\n if (controlAttribute.isHidden) {\n attribute.hide();\n return;\n }\n\n const result = this.handleOperator(controlAttribute);\n if (this.action === SHOW) {\n attribute.isHidden = !result;\n } else if (this.action === HIDE) {\n attribute.isHidden = result;\n } else {\n throw new ConfigurationException(\n `Unsupported action ${this.action} for dependent question on attribute: ${attribute.label}`\n );\n }\n }\n}\n\nexport default DependentAttribute;\n"],"mappings":";;;;;;;;;;;AACA;AAEA;AAKA;AACA;AAEA;AAKA,MAAMA,MAAM,GAAG,QAAQ;AACvB,MAAMC,QAAQ,GAAG,UAAU;AAC3B,MAAMC,UAAU,GAAG,WAAW;AAC9B,MAAMC,YAAY,GAAG,aAAa;AAClC,MAAMC,YAAY,GAAG,YAAY;AACjC,MAAMC,QAAQ,GAAG,SAAS;AAE1B,MAAMC,IAAI,GAAG,MAAM;AACnB,MAAMC,IAAI,GAAG,MAAM;;AAEnB;AACA;AACA;AACA,MAAMC,kBAAkB,SAASC,2BAAkB,CAAC;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAUlD;AACF;EACE,OAAOC,mBAAmB,CAACC,IAAY,EAAW;IAChD,MAAMC,KAAK,GAAG,IAAIC,MAAM,CACrB,IAAGC,8BAAoB,QAAOR,IAAK,IAAGC,IAAK,GAAE,EAC9C,GAAG,CACJ;IAED,OAAOK,KAAK,CAACG,IAAI,CAACJ,IAAI,CAAC;EACzB;;EAEA;AACF;AACA;EACE,OAAOK,eAAe,GAAuB;IAC3C,OAAO,IAAIR,kBAAkB,EAAE;EACjC;;EAEA;AACF;EACE,OAAOS,QAAQ,CAACN,IAAY,EAAO;IACjC,MAAMO,IAAI,GAAG,IAAI,CAACF,eAAe,EAAE;IAEnC,MAAMG,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CAAC7B,MAAM;IAC9B,CAAC,MAAM,IAAI,IAAI,CAACE,MAAM,KAAKjB,IAAI,EAAE;MAC/BwC,SAAS,CAACI,QAAQ,GAAG7B,MAAM;IAC7B,CAAC,MAAM;MACL,MAAM,IAAIM,kCAAsB,CAC7B,sBAAqB,IAAI,CAACJ,MAAO,yCAAwCuB,SAAS,CAACM,KAAM,EAAC,CAC5F;IACH;EACF;AACF;AAAC,8BAtNK7C,kBAAkB,4BAQmB,IAAI;AAAA,eAgNhCA,kBAAkB;AAAA"}
@@ -10,7 +10,6 @@ var _BaseLayoutHintRule = _interopRequireDefault(require("./BaseLayoutHintRule")
10
10
  var _DependentAttribute = _interopRequireDefault(require("./DependentAttribute"));
11
11
  var _RemainingTotalUploadSize = _interopRequireDefault(require("./RemainingTotalUploadSize"));
12
12
  var _exceptions = require("../../../exceptions");
13
-
14
13
  /**
15
14
  * Array of available layout hint rules
16
15
  * @private
@@ -1 +1 @@
1
- {"version":3,"file":"LayoutHintRuleCollection.js","names":["layoutHintRules","DependentAttribute","RemainingTotalUploadSize","addLayoutHintRule","rule","push","updateLayoutHintRules","updater","newRules","Array","isArray","IllegalReturnException","LayoutHintRuleCollection","BaseCollection","allRules","setLayoutHintRules","attribute","rules","forEach","isApplicableForAttribute","checkHintApplicability","layouthint","hint","isApplicableForHint","add","initHint","initAttribute","process","attributes","all"],"sources":["../../../../src/models/attributes/layouthint-rules/LayoutHintRuleCollection.js"],"sourcesContent":["// @flow\nimport BaseCollection from \"../../base/BaseCollection\";\n\nimport BaseLayoutHintRule from \"./BaseLayoutHintRule\";\n\nimport DependentAttribute from \"./DependentAttribute\";\nimport RemainingTotalUploadSize from \"./RemainingTotalUploadSize\";\n\nimport { IllegalReturnException } from \"../../../exceptions\";\n\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type { AttributeType, ILayoutHintRule } from \"../../types\";\nimport type AttributeModel from \"../AttributeModel\";\n\n/**\n * Array of available layout hint rules\n * @private\n */\nlet layoutHintRules: Array<Class<BaseLayoutHintRule>> = [\n DependentAttribute,\n RemainingTotalUploadSize,\n];\n\n/**\n * Add custom layout hint rules\n */\nexport const addLayoutHintRule = (rule: Class<BaseLayoutHintRule>) => {\n layoutHintRules.push(rule);\n};\n\ntype LayoutHintRulesUpdater = (\n rules: Array<Class<BaseLayoutHintRule>>\n) => Array<Class<BaseLayoutHintRule>>;\n\n/**\n * Update existing array of layout hint rules, use this to update or remove standard rules\n *\n * @example\n * // remove RemainingTotalUploadSize rule\n * updateLayoutHintRules((rules) => {\n * return rules.filter(rule => rule !== RemainingTotalUploadSize));\n * });\n */\nexport const updateLayoutHintRules = (updater: LayoutHintRulesUpdater) => {\n const newRules = updater(layoutHintRules);\n if (Array.isArray(newRules)) {\n layoutHintRules = newRules;\n } else {\n throw new IllegalReturnException(\n \"Result of updater of updateLayoutHintRules is not an array\"\n );\n }\n};\n\n/**\n * Collection of layout hint rules\n */\nclass LayoutHintRuleCollection extends BaseCollection<ILayoutHintRule> {\n /**\n * Retrieve all rules available in the collection\n */\n get allRules(): Array<Class<BaseLayoutHintRule>> {\n return layoutHintRules;\n }\n\n /**\n * Set layout hint rules on the applicable attributes\n */\n static setLayoutHintRules<T: AttributeType>(attribute: T): T {\n const rules = new LayoutHintRuleCollection();\n\n layoutHintRules.forEach((rule) => {\n if (rule.isApplicableForAttribute(attribute)) {\n if (rule.checkHintApplicability) {\n attribute.layouthint.forEach((hint) => {\n if (rule.isApplicableForHint(hint)) {\n rules.add(rule.initHint(hint));\n }\n });\n } else {\n rules.add(rule.initAttribute(attribute));\n }\n }\n });\n\n attribute.layoutHintRules = rules;\n\n return attribute;\n }\n\n /**\n * Process layout hint rules in the collection\n */\n process(attribute: AttributeModel, attributes: AttributeCollection) {\n this.all.forEach((rule) => {\n rule.process(attribute, attributes);\n });\n }\n}\n\nexport default LayoutHintRuleCollection;\n"],"mappings":";;;;;;;AACA;AAEA;AAEA;AACA;AAEA;;AAMA;AACA;AACA;AACA;AACA,IAAIA,eAAiD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B,KAAK;IAEjC,OAAOD,SAAS;EAClB;;EAEA;AACF;AACA;EACEW,OAAO,CAACX,SAAyB,EAAEY,UAA+B,EAAE;IAClE,IAAI,CAACC,GAAG,CAACX,OAAO,CAAEd,IAAI,IAAK;MACzBA,IAAI,CAACuB,OAAO,CAACX,SAAS,EAAEY,UAAU,CAAC;IACrC,CAAC,CAAC;EACJ;AACF;AAAC,eAEchB,wBAAwB;AAAA"}
1
+ {"version":3,"file":"LayoutHintRuleCollection.js","names":["layoutHintRules","DependentAttribute","RemainingTotalUploadSize","addLayoutHintRule","rule","push","updateLayoutHintRules","updater","newRules","Array","isArray","IllegalReturnException","LayoutHintRuleCollection","BaseCollection","allRules","setLayoutHintRules","attribute","rules","forEach","isApplicableForAttribute","checkHintApplicability","layouthint","hint","isApplicableForHint","add","initHint","initAttribute","process","attributes","all"],"sources":["../../../../src/models/attributes/layouthint-rules/LayoutHintRuleCollection.js"],"sourcesContent":["// @flow\nimport BaseCollection from \"../../base/BaseCollection\";\n\nimport BaseLayoutHintRule from \"./BaseLayoutHintRule\";\n\nimport DependentAttribute from \"./DependentAttribute\";\nimport RemainingTotalUploadSize from \"./RemainingTotalUploadSize\";\n\nimport { IllegalReturnException } from \"../../../exceptions\";\n\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type { AttributeType, ILayoutHintRule } from \"../../types\";\nimport type AttributeModel from \"../AttributeModel\";\n\n/**\n * Array of available layout hint rules\n * @private\n */\nlet layoutHintRules: Array<Class<BaseLayoutHintRule>> = [\n DependentAttribute,\n RemainingTotalUploadSize,\n];\n\n/**\n * Add custom layout hint rules\n */\nexport const addLayoutHintRule = (rule: Class<BaseLayoutHintRule>) => {\n layoutHintRules.push(rule);\n};\n\ntype LayoutHintRulesUpdater = (\n rules: Array<Class<BaseLayoutHintRule>>\n) => Array<Class<BaseLayoutHintRule>>;\n\n/**\n * Update existing array of layout hint rules, use this to update or remove standard rules\n *\n * @example\n * // remove RemainingTotalUploadSize rule\n * updateLayoutHintRules((rules) => {\n * return rules.filter(rule => rule !== RemainingTotalUploadSize));\n * });\n */\nexport const updateLayoutHintRules = (updater: LayoutHintRulesUpdater) => {\n const newRules = updater(layoutHintRules);\n if (Array.isArray(newRules)) {\n layoutHintRules = newRules;\n } else {\n throw new IllegalReturnException(\n \"Result of updater of updateLayoutHintRules is not an array\"\n );\n }\n};\n\n/**\n * Collection of layout hint rules\n */\nclass LayoutHintRuleCollection extends BaseCollection<ILayoutHintRule> {\n /**\n * Retrieve all rules available in the collection\n */\n get allRules(): Array<Class<BaseLayoutHintRule>> {\n return layoutHintRules;\n }\n\n /**\n * Set layout hint rules on the applicable attributes\n */\n static setLayoutHintRules<T: AttributeType>(attribute: T): T {\n const rules = new LayoutHintRuleCollection();\n\n layoutHintRules.forEach((rule) => {\n if (rule.isApplicableForAttribute(attribute)) {\n if (rule.checkHintApplicability) {\n attribute.layouthint.forEach((hint) => {\n if (rule.isApplicableForHint(hint)) {\n rules.add(rule.initHint(hint));\n }\n });\n } else {\n rules.add(rule.initAttribute(attribute));\n }\n }\n });\n\n attribute.layoutHintRules = rules;\n\n return attribute;\n }\n\n /**\n * Process layout hint rules in the collection\n */\n process(attribute: AttributeModel, attributes: AttributeCollection) {\n this.all.forEach((rule) => {\n rule.process(attribute, attributes);\n });\n }\n}\n\nexport default LayoutHintRuleCollection;\n"],"mappings":";;;;;;;AACA;AAEA;AAEA;AACA;AAEA;AAMA;AACA;AACA;AACA;AACA,IAAIA,eAAiD,GAAG,CACtDC,2BAAkB,EAClBC,iCAAwB,CACzB;;AAED;AACA;AACA;AACO,MAAMC,iBAAiB,GAAIC,IAA+B,IAAK;EACpEJ,eAAe,CAACK,IAAI,CAACD,IAAI,CAAC;AAC5B,CAAC;AAAC;AAMF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAME,qBAAqB,GAAIC,OAA+B,IAAK;EACxE,MAAMC,QAAQ,GAAGD,OAAO,CAACP,eAAe,CAAC;EACzC,IAAIS,KAAK,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Rule = _interopRequireDefault(require("./BaseLayoutHintRule"));
9
9
  var _UploadAttributeModel = _interopRequireDefault(require("../UploadAttributeModel"));
10
10
  var _constants = require("../../../constants");
11
-
12
11
  /**
13
12
  * This pattern enables showing the upload file size remaining when uploading resources<br>
14
13
  * The rule depends on other attributes with the INITIAL_TOTAL_FILESIZE and MAX_TOTAL_FILESIZE layout hints
@@ -1 +1 @@
1
- {"version":3,"file":"RemainingTotalUploadSize.js","names":["RemainingTotalUploadSize","BaseLayoutHintRule","isApplicableForAttribute","attribute","UploadAttributeModel","initAttribute","processUploadInformation","attributes","uploadInformationAttributes","getAttributesByLayoutHint","INITIAL_TOTAL_FILESIZE","MAX_TOTAL_FILESIZE","length","firstHasInitialTotalFileSize","layouthint","has","initialTotalFileSize","value","maxTotalFileSize","process"],"sources":["../../../../src/models/attributes/layouthint-rules/RemainingTotalUploadSize.js"],"sourcesContent":["// @flow\nimport BaseLayoutHintRule from \"./BaseLayoutHintRule\";\n\nimport UploadAttributeModel from \"../UploadAttributeModel\";\n\nimport { INITIAL_TOTAL_FILESIZE, MAX_TOTAL_FILESIZE } from \"../../../constants\";\n\nimport type { AttributeType, ILayoutHintRule } from \"../../types\";\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type AttributeModel from \"../AttributeModel\";\n\n/**\n * This pattern enables showing the upload file size remaining when uploading resources<br>\n * The rule depends on other attributes with the INITIAL_TOTAL_FILESIZE and MAX_TOTAL_FILESIZE layout hints\n */\nclass RemainingTotalUploadSize extends BaseLayoutHintRule {\n /**\n */\n static isApplicableForAttribute(attribute: AttributeType): boolean {\n return attribute instanceof UploadAttributeModel;\n }\n\n /**\n */\n static initAttribute(): ILayoutHintRule {\n return new RemainingTotalUploadSize();\n }\n\n /**\n */\n processUploadInformation(\n attribute: UploadAttributeModel,\n attributes: AttributeCollection\n ) {\n const uploadInformationAttributes = attributes.getAttributesByLayoutHint(\n INITIAL_TOTAL_FILESIZE,\n MAX_TOTAL_FILESIZE\n );\n\n if (uploadInformationAttributes.length === 2) {\n const firstHasInitialTotalFileSize =\n uploadInformationAttributes[0].layouthint.has(INITIAL_TOTAL_FILESIZE);\n\n const initialTotalFileSize = firstHasInitialTotalFileSize\n ? uploadInformationAttributes[0].value\n : uploadInformationAttributes[1].value;\n\n const maxTotalFileSize = firstHasInitialTotalFileSize\n ? uploadInformationAttributes[1].value\n : uploadInformationAttributes[0].value;\n\n attribute.initialTotalFileSize = initialTotalFileSize;\n attribute.maxTotalFileSize = maxTotalFileSize;\n }\n }\n\n /**\n * Sets tresholds for initial and maximum upload file size\n */\n process(attribute: AttributeModel, attributes: AttributeCollection): void {\n if (attribute instanceof UploadAttributeModel) {\n this.processUploadInformation(attribute, attributes);\n }\n }\n}\n\nexport default RemainingTotalUploadSize;\n"],"mappings":";;;;;;;AACA;AAEA;AAEA;;AAMA;AACA;AACA;AACA;AACA,MAAMA,wBAAwB,SAASC,2BAAkB,CAAC;EACxD;AACF;EACE,OAAOC,wBAAwB,CAACC,SAAwB,EAAW;IACjE,OAAOA,SAAS,YAAYC,6BAAoB;EAClD;;EAEA;AACF;EACE,OAAOC,aAAa,GAAoB;IACtC,OAAO,IAAIL,wBAAwB,EAAE;EACvC;;EAEA;AACF;EACEM,wBAAwB,CACtBH,SAA+B,EAC/BI,UAA+B,EAC/B;IACA,MAAMC,2BAA2B,GAAGD,UAAU,CAACE,yBAAyB,CACtEC,iCAAsB,EACtBC,6BAAkB,CACnB;IAED,IAAIH,2BAA2B,CAACI,MAAM,KAAK,CAAC,EAAE;MAC5C,MAAMC,4BAA4B,GAChCL,2BAA2B,CAAC,CAAC,CAAC,CAACM,UAAU,CAACC,GAAG,CAACL,iCAAsB,CAAC;MAEvE,MAAMM,oBAAoB,GAAGH,4BAA4B,GACrDL,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK,GACpCT,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK;MAExC,MAAMC,gBAAgB,GAAGL,4BAA4B,GACjDL,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK,GACpCT,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK;MAExCd,SAAS,CAACa,oBAAoB,GAAGA,oBAAoB;MACrDb,SAAS,CAACe,gBAAgB,GAAGA,gBAAgB;IAC/C;EACF;;EAEA;AACF;AACA;EACEC,OAAO,CAAChB,SAAyB,EAAEI,UAA+B,EAAQ;IACxE,IAAIJ,SAAS,YAAYC,6BAAoB,EAAE;MAC7C,IAAI,CAACE,wBAAwB,CAACH,SAAS,EAAEI,UAAU,CAAC;IACtD;EACF;AACF;AAAC,eAEcP,wBAAwB;AAAA"}
1
+ {"version":3,"file":"RemainingTotalUploadSize.js","names":["RemainingTotalUploadSize","BaseLayoutHintRule","isApplicableForAttribute","attribute","UploadAttributeModel","initAttribute","processUploadInformation","attributes","uploadInformationAttributes","getAttributesByLayoutHint","INITIAL_TOTAL_FILESIZE","MAX_TOTAL_FILESIZE","length","firstHasInitialTotalFileSize","layouthint","has","initialTotalFileSize","value","maxTotalFileSize","process"],"sources":["../../../../src/models/attributes/layouthint-rules/RemainingTotalUploadSize.js"],"sourcesContent":["// @flow\nimport BaseLayoutHintRule from \"./BaseLayoutHintRule\";\n\nimport UploadAttributeModel from \"../UploadAttributeModel\";\n\nimport { INITIAL_TOTAL_FILESIZE, MAX_TOTAL_FILESIZE } from \"../../../constants\";\n\nimport type { AttributeType, ILayoutHintRule } from \"../../types\";\nimport type AttributeCollection from \"../AttributeCollection\";\nimport type AttributeModel from \"../AttributeModel\";\n\n/**\n * This pattern enables showing the upload file size remaining when uploading resources<br>\n * The rule depends on other attributes with the INITIAL_TOTAL_FILESIZE and MAX_TOTAL_FILESIZE layout hints\n */\nclass RemainingTotalUploadSize extends BaseLayoutHintRule {\n /**\n */\n static isApplicableForAttribute(attribute: AttributeType): boolean {\n return attribute instanceof UploadAttributeModel;\n }\n\n /**\n */\n static initAttribute(): ILayoutHintRule {\n return new RemainingTotalUploadSize();\n }\n\n /**\n */\n processUploadInformation(\n attribute: UploadAttributeModel,\n attributes: AttributeCollection\n ) {\n const uploadInformationAttributes = attributes.getAttributesByLayoutHint(\n INITIAL_TOTAL_FILESIZE,\n MAX_TOTAL_FILESIZE\n );\n\n if (uploadInformationAttributes.length === 2) {\n const firstHasInitialTotalFileSize =\n uploadInformationAttributes[0].layouthint.has(INITIAL_TOTAL_FILESIZE);\n\n const initialTotalFileSize = firstHasInitialTotalFileSize\n ? uploadInformationAttributes[0].value\n : uploadInformationAttributes[1].value;\n\n const maxTotalFileSize = firstHasInitialTotalFileSize\n ? uploadInformationAttributes[1].value\n : uploadInformationAttributes[0].value;\n\n attribute.initialTotalFileSize = initialTotalFileSize;\n attribute.maxTotalFileSize = maxTotalFileSize;\n }\n }\n\n /**\n * Sets tresholds for initial and maximum upload file size\n */\n process(attribute: AttributeModel, attributes: AttributeCollection): void {\n if (attribute instanceof UploadAttributeModel) {\n this.processUploadInformation(attribute, attributes);\n }\n }\n}\n\nexport default RemainingTotalUploadSize;\n"],"mappings":";;;;;;;AACA;AAEA;AAEA;AAMA;AACA;AACA;AACA;AACA,MAAMA,wBAAwB,SAASC,2BAAkB,CAAC;EACxD;AACF;EACE,OAAOC,wBAAwB,CAACC,SAAwB,EAAW;IACjE,OAAOA,SAAS,YAAYC,6BAAoB;EAClD;;EAEA;AACF;EACE,OAAOC,aAAa,GAAoB;IACtC,OAAO,IAAIL,wBAAwB,EAAE;EACvC;;EAEA;AACF;EACEM,wBAAwB,CACtBH,SAA+B,EAC/BI,UAA+B,EAC/B;IACA,MAAMC,2BAA2B,GAAGD,UAAU,CAACE,yBAAyB,CACtEC,iCAAsB,EACtBC,6BAAkB,CACnB;IAED,IAAIH,2BAA2B,CAACI,MAAM,KAAK,CAAC,EAAE;MAC5C,MAAMC,4BAA4B,GAChCL,2BAA2B,CAAC,CAAC,CAAC,CAACM,UAAU,CAACC,GAAG,CAACL,iCAAsB,CAAC;MAEvE,MAAMM,oBAAoB,GAAGH,4BAA4B,GACrDL,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK,GACpCT,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK;MAExC,MAAMC,gBAAgB,GAAGL,4BAA4B,GACjDL,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK,GACpCT,2BAA2B,CAAC,CAAC,CAAC,CAACS,KAAK;MAExCd,SAAS,CAACa,oBAAoB,GAAGA,oBAAoB;MACrDb,SAAS,CAACe,gBAAgB,GAAGA,gBAAgB;IAC/C;EACF;;EAEA;AACF;AACA;EACEC,OAAO,CAAChB,SAAyB,EAAEI,UAA+B,EAAQ;IACxE,IAAIJ,SAAS,YAAYC,6BAAoB,EAAE;MAC7C,IAAI,CAACE,wBAAwB,CAACH,SAAS,EAAEI,UAAU,CAAC;IACtD;EACF;AACF;AAAC,eAEcP,wBAAwB;AAAA"}
@@ -13,7 +13,6 @@ var _sort = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stabl
13
13
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
14
14
  var _clone = _interopRequireDefault(require("lodash/clone"));
15
15
  var _cloneDeep = _interopRequireDefault(require("lodash/cloneDeep"));
16
-
17
16
  /**
18
17
  * Base class for collections of models
19
18
  */
@@ -1 +1 @@
1
- {"version":3,"file":"BaseCollection.js","names":["BaseCollection","constructor","initCollection","collection","_collection","add","items","all","Array","isArray","removeByIndex","itemIndex","hasItems","length","isEmpty","size","first","last","get","index","find","callbackfn","thisArg","filter","some","every","map","forEach","sort","compareFn","sorted","clone","deepcopy","cloneDeep"],"sources":["../../../src/models/base/BaseCollection.js"],"sourcesContent":["// @flow\nimport clone from \"lodash/clone\";\nimport cloneDeep from \"lodash/cloneDeep\";\n\n/**\n * Base class for collections of models\n */\nclass BaseCollection<T> {\n _collection: Array<T>;\n\n /**\n * Construct base collection\n */\n constructor(initCollection: Array<T> = []) {\n this.collection = initCollection;\n }\n\n /**\n * Retrieve current collection\n */\n get collection(): Array<T> {\n return this._collection;\n }\n\n /**\n * Replace current collection with a new collection\n */\n set collection(collection: Array<T>) {\n this._collection = collection;\n }\n\n /**\n * Add an other collection, array of items or single item to this collection;\n */\n add(items: BaseCollection<T> | Array<T> | T): BaseCollection<T> {\n if (items instanceof BaseCollection) {\n this.collection = [...this.collection, ...items.all];\n } else if (Array.isArray(items)) {\n // $FlowExpectedError[incompatible-type]\n this.collection = [...this.collection, ...items];\n } else {\n this.collection = [...this.collection, items];\n }\n\n return this;\n }\n\n /**\n * Remove an item from the collection by it's index.\n */\n removeByIndex(itemIndex: number) {\n if (itemIndex > -1) {\n this.collection = [\n ...this.collection.slice(0, itemIndex),\n ...this.collection.slice(itemIndex + 1),\n ];\n }\n }\n\n /**\n * Indicates if the collection has items\n */\n get hasItems(): boolean {\n return this.length > 0;\n }\n\n /**\n * Indicates if collection is empty\n */\n get isEmpty(): boolean {\n return !this.hasItems;\n }\n\n /**\n * Retrieve all items in collection\n */\n get all(): Array<T> {\n return this.collection;\n }\n\n /**\n * Get the size of this collection\n */\n get size(): number {\n return this.length;\n }\n\n /**\n * Get the size of this collection\n */\n get length(): number {\n return this.collection.length;\n }\n\n /**\n * Return first link in collection\n */\n get first(): T | null {\n return this.collection[0] ?? null;\n }\n\n /**\n */\n get last(): T | null {\n return this.collection[this.collection.length - 1] ?? null;\n }\n\n /**\n */\n get(index: number): T | null {\n return this.collection[index] ?? null;\n }\n\n /**\n * Find item\n */\n find(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): T | null {\n return this.collection.find(callbackfn, thisArg) ?? null;\n }\n\n /**\n * Filter items\n */\n filter(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): Array<T> {\n return this.collection.filter(callbackfn, thisArg);\n }\n\n /**\n * Check if at least one item occurs\n */\n some(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): boolean {\n return this.collection.some(callbackfn, thisArg);\n }\n\n /**\n */\n every(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): boolean {\n return this.collection.every(callbackfn, thisArg);\n }\n\n /**\n */\n map<U>(\n callbackfn: (value: T, index: number, array: Array<T>) => U,\n thisArg?: T\n ): Array<U> {\n return this.collection.map<U, ?T>(callbackfn, thisArg);\n }\n\n /**\n */\n forEach(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ) {\n this.collection.forEach(callbackfn, thisArg);\n }\n\n /**\n */\n sort(compareFn?: (a: T, b: T) => number): Array<T> {\n return this.collection.sort(compareFn);\n }\n\n /**\n * Retrieve an alphabetically sorted array of items\n */\n get sorted(): Array<T> {\n return this.collection.sort();\n }\n\n /**\n * Returns a clone of the model (this is not a deep copy)\n */\n clone(deepcopy: boolean = false): this {\n // deepcopy can be expensive, use with care!\n if (deepcopy) {\n return cloneDeep(this);\n }\n\n return clone(this);\n }\n}\n\nexport default BaseCollection;\n"],"mappings":";;;;;;;;;;;;;AACA;AACA;;AAEA;AACA;AACA;AACA,MAAMA,cAAc,CAAI;EAGtB;AACF;AACA;EACEC,WAAW,GAAgC;IAAA,IAA/BC,cAAwB,uEAAG,EAAE;IAAA;IACvC,IAAI,CAACC,UAAU,GAAGD,cAAc;EAClC;;EAEA;AACF;AACA;EACE,IAAIC,UAAU,GAAa;IACzB,OAAO,IAAI,CAACC,WAAW;EACzB;;EAEA;AACF;AACA;EACE,IAAID,UAAU,CAACA,UAAoB,EAAE;IACnC,IAAI,CAACC,WAAW,GAAGD,UAAU;EAC/B;;EAEA;AACF;AACA;EACEE,GAAG,CAACC,KAAuC,EAAqB;IAC9D,IAAIA,KAAK,YAAYN,cAAc,EAAE;MACnC,IAAI,CAACG,UAAU,GAAG,CAAC,GAAG,IAAI,CAACA,UAAU,EAAE,GAAGG,KAAK,CAACC,GAAG,CAAC;IACtD,CAAC,MAAM,IAAIC,KAAK,CAACC,OAAO,CAACH,KAAK,CAAC,EAAE;MAC/B;MACA,IAAI,CAACH,UAAU,GAAG,CAAC,GAAG,IA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AC;EACpB;AACF;AAAC,eAEc/B,cAAc;AAAA"}
1
+ {"version":3,"file":"BaseCollection.js","names":["BaseCollection","constructor","initCollection","collection","_collection","add","items","all","Array","isArray","removeByIndex","itemIndex","hasItems","length","isEmpty","size","first","last","get","index","find","callbackfn","thisArg","filter","some","every","map","forEach","sort","compareFn","sorted","clone","deepcopy","cloneDeep"],"sources":["../../../src/models/base/BaseCollection.js"],"sourcesContent":["// @flow\nimport clone from \"lodash/clone\";\nimport cloneDeep from \"lodash/cloneDeep\";\n\n/**\n * Base class for collections of models\n */\nclass BaseCollection<T> {\n _collection: Array<T>;\n\n /**\n * Construct base collection\n */\n constructor(initCollection: Array<T> = []) {\n this.collection = initCollection;\n }\n\n /**\n * Retrieve current collection\n */\n get collection(): Array<T> {\n return this._collection;\n }\n\n /**\n * Replace current collection with a new collection\n */\n set collection(collection: Array<T>) {\n this._collection = collection;\n }\n\n /**\n * Add an other collection, array of items or single item to this collection;\n */\n add(items: BaseCollection<T> | Array<T> | T): BaseCollection<T> {\n if (items instanceof BaseCollection) {\n this.collection = [...this.collection, ...items.all];\n } else if (Array.isArray(items)) {\n // $FlowExpectedError[incompatible-type]\n this.collection = [...this.collection, ...items];\n } else {\n this.collection = [...this.collection, items];\n }\n\n return this;\n }\n\n /**\n * Remove an item from the collection by it's index.\n */\n removeByIndex(itemIndex: number) {\n if (itemIndex > -1) {\n this.collection = [\n ...this.collection.slice(0, itemIndex),\n ...this.collection.slice(itemIndex + 1),\n ];\n }\n }\n\n /**\n * Indicates if the collection has items\n */\n get hasItems(): boolean {\n return this.length > 0;\n }\n\n /**\n * Indicates if collection is empty\n */\n get isEmpty(): boolean {\n return !this.hasItems;\n }\n\n /**\n * Retrieve all items in collection\n */\n get all(): Array<T> {\n return this.collection;\n }\n\n /**\n * Get the size of this collection\n */\n get size(): number {\n return this.length;\n }\n\n /**\n * Get the size of this collection\n */\n get length(): number {\n return this.collection.length;\n }\n\n /**\n * Return first link in collection\n */\n get first(): T | null {\n return this.collection[0] ?? null;\n }\n\n /**\n */\n get last(): T | null {\n return this.collection[this.collection.length - 1] ?? null;\n }\n\n /**\n */\n get(index: number): T | null {\n return this.collection[index] ?? null;\n }\n\n /**\n * Find item\n */\n find(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): T | null {\n return this.collection.find(callbackfn, thisArg) ?? null;\n }\n\n /**\n * Filter items\n */\n filter(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): Array<T> {\n return this.collection.filter(callbackfn, thisArg);\n }\n\n /**\n * Check if at least one item occurs\n */\n some(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): boolean {\n return this.collection.some(callbackfn, thisArg);\n }\n\n /**\n */\n every(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ): boolean {\n return this.collection.every(callbackfn, thisArg);\n }\n\n /**\n */\n map<U>(\n callbackfn: (value: T, index: number, array: Array<T>) => U,\n thisArg?: T\n ): Array<U> {\n return this.collection.map<U, ?T>(callbackfn, thisArg);\n }\n\n /**\n */\n forEach(\n callbackfn: (value: T, index: number, array: Array<T>) => any,\n thisArg?: any\n ) {\n this.collection.forEach(callbackfn, thisArg);\n }\n\n /**\n */\n sort(compareFn?: (a: T, b: T) => number): Array<T> {\n return this.collection.sort(compareFn);\n }\n\n /**\n * Retrieve an alphabetically sorted array of items\n */\n get sorted(): Array<T> {\n return this.collection.sort();\n }\n\n /**\n * Returns a clone of the model (this is not a deep copy)\n */\n clone(deepcopy: boolean = false): this {\n // deepcopy can be expensive, use with care!\n if (deepcopy) {\n return cloneDeep(this);\n }\n\n return clone(this);\n }\n}\n\nexport default BaseCollection;\n"],"mappings":";;;;;;;;;;;;;AACA;AACA;AAEA;AACA;AACA;AACA,MAAMA,cAAc,CAAI;EAGtB;AACF;AACA;EACEC,WAAW,GAAgC;IAAA,IAA/BC,cAAwB,uEAAG,EAAE;IAAA;IACvC,IAAI,CAACC,UAAU,G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