@k-int/stripes-kint-components 4.3.0 → 4.4.0

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 (249) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/es/index.js +17 -4
  3. package/es/lib/ActionList/ActionList.js +5 -4
  4. package/es/lib/ActionList/ActionListFieldArray.js +7 -4
  5. package/es/lib/CustomProperties/Config/CustomPropertiesLookup.js +2 -2
  6. package/es/lib/CustomProperties/Config/CustomPropertiesSettings.js +22 -24
  7. package/es/lib/CustomProperties/Config/CustomPropertiesSettings.test.js +26 -32
  8. package/es/lib/CustomProperties/Config/CustomPropertyForm.js +3 -3
  9. package/es/lib/CustomProperties/Config/CustomPropertyForm.test.js +39 -47
  10. package/es/lib/CustomProperties/Config/CustomPropertyView.test.js +82 -100
  11. package/es/lib/CustomProperties/Edit/CustomPropertiesListField.js +2 -2
  12. package/es/lib/CustomProperties/Edit/CustomPropertiesListField.test.js +22 -28
  13. package/es/lib/CustomProperties/Edit/CustomPropertyField.js +1 -1
  14. package/es/lib/CustomProperties/Edit/CustomPropertyField.test.js +69 -85
  15. package/es/lib/CustomProperties/Filter/CustomPropertiesFilter.js +2 -2
  16. package/es/lib/CustomProperties/Filter/CustomPropertiesFilter.test.js +26 -32
  17. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterField.js +3 -3
  18. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterFieldArray.test.js +15 -19
  19. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterForm.test.js +17 -21
  20. package/es/lib/CustomProperties/Filter/CustomPropertiesRule.js +1 -1
  21. package/es/lib/CustomProperties/Filter/CustomPropertiesRule.test.js +129 -161
  22. package/es/lib/CustomProperties/Filter/useParseActiveFilterStrings.js +2 -2
  23. package/es/lib/CustomProperties/Filter/useValueProps.js +1 -1
  24. package/es/lib/CustomProperties/View/CustomPropertiesViewCtx.js +2 -2
  25. package/es/lib/CycleButton/CycleButton.js +2 -2
  26. package/es/lib/EditableRefdataCategoryList/EditableRefdataCategoryList.js +45 -28
  27. package/es/lib/EditableRefdataList/EditableRefdataList.js +70 -50
  28. package/es/lib/EditableSettingsList/EditableSettingsListFieldArray.test.js +44 -50
  29. package/es/lib/EditableSettingsList/SettingField/EditSettingValue.js +1 -1
  30. package/es/lib/EditableSettingsList/SettingField/RenderSettingValue.test.js +139 -163
  31. package/es/lib/EditableSettingsList/SettingField/SettingField.js +9 -9
  32. package/es/lib/EditableSettingsList/SettingField/SettingField.test.js +117 -133
  33. package/es/lib/IconSelect/IconSelect.js +2 -2
  34. package/es/lib/QueryTypedown/QueryTypedown.js +2 -2
  35. package/es/lib/ResponsiveButtonGroup/ResponsiveButtonGroup.js +1 -1
  36. package/es/lib/ResponsiveButtonGroup/useResponsiveButtonGroupSizing.js +15 -5
  37. package/es/lib/RichSelect/RichSelect.js +2 -2
  38. package/es/lib/RichSelect/useSelectedOption.js +2 -2
  39. package/es/lib/SASQLookupComponent/SASQLookupComponent.js +2 -2
  40. package/es/lib/SettingPage/SettingPage.js +4 -2
  41. package/es/lib/Typedown/Typedown.js +6 -3
  42. package/es/lib/hooks/index.js +0 -19
  43. package/es/lib/hooks/typedownHooks/useTypedownData.js +2 -2
  44. package/es/lib/hooks/typedownHooks/useTypedownToggle.js +2 -2
  45. package/es/lib/hooks/useActiveElement.js +2 -2
  46. package/es/lib/hooks/useHelperApp.js +2 -2
  47. package/es/lib/hooks/useKiwtFieldArray.js +2 -2
  48. package/es/lib/hooks/useKiwtSASQuery.js +2 -2
  49. package/es/lib/hooks/useLocalStorageState.js +2 -2
  50. package/es/lib/hooks/useMutateCustomProperties.js +23 -29
  51. package/es/lib/hooks/useMutateRefdataCategory.js +21 -25
  52. package/es/lib/hooks/useMutateRefdataValue.js +30 -34
  53. package/es/lib/hooks/useQIndex.js +2 -2
  54. package/es/lib/hooks/useSASQQueryMeta.js +1 -1
  55. package/es/lib/{hooks/settingsHooks → settingsHooks}/index.js +0 -0
  56. package/es/lib/{hooks/settingsHooks → settingsHooks}/useAppSettings.js +2 -2
  57. package/es/lib/{hooks/settingsHooks → settingsHooks}/useSettingSection.js +1 -3
  58. package/es/lib/{hooks/settingsHooks → settingsHooks}/useSettings.js +7 -8
  59. package/es/lib/utils/generateKiwtQueryParams.js +2 -2
  60. package/es/lib/utils/groupCustomPropertiesByCtx.js +1 -1
  61. package/es/lib/utils/highlightString.js +2 -2
  62. package/es/lib/utils/index.js +0 -43
  63. package/es/lib/utils/parseErrorResponse.js +42 -44
  64. package/es/lib/validators/index.js +16 -0
  65. package/es/lib/{utils → validators}/validators.js +0 -0
  66. package/junit.xml +133 -133
  67. package/package.json +1 -1
  68. package/src/artifacts/coverage-jest/lcov-report/ActionList/ActionList.js.html +12 -3
  69. package/src/artifacts/coverage-jest/lcov-report/ActionList/ActionListFieldArray.js.html +53 -14
  70. package/src/artifacts/coverage-jest/lcov-report/ActionList/index.html +8 -8
  71. package/src/artifacts/coverage-jest/lcov-report/ActionList/index.js.html +1 -1
  72. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertiesLookup.js.html +1 -1
  73. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertiesSettings.js.html +1 -1
  74. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertyForm.js.html +2 -2
  75. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertyView.js.html +1 -1
  76. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/index.html +1 -1
  77. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/index.js.html +1 -1
  78. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertiesEdit.js.html +1 -1
  79. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertiesEditCtx.js.html +1 -1
  80. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertiesListField.js.html +1 -1
  81. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertyField.js.html +1 -1
  82. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertyFormCard.js.html +1 -1
  83. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/index.html +1 -1
  84. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/index.js.html +1 -1
  85. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/testResources.js.html +1 -1
  86. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilter.js.html +1 -1
  87. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilterField.js.html +2 -2
  88. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilterFieldArray.js.html +1 -1
  89. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilterForm.js.html +1 -1
  90. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesRule.js.html +2 -2
  91. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/index.html +1 -1
  92. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/index.js.html +1 -1
  93. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/testResources.js.html +1 -1
  94. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/useOperators.js.html +1 -1
  95. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/useParseActiveFilterStrings.js.html +1 -1
  96. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/useValueProps.js.html +2 -2
  97. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/CustomPropertiesView.js.html +1 -1
  98. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/CustomPropertiesViewCtx.js.html +1 -1
  99. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/CustomPropertyCard.js.html +1 -1
  100. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/index.html +1 -1
  101. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/index.js.html +1 -1
  102. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/testResources.js.html +1 -1
  103. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/index.html +1 -1
  104. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/index.js.html +1 -1
  105. package/src/artifacts/coverage-jest/lcov-report/CycleButton/CycleButton.js.html +1 -1
  106. package/src/artifacts/coverage-jest/lcov-report/CycleButton/index.html +1 -1
  107. package/src/artifacts/coverage-jest/lcov-report/CycleButton/index.js.html +1 -1
  108. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataCategoryList/EditableRefdataCategoryList.js.html +96 -9
  109. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataCategoryList/index.html +9 -9
  110. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataCategoryList/index.js.html +1 -1
  111. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataList/EditableRefdataList.js.html +152 -29
  112. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataList/index.html +9 -9
  113. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataList/index.js.html +1 -1
  114. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/EditableSettingsList.js.html +1 -1
  115. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/EditableSettingsListFieldArray.js.html +1 -1
  116. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/EditSettingValue.js.html +1 -1
  117. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/RenderSettingValue.js.html +1 -1
  118. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/SettingField.js.html +1 -1
  119. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/index.html +1 -1
  120. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/index.js.html +1 -1
  121. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/index.html +1 -1
  122. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/index.js.html +1 -1
  123. package/src/artifacts/coverage-jest/lcov-report/FormModal/FormModal.js.html +1 -1
  124. package/src/artifacts/coverage-jest/lcov-report/FormModal/index.html +1 -1
  125. package/src/artifacts/coverage-jest/lcov-report/FormModal/index.js.html +1 -1
  126. package/src/artifacts/coverage-jest/lcov-report/FormattedKintMessage/FormattedKintMessage.js.html +3 -3
  127. package/src/artifacts/coverage-jest/lcov-report/FormattedKintMessage/index.html +1 -1
  128. package/src/artifacts/coverage-jest/lcov-report/FormattedKintMessage/index.js.html +1 -1
  129. package/src/artifacts/coverage-jest/lcov-report/IconSelect/IconSelect.js.html +1 -1
  130. package/src/artifacts/coverage-jest/lcov-report/IconSelect/index.html +1 -1
  131. package/src/artifacts/coverage-jest/lcov-report/IconSelect/index.js.html +1 -1
  132. package/src/artifacts/coverage-jest/lcov-report/NoResultsMessage/NoResultsMessage.js.html +1 -1
  133. package/src/artifacts/coverage-jest/lcov-report/NoResultsMessage/index.html +1 -1
  134. package/src/artifacts/coverage-jest/lcov-report/NoResultsMessage/index.js.html +1 -1
  135. package/src/artifacts/coverage-jest/lcov-report/QueryTypedown/QueryTypedown.js.html +1 -1
  136. package/src/artifacts/coverage-jest/lcov-report/QueryTypedown/index.html +1 -1
  137. package/src/artifacts/coverage-jest/lcov-report/QueryTypedown/index.js.html +1 -1
  138. package/src/artifacts/coverage-jest/lcov-report/RefdataButtons/RefdataButtons.js.html +1 -1
  139. package/src/artifacts/coverage-jest/lcov-report/RefdataButtons/index.html +1 -1
  140. package/src/artifacts/coverage-jest/lcov-report/RefdataButtons/index.js.html +1 -1
  141. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/ResponsiveButtonGroup.js.html +1 -1
  142. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/index.html +9 -9
  143. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/index.js.html +1 -1
  144. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/useResponsiveButtonGroupSizing.js.html +43 -10
  145. package/src/artifacts/coverage-jest/lcov-report/RichSelect/RichSelect.js.html +1 -1
  146. package/src/artifacts/coverage-jest/lcov-report/RichSelect/index.html +1 -1
  147. package/src/artifacts/coverage-jest/lcov-report/RichSelect/index.js.html +1 -1
  148. package/src/artifacts/coverage-jest/lcov-report/RichSelect/useSelectedOption.js.html +1 -1
  149. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/SASQLookupComponent.js.html +1 -1
  150. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/TableBody/TableBody.js.html +1 -1
  151. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/TableBody/index.html +1 -1
  152. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/TableBody/index.js.html +1 -1
  153. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/index.html +1 -1
  154. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/index.js.html +1 -1
  155. package/src/artifacts/coverage-jest/lcov-report/SASQRoute/SASQRoute.js.html +1 -1
  156. package/src/artifacts/coverage-jest/lcov-report/SASQRoute/index.html +1 -1
  157. package/src/artifacts/coverage-jest/lcov-report/SASQRoute/index.js.html +1 -1
  158. package/src/artifacts/coverage-jest/lcov-report/SASQViewComponent/SASQViewComponent.js.html +1 -1
  159. package/src/artifacts/coverage-jest/lcov-report/SASQViewComponent/index.html +1 -1
  160. package/src/artifacts/coverage-jest/lcov-report/SASQViewComponent/index.js.html +1 -1
  161. package/src/artifacts/coverage-jest/lcov-report/SearchField/SearchField.js.html +1 -1
  162. package/src/artifacts/coverage-jest/lcov-report/SearchField/index.html +1 -1
  163. package/src/artifacts/coverage-jest/lcov-report/SearchField/index.js.html +1 -1
  164. package/src/artifacts/coverage-jest/lcov-report/SettingPage/SettingPage.js.html +6 -3
  165. package/src/artifacts/coverage-jest/lcov-report/SettingPage/SettingPagePane.js.html +1 -1
  166. package/src/artifacts/coverage-jest/lcov-report/SettingPage/index.html +1 -1
  167. package/src/artifacts/coverage-jest/lcov-report/SettingPage/index.js.html +1 -1
  168. package/src/artifacts/coverage-jest/lcov-report/Typedown/Typedown.js.html +20 -8
  169. package/src/artifacts/coverage-jest/lcov-report/Typedown/index.html +3 -3
  170. package/src/artifacts/coverage-jest/lcov-report/Typedown/index.js.html +1 -1
  171. package/src/artifacts/coverage-jest/lcov-report/constants/customProperties.js.html +1 -1
  172. package/src/artifacts/coverage-jest/lcov-report/constants/eventCodes.js.html +1 -1
  173. package/src/artifacts/coverage-jest/lcov-report/constants/index.html +1 -1
  174. package/src/artifacts/coverage-jest/lcov-report/contexts/SettingsContext.js.html +1 -1
  175. package/src/artifacts/coverage-jest/lcov-report/contexts/index.html +1 -1
  176. package/src/artifacts/coverage-jest/lcov-report/contexts/index.js.html +1 -1
  177. package/src/artifacts/coverage-jest/lcov-report/hooks/index.html +1 -1
  178. package/src/artifacts/coverage-jest/lcov-report/hooks/index.js.html +2 -5
  179. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/index.html +1 -1
  180. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/index.js.html +1 -1
  181. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/useTypedown.js.html +1 -1
  182. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/useTypedownData.js.html +1 -1
  183. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/useTypedownToggle.js.html +1 -1
  184. package/src/artifacts/coverage-jest/lcov-report/hooks/useActiveElement.js.html +1 -1
  185. package/src/artifacts/coverage-jest/lcov-report/hooks/useCustomProperties.js.html +1 -1
  186. package/src/artifacts/coverage-jest/lcov-report/hooks/useHelperApp.js.html +1 -1
  187. package/src/artifacts/coverage-jest/lcov-report/hooks/useIntlKey.js.html +1 -1
  188. package/src/artifacts/coverage-jest/lcov-report/hooks/useIntlKeyStore.js.html +1 -1
  189. package/src/artifacts/coverage-jest/lcov-report/hooks/useInvalidateRefdata.js.html +1 -1
  190. package/src/artifacts/coverage-jest/lcov-report/hooks/useKintIntl.js.html +1 -1
  191. package/src/artifacts/coverage-jest/lcov-report/hooks/useKiwtFieldArray.js.html +1 -1
  192. package/src/artifacts/coverage-jest/lcov-report/hooks/useKiwtSASQuery.js.html +1 -1
  193. package/src/artifacts/coverage-jest/lcov-report/hooks/useLocalStorageState.js.html +1 -1
  194. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateCustomProperties.js.html +1 -1
  195. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateRefdataCategory.js.html +1 -1
  196. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateRefdataValue.js.html +1 -1
  197. package/src/artifacts/coverage-jest/lcov-report/hooks/useQIndex.js.html +1 -1
  198. package/src/artifacts/coverage-jest/lcov-report/hooks/useRefdata.js.html +1 -1
  199. package/src/artifacts/coverage-jest/lcov-report/hooks/useSASQQueryMeta.js.html +1 -1
  200. package/src/artifacts/coverage-jest/lcov-report/hooks/useTemplates.js.html +1 -1
  201. package/src/artifacts/coverage-jest/lcov-report/index.html +60 -45
  202. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/index.html +161 -0
  203. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/index.js.html +94 -0
  204. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/useAppSettings.js.html +292 -0
  205. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/useSettingSection.js.html +211 -0
  206. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/useSettings.js.html +460 -0
  207. package/src/artifacts/coverage-jest/lcov-report/utils/buildUrl.js.html +1 -1
  208. package/src/artifacts/coverage-jest/lcov-report/utils/generateKiwtQuery.js.html +1 -1
  209. package/src/artifacts/coverage-jest/lcov-report/utils/generateKiwtQueryParams.js.html +1 -1
  210. package/src/artifacts/coverage-jest/lcov-report/utils/groupCustomPropertiesByCtx.js.html +1 -1
  211. package/src/artifacts/coverage-jest/lcov-report/utils/highlightString.js.html +1 -1
  212. package/src/artifacts/coverage-jest/lcov-report/utils/index.html +9 -24
  213. package/src/artifacts/coverage-jest/lcov-report/utils/index.js.html +2 -35
  214. package/src/artifacts/coverage-jest/lcov-report/utils/matchString.js.html +1 -1
  215. package/src/artifacts/coverage-jest/lcov-report/utils/parseErrorResponse.js.html +1 -1
  216. package/src/artifacts/coverage-jest/lcov-report/utils/parseKiwtQueryGroups.js.html +1 -1
  217. package/src/artifacts/coverage-jest/lcov-report/utils/refdataOptions.js.html +1 -1
  218. package/src/artifacts/coverage-jest/lcov-report/utils/refdataQueryKey.js.html +1 -1
  219. package/src/artifacts/coverage-jest/lcov-report/utils/selectorSafe.js.html +1 -1
  220. package/src/artifacts/coverage-jest/lcov-report/utils/sortByLabel.js.html +1 -1
  221. package/src/artifacts/coverage-jest/lcov-report/utils/toCamelCase.js.html +1 -1
  222. package/src/artifacts/coverage-jest/lcov-report/utils/typedownQueryKey.js.html +1 -1
  223. package/src/artifacts/coverage-jest/lcov-report/validators/index.html +131 -0
  224. package/src/artifacts/coverage-jest/lcov-report/validators/index.js.html +88 -0
  225. package/src/artifacts/coverage-jest/lcov-report/validators/validators.js.html +370 -0
  226. package/src/artifacts/coverage-jest/lcov.info +650 -588
  227. package/src/index.js +6 -2
  228. package/src/lib/ActionList/ActionList.js +3 -2
  229. package/src/lib/ActionList/ActionListFieldArray.js +9 -1
  230. package/src/lib/ActionList/README.md +1 -0
  231. package/src/lib/CustomProperties/Config/CustomPropertyForm.js +1 -1
  232. package/src/lib/CustomProperties/Filter/CustomPropertiesFilterField.js +1 -1
  233. package/src/lib/CustomProperties/Filter/CustomPropertiesRule.js +1 -1
  234. package/src/lib/CustomProperties/Filter/useValueProps.js +1 -1
  235. package/src/lib/EditableRefdataCategoryList/EditableRefdataCategoryList.js +32 -3
  236. package/src/lib/EditableRefdataList/EditableRefdataList.js +50 -22
  237. package/src/lib/EditableRefdataList/README.md +2 -1
  238. package/src/lib/ResponsiveButtonGroup/useResponsiveButtonGroupSizing.js +15 -4
  239. package/src/lib/SettingPage/SettingPage.js +2 -1
  240. package/src/lib/Typedown/Typedown.js +9 -5
  241. package/src/lib/hooks/index.js +0 -1
  242. package/src/lib/{hooks/settingsHooks → settingsHooks}/index.js +0 -0
  243. package/src/lib/{hooks/settingsHooks → settingsHooks}/useAppSettings.js +1 -1
  244. package/src/lib/{hooks/settingsHooks → settingsHooks}/useSettingSection.js +1 -2
  245. package/src/lib/{hooks/settingsHooks → settingsHooks}/useSettings.js +4 -5
  246. package/src/lib/utils/index.js +0 -11
  247. package/src/lib/validators/index.js +1 -0
  248. package/src/lib/{utils → validators}/validators.js +0 -0
  249. package/styles/TypeDown.css +17 -17
