@leav/ui 1.9.0 → 1.10.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 (514) hide show
  1. package/dist/_gqlTypes/index.d.ts +291 -120
  2. package/dist/_gqlTypes/index.js +204 -87
  3. package/dist/_gqlTypes/index.js.map +1 -1
  4. package/dist/_queries/records/createRecordMutation.js +2 -2
  5. package/dist/_queries/records/createRecordMutation.js.map +1 -1
  6. package/dist/_utils/getFiltersFromRequest.js +5 -6
  7. package/dist/_utils/getFiltersFromRequest.js.map +1 -1
  8. package/dist/_utils/index.js +3 -4
  9. package/dist/_utils/index.js.map +1 -1
  10. package/dist/_utils/typeguards.d.ts +5 -0
  11. package/dist/_utils/typeguards.js +6 -0
  12. package/dist/_utils/typeguards.js.map +1 -1
  13. package/dist/components/Explorer/Explorer.d.ts +2 -1
  14. package/dist/components/Explorer/Explorer.js +31 -13
  15. package/dist/components/Explorer/Explorer.js.map +1 -1
  16. package/dist/components/Explorer/ExplorerToolbar.js +2 -1
  17. package/dist/components/Explorer/ExplorerToolbar.js.map +1 -1
  18. package/dist/components/Explorer/_queries/useExplorerCountData.d.ts +16 -0
  19. package/dist/components/Explorer/_queries/useExplorerCountData.js +26 -0
  20. package/dist/components/Explorer/_queries/useExplorerCountData.js.map +1 -0
  21. package/dist/components/Explorer/_queries/useExplorerData.js +18 -20
  22. package/dist/components/Explorer/_queries/useExplorerData.js.map +1 -1
  23. package/dist/components/Explorer/actions-mass/ResultsCount.d.ts +10 -0
  24. package/dist/components/Explorer/actions-mass/ResultsCount.js +8 -0
  25. package/dist/components/Explorer/actions-mass/ResultsCount.js.map +1 -0
  26. package/dist/components/Explorer/actions-mass/edit-attribute/EditAttributeMassActionModal.js +1 -1
  27. package/dist/components/Explorer/actions-mass/edit-attribute/EditAttributeMassActionModal.js.map +1 -1
  28. package/dist/components/Explorer/actions-mass/edit-attribute/useCountValuesOccurrencesHook.d.ts +9 -2
  29. package/dist/components/Explorer/actions-mass/edit-attribute/useCountValuesOccurrencesHook.js +18 -4
  30. package/dist/components/Explorer/actions-mass/edit-attribute/useCountValuesOccurrencesHook.js.map +1 -1
  31. package/dist/components/Explorer/actions-mass/generate-previews/GeneratePreviewsModal.d.ts +10 -0
  32. package/dist/components/Explorer/actions-mass/generate-previews/GeneratePreviewsModal.js +69 -0
  33. package/dist/components/Explorer/actions-mass/generate-previews/GeneratePreviewsModal.js.map +1 -0
  34. package/dist/components/Explorer/actions-mass/generate-previews/useGetPreviewSizesData.d.ts +18 -0
  35. package/dist/components/Explorer/actions-mass/generate-previews/useGetPreviewSizesData.js +57 -0
  36. package/dist/components/Explorer/actions-mass/generate-previews/useGetPreviewSizesData.js.map +1 -0
  37. package/dist/components/Explorer/actions-mass/useGeneratePreviewsMassAction.d.ts +19 -0
  38. package/dist/components/Explorer/actions-mass/useGeneratePreviewsMassAction.js +94 -0
  39. package/dist/components/Explorer/actions-mass/useGeneratePreviewsMassAction.js.map +1 -0
  40. package/dist/components/Explorer/actions-mass/useMassActions.d.ts +5 -3
  41. package/dist/components/Explorer/actions-mass/useMassActions.js +19 -13
  42. package/dist/components/Explorer/actions-mass/useMassActions.js.map +1 -1
  43. package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.d.ts +3 -1
  44. package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.js +5 -1
  45. package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.js.map +1 -1
  46. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js +6 -1
  47. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js.map +1 -1
  48. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.d.ts +3 -0
  49. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js +5 -5
  50. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js.map +1 -1
  51. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js +1 -1
  52. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js.map +1 -1
  53. package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js +2 -2
  54. package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js.map +1 -1
  55. package/dist/components/Explorer/useViewSettingsReducer.js +11 -8
  56. package/dist/components/Explorer/useViewSettingsReducer.js.map +1 -1
  57. package/dist/components/Filters/_queries/treeFiltersDataQuery.d.ts +6 -0
  58. package/dist/components/Filters/_queries/treeFiltersDataQuery.js +54 -0
  59. package/dist/components/Filters/_queries/treeFiltersDataQuery.js.map +1 -0
  60. package/dist/components/Filters/context/useGetTreeFilters.js +24 -40
  61. package/dist/components/Filters/context/useGetTreeFilters.js.map +1 -1
  62. package/dist/components/Filters/filter-items/filter-type/tree/TreeAttributeDropDown.js +1 -2
  63. package/dist/components/Filters/filter-items/filter-type/tree/TreeAttributeDropDown.js.map +1 -1
  64. package/dist/components/Filters/filter-items/filter-type/tree/_queries/filterTreeDataQuery.d.ts +6 -0
  65. package/dist/components/Filters/filter-items/filter-type/tree/_queries/filterTreeDataQuery.js +54 -0
  66. package/dist/components/Filters/filter-items/filter-type/tree/_queries/filterTreeDataQuery.js.map +1 -0
  67. package/dist/components/Filters/filter-items/filter-type/tree/useGetTreeData.js +22 -41
  68. package/dist/components/Filters/filter-items/filter-type/tree/useGetTreeData.js.map +1 -1
  69. package/dist/components/RecordEdition/EditRecord/EditRecord.d.ts +1 -0
  70. package/dist/components/RecordEdition/EditRecord/EditRecord.js +3 -3
  71. package/dist/components/RecordEdition/EditRecord/EditRecord.js.map +1 -1
  72. package/dist/components/RecordEdition/EditRecordContent/_types.d.ts +4 -0
  73. package/dist/components/RecordEdition/EditRecordContent/_types.js.map +1 -1
  74. package/dist/components/RecordEdition/EditRecordContent/antdUtils.js +1 -3
  75. package/dist/components/RecordEdition/EditRecordContent/antdUtils.js.map +1 -1
  76. package/dist/components/RecordEdition/EditRecordModal/EditRecordModal.js +28 -17
  77. package/dist/components/RecordEdition/EditRecordModal/EditRecordModal.js.map +1 -1
  78. package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.d.ts +1 -0
  79. package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.js +30 -18
  80. package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.js.map +1 -1
  81. package/dist/components/RecordEdition/EditRecordPage/ErrorComponent.d.ts +2 -0
  82. package/dist/components/RecordEdition/EditRecordPage/ErrorComponent.js +11 -0
  83. package/dist/components/RecordEdition/EditRecordPage/ErrorComponent.js.map +1 -0
  84. package/dist/components/RecordEdition/EditRecordPage/getInitialRecordValues.d.ts +2 -0
  85. package/dist/components/RecordEdition/EditRecordPage/getInitialRecordValues.js +35 -0
  86. package/dist/components/RecordEdition/EditRecordPage/getInitialRecordValues.js.map +1 -0
  87. package/dist/components/RecordEdition/_types.d.ts +1 -1
  88. package/dist/components/RecordEdition/_types.js.map +1 -1
  89. package/dist/components/RecordEdition/editRecordReducer/editRecordReducer.js +7 -6
  90. package/dist/components/RecordEdition/editRecordReducer/editRecordReducer.js.map +1 -1
  91. package/dist/components/RecordEdition/hooks/useGetSubmitButtons.d.ts +1 -1
  92. package/dist/components/RecordEdition/hooks/useGetSubmitButtons.js +6 -2
  93. package/dist/components/RecordEdition/hooks/useGetSubmitButtons.js.map +1 -1
  94. package/dist/components/SearchModal/SearchModal.js +28 -18
  95. package/dist/components/SearchModal/SearchModal.js.map +1 -1
  96. package/dist/components/SelectTreeNode/SelectTreeNode.d.ts +0 -2
  97. package/dist/components/SelectTreeNode/SelectTreeNode.js +2 -2
  98. package/dist/components/SelectTreeNode/SelectTreeNode.js.map +1 -1
  99. package/dist/components/SelectTreeNode/SelectTreeNodeContent.d.ts +0 -2
  100. package/dist/components/SelectTreeNode/SelectTreeNodeContent.js +60 -114
  101. package/dist/components/SelectTreeNode/SelectTreeNodeContent.js.map +1 -1
  102. package/dist/components/SelectTreeNode/TreeNodeTitle.d.ts +0 -1
  103. package/dist/components/SelectTreeNode/TreeNodeTitle.js +3 -7
  104. package/dist/components/SelectTreeNode/TreeNodeTitle.js.map +1 -1
  105. package/dist/components/SelectTreeNode/_queries/treeContentDataQuery.d.ts +6 -0
  106. package/dist/components/SelectTreeNode/_queries/treeContentDataQuery.js +56 -0
  107. package/dist/components/SelectTreeNode/_queries/treeContentDataQuery.js.map +1 -0
  108. package/dist/components/SelectTreeNode/_types.d.ts +0 -1
  109. package/dist/components/SelectTreeNode/_types.js.map +1 -1
  110. package/dist/components/index.d.ts +0 -3
  111. package/dist/components/index.js +0 -3
  112. package/dist/components/index.js.map +1 -1
  113. package/dist/hooks/useGetRecordForm/useGetRecordForm.js +24 -22
  114. package/dist/hooks/useGetRecordForm/useGetRecordForm.js.map +1 -1
  115. package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.js +9 -6
  116. package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.js.map +1 -1
  117. package/dist/hooks/useIFrameMessenger/schema.d.ts +14 -2
  118. package/dist/hooks/useIFrameMessenger/schema.js +7 -1
  119. package/dist/hooks/useIFrameMessenger/schema.js.map +1 -1
  120. package/dist/hooks/useIFrameMessenger/types.d.ts +5 -0
  121. package/dist/hooks/useIFrameMessenger/types.js.map +1 -1
  122. package/dist/hooks/useRecordsConsultationHistory/useRecordsConsultationHistory.d.ts +1 -1
  123. package/dist/hooks/useRecordsConsultationHistory/useRecordsConsultationHistory.js +14 -6
  124. package/dist/hooks/useRecordsConsultationHistory/useRecordsConsultationHistory.js.map +1 -1
  125. package/dist/locales/en/shared.json +14 -4
  126. package/dist/locales/fr/shared.json +14 -4
  127. package/package.json +11 -20
  128. package/dist/__mocks__/common/mockSearchContextProvider.d.ts +0 -6
  129. package/dist/__mocks__/common/mockSearchContextProvider.js +0 -10
  130. package/dist/__mocks__/common/mockSearchContextProvider.js.map +0 -1
  131. package/dist/components/AttributesSelectionList/Attribute/Attribute.d.ts +0 -3
  132. package/dist/components/AttributesSelectionList/Attribute/Attribute.js +0 -50
  133. package/dist/components/AttributesSelectionList/Attribute/Attribute.js.map +0 -1
  134. package/dist/components/AttributesSelectionList/Attribute/index.d.ts +0 -2
  135. package/dist/components/AttributesSelectionList/Attribute/index.js +0 -6
  136. package/dist/components/AttributesSelectionList/Attribute/index.js.map +0 -1
  137. package/dist/components/AttributesSelectionList/AttributesSelectionList.d.ts +0 -10
  138. package/dist/components/AttributesSelectionList/AttributesSelectionList.js +0 -72
  139. package/dist/components/AttributesSelectionList/AttributesSelectionList.js.map +0 -1
  140. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/SelectedAttribute.d.ts +0 -7
  141. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/SelectedAttribute.js +0 -39
  142. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/SelectedAttribute.js.map +0 -1
  143. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/index.d.ts +0 -2
  144. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/index.js +0 -6
  145. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/index.js.map +0 -1
  146. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttributesList.d.ts +0 -2
  147. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttributesList.js +0 -63
  148. package/dist/components/AttributesSelectionList/SelectedAttributesList/SelectedAttributesList.js.map +0 -1
  149. package/dist/components/AttributesSelectionList/SelectedAttributesList/index.d.ts +0 -2
  150. package/dist/components/AttributesSelectionList/SelectedAttributesList/index.js +0 -6
  151. package/dist/components/AttributesSelectionList/SelectedAttributesList/index.js.map +0 -1
  152. package/dist/components/AttributesSelectionList/_types.d.ts +0 -8
  153. package/dist/components/AttributesSelectionList/_types.js +0 -2
  154. package/dist/components/AttributesSelectionList/_types.js.map +0 -1
  155. package/dist/components/AttributesSelectionList/helpers/attributeToSelectedAttribute.d.ts +0 -3
  156. package/dist/components/AttributesSelectionList/helpers/attributeToSelectedAttribute.js +0 -9
  157. package/dist/components/AttributesSelectionList/helpers/attributeToSelectedAttribute.js.map +0 -1
  158. package/dist/components/AttributesSelectionList/index.d.ts +0 -2
  159. package/dist/components/AttributesSelectionList/index.js +0 -6
  160. package/dist/components/AttributesSelectionList/index.js.map +0 -1
  161. package/dist/components/AttributesSelectionList/reducer/__mocks__/attributesSelectionListStateContext.d.ts +0 -11
  162. package/dist/components/AttributesSelectionList/reducer/__mocks__/attributesSelectionListStateContext.js +0 -10
  163. package/dist/components/AttributesSelectionList/reducer/__mocks__/attributesSelectionListStateContext.js.map +0 -1
  164. package/dist/components/AttributesSelectionList/reducer/attributesSelectionListReducer.d.ts +0 -33
  165. package/dist/components/AttributesSelectionList/reducer/attributesSelectionListReducer.js +0 -77
  166. package/dist/components/AttributesSelectionList/reducer/attributesSelectionListReducer.js.map +0 -1
  167. package/dist/components/AttributesSelectionList/reducer/attributesSelectionListStateContext.d.ts +0 -10
  168. package/dist/components/AttributesSelectionList/reducer/attributesSelectionListStateContext.js +0 -8
  169. package/dist/components/AttributesSelectionList/reducer/attributesSelectionListStateContext.js.map +0 -1
  170. package/dist/components/AttributesSelectionList/sharedComponents.d.ts +0 -809
  171. package/dist/components/AttributesSelectionList/sharedComponents.js +0 -16
  172. package/dist/components/AttributesSelectionList/sharedComponents.js.map +0 -1
  173. package/dist/components/DeactivateRecordsModal/DeactivateRecordsModal.d.ts +0 -10
  174. package/dist/components/DeactivateRecordsModal/DeactivateRecordsModal.js +0 -39
  175. package/dist/components/DeactivateRecordsModal/DeactivateRecordsModal.js.map +0 -1
  176. package/dist/components/DeactivateRecordsModal/index.d.ts +0 -1
  177. package/dist/components/DeactivateRecordsModal/index.js +0 -5
  178. package/dist/components/DeactivateRecordsModal/index.js.map +0 -1
  179. package/dist/components/LibraryItemsList/CreateNewRecordButton/CreateNewRecordButton.d.ts +0 -13
  180. package/dist/components/LibraryItemsList/CreateNewRecordButton/CreateNewRecordButton.js +0 -50
  181. package/dist/components/LibraryItemsList/CreateNewRecordButton/CreateNewRecordButton.js.map +0 -1
  182. package/dist/components/LibraryItemsList/CreateNewRecordButton/index.d.ts +0 -2
  183. package/dist/components/LibraryItemsList/CreateNewRecordButton/index.js +0 -6
  184. package/dist/components/LibraryItemsList/CreateNewRecordButton/index.js.map +0 -1
  185. package/dist/components/LibraryItemsList/DisplayOptions/DisplayOptions.d.ts +0 -2
  186. package/dist/components/LibraryItemsList/DisplayOptions/DisplayOptions.js +0 -80
  187. package/dist/components/LibraryItemsList/DisplayOptions/DisplayOptions.js.map +0 -1
  188. package/dist/components/LibraryItemsList/DisplayOptions/index.d.ts +0 -2
  189. package/dist/components/LibraryItemsList/DisplayOptions/index.js +0 -6
  190. package/dist/components/LibraryItemsList/DisplayOptions/index.js.map +0 -1
  191. package/dist/components/LibraryItemsList/DisplayTypeSelector/DisplayTypeSelector.d.ts +0 -2
  192. package/dist/components/LibraryItemsList/DisplayTypeSelector/DisplayTypeSelector.js +0 -22
  193. package/dist/components/LibraryItemsList/DisplayTypeSelector/DisplayTypeSelector.js.map +0 -1
  194. package/dist/components/LibraryItemsList/DisplayTypeSelector/index.d.ts +0 -2
  195. package/dist/components/LibraryItemsList/DisplayTypeSelector/index.js +0 -6
  196. package/dist/components/LibraryItemsList/DisplayTypeSelector/index.js.map +0 -1
  197. package/dist/components/LibraryItemsList/FiltersDropdown/FiltersDropdown.d.ts +0 -13
  198. package/dist/components/LibraryItemsList/FiltersDropdown/FiltersDropdown.js +0 -229
  199. package/dist/components/LibraryItemsList/FiltersDropdown/FiltersDropdown.js.map +0 -1
  200. package/dist/components/LibraryItemsList/FiltersDropdown/index.d.ts +0 -2
  201. package/dist/components/LibraryItemsList/FiltersDropdown/index.js +0 -6
  202. package/dist/components/LibraryItemsList/FiltersDropdown/index.js.map +0 -1
  203. package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.d.ts +0 -11
  204. package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.js +0 -328
  205. package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.js.map +0 -1
  206. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/FilterAttributeCondition.d.ts +0 -7
  207. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/FilterAttributeCondition.js +0 -90
  208. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/FilterAttributeCondition.js.map +0 -1
  209. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/index.d.ts +0 -2
  210. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/index.js +0 -6
  211. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/index.js.map +0 -1
  212. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/BooleanFilter.d.ts +0 -3
  213. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/BooleanFilter.js +0 -13
  214. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/BooleanFilter.js.map +0 -1
  215. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/index.d.ts +0 -2
  216. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/index.js +0 -6
  217. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/index.js.map +0 -1
  218. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/DateBetweenFilter.d.ts +0 -3
  219. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/DateBetweenFilter.js +0 -26
  220. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/DateBetweenFilter.js.map +0 -1
  221. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/index.d.ts +0 -2
  222. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/index.js +0 -6
  223. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/index.js.map +0 -1
  224. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/DateFilter.d.ts +0 -3
  225. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/DateFilter.js +0 -22
  226. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/DateFilter.js.map +0 -1
  227. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/index.d.ts +0 -2
  228. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/index.js +0 -6
  229. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/index.js.map +0 -1
  230. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/NumericFilter.d.ts +0 -3
  231. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/NumericFilter.js +0 -35
  232. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/NumericFilter.js.map +0 -1
  233. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/index.d.ts +0 -2
  234. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/index.js +0 -6
  235. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/index.js.map +0 -1
  236. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/TextFilter.d.ts +0 -3
  237. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/TextFilter.js +0 -34
  238. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/TextFilter.js.map +0 -1
  239. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/index.d.ts +0 -2
  240. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/index.js +0 -6
  241. package/dist/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/index.js.map +0 -1
  242. package/dist/components/LibraryItemsList/FiltersPanel/Filter/filterUtils.d.ts +0 -2
  243. package/dist/components/LibraryItemsList/FiltersPanel/Filter/filterUtils.js +0 -16
  244. package/dist/components/LibraryItemsList/FiltersPanel/Filter/filterUtils.js.map +0 -1
  245. package/dist/components/LibraryItemsList/FiltersPanel/Filter/index.d.ts +0 -2
  246. package/dist/components/LibraryItemsList/FiltersPanel/Filter/index.js +0 -6
  247. package/dist/components/LibraryItemsList/FiltersPanel/Filter/index.js.map +0 -1
  248. package/dist/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/FilterDropdownButton.d.ts +0 -8
  249. package/dist/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/FilterDropdownButton.js +0 -11
  250. package/dist/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/FilterDropdownButton.js.map +0 -1
  251. package/dist/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/index.d.ts +0 -2
  252. package/dist/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/index.js +0 -6
  253. package/dist/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/index.js.map +0 -1
  254. package/dist/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/FilterTreeCondition.d.ts +0 -6
  255. package/dist/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/FilterTreeCondition.js +0 -38
  256. package/dist/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/FilterTreeCondition.js.map +0 -1
  257. package/dist/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/index.d.ts +0 -2
  258. package/dist/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/index.js +0 -6
  259. package/dist/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/index.js.map +0 -1
  260. package/dist/components/LibraryItemsList/FiltersPanel/FiltersOptions.d.ts +0 -14
  261. package/dist/components/LibraryItemsList/FiltersPanel/FiltersOptions.js +0 -147
  262. package/dist/components/LibraryItemsList/FiltersPanel/FiltersOptions.js.map +0 -1
  263. package/dist/components/LibraryItemsList/FiltersPanel/FiltersPanel.d.ts +0 -2
  264. package/dist/components/LibraryItemsList/FiltersPanel/FiltersPanel.js +0 -121
  265. package/dist/components/LibraryItemsList/FiltersPanel/FiltersPanel.js.map +0 -1
  266. package/dist/components/LibraryItemsList/FiltersPanel/index.d.ts +0 -2
  267. package/dist/components/LibraryItemsList/FiltersPanel/index.js +0 -6
  268. package/dist/components/LibraryItemsList/FiltersPanel/index.js.map +0 -1
  269. package/dist/components/LibraryItemsList/FiltersPanel/mustHideValue.d.ts +0 -3
  270. package/dist/components/LibraryItemsList/FiltersPanel/mustHideValue.js +0 -17
  271. package/dist/components/LibraryItemsList/FiltersPanel/mustHideValue.js.map +0 -1
  272. package/dist/components/LibraryItemsList/IconViewType/IconViewType.d.ts +0 -8
  273. package/dist/components/LibraryItemsList/IconViewType/IconViewType.js +0 -18
  274. package/dist/components/LibraryItemsList/IconViewType/IconViewType.js.map +0 -1
  275. package/dist/components/LibraryItemsList/IconViewType/index.d.ts +0 -2
  276. package/dist/components/LibraryItemsList/IconViewType/index.js +0 -6
  277. package/dist/components/LibraryItemsList/IconViewType/index.js.map +0 -1
  278. package/dist/components/LibraryItemsList/LibraryItemsList.d.ts +0 -14
  279. package/dist/components/LibraryItemsList/LibraryItemsList.js +0 -18
  280. package/dist/components/LibraryItemsList/LibraryItemsList.js.map +0 -1
  281. package/dist/components/LibraryItemsList/LibraryItemsListContent/LibraryItemsListContent.d.ts +0 -16
  282. package/dist/components/LibraryItemsList/LibraryItemsListContent/LibraryItemsListContent.js +0 -202
  283. package/dist/components/LibraryItemsList/LibraryItemsListContent/LibraryItemsListContent.js.map +0 -1
  284. package/dist/components/LibraryItemsList/LibraryItemsListContent/index.d.ts +0 -2
  285. package/dist/components/LibraryItemsList/LibraryItemsListContent/index.js +0 -6
  286. package/dist/components/LibraryItemsList/LibraryItemsListContent/index.js.map +0 -1
  287. package/dist/components/LibraryItemsList/LibraryItemsListEmpty/LibraryItemsListEmpty.d.ts +0 -6
  288. package/dist/components/LibraryItemsList/LibraryItemsListEmpty/LibraryItemsListEmpty.js +0 -32
  289. package/dist/components/LibraryItemsList/LibraryItemsListEmpty/LibraryItemsListEmpty.js.map +0 -1
  290. package/dist/components/LibraryItemsList/LibraryItemsListEmpty/index.d.ts +0 -2
  291. package/dist/components/LibraryItemsList/LibraryItemsListEmpty/index.js +0 -6
  292. package/dist/components/LibraryItemsList/LibraryItemsListEmpty/index.js.map +0 -1
  293. package/dist/components/LibraryItemsList/LibraryItemsListPagination/LibraryItemsListPagination.d.ts +0 -2
  294. package/dist/components/LibraryItemsList/LibraryItemsListPagination/LibraryItemsListPagination.js +0 -21
  295. package/dist/components/LibraryItemsList/LibraryItemsListPagination/LibraryItemsListPagination.js.map +0 -1
  296. package/dist/components/LibraryItemsList/LibraryItemsListPagination/index.d.ts +0 -2
  297. package/dist/components/LibraryItemsList/LibraryItemsListPagination/index.js +0 -6
  298. package/dist/components/LibraryItemsList/LibraryItemsListPagination/index.js.map +0 -1
  299. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyCell/BodyCell.d.ts +0 -8
  300. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyCell/BodyCell.js +0 -56
  301. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyCell/BodyCell.js.map +0 -1
  302. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyCell/index.d.ts +0 -2
  303. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyCell/index.js +0 -6
  304. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyCell/index.js.map +0 -1
  305. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyRow/BodyRow.d.ts +0 -7
  306. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyRow/BodyRow.js +0 -54
  307. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyRow/BodyRow.js.map +0 -1
  308. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyRow/index.d.ts +0 -2
  309. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyRow/index.js +0 -6
  310. package/dist/components/LibraryItemsList/LibraryItemsListTable/BodyRow/index.js.map +0 -1
  311. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/AllValuesCount.d.ts +0 -8
  312. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/AllValuesCount.js +0 -66
  313. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/AllValuesCount.js.map +0 -1
  314. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/index.d.ts +0 -2
  315. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/index.js +0 -6
  316. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/index.js.map +0 -1
  317. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/Cell.d.ts +0 -8
  318. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/Cell.js +0 -59
  319. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/Cell.js.map +0 -1
  320. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/CellInfos.d.ts +0 -9
  321. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/CellInfos.js +0 -56
  322. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/CellInfos.js.map +0 -1
  323. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/index.d.ts +0 -2
  324. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/index.js +0 -6
  325. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/index.js.map +0 -1
  326. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/CellSelection.d.ts +0 -5
  327. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/CellSelection.js +0 -34
  328. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/CellSelection.js.map +0 -1
  329. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/index.d.ts +0 -2
  330. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/index.js +0 -6
  331. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/index.js.map +0 -1
  332. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/ElementsToDisplay/RichTextDisplay.d.ts +0 -5
  333. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/ElementsToDisplay/RichTextDisplay.js +0 -23
  334. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/ElementsToDisplay/RichTextDisplay.js.map +0 -1
  335. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/StandardCell.d.ts +0 -3
  336. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/StandardCell.js +0 -80
  337. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/StandardCell.js.map +0 -1
  338. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/index.d.ts +0 -2
  339. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/index.js +0 -6
  340. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/index.js.map +0 -1
  341. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/index.d.ts +0 -2
  342. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/index.js +0 -6
  343. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/index.js.map +0 -1
  344. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/typeGuards.d.ts +0 -12
  345. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/typeGuards.js +0 -11
  346. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/typeGuards.js.map +0 -1
  347. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/types.d.ts +0 -12
  348. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/types.js +0 -2
  349. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/types.js.map +0 -1
  350. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/utils.d.ts +0 -2
  351. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/utils.js +0 -40
  352. package/dist/components/LibraryItemsList/LibraryItemsListTable/Cell/utils.js.map +0 -1
  353. package/dist/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/ChooseTableColumns.d.ts +0 -6
  354. package/dist/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/ChooseTableColumns.js +0 -81
  355. package/dist/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/ChooseTableColumns.js.map +0 -1
  356. package/dist/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/index.d.ts +0 -2
  357. package/dist/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/index.js +0 -6
  358. package/dist/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/index.js.map +0 -1
  359. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/Header.d.ts +0 -9
  360. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/Header.js +0 -142
  361. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/Header.js.map +0 -1
  362. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/index.d.ts +0 -2
  363. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/index.js +0 -6
  364. package/dist/components/LibraryItemsList/LibraryItemsListTable/Header/index.js.map +0 -1
  365. package/dist/components/LibraryItemsList/LibraryItemsListTable/Table.d.ts +0 -2
  366. package/dist/components/LibraryItemsList/LibraryItemsListTable/Table.js +0 -232
  367. package/dist/components/LibraryItemsList/LibraryItemsListTable/Table.js.map +0 -1
  368. package/dist/components/LibraryItemsList/LibraryItemsListTable/index.d.ts +0 -2
  369. package/dist/components/LibraryItemsList/LibraryItemsListTable/index.js +0 -6
  370. package/dist/components/LibraryItemsList/LibraryItemsListTable/index.js.map +0 -1
  371. package/dist/components/LibraryItemsList/MenuItemList/MenuItemList.d.ts +0 -9
  372. package/dist/components/LibraryItemsList/MenuItemList/MenuItemList.js +0 -27
  373. package/dist/components/LibraryItemsList/MenuItemList/MenuItemList.js.map +0 -1
  374. package/dist/components/LibraryItemsList/MenuItemList/index.d.ts +0 -2
  375. package/dist/components/LibraryItemsList/MenuItemList/index.js +0 -6
  376. package/dist/components/LibraryItemsList/MenuItemList/index.js.map +0 -1
  377. package/dist/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/ActionsMenu.d.ts +0 -2
  378. package/dist/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/ActionsMenu.js +0 -62
  379. package/dist/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/ActionsMenu.js.map +0 -1
  380. package/dist/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/index.d.ts +0 -2
  381. package/dist/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/index.js +0 -6
  382. package/dist/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/index.js.map +0 -1
  383. package/dist/components/LibraryItemsList/MenuItemListSelected/MenuItemListSelected.d.ts +0 -5
  384. package/dist/components/LibraryItemsList/MenuItemListSelected/MenuItemListSelected.js +0 -139
  385. package/dist/components/LibraryItemsList/MenuItemListSelected/MenuItemListSelected.js.map +0 -1
  386. package/dist/components/LibraryItemsList/MenuItemListSelected/index.d.ts +0 -2
  387. package/dist/components/LibraryItemsList/MenuItemListSelected/index.js +0 -6
  388. package/dist/components/LibraryItemsList/MenuItemListSelected/index.js.map +0 -1
  389. package/dist/components/LibraryItemsList/MenuSelection/MenuSelection.d.ts +0 -2
  390. package/dist/components/LibraryItemsList/MenuSelection/MenuSelection.js +0 -58
  391. package/dist/components/LibraryItemsList/MenuSelection/MenuSelection.js.map +0 -1
  392. package/dist/components/LibraryItemsList/MenuSelection/index.d.ts +0 -2
  393. package/dist/components/LibraryItemsList/MenuSelection/index.js +0 -6
  394. package/dist/components/LibraryItemsList/MenuSelection/index.js.map +0 -1
  395. package/dist/components/LibraryItemsList/MenuView/MenuView.d.ts +0 -6
  396. package/dist/components/LibraryItemsList/MenuView/MenuView.js +0 -162
  397. package/dist/components/LibraryItemsList/MenuView/MenuView.js.map +0 -1
  398. package/dist/components/LibraryItemsList/MenuView/index.d.ts +0 -2
  399. package/dist/components/LibraryItemsList/MenuView/index.js +0 -6
  400. package/dist/components/LibraryItemsList/MenuView/index.js.map +0 -1
  401. package/dist/components/LibraryItemsList/SearchItems/SearchItems.d.ts +0 -2
  402. package/dist/components/LibraryItemsList/SearchItems/SearchItems.js +0 -21
  403. package/dist/components/LibraryItemsList/SearchItems/SearchItems.js.map +0 -1
  404. package/dist/components/LibraryItemsList/SearchItems/index.d.ts +0 -2
  405. package/dist/components/LibraryItemsList/SearchItems/index.js +0 -6
  406. package/dist/components/LibraryItemsList/SearchItems/index.js.map +0 -1
  407. package/dist/components/LibraryItemsList/Sidebar/Sidebar.d.ts +0 -2
  408. package/dist/components/LibraryItemsList/Sidebar/Sidebar.js +0 -58
  409. package/dist/components/LibraryItemsList/Sidebar/Sidebar.js.map +0 -1
  410. package/dist/components/LibraryItemsList/Sidebar/index.d.ts +0 -2
  411. package/dist/components/LibraryItemsList/Sidebar/index.js +0 -6
  412. package/dist/components/LibraryItemsList/Sidebar/index.js.map +0 -1
  413. package/dist/components/LibraryItemsList/TileDisplay/ItemTileDisplay/ItemTileDisplay.d.ts +0 -6
  414. package/dist/components/LibraryItemsList/TileDisplay/ItemTileDisplay/ItemTileDisplay.js +0 -199
  415. package/dist/components/LibraryItemsList/TileDisplay/ItemTileDisplay/ItemTileDisplay.js.map +0 -1
  416. package/dist/components/LibraryItemsList/TileDisplay/ItemTileDisplay/index.d.ts +0 -2
  417. package/dist/components/LibraryItemsList/TileDisplay/ItemTileDisplay/index.js +0 -6
  418. package/dist/components/LibraryItemsList/TileDisplay/ItemTileDisplay/index.js.map +0 -1
  419. package/dist/components/LibraryItemsList/TileDisplay/TileDisplay.d.ts +0 -2
  420. package/dist/components/LibraryItemsList/TileDisplay/TileDisplay.js +0 -50
  421. package/dist/components/LibraryItemsList/TileDisplay/TileDisplay.js.map +0 -1
  422. package/dist/components/LibraryItemsList/TileDisplay/helpers/getItemPreviewSize.d.ts +0 -3
  423. package/dist/components/LibraryItemsList/TileDisplay/helpers/getItemPreviewSize.js +0 -11
  424. package/dist/components/LibraryItemsList/TileDisplay/helpers/getItemPreviewSize.js.map +0 -1
  425. package/dist/components/LibraryItemsList/TileDisplay/index.d.ts +0 -2
  426. package/dist/components/LibraryItemsList/TileDisplay/index.js +0 -6
  427. package/dist/components/LibraryItemsList/TileDisplay/index.js.map +0 -1
  428. package/dist/components/LibraryItemsList/VersionsPanel/VersionsPanel.d.ts +0 -2
  429. package/dist/components/LibraryItemsList/VersionsPanel/VersionsPanel.js +0 -66
  430. package/dist/components/LibraryItemsList/VersionsPanel/VersionsPanel.js.map +0 -1
  431. package/dist/components/LibraryItemsList/VersionsPanel/index.d.ts +0 -2
  432. package/dist/components/LibraryItemsList/VersionsPanel/index.js +0 -6
  433. package/dist/components/LibraryItemsList/VersionsPanel/index.js.map +0 -1
  434. package/dist/components/LibraryItemsList/ViewPanel/EditView/EditView.d.ts +0 -9
  435. package/dist/components/LibraryItemsList/ViewPanel/EditView/EditView.js +0 -85
  436. package/dist/components/LibraryItemsList/ViewPanel/EditView/EditView.js.map +0 -1
  437. package/dist/components/LibraryItemsList/ViewPanel/EditView/index.d.ts +0 -2
  438. package/dist/components/LibraryItemsList/ViewPanel/EditView/index.js +0 -6
  439. package/dist/components/LibraryItemsList/ViewPanel/EditView/index.js.map +0 -1
  440. package/dist/components/LibraryItemsList/ViewPanel/View/View.d.ts +0 -7
  441. package/dist/components/LibraryItemsList/ViewPanel/View/View.js +0 -152
  442. package/dist/components/LibraryItemsList/ViewPanel/View/View.js.map +0 -1
  443. package/dist/components/LibraryItemsList/ViewPanel/View/index.d.ts +0 -2
  444. package/dist/components/LibraryItemsList/ViewPanel/View/index.js +0 -6
  445. package/dist/components/LibraryItemsList/ViewPanel/View/index.js.map +0 -1
  446. package/dist/components/LibraryItemsList/ViewPanel/ViewPanel.d.ts +0 -2
  447. package/dist/components/LibraryItemsList/ViewPanel/ViewPanel.js +0 -209
  448. package/dist/components/LibraryItemsList/ViewPanel/ViewPanel.js.map +0 -1
  449. package/dist/components/LibraryItemsList/ViewPanel/index.d.ts +0 -2
  450. package/dist/components/LibraryItemsList/ViewPanel/index.js +0 -6
  451. package/dist/components/LibraryItemsList/ViewPanel/index.js.map +0 -1
  452. package/dist/components/LibraryItemsList/constants.d.ts +0 -12
  453. package/dist/components/LibraryItemsList/constants.js +0 -19
  454. package/dist/components/LibraryItemsList/constants.js.map +0 -1
  455. package/dist/components/LibraryItemsList/helpers/defaultFilterConditionByAttributeFormat.d.ts +0 -3
  456. package/dist/components/LibraryItemsList/helpers/defaultFilterConditionByAttributeFormat.js +0 -21
  457. package/dist/components/LibraryItemsList/helpers/defaultFilterConditionByAttributeFormat.js.map +0 -1
  458. package/dist/components/LibraryItemsList/helpers/displayTypeToPreviewSize.d.ts +0 -3
  459. package/dist/components/LibraryItemsList/helpers/displayTypeToPreviewSize.js +0 -18
  460. package/dist/components/LibraryItemsList/helpers/displayTypeToPreviewSize.js.map +0 -1
  461. package/dist/components/LibraryItemsList/helpers/extractAttributesFromLibrary.d.ts +0 -4
  462. package/dist/components/LibraryItemsList/helpers/extractAttributesFromLibrary.js +0 -64
  463. package/dist/components/LibraryItemsList/helpers/extractAttributesFromLibrary.js.map +0 -1
  464. package/dist/components/LibraryItemsList/helpers/getFieldFromKey.d.ts +0 -5
  465. package/dist/components/LibraryItemsList/helpers/getFieldFromKey.js +0 -40
  466. package/dist/components/LibraryItemsList/helpers/getFieldFromKey.js.map +0 -1
  467. package/dist/components/LibraryItemsList/helpers/getFieldsFromView.d.ts +0 -6
  468. package/dist/components/LibraryItemsList/helpers/getFieldsFromView.js +0 -10
  469. package/dist/components/LibraryItemsList/helpers/getFieldsFromView.js.map +0 -1
  470. package/dist/components/LibraryItemsList/helpers/getFieldsKeyFromAttribute.d.ts +0 -2
  471. package/dist/components/LibraryItemsList/helpers/getFieldsKeyFromAttribute.js +0 -13
  472. package/dist/components/LibraryItemsList/helpers/getFieldsKeyFromAttribute.js.map +0 -1
  473. package/dist/components/LibraryItemsList/helpers/getSortFieldByAttributeType.d.ts +0 -2
  474. package/dist/components/LibraryItemsList/helpers/getSortFieldByAttributeType.js +0 -18
  475. package/dist/components/LibraryItemsList/helpers/getSortFieldByAttributeType.js.map +0 -1
  476. package/dist/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.d.ts +0 -8
  477. package/dist/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.js +0 -99
  478. package/dist/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.js.map +0 -1
  479. package/dist/components/LibraryItemsList/hooks/useSearchReducer/_types.d.ts +0 -82
  480. package/dist/components/LibraryItemsList/hooks/useSearchReducer/_types.js +0 -2
  481. package/dist/components/LibraryItemsList/hooks/useSearchReducer/_types.js.map +0 -1
  482. package/dist/components/LibraryItemsList/hooks/useSearchReducer/index.d.ts +0 -2
  483. package/dist/components/LibraryItemsList/hooks/useSearchReducer/index.js +0 -6
  484. package/dist/components/LibraryItemsList/hooks/useSearchReducer/index.js.map +0 -1
  485. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchContext.d.ts +0 -7
  486. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchContext.js +0 -7
  487. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchContext.js.map +0 -1
  488. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.d.ts +0 -121
  489. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.js +0 -228
  490. package/dist/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.js.map +0 -1
  491. package/dist/components/LibraryItemsList/hooks/useSearchReducer/useSearchReducer.d.ts +0 -5
  492. package/dist/components/LibraryItemsList/hooks/useSearchReducer/useSearchReducer.js +0 -8
  493. package/dist/components/LibraryItemsList/hooks/useSearchReducer/useSearchReducer.js.map +0 -1
  494. package/dist/components/LibraryItemsList/hooks/useUpdateViewsOrderMutation.d.ts +0 -7
  495. package/dist/components/LibraryItemsList/hooks/useUpdateViewsOrderMutation.js +0 -40
  496. package/dist/components/LibraryItemsList/hooks/useUpdateViewsOrderMutation.js.map +0 -1
  497. package/dist/components/LibraryItemsList/index.d.ts +0 -1
  498. package/dist/components/LibraryItemsList/index.js +0 -5
  499. package/dist/components/LibraryItemsList/index.js.map +0 -1
  500. package/dist/components/LibraryItemsList/manageItems.d.ts +0 -11
  501. package/dist/components/LibraryItemsList/manageItems.js +0 -98
  502. package/dist/components/LibraryItemsList/manageItems.js.map +0 -1
  503. package/dist/components/LibraryItemsList/shared/DeactivateRecordBtn/DeactivateRecordBtn.d.ts +0 -7
  504. package/dist/components/LibraryItemsList/shared/DeactivateRecordBtn/DeactivateRecordBtn.js +0 -38
  505. package/dist/components/LibraryItemsList/shared/DeactivateRecordBtn/DeactivateRecordBtn.js.map +0 -1
  506. package/dist/components/LibraryItemsList/shared/DeactivateRecordBtn/index.d.ts +0 -2
  507. package/dist/components/LibraryItemsList/shared/DeactivateRecordBtn/index.js +0 -6
  508. package/dist/components/LibraryItemsList/shared/DeactivateRecordBtn/index.js.map +0 -1
  509. package/dist/components/LibraryItemsList/shared/SelectCellsBtn.d.ts +0 -12
  510. package/dist/components/LibraryItemsList/shared/SelectCellsBtn.js +0 -29
  511. package/dist/components/LibraryItemsList/shared/SelectCellsBtn.js.map +0 -1
  512. package/dist/components/LibraryItemsList/shared/sharedUtils.d.ts +0 -4
  513. package/dist/components/LibraryItemsList/shared/sharedUtils.js +0 -9
  514. package/dist/components/LibraryItemsList/shared/sharedUtils.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"FiltersDropdown.js","sourceRoot":"","sources":["../../../../src/components/LibraryItemsList/FiltersDropdown/FiltersDropdown.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,gBAAgB,EAAE,cAAc,EAAC,MAAM,mBAAmB,CAAC;AACnE,OAAO,EAAC,UAAU,EAAE,oBAAoB,EAAC,MAAM,aAAa,CAAC;AAC7D,OAAO,EAAC,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAC,MAAM,MAAM,CAAC;AAE5C,OAAc,EAAC,QAAQ,EAAC,MAAM,OAAO,CAAC;AACtC,OAAO,gBAAgB,MAAM,wDAAwD,CAAC;AACtF,OAAO,EAAC,iBAAiB,EAAC,MAAM,sEAAsE,CAAC;AACvG,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AAEpE,OAAO,EACH,wBAAwB,EACxB,UAAU,EAKV,kBAAkB,EAClB,sBAAsB,EACtB,mBAAmB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAC,aAAa,EAAC,MAAM,eAAe,CAAC;AAW5C,OAAO,EAAC,gCAAgC,EAAC,MAAM,cAAc,CAAC;AAC9D,OAAO,EAAC,6BAA6B,EAAC,MAAM,oCAAoC,CAAC;AACjF,OAAO,EAAC,uCAAuC,EAAC,MAAM,oDAAoD,CAAC;AAY3G,SAAS,eAAe,CAAC,EACrB,SAAS,EACT,MAAM,EACN,UAAU,EACV,SAAS,EACT,KAAK,EACL,MAAM,GACc;IACpB,MAAM,EAAC,CAAC,EAAC,GAAG,oBAAoB,EAAE,CAAC;IACnC,MAAM,EAAC,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,cAAc,EAAC,GAAG,gBAAgB,EAAE,CAAC;IAC1E,MAAM,EAAC,IAAI,EAAC,GAAG,OAAO,EAAE,CAAC;I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tB,KAAK,EAAE,IAAI;QACX,SAAS,EAAE,kBAAkB;QAC7B,KAAK,EAAE,EAAC,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAC;KAChD,CAAC,CAAC;IAEH,MAAM,IAAI,GAAG,EAAC,KAAK,EAAE,SAAS,EAAC,CAAC;IAEhC,OAAO,CACH,KAAC,QAAQ,IACL,QAAQ,EAAE,CAAC,CAAC,MAAM,IAAI,CAAC,MAAM,CAAC,MAAM,EACpC,IAAI,EAAE,OAAO,EACb,YAAY,EAAE,iBAAiB,EAC/B,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,CAAC,OAAO,CAAC,YAEjB,MAAM,GACA,CACd,CAAC;AACN,CAAC;AAED,eAAe,eAAe,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport {BranchesOutlined, NumberOutlined} from '@ant-design/icons';\nimport {isTypeLink, localizedTranslation} from '@leav/utils';\nimport {Badge, Dropdown, Input} from 'antd';\nimport {type ItemType} from 'antd/es/menu/interface';\nimport React, {useState} from 'react';\nimport useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';\nimport {SearchActionTypes} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';\nimport {useLang} from '_ui/hooks';\nimport {useSharedTranslation} from '_ui/hooks/useSharedTranslation';\nimport {type SystemTranslation} from '_ui/types/scalars';\nimport {\n AttributeConditionFilter,\n FilterType,\n type IFilter,\n type IFilterAttribute,\n type IFilterLibrary,\n type IFilterTree,\n SidebarContentType,\n ThroughConditionFilter,\n TreeConditionFilter,\n} from '_ui/types/search';\nimport {AttributeType} from '_ui/_gqlTypes';\nimport {\n type ILibraryDetailExtendedAttribute,\n type ILibraryDetailExtendedAttributeChild,\n type ILibraryDetailExtendedAttributeLink,\n type ILibraryDetailExtendedAttributeParentLinkedTree,\n type ILibraryDetailExtendedAttributeParentLinkedTreeLibrary,\n type ILibraryDetailExtendedAttributeStandard,\n type ILibraryDetailExtendedAttributeTree,\n type ILibraryDetailExtendedLinkedTree,\n} from '_ui/_queries/libraries/getLibraryDetailExtendQuery';\nimport {defaultLinkAttributeFilterFormat} from '../constants';\nimport {getDefaultFilterValueByFormat} from '../FiltersPanel/Filter/filterUtils';\nimport {defaultFilterConditionByAttributeFormat} from '../helpers/defaultFilterConditionByAttributeFormat';\n\ninterface IFiltersDropdownProps {\n libraryId: string;\n button: JSX.Element;\n attributes: ILibraryDetailExtendedAttribute[];\n libraries: ILibraryDetailExtendedAttributeParentLinkedTree['libraries'];\n trees: ILibraryDetailExtendedLinkedTree[];\n disabled?: boolean;\n filter?: IFilter; // if replace filter\n}\n\nfunction FiltersDropdown({\n libraryId,\n button,\n attributes,\n libraries,\n trees,\n filter,\n}: IFiltersDropdownProps): JSX.Element {\n const {t} = useSharedTranslation();\n const {state: searchState, dispatch: searchDispatch} = useSearchReducer();\n const {lang} = useLang();\n const [visible, setVisible] = useState<boolean>(false);\n const [search, setSearch] = useState<string>();\n\n const getAttributeFilter = (attribute: ILibraryDetailExtendedAttribute): IFilterAttribute => {\n // we set the new filter key with the attribute id by default\n let key = attribute.id;\n\n // If we replace a current filter, the filter key depends on filter type and whether it goes through parent attributes or not\n // The key is a concatenation of parents attribute's id\n if (typeof (filter as IFilterAttribute)?.parentTreeLibrary !== 'undefined') {\n key = `${(filter as IFilterAttribute)?.parentTreeLibrary.key}.${attribute.id}`;\n } else if (filter?.condition === ThroughConditionFilter.THROUGH && filter.type === FilterType.LIBRARY) {\n key = `${(filter as IFilterLibrary).key}.${attribute.id}`;\n } else if (filter?.condition === ThroughConditionFilter.THROUGH) {\n key = `${(filter as IFilterAttribute)?.attribute?.id}.${attribute.id}`;\n } else if ((filter as IFilterAttribute)?.attribute?.parentAttribute) {\n key = `${(filter as IFilterAttribute)?.attribute?.parentAttribute.id}.${attribute.id}`;\n }\n\n const filterAttribute: IFilterAttribute = {\n type: FilterType.ATTRIBUTE,\n index: Date.now(),\n active: true,\n key,\n condition: AttributeConditionFilter[defaultFilterConditionByAttributeFormat(attribute.format)],\n attribute: {\n id: attribute.id,\n type: attribute.type,\n format:\n isTypeLink(attribute.type) || attribute.type === AttributeType.tree\n ? defaultLinkAttributeFilterFormat\n : attribute.format,\n label: attribute.label,\n isLink: isTypeLink(attribute.type),\n isMultiple: attribute.multiple_values,\n linkedLibrary: (attribute as ILibraryDetailExtendedAttributeLink).linked_library,\n linkedTree: (attribute as ILibraryDetailExtendedAttributeTree).linked_tree,\n library: (attribute as ILibraryDetailExtendedAttributeLink).linked_library?.id || libraryId,\n embedded_fields: (attribute as ILibraryDetailExtendedAttributeStandard).embedded_fields,\n },\n value: {value: getDefaultFilterValueByFormat(attribute.format)},\n };\n\n // If filter's condition is a through condition it means current filter is a parent\n // so we set the parentAttribute field to current filter's attribute, otherwise it means\n // that the current filter is just a \"brother\" so we get the parent attribute of the current filter instead\n if (filter?.condition === ThroughConditionFilter.THROUGH) {\n filterAttribute.attribute.parentAttribute = (filter as IFilterAttribute)?.attribute;\n } else if ((filter as IFilterAttribute)?.attribute?.parentAttribute) {\n filterAttribute.attribute.parentAttribute = (filter as IFilterAttribute)?.attribute?.parentAttribute;\n }\n\n // When we chose an attribute through a tree attribute and a child library we have to set the parent tree library of the new filter\n // If current filter type is not library it means we just change the current filter attribute by another at the same level,\n // so the parent tree library is not as the first time, the filter itself, but the parentTreeLibrary of this one\n if (filter?.type === FilterType.LIBRARY) {\n filterAttribute.parentTreeLibrary = filter as IFilterLibrary;\n } else if (typeof (filter as IFilterAttribute)?.parentTreeLibrary !== 'undefined') {\n filterAttribute.parentTreeLibrary = (filter as IFilterAttribute)?.parentTreeLibrary;\n }\n\n return filterAttribute;\n };\n\n const getTreeFilter = (tree: ILibraryDetailExtendedLinkedTree): IFilterTree => ({\n type: FilterType.TREE,\n index: Date.now(),\n active: true,\n key: tree.id,\n condition: TreeConditionFilter[TreeConditionFilter.CLASSIFIED_IN],\n tree,\n value: {value: null},\n });\n\n const getLibraryFilter = (library: {\n id: string;\n label: SystemTranslation;\n attributes: ILibraryDetailExtendedAttributeChild[];\n }): IFilterLibrary => {\n // If current filter's type is a LIBRARY type it means we just changed the child library\n // and not the parent attribute so we copy the current filter parent attribute\n // The key is a concatenation of parent attributes' and libraries' id\n const key =\n filter?.type !== FilterType.LIBRARY\n ? `${(filter as IFilterAttribute).attribute?.id}.${library.id}`\n : `${(filter as IFilterLibrary).parentAttribute?.id}.${library.id}`;\n\n return {\n type: FilterType.LIBRARY,\n index: Date.now(),\n active: true,\n key,\n condition:\n AttributeConditionFilter[defaultFilterConditionByAttributeFormat(defaultLinkAttributeFilterFormat)],\n library: {id: library.id, label: library.label},\n value: {value: getDefaultFilterValueByFormat(defaultLinkAttributeFilterFormat)},\n parentAttribute:\n filter?.condition === ThroughConditionFilter.THROUGH\n ? ((filter as IFilterAttribute).attribute ?? (filter as IFilterLibrary).parentAttribute)\n : (filter as IFilterLibrary).parentAttribute,\n };\n };\n\n const addFilter = (newFilter: IFilter) => {\n const filters = [...searchState.filters];\n\n if (typeof filter !== 'undefined') {\n // we replace current filter\n const filterPos = searchState.filters.findIndex(f => f.index === filter.index);\n filters.splice(filterPos, 1, {...newFilter, index: filter.index});\n setVisible(false);\n } else {\n filters.push(newFilter);\n }\n\n searchDispatch({\n type: SearchActionTypes.SET_FILTERS,\n filters,\n });\n\n searchDispatch({\n type: SearchActionTypes.SET_SIDEBAR,\n visible: true,\n sidebarType: SidebarContentType.FILTERS,\n });\n };\n\n const _handleOpenChange = () => setVisible(!visible);\n\n const _handleSearchChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n setSearch(e.target.value);\n };\n\n const _translateLabel = function <\n T extends\n | ILibraryDetailExtendedAttribute\n | ILibraryDetailExtendedLinkedTree\n | ILibraryDetailExtendedAttributeParentLinkedTreeLibrary,\n >(el: T) {\n return {\n ...el,\n localizedLabel: localizedTranslation(el.label, lang) || el.id,\n };\n };\n\n const _filterBySearch = function (el: {id: string; localizedLabel: string}): boolean {\n const searchRegEx = new RegExp(`${search}`, 'i');\n return !search || !!el.id.match(searchRegEx) || !!el.localizedLabel.match(searchRegEx);\n };\n\n const filteredTrees = trees.map(_translateLabel).filter(_filterBySearch);\n const filteredAttributes = attributes.map(_translateLabel).filter(_filterBySearch);\n const filteredLibraries = libraries\n .map(lib => ({...lib, library: _translateLabel(lib.library)}))\n .filter(lib => _filterBySearch(lib.library));\n\n // to verify if a filter is used, we have to get the filter attribute/tree base id\n // and check if one of those is used in the list of filters depending on the filter type\n const isUIFilterUsed = (id: string) =>\n searchState.filters.some(\n f =>\n (f as IFilterTree)?.key === id ||\n (f as IFilterAttribute).attribute?.parentAttribute?.id === id ||\n (f as IFilterLibrary).parentAttribute?.id === id ||\n (f as IFilterAttribute).parentTreeLibrary?.parentAttribute?.id === id,\n );\n\n const menuItems: ItemType[] = [\n {\n key: 'search',\n label: <Input.Search placeholder={t('global.search')} onChange={_handleSearchChange} />,\n },\n {\n key: 'divider',\n type: 'divider',\n },\n ];\n\n let menuElements = [];\n if (filteredTrees.length > 0) {\n menuElements = [\n ...menuElements,\n {\n key: 'trees-group',\n type: 'group',\n label: t('filters.trees-group'),\n children: filteredTrees.map(tree => ({\n key: tree.id,\n icon: <BranchesOutlined />,\n onClick: () => addFilter(getTreeFilter(tree)),\n label: isUIFilterUsed(tree.id) ? (\n <Badge color=\"blue\" text={tree.localizedLabel} />\n ) : (\n tree.localizedLabel\n ),\n })),\n },\n ];\n }\n\n if (filteredAttributes.length > 0) {\n menuElements = [\n ...menuElements,\n {\n key: 'attributes-group',\n type: 'group',\n label: t('filters.attributes-group'),\n children: filteredAttributes.map(attribute => ({\n key: attribute.id,\n icon: <NumberOutlined />,\n onClick: () => addFilter(getAttributeFilter(attribute)),\n label: isUIFilterUsed(attribute.id) ? (\n <Badge color=\"blue\" text={attribute.localizedLabel} />\n ) : (\n attribute.localizedLabel\n ),\n })),\n },\n ];\n }\n\n if (filteredLibraries.length > 0) {\n menuElements = [\n ...menuElements,\n {\n key: 'libraries-group',\n type: 'group',\n label: t('filters.libraries-group'),\n children: filteredLibraries.map(({library}) => ({\n key: library.id,\n icon: <NumberOutlined />,\n onClick: () => addFilter(getLibraryFilter(library)),\n label: isUIFilterUsed(library.id) ? (\n <Badge color=\"blue\" text={library.localizedLabel} />\n ) : (\n library.localizedLabel\n ),\n })),\n },\n ];\n }\n\n menuItems.push({\n key: 'elements-wrapper',\n type: 'group',\n children: menuElements,\n label: null,\n className: 'elements-wrapper',\n style: {maxHeight: '75vh', overflowY: 'auto'},\n });\n\n const menu = {items: menuItems};\n\n return (\n <Dropdown\n disabled={!!filter && !filter.active}\n open={visible}\n onOpenChange={_handleOpenChange}\n menu={menu}\n trigger={['click']}\n >\n {button}\n </Dropdown>\n );\n}\n\nexport default FiltersDropdown;\n"]}
