@leav/ui 1.13.0 → 1.14.0-2fd28db5
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/__mocks__/common/application.js.map +1 -1
- package/dist/__mocks__/common/attribute.js.map +1 -1
- package/dist/__mocks__/common/filter.js +0 -3
- package/dist/__mocks__/common/filter.js.map +1 -1
- package/dist/__mocks__/common/form.js +0 -3
- package/dist/__mocks__/common/form.js.map +1 -1
- package/dist/__mocks__/common/import.js +0 -3
- package/dist/__mocks__/common/import.js.map +1 -1
- package/dist/__mocks__/common/label.js +0 -3
- package/dist/__mocks__/common/label.js.map +1 -1
- package/dist/__mocks__/common/library.js +0 -3
- package/dist/__mocks__/common/library.js.map +1 -1
- package/dist/__mocks__/common/record.js.map +1 -1
- package/dist/__mocks__/common/tree.js +0 -3
- package/dist/__mocks__/common/tree.js.map +1 -1
- package/dist/__mocks__/common/treeElements.js.map +1 -1
- package/dist/__mocks__/common/value.js.map +1 -1
- package/dist/__mocks__/common/versionProfile.js.map +1 -1
- package/dist/__mocks__/common/view.js +0 -3
- package/dist/__mocks__/common/view.js.map +1 -1
- package/dist/__mocks__/mockQuery/mockGetLibraryDetailExtendedQuery.js +0 -3
- package/dist/__mocks__/mockQuery/mockGetLibraryDetailExtendedQuery.js.map +1 -1
- package/dist/__mocks__/mockQuery/mockGetRecordsFromLibraryQuery.js +0 -3
- package/dist/__mocks__/mockQuery/mockGetRecordsFromLibraryQuery.js.map +1 -1
- package/dist/__mocks__/mockQuery/mockGetViewListQuery.js +0 -3
- package/dist/__mocks__/mockQuery/mockGetViewListQuery.js.map +1 -1
- package/dist/__mocks__/react-i18next.js +0 -3
- package/dist/__mocks__/react-i18next.js.map +1 -1
- package/dist/__mocks__/utils.js.map +1 -1
- package/dist/_gqlTypes/index.d.ts +233 -118
- package/dist/_gqlTypes/index.js +142 -91
- package/dist/_gqlTypes/index.js.map +1 -1
- package/dist/_queries/applications/applicationDetailsFragment.js +0 -3
- package/dist/_queries/applications/applicationDetailsFragment.js.map +1 -1
- package/dist/_queries/applications/checkApplicationExistence.js +0 -3
- package/dist/_queries/applications/checkApplicationExistence.js.map +1 -1
- package/dist/_queries/applications/getApplicationDetails.js +0 -3
- package/dist/_queries/applications/getApplicationDetails.js.map +1 -1
- package/dist/_queries/applications/getApplicationsModulesQuery.js +0 -3
- package/dist/_queries/applications/getApplicationsModulesQuery.js.map +1 -1
- package/dist/_queries/applications/saveApplicationMutation.js +0 -3
- package/dist/_queries/applications/saveApplicationMutation.js.map +1 -1
- package/dist/_queries/attributes/attributeDetailsFragment.js +3 -3
- package/dist/_queries/attributes/attributeDetailsFragment.js.map +1 -1
- package/dist/_queries/attributes/checkAttributeExistenceQuery.js +0 -3
- package/dist/_queries/attributes/checkAttributeExistenceQuery.js.map +1 -1
- package/dist/_queries/attributes/deleteAttributeMutation.js +0 -3
- package/dist/_queries/attributes/deleteAttributeMutation.js.map +1 -1
- package/dist/_queries/attributes/getAttributeByIdQuery.js +0 -3
- package/dist/_queries/attributes/getAttributeByIdQuery.js.map +1 -1
- package/dist/_queries/attributes/getAttributeWithEmbeddedFields.js +0 -3
- package/dist/_queries/attributes/getAttributeWithEmbeddedFields.js.map +1 -1
- package/dist/_queries/attributes/getAttributesByLib.js +0 -3
- package/dist/_queries/attributes/getAttributesByLib.js.map +1 -1
- package/dist/_queries/attributes/getAttributesQuery.js +0 -3
- package/dist/_queries/attributes/getAttributesQuery.js.map +1 -1
- package/dist/_queries/attributes/getVersionProfilesQuery.js +0 -3
- package/dist/_queries/attributes/getVersionProfilesQuery.js.map +1 -1
- package/dist/_queries/attributes/getVersionableAttributesByLibrary.js +0 -3
- package/dist/_queries/attributes/getVersionableAttributesByLibrary.js.map +1 -1
- package/dist/_queries/attributes/saveAttributeMutation.js +0 -3
- package/dist/_queries/attributes/saveAttributeMutation.js.map +1 -1
- package/dist/_queries/export/exportQuery.js +0 -3
- package/dist/_queries/export/exportQuery.js.map +1 -1
- package/dist/_queries/files/createDirectory.js +0 -3
- package/dist/_queries/files/createDirectory.js.map +1 -1
- package/dist/_queries/files/forcePreviewsGenerationMutation.js +0 -3
- package/dist/_queries/files/forcePreviewsGenerationMutation.js.map +1 -1
- package/dist/_queries/files/getDirectoryDataQuery.js +0 -3
- package/dist/_queries/files/getDirectoryDataQuery.js.map +1 -1
- package/dist/_queries/files/getUploadUpdates.js +0 -3
- package/dist/_queries/files/getUploadUpdates.js.map +1 -1
- package/dist/_queries/files/uploadMutation.js +0 -3
- package/dist/_queries/files/uploadMutation.js.map +1 -1
- package/dist/_queries/import/importExcel.js +0 -3
- package/dist/_queries/import/importExcel.js.map +1 -1
- package/dist/_queries/libraries/checkLibraryExistenceQuery.js +0 -3
- package/dist/_queries/libraries/checkLibraryExistenceQuery.js.map +1 -1
- package/dist/_queries/libraries/deleteLibraryMutation.js +0 -3
- package/dist/_queries/libraries/deleteLibraryMutation.js.map +1 -1
- package/dist/_queries/libraries/getLibrariesQuery.js +0 -3
- package/dist/_queries/libraries/getLibrariesQuery.js.map +1 -1
- package/dist/_queries/libraries/getLibraryByIdQuery.js +0 -3
- package/dist/_queries/libraries/getLibraryByIdQuery.js.map +1 -1
- package/dist/_queries/libraries/getLibraryDetailExtendQuery.js.map +1 -1
- package/dist/_queries/libraries/getLibraryPermissionsQuery.js +0 -3
- package/dist/_queries/libraries/getLibraryPermissionsQuery.js.map +1 -1
- package/dist/_queries/libraries/getLibraryPreviewsSettingsQuery.js +0 -3
- package/dist/_queries/libraries/getLibraryPreviewsSettingsQuery.js.map +1 -1
- package/dist/_queries/libraries/libraryDetailsFragment.js +0 -3
- package/dist/_queries/libraries/libraryDetailsFragment.js.map +1 -1
- package/dist/_queries/libraries/saveLibraryMutation.js +0 -3
- package/dist/_queries/libraries/saveLibraryMutation.js.map +1 -1
- package/dist/_queries/permissions/isAllowedQuery.js +0 -3
- package/dist/_queries/permissions/isAllowedQuery.js.map +1 -1
- package/dist/_queries/records/activateRecordsMutation.js +0 -3
- package/dist/_queries/records/activateRecordsMutation.js.map +1 -1
- package/dist/_queries/records/createRecordMutation.js +0 -3
- package/dist/_queries/records/createRecordMutation.js.map +1 -1
- package/dist/_queries/records/deactivateRecordsMutation.js +0 -3
- package/dist/_queries/records/deactivateRecordsMutation.js.map +1 -1
- package/dist/_queries/records/doesFileExistAsChild.js +0 -3
- package/dist/_queries/records/doesFileExistAsChild.js.map +1 -1
- package/dist/_queries/records/getFileDataQuery.js +0 -3
- package/dist/_queries/records/getFileDataQuery.js.map +1 -1
- package/dist/_queries/records/getRecordColumnsValues.js +0 -3
- package/dist/_queries/records/getRecordColumnsValues.js.map +1 -1
- package/dist/_queries/records/getRecordFormQuery.js +0 -3
- package/dist/_queries/records/getRecordFormQuery.js.map +1 -1
- package/dist/_queries/records/getRecordPropertiesQuery.js +0 -3
- package/dist/_queries/records/getRecordPropertiesQuery.js.map +1 -1
- package/dist/_queries/records/getRecordUpdatesSubscription.js +0 -3
- package/dist/_queries/records/getRecordUpdatesSubscription.js.map +1 -1
- package/dist/_queries/records/getRecordsFromLibraryQuery.js +0 -3
- package/dist/_queries/records/getRecordsFromLibraryQuery.js.map +1 -1
- package/dist/_queries/records/indexRecordsMutation.js +0 -3
- package/dist/_queries/records/indexRecordsMutation.js.map +1 -1
- package/dist/_queries/records/recordFormAttributeFragment.js +0 -3
- package/dist/_queries/records/recordFormAttributeFragment.js.map +1 -1
- package/dist/_queries/tasks/cancelTaskMutation.js +0 -3
- package/dist/_queries/tasks/cancelTaskMutation.js.map +1 -1
- package/dist/_queries/trees/checkTreeExistenceQuery.js +0 -3
- package/dist/_queries/trees/checkTreeExistenceQuery.js.map +1 -1
- package/dist/_queries/trees/deleteTreeMutation.js +0 -3
- package/dist/_queries/trees/deleteTreeMutation.js.map +1 -1
- package/dist/_queries/trees/getTreeByIdQuery.js +0 -3
- package/dist/_queries/trees/getTreeByIdQuery.js.map +1 -1
- package/dist/_queries/trees/getTreeLibraries.js +0 -3
- package/dist/_queries/trees/getTreeLibraries.js.map +1 -1
- package/dist/_queries/trees/getTreesQuery.js +0 -3
- package/dist/_queries/trees/getTreesQuery.js.map +1 -1
- package/dist/_queries/trees/saveTreeMutation.js +0 -3
- package/dist/_queries/trees/saveTreeMutation.js.map +1 -1
- package/dist/_queries/trees/treeDetailsFragment.js +0 -3
- package/dist/_queries/trees/treeDetailsFragment.js.map +1 -1
- package/dist/_queries/trees/treeNodeChildrenQuery.js +0 -3
- package/dist/_queries/trees/treeNodeChildrenQuery.js.map +1 -1
- package/dist/_queries/userData/getUserData.js +0 -3
- package/dist/_queries/userData/getUserData.js.map +1 -1
- package/dist/_queries/userData/saveUserData.js +0 -3
- package/dist/_queries/userData/saveUserData.js.map +1 -1
- package/dist/_queries/values/deleteValueMutation.js +0 -3
- package/dist/_queries/values/deleteValueMutation.js.map +1 -1
- package/dist/_queries/values/saveValueBatchMutation.js +0 -3
- package/dist/_queries/values/saveValueBatchMutation.js.map +1 -1
- package/dist/_queries/values/valueDetailsFragment.js +0 -3
- package/dist/_queries/values/valueDetailsFragment.js.map +1 -1
- package/dist/_queries/values/valuesVersionFragment.js +0 -3
- package/dist/_queries/values/valuesVersionFragment.js.map +1 -1
- package/dist/_queries/views/deleteViewMutation.js +0 -3
- package/dist/_queries/views/deleteViewMutation.js.map +1 -1
- package/dist/_queries/views/getViewById.js +0 -3
- package/dist/_queries/views/getViewById.js.map +1 -1
- package/dist/_queries/views/getViewsListQuery.js +0 -3
- package/dist/_queries/views/getViewsListQuery.js.map +1 -1
- package/dist/_queries/views/saveViewMutation.js +0 -3
- package/dist/_queries/views/saveViewMutation.js.map +1 -1
- package/dist/_queries/views/viewDetailsFragment.js +0 -3
- package/dist/_queries/views/viewDetailsFragment.js.map +1 -1
- package/dist/_utils/__mocks__/isDevEnv.js +0 -3
- package/dist/_utils/__mocks__/isDevEnv.js.map +1 -1
- package/dist/_utils/attributeType.js +0 -3
- package/dist/_utils/attributeType.js.map +1 -1
- package/dist/_utils/getFiltersFromRequest.js +0 -3
- package/dist/_utils/getFiltersFromRequest.js.map +1 -1
- package/dist/_utils/getRequestFromFilter.js +0 -3
- package/dist/_utils/getRequestFromFilter.js.map +1 -1
- package/dist/_utils/index.js +0 -3
- package/dist/_utils/index.js.map +1 -1
- package/dist/_utils/interleaveElement.js +0 -3
- package/dist/_utils/interleaveElement.js.map +1 -1
- package/dist/_utils/isDevEnv.js +0 -3
- package/dist/_utils/isDevEnv.js.map +1 -1
- package/dist/_utils/typeguards.js.map +1 -1
- package/dist/antdTheme/index.js +0 -3
- package/dist/antdTheme/index.js.map +1 -1
- package/dist/antdTheme/types.js.map +1 -1
- package/dist/components/AttributePicker/AttributePicker.js +0 -3
- package/dist/components/AttributePicker/AttributePicker.js.map +1 -1
- package/dist/components/AttributePicker/AttributesList/AttributesList.js +0 -3
- package/dist/components/AttributePicker/AttributesList/AttributesList.js.map +1 -1
- package/dist/components/AttributePicker/AttributesList/index.js +0 -3
- package/dist/components/AttributePicker/AttributesList/index.js.map +1 -1
- package/dist/components/AttributePicker/index.js +0 -3
- package/dist/components/AttributePicker/index.js.map +1 -1
- package/dist/components/BasicButton/BasicButton.js +0 -3
- package/dist/components/BasicButton/BasicButton.js.map +1 -1
- package/dist/components/BasicButton/index.js +0 -3
- package/dist/components/BasicButton/index.js.map +1 -1
- package/dist/components/CreateDirectory/CreateDirectory.js +0 -3
- package/dist/components/CreateDirectory/CreateDirectory.js.map +1 -1
- package/dist/components/CreateDirectory/index.js +0 -3
- package/dist/components/CreateDirectory/index.js.map +1 -1
- package/dist/components/Dimmer/Dimmer.js.map +1 -1
- package/dist/components/Dimmer/index.js +0 -3
- package/dist/components/Dimmer/index.js.map +1 -1
- package/dist/components/EditApplication/EditApplication.js +0 -3
- package/dist/components/EditApplication/EditApplication.js.map +1 -1
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfo.js +0 -3
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfo.js.map +1 -1
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/EditApplicationInfoForm.js +0 -3
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/EditApplicationInfoForm.js.map +1 -1
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/ModuleSelector/ModuleSelector.js +0 -3
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/ModuleSelector/ModuleSelector.js.map +1 -1
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/ModuleSelector/index.js +0 -3
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/ModuleSelector/index.js.map +1 -1
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/index.js +0 -3
- package/dist/components/EditApplication/EditApplicationInfo/EditApplicationInfoForm/index.js.map +1 -1
- package/dist/components/EditApplication/EditApplicationInfo/index.js +0 -3
- package/dist/components/EditApplication/EditApplicationInfo/index.js.map +1 -1
- package/dist/components/EditApplication/_types.js.map +1 -1
- package/dist/components/EditApplication/index.js +0 -3
- package/dist/components/EditApplication/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttribute.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttribute.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfo.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfo.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/EditAttributeInfoForm.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/EditAttributeInfoForm.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedLibraryForm/LinkedLibraryForm.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedLibraryForm/LinkedLibraryForm.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedLibraryForm/index.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedLibraryForm/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedTreeForm/LinkedTreeForm.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedTreeForm/LinkedTreeForm.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedTreeForm/index.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/LinkedTreeForm/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/ValuesVersionsForm/ValuesVersionsForm.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/ValuesVersionsForm/ValuesVersionsForm.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/ValuesVersionsForm/index.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/ValuesVersionsForm/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/index.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/EditAttributeInfoForm/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/index.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/EditAttributeInfo/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttribute/index.js +0 -3
- package/dist/components/EditAttributeModal/EditAttribute/index.js.map +1 -1
- package/dist/components/EditAttributeModal/EditAttributeModal.js +0 -3
- package/dist/components/EditAttributeModal/EditAttributeModal.js.map +1 -1
- package/dist/components/EditAttributeModal/index.js +0 -3
- package/dist/components/EditAttributeModal/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibrary.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibrary.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributeCell/AttributeCell.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributeCell/AttributeCell.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributeCell/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributeCell/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributesList.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/AttributesList.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/DeleteButton/DeleteButton.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/DeleteButton/DeleteButton.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/DeleteButton/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/DeleteButton/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/AttributesList/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/EditLibraryAttributes.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/EditLibraryAttributes.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryAttributes/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryIndexation/EditLibraryIndexation.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryIndexation/EditLibraryIndexation.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryIndexation/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryIndexation/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfo.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfoForm/EditLibraryInfoForm.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfoForm/EditLibraryInfoForm.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfoForm/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/EditLibraryInfoForm/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryInfo/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditLibraryPreviewsSettings.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditLibraryPreviewsSettings.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/EditPreviewsSettingsModal.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/EditPreviewsSettingsModal.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/SizesEditor/SizesEditor.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/SizesEditor/SizesEditor.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/SizesEditor/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/SizesEditor/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/EditPreviewsSettingsModal/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/PreviewsSettingsList/PreviewsSettingsList.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/PreviewsSettingsList/PreviewsSettingsList.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/PreviewsSettingsList/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/PreviewsSettingsList/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/EditLibraryPreviewsSettings/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibrary/index.js +0 -3
- package/dist/components/EditLibraryModal/EditLibrary/index.js.map +1 -1
- package/dist/components/EditLibraryModal/EditLibraryModal.js +0 -3
- package/dist/components/EditLibraryModal/EditLibraryModal.js.map +1 -1
- package/dist/components/EditLibraryModal/index.js +0 -3
- package/dist/components/EditLibraryModal/index.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTree.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTree.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfo.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfo.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/EditTreeInfoForm.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/EditTreeInfoForm.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/TreeLibrariesForm/TreeLibrariesForm.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/TreeLibrariesForm/TreeLibrariesForm.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/TreeLibrariesForm/index.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/TreeLibrariesForm/index.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/index.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/EditTreeInfoForm/index.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/index.js +0 -3
- package/dist/components/EditTreeModal/EditTree/EditTreeInfo/index.js.map +1 -1
- package/dist/components/EditTreeModal/EditTree/index.js +0 -3
- package/dist/components/EditTreeModal/EditTree/index.js.map +1 -1
- package/dist/components/EditTreeModal/EditTreeModal.js +0 -3
- package/dist/components/EditTreeModal/EditTreeModal.js.map +1 -1
- package/dist/components/EditTreeModal/index.js +0 -3
- package/dist/components/EditTreeModal/index.js.map +1 -1
- package/dist/components/EntityCard/EntityCard.js +0 -3
- package/dist/components/EntityCard/EntityCard.js.map +1 -1
- package/dist/components/EntityCard/_types.js.map +1 -1
- package/dist/components/EntityCard/index.js +0 -3
- package/dist/components/EntityCard/index.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreview.js +0 -3
- package/dist/components/EntityPreview/EntityPreview.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreviewList/EntityPreviewList.js +0 -3
- package/dist/components/EntityPreview/EntityPreviewList/EntityPreviewList.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreviewList/SimplisticEntityPreview/SimplisticEntityPreview.js +0 -3
- package/dist/components/EntityPreview/EntityPreviewList/SimplisticEntityPreview/SimplisticEntityPreview.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreviewList/SimplisticEntityPreview/index.js +0 -3
- package/dist/components/EntityPreview/EntityPreviewList/SimplisticEntityPreview/index.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreviewList/index.js +0 -3
- package/dist/components/EntityPreview/EntityPreviewList/index.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreviewTile/EntityPreviewTile.js +0 -3
- package/dist/components/EntityPreview/EntityPreviewTile/EntityPreviewTile.js.map +1 -1
- package/dist/components/EntityPreview/EntityPreviewTile/index.js +0 -3
- package/dist/components/EntityPreview/EntityPreviewTile/index.js.map +1 -1
- package/dist/components/EntityPreview/_types.js.map +1 -1
- package/dist/components/EntityPreview/index.js +0 -3
- package/dist/components/EntityPreview/index.js.map +1 -1
- package/dist/components/ErrorBoundary/ErrorBoundary.js +0 -3
- package/dist/components/ErrorBoundary/ErrorBoundary.js.map +1 -1
- package/dist/components/ErrorBoundary/ErrorBoundaryContent/ErrorBoundaryContent.js +0 -3
- package/dist/components/ErrorBoundary/ErrorBoundaryContent/ErrorBoundaryContent.js.map +1 -1
- package/dist/components/ErrorBoundary/ErrorBoundaryContent/index.js +0 -3
- package/dist/components/ErrorBoundary/ErrorBoundaryContent/index.js.map +1 -1
- package/dist/components/ErrorBoundary/index.js +0 -3
- package/dist/components/ErrorBoundary/index.js.map +1 -1
- package/dist/components/ErrorDisplay/ErrorDisplay.js +0 -3
- package/dist/components/ErrorDisplay/ErrorDisplay.js.map +1 -1
- package/dist/components/ErrorDisplay/index.js +0 -3
- package/dist/components/ErrorDisplay/index.js.map +1 -1
- package/dist/components/ErrorMessage/ErrorMessage.js +0 -3
- package/dist/components/ErrorMessage/ErrorMessage.js.map +1 -1
- package/dist/components/ErrorMessage/index.js +0 -3
- package/dist/components/ErrorMessage/index.js.map +1 -1
- package/dist/components/Explorer/DataView.js +0 -3
- package/dist/components/Explorer/DataView.js.map +1 -1
- package/dist/components/Explorer/Explorer.d.ts +5 -1
- package/dist/components/Explorer/Explorer.js +7 -3
- package/dist/components/Explorer/Explorer.js.map +1 -1
- package/dist/components/Explorer/ExplorerFiltersAndSorts.js +0 -3
- package/dist/components/Explorer/ExplorerFiltersAndSorts.js.map +1 -1
- package/dist/components/Explorer/ExplorerTitle.js +0 -3
- package/dist/components/Explorer/ExplorerTitle.js.map +1 -1
- package/dist/components/Explorer/ExplorerToolbar.js.map +1 -1
- package/dist/components/Explorer/IdCard.js +0 -3
- package/dist/components/Explorer/IdCard.js.map +1 -1
- package/dist/components/Explorer/TableCell.js +0 -3
- package/dist/components/Explorer/TableCell.js.map +1 -1
- package/dist/components/Explorer/TableNameCell.js +0 -3
- package/dist/components/Explorer/TableNameCell.js.map +1 -1
- package/dist/components/Explorer/TableTagGroup.js +0 -3
- package/dist/components/Explorer/TableTagGroup.js.map +1 -1
- package/dist/components/Explorer/_constants.js +0 -3
- package/dist/components/Explorer/_constants.js.map +1 -1
- package/dist/components/Explorer/_queries/useExecuteUpdateViewMutation.js.map +1 -1
- package/dist/components/Explorer/_queries/useExplorerCountData.js +0 -3
- package/dist/components/Explorer/_queries/useExplorerCountData.js.map +1 -1
- package/dist/components/Explorer/_queries/useExplorerData.js +0 -3
- package/dist/components/Explorer/_queries/useExplorerData.js.map +1 -1
- package/dist/components/Explorer/_types.d.ts +6 -0
- package/dist/components/Explorer/_types.js.map +1 -1
- package/dist/components/Explorer/actions-item/useEditStatusItemAction.js +18 -5
- package/dist/components/Explorer/actions-item/useEditStatusItemAction.js.map +1 -1
- package/dist/components/Explorer/actions-item/useReplaceItemAction.js +0 -3
- package/dist/components/Explorer/actions-item/useReplaceItemAction.js.map +1 -1
- package/dist/components/Explorer/actions-mass/ResultsCount.js.map +1 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/EditAttributeMassActionModal.js.map +1 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/EditMonoDependencyWorkflowTreeAttribute.d.ts +8 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/EditMonoDependencyWorkflowTreeAttribute.js +34 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/EditMonoDependencyWorkflowTreeAttribute.js.map +1 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/EditTreeAttributeValuesMapping.d.ts +3 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/EditTreeAttributeValuesMapping.js +12 -17
- package/dist/components/Explorer/actions-mass/edit-attribute/EditTreeAttributeValuesMapping.js.map +1 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/TreeNodeRemap.js.map +1 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/_types.d.ts +15 -3
- package/dist/components/Explorer/actions-mass/edit-attribute/_types.js.map +1 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/useDependencyValues.d.ts +13 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useDependencyValues.js +44 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useDependencyValues.js.map +1 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useEditionMappingState.d.ts +13 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useEditionMappingState.js +70 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useEditionMappingState.js.map +1 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useMassEditableAttributes.js +14 -20
- package/dist/components/Explorer/actions-mass/edit-attribute/useMassEditableAttributes.js.map +1 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/useTreeNodesCandidates.d.ts +23 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useTreeNodesCandidates.js +65 -0
- package/dist/components/Explorer/actions-mass/edit-attribute/useTreeNodesCandidates.js.map +1 -0
- package/dist/components/Explorer/actions-mass/export/ExportProfileSelectionModal.js +0 -3
- package/dist/components/Explorer/actions-mass/export/ExportProfileSelectionModal.js.map +1 -1
- package/dist/components/Explorer/actions-mass/export/content/NoProfiles.js +0 -3
- package/dist/components/Explorer/actions-mass/export/content/NoProfiles.js.map +1 -1
- package/dist/components/Explorer/actions-mass/export/content/ProfilesSelection.js +0 -3
- package/dist/components/Explorer/actions-mass/export/content/ProfilesSelection.js.map +1 -1
- package/dist/components/Explorer/actions-mass/export/useGetLibraryExportProfiles.js +0 -3
- package/dist/components/Explorer/actions-mass/export/useGetLibraryExportProfiles.js.map +1 -1
- package/dist/components/Explorer/actions-mass/generate-previews/GeneratePreviewsModal.js +0 -3
- package/dist/components/Explorer/actions-mass/generate-previews/GeneratePreviewsModal.js.map +1 -1
- package/dist/components/Explorer/actions-mass/generate-previews/useGetPreviewSizesData.js +0 -3
- package/dist/components/Explorer/actions-mass/generate-previews/useGetPreviewSizesData.js.map +1 -1
- package/dist/components/Explorer/actions-mass/useDeactivateMassAction.js +0 -3
- package/dist/components/Explorer/actions-mass/useDeactivateMassAction.js.map +1 -1
- package/dist/components/Explorer/actions-mass/useDeleteLinkValues.js +0 -3
- package/dist/components/Explorer/actions-mass/useDeleteLinkValues.js.map +1 -1
- package/dist/components/Explorer/actions-mass/useEditAttributeMassAction.js +16 -53
- package/dist/components/Explorer/actions-mass/useEditAttributeMassAction.js.map +1 -1
- package/dist/components/Explorer/actions-mass/useExportMassAction.js +0 -3
- package/dist/components/Explorer/actions-mass/useExportMassAction.js.map +1 -1
- package/dist/components/Explorer/actions-mass/useGeneratePreviewsMassAction.js +0 -3
- package/dist/components/Explorer/actions-mass/useGeneratePreviewsMassAction.js.map +1 -1
- package/dist/components/Explorer/actions-mass/useMassActions.js +0 -3
- package/dist/components/Explorer/actions-mass/useMassActions.js.map +1 -1
- package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.js +0 -3
- package/dist/components/Explorer/actions-primary/useCreatePrimaryAction.js.map +1 -1
- package/dist/components/Explorer/actions-primary/useLinkPrimaryAction.js +0 -3
- package/dist/components/Explorer/actions-primary/useLinkPrimaryAction.js.map +1 -1
- package/dist/components/Explorer/actions-primary/usePrimaryActions.js +0 -3
- package/dist/components/Explorer/actions-primary/usePrimaryActions.js.map +1 -1
- package/dist/components/Explorer/conditionsHelper.js +0 -3
- package/dist/components/Explorer/conditionsHelper.js.map +1 -1
- package/dist/components/Explorer/index.js +0 -3
- package/dist/components/Explorer/index.js.map +1 -1
- package/dist/components/Explorer/link-item/LinkModal.js +0 -3
- package/dist/components/Explorer/link-item/LinkModal.js.map +1 -1
- package/dist/components/Explorer/link-item/useAddLinkMassAction.js +0 -3
- package/dist/components/Explorer/link-item/useAddLinkMassAction.js.map +1 -1
- package/dist/components/Explorer/link-item/useReplaceLinkMassAction.js.map +1 -1
- package/dist/components/Explorer/list-saved-views/SavedViews.js +0 -3
- package/dist/components/Explorer/list-saved-views/SavedViews.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/_shared/ColumnItem.js +0 -3
- package/dist/components/Explorer/manage-view-settings/_shared/ColumnItem.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.js +0 -3
- package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js +0 -3
- package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js +0 -3
- package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js +6 -6
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/index.d.ts +1 -0
- package/dist/components/Explorer/manage-view-settings/index.js +1 -3
- package/dist/components/Explorer/manage-view-settings/index.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.js +0 -3
- package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.js +0 -3
- package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/open-view-settings/SidePanel.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.js +0 -3
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.js +0 -3
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/router-menu/SettingItem.js +0 -3
- package/dist/components/Explorer/manage-view-settings/router-menu/SettingItem.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/router-menu/SettingsPanel.js +0 -3
- package/dist/components/Explorer/manage-view-settings/router-menu/SettingsPanel.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/LabelViewFormModal.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/ViewActionsButtons.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/ViewActionsButtons.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/prepareViewForRequest.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/useCreateNewView.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/useCreateNewView.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/useDeleteView.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/useDeleteView.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/useEditLabelView.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/useEditLabelView.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/useResetView.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/useResetView.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/useShareView.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/useShareView.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/save-view/useUpdateView.js +0 -3
- package/dist/components/Explorer/manage-view-settings/save-view/useUpdateView.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js +0 -3
- package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js +0 -3
- package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js.map +1 -1
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.d.ts +7 -31
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js +9 -20
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js.map +1 -1
- package/dist/components/Explorer/useColumnWidth.js +0 -3
- package/dist/components/Explorer/useColumnWidth.js.map +1 -1
- package/dist/components/Explorer/useLoadView.js +0 -3
- package/dist/components/Explorer/useLoadView.js.map +1 -1
- package/dist/components/Explorer/useNotifyFiltersChange.d.ts +15 -0
- package/dist/components/Explorer/useNotifyFiltersChange.js +23 -0
- package/dist/components/Explorer/useNotifyFiltersChange.js.map +1 -0
- package/dist/components/Explorer/usePagination.js +0 -3
- package/dist/components/Explorer/usePagination.js.map +1 -1
- package/dist/components/Explorer/useSearchInput.js +0 -3
- package/dist/components/Explorer/useSearchInput.js.map +1 -1
- package/dist/components/Explorer/useTableScrollableHeight.js +0 -3
- package/dist/components/Explorer/useTableScrollableHeight.js.map +1 -1
- package/dist/components/Explorer/useViewSettingsReducer.js +0 -3
- package/dist/components/Explorer/useViewSettingsReducer.js.map +1 -1
- package/dist/components/FieldsGroup/FieldsGroup.js +0 -3
- package/dist/components/FieldsGroup/FieldsGroup.js.map +1 -1
- package/dist/components/FieldsGroup/index.js +0 -3
- package/dist/components/FieldsGroup/index.js.map +1 -1
- package/dist/components/Filters/FiltersProvider.js.map +1 -1
- package/dist/components/Filters/_queries/treeFiltersDataQuery.js +0 -3
- package/dist/components/Filters/_queries/treeFiltersDataQuery.js.map +1 -1
- package/dist/components/Filters/_types.d.ts +14 -0
- package/dist/components/Filters/_types.js +2 -1
- package/dist/components/Filters/_types.js.map +1 -1
- package/dist/components/Filters/conditionsHelper.js +0 -3
- package/dist/components/Filters/conditionsHelper.js.map +1 -1
- package/dist/components/Filters/context/filtersContext.js +0 -3
- package/dist/components/Filters/context/filtersContext.js.map +1 -1
- package/dist/components/Filters/context/filtersInitialState.js.map +1 -1
- package/dist/components/Filters/context/filtersReducer.d.ts +14 -1
- package/dist/components/Filters/context/filtersReducer.js +88 -52
- package/dist/components/Filters/context/filtersReducer.js.map +1 -1
- package/dist/components/Filters/context/useFiltersReducer.js +12 -24
- package/dist/components/Filters/context/useFiltersReducer.js.map +1 -1
- package/dist/components/Filters/context/useGetTreeFilters.js +0 -3
- package/dist/components/Filters/context/useGetTreeFilters.js.map +1 -1
- package/dist/components/Filters/filter-items/CommonFilterItem.js +11 -12
- package/dist/components/Filters/filter-items/CommonFilterItem.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/BooleanAttributeDropdown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/ColorAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/DateAttributeDropDown.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/DateAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/DateRangeAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/EncryptedAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/ExtendedAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/FilterDropDown.js +15 -6
- package/dist/components/Filters/filter-items/filter-type/FilterDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/FilterDropdownContent.d.ts +3 -1
- package/dist/components/Filters/filter-items/filter-type/FilterDropdownContent.js +2 -5
- package/dist/components/Filters/filter-items/filter-type/FilterDropdownContent.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/FilterValueListDropDown.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/FilterValueListDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/LinkAttributeDropdown.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/LinkAttributeDropdown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/NumericAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/TextAttributeDropDown.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/TextAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/_types.d.ts +3 -1
- package/dist/components/Filters/filter-items/filter-type/_types.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/smart-filter/SmartFilterAttributeDropdown.js +2 -6
- package/dist/components/Filters/filter-items/filter-type/smart-filter/SmartFilterAttributeDropdown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/smart-filter/useGetSmartFilterData.d.ts +2 -4
- package/dist/components/Filters/filter-items/filter-type/smart-filter/useGetSmartFilterData.js +22 -19
- package/dist/components/Filters/filter-items/filter-type/smart-filter/useGetSmartFilterData.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/smart-filter/useSmartFilerSearch.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/smart-filter/useSmartFilerSearch.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/TreeAttributeDropDown.js +52 -86
- package/dist/components/Filters/filter-items/filter-type/tree/TreeAttributeDropDown.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/_queries/filterTreeDataQuery.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/tree/_queries/filterTreeDataQuery.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/useGetTreeData.d.ts +1 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useGetTreeData.js +0 -3
- package/dist/components/Filters/filter-items/filter-type/tree/useGetTreeData.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/useTreeNodeSelection.d.ts +21 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useTreeNodeSelection.js +85 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useTreeNodeSelection.js.map +1 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useTreePermissions.d.ts +8 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useTreePermissions.js +37 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useTreePermissions.js.map +1 -0
- package/dist/components/Filters/filter-items/filter-type/tree/useTreesSearch.d.ts +2 -3
- package/dist/components/Filters/filter-items/filter-type/tree/useTreesSearch.js +2 -6
- package/dist/components/Filters/filter-items/filter-type/tree/useTreesSearch.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/utils/buildFlattenTreeMap.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/utils/countSelectedTreeChildren.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/utils/filterTreeByPermission.d.ts +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/utils/filterTreeByPermission.js +3 -4
- package/dist/components/Filters/filter-items/filter-type/tree/utils/filterTreeByPermission.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/tree/utils/getSelectAllState.js.map +1 -1
- package/dist/components/Filters/filter-items/filter-type/useConditionOptionsByType.js +3 -19
- package/dist/components/Filters/filter-items/filter-type/useConditionOptionsByType.js.map +1 -1
- package/dist/components/Filters/filter-items/shared/EmptyValueCheckbox.js +1 -7
- package/dist/components/Filters/filter-items/shared/EmptyValueCheckbox.js.map +1 -1
- package/dist/components/Filters/filter-items/shared/FilterTreeNodeTitle.js +0 -3
- package/dist/components/Filters/filter-items/shared/FilterTreeNodeTitle.js.map +1 -1
- package/dist/components/Filters/filter-items/shared/SelectAllCheckbox.js.map +1 -1
- package/dist/components/Filters/index.js +0 -3
- package/dist/components/Filters/index.js.map +1 -1
- package/dist/components/Filters/prepareFiltersForRequest.js +116 -129
- package/dist/components/Filters/prepareFiltersForRequest.js.map +1 -1
- package/dist/components/Filters/useFilters.d.ts +312 -0
- package/dist/components/Filters/useFilters.js +0 -3
- package/dist/components/Filters/useFilters.js.map +1 -1
- package/dist/components/Filters/useFiltersContext.js +0 -3
- package/dist/components/Filters/useFiltersContext.js.map +1 -1
- package/dist/components/Filters/useTransformFilters.d.ts +3 -1
- package/dist/components/Filters/useTransformFilters.js +133 -137
- package/dist/components/Filters/useTransformFilters.js.map +1 -1
- package/dist/components/FloatingMenu/FloatingMenu.js +0 -3
- package/dist/components/FloatingMenu/FloatingMenu.js.map +1 -1
- package/dist/components/FloatingMenu/_types.js.map +1 -1
- package/dist/components/FloatingMenu/index.js +0 -3
- package/dist/components/FloatingMenu/index.js.map +1 -1
- package/dist/components/ImageLoading/ImageLoading.js +0 -3
- package/dist/components/ImageLoading/ImageLoading.js.map +1 -1
- package/dist/components/ImageLoading/index.js +0 -3
- package/dist/components/ImageLoading/index.js.map +1 -1
- package/dist/components/ImageMissing/ImageMissing.js +0 -3
- package/dist/components/ImageMissing/ImageMissing.js.map +1 -1
- package/dist/components/ImageMissing/index.js +0 -3
- package/dist/components/ImageMissing/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModal.js +0 -3
- package/dist/components/ImportModal/ImportModal.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportKeysSelector/ImportKeysSelector.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportKeysSelector/ImportKeysSelector.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportKeysSelector/index.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportKeysSelector/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportMappingRowTitle/ImportMappingRowTitle.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportMappingRowTitle/ImportMappingRowTitle.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportMappingRowTitle/index.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportMappingRowTitle/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportScheduleModal/ImportScheduleModal.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportScheduleModal/ImportScheduleModal.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportScheduleModal/index.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportScheduleModal/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportSheetSettings/ImportSheetSettings.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportSheetSettings/ImportSheetSettings.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportSheetSettings/index.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/ImportSheetSettings/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/index.js +0 -3
- package/dist/components/ImportModal/ImportModalConfigStep/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalDoneStep/ImportModalDoneStep.js +0 -3
- package/dist/components/ImportModal/ImportModalDoneStep/ImportModalDoneStep.js.map +1 -1
- package/dist/components/ImportModal/ImportModalDoneStep/index.js +0 -3
- package/dist/components/ImportModal/ImportModalDoneStep/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalProcessingStep/ImportModalProcessingStep.js +0 -3
- package/dist/components/ImportModal/ImportModalProcessingStep/ImportModalProcessingStep.js.map +1 -1
- package/dist/components/ImportModal/ImportModalProcessingStep/index.js +0 -3
- package/dist/components/ImportModal/ImportModalProcessingStep/index.js.map +1 -1
- package/dist/components/ImportModal/ImportModalSelectFileStep/ImportModalSelectFileStep.js +0 -3
- package/dist/components/ImportModal/ImportModalSelectFileStep/ImportModalSelectFileStep.js.map +1 -1
- package/dist/components/ImportModal/ImportModalSelectFileStep/index.js +0 -3
- package/dist/components/ImportModal/ImportModalSelectFileStep/index.js.map +1 -1
- package/dist/components/ImportModal/_types.js.map +1 -1
- package/dist/components/ImportModal/importReducer/ImportReducerContext.js +0 -3
- package/dist/components/ImportModal/importReducer/ImportReducerContext.js.map +1 -1
- package/dist/components/ImportModal/importReducer/importReducer.js +0 -3
- package/dist/components/ImportModal/importReducer/importReducer.js.map +1 -1
- package/dist/components/ImportModal/importReducer/index.js +0 -3
- package/dist/components/ImportModal/importReducer/index.js.map +1 -1
- package/dist/components/ImportModal/index.js +0 -3
- package/dist/components/ImportModal/index.js.map +1 -1
- package/dist/components/LibraryPicker/LibrariesList/LibrariesList.js +0 -3
- package/dist/components/LibraryPicker/LibrariesList/LibrariesList.js.map +1 -1
- package/dist/components/LibraryPicker/LibrariesList/index.js +0 -3
- package/dist/components/LibraryPicker/LibrariesList/index.js.map +1 -1
- package/dist/components/LibraryPicker/LibraryPicker.js +0 -3
- package/dist/components/LibraryPicker/LibraryPicker.js.map +1 -1
- package/dist/components/LibraryPicker/index.js +0 -3
- package/dist/components/LibraryPicker/index.js.map +1 -1
- package/dist/components/List/List.js +0 -3
- package/dist/components/List/List.js.map +1 -1
- package/dist/components/List/index.js +0 -3
- package/dist/components/List/index.js.map +1 -1
- package/dist/components/Loading/Loading.js +0 -3
- package/dist/components/Loading/Loading.js.map +1 -1
- package/dist/components/Loading/index.js +0 -3
- package/dist/components/Loading/index.js.map +1 -1
- package/dist/components/Notifications/InitNotificationsSubscription.js.map +1 -1
- package/dist/components/Notifications/hooks/useNotificationSubscription.js +0 -3
- package/dist/components/Notifications/hooks/useNotificationSubscription.js.map +1 -1
- package/dist/components/Notifications/index.js +0 -3
- package/dist/components/Notifications/index.js.map +1 -1
- package/dist/components/RecordCard/RecordCard.js +0 -3
- package/dist/components/RecordCard/RecordCard.js.map +1 -1
- package/dist/components/RecordCard/_types.js.map +1 -1
- package/dist/components/RecordCard/index.js +0 -3
- package/dist/components/RecordCard/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecord/EditRecord.js +0 -3
- package/dist/components/RecordEdition/EditRecord/EditRecord.js.map +1 -1
- package/dist/components/RecordEdition/EditRecord/ValuesVersionSummary/ValuesVersionSummary.js +0 -3
- package/dist/components/RecordEdition/EditRecord/ValuesVersionSummary/ValuesVersionSummary.js.map +1 -1
- package/dist/components/RecordEdition/EditRecord/ValuesVersionSummary/index.js +0 -3
- package/dist/components/RecordEdition/EditRecord/ValuesVersionSummary/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecord/index.js +0 -3
- package/dist/components/RecordEdition/EditRecord/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordBtn/EditRecordBtn.js +0 -3
- package/dist/components/RecordEdition/EditRecordBtn/EditRecordBtn.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordBtn/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordBtn/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordButtons/EditRecordButtons.js +0 -3
- package/dist/components/RecordEdition/EditRecordButtons/EditRecordButtons.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordButtons/SidebarButton.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordButtons/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordButtons/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/_types.d.ts +0 -1
- package/dist/components/RecordEdition/EditRecordContent/_types.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/antdUtils.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/formConstants.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/formConstants.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/helpers/extractFormElements/extractFormElements.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/helpers/extractFormElements/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/helpers/extractFormElements/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/__mocks__/useDeleteValueMutation.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/hooks/__mocks__/useDeleteValueMutation.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/__mocks__/useSaveValueMutation.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/hooks/__mocks__/useSaveValueMutation.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/helpers/getPropertyCacheFieldName.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/hooks/helpers/getPropertyCacheFieldName.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/useExecuteDeleteValueMutation.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/useExecuteSaveValueBatchMutation.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/useRecordEditionContext.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/hooks/useRecordEditionContext.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/ErrorField/ErrorField.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/ErrorField/ErrorField.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/ErrorField/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/ErrorField/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/FormDivider/FormDivider.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/FormDivider/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/FormDivider/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/FormTabs/FormTabs.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/FormTabs/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/FormTabs/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Frame/Frame.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Frame/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Frame/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/LinkField.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/_types.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/explorer/LinkFieldExplorer.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/explorer/LinkFieldExplorer.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/explorer/link-record/useExplorerLinkRecords.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/explorer/link-record/useLinkRecords.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/explorer/link-record/useLinkRecords.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/shared/InputExtraAlignLeft.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/shared/InputExtraAlignLeft.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/shared/InputWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/shared/InputWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/shared/Wrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/shared/Wrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/tag/LinkFieldTags.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/tag/LinkFieldTags.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/tag/link-record/useLinkRecord.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/tag/link-record/useLinkRecord.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/tag/unlink-record/useUnlinkRecord.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/tag/unlink-record/useUnlinkRecord.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/unlink-all-records/useUnlinkAllRecords.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/DSListSelect.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/DSListSelect.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/_types.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TextBlock/TextBlock.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TextBlock/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TextBlock/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/TreeField.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/TreeField.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/display-tree-node/TreeFieldWrapper.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/display-tree-node/TreeFieldWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/display-tree-node/TreeNodeItem.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/display-tree-node/TreeNodeList.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/manage-tree-node-selection/SelectTreeNodeModal.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/manage-tree-node-selection/SelectTreeNodeModal.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/manage-tree-node-selection/useManageTreeNodeSelection.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/manage-tree-node-selection/useManageTreeNodeSelection.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/shared/ComputeIndicator.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/shared/DeleteAllValuesButton.js +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/shared/DeleteAllValuesButton.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/shared/calculatedInheritedFlags.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/shared/useOutsideInteractionDetector.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordModal/EditRecordModal.js +2 -5
- package/dist/components/RecordEdition/EditRecordModal/EditRecordModal.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordModal/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordModal/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordModal/useEditRecordModal.js +0 -3
- package/dist/components/RecordEdition/EditRecordModal/useEditRecordModal.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.js +2 -5
- package/dist/components/RecordEdition/EditRecordPage/EditRecordPage.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordPage/ErrorComponent.js +0 -3
- package/dist/components/RecordEdition/EditRecordPage/ErrorComponent.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordPage/getInitialRecordValues.js +0 -3
- package/dist/components/RecordEdition/EditRecordPage/getInitialRecordValues.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordPage/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordPage/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/AttributeSummary.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/useAttributeInformations.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/AttributeSummary/useAttributeInformations.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/Breadcrumb.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/Breadcrumb.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/Breacrumb/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/EditRecordSidebar.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/PropertiesList.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/PropertiesList/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/RecordInformations.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/useRecordInformations.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordInformations/useRecordInformations.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/RecordSummary.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/RecordSummary/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/ValuesSummary.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesSummary/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesVersions/ValuesVersions.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesVersions/ValuesVersions.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesVersions/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/ValuesVersions/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSidebar/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSidebar/index.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSkeleton/EditRecordSkeleton.js +0 -3
- package/dist/components/RecordEdition/EditRecordSkeleton/EditRecordSkeleton.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordSkeleton/index.js +0 -3
- package/dist/components/RecordEdition/EditRecordSkeleton/index.js.map +1 -1
- package/dist/components/RecordEdition/_types.js.map +1 -1
- package/dist/components/RecordEdition/constants.js +0 -3
- package/dist/components/RecordEdition/constants.js.map +1 -1
- package/dist/components/RecordEdition/editRecordReducer/editRecordReducer.js.map +1 -1
- package/dist/components/RecordEdition/editRecordReducer/editRecordReducerContext.js +0 -3
- package/dist/components/RecordEdition/editRecordReducer/editRecordReducerContext.js.map +1 -1
- package/dist/components/RecordEdition/editRecordReducer/index.js +0 -3
- package/dist/components/RecordEdition/editRecordReducer/index.js.map +1 -1
- package/dist/components/RecordEdition/editRecordReducer/useEditRecordReducer.js +0 -3
- package/dist/components/RecordEdition/editRecordReducer/useEditRecordReducer.js.map +1 -1
- package/dist/components/RecordEdition/hooks/useCreateCancelConfirm/index.js +0 -3
- package/dist/components/RecordEdition/hooks/useCreateCancelConfirm/index.js.map +1 -1
- package/dist/components/RecordEdition/hooks/useCreateCancelConfirm/useCreateCancelConfirm.js +0 -3
- package/dist/components/RecordEdition/hooks/useCreateCancelConfirm/useCreateCancelConfirm.js.map +1 -1
- package/dist/components/RecordEdition/hooks/useGetSubmitButtons.js +0 -3
- package/dist/components/RecordEdition/hooks/useGetSubmitButtons.js.map +1 -1
- package/dist/components/RecordEdition/index.d.ts +0 -1
- package/dist/components/RecordEdition/index.js +0 -4
- package/dist/components/RecordEdition/index.js.map +1 -1
- package/dist/components/RecordHistory/RecordHistory.js +0 -3
- package/dist/components/RecordHistory/RecordHistory.js.map +1 -1
- package/dist/components/RecordHistory/RecordHistoryGoUpButton.js +0 -3
- package/dist/components/RecordHistory/RecordHistoryGoUpButton.js.map +1 -1
- package/dist/components/RecordHistory/RecordHistoryLogEntry.js +0 -3
- package/dist/components/RecordHistory/RecordHistoryLogEntry.js.map +1 -1
- package/dist/components/RecordHistory/_queries/recordHistoryQuery.js +0 -3
- package/dist/components/RecordHistory/_queries/recordHistoryQuery.js.map +1 -1
- package/dist/components/RecordHistory/_types.js.map +1 -1
- package/dist/components/RecordHistory/hooks/useFetchRecordHistory.js +0 -3
- package/dist/components/RecordHistory/hooks/useFetchRecordHistory.js.map +1 -1
- package/dist/components/RecordHistory/index.js +0 -3
- package/dist/components/RecordHistory/index.js.map +1 -1
- package/dist/components/RecordHistory/utils/extendedAttribute.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModal.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModal.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/AudioFile/AudioFile.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/AudioFile/AudioFile.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/AudioFile/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/AudioFile/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/DocumentFile/DocumentFile.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/DocumentFile/DocumentFile.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/DocumentFile/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/DocumentFile/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalContent.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalContent.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalSidebar/FileModalSidebar.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalSidebar/FileModalSidebar.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalSidebar/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/FileModalSidebar/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/ImageFile/ImageFile.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/ImageFile/ImageFile.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/ImageFile/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/ImageFile/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/NoDisplayFile/NoDisplayFile.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/NoDisplayFile/NoDisplayFile.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/NoDisplayFile/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/NoDisplayFile/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/VideoFile/VideoFile.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/VideoFile/VideoFile.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/VideoFile/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/VideoFile/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/_types.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/FileModalContent/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/_constants.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/_constants.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/FileModal/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/FileModal/index.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/RecordPreviewWithModal.js +0 -3
- package/dist/components/RecordPreviewWithModal/RecordPreviewWithModal.js.map +1 -1
- package/dist/components/RecordPreviewWithModal/index.js +0 -3
- package/dist/components/RecordPreviewWithModal/index.js.map +1 -1
- package/dist/components/SearchModal/SearchModal.js.map +1 -1
- package/dist/components/SearchModal/index.js +0 -3
- package/dist/components/SearchModal/index.js.map +1 -1
- package/dist/components/SelectRecordForLinkModal/SelectRecordForLinkModal.js +0 -3
- package/dist/components/SelectRecordForLinkModal/SelectRecordForLinkModal.js.map +1 -1
- package/dist/components/SelectRecordForLinkModal/index.js +0 -3
- package/dist/components/SelectRecordForLinkModal/index.js.map +1 -1
- package/dist/components/SelectTreeNode/SelectTreeNode.js +0 -3
- package/dist/components/SelectTreeNode/SelectTreeNode.js.map +1 -1
- package/dist/components/SelectTreeNode/SelectTreeNodeContent.js +0 -3
- package/dist/components/SelectTreeNode/SelectTreeNodeContent.js.map +1 -1
- package/dist/components/SelectTreeNode/SelectTreeNodeContentSkeleton.js.map +1 -1
- package/dist/components/SelectTreeNode/TreeNodeTitle.js +0 -3
- package/dist/components/SelectTreeNode/TreeNodeTitle.js.map +1 -1
- package/dist/components/SelectTreeNode/_queries/treeContentDataQuery.js +0 -3
- package/dist/components/SelectTreeNode/_queries/treeContentDataQuery.js.map +1 -1
- package/dist/components/SelectTreeNode/_types.js.map +1 -1
- package/dist/components/SelectTreeNode/index.js +0 -3
- package/dist/components/SelectTreeNode/index.js.map +1 -1
- package/dist/components/SelectTreeNodeModalOld/SelectTreeNodeModalOld.js +0 -3
- package/dist/components/SelectTreeNodeModalOld/SelectTreeNodeModalOld.js.map +1 -1
- package/dist/components/SelectTreeNodeModalOld/index.js +0 -3
- package/dist/components/SelectTreeNodeModalOld/index.js.map +1 -1
- package/dist/components/ShowMore/ShowMore.js +0 -3
- package/dist/components/ShowMore/ShowMore.js.map +1 -1
- package/dist/components/ShowMore/index.js +0 -3
- package/dist/components/ShowMore/index.js.map +1 -1
- package/dist/components/SimpleErrorBoundary/SimpleErrorBoundary.js +0 -3
- package/dist/components/SimpleErrorBoundary/SimpleErrorBoundary.js.map +1 -1
- package/dist/components/SimpleErrorBoundary/SimpleErrorBoundaryContent/SimpleErrorBoundaryContent.js +0 -3
- package/dist/components/SimpleErrorBoundary/SimpleErrorBoundaryContent/SimpleErrorBoundaryContent.js.map +1 -1
- package/dist/components/SimpleErrorBoundary/SimpleErrorBoundaryContent/index.js +0 -3
- package/dist/components/SimpleErrorBoundary/SimpleErrorBoundaryContent/index.js.map +1 -1
- package/dist/components/SimpleErrorBoundary/index.js +0 -3
- package/dist/components/SimpleErrorBoundary/index.js.map +1 -1
- package/dist/components/SubmitStateNotifier/SubmitStateNotifier.js +0 -3
- package/dist/components/SubmitStateNotifier/SubmitStateNotifier.js.map +1 -1
- package/dist/components/SubmitStateNotifier/_types.js.map +1 -1
- package/dist/components/SubmitStateNotifier/index.js +0 -3
- package/dist/components/SubmitStateNotifier/index.js.map +1 -1
- package/dist/components/TreePicker/TreePicker.js +0 -3
- package/dist/components/TreePicker/TreePicker.js.map +1 -1
- package/dist/components/TreePicker/TreesList/TreesList.js +0 -3
- package/dist/components/TreePicker/TreesList/TreesList.js.map +1 -1
- package/dist/components/TreePicker/TreesList/index.js +0 -3
- package/dist/components/TreePicker/TreesList/index.js.map +1 -1
- package/dist/components/TreePicker/index.js +0 -3
- package/dist/components/TreePicker/index.js.map +1 -1
- package/dist/components/TriggerPreviewsGenerationModal/TriggerPreviewsGenerationModal.js +0 -3
- package/dist/components/TriggerPreviewsGenerationModal/TriggerPreviewsGenerationModal.js.map +1 -1
- package/dist/components/TriggerPreviewsGenerationModal/index.js +0 -3
- package/dist/components/TriggerPreviewsGenerationModal/index.js.map +1 -1
- package/dist/components/UploadFiles/UploadFiles.js +0 -3
- package/dist/components/UploadFiles/UploadFiles.js.map +1 -1
- package/dist/components/UploadFiles/index.js +0 -3
- package/dist/components/UploadFiles/index.js.map +1 -1
- package/dist/components/ValuesVersionConfigurator/ValuesVersionConfigurator.js +0 -3
- package/dist/components/ValuesVersionConfigurator/ValuesVersionConfigurator.js.map +1 -1
- package/dist/components/ValuesVersionConfigurator/VersionTree/VersionTree.js +0 -3
- package/dist/components/ValuesVersionConfigurator/VersionTree/VersionTree.js.map +1 -1
- package/dist/components/ValuesVersionConfigurator/VersionTree/index.js +0 -3
- package/dist/components/ValuesVersionConfigurator/VersionTree/index.js.map +1 -1
- package/dist/components/ValuesVersionConfigurator/index.js +0 -3
- package/dist/components/ValuesVersionConfigurator/index.js.map +1 -1
- package/dist/components/index.js +0 -3
- package/dist/components/index.js.map +1 -1
- package/dist/constants.js +0 -3
- package/dist/constants.js.map +1 -1
- package/dist/contexts/EditRecordModalContext/EditRecordModalContext.js.map +1 -1
- package/dist/contexts/EditRecordModalContext/EditRecordModalProvider.js +0 -3
- package/dist/contexts/EditRecordModalContext/EditRecordModalProvider.js.map +1 -1
- package/dist/contexts/EditRecordModalContext/index.js +0 -3
- package/dist/contexts/EditRecordModalContext/index.js.map +1 -1
- package/dist/contexts/EditRecordModalContext/useEditRecordModalContext.js +0 -3
- package/dist/contexts/EditRecordModalContext/useEditRecordModalContext.js.map +1 -1
- package/dist/contexts/LangContext/LangContext.js +0 -3
- package/dist/contexts/LangContext/LangContext.js.map +1 -1
- package/dist/contexts/LangContext/index.js +0 -3
- package/dist/contexts/LangContext/index.js.map +1 -1
- package/dist/contexts/LangContext/types.js.map +1 -1
- package/dist/contexts/UserContext/UserContext.js +0 -3
- package/dist/contexts/UserContext/UserContext.js.map +1 -1
- package/dist/contexts/UserContext/index.js +0 -3
- package/dist/contexts/UserContext/index.js.map +1 -1
- package/dist/contexts/UserContext/types.js.map +1 -1
- package/dist/contexts/index.js +0 -3
- package/dist/contexts/index.js.map +1 -1
- package/dist/gqlFragments/index.js +0 -3
- package/dist/gqlFragments/index.js.map +1 -1
- package/dist/gqlFragments/recordIdentityFragment.js +0 -3
- package/dist/gqlFragments/recordIdentityFragment.js.map +1 -1
- package/dist/gqlPossibleTypes/index.js.map +1 -1
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/index.js +1 -3
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/useAntdLocale/index.js +0 -3
- package/dist/hooks/useAntdLocale/index.js.map +1 -1
- package/dist/hooks/useAntdLocale/useAntdLocale.js.map +1 -1
- package/dist/hooks/useAppLang/index.js +0 -3
- package/dist/hooks/useAppLang/index.js.map +1 -1
- package/dist/hooks/useAppLang/useAppLang.js +0 -3
- package/dist/hooks/useAppLang/useAppLang.js.map +1 -1
- package/dist/hooks/useAuth/index.js +0 -3
- package/dist/hooks/useAuth/index.js.map +1 -1
- package/dist/hooks/useAuth/useAuth.js +0 -3
- package/dist/hooks/useAuth/useAuth.js.map +1 -1
- package/dist/hooks/useCanEditRecord/index.js +0 -3
- package/dist/hooks/useCanEditRecord/index.js.map +1 -1
- package/dist/hooks/useCanEditRecord/useCanEditRecord.js +0 -3
- package/dist/hooks/useCanEditRecord/useCanEditRecord.js.map +1 -1
- package/dist/hooks/useConfirmModal/__mocks__/index.js +0 -3
- package/dist/hooks/useConfirmModal/__mocks__/index.js.map +1 -1
- package/dist/hooks/useConfirmModal/__mocks__/useConfirmModal.js +0 -3
- package/dist/hooks/useConfirmModal/__mocks__/useConfirmModal.js.map +1 -1
- package/dist/hooks/useConfirmModal/index.js +0 -3
- package/dist/hooks/useConfirmModal/index.js.map +1 -1
- package/dist/hooks/useConfirmModal/useConfirmModal.js +0 -3
- package/dist/hooks/useConfirmModal/useConfirmModal.js.map +1 -1
- package/dist/hooks/useDebouncedValue/index.js +0 -3
- package/dist/hooks/useDebouncedValue/index.js.map +1 -1
- package/dist/hooks/useDebouncedValue/useDebouncedValue.js +0 -3
- package/dist/hooks/useDebouncedValue/useDebouncedValue.js.map +1 -1
- package/dist/hooks/useDelayedLoading/index.d.ts +1 -0
- package/dist/hooks/useDelayedLoading/index.js +2 -0
- package/dist/hooks/useDelayedLoading/index.js.map +1 -0
- package/dist/hooks/useDelayedLoading/useDelayedLoading.d.ts +17 -0
- package/dist/hooks/useDelayedLoading/useDelayedLoading.js +51 -0
- package/dist/hooks/useDelayedLoading/useDelayedLoading.js.map +1 -0
- package/dist/hooks/useExecuteDeleteViewMutation/useExecuteDeleteViewMutation.js.map +1 -1
- package/dist/hooks/useExecuteSaveViewMutation/index.js +0 -3
- package/dist/hooks/useExecuteSaveViewMutation/index.js.map +1 -1
- package/dist/hooks/useExecuteSaveViewMutation/useExecuteSaveViewMutation.js.map +1 -1
- package/dist/hooks/useGetLibraryDetailExtendedQuery/useGetLibraryDetailExtendedQuery.js +0 -3
- package/dist/hooks/useGetLibraryDetailExtendedQuery/useGetLibraryDetailExtendedQuery.js.map +1 -1
- package/dist/hooks/useGetPreparedFileData/useGetPreparedFileData.js +0 -3
- package/dist/hooks/useGetPreparedFileData/useGetPreparedFileData.js.map +1 -1
- package/dist/hooks/useGetRecordForm/index.js +0 -3
- package/dist/hooks/useGetRecordForm/index.js.map +1 -1
- package/dist/hooks/useGetRecordForm/useGetRecordForm.js.map +1 -1
- package/dist/hooks/useGetRecordIdCard/index.js +0 -3
- package/dist/hooks/useGetRecordIdCard/index.js.map +1 -1
- package/dist/hooks/useGetRecordIdCard/useGetRecordIdCard.js +0 -3
- package/dist/hooks/useGetRecordIdCard/useGetRecordIdCard.js.map +1 -1
- package/dist/hooks/useGetRecordUpdatesSubscription/index.js +0 -3
- package/dist/hooks/useGetRecordUpdatesSubscription/index.js.map +1 -1
- package/dist/hooks/useGetRecordUpdatesSubscription/useGetRecordUpdatesSubscription.js +0 -3
- package/dist/hooks/useGetRecordUpdatesSubscription/useGetRecordUpdatesSubscription.js.map +1 -1
- package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.js +0 -3
- package/dist/hooks/useGetRecordValuesQuery/useGetRecordValuesQuery.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/iFrameMessengerContext.d.ts +3 -1
- package/dist/hooks/useIFrameMessenger/iFrameMessengerContext.js +0 -3
- package/dist/hooks/useIFrameMessenger/iFrameMessengerContext.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/messageHandlers.d.ts +2 -1
- package/dist/hooks/useIFrameMessenger/messageHandlers.js +9 -0
- package/dist/hooks/useIFrameMessenger/messageHandlers.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/schema.js +0 -3
- package/dist/hooks/useIFrameMessenger/schema.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/types.d.ts +21 -2
- package/dist/hooks/useIFrameMessenger/types.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/useIFrameMessenger.d.ts +1 -0
- package/dist/hooks/useIFrameMessenger/useIFrameMessenger.js +0 -3
- package/dist/hooks/useIFrameMessenger/useIFrameMessenger.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/useIFrameMessengerContext.js +29 -10
- package/dist/hooks/useIFrameMessenger/useIFrameMessengerContext.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/useIFrameMessengerHandlers.js +0 -3
- package/dist/hooks/useIFrameMessenger/useIFrameMessengerHandlers.js.map +1 -1
- package/dist/hooks/useIFrameMessenger/useNativePanelMessengerHandlers.d.ts +14 -0
- package/dist/hooks/useIFrameMessenger/useNativePanelMessengerHandlers.js +19 -0
- package/dist/hooks/useIFrameMessenger/useNativePanelMessengerHandlers.js.map +1 -0
- package/dist/hooks/useIFrameMessengerClient/IFrameMessengerClient.js +0 -3
- package/dist/hooks/useIFrameMessengerClient/IFrameMessengerClient.js.map +1 -1
- package/dist/hooks/useIFrameMessengerClient/iFrameMessengerClientContext.d.ts +1 -0
- package/dist/hooks/useIFrameMessengerClient/iFrameMessengerClientContext.js +0 -3
- package/dist/hooks/useIFrameMessengerClient/iFrameMessengerClientContext.js.map +1 -1
- package/dist/hooks/useIFrameMessengerClient/useIFrameMessengerClient.d.ts +1 -0
- package/dist/hooks/useIFrameMessengerClient/useIFrameMessengerClient.js +0 -3
- package/dist/hooks/useIFrameMessengerClient/useIFrameMessengerClient.js.map +1 -1
- package/dist/hooks/useLang/__mocks__/index.js +0 -3
- package/dist/hooks/useLang/__mocks__/index.js.map +1 -1
- package/dist/hooks/useLang/__mocks__/useLang.js +0 -3
- package/dist/hooks/useLang/__mocks__/useLang.js.map +1 -1
- package/dist/hooks/useLang/index.js +0 -3
- package/dist/hooks/useLang/index.js.map +1 -1
- package/dist/hooks/useLang/useLang.js +0 -3
- package/dist/hooks/useLang/useLang.js.map +1 -1
- package/dist/hooks/useLibraryVersionTrees/index.js +0 -3
- package/dist/hooks/useLibraryVersionTrees/index.js.map +1 -1
- package/dist/hooks/useLibraryVersionTrees/useLibraryVersionTrees.js.map +1 -1
- package/dist/hooks/useLocalStorage/index.js +0 -3
- package/dist/hooks/useLocalStorage/index.js.map +1 -1
- package/dist/hooks/useLocalStorage/useLocalStorage.js +0 -3
- package/dist/hooks/useLocalStorage/useLocalStorage.js.map +1 -1
- package/dist/hooks/useLoginChecker/index.js +0 -3
- package/dist/hooks/useLoginChecker/index.js.map +1 -1
- package/dist/hooks/useLoginChecker/useLoginChecker.js +0 -3
- package/dist/hooks/useLoginChecker/useLoginChecker.js.map +1 -1
- package/dist/hooks/useRecordsConsultationHistory/index.js +0 -3
- package/dist/hooks/useRecordsConsultationHistory/index.js.map +1 -1
- package/dist/hooks/useRecordsConsultationHistory/useRecordsConsultationHistory.js +0 -3
- package/dist/hooks/useRecordsConsultationHistory/useRecordsConsultationHistory.js.map +1 -1
- package/dist/hooks/useRedirectToLogin/index.js +0 -3
- package/dist/hooks/useRedirectToLogin/index.js.map +1 -1
- package/dist/hooks/useRedirectToLogin/useRedirectToLogin.js +0 -3
- package/dist/hooks/useRedirectToLogin/useRedirectToLogin.js.map +1 -1
- package/dist/hooks/useRefreshFieldValues/index.js +0 -3
- package/dist/hooks/useRefreshFieldValues/index.js.map +1 -1
- package/dist/hooks/useRefreshFieldValues/useRefreshFieldValues.js +0 -3
- package/dist/hooks/useRefreshFieldValues/useRefreshFieldValues.js.map +1 -1
- package/dist/hooks/useSharedTranslation/__mocks__/index.js +0 -3
- package/dist/hooks/useSharedTranslation/__mocks__/index.js.map +1 -1
- package/dist/hooks/useSharedTranslation/__mocks__/useSharedTranslation.js.map +1 -1
- package/dist/hooks/useSharedTranslation/index.js +0 -3
- package/dist/hooks/useSharedTranslation/index.js.map +1 -1
- package/dist/hooks/useSharedTranslation/useSharedTranslation.js +0 -3
- package/dist/hooks/useSharedTranslation/useSharedTranslation.js.map +1 -1
- package/dist/hooks/useUser/index.js +0 -3
- package/dist/hooks/useUser/index.js.map +1 -1
- package/dist/hooks/useUser/useUser.js +0 -3
- package/dist/hooks/useUser/useUser.js.map +1 -1
- package/dist/hooks/useValuesCacheUpdate/index.js +0 -3
- package/dist/hooks/useValuesCacheUpdate/index.js.map +1 -1
- package/dist/hooks/useValuesCacheUpdate/useValuesCacheUpdate.js +0 -3
- package/dist/hooks/useValuesCacheUpdate/useValuesCacheUpdate.js.map +1 -1
- package/dist/index.js +0 -3
- package/dist/index.js.map +1 -1
- package/dist/locales/en/shared.json +5 -1
- package/dist/locales/fr/shared.json +5 -1
- package/dist/testing/MockedLangContextProvider/MockedLangContextProvider.js +0 -3
- package/dist/testing/MockedLangContextProvider/MockedLangContextProvider.js.map +1 -1
- package/dist/testing/MockedLangContextProvider/index.js +0 -3
- package/dist/testing/MockedLangContextProvider/index.js.map +1 -1
- package/dist/testing/MockedUserContextProvider/MockedUserContextProvider.js +0 -3
- package/dist/testing/MockedUserContextProvider/MockedUserContextProvider.js.map +1 -1
- package/dist/testing/MockedUserContextProvider/index.js +0 -3
- package/dist/testing/MockedUserContextProvider/index.js.map +1 -1
- package/dist/testing/index.js +0 -3
- package/dist/testing/index.js.map +1 -1
- package/dist/types/attributes.js.map +1 -1
- package/dist/types/index.js +0 -3
- package/dist/types/index.js.map +1 -1
- package/dist/types/misc.js.map +1 -1
- package/dist/types/records.js.map +1 -1
- package/dist/types/scalars.js.map +1 -1
- package/dist/types/search.js.map +1 -1
- package/dist/types/trees.js.map +1 -1
- package/dist/types/values.js.map +1 -1
- package/dist/types/views.js.map +1 -1
- package/package.json +8 -13
- package/dist/components/Explorer/actions-mass/edit-attribute/useTreeNodeRemapping.d.ts +0 -12
- package/dist/components/Explorer/actions-mass/edit-attribute/useTreeNodeRemapping.js +0 -24
- package/dist/components/Explorer/actions-mass/edit-attribute/useTreeNodeRemapping.js.map +0 -1
- package/dist/components/Explorer/actions-mass/edit-attribute/useValuesDistribution.d.ts +0 -13
- package/dist/components/Explorer/actions-mass/edit-attribute/useValuesDistribution.js +0 -28
- package/dist/components/Explorer/actions-mass/edit-attribute/useValuesDistribution.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/hooks/useCreateEmptyRecordMutation.d.ts +0 -5
- package/dist/components/RecordEdition/EditRecordContent/hooks/useCreateEmptyRecordMutation.js +0 -20
- package/dist/components/RecordEdition/EditRecordContent/hooks/useCreateEmptyRecordMutation.js.map +0 -1
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { gql } from '@apollo/client';
|
|
5
2
|
const deleteViewMutation = gql `
|
|
6
3
|
mutation DELETE_VIEW($viewId: String!) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deleteViewMutation.js","sourceRoot":"","sources":["../../../src/_queries/views/deleteViewMutation.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"deleteViewMutation.js","sourceRoot":"","sources":["../../../src/_queries/views/deleteViewMutation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,GAAG,EAAC,MAAM,gBAAgB,CAAC;AAUnC,MAAM,kBAAkB,GAAG,GAAG,CAAA;;;;;;;CAO7B,CAAC;AAEF,eAAe,kBAAkB,CAAC","sourcesContent":["import {gql} from '@apollo/client';\n\nexport interface IDeleteViewMutation {\n id: string;\n}\n\nexport interface IDeleteViewMutationVariables {\n viewId: string;\n}\n\nconst deleteViewMutation = gql`\n mutation DELETE_VIEW($viewId: String!) {\n deleteView(viewId: $viewId) {\n id\n library\n }\n }\n`;\n\nexport default deleteViewMutation;\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { gql } from '@apollo/client';
|
|
5
2
|
import { recordIdentityFragment } from '../../gqlFragments/recordIdentityFragment';
|
|
6
3
|
import viewDetailsFragment from './viewDetailsFragment';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getViewById.js","sourceRoot":"","sources":["../../../src/_queries/views/getViewById.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"getViewById.js","sourceRoot":"","sources":["../../../src/_queries/views/getViewById.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,GAAG,EAAC,MAAM,gBAAgB,CAAC;AACnC,OAAO,EAAC,sBAAsB,EAAC,MAAM,yCAAyC,CAAC;AAC/E,OAAO,mBAAmB,MAAM,uBAAuB,CAAC;AAExD,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,CAAA;MAC7B,sBAAsB;MACtB,mBAAmB;;;;;;CAMxB,CAAC","sourcesContent":["import {gql} from '@apollo/client';\nimport {recordIdentityFragment} from '_ui/gqlFragments/recordIdentityFragment';\nimport viewDetailsFragment from './viewDetailsFragment';\n\nexport const getViewByIdQuery = gql`\n ${recordIdentityFragment}\n ${viewDetailsFragment}\n query GET_VIEW($viewId: String!) {\n view(viewId: $viewId) {\n ...ViewDetails\n }\n }\n`;\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { gql } from '@apollo/client';
|
|
5
2
|
import viewDetailsFragment from './viewDetailsFragment';
|
|
6
3
|
export const getViewsListQuery = gql `
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getViewsListQuery.js","sourceRoot":"","sources":["../../../src/_queries/views/getViewsListQuery.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"getViewsListQuery.js","sourceRoot":"","sources":["../../../src/_queries/views/getViewsListQuery.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,GAAG,EAAC,MAAM,gBAAgB,CAAC;AACnC,OAAO,mBAAmB,MAAM,uBAAuB,CAAC;AAExD,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,CAAA;MAC9B,mBAAmB;;;;;;;;;CASxB,CAAC","sourcesContent":["import {gql} from '@apollo/client';\nimport viewDetailsFragment from './viewDetailsFragment';\n\nexport const getViewsListQuery = gql`\n ${viewDetailsFragment}\n query GET_VIEWS_LIST($libraryId: String!) {\n views(library: $libraryId) {\n totalCount\n list {\n ...ViewDetails\n }\n }\n }\n`;\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { gql } from '@apollo/client';
|
|
5
2
|
import viewDetailsFragment from './viewDetailsFragment';
|
|
6
3
|
const saveViewMutation = gql `
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"saveViewMutation.js","sourceRoot":"","sources":["../../../src/_queries/views/saveViewMutation.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"saveViewMutation.js","sourceRoot":"","sources":["../../../src/_queries/views/saveViewMutation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,GAAG,EAAC,MAAM,gBAAgB,CAAC;AACnC,OAAO,mBAAmB,MAAM,uBAAuB,CAAC;AAExD,MAAM,gBAAgB,GAAG,GAAG,CAAA;MACtB,mBAAmB;;;;;;CAMxB,CAAC;AAEF,eAAe,gBAAgB,CAAC","sourcesContent":["import {gql} from '@apollo/client';\nimport viewDetailsFragment from './viewDetailsFragment';\n\nconst saveViewMutation = gql`\n ${viewDetailsFragment}\n mutation SAVE_VIEW($view: ViewInput!) {\n saveView(view: $view) {\n ...ViewDetails\n }\n }\n`;\n\nexport default saveViewMutation;\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { gql } from '@apollo/client';
|
|
5
2
|
import { recordIdentityFragment } from '../../gqlFragments';
|
|
6
3
|
const viewDetailsFragment = gql `
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"viewDetailsFragment.js","sourceRoot":"","sources":["../../../src/_queries/views/viewDetailsFragment.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"viewDetailsFragment.js","sourceRoot":"","sources":["../../../src/_queries/views/viewDetailsFragment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,GAAG,EAAC,MAAM,gBAAgB,CAAC;AACnC,OAAO,EAAC,sBAAsB,EAAC,MAAM,kBAAkB,CAAC;AAExD,MAAM,mBAAmB,GAAG,GAAG,CAAA;MACzB,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqD3B,CAAC;AAEF,eAAe,mBAAmB,CAAC","sourcesContent":["import {gql} from '@apollo/client';\nimport {recordIdentityFragment} from '_ui/gqlFragments';\n\nconst viewDetailsFragment = gql`\n ${recordIdentityFragment}\n fragment ViewDetailsFilter on RecordFilter {\n field\n value\n tree {\n id\n label\n }\n condition\n operator\n withEmptyValues\n }\n\n fragment ViewDetails on View {\n id\n display {\n size\n type\n }\n shared\n created_by {\n id\n whoAmI {\n id\n label\n library {\n id\n }\n }\n }\n label\n description\n color\n filters {\n ...ViewDetailsFilter\n }\n sort {\n field\n order\n }\n valuesVersions {\n treeId\n treeNode {\n id\n record {\n ...RecordIdentity\n }\n }\n }\n attributes {\n id\n }\n }\n`;\n\nexport default viewDetailsFragment;\n"]}
|
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export const isDevEnv = () => false;
|
|
5
2
|
//# sourceMappingURL=isDevEnv.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isDevEnv.js","sourceRoot":"","sources":["../../../src/_utils/__mocks__/isDevEnv.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"isDevEnv.js","sourceRoot":"","sources":["../../../src/_utils/__mocks__/isDevEnv.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,QAAQ,GAAG,GAAG,EAAE,CAAC,KAAK,CAAC","sourcesContent":["export const isDevEnv = () => false;\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { AttributeType } from '../_gqlTypes';
|
|
5
2
|
export const isLinkAttribute = (type) => type === AttributeType.simple_link || type === AttributeType.advanced_link;
|
|
6
3
|
export const isTreeAttribute = (type) => type === AttributeType.tree;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"attributeType.js","sourceRoot":"","sources":["../../src/_utils/attributeType.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"attributeType.js","sourceRoot":"","sources":["../../src/_utils/attributeType.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,aAAa,EAAC,MAAM,eAAe,CAAC;AAE5C,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,IAAmB,EAAE,EAAE,CACnD,IAAI,KAAK,aAAa,CAAC,WAAW,IAAI,IAAI,KAAK,aAAa,CAAC,aAAa,CAAC;AAE/E,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,IAAmB,EAAE,EAAE,CAAC,IAAI,KAAK,aAAa,CAAC,IAAI,CAAC;AAEpF,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,IAAmB,EAAE,EAAE,CACvD,IAAI,KAAK,aAAa,CAAC,MAAM,IAAI,IAAI,KAAK,aAAa,CAAC,QAAQ,CAAC","sourcesContent":["import {AttributeType} from '_ui/_gqlTypes';\n\nexport const isLinkAttribute = (type: AttributeType) =>\n type === AttributeType.simple_link || type === AttributeType.advanced_link;\n\nexport const isTreeAttribute = (type: AttributeType) => type === AttributeType.tree;\n\nexport const isStandardAttribute = (type: AttributeType) =>\n type === AttributeType.simple || type === AttributeType.advanced;\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { isTypeLink } from '@leav/utils';
|
|
5
2
|
import { AttributeConditionFilter, FilterType, TreeConditionFilter, } from '../types/search';
|
|
6
3
|
import { AttributeFormat, AttributeType, RecordFilterCondition } from '../_gqlTypes';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getFiltersFromRequest.js","sourceRoot":"","sources":["../../src/_utils/getFiltersFromRequest.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AAEtE,OAAO,EAAC,UAAU,EAAC,MAAM,aAAa,CAAC;AACvC,OAAO,EACH,wBAAwB,EACxB,UAAU,EAMV,mBAAmB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAC,eAAe,EAAE,aAAa,EAAE,qBAAqB,EAAyB,MAAM,eAAe,CAAC;AAE5G,MAAM,uBAAuB,GAAG,CAAC,SAAgC,EAAW,EAAE,CAC1E,SAAS,KAAK,qBAAqB,CAAC,QAAQ;IAC5C,SAAS,KAAK,qBAAqB,CAAC,YAAY;IAChD,SAAS,KAAK,qBAAqB,CAAC,UAAU;IAC9C,SAAS,KAAK,qBAAqB,CAAC,UAAU;IAC9C,SAAS,KAAK,qBAAqB,CAAC,KAAK;IACzC,SAAS,KAAK,qBAAqB,CAAC,QAAQ;IAC5C,SAAS,KAAK,qBAAqB,CAAC,SAAS,CAAC;AAElD,MAAM,CAAC,MAAM,qBAAqB,GAAG,CACjC,YAAiC,EACjC,OAAe,EACf,UAAwB,EACf,EAAE;IACX,IAAI,OAAO,GAAc,EAAE,CAAC;IAE5B,KAAK,MAAM,WAAW,IAAI,YAAY,EAAE,CAAC;QACrC,MAAM,sBAAsB,GAAG,uBAAuB,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC;QAE9E,IAAI,WAAW,CAAC,KAAK,IAA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C,CAAC,CAAC,OAAO;iCAClF,KAAK,IAAI,IAAI;yBACzB,CAAC;oBACN,CAAC;yBAAM,CAAC;wBACJ,oDAAoD;wBACpD,MAAM,eAAe,GAAG,UAAU,CAAC,IAAI,CACnC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,KAAK,SAAS,IAAI,IAAI,CAAC,EAAE,KAAK,mBAAmB,CACxE,CAAC;wBAED,MAA2B,CAAC,SAAS,GAAG,eAAe,CAAC;wBACxD,MAA2B,CAAC,iBAAiB,GAAG;4BAC7C,GAAG,MAAM;4BACT,IAAI,EAAE,UAAU,CAAC,OAAO;4BACxB,OAAO,EAAE;gCACL,EAAE,EAAE,SAAS;gCACb,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,SAAS;oCACvC,CAAC,CAAC,aAAa,CAAC,UAAU,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,EAAE,KAAK,SAAS,CAAC,EAAE,CAAC,CAAC,CAAC;yCAC1E,OAAO,CAAC,KAAK;oCACpB,CAAC,CAAC,IAAI;6BACb;4BACD,eAAe,EAAE,EAAC,GAAG,aAAa,EAAE,MAAM,EAAE,eAAe,CAAC,IAAI,EAAC;yBACpE,CAAC;oBACN,CAAC;gBACL,CAAC;YACL,CAAC;iBAAM,IAAI,WAAW,CAAC,SAAS,IAAI,mBAAmB,EAAE,CAAC;gBACrD,MAAsB,CAAC,IAAI,GAAG,EAAC,EAAE,EAAE,WAAW,CAAC,MAAM,EAAC,CAAC;YAC5D,CAAC;YAED,OAAO,GAAG,CAAC,GAAG,OAAO,EAAE,MAAM,CAAC,CAAC;QACnC,CAAC;IACL,CAAC;IAED,OAAO,OAAO,CAAC;AACnB,CAAC,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\n\nimport {isTypeLink} from '@leav/utils';\nimport {\n AttributeConditionFilter,\n FilterType,\n type IAttribute,\n type IFilter,\n type IFilterAttribute,\n type IFilterLibrary,\n type IFilterTree,\n TreeConditionFilter,\n} from '_ui/types/search';\nimport {AttributeFormat, AttributeType, RecordFilterCondition, type RecordFilterInput} from '_ui/_gqlTypes';\n\nconst _isConditionWithNoValue = (condition: RecordFilterCondition): boolean =>\n condition === RecordFilterCondition.IS_EMPTY ||\n condition === RecordFilterCondition.IS_NOT_EMPTY ||\n condition === RecordFilterCondition.LAST_MONTH ||\n condition === RecordFilterCondition.NEXT_MONTH ||\n condition === RecordFilterCondition.TODAY ||\n condition === RecordFilterCondition.TOMORROW ||\n condition === RecordFilterCondition.YESTERDAY;\n\nexport const getFiltersFromRequest = (\n queryFilters: RecordFilterInput[],\n library: string,\n attributes: IAttribute[],\n): IFilter[] => {\n let filters: IFilter[] = [];\n\n for (const queryFilter of queryFilters) {\n const isConditionWithNoValue = _isConditionWithNoValue(queryFilter.condition);\n\n if (queryFilter.value || isConditionWithNoValue) {\n const splitKey = queryFilter.field.split('.');\n\n const filter: IFilter = {\n type: queryFilter.condition in TreeConditionFilter ? FilterType.TREE : FilterType.ATTRIBUTE,\n index: filters.length,\n key: queryFilter.field,\n value: !isConditionWithNoValue\n ? {\n value:\n queryFilter.condition === AttributeConditionFilter.BETWEEN\n ? String(JSON.parse(queryFilter.value))\n : queryFilter.value,\n }\n : null,\n active: true,\n condition:\n AttributeConditionFilter[queryFilter.condition] || TreeConditionFilter[queryFilter.condition],\n };\n\n // Get root attribute by first key part\n const rootAttribute = attributes.find(attr => attr.library === library && attr.id === splitKey[0]);\n\n if (rootAttribute) {\n if (rootAttribute.type === AttributeType.simple || rootAttribute.type === AttributeType.advanced) {\n (filter as IFilterAttribute).attribute = rootAttribute;\n }\n\n if (isTypeLink(rootAttribute.type)) {\n const [, linkedAttributeId] = splitKey;\n if (linkedAttributeId) {\n const linkedAttribute = attributes.find(\n attr => attr.library === rootAttribute?.linkedLibrary?.id && attr.id === linkedAttributeId,\n );\n\n (filter as IFilterAttribute).attribute = {\n ...linkedAttribute,\n parentAttribute: {...rootAttribute, format: AttributeFormat.text},\n };\n } else {\n (filter as IFilterAttribute).attribute = rootAttribute;\n }\n }\n\n if (rootAttribute.type === AttributeType.tree) {\n const [, libraryId, linkedTreeAttribute] = splitKey;\n\n if (!libraryId && !linkedTreeAttribute) {\n // Only root attribute => search on tree\n (filter as IFilterAttribute).attribute = {\n ...rootAttribute,\n format: AttributeFormat.text,\n };\n } else if (libraryId && !linkedTreeAttribute) {\n // Search on tree library\n filter.type = FilterType.LIBRARY;\n (filter as IFilterLibrary).parentAttribute = {\n ...rootAttribute,\n format: AttributeFormat.text,\n };\n (filter as IFilterLibrary).library = {\n id: libraryId,\n label:\n rootAttribute.linkedTree.libraries.filter(l => l.library.id === libraryId)?.[0].library\n .label ?? null,\n };\n } else {\n // Search on linked attribute through tree attribute\n const linkedAttribute = attributes.find(\n attr => attr.library === libraryId && attr.id === linkedTreeAttribute,\n );\n\n (filter as IFilterAttribute).attribute = linkedAttribute;\n (filter as IFilterAttribute).parentTreeLibrary = {\n ...filter,\n type: FilterType.LIBRARY,\n library: {\n id: libraryId,\n label: rootAttribute?.linkedTree?.libraries\n ? rootAttribute.linkedTree.libraries.filter(l => l.library.id === libraryId)?.[0]\n .library.label\n : null,\n },\n parentAttribute: {...rootAttribute, format: AttributeFormat.text},\n };\n }\n }\n } else if (queryFilter.condition in TreeConditionFilter) {\n (filter as IFilterTree).tree = {id: queryFilter.treeId};\n }\n\n filters = [...filters, filter];\n }\n }\n\n return filters;\n};\n"]}
|
|
1
|
+
{"version":3,"file":"getFiltersFromRequest.js","sourceRoot":"","sources":["../../src/_utils/getFiltersFromRequest.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,aAAa,CAAC;AACvC,OAAO,EACH,wBAAwB,EACxB,UAAU,EAMV,mBAAmB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,O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AC,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,EAAE,KAAK,SAAS,CAAC,EAAE,CAAC,CAAC,CAAC;yCAC1E,OAAO,CAAC,KAAK;oCACpB,CAAC,CAAC,IAAI;6BACb;4BACD,eAAe,EAAE,EAAC,GAAG,aAAa,EAAE,MAAM,EAAE,eAAe,CAAC,IAAI,EAAC;yBACpE,CAAC;oBACN,CAAC;gBACL,CAAC;YACL,CAAC;iBAAM,IAAI,WAAW,CAAC,SAAS,IAAI,mBAAmB,EAAE,CAAC;gBACrD,MAAsB,CAAC,IAAI,GAAG,EAAC,EAAE,EAAE,WAAW,CAAC,MAAM,EAAC,CAAC;YAC5D,CAAC;YAED,OAAO,GAAG,CAAC,GAAG,OAAO,EAAE,MAAM,CAAC,CAAC;QACnC,CAAC;IACL,CAAC;IAED,OAAO,OAAO,CAAC;AACnB,CAAC,CAAC","sourcesContent":["import {isTypeLink} from '@leav/utils';\nimport {\n AttributeConditionFilter,\n FilterType,\n type IAttribute,\n type IFilter,\n type IFilterAttribute,\n type IFilterLibrary,\n type IFilterTree,\n TreeConditionFilter,\n} from '_ui/types/search';\nimport {AttributeFormat, AttributeType, RecordFilterCondition, type RecordFilterInput} from '_ui/_gqlTypes';\n\nconst _isConditionWithNoValue = (condition: RecordFilterCondition): boolean =>\n condition === RecordFilterCondition.IS_EMPTY ||\n condition === RecordFilterCondition.IS_NOT_EMPTY ||\n condition === RecordFilterCondition.LAST_MONTH ||\n condition === RecordFilterCondition.NEXT_MONTH ||\n condition === RecordFilterCondition.TODAY ||\n condition === RecordFilterCondition.TOMORROW ||\n condition === RecordFilterCondition.YESTERDAY;\n\nexport const getFiltersFromRequest = (\n queryFilters: RecordFilterInput[],\n library: string,\n attributes: IAttribute[],\n): IFilter[] => {\n let filters: IFilter[] = [];\n\n for (const queryFilter of queryFilters) {\n const isConditionWithNoValue = _isConditionWithNoValue(queryFilter.condition);\n\n if (queryFilter.value || isConditionWithNoValue) {\n const splitKey = queryFilter.field.split('.');\n\n const filter: IFilter = {\n type: queryFilter.condition in TreeConditionFilter ? FilterType.TREE : FilterType.ATTRIBUTE,\n index: filters.length,\n key: queryFilter.field,\n value: !isConditionWithNoValue\n ? {\n value:\n queryFilter.condition === AttributeConditionFilter.BETWEEN\n ? String(JSON.parse(queryFilter.value))\n : queryFilter.value,\n }\n : null,\n active: true,\n condition:\n AttributeConditionFilter[queryFilter.condition] || TreeConditionFilter[queryFilter.condition],\n };\n\n // Get root attribute by first key part\n const rootAttribute = attributes.find(attr => attr.library === library && attr.id === splitKey[0]);\n\n if (rootAttribute) {\n if (rootAttribute.type === AttributeType.simple || rootAttribute.type === AttributeType.advanced) {\n (filter as IFilterAttribute).attribute = rootAttribute;\n }\n\n if (isTypeLink(rootAttribute.type)) {\n const [, linkedAttributeId] = splitKey;\n if (linkedAttributeId) {\n const linkedAttribute = attributes.find(\n attr => attr.library === rootAttribute?.linkedLibrary?.id && attr.id === linkedAttributeId,\n );\n\n (filter as IFilterAttribute).attribute = {\n ...linkedAttribute,\n parentAttribute: {...rootAttribute, format: AttributeFormat.text},\n };\n } else {\n (filter as IFilterAttribute).attribute = rootAttribute;\n }\n }\n\n if (rootAttribute.type === AttributeType.tree) {\n const [, libraryId, linkedTreeAttribute] = splitKey;\n\n if (!libraryId && !linkedTreeAttribute) {\n // Only root attribute => search on tree\n (filter as IFilterAttribute).attribute = {\n ...rootAttribute,\n format: AttributeFormat.text,\n };\n } else if (libraryId && !linkedTreeAttribute) {\n // Search on tree library\n filter.type = FilterType.LIBRARY;\n (filter as IFilterLibrary).parentAttribute = {\n ...rootAttribute,\n format: AttributeFormat.text,\n };\n (filter as IFilterLibrary).library = {\n id: libraryId,\n label:\n rootAttribute.linkedTree.libraries.filter(l => l.library.id === libraryId)?.[0].library\n .label ?? null,\n };\n } else {\n // Search on linked attribute through tree attribute\n const linkedAttribute = attributes.find(\n attr => attr.library === libraryId && attr.id === linkedTreeAttribute,\n );\n\n (filter as IFilterAttribute).attribute = linkedAttribute;\n (filter as IFilterAttribute).parentTreeLibrary = {\n ...filter,\n type: FilterType.LIBRARY,\n library: {\n id: libraryId,\n label: rootAttribute?.linkedTree?.libraries\n ? rootAttribute.linkedTree.libraries.filter(l => l.library.id === libraryId)?.[0]\n .library.label\n : null,\n },\n parentAttribute: {...rootAttribute, format: AttributeFormat.text},\n };\n }\n }\n } else if (queryFilter.condition in TreeConditionFilter) {\n (filter as IFilterTree).tree = {id: queryFilter.treeId};\n }\n\n filters = [...filters, filter];\n }\n }\n\n return filters;\n};\n"]}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { AttributeConditionFilter, ThroughConditionFilter } from '../types/search';
|
|
5
2
|
import { RecordFilterCondition, RecordFilterOperator } from '../_gqlTypes';
|
|
6
3
|
export const getRequestFromFilters = (filters) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getRequestFromFilter.js","sourceRoot":"","sources":["../../src/_utils/getRequestFromFilter.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"getRequestFromFilter.js","sourceRoot":"","sources":["../../src/_utils/getRequestFromFilter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,wBAAwB,EAAkC,sBAAsB,EAAC,MAAM,kBAAkB,CAAC;AAClH,OAAO,EAAC,qBAAqB,EAA0B,oBAAoB,EAAC,MAAM,eAAe,CAAC;AAElG,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,OAAkB,EAAuB,EAAE;IAC7E,MAAM,YAAY,GAAG,OAAO;SACvB,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC;SACrB,MAAM,CAAC,CAAC,GAAG,EAAE,MAAM,EAAE,EAAE;QACpB,IAAI,WAAW,G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E,CAAC,CAAC,0BAA0B;YAC7C,WAAW,CAAC,IAAI,CAAC,EAAC,QAAQ,EAAE,oBAAoB,CAAC,aAAa,EAAC,CAAC,CAAC;QACrE,CAAC;aAAM,CAAC;YACJ,WAAW,GAAG;gBACV;oBACI,KAAK,EAAE,MAAM,EAAE,SAAS,IAAI,wBAAwB,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI;oBACxE,KAAK,EACD,MAAM,EAAE,SAAS,KAAK,wBAAwB,CAAC,OAAO;wBAClD,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,IAAI,EAAE,CAAC;wBAC5C,CAAC,CAAC,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,QAAQ,EAAE;oBACjD,SAAS,EAAE,qBAAqB,CAAC,MAAM,EAAE,SAAS,CAAC;oBACnD,MAAM,EAAG,MAAsB,CAAC,IAAI,EAAE,EAAE;iBAC3C;aACJ,CAAC;QACN,CAAC;QAED,OAAO,GAAG,CAAC,MAAM,CAAC,GAAG,WAAW,EAAE,EAAC,QAAQ,EAAE,oBAAoB,CAAC,GAAG,EAAC,CAAC,CAAC;IAC5E,CAAC,EAAE,EAAyB,CAAC,CAAC;IAElC,YAAY,CAAC,GAAG,EAAE,CAAC,CAAC,2BAA2B;IAE/C,OAAO,YAAY,CAAC;AACxB,CAAC,CAAC","sourcesContent":["import {AttributeConditionFilter, type IFilter, type IFilterTree, ThroughConditionFilter} from '_ui/types/search';\nimport {RecordFilterCondition, type RecordFilterInput, RecordFilterOperator} from '_ui/_gqlTypes';\n\nexport const getRequestFromFilters = (filters: IFilter[]): RecordFilterInput[] => {\n const queryFilters = filters\n .filter(f => f.active)\n .reduce((acc, filter) => {\n let queryFilter: RecordFilterInput[] = [];\n const conditionToApply =\n filter.condition === ThroughConditionFilter.THROUGH ? AttributeConditionFilter.EQUAL : filter.condition;\n\n if (filter.value === null) {\n queryFilter = [\n {\n field: conditionToApply in AttributeConditionFilter ? filter.key : null,\n condition: RecordFilterCondition[conditionToApply],\n treeId: (filter as IFilterTree).tree?.id,\n },\n ];\n } else if (typeof filter.value.value === 'string' && filter.value.value.match(/\\n/g)) {\n const values = filter.value.value.split('\\n').filter(Boolean);\n\n queryFilter.push({operator: RecordFilterOperator.OPEN_BRACKET});\n\n for (const v of values) {\n queryFilter.push({\n field: conditionToApply in AttributeConditionFilter ? filter.key : null,\n value: v,\n condition: RecordFilterCondition[conditionToApply],\n });\n\n queryFilter.push({operator: RecordFilterOperator.OR});\n }\n\n queryFilter.pop(); // delete last OR operator\n queryFilter.push({operator: RecordFilterOperator.CLOSE_BRACKET});\n } else {\n queryFilter = [\n {\n field: filter?.condition in AttributeConditionFilter ? filter.key : null,\n value:\n filter?.condition === AttributeConditionFilter.BETWEEN\n ? JSON.stringify(filter?.value?.value ?? '')\n : (filter?.value?.value ?? '').toString(),\n condition: RecordFilterCondition[filter?.condition],\n treeId: (filter as IFilterTree).tree?.id,\n },\n ];\n }\n\n return acc.concat(...queryFilter, {operator: RecordFilterOperator.AND});\n }, [] as RecordFilterInput[]);\n\n queryFilters.pop(); // delete last AND operator\n\n return queryFilters;\n};\n"]}
|
package/dist/_utils/index.js
CHANGED
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
import { gql } from '@apollo/client';
|
|
5
2
|
import { isTypeLink, objectToNameValueArray, omit } from '@leav/utils';
|
|
6
3
|
import { PreviewSize } from '../constants';
|
package/dist/_utils/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/_utils/index.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,s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AG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAChC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;IAC/C,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC,EAAE,OAAO,CAAC,CAAC;IAEpC,OAAO,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;AAC/C,CAAC,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport {gql} from '@apollo/client';\nimport {type IDateRangeValue, isTypeLink, objectToNameValueArray, omit, type WithTypename} from '@leav/utils';\nimport {type TFunction} from 'i18next';\nimport {type SyntheticEvent} from 'react';\nimport {PreviewSize} from '_ui/constants';\nimport {type IAttribute} from '_ui/types/search';\nimport {type IValueVersion} from '_ui/types/values';\nimport {type IView} from '_ui/types/views';\nimport {\n AttributeFormat,\n AttributeType,\n type PermissionsActions,\n type RecordFilterInput,\n type RecordIdentityFragment,\n type useIsAllowedQuery,\n type ValueDetailsFragment,\n type ValueVersionInput,\n type ViewDetailsFragment,\n} from '_ui/_gqlTypes';\nimport {getFiltersFromRequest} from './getFiltersFromRequest';\nimport dayjs from 'dayjs';\nimport utc from 'dayjs/plugin/utc';\n\ndayjs.extend(utc);\n\nexport const arrayValueVersionToObject = (version: ValueDetailsFragment['version']): IValueVersion =>\n version?.reduce((acc: IValueVersion, value) => {\n acc[value.treeId] = {\n id: value.treeNode.id,\n label: value.treeNode.record.whoAmI.label,\n };\n\n return acc;\n }, {});\n\nexport const objectValueVersionToArray = (version: IValueVersion): ValueVersionInput[] =>\n version\n ? objectToNameValueArray(version).map(v => ({\n treeId: v.name,\n treeNodeId: v?.value?.id ?? null,\n }))\n : null;\n\nexport const extractPermissionFromQuery = (\n queryResult: ReturnType<typeof useIsAllowedQuery>,\n action: PermissionsActions,\n fallbackPermission = false,\n): boolean =>\n !queryResult.loading && !queryResult.error\n ? (queryResult.data?.isAllowed?.find(permission => permission.name === action)?.allowed ?? fallbackPermission)\n : fallbackPermission;\n\nexport const getPreviewSize = (size?: PreviewSize, simplistic = false) => {\n if (simplistic) {\n return '1.2rem';\n }\n\n switch (size) {\n case PreviewSize.MEDIUM:\n return '3.5rem';\n case PreviewSize.BIG:\n return '6rem';\n case PreviewSize.SMALL:\n return '2.5rem';\n case PreviewSize.TINY:\n return '1.7rem';\n default:\n return '2rem';\n }\n};\n\nexport const setDateToUTCNoon = (date: dayjs.Dayjs): dayjs.Dayjs =>\n date.set('hour', 12).set('minute', 0).set('second', 0).set('millisecond', 0);\n\nexport const getTreeRecordKey = (record: RecordIdentityFragment): string => `${record.whoAmI.library.id}/${record.id}`;\n\nexport const stringifyDateRangeValue = (value: IDateRangeValue, t: TFunction): string =>\n t('record_edition.date_range_value', {\n ...value,\n interpolation: {escapeValue: false},\n });\n\n/**\n * Cloning gql template tag because some apollo tools like query validation and codegen won't be happy if we use\n * interpolation in template strings. With a different tag name, the query won't be parsed by these tools\n * thus they won't complain about it.\n * It works exactly the same at runtime.\n */\nexport const gqlUnchecked = gql;\n\nexport const getPropertyCacheFieldName = (attributeId: string): string => `property({\"attribute\":\"${attributeId}\"})`;\n\n/**\n * Prepare view coming from the server to be used in the app\n */\nexport const prepareView = (\n view: WithTypename<ViewDetailsFragment>,\n attributes: IAttribute[],\n libraryId: string,\n userId: string,\n): IView => {\n const viewFilters: RecordFilterInput[] = (view?.filters ?? []).map(filter => ({\n ...filter,\n treeId: filter.tree?.id,\n }));\n\n const viewValuesVersions = (view?.valuesVersions ?? []).map(version => ({\n ...version,\n treeNode: {\n ...version.treeNode,\n title: version.treeNode.record.whoAmI.label,\n },\n }));\n\n return {\n ...omit(view, 'created_by', '__typename'),\n owner: view.created_by.id === userId,\n filters: getFiltersFromRequest(viewFilters, libraryId, attributes),\n sort: (view.sort ?? []).map(s => ({\n field: s.field,\n order: s.order,\n })),\n display: omit(view.display, '__typename') as ViewDetailsFragment['display'],\n valuesVersions: viewValuesVersions.reduce((versions: IValueVersion, version): IValueVersion => {\n versions[version.treeId] = {\n id: version.treeNode.id,\n label: version.treeNode.record.whoAmI.label,\n };\n\n return versions;\n }, {}),\n attributes: (view.attributes ?? []).map(attr => attr.id),\n };\n};\nexport const getAttributeFromKey = (key: string, library: string, attributes: IAttribute[]): IAttribute | undefined => {\n const splitKey = key.split('.');\n\n // Get root attribute by first key part\n const rootAttribute = attributes.find(attr => attr.library === library && attr.id === splitKey[0]);\n\n if (!rootAttribute) {\n return;\n }\n\n if (rootAttribute.type === AttributeType.simple || rootAttribute.type === AttributeType.advanced) {\n return rootAttribute;\n }\n\n if (isTypeLink(rootAttribute.type)) {\n if (splitKey[1]) {\n const linkedAttribute = attributes.find(\n attr => attr.library === rootAttribute?.linkedLibrary?.id && attr.id === splitKey[1],\n );\n\n return {...linkedAttribute, parentAttribute: {...rootAttribute, format: AttributeFormat.text}};\n }\n\n return rootAttribute;\n }\n\n if (rootAttribute.type === AttributeType.tree) {\n const [, libraryId, linkedTreeAttribute] = splitKey;\n\n if (!libraryId && !linkedTreeAttribute) {\n // Only root attribute => search on tree\n return {...rootAttribute, format: AttributeFormat.text};\n } else if (libraryId && !linkedTreeAttribute) {\n return rootAttribute;\n }\n\n const linkedAttribute = attributes.find(attr => attr.library === splitKey[1] && attr.id === splitKey[2]);\n\n return linkedAttribute;\n }\n};\n\nexport const stopEvent = (e: SyntheticEvent) => {\n e.stopPropagation();\n e.preventDefault();\n};\n\nexport const reorder = (list: any[], startIndex: number, endIndex: number) => {\n const result = Array.from(list);\n const [removed] = result.splice(startIndex, 1);\n result.splice(endIndex, 0, removed);\n\n return result.filter(element => !!element);\n};\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/_utils/index.ts"],"names":[],"mappings":"AAAA,OAA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AAI,CAAC,IAAI,CAAC,CAAC;IAChC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;IAC/C,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC,EAAE,OAAO,CAAC,CAAC;IAEpC,OAAO,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;AAC/C,CAAC,CAAC","sourcesContent":["import {gql} from '@apollo/client';\nimport {type IDateRangeValue, isTypeLink, objectToNameValueArray, omit, type WithTypename} from '@leav/utils';\nimport {type TFunction} from 'i18next';\nimport {type SyntheticEvent} from 'react';\nimport {PreviewSize} from '_ui/constants';\nimport {type IAttribute} from '_ui/types/search';\nimport {type IValueVersion} from '_ui/types/values';\nimport {type IView} from '_ui/types/views';\nimport {\n AttributeFormat,\n AttributeType,\n type PermissionsActions,\n type RecordFilterInput,\n type RecordIdentityFragment,\n type useIsAllowedQuery,\n type ValueDetailsFragment,\n type ValueVersionInput,\n type ViewDetailsFragment,\n} from '_ui/_gqlTypes';\nimport {getFiltersFromRequest} from './getFiltersFromRequest';\nimport dayjs from 'dayjs';\nimport utc from 'dayjs/plugin/utc';\n\ndayjs.extend(utc);\n\nexport const arrayValueVersionToObject = (version: ValueDetailsFragment['version']): IValueVersion =>\n version?.reduce((acc: IValueVersion, value) => {\n acc[value.treeId] = {\n id: value.treeNode.id,\n label: value.treeNode.record.whoAmI.label,\n };\n\n return acc;\n }, {});\n\nexport const objectValueVersionToArray = (version: IValueVersion): ValueVersionInput[] =>\n version\n ? objectToNameValueArray(version).map(v => ({\n treeId: v.name,\n treeNodeId: v?.value?.id ?? null,\n }))\n : null;\n\nexport const extractPermissionFromQuery = (\n queryResult: ReturnType<typeof useIsAllowedQuery>,\n action: PermissionsActions,\n fallbackPermission = false,\n): boolean =>\n !queryResult.loading && !queryResult.error\n ? (queryResult.data?.isAllowed?.find(permission => permission.name === action)?.allowed ?? fallbackPermission)\n : fallbackPermission;\n\nexport const getPreviewSize = (size?: PreviewSize, simplistic = false) => {\n if (simplistic) {\n return '1.2rem';\n }\n\n switch (size) {\n case PreviewSize.MEDIUM:\n return '3.5rem';\n case PreviewSize.BIG:\n return '6rem';\n case PreviewSize.SMALL:\n return '2.5rem';\n case PreviewSize.TINY:\n return '1.7rem';\n default:\n return '2rem';\n }\n};\n\nexport const setDateToUTCNoon = (date: dayjs.Dayjs): dayjs.Dayjs =>\n date.set('hour', 12).set('minute', 0).set('second', 0).set('millisecond', 0);\n\nexport const getTreeRecordKey = (record: RecordIdentityFragment): string => `${record.whoAmI.library.id}/${record.id}`;\n\nexport const stringifyDateRangeValue = (value: IDateRangeValue, t: TFunction): string =>\n t('record_edition.date_range_value', {\n ...value,\n interpolation: {escapeValue: false},\n });\n\n/**\n * Cloning gql template tag because some apollo tools like query validation and codegen won't be happy if we use\n * interpolation in template strings. With a different tag name, the query won't be parsed by these tools\n * thus they won't complain about it.\n * It works exactly the same at runtime.\n */\nexport const gqlUnchecked = gql;\n\nexport const getPropertyCacheFieldName = (attributeId: string): string => `property({\"attribute\":\"${attributeId}\"})`;\n\n/**\n * Prepare view coming from the server to be used in the app\n */\nexport const prepareView = (\n view: WithTypename<ViewDetailsFragment>,\n attributes: IAttribute[],\n libraryId: string,\n userId: string,\n): IView => {\n const viewFilters: RecordFilterInput[] = (view?.filters ?? []).map(filter => ({\n ...filter,\n treeId: filter.tree?.id,\n }));\n\n const viewValuesVersions = (view?.valuesVersions ?? []).map(version => ({\n ...version,\n treeNode: {\n ...version.treeNode,\n title: version.treeNode.record.whoAmI.label,\n },\n }));\n\n return {\n ...omit(view, 'created_by', '__typename'),\n owner: view.created_by.id === userId,\n filters: getFiltersFromRequest(viewFilters, libraryId, attributes),\n sort: (view.sort ?? []).map(s => ({\n field: s.field,\n order: s.order,\n })),\n display: omit(view.display, '__typename') as ViewDetailsFragment['display'],\n valuesVersions: viewValuesVersions.reduce((versions: IValueVersion, version): IValueVersion => {\n versions[version.treeId] = {\n id: version.treeNode.id,\n label: version.treeNode.record.whoAmI.label,\n };\n\n return versions;\n }, {}),\n attributes: (view.attributes ?? []).map(attr => attr.id),\n };\n};\nexport const getAttributeFromKey = (key: string, library: string, attributes: IAttribute[]): IAttribute | undefined => {\n const splitKey = key.split('.');\n\n // Get root attribute by first key part\n const rootAttribute = attributes.find(attr => attr.library === library && attr.id === splitKey[0]);\n\n if (!rootAttribute) {\n return;\n }\n\n if (rootAttribute.type === AttributeType.simple || rootAttribute.type === AttributeType.advanced) {\n return rootAttribute;\n }\n\n if (isTypeLink(rootAttribute.type)) {\n if (splitKey[1]) {\n const linkedAttribute = attributes.find(\n attr => attr.library === rootAttribute?.linkedLibrary?.id && attr.id === splitKey[1],\n );\n\n return {...linkedAttribute, parentAttribute: {...rootAttribute, format: AttributeFormat.text}};\n }\n\n return rootAttribute;\n }\n\n if (rootAttribute.type === AttributeType.tree) {\n const [, libraryId, linkedTreeAttribute] = splitKey;\n\n if (!libraryId && !linkedTreeAttribute) {\n // Only root attribute => search on tree\n return {...rootAttribute, format: AttributeFormat.text};\n } else if (libraryId && !linkedTreeAttribute) {\n return rootAttribute;\n }\n\n const linkedAttribute = attributes.find(attr => attr.library === splitKey[1] && attr.id === splitKey[2]);\n\n return linkedAttribute;\n }\n};\n\nexport const stopEvent = (e: SyntheticEvent) => {\n e.stopPropagation();\n e.preventDefault();\n};\n\nexport const reorder = (list: any[], startIndex: number, endIndex: number) => {\n const result = Array.from(list);\n const [removed] = result.splice(startIndex, 1);\n result.splice(endIndex, 0, removed);\n\n return result.filter(element => !!element);\n};\n"]}
|
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export const interleaveElement = (insertedElement, sourceArray) => sourceArray.flatMap(arrayElement => [insertedElement, ...arrayElement]).slice(1);
|
|
5
2
|
//# sourceMappingURL=interleaveElement.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interleaveElement.js","sourceRoot":"","sources":["../../src/_utils/interleaveElement.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"interleaveElement.js","sourceRoot":"","sources":["../../src/_utils/interleaveElement.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAC7B,eAAkB,EAClB,WAAkB,EACN,EAAE,CAAC,WAAW,CAAC,OAAO,CAAC,YAAY,CAAC,EAAE,CAAC,CAAC,eAAe,EAAE,GAAG,YAAY,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC","sourcesContent":["export const interleaveElement = <T extends unknown, U extends unknown>(\n insertedElement: T,\n sourceArray: U[][],\n): Array<T | U> => sourceArray.flatMap(arrayElement => [insertedElement, ...arrayElement]).slice(1);\n"]}
|
package/dist/_utils/isDevEnv.js
CHANGED
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export const isDevEnv = () => import.meta.env.DEV;
|
|
5
2
|
//# sourceMappingURL=isDevEnv.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isDevEnv.js","sourceRoot":"","sources":["../../src/_utils/isDevEnv.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"isDevEnv.js","sourceRoot":"","sources":["../../src/_utils/isDevEnv.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,QAAQ,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC","sourcesContent":["export const isDevEnv = () => import.meta.env.DEV;\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typeguards.js","sourceRoot":"","sources":["../../src/_utils/typeguards.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"typeguards.js","sourceRoot":"","sources":["../../src/_utils/typeguards.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,aAAa,EAAC,MAAM,eAAe,CAAC;AAQ5C,MAAM,CAAC,MAAM,WAAW,GAAG,CAAI,KAAU,EAA4B,EAAE,CAAC,YAAY,IAAI,KAAK,CAAC;AAE9F,MAAM,CAAC,MAAM,kCAAkC,GAAG,CAC9C,KAA8B,EAC9B,SAAqC,EACI,EAAE,CAC3C,SAAS,CAAC,IAAI,KAAK,aAAa,CAAC,WAAW;IAC5C,CAAC,SAAS,CAAC,IAAI,KAAK,aAAa,CAAC,aAAa,IAAI,SAAS,CAAC,eAAe,KAAK,KAAK,CAAC,CAAC;AAE5F,MAAM,CAAC,MAAM,mCAAmC,GAAG,CAC/C,MAAiC,EACjC,SAAqC,EACO,EAAE,CAC9C,SAAS,CAAC,IAAI,KAAK,aAAa,CAAC,aAAa,IAAI,SAAS,CAAC,eAAe,KAAK,IAAI,CAAC;AAEzF,MAAM,CAAC,MAAM,mCAAmC,GAAG,CAC/C,KAA8B,EAC9B,SAAqC,EACI,EAAE,CAC3C,SAAS,CAAC,IAAI,KAAK,aAAa,CAAC,IAAI,IAAI,SAAS,CAAC,eAAe,KAAK,KAAK,CAAC;AAEjF,MAAM,CAAC,MAAM,oCAAoC,GAAG,CAChD,MAAiC,EACjC,SAAqC,EACO,EAAE,CAC9C,SAAS,CAAC,IAAI,KAAK,aAAa,CAAC,IAAI,IAAI,SAAS,CAAC,eAAe,KAAK,IAAI,CAAC","sourcesContent":["import {type WithTypename} from '@leav/utils';\nimport {AttributeType} from '_ui/_gqlTypes';\nimport {\n type RecordFormElementsValueTreeValue,\n type RecordFormElementAttribute,\n type RecordFormElementsValue,\n type RecordFormElementsValueLinkValue,\n} from '_ui/hooks/useGetRecordForm';\n\nexport const hasTypename = <T>(value: any): value is WithTypename<T> => '__typename' in value;\n\nexport const isRecordFormElementsValueLinkValue = (\n value: RecordFormElementsValue,\n attribute: RecordFormElementAttribute,\n): value is RecordFormElementsValueLinkValue =>\n attribute.type === AttributeType.simple_link ||\n (attribute.type === AttributeType.advanced_link && attribute.multiple_values === false);\n\nexport const isRecordFormElementsValueLinkValues = (\n values: RecordFormElementsValue[],\n attribute: RecordFormElementAttribute,\n): values is RecordFormElementsValueLinkValue[] =>\n attribute.type === AttributeType.advanced_link && attribute.multiple_values === true;\n\nexport const isRecordFormElementsValuesTreeValue = (\n value: RecordFormElementsValue,\n attribute: RecordFormElementAttribute,\n): value is RecordFormElementsValueTreeValue =>\n attribute.type === AttributeType.tree && attribute.multiple_values === false;\n\nexport const isRecordFormElementsValuesTreeValues = (\n values: RecordFormElementsValue[],\n attribute: RecordFormElementAttribute,\n): values is RecordFormElementsValueTreeValue[] =>\n attribute.type === AttributeType.tree && attribute.multiple_values === true;\n"]}
|
package/dist/antdTheme/index.js
CHANGED
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export * from './types';
|
|
5
2
|
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
6
3
|
const baseTextColor = '#000000';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/antdTheme/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/antdTheme/index.ts"],"names":[],"mappings":"AAEA,cAAc,SAAS,CAAC;AAExB,sEAAsE;AACtE,MAAM,aAAa,GAAG,SAAS,CAAC;AAChC,MAAM,CAAC,MAAM,SAAS,GAAG;IACrB,YAAY,EAAE,mCAAmC;IACjD,mBAAmB,EAAE,mCAAmC;IACxD,SAAS,EAAE,SAAS;IACpB,iBAAiB,EAAE,SAAS;IAC5B,gBAAgB,EAAE,aAAa;IAC/B,wBAAwB,EAAE,SAAS;IACnC,kBAAkB,EAAE,aAAa,GAAG,IAAI;IACxC,WAAW,EAAE,SAAS;IACtB,UAAU,EAAE,SAAS;IACrB,WAAW,EAAE,SAAS;IACtB,OAAO,EAAE,SAAS;IAClB,QAAQ,EAAE,SAAS;IACnB,WAAW,EAAE,SAAS;IACtB,gBAAgB,EAAE,oBAAoB;IACtC,YAAY,EAAE,MAAM;IACpB,qBAAqB,EAAE,OAAO;IAC9B,2BAA2B,EAAE,SAAS;IACtC,YAAY,EAAE,4FAA4F;IAC1G,sBAAsB,EAAE,oBAAoB;CAC/C,CAAC;AAEF,MAAM,CAAC,MAAM,WAAW,GAAgB;IACpC,UAAU,EAAE;QACR,MAAM,EAAE;YACJ,QAAQ,EAAE,SAAS,CAAC,WAAW;YAC/B,aAAa,EAAE,EAAE,EAAE,uEAAuE;SAC7F;QACD,IAAI,EAAE;YACF,wBAAwB,EAAE,CAAC;SAC9B;QACD,KAAK,EAAE;YACH,gBAAgB,EAAE,aAAa,EAAE,+CAA+C;SACnF;KACJ;CACJ,CAAC","sourcesContent":["import {type ThemeConfig} from 'antd/lib/config-provider/context';\n\nexport * from './types';\n\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nconst baseTextColor = '#000000';\nexport const themeVars = {\n primaryColor: 'var(--general-colors-primary-400)',\n primaryColorLighter: 'var(--general-colors-primary-100)',\n defaultBg: '#ffffff',\n invertedDefaultBg: '#000000',\n defaultTextColor: baseTextColor,\n invertedDefaultTextColor: '#ffffff',\n secondaryTextColor: baseTextColor + '80',\n activeColor: '#def4ff',\n errorColor: '#e02020',\n secondaryBg: '#f0f0f0',\n lightBg: '#fafafa',\n headerBg: '#f4f4f4',\n borderColor: '#d9d9d9',\n borderLightColor: 'rgb(240, 240, 240)',\n headerHeight: '3rem',\n navigationColumnWidth: '20rem',\n inheritedValuesVersionColor: '#FFBA00',\n checkerBoard: 'repeating-conic-gradient(rgb(220,220,220) 0% 25%, rgb(240,240,240) 0% 50%) 50% / 20px 20px',\n imageDefaultBackground: 'rgb(245, 245, 245)',\n};\n\nexport const customTheme: ThemeConfig = {\n components: {\n Layout: {\n headerBg: themeVars.secondaryBg,\n controlHeight: 24, // Used by antd to compute the height of the header (2 * controlHeight)\n },\n Menu: {\n colorActiveBarBorderSize: 0,\n },\n Table: {\n colorBgContainer: 'transparent', // To avoid issues with border-radius on footer\n },\n },\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/antdTheme/types.ts"],"names":[],"mappings":"","sourcesContent":["
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/antdTheme/types.ts"],"names":[],"mappings":"","sourcesContent":["import {type theme} from 'antd';\n\nexport type AntdThemeToken = ReturnType<typeof theme.useToken>['token'];\n"]}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
3
|
-
// This file is released under LGPL V3
|
|
4
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
5
2
|
import { Modal } from 'antd';
|
|
6
3
|
import { useState } from 'react';
|
|
7
4
|
import { useSharedTranslation } from '../../hooks/useSharedTranslation';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AttributePicker.js","sourceRoot":"","sources":["../../../src/components/AttributePicker/AttributePicker.tsx"],"names":[],"mappings":";AAAA,
|
|
1
|
+
{"version":3,"file":"AttributePicker.js","sourceRoot":"","sources":["../../../src/components/AttributePicker/AttributePicker.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAC,KAAK,EAAC,MAAM,MAAM,CAA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,QAAQ,EAAE,aAAa,EACvB,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,QAAQ,EAClB,gBAAgB,EAAE,gBAAgB,EAClC,WAAW,EAAE,WAAW,GAC1B,GACU,GACZ,CACX,CAAC;AACN,CAAC;AAED,eAAe,eAAe,CAAC","sourcesContent":["import {Modal} from 'antd';\nimport {useState} from 'react';\nimport {type GetAttributesQueryVariables} from '_ui/_gqlTypes';\nimport {useSharedTranslation} from '../../hooks/useSharedTranslation';\nimport {ErrorBoundary} from '../ErrorBoundary';\nimport {AttributesList} from './AttributesList';\n\ninterface IAttributePickerProps {\n open: boolean;\n onClose: () => void;\n onSubmit: (selectedAttributes: string[]) => Promise<void>;\n showCreateButton?: boolean;\n selected?: string[];\n multiple?: boolean;\n baseFilters?: GetAttributesQueryVariables['filters'];\n}\n\nfunction AttributePicker({\n open,\n onClose,\n onSubmit,\n selected = [],\n showCreateButton = true,\n multiple = true,\n baseFilters,\n}: IAttributePickerProps): JSX.Element {\n const {t} = useSharedTranslation();\n const [selectedAttributes, setSelectedAttributes] = useState<string[]>([]);\n const [isLoading, setIsLoading] = useState(false);\n\n const _handleSelect = (selection: string[]) => {\n setSelectedAttributes(selection);\n };\n\n const _handleSubmit = async () => {\n setIsLoading(true);\n await onSubmit(selectedAttributes);\n setIsLoading(false);\n onClose();\n };\n\n return (\n <Modal\n open={open}\n onCancel={onClose}\n width={800}\n title={t('attributes.select_attributes')}\n onOk={_handleSubmit}\n destroyOnClose\n okText={t('global.submit')}\n cancelText={t('global.cancel')}\n confirmLoading={isLoading}\n centered\n >\n <ErrorBoundary>\n <AttributesList\n onSelect={_handleSelect}\n selected={selected}\n multiple={multiple}\n showCreateButton={showCreateButton}\n baseFilters={baseFilters}\n />\n </ErrorBoundary>\n </Modal>\n );\n}\n\nexport default AttributePicker;\n"]}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
3
|
-
// This file is released under LGPL V3
|
|
4
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
5
2
|
import { PlusOutlined, SearchOutlined } from '@ant-design/icons';
|
|
6
3
|
import { useApolloClient } from '@apollo/client';
|
|
7
4
|
import { localizedTranslation } from '@leav/utils';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AttributesList.js","sourceRoot":"","sources":["../../../../src/components/AttributePicker/AttributesList/AttributesList.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,YAAY,EAAE,cAAc,EAAC,MAAM,mBAAmB,CAAC;AAC/D,OAAO,EAAC,eAAe,EAAC,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAC,oBAAoB,EAAgB,MAAM,aAAa,CAAC;AAChE,OAAO,EAAC,KAAK,EAAoD,MAAM,MAAM,CAAC;AAE9E,OAAO,EAAC,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAC,MAAM,YAAY,CAAC;AAClE,OAAO,EAAW,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC5D,OAAO,MAAM,MAAM,mBAAmB,CAAC;AACvC,OAAO,EACH,yBAAyB,EACzB,WAAW,EACX,yBAAyB,EACzB,uBAAuB,GAC1B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AACvC,OAAO,EAAC,oBAAoB,EAAC,MAAM,qCAAqC,CAAC;AACzE,OAAO,EAEH,eAAe,EACf,wBAAwB,EACxB,aAAa,EAGb,kBAAkB,EAClB,eAAe,EACf,SAAS,EACT,qBAAqB,EACrB,iBAAiB,GACpB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAC,kBAAkB,EAAC,MAAM,iDAAiD,CAAC;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EACb,YAAY,EAAE;oBACV,IAAI,EAAE,QAAQ,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,OAAO;oBACrC,eAAe;oBACf,QAAQ,EAAE,sBAAsB;iBACnC,EACD,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,SAAS,EACrB,QAAQ,QACR,UAAU,EAAE;oBACR,QAAQ,EAAE,CAAC,cAAc,CAAC;oBAC1B,QAAQ;oBACR,OAAO,EAAE,WAAW;oBACpB,KAAK,EAAE,IAAI,EAAE,UAAU,EAAE,UAAU,IAAI,CAAC;oBACxC,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC,oBAAoB,EAAE,EAAC,KAAK,EAAC,CAAC;iBACvD,EACD,MAAM,EAAE,EAAC,CAAC,EAAE,oBAAoB,EAAC,EACjC,KAAK,EAAE,GAAG,EAAE,CAAC,WAAW,EACxB,KAAK,EAAE,MAAM,CAAC,EAAE,CAAC,CAAC;oBACd,OAAO,EAAE,GAAG,EAAE,CAAC,eAAe,CAAC,MAAM,CAAC;iBACzC,CAAC,EACF,QAAQ,EAAE,aAAa,GACzB,EACD,uBAAuB,IAAI,CACxB,KAAC,kBAAkB,IACf,IAAI,EAAE,uBAAuB,EAC7B,OAAO,EAAE,wBAAwB,EACjC,YAAY,EAAE,iBAAiB,EAC/B,KAAK,EAAE,GAAG,GACZ,CACL,IACF,CACN,CAAC;AACN,CAAC;AAED,eAAe,cAAc,CAAC","sourcesContent":["// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06\n// This file is released under LGPL V3\n// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt\nimport {PlusOutlined, SearchOutlined} from '@ant-design/icons';\nimport {useApolloClient} from '@apollo/client';\nimport {localizedTranslation, type Override} from '@leav/utils';\nimport {Table, type TableColumnsType, type TablePaginationConfig} from 'antd';\nimport {type FilterValue, type SorterResult} from 'antd/lib/table/interface';\nimport {KitButton, KitIdCard, KitInput, KitTag} from 'aristid-ds';\nimport {type Key, useEffect, useRef, useState} from 'react';\nimport styled from 'styled-components';\nimport {\n defaultPaginationPageSize,\n PreviewSize,\n tagColorByAttributeFormat,\n tagColorByAttributeType,\n} from '../../../constants';\nimport {useLang} from '../../../hooks';\nimport {useSharedTranslation} from '../../../hooks/useSharedTranslation';\nimport {\n type AttributeDetailsFragment,\n AttributeFormat,\n AttributesSortableFields,\n AttributeType,\n type GetAttributesQuery,\n type GetAttributesQueryVariables,\n PermissionsActions,\n PermissionTypes,\n SortOrder,\n useGetAttributesQuery,\n useIsAllowedQuery,\n} from '../../../_gqlTypes';\nimport {getAttributesQuery} from '../../../_queries/attributes/getAttributesQuery';\nimport {extractPermissionFromQuery} from '../../../_utils';\nimport {EditAttributeModal} from '../../EditAttributeModal';\nimport {EntityCard, type IEntityData} from '../../EntityCard';\nimport {ErrorDisplay} from '../../ErrorDisplay';\n\nconst HeaderWrapper = styled.div`\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 0.5rem;\n\n .kit-input-wrapper {\n flex-grow: 1;\n }\n`;\n\ntype ListAttributeType = Override<GetAttributesQuery['attributes']['list'][number], {label: string}> & {key: string};\n\ninterface IAttributesListProps {\n onSelect: (selectedAttributes: string[]) => void;\n selected?: string[];\n multiple?: boolean;\n showCreateButton?: boolean;\n baseFilters?: GetAttributesQueryVariables['filters'];\n}\n\nfunction AttributesList({\n onSelect,\n selected = [],\n multiple = true,\n showCreateButton = true,\n baseFilters,\n}: IAttributesListProps): JSX.Element {\n const {t} = useSharedTranslation();\n const {lang} = useLang();\n\n const inputRef = useRef<HTMLInputElement>(null);\n\n const [pageSize, setPageSize] = useState(defaultPaginationPageSize);\n const [currentPage, setCurrentPage] = useState(1);\n const [sort, setSort] = useState<GetAttributesQueryVariables['sort']>();\n const [filters, setFilters] = useState<GetAttributesQueryVariables['filters']>({});\n const [tableData, setTableData] = useState<ListAttributeType[]>([]);\n\n const {loading, error, data} = useGetAttributesQuery({\n variables: {\n pagination: {\n limit: pageSize,\n offset: (currentPage - 1) * pageSize,\n },\n sort,\n filters: {\n ...filters,\n ...baseFilters,\n },\n },\n });\n\n const isAllowedQueryResult = useIsAllowedQuery({\n fetchPolicy: 'cache-and-network',\n variables: {\n type: PermissionTypes.admin,\n actions: [PermissionsActions.admin_create_attribute],\n },\n });\n const canCreate =\n showCreateButton && extractPermissionFromQuery(isAllowedQueryResult, PermissionsActions.admin_create_attribute);\n\n const [selectedRowKeys, setSelectedRowKeys] = useState<Key[]>(selected);\n const [isNewAttributeModalOpen, setIsNewAttributeModalOpen] = useState(false);\n const client = useApolloClient();\n\n const _handleSelectionChange = (selection: Key[]) => {\n setSelectedRowKeys(selection);\n onSelect(selection as string[]);\n };\n\n const _handleRowClick = (record: ListAttributeType) => {\n let newSelection;\n\n if (selectedRowKeys.indexOf(record.key) === -1) {\n newSelection = multiple ? [...selectedRowKeys, record.key] : [record.key]; // Add to selection\n } else {\n newSelection = multiple ? selectedRowKeys.filter(key => key !== record.key) : []; // Remove from selection\n }\n\n setSelectedRowKeys(newSelection);\n onSelect(newSelection as string[]);\n };\n\n const _handleSearchSubmit = (e: React.SyntheticEvent<HTMLInputElement>) => {\n setFilters({\n ...filters,\n label: `%${e.currentTarget.value}%`,\n });\n };\n\n const _handleSearchChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n // Handle clearing input only. Submitting input is otherwise handled by \"onPressEnter\"\n if (!e.currentTarget.value) {\n _handleSearchSubmit(e);\n }\n };\n\n const _handleClickNewAttribute = () => {\n setIsNewAttributeModalOpen(true);\n };\n const _handleCloseNewAttribute = () => setIsNewAttributeModalOpen(false);\n\n const _handlePostCreate = async (newAttribute: AttributeDetailsFragment) => {\n const allAttributesData = client.readQuery<GetAttributesQuery>({query: getAttributesQuery});\n\n if (allAttributesData) {\n client.writeQuery({\n query: getAttributesQuery,\n data: {\n attributes: {\n ...allAttributesData.attributes,\n list: [newAttribute, ...allAttributesData.attributes.list],\n },\n },\n });\n }\n const newSelection = [...selectedRowKeys, newAttribute.id];\n onSelect(newSelection as string[]);\n setSelectedRowKeys(newSelection);\n };\n\n const _handleChange = (\n pagination: TablePaginationConfig,\n filter: Record<string, FilterValue | null>,\n sorter: SorterResult<ListAttributeType> | Array<SorterResult<ListAttributeType>>,\n ) => {\n setCurrentPage(pagination.current);\n setPageSize(pagination.pageSize);\n\n const relevantSorter = Array.isArray(sorter) ? sorter[0] : sorter;\n if (relevantSorter.column && relevantSorter.order) {\n const newSort = {\n field: AttributesSortableFields[relevantSorter.columnKey],\n order: relevantSorter.order === 'ascend' ? SortOrder.asc : SortOrder.desc,\n };\n setSort(newSort);\n }\n\n const newFilters: GetAttributesQueryVariables['filters'] = {};\n for (const [field, filterValue] of Object.entries(filter)) {\n if (filterValue) {\n newFilters[field] = filterValue;\n }\n }\n setFilters(newFilters);\n };\n\n if (error || isAllowedQueryResult.error) {\n return <ErrorDisplay message={error?.message || isAllowedQueryResult?.error?.message} />;\n }\n\n const columns: TableColumnsType<ListAttributeType> = [\n {\n title: t('attributes.attribute'),\n key: 'attribute',\n render: (_, attribute) => {\n const attributeIdentity: IEntityData = {\n label: attribute.label,\n subLabel: attribute.id,\n preview: null,\n color: null,\n };\n return <EntityCard entity={attributeIdentity} size={PreviewSize.SMALL} />;\n },\n },\n {\n title: t('attributes.type'),\n dataIndex: 'type',\n key: 'type',\n width: '150px',\n render: (type: AttributeType) => (\n <KitTag\n style={{\n borderColor: tagColorByAttributeType[type][0],\n backgroundColor: tagColorByAttributeType[type][1],\n }}\n >\n <KitIdCard description={t(`attributes.type_${type}`)} />\n </KitTag>\n ),\n filters: Object.values(AttributeType).map(type => ({\n text: t(`attributes.type_${type}`),\n value: type,\n })),\n onFilter: (value, record) => record.type === value,\n sorter: (a, b) => {\n const aTypeLabel = t(`attributes.type_${a.type}`);\n const bTypeLabel = t(`attributes.type_${b.type}`);\n\n return aTypeLabel.localeCompare(bTypeLabel);\n },\n },\n {\n title: t('attributes.format'),\n dataIndex: 'format',\n key: 'format',\n width: '150px',\n render: (format: AttributeFormat) =>\n format ? (\n <KitTag\n style={{\n borderColor: tagColorByAttributeFormat[format][0],\n backgroundColor: tagColorByAttributeFormat[format][1],\n }}\n >\n <KitIdCard description={t(`attributes.format_${format}`)} />\n </KitTag>\n ) : null,\n filters: Object.values(AttributeFormat).map(format => ({\n text: t(`attributes.format_${format}`),\n value: format,\n })),\n onFilter: (value, record) => record.format === value,\n sorter: (a, b) => {\n const aFormatLabel = t(`attributes.format_${a.format}`);\n const bFormatLabel = t(`attributes.format_${b.format}`);\n\n return aFormatLabel.localeCompare(bFormatLabel);\n },\n },\n ];\n\n useEffect(() => {\n // To avoid temporary display of \"no data\" when pagination changes\n if (loading || !data) {\n return;\n }\n\n const newTableData = data?.attributes?.list\n ? [...data.attributes.list].map(attribute => ({\n ...attribute,\n key: attribute.id,\n label: localizedTranslation(attribute.label, lang),\n }))\n : [];\n\n setTableData(newTableData);\n }, [loading, data]);\n\n useEffect(() => {\n if (inputRef.current) {\n inputRef.current.focus();\n }\n }, [inputRef]);\n\n const tableHeader = (\n <HeaderWrapper>\n <KitInput\n onPressEnter={_handleSearchSubmit}\n onChange={_handleSearchChange}\n placeholder={t('global.search') + '...'}\n allowClear\n suffix={<SearchOutlined />}\n // @ts-ignore - ref is a valid prop\n ref={inputRef}\n />\n {canCreate && (\n <KitButton type=\"primary\" icon={<PlusOutlined />} onClick={_handleClickNewAttribute}>\n {t('attributes.new_attribute')}\n </KitButton>\n )}\n </HeaderWrapper>\n );\n\n return (\n <>\n <Table\n loading={loading}\n size=\"middle\"\n rowSelection={{\n type: multiple ? 'checkbox' : 'radio',\n selectedRowKeys,\n onChange: _handleSelectionChange,\n }}\n columns={columns}\n dataSource={tableData}\n bordered\n pagination={{\n position: ['bottomCenter'],\n pageSize,\n current: currentPage,\n total: data?.attributes?.totalCount ?? 0,\n showTotal: total => t('global.total_count', {total}),\n }}\n scroll={{y: 'calc(95vh - 20rem)'}}\n title={() => tableHeader}\n onRow={record => ({\n onClick: () => _handleRowClick(record),\n })}\n onChange={_handleChange}\n />\n {isNewAttributeModalOpen && (\n <EditAttributeModal\n open={isNewAttributeModalOpen}\n onClose={_handleCloseNewAttribute}\n onPostCreate={_handlePostCreate}\n width={790}\n />\n )}\n </>\n );\n}\n\nexport default AttributesList;\n"]}
|
|
1
|
+
{"version":3,"file":"AttributesList.js","sourceRoot":"","sources":["../../../../src/components/AttributePicker/AttributesList/AttributesList.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAC,YAAY,EAAE,cAAc,EAAC,MAAM,mBAAmB,CAAC;AAC/D,OAAO,EAAC,eAAe,EAAC,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAC,oBAAoB,EAAgB,MAAM,aAAa,CAAC;AAChE,OAAO,EAAC,KAAK,EAAoD,MAAM,MAAM,CAAC;AAE9E,OAAO,EAAC,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAC,MAAM,YAAY,CAAC;AAClE,OAAO,EAAW,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AAC5D,OAAO,MAAM,MAAM,mBAAmB,CAAC;AACvC,OAAO,EACH,yBAAyB,EACzB,WAAW,EACX,yBAAyB,EACzB,uBAAuB,GAC1B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AACvC,OAAO,EAAC,oBAAoB,EAAC,MAAM,qCAAqC,CAAC;AACzE,OAAO,EAEH,eAAe,EACf,wBAAwB,EACxB,aAAa,EAGb,kBAAkB,EAClB,eAAe,EACf,SAAS,EACT,qBAAqB,EACrB,iBAAiB,GACpB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAC,kBAAkB,EAAC,MAAM,iDAAiD,CAAC;AACnF,OAAO,EAAC,0BAA0B,EAAC,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAC,kBAAkB,EAAC,MAAM,0BAA0B,CAAC;AAC5D,OAAO,EAAC,UAAU,EAAmB,MA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,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,SAAS,EACrB,QAAQ,QACR,UAAU,EAAE;oBACR,QAAQ,EAAE,CAAC,cAAc,CAAC;oBAC1B,QAAQ;oBACR,OAAO,EAAE,WAAW;oBACpB,KAAK,EAAE,IAAI,EAAE,UAAU,EAAE,UAAU,IAAI,CAAC;oBACxC,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC,oBAAoB,EAAE,EAAC,KAAK,EAAC,CAAC;iBACvD,EACD,MAAM,EAAE,EAAC,CAAC,EAAE,oBAAoB,EAAC,EACjC,KAAK,EAAE,GAAG,EAAE,CAAC,WAAW,EACxB,KAAK,EAAE,MAAM,CAAC,EAAE,CAAC,CAAC;oBACd,OAAO,EAAE,GAAG,EAAE,CAAC,eAAe,CAAC,MAAM,CAAC;iBACzC,CAAC,EACF,QAAQ,EAAE,aAAa,GACzB,EACD,uBAAuB,IAAI,CACxB,KAAC,kBAAkB,IACf,IAAI,EAAE,uBAAuB,EAC7B,OAAO,EAAE,wBAAwB,EACjC,YAAY,EAAE,iBAAiB,EAC/B,KAAK,EAAE,GAAG,GACZ,CACL,IACF,CACN,CAAC;AACN,CAAC;AAED,eAAe,cAAc,CAAC","sourcesContent":["import {PlusOutlined, SearchOutlined} from '@ant-design/icons';\nimport {useApolloClient} from '@apollo/client';\nimport {localizedTranslation, type Override} from '@leav/utils';\nimport {Table, type TableColumnsType, type TablePaginationConfig} from 'antd';\nimport {type FilterValue, type SorterResult} from 'antd/lib/table/interface';\nimport {KitButton, KitIdCard, KitInput, KitTag} from 'aristid-ds';\nimport {type Key, useEffect, useRef, useState} from 'react';\nimport styled from 'styled-components';\nimport {\n defaultPaginationPageSize,\n PreviewSize,\n tagColorByAttributeFormat,\n tagColorByAttributeType,\n} from '../../../constants';\nimport {useLang} from '../../../hooks';\nimport {useSharedTranslation} from '../../../hooks/useSharedTranslation';\nimport {\n type AttributeDetailsFragment,\n AttributeFormat,\n AttributesSortableFields,\n AttributeType,\n type GetAttributesQuery,\n type GetAttributesQueryVariables,\n PermissionsActions,\n PermissionTypes,\n SortOrder,\n useGetAttributesQuery,\n useIsAllowedQuery,\n} from '../../../_gqlTypes';\nimport {getAttributesQuery} from '../../../_queries/attributes/getAttributesQuery';\nimport {extractPermissionFromQuery} from '../../../_utils';\nimport {EditAttributeModal} from '../../EditAttributeModal';\nimport {EntityCard, type IEntityData} from '../../EntityCard';\nimport {ErrorDisplay} from '../../ErrorDisplay';\n\nconst HeaderWrapper = styled.div`\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 0.5rem;\n\n .kit-input-wrapper {\n flex-grow: 1;\n }\n`;\n\ntype ListAttributeType = Override<GetAttributesQuery['attributes']['list'][number], {label: string}> & {key: string};\n\ninterface IAttributesListProps {\n onSelect: (selectedAttributes: string[]) => void;\n selected?: string[];\n multiple?: boolean;\n showCreateButton?: boolean;\n baseFilters?: GetAttributesQueryVariables['filters'];\n}\n\nfunction AttributesList({\n onSelect,\n selected = [],\n multiple = true,\n showCreateButton = true,\n baseFilters,\n}: IAttributesListProps): JSX.Element {\n const {t} = useSharedTranslation();\n const {lang} = useLang();\n\n const inputRef = useRef<HTMLInputElement>(null);\n\n const [pageSize, setPageSize] = useState(defaultPaginationPageSize);\n const [currentPage, setCurrentPage] = useState(1);\n const [sort, setSort] = useState<GetAttributesQueryVariables['sort']>();\n const [filters, setFilters] = useState<GetAttributesQueryVariables['filters']>({});\n const [tableData, setTableData] = useState<ListAttributeType[]>([]);\n\n const {loading, error, data} = useGetAttributesQuery({\n variables: {\n pagination: {\n limit: pageSize,\n offset: (currentPage - 1) * pageSize,\n },\n sort,\n filters: {\n ...filters,\n ...baseFilters,\n },\n },\n });\n\n const isAllowedQueryResult = useIsAllowedQuery({\n fetchPolicy: 'cache-and-network',\n variables: {\n type: PermissionTypes.admin,\n actions: [PermissionsActions.admin_create_attribute],\n },\n });\n const canCreate =\n showCreateButton && extractPermissionFromQuery(isAllowedQueryResult, PermissionsActions.admin_create_attribute);\n\n const [selectedRowKeys, setSelectedRowKeys] = useState<Key[]>(selected);\n const [isNewAttributeModalOpen, setIsNewAttributeModalOpen] = useState(false);\n const client = useApolloClient();\n\n const _handleSelectionChange = (selection: Key[]) => {\n setSelectedRowKeys(selection);\n onSelect(selection as string[]);\n };\n\n const _handleRowClick = (record: ListAttributeType) => {\n let newSelection;\n\n if (selectedRowKeys.indexOf(record.key) === -1) {\n newSelection = multiple ? [...selectedRowKeys, record.key] : [record.key]; // Add to selection\n } else {\n newSelection = multiple ? selectedRowKeys.filter(key => key !== record.key) : []; // Remove from selection\n }\n\n setSelectedRowKeys(newSelection);\n onSelect(newSelection as string[]);\n };\n\n const _handleSearchSubmit = (e: React.SyntheticEvent<HTMLInputElement>) => {\n setFilters({\n ...filters,\n label: `%${e.currentTarget.value}%`,\n });\n };\n\n const _handleSearchChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n // Handle clearing input only. Submitting input is otherwise handled by \"onPressEnter\"\n if (!e.currentTarget.value) {\n _handleSearchSubmit(e);\n }\n };\n\n const _handleClickNewAttribute = () => {\n setIsNewAttributeModalOpen(true);\n };\n const _handleCloseNewAttribute = () => setIsNewAttributeModalOpen(false);\n\n const _handlePostCreate = async (newAttribute: AttributeDetailsFragment) => {\n const allAttributesData = client.readQuery<GetAttributesQuery>({query: getAttributesQuery});\n\n if (allAttributesData) {\n client.writeQuery({\n query: getAttributesQuery,\n data: {\n attributes: {\n ...allAttributesData.attributes,\n list: [newAttribute, ...allAttributesData.attributes.list],\n },\n },\n });\n }\n const newSelection = [...selectedRowKeys, newAttribute.id];\n onSelect(newSelection as string[]);\n setSelectedRowKeys(newSelection);\n };\n\n const _handleChange = (\n pagination: TablePaginationConfig,\n filter: Record<string, FilterValue | null>,\n sorter: SorterResult<ListAttributeType> | Array<SorterResult<ListAttributeType>>,\n ) => {\n setCurrentPage(pagination.current);\n setPageSize(pagination.pageSize);\n\n const relevantSorter = Array.isArray(sorter) ? sorter[0] : sorter;\n if (relevantSorter.column && relevantSorter.order) {\n const newSort = {\n field: AttributesSortableFields[relevantSorter.columnKey],\n order: relevantSorter.order === 'ascend' ? SortOrder.asc : SortOrder.desc,\n };\n setSort(newSort);\n }\n\n const newFilters: GetAttributesQueryVariables['filters'] = {};\n for (const [field, filterValue] of Object.entries(filter)) {\n if (filterValue) {\n newFilters[field] = filterValue;\n }\n }\n setFilters(newFilters);\n };\n\n if (error || isAllowedQueryResult.error) {\n return <ErrorDisplay message={error?.message || isAllowedQueryResult?.error?.message} />;\n }\n\n const columns: TableColumnsType<ListAttributeType> = [\n {\n title: t('attributes.attribute'),\n key: 'attribute',\n render: (_, attribute) => {\n const attributeIdentity: IEntityData = {\n label: attribute.label,\n subLabel: attribute.id,\n preview: null,\n color: null,\n };\n return <EntityCard entity={attributeIdentity} size={PreviewSize.SMALL} />;\n },\n },\n {\n title: t('attributes.type'),\n dataIndex: 'type',\n key: 'type',\n width: '150px',\n render: (type: AttributeType) => (\n <KitTag\n style={{\n borderColor: tagColorByAttributeType[type][0],\n backgroundColor: tagColorByAttributeType[type][1],\n }}\n >\n <KitIdCard description={t(`attributes.type_${type}`)} />\n </KitTag>\n ),\n filters: Object.values(AttributeType).map(type => ({\n text: t(`attributes.type_${type}`),\n value: type,\n })),\n onFilter: (value, record) => record.type === value,\n sorter: (a, b) => {\n const aTypeLabel = t(`attributes.type_${a.type}`);\n const bTypeLabel = t(`attributes.type_${b.type}`);\n\n return aTypeLabel.localeCompare(bTypeLabel);\n },\n },\n {\n title: t('attributes.format'),\n dataIndex: 'format',\n key: 'format',\n width: '150px',\n render: (format: AttributeFormat) =>\n format ? (\n <KitTag\n style={{\n borderColor: tagColorByAttributeFormat[format][0],\n backgroundColor: tagColorByAttributeFormat[format][1],\n }}\n >\n <KitIdCard description={t(`attributes.format_${format}`)} />\n </KitTag>\n ) : null,\n filters: Object.values(AttributeFormat).map(format => ({\n text: t(`attributes.format_${format}`),\n value: format,\n })),\n onFilter: (value, record) => record.format === value,\n sorter: (a, b) => {\n const aFormatLabel = t(`attributes.format_${a.format}`);\n const bFormatLabel = t(`attributes.format_${b.format}`);\n\n return aFormatLabel.localeCompare(bFormatLabel);\n },\n },\n ];\n\n useEffect(() => {\n // To avoid temporary display of \"no data\" when pagination changes\n if (loading || !data) {\n return;\n }\n\n const newTableData = data?.attributes?.list\n ? [...data.attributes.list].map(attribute => ({\n ...attribute,\n key: attribute.id,\n label: localizedTranslation(attribute.label, lang),\n }))\n : [];\n\n setTableData(newTableData);\n }, [loading, data]);\n\n useEffect(() => {\n if (inputRef.current) {\n inputRef.current.focus();\n }\n }, [inputRef]);\n\n const tableHeader = (\n <HeaderWrapper>\n <KitInput\n onPressEnter={_handleSearchSubmit}\n onChange={_handleSearchChange}\n placeholder={t('global.search') + '...'}\n allowClear\n suffix={<SearchOutlined />}\n // @ts-ignore - ref is a valid prop\n ref={inputRef}\n />\n {canCreate && (\n <KitButton type=\"primary\" icon={<PlusOutlined />} onClick={_handleClickNewAttribute}>\n {t('attributes.new_attribute')}\n </KitButton>\n )}\n </HeaderWrapper>\n );\n\n return (\n <>\n <Table\n loading={loading}\n size=\"middle\"\n rowSelection={{\n type: multiple ? 'checkbox' : 'radio',\n selectedRowKeys,\n onChange: _handleSelectionChange,\n }}\n columns={columns}\n dataSource={tableData}\n bordered\n pagination={{\n position: ['bottomCenter'],\n pageSize,\n current: currentPage,\n total: data?.attributes?.totalCount ?? 0,\n showTotal: total => t('global.total_count', {total}),\n }}\n scroll={{y: 'calc(95vh - 20rem)'}}\n title={() => tableHeader}\n onRow={record => ({\n onClick: () => _handleRowClick(record),\n })}\n onChange={_handleChange}\n />\n {isNewAttributeModalOpen && (\n <EditAttributeModal\n open={isNewAttributeModalOpen}\n onClose={_handleCloseNewAttribute}\n onPostCreate={_handlePostCreate}\n width={790}\n />\n )}\n </>\n );\n}\n\nexport default AttributesList;\n"]}
|
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export { default as AttributesList } from './AttributesList';
|
|
5
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/AttributePicker/AttributesList/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/AttributePicker/AttributesList/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,IAAI,cAAc,EAAC,MAAM,kBAAkB,CAAC","sourcesContent":["export {default as AttributesList} from './AttributesList';\n"]}
|
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export { default as AttributePicker } from './AttributePicker';
|
|
5
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/AttributePicker/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/AttributePicker/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,IAAI,eAAe,EAAC,MAAM,mBAAmB,CAAC","sourcesContent":["export {default as AttributePicker} from './AttributePicker';\n"]}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
3
|
-
// This file is released under LGPL V3
|
|
4
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
5
2
|
import { Button } from 'antd';
|
|
6
3
|
import styled from 'styled-components';
|
|
7
4
|
import { themeVars } from '../../antdTheme';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BasicButton.js","sourceRoot":"","sources":["../../../src/components/BasicButton/BasicButton.tsx"],"names":[],"mappings":";AAAA,
|
|
1
|
+
{"version":3,"file":"BasicButton.js","sourceRoot":"","sources":["../../../src/components/BasicButton/BasicButton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAC,MAAM,EAAmB,MAAM,MAAM,CAAC;AAC9C,OAAO,MAAM,MAAM,mBAAmB,CAAC;AACvC,OAAO,EAAC,SAAS,EAAC,MAAM,iBAAiB,CAAC;AAE1C,MAAM,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,CAA4C;;iBAE3D,SAAS,CAAC,kBAAkB;;;;;;;sBAOvB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC;;UAElD,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,yBAAyB,CAAC,CAAC,CAAC,EAAE,CAAC;;CAErE,CAAC;AAOF,SAAS,WAAW,CAAC,EAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAoB;IAC5E,OAAO,CACH,KAAC,SAAS,OAAK,KAAK,eAAa,QAAQ,eAAa,QAAQ,YACzD,QAAQ,GACD,CACf,CAAC;AACN,CAAC;AAED,eAAe,WAAW,CAAC","sourcesContent":["import {Button, type ButtonProps} from 'antd';\nimport styled from 'styled-components';\nimport {themeVars} from '../../antdTheme';\n\nconst StyledBtn = styled(Button)<{$bordered?: boolean; $centered?: boolean}>`\n && {\n color: ${themeVars.secondaryTextColor};\n box-shadow: none;\n &,\n &:hover,\n &[disabled] {\n background: transparent;\n }\n text-align: ${p => (p.$centered ? 'center' : 'left')};\n\n ${props => (!props.$bordered ? '&, &:hover {border: 0;}' : '')}\n }\n`;\n\ninterface IBasicButtonProps extends ButtonProps {\n bordered?: boolean;\n centered?: boolean;\n}\n\nfunction BasicButton({children, bordered, centered, ...props}: IBasicButtonProps): JSX.Element {\n return (\n <StyledBtn {...props} $bordered={bordered} $centered={centered}>\n {children}\n </StyledBtn>\n );\n}\n\nexport default BasicButton;\n"]}
|
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
2
|
-
// This file is released under LGPL V3
|
|
3
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
1
|
export { default as BasicButton } from './BasicButton';
|
|
5
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/BasicButton/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/BasicButton/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,IAAI,WAAW,EAAC,MAAM,eAAe,CAAC","sourcesContent":["export {default as BasicButton} from './BasicButton';\n"]}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
// Copyright LEAV Solutions 2017 until 2023/11/05, Copyright Aristid from 2023/11/06
|
|
3
|
-
// This file is released under LGPL V3
|
|
4
|
-
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
5
2
|
import { App, Button, Input, Modal, Steps, theme } from 'antd';
|
|
6
3
|
import { useState } from 'react';
|
|
7
4
|
import { useSharedTranslation } from '../../hooks/useSharedTranslation';
|