@leav/ui 0.3.6-a2e27b3 → 0.3.6-a559a4e

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 (583) hide show
  1. package/dist/__mocks__/common/attribute.d.ts +1 -0
  2. package/dist/__mocks__/common/attribute.js +9 -2
  3. package/dist/__mocks__/common/attribute.js.map +1 -1
  4. package/dist/__mocks__/common/form.d.ts +12 -5
  5. package/dist/__mocks__/common/form.js +33 -2
  6. package/dist/__mocks__/common/form.js.map +1 -1
  7. package/dist/__mocks__/common/record.d.ts +13 -2
  8. package/dist/__mocks__/common/record.js.map +1 -1
  9. package/dist/__mocks__/common/value.js +3 -2
  10. package/dist/__mocks__/common/value.js.map +1 -1
  11. package/dist/__mocks__/common/view.js +7 -5
  12. package/dist/__mocks__/common/view.js.map +1 -1
  13. package/dist/__mocks__/mockQuery/mockGetLibraryDetailExtendedQuery.js +1 -1
  14. package/dist/__mocks__/mockQuery/mockGetLibraryDetailExtendedQuery.js.map +1 -1
  15. package/dist/__mocks__/mockQuery/mockGetViewListQuery.js +2 -1
  16. package/dist/__mocks__/mockQuery/mockGetViewListQuery.js.map +1 -1
  17. package/dist/_gqlTypes/index.d.ts +607 -98
  18. package/dist/_gqlTypes/index.js +366 -54
  19. package/dist/_gqlTypes/index.js.map +1 -1
  20. package/dist/_queries/attributes/attributeDetailsFragment.js +0 -1
  21. package/dist/_queries/attributes/attributeDetailsFragment.js.map +1 -1
  22. package/dist/_queries/attributes/getAttributesByLib.js +7 -5
  23. package/dist/_queries/attributes/getAttributesByLib.js.map +1 -1
  24. package/dist/_queries/libraries/getLibraryDetailExtendQuery.d.ts +3 -4
  25. package/dist/_queries/libraries/getLibraryDetailExtendQuery.js +2 -3
  26. package/dist/_queries/libraries/getLibraryDetailExtendQuery.js.map +1 -1
  27. package/dist/_queries/records/createRecordMutation.js +2 -3
  28. package/dist/_queries/records/createRecordMutation.js.map +1 -1
  29. package/dist/_queries/records/getRecordColumnsValues.d.ts +5 -3
  30. package/dist/_queries/records/getRecordColumnsValues.js +4 -1
  31. package/dist/_queries/records/getRecordColumnsValues.js.map +1 -1
  32. package/dist/_queries/records/getRecordsFromLibraryQuery.js +1 -0
  33. package/dist/_queries/records/getRecordsFromLibraryQuery.js.map +1 -1
  34. package/dist/_queries/records/recordFormAttributeFragment.js +3 -0
  35. package/dist/_queries/records/recordFormAttributeFragment.js.map +1 -1
  36. package/dist/_queries/views/saveViewMutation.js +1 -1
  37. package/dist/_queries/views/viewDetailsFragment.js +14 -11
  38. package/dist/_queries/views/viewDetailsFragment.js.map +1 -1
  39. package/dist/_utils/attributeType.d.ts +3 -0
  40. package/dist/_utils/attributeType.js +7 -0
  41. package/dist/_utils/attributeType.js.map +1 -0
  42. package/dist/_utils/index.js +5 -2
  43. package/dist/_utils/index.js.map +1 -1
  44. package/dist/_utils/interleaveElement.d.ts +1 -0
  45. package/dist/{components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducerContext.js → _utils/interleaveElement.js} +2 -6
  46. package/dist/_utils/interleaveElement.js.map +1 -0
  47. package/dist/antdTheme/index.d.ts +0 -3
  48. package/dist/antdTheme/index.js +3 -42
  49. package/dist/antdTheme/index.js.map +1 -1
  50. package/dist/components/CreateDirectory/CreateDirectory.js +1 -1
  51. package/dist/components/CreateDirectory/CreateDirectory.js.map +1 -1
  52. package/dist/components/EditApplication/EditApplication.js +2 -2
  53. package/dist/components/EditApplication/EditApplication.js.map +1 -1
  54. package/dist/components/EditApplication/_types.d.ts +2 -2
  55. package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfo.js +0 -1
  56. package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfo.js.map +1 -1
  57. package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/EditAttributeInfoForm.js +2 -5
  58. package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/EditAttributeInfoForm.js.map +1 -1
  59. package/dist/components/Explorer/DataView.d.ts +16 -1
  60. package/dist/components/Explorer/DataView.js +104 -49
  61. package/dist/components/Explorer/DataView.js.map +1 -1
  62. package/dist/components/Explorer/Explorer.d.ts +12 -4
  63. package/dist/components/Explorer/Explorer.js +103 -22
  64. package/dist/components/Explorer/Explorer.js.map +1 -1
  65. package/dist/components/Explorer/ExplorerTitle.d.ts +2 -0
  66. package/dist/components/Explorer/ExplorerTitle.js +30 -11
  67. package/dist/components/Explorer/ExplorerTitle.js.map +1 -1
  68. package/dist/components/Explorer/ExplorerToolbar.d.ts +5 -0
  69. package/dist/components/Explorer/ExplorerToolbar.js +49 -0
  70. package/dist/components/Explorer/ExplorerToolbar.js.map +1 -0
  71. package/dist/components/Explorer/IdCard.d.ts +7 -0
  72. package/dist/components/Explorer/IdCard.js +15 -0
  73. package/dist/components/Explorer/IdCard.js.map +1 -0
  74. package/dist/components/Explorer/TableCell.d.ts +8 -0
  75. package/dist/components/Explorer/TableCell.js +152 -0
  76. package/dist/components/Explorer/TableCell.js.map +1 -0
  77. package/dist/components/Explorer/TableTagGroup.d.ts +7 -0
  78. package/dist/components/Explorer/TableTagGroup.js +30 -0
  79. package/dist/components/Explorer/TableTagGroup.js.map +1 -0
  80. package/dist/components/Explorer/_constants.d.ts +5 -0
  81. package/dist/components/Explorer/_constants.js +18 -0
  82. package/dist/components/Explorer/_constants.js.map +1 -0
  83. package/dist/components/Explorer/_queries/prepareFiltersForRequest.d.ts +4 -0
  84. package/dist/components/Explorer/_queries/prepareFiltersForRequest.js +99 -0
  85. package/dist/components/Explorer/_queries/prepareFiltersForRequest.js.map +1 -0
  86. package/dist/components/Explorer/_queries/useExplorerData.d.ts +30 -6
  87. package/dist/components/Explorer/_queries/useExplorerData.js +115 -19
  88. package/dist/components/Explorer/_queries/useExplorerData.js.map +1 -1
  89. package/dist/components/Explorer/_types.d.ts +102 -4
  90. package/dist/components/Explorer/_types.js +7 -1
  91. package/dist/components/Explorer/_types.js.map +1 -1
  92. package/dist/components/Explorer/{useEditAction.d.ts → actions-item/useEditItemAction.d.ts} +4 -4
  93. package/dist/components/Explorer/{useEditAction.js → actions-item/useEditItemAction.js} +15 -13
  94. package/dist/components/Explorer/actions-item/useEditItemAction.js.map +1 -0
  95. package/dist/components/Explorer/actions-item/useRemoveItemAction.d.ts +23 -0
  96. package/dist/components/Explorer/actions-item/useRemoveItemAction.js +109 -0
  97. package/dist/components/Explorer/actions-item/useRemoveItemAction.js.map +1 -0
  98. package/dist/components/Explorer/actions-mass/useDeactivateMassAction.d.ts +27 -0
  99. package/dist/components/Explorer/actions-mass/useDeactivateMassAction.js +71 -0
  100. package/dist/components/Explorer/actions-mass/useDeactivateMassAction.js.map +1 -0
  101. package/dist/components/Explorer/actions-mass/useMassActions.d.ts +28 -0
  102. package/dist/components/Explorer/actions-mass/useMassActions.js +111 -0
  103. package/dist/components/Explorer/actions-mass/useMassActions.js.map +1 -0
  104. package/dist/components/Explorer/{useCreateAction.d.ts → actions-primary/useCreatePrimaryAction.d.ts} +9 -5
  105. package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.js +75 -0
  106. package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.js.map +1 -0
  107. package/dist/components/Explorer/actions-primary/useLinkPrimaryAction.d.ts +17 -0
  108. package/dist/components/Explorer/actions-primary/useLinkPrimaryAction.js +38 -0
  109. package/dist/components/Explorer/actions-primary/useLinkPrimaryAction.js.map +1 -0
  110. package/dist/components/Explorer/actions-primary/usePrimaryActions.d.ts +12 -0
  111. package/dist/components/Explorer/actions-primary/usePrimaryActions.js +25 -0
  112. package/dist/components/Explorer/actions-primary/usePrimaryActions.js.map +1 -0
  113. package/dist/components/Explorer/conditionsHelper.d.ts +2 -0
  114. package/dist/components/Explorer/conditionsHelper.js +16 -0
  115. package/dist/components/Explorer/conditionsHelper.js.map +1 -0
  116. package/dist/components/Explorer/index.d.ts +1 -3
  117. package/dist/components/Explorer/index.js +1 -3
  118. package/dist/components/Explorer/index.js.map +1 -1
  119. package/dist/components/Explorer/link-item/LinkModal.d.ts +7 -0
  120. package/dist/components/Explorer/link-item/LinkModal.js +73 -0
  121. package/dist/components/Explorer/link-item/LinkModal.js.map +1 -0
  122. package/dist/components/Explorer/link-item/useLinkMassAction.d.ts +24 -0
  123. package/dist/components/Explorer/link-item/useLinkMassAction.js +57 -0
  124. package/dist/components/Explorer/link-item/useLinkMassAction.js.map +1 -0
  125. package/dist/components/Explorer/list-saved-views/SavedViews.d.ts +2 -0
  126. package/dist/components/Explorer/list-saved-views/SavedViews.js +74 -0
  127. package/dist/components/Explorer/list-saved-views/SavedViews.js.map +1 -0
  128. package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/ColumnItem.d.ts +2 -1
  129. package/dist/components/Explorer/manage-view-settings/_shared/ColumnItem.js +85 -0
  130. package/dist/components/Explorer/manage-view-settings/_shared/ColumnItem.js.map +1 -0
  131. package/dist/components/Explorer/manage-view-settings/_shared/CommonFilterItem.d.ts +6 -0
  132. package/dist/components/Explorer/manage-view-settings/_shared/CommonFilterItem.js +19 -0
  133. package/dist/components/Explorer/manage-view-settings/_shared/CommonFilterItem.js.map +1 -0
  134. package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.d.ts +13 -0
  135. package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.js +67 -0
  136. package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.js.map +1 -0
  137. package/dist/components/Explorer/manage-view-settings/_shared/useTransformFilters.d.ts +17 -0
  138. package/dist/components/Explorer/manage-view-settings/_shared/useTransformFilters.js +93 -0
  139. package/dist/components/Explorer/manage-view-settings/_shared/useTransformFilters.js.map +1 -0
  140. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.d.ts +6 -0
  141. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js +28 -0
  142. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js.map +1 -0
  143. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.d.ts +6 -0
  144. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js +55 -0
  145. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js.map +1 -0
  146. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.d.ts +8 -0
  147. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js +12 -0
  148. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js.map +1 -0
  149. package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.d.ts +4 -0
  150. package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js +88 -0
  151. package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js.map +1 -0
  152. package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.d.ts +9 -0
  153. package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.js +33 -0
  154. package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.js.map +1 -0
  155. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/BooleanAttributeDropdown.d.ts +3 -0
  156. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/BooleanAttributeDropdown.js +22 -0
  157. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/BooleanAttributeDropdown.js.map +1 -0
  158. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/ColorAttributeDropDown.d.ts +3 -0
  159. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/ColorAttributeDropDown.js +11 -0
  160. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/ColorAttributeDropDown.js.map +1 -0
  161. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/DateAttributeDropDown.d.ts +3 -0
  162. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/DateAttributeDropDown.js +66 -0
  163. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/DateAttributeDropDown.js.map +1 -0
  164. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/DateRangeAttributeDropDown.d.ts +3 -0
  165. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/DateRangeAttributeDropDown.js +11 -0
  166. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/DateRangeAttributeDropDown.js.map +1 -0
  167. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/EncryptedAttributeDropDown.d.ts +3 -0
  168. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/EncryptedAttributeDropDown.js +11 -0
  169. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/EncryptedAttributeDropDown.js.map +1 -0
  170. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/ExtendedAttributeDropDown.d.ts +3 -0
  171. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/ExtendedAttributeDropDown.js +11 -0
  172. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/ExtendedAttributeDropDown.js.map +1 -0
  173. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterDropDown.d.ts +3 -0
  174. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterDropDown.js +35 -0
  175. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterDropDown.js.map +1 -0
  176. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterDropdownContent.d.ts +7 -0
  177. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterDropdownContent.js +40 -0
  178. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterDropdownContent.js.map +1 -0
  179. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterValueList.d.ts +10 -0
  180. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterValueList.js +75 -0
  181. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/FilterValueList.js.map +1 -0
  182. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/LinkAttributeDropdown.d.ts +3 -0
  183. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/LinkAttributeDropdown.js +79 -0
  184. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/LinkAttributeDropdown.js.map +1 -0
  185. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/NumericAttributeDropDown.d.ts +3 -0
  186. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/NumericAttributeDropDown.js +19 -0
  187. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/NumericAttributeDropDown.js.map +1 -0
  188. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/TextAttributeDropDown.d.ts +3 -0
  189. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/TextAttributeDropDown.js +28 -0
  190. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/TextAttributeDropDown.js.map +1 -0
  191. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/_types.d.ts +10 -0
  192. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/_types.js +2 -0
  193. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/_types.js.map +1 -0
  194. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/useConditionOptionsByType.d.ts +12 -0
  195. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/useConditionOptionsByType.js +108 -0
  196. package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/useConditionOptionsByType.js.map +1 -0
  197. package/dist/components/Explorer/manage-view-settings/index.d.ts +8 -0
  198. package/dist/components/Explorer/manage-view-settings/index.js +11 -0
  199. package/dist/components/Explorer/manage-view-settings/index.js.map +1 -0
  200. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContext.d.ts +3 -1
  201. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContext.js +3 -2
  202. package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.js.map +1 -0
  203. package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.d.ts +8 -0
  204. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContextProvider.js +4 -3
  205. package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.js.map +1 -0
  206. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/SidePanel.js +4 -4
  207. package/dist/components/Explorer/manage-view-settings/open-view-settings/SidePanel.js.map +1 -0
  208. package/dist/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.js.map +1 -0
  209. package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.d.ts +12 -0
  210. package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.js +64 -0
  211. package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.js.map +1 -0
  212. package/dist/components/Explorer/manage-view-settings/router-menu/SettingItem.js.map +1 -0
  213. package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingsPanel.d.ts +2 -1
  214. package/dist/components/Explorer/manage-view-settings/router-menu/SettingsPanel.js +36 -0
  215. package/dist/components/Explorer/manage-view-settings/router-menu/SettingsPanel.js.map +1 -0
  216. package/dist/components/Explorer/manage-view-settings/save-view/SaveViewModal.d.ts +8 -0
  217. package/dist/components/Explorer/manage-view-settings/save-view/SaveViewModal.js +40 -0
  218. package/dist/components/Explorer/manage-view-settings/save-view/SaveViewModal.js.map +1 -0
  219. package/dist/components/Explorer/manage-view-settings/save-view/ViewActionsButtons.d.ts +1 -0
  220. package/dist/components/Explorer/manage-view-settings/save-view/ViewActionsButtons.js +24 -0
  221. package/dist/components/Explorer/manage-view-settings/save-view/ViewActionsButtons.js.map +1 -0
  222. package/dist/components/Explorer/manage-view-settings/save-view/prepareViewForRequest.d.ts +3 -0
  223. package/dist/components/Explorer/manage-view-settings/save-view/prepareViewForRequest.js +24 -0
  224. package/dist/components/Explorer/manage-view-settings/save-view/prepareViewForRequest.js.map +1 -0
  225. package/dist/components/Explorer/manage-view-settings/save-view/useCreateNewView.d.ts +3 -0
  226. package/dist/components/Explorer/manage-view-settings/save-view/useCreateNewView.js +51 -0
  227. package/dist/components/Explorer/manage-view-settings/save-view/useCreateNewView.js.map +1 -0
  228. package/dist/components/Explorer/manage-view-settings/save-view/useResetView.d.ts +3 -0
  229. package/dist/components/Explorer/manage-view-settings/save-view/useResetView.js +20 -0
  230. package/dist/components/Explorer/manage-view-settings/save-view/useResetView.js.map +1 -0
  231. package/dist/components/Explorer/manage-view-settings/save-view/useUpdateView.d.ts +3 -0
  232. package/dist/components/Explorer/manage-view-settings/save-view/useUpdateView.js +48 -0
  233. package/dist/components/Explorer/manage-view-settings/save-view/useUpdateView.js.map +1 -0
  234. package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.d.ts +4 -0
  235. package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.js +111 -0
  236. package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.js.map +1 -0
  237. package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.d.ts +10 -0
  238. package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.js +32 -0
  239. package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.js.map +1 -0
  240. package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.d.ts +6 -0
  241. package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js +11 -0
  242. package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js.map +1 -0
  243. package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.d.ts +4 -0
  244. package/dist/components/{RecordEdition/EditRecordContent/reducers/standardFieldReducer/useStandardFieldReducer.js → Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js} +3 -3
  245. package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js.map +1 -0
  246. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.d.ts +4 -0
  247. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js +35 -0
  248. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js.map +1 -0
  249. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.d.ts +174 -0
  250. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js +281 -0
  251. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js.map +1 -0
  252. package/dist/components/Explorer/useColumnWidth.d.ts +8 -0
  253. package/dist/components/Explorer/useColumnWidth.js +49 -0
  254. package/dist/components/Explorer/useColumnWidth.js.map +1 -0
  255. package/dist/components/Explorer/useLoadView.d.ts +3 -0
  256. package/dist/components/Explorer/useLoadView.js +79 -0
  257. package/dist/components/Explorer/useLoadView.js.map +1 -0
  258. package/dist/components/Explorer/usePagination.d.ts +7 -0
  259. package/dist/components/Explorer/usePagination.js +25 -0
  260. package/dist/components/Explorer/usePagination.js.map +1 -0
  261. package/dist/components/Explorer/useSearchInput.d.ts +16 -0
  262. package/dist/components/Explorer/useSearchInput.js +39 -0
  263. package/dist/components/Explorer/useSearchInput.js.map +1 -0
  264. package/dist/components/Explorer/useTableScrollableHeight.d.ts +5 -0
  265. package/dist/components/Explorer/useTableScrollableHeight.js +15 -0
  266. package/dist/components/Explorer/useTableScrollableHeight.js.map +1 -0
  267. package/dist/components/Explorer/useViewSettingsReducer.d.ts +8 -0
  268. package/dist/components/Explorer/useViewSettingsReducer.js +130 -0
  269. package/dist/components/Explorer/useViewSettingsReducer.js.map +1 -0
  270. package/dist/components/ExportModal/ExportModal.js +2 -2
  271. package/dist/components/ExportModal/ExportModal.js.map +1 -1
  272. package/dist/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.js +5 -5
  273. package/dist/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.js.map +1 -1
  274. package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.js +2 -2
  275. package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.js.map +1 -1
  276. package/dist/components/LibraryItemsList/LibraryItemsListContent/LibraryItemsListContent.js +7 -11
  277. package/dist/components/LibraryItemsList/LibraryItemsListContent/LibraryItemsListContent.js.map +1 -1
  278. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/StandardCell.js +7 -2
  279. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/StandardCell.js.map +1 -1
  280. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/Header.js +7 -5
  281. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/Header.js.map +1 -1
  282. package/dist/components/LibraryItemsList/MenuView/MenuView.js +4 -9
  283. package/dist/components/LibraryItemsList/MenuView/MenuView.js.map +1 -1
  284. package/dist/components/LibraryItemsList/ViewPanel/EditView/EditView.js +2 -3
  285. package/dist/components/LibraryItemsList/ViewPanel/EditView/EditView.js.map +1 -1
  286. package/dist/components/LibraryItemsList/ViewPanel/View/View.js +3 -3
  287. package/dist/components/LibraryItemsList/ViewPanel/View/View.js.map +1 -1
  288. package/dist/components/LibraryItemsList/helpers/getFieldsFromView.js +4 -9
  289. package/dist/components/LibraryItemsList/helpers/getFieldsFromView.js.map +1 -1
  290. package/dist/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.js +7 -5
  291. package/dist/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.js.map +1 -1
  292. package/dist/components/LibraryItemsList/hooks/useSearchReducer/_types.d.ts +1 -1
  293. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.d.ts +1 -1
  294. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.js +25 -33
  295. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.js.map +1 -1
  296. package/dist/components/RecordEdition/EditRecord/EditRecord.d.ts +1 -0
  297. package/dist/components/RecordEdition/EditRecord/EditRecord.js +82 -76
  298. package/dist/components/RecordEdition/EditRecord/EditRecord.js.map +1 -1
  299. package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.d.ts +2 -1
  300. package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.js +17 -4
  301. package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.js.map +1 -1
  302. package/dist/components/RecordEdition/EditRecordContent/_types.d.ts +17 -22
  303. package/dist/components/RecordEdition/EditRecordContent/_types.js.map +1 -1
  304. package/dist/components/RecordEdition/EditRecordContent/antdUtils.d.ts +5 -1
  305. package/dist/components/RecordEdition/EditRecordContent/antdUtils.js +44 -34
  306. package/dist/components/RecordEdition/EditRecordContent/antdUtils.js.map +1 -1
  307. package/dist/components/RecordEdition/EditRecordContent/helpers/extractFormElements/extractFormElements.d.ts +3 -1
  308. package/dist/components/RecordEdition/EditRecordContent/helpers/extractFormElements/extractFormElements.js +8 -2
  309. package/dist/components/RecordEdition/EditRecordContent/helpers/extractFormElements/extractFormElements.js.map +1 -1
  310. package/dist/components/RecordEdition/EditRecordContent/hooks/useCreateRecordMutation.d.ts +5 -0
  311. package/dist/components/RecordEdition/EditRecordContent/hooks/useCreateRecordMutation.js +28 -0
  312. package/dist/components/RecordEdition/EditRecordContent/hooks/useCreateRecordMutation.js.map +1 -0
  313. package/dist/components/RecordEdition/EditRecordContent/hooks/useExecuteSaveValueBatchMutation.js.map +1 -1
  314. package/dist/components/RecordEdition/EditRecordContent/shared/ValueDetailsBtn/ValueDetailsBtn.js +1 -7
  315. package/dist/components/RecordEdition/EditRecordContent/shared/ValueDetailsBtn/ValueDetailsBtn.js.map +1 -1
  316. package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.d.ts +3 -1
  317. package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.js +2 -2
  318. package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.js.map +1 -1
  319. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/LinkField.js +2 -2
  320. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/LinkField.js.map +1 -1
  321. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MonoValueSelect/MonoValueSelect.d.ts +0 -1
  322. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MonoValueSelect/MonoValueSelect.js +2 -7
  323. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MonoValueSelect/MonoValueSelect.js.map +1 -1
  324. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MultiValueSelect/MultiValueSelect.d.ts +0 -1
  325. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MultiValueSelect/MultiValueSelect.js +2 -9
  326. package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MultiValueSelect/MultiValueSelect.js.map +1 -1
  327. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/ComputeIndicator.d.ts +6 -0
  328. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/ComputeIndicator.js +16 -0
  329. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/ComputeIndicator.js.map +1 -0
  330. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/DeleteAllValuesButton.d.ts +4 -0
  331. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/DeleteAllValuesButton.js +25 -0
  332. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/DeleteAllValuesButton.js.map +1 -0
  333. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.d.ts +5 -2
  334. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.js +203 -186
  335. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.js.map +1 -1
  336. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.d.ts +2 -8
  337. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.js +11 -30
  338. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.js.map +1 -1
  339. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.d.ts +2 -13
  340. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.js +79 -45
  341. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.js.map +1 -1
  342. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.d.ts +3 -14
  343. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.js +37 -46
  344. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.js.map +1 -1
  345. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.d.ts +3 -14
  346. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.js +14 -74
  347. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.js.map +1 -1
  348. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.d.ts +3 -14
  349. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.js +33 -49
  350. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.js.map +1 -1
  351. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.d.ts +3 -14
  352. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.js +33 -60
  353. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.js.map +1 -1
  354. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.d.ts +3 -14
  355. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.js +52 -64
  356. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.js.map +1 -1
  357. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.d.ts +3 -14
  358. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.js +33 -56
  359. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.js.map +1 -1
  360. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.d.ts +16 -9
  361. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.js +56 -402
  362. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.js.map +1 -1
  363. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/DSListSelect.d.ts +4 -0
  364. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/{MonoValueSelect.js → DSListSelect.js} +48 -52
  365. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/DSListSelect.js.map +1 -0
  366. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/_types.d.ts +2 -9
  367. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.d.ts +15 -0
  368. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.js +2 -0
  369. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.js.map +1 -0
  370. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/calculatedInheritedFlags.d.ts +42 -0
  371. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/calculatedInheritedFlags.js +56 -0
  372. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/calculatedInheritedFlags.js.map +1 -0
  373. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.d.ts +12 -0
  374. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.js +32 -0
  375. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.js.map +1 -0
  376. package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/TreeField.js +4 -7
  377. package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/TreeField.js.map +1 -1
  378. package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/ValuesAdd/ValuesAdd.js +2 -2
  379. package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/ValuesAdd/ValuesAdd.js.map +1 -1
  380. package/dist/components/RecordEdition/EditRecordModal/EditRecordModal.js +10 -4
  381. package/dist/components/RecordEdition/EditRecordModal/EditRecordModal.js.map +1 -1
  382. package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.d.ts +2 -0
  383. package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.js +2 -2
  384. package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.js.map +1 -1
  385. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/AttributeSummary.d.ts +7 -0
  386. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/AttributeSummary.js +9 -0
  387. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/AttributeSummary.js.map +1 -0
  388. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/index.d.ts +2 -0
  389. package/dist/components/RecordEdition/EditRecordSidebar/{ValueDetails/AttributeDetails → AttributeSummary}/index.js +2 -2
  390. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/index.js.map +1 -0
  391. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/useAttributeInformations.d.ts +2 -0
  392. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/useAttributeInformations.js +25 -0
  393. package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/useAttributeInformations.js.map +1 -0
  394. package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/Breadcrumb.d.ts +3 -0
  395. package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/Breadcrumb.js +53 -0
  396. package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/Breadcrumb.js.map +1 -0
  397. package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/index.d.ts +2 -0
  398. package/dist/components/RecordEdition/EditRecordSidebar/{ValueDetails → Breacrumb}/index.js +2 -2
  399. package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/index.js.map +1 -0
  400. package/dist/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.d.ts +4 -1
  401. package/dist/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.js +41 -6
  402. package/dist/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.js.map +1 -1
  403. package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.d.ts +4 -7
  404. package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.js +6 -8
  405. package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.js.map +1 -1
  406. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/RecordInformations.d.ts +9 -0
  407. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/RecordInformations.js +42 -0
  408. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/RecordInformations.js.map +1 -0
  409. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/useRecordInformations.d.ts +6 -0
  410. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/useRecordInformations.js +35 -0
  411. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/useRecordInformations.js.map +1 -0
  412. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.d.ts +2 -281
  413. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.js +25 -56
  414. package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.js.map +1 -1
  415. package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/ValuesSummary.d.ts +8 -0
  416. package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/ValuesSummary.js +73 -0
  417. package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/ValuesSummary.js.map +1 -0
  418. package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/index.d.ts +2 -0
  419. package/dist/components/RecordEdition/EditRecordSidebar/{ValueDetails/ValueMetadata → ValuesSummary}/index.js +2 -2
  420. package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/index.js.map +1 -0
  421. package/dist/components/RecordEdition/{EditRecordContent → EditRecordSkeleton}/EditRecordSkeleton.d.ts +1 -1
  422. package/dist/components/RecordEdition/{EditRecordContent → EditRecordSkeleton}/EditRecordSkeleton.js +2 -2
  423. package/dist/components/RecordEdition/EditRecordSkeleton/EditRecordSkeleton.js.map +1 -0
  424. package/dist/components/RecordEdition/EditRecordSkeleton/index.d.ts +2 -0
  425. package/dist/components/RecordEdition/{EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler → EditRecordSkeleton}/index.js +2 -1
  426. package/dist/components/RecordEdition/EditRecordSkeleton/index.js.map +1 -0
  427. package/dist/components/RecordEdition/editRecordReducer/editRecordReducer.d.ts +12 -10
  428. package/dist/components/RecordEdition/editRecordReducer/editRecordReducer.js +15 -13
  429. package/dist/components/RecordEdition/editRecordReducer/editRecordReducer.js.map +1 -1
  430. package/dist/components/RecordEdition/index.d.ts +1 -0
  431. package/dist/components/RecordEdition/index.js +1 -0
  432. package/dist/components/RecordEdition/index.js.map +1 -1
  433. package/dist/components/SelectTreeNode/SelectTreeNode.d.ts +4 -7
  434. package/dist/components/SelectTreeNode/SelectTreeNode.js +17 -135
  435. package/dist/components/SelectTreeNode/SelectTreeNode.js.map +1 -1
  436. package/dist/components/SelectTreeNode/SelectTreeNodeContent.d.ts +16 -0
  437. package/dist/components/SelectTreeNode/SelectTreeNodeContent.js +129 -0
  438. package/dist/components/SelectTreeNode/SelectTreeNodeContent.js.map +1 -0
  439. package/dist/components/SelectTreeNode/index.d.ts +1 -1
  440. package/dist/components/SelectTreeNode/index.js +1 -1
  441. package/dist/components/SelectTreeNode/index.js.map +1 -1
  442. package/dist/components/SelectTreeNodeModal/SelectTreeNodeModal.d.ts +4 -7
  443. package/dist/components/SelectTreeNodeModal/SelectTreeNodeModal.js +10 -10
  444. package/dist/components/SelectTreeNodeModal/SelectTreeNodeModal.js.map +1 -1
  445. package/dist/components/SelectTreeNodeModal/index.d.ts +1 -2
  446. package/dist/components/SelectTreeNodeModal/index.js +1 -2
  447. package/dist/components/SelectTreeNodeModal/index.js.map +1 -1
  448. package/dist/components/UploadFiles/UploadFiles.js +1 -1
  449. package/dist/components/UploadFiles/UploadFiles.js.map +1 -1
  450. package/dist/components/ValuesVersionConfigurator/VersionTree/VersionTree.js +2 -2
  451. package/dist/components/ValuesVersionConfigurator/VersionTree/VersionTree.js.map +1 -1
  452. package/dist/constants.d.ts +3 -0
  453. package/dist/constants.js +3 -0
  454. package/dist/constants.js.map +1 -1
  455. package/dist/hooks/useDebouncedValue/index.d.ts +1 -0
  456. package/dist/{components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo → hooks/useDebouncedValue}/index.js +1 -2
  457. package/dist/hooks/useDebouncedValue/index.js.map +1 -0
  458. package/dist/hooks/useExecuteSaveViewMutation/index.d.ts +1 -0
  459. package/dist/{components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath → hooks/useExecuteSaveViewMutation}/index.js +1 -2
  460. package/dist/hooks/useExecuteSaveViewMutation/index.js.map +1 -0
  461. package/dist/hooks/useExecuteSaveViewMutation/useExecuteSaveViewMutation.d.ts +6 -0
  462. package/dist/hooks/{useExecuteAddViewMutation/useExecuteAddViewMutation.js → useExecuteSaveViewMutation/useExecuteSaveViewMutation.js} +8 -7
  463. package/dist/hooks/useExecuteSaveViewMutation/useExecuteSaveViewMutation.js.map +1 -0
  464. package/dist/hooks/useGetRecordForm/useGetRecordForm.d.ts +1 -0
  465. package/dist/hooks/useGetRecordForm/useGetRecordForm.js.map +1 -1
  466. package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.d.ts +1 -1
  467. package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.js +2 -2
  468. package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.js.map +1 -1
  469. package/dist/locales/en/shared.json +108 -18
  470. package/dist/locales/fr/shared.json +110 -20
  471. package/dist/types/views.d.ts +4 -4
  472. package/package.json +7 -2
  473. package/dist/components/Explorer/edit-settings/ColumnItem.js +0 -62
  474. package/dist/components/Explorer/edit-settings/ColumnItem.js.map +0 -1
  475. package/dist/components/Explorer/edit-settings/DisplayMode.d.ts +0 -6
  476. package/dist/components/Explorer/edit-settings/DisplayMode.js +0 -28
  477. package/dist/components/Explorer/edit-settings/DisplayMode.js.map +0 -1
  478. package/dist/components/Explorer/edit-settings/DisplayModeTable.d.ts +0 -6
  479. package/dist/components/Explorer/edit-settings/DisplayModeTable.js +0 -77
  480. package/dist/components/Explorer/edit-settings/DisplayModeTable.js.map +0 -1
  481. package/dist/components/Explorer/edit-settings/EditSettingsContext.js.map +0 -1
  482. package/dist/components/Explorer/edit-settings/EditSettingsContextProvider.d.ts +0 -2
  483. package/dist/components/Explorer/edit-settings/EditSettingsContextProvider.js.map +0 -1
  484. package/dist/components/Explorer/edit-settings/SettingItem.js.map +0 -1
  485. package/dist/components/Explorer/edit-settings/SettingsPanel.js +0 -53
  486. package/dist/components/Explorer/edit-settings/SettingsPanel.js.map +0 -1
  487. package/dist/components/Explorer/edit-settings/SidePanel.js.map +0 -1
  488. package/dist/components/Explorer/edit-settings/useEditSettings.js.map +0 -1
  489. package/dist/components/Explorer/edit-settings/useGetLibraryColumns.d.ts +0 -10
  490. package/dist/components/Explorer/edit-settings/useGetLibraryColumns.js +0 -24
  491. package/dist/components/Explorer/edit-settings/useGetLibraryColumns.js.map +0 -1
  492. package/dist/components/Explorer/edit-settings/useOpenSettings.d.ts +0 -1
  493. package/dist/components/Explorer/edit-settings/useOpenSettings.js +0 -19
  494. package/dist/components/Explorer/edit-settings/useOpenSettings.js.map +0 -1
  495. package/dist/components/Explorer/useCreateAction.js +0 -40
  496. package/dist/components/Explorer/useCreateAction.js.map +0 -1
  497. package/dist/components/Explorer/useDeactivateAction.d.ts +0 -12
  498. package/dist/components/Explorer/useDeactivateAction.js +0 -51
  499. package/dist/components/Explorer/useDeactivateAction.js.map +0 -1
  500. package/dist/components/Explorer/useEditAction.js.map +0 -1
  501. package/dist/components/Explorer/usePrimaryActions.d.ts +0 -19
  502. package/dist/components/Explorer/usePrimaryActions.js +0 -28
  503. package/dist/components/Explorer/usePrimaryActions.js.map +0 -1
  504. package/dist/components/RecordEdition/EditRecordContent/EditRecordSkeleton.js.map +0 -1
  505. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/index.d.ts +0 -2
  506. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/index.js +0 -6
  507. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/index.js.map +0 -1
  508. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducer.d.ts +0 -138
  509. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducer.js +0 -361
  510. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducer.js.map +0 -1
  511. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducerContext.d.ts +0 -7
  512. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducerContext.js.map +0 -1
  513. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/useStandardFieldReducer.d.ts +0 -1
  514. package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/useStandardFieldReducer.js.map +0 -1
  515. package/dist/components/RecordEdition/EditRecordContent/shared/ValueDetailsBtn/useValueDetailsButton.d.ts +0 -8
  516. package/dist/components/RecordEdition/EditRecordContent/shared/ValueDetailsBtn/useValueDetailsButton.js +0 -23
  517. package/dist/components/RecordEdition/EditRecordContent/shared/ValueDetailsBtn/useValueDetailsButton.js.map +0 -1
  518. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.d.ts +0 -3
  519. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.js +0 -14
  520. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.js.map +0 -1
  521. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.d.ts +0 -3
  522. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.js +0 -22
  523. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.js.map +0 -1
  524. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.d.ts +0 -3
  525. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.js +0 -22
  526. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.js.map +0 -1
  527. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.d.ts +0 -3
  528. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.js +0 -19
  529. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.js.map +0 -1
  530. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.d.ts +0 -3
  531. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.js +0 -32
  532. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.js.map +0 -1
  533. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.d.ts +0 -3
  534. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.js +0 -51
  535. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.js.map +0 -1
  536. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.d.ts +0 -3
  537. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.js +0 -26
  538. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.js.map +0 -1
  539. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueDisplayHandler.d.ts +0 -13
  540. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueDisplayHandler.js +0 -90
  541. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueDisplayHandler.js.map +0 -1
  542. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/ColorPickerBlock.d.ts +0 -7
  543. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/ColorPickerBlock.js +0 -45
  544. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/ColorPickerBlock.js.map +0 -1
  545. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/StandardFieldValueRead.d.ts +0 -9
  546. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/StandardFieldValueRead.js +0 -141
  547. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/StandardFieldValueRead.js.map +0 -1
  548. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/index.d.ts +0 -1
  549. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/index.js.map +0 -1
  550. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/MonoValueSelect.d.ts +0 -3
  551. package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/MonoValueSelect.js.map +0 -1
  552. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/AttributeDetails.d.ts +0 -6
  553. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/AttributeDetails.js +0 -56
  554. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/AttributeDetails.js.map +0 -1
  555. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/index.d.ts +0 -2
  556. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/index.js.map +0 -1
  557. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/TreeValuePath.d.ts +0 -8
  558. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/TreeValuePath.js +0 -41
  559. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/TreeValuePath.js.map +0 -1
  560. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/index.d.ts +0 -2
  561. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/index.js.map +0 -1
  562. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueDetails.d.ts +0 -10
  563. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueDetails.js +0 -63
  564. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueDetails.js.map +0 -1
  565. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/ValueInfo.d.ts +0 -2
  566. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/ValueInfo.js +0 -76
  567. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/ValueInfo.js.map +0 -1
  568. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/index.d.ts +0 -2
  569. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/index.js.map +0 -1
  570. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/ValueMetadata.d.ts +0 -11
  571. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/ValueMetadata.js +0 -43
  572. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/ValueMetadata.js.map +0 -1
  573. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/index.d.ts +0 -2
  574. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/index.js.map +0 -1
  575. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/index.d.ts +0 -2
  576. package/dist/components/RecordEdition/EditRecordSidebar/ValueDetails/index.js.map +0 -1
  577. package/dist/hooks/useExecuteAddViewMutation/useExecuteAddViewMutation.d.ts +0 -6
  578. package/dist/hooks/useExecuteAddViewMutation/useExecuteAddViewMutation.js.map +0 -1
  579. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/SidePanel.d.ts +0 -0
  580. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useEditSettings.d.ts +0 -0
  581. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useEditSettings.js +0 -0
  582. /package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingItem.d.ts +0 -0
  583. /package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingItem.js +0 -0