@@ -101,7 +101,7 @@
101
101
  <div class='footer quiet pad2 space-top1 center small'>
102
102
  Code coverage generated by
103
103
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
104
- at 2023-01-18T10:53:27.335Z
104
+ at 2023-02-08T10:17:09.386Z
105
105
  </div>
106
106
  <script src="../prettify.js"></script>
107
107
  <script>
@@ -160,7 +160,7 @@ export {
160
160
  <div class='footer quiet pad2 space-top1 center small'>
161
161
  Code coverage generated by
162
162
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
163
- at 2023-01-18T10:53:27.335Z
163
+ at 2023-02-08T10:17:09.386Z
164
164
  </div>
165
165
  <script src="../prettify.js"></script>
166
166
  <script>
@@ -202,7 +202,7 @@ export default CycleButton;
202
202
  <div class='footer quiet pad2 space-top1 center small'>
203
203
  Code coverage generated by
204
204
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
205
- at 2023-01-18T10:53:27.335Z
205
+ at 2023-02-08T10:17:09.386Z
206
206
  </div>
207
207
  <script src="../prettify.js"></script>
208
208
  <script>
@@ -116,7 +116,7 @@
116
116
  <div class='footer quiet pad2 space-top1 center small'>
117
117
  Code coverage generated by
118
118
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
119
- at 2023-01-18T10:53:27.335Z
119
+ at 2023-02-08T10:17:09.386Z
120
120
  </div>
121
121
  <script src="../prettify.js"></script>
122
122
  <script>
@@ -73,7 +73,7 @@
73
73
  <div class='footer quiet pad2 space-top1 center small'>
74
74
  Code coverage generated by
75
75
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
76
- at 2023-01-18T10:53:27.335Z
76
+ at 2023-02-08T10:17:09.386Z
77
77
  </div>
78
78
  <script src="../prettify.js"></script>
79
79
  <script>
@@ -25,28 +25,28 @@
25
25
  <div class='fl pad1y space-right2'>
26
26
  <span class="strong">0% </span>
27
27
  <span class="quiet">Statements</span>
28
- <span class='fraction'>0/37</span>
28
+ <span class='fraction'>0/39</span>
29
29
  </div>
30
30
 
31
31
 
32
32
  <div class='fl pad1y space-right2'>
33
33
  <span class="strong">0% </span>
34
34
  <span class="quiet">Branches</span>
35
- <span class='fraction'>0/14</span>
35
+ <span class='fraction'>0/24</span>
36
36
  </div>
37
37
 
38
38
 
39
39
  <div class='fl pad1y space-right2'>
40
40
  <span class="strong">0% </span>
41
41
  <span class="quiet">Functions</span>
42
- <span class='fraction'>0/15</span>
42
+ <span class='fraction'>0/16</span>
43
43
  </div>
44
44
 
45
45
 
46
46
  <div class='fl pad1y space-right2'>
47
47
  <span class="strong">0% </span>
48
48
  <span class="quiet">Lines</span>
49
- <span class='fraction'>0/36</span>
49
+ <span class='fraction'>0/38</span>
50
50
  </div>
51
51
 
52
52
 
@@ -256,7 +256,36 @@
256
256
  <a name='L191'></a><a href='#L191'>191</a>
257
257
  <a name='L192'></a><a href='#L192'>192</a>
258
258
  <a name='L193'></a><a href='#L193'>193</a>
259
- <a name='L194'></a><a href='#L194'>194</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
259
+ <a name='L194'></a><a href='#L194'>194</a>
260
+ <a name='L195'></a><a href='#L195'>195</a>
261
+ <a name='L196'></a><a href='#L196'>196</a>
262
+ <a name='L197'></a><a href='#L197'>197</a>
263
+ <a name='L198'></a><a href='#L198'>198</a>
264
+ <a name='L199'></a><a href='#L199'>199</a>
265
+ <a name='L200'></a><a href='#L200'>200</a>
266
+ <a name='L201'></a><a href='#L201'>201</a>
267
+ <a name='L202'></a><a href='#L202'>202</a>
268
+ <a name='L203'></a><a href='#L203'>203</a>
269
+ <a name='L204'></a><a href='#L204'>204</a>
270
+ <a name='L205'></a><a href='#L205'>205</a>
271
+ <a name='L206'></a><a href='#L206'>206</a>
272
+ <a name='L207'></a><a href='#L207'>207</a>
273
+ <a name='L208'></a><a href='#L208'>208</a>
274
+ <a name='L209'></a><a href='#L209'>209</a>
275
+ <a name='L210'></a><a href='#L210'>210</a>
276
+ <a name='L211'></a><a href='#L211'>211</a>
277
+ <a name='L212'></a><a href='#L212'>212</a>
278
+ <a name='L213'></a><a href='#L213'>213</a>
279
+ <a name='L214'></a><a href='#L214'>214</a>
280
+ <a name='L215'></a><a href='#L215'>215</a>
281
+ <a name='L216'></a><a href='#L216'>216</a>
282
+ <a name='L217'></a><a href='#L217'>217</a>
283
+ <a name='L218'></a><a href='#L218'>218</a>
284
+ <a name='L219'></a><a href='#L219'>219</a>
285
+ <a name='L220'></a><a href='#L220'>220</a>
286
+ <a name='L221'></a><a href='#L221'>221</a>
287
+ <a name='L222'></a><a href='#L222'>222</a>
288
+ <a name='L223'></a><a href='#L223'>223</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
260
289
  <span class="cline-any cline-neutral">&nbsp;</span>
261
290
  <span class="cline-any cline-neutral">&nbsp;</span>
262
291
  <span class="cline-any cline-neutral">&nbsp;</span>
@@ -281,6 +310,11 @@
281
310
  <span class="cline-any cline-neutral">&nbsp;</span>
282
311
  <span class="cline-any cline-neutral">&nbsp;</span>
283
312
  <span class="cline-any cline-neutral">&nbsp;</span>
313
+ <span class="cline-any cline-neutral">&nbsp;</span>
314
+ <span class="cline-any cline-neutral">&nbsp;</span>
315
+ <span class="cline-any cline-neutral">&nbsp;</span>
316
+ <span class="cline-any cline-neutral">&nbsp;</span>
317
+ <span class="cline-any cline-neutral">&nbsp;</span>
284
318
  <span class="cline-any cline-no">&nbsp;</span>
285
319
  <span class="cline-any cline-neutral">&nbsp;</span>
286
320
  <span class="cline-any cline-neutral">&nbsp;</span>
@@ -291,10 +325,26 @@
291
325
  <span class="cline-any cline-neutral">&nbsp;</span>
292
326
  <span class="cline-any cline-neutral">&nbsp;</span>
293
327
  <span class="cline-any cline-neutral">&nbsp;</span>
328
+ <span class="cline-any cline-neutral">&nbsp;</span>
329
+ <span class="cline-any cline-neutral">&nbsp;</span>
330
+ <span class="cline-any cline-neutral">&nbsp;</span>
331
+ <span class="cline-any cline-neutral">&nbsp;</span>
332
+ <span class="cline-any cline-neutral">&nbsp;</span>
333
+ <span class="cline-any cline-neutral">&nbsp;</span>
334
+ <span class="cline-any cline-neutral">&nbsp;</span>
335
+ <span class="cline-any cline-neutral">&nbsp;</span>
336
+ <span class="cline-any cline-neutral">&nbsp;</span>
337
+ <span class="cline-any cline-neutral">&nbsp;</span>
338
+ <span class="cline-any cline-neutral">&nbsp;</span>
294
339
  <span class="cline-any cline-no">&nbsp;</span>
295
340
  <span class="cline-any cline-no">&nbsp;</span>
296
341
  <span class="cline-any cline-neutral">&nbsp;</span>
297
342
  <span class="cline-any cline-neutral">&nbsp;</span>
343
+ <span class="cline-any cline-neutral">&nbsp;</span>
344
+ <span class="cline-any cline-neutral">&nbsp;</span>
345
+ <span class="cline-any cline-no">&nbsp;</span>
346
+ <span class="cline-any cline-neutral">&nbsp;</span>
347
+ <span class="cline-any cline-neutral">&nbsp;</span>
298
348
  <span class="cline-any cline-no">&nbsp;</span>
299
349
  <span class="cline-any cline-neutral">&nbsp;</span>
300
350
  <span class="cline-any cline-neutral">&nbsp;</span>
@@ -406,8 +456,16 @@
406
456
  <span class="cline-any cline-neutral">&nbsp;</span>
407
457
  <span class="cline-any cline-no">&nbsp;</span>
408
458
  <span class="cline-any cline-neutral">&nbsp;</span>
459
+ <span class="cline-any cline-neutral">&nbsp;</span>
460
+ <span class="cline-any cline-neutral">&nbsp;</span>
461
+ <span class="cline-any cline-no">&nbsp;</span>
462
+ <span class="cline-any cline-neutral">&nbsp;</span>
463
+ <span class="cline-any cline-neutral">&nbsp;</span>
409
464
  <span class="cline-any cline-no">&nbsp;</span>
410
465
  <span class="cline-any cline-neutral">&nbsp;</span>
466
+ <span class="cline-any cline-neutral">&nbsp;</span>
467
+ <span class="cline-any cline-neutral">&nbsp;</span>
468
+ <span class="cline-any cline-neutral">&nbsp;</span>
411
469
  <span class="cline-any cline-no">&nbsp;</span>
412
470
  <span class="cline-any cline-neutral">&nbsp;</span>
413
471
  <span class="cline-any cline-neutral">&nbsp;</span>
@@ -458,12 +516,17 @@ import { CalloutContext } from '@folio/stripes/core';
458
516
  import { useKintIntl, useMutateRefdataCategory, useRefdata } from '../hooks';
459
517
  &nbsp;
460
518
  import ActionList from '../ActionList';
461
- import { required } from '../utils/validators';
519
+ import { required } from '../validators';
462
520
  import { parseErrorResponse } from '../utils';
463
521
  &nbsp;
464
522
  const propTypes = <span class="cstat-no" title="statement not covered" >{</span>
465
523
  afterQueryCalls: PropTypes.object,
466
524
  catchQueryCalls: PropTypes.object,
525
+ displayConditions: PropTypes.shape({
526
+ create: PropTypes.bool,
527
+ delete: PropTypes.bool,
528
+ view: PropTypes.bool,
529
+ }),
467
530
  intlKey: PropTypes.string,
468
531
  intlNS: PropTypes.string,
469
532
  label: PropTypes.oneOfType([
@@ -477,6 +540,17 @@ const propTypes = <span class="cstat-no" title="statement not covered" >{</span>
477
540
  const EditableRefdataCategoryList = <span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >({</span></span>
478
541
  afterQueryCalls,
479
542
  catchQueryCalls,
543
+ /*
544
+ * Set of extra booleans for controlling access to actions
545
+ * create/delete (View should be handled externally)
546
+ * This will not overwrite "internal" behaviour, ie setting
547
+ * delete to 'true' here would still not render a delete button
548
+ * for a refdata category that has refdata values.
549
+ */
550
+ displayConditions = <span class="branch-0 cbranch-no" title="branch not covered" >{</span>
551
+ create: true,
552
+ delete: true,
553
+ },
480
554
  intlKey: passedIntlKey,
481
555
  intlNS: passedIntlNS,
482
556
  label,
@@ -486,6 +560,11 @@ const EditableRefdataCategoryList = <span class="cstat-no" title="statement not
486
560
  /* A component that allows for editing of refdata categories */
487
561
  const callout = <span class="cstat-no" title="statement not covered" >useContext(CalloutContext);</span>
488
562
  const kintIntl = <span class="cstat-no" title="statement not covered" >useKintIntl(passedIntlKey, passedIntlNS);</span>
563
+ &nbsp;
564
+ const {
565
+ create: createCondition = <span class="branch-0 cbranch-no" title="branch not covered" >true,</span>
566
+ delete: deleteCondition = <span class="branch-0 cbranch-no" title="branch not covered" >true,</span>
567
+ } = <span class="cstat-no" title="statement not covered" >displayConditions;</span>
489
568
  &nbsp;
490
569
  // fetch refdata values
491
570
  const { data: refdata = <span class="branch-0 cbranch-no" title="branch not covered" >[],</span> isLoading: isRefdataLoading } = <span class="cstat-no" title="statement not covered" >useRefdata({</span>
@@ -560,7 +639,7 @@ const EditableRefdataCategoryList = <span class="cstat-no" title="statement not
560
639
  const actionAssigner = <span class="cstat-no" title="statement not covered" ><span class="fstat-no" title="function not covered" >(r</span>owData) =&gt; {</span>
561
640
  const actionArray = <span class="cstat-no" title="statement not covered" >[];</span>
562
641
  &nbsp;
563
- <span class="cstat-no" title="statement not covered" > if (!rowData?.values?.length) {</span>
642
+ <span class="cstat-no" title="statement not covered" > if (!rowData?.values?.length &amp;&amp; deleteCondition) {</span>
564
643
  <span class="cstat-no" title="statement not covered" > actionArray.push({</span>
565
644
  name: 'delete',
566
645
  label: kintIntl.formatKintMessage({
@@ -599,10 +678,18 @@ const EditableRefdataCategoryList = <span class="cstat-no" title="statement not
599
678
  creatableFields={{
600
679
  values: <span class="fstat-no" title="function not covered" >()</span> =&gt; <span class="cstat-no" title="statement not covered" >false</span>
601
680
  }}
602
- createCallback={<span class="fstat-no" title="function not covered" >(d</span>ata) =&gt; <span class="cstat-no" title="statement not covered" >createRefdataCategory(data)}</span>
681
+ createCallback={!createCondition ?
682
+ null :
683
+ <span class="fstat-no" title="function not covered" > (d</span>ata) =&gt; <span class="cstat-no" title="statement not covered" >createRefdataCategory(data)</span>
684
+ }
603
685
  formatter={{
604
686
  values: <span class="fstat-no" title="function not covered" >(r</span>owData) =&gt; <span class="cstat-no" title="statement not covered" >rowData?.values?.length</span>
605
687
  }}
688
+ /* Hide actions column when no permissions, or no deletable refdata categories */
689
+ hideActionsColumn={
690
+ (!createCondition &amp;&amp; !deleteCondition) ||
691
+ !contentData?.find(<span class="fstat-no" title="function not covered" >cd</span> =&gt; <span class="cstat-no" title="statement not covered" >cd?.values?.length === 0)</span>
692
+ }
606
693
  label={label}
607
694
  validateFields={{
608
695
  desc: <span class="fstat-no" title="function not covered" >()</span> =&gt; <span class="cstat-no" title="statement not covered" >required</span>
@@ -649,7 +736,7 @@ export default EditableRefdataCategoryList;
649
736
  <div class='footer quiet pad2 space-top1 center small'>
650
737
  Code coverage generated by
651
738
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
652
- at 2023-01-18T10:53:27.335Z
739
+ at 2023-02-08T10:17:09.386Z
653
740
  </div>
654
741
  <script src="../prettify.js"></script>
655
742
  <script>
@@ -25,28 +25,28 @@
25
25
  <div class='fl pad1y space-right2'>
26
26
  <span class="strong">0% </span>
27
27
  <span class="quiet">Statements</span>
28
- <span class='fraction'>0/37</span>
28
+ <span class='fraction'>0/39</span>
29
29
  </div>
30
30
 
31
31
 
32
32
  <div class='fl pad1y space-right2'>
33
33
  <span class="strong">0% </span>
34
34
  <span class="quiet">Branches</span>
35
- <span class='fraction'>0/14</span>
35
+ <span class='fraction'>0/24</span>
36
36
  </div>
37
37
 
38
38
 
39
39
  <div class='fl pad1y space-right2'>
40
40
  <span class="strong">0% </span>
41
41
  <span class="quiet">Functions</span>
42
- <span class='fraction'>0/15</span>
42
+ <span class='fraction'>0/16</span>
43
43
  </div>
44
44
 
45
45
 
46
46
  <div class='fl pad1y space-right2'>
47
47
  <span class="strong">0% </span>
48
48
  <span class="quiet">Lines</span>
49
- <span class='fraction'>0/36</span>
49
+ <span class='fraction'>0/38</span>
50
50
  </div>
51
51
 
52
52
 
@@ -84,13 +84,13 @@
84
84
  <div class="chart"><div class="cover-fill" style="width: 0%"></div><div class="cover-empty" style="width: 100%"></div></div>
85
85
  </td>
86
86
  <td data-value="0" class="pct low">0%</td>
87
- <td data-value="37" class="abs low">0/37</td>
87
+ <td data-value="39" class="abs low">0/39</td>
88
88
  <td data-value="0" class="pct low">0%</td>
89
- <td data-value="14" class="abs low">0/14</td>
89
+ <td data-value="24" class="abs low">0/24</td>
90
90
  <td data-value="0" class="pct low">0%</td>
91
- <td data-value="15" class="abs low">0/15</td>
91
+ <td data-value="16" class="abs low">0/16</td>
92
92
  <td data-value="0" class="pct low">0%</td>
93
- <td data-value="36" class="abs low">0/36</td>
93
+ <td data-value="38" class="abs low">0/38</td>
94
94
  </tr>
95
95
 
96
96
  <tr>
@@ -116,7 +116,7 @@
116
116
  <div class='footer quiet pad2 space-top1 center small'>
117
117
  Code coverage generated by
118
118
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
119
- at 2023-01-18T10:53:27.335Z
119
+ at 2023-02-08T10:17:09.386Z
120
120
  </div>
121
121
  <script src="../prettify.js"></script>
122
122
  <script>
@@ -73,7 +73,7 @@
73
73
  <div class='footer quiet pad2 space-top1 center small'>
74
74
  Code coverage generated by
75
75
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
76
- at 2023-01-18T10:53:27.335Z
76
+ at 2023-02-08T10:17:09.386Z
77
77
  </div>
78
78
  <script src="../prettify.js"></script>
79
79
  <script>