@leav/ui 0.0.1-alpha-2 → 0.0.1-alpha-3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/libs/ui/tsconfig.tsbuildinfo +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +5 -1
- package/apollo.apiKey.js.example +0 -7
- package/codegen.ts +0 -48
- package/graphql_codegen.ts +0 -19
- package/jest.config.js +0 -21
- package/scripts/createComponent.js +0 -79
- package/setupTests.ts +0 -21
- package/src/__mocks__/common/application.ts +0 -30
- package/src/__mocks__/common/attribute.ts +0 -164
- package/src/__mocks__/common/filter.ts +0 -41
- package/src/__mocks__/common/form.tsx +0 -291
- package/src/__mocks__/common/import.ts +0 -31
- package/src/__mocks__/common/label.ts +0 -7
- package/src/__mocks__/common/library.ts +0 -111
- package/src/__mocks__/common/mockSearchContextProvider.tsx +0 -23
- package/src/__mocks__/common/record.ts +0 -27
- package/src/__mocks__/common/tree.ts +0 -33
- package/src/__mocks__/common/treeElements.ts +0 -73
- package/src/__mocks__/common/value.ts +0 -48
- package/src/__mocks__/common/versionProfile.ts +0 -10
- package/src/__mocks__/common/view.ts +0 -28
- package/src/__mocks__/mockQuery/mockGetLibraryDetailExtendedQuery.ts +0 -66
- package/src/__mocks__/mockQuery/mockGetRecordsFromLibraryQuery.ts +0 -42
- package/src/__mocks__/mockQuery/mockGetViewListQuery.ts +0 -52
- package/src/__mocks__/react-i18next.js +0 -73
- package/src/_gqlTypes/index.ts +0 -3853
- package/src/_queries/applications/applicationDetailsFragment.ts +0 -27
- package/src/_queries/applications/checkApplicationExistence.ts +0 -12
- package/src/_queries/applications/getApplicationDetails.ts +0 -16
- package/src/_queries/applications/getApplicationsModulesQuery.ts +0 -14
- package/src/_queries/applications/saveApplicationMutation.ts +0 -14
- package/src/_queries/attributes/attributeDetailsFragment.ts +0 -57
- package/src/_queries/attributes/checkAttributeExistenceQuery.ts +0 -12
- package/src/_queries/attributes/deleteAttributeMutation.ts +0 -12
- package/src/_queries/attributes/getAttributeByIdQuery.ts +0 -16
- package/src/_queries/attributes/getAttributeWithEmbeddedFields.ts +0 -32
- package/src/_queries/attributes/getAttributesByLib.ts +0 -48
- package/src/_queries/attributes/getAttributesQuery.ts +0 -19
- package/src/_queries/attributes/getVersionProfilesQuery.ts +0 -15
- package/src/_queries/attributes/getVersionableAttributesByLibrary.ts +0 -24
- package/src/_queries/attributes/saveAttributeMutation.ts +0 -14
- package/src/_queries/export/exportQuery.ts +0 -10
- package/src/_queries/files/createDirectory.ts +0 -14
- package/src/_queries/files/forcePreviewsGenerationMutation.ts +0 -22
- package/src/_queries/files/getDirectoryDataQuery.ts +0 -53
- package/src/_queries/files/getUploadUpdates.ts +0 -23
- package/src/_queries/files/uploadMutation.ts +0 -18
- package/src/_queries/import/importExcel.ts +0 -11
- package/src/_queries/libraries/checkLibraryExistenceQuery.ts +0 -12
- package/src/_queries/libraries/deleteLibraryMutation.ts +0 -12
- package/src/_queries/libraries/getLibrariesQuery.ts +0 -29
- package/src/_queries/libraries/getLibraryByIdQuery.ts +0 -16
- package/src/_queries/libraries/getLibraryDetailExtendQuery.ts +0 -259
- package/src/_queries/libraries/getLibraryPermissionsQuery.ts +0 -20
- package/src/_queries/libraries/getLibraryPreviewsSettingsQuery.ts +0 -29
- package/src/_queries/libraries/libraryDetailsFragment.ts +0 -87
- package/src/_queries/libraries/saveLibraryMutation.ts +0 -14
- package/src/_queries/permissions/isAllowedQuery.ts +0 -18
- package/src/_queries/records/createRecordMutation.ts +0 -26
- package/src/_queries/records/deactivateRecordsMutation.ts +0 -15
- package/src/_queries/records/doesFileExistAsChild.ts +0 -10
- package/src/_queries/records/getFileDataQuery.ts +0 -77
- package/src/_queries/records/getRecordColumnsValues.ts +0 -90
- package/src/_queries/records/getRecordFormQuery.ts +0 -62
- package/src/_queries/records/getRecordPropertiesQuery.ts +0 -165
- package/src/_queries/records/getRecordUpdatesSubscription.ts +0 -31
- package/src/_queries/records/getRecordsFromLibraryQuery.ts +0 -137
- package/src/_queries/records/indexRecordsMutation.ts +0 -10
- package/src/_queries/records/recordFormAttributeFragment.ts +0 -94
- package/src/_queries/tasks/cancelTaskMutation.ts +0 -10
- package/src/_queries/trees/checkTreeExistenceQuery.ts +0 -12
- package/src/_queries/trees/deleteTreeMutation.ts +0 -12
- package/src/_queries/trees/getTreeByIdQuery.ts +0 -16
- package/src/_queries/trees/getTreeLibraries.ts +0 -30
- package/src/_queries/trees/getTreesQuery.ts +0 -18
- package/src/_queries/trees/saveTreeMutation.ts +0 -14
- package/src/_queries/trees/treeDetailsFragment.ts +0 -24
- package/src/_queries/trees/treeNodeChildrenQuery.ts +0 -48
- package/src/_queries/userData/getUserData.ts +0 -13
- package/src/_queries/userData/saveUserData.ts +0 -13
- package/src/_queries/values/deleteValueMutation.ts +0 -14
- package/src/_queries/values/saveValueBatchMutation.ts +0 -34
- package/src/_queries/values/valueDetailsFragment.ts +0 -76
- package/src/_queries/values/valuesVersionFragment.ts +0 -23
- package/src/_queries/views/deleteViewMutation.ts +0 -23
- package/src/_queries/views/getViewById.ts +0 -16
- package/src/_queries/views/getViewsListQuery.ts +0 -17
- package/src/_queries/views/saveViewMutation.ts +0 -16
- package/src/_queries/views/viewDetailsFragment.ts +0 -59
- package/src/_tests/testUtils.tsx +0 -46
- package/src/_utils/getFiltersFromRequest.ts +0 -136
- package/src/_utils/getRequestFromFilter.ts +0 -61
- package/src/_utils/index.ts +0 -189
- package/src/antdTheme/index.ts +0 -108
- package/src/antdTheme/types.ts +0 -5
- package/src/components/AttributePicker/AttributePicker.test.tsx +0 -286
- package/src/components/AttributePicker/AttributePicker.tsx +0 -71
- package/src/components/AttributePicker/AttributesList/AttributesList.tsx +0 -330
- package/src/components/AttributePicker/AttributesList/index.ts +0 -4
- package/src/components/AttributePicker/index.ts +0 -4
- package/src/components/AttributesSelectionList/Attribute/Attribute.tsx +0 -67
- package/src/components/AttributesSelectionList/Attribute/index.ts +0 -5
- package/src/components/AttributesSelectionList/AttributesSelectionList.test.tsx +0 -115
- package/src/components/AttributesSelectionList/AttributesSelectionList.tsx +0 -132
- package/src/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/SelectedAttribute.tsx +0 -69
- package/src/components/AttributesSelectionList/SelectedAttributesList/SelectedAttribute/index.ts +0 -5
- package/src/components/AttributesSelectionList/SelectedAttributesList/SelectedAttributesList.tsx +0 -96
- package/src/components/AttributesSelectionList/SelectedAttributesList/index.ts +0 -5
- package/src/components/AttributesSelectionList/_types.ts +0 -16
- package/src/components/AttributesSelectionList/helpers/attributeToSelectedAttribute.ts +0 -11
- package/src/components/AttributesSelectionList/index.ts +0 -5
- package/src/components/AttributesSelectionList/reducer/__mocks__/attributesSelectionListStateContext.ts +0 -10
- package/src/components/AttributesSelectionList/reducer/attributesSelectionListReducer.test.tsx +0 -202
- package/src/components/AttributesSelectionList/reducer/attributesSelectionListReducer.tsx +0 -118
- package/src/components/AttributesSelectionList/reducer/attributesSelectionListStateContext.ts +0 -16
- package/src/components/AttributesSelectionList/sharedComponents.tsx +0 -18
- package/src/components/BasicButton/BasicButton.test.tsx +0 -14
- package/src/components/BasicButton/BasicButton.tsx +0 -36
- package/src/components/BasicButton/index.ts +0 -4
- package/src/components/CreateDirectory/CreateDirectory.test.tsx +0 -291
- package/src/components/CreateDirectory/CreateDirectory.tsx +0 -222
- package/src/components/CreateDirectory/index.ts +0 -4
- package/src/components/DeactivateRecordsModal/DeactivateRecordsModal.test.tsx +0 -147
- package/src/components/DeactivateRecordsModal/DeactivateRecordsModal.tsx +0 -78
- package/src/components/DeactivateRecordsModal/index.ts +0 -4
- package/src/components/Dimmer/Dimmer.test.tsx +0 -21
- package/src/components/Dimmer/Dimmer.tsx +0 -27
- package/src/components/Dimmer/index.ts +0 -5
- package/src/components/EditApplication/EditApplication.test.tsx +0 -315
- package/src/components/EditApplication/EditApplication.tsx +0 -64
- package/src/components/EditApplication/EditApplicationInfo/EditApplicationInfo.tsx +0 -166
- package/src/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/EditApplicationInfoForm.tsx +0 -316
- package/src/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/ModuleSelector/ModuleSelector.tsx +0 -51
- package/src/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/ModuleSelector/index.ts +0 -5
- package/src/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/index.ts +0 -5
- package/src/components/EditApplication/EditApplicationInfo/index.ts +0 -4
- package/src/components/EditApplication/_types.ts +0 -12
- package/src/components/EditApplication/index.ts +0 -5
- package/src/components/EditAttributeModal/EditAttribute/EditAttribute.tsx +0 -68
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfo.tsx +0 -188
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/EditAttributeInfoForm.tsx +0 -382
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedLibraryForm/LinkedLibraryForm.tsx +0 -88
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedLibraryForm/index.ts +0 -4
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedTreeForm/LinkedTreeForm.tsx +0 -84
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedTreeForm/index.ts +0 -4
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/ValuesVersionsForm/ValuesVersionsForm.tsx +0 -100
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/ValuesVersionsForm/index.ts +0 -4
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/index.ts +0 -4
- package/src/components/EditAttributeModal/EditAttribute/EditAttributeInfo/index.ts +0 -4
- package/src/components/EditAttributeModal/EditAttribute/index.ts +0 -4
- package/src/components/EditAttributeModal/EditAttributeModal.test.tsx +0 -335
- package/src/components/EditAttributeModal/EditAttributeModal.tsx +0 -178
- package/src/components/EditAttributeModal/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibrary.tsx +0 -119
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributeCell/AttributeCell.tsx +0 -61
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributeCell/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributesList.tsx +0 -273
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/DeleteButton/DeleteButton.tsx +0 -52
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/DeleteButton/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/EditLibraryAttributes.test.tsx +0 -116
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/EditLibraryAttributes.tsx +0 -56
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryIndexation/EditLibraryIndexation.tsx +0 -134
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryIndexation/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfo.tsx +0 -159
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfoForm/EditLibraryInfoForm.tsx +0 -306
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfoForm/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryInfo/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditLibraryPreviewsSettings.test.tsx +0 -85
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditLibraryPreviewsSettings.tsx +0 -51
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/EditPreviewsSettingsModal.test.tsx +0 -76
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/EditPreviewsSettingsModal.tsx +0 -180
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/SizesEditor/SizesEditor.tsx +0 -182
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/SizesEditor/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/PreviewsSettingsList/PreviewsSettingsList.tsx +0 -241
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/PreviewsSettingsList/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibrary/index.ts +0 -4
- package/src/components/EditLibraryModal/EditLibraryModal.test.tsx +0 -346
- package/src/components/EditLibraryModal/EditLibraryModal.tsx +0 -178
- package/src/components/EditLibraryModal/index.ts +0 -4
- package/src/components/EditTreeModal/EditTree/EditTree.tsx +0 -68
- package/src/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfo.tsx +0 -171
- package/src/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/EditTreeInfoForm.tsx +0 -216
- package/src/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/TreeLibrariesForm/TreeLibrariesForm.tsx +0 -239
- package/src/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/TreeLibrariesForm/index.ts +0 -4
- package/src/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/index.ts +0 -4
- package/src/components/EditTreeModal/EditTree/EditTreeInfo/index.ts +0 -4
- package/src/components/EditTreeModal/EditTree/index.ts +0 -4
- package/src/components/EditTreeModal/EditTreeModal.test.tsx +0 -516
- package/src/components/EditTreeModal/EditTreeModal.tsx +0 -167
- package/src/components/EditTreeModal/index.ts +0 -4
- package/src/components/EntityCard/EntityCard.test.tsx +0 -50
- package/src/components/EntityCard/EntityCard.tsx +0 -177
- package/src/components/EntityCard/_types.ts +0 -9
- package/src/components/EntityCard/index.ts +0 -5
- package/src/components/EntityPreview/EntityPreview.test.tsx +0 -50
- package/src/components/EntityPreview/EntityPreview.tsx +0 -17
- package/src/components/EntityPreview/EntityPreviewList/EntityPreviewList.tsx +0 -106
- package/src/components/EntityPreview/EntityPreviewList/SimplisticEntityPreview/SimplisticEntityPreview.tsx +0 -34
- package/src/components/EntityPreview/EntityPreviewList/SimplisticEntityPreview/index.ts +0 -5
- package/src/components/EntityPreview/EntityPreviewList/index.ts +0 -5
- package/src/components/EntityPreview/EntityPreviewTile/EntityPreviewTile.tsx +0 -105
- package/src/components/EntityPreview/EntityPreviewTile/index.ts +0 -5
- package/src/components/EntityPreview/_types.ts +0 -25
- package/src/components/EntityPreview/index.ts +0 -5
- package/src/components/ErrorBoundary/ErrorBoundary.test.tsx +0 -43
- package/src/components/ErrorBoundary/ErrorBoundary.tsx +0 -46
- package/src/components/ErrorBoundary/ErrorBoundaryContent/ErrorBoundaryContent.tsx +0 -59
- package/src/components/ErrorBoundary/ErrorBoundaryContent/index.ts +0 -5
- package/src/components/ErrorBoundary/index.ts +0 -4
- package/src/components/ErrorDisplay/ErrorDisplay.test.tsx +0 -15
- package/src/components/ErrorDisplay/ErrorDisplay.tsx +0 -67
- package/src/components/ErrorDisplay/index.ts +0 -4
- package/src/components/ErrorMessage/ErrorMessage.test.tsx +0 -30
- package/src/components/ErrorMessage/ErrorMessage.tsx +0 -45
- package/src/components/ErrorMessage/index.ts +0 -5
- package/src/components/ExportModal/ExportModal.test.tsx +0 -44
- package/src/components/ExportModal/ExportModal.tsx +0 -205
- package/src/components/ExportModal/index.ts +0 -4
- package/src/components/FieldsGroup/FieldsGroup.test.tsx +0 -18
- package/src/components/FieldsGroup/FieldsGroup.tsx +0 -43
- package/src/components/FieldsGroup/index.ts +0 -5
- package/src/components/FloatingMenu/FloatingMenu.test.tsx +0 -81
- package/src/components/FloatingMenu/FloatingMenu.tsx +0 -94
- package/src/components/FloatingMenu/_types.ts +0 -20
- package/src/components/FloatingMenu/index.ts +0 -5
- package/src/components/ImageLoading/ImageLoading.tsx +0 -32
- package/src/components/ImageLoading/index.ts +0 -4
- package/src/components/ImageMissing/ImageMissing.tsx +0 -38
- package/src/components/ImageMissing/index.ts +0 -4
- package/src/components/ImportModal/ImportModal.tsx +0 -287
- package/src/components/ImportModal/ImportModalConfigStep/ImportKeysSelector/ImportKeysSelector.tsx +0 -60
- package/src/components/ImportModal/ImportModalConfigStep/ImportKeysSelector/index.ts +0 -5
- package/src/components/ImportModal/ImportModalConfigStep/ImportMappingRowTitle/ImportMappingRowTitle.tsx +0 -37
- package/src/components/ImportModal/ImportModalConfigStep/ImportMappingRowTitle/index.ts +0 -5
- package/src/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.tsx +0 -298
- package/src/components/ImportModal/ImportModalConfigStep/ImportScheduleModal/ImportScheduleModal.tsx +0 -52
- package/src/components/ImportModal/ImportModalConfigStep/ImportScheduleModal/index.ts +0 -5
- package/src/components/ImportModal/ImportModalConfigStep/ImportSheetSettings/ImportSheetSettings.tsx +0 -155
- package/src/components/ImportModal/ImportModalConfigStep/ImportSheetSettings/index.ts +0 -5
- package/src/components/ImportModal/ImportModalConfigStep/index.ts +0 -5
- package/src/components/ImportModal/ImportModalDoneStep/ImportModalDoneStep.tsx +0 -28
- package/src/components/ImportModal/ImportModalDoneStep/index.ts +0 -5
- package/src/components/ImportModal/ImportModalProcessingStep/ImportModalProcessingStep.tsx +0 -17
- package/src/components/ImportModal/ImportModalProcessingStep/index.ts +0 -5
- package/src/components/ImportModal/ImportModalSelectFileStep/ImportModalSelectFileStep.tsx +0 -212
- package/src/components/ImportModal/ImportModalSelectFileStep/index.ts +0 -5
- package/src/components/ImportModal/_types.ts +0 -44
- package/src/components/ImportModal/importReducer/ImportReducerContext.ts +0 -17
- package/src/components/ImportModal/importReducer/importReducer.test.ts +0 -125
- package/src/components/ImportModal/importReducer/importReducer.ts +0 -171
- package/src/components/ImportModal/importReducer/index.ts +0 -5
- package/src/components/ImportModal/index.ts +0 -4
- package/src/components/LibraryItemsList/DisplayOptions/DisplayOptions.tsx +0 -121
- package/src/components/LibraryItemsList/DisplayOptions/index.ts +0 -5
- package/src/components/LibraryItemsList/DisplayTypeSelector/DisplayTypeSelector.test.tsx +0 -29
- package/src/components/LibraryItemsList/DisplayTypeSelector/DisplayTypeSelector.tsx +0 -23
- package/src/components/LibraryItemsList/DisplayTypeSelector/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersDropdown/FiltersDropdown.tsx +0 -341
- package/src/components/LibraryItemsList/FiltersDropdown/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/Filter.test.tsx +0 -75
- package/src/components/LibraryItemsList/FiltersPanel/Filter/Filter.tsx +0 -544
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/FilterAttributeCondition.tsx +0 -134
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterAttributeCondition/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/BooleanFilter.test.tsx +0 -38
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/BooleanFilter.tsx +0 -23
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/BooleanFilter/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/DateBetweenFilter.test.tsx +0 -14
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/DateBetweenFilter.tsx +0 -43
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateBetweenFilter/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/DateFilter.test.tsx +0 -14
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/DateFilter.tsx +0 -36
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/DateFilter/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/NumericFilter.test.tsx +0 -14
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/NumericFilter.tsx +0 -50
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/NumericFilter/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/TextFilter.test.tsx +0 -16
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/TextFilter.tsx +0 -52
- package/src/components/LibraryItemsList/FiltersPanel/Filter/FilterInput/TextFilter/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/Filter/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/FilterDropdownButton.tsx +0 -27
- package/src/components/LibraryItemsList/FiltersPanel/FilterDropdownButton/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/FilterTreeCondition.test.tsx +0 -23
- package/src/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/FilterTreeCondition.tsx +0 -54
- package/src/components/LibraryItemsList/FiltersPanel/FilterTreeCondition/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/FiltersOptions.tsx +0 -192
- package/src/components/LibraryItemsList/FiltersPanel/FiltersPanel.tsx +0 -190
- package/src/components/LibraryItemsList/FiltersPanel/index.ts +0 -5
- package/src/components/LibraryItemsList/FiltersPanel/mustHideValue.ts +0 -19
- package/src/components/LibraryItemsList/IconViewType/IconViewType.tsx +0 -24
- package/src/components/LibraryItemsList/IconViewType/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsList.test.tsx +0 -107
- package/src/components/LibraryItemsList/LibraryItemsList.tsx +0 -55
- package/src/components/LibraryItemsList/LibraryItemsListContent/LibraryItemsListContent.tsx +0 -288
- package/src/components/LibraryItemsList/LibraryItemsListContent/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListEmpty/LibraryItemsListEmpty.tsx +0 -106
- package/src/components/LibraryItemsList/LibraryItemsListEmpty/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListPagination/LibraryItemsListPagination.test.tsx +0 -20
- package/src/components/LibraryItemsList/LibraryItemsListPagination/LibraryItemsListPagination.tsx +0 -36
- package/src/components/LibraryItemsList/LibraryItemsListPagination/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/BodyCell/BodyCell.test.tsx +0 -39
- package/src/components/LibraryItemsList/LibraryItemsListTable/BodyCell/BodyCell.tsx +0 -70
- package/src/components/LibraryItemsList/LibraryItemsListTable/BodyCell/index.ts +0 -6
- package/src/components/LibraryItemsList/LibraryItemsListTable/BodyRow/BodyRow.test.tsx +0 -48
- package/src/components/LibraryItemsList/LibraryItemsListTable/BodyRow/BodyRow.tsx +0 -93
- package/src/components/LibraryItemsList/LibraryItemsListTable/BodyRow/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/AllValuesCount.tsx +0 -88
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/AllValuesCount/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/Cell.test.tsx +0 -75
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/Cell.tsx +0 -78
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/CellInfos.test.tsx +0 -38
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/CellInfos.tsx +0 -91
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/CellInfos/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/CellSelection.test.tsx +0 -13
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/CellSelection.tsx +0 -46
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/CellSelection/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/ElementsToDisplay/RichTextDisplay.tsx +0 -33
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/StandardCell.tsx +0 -117
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/StandardCell/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Cell/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/ChooseTableColumns.css +0 -3
- package/src/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/ChooseTableColumns.test.tsx +0 -45
- package/src/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/ChooseTableColumns.tsx +0 -144
- package/src/components/LibraryItemsList/LibraryItemsListTable/ChooseTableColumns/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Header/Header.test.tsx +0 -73
- package/src/components/LibraryItemsList/LibraryItemsListTable/Header/Header.tsx +0 -197
- package/src/components/LibraryItemsList/LibraryItemsListTable/Header/index.ts +0 -5
- package/src/components/LibraryItemsList/LibraryItemsListTable/Table.test.tsx +0 -39
- package/src/components/LibraryItemsList/LibraryItemsListTable/Table.tsx +0 -328
- package/src/components/LibraryItemsList/LibraryItemsListTable/index.ts +0 -5
- package/src/components/LibraryItemsList/MenuItemList/MenuItemList.test.tsx +0 -75
- package/src/components/LibraryItemsList/MenuItemList/MenuItemList.tsx +0 -104
- package/src/components/LibraryItemsList/MenuItemList/index.ts +0 -5
- package/src/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/ActionsMenu.test.tsx +0 -29
- package/src/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/ActionsMenu.tsx +0 -107
- package/src/components/LibraryItemsList/MenuItemListSelected/ActionsMenu/index.ts +0 -5
- package/src/components/LibraryItemsList/MenuItemListSelected/MenuItemListSelected.test.tsx +0 -18
- package/src/components/LibraryItemsList/MenuItemListSelected/MenuItemListSelected.tsx +0 -182
- package/src/components/LibraryItemsList/MenuItemListSelected/index.ts +0 -5
- package/src/components/LibraryItemsList/MenuSelection/MenuSelection.test.tsx +0 -16
- package/src/components/LibraryItemsList/MenuSelection/MenuSelection.tsx +0 -74
- package/src/components/LibraryItemsList/MenuSelection/index.ts +0 -5
- package/src/components/LibraryItemsList/MenuView/MenuView.test.tsx +0 -20
- package/src/components/LibraryItemsList/MenuView/MenuView.tsx +0 -248
- package/src/components/LibraryItemsList/MenuView/index.ts +0 -5
- package/src/components/LibraryItemsList/SearchItems/SearchItems.test.tsx +0 -20
- package/src/components/LibraryItemsList/SearchItems/SearchItems.tsx +0 -37
- package/src/components/LibraryItemsList/SearchItems/index.ts +0 -5
- package/src/components/LibraryItemsList/Sidebar/Sidebar.test.tsx +0 -66
- package/src/components/LibraryItemsList/Sidebar/Sidebar.tsx +0 -71
- package/src/components/LibraryItemsList/Sidebar/index.ts +0 -5
- package/src/components/LibraryItemsList/TileDisplay/ItemTileDisplay/ItemTileDisplay.test.tsx +0 -40
- package/src/components/LibraryItemsList/TileDisplay/ItemTileDisplay/ItemTileDisplay.tsx +0 -322
- package/src/components/LibraryItemsList/TileDisplay/ItemTileDisplay/index.ts +0 -5
- package/src/components/LibraryItemsList/TileDisplay/TileDisplay.test.tsx +0 -50
- package/src/components/LibraryItemsList/TileDisplay/TileDisplay.tsx +0 -75
- package/src/components/LibraryItemsList/TileDisplay/helpers/getItemPreviewSize.ts +0 -13
- package/src/components/LibraryItemsList/TileDisplay/index.ts +0 -5
- package/src/components/LibraryItemsList/VersionsPanel/VersionsPanel.test.tsx +0 -24
- package/src/components/LibraryItemsList/VersionsPanel/VersionsPanel.tsx +0 -85
- package/src/components/LibraryItemsList/VersionsPanel/index.ts +0 -5
- package/src/components/LibraryItemsList/ViewPanel/EditView/EditView.test.tsx +0 -41
- package/src/components/LibraryItemsList/ViewPanel/EditView/EditView.tsx +0 -176
- package/src/components/LibraryItemsList/ViewPanel/EditView/index.ts +0 -5
- package/src/components/LibraryItemsList/ViewPanel/View/View.test.tsx +0 -36
- package/src/components/LibraryItemsList/ViewPanel/View/View.tsx +0 -262
- package/src/components/LibraryItemsList/ViewPanel/View/index.ts +0 -5
- package/src/components/LibraryItemsList/ViewPanel/ViewPanel.test.tsx +0 -143
- package/src/components/LibraryItemsList/ViewPanel/ViewPanel.tsx +0 -299
- package/src/components/LibraryItemsList/ViewPanel/index.ts +0 -5
- package/src/components/LibraryItemsList/constants.ts +0 -24
- package/src/components/LibraryItemsList/helpers/defaultFilterConditionByAttributeFormat.ts +0 -18
- package/src/components/LibraryItemsList/helpers/displayTypeToPreviewSize.ts +0 -15
- package/src/components/LibraryItemsList/helpers/extractAttributesFromLibrary.ts +0 -86
- package/src/components/LibraryItemsList/helpers/getFieldFromKey.ts +0 -50
- package/src/components/LibraryItemsList/helpers/getFieldsFromView.ts +0 -23
- package/src/components/LibraryItemsList/helpers/getFieldsKeyFromAttribute.ts +0 -14
- package/src/components/LibraryItemsList/helpers/getSortFieldByAttributeType.ts +0 -16
- package/src/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.test.tsx +0 -146
- package/src/components/LibraryItemsList/hooks/useLibraryView/useLibraryView.tsx +0 -118
- package/src/components/LibraryItemsList/hooks/useSearchReducer/_types.ts +0 -80
- package/src/components/LibraryItemsList/hooks/useSearchReducer/index.ts +0 -6
- package/src/components/LibraryItemsList/hooks/useSearchReducer/searchContext.ts +0 -11
- package/src/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.test.ts +0 -380
- package/src/components/LibraryItemsList/hooks/useSearchReducer/searchReducer.ts +0 -302
- package/src/components/LibraryItemsList/hooks/useSearchReducer/useSearchReducer.ts +0 -9
- package/src/components/LibraryItemsList/hooks/useUpdateViewsOrderMutation.ts +0 -54
- package/src/components/LibraryItemsList/index.ts +0 -4
- package/src/components/LibraryItemsList/manageItems.test.ts +0 -367
- package/src/components/LibraryItemsList/manageItems.ts +0 -124
- package/src/components/LibraryItemsList/shared/DeactivateRecordBtn/DeactivateRecordBtn.test.tsx +0 -49
- package/src/components/LibraryItemsList/shared/DeactivateRecordBtn/DeactivateRecordBtn.tsx +0 -53
- package/src/components/LibraryItemsList/shared/DeactivateRecordBtn/index.ts +0 -5
- package/src/components/LibraryItemsList/shared/SelectCellsBtn.tsx +0 -50
- package/src/components/LibraryPicker/LibrariesList/LibrariesList.tsx +0 -211
- package/src/components/LibraryPicker/LibrariesList/index.ts +0 -4
- package/src/components/LibraryPicker/LibraryPicker.test.tsx +0 -207
- package/src/components/LibraryPicker/LibraryPicker.tsx +0 -62
- package/src/components/LibraryPicker/index.ts +0 -4
- package/src/components/List/List.test.tsx +0 -66
- package/src/components/List/List.tsx +0 -95
- package/src/components/List/index.ts +0 -5
- package/src/components/Loading/Loading.tsx +0 -23
- package/src/components/Loading/index.ts +0 -4
- package/src/components/RecordCard/RecordCard.test.tsx +0 -40
- package/src/components/RecordCard/RecordCard.tsx +0 -64
- package/src/components/RecordCard/_types.ts +0 -19
- package/src/components/RecordCard/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/EditRecord.test.tsx +0 -137
- package/src/components/RecordEdition/EditRecord/EditRecord.tsx +0 -140
- package/src/components/RecordEdition/EditRecord/EditRecordSkeleton.tsx +0 -29
- package/src/components/RecordEdition/EditRecord/_types.ts +0 -154
- package/src/components/RecordEdition/EditRecord/helpers/extractFormElements/extractFormElements.test.tsx +0 -115
- package/src/components/RecordEdition/EditRecord/helpers/extractFormElements/extractFormElements.tsx +0 -26
- package/src/components/RecordEdition/EditRecord/helpers/extractFormElements/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/helpers/getActiveFieldValues/getActiveFieldValues.ts +0 -8
- package/src/components/RecordEdition/EditRecord/helpers/getActiveFieldValues/index.ts +0 -4
- package/src/components/RecordEdition/EditRecord/helpers/isCurrentVersion/index.ts +0 -4
- package/src/components/RecordEdition/EditRecord/helpers/isCurrentVersion/isCurrentVersion.test.ts +0 -87
- package/src/components/RecordEdition/EditRecord/helpers/isCurrentVersion/isCurrentVersion.ts +0 -27
- package/src/components/RecordEdition/EditRecord/hooks/__mocks__/useDeleteValueMutation.ts +0 -8
- package/src/components/RecordEdition/EditRecord/hooks/__mocks__/useSaveValueMutation.ts +0 -8
- package/src/components/RecordEdition/EditRecord/hooks/helpers/getPropertyCacheFieldName.ts +0 -4
- package/src/components/RecordEdition/EditRecord/hooks/useExecuteDeleteValueMutation.ts +0 -50
- package/src/components/RecordEdition/EditRecord/hooks/useExecuteSaveValueBatchMutation.ts +0 -75
- package/src/components/RecordEdition/EditRecord/hooks/useRecordEditionContext.ts +0 -9
- package/src/components/RecordEdition/EditRecord/hooks/useSaveValueBatchMutation.test.ts +0 -134
- package/src/components/RecordEdition/EditRecord/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/reducers/linkFieldReducer/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/reducers/linkFieldReducer/linkFieldReducer.test.ts +0 -173
- package/src/components/RecordEdition/EditRecord/reducers/linkFieldReducer/linkFieldReducer.ts +0 -205
- package/src/components/RecordEdition/EditRecord/reducers/standardFieldReducer/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/reducers/standardFieldReducer/standardFieldReducer.test.ts +0 -473
- package/src/components/RecordEdition/EditRecord/reducers/standardFieldReducer/standardFieldReducer.ts +0 -434
- package/src/components/RecordEdition/EditRecord/shared/AddValueBtn/AddValueBtn.test.tsx +0 -27
- package/src/components/RecordEdition/EditRecord/shared/AddValueBtn/AddValueBtn.tsx +0 -36
- package/src/components/RecordEdition/EditRecord/shared/AddValueBtn/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/DeleteAllValuesBtn/DeleteAllValuesBtn.test.tsx +0 -25
- package/src/components/RecordEdition/EditRecord/shared/DeleteAllValuesBtn/DeleteAllValuesBtn.tsx +0 -48
- package/src/components/RecordEdition/EditRecord/shared/DeleteAllValuesBtn/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/DeleteValueBtn/DeleteValueBtn.test.tsx +0 -26
- package/src/components/RecordEdition/EditRecord/shared/DeleteValueBtn/DeleteValueBtn.tsx +0 -40
- package/src/components/RecordEdition/EditRecord/shared/DeleteValueBtn/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/FieldFooter/FieldFooter.test.tsx +0 -17
- package/src/components/RecordEdition/EditRecord/shared/FieldFooter/FieldFooter.tsx +0 -42
- package/src/components/RecordEdition/EditRecord/shared/FieldFooter/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/InheritedFieldLabel/InheritedFieldLabel.test.tsx +0 -28
- package/src/components/RecordEdition/EditRecord/shared/InheritedFieldLabel/InheritedFieldLabel.tsx +0 -33
- package/src/components/RecordEdition/EditRecord/shared/InheritedFieldLabel/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/NoValue/NoValue.test.tsx +0 -29
- package/src/components/RecordEdition/EditRecord/shared/NoValue/NoValue.tsx +0 -56
- package/src/components/RecordEdition/EditRecord/shared/NoValue/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/UpdatedFieldIcon/UpdatedFieldIcon.tsx +0 -18
- package/src/components/RecordEdition/EditRecord/shared/UpdatedFieldIcon/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/ValueDetailsBtn/ValueDetailsBtn.test.tsx +0 -54
- package/src/components/RecordEdition/EditRecord/shared/ValueDetailsBtn/ValueDetailsBtn.tsx +0 -45
- package/src/components/RecordEdition/EditRecord/shared/ValueDetailsBtn/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/ValuesVersionBtn/ValuesVersionBtn.test.tsx +0 -49
- package/src/components/RecordEdition/EditRecord/shared/ValuesVersionBtn/ValuesVersionBtn.tsx +0 -104
- package/src/components/RecordEdition/EditRecord/shared/ValuesVersionBtn/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/shared/ValuesVersionIndicator/ValuesVersionIndicator.tsx +0 -42
- package/src/components/RecordEdition/EditRecord/shared/ValuesVersionIndicator/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/Container/Container.test.tsx +0 -35
- package/src/components/RecordEdition/EditRecord/uiElements/Container/Container.tsx +0 -37
- package/src/components/RecordEdition/EditRecord/uiElements/Container/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/ErrorField/ErrorField.test.tsx +0 -35
- package/src/components/RecordEdition/EditRecord/uiElements/ErrorField/ErrorField.tsx +0 -82
- package/src/components/RecordEdition/EditRecord/uiElements/ErrorField/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/FormDivider/FormDivider.test.tsx +0 -25
- package/src/components/RecordEdition/EditRecord/uiElements/FormDivider/FormDivider.tsx +0 -14
- package/src/components/RecordEdition/EditRecord/uiElements/FormDivider/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/FormTabs/FormTabs.test.tsx +0 -35
- package/src/components/RecordEdition/EditRecord/uiElements/FormTabs/FormTabs.tsx +0 -50
- package/src/components/RecordEdition/EditRecord/uiElements/FormTabs/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/FloatingMenuHandler/FloatingMenuHandler.tsx +0 -60
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/FloatingMenuHandler/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/LinkField.test.tsx +0 -593
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/LinkField.tsx +0 -494
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/RecordIdentityCell/RecordIdentityCell.tsx +0 -16
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/RecordIdentityCell/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/ValuesAdd/QuickSearch/QuickSearch.tsx +0 -83
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/ValuesAdd/QuickSearch/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/ValuesAdd/ValuesAdd.tsx +0 -419
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/ValuesAdd/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/LinkField/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardField.test.tsx +0 -627
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardField.tsx +0 -320
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.tsx +0 -26
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.tsx +0 -38
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.tsx +0 -62
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/DateRangeInput.tsx +0 -67
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.tsx +0 -34
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.tsx +0 -53
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.tsx +0 -67
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.tsx +0 -44
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/StandardFieldValue.tsx +0 -629
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/ValuesList/ValuesList.tsx +0 -79
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/ValuesList/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/StandardFieldValue/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/StandardField/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/TextBlock/TextBlock.test.tsx +0 -15
- package/src/components/RecordEdition/EditRecord/uiElements/TextBlock/TextBlock.tsx +0 -13
- package/src/components/RecordEdition/EditRecord/uiElements/TextBlock/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/TreeField.test.tsx +0 -249
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/TreeField.tsx +0 -349
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/TreeFieldValue/TreeFieldValue.tsx +0 -68
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/TreeFieldValue/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/ValuesAdd/ValuesAdd.tsx +0 -198
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/ValuesAdd/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/TreeField/index.ts +0 -5
- package/src/components/RecordEdition/EditRecord/uiElements/index.tsx +0 -27
- package/src/components/RecordEdition/EditRecordBtn/EditRecordBtn.test.tsx +0 -30
- package/src/components/RecordEdition/EditRecordBtn/EditRecordBtn.tsx +0 -52
- package/src/components/RecordEdition/EditRecordBtn/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordModal/EditRecordModal.test.tsx +0 -84
- package/src/components/RecordEdition/EditRecordModal/EditRecordModal.tsx +0 -531
- package/src/components/RecordEdition/EditRecordModal/EditRecordModalHeader/EditRecordModalHeader.tsx +0 -93
- package/src/components/RecordEdition/EditRecordModal/EditRecordModalHeader/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordModal/ValuesVersionSummary/ValuesVersionSummary.tsx +0 -57
- package/src/components/RecordEdition/EditRecordModal/ValuesVersionSummary/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordModal/creationErrorContext.ts +0 -12
- package/src/components/RecordEdition/EditRecordModal/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.test.tsx +0 -159
- package/src/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.tsx +0 -33
- package/src/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.test.tsx +0 -36
- package/src/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.tsx +0 -46
- package/src/components/RecordEdition/EditRecordSidebar/PropertiesList/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.test.tsx +0 -50
- package/src/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.tsx +0 -107
- package/src/components/RecordEdition/EditRecordSidebar/RecordSummary/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/AttributeDetails.tsx +0 -75
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/AttributeDetails/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/TreeValuePath.tsx +0 -56
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/TreeValuePath/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueDetails.tsx +0 -109
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/ValueInfo.tsx +0 -106
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueInfo/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/ValueMetadata.tsx +0 -96
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/ValueMetadata/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/ValueDetails/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/ValuesVersions/ValuesVersions.tsx +0 -91
- package/src/components/RecordEdition/EditRecordSidebar/ValuesVersions/index.ts +0 -5
- package/src/components/RecordEdition/EditRecordSidebar/index.ts +0 -5
- package/src/components/RecordEdition/editRecordModalReducer/editRecordModalReducer.test.ts +0 -174
- package/src/components/RecordEdition/editRecordModalReducer/editRecordModalReducer.ts +0 -155
- package/src/components/RecordEdition/editRecordModalReducer/editRecordModalReducerContext.ts +0 -15
- package/src/components/RecordEdition/editRecordModalReducer/index.ts +0 -5
- package/src/components/RecordEdition/editRecordModalReducer/useEditRecordModalReducer.ts +0 -7
- package/src/components/RecordEdition/index.ts +0 -4
- package/src/components/RecordPreviewWithModal/FileModal/FileModal.test.tsx +0 -357
- package/src/components/RecordPreviewWithModal/FileModal/FileModal.tsx +0 -71
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/AudioFile/AudioFile.tsx +0 -27
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/AudioFile/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/DocumentFile/DocumentFile.tsx +0 -44
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/DocumentFile/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalContent.tsx +0 -103
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalSidebar/FileModalSidebar.tsx +0 -127
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalSidebar/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/ImageFile/ImageFile.tsx +0 -52
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/ImageFile/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/NoDisplayFile/NoDisplayFile.tsx +0 -79
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/NoDisplayFile/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/VideoFile/VideoFile.tsx +0 -33
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/VideoFile/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/_types.ts +0 -11
- package/src/components/RecordPreviewWithModal/FileModal/FileModalContent/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/_constants.ts +0 -5
- package/src/components/RecordPreviewWithModal/FileModal/index.ts +0 -5
- package/src/components/RecordPreviewWithModal/RecordPreviewWithModal.test.tsx +0 -48
- package/src/components/RecordPreviewWithModal/RecordPreviewWithModal.tsx +0 -84
- package/src/components/RecordPreviewWithModal/index.ts +0 -4
- package/src/components/SearchModal/SearchModal.test.tsx +0 -38
- package/src/components/SearchModal/SearchModal.tsx +0 -85
- package/src/components/SearchModal/index.ts +0 -4
- package/src/components/SelectTreeNode/SelectTreeNode.test.tsx +0 -100
- package/src/components/SelectTreeNode/SelectTreeNode.tsx +0 -232
- package/src/components/SelectTreeNode/index.ts +0 -4
- package/src/components/SelectTreeNodeModal/SelectTreeNodeModal.test.tsx +0 -35
- package/src/components/SelectTreeNodeModal/SelectTreeNodeModal.tsx +0 -75
- package/src/components/SelectTreeNodeModal/index.ts +0 -5
- package/src/components/SimpleErrorBoundary/SimpleErrorBoundary.test.tsx +0 -24
- package/src/components/SimpleErrorBoundary/SimpleErrorBoundary.tsx +0 -39
- package/src/components/SimpleErrorBoundary/SimpleErrorBoundaryContent/SimpleErrorBoundaryContent.tsx +0 -41
- package/src/components/SimpleErrorBoundary/SimpleErrorBoundaryContent/index.ts +0 -5
- package/src/components/SimpleErrorBoundary/index.ts +0 -4
- package/src/components/SubmitStateNotifier/SubmitStateNotifier.test.tsx +0 -13
- package/src/components/SubmitStateNotifier/SubmitStateNotifier.tsx +0 -83
- package/src/components/SubmitStateNotifier/_types.ts +0 -4
- package/src/components/SubmitStateNotifier/index.ts +0 -5
- package/src/components/TreePicker/TreePicker.test.tsx +0 -208
- package/src/components/TreePicker/TreePicker.tsx +0 -60
- package/src/components/TreePicker/TreesList/TreesList.tsx +0 -208
- package/src/components/TreePicker/TreesList/index.ts +0 -4
- package/src/components/TreePicker/index.ts +0 -4
- package/src/components/TriggerPreviewsGenerationModal/TriggerPreviewsGenerationModal.test.tsx +0 -161
- package/src/components/TriggerPreviewsGenerationModal/TriggerPreviewsGenerationModal.tsx +0 -146
- package/src/components/TriggerPreviewsGenerationModal/index.ts +0 -2
- package/src/components/UploadFiles/UploadFiles.test.tsx +0 -200
- package/src/components/UploadFiles/UploadFiles.tsx +0 -406
- package/src/components/UploadFiles/index.ts +0 -4
- package/src/components/ValuesVersionConfigurator/ValuesVersionConfigurator.test.tsx +0 -106
- package/src/components/ValuesVersionConfigurator/ValuesVersionConfigurator.tsx +0 -72
- package/src/components/ValuesVersionConfigurator/VersionTree/VersionTree.tsx +0 -125
- package/src/components/ValuesVersionConfigurator/VersionTree/index.ts +0 -5
- package/src/components/ValuesVersionConfigurator/index.ts +0 -5
- package/src/components/index.ts +0 -40
- package/src/constants.ts +0 -52
- package/src/contexts/LangContext/LangContext.tsx +0 -9
- package/src/contexts/LangContext/_types.ts +0 -9
- package/src/contexts/LangContext/index.ts +0 -5
- package/src/contexts/UserContext/UserContext.ts +0 -7
- package/src/contexts/UserContext/index.ts +0 -2
- package/src/contexts/UserContext/types.ts +0 -11
- package/src/contexts/index.ts +0 -5
- package/src/gqlFragments/index.ts +0 -4
- package/src/gqlFragments/recordIdentityFragment.ts +0 -21
- package/src/gqlPossibleTypes/index.ts +0 -28
- package/src/hooks/index.ts +0 -17
- package/src/hooks/useAntdLocale/index.ts +0 -4
- package/src/hooks/useAntdLocale/useAntdLocale.ts +0 -17
- package/src/hooks/useAppLang/index.ts +0 -4
- package/src/hooks/useAppLang/useAppLang.tsx +0 -39
- package/src/hooks/useAuth/index.ts +0 -4
- package/src/hooks/useAuth/useAuth.ts +0 -23
- package/src/hooks/useCanEditRecord/index.ts +0 -1
- package/src/hooks/useCanEditRecord/useCanEditRecord.test.tsx +0 -195
- package/src/hooks/useCanEditRecord/useCanEditRecord.ts +0 -71
- package/src/hooks/useExecuteAddViewMutation/useExecuteAddViewMutation.ts +0 -54
- package/src/hooks/useExecuteDeleteViewMutation/useExecuteDeleteViewMutation.ts +0 -29
- package/src/hooks/useGetLibraryDetailExtendedQuery/useGetLibraryDetailExtendedQuery.ts +0 -30
- package/src/hooks/useGetPreparedFileData/useGetPreparedFileData.ts +0 -54
- package/src/hooks/useGetRecordForm/index.ts +0 -5
- package/src/hooks/useGetRecordForm/useGetRecordForm.test.tsx +0 -159
- package/src/hooks/useGetRecordForm/useGetRecordForm.ts +0 -153
- package/src/hooks/useGetRecordUpdatesSubscription/index.ts +0 -4
- package/src/hooks/useGetRecordUpdatesSubscription/useGetRecordUpdatesSubscription.ts +0 -21
- package/src/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.ts +0 -82
- package/src/hooks/useLang/__mocks__/index.ts +0 -5
- package/src/hooks/useLang/__mocks__/useLang.tsx +0 -13
- package/src/hooks/useLang/index.ts +0 -5
- package/src/hooks/useLang/useLang.test.tsx +0 -34
- package/src/hooks/useLang/useLang.tsx +0 -17
- package/src/hooks/useLibraryVersionTrees/index.ts +0 -4
- package/src/hooks/useLibraryVersionTrees/useLibraryVersionTrees.test.tsx +0 -95
- package/src/hooks/useLibraryVersionTrees/useLibraryVersionTrees.ts +0 -35
- package/src/hooks/useLocalStorage/index.ts +0 -4
- package/src/hooks/useLocalStorage/useLocalStorage.ts +0 -23
- package/src/hooks/useRecordsConsultationHistory/index.ts +0 -5
- package/src/hooks/useRecordsConsultationHistory/useRecordsConsultationHistory.ts +0 -38
- package/src/hooks/useRefreshFieldValues/index.ts +0 -4
- package/src/hooks/useRefreshFieldValues/useRefreshFieldValues.test.tsx +0 -75
- package/src/hooks/useRefreshFieldValues/useRefreshFieldValues.ts +0 -63
- package/src/hooks/useRefreshToken/index.ts +0 -4
- package/src/hooks/useRefreshToken/useRefreshToken.ts +0 -34
- package/src/hooks/useSharedTranslation/__mocks__/index.ts +0 -4
- package/src/hooks/useSharedTranslation/__mocks__/useSharedTranslation.ts +0 -21
- package/src/hooks/useSharedTranslation/index.ts +0 -4
- package/src/hooks/useSharedTranslation/useSharedTranslation.ts +0 -45
- package/src/hooks/useUser/index.ts +0 -1
- package/src/hooks/useUser/useUser.test.tsx +0 -28
- package/src/hooks/useUser/useUser.ts +0 -15
- package/src/hooks/useValuesCacheUpdate/index.ts +0 -4
- package/src/hooks/useValuesCacheUpdate/useValuesCacheUpdate.ts +0 -56
- package/src/index.ts +0 -12
- package/src/locales/en/shared.json +0 -576
- package/src/locales/fr/shared.json +0 -578
- package/src/testing/MockedLangContextProvider/MockedLangContextProvider.tsx +0 -17
- package/src/testing/MockedLangContextProvider/index.ts +0 -5
- package/src/testing/MockedUserContextProvider/MockedUserContextProvider.tsx +0 -27
- package/src/testing/MockedUserContextProvider/index.ts +0 -5
- package/src/testing/index.ts +0 -4
- package/src/types/attributes.ts +0 -23
- package/src/types/index.ts +0 -8
- package/src/types/misc.ts +0 -3
- package/src/types/records.ts +0 -32
- package/src/types/scalars.ts +0 -4
- package/src/types/search.ts +0 -207
- package/src/types/trees.ts +0 -20
- package/src/types/values.ts +0 -8
- package/src/types/views.ts +0 -39
- package/tsconfig.build.json +0 -21
- package/tsconfig.json +0 -20
|
@@ -1,288 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {useQuery} from '@apollo/client';
|
|
5
|
-
import {useEffect, useMemo, useReducer} from 'react';
|
|
6
|
-
import styled, {CSSObject} from 'styled-components';
|
|
7
|
-
import {ErrorDisplay, Loading} from '_ui/components';
|
|
8
|
-
import {SearchContext} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchContext';
|
|
9
|
-
import searchReducer, {
|
|
10
|
-
initialSearchState,
|
|
11
|
-
SearchActionTypes
|
|
12
|
-
} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';
|
|
13
|
-
import {ISearchRecord} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/_types';
|
|
14
|
-
import {useGetRecordUpdatesSubscription, useLang} from '_ui/hooks';
|
|
15
|
-
import {IField, IFilter, ISearchSelection, SearchMode} from '_ui/types/search';
|
|
16
|
-
import {IView} from '_ui/types/views';
|
|
17
|
-
import {useSaveUserDataMutation} from '_ui/_gqlTypes';
|
|
18
|
-
import {ILibraryDetailExtended} from '_ui/_queries/libraries/getLibraryDetailExtendQuery';
|
|
19
|
-
import {
|
|
20
|
-
getRecordsFromLibraryQuery,
|
|
21
|
-
IGetRecordsFromLibraryQuery,
|
|
22
|
-
IGetRecordsFromLibraryQueryVariables
|
|
23
|
-
} from '_ui/_queries/records/getRecordsFromLibraryQuery';
|
|
24
|
-
import {objectValueVersionToArray} from '_ui/_utils';
|
|
25
|
-
import {getRequestFromFilters} from '_ui/_utils/getRequestFromFilter';
|
|
26
|
-
import {getSelectedViewKey, viewSettingsField} from '../constants';
|
|
27
|
-
import DisplayTypeSelector from '../DisplayTypeSelector';
|
|
28
|
-
import extractAttributesFromLibrary from '../helpers/extractAttributesFromLibrary';
|
|
29
|
-
import getFieldFromKey from '../helpers/getFieldFromKey';
|
|
30
|
-
import LibraryItemsListEmpty from '../LibraryItemsListEmpty';
|
|
31
|
-
import {manageItems} from '../manageItems';
|
|
32
|
-
import MenuItemList from '../MenuItemList';
|
|
33
|
-
import MenuItemListSelected from '../MenuItemListSelected';
|
|
34
|
-
import Sidebar from '../Sidebar';
|
|
35
|
-
|
|
36
|
-
const MenuWrapper = styled.div`
|
|
37
|
-
border-bottom: 1px solid rgb(235, 237, 240);
|
|
38
|
-
padding: 0 1rem;
|
|
39
|
-
height: 4rem;
|
|
40
|
-
|
|
41
|
-
display: flex;
|
|
42
|
-
align-content: center;
|
|
43
|
-
justify-content: space-around;
|
|
44
|
-
`;
|
|
45
|
-
|
|
46
|
-
interface IWrapperProps {
|
|
47
|
-
$showSide: boolean;
|
|
48
|
-
style?: CSSObject;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
const panelSize = '22.5rem';
|
|
52
|
-
const Wrapper = styled.div<IWrapperProps>`
|
|
53
|
-
display: grid;
|
|
54
|
-
|
|
55
|
-
${({$showSide}) =>
|
|
56
|
-
$showSide
|
|
57
|
-
? `
|
|
58
|
-
grid-template-columns: ${panelSize} calc(100% - ${panelSize});
|
|
59
|
-
grid-template-rows: 92% auto;
|
|
60
|
-
grid-template-areas:
|
|
61
|
-
'side data'
|
|
62
|
-
'side pagination';`
|
|
63
|
-
: `
|
|
64
|
-
grid-template-columns: auto;
|
|
65
|
-
grid-template-rows: 92% auto;
|
|
66
|
-
grid-template-areas:
|
|
67
|
-
'data'
|
|
68
|
-
'pagination';`}
|
|
69
|
-
|
|
70
|
-
height: calc(100vh - 7rem);
|
|
71
|
-
position: relative;
|
|
72
|
-
overflow: auto;
|
|
73
|
-
`;
|
|
74
|
-
|
|
75
|
-
interface ILibraryItemsListContentProps {
|
|
76
|
-
selectionMode?: boolean;
|
|
77
|
-
library: ILibraryDetailExtended;
|
|
78
|
-
defaultView: IView;
|
|
79
|
-
style?: CSSObject;
|
|
80
|
-
showTransparency?: boolean;
|
|
81
|
-
mode?: SearchMode;
|
|
82
|
-
onSelectChange?: (selection: ISearchSelection, filters?: IFilter[]) => void;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
function LibraryItemsListContent({
|
|
86
|
-
selectionMode,
|
|
87
|
-
library,
|
|
88
|
-
defaultView,
|
|
89
|
-
showTransparency,
|
|
90
|
-
onSelectChange,
|
|
91
|
-
style
|
|
92
|
-
}: ILibraryItemsListContentProps): JSX.Element {
|
|
93
|
-
const {lang} = useLang();
|
|
94
|
-
const defaultAttributes = extractAttributesFromLibrary(library);
|
|
95
|
-
|
|
96
|
-
const _getFieldsFromView = (view: IView): IField[] =>
|
|
97
|
-
!!view.settings?.find(s => s.name === viewSettingsField)
|
|
98
|
-
? view.settings
|
|
99
|
-
.find(s => s.name === viewSettingsField)
|
|
100
|
-
.value.reduce((acc, fieldKey) => {
|
|
101
|
-
const field = getFieldFromKey(fieldKey, library, defaultAttributes, lang);
|
|
102
|
-
return field ? [...acc, field] : acc;
|
|
103
|
-
}, [])
|
|
104
|
-
: [];
|
|
105
|
-
|
|
106
|
-
const [searchState, searchDispatch] = useReducer(searchReducer, {
|
|
107
|
-
...initialSearchState,
|
|
108
|
-
library,
|
|
109
|
-
loading: true,
|
|
110
|
-
attributes: defaultAttributes,
|
|
111
|
-
trees: library.linkedTrees,
|
|
112
|
-
fields: _getFieldsFromView(defaultView),
|
|
113
|
-
filters: defaultView.filters,
|
|
114
|
-
sort: defaultView.sort,
|
|
115
|
-
display: defaultView.display,
|
|
116
|
-
view: {
|
|
117
|
-
current: defaultView,
|
|
118
|
-
reload: false,
|
|
119
|
-
sync: true
|
|
120
|
-
},
|
|
121
|
-
lang,
|
|
122
|
-
valuesVersions: defaultView.valuesVersions,
|
|
123
|
-
showTransparency,
|
|
124
|
-
mode: selectionMode ? SearchMode.select : SearchMode.search
|
|
125
|
-
});
|
|
126
|
-
|
|
127
|
-
useGetRecordUpdatesSubscription({libraries: [library.id]});
|
|
128
|
-
|
|
129
|
-
const [updateSelectedViewMutation] = useSaveUserDataMutation();
|
|
130
|
-
const selectedViewKey = getSelectedViewKey(library.id);
|
|
131
|
-
|
|
132
|
-
const _applyResults = (data: IGetRecordsFromLibraryQuery) => {
|
|
133
|
-
const itemsFromQuery = data ? data.records.list : [];
|
|
134
|
-
|
|
135
|
-
const newRecords: ISearchRecord[] = manageItems({
|
|
136
|
-
items: itemsFromQuery,
|
|
137
|
-
fields: searchState.fields
|
|
138
|
-
});
|
|
139
|
-
|
|
140
|
-
searchDispatch({
|
|
141
|
-
type: SearchActionTypes.UPDATE_RESULT,
|
|
142
|
-
records: newRecords,
|
|
143
|
-
totalCount: data?.records.totalCount ?? searchState.totalCount
|
|
144
|
-
});
|
|
145
|
-
};
|
|
146
|
-
|
|
147
|
-
const _getVersionForRequest = () =>
|
|
148
|
-
searchState.valuesVersions
|
|
149
|
-
? objectValueVersionToArray(searchState.valuesVersions).filter(v => !!v.treeNodeId)
|
|
150
|
-
: [];
|
|
151
|
-
|
|
152
|
-
// We're using a useMemo here to prevent query being fired on every change of searchState.
|
|
153
|
-
// Subsequent search will be triggered on user request and are handled elsewhere.
|
|
154
|
-
// We were previously using the skip property of useQuery but it was causing issues with data update
|
|
155
|
-
const variables = useMemo(
|
|
156
|
-
() => ({
|
|
157
|
-
library: library.id,
|
|
158
|
-
limit: searchState.pagination,
|
|
159
|
-
offset: searchState.offset,
|
|
160
|
-
filters: getRequestFromFilters(searchState.filters),
|
|
161
|
-
sort: searchState.sort,
|
|
162
|
-
fullText: searchState.fullText,
|
|
163
|
-
version: _getVersionForRequest()
|
|
164
|
-
}),
|
|
165
|
-
[]
|
|
166
|
-
);
|
|
167
|
-
|
|
168
|
-
const {loading: getRecordsLoading, data: searchData, fetchMore: getRecordsFetchMore} = useQuery<
|
|
169
|
-
IGetRecordsFromLibraryQuery,
|
|
170
|
-
IGetRecordsFromLibraryQueryVariables
|
|
171
|
-
>(getRecordsFromLibraryQuery(searchState.fields, !searchState.offset), {
|
|
172
|
-
fetchPolicy: 'network-only',
|
|
173
|
-
variables,
|
|
174
|
-
onError: err => {
|
|
175
|
-
searchDispatch({
|
|
176
|
-
type: SearchActionTypes.UPDATE_RESULT,
|
|
177
|
-
error: err
|
|
178
|
-
});
|
|
179
|
-
}
|
|
180
|
-
});
|
|
181
|
-
|
|
182
|
-
const _fetchRecords = async () => {
|
|
183
|
-
try {
|
|
184
|
-
const queryFilters = getRequestFromFilters(searchState.filters);
|
|
185
|
-
|
|
186
|
-
const currentVariables = {
|
|
187
|
-
library: library.id,
|
|
188
|
-
limit: searchState.pagination,
|
|
189
|
-
offset: searchState.offset,
|
|
190
|
-
filters: queryFilters,
|
|
191
|
-
sort: searchState.sort,
|
|
192
|
-
fullText: searchState.fullText,
|
|
193
|
-
version: _getVersionForRequest()
|
|
194
|
-
};
|
|
195
|
-
|
|
196
|
-
// Records have already been fetched, we use fetchMore to make sure
|
|
197
|
-
// we request the right fields by passing in a whole new query
|
|
198
|
-
const results = await getRecordsFetchMore({
|
|
199
|
-
query: getRecordsFromLibraryQuery(searchState.fields, !searchState.offset),
|
|
200
|
-
variables: currentVariables
|
|
201
|
-
});
|
|
202
|
-
|
|
203
|
-
const recordsData = results.data;
|
|
204
|
-
|
|
205
|
-
// We have to call applyResults here because onCompleted is not called when fetchMore is used
|
|
206
|
-
_applyResults(recordsData);
|
|
207
|
-
} catch (err) {
|
|
208
|
-
searchDispatch({type: SearchActionTypes.SET_LOADING, loading: false});
|
|
209
|
-
// Error is already handled. This try/catch is just to avoid unhandled rejection
|
|
210
|
-
}
|
|
211
|
-
};
|
|
212
|
-
|
|
213
|
-
const isLoading = getRecordsLoading || searchState.view.reload || searchState.loading;
|
|
214
|
-
|
|
215
|
-
useEffect(() => {
|
|
216
|
-
if (searchData) {
|
|
217
|
-
_applyResults(searchData);
|
|
218
|
-
}
|
|
219
|
-
}, [searchData]);
|
|
220
|
-
|
|
221
|
-
useEffect(() => {
|
|
222
|
-
if (searchState.loading) {
|
|
223
|
-
_fetchRecords();
|
|
224
|
-
}
|
|
225
|
-
}, [searchState.loading]);
|
|
226
|
-
|
|
227
|
-
/**
|
|
228
|
-
* Called when current view changes. In charge of refetching record and saving last used view
|
|
229
|
-
*/
|
|
230
|
-
useEffect(() => {
|
|
231
|
-
if (!searchState.view.reload) {
|
|
232
|
-
return;
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
_fetchRecords();
|
|
236
|
-
|
|
237
|
-
updateSelectedViewMutation({
|
|
238
|
-
variables: {
|
|
239
|
-
key: selectedViewKey,
|
|
240
|
-
value: searchState.view.current.id,
|
|
241
|
-
global: false
|
|
242
|
-
}
|
|
243
|
-
});
|
|
244
|
-
searchDispatch({type: SearchActionTypes.SET_VIEW_RELOAD, reload: false});
|
|
245
|
-
}, [selectedViewKey, updateSelectedViewMutation, searchState.view, searchState.fields, searchDispatch, library]);
|
|
246
|
-
|
|
247
|
-
/**
|
|
248
|
-
* Calls onSelectChange when selection changes
|
|
249
|
-
*/
|
|
250
|
-
useEffect(() => {
|
|
251
|
-
if (!onSelectChange) {
|
|
252
|
-
return;
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
onSelectChange(searchState.selection, searchState.selection.allSelected ? searchState.filters : null);
|
|
256
|
-
}, [searchState.selection]);
|
|
257
|
-
|
|
258
|
-
const _reload = () => {
|
|
259
|
-
searchDispatch({type: SearchActionTypes.SET_LOADING, loading: true});
|
|
260
|
-
};
|
|
261
|
-
|
|
262
|
-
// If some elements are selected and the selection type is search, show the selection Menu
|
|
263
|
-
const menuSelectedActive = !!searchState.selection.selected.length || searchState.selection.allSelected;
|
|
264
|
-
|
|
265
|
-
return (
|
|
266
|
-
<SearchContext.Provider value={{state: searchState, dispatch: searchDispatch}}>
|
|
267
|
-
<MenuWrapper>
|
|
268
|
-
<MenuItemList refetch={_reload} library={library} />
|
|
269
|
-
<MenuItemListSelected active={menuSelectedActive} />
|
|
270
|
-
</MenuWrapper>
|
|
271
|
-
|
|
272
|
-
<Wrapper
|
|
273
|
-
$showSide={searchState.sideBar.visible}
|
|
274
|
-
className={searchState.sideBar.visible ? 'wrapper-open' : 'wrapper-close'}
|
|
275
|
-
style={style}
|
|
276
|
-
>
|
|
277
|
-
<Sidebar />
|
|
278
|
-
{isLoading && <Loading />}
|
|
279
|
-
{!isLoading && searchState.error && <ErrorDisplay message={searchState.error.message} />}
|
|
280
|
-
{!isLoading &&
|
|
281
|
-
!searchState.error &&
|
|
282
|
-
(!searchState.records.length ? <LibraryItemsListEmpty /> : <DisplayTypeSelector />)}
|
|
283
|
-
</Wrapper>
|
|
284
|
-
</SearchContext.Provider>
|
|
285
|
-
);
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
export default LibraryItemsListContent;
|
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {CloudUploadOutlined,PlusOutlined} from '@ant-design/icons';
|
|
5
|
-
import {Button,Col,Empty,Row} from 'antd';
|
|
6
|
-
import {useState} from 'react';
|
|
7
|
-
import {ImportModal} from '_ui/components/ImportModal';
|
|
8
|
-
import useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';
|
|
9
|
-
import EditRecordModal from '_ui/components/RecordEdition/EditRecordModal';
|
|
10
|
-
import {useSharedTranslation} from '_ui/hooks/useSharedTranslation';
|
|
11
|
-
|
|
12
|
-
const LibraryItemsListEmpty = () => {
|
|
13
|
-
const {t} = useSharedTranslation();
|
|
14
|
-
const {state: searchState} = useSearchReducer();
|
|
15
|
-
|
|
16
|
-
const [isRecordCreationVisible, setIsRecordCreationVisible] = useState<boolean>(false);
|
|
17
|
-
const [isImportModalVisible, setIsImportModalVisible] = useState<boolean>(false);
|
|
18
|
-
|
|
19
|
-
const _handleCreateRecord = () => {
|
|
20
|
-
setIsRecordCreationVisible(true);
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
const _handleRecordCreationClose = () => {
|
|
24
|
-
setIsRecordCreationVisible(false);
|
|
25
|
-
};
|
|
26
|
-
|
|
27
|
-
const _handleImportModalOpen = () => {
|
|
28
|
-
setIsImportModalVisible(true);
|
|
29
|
-
};
|
|
30
|
-
|
|
31
|
-
const _handleImportModalClose = () => {
|
|
32
|
-
setIsImportModalVisible(false);
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
return (
|
|
36
|
-
<>
|
|
37
|
-
<Empty
|
|
38
|
-
image={Empty.PRESENTED_IMAGE_SIMPLE}
|
|
39
|
-
imageStyle={{
|
|
40
|
-
height: 60
|
|
41
|
-
}}
|
|
42
|
-
description={<span>{t('items_list.no_data')}.</span>}
|
|
43
|
-
>
|
|
44
|
-
<Row>
|
|
45
|
-
<Col span={11}>
|
|
46
|
-
<Row justify="end">
|
|
47
|
-
<Col>
|
|
48
|
-
<Button
|
|
49
|
-
type="primary"
|
|
50
|
-
block
|
|
51
|
-
style={{
|
|
52
|
-
width: 'fit-content'
|
|
53
|
-
}}
|
|
54
|
-
icon={<PlusOutlined />}
|
|
55
|
-
className="primary-btn"
|
|
56
|
-
onClick={_handleCreateRecord}
|
|
57
|
-
>
|
|
58
|
-
{t('items_list.new_record')}
|
|
59
|
-
</Button>
|
|
60
|
-
</Col>
|
|
61
|
-
</Row>
|
|
62
|
-
</Col>
|
|
63
|
-
<Col span={2}>
|
|
64
|
-
<span>{t('global.or')}</span>
|
|
65
|
-
</Col>
|
|
66
|
-
<Col span={11}>
|
|
67
|
-
<Row justify="start">
|
|
68
|
-
<Col>
|
|
69
|
-
<Button
|
|
70
|
-
type="primary"
|
|
71
|
-
style={{
|
|
72
|
-
width: 'fit-content'
|
|
73
|
-
}}
|
|
74
|
-
block
|
|
75
|
-
icon={<CloudUploadOutlined />}
|
|
76
|
-
className="primary-btn"
|
|
77
|
-
onClick={_handleImportModalOpen}
|
|
78
|
-
>
|
|
79
|
-
{t('items_list.import_data')}
|
|
80
|
-
</Button>
|
|
81
|
-
</Col>
|
|
82
|
-
</Row>
|
|
83
|
-
</Col>
|
|
84
|
-
</Row>
|
|
85
|
-
</Empty>
|
|
86
|
-
{isRecordCreationVisible && (
|
|
87
|
-
<EditRecordModal
|
|
88
|
-
record={null}
|
|
89
|
-
library={searchState.library.id}
|
|
90
|
-
open={isRecordCreationVisible}
|
|
91
|
-
onClose={_handleRecordCreationClose}
|
|
92
|
-
valuesVersion={searchState.valuesVersions}
|
|
93
|
-
/>
|
|
94
|
-
)}
|
|
95
|
-
{isImportModalVisible && (
|
|
96
|
-
<ImportModal
|
|
97
|
-
open={isImportModalVisible}
|
|
98
|
-
library={searchState.library.id}
|
|
99
|
-
onClose={_handleImportModalClose}
|
|
100
|
-
/>
|
|
101
|
-
)}
|
|
102
|
-
</>
|
|
103
|
-
);
|
|
104
|
-
};
|
|
105
|
-
|
|
106
|
-
export default LibraryItemsListEmpty;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {ISearchState} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/_types';
|
|
5
|
-
import {render, screen} from '_ui/_tests/testUtils';
|
|
6
|
-
import MockSearchContextProvider from '_ui/__mocks__/common/mockSearchContextProvider';
|
|
7
|
-
import LibraryItemsListPagination from './LibraryItemsListPagination';
|
|
8
|
-
|
|
9
|
-
describe('LibraryItemsListPagination', () => {
|
|
10
|
-
test('should have pagination', async () => {
|
|
11
|
-
const mockState: Partial<ISearchState> = {pagination: 5, offset: 0, totalCount: 15};
|
|
12
|
-
render(
|
|
13
|
-
<MockSearchContextProvider state={mockState}>
|
|
14
|
-
<LibraryItemsListPagination />
|
|
15
|
-
</MockSearchContextProvider>
|
|
16
|
-
);
|
|
17
|
-
|
|
18
|
-
expect(screen.getAllByRole('listitem')).toHaveLength(6); // 3 page, 1 previous, 1 next and 1 size selector
|
|
19
|
-
});
|
|
20
|
-
});
|
package/src/components/LibraryItemsList/LibraryItemsListPagination/LibraryItemsListPagination.tsx
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {Pagination} from 'antd';
|
|
5
|
-
import useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';
|
|
6
|
-
import {SearchActionTypes} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';
|
|
7
|
-
|
|
8
|
-
function LibraryItemsListPagination(): JSX.Element {
|
|
9
|
-
const {state: searchState, dispatch: searchDispatch} = useSearchReducer();
|
|
10
|
-
|
|
11
|
-
const setPagination = (current: number, size: number) => {
|
|
12
|
-
searchDispatch({type: SearchActionTypes.SET_PAGINATION, page: size});
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
const setOffset = (page: number, pageSize: number) => {
|
|
16
|
-
searchDispatch({type: SearchActionTypes.SET_OFFSET, offset: (page - 1) * (pageSize ?? 0)});
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
const currentPage = searchState.offset / searchState.pagination + 1;
|
|
20
|
-
const paginationOptions = [5, 10, 20, 50, 100];
|
|
21
|
-
|
|
22
|
-
return (
|
|
23
|
-
<Pagination
|
|
24
|
-
defaultCurrent={currentPage}
|
|
25
|
-
current={currentPage}
|
|
26
|
-
total={searchState.totalCount}
|
|
27
|
-
defaultPageSize={searchState.pagination}
|
|
28
|
-
onShowSizeChange={setPagination}
|
|
29
|
-
showSizeChanger
|
|
30
|
-
pageSizeOptions={paginationOptions.map(option => option.toString())}
|
|
31
|
-
onChange={setOffset}
|
|
32
|
-
/>
|
|
33
|
-
);
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
export default LibraryItemsListPagination;
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {AttributeType} from '_ui/_gqlTypes';
|
|
5
|
-
import {act, render, screen} from '_ui/_tests/testUtils';
|
|
6
|
-
import {mockRecord} from '_ui/__mocks__/common/record';
|
|
7
|
-
import BodyCell from './BodyCell';
|
|
8
|
-
|
|
9
|
-
jest.mock(
|
|
10
|
-
'../Cell',
|
|
11
|
-
() =>
|
|
12
|
-
function Cell() {
|
|
13
|
-
return <div>Cell</div>;
|
|
14
|
-
}
|
|
15
|
-
);
|
|
16
|
-
|
|
17
|
-
describe('BodyCell', () => {
|
|
18
|
-
const mockCell = {
|
|
19
|
-
getCellProps: jest.fn(),
|
|
20
|
-
column: {
|
|
21
|
-
id: 'columnId'
|
|
22
|
-
},
|
|
23
|
-
value: {value: 'valueCell', type: AttributeType.simple, id: 'idCell'},
|
|
24
|
-
row: {
|
|
25
|
-
original: {
|
|
26
|
-
record: mockRecord
|
|
27
|
-
}
|
|
28
|
-
},
|
|
29
|
-
render: jest.fn()
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
test('should call cell', async () => {
|
|
33
|
-
await act(async () => {
|
|
34
|
-
render(<BodyCell cell={mockCell as any} selected={false} />);
|
|
35
|
-
});
|
|
36
|
-
|
|
37
|
-
expect(screen.getByText('Cell')).toBeInTheDocument();
|
|
38
|
-
});
|
|
39
|
-
});
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {Cell as ReactTableTypeCell} from 'react-table';
|
|
5
|
-
import styled from 'styled-components';
|
|
6
|
-
import {themeVars} from '_ui/antdTheme';
|
|
7
|
-
import {ITableRow} from '_ui/types/search';
|
|
8
|
-
import {infosCol, INFOS_COLUMN_WIDTH, selectionColumn} from '../../constants';
|
|
9
|
-
import Cell from '../Cell';
|
|
10
|
-
import CellSelection from '../Cell/CellSelection';
|
|
11
|
-
|
|
12
|
-
const CustomBodyCell = styled.div<{id?: string | number; selected: boolean}>`
|
|
13
|
-
// Inherit background from row. If background is transparent, the sticky column won't behave properly
|
|
14
|
-
background-color: inherit;
|
|
15
|
-
padding: 4px 0;
|
|
16
|
-
|
|
17
|
-
&:not(:first-child) {
|
|
18
|
-
border-left: 1px solid ${props => (props.selected ? themeVars.activeColor : themeVars.borderLightColor)};
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
max-width: ${p => (p.id === selectionColumn ? '35px' : 'auto')};
|
|
22
|
-
|
|
23
|
-
display: flex;
|
|
24
|
-
align-items: center;
|
|
25
|
-
`;
|
|
26
|
-
|
|
27
|
-
interface IBodyCellProps {
|
|
28
|
-
cell: ReactTableTypeCell<ITableRow>;
|
|
29
|
-
selected: boolean;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
function BodyCell({cell, selected}: IBodyCellProps): JSX.Element {
|
|
33
|
-
const props = cell.getCellProps();
|
|
34
|
-
if (cell.column.id === infosCol) {
|
|
35
|
-
// define info column row style
|
|
36
|
-
props.style = {
|
|
37
|
-
...props.style,
|
|
38
|
-
flex: '1 0 auto',
|
|
39
|
-
maxWidth: INFOS_COLUMN_WIDTH,
|
|
40
|
-
minWidth: INFOS_COLUMN_WIDTH,
|
|
41
|
-
zIndex: 3
|
|
42
|
-
};
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
const data = {
|
|
46
|
-
id: cell?.value?.id,
|
|
47
|
-
key: cell?.value?.id,
|
|
48
|
-
library: cell?.value?.library,
|
|
49
|
-
label: cell?.value?.label,
|
|
50
|
-
value: cell?.value?.value,
|
|
51
|
-
type: cell?.value?.type,
|
|
52
|
-
format: cell?.value?.format
|
|
53
|
-
};
|
|
54
|
-
|
|
55
|
-
if (!cell.value) {
|
|
56
|
-
return <CustomBodyCell selected={selected} {...props} />;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
return (
|
|
60
|
-
<CustomBodyCell {...props} id={cell.column.id} selected={selected} className="body-cell">
|
|
61
|
-
{cell.column.id === selectionColumn ? (
|
|
62
|
-
<CellSelection selected={selected} />
|
|
63
|
-
) : (
|
|
64
|
-
<Cell columnName={cell.column.id} data={data} />
|
|
65
|
-
)}
|
|
66
|
-
</CustomBodyCell>
|
|
67
|
-
);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
export default BodyCell;
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
|
-
import {render, screen} from '_ui/_tests/testUtils';
|
|
5
|
-
import {mockRecord} from '_ui/__mocks__/common/record';
|
|
6
|
-
import BodyRow from './BodyRow';
|
|
7
|
-
|
|
8
|
-
jest.mock(
|
|
9
|
-
'../BodyCell',
|
|
10
|
-
() =>
|
|
11
|
-
function BodyCell() {
|
|
12
|
-
return <div>BodyCell</div>;
|
|
13
|
-
}
|
|
14
|
-
);
|
|
15
|
-
|
|
16
|
-
jest.mock(
|
|
17
|
-
'../BodyCell',
|
|
18
|
-
() =>
|
|
19
|
-
function BodyCell() {
|
|
20
|
-
return <div>BodyCell</div>;
|
|
21
|
-
}
|
|
22
|
-
);
|
|
23
|
-
|
|
24
|
-
describe('BodyRow', () => {
|
|
25
|
-
const mockRow = {
|
|
26
|
-
cells: [
|
|
27
|
-
{
|
|
28
|
-
getCellProps: () => ({
|
|
29
|
-
key: 1
|
|
30
|
-
}),
|
|
31
|
-
column: {
|
|
32
|
-
id: 'test'
|
|
33
|
-
},
|
|
34
|
-
row: {
|
|
35
|
-
original: {
|
|
36
|
-
record: mockRecord
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
],
|
|
41
|
-
getRowProps: jest.fn()
|
|
42
|
-
};
|
|
43
|
-
test('should display n cells', async () => {
|
|
44
|
-
render(<BodyRow row={mockRow as any} />);
|
|
45
|
-
|
|
46
|
-
expect(screen.getByText('BodyCell')).toBeInTheDocument();
|
|
47
|
-
});
|
|
48
|
-
});
|