@leav/ui 0.3.6-df40eff → 0.3.6-e865e1b
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/form.d.ts +11 -5
- package/dist/__mocks__/common/form.js +18 -2
- package/dist/__mocks__/common/form.js.map +1 -1
- package/dist/__mocks__/common/record.d.ts +13 -2
- package/dist/__mocks__/common/record.js.map +1 -1
- package/dist/_gqlTypes/index.d.ts +65 -36
- package/dist/_gqlTypes/index.js +59 -8
- package/dist/_gqlTypes/index.js.map +1 -1
- package/dist/components/CreateDirectory/CreateDirectory.js +1 -1
- package/dist/components/CreateDirectory/CreateDirectory.js.map +1 -1
- package/dist/components/EditApplication/EditApplication.js +2 -2
- package/dist/components/EditApplication/EditApplication.js.map +1 -1
- package/dist/components/EditApplication/_types.d.ts +2 -2
- package/dist/components/Explorer/DataView.d.ts +9 -1
- package/dist/components/Explorer/DataView.js +30 -14
- package/dist/components/Explorer/DataView.js.map +1 -1
- package/dist/components/Explorer/Explorer.d.ts +3 -0
- package/dist/components/Explorer/Explorer.js +44 -21
- package/dist/components/Explorer/Explorer.js.map +1 -1
- package/dist/components/Explorer/IdCard.d.ts +7 -0
- package/dist/components/Explorer/IdCard.js +15 -0
- package/dist/components/Explorer/IdCard.js.map +1 -0
- package/dist/components/Explorer/TableCell.d.ts +2 -1
- package/dist/components/Explorer/TableCell.js +123 -20
- package/dist/components/Explorer/TableCell.js.map +1 -1
- package/dist/components/Explorer/TableTagGroup.d.ts +7 -0
- package/dist/components/Explorer/TableTagGroup.js +30 -0
- package/dist/components/Explorer/TableTagGroup.js.map +1 -0
- package/dist/components/Explorer/_queries/useExplorerData.d.ts +17 -2
- package/dist/components/Explorer/_queries/useExplorerData.js +23 -9
- package/dist/components/Explorer/_queries/useExplorerData.js.map +1 -1
- package/dist/components/Explorer/_types.d.ts +7 -4
- package/dist/components/Explorer/index.d.ts +1 -3
- package/dist/components/Explorer/index.js +1 -3
- package/dist/components/Explorer/index.js.map +1 -1
- package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/ColumnItem.d.ts +1 -1
- package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/ColumnItem.js +12 -5
- package/dist/components/Explorer/manage-view-settings/_shared/ColumnItem.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.d.ts +11 -0
- package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.js +61 -0
- package/dist/components/Explorer/manage-view-settings/_shared/useAttributeDetailsData.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.d.ts +6 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js +28 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.d.ts +6 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js +56 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.d.ts +8 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js +12 -0
- package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.d.ts +4 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js +89 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterItems.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.d.ts +10 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.js +33 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/FilterListItem.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/SimpleFilterDropDown.d.ts +8 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/SimpleFilterDropDown.js +100 -0
- package/dist/components/Explorer/manage-view-settings/filter-items/filter-type/SimpleFilterDropDown.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/index.d.ts +8 -0
- package/dist/components/Explorer/manage-view-settings/index.js +11 -0
- package/dist/components/Explorer/manage-view-settings/index.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.js.map +1 -0
- package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/SidePanel.js +2 -2
- package/dist/components/Explorer/manage-view-settings/open-view-settings/SidePanel.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.d.ts +3 -0
- package/dist/components/Explorer/{edit-settings/useOpenSettings.js → manage-view-settings/open-view-settings/useOpenViewSettings.js} +7 -5
- package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/router-menu/SettingItem.js.map +1 -0
- package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingsPanel.d.ts +1 -1
- package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingsPanel.js +10 -10
- package/dist/components/Explorer/manage-view-settings/router-menu/SettingsPanel.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.d.ts +4 -0
- package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.js +109 -0
- package/dist/components/Explorer/manage-view-settings/sort-items/SortItems.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.d.ts +10 -0
- package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.js +32 -0
- package/dist/components/Explorer/manage-view-settings/sort-items/SortListItem.js.map +1 -0
- package/dist/components/Explorer/{edit-settings/ViewSetingsContext.d.ts → manage-view-settings/store-view-settings/ViewSettingsContext.d.ts} +1 -2
- package/dist/components/Explorer/{edit-settings/ViewSetingsContext.js → manage-view-settings/store-view-settings/ViewSettingsContext.js} +1 -5
- package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js.map +1 -0
- package/dist/components/Explorer/{edit-settings → manage-view-settings/store-view-settings}/useViewSettingsContext.js +1 -1
- package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.d.ts +4 -0
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js +13 -0
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js.map +1 -0
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.d.ts +135 -0
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js +164 -0
- package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js.map +1 -0
- package/dist/components/Explorer/useEditAction.js +1 -0
- package/dist/components/Explorer/useEditAction.js.map +1 -1
- package/dist/components/Explorer/usePagination.d.ts +7 -0
- package/dist/components/Explorer/usePagination.js +25 -0
- package/dist/components/Explorer/usePagination.js.map +1 -0
- package/dist/components/Explorer/usePrimaryActions.d.ts +1 -9
- package/dist/components/Explorer/usePrimaryActions.js +4 -12
- package/dist/components/Explorer/usePrimaryActions.js.map +1 -1
- package/dist/components/Explorer/useSearchInput.d.ts +10 -0
- package/dist/components/Explorer/useSearchInput.js +31 -0
- package/dist/components/Explorer/useSearchInput.js.map +1 -0
- package/dist/components/Explorer/useTableScrollableHeight.d.ts +5 -0
- package/dist/components/Explorer/useTableScrollableHeight.js +15 -0
- package/dist/components/Explorer/useTableScrollableHeight.js.map +1 -0
- package/dist/components/ExportModal/ExportModal.js +2 -2
- package/dist/components/ExportModal/ExportModal.js.map +1 -1
- package/dist/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.js +5 -5
- package/dist/components/ImportModal/ImportModalConfigStep/ImportModalConfigStep.js.map +1 -1
- package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.js +2 -2
- package/dist/components/LibraryItemsList/FiltersPanel/Filter/Filter.js.map +1 -1
- package/dist/components/RecordEdition/EditRecord/EditRecord.js +1 -1
- package/dist/components/RecordEdition/EditRecord/EditRecord.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.js +1 -1
- package/dist/components/RecordEdition/EditRecordContent/EditRecordContent.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/_types.d.ts +7 -20
- package/dist/components/RecordEdition/EditRecordContent/_types.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/antdUtils.d.ts +2 -1
- package/dist/components/RecordEdition/EditRecordContent/antdUtils.js +40 -33
- package/dist/components/RecordEdition/EditRecordContent/antdUtils.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.d.ts +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.js +2 -2
- package/dist/components/RecordEdition/EditRecordContent/uiElements/Container/Container.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MonoValueSelect/MonoValueSelect.js +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MonoValueSelect/MonoValueSelect.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MultiValueSelect/MultiValueSelect.js +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/LinkField/MultiValueSelect/MultiValueSelect.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/DeleteAllValuesButton.d.ts +4 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/DeleteAllValuesButton.js +25 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/DeleteAllValuesButton.js.map +1 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.d.ts +3 -2
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.js +165 -192
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardField.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.d.ts +2 -8
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.js +10 -29
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSBooleanWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.d.ts +2 -13
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.js +33 -43
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSColorPickerWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.d.ts +3 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.js +19 -47
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSDatePickerWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.d.ts +3 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.js +9 -77
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputEncryptedWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.d.ts +3 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.js +24 -46
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputNumberWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.d.ts +3 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.js +29 -50
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSInputWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.d.ts +3 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.js +43 -62
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRangePickerWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.d.ts +3 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.js +28 -50
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/DSRichTextWrapper.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.d.ts +14 -9
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.js +64 -401
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValue.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/MonoValueSelect.d.ts +3 -2
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/MonoValueSelect.js +23 -49
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/MonoValueSelect.js.map +1 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/ValuesList/_types.d.ts +2 -9
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.d.ts +13 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.js +2 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/_types.js.map +1 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/calculatedInheritedFlags.d.ts +42 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/calculatedInheritedFlags.js +55 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/calculatedInheritedFlags.js.map +1 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.d.ts +12 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.js +31 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/useGetPresentationValues.js.map +1 -0
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/ValuesAdd/ValuesAdd.js +2 -2
- package/dist/components/RecordEdition/EditRecordContent/uiElements/TreeField/ValuesAdd/ValuesAdd.js.map +1 -1
- package/dist/components/SelectTreeNode/SelectTreeNode.d.ts +4 -7
- package/dist/components/SelectTreeNode/SelectTreeNode.js +17 -135
- package/dist/components/SelectTreeNode/SelectTreeNode.js.map +1 -1
- package/dist/components/SelectTreeNode/SelectTreeNodeContent.d.ts +16 -0
- package/dist/components/SelectTreeNode/SelectTreeNodeContent.js +131 -0
- package/dist/components/SelectTreeNode/SelectTreeNodeContent.js.map +1 -0
- package/dist/components/SelectTreeNode/index.d.ts +1 -1
- package/dist/components/SelectTreeNode/index.js +1 -1
- package/dist/components/SelectTreeNode/index.js.map +1 -1
- package/dist/components/SelectTreeNodeModal/SelectTreeNodeModal.d.ts +4 -7
- package/dist/components/SelectTreeNodeModal/SelectTreeNodeModal.js +10 -10
- package/dist/components/SelectTreeNodeModal/SelectTreeNodeModal.js.map +1 -1
- package/dist/components/SelectTreeNodeModal/index.d.ts +1 -2
- package/dist/components/SelectTreeNodeModal/index.js +1 -2
- package/dist/components/SelectTreeNodeModal/index.js.map +1 -1
- package/dist/components/UploadFiles/UploadFiles.js +1 -1
- package/dist/components/UploadFiles/UploadFiles.js.map +1 -1
- package/dist/components/ValuesVersionConfigurator/VersionTree/VersionTree.js +2 -2
- package/dist/components/ValuesVersionConfigurator/VersionTree/VersionTree.js.map +1 -1
- package/dist/hooks/useDebouncedValue/index.d.ts +1 -0
- package/dist/{components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler → hooks/useDebouncedValue}/index.js +1 -1
- package/dist/hooks/useDebouncedValue/index.js.map +1 -0
- package/dist/hooks/useGetRecordForm/useGetRecordForm.d.ts +1 -0
- package/dist/hooks/useGetRecordForm/useGetRecordForm.js.map +1 -1
- package/dist/locales/en/shared.json +44 -11
- package/dist/locales/fr/shared.json +44 -11
- package/package.json +3 -2
- package/dist/components/Explorer/edit-settings/ColumnItem.js.map +0 -1
- package/dist/components/Explorer/edit-settings/DisplayMode.d.ts +0 -6
- package/dist/components/Explorer/edit-settings/DisplayMode.js +0 -34
- package/dist/components/Explorer/edit-settings/DisplayMode.js.map +0 -1
- package/dist/components/Explorer/edit-settings/DisplayModeTable.d.ts +0 -6
- package/dist/components/Explorer/edit-settings/DisplayModeTable.js +0 -89
- package/dist/components/Explorer/edit-settings/DisplayModeTable.js.map +0 -1
- package/dist/components/Explorer/edit-settings/EditSettingsContext.js.map +0 -1
- package/dist/components/Explorer/edit-settings/EditSettingsContextProvider.js.map +0 -1
- package/dist/components/Explorer/edit-settings/SettingItem.js.map +0 -1
- package/dist/components/Explorer/edit-settings/SettingsPanel.js.map +0 -1
- package/dist/components/Explorer/edit-settings/SidePanel.js.map +0 -1
- package/dist/components/Explorer/edit-settings/ViewSetingsContext.js.map +0 -1
- package/dist/components/Explorer/edit-settings/useEditSettings.js.map +0 -1
- package/dist/components/Explorer/edit-settings/useGetLibraryColumns.d.ts +0 -10
- package/dist/components/Explorer/edit-settings/useGetLibraryColumns.js +0 -24
- package/dist/components/Explorer/edit-settings/useGetLibraryColumns.js.map +0 -1
- package/dist/components/Explorer/edit-settings/useOpenSettings.d.ts +0 -1
- package/dist/components/Explorer/edit-settings/useOpenSettings.js.map +0 -1
- package/dist/components/Explorer/edit-settings/useViewSettingsContext.js.map +0 -1
- package/dist/components/Explorer/edit-settings/viewSettingsReducer.d.ts +0 -43
- package/dist/components/Explorer/edit-settings/viewSettingsReducer.js +0 -58
- package/dist/components/Explorer/edit-settings/viewSettingsReducer.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/index.d.ts +0 -2
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/index.js +0 -6
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/index.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducer.d.ts +0 -138
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducer.js +0 -361
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducer.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducerContext.d.ts +0 -7
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducerContext.js +0 -9
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/standardFieldReducerContext.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/useStandardFieldReducer.d.ts +0 -1
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/useStandardFieldReducer.js +0 -7
- package/dist/components/RecordEdition/EditRecordContent/reducers/standardFieldReducer/useStandardFieldReducer.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.js +0 -14
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/CheckboxInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.js +0 -22
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/ColorInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.js +0 -22
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/DateInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.js +0 -19
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/EncryptedInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.js +0 -32
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/NumberInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.js +0 -51
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/RichTextEditorInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.d.ts +0 -3
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.js +0 -26
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/Inputs/TextInput.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueDisplayHandler.d.ts +0 -13
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueDisplayHandler.js +0 -90
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueDisplayHandler.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/ColorPickerBlock.d.ts +0 -7
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/ColorPickerBlock.js +0 -45
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/ColorPickerBlock.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/StandardFieldValueRead.d.ts +0 -9
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/StandardFieldValueRead.js +0 -141
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/StandardFieldValueRead/StandardFieldValueRead.js.map +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/index.d.ts +0 -1
- package/dist/components/RecordEdition/EditRecordContent/uiElements/StandardField/StandardFieldValue/StandardFieldValueDisplayHandler/index.js.map +0 -1
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContext.d.ts +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContext.js +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContextProvider.d.ts +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContextProvider.js +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/SidePanel.d.ts +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useEditSettings.d.ts +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useEditSettings.js +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingItem.d.ts +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingItem.js +0 -0
- /package/dist/components/Explorer/{edit-settings → manage-view-settings/store-view-settings}/useViewSettingsContext.d.ts +0 -0
|
@@ -0,0 +1,100 @@
|
|
|
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
|
+
import { useSharedTranslation } from '../../../../../hooks/useSharedTranslation';
|
|
6
|
+
import { KitButton, KitDivider, KitInput, KitSelect, KitSpace } from 'aristid-ds';
|
|
7
|
+
import { FaCheck, FaClock, FaTrash } from 'react-icons/fa';
|
|
8
|
+
import { useViewSettingsContext } from '../../store-view-settings/useViewSettingsContext';
|
|
9
|
+
import { ViewSettingsActionTypes } from '../../store-view-settings/viewSettingsReducer';
|
|
10
|
+
import styled from 'styled-components';
|
|
11
|
+
// TODO : This is an exemple file showing ho to customize dropdown Panel content. Don't mind the content of the file, missing types,... it's just an example.
|
|
12
|
+
const conditions = [
|
|
13
|
+
{
|
|
14
|
+
label: 'Egal à',
|
|
15
|
+
value: 'eq'
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
label: 'Différent de',
|
|
19
|
+
value: 'neq'
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
label: 'Commence par',
|
|
23
|
+
value: 'start'
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
label: 'Contient',
|
|
27
|
+
value: 'contains'
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
label: 'Ne contient pas',
|
|
31
|
+
value: 'not_contains'
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
label: 'Est dans la liste',
|
|
35
|
+
value: 'in'
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
label: "N'est pas dans la liste",
|
|
39
|
+
value: 'not_in'
|
|
40
|
+
}
|
|
41
|
+
];
|
|
42
|
+
const attributeValuesList = ['Value 1', 'Value 2', 'Value 3', 'Value 4', 'Value 5'];
|
|
43
|
+
const ValueListItemValueLi = styled.li `
|
|
44
|
+
display: flex;
|
|
45
|
+
align-items: center;
|
|
46
|
+
min-height: 32px;
|
|
47
|
+
height: 32px;
|
|
48
|
+
border-radius: calc(var(--general-border-radius-s) * 1px);
|
|
49
|
+
cursor: pointer;
|
|
50
|
+
|
|
51
|
+
&.selected {
|
|
52
|
+
color: var(--components-Icon-colors-icon-on, var(--general-utilities-main-default));
|
|
53
|
+
background-color: var(--components-Icon-colors-background-on, var(--general-utilities-main-light));
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.label {
|
|
57
|
+
flex: 1;
|
|
58
|
+
padding: 0 calc(var(--general-spacing-xs) * 1px);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.check {
|
|
62
|
+
flex: 0;
|
|
63
|
+
padding: 0 calc(var(--general-spacing-xs) * 1px);
|
|
64
|
+
}
|
|
65
|
+
`;
|
|
66
|
+
export const SimpleFilterDropdown = ({ filter, attribute }) => {
|
|
67
|
+
const { t } = useSharedTranslation();
|
|
68
|
+
const { dispatch } = useViewSettingsContext();
|
|
69
|
+
const updateFilter = data => {
|
|
70
|
+
dispatch({
|
|
71
|
+
type: ViewSettingsActionTypes.CHANGE_FILTER_CONFIG,
|
|
72
|
+
payload: {
|
|
73
|
+
id: filter.id,
|
|
74
|
+
field: filter.field,
|
|
75
|
+
condition: data.condition,
|
|
76
|
+
values: data.values
|
|
77
|
+
}
|
|
78
|
+
});
|
|
79
|
+
};
|
|
80
|
+
const onconditionChanged = condition => {
|
|
81
|
+
updateFilter({ ...filter, condition });
|
|
82
|
+
};
|
|
83
|
+
const onValueClick = value => {
|
|
84
|
+
let newValues = [...filter.values];
|
|
85
|
+
if (filter.values.includes(value)) {
|
|
86
|
+
newValues = filter.values.filter(v => v !== value);
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
89
|
+
if (attribute.multiple_values) {
|
|
90
|
+
newValues = [...filter.values, value];
|
|
91
|
+
}
|
|
92
|
+
else {
|
|
93
|
+
newValues = [value];
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
updateFilter({ ...filter, values: newValues });
|
|
97
|
+
};
|
|
98
|
+
return (_jsxs(KitSpace, { size: "xxs", direction: "vertical", children: [_jsx(KitSelect, { options: conditions, onChange: onconditionChanged, value: filter.condition }), _jsx(KitInput, { placeholder: String(t('search')) }), _jsx("ul", { children: attributeValuesList.map(value => (_jsxs(ValueListItemValueLi, { onClick: () => onValueClick(value), className: filter.values.includes(value) ? 'selected' : '', children: [_jsx("span", { className: "label", children: value }), filter.values.includes(value) && (_jsx("span", { className: "check", children: _jsx(FaCheck, {}) }))] }, value))) }), _jsx(KitDivider, { noMargin: true }), _jsx(KitButton, { type: "link", icon: _jsx(FaClock, {}), children: "R\u00E9initialiser le filtre" }), _jsx(KitButton, { type: "link", icon: _jsx(FaTrash, {}), children: "Supprimer" })] }));
|
|
99
|
+
};
|
|
100
|
+
//# sourceMappingURL=SimpleFilterDropDown.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SimpleFilterDropDown.js","sourceRoot":"","sources":["../../../../../../src/components/Explorer/manage-view-settings/filter-items/filter-type/SimpleFilterDropDown.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAC,SAAS,EAAE,UAAU,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAC,MAAM,YAAY,CAAC;AAEhF,OAAO,EAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAC,MAAM,gBAAgB,CAAC;AACzD,OAAO,EAAC,sBAAsB,EAAC,MAAM,kDAAkD,CAAC;AACxF,OAAO,EAAkB,uBAAuB,EAAC,MAAM,+CAA+C,CAAC;AACvG,OAAO,MAAM,MAAM,mBAAmB,CAAC;AAEvC,6JAA6J;AAE7J,MAAM,UAAU,GAAG;IACf;QACI,KAAK,EAAE,QAAQ;QACf,KAAK,EAAE,IAAI;KACd;IACD;QACI,KAAK,EAAE,cAAc;QACrB,KAAK,EAAE,KAAK;KACf;IACD;QACI,KAAK,EAAE,cAAc;QACrB,KAAK,EAAE,OAAO;KACjB;IACD;QACI,KAAK,EAAE,UAAU;QACjB,KAAK,EAAE,UAAU;KACpB;IACD;QACI,KAAK,EAAE,iBAAiB;QACxB,KAAK,EAAE,cAAc;KACxB;IACD;QACI,KAAK,EAAE,mBAAmB;QAC1B,KAAK,EAAE,IAAI;KACd;IACD;QACI,KAAK,EAAE,yBAAyB;QAChC,KAAK,EAAE,QAAQ;KAClB;CACJ,CAAC;AAEF,MAAM,mBAAmB,GAAG,CA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er, ViewSettingsActionTypes } from './store-view-settings/viewSettingsReducer';
|
|
2
|
+
export type { IViewSettingsState, IViewSettingsAction } from './store-view-settings/viewSettingsReducer';
|
|
3
|
+
export { ViewSettingsContext } from './store-view-settings/ViewSettingsContext';
|
|
4
|
+
export { viewSettingsInitialState, defaultPageSizeOptions } from './store-view-settings/viewSettingsInitialState';
|
|
5
|
+
export { useOpenViewSettings } from './open-view-settings/useOpenViewSettings';
|
|
6
|
+
export { SidePanel } from './open-view-settings/SidePanel';
|
|
7
|
+
export { useEditSettings } from './open-view-settings/useEditSettings';
|
|
8
|
+
export { EditSettingsContextProvider } from './open-view-settings/EditSettingsContextProvider';
|
|
@@ -0,0 +1,11 @@
|
|
|
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.txtexport {useViewSettingsContext} from './store-view-settings/useViewSettingsContext';
|
|
4
|
+
export { viewSettingsReducer, ViewSettingsActionTypes } from './store-view-settings/viewSettingsReducer';
|
|
5
|
+
export { ViewSettingsContext } from './store-view-settings/ViewSettingsContext';
|
|
6
|
+
export { viewSettingsInitialState, defaultPageSizeOptions } from './store-view-settings/viewSettingsInitialState';
|
|
7
|
+
export { useOpenViewSettings } from './open-view-settings/useOpenViewSettings';
|
|
8
|
+
export { SidePanel } from './open-view-settings/SidePanel';
|
|
9
|
+
export { useEditSettings } from './open-view-settings/useEditSettings';
|
|
10
|
+
export { EditSettingsContextProvider } from './open-view-settings/EditSettingsContextProvider';
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/Explorer/manage-view-settings/index.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,0JAA0J;AAC1J,OAAO,EAAC,mBAAmB,EAAE,uBAAuB,EAAC,MAAM,2CAA2C,CAAC;AAEvG,OAAO,EAAC,mBAAmB,EAAC,MAAM,2CAA2C,CAAC;AAC9E,OAAO,EAAC,wBAAwB,EAAE,sBAAsB,EAAC,MAAM,gDAAgD,CAAC;AAEhH,OAAO,EAAC,mBAAmB,EAAC,MAAM,0CAA0C,CAAC;AAC7E,OAAO,EAAC,SAAS,EAAC,MAAM,gCAAgC,CAAC;AACzD,OAAO,EAAC,eAAe,EAAC,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAC,2BAA2B,EAAC,MAAM,kDAAkD,CAAC"}
|
package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EditSettingsContext.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,aAAa,EAAY,MAAM,OAAO,CAAC;AAe/C,MAAM,CAAC,MAAM,mBAAmB,GAAG,aAAa,CAAuB;IACnE,iBAAiB,EAAE,GAAG,EAAE;QACpB,MAAM,IAAI,KAAK,CAAC,iBAAiB,CAAC,CAAC;IACvC,CAAC;IACD,cAAc,EAAE,IAAI;IACpB,YAAY,EAAE,IAAI;IAClB,OAAO,EAAE,GAAG,EAAE;QACV,MAAM,IAAI,KAAK,CAAC,iBAAiB,CAAC,CAAC;IACvC,CAAC;CACJ,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EditSettingsContextProvider.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAoB,QAAQ,EAAC,MAAM,OAAO,CAAC;AAClD,OAAO,EAAC,mBAAmB,EAAuB,MAAM,uBAAuB,CAAC;AAMhF,MAAM,CAAC,MAAM,2BAA2B,GAAyD,CAAC,EAC9F,QAAQ,EACR,YAAY,EACf,EAAE,EAAE;IACD,MAAM,CAAC,cAAc,EAAE,iBAAiB,CAAC,GAAG,QAAQ,CAAyC,IAAI,CAAC,CAAC;IACnG,MAAM,OAAO,GAAG,GAAG,EAAE,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC;IAE9C,OAAO,CACH,KAAC,mBAAmB,CAAC,QAAQ,IACzB,KAAK,EAAE;YACH,cAAc;YACd,iBAAiB;YACjB,YAAY,EAAE,YAAY,IAAI,IAAI;YAClC,OAAO;SACV,YAEA,QAAQ,GACkB,CAClC,CAAC;AACN,CAAC,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { KitSidePanel } from 'aristid-ds';
|
|
3
3
|
import { useEditSettings } from './useEditSettings';
|
|
4
|
-
import { useSharedTranslation } from '
|
|
4
|
+
import { useSharedTranslation } from '../../../../hooks/useSharedTranslation';
|
|
5
5
|
export const SidePanel = () => {
|
|
6
6
|
const { t } = useSharedTranslation();
|
|
7
7
|
const { activeSettings, onClose } = useEditSettings();
|
|
@@ -12,7 +12,7 @@ export const SidePanel = () => {
|
|
|
12
12
|
const makeA11yBackButton = {
|
|
13
13
|
title: String(t('explorer.back')) /* TODO: avoid transform null to 'null' */
|
|
14
14
|
};
|
|
15
|
-
return (_jsx(KitSidePanel, {
|
|
15
|
+
return (_jsx(KitSidePanel, { initialOpen: true, floating: true, closable: true, idCardProps: { title: activeSettings.title }, leftActionProps: activeSettings.onClickLeftButton
|
|
16
16
|
? { onClick: activeSettings.onClickLeftButton, ...makeA11yBackButton }
|
|
17
17
|
: undefined, onClose: onClose, children: activeSettings.content }));
|
|
18
18
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SidePanel.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/open-view-settings/SidePanel.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAC,YAAY,EAAC,MAAM,YAAY,CAAC;AACxC,OAAO,EAAC,eAAe,EAAC,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AAEpE,MAAM,CAAC,MAAM,SAAS,GAAsB,GAAG,EAAE;IAC7C,MAAM,EAAC,CAAC,EAAC,GAAG,oBAAoB,EAAE,CAAC;IAEnC,MAAM,EAAC,cAAc,EAAE,OAAO,EAAC,GAAG,eAAe,EAAE,CAAC;IAEpD,IAAI,CAAC,cAAc,EAAE,CAAC;QAClB,OAAO,IAAI,CAAC;IAChB,CAAC;IAED,gEAAgE;IAEhE,MAAM,kBAAkB,GAA4C;QAChE,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,0CAA0C;KAC/E,CAAC;IAEF,OAAO,CACH,KAAC,YAAY,IACT,WAAW,QACX,QAAQ,QACR,QAAQ,QACR,WAAW,EAAE,EAAC,KAAK,EAAE,cAAc,CAAC,KAAK,EAAC,EAC1C,eAAe,EACX,cAAc,CAAC,iBAAiB;YAC5B,CAAC,CAAC,EAAC,OAAO,EAAE,cAAc,CAAC,iBAAiB,EAAE,GAAG,kBAAkB,EAAC;YACpE,CAAC,CAAC,SAAS,EAEnB,OAAO,EAAE,OAAO,YAEf,cAAc,CAAC,OAAO,GACZ,CAClB,CAAC;AACN,CAAC,CAAC"}
|
package/dist/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useEditSettings.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,UAAU,EAAC,MAAM,OAAO,CAAC;AACjC,OAAO,EAAC,mBAAmB,EAAC,MAAM,uBAAuB,CAAC;AAE1D,MAAM,CAAC,MAAM,eAAe,GAAG,GAAG,EAAE,CAAC,UAAU,CAAC,mBAAmB,CAAC,CAAC"}
|
|
@@ -4,16 +4,18 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
4
4
|
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
5
5
|
import { KitButton } from 'aristid-ds';
|
|
6
6
|
import { FaSlidersH } from 'react-icons/fa';
|
|
7
|
-
import { useSharedTranslation } from '
|
|
8
|
-
import { SettingsPanel } from '
|
|
7
|
+
import { useSharedTranslation } from '../../../../hooks/useSharedTranslation';
|
|
8
|
+
import { SettingsPanel } from '../router-menu/SettingsPanel';
|
|
9
9
|
import { useEditSettings } from './useEditSettings';
|
|
10
|
-
export const
|
|
10
|
+
export const useOpenViewSettings = (library) => {
|
|
11
11
|
const { setActiveSettings } = useEditSettings();
|
|
12
12
|
const { t } = useSharedTranslation();
|
|
13
13
|
const _openSettingsPanel = () => setActiveSettings({
|
|
14
14
|
content: _jsx(SettingsPanel, { library: library }),
|
|
15
15
|
title: t('explorer.settings')
|
|
16
16
|
});
|
|
17
|
-
return
|
|
17
|
+
return {
|
|
18
|
+
viewSettingsButton: (_jsx(KitButton, { type: "tertiary", color: "neutral", icon: _jsx(FaSlidersH, {}), onClick: _openSettingsPanel, title: String(t('explorer.settings')) /* TODO: avoid transform null to 'null' */ }))
|
|
19
|
+
};
|
|
18
20
|
};
|
|
19
|
-
//# sourceMappingURL=
|
|
21
|
+
//# sourceMappingURL=useOpenViewSettings.js.map
|
package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useOpenViewSettings.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/open-view-settings/useOpenViewSettings.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,SAAS,EAAC,MAAM,YAAY,CAAC;AACrC,OAAO,EAAC,UAAU,EAAC,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAC,aAAa,EAAC,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAC,eAAe,EAAC,MAAM,mBAAmB,CAAC;AAElD,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,OAAe,EAAE,EAAE;IACnD,MAAM,EAAC,iBAAiB,EAAC,GAAG,eAAe,EAAE,CAAC;IAC9C,MAAM,EAAC,CAAC,EAAC,GAAG,oBAAoB,EAAE,CAAC;IAEnC,MAAM,kBAAkB,GAAG,GAAG,EAAE,CAC5B,iBAAiB,CAAC;QACd,OAAO,EAAE,KAAC,aAAa,IAAC,OAAO,EAAE,OAAO,GAAI;QAC5C,KAAK,EAAE,CAAC,CAAC,mBAAmB,CAAC;KAChC,CAAC,CAAC;IAEP,OAAO;QACH,kBAAkB,EAAE,CAChB,KAAC,SAAS,IACN,IAAI,EAAC,UAAU,EACf,KAAK,EAAC,SAAS,EACf,IAAI,EAAE,KAAC,UAAU,KAAG,EACpB,OAAO,EAAE,kBAAkB,EAC3B,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,0CAA0C,GAClF,CACL;KACJ,CAAC;AACN,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SettingItem.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/router-menu/SettingItem.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,aAAa,EAAC,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAC,cAAc,EAAC,MAAM,gBAAgB,CAAC;AAC9C,OAAO,MAAM,MAAM,mBAAmB,CAAC;AAEvC,MAAM,WAAW,GAAG,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC,CAAA;;CAE7C,CAAC;AAEF,MAAM,uBAAuB,GAAG,MAAM,CAAC,EAAE,CAAA;;;;;;;;;;;;;;;;;;;;;;;;cAwB3B,WAAW;;;;;;;;;;;;;;;;;;CAkBxB,CAAC;AASF,MAAM,CAAC,MAAM,WAAW,GAAyC,CAAC,EAAC,IAAI,EAAE,KAAK,EAAE,KAAK,GAAG,EAAE,EAAE,OAAO,EAAC,EAAE,EAAE,CAAC,CACrG,KAAC,uBAAuB,cACpB,kBAAQ,OAAO,EAAE,OAAO,aACnB,IAAI,EACL,KAAC,aAAa,CAAC,IAAI,IAAC,IAAI,EAAC,WAAW,EAAC,QAAQ,QAAC,SAAS,EAAC,OAAO,YAC1D,KAAK,GACW,EACrB,KAAC,WAAW,IAAC,IAAI,EAAC,WAAW,EAAC,QAAQ,QAAC,SAAS,EAAC,OAAO,YACnD,KAAK,GACI,EACd,KAAC,cAAc,KAAG,IACb,GACa,CAC7B,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FunctionComponent } from 'react';
|
|
2
|
-
export type SettingsPanelPages = '
|
|
2
|
+
export type SettingsPanelPages = 'router-menu' | 'configure-display' | 'sort-items' | 'filter-items';
|
|
3
3
|
interface ISettingsPanelProps {
|
|
4
4
|
library: string;
|
|
5
5
|
}
|
package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingsPanel.js
RENAMED
|
@@ -6,10 +6,13 @@ import styled from 'styled-components';
|
|
|
6
6
|
import { useState } from 'react';
|
|
7
7
|
import { KitTypography } from 'aristid-ds';
|
|
8
8
|
import { FaFilter, FaList, FaSortAlphaDown } from 'react-icons/fa';
|
|
9
|
-
import { useSharedTranslation } from '
|
|
10
|
-
import {
|
|
9
|
+
import { useSharedTranslation } from '../../../../hooks/useSharedTranslation';
|
|
10
|
+
import { useEditSettings } from '../open-view-settings/useEditSettings';
|
|
11
|
+
import { ConfigureDisplay } from '../configure-display/ConfigureDisplay';
|
|
12
|
+
import { SortItems } from '../sort-items/SortItems';
|
|
11
13
|
import { SettingItem } from './SettingItem';
|
|
12
|
-
import {
|
|
14
|
+
import { FilterItems } from '../filter-items/FilterItems';
|
|
15
|
+
import { useViewSettingsContext } from '../store-view-settings/useViewSettingsContext';
|
|
13
16
|
const ContentWrapperStyledDiv = styled.div `
|
|
14
17
|
display: flex;
|
|
15
18
|
flex-direction: column;
|
|
@@ -21,7 +24,8 @@ const ConfigurationStyledMenu = styled.menu `
|
|
|
21
24
|
export const SettingsPanel = ({ library }) => {
|
|
22
25
|
const { t } = useSharedTranslation();
|
|
23
26
|
const { setActiveSettings, activeSettings } = useEditSettings();
|
|
24
|
-
const
|
|
27
|
+
const { view: { filters } } = useViewSettingsContext();
|
|
28
|
+
const [currentPage, setCurrentPage] = useState('router-menu');
|
|
25
29
|
const _goToAdvancedSettingsPage = (page) => {
|
|
26
30
|
if (!activeSettings) {
|
|
27
31
|
throw Error('Should not be able to change side pane page if there is no side panel!');
|
|
@@ -38,16 +42,12 @@ export const SettingsPanel = ({ library }) => {
|
|
|
38
42
|
pageName: page,
|
|
39
43
|
title: t(`explorer.${page}`),
|
|
40
44
|
onClickLeftButton: () => {
|
|
41
|
-
const rootPanel = { pageName: '
|
|
45
|
+
const rootPanel = { pageName: 'router-menu', title: t('explorer.settings') };
|
|
42
46
|
_changePanelPage(rootPanel);
|
|
43
47
|
}
|
|
44
48
|
});
|
|
45
49
|
};
|
|
46
50
|
// TODO: look for MemoryRouter
|
|
47
|
-
return (_jsxs(ContentWrapperStyledDiv, { children: [currentPage === '
|
|
48
|
-
/* TODO: not implemented yet */
|
|
49
|
-
} }), _jsx(SettingItem, { icon: _jsx(FaSortAlphaDown, {}), title: t('explorer.sort'), onClick: () => {
|
|
50
|
-
/* TODO: not implemented yet */
|
|
51
|
-
} })] })] })), currentPage === 'display-mode' && _jsx(DisplayMode, { library: library })] }));
|
|
51
|
+
return (_jsxs(ContentWrapperStyledDiv, { children: [currentPage === 'router-menu' && (_jsxs("nav", { children: [_jsx(KitTypography.Title, { level: "h4", children: t('explorer.router-menu') }), _jsxs(ConfigurationStyledMenu, { children: [_jsx(SettingItem, { icon: _jsx(FaList, {}), title: t('explorer.configure-display'), onClick: () => _goToAdvancedSettingsPage('configure-display') }), _jsx(SettingItem, { icon: _jsx(FaFilter, {}), title: t('explorer.filters'), value: String(t('explorer.active-items-number', { count: filters.length })), onClick: () => _goToAdvancedSettingsPage('filter-items') }), _jsx(SettingItem, { icon: _jsx(FaSortAlphaDown, {}), title: t('explorer.sort-items'), onClick: () => _goToAdvancedSettingsPage('sort-items') })] })] })), currentPage === 'configure-display' && _jsx(ConfigureDisplay, { libraryId: library }), currentPage === 'sort-items' && _jsx(SortItems, { libraryId: library }), currentPage === 'filter-items' && _jsx(FilterItems, { libraryId: library })] }));
|
|
52
52
|
};
|
|
53
53
|
//# sourceMappingURL=SettingsPanel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SettingsPanel.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/router-menu/SettingsPanel.tsx"],"names":[],"mappings":";AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,MAAM,MAAM,mBAAmB,CAAC;AACvC,OAAO,EAAoB,QAAQ,EAAC,MAAM,OAAO,CAAC;AAClD,OAAO,EAAC,aAAa,EAAC,MAAM,YAAY,CAAC;AACzC,OAAO,EAAC,QAAQ,EAAE,MAAM,EAAE,eAAe,EAAC,MAAM,gBAAgB,CAAC;AACjE,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAC,eAAe,EAAC,MAAM,uCAAuC,CAAC;AACtE,OAAO,EAAC,gBAAgB,EAAC,MAAM,uCAAuC,CAAC;AACvE,OAAO,EAAC,SAAS,EAAC,MAAM,yBAAyB,CAAC;AAClD,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAC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|
|
2
|
+
import { FaEye, FaEyeSlash, FaSearch } from 'react-icons/fa';
|
|
3
|
+
import { KitInput, KitTypography } from 'aristid-ds';
|
|
4
|
+
import styled from 'styled-components';
|
|
5
|
+
import { useSharedTranslation } from '../../../../hooks/useSharedTranslation';
|
|
6
|
+
import { SortOrder } from '../../../../_gqlTypes';
|
|
7
|
+
import { closestCenter, DndContext, KeyboardSensor, PointerSensor, useSensor, useSensors } from '@dnd-kit/core';
|
|
8
|
+
import { SortableContext, sortableKeyboardCoordinates, verticalListSortingStrategy } from '@dnd-kit/sortable';
|
|
9
|
+
import { useAttributeDetailsData } from '../_shared/useAttributeDetailsData';
|
|
10
|
+
import { ViewSettingsActionTypes } from '../store-view-settings/viewSettingsReducer';
|
|
11
|
+
import { useViewSettingsContext } from '../store-view-settings/useViewSettingsContext';
|
|
12
|
+
import { SortListItem } from './SortListItem';
|
|
13
|
+
const StyledList = styled.ul `
|
|
14
|
+
padding: calc(var(--general-spacing-s) * 1px) 0;
|
|
15
|
+
margin: 0;
|
|
16
|
+
list-style: none;
|
|
17
|
+
color: var(--general-utilities-text-primary);
|
|
18
|
+
`;
|
|
19
|
+
const StyledEyeSlash = styled(FaEyeSlash) `
|
|
20
|
+
color: var(--general-utilities-neutral-dark);
|
|
21
|
+
`;
|
|
22
|
+
const StyledFaEye = styled(FaEye) `
|
|
23
|
+
color: var(--general-utilities-neutral-deepDark);
|
|
24
|
+
`;
|
|
25
|
+
export const SortItems = ({ libraryId }) => {
|
|
26
|
+
const { t } = useSharedTranslation();
|
|
27
|
+
const { view: { sort }, dispatch } = useViewSettingsContext();
|
|
28
|
+
const { onSearchChanged, searchFilteredColumnsIds, attributeDetailsById } = useAttributeDetailsData(libraryId);
|
|
29
|
+
const sensors = useSensors(useSensor(PointerSensor), useSensor(KeyboardSensor, {
|
|
30
|
+
coordinateGetter: sortableKeyboardCoordinates
|
|
31
|
+
}));
|
|
32
|
+
const _toggleColumnVisibility = (attributeId) => () => {
|
|
33
|
+
const isAttributeAlreadySorting = sort.some(sortItem => sortItem.attributeId === attributeId);
|
|
34
|
+
if (isAttributeAlreadySorting) {
|
|
35
|
+
dispatch({
|
|
36
|
+
type: ViewSettingsActionTypes.REMOVE_SORT,
|
|
37
|
+
payload: {
|
|
38
|
+
attributeId
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
else {
|
|
43
|
+
dispatch({
|
|
44
|
+
type: ViewSettingsActionTypes.ADD_SORT,
|
|
45
|
+
payload: {
|
|
46
|
+
order: SortOrder.asc,
|
|
47
|
+
attributeId
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
const _changeOrderActiveFilterTo = (attributeId) => (order) => {
|
|
53
|
+
dispatch({
|
|
54
|
+
type: ViewSettingsActionTypes.CHANGE_SORT_ORDER,
|
|
55
|
+
payload: {
|
|
56
|
+
attributeId,
|
|
57
|
+
order
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
};
|
|
61
|
+
const _handleDragEnd = ({ active: draggedElement, over: dropTarget }) => {
|
|
62
|
+
const indexFrom = activeFilters.findIndex(({ attributeId }) => attributeId === String(draggedElement.id));
|
|
63
|
+
const indexTo = activeFilters.findIndex(({ attributeId }) => attributeId === String(dropTarget?.id));
|
|
64
|
+
if (!dropTarget || indexFrom === indexTo || indexTo === -1) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
dispatch({ type: ViewSettingsActionTypes.MOVE_SORT, payload: { indexFrom, indexTo } });
|
|
68
|
+
};
|
|
69
|
+
const activeFilters = sort.filter(({ attributeId }) => searchFilteredColumnsIds.includes(attributeId));
|
|
70
|
+
const inactiveFilters = searchFilteredColumnsIds.filter(attributeId => sort.every(sortItem => sortItem.attributeId !== attributeId));
|
|
71
|
+
return (_jsxs(_Fragment, { children: [activeFilters.length > 0 && (_jsx(StyledList, { "aria-label": t('explorer.sort-list.active'), children: _jsx(DndContext, { sensors: sensors, collisionDetection: closestCenter, onDragEnd: _handleDragEnd, children: _jsx(SortableContext, { items: activeFilters.map(({ attributeId }) => ({ id: attributeId })), strategy: verticalListSortingStrategy, children: activeFilters.map(({ attributeId, order }) => (_jsx(SortListItem, { attributeId: attributeId, isDraggable: true, filterChipProps: {
|
|
72
|
+
label: attributeDetailsById[attributeId].label,
|
|
73
|
+
values: [
|
|
74
|
+
order === SortOrder.asc
|
|
75
|
+
? t('explorer.sort-ascending')
|
|
76
|
+
: t('explorer.sort-descending')
|
|
77
|
+
],
|
|
78
|
+
expandable: true,
|
|
79
|
+
dropDownProps: {
|
|
80
|
+
menu: {
|
|
81
|
+
selectable: true,
|
|
82
|
+
selectedKeys: [order],
|
|
83
|
+
items: [
|
|
84
|
+
{
|
|
85
|
+
key: SortOrder.asc,
|
|
86
|
+
label: t('explorer.sort-ascending')
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
key: SortOrder.desc,
|
|
90
|
+
label: t('explorer.sort-descending')
|
|
91
|
+
}
|
|
92
|
+
],
|
|
93
|
+
onSelect: ({ selectedKeys: [newOrder] }) => _changeOrderActiveFilterTo(attributeId)(newOrder),
|
|
94
|
+
onDeselect: ({ selectedKeys: [newOrder] }) => _changeOrderActiveFilterTo(attributeId)(newOrder)
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}, visibilityButtonProps: {
|
|
98
|
+
icon: _jsx(StyledFaEye, {}),
|
|
99
|
+
title: String(t('explorer.hide')),
|
|
100
|
+
onClick: _toggleColumnVisibility(attributeId)
|
|
101
|
+
} }, attributeId))) }) }) })), _jsx(KitTypography.Title, { level: "h4", children: t('explorer.available-attributes') }), _jsx(KitInput, { placeholder: String(t('global.search')), onChange: onSearchChanged, allowClear: true, prefix: _jsx(FaSearch, {}) }), _jsx(StyledList, { "aria-label": t('explorer.sort-list.inactive'), children: inactiveFilters.map(attributeId => (_jsx(SortListItem, { attributeId: attributeId, filterChipProps: {
|
|
102
|
+
label: attributeDetailsById[attributeId].label
|
|
103
|
+
}, visibilityButtonProps: {
|
|
104
|
+
icon: _jsx(StyledEyeSlash, {}),
|
|
105
|
+
title: String(t('explorer.show')),
|
|
106
|
+
onClick: _toggleColumnVisibility(attributeId)
|
|
107
|
+
} }, attributeId))) })] }));
|
|
108
|
+
};
|
|
109
|
+
//# sourceMappingURL=SortItems.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SortItems.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/sort-items/SortItems.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAC,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAC,MAAM,gBAAgB,CAAC;AAC3D,OAAO,EAAC,QAAQ,EAAE,aAAa,EAAC,MAAM,YAAY,CAAC;AACnD,OAAO,MAAM,MAAM,mBAAmB,CAAC;AACvC,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAC,SAAS,EAAC,MAAM,eAAe,CAAC;AACxC,OAAO,EACH,aAAa,EACb,UAAU,EAEV,cAAc,EACd,aAAa,EACb,SAAS,EACT,UAAU,EACb,MAAM,eAAe,CAAC;AACvB,OAAO,EAAC,eAAe,EAAE,2BAA2B,EAAE,2BAA2B,EAAC,MAAM,mBAAmB,CAAC;AAC5G,OAAO,EAAC,uBAAuB,EAAC,MAAM,oCAAoC,CAAC;AAC3E,OAAO,EAAC,uBAAuB,EAAC,MAAM,4CAA4C,CAAC;AACnF,OAAO,EAAC,sBAAsB,EAAC,MAAM,+CAA+C,CAAC;AACrF,OAAO,EAAC,YAAY,EAAC,MAAM,gBAAgB,CAAC;AAE5C,MAAM,UAAU,GAAG,MAAM,CAAC,EAAE,CAAA;;;;;CAK3B,CAAC;AAEF,MAAM,cAAc,GAAG,MAAM,CAAC,UAAU,CAAC,CAAA;;CAExC,CAAC;AAEF,MAAM,WAAW,GAAG,MAAM,CAAC,KAAK,CAAC,CAAA;;CAEhC,CAAC;AAEF,MAAM,CAAC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uBAAuB,CAAC,WAAW,CAAC;6BAChD,IApCI,WAAW,CAqClB,CACL,CAAC,GACY,GACT,GACJ,CAChB,EACD,KAAC,aAAa,CAAC,KAAK,IAAC,KAAK,EAAC,IAAI,YAAE,CAAC,CAAC,+BAA+B,CAAC,GAAuB,EAC1F,KAAC,QAAQ,IACL,WAAW,EAAE,MAAM,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,EACvC,QAAQ,EAAE,eAAe,EACzB,UAAU,QACV,MAAM,EAAE,KAAC,QAAQ,KAAG,GACtB,EACF,KAAC,UAAU,kBAAa,CAAC,CAAC,6BAA6B,CAAC,YACnD,eAAe,CAAC,GAAG,CAAC,WAAW,CAAC,EAAE,CAAC,CAChC,KAAC,YAAY,IAET,WAAW,EAAE,WAAW,EACxB,eAAe,EAAE;wBACb,KAAK,EAAE,oBAAoB,CAAC,WAAW,CAAC,CAAC,KAAK;qBACjD,EACD,qBAAqB,EAAE;wBACnB,IAAI,EAAE,KAAC,cAAc,KAAG;wBACxB,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC;wBACjC,OAAO,EAAE,uBAAuB,CAAC,WAAW,CAAC;qBAChD,IATI,WAAW,CAUlB,CACL,CAAC,GACO,IACd,CACN,CAAC;AACN,CAAC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ComponentProps, FunctionComponent } from 'react';
|
|
2
|
+
import { KitButton, KitFilter } from 'aristid-ds';
|
|
3
|
+
interface IActiveFilterListItemProps {
|
|
4
|
+
attributeId: string;
|
|
5
|
+
isDraggable?: true;
|
|
6
|
+
filterChipProps: Pick<ComponentProps<typeof KitFilter>, 'label' | 'values' | 'expandable' | 'dropDownProps'>;
|
|
7
|
+
visibilityButtonProps: Pick<ComponentProps<typeof KitButton>, 'onClick' | 'icon' | 'title'>;
|
|
8
|
+
}
|
|
9
|
+
export declare const SortListItem: FunctionComponent<IActiveFilterListItemProps>;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import styled from 'styled-components';
|
|
3
|
+
import { FaGripLines } from 'react-icons/fa';
|
|
4
|
+
import { KitButton, KitFilter } from 'aristid-ds';
|
|
5
|
+
import { useSortable } from '@dnd-kit/sortable';
|
|
6
|
+
import { CSS } from '@dnd-kit/utilities';
|
|
7
|
+
const StyledSortListItem = styled.li `
|
|
8
|
+
display: flex;
|
|
9
|
+
justify-content: space-between;
|
|
10
|
+
align-items: center;
|
|
11
|
+
|
|
12
|
+
div {
|
|
13
|
+
display: flex;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
align-items: center;
|
|
16
|
+
gap: calc(var(--general-spacing-xs) * 1px);
|
|
17
|
+
}
|
|
18
|
+
`;
|
|
19
|
+
const StyledDragHandle = styled.span `
|
|
20
|
+
display: flex;
|
|
21
|
+
align-items: center;
|
|
22
|
+
cursor: ${props => (props.$isDragging ? 'grabbing' : 'grab')};
|
|
23
|
+
`;
|
|
24
|
+
export const SortListItem = ({ attributeId, isDraggable, visibilityButtonProps, filterChipProps }) => {
|
|
25
|
+
const { attributes, listeners, setNodeRef, transform, transition, isDragging } = useSortable({ id: attributeId });
|
|
26
|
+
const style = {
|
|
27
|
+
transform: CSS.Transform.toString(transform),
|
|
28
|
+
transition
|
|
29
|
+
};
|
|
30
|
+
return (_jsxs(StyledSortListItem, { ref: setNodeRef, style: style, children: [_jsxs("div", { children: [isDraggable && (_jsx(StyledDragHandle, { ...attributes, ...listeners, "$isDragging": isDragging, children: _jsx(FaGripLines, {}) })), _jsx(KitFilter, { ...filterChipProps }, attributeId)] }), _jsx(KitButton, { size: "m", type: "tertiary", ...visibilityButtonProps })] }));
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=SortListItem.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SortListItem.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-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AAU,KAAK,qBAAqB,GAAI,IAChD,CACxB,CAAC;AACN,CAAC,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Dispatch } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
export declare const viewSettingsInitialState: IViewSettingsState;
|
|
2
|
+
import { IViewSettingsAction, IViewSettingsState } from './viewSettingsReducer';
|
|
4
3
|
export declare const ViewSettingsContext: import("react").Context<{
|
|
5
4
|
view: IViewSettingsState;
|
|
6
5
|
dispatch: Dispatch<IViewSettingsAction>;
|
|
@@ -2,14 +2,10 @@
|
|
|
2
2
|
// This file is released under LGPL V3
|
|
3
3
|
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
4
|
import { createContext } from 'react';
|
|
5
|
-
export const viewSettingsInitialState = {
|
|
6
|
-
displayMode: 'table',
|
|
7
|
-
fields: []
|
|
8
|
-
};
|
|
9
5
|
export const ViewSettingsContext = createContext({
|
|
10
6
|
view: null,
|
|
11
7
|
dispatch: () => {
|
|
12
8
|
throw new Error('useViewSettingsContext must be used inside a <ViewSettingsContext.Provider />');
|
|
13
9
|
}
|
|
14
10
|
});
|
|
15
|
-
//# sourceMappingURL=
|
|
11
|
+
//# sourceMappingURL=ViewSettingsContext.js.map
|
package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ViewSettingsContext.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.tsx"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,aAAa,EAAW,MAAM,OAAO,CAAC;AAG9C,MAAM,CAAC,MAAM,mBAAmB,GAAG,aAAa,CAG7C;IACC,IAAI,EAAE,IAAW;IACjB,QAAQ,EAAE,GAAG,EAAE;QACX,MAAM,IAAI,KAAK,CAAC,+EAA+E,CAAC,CAAC;IACrG,CAAC;CACJ,CAAC,CAAC"}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
// This file is released under LGPL V3
|
|
3
3
|
// License text available at https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
4
4
|
import { useContext } from 'react';
|
|
5
|
-
import { ViewSettingsContext } from './
|
|
5
|
+
import { ViewSettingsContext } from './ViewSettingsContext';
|
|
6
6
|
export const useViewSettingsContext = () => useContext(ViewSettingsContext);
|
|
7
7
|
//# sourceMappingURL=useViewSettingsContext.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useViewSettingsContext.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,sCAAsC;AACtC,sEAAsE;AACtE,OAAO,EAAC,UAAU,EAAC,MAAM,OAAO,CAAC;AACjC,OAAO,EAAC,mBAAmB,EAAC,MAAM,uBAAuB,CAAC;AAE1D,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,EAAE,CAAC,UAAU,CAAC,mBAAmB,CAAC,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export const defaultPageSizeOptions = [20, 50, 100];
|
|
2
|
+
export const defaultMaxFilters = 3;
|
|
3
|
+
export const viewSettingsInitialState = {
|
|
4
|
+
viewType: 'table',
|
|
5
|
+
attributesIds: [],
|
|
6
|
+
fulltextSearch: '',
|
|
7
|
+
sort: [],
|
|
8
|
+
pageSize: defaultPageSizeOptions[0],
|
|
9
|
+
filters: [],
|
|
10
|
+
maxFilters: defaultMaxFilters,
|
|
11
|
+
canAddFilter: true
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=viewSettingsInitialState.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"viewSettingsInitialState.js","sourceRoot":"","sources":["../../../../../src/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,EAAE,EAAE,EAAE,EAAE,GAAG,CAAC,CAAC;AAEpD,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC;AAEnC,MAAM,CAAC,MAAM,wBAAwB,GAAuB;IACxD,QAAQ,EAAE,OAAO;IACjB,aAAa,EAAE,EAAE;IACjB,cAAc,EAAE,EAAE;IAClB,IAAI,EAAE,EAAE;IACR,QAAQ,EAAE,sBAAsB,CAAC,CAAC,CAAC;IACnC,OAAO,EAAE,EAAE;IACX,UAAU,EAAE,iBAAiB;IAC7B,YAAY,EAAE,IAAI;CACrB,CAAC"}
|