@@ -1,2 +0,0 @@
1
- import FiltersDropdown from './FiltersDropdown';
2
- export default FiltersDropdown;
@@ -1,6 +0,0 @@
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 FiltersDropdown from './FiltersDropdown';
5
- export default FiltersDropdown;
6
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/LibraryItemsList/FiltersDropdown/index.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,eAAe,MAAM,mBAAmB,CAAC;AAEhD,eAAe,eAAe,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport FiltersDropdown from './FiltersDropdown';\n\nexport default FiltersDropdown;\n"]}
@@ -1,11 +0,0 @@
1
- import { type IFilter } from '../../../../types/search';
2
- export interface IFilterInputProps {
3
- filter: IFilter;
4
- updateFilterValue: (newFilterValue: IFilter['value']) => void;
5
- onPressEnter?: () => void;
6
- }
7
- interface IFilterProps {
8
- filter: IFilter;
9
- }
10
- declare function Filter({ filter }: IFilterProps): JSX.Element;
11
- export default Filter;
@@ -1,328 +0,0 @@
1
- import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- // Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
3
- // This file is released under LGPL V3
4
- // License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
5
- import { CloseCircleFilled, MoreOutlined } from '@ant-design/icons';
6
- import { localizedTranslation } from '@leav/utils';
7
- import { Button, Dropdown } from 'antd';
8
- import { useCallback, useState } from 'react';
9
- import { CSS } from '@dnd-kit/utilities';
10
- import styled from 'styled-components';
11
- import { themeVars } from '../../../../antdTheme';
12
- import DateBetweenFilter from '../../../../components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter';
13
- import useSearchReducer from '../../../../components/LibraryItemsList/hooks/useSearchReducer';
14
- import { SearchActionTypes } from '../../../../components/LibraryItemsList/hooks/useSearchReducer/searchReducer';
15
- import { SelectTreeNodeModalOld } from '../../../../components/SelectTreeNodeModalOld';
16
- import { useLang } from '../../../../hooks';
17
- import { useSharedTranslation } from '../../../../hooks/useSharedTranslation';
18
- import { AttributeConditionFilter, FilterType, ThroughConditionFilter, TreeConditionFilter, } from '../../../../types/search';
19
- import { AttributeFormat, AttributeType, RecordFilterCondition, } from '../../../../_gqlTypes';
20
- import { formatNotUsingCondition } from '../../constants';
21
- import FiltersDropdown from '../../FiltersDropdown';
22
- import { defaultFilterConditionByAttributeFormat } from '../../helpers/defaultFilterConditionByAttributeFormat';
23
- import FilterDropdownButton from '../FilterDropdownButton';
24
- import FilterTreeCondition from '../FilterTreeCondition';
25
- import mustHideValue from '../mustHideValue';
26
- import FilterAttributeCondition from './FilterAttributeCondition';
27
- import DateFilter from './FilterInput/DateFilter';
28
- import NumericFilter from './FilterInput/NumericFilter';
29
- import TextFilter from './FilterInput/TextFilter';
30
- import { getDefaultFilterValueByFormat } from '../../../../components/LibraryItemsList/FiltersPanel/Filter/filterUtils';
31
- import { useSortable } from '@dnd-kit/sortable';
32
- const Wrapper = styled.div `
33
- background: ${themeVars.lightBg};
34
- padding: 8px 8px 8px 0px;
35
- border-radius: 3px;
36
- display: grid;
37
- grid-template-columns: 1.375rem 1fr;
38
- margin-bottom: 8px;
39
- border: 2px solid transparent;
40
-
41
- ${({ $active }) => $active
42
- ? `
43
- &:hover,
44
- &:active {
45
- border: 2px solid ${themeVars.primaryColor};
46
-
47
- &&& .filter-handle {
48
- color: ${themeVars.primaryColor};
49
- }
50
- }
51
- `
52
- : 'opacity: .5;'}
53
- `;
54
- const Handle = styled.div `
55
- content: '....';
56
- width: 20px;
57
- height: 30px;
58
- display: inline-block;
59
- overflow: hidden;
60
- line-height: 5px;
61
- padding: 3px 4px;
62
- vertical-align: middle;
63
- margin: auto;
64
- font-size: 12px;
65
- font-family: sans-serif;
66
- letter-spacing: 2px;
67
- color: ${themeVars.borderLightColor};
68
- text-shadow: 1px 0 1px black;
69
-
70
- &::after {
71
- content: '.. .. .. ..';
72
- }
73
- `;
74
- const Content = styled.div `
75
- display: grid;
76
- grid-template-rows: ${p => (p.$hasParent ? 'auto auto 1fr' : 'auto 1fr')};
77
- row-gap: 8px;
78
- `;
79
- const Head = styled.div `
80
- display: grid;
81
- grid-template-columns: 1fr 1.5rem;
82
- align-items: center;
83
- column-gap: 8px;
84
- min-width: 0;
85
- `;
86
- const HeadInfos = styled.div `
87
- display: grid;
88
- grid-template-columns: 1fr 1fr;
89
- justify-items: space-around;
90
- align-items: center;
91
- justify-content: center;
92
-
93
- background: ${themeVars.defaultBg} 0% 0% no-repeat padding-box;
94
- border: 1px solid ${themeVars.borderColor};
95
- border-radius: 3px;
96
-
97
- min-width: 0;
98
- `;
99
- const HeadOptions = styled.div `
100
- display: grid;
101
- place-items: center;
102
- height: 32px;
103
-
104
- background: ${themeVars.defaultBg} 0% 0% no-repeat padding-box;
105
- border: 1px solid ${themeVars.borderColor};
106
- border-radius: 3px;
107
- `;
108
- const ParentLabel = styled.div `
109
- display: flex;
110
- align-content: flex-start;
111
- `;
112
- const ClearParentButton = styled(Button) `
113
- && {
114
- border: none;
115
- color: ${themeVars.secondaryTextColor};
116
-
117
- :hover {
118
- border: none;
119
- color: ${themeVars.secondaryTextColor};
120
- }
121
- }
122
- `;
123
- function Filter({ filter }) {
124
- const { t } = useSharedTranslation();
125
- const { lang } = useLang();
126
- const { state: searchState, dispatch: searchDispatch } = useSearchReducer();
127
- const [showSelectTreeNodeModal, setShowSelectTreeNodeModal] = useState(false);
128
- const { attributes, listeners, setNodeRef, transform, transition } = useSortable({ id: filter.key });
129
- const style = { transform: CSS.Transform.toString(transform), transition };
130
- const handleDelete = () => {
131
- searchDispatch({
132
- type: SearchActionTypes.SET_FILTERS,
133
- filters: searchState.filters.filter(f => f.index !== filter.index),
134
- });
135
- };
136
- const updateFilterValue = (newFilterValue) => {
137
- const newFilters = searchState.filters.map(f => {
138
- if (f.index === filter.index) {
139
- return { ...f, value: newFilterValue };
140
- }
141
- return f;
142
- });
143
- searchDispatch({
144
- type: SearchActionTypes.SET_FILTERS,
145
- filters: newFilters,
146
- });
147
- };
148
- const _getValueFromNode = (node) => typeof node === 'undefined' || node.id === filter.tree.id
149
- ? { value: null }
150
- : { value: node.id, label: String(node.title) };
151
- const toggleActiveStatus = () => {
152
- const newFilters = searchState.filters.map(f => {
153
- if (f.index === filter.index) {
154
- return { ...f, active: !f.active };
155
- }
156
- return f;
157
- });
158
- searchDispatch({
159
- type: SearchActionTypes.SET_FILTERS,
160
- filters: newFilters,
161
- });
162
- };
163
- const filterOptions = {
164
- items: [
165
- {
166
- key: 'deactivate',
167
- label: filter.active ? t('filters.deactivate') : t('filters.activate'),
168
- onClick: toggleActiveStatus,
169
- },
170
- {
171
- key: 'delete',
172
- label: t('global.delete'),
173
- onClick: handleDelete,
174
- },
175
- ],
176
- };
177
- const InputByFormat = useCallback((props) => {
178
- const showStandardCondition = props.filter.condition in AttributeConditionFilter &&
179
- !(props.filter.condition in TreeConditionFilter) &&
180
- !formatNotUsingCondition.find(format => format === props.filter.attribute?.format);
181
- const showTreeCondition = props.filter.condition in TreeConditionFilter;
182
- if (showStandardCondition) {
183
- if (mustHideValue(props.filter.condition)) {
184
- return _jsx(_Fragment, {});
185
- }
186
- switch (props.filter.attribute?.format) {
187
- case AttributeFormat.date:
188
- return props.filter.condition === AttributeConditionFilter.BETWEEN ? (_jsx(DateBetweenFilter, { ...props })) : (_jsx(DateFilter, { ...props }));
189
- case AttributeFormat.date_range:
190
- return _jsx(DateFilter, { ...props });
191
- case AttributeFormat.numeric:
192
- return _jsx(NumericFilter, { ...props });
193
- case AttributeFormat.text:
194
- default:
195
- return _jsx(TextFilter, { ...props });
196
- }
197
- }
198
- else if (showTreeCondition) {
199
- return (_jsx(Button, { disabled: !props.filter.active, onClick: () => setShowSelectTreeNodeModal(true), children: props.filter.value.label || t('global.select') }));
200
- }
201
- return _jsx(_Fragment, {});
202
- }, [t]);
203
- const embeddedFieldsToAttribute = (embeddedFields) => embeddedFields
204
- ? embeddedFields.map(f => ({
205
- ...f,
206
- type: AttributeType.simple,
207
- multiple_values: undefined,
208
- linked_tree: undefined,
209
- system: false,
210
- readonly: false,
211
- }))
212
- : [];
213
- const getAttributes = () => {
214
- if (filter.type === FilterType.ATTRIBUTE) {
215
- if (filter.condition === ThroughConditionFilter.THROUGH &&
216
- filter.attribute?.format === AttributeFormat.extended) {
217
- return embeddedFieldsToAttribute(filter.attribute.embedded_fields);
218
- }
219
- if (filter.condition === ThroughConditionFilter.THROUGH &&
220
- typeof filter.attribute.linkedTree === 'undefined') {
221
- return filter.attribute.linkedLibrary?.attributes;
222
- }
223
- if (typeof filter.attribute.parentAttribute !== 'undefined') {
224
- return (filter.attribute.parentAttribute?.linkedLibrary?.attributes ||
225
- embeddedFieldsToAttribute(filter.attribute.parentAttribute?.embedded_fields));
226
- }
227
- if (typeof filter.parentTreeLibrary !== 'undefined') {
228
- const lib = filter.parentTreeLibrary.parentAttribute.linkedTree.libraries.find(l => l.library.id === filter.parentTreeLibrary.library.id);
229
- return lib.library.attributes;
230
- }
231
- if (typeof filter.attribute.linkedTree !== 'undefined' &&
232
- filter.condition === ThroughConditionFilter.THROUGH) {
233
- return [];
234
- }
235
- }
236
- if (filter.type === FilterType.LIBRARY) {
237
- if (filter.condition !== ThroughConditionFilter.THROUGH) {
238
- return [];
239
- }
240
- if (filter.condition === ThroughConditionFilter.THROUGH) {
241
- const lib = filter.parentAttribute.linkedTree?.libraries.find(l => l.library.id === filter.library.id);
242
- return lib.library.attributes;
243
- }
244
- }
245
- return searchState.library.attributes;
246
- };
247
- // on tree attribute type with linkedTree
248
- const getLibraries = () => {
249
- if (filter.type === FilterType.LIBRARY) {
250
- return filter.parentAttribute.linkedTree?.libraries;
251
- }
252
- if (filter.type === FilterType.ATTRIBUTE &&
253
- typeof filter.attribute.linkedTree !== 'undefined' &&
254
- filter.condition === ThroughConditionFilter.THROUGH) {
255
- return filter.attribute.linkedTree?.libraries;
256
- }
257
- return [];
258
- };
259
- const getTrees = () => {
260
- if (filter.type === FilterType.TREE ||
261
- (filter.condition !== ThroughConditionFilter.THROUGH &&
262
- filter.type === FilterType.ATTRIBUTE &&
263
- !filter.parentTreeLibrary &&
264
- !filter.attribute.parentAttribute)) {
265
- return searchState.trees;
266
- }
267
- return [];
268
- };
269
- const _handleResetClick = () => {
270
- const filters = [...searchState.filters];
271
- const parentAttribute = filter.type === FilterType.ATTRIBUTE &&
272
- typeof filter.parentTreeLibrary !== 'undefined'
273
- ? filter.parentTreeLibrary.parentAttribute
274
- : filter.type === FilterType.ATTRIBUTE
275
- ? (filter.attribute.parentAttribute ?? filter.attribute)
276
- : filter.parentAttribute;
277
- const newFilter = {
278
- type: FilterType.ATTRIBUTE,
279
- index: filter.index,
280
- key: parentAttribute?.id,
281
- value: {
282
- value: getDefaultFilterValueByFormat(parentAttribute.format),
283
- },
284
- active: true,
285
- condition: RecordFilterCondition[defaultFilterConditionByAttributeFormat(parentAttribute.format)],
286
- attribute: parentAttribute,
287
- };
288
- const filterPos = searchState.filters.findIndex(f => f.index === filter.index);
289
- filters.splice(filterPos, 1, newFilter);
290
- searchDispatch({
291
- type: SearchActionTypes.SET_FILTERS,
292
- filters,
293
- });
294
- };
295
- const getDropdownLabel = () => {
296
- if (filter.condition === ThroughConditionFilter.THROUGH) {
297
- return `${t('global.select')}...`;
298
- }
299
- if (filter.type === FilterType.ATTRIBUTE) {
300
- return (localizedTranslation(filter.attribute?.label, lang) ||
301
- filter.attribute?.id);
302
- }
303
- else if (filter.type === FilterType.TREE) {
304
- return localizedTranslation(filter.tree.label, lang) || filter.tree.id;
305
- }
306
- return (localizedTranslation(filter.library.label, lang) ||
307
- filter.library.id);
308
- };
309
- const getParentLabel = () => localizedTranslation(filter.condition === ThroughConditionFilter.THROUGH
310
- ? filter.attribute?.label
311
- : filter.attribute?.parentAttribute?.label ||
312
- filter.parentAttribute?.label, lang) ||
313
- `${localizedTranslation(filter.condition === ThroughConditionFilter.THROUGH
314
- ? filter.parentAttribute?.label
315
- : filter.parentTreeLibrary?.parentAttribute?.label, lang)} > ${localizedTranslation(filter.condition === ThroughConditionFilter.THROUGH
316
- ? filter?.library.label
317
- : filter.parentTreeLibrary?.library.label, lang)} `;
318
- const hasParent = !!(filter.condition === ThroughConditionFilter.THROUGH ||
319
- !!filter.attribute?.parentAttribute ||
320
- filter.parentTreeLibrary ||
321
- filter.type === FilterType.LIBRARY);
322
- const _handlePressEnter = () => {
323
- searchDispatch({ type: SearchActionTypes.APPLY_FILTERS });
324
- };
325
- return (_jsxs(_Fragment, { children: [showSelectTreeNodeModal && (_jsx(SelectTreeNodeModalOld, { selectedNodeKey: filter.value.value || filter.tree.id, treeId: filter.tree.id, onSubmit: node => updateFilterValue(_getValueFromNode(node)), onClose: () => setShowSelectTreeNodeModal(false), isVisible: showSelectTreeNodeModal, canSelectRoot: true })), _jsxs(Wrapper, { "data-testid": "filter", "$active": filter.active, ref: setNodeRef, style: style, ...attributes, children: [_jsx(Handle, { className: "filter-handle", ...listeners }), _jsxs(Content, { "$hasParent": hasParent, children: [hasParent && (_jsxs(ParentLabel, { children: [_jsxs("span", { children: [t('filters.through'), ":\u00A0"] }), _jsx("span", { children: getParentLabel() }), _jsx(ClearParentButton, { disabled: !filter.active, size: "small", onClick: _handleResetClick, shape: "circle", icon: _jsx(CloseCircleFilled, {}) })] })), _jsxs(Head, { children: [_jsxs(HeadInfos, { children: [_jsx(FiltersDropdown, { libraryId: searchState.library.id, button: _jsx(FilterDropdownButton, { secondary: filter.condition === ThroughConditionFilter.THROUGH, children: getDropdownLabel() }), filter: filter, attributes: getAttributes(), libraries: getLibraries(), trees: getTrees() }), (filter.type === FilterType.ATTRIBUTE || filter.type === FilterType.LIBRARY) && (_jsx(FilterAttributeCondition, { filter: filter, updateFilterValue: updateFilterValue })), filter.type === FilterType.TREE && _jsx(FilterTreeCondition, { filter: filter })] }), _jsx(Dropdown, { menu: filterOptions, placement: "bottomRight", children: _jsx(HeadOptions, { children: _jsx(MoreOutlined, {}) }) })] }), _jsx(InputByFormat, { filter: filter, updateFilterValue: updateFilterValue, onPressEnter: _handlePressEnter })] })] })] }));
326
- }
327
- export default Filter;
328
- //# sourceMappingURL=Filter.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Filter.js","sourceRoot":"","sources":["../../../../../src/components/LibraryItemsList/FiltersPanel/Filter/Filter.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,iBAAiB,EAAE,YAAY,EAAC,MAAM,mBAAmB,CAAC;AAClE,OAAO,EAAC,oBAAoB,EAAC,MAAM,aAAa,CAAC;AACjD,OAAO,EAAC,MAAM,EAAE,QAAQ,E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AM,CAAC,IAAI,KAAK,UAAU,CAAC,IAAI,IAAI,KAAC,mBAAmB,IAAC,MAAM,EAAE,MAAqB,GAAI,IAClF,EACZ,KAAC,QAAQ,IAAC,IAAI,EAAE,aAAa,EAAE,SAAS,EAAC,aAAa,YAClD,KAAC,WAAW,cACR,KAAC,YAAY,KAAG,GACN,GACP,IACR,EACP,KAAC,aAAa,IACV,MAAM,EAAE,MAAM,EACd,iBAAiB,EAAE,iBAAiB,EACpC,YAAY,EAAE,iBAAiB,GACjC,IACI,IACJ,IACX,CACN,CAAC;AACN,CAAC;AAED,eAAe,MAAM,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport {CloseCircleFilled, MoreOutlined} from '@ant-design/icons';\nimport {localizedTranslation} from '@leav/utils';\nimport {Button, Dropdown} from 'antd';\nimport {useCallback, useState} from 'react';\nimport {CSS} from '@dnd-kit/utilities';\nimport styled from 'styled-components';\nimport {themeVars} from '_ui/antdTheme';\nimport DateBetweenFilter from '_ui/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter';\nimport useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';\nimport {SearchActionTypes} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';\nimport {SelectTreeNodeModalOld} from '_ui/components/SelectTreeNodeModalOld';\nimport {useLang} from '_ui/hooks';\nimport {useSharedTranslation} from '_ui/hooks/useSharedTranslation';\nimport {\n AttributeConditionFilter,\n type AttributeConditionType,\n FilterType,\n type IAttribute,\n type IFilter,\n type IFilterAttribute,\n type IFilterLibrary,\n type IFilterTree,\n ThroughConditionFilter,\n TreeConditionFilter,\n} from '_ui/types/search';\nimport {type ITreeNode} from '_ui/types/trees';\nimport {\n AttributeFormat,\n type AttributesByLibAttributeStandardAttributeFragment,\n AttributeType,\n RecordFilterCondition,\n} from '_ui/_gqlTypes';\nimport {\n type ILibraryDetailExtended,\n type ILibraryDetailExtendedAttribute,\n type ILibraryDetailExtendedAttributeParentLinkedTree,\n} from '_ui/_queries/libraries/getLibraryDetailExtendQuery';\nimport {formatNotUsingCondition} from '../../constants';\nimport FiltersDropdown from '../../FiltersDropdown';\nimport {defaultFilterConditionByAttributeFormat} from '../../helpers/defaultFilterConditionByAttributeFormat';\nimport FilterDropdownButton from '../FilterDropdownButton';\nimport FilterTreeCondition from '../FilterTreeCondition';\nimport mustHideValue from '../mustHideValue';\nimport FilterAttributeCondition from './FilterAttributeCondition';\nimport DateFilter from './FilterInput/DateFilter';\nimport NumericFilter from './FilterInput/NumericFilter';\nimport TextFilter from './FilterInput/TextFilter';\nimport {getDefaultFilterValueByFormat} from '_ui/components/LibraryItemsList/FiltersPanel/Filter/filterUtils';\nimport {useSortable} from '@dnd-kit/sortable';\n\ninterface IWrapperProps {\n $active: boolean;\n}\n\nconst Wrapper = styled.div<IWrapperProps>`\n background: ${themeVars.lightBg};\n padding: 8px 8px 8px 0px;\n border-radius: 3px;\n display: grid;\n grid-template-columns: 1.375rem 1fr;\n margin-bottom: 8px;\n border: 2px solid transparent;\n\n ${({$active}) =>\n $active\n ? `\n &:hover,\n &:active {\n border: 2px solid ${themeVars.primaryColor};\n\n &&& .filter-handle {\n color: ${themeVars.primaryColor};\n }\n }\n `\n : 'opacity: .5;'}\n`;\n\nconst Handle = styled.div`\n content: '....';\n width: 20px;\n height: 30px;\n display: inline-block;\n overflow: hidden;\n line-height: 5px;\n padding: 3px 4px;\n vertical-align: middle;\n margin: auto;\n font-size: 12px;\n font-family: sans-serif;\n letter-spacing: 2px;\n color: ${themeVars.borderLightColor};\n text-shadow: 1px 0 1px black;\n\n &::after {\n content: '.. .. .. ..';\n }\n`;\n\nconst Content = styled.div<{$hasParent: boolean}>`\n display: grid;\n grid-template-rows: ${p => (p.$hasParent ? 'auto auto 1fr' : 'auto 1fr')};\n row-gap: 8px;\n`;\n\nconst Head = styled.div`\n display: grid;\n grid-template-columns: 1fr 1.5rem;\n align-items: center;\n column-gap: 8px;\n min-width: 0;\n`;\n\nconst HeadInfos = styled.div`\n display: grid;\n grid-template-columns: 1fr 1fr;\n justify-items: space-around;\n align-items: center;\n justify-content: center;\n\n background: ${themeVars.defaultBg} 0% 0% no-repeat padding-box;\n border: 1px solid ${themeVars.borderColor};\n border-radius: 3px;\n\n min-width: 0;\n`;\n\nconst HeadOptions = styled.div`\n display: grid;\n place-items: center;\n height: 32px;\n\n background: ${themeVars.defaultBg} 0% 0% no-repeat padding-box;\n border: 1px solid ${themeVars.borderColor};\n border-radius: 3px;\n`;\n\nconst ParentLabel = styled.div`\n display: flex;\n align-content: flex-start;\n`;\n\nconst ClearParentButton = styled(Button)`\n && {\n border: none;\n color: ${themeVars.secondaryTextColor};\n\n :hover {\n border: none;\n color: ${themeVars.secondaryTextColor};\n }\n }\n`;\n\nexport interface IFilterInputProps {\n filter: IFilter;\n updateFilterValue: (newFilterValue: IFilter['value']) => void;\n onPressEnter?: () => void;\n}\n\ninterface IFilterProps {\n filter: IFilter;\n}\n\nfunction Filter({filter}: IFilterProps): JSX.Element {\n const {t} = useSharedTranslation();\n const {lang} = useLang();\n const {state: searchState, dispatch: searchDispatch} = useSearchReducer();\n const [showSelectTreeNodeModal, setShowSelectTreeNodeModal] = useState(false);\n\n const {attributes, listeners, setNodeRef, transform, transition} = useSortable({id: filter.key});\n const style = {transform: CSS.Transform.toString(transform), transition};\n\n const handleDelete = () => {\n searchDispatch({\n type: SearchActionTypes.SET_FILTERS,\n filters: searchState.filters.filter(f => f.index !== filter.index),\n });\n };\n\n const updateFilterValue = (newFilterValue: IFilter['value']) => {\n const newFilters: IFilter[] = searchState.filters.map(f => {\n if (f.index === filter.index) {\n return {...f, value: newFilterValue};\n }\n\n return f;\n });\n\n searchDispatch({\n type: SearchActionTypes.SET_FILTERS,\n filters: newFilters,\n });\n };\n\n const _getValueFromNode = (node: ITreeNode): IFilter['value'] =>\n typeof node === 'undefined' || node.id === (filter as IFilterTree).tree.id\n ? {value: null}\n : {value: node.id, label: String(node.title)};\n\n const toggleActiveStatus = () => {\n const newFilters = searchState.filters.map(f => {\n if (f.index === filter.index) {\n return {...f, active: !f.active};\n }\n\n return f;\n });\n\n searchDispatch({\n type: SearchActionTypes.SET_FILTERS,\n filters: newFilters,\n });\n };\n\n const filterOptions = {\n items: [\n {\n key: 'deactivate',\n label: filter.active ? t('filters.deactivate') : t('filters.activate'),\n onClick: toggleActiveStatus,\n },\n {\n key: 'delete',\n label: t('global.delete'),\n onClick: handleDelete,\n },\n ],\n };\n\n const InputByFormat = useCallback(\n (props: IFilterInputProps) => {\n const showStandardCondition =\n props.filter.condition in AttributeConditionFilter &&\n !(props.filter.condition in TreeConditionFilter) &&\n !formatNotUsingCondition.find(\n format => format === (props.filter as IFilterAttribute).attribute?.format,\n );\n\n const showTreeCondition = props.filter.condition in TreeConditionFilter;\n\n if (showStandardCondition) {\n if (mustHideValue(props.filter.condition as AttributeConditionType)) {\n return <></>;\n }\n\n switch ((props.filter as IFilterAttribute).attribute?.format) {\n case AttributeFormat.date:\n return props.filter.condition === AttributeConditionFilter.BETWEEN ? (\n <DateBetweenFilter {...props} />\n ) : (\n <DateFilter {...props} />\n );\n case AttributeFormat.date_range:\n return <DateFilter {...props} />;\n case AttributeFormat.numeric:\n return <NumericFilter {...props} />;\n case AttributeFormat.text:\n default:\n return <TextFilter {...props} />;\n }\n } else if (showTreeCondition) {\n return (\n <Button disabled={!props.filter.active} onClick={() => setShowSelectTreeNodeModal(true)}>\n {props.filter.value.label || t('global.select')}\n </Button>\n );\n }\n\n return <></>;\n },\n [t],\n );\n\n const embeddedFieldsToAttribute = (\n embeddedFields: AttributesByLibAttributeStandardAttributeFragment['embedded_fields'],\n ): AttributesByLibAttributeStandardAttributeFragment[] =>\n embeddedFields\n ? embeddedFields.map(f => ({\n ...f,\n type: AttributeType.simple,\n multiple_values: undefined,\n linked_tree: undefined,\n system: false,\n readonly: false,\n }))\n : [];\n\n const getAttributes = (): ILibraryDetailExtendedAttribute[] => {\n if (filter.type === FilterType.ATTRIBUTE) {\n if (\n filter.condition === ThroughConditionFilter.THROUGH &&\n (filter as IFilterAttribute).attribute?.format === AttributeFormat.extended\n ) {\n return embeddedFieldsToAttribute((filter as IFilterAttribute).attribute.embedded_fields);\n }\n\n if (\n filter.condition === ThroughConditionFilter.THROUGH &&\n typeof (filter as IFilterAttribute).attribute.linkedTree === 'undefined'\n ) {\n return (filter as IFilterAttribute).attribute.linkedLibrary?.attributes;\n }\n\n if (typeof (filter as IFilterAttribute).attribute.parentAttribute !== 'undefined') {\n return (\n (filter as IFilterAttribute).attribute.parentAttribute?.linkedLibrary?.attributes ||\n embeddedFieldsToAttribute((filter as IFilterAttribute).attribute.parentAttribute?.embedded_fields)\n );\n }\n\n if (typeof (filter as IFilterAttribute).parentTreeLibrary !== 'undefined') {\n const lib = (filter as IFilterAttribute).parentTreeLibrary.parentAttribute.linkedTree.libraries.find(\n l => l.library.id === (filter as IFilterAttribute).parentTreeLibrary.library.id,\n );\n\n return lib.library.attributes;\n }\n\n if (\n typeof (filter as IFilterAttribute).attribute.linkedTree !== 'undefined' &&\n filter.condition === ThroughConditionFilter.THROUGH\n ) {\n return [];\n }\n }\n\n if (filter.type === FilterType.LIBRARY) {\n if (filter.condition !== ThroughConditionFilter.THROUGH) {\n return [];\n }\n\n if (filter.condition === ThroughConditionFilter.THROUGH) {\n const lib = (filter as IFilterLibrary).parentAttribute.linkedTree?.libraries.find(\n l => l.library.id === (filter as IFilterLibrary).library.id,\n );\n\n return lib.library.attributes;\n }\n }\n\n return searchState.library.attributes;\n };\n\n // on tree attribute type with linkedTree\n const getLibraries = (): ILibraryDetailExtendedAttributeParentLinkedTree['libraries'] => {\n if (filter.type === FilterType.LIBRARY) {\n return (filter as IFilterLibrary).parentAttribute.linkedTree?.libraries;\n }\n\n if (\n filter.type === FilterType.ATTRIBUTE &&\n typeof (filter as IFilterAttribute).attribute.linkedTree !== 'undefined' &&\n filter.condition === ThroughConditionFilter.THROUGH\n ) {\n return (filter as IFilterAttribute).attribute.linkedTree?.libraries;\n }\n\n return [];\n };\n\n const getTrees = (): ILibraryDetailExtended['linkedTrees'] => {\n if (\n filter.type === FilterType.TREE ||\n (filter.condition !== ThroughConditionFilter.THROUGH &&\n filter.type === FilterType.ATTRIBUTE &&\n !(filter as IFilterAttribute).parentTreeLibrary &&\n !(filter as IFilterAttribute).attribute.parentAttribute)\n ) {\n return searchState.trees;\n }\n\n return [];\n };\n\n const _handleResetClick = () => {\n const filters = [...searchState.filters];\n\n const parentAttribute: IAttribute =\n filter.type === FilterType.ATTRIBUTE &&\n typeof (filter as IFilterAttribute).parentTreeLibrary !== 'undefined'\n ? (filter as IFilterAttribute).parentTreeLibrary.parentAttribute\n : filter.type === FilterType.ATTRIBUTE\n ? ((filter as IFilterAttribute).attribute.parentAttribute ?? (filter as IFilterAttribute).attribute)\n : (filter as IFilterLibrary).parentAttribute;\n\n const newFilter: IFilterAttribute = {\n type: FilterType.ATTRIBUTE,\n index: filter.index,\n key: parentAttribute?.id,\n value: {\n value: getDefaultFilterValueByFormat(parentAttribute.format),\n },\n active: true,\n condition: RecordFilterCondition[defaultFilterConditionByAttributeFormat(parentAttribute.format)],\n attribute: parentAttribute,\n };\n\n const filterPos = searchState.filters.findIndex(f => f.index === filter.index);\n filters.splice(filterPos, 1, newFilter);\n\n searchDispatch({\n type: SearchActionTypes.SET_FILTERS,\n filters,\n });\n };\n\n const getDropdownLabel = (): string => {\n if (filter.condition === ThroughConditionFilter.THROUGH) {\n return `${t('global.select')}...`;\n }\n\n if (filter.type === FilterType.ATTRIBUTE) {\n return (\n localizedTranslation((filter as IFilterAttribute).attribute?.label, lang) ||\n (filter as IFilterAttribute).attribute?.id\n );\n } else if (filter.type === FilterType.TREE) {\n return localizedTranslation((filter as IFilterTree).tree.label, lang) || (filter as IFilterTree).tree.id;\n }\n\n return (\n localizedTranslation((filter as IFilterLibrary).library.label, lang) ||\n (filter as IFilterLibrary).library.id\n );\n };\n\n const getParentLabel = () =>\n localizedTranslation(\n filter.condition === ThroughConditionFilter.THROUGH\n ? (filter as IFilterAttribute).attribute?.label\n : (filter as IFilterAttribute).attribute?.parentAttribute?.label ||\n (filter as IFilterLibrary).parentAttribute?.label,\n lang,\n ) ||\n `${localizedTranslation(\n filter.condition === ThroughConditionFilter.THROUGH\n ? (filter as IFilterLibrary).parentAttribute?.label\n : (filter as IFilterAttribute).parentTreeLibrary?.parentAttribute?.label,\n lang,\n )} > ${localizedTranslation(\n filter.condition === ThroughConditionFilter.THROUGH\n ? (filter as IFilterLibrary)?.library.label\n : (filter as IFilterAttribute).parentTreeLibrary?.library.label,\n lang,\n )} `;\n\n const hasParent = !!(\n filter.condition === ThroughConditionFilter.THROUGH ||\n !!(filter as IFilterAttribute).attribute?.parentAttribute ||\n (filter as IFilterAttribute).parentTreeLibrary ||\n filter.type === FilterType.LIBRARY\n );\n\n const _handlePressEnter = () => {\n searchDispatch({type: SearchActionTypes.APPLY_FILTERS});\n };\n\n return (\n <>\n {showSelectTreeNodeModal && (\n <SelectTreeNodeModalOld\n selectedNodeKey={(filter.value.value as string) || (filter as IFilterTree).tree.id}\n treeId={(filter as IFilterTree).tree.id}\n onSubmit={node => updateFilterValue(_getValueFromNode(node))}\n onClose={() => setShowSelectTreeNodeModal(false)}\n isVisible={showSelectTreeNodeModal}\n canSelectRoot\n />\n )}\n <Wrapper data-testid=\"filter\" $active={filter.active} ref={setNodeRef} style={style} {...attributes}>\n <Handle className=\"filter-handle\" {...listeners} />\n <Content $hasParent={hasParent}>\n {hasParent && (\n <ParentLabel>\n <span>{t('filters.through')}:&nbsp;</span>\n <span>{getParentLabel()}</span>\n <ClearParentButton\n disabled={!filter.active}\n size=\"small\"\n onClick={_handleResetClick}\n shape=\"circle\"\n icon={<CloseCircleFilled />}\n />\n </ParentLabel>\n )}\n <Head>\n <HeadInfos>\n <FiltersDropdown\n libraryId={searchState.library.id}\n button={\n <FilterDropdownButton\n secondary={filter.condition === ThroughConditionFilter.THROUGH}\n >\n {getDropdownLabel()}\n </FilterDropdownButton>\n }\n filter={filter}\n attributes={getAttributes()}\n libraries={getLibraries()}\n trees={getTrees()}\n />\n {(filter.type === FilterType.ATTRIBUTE || filter.type === FilterType.LIBRARY) && (\n <FilterAttributeCondition\n filter={filter as IFilterAttribute | IFilterLibrary}\n updateFilterValue={updateFilterValue}\n />\n )}\n {filter.type === FilterType.TREE && <FilterTreeCondition filter={filter as IFilterTree} />}\n </HeadInfos>\n <Dropdown menu={filterOptions} placement=\"bottomRight\">\n <HeadOptions>\n <MoreOutlined />\n </HeadOptions>\n </Dropdown>\n </Head>\n <InputByFormat\n filter={filter}\n updateFilterValue={updateFilterValue}\n onPressEnter={_handlePressEnter}\n />\n </Content>\n </Wrapper>\n </>\n );\n}\n\nexport default Filter;\n"]}
@@ -1,7 +0,0 @@
1
- import { type IFilterAttribute, type IFilterLibrary } from '../../../../../types/search';
2
- interface IFilterAttributeConditionProps {
3
- filter: IFilterAttribute | IFilterLibrary;
4
- updateFilterValue: (newValue: any) => void;
5
- }
6
- declare const FilterAttributeCondition: ({ filter, updateFilterValue }: IFilterAttributeConditionProps) => JSX.Element;
7
- export default FilterAttributeCondition;
@@ -1,90 +0,0 @@
1
- import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
2
- // Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
3
- // This file is released under LGPL V3
4
- // License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
5
- import { isTypeLink } from '@leav/utils';
6
- import { Dropdown } from 'antd';
7
- import styled from 'styled-components';
8
- import { formatNotUsingCondition } from '../../../../../components/LibraryItemsList/constants';
9
- import BooleanFilter from '../../../../../components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter';
10
- import useSearchReducer from '../../../../../components/LibraryItemsList/hooks/useSearchReducer';
11
- import { SearchActionTypes } from '../../../../../components/LibraryItemsList/hooks/useSearchReducer/searchReducer';
12
- import { useSharedTranslation } from '../../../../../hooks/useSharedTranslation';
13
- import { AttributeConditionFilter, FilterType, } from '../../../../../types/search';
14
- import { AttributeFormat, AttributeType } from '../../../../../_gqlTypes';
15
- import FilterDropdownButton from '../../FilterDropdownButton';
16
- import { getConditionOptionsByType } from '../../FiltersOptions';
17
- import mustHideValue from '../../mustHideValue';
18
- import { getDefaultFilterValueByFormat } from '../filterUtils';
19
- const BooleanWrapper = styled.span `
20
- padding: 0 1rem;
21
- height: 100%;
22
- display: grid;
23
- place-items: center;
24
- `;
25
- const FilterAttributeCondition = ({ filter, updateFilterValue }) => {
26
- const { t } = useSharedTranslation();
27
- const { state: searchState, dispatch: searchDispatch } = useSearchReducer();
28
- const showthroughCondition = (filter.attribute?.format === AttributeFormat.extended ||
29
- filter.type === FilterType.LIBRARY ||
30
- isTypeLink(filter.attribute?.type) ||
31
- filter.attribute?.type === AttributeType.tree) &&
32
- typeof filter.attribute?.parentAttribute === 'undefined' &&
33
- typeof filter.parentTreeLibrary === 'undefined' &&
34
- filter.condition !== AttributeConditionFilter.THROUGH;
35
- const conditionOptionsByType = getConditionOptionsByType(filter, showthroughCondition, t);
36
- const _handleConditionChange = (condition) => {
37
- const newFilters = searchState.filters.map(f => {
38
- if (f.index === filter.index) {
39
- let newValue = { ...filter.value };
40
- if (mustHideValue(condition)) {
41
- newValue = null;
42
- }
43
- else if (newValue === null ||
44
- (typeof newValue?.value === 'object' && condition !== AttributeConditionFilter.BETWEEN)) {
45
- newValue.value = getDefaultFilterValueByFormat(filter.attribute.format);
46
- }
47
- return {
48
- ...filter,
49
- value: newValue,
50
- condition: AttributeConditionFilter[condition],
51
- };
52
- }
53
- return f;
54
- });
55
- searchDispatch({ type: SearchActionTypes.SET_FILTERS, filters: newFilters });
56
- };
57
- const showStandardCondition = !formatNotUsingCondition.find(format => (filter.type === FilterType.LIBRARY && format === AttributeFormat.text) ||
58
- (filter.type === FilterType.ATTRIBUTE && format === filter.attribute.format));
59
- const menuItems = conditionOptionsByType
60
- .filter(c => c.value !== AttributeConditionFilter.THROUGH || showthroughCondition)
61
- .reduce((items, condition) => {
62
- if (condition.value === AttributeConditionFilter.THROUGH) {
63
- items.push({
64
- key: 'through-divider',
65
- type: 'divider',
66
- });
67
- }
68
- items.push({
69
- key: condition.value,
70
- label: condition.textByFormat?.[filter?.attribute?.format] ?? condition?.text,
71
- onClick: () => _handleConditionChange(condition.value),
72
- });
73
- return items;
74
- }, []);
75
- if (showStandardCondition) {
76
- const conditionOption = conditionOptionsByType.filter(c => c.value === filter.condition)[0];
77
- return (_jsx(Dropdown, { disabled: !filter.active || filter.condition === AttributeConditionFilter.THROUGH, menu: { items: menuItems }, trigger: ['click'], children: _jsx(FilterDropdownButton, { "aria-label": "filter-condition", children: conditionOption?.textByFormat?.[filter?.attribute?.format] ??
78
- conditionOption?.text }) }));
79
- }
80
- else {
81
- switch (filter.attribute.format) {
82
- case AttributeFormat.boolean:
83
- return (_jsx(BooleanWrapper, { children: _jsx(BooleanFilter, { filter: filter, updateFilterValue: updateFilterValue }) }));
84
- default:
85
- return _jsx(_Fragment, {});
86
- }
87
- }
88
- };
89
- export default FilterAttributeCondition;
90
- //# sourceMappingURL=FilterAttributeCondition.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FilterAttributeCondition.js","sourceRoot":"","sources":["../../../../../../src/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/FilterAttributeCondition.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,UAAU,EAAC,MAAM,aAAa,CAAC;AACvC,OAAO,EAAC,QAAQ,EAAC,MAAM,MAAM,CAAC;AAE9B,OAAO,MAAM,MAAM,mBAAmB,CAAC;AACvC,OAAO,EAAC,uBAAuB,EAAC,MAAM,2CAA2C,CAAC;AAClF,OAAO,aAAa,MAAM,+EAA+E,CAAC;AAC1G,OAAO,gBAAgB,MAAM,wDAAwD,CAA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AAS,MAA2B,CAAC,SAAS,CAAC,MAAM,EAAE,CAAC;YACpD,KAAK,eAAe,CAAC,OAAO;gBACxB,OAAO,CACH,KAAC,cAAc,cACX,KAAC,aAAa,IAAC,MAAM,EAAE,MAAM,EAAE,iBAAiB,EAAE,iBAAiB,GAAI,GAC1D,CACpB,CAAC;YACN;gBACI,OAAO,mBAAK,CAAC;QACrB,CAAC;IACL,CAAC;AACL,CAAC,CAAC;AAEF,eAAe,wBAAwB,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport {isTypeLink} from '@leav/utils';\nimport {Dropdown} from 'antd';\nimport {type ItemType} from 'antd/es/menu/interface';\nimport styled from 'styled-components';\nimport {formatNotUsingCondition} from '_ui/components/LibraryItemsList/constants';\nimport BooleanFilter from '_ui/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter';\nimport useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';\nimport {SearchActionTypes} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';\nimport {useSharedTranslation} from '_ui/hooks/useSharedTranslation';\nimport {\n AttributeConditionFilter,\n type AttributeConditionType,\n FilterType,\n type IFilterAttribute,\n type IFilterLibrary,\n} from '_ui/types/search';\nimport {AttributeFormat, AttributeType} from '_ui/_gqlTypes';\nimport FilterDropdownButton from '../../FilterDropdownButton';\nimport {getConditionOptionsByType} from '../../FiltersOptions';\nimport mustHideValue from '../../mustHideValue';\nimport {getDefaultFilterValueByFormat} from '../filterUtils';\n\nconst BooleanWrapper = styled.span`\n padding: 0 1rem;\n height: 100%;\n display: grid;\n place-items: center;\n`;\n\ninterface IFilterAttributeConditionProps {\n filter: IFilterAttribute | IFilterLibrary;\n updateFilterValue: (newValue: any) => void;\n}\n\nconst FilterAttributeCondition = ({filter, updateFilterValue}: IFilterAttributeConditionProps) => {\n const {t} = useSharedTranslation();\n\n const {state: searchState, dispatch: searchDispatch} = useSearchReducer();\n\n const showthroughCondition =\n ((filter as IFilterAttribute).attribute?.format === AttributeFormat.extended ||\n filter.type === FilterType.LIBRARY ||\n isTypeLink((filter as IFilterAttribute).attribute?.type) ||\n (filter as IFilterAttribute).attribute?.type === AttributeType.tree) &&\n typeof (filter as IFilterAttribute).attribute?.parentAttribute === 'undefined' &&\n typeof (filter as IFilterAttribute).parentTreeLibrary === 'undefined' &&\n filter.condition !== AttributeConditionFilter.THROUGH;\n\n const conditionOptionsByType = getConditionOptionsByType(filter, showthroughCondition, t);\n\n const _handleConditionChange = (condition: AttributeConditionType) => {\n const newFilters = searchState.filters.map(f => {\n if (f.index === filter.index) {\n let newValue = {...filter.value};\n\n if (mustHideValue(condition)) {\n newValue = null;\n } else if (\n newValue === null ||\n (typeof newValue?.value === 'object' && condition !== AttributeConditionFilter.BETWEEN)\n ) {\n newValue.value = getDefaultFilterValueByFormat((filter as IFilterAttribute).attribute.format);\n }\n\n return {\n ...filter,\n value: newValue,\n condition: AttributeConditionFilter[condition],\n };\n }\n\n return f;\n });\n\n searchDispatch({type: SearchActionTypes.SET_FILTERS, filters: newFilters});\n };\n\n const showStandardCondition = !formatNotUsingCondition.find(\n format =>\n (filter.type === FilterType.LIBRARY && format === AttributeFormat.text) ||\n (filter.type === FilterType.ATTRIBUTE && format === (filter as IFilterAttribute).attribute.format),\n );\n\n const menuItems: ItemType[] = conditionOptionsByType\n .filter(c => c.value !== AttributeConditionFilter.THROUGH || showthroughCondition)\n .reduce((items: ItemType[], condition): ItemType[] => {\n if (condition.value === AttributeConditionFilter.THROUGH) {\n items.push({\n key: 'through-divider',\n type: 'divider',\n });\n }\n\n items.push({\n key: condition.value,\n label: condition.textByFormat?.[(filter as IFilterAttribute)?.attribute?.format] ?? condition?.text,\n onClick: () => _handleConditionChange(condition.value),\n });\n\n return items;\n }, []);\n\n if (showStandardCondition) {\n const conditionOption = conditionOptionsByType.filter(c => c.value === filter.condition)[0];\n return (\n <Dropdown\n disabled={!filter.active || filter.condition === AttributeConditionFilter.THROUGH}\n menu={{items: menuItems}}\n trigger={['click']}\n >\n <FilterDropdownButton aria-label=\"filter-condition\">\n {conditionOption?.textByFormat?.[(filter as IFilterAttribute)?.attribute?.format] ??\n conditionOption?.text}\n </FilterDropdownButton>\n </Dropdown>\n );\n } else {\n switch ((filter as IFilterAttribute).attribute.format) {\n case AttributeFormat.boolean:\n return (\n <BooleanWrapper>\n <BooleanFilter filter={filter} updateFilterValue={updateFilterValue} />\n </BooleanWrapper>\n );\n default:\n return <></>;\n }\n }\n};\n\nexport default FilterAttributeCondition;\n"]}
@@ -1,2 +0,0 @@
1
- import FilterAttributeCondition from './FilterAttributeCondition';
2
- export default FilterAttributeCondition;
@@ -1,6 +0,0 @@
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 FilterAttributeCondition from './FilterAttributeCondition';
5
- export default FilterAttributeCondition;
6
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/index.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,wBAAwB,MAAM,4BAA4B,CAAC;AAElE,eAAe,wBAAwB,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport FilterAttributeCondition from './FilterAttributeCondition';\n\nexport default FilterAttributeCondition;\n"]}
@@ -1,3 +0,0 @@
1
- import { type IFilterInputProps } from '../../Filter';
2
- declare function BooleanFilter({ filter, updateFilterValue }: IFilterInputProps): JSX.Element;
3
- export default BooleanFilter;