@k-int/stripes-kint-components 4.5.1 → 4.6.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 (342) hide show
  1. package/CHANGELOG.md +8 -1
  2. package/README.md +14 -0
  3. package/es/__mocks__/@folio/stripes/components.js +10 -21
  4. package/es/__mocks__/@folio/stripes/core.js +4 -7
  5. package/es/__mocks__/@folio/stripes/smart-components.js +4 -7
  6. package/es/__mocks__/react-query.js +4 -7
  7. package/es/__mocks__/react-router-dom.js +6 -7
  8. package/es/artifacts/coverage-jest/lcov-report/prettify.js +2 -2
  9. package/es/artifacts/coverage-jest/lcov-report/sorter.js +6 -6
  10. package/es/index.js +62 -49
  11. package/es/lib/ActionList/ActionList.js +38 -51
  12. package/es/lib/ActionList/ActionListFieldArray.js +143 -167
  13. package/es/lib/ActionList/index.js +1 -1
  14. package/es/lib/CustomProperties/Config/CustomPropertiesLookup.js +57 -77
  15. package/es/lib/CustomProperties/Config/CustomPropertiesLookup.test.js +15 -19
  16. package/es/lib/CustomProperties/Config/CustomPropertiesSettings.js +111 -160
  17. package/es/lib/CustomProperties/Config/CustomPropertiesSettings.test.js +30 -67
  18. package/es/lib/CustomProperties/Config/CustomPropertyForm.js +36 -48
  19. package/es/lib/CustomProperties/Config/CustomPropertyForm.test.js +83 -121
  20. package/es/lib/CustomProperties/Config/CustomPropertyView.js +9 -8
  21. package/es/lib/CustomProperties/Config/CustomPropertyView.test.js +48 -135
  22. package/es/lib/CustomProperties/Config/index.js +4 -4
  23. package/es/lib/CustomProperties/Edit/CustomPropertiesEdit.js +19 -21
  24. package/es/lib/CustomProperties/Edit/CustomPropertiesEdit.test.js +11 -16
  25. package/es/lib/CustomProperties/Edit/CustomPropertiesEditCtx.js +29 -27
  26. package/es/lib/CustomProperties/Edit/CustomPropertiesEditCtx.test.js +11 -16
  27. package/es/lib/CustomProperties/Edit/CustomPropertiesListField.js +86 -103
  28. package/es/lib/CustomProperties/Edit/CustomPropertiesListField.test.js +26 -63
  29. package/es/lib/CustomProperties/Edit/CustomPropertyField.js +123 -115
  30. package/es/lib/CustomProperties/Edit/CustomPropertyField.test.js +95 -176
  31. package/es/lib/CustomProperties/Edit/CustomPropertyFormCard.js +43 -44
  32. package/es/lib/CustomProperties/Edit/CustomPropertyFormCard.test.js +23 -27
  33. package/es/lib/CustomProperties/Edit/index.js +5 -5
  34. package/es/lib/CustomProperties/Edit/testResources.js +13 -35
  35. package/es/lib/CustomProperties/Filter/CustomPropertiesFilter.js +60 -81
  36. package/es/lib/CustomProperties/Filter/CustomPropertiesFilter.test.js +23 -57
  37. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterField.js +39 -54
  38. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterField.test.js +17 -16
  39. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterFieldArray.js +27 -23
  40. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterFieldArray.test.js +18 -45
  41. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterForm.js +18 -20
  42. package/es/lib/CustomProperties/Filter/CustomPropertiesFilterForm.test.js +23 -52
  43. package/es/lib/CustomProperties/Filter/CustomPropertiesRule.js +37 -41
  44. package/es/lib/CustomProperties/Filter/CustomPropertiesRule.test.js +77 -225
  45. package/es/lib/CustomProperties/Filter/index.js +6 -6
  46. package/es/lib/CustomProperties/Filter/testResources.js +12 -32
  47. package/es/lib/CustomProperties/Filter/useOperators.js +17 -16
  48. package/es/lib/CustomProperties/Filter/useParseActiveFilterStrings.js +17 -30
  49. package/es/lib/CustomProperties/Filter/useValueProps.js +22 -27
  50. package/es/lib/CustomProperties/View/CustomPropertiesView.js +19 -21
  51. package/es/lib/CustomProperties/View/CustomPropertiesView.test.js +11 -16
  52. package/es/lib/CustomProperties/View/CustomPropertiesViewCtx.js +49 -57
  53. package/es/lib/CustomProperties/View/CustomPropertiesViewCtx.test.js +14 -23
  54. package/es/lib/CustomProperties/View/CustomPropertyCard.js +17 -18
  55. package/es/lib/CustomProperties/View/index.js +3 -3
  56. package/es/lib/CustomProperties/View/testResources.js +4 -4
  57. package/es/lib/CustomProperties/index.js +18 -18
  58. package/es/lib/CycleButton/CycleButton.js +17 -32
  59. package/es/lib/CycleButton/index.js +1 -1
  60. package/es/lib/EditableRefdataCategoryList/EditableRefdataCategoryList.js +108 -150
  61. package/es/lib/EditableRefdataCategoryList/index.js +1 -1
  62. package/es/lib/EditableRefdataList/EditableRefdataList.js +127 -170
  63. package/es/lib/EditableRefdataList/index.js +1 -1
  64. package/es/lib/EditableSettingsList/EditableSettingsList.js +16 -13
  65. package/es/lib/EditableSettingsList/EditableSettingsListFieldArray.js +18 -25
  66. package/es/lib/EditableSettingsList/EditableSettingsListFieldArray.test.js +61 -90
  67. package/es/lib/EditableSettingsList/SettingField/EditSettingValue.js +21 -34
  68. package/es/lib/EditableSettingsList/SettingField/EditSettingValue.test.js +99 -83
  69. package/es/lib/EditableSettingsList/SettingField/RenderSettingValue.js +17 -19
  70. package/es/lib/EditableSettingsList/SettingField/RenderSettingValue.test.js +187 -275
  71. package/es/lib/EditableSettingsList/SettingField/SettingField.js +74 -109
  72. package/es/lib/EditableSettingsList/SettingField/SettingField.test.js +52 -157
  73. package/es/lib/EditableSettingsList/SettingField/index.js +3 -3
  74. package/es/lib/EditableSettingsList/index.js +3 -3
  75. package/es/lib/FormModal/FormModal.js +43 -46
  76. package/es/lib/FormModal/index.js +1 -1
  77. package/es/lib/FormattedKintMessage/FormattedKintMessage.js +23 -27
  78. package/es/lib/FormattedKintMessage/index.js +1 -1
  79. package/es/lib/IconSelect/IconSelect.js +48 -68
  80. package/es/lib/IconSelect/index.js +1 -1
  81. package/es/lib/NoResultsMessage/NoResultsMessage.js +18 -17
  82. package/es/lib/NoResultsMessage/index.js +1 -1
  83. package/es/lib/QueryTypedown/QueryTypedown.js +17 -38
  84. package/es/lib/QueryTypedown/index.js +1 -1
  85. package/es/lib/RefdataButtons/RefdataButtons.js +26 -29
  86. package/es/lib/RefdataButtons/index.js +1 -1
  87. package/es/lib/ResponsiveButtonGroup/ResponsiveButtonGroup.js +83 -88
  88. package/es/lib/ResponsiveButtonGroup/index.js +1 -1
  89. package/es/lib/ResponsiveButtonGroup/useResponsiveButtonGroupSizing.js +27 -40
  90. package/es/lib/RichSelect/RichSelect.js +70 -86
  91. package/es/lib/RichSelect/index.js +2 -2
  92. package/es/lib/RichSelect/useSelectedOption.js +3 -12
  93. package/es/lib/SASQLookupComponent/SASQLookupComponent.js +115 -137
  94. package/es/lib/SASQLookupComponent/TableBody/TableBody.js +39 -45
  95. package/es/lib/SASQLookupComponent/TableBody/index.js +1 -1
  96. package/es/lib/SASQLookupComponent/index.js +2 -2
  97. package/es/lib/SASQRoute/SASQRoute.js +31 -37
  98. package/es/lib/SASQRoute/index.js +1 -1
  99. package/es/lib/SASQViewComponent/SASQViewComponent.js +38 -45
  100. package/es/lib/SASQViewComponent/index.js +1 -1
  101. package/es/lib/SearchField/SearchField.js +10 -16
  102. package/es/lib/SearchField/index.js +1 -1
  103. package/es/lib/SettingPage/SettingPage.js +21 -20
  104. package/es/lib/SettingPage/SettingPagePane.js +8 -6
  105. package/es/lib/SettingPage/index.js +2 -2
  106. package/es/lib/SettingsFormContainer/SettingsFormContainer.js +87 -0
  107. package/es/lib/SettingsFormContainer/index.js +13 -0
  108. package/es/lib/Typedown/Typedown.js +61 -79
  109. package/es/lib/Typedown/index.js +1 -1
  110. package/es/lib/constants/customProperties.js +11 -11
  111. package/es/lib/constants/endpoints.js +9 -0
  112. package/es/lib/constants/eventCodes.js +3 -3
  113. package/es/lib/contexts/SettingsContext.js +1 -1
  114. package/es/lib/contexts/index.js +1 -1
  115. package/es/lib/hooks/__mocks__/index.js +9 -29
  116. package/es/lib/hooks/index.js +31 -17
  117. package/es/lib/hooks/typedownHooks/index.js +3 -3
  118. package/es/lib/hooks/typedownHooks/useTypedown.js +48 -48
  119. package/es/lib/hooks/typedownHooks/useTypedownData.js +11 -21
  120. package/es/lib/hooks/typedownHooks/useTypedownToggle.js +12 -20
  121. package/es/lib/hooks/useActiveElement.js +8 -17
  122. package/es/lib/hooks/useCustomProperties.js +22 -30
  123. package/es/lib/hooks/useHelperApp.js +30 -49
  124. package/es/lib/hooks/useIntlKey.js +3 -5
  125. package/es/lib/hooks/useIntlKeyStore.js +44 -49
  126. package/es/lib/hooks/useInvalidateRefdata.js +3 -5
  127. package/es/lib/hooks/useKintIntl.js +28 -31
  128. package/es/lib/hooks/useKiwtFieldArray.js +34 -45
  129. package/es/lib/hooks/useKiwtSASQuery.js +38 -48
  130. package/es/lib/hooks/useLocalStorageState.js +6 -18
  131. package/es/lib/hooks/useModConfigEntries.js +49 -0
  132. package/es/lib/hooks/useMutateCustomProperties.js +19 -62
  133. package/es/lib/hooks/useMutateModConfigEntry.js +40 -0
  134. package/es/lib/hooks/useMutateRefdataCategory.js +19 -60
  135. package/es/lib/hooks/useMutateRefdataValue.js +28 -65
  136. package/es/lib/hooks/useQIndex.js +12 -26
  137. package/es/lib/hooks/useRefdata.js +17 -19
  138. package/es/lib/hooks/useSASQQueryMeta.js +13 -20
  139. package/es/lib/hooks/useTemplates.js +13 -12
  140. package/es/lib/settingsHooks/index.js +3 -3
  141. package/es/lib/settingsHooks/useAppSettings.js +18 -25
  142. package/es/lib/settingsHooks/useSettingSection.js +16 -17
  143. package/es/lib/settingsHooks/useSettings.js +58 -72
  144. package/es/lib/utils/buildUrl.js +5 -5
  145. package/es/lib/utils/generateKiwtQuery.js +3 -3
  146. package/es/lib/utils/generateKiwtQueryParams.js +85 -93
  147. package/es/lib/utils/groupCustomPropertiesByCtx.js +8 -18
  148. package/es/lib/utils/highlightString.js +17 -37
  149. package/es/lib/utils/index.js +29 -15
  150. package/es/lib/utils/matchString.js +4 -8
  151. package/es/lib/utils/modConfigEntriesQueryKey.js +24 -0
  152. package/es/lib/utils/parseErrorResponse.js +22 -63
  153. package/es/lib/utils/parseKiwtQueryGroups.js +10 -10
  154. package/es/lib/utils/parseKiwtQueryGroups.test.js +15 -15
  155. package/es/lib/utils/parseModConfigEntry.js +21 -0
  156. package/es/lib/utils/refdataQueryKey.js +2 -2
  157. package/es/lib/utils/selectorSafe.js +3 -3
  158. package/es/lib/utils/sortByLabel.js +3 -3
  159. package/es/lib/utils/toCamelCase.js +7 -12
  160. package/es/lib/utils/typedownQueryKey.js +2 -2
  161. package/es/lib/validators/index.js +1 -1
  162. package/es/lib/validators/validators.js +22 -29
  163. package/junit.xml +239 -1489
  164. package/package.json +1 -1
  165. package/src/artifacts/coverage-jest/lcov-report/ActionList/ActionList.js.html +11 -11
  166. package/src/artifacts/coverage-jest/lcov-report/ActionList/ActionListFieldArray.js.html +21 -21
  167. package/src/artifacts/coverage-jest/lcov-report/ActionList/index.html +17 -17
  168. package/src/artifacts/coverage-jest/lcov-report/ActionList/index.js.html +1 -1
  169. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertiesLookup.js.html +44 -44
  170. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertiesSettings.js.html +53 -53
  171. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertyForm.js.html +59 -59
  172. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/CustomPropertyView.js.html +29 -29
  173. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/index.html +53 -53
  174. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Config/index.js.html +1 -1
  175. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertiesEdit.js.html +19 -19
  176. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertiesEditCtx.js.html +28 -28
  177. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertiesListField.js.html +94 -94
  178. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertyField.js.html +118 -118
  179. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/CustomPropertyFormCard.js.html +28 -28
  180. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/index.html +64 -64
  181. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/index.js.html +1 -1
  182. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Edit/testResources.js.html +1 -1
  183. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilter.js.html +33 -33
  184. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilterField.js.html +47 -47
  185. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilterFieldArray.js.html +22 -22
  186. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesFilterForm.js.html +19 -19
  187. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/CustomPropertiesRule.js.html +42 -42
  188. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/index.html +96 -96
  189. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/index.js.html +1 -1
  190. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/testResources.js.html +5 -5
  191. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/useOperators.js.html +35 -35
  192. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/useParseActiveFilterStrings.js.html +38 -38
  193. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/Filter/useValueProps.js.html +34 -34
  194. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/CustomPropertiesView.js.html +16 -16
  195. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/CustomPropertiesViewCtx.js.html +45 -45
  196. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/CustomPropertyCard.js.html +9 -9
  197. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/index.html +36 -36
  198. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/index.js.html +1 -1
  199. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/View/testResources.js.html +1 -1
  200. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/index.html +1 -1
  201. package/src/artifacts/coverage-jest/lcov-report/CustomProperties/index.js.html +1 -1
  202. package/src/artifacts/coverage-jest/lcov-report/CycleButton/CycleButton.js.html +9 -9
  203. package/src/artifacts/coverage-jest/lcov-report/CycleButton/index.html +11 -11
  204. package/src/artifacts/coverage-jest/lcov-report/CycleButton/index.js.html +1 -1
  205. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataCategoryList/EditableRefdataCategoryList.js.html +11 -11
  206. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataCategoryList/index.html +11 -11
  207. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataCategoryList/index.js.html +1 -1
  208. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataList/EditableRefdataList.js.html +11 -11
  209. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataList/index.html +11 -11
  210. package/src/artifacts/coverage-jest/lcov-report/EditableRefdataList/index.js.html +1 -1
  211. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/EditableSettingsList.js.html +10 -10
  212. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/EditableSettingsListFieldArray.js.html +22 -22
  213. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/EditSettingValue.js.html +39 -39
  214. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/RenderSettingValue.js.html +64 -64
  215. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/SettingField.js.html +64 -64
  216. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/index.html +43 -43
  217. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/SettingField/index.js.html +1 -1
  218. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/index.html +28 -28
  219. package/src/artifacts/coverage-jest/lcov-report/EditableSettingsList/index.js.html +1 -1
  220. package/src/artifacts/coverage-jest/lcov-report/FormModal/FormModal.js.html +32 -32
  221. package/src/artifacts/coverage-jest/lcov-report/FormModal/index.html +21 -21
  222. package/src/artifacts/coverage-jest/lcov-report/FormModal/index.js.html +1 -1
  223. package/src/artifacts/coverage-jest/lcov-report/FormattedKintMessage/FormattedKintMessage.js.html +3 -3
  224. package/src/artifacts/coverage-jest/lcov-report/FormattedKintMessage/index.html +1 -1
  225. package/src/artifacts/coverage-jest/lcov-report/FormattedKintMessage/index.js.html +1 -1
  226. package/src/artifacts/coverage-jest/lcov-report/IconSelect/IconSelect.js.html +9 -9
  227. package/src/artifacts/coverage-jest/lcov-report/IconSelect/index.html +11 -11
  228. package/src/artifacts/coverage-jest/lcov-report/IconSelect/index.js.html +1 -1
  229. package/src/artifacts/coverage-jest/lcov-report/NoResultsMessage/NoResultsMessage.js.html +9 -9
  230. package/src/artifacts/coverage-jest/lcov-report/NoResultsMessage/index.html +11 -11
  231. package/src/artifacts/coverage-jest/lcov-report/NoResultsMessage/index.js.html +1 -1
  232. package/src/artifacts/coverage-jest/lcov-report/QueryTypedown/QueryTypedown.js.html +9 -9
  233. package/src/artifacts/coverage-jest/lcov-report/QueryTypedown/index.html +11 -11
  234. package/src/artifacts/coverage-jest/lcov-report/QueryTypedown/index.js.html +1 -1
  235. package/src/artifacts/coverage-jest/lcov-report/RefdataButtons/RefdataButtons.js.html +54 -54
  236. package/src/artifacts/coverage-jest/lcov-report/RefdataButtons/index.html +21 -21
  237. package/src/artifacts/coverage-jest/lcov-report/RefdataButtons/index.js.html +1 -1
  238. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/ResponsiveButtonGroup.js.html +15 -15
  239. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/index.html +17 -17
  240. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/index.js.html +1 -1
  241. package/src/artifacts/coverage-jest/lcov-report/ResponsiveButtonGroup/useResponsiveButtonGroupSizing.js.html +7 -7
  242. package/src/artifacts/coverage-jest/lcov-report/RichSelect/RichSelect.js.html +9 -9
  243. package/src/artifacts/coverage-jest/lcov-report/RichSelect/index.html +17 -17
  244. package/src/artifacts/coverage-jest/lcov-report/RichSelect/index.js.html +1 -1
  245. package/src/artifacts/coverage-jest/lcov-report/RichSelect/useSelectedOption.js.html +7 -7
  246. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/SASQLookupComponent.js.html +9 -9
  247. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/TableBody/TableBody.js.html +9 -9
  248. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/TableBody/index.html +11 -11
  249. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/TableBody/index.js.html +1 -1
  250. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/index.html +11 -11
  251. package/src/artifacts/coverage-jest/lcov-report/SASQLookupComponent/index.js.html +1 -1
  252. package/src/artifacts/coverage-jest/lcov-report/SASQRoute/SASQRoute.js.html +9 -9
  253. package/src/artifacts/coverage-jest/lcov-report/SASQRoute/index.html +11 -11
  254. package/src/artifacts/coverage-jest/lcov-report/SASQRoute/index.js.html +1 -1
  255. package/src/artifacts/coverage-jest/lcov-report/SASQViewComponent/SASQViewComponent.js.html +9 -9
  256. package/src/artifacts/coverage-jest/lcov-report/SASQViewComponent/index.html +11 -11
  257. package/src/artifacts/coverage-jest/lcov-report/SASQViewComponent/index.js.html +1 -1
  258. package/src/artifacts/coverage-jest/lcov-report/SearchField/SearchField.js.html +12 -12
  259. package/src/artifacts/coverage-jest/lcov-report/SearchField/index.html +13 -13
  260. package/src/artifacts/coverage-jest/lcov-report/SearchField/index.js.html +1 -1
  261. package/src/artifacts/coverage-jest/lcov-report/SettingPage/SettingPage.js.html +9 -9
  262. package/src/artifacts/coverage-jest/lcov-report/SettingPage/SettingPagePane.js.html +10 -10
  263. package/src/artifacts/coverage-jest/lcov-report/SettingPage/index.html +18 -18
  264. package/src/artifacts/coverage-jest/lcov-report/SettingPage/index.js.html +1 -1
  265. package/src/artifacts/coverage-jest/lcov-report/SettingsFormContainer/SettingsFormContainer.js.html +337 -0
  266. package/src/artifacts/coverage-jest/lcov-report/SettingsFormContainer/index.html +131 -0
  267. package/src/artifacts/coverage-jest/lcov-report/SettingsFormContainer/index.js.html +88 -0
  268. package/src/artifacts/coverage-jest/lcov-report/Typedown/Typedown.js.html +9 -9
  269. package/src/artifacts/coverage-jest/lcov-report/Typedown/index.html +11 -11
  270. package/src/artifacts/coverage-jest/lcov-report/Typedown/index.js.html +1 -1
  271. package/src/artifacts/coverage-jest/lcov-report/constants/customProperties.js.html +12 -12
  272. package/src/artifacts/coverage-jest/lcov-report/constants/endpoints.js.html +91 -0
  273. package/src/artifacts/coverage-jest/lcov-report/constants/eventCodes.js.html +12 -12
  274. package/src/artifacts/coverage-jest/lcov-report/constants/index.html +28 -13
  275. package/src/artifacts/coverage-jest/lcov-report/contexts/SettingsContext.js.html +2 -2
  276. package/src/artifacts/coverage-jest/lcov-report/contexts/index.html +1 -1
  277. package/src/artifacts/coverage-jest/lcov-report/contexts/index.js.html +1 -1
  278. package/src/artifacts/coverage-jest/lcov-report/hooks/index.html +153 -123
  279. package/src/artifacts/coverage-jest/lcov-report/hooks/index.js.html +8 -2
  280. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/index.html +23 -23
  281. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/index.js.html +1 -1
  282. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/useTypedown.js.html +7 -7
  283. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/useTypedownData.js.html +7 -7
  284. package/src/artifacts/coverage-jest/lcov-report/hooks/typedownHooks/useTypedownToggle.js.html +7 -7
  285. package/src/artifacts/coverage-jest/lcov-report/hooks/useActiveElement.js.html +7 -7
  286. package/src/artifacts/coverage-jest/lcov-report/hooks/useCustomProperties.js.html +9 -9
  287. package/src/artifacts/coverage-jest/lcov-report/hooks/useHelperApp.js.html +9 -9
  288. package/src/artifacts/coverage-jest/lcov-report/hooks/useIntlKey.js.html +24 -24
  289. package/src/artifacts/coverage-jest/lcov-report/hooks/useIntlKeyStore.js.html +21 -21
  290. package/src/artifacts/coverage-jest/lcov-report/hooks/useInvalidateRefdata.js.html +7 -7
  291. package/src/artifacts/coverage-jest/lcov-report/hooks/useKintIntl.js.html +38 -38
  292. package/src/artifacts/coverage-jest/lcov-report/hooks/useKiwtFieldArray.js.html +7 -7
  293. package/src/artifacts/coverage-jest/lcov-report/hooks/useKiwtSASQuery.js.html +9 -9
  294. package/src/artifacts/coverage-jest/lcov-report/hooks/useLocalStorageState.js.html +7 -7
  295. package/src/artifacts/coverage-jest/lcov-report/hooks/useModConfigEntries.js.html +226 -0
  296. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateCustomProperties.js.html +7 -7
  297. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateModConfigEntry.js.html +238 -0
  298. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateRefdataCategory.js.html +7 -7
  299. package/src/artifacts/coverage-jest/lcov-report/hooks/useMutateRefdataValue.js.html +7 -7
  300. package/src/artifacts/coverage-jest/lcov-report/hooks/useQIndex.js.html +7 -7
  301. package/src/artifacts/coverage-jest/lcov-report/hooks/useRefdata.js.html +9 -9
  302. package/src/artifacts/coverage-jest/lcov-report/hooks/useSASQQueryMeta.js.html +7 -7
  303. package/src/artifacts/coverage-jest/lcov-report/hooks/useTemplates.js.html +7 -7
  304. package/src/artifacts/coverage-jest/lcov-report/index.html +257 -242
  305. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/index.html +23 -23
  306. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/index.js.html +1 -1
  307. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/useAppSettings.js.html +7 -7
  308. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/useSettingSection.js.html +7 -7
  309. package/src/artifacts/coverage-jest/lcov-report/settingsHooks/useSettings.js.html +7 -7
  310. package/src/artifacts/coverage-jest/lcov-report/utils/buildUrl.js.html +1 -1
  311. package/src/artifacts/coverage-jest/lcov-report/utils/generateKiwtQuery.js.html +2 -2
  312. package/src/artifacts/coverage-jest/lcov-report/utils/generateKiwtQueryParams.js.html +4 -4
  313. package/src/artifacts/coverage-jest/lcov-report/utils/groupCustomPropertiesByCtx.js.html +22 -22
  314. package/src/artifacts/coverage-jest/lcov-report/utils/highlightString.js.html +3 -3
  315. package/src/artifacts/coverage-jest/lcov-report/utils/index.html +61 -31
  316. package/src/artifacts/coverage-jest/lcov-report/utils/index.js.html +11 -2
  317. package/src/artifacts/coverage-jest/lcov-report/utils/matchString.js.html +2 -2
  318. package/src/artifacts/coverage-jest/lcov-report/utils/modConfigEntriesQueryKey.js.html +142 -0
  319. package/src/artifacts/coverage-jest/lcov-report/utils/parseErrorResponse.js.html +2 -2
  320. package/src/artifacts/coverage-jest/lcov-report/utils/parseKiwtQueryGroups.js.html +2 -2
  321. package/src/artifacts/coverage-jest/lcov-report/utils/parseModConfigEntry.js.html +130 -0
  322. package/src/artifacts/coverage-jest/lcov-report/utils/refdataOptions.js.html +1 -1
  323. package/src/artifacts/coverage-jest/lcov-report/utils/refdataQueryKey.js.html +2 -2
  324. package/src/artifacts/coverage-jest/lcov-report/utils/selectorSafe.js.html +2 -2
  325. package/src/artifacts/coverage-jest/lcov-report/utils/sortByLabel.js.html +2 -2
  326. package/src/artifacts/coverage-jest/lcov-report/utils/toCamelCase.js.html +16 -16
  327. package/src/artifacts/coverage-jest/lcov-report/utils/typedownQueryKey.js.html +2 -2
  328. package/src/artifacts/coverage-jest/lcov-report/validators/index.html +19 -19
  329. package/src/artifacts/coverage-jest/lcov-report/validators/index.js.html +1 -1
  330. package/src/artifacts/coverage-jest/lcov-report/validators/validators.js.html +32 -32
  331. package/src/artifacts/coverage-jest/lcov.info +1225 -1067
  332. package/src/index.js +6 -0
  333. package/src/lib/SettingsFormContainer/SettingsFormContainer.js +84 -0
  334. package/src/lib/SettingsFormContainer/index.js +1 -0
  335. package/src/lib/constants/endpoints.js +2 -0
  336. package/src/lib/hooks/index.js +2 -0
  337. package/src/lib/hooks/useModConfigEntries.js +47 -0
  338. package/src/lib/hooks/useMutateModConfigEntry.js +51 -0
  339. package/src/lib/utils/index.js +3 -0
  340. package/src/lib/utils/modConfigEntriesQueryKey.js +19 -0
  341. package/src/lib/utils/parseModConfigEntry.js +15 -0
  342. package/test/jest/helpers/KintHarness.js +21 -4
@@ -1,6 +1,5 @@
1
1
  "use strict";
2
2
 
3
- function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
3
  Object.defineProperty(exports, "__esModule", {
5
4
  value: true
6
5
  });
@@ -12,18 +11,10 @@ var _reactFinalFormArrays = require("react-final-form-arrays");
12
11
  var _finalFormArrays = _interopRequireDefault(require("final-form-arrays"));
13
12
  var _ActionListFieldArray = _interopRequireDefault(require("./ActionListFieldArray"));
14
13
  var _jsxRuntime = require("react/jsx-runtime");
15
- var _excluded = ["actionAssigner", "columnMapping", "contentData", "creatableFields", "createCallback", "defaultNewObject", "editableFields", "fieldComponents", "hideActionsColumn", "hideCreateButton", "intlKey", "intlNS", "label", "labelOverrides", "validateFields", "visibleFields"];
16
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
17
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
18
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
19
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
20
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
21
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
22
- function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
23
- function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
24
- function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
25
- function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
26
- var propTypes = {
15
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
16
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
17
+ const propTypes = {
27
18
  actionAssigner: _propTypes.default.func,
28
19
  columnMapping: _propTypes.default.object,
29
20
  contentData: _propTypes.default.arrayOf(_propTypes.default.object),
@@ -41,55 +32,50 @@ var propTypes = {
41
32
  validateFields: _propTypes.default.object,
42
33
  visibleFields: _propTypes.default.arrayOf(_propTypes.default.string)
43
34
  };
44
- var ActionList = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
45
- var actionAssigner = _ref.actionAssigner,
46
- columnMapping = _ref.columnMapping,
47
- contentData = _ref.contentData,
48
- _ref$creatableFields = _ref.creatableFields,
49
- creatableFields = _ref$creatableFields === void 0 ? {} : _ref$creatableFields,
50
- createCallback = _ref.createCallback,
51
- _ref$defaultNewObject = _ref.defaultNewObject,
52
- defaultNewObject = _ref$defaultNewObject === void 0 ? {} : _ref$defaultNewObject,
53
- _ref$editableFields = _ref.editableFields,
54
- editableFields = _ref$editableFields === void 0 ? {} : _ref$editableFields,
55
- _ref$fieldComponents = _ref.fieldComponents,
56
- fieldComponents = _ref$fieldComponents === void 0 ? {} : _ref$fieldComponents,
57
- _ref$hideActionsColum = _ref.hideActionsColumn,
58
- hideActionsColumn = _ref$hideActionsColum === void 0 ? false : _ref$hideActionsColum,
59
- hideCreateButton = _ref.hideCreateButton,
60
- passedIntlKey = _ref.intlKey,
61
- passedIntlNS = _ref.intlNS,
62
- label = _ref.label,
63
- _ref$labelOverrides = _ref.labelOverrides,
64
- labelOverrides = _ref$labelOverrides === void 0 ? {} : _ref$labelOverrides,
65
- validateFields = _ref.validateFields,
66
- visibleFields = _ref.visibleFields,
67
- mclProps = _objectWithoutProperties(_ref, _excluded);
68
- var ActionListFieldArrayWithRef = function ActionListFieldArrayWithRef(alfaProps) {
69
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ActionListFieldArray.default, _objectSpread({
70
- ref: ref
71
- }, alfaProps));
72
- };
35
+ const ActionList = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
36
+ let {
37
+ actionAssigner,
38
+ columnMapping,
39
+ contentData,
40
+ creatableFields = {},
41
+ createCallback,
42
+ defaultNewObject = {},
43
+ editableFields = {},
44
+ fieldComponents = {},
45
+ hideActionsColumn = false,
46
+ hideCreateButton,
47
+ intlKey: passedIntlKey,
48
+ intlNS: passedIntlNS,
49
+ label,
50
+ labelOverrides = {},
51
+ validateFields,
52
+ visibleFields,
53
+ ...mclProps // Assume anything left over is to directly apply to the MCL
54
+ } = _ref;
55
+ const ActionListFieldArrayWithRef = alfaProps => /*#__PURE__*/(0, _jsxRuntime.jsx)(_ActionListFieldArray.default, {
56
+ ref: ref,
57
+ ...alfaProps
58
+ });
73
59
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_jsxRuntime.Fragment, {
74
60
  children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFinalForm.Form, {
75
61
  enableReinitialize: true,
76
62
  initialValues: {
77
- contentData: contentData
63
+ contentData
78
64
  },
79
65
  mutators: _finalFormArrays.default,
80
- onSubmit: function onSubmit() {
81
- return null;
82
- },
66
+ onSubmit: () => null,
83
67
  subscription: {
84
68
  contentData: true
85
69
  },
86
- children: function children(_ref2) {
87
- var handleSubmit = _ref2.handleSubmit;
70
+ children: _ref2 => {
71
+ let {
72
+ handleSubmit
73
+ } = _ref2;
88
74
  return /*#__PURE__*/(0, _jsxRuntime.jsx)("form", {
89
- onSubmit: function onSubmit(e) {
75
+ onSubmit: e => {
90
76
  e.preventDefault();
91
77
  },
92
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFinalFormArrays.FieldArray, _objectSpread({
78
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFinalFormArrays.FieldArray, {
93
79
  actionAssigner: actionAssigner,
94
80
  columnMapping: columnMapping,
95
81
  component: ActionListFieldArrayWithRef,
@@ -107,8 +93,9 @@ var ActionList = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
107
93
  name: "contentData",
108
94
  triggerFormSubmit: handleSubmit,
109
95
  validateFields: validateFields,
110
- visibleFields: visibleFields
111
- }, mclProps))
96
+ visibleFields: visibleFields,
97
+ ...mclProps
98
+ })
112
99
  });
113
100
  }
114
101
  })
@@ -1,6 +1,5 @@
1
1
  "use strict";
2
2
 
3
- function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
3
  Object.defineProperty(exports, "__esModule", {
5
4
  value: true
6
5
  });
@@ -14,37 +13,13 @@ var _components = require("@folio/stripes/components");
14
13
  var _hooks = require("../hooks");
15
14
  var _ActionListFieldArray = _interopRequireDefault(require("../../../styles/ActionListFieldArray.css"));
16
15
  var _jsxRuntime = require("react/jsx-runtime");
17
- var _excluded = ["action"],
18
- _excluded2 = ["actionAssigner", "columnMapping", "creatableFields", "createCallback", "defaultNewObject", "editableFields", "fields", "fieldComponents", "hideActionsColumn", "hideCreateButton", "intlKey", "intlNS", "label", "labelOverrides", "onRowClick", "validateFields", "visibleFields", "triggerFormSubmit"],
19
- _excluded3 = ["actionListActions", "fieldName", "fieldIndex"],
20
- _excluded4 = ["actionListActions", "fieldName", "fieldIndex"],
21
- _excluded5 = ["actionListActions"],
22
- _excluded6 = ["formatter"],
23
- _excluded7 = ["actionListActions"];
24
16
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
25
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
26
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
27
- function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
28
- function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
29
- function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
30
- function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
31
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
32
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
33
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
34
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
35
- function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
36
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
37
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
38
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
39
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
40
- function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
41
- function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
42
- function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
43
- function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
44
- var EDITING_ACTIONS_WIDTH = 25;
45
- var NON_EDITING_ACTIONS_WIDTH = 20;
46
- var TOTAL_WIDTH = 100;
47
- var propTypes = {
17
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
18
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
19
+ const EDITING_ACTIONS_WIDTH = 25;
20
+ const NON_EDITING_ACTIONS_WIDTH = 20;
21
+ const TOTAL_WIDTH = 100;
22
+ const propTypes = {
48
23
  actionAssigner: _propTypes.default.func,
49
24
  columnMapping: _propTypes.default.object,
50
25
  creatableFields: _propTypes.default.object,
@@ -67,22 +42,25 @@ var propTypes = {
67
42
  };
68
43
 
69
44
  // This needs to be outside of the main component for forwardRef to work properly it seems.
70
- var ActionTrigger = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
45
+ const ActionTrigger = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
71
46
  var _action$label;
72
- var action = _ref.action,
73
- actionTriggerProps = _objectWithoutProperties(_ref, _excluded);
47
+ let {
48
+ action,
49
+ ...actionTriggerProps
50
+ } = _ref;
74
51
  if (action.icon) {
75
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.IconButton, _objectSpread({
52
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.IconButton, {
76
53
  ref: ref,
77
- icon: action.icon
78
- }, actionTriggerProps));
54
+ icon: action.icon,
55
+ ...actionTriggerProps
56
+ });
79
57
  }
80
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Button, _objectSpread(_objectSpread({
58
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Button, {
81
59
  ref: ref,
82
- marginBottom0: true
83
- }, actionTriggerProps), {}, {
60
+ marginBottom0: true,
61
+ ...actionTriggerProps,
84
62
  children: (_action$label = action.label) !== null && _action$label !== void 0 ? _action$label : action.name
85
- }));
63
+ });
86
64
  });
87
65
  ActionTrigger.propTypes = {
88
66
  action: _propTypes.default.shape({
@@ -91,98 +69,94 @@ ActionTrigger.propTypes = {
91
69
  name: _propTypes.default.string
92
70
  })
93
71
  };
94
- var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2, ref) {
95
- var actionAssigner = _ref2.actionAssigner,
96
- columnMapping = _ref2.columnMapping,
97
- creatableFields = _ref2.creatableFields,
98
- createCallback = _ref2.createCallback,
99
- defaultNewObject = _ref2.defaultNewObject,
100
- editableFields = _ref2.editableFields,
101
- fields = _ref2.fields,
102
- fieldComponents = _ref2.fieldComponents,
103
- _ref2$hideActionsColu = _ref2.hideActionsColumn,
104
- hideActionsColumn = _ref2$hideActionsColu === void 0 ? false : _ref2$hideActionsColu,
105
- _ref2$hideCreateButto = _ref2.hideCreateButton,
106
- hideCreateButton = _ref2$hideCreateButto === void 0 ? false : _ref2$hideCreateButto,
107
- passedIntlKey = _ref2.intlKey,
108
- passedIntlNS = _ref2.intlNS,
109
- label = _ref2.label,
110
- _ref2$labelOverrides = _ref2.labelOverrides,
111
- labelOverrides = _ref2$labelOverrides === void 0 ? {} : _ref2$labelOverrides,
112
- onRowClick = _ref2.onRowClick,
113
- validateFields = _ref2.validateFields,
114
- visibleFields = _ref2.visibleFields,
115
- triggerFormSubmit = _ref2.triggerFormSubmit,
116
- mclProps = _objectWithoutProperties(_ref2, _excluded2);
72
+ const ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)((_ref2, ref) => {
73
+ let {
74
+ actionAssigner,
75
+ columnMapping,
76
+ creatableFields,
77
+ createCallback,
78
+ defaultNewObject,
79
+ editableFields,
80
+ fields,
81
+ fieldComponents,
82
+ hideActionsColumn = false,
83
+ hideCreateButton = false,
84
+ intlKey: passedIntlKey,
85
+ intlNS: passedIntlNS,
86
+ label,
87
+ labelOverrides = {},
88
+ onRowClick,
89
+ validateFields,
90
+ visibleFields,
91
+ triggerFormSubmit,
92
+ ...mclProps // Assume anything left over is to directly apply to the MCL
93
+ } = _ref2;
117
94
  // Grab finalForm functions/values from form hooks
118
- var _useForm = (0, _reactFinalForm.useForm)(),
119
- change = _useForm.change;
120
- var _useFormState = (0, _reactFinalForm.useFormState)(),
121
- hasValidationErrors = _useFormState.hasValidationErrors,
122
- initialValues = _useFormState.initialValues,
123
- pristine = _useFormState.pristine,
124
- submitting = _useFormState.submitting,
125
- values = _useFormState.values;
126
- var kintIntl = (0, _hooks.useKintIntl)(passedIntlKey, passedIntlNS);
95
+ const {
96
+ change
97
+ } = (0, _reactFinalForm.useForm)();
98
+ const {
99
+ hasValidationErrors,
100
+ initialValues,
101
+ pristine,
102
+ submitting,
103
+ values
104
+ } = (0, _reactFinalForm.useFormState)();
105
+ const kintIntl = (0, _hooks.useKintIntl)(passedIntlKey, passedIntlNS);
127
106
  /*
128
107
  Keep track of which field we are editing.
129
108
  null for no field, string id if we are editing an existing field and
130
109
  'NEW_ROW' for a new row
131
110
  */
132
- var _useState = (0, _react.useState)(null),
133
- _useState2 = _slicedToArray(_useState, 2),
134
- editing = _useState2[0],
135
- setEditing = _useState2[1];
136
- var toggleEditing = function toggleEditing(id) {
111
+ const [editing, setEditing] = (0, _react.useState)(null);
112
+ const toggleEditing = id => {
137
113
  if (editing) {
138
114
  setEditing(null);
139
115
  } else {
140
116
  setEditing(id);
141
117
  }
142
118
  };
143
- var handleSave = function handleSave(index) {
119
+ const handleSave = index => {
144
120
  var _actionAssigner, _actionAssigner$find;
145
- var _fields$value$index = fields.value[index],
146
- _a = _fields$value$index.actionListActions,
147
- _fn = _fields$value$index.fieldName,
148
- _fi = _fields$value$index.fieldIndex,
149
- rowData = _objectWithoutProperties(_fields$value$index, _excluded3);
121
+ const {
122
+ actionListActions: _a,
123
+ fieldName: _fn,
124
+ fieldIndex: _fi,
125
+ ...rowData
126
+ } = fields.value[index];
150
127
 
151
128
  // Find "edit" entry in actionAssigner
152
- var editCallback = (_actionAssigner = actionAssigner(rowData)) === null || _actionAssigner === void 0 ? void 0 : (_actionAssigner$find = _actionAssigner.find(function (act) {
153
- return act.name === 'edit';
154
- })) === null || _actionAssigner$find === void 0 ? void 0 : _actionAssigner$find.callback;
129
+ const editCallback = (_actionAssigner = actionAssigner(rowData)) === null || _actionAssigner === void 0 ? void 0 : (_actionAssigner$find = _actionAssigner.find(act => act.name === 'edit')) === null || _actionAssigner$find === void 0 ? void 0 : _actionAssigner$find.callback;
155
130
  if (editCallback) {
156
131
  editCallback(rowData);
157
132
  }
158
133
  };
159
- var handleCreate = function handleCreate(index) {
160
- var _fields$value$index2 = fields.value[index],
161
- _a = _fields$value$index2.actionListActions,
162
- _fn = _fields$value$index2.fieldName,
163
- _fi = _fields$value$index2.fieldIndex,
164
- rowData = _objectWithoutProperties(_fields$value$index2, _excluded4);
134
+ const handleCreate = index => {
135
+ const {
136
+ actionListActions: _a,
137
+ fieldName: _fn,
138
+ fieldIndex: _fi,
139
+ ...rowData
140
+ } = fields.value[index];
165
141
  if (createCallback) {
166
142
  createCallback(rowData);
167
143
  }
168
144
  };
169
- var handleClickCreate = function handleClickCreate() {
145
+ const handleClickCreate = () => {
170
146
  toggleEditing('NEW_ROW');
171
147
  fields.unshift(defaultNewObject);
172
148
  };
173
149
 
174
150
  // Way to go into create mode from external component, and way to tell internal editing state
175
- (0, _react.useImperativeHandle)(ref, function () {
176
- return {
177
- create: handleClickCreate,
178
- editing: editing
179
- };
180
- });
181
- var getColumnWidths = function getColumnWidths() {
182
- var widthNotInUseByActions = editing ? TOTAL_WIDTH - EDITING_ACTIONS_WIDTH : TOTAL_WIDTH - NON_EDITING_ACTIONS_WIDTH;
183
- var staticWidth = widthNotInUseByActions / visibleFields.length;
184
- var widthsObject = {};
185
- visibleFields.forEach(function (f) {
151
+ (0, _react.useImperativeHandle)(ref, () => ({
152
+ create: handleClickCreate,
153
+ editing
154
+ }));
155
+ const getColumnWidths = () => {
156
+ const widthNotInUseByActions = editing ? TOTAL_WIDTH - EDITING_ACTIONS_WIDTH : TOTAL_WIDTH - NON_EDITING_ACTIONS_WIDTH;
157
+ const staticWidth = widthNotInUseByActions / visibleFields.length;
158
+ const widthsObject = {};
159
+ visibleFields.forEach(f => {
186
160
  if (f !== 'actionListActions') {
187
161
  widthsObject[f] = "".concat(staticWidth, "%");
188
162
  }
@@ -190,10 +164,12 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
190
164
  widthsObject.actionListActions = editing ? "".concat(EDITING_ACTIONS_WIDTH, "%") : "".concat(NON_EDITING_ACTIONS_WIDTH, "%");
191
165
  return widthsObject;
192
166
  };
193
- var renderActionButtons = function renderActionButtons(data) {
194
- var fieldName = "contentData[".concat(data.rowIndex, "]");
195
- var actions = data.actionListActions,
196
- rest = _objectWithoutProperties(data, _excluded5);
167
+ const renderActionButtons = data => {
168
+ const fieldName = "contentData[".concat(data.rowIndex, "]");
169
+ const {
170
+ actionListActions: actions,
171
+ ...rest
172
+ } = data;
197
173
  if (data.id === editing || !data.id && editing === 'NEW_ROW') {
198
174
  // Render the save/cancel buttons
199
175
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
@@ -202,7 +178,7 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
202
178
  buttonStyle: "primary",
203
179
  disabled: hasValidationErrors || submitting || pristine,
204
180
  marginBottom0: true,
205
- onClick: function onClick() {
181
+ onClick: () => {
206
182
  triggerFormSubmit(); // This is set up as () => null in ActionList, so essentially only acts here to force validation
207
183
 
208
184
  if (!hasValidationErrors) {
@@ -222,7 +198,7 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
222
198
  }, "save[".concat(data.rowIndex, "]")), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Button, {
223
199
  "data-type-button": "cancel",
224
200
  marginBottom0: true,
225
- onClick: function onClick() {
201
+ onClick: () => {
226
202
  if (!data.id && editing === 'NEW_ROW') {
227
203
  fields.remove(data.rowIndex);
228
204
  toggleEditing('NEW_ROW');
@@ -240,21 +216,17 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
240
216
  }
241
217
  return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
242
218
  id: "action-button-parent",
243
- children: actions === null || actions === void 0 ? void 0 : actions.map(function (action) {
244
- var actionFunction;
219
+ children: actions === null || actions === void 0 ? void 0 : actions.map(action => {
220
+ let actionFunction;
245
221
  if (action.callback) {
246
- actionFunction = function actionFunction() {
247
- return action.callback(rest);
248
- };
222
+ actionFunction = () => action.callback(rest);
249
223
  }
250
224
 
251
225
  // Edit has special action functionality, revealing fields etc.
252
226
  if (action.name === 'edit') {
253
- actionFunction = function actionFunction() {
254
- return toggleEditing(data.id);
255
- };
227
+ actionFunction = () => toggleEditing(data.id);
256
228
  }
257
- var ariaLabel = "action-".concat(action.name, "[").concat(data.rowIndex, "]");
229
+ let ariaLabel = "action-".concat(action.name, "[").concat(data.rowIndex, "]");
258
230
  if (action !== null && action !== void 0 && action.ariaLabel) {
259
231
  if (typeof action.ariaLabel === 'function') {
260
232
  ariaLabel = action.ariaLabel(data);
@@ -264,8 +236,8 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
264
236
  throw new Error("Provided ariaLabel for action \"".concat(action.name, "\" must be a function or a string."));
265
237
  }
266
238
  }
267
- var tooltip;
268
- var tooltipSub;
239
+ let tooltip;
240
+ let tooltipSub;
269
241
  if (action !== null && action !== void 0 && action.tooltip) {
270
242
  if (typeof action.tooltip === 'function') {
271
243
  tooltip = action.tooltip(data);
@@ -287,16 +259,18 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
287
259
  id: "action-".concat(action.name, "[").concat(data.rowIndex, "]-tooltip"),
288
260
  sub: tooltipSub,
289
261
  text: tooltip,
290
- children: function children(_ref3) {
291
- var actionTriggerRef = _ref3.ref,
292
- ariaIds = _ref3.ariaIds;
262
+ children: _ref3 => {
263
+ let {
264
+ ref: actionTriggerRef,
265
+ ariaIds
266
+ } = _ref3;
293
267
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(ActionTrigger, {
294
268
  ref: actionTriggerRef,
295
269
  action: action,
296
270
  "aria-describedby": ariaIds.sub,
297
271
  "aria-labelledby": ariaIds.text,
298
272
  disabled: !!editing,
299
- onClick: function onClick(e) {
273
+ onClick: e => {
300
274
  e.stopPropagation();
301
275
  if (actionFunction) {
302
276
  return actionFunction();
@@ -314,7 +288,7 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
314
288
  action: action,
315
289
  ariaLabel: ariaLabel,
316
290
  disabled: !!editing,
317
- onClick: function onClick(e) {
291
+ onClick: e => {
318
292
  e.stopPropagation();
319
293
  if (actionFunction) {
320
294
  return actionFunction();
@@ -326,32 +300,35 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
326
300
  })
327
301
  });
328
302
  };
329
- var assignActions = function assignActions() {
330
- return fields.map(function (fieldName, fieldIndex) {
303
+ const assignActions = () => {
304
+ return fields.map((fieldName, fieldIndex) => {
331
305
  // Fetch the content from the field Values
332
- var cd = (0, _cloneDeep.default)((0, _get.default)(values, fieldName));
306
+ const cd = (0, _cloneDeep.default)((0, _get.default)(values, fieldName));
333
307
  cd.actionListActions = actionAssigner(cd);
334
- return _objectSpread(_objectSpread({}, cd), {}, {
335
- fieldName: fieldName,
336
- fieldIndex: fieldIndex
337
- });
308
+ return {
309
+ ...cd,
310
+ fieldName,
311
+ fieldIndex
312
+ };
338
313
  });
339
314
  };
340
- var formatter = mclProps.formatter,
341
- restOfMclProps = _objectWithoutProperties(mclProps, _excluded6); // Destructure formatter part of mclProps
342
- var fieldAwareFormatter = function fieldAwareFormatter() {
343
- var returnObj = {};
315
+ const {
316
+ formatter,
317
+ ...restOfMclProps
318
+ } = mclProps; // Destructure formatter part of mclProps
319
+ const fieldAwareFormatter = () => {
320
+ const returnObj = {};
344
321
  // For each visible field, if it's being edited then ignore passed formatters, else use them
345
322
 
346
323
  // Track whether we've autoFocused on a field yet
347
- var autoFocus = true;
348
- visibleFields.forEach(function (key) {
349
- returnObj[key] = function (cd) {
324
+ let autoFocus = true;
325
+ visibleFields.forEach(key => {
326
+ returnObj[key] = cd => {
350
327
  // Row is being edited if it has no id, or its id is in the editing string
351
- var editingRow = cd.id === editing || !cd.id;
328
+ const editingRow = cd.id === editing || !cd.id;
352
329
 
353
330
  // Default to the passed formatter values
354
- var returnValue = formatter !== null && formatter !== void 0 && formatter[key] ? formatter[key](cd) : cd[key];
331
+ let returnValue = formatter !== null && formatter !== void 0 && formatter[key] ? formatter[key](cd) : cd[key];
355
332
 
356
333
  // If editing, replace values with fields
357
334
  if (editingRow) {
@@ -360,12 +337,8 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
360
337
  Check if the property is a visible field.
361
338
  If it is not then we don't allow editing in this component.
362
339
  */
363
- var editFunction = (_editableFields$key = editableFields[key]) !== null && _editableFields$key !== void 0 ? _editableFields$key : function () {
364
- return true;
365
- };
366
- var createFunction = (_creatableFields$key = creatableFields[key]) !== null && _creatableFields$key !== void 0 ? _creatableFields$key : function () {
367
- return true;
368
- };
340
+ const editFunction = (_editableFields$key = editableFields[key]) !== null && _editableFields$key !== void 0 ? _editableFields$key : () => true;
341
+ const createFunction = (_creatableFields$key = creatableFields[key]) !== null && _creatableFields$key !== void 0 ? _creatableFields$key : () => true;
369
342
  /*
370
343
  Next check if this is a new row, if so we should run the createableField function with the data.
371
344
  If it is not a new row, then we run the editableField function with the data,
@@ -374,22 +347,20 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
374
347
  true => Field, false => display value
375
348
  */
376
349
  if (!cd.id && createFunction(cd) || !!cd.id && editFunction(cd)) {
377
- var passedObject = {
350
+ const passedObject = {
378
351
  allValues: values,
379
352
  index: cd === null || cd === void 0 ? void 0 : cd.fieldIndex,
380
- key: key,
353
+ key,
381
354
  name: "".concat(cd.fieldName, ".").concat(key),
382
355
  rowFieldName: cd.fieldName
383
356
  };
384
- var validateFunction = validateFields !== null && validateFields !== void 0 && validateFields[key] ? validateFields === null || validateFields === void 0 ? void 0 : validateFields[key](passedObject) : null;
357
+ const validateFunction = validateFields !== null && validateFields !== void 0 && validateFields[key] ? validateFields === null || validateFields === void 0 ? void 0 : validateFields[key](passedObject) : null;
385
358
  returnValue = fieldComponents[key] ? fieldComponents[key](passedObject) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactFinalForm.Field, {
386
359
  autoFocus: autoFocus,
387
360
  component: _components.TextField,
388
361
  marginBottom0: true,
389
362
  name: "".concat(cd.fieldName, ".").concat(key),
390
- parse: function parse(v) {
391
- return v;
392
- },
363
+ parse: v => v,
393
364
  validate: validateFunction
394
365
  });
395
366
  // After first field, every other field should not autofocus
@@ -416,30 +387,35 @@ var ActionListFieldArray = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2,
416
387
  overrideValue: labelOverrides === null || labelOverrides === void 0 ? void 0 : labelOverrides.new
417
388
  })
418
389
  })]
419
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.MultiColumnList, _objectSpread({
420
- columnMapping: _objectSpread(_objectSpread({}, columnMapping), {}, {
390
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.MultiColumnList, {
391
+ columnMapping: {
392
+ ...columnMapping,
421
393
  actionListActions: kintIntl.formatKintMessage({
422
394
  id: 'actions',
423
395
  overrideValue: labelOverrides === null || labelOverrides === void 0 ? void 0 : labelOverrides.actions
424
396
  })
425
- }),
397
+ },
426
398
  columnWidths: getColumnWidths(),
427
399
  contentData: assignActions(),
428
- formatter: _objectSpread({
429
- actionListActions: renderActionButtons
430
- }, fieldAwareFormatter()),
400
+ formatter: {
401
+ actionListActions: renderActionButtons,
402
+ ...fieldAwareFormatter()
403
+ },
431
404
  interactive: !!onRowClick,
432
- onRowClick: onRowClick ? function (e, row) {
405
+ onRowClick: onRowClick ? (e, row) => {
433
406
  // Make sure we ONLY fire row click from row, and not from action buttons.
434
- var targetIsAction = e.target.closest('[id^=action-button-parent]') !== null;
407
+ const targetIsAction = e.target.closest('[id^=action-button-parent]') !== null;
435
408
  if (!targetIsAction) {
436
- var _ala = row.actionListActions,
437
- rowWithoutActions = _objectWithoutProperties(row, _excluded7);
409
+ const {
410
+ actionListActions: _ala,
411
+ ...rowWithoutActions
412
+ } = row;
438
413
  onRowClick(e, rowWithoutActions);
439
414
  }
440
415
  } : null,
441
- visibleColumns: !hideActionsColumn || !!editing ? [].concat(_toConsumableArray(visibleFields), ['actionListActions']) : visibleFields
442
- }, restOfMclProps))]
416
+ visibleColumns: !hideActionsColumn || !!editing ? [...visibleFields, 'actionListActions'] : visibleFields,
417
+ ...restOfMclProps
418
+ })]
443
419
  });
444
420
  });
445
421
  ActionListFieldArray.propTypes = propTypes;
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  Object.defineProperty(exports, "default", {
7
7
  enumerable: true,
8
- get: function get() {
8
+ get: function () {
9
9
  return _ActionList.default;
10
10
  }
11
11
  });