@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,121 +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 {AppstoreFilled, DownOutlined, MenuOutlined} from '@ant-design/icons';
|
|
5
|
-
import {Button, Dropdown} from 'antd';
|
|
6
|
-
import {useState} from 'react';
|
|
7
|
-
import styled from 'styled-components';
|
|
8
|
-
import useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';
|
|
9
|
-
import {SearchActionTypes} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';
|
|
10
|
-
import {useSharedTranslation} from '_ui/hooks/useSharedTranslation';
|
|
11
|
-
import {ViewSizes, ViewTypes} from '_ui/_gqlTypes';
|
|
12
|
-
import IconViewType from '../IconViewType';
|
|
13
|
-
|
|
14
|
-
const DisplaySizeWrapper = styled.div`
|
|
15
|
-
display: flex;
|
|
16
|
-
justify-content: space-between;
|
|
17
|
-
|
|
18
|
-
&&& {
|
|
19
|
-
background: none;
|
|
20
|
-
}
|
|
21
|
-
`;
|
|
22
|
-
|
|
23
|
-
function DisplayOptions(): JSX.Element {
|
|
24
|
-
const {t} = useSharedTranslation();
|
|
25
|
-
|
|
26
|
-
const {state: searchState, dispatch: searchDispatch} = useSearchReducer();
|
|
27
|
-
const [visible, setVisible] = useState<boolean>(false);
|
|
28
|
-
const sizes = {
|
|
29
|
-
[ViewSizes.SMALL]: t('items_list.display.small'),
|
|
30
|
-
[ViewSizes.MEDIUM]: t('items_list.display.medium'),
|
|
31
|
-
[ViewSizes.BIG]: t('items_list.display.big')
|
|
32
|
-
};
|
|
33
|
-
|
|
34
|
-
enum SizeAction {
|
|
35
|
-
LESS = 'LESS',
|
|
36
|
-
MORE = 'MORE'
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
const _handleChangeType = (type: ViewTypes) => {
|
|
40
|
-
searchDispatch({
|
|
41
|
-
type: SearchActionTypes.SET_DISPLAY,
|
|
42
|
-
display: {type, size: searchState.display.size}
|
|
43
|
-
});
|
|
44
|
-
};
|
|
45
|
-
|
|
46
|
-
const _handleChangeSize = (action: SizeAction) => {
|
|
47
|
-
let idx = Object.keys(sizes).indexOf(searchState.display.size);
|
|
48
|
-
idx = action === SizeAction.LESS ? idx - 1 : idx + 1;
|
|
49
|
-
idx = idx < 0 ? 0 : idx > 2 ? 2 : idx;
|
|
50
|
-
|
|
51
|
-
searchDispatch({
|
|
52
|
-
type: SearchActionTypes.SET_DISPLAY,
|
|
53
|
-
display: {type: searchState.display.type, size: ViewSizes[Object.keys(sizes)[idx]]}
|
|
54
|
-
});
|
|
55
|
-
};
|
|
56
|
-
|
|
57
|
-
const _handleOpenChange = () => setVisible(!visible);
|
|
58
|
-
|
|
59
|
-
const menu = {
|
|
60
|
-
style: {minWidth: '11em'},
|
|
61
|
-
items: [
|
|
62
|
-
{
|
|
63
|
-
key: 'display_size',
|
|
64
|
-
label: (
|
|
65
|
-
<DisplaySizeWrapper>
|
|
66
|
-
<Button
|
|
67
|
-
shape="circle"
|
|
68
|
-
disabled={searchState.display.size === ViewSizes.SMALL}
|
|
69
|
-
onClick={() => _handleChangeSize(SizeAction.LESS)}
|
|
70
|
-
size="small"
|
|
71
|
-
>
|
|
72
|
-
-
|
|
73
|
-
</Button>
|
|
74
|
-
{` ${sizes[searchState.display.size]} `}
|
|
75
|
-
<Button
|
|
76
|
-
shape="circle"
|
|
77
|
-
disabled={searchState.display.size === ViewSizes.BIG}
|
|
78
|
-
onClick={() => _handleChangeSize(SizeAction.MORE)}
|
|
79
|
-
size="small"
|
|
80
|
-
>
|
|
81
|
-
+
|
|
82
|
-
</Button>
|
|
83
|
-
</DisplaySizeWrapper>
|
|
84
|
-
)
|
|
85
|
-
},
|
|
86
|
-
{
|
|
87
|
-
type: 'divider',
|
|
88
|
-
key: 'divider'
|
|
89
|
-
},
|
|
90
|
-
{
|
|
91
|
-
key: 'display_list',
|
|
92
|
-
label: t('view.type-list'),
|
|
93
|
-
onClick: () => _handleChangeType(ViewTypes.list),
|
|
94
|
-
icon: <MenuOutlined />
|
|
95
|
-
},
|
|
96
|
-
{
|
|
97
|
-
key: 'display_cards',
|
|
98
|
-
label: t('view.type-cards'),
|
|
99
|
-
onClick: () => _handleChangeType(ViewTypes.cards),
|
|
100
|
-
icon: <AppstoreFilled />
|
|
101
|
-
}
|
|
102
|
-
]
|
|
103
|
-
};
|
|
104
|
-
|
|
105
|
-
return (
|
|
106
|
-
<Dropdown
|
|
107
|
-
open={visible}
|
|
108
|
-
onOpenChange={_handleOpenChange}
|
|
109
|
-
trigger={['click']}
|
|
110
|
-
placement="bottomRight"
|
|
111
|
-
menu={menu}
|
|
112
|
-
>
|
|
113
|
-
<Button>
|
|
114
|
-
<IconViewType type={searchState.display.type} />
|
|
115
|
-
<DownOutlined />
|
|
116
|
-
</Button>
|
|
117
|
-
</Dropdown>
|
|
118
|
-
);
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
export default DisplayOptions;
|
|
@@ -1,29 +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 DisplayTypeSelector from './DisplayTypeSelector';
|
|
6
|
-
|
|
7
|
-
jest.mock(
|
|
8
|
-
'../TileDisplay',
|
|
9
|
-
() =>
|
|
10
|
-
function ItemsTitleDisplay() {
|
|
11
|
-
return <div>ItemsTitleDisplay</div>;
|
|
12
|
-
}
|
|
13
|
-
);
|
|
14
|
-
|
|
15
|
-
jest.mock(
|
|
16
|
-
'../LibraryItemsListTable',
|
|
17
|
-
() =>
|
|
18
|
-
function LibraryItemsListTable() {
|
|
19
|
-
return <div>LibraryItemsListTable</div>;
|
|
20
|
-
}
|
|
21
|
-
);
|
|
22
|
-
|
|
23
|
-
describe('DisplayTypeSelector', () => {
|
|
24
|
-
test('Should call LibraryItemsListTable', async () => {
|
|
25
|
-
render(<DisplayTypeSelector />);
|
|
26
|
-
|
|
27
|
-
expect(screen.getByText('LibraryItemsListTable')).toBeInTheDocument();
|
|
28
|
-
});
|
|
29
|
-
});
|
|
@@ -1,23 +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 useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';
|
|
5
|
-
import {ViewTypes} from '_ui/_gqlTypes';
|
|
6
|
-
import Table from '../LibraryItemsListTable';
|
|
7
|
-
import TileDisplay from '../TileDisplay';
|
|
8
|
-
|
|
9
|
-
function DisplayTypeSelector(): JSX.Element {
|
|
10
|
-
const {state: searchState} = useSearchReducer();
|
|
11
|
-
|
|
12
|
-
switch (searchState.display.type) {
|
|
13
|
-
case ViewTypes.list:
|
|
14
|
-
return <Table />;
|
|
15
|
-
case ViewTypes.timeline:
|
|
16
|
-
return <div>Not supported yet</div>;
|
|
17
|
-
case ViewTypes.cards:
|
|
18
|
-
default:
|
|
19
|
-
return <TileDisplay />;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export default DisplayTypeSelector;
|
|
@@ -1,341 +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 {BranchesOutlined, NumberOutlined} from '@ant-design/icons';
|
|
5
|
-
import {isTypeLink, localizedTranslation} from '@leav/utils';
|
|
6
|
-
import {Badge, Dropdown, Input, Menu} from 'antd';
|
|
7
|
-
import {ItemType} from 'antd/lib/menu/hooks/useItems';
|
|
8
|
-
import React, {useState} from 'react';
|
|
9
|
-
import styled from 'styled-components';
|
|
10
|
-
import useSearchReducer from '_ui/components/LibraryItemsList/hooks/useSearchReducer';
|
|
11
|
-
import {SearchActionTypes} from '_ui/components/LibraryItemsList/hooks/useSearchReducer/searchReducer';
|
|
12
|
-
import {useLang} from '_ui/hooks';
|
|
13
|
-
import {useSharedTranslation} from '_ui/hooks/useSharedTranslation';
|
|
14
|
-
import {SystemTranslation} from '_ui/types/scalars';
|
|
15
|
-
import {
|
|
16
|
-
AttributeConditionFilter,
|
|
17
|
-
FilterType,
|
|
18
|
-
IFilter,
|
|
19
|
-
IFilterAttribute,
|
|
20
|
-
IFilterLibrary,
|
|
21
|
-
IFilterTree,
|
|
22
|
-
SidebarContentType,
|
|
23
|
-
ThroughConditionFilter,
|
|
24
|
-
TreeConditionFilter
|
|
25
|
-
} from '_ui/types/search';
|
|
26
|
-
import {AttributeType} from '_ui/_gqlTypes';
|
|
27
|
-
import {
|
|
28
|
-
ILibraryDetailExtendedAttribute,
|
|
29
|
-
ILibraryDetailExtendedAttributeChild,
|
|
30
|
-
ILibraryDetailExtendedAttributeLink,
|
|
31
|
-
ILibraryDetailExtendedAttributeParentLinkedTree,
|
|
32
|
-
ILibraryDetailExtendedAttributeParentLinkedTreeLibrary,
|
|
33
|
-
ILibraryDetailExtendedAttributeStandard,
|
|
34
|
-
ILibraryDetailExtendedAttributeTree,
|
|
35
|
-
ILibraryDetailExtendedLinkedTree
|
|
36
|
-
} from '_ui/_queries/libraries/getLibraryDetailExtendQuery';
|
|
37
|
-
import {defaultLinkAttributeFilterFormat} from '../constants';
|
|
38
|
-
import {getDefaultFilterValueByFormat} from '../FiltersPanel/Filter/Filter';
|
|
39
|
-
import {defaultFilterConditionByAttributeFormat} from '../helpers/defaultFilterConditionByAttributeFormat';
|
|
40
|
-
|
|
41
|
-
const CustomMenu = styled(Menu)`
|
|
42
|
-
& .elements-wrapper {
|
|
43
|
-
max-height: 75vh;
|
|
44
|
-
overflow-y: auto;
|
|
45
|
-
|
|
46
|
-
> .ant-dropdown-menu-item-group-title {
|
|
47
|
-
display: none;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
`;
|
|
51
|
-
|
|
52
|
-
interface IFiltersDropdownProps {
|
|
53
|
-
libraryId: string;
|
|
54
|
-
button: JSX.Element;
|
|
55
|
-
attributes: ILibraryDetailExtendedAttribute[];
|
|
56
|
-
libraries: ILibraryDetailExtendedAttributeParentLinkedTree['libraries'];
|
|
57
|
-
trees: ILibraryDetailExtendedLinkedTree[];
|
|
58
|
-
disabled?: boolean;
|
|
59
|
-
filter?: IFilter; // if replace filter
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
function FiltersDropdown({
|
|
63
|
-
libraryId,
|
|
64
|
-
button,
|
|
65
|
-
attributes,
|
|
66
|
-
libraries,
|
|
67
|
-
trees,
|
|
68
|
-
filter
|
|
69
|
-
}: IFiltersDropdownProps): JSX.Element {
|
|
70
|
-
const {t} = useSharedTranslation();
|
|
71
|
-
const {state: searchState, dispatch: searchDispatch} = useSearchReducer();
|
|
72
|
-
const {lang} = useLang();
|
|
73
|
-
const [visible, setVisible] = useState<boolean>(false);
|
|
74
|
-
const [search, setSearch] = useState<string>();
|
|
75
|
-
|
|
76
|
-
const getAttributeFilter = (attribute: ILibraryDetailExtendedAttribute): IFilterAttribute => {
|
|
77
|
-
// we set the new filter key with the attribute id by default
|
|
78
|
-
let key = attribute.id;
|
|
79
|
-
|
|
80
|
-
// If we replace a current filter, the filter key depends on filter type and whether it goes through parent attributes or not
|
|
81
|
-
// The key is a concatenation of parents attribute's id
|
|
82
|
-
if (typeof (filter as IFilterAttribute)?.parentTreeLibrary !== 'undefined') {
|
|
83
|
-
key = `${(filter as IFilterAttribute)?.parentTreeLibrary.key}.${attribute.id}`;
|
|
84
|
-
} else if (filter?.condition === ThroughConditionFilter.THROUGH && filter.type === FilterType.LIBRARY) {
|
|
85
|
-
key = `${(filter as IFilterLibrary).key}.${attribute.id}`;
|
|
86
|
-
} else if (filter?.condition === ThroughConditionFilter.THROUGH) {
|
|
87
|
-
key = `${(filter as IFilterAttribute)?.attribute?.id}.${attribute.id}`;
|
|
88
|
-
} else if ((filter as IFilterAttribute)?.attribute?.parentAttribute) {
|
|
89
|
-
key = `${(filter as IFilterAttribute)?.attribute?.parentAttribute.id}.${attribute.id}`;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
const filterAttribute: IFilterAttribute = {
|
|
93
|
-
type: FilterType.ATTRIBUTE,
|
|
94
|
-
index: Date.now(),
|
|
95
|
-
active: true,
|
|
96
|
-
key,
|
|
97
|
-
condition: AttributeConditionFilter[defaultFilterConditionByAttributeFormat(attribute.format)],
|
|
98
|
-
attribute: {
|
|
99
|
-
id: attribute.id,
|
|
100
|
-
type: attribute.type,
|
|
101
|
-
format:
|
|
102
|
-
isTypeLink(attribute.type) || attribute.type === AttributeType.tree
|
|
103
|
-
? defaultLinkAttributeFilterFormat
|
|
104
|
-
: attribute.format,
|
|
105
|
-
label: attribute.label,
|
|
106
|
-
isLink: isTypeLink(attribute.type),
|
|
107
|
-
isMultiple: attribute.multiple_values,
|
|
108
|
-
linkedLibrary: (attribute as ILibraryDetailExtendedAttributeLink).linked_library,
|
|
109
|
-
linkedTree: (attribute as ILibraryDetailExtendedAttributeTree).linked_tree,
|
|
110
|
-
library: (attribute as ILibraryDetailExtendedAttributeLink).linked_library?.id || libraryId,
|
|
111
|
-
embedded_fields: (attribute as ILibraryDetailExtendedAttributeStandard).embedded_fields
|
|
112
|
-
},
|
|
113
|
-
value: {value: getDefaultFilterValueByFormat(attribute.format)}
|
|
114
|
-
};
|
|
115
|
-
|
|
116
|
-
// If filter's condition is a through condition it means current filter is a parent
|
|
117
|
-
// so we set the parentAttribute field to current filter's attribute, otherwise it means
|
|
118
|
-
// that the current filter is just a "brother" so we get the parent attribute of the current filter instead
|
|
119
|
-
if (filter?.condition === ThroughConditionFilter.THROUGH) {
|
|
120
|
-
filterAttribute.attribute.parentAttribute = (filter as IFilterAttribute)?.attribute;
|
|
121
|
-
} else if ((filter as IFilterAttribute)?.attribute?.parentAttribute) {
|
|
122
|
-
filterAttribute.attribute.parentAttribute = (filter as IFilterAttribute)?.attribute?.parentAttribute;
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
// 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
|
|
126
|
-
// If current filter type is not library it means we just change the current filter attribute by another at the same level,
|
|
127
|
-
// so the parent tree library is not as the first time, the filter itself, but the parentTreeLibrary of this one
|
|
128
|
-
if (filter?.type === FilterType.LIBRARY) {
|
|
129
|
-
filterAttribute.parentTreeLibrary = filter as IFilterLibrary;
|
|
130
|
-
} else if (typeof (filter as IFilterAttribute)?.parentTreeLibrary !== 'undefined') {
|
|
131
|
-
filterAttribute.parentTreeLibrary = (filter as IFilterAttribute)?.parentTreeLibrary;
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
return filterAttribute;
|
|
135
|
-
};
|
|
136
|
-
|
|
137
|
-
const getTreeFilter = (tree: ILibraryDetailExtendedLinkedTree): IFilterTree => ({
|
|
138
|
-
type: FilterType.TREE,
|
|
139
|
-
index: Date.now(),
|
|
140
|
-
active: true,
|
|
141
|
-
key: tree.id,
|
|
142
|
-
condition: TreeConditionFilter[TreeConditionFilter.CLASSIFIED_IN],
|
|
143
|
-
tree,
|
|
144
|
-
value: {value: null}
|
|
145
|
-
});
|
|
146
|
-
|
|
147
|
-
const getLibraryFilter = (library: {
|
|
148
|
-
id: string;
|
|
149
|
-
label: SystemTranslation;
|
|
150
|
-
attributes: ILibraryDetailExtendedAttributeChild[];
|
|
151
|
-
}): IFilterLibrary => {
|
|
152
|
-
// If current filter's type is a LIBRARY type it means we just changed the child library
|
|
153
|
-
// and not the parent attribute so we copy the current filter parent attribute
|
|
154
|
-
// The key is a concatenation of parent attributes' and libraries' id
|
|
155
|
-
const key =
|
|
156
|
-
filter?.type !== FilterType.LIBRARY
|
|
157
|
-
? `${(filter as IFilterAttribute).attribute?.id}.${library.id}`
|
|
158
|
-
: `${(filter as IFilterLibrary).parentAttribute?.id}.${library.id}`;
|
|
159
|
-
|
|
160
|
-
return {
|
|
161
|
-
type: FilterType.LIBRARY,
|
|
162
|
-
index: Date.now(),
|
|
163
|
-
active: true,
|
|
164
|
-
key,
|
|
165
|
-
condition:
|
|
166
|
-
AttributeConditionFilter[defaultFilterConditionByAttributeFormat(defaultLinkAttributeFilterFormat)],
|
|
167
|
-
library: {id: library.id, label: library.label},
|
|
168
|
-
value: {value: getDefaultFilterValueByFormat(defaultLinkAttributeFilterFormat)},
|
|
169
|
-
parentAttribute:
|
|
170
|
-
filter?.condition === ThroughConditionFilter.THROUGH
|
|
171
|
-
? (filter as IFilterAttribute).attribute ?? (filter as IFilterLibrary).parentAttribute
|
|
172
|
-
: (filter as IFilterLibrary).parentAttribute
|
|
173
|
-
};
|
|
174
|
-
};
|
|
175
|
-
|
|
176
|
-
const addFilter = (newFilter: IFilter) => {
|
|
177
|
-
const filters = [...searchState.filters];
|
|
178
|
-
|
|
179
|
-
if (typeof filter !== 'undefined') {
|
|
180
|
-
// we replace current filter
|
|
181
|
-
const filterPos = searchState.filters.findIndex(f => f.index === filter.index);
|
|
182
|
-
filters.splice(filterPos, 1, {...newFilter, index: filter.index});
|
|
183
|
-
setVisible(false);
|
|
184
|
-
} else {
|
|
185
|
-
filters.push(newFilter);
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
searchDispatch({
|
|
189
|
-
type: SearchActionTypes.SET_FILTERS,
|
|
190
|
-
filters
|
|
191
|
-
});
|
|
192
|
-
|
|
193
|
-
searchDispatch({
|
|
194
|
-
type: SearchActionTypes.SET_SIDEBAR,
|
|
195
|
-
visible: true,
|
|
196
|
-
sidebarType: SidebarContentType.filters
|
|
197
|
-
});
|
|
198
|
-
};
|
|
199
|
-
|
|
200
|
-
const _handleOpenChange = () => setVisible(!visible);
|
|
201
|
-
|
|
202
|
-
const _handleSearchChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
203
|
-
setSearch(e.target.value);
|
|
204
|
-
};
|
|
205
|
-
|
|
206
|
-
const _translateLabel = function <
|
|
207
|
-
T extends
|
|
208
|
-
| ILibraryDetailExtendedAttribute
|
|
209
|
-
| ILibraryDetailExtendedLinkedTree
|
|
210
|
-
| ILibraryDetailExtendedAttributeParentLinkedTreeLibrary
|
|
211
|
-
>(el: T) {
|
|
212
|
-
return {
|
|
213
|
-
...el,
|
|
214
|
-
localizedLabel: localizedTranslation(el.label, lang) || el.id
|
|
215
|
-
};
|
|
216
|
-
};
|
|
217
|
-
|
|
218
|
-
const _filterBySearch = function (el: {id: string; localizedLabel: string}): boolean {
|
|
219
|
-
const searchRegEx = new RegExp(`${search}`, 'i');
|
|
220
|
-
return !search || !!el.id.match(searchRegEx) || !!el.localizedLabel.match(searchRegEx);
|
|
221
|
-
};
|
|
222
|
-
|
|
223
|
-
const filteredTrees = trees.map(_translateLabel).filter(_filterBySearch);
|
|
224
|
-
const filteredAttributes = attributes.map(_translateLabel).filter(_filterBySearch);
|
|
225
|
-
const filteredLibraries = libraries
|
|
226
|
-
.map(lib => ({...lib, library: _translateLabel(lib.library)}))
|
|
227
|
-
.filter(lib => _filterBySearch(lib.library));
|
|
228
|
-
|
|
229
|
-
// to verify if a filter is used, we have to get the filter attribute/tree base id
|
|
230
|
-
// and check if one of those is used in the list of filters depending on the filter type
|
|
231
|
-
const isFilterUsed = (id: string) => {
|
|
232
|
-
return searchState.filters.some(f => {
|
|
233
|
-
return (
|
|
234
|
-
(f as IFilterTree)?.key === id ||
|
|
235
|
-
(f as IFilterAttribute).attribute?.parentAttribute?.id === id ||
|
|
236
|
-
(f as IFilterLibrary).parentAttribute?.id === id ||
|
|
237
|
-
(f as IFilterAttribute).parentTreeLibrary?.parentAttribute?.id === id
|
|
238
|
-
);
|
|
239
|
-
});
|
|
240
|
-
};
|
|
241
|
-
|
|
242
|
-
const menuItems: ItemType[] = [
|
|
243
|
-
{
|
|
244
|
-
key: 'search',
|
|
245
|
-
label: <Input.Search placeholder={t('global.search')} onChange={_handleSearchChange} />
|
|
246
|
-
},
|
|
247
|
-
{
|
|
248
|
-
key: 'divider',
|
|
249
|
-
type: 'divider'
|
|
250
|
-
}
|
|
251
|
-
];
|
|
252
|
-
|
|
253
|
-
let menuElements = [];
|
|
254
|
-
if (filteredTrees.length > 0) {
|
|
255
|
-
menuElements = [
|
|
256
|
-
...menuElements,
|
|
257
|
-
{
|
|
258
|
-
key: 'trees-group',
|
|
259
|
-
type: 'group',
|
|
260
|
-
label: t('filters.trees-group'),
|
|
261
|
-
children: filteredTrees.map(tree => ({
|
|
262
|
-
key: tree.id,
|
|
263
|
-
icon: <BranchesOutlined />,
|
|
264
|
-
onClick: () => addFilter(getTreeFilter(tree)),
|
|
265
|
-
label: isFilterUsed(tree.id) ? (
|
|
266
|
-
<Badge color={'blue'} text={tree.localizedLabel} />
|
|
267
|
-
) : (
|
|
268
|
-
tree.localizedLabel
|
|
269
|
-
)
|
|
270
|
-
}))
|
|
271
|
-
}
|
|
272
|
-
];
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
if (filteredAttributes.length > 0) {
|
|
276
|
-
menuElements = [
|
|
277
|
-
...menuElements,
|
|
278
|
-
{
|
|
279
|
-
key: 'attributes-group',
|
|
280
|
-
type: 'group',
|
|
281
|
-
label: t('filters.attributes-group'),
|
|
282
|
-
children: filteredAttributes.map(attribute => ({
|
|
283
|
-
key: attribute.id,
|
|
284
|
-
icon: <NumberOutlined />,
|
|
285
|
-
onClick: () => addFilter(getAttributeFilter(attribute)),
|
|
286
|
-
label: isFilterUsed(attribute.id) ? (
|
|
287
|
-
<Badge color={'blue'} text={attribute.localizedLabel} />
|
|
288
|
-
) : (
|
|
289
|
-
attribute.localizedLabel
|
|
290
|
-
)
|
|
291
|
-
}))
|
|
292
|
-
}
|
|
293
|
-
];
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
if (filteredLibraries.length > 0) {
|
|
297
|
-
menuElements = [
|
|
298
|
-
...menuElements,
|
|
299
|
-
{
|
|
300
|
-
key: 'libraries-group',
|
|
301
|
-
type: 'group',
|
|
302
|
-
label: t('filters.libraries-group'),
|
|
303
|
-
children: filteredLibraries.map(({library}) => ({
|
|
304
|
-
key: library.id,
|
|
305
|
-
icon: <NumberOutlined />,
|
|
306
|
-
onClick: () => addFilter(getLibraryFilter(library)),
|
|
307
|
-
label: isFilterUsed(library.id) ? (
|
|
308
|
-
<Badge color={'blue'} text={library.localizedLabel} />
|
|
309
|
-
) : (
|
|
310
|
-
library.localizedLabel
|
|
311
|
-
)
|
|
312
|
-
}))
|
|
313
|
-
}
|
|
314
|
-
];
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
menuItems.push({
|
|
318
|
-
key: 'elements-wrapper',
|
|
319
|
-
type: 'group',
|
|
320
|
-
children: menuElements,
|
|
321
|
-
label: null,
|
|
322
|
-
className: 'elements-wrapper',
|
|
323
|
-
style: {maxHeight: '75vh', overflowY: 'auto'}
|
|
324
|
-
});
|
|
325
|
-
|
|
326
|
-
const menu = {items: menuItems};
|
|
327
|
-
|
|
328
|
-
return (
|
|
329
|
-
<Dropdown
|
|
330
|
-
disabled={!!filter && !filter.active}
|
|
331
|
-
open={visible}
|
|
332
|
-
onOpenChange={_handleOpenChange}
|
|
333
|
-
menu={menu}
|
|
334
|
-
trigger={['click']}
|
|
335
|
-
>
|
|
336
|
-
{button}
|
|
337
|
-
</Dropdown>
|
|
338
|
-
);
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
export default FiltersDropdown;
|
|
@@ -1,75 +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 {AttributeConditionFilter, IFilterAttribute} from '_ui/types/search';
|
|
5
|
-
import {AttributeFormat} from '_ui/_gqlTypes';
|
|
6
|
-
import {act, render, screen} from '_ui/_tests/testUtils';
|
|
7
|
-
import {mockAttributeSimple} from '_ui/__mocks__/common/attribute';
|
|
8
|
-
import {mockFilterAttribute} from '_ui/__mocks__/common/filter';
|
|
9
|
-
import {mockLibrarySimple} from '_ui/__mocks__/common/library';
|
|
10
|
-
import MockSearchContextProvider from '_ui/__mocks__/common/mockSearchContextProvider';
|
|
11
|
-
import Filter from './Filter';
|
|
12
|
-
|
|
13
|
-
describe('Filter', () => {
|
|
14
|
-
test('Should contain filter', async () => {
|
|
15
|
-
await act(async () => {
|
|
16
|
-
render(
|
|
17
|
-
<MockSearchContextProvider>
|
|
18
|
-
<Filter filter={mockFilterAttribute} handleProps={{} as any} />
|
|
19
|
-
</MockSearchContextProvider>
|
|
20
|
-
);
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
expect(screen.getByTestId('filter')).toBeInTheDocument();
|
|
24
|
-
expect(screen.getByRole('button', {name: 'filter-condition'})).toBeInTheDocument();
|
|
25
|
-
expect(screen.getByRole('textbox')).toBeInTheDocument();
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
test('If attribute is boolean, just display switch', async () => {
|
|
29
|
-
const mockFilterBoolean: IFilterAttribute = {
|
|
30
|
-
...mockFilterAttribute,
|
|
31
|
-
attribute: {
|
|
32
|
-
...mockAttributeSimple,
|
|
33
|
-
isLink: false,
|
|
34
|
-
isMultiple: false,
|
|
35
|
-
library: mockLibrarySimple.id,
|
|
36
|
-
format: AttributeFormat.boolean
|
|
37
|
-
},
|
|
38
|
-
condition: AttributeConditionFilter.EQUAL,
|
|
39
|
-
value: {value: true}
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
await act(async () => {
|
|
43
|
-
render(
|
|
44
|
-
<MockSearchContextProvider>
|
|
45
|
-
<Filter filter={mockFilterBoolean} handleProps={{} as any} />
|
|
46
|
-
</MockSearchContextProvider>
|
|
47
|
-
);
|
|
48
|
-
});
|
|
49
|
-
|
|
50
|
-
expect(screen.getByTestId('filter')).toBeInTheDocument();
|
|
51
|
-
expect(screen.queryByRole('button', {name: 'filter-condition'})).not.toBeInTheDocument();
|
|
52
|
-
expect(screen.queryByRole('textbox')).not.toBeInTheDocument();
|
|
53
|
-
expect(screen.getByRole('switch')).toBeInTheDocument();
|
|
54
|
-
});
|
|
55
|
-
|
|
56
|
-
test('If condition is "is empty", hide value input', async () => {
|
|
57
|
-
await act(async () => {
|
|
58
|
-
render(
|
|
59
|
-
<MockSearchContextProvider>
|
|
60
|
-
<Filter
|
|
61
|
-
filter={{
|
|
62
|
-
...mockFilterAttribute,
|
|
63
|
-
condition: AttributeConditionFilter.IS_EMPTY,
|
|
64
|
-
value: null
|
|
65
|
-
}}
|
|
66
|
-
handleProps={{} as any}
|
|
67
|
-
/>
|
|
68
|
-
</MockSearchContextProvider>
|
|
69
|
-
);
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
expect(screen.getByTestId('filter')).toBeInTheDocument();
|
|
73
|
-
expect(screen.queryByRole('textbox')).not.toBeInTheDocument();
|
|
74
|
-
});
|
|
75
|
-
});
|