@@ -0,0 +1,174 @@
1
+ import { SortOrder } from '../../../../_gqlTypes';
2
+ import { DefaultViewSettings, Entrypoint, ExplorerFilter, IUserView } from '../../_types';
3
+ import { MASS_SELECTION_ALL } from '../../_constants';
4
+ export type ViewType = 'table' | 'list' | 'timeline' | 'mosaic';
5
+ export type MassSelection = string[] | typeof MASS_SELECTION_ALL;
6
+ export declare const ViewSettingsActionTypes: {
7
+ readonly RESET: "RESET";
8
+ readonly ADD_ATTRIBUTE: "ADD_ATTRIBUTE";
9
+ readonly REMOVE_ATTRIBUTE: "REMOVE_ATTRIBUTE";
10
+ readonly MOVE_ATTRIBUTE: "MOVE_ATTRIBUTE";
11
+ readonly RESET_ATTRIBUTES: "RESET_ATTRIBUTES";
12
+ readonly CHANGE_VIEW_TYPE: "CHANGE_VIEW_TYPE";
13
+ readonly ADD_SORT: "ADD_SORT";
14
+ readonly REMOVE_SORT: "REMOVE_SORT";
15
+ readonly MOVE_SORT: "MOVE_SORT";
16
+ readonly CHANGE_SORT_ORDER: "CHANGE_SORT_ORDER";
17
+ readonly CHANGE_PAGE_SIZE: "CHANGE_PAGE_SIZE";
18
+ readonly CHANGE_FULLTEXT_SEARCH: "CHANGE_FULLTEXT_SEARCH";
19
+ readonly CLEAR_FULLTEXT_SEARCH: "CLEAR_FULLTEXT_SEARCH";
20
+ readonly ADD_FILTER: "ADD_FILTER";
21
+ readonly RESET_FILTER: "RESET_FILTER";
22
+ readonly REMOVE_FILTER: "REMOVE_FILTER";
23
+ readonly MOVE_FILTER: "MOVE_FILTER";
24
+ readonly CHANGE_FILTER_CONFIG: "CHANGE_FILTER_CONFIG";
25
+ readonly SET_SELECTED_KEYS: "SET_SELECTED_KEYS";
26
+ readonly RESTORE_INITIAL_VIEW_SETTINGS: "RESTORE_INITIAL_VIEW_SETTINGS";
27
+ readonly UPDATE_VIEWS: "UPDATE_VIEWS";
28
+ readonly LOAD_VIEW: "LOAD_VIEW";
29
+ };
30
+ export interface IViewSettingsState {
31
+ libraryId: string;
32
+ viewId: string | null;
33
+ viewLabels: Record<string, string>;
34
+ viewModified: boolean;
35
+ entrypoint: Entrypoint;
36
+ viewType: ViewType;
37
+ savedViews: IUserView[];
38
+ attributesIds: string[];
39
+ fulltextSearch: string;
40
+ sort: Array<{
41
+ field: string;
42
+ order: SortOrder;
43
+ }>;
44
+ pageSize: number;
45
+ filters: ExplorerFilter[];
46
+ maxFilters: number;
47
+ initialViewSettings: Pick<IViewSettingsState, 'viewType' | 'attributesIds' | 'sort' | 'pageSize' | 'filters'>;
48
+ defaultViewSettings: DefaultViewSettings;
49
+ massSelection: MassSelection;
50
+ }
51
+ interface IViewSettingsActionChangePageSize {
52
+ type: typeof ViewSettingsActionTypes.CHANGE_PAGE_SIZE;
53
+ payload: {
54
+ pageSize: number;
55
+ };
56
+ }
57
+ interface IViewSettingsActionAddAttribute {
58
+ type: typeof ViewSettingsActionTypes.ADD_ATTRIBUTE;
59
+ payload: {
60
+ attributeId: string;
61
+ };
62
+ }
63
+ interface IViewSettingsActionRemoveAttribute {
64
+ type: typeof ViewSettingsActionTypes.REMOVE_ATTRIBUTE;
65
+ payload: {
66
+ attributeId: string;
67
+ };
68
+ }
69
+ interface IViewSettingsActionMoveAttribute {
70
+ type: typeof ViewSettingsActionTypes.MOVE_ATTRIBUTE;
71
+ payload: {
72
+ indexFrom: number;
73
+ indexTo: number;
74
+ };
75
+ }
76
+ interface IViewSettingsActionChangeViewType {
77
+ type: typeof ViewSettingsActionTypes.CHANGE_VIEW_TYPE;
78
+ payload: {
79
+ viewType: ViewType;
80
+ };
81
+ }
82
+ interface IViewSettingsActionResetAttributes {
83
+ type: typeof ViewSettingsActionTypes.RESET_ATTRIBUTES;
84
+ }
85
+ interface IViewSettingsActionAddSort {
86
+ type: typeof ViewSettingsActionTypes.ADD_SORT;
87
+ payload: {
88
+ field: string;
89
+ order: SortOrder;
90
+ };
91
+ }
92
+ interface IViewSettingsActionRemoveSort {
93
+ type: typeof ViewSettingsActionTypes.REMOVE_SORT;
94
+ payload: {
95
+ field: string;
96
+ };
97
+ }
98
+ interface IViewSettingsActionChangeSortOrder {
99
+ type: typeof ViewSettingsActionTypes.CHANGE_SORT_ORDER;
100
+ payload: {
101
+ field: string;
102
+ order: SortOrder;
103
+ };
104
+ }
105
+ interface IViewSettingsActionMoveSort {
106
+ type: typeof ViewSettingsActionTypes.MOVE_SORT;
107
+ payload: {
108
+ indexFrom: number;
109
+ indexTo: number;
110
+ };
111
+ }
112
+ interface IViewSettingsActionChangeFulltextSearch {
113
+ type: typeof ViewSettingsActionTypes.CHANGE_FULLTEXT_SEARCH;
114
+ payload: {
115
+ search: string;
116
+ };
117
+ }
118
+ interface IViewSettingsActionClearFulltextSearch {
119
+ type: typeof ViewSettingsActionTypes.CLEAR_FULLTEXT_SEARCH;
120
+ }
121
+ interface IViewSettingsActionAddFilter {
122
+ type: typeof ViewSettingsActionTypes.ADD_FILTER;
123
+ payload: Omit<ExplorerFilter, 'id' | 'value' | 'condition'>;
124
+ }
125
+ interface IViewSettingsActionResetFilter {
126
+ type: typeof ViewSettingsActionTypes.RESET_FILTER;
127
+ payload: Pick<ExplorerFilter, 'id'>;
128
+ }
129
+ interface IViewSettingsActionRemoveFilter {
130
+ type: typeof ViewSettingsActionTypes.REMOVE_FILTER;
131
+ payload: Pick<ExplorerFilter, 'id'>;
132
+ }
133
+ interface IViewSettingsActionChangeFilterConfig {
134
+ type: typeof ViewSettingsActionTypes.CHANGE_FILTER_CONFIG;
135
+ payload: ExplorerFilter;
136
+ }
137
+ interface IViewSettingsActionMoveFilter {
138
+ type: typeof ViewSettingsActionTypes.MOVE_FILTER;
139
+ payload: {
140
+ indexFrom: number;
141
+ indexTo: number;
142
+ };
143
+ }
144
+ interface IViewSettingsActionReset {
145
+ type: typeof ViewSettingsActionTypes.RESET;
146
+ payload: IViewSettingsState;
147
+ }
148
+ interface IViewSettingsActionSetSelectedKeys {
149
+ type: typeof ViewSettingsActionTypes.SET_SELECTED_KEYS;
150
+ payload: MassSelection;
151
+ }
152
+ interface IViewSettingsActionRestoreInitialViewSettings {
153
+ type: typeof ViewSettingsActionTypes.RESTORE_INITIAL_VIEW_SETTINGS;
154
+ }
155
+ interface IViewSettingsActionUpdateViewListAndCurrentViewName {
156
+ type: typeof ViewSettingsActionTypes.UPDATE_VIEWS;
157
+ payload: IUserView;
158
+ }
159
+ export type IViewSettingsActionLoadViewPayload = Pick<IViewSettingsState, 'viewId' | 'viewLabels' | 'viewType' | 'attributesIds' | 'sort' | 'filters'>;
160
+ interface IViewSettingsActionLoadView {
161
+ type: typeof ViewSettingsActionTypes.LOAD_VIEW;
162
+ payload: IViewSettingsActionLoadViewPayload;
163
+ }
164
+ type Reducer<PAYLOAD extends {
165
+ type: keyof typeof ViewSettingsActionTypes;
166
+ payload?: unknown;
167
+ } = {
168
+ type: any;
169
+ payload: 'no_payload';
170
+ }> = PAYLOAD['payload'] extends 'no_payload' ? (state: IViewSettingsState) => IViewSettingsState : (state: IViewSettingsState, payload: PAYLOAD['payload']) => IViewSettingsState;
171
+ export declare const clearFulltextSearch: Reducer;
172
+ export type IViewSettingsAction = IViewSettingsActionResetAttributes | IViewSettingsActionAddAttribute | IViewSettingsActionRemoveAttribute | IViewSettingsActionMoveAttribute | IViewSettingsActionChangeViewType | IViewSettingsActionAddSort | IViewSettingsActionRemoveSort | IViewSettingsActionChangeSortOrder | IViewSettingsActionMoveSort | IViewSettingsActionChangePageSize | IViewSettingsActionChangeFulltextSearch | IViewSettingsActionClearFulltextSearch | IViewSettingsActionAddFilter | IViewSettingsActionResetFilter | IViewSettingsActionRemoveFilter | IViewSettingsActionChangeFilterConfig | IViewSettingsActionMoveFilter | IViewSettingsActionReset | IViewSettingsActionSetSelectedKeys | IViewSettingsActionRestoreInitialViewSettings | IViewSettingsActionUpdateViewListAndCurrentViewName | IViewSettingsActionLoadView;
173
+ export declare const viewSettingsReducer: (state: IViewSettingsState, action: IViewSettingsAction) => IViewSettingsState;
174
+ export {};
@@ -0,0 +1,281 @@
1
+ // Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
2
+ // This file is released under LGPL V3
3
+ // License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
4
+ import { v4 as uuid } from 'uuid';
5
+ import { AttributeFormat } from '../../../../_gqlTypes';
6
+ import { isExplorerFilterLink, isExplorerFilterStandard, isExplorerFilterThrough } from '../../_types';
7
+ import { hasOnlyNoValueConditions } from '../../conditionsHelper';
8
+ import { conditionsByFormat } from '../filter-items/filter-type/useConditionOptionsByType';
9
+ import { ThroughConditionFilter } from '../../../../types';
10
+ export const ViewSettingsActionTypes = {
11
+ RESET: 'RESET',
12
+ ADD_ATTRIBUTE: 'ADD_ATTRIBUTE',
13
+ REMOVE_ATTRIBUTE: 'REMOVE_ATTRIBUTE',
14
+ MOVE_ATTRIBUTE: 'MOVE_ATTRIBUTE',
15
+ RESET_ATTRIBUTES: 'RESET_ATTRIBUTES',
16
+ CHANGE_VIEW_TYPE: 'CHANGE_VIEW_TYPE',
17
+ ADD_SORT: 'ADD_SORT',
18
+ REMOVE_SORT: 'REMOVE_SORT',
19
+ MOVE_SORT: 'MOVE_SORT',
20
+ CHANGE_SORT_ORDER: 'CHANGE_SORT_ORDER',
21
+ CHANGE_PAGE_SIZE: 'CHANGE_PAGE_SIZE',
22
+ CHANGE_FULLTEXT_SEARCH: 'CHANGE_FULLTEXT_SEARCH',
23
+ CLEAR_FULLTEXT_SEARCH: 'CLEAR_FULLTEXT_SEARCH',
24
+ ADD_FILTER: 'ADD_FILTER',
25
+ RESET_FILTER: 'RESET_FILTER',
26
+ REMOVE_FILTER: 'REMOVE_FILTER',
27
+ MOVE_FILTER: 'MOVE_FILTER',
28
+ CHANGE_FILTER_CONFIG: 'CHANGE_FILTER_CONFIG',
29
+ SET_SELECTED_KEYS: 'SET_SELECTED_KEYS',
30
+ RESTORE_INITIAL_VIEW_SETTINGS: 'RESTORE_INITIAL_VIEW_SETTINGS',
31
+ UPDATE_VIEWS: 'UPDATE_VIEWS',
32
+ LOAD_VIEW: 'LOAD_VIEW'
33
+ };
34
+ const changePageSize = (state, payload) => ({
35
+ ...state,
36
+ pageSize: payload.pageSize
37
+ });
38
+ const addAttribute = (state, payload) => ({
39
+ ...state,
40
+ attributesIds: [...state.attributesIds, payload.attributeId],
41
+ viewModified: true
42
+ });
43
+ const removeAttribute = (state, payload) => ({
44
+ ...state,
45
+ attributesIds: state.attributesIds.filter(attributesId => attributesId !== payload.attributeId),
46
+ viewModified: true
47
+ });
48
+ const moveAttribute = (state, payload) => {
49
+ const attributesIds = [...state.attributesIds];
50
+ const [attributeIdToMove] = attributesIds.splice(payload.indexFrom, 1);
51
+ // TODO use newES6 syntax (toSpliced)
52
+ attributesIds.splice(payload.indexTo, 0, attributeIdToMove);
53
+ return {
54
+ ...state,
55
+ attributesIds,
56
+ viewModified: true
57
+ };
58
+ };
59
+ const resetAttributes = state => ({
60
+ ...state,
61
+ attributesIds: []
62
+ });
63
+ const changeViewType = (state, payload) => ({
64
+ ...state,
65
+ viewType: payload.viewType,
66
+ viewModified: true
67
+ });
68
+ const addSort = (state, payload) => ({
69
+ ...state,
70
+ sort: [...state.sort, { field: payload.field, order: payload.order }],
71
+ viewModified: true
72
+ });
73
+ const removeSort = (state, payload) => ({
74
+ ...state,
75
+ sort: state.sort.filter(({ field: attributeId }) => attributeId !== payload.field),
76
+ viewModified: true
77
+ });
78
+ const changeSortOrder = (state, payload) => ({
79
+ ...state,
80
+ sort: state.sort.map(sort => (sort.field === payload.field ? { ...sort, order: payload.order } : sort)),
81
+ viewModified: true
82
+ });
83
+ const moveSort = (state, payload) => {
84
+ const attributesUsedToSort = [...state.sort];
85
+ const [sortToMove] = attributesUsedToSort.splice(payload.indexFrom, 1);
86
+ attributesUsedToSort.splice(payload.indexTo, 0, sortToMove);
87
+ return {
88
+ ...state,
89
+ sort: attributesUsedToSort,
90
+ viewModified: true
91
+ };
92
+ };
93
+ const changeFulltextSearch = (state, payload) => ({
94
+ ...state,
95
+ fulltextSearch: payload.search
96
+ });
97
+ export const clearFulltextSearch = state => ({
98
+ ...state,
99
+ fulltextSearch: ''
100
+ });
101
+ const addFilter = (state, payload) => ({
102
+ ...state,
103
+ filters: [
104
+ ...state.filters,
105
+ {
106
+ ...payload,
107
+ id: uuid(),
108
+ condition: hasOnlyNoValueConditions(payload.attribute.format)
109
+ ? null
110
+ : (conditionsByFormat[payload.attribute.format][0] ?? null),
111
+ value: null
112
+ }
113
+ ],
114
+ viewModified: true
115
+ });
116
+ const resetFilter = (state, payload) => ({
117
+ ...state,
118
+ filters: state.filters.map(filter => {
119
+ if (filter.id === payload.id) {
120
+ const initialViewFilter = state.initialViewSettings.filters.find(({ id }) => id === payload.id);
121
+ if (initialViewFilter) {
122
+ return initialViewFilter;
123
+ }
124
+ if (isExplorerFilterStandard(filter)) {
125
+ return {
126
+ ...filter,
127
+ condition: hasOnlyNoValueConditions(filter.attribute.format)
128
+ ? null
129
+ : conditionsByFormat[filter.attribute.format][0],
130
+ value: null
131
+ };
132
+ }
133
+ if (isExplorerFilterThrough(filter)) {
134
+ return {
135
+ ...filter,
136
+ condition: ThroughConditionFilter.THROUGH,
137
+ value: null
138
+ };
139
+ }
140
+ if (isExplorerFilterLink(filter)) {
141
+ return {
142
+ ...filter,
143
+ condition: conditionsByFormat[AttributeFormat.text][0],
144
+ value: null
145
+ };
146
+ }
147
+ }
148
+ return filter;
149
+ })
150
+ });
151
+ const removeFilter = (state, payload) => ({
152
+ ...state,
153
+ filters: state.filters.filter(({ id }) => id !== payload.id),
154
+ viewModified: true
155
+ });
156
+ const changeFilterConfig = (state, payload) => ({
157
+ ...state,
158
+ filters: state.filters.map(filter => (filter.id === payload.id ? { ...filter, ...payload } : filter)),
159
+ viewModified: true
160
+ });
161
+ const moveFilter = (state, payload) => {
162
+ const attributesUsedToFilter = [...state.filters];
163
+ const [filterToMove] = attributesUsedToFilter.splice(payload.indexFrom, 1);
164
+ attributesUsedToFilter.splice(payload.indexTo, 0, filterToMove);
165
+ return {
166
+ ...state,
167
+ filters: attributesUsedToFilter,
168
+ viewModified: true
169
+ };
170
+ };
171
+ const reset = (_, payload) => payload;
172
+ const setSelectedKeys = (state, payload) => ({
173
+ ...state,
174
+ massSelection: payload
175
+ });
176
+ const restoreInitialViewSettings = state => ({
177
+ ...state,
178
+ ...state.initialViewSettings,
179
+ viewModified: false
180
+ });
181
+ const updateViewListAndCurrentViewName = (state, payload) => ({
182
+ ...state,
183
+ viewId: payload.id ?? null,
184
+ viewLabels: payload.label,
185
+ savedViews: state.savedViews.find(({ id }) => id === payload.id)
186
+ ? state.savedViews.map(view => (view.id === payload.id ? payload : view))
187
+ : state.savedViews.concat([payload]),
188
+ initialViewSettings: {
189
+ viewType: state.viewType,
190
+ attributesIds: state.attributesIds,
191
+ sort: state.sort,
192
+ pageSize: state.pageSize,
193
+ filters: state.filters
194
+ },
195
+ viewModified: false
196
+ });
197
+ const loadView = (state, payload) => ({
198
+ ...state,
199
+ ...payload,
200
+ initialViewSettings: {
201
+ viewType: payload.viewType,
202
+ attributesIds: payload.attributesIds,
203
+ sort: payload.sort,
204
+ pageSize: state.pageSize,
205
+ filters: payload.filters
206
+ },
207
+ viewModified: false
208
+ });
209
+ export const viewSettingsReducer = (state, action) => {
210
+ switch (action.type) {
211
+ case ViewSettingsActionTypes.CHANGE_PAGE_SIZE: {
212
+ return changePageSize(state, action.payload);
213
+ }
214
+ case ViewSettingsActionTypes.ADD_ATTRIBUTE: {
215
+ return addAttribute(state, action.payload);
216
+ }
217
+ case ViewSettingsActionTypes.REMOVE_ATTRIBUTE: {
218
+ return removeAttribute(state, action.payload);
219
+ }
220
+ case ViewSettingsActionTypes.MOVE_ATTRIBUTE: {
221
+ return moveAttribute(state, action.payload);
222
+ }
223
+ case ViewSettingsActionTypes.RESET_ATTRIBUTES: {
224
+ return resetAttributes(state);
225
+ }
226
+ case ViewSettingsActionTypes.CHANGE_VIEW_TYPE: {
227
+ return changeViewType(state, action.payload);
228
+ }
229
+ case ViewSettingsActionTypes.ADD_SORT: {
230
+ return addSort(state, action.payload);
231
+ }
232
+ case ViewSettingsActionTypes.REMOVE_SORT: {
233
+ return removeSort(state, action.payload);
234
+ }
235
+ case ViewSettingsActionTypes.MOVE_SORT: {
236
+ return moveSort(state, action.payload);
237
+ }
238
+ case ViewSettingsActionTypes.CHANGE_SORT_ORDER: {
239
+ return changeSortOrder(state, action.payload);
240
+ }
241
+ case ViewSettingsActionTypes.CHANGE_FULLTEXT_SEARCH: {
242
+ return changeFulltextSearch(state, action.payload);
243
+ }
244
+ case ViewSettingsActionTypes.CLEAR_FULLTEXT_SEARCH: {
245
+ return clearFulltextSearch(state);
246
+ }
247
+ case ViewSettingsActionTypes.ADD_FILTER: {
248
+ return addFilter(state, action.payload);
249
+ }
250
+ case ViewSettingsActionTypes.RESET_FILTER: {
251
+ return resetFilter(state, action.payload);
252
+ }
253
+ case ViewSettingsActionTypes.REMOVE_FILTER: {
254
+ return removeFilter(state, action.payload);
255
+ }
256
+ case ViewSettingsActionTypes.CHANGE_FILTER_CONFIG: {
257
+ return changeFilterConfig(state, action.payload);
258
+ }
259
+ case ViewSettingsActionTypes.MOVE_FILTER: {
260
+ return moveFilter(state, action.payload);
261
+ }
262
+ case ViewSettingsActionTypes.RESET: {
263
+ return reset(state, action.payload);
264
+ }
265
+ case ViewSettingsActionTypes.SET_SELECTED_KEYS: {
266
+ return setSelectedKeys(state, action.payload);
267
+ }
268
+ case ViewSettingsActionTypes.RESTORE_INITIAL_VIEW_SETTINGS: {
269
+ return restoreInitialViewSettings(state);
270
+ }
271
+ case ViewSettingsActionTypes.UPDATE_VIEWS: {
272
+ return updateViewListAndCurrentViewName(state, action.payload);
273
+ }
274
+ case ViewSettingsActionTypes.LOAD_VIEW: {
275
+ return loadView(state, action.payload);
276
+ }
277
+ default:
278
+ return state;
279
+ }
280
+ };
281
+ //# sourceMappingURL=viewSettingsReducer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"viewSettingsReducer.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,EAAE,IAAI,IAAI,EAAC,MAAM,MAAM,CAAC;AAChC,OAAO,EAAY,eAAe,EAAC,MAAM,eAAe,CAAC;AACzD,OAAO,EAKH,oBAAoB,EACpB,wBAAwB,EACxB,uBAAuB,EAE1B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAC,wBAAwB,EAAC,MAAM,wBAAwB,CAAC;AAEhE,OAAO,EAAC,kBAAkB,EAAC,MAAM,uDAAuD,CAAC;AACzF,OAAO,EAAC,sBAAsB,EAAC,MAAM,WAAW,CAAC;AAKjD,MAAM,CAAC,MAAM,uBAAuB,GAAG;IACnC,KAAK,EAAE,OAAO;IACd,aAAa,EAAE,eAAe;IAC9B,gBAAgB,EAAE,kBAAkB;IACpC,cAAc,EAAE,gBAAgB;IAChC,gBAAgB,EAAE,kBAAkB;IACpC,gBAAgB,EAAE,kBAAkB;IACpC,QAAQ,EAAE,UAAU;IACpB,WAAW,EAAE,aAAa;IAC1B,SAAS,EAAE,WAAW;IACtB,iBAAiB,EAAE,mBAAmB;IACtC,gBAAgB,EAAE,kBAAkB;IACpC,sBAAsB,EAAE,wBAAwB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CAAC,CAAC;YACjC,OAAO,KAAK,CAAC,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;QACxC,CAAC;QACD,KAAK,uBAAuB,CAAC,iBAAiB,CAAC,CAAC,CAAC;YAC7C,OAAO,eAAe,CAAC,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;QAClD,CAAC;QACD,KAAK,uBAAuB,CAAC,6BAA6B,CAAC,CAAC,CAAC;YACzD,OAAO,0BAA0B,CAAC,KAAK,CAAC,CAAC;QAC7C,CAAC;QACD,KAAK,uBAAuB,CAAC,YAAY,CAAC,CAAC,CAAC;YACxC,OAAO,gCAAgC,CAAC,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;QACnE,CAAC;QACD,KAAK,uBAAuB,CAAC,SAAS,CAAC,CAAC,CAAC;YACrC,OAAO,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;QAC3C,CAAC;QACD;YACI,OAAO,KAAK,CAAC;IACrB,CAAC;AACL,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { IExplorerData } from './_types';
2
+ export declare const lastColumnsInlinePadding = 36;
3
+ export declare const useColumnWidth: () => {
4
+ ref: import("react").MutableRefObject<HTMLDivElement>;
5
+ getFieldColumnWidth: (field: IExplorerData["attributes"][string]) => number;
6
+ columnWidth: number;
7
+ actionsColumnHeaderWidth: number;
8
+ };
@@ -0,0 +1,49 @@
1
+ // Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
2
+ // This file is released under LGPL V3
3
+ // License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
4
+ import { isTypeStandard } from '@leav/utils';
5
+ import { useEffect, useRef, useState } from 'react';
6
+ import { AttributeFormat } from '../../_gqlTypes';
7
+ const FieldColumnWidth = {
8
+ TINY: 125,
9
+ SMALL: 150,
10
+ MEDIUM: 250,
11
+ LARGE: 300
12
+ };
13
+ const _getFieldColumWidth = (field) => {
14
+ if (!field || !isTypeStandard(field.type) || field.multiple_values) {
15
+ return FieldColumnWidth.LARGE;
16
+ }
17
+ switch (field.format) {
18
+ case AttributeFormat.boolean:
19
+ return FieldColumnWidth.TINY;
20
+ case AttributeFormat.numeric:
21
+ case AttributeFormat.date:
22
+ return FieldColumnWidth.SMALL;
23
+ case AttributeFormat.date_range:
24
+ return FieldColumnWidth.LARGE;
25
+ default:
26
+ return FieldColumnWidth.MEDIUM;
27
+ }
28
+ };
29
+ export const lastColumnsInlinePadding = 36;
30
+ export const useColumnWidth = () => {
31
+ const ref = useRef(null);
32
+ const [columnWidth, setColumnWidth] = useState(FieldColumnWidth.TINY);
33
+ useEffect(() => {
34
+ if (ref.current) {
35
+ const columnElement = ref.current;
36
+ const columnElementtWidth = columnElement.getBoundingClientRect().width;
37
+ if (columnElementtWidth !== columnWidth - lastColumnsInlinePadding) {
38
+ setColumnWidth(columnElementtWidth + lastColumnsInlinePadding);
39
+ }
40
+ }
41
+ }, [ref.current]);
42
+ return {
43
+ ref,
44
+ getFieldColumnWidth: _getFieldColumWidth,
45
+ columnWidth,
46
+ actionsColumnHeaderWidth: columnWidth - lastColumnsInlinePadding
47
+ };
48
+ };
49
+ //# sourceMappingURL=useColumnWidth.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useColumnWidth.js","sourceRoot":"","sources":["../../../src/components/Explorer/useColumnWidth.tsx"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,cAAc,EAAC,MAAM,aAAa,CAAC;AAE3C,OAAO,EAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAClD,OAAO,EAAC,eAAe,EAAC,MAAM,eAAe,CAAC;AAE9C,MAAM,gBAAgB,GAAG;IACrB,IAAI,EAAE,GAAG;IACT,KAAK,EAAE,GAAG;IACV,MAAM,EAAE,GAAG;IACX,KAAK,EAAE,GAAG;CACb,CAAC;AAEF,MAAM,mBAAmB,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mB;QACxC,WAAW;QACX,wBAAwB,EAAE,WAAW,GAAG,wBAAwB;KACnE,CAAC;AACN,CAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ export declare const useLoadView: () => {
2
+ loadView: (viewId: string | null) => void;
3
+ };
@@ -0,0 +1,79 @@
1
+ // Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
2
+ // This file is released under LGPL V3
3
+ // License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
4
+ import { useExplorerAttributesLazyQuery } from '../../_gqlTypes';
5
+ import { useEffect, useRef } from 'react';
6
+ import { useViewSettingsContext } from './manage-view-settings/store-view-settings/useViewSettingsContext';
7
+ import { useEditSettings, ViewSettingsActionTypes } from './manage-view-settings';
8
+ import { useTransformFilters } from './manage-view-settings/_shared/useTransformFilters';
9
+ import { mapViewTypeFromExplorerToLegacy, mapViewTypeFromLegacyToExplorer } from './_constants';
10
+ export const useLoadView = () => {
11
+ const { view, dispatch } = useViewSettingsContext();
12
+ const { closeSettingsPanel } = useEditSettings();
13
+ const { toExplorerFilters, toValidFilters } = useTransformFilters();
14
+ const curentView = useRef(null);
15
+ const [fetchAttributes, { data: attributesData, loading: attributesLoading }] = useExplorerAttributesLazyQuery({
16
+ fetchPolicy: 'network-only'
17
+ });
18
+ useEffect(() => {
19
+ if (!attributesLoading && attributesData) {
20
+ const attributesDataById = (attributesData?.attributes?.list ?? []).reduce((acc, attr) => {
21
+ acc[attr.id] = attr;
22
+ return acc;
23
+ }, {});
24
+ const viewSettings = {
25
+ viewId: curentView.current?.id ?? null,
26
+ viewLabels: curentView.current?.label ?? {},
27
+ viewType: curentView.current?.display
28
+ ? mapViewTypeFromLegacyToExplorer[curentView.current?.display.type]
29
+ : view.viewType,
30
+ attributesIds: curentView.current?.attributes ?? [],
31
+ sort: (curentView.current?.sort ?? []).map(s => ({
32
+ field: s.field,
33
+ order: s.order
34
+ })),
35
+ filters: toExplorerFilters({
36
+ filters: toValidFilters(curentView.current?.filters ?? []),
37
+ attributesDataById
38
+ })
39
+ };
40
+ dispatch({
41
+ type: ViewSettingsActionTypes.LOAD_VIEW,
42
+ payload: viewSettings
43
+ });
44
+ closeSettingsPanel();
45
+ }
46
+ }, [attributesData, attributesLoading]);
47
+ const loadView = (viewId) => {
48
+ let viewData;
49
+ if (!viewId) {
50
+ viewData = {
51
+ ...view.defaultViewSettings,
52
+ id: null,
53
+ display: { type: mapViewTypeFromExplorerToLegacy[view.viewType] },
54
+ label: {},
55
+ shared: false,
56
+ filters: view.defaultViewSettings.filters
57
+ };
58
+ }
59
+ else {
60
+ viewData = view.savedViews.find(v => v.id === viewId) ?? null;
61
+ }
62
+ if (!viewData) {
63
+ return;
64
+ }
65
+ curentView.current = viewData;
66
+ const attributesToHydrate = [
67
+ ...new Set([...(viewData?.sort ?? []), ...(viewData?.sort ?? [])].map(({ field }) => field))
68
+ ];
69
+ fetchAttributes({
70
+ variables: {
71
+ ids: attributesToHydrate
72
+ }
73
+ });
74
+ };
75
+ return {
76
+ loadView
77
+ };
78
+ };
79
+ //# sourceMappingURL=useLoadView.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useLoadView.js","sourceRoot":"","sources":["../../../src/components/Explorer/useLoadView.tsx"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,8BAA8B,EAAC,MAAM,eAAe,CAAC;AAC7D,OAAO,EAAC,SAAS,EAAE,MAAM,EAAC,MAAM,OAAO,CAAC;AACxC,OAAO,EAAC,sBAAsB,EAAC,MAAM,mEAAmE,CAAC;AAEzG,OAAO,EAAC,eAAe,EAAE,uBAAuB,EAAC,MAAM,wBAAwB,CAAC;AAChF,OAAO,EAAC,mBAAmB,EAAuB,MAAM,oDAAoD,CAAC;AAC7G,OAAO,EAAC,+BAA+B,EAAE,+BAA+B,EAAC,MAAM,cAAc,CAAC;AAG9F,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,EAAE;IAC5B,MAA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,CAAC,QAAQ,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,KAAK,CAAC,CAAC;SAC7F,CAAC;QAEF,eAAe,CAAC;YACZ,SAAS,EAAE;gBACP,GAAG,EAAE,mBAAmB;aAC3B;SACJ,CAAC,CAAC;IACP,CAAC,CAAC;IAEF,OAAO;QACH,QAAQ;KACX,CAAC;AACN,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { Dispatch } from 'react';
2
+ import { IViewSettingsAction } from './manage-view-settings';
3
+ export declare const usePagination: (dispatch: Dispatch<IViewSettingsAction>) => {
4
+ currentPage: number;
5
+ setNewPage: (newCurrentPage: number, ignoredPageSize: number) => void;
6
+ setNewPageSize: (ignoredCurrentPage: number, newPageSize: number) => void;
7
+ };
@@ -0,0 +1,25 @@
1
+ // Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
2
+ // This file is released under LGPL V3
3
+ // License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
4
+ import { useState } from 'react';
5
+ import { ViewSettingsActionTypes } from './manage-view-settings';
6
+ export const usePagination = (dispatch) => {
7
+ const [currentPage, setCurrentPage] = useState(1);
8
+ const setNewPage = (newCurrentPage, ignoredPageSize) => {
9
+ setCurrentPage(newCurrentPage);
10
+ };
11
+ const setNewPageSize = (ignoredCurrentPage, newPageSize) => {
12
+ dispatch({
13
+ type: ViewSettingsActionTypes.CHANGE_PAGE_SIZE,
14
+ payload: {
15
+ pageSize: newPageSize
16
+ }
17
+ });
18
+ };
19
+ return {
20
+ currentPage,
21
+ setNewPage,
22
+ setNewPageSize
23
+ };
24
+ };
25
+ //# sourceMappingURL=usePagination.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usePagination.js","sourceRoot":"","sources":["../../../src/components/Explorer/usePagination.tsx"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAW,QAAQ,EAAC,MAAM,OAAO,CAAC;AACzC,OAAO,EAAsB,uBAAuB,EAAC,MAAM,wBAAwB,CAAC;AAEpF,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,QAAuC,EAAE,EAAE;IACrE,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;IAElD,MAAM,UAAU,GAAG,CAAC,cAAsB,EAAE,eAAuB,EAAE,EAAE;QACnE,cAAc,CAAC,cAAc,CAAC,CAAC;IACnC,CAAC,CAAC;IAEF,MAAM,cAAc,GAAG,CAAC,kBAA0B,EAAE,WAAmB,EAAE,EAAE;QACvE,QAAQ,CAAC;YACL,IAAI,EAAE,uBAAuB,CAAC,gBAAgB;YAC9C,OAAO,EAAE;gBACL,QAAQ,EAAE,WAAW;aACxB;SACJ,CAAC,CAAC;IACP,CAAC,CAAC;IAEF,OAAO;QACH,WAAW;QACX,UAAU;QACV,cAAc;KACjB,CAAC;AACN,CAAC,CAAC"}