geonetwork-ui 2.3.0 → 2.4.0-dev.656babc7
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/esm2022/libs/api/metadata-converter/src/lib/gn4/gn4.converter.mjs +4 -4
- package/esm2022/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.mjs +4 -4
- package/esm2022/libs/api/metadata-converter/src/lib/gn4/metadata-url.service.mjs +4 -4
- package/esm2022/libs/api/metadata-converter/src/lib/gn4/types/index.mjs +2 -1
- package/esm2022/libs/api/metadata-converter/src/lib/gn4/types/keywords.model.mjs +2 -0
- package/esm2022/libs/api/metadata-converter/src/lib/iso19139/read-parts.mjs +1 -1
- package/esm2022/libs/api/metadata-converter/src/lib/iso19139/utils/keyword.mapper.mjs +1 -1
- package/esm2022/libs/api/metadata-converter/src/lib/iso19139/write-parts.mjs +1 -1
- package/esm2022/libs/api/repository/src/lib/gn4/auth/auth.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/auth/gravatar.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/elasticsearch/elasticsearch.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/favorites/favorites.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/gn4-repository.mjs +59 -11
- package/esm2022/libs/api/repository/src/lib/gn4/organizations/organizations-from-groups.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/organizations/organizations-from-metadata.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/platform/gn4-platform.mapper.mjs +14 -6
- package/esm2022/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.mjs +36 -16
- package/esm2022/libs/api/repository/src/lib/gn4/selection/selection.service.mjs +4 -4
- package/esm2022/libs/api/repository/src/lib/gn4/settings/gn4-settings.service.mjs +4 -4
- package/esm2022/libs/common/domain/src/lib/model/record/metadata.model.mjs +1 -1
- package/esm2022/libs/common/domain/src/lib/model/thesaurus/thesaurus.model.mjs +1 -1
- package/esm2022/libs/common/domain/src/lib/platform.service.interface.mjs +1 -1
- package/esm2022/libs/common/domain/src/lib/repository/records-repository.interface.mjs +1 -1
- package/esm2022/libs/data-access/gn4/src/openapi/api/atom.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/customstyle.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/formatters.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/groups.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/harvesters.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/identifiers.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/languages.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/links.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/logos.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/mapservers.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/mapservices.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/me.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/operations.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/pages.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/processes.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/records.api.service.mjs +5 -5
- package/esm2022/libs/data-access/gn4/src/openapi/api/regions.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/registries.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/related.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/search.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/selections.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/site.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/sources.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/standards.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/status.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/tags.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/tools.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/ui.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/userfeedback.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/users.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/usersearches.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api/userselections.api.service.mjs +4 -4
- package/esm2022/libs/data-access/gn4/src/openapi/api.module.mjs +5 -5
- package/esm2022/libs/feature/auth/src/lib/feature-auth.module.mjs +5 -5
- package/esm2022/libs/feature/catalog/src/lib/feature-catalog.module.mjs +5 -5
- package/esm2022/libs/feature/catalog/src/lib/my-org/my-org.service.mjs +4 -4
- package/esm2022/libs/feature/catalog/src/lib/organisations/organisations.component.mjs +4 -4
- package/esm2022/libs/feature/catalog/src/lib/records/records.service.mjs +4 -4
- package/esm2022/libs/feature/catalog/src/lib/site-title/site-title.component.mjs +4 -4
- package/esm2022/libs/feature/catalog/src/lib/source-label/source-label.component.mjs +4 -4
- package/esm2022/libs/feature/catalog/src/lib/sources/sources.service.mjs +4 -4
- package/esm2022/libs/feature/dataviz/src/lib/chart-view/chart-view.component.mjs +4 -4
- package/esm2022/libs/feature/dataviz/src/lib/feature-dataviz.module.mjs +5 -5
- package/esm2022/libs/feature/dataviz/src/lib/figure/figure-container/figure-container.component.mjs +4 -4
- package/esm2022/libs/feature/dataviz/src/lib/figure/figure.service.mjs +4 -4
- package/esm2022/libs/feature/dataviz/src/lib/geo-table-view/geo-table-view.component.mjs +4 -4
- package/esm2022/libs/feature/dataviz/src/lib/service/data.service.mjs +4 -4
- package/esm2022/libs/feature/dataviz/src/lib/table-view/table-view.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/+state/editor.actions.mjs +1 -1
- package/esm2022/libs/feature/editor/src/lib/+state/editor.effects.mjs +14 -6
- package/esm2022/libs/feature/editor/src/lib/+state/editor.facade.mjs +8 -6
- package/esm2022/libs/feature/editor/src/lib/+state/editor.reducer.mjs +6 -2
- package/esm2022/libs/feature/editor/src/lib/+state/editor.selectors.mjs +3 -1
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-array/form-field-array.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-file/form-field-file.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-keywords/form-field-keywords.component.mjs +87 -0
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-license/form-field-license.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-object/form-field-object.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-resource-updated/form-field-resource-updated.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-rich/form-field-rich.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-simple/form-field-simple.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-spatial-extent/form-field-spatial-extent.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-date/form-field-temporal-extents-date.component.mjs +17 -0
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-range/form-field-temporal-extents-range.component.mjs +17 -0
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents.component.mjs +105 -0
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-update-frequency/form-field-update-frequency.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.mjs +15 -12
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/index.mjs +5 -2
- package/esm2022/libs/feature/editor/src/lib/components/record-form/record-form.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/wizard/wizard.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/wizard-field/wizard-field.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/components/wizard-summarize/wizard-summarize.component.mjs +4 -4
- package/esm2022/libs/feature/editor/src/lib/feature-editor.module.mjs +7 -6
- package/esm2022/libs/feature/editor/src/lib/fields.config.mjs +15 -1
- package/esm2022/libs/feature/editor/src/lib/services/editor.service.mjs +22 -42
- package/esm2022/libs/feature/editor/src/lib/services/wizard.service.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/+state/map.effects.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/+state/map.facade.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/add-layer-from-catalog/add-layer-from-catalog.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/add-layer-from-catalog/add-layer-record-preview/add-layer-record-preview.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/add-layer-from-file/add-layer-from-file.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/add-layer-from-ogc-api/add-layer-from-ogc-api.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/add-layer-from-wfs/add-layer-from-wfs.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/add-layer-from-wms/add-layer-from-wms.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/feature-info/feature-info.service.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/feature-map.module.mjs +5 -5
- package/esm2022/libs/feature/map/src/lib/geocoding/geocoding.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/geocoding.service.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/layers-panel/layers-panel.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/manager/map-instance.directive.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/manager/map-manager.service.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/map-container/map-container.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/map-context/component/map-context.component.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/map-context/map-context.service.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/style/map-style.service.mjs +4 -4
- package/esm2022/libs/feature/map/src/lib/utils/map-utils.service.mjs +4 -4
- package/esm2022/libs/feature/notifications/src/lib/feature-notifications.module.mjs +5 -5
- package/esm2022/libs/feature/notifications/src/lib/notifications-container/notifications-container.component.mjs +4 -4
- package/esm2022/libs/feature/notifications/src/lib/notifications.service.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/data-view/data-view.component.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/data-view-permalink/data-view-permalink.component.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/data-view-share/data-view-share.component.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/data-view-web-component/data-view-web-component.component.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/external-viewer-button/external-viewer-button.component.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/feature-record.module.mjs +5 -5
- package/esm2022/libs/feature/record/src/lib/map-view/map-view.component.mjs +4 -4
- package/esm2022/libs/feature/record/src/lib/state/mdview.effects.mjs +5 -5
- package/esm2022/libs/feature/record/src/lib/state/mdview.facade.mjs +4 -4
- package/esm2022/libs/feature/router/src/lib/default/container/search-router.container.directive.mjs +4 -4
- package/esm2022/libs/feature/router/src/lib/default/router.module.mjs +5 -5
- package/esm2022/libs/feature/router/src/lib/default/router.service.mjs +4 -4
- package/esm2022/libs/feature/router/src/lib/default/services/router-search.service.mjs +4 -4
- package/esm2022/libs/feature/router/src/lib/default/state/router.effects.mjs +4 -4
- package/esm2022/libs/feature/router/src/lib/default/state/router.facade.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/facets/facets-container/facets-container.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/facets/facets.module.mjs +5 -5
- package/esm2022/libs/feature/search/src/lib/facets/facets.service.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/favorites/favorite-star/favorite-star.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/feature-search.module.mjs +5 -5
- package/esm2022/libs/feature/search/src/lib/filter-dropdown/filter-dropdown.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/fuzzy-search/fuzzy-search.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/records-metrics/records-metrics.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/results-hits-number/results-hits.container.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/results-layout/results-layout.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/results-list/results-list.container.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/results-table/results-table.component.mjs +20 -12
- package/esm2022/libs/feature/search/src/lib/sort-by/sort-by.component.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/state/container/search-state.container.directive.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/state/effects.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/state/search.facade.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/utils/service/fields.service.mjs +4 -4
- package/esm2022/libs/feature/search/src/lib/utils/service/search.service.mjs +4 -4
- package/esm2022/libs/ui/catalog/src/lib/catalog-title/catalog-title.component.mjs +4 -4
- package/esm2022/libs/ui/catalog/src/lib/language-switcher/language-switcher.component.mjs +4 -4
- package/esm2022/libs/ui/catalog/src/lib/organisation-preview/organisation-preview.component.mjs +4 -4
- package/esm2022/libs/ui/catalog/src/lib/organisations-filter/organisations-filter.component.mjs +4 -4
- package/esm2022/libs/ui/catalog/src/lib/organisations-result/organisations-result.component.mjs +4 -4
- package/esm2022/libs/ui/catalog/src/lib/ui-catalog.module.mjs +5 -5
- package/esm2022/libs/ui/dataviz/src/lib/chart/chart.component.mjs +4 -4
- package/esm2022/libs/ui/dataviz/src/lib/figure/figure.component.mjs +4 -4
- package/esm2022/libs/ui/dataviz/src/lib/table/table.component.mjs +4 -4
- package/esm2022/libs/ui/dataviz/src/lib/ui-dataviz.module.mjs +5 -5
- package/esm2022/libs/ui/elements/src/index.mjs +4 -3
- package/esm2022/libs/ui/elements/src/lib/api-card/api-card.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/avatar/avatar.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/content-ghost/content-ghost.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/download-item/download-item.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/downloads-list/downloads-list.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/error/error.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/image-overlay-preview/image-overlay-preview.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/link-card/link-card.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/markdown-editor/markdown-editor.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/markdown-parser/markdown-parser.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/max-lines/max-lines.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/metadata-catalog/metadata-catalog.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/metadata-contact/metadata-contact.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/metadata-info/linkify.directive.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/metadata-info/metadata-info.component.mjs +8 -8
- package/esm2022/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/metadata-quality-item/metadata-quality-item.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/notification/notification.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/pagination/pagination.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/pagination-buttons/pagination-buttons.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/record-api-form/record-api-form.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/related-record-card/related-record-card.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/sortable-list/sortable-list.component.mjs +43 -0
- package/esm2022/libs/ui/elements/src/lib/thumbnail/thumbnail.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/ui-elements.module.mjs +11 -8
- package/esm2022/libs/ui/elements/src/lib/user-feedback-item/time-since.pipe.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/user-feedback-item/user-feedback-item.component.mjs +4 -4
- package/esm2022/libs/ui/elements/src/lib/user-preview/user-preview.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/index.mjs +2 -1
- package/esm2022/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/badge/badge.component.mjs +28 -0
- package/esm2022/libs/ui/inputs/src/lib/button/button.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/check-toggle/check-toggle.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/checkbox/checkbox.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/chips-input/chips-input.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/copy-text-button/copy-text-button.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/date-picker/date-picker.component.mjs +6 -6
- package/esm2022/libs/ui/inputs/src/lib/date-range-picker/date-range-picker.component.mjs +19 -13
- package/esm2022/libs/ui/inputs/src/lib/drag-and-drop-file-input/drag-and-drop-file-input.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/dropdown-multiselect/dropdown-multiselect.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/dropdown-selector/dropdown-selector.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/editable-label/editable-label.directive.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/files-drop/files-drop.directive.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/image-input/image-input.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/navigation-button/navigation-button.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/previous-next-buttons/previous-next-buttons.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/search-input/search-input.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/star-toggle/star-toggle.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/text-area/text-area.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/text-input/text-input.component.mjs +4 -4
- package/esm2022/libs/ui/inputs/src/lib/ui-inputs.module.mjs +14 -8
- package/esm2022/libs/ui/inputs/src/lib/viewport-intersector/viewport-intersector.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/anchor-link/anchor-link.directive.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/block-list/block-list.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/carousel/carousel.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/expandable-panel/expandable-panel.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/expandable-panel-button/expandable-panel-button.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/form-field-wrapper/form-field-wrapper.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/interactive-table/interactive-table-column/interactive-table-column.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/interactive-table/interactive-table.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/sticky-header/sticky-header.component.mjs +4 -4
- package/esm2022/libs/ui/layout/src/lib/ui-layout.module.mjs +5 -5
- package/esm2022/libs/ui/map/src/lib/components/feature-detail/feature-detail.component.mjs +4 -4
- package/esm2022/libs/ui/map/src/lib/components/map/map.component.mjs +4 -4
- package/esm2022/libs/ui/map/src/lib/ui-map.module.mjs +5 -5
- package/esm2022/libs/ui/search/src/lib/facets/facet-block/facet-block.component.mjs +7 -7
- package/esm2022/libs/ui/search/src/lib/facets/facet-item/facet-item.component.mjs +7 -7
- package/esm2022/libs/ui/search/src/lib/facets/facet-list/facet-list.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/facets/facets.module.mjs +5 -5
- package/esm2022/libs/ui/search/src/lib/record-metric/record-metric.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview/record-preview.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview-card/record-preview-card.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview-feed/record-preview-feed.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview-list/record-preview-list.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview-row/record-preview-row.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview-text/record-preview-text.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/record-preview-title/record-preview-title.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/results-hits-number/results-hits-number.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/results-list/results-list.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/results-list-item/results-list-item.component.mjs +4 -4
- package/esm2022/libs/ui/search/src/lib/ui-search.module.mjs +5 -5
- package/esm2022/libs/ui/widgets/src/index.mjs +1 -2
- package/esm2022/libs/ui/widgets/src/lib/color-scale/color-scale.component.mjs +4 -4
- package/esm2022/libs/ui/widgets/src/lib/loading-mask/loading-mask.component.mjs +4 -4
- package/esm2022/libs/ui/widgets/src/lib/popup-alert/popup-alert.component.mjs +4 -4
- package/esm2022/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.mjs +4 -4
- package/esm2022/libs/ui/widgets/src/lib/spinning-loader/spinning-loader.component.mjs +4 -4
- package/esm2022/libs/ui/widgets/src/lib/step-bar/step-bar.component.mjs +4 -4
- package/esm2022/libs/ui/widgets/src/lib/ui-widgets.module.mjs +5 -10
- package/esm2022/libs/util/i18n/src/lib/i18n.interceptor.mjs +4 -4
- package/esm2022/libs/util/i18n/src/lib/lang.service.mjs +4 -4
- package/esm2022/libs/util/i18n/src/lib/util-i18n.module.mjs +5 -5
- package/esm2022/libs/util/shared/src/lib/image-fallback.directive.mjs +4 -4
- package/esm2022/libs/util/shared/src/lib/links/link-classifier.service.mjs +4 -4
- package/esm2022/libs/util/shared/src/lib/services/log.service.mjs +4 -4
- package/esm2022/libs/util/shared/src/lib/services/proxy.service.mjs +4 -4
- package/esm2022/libs/util/shared/src/lib/services/theme.service.mjs +4 -4
- package/esm2022/libs/util/shared/src/lib/util-shared.module.mjs +5 -5
- package/esm2022/translations/de.json +10 -1
- package/esm2022/translations/en.json +10 -1
- package/esm2022/translations/es.json +10 -1
- package/esm2022/translations/fr.json +10 -1
- package/esm2022/translations/it.json +10 -1
- package/esm2022/translations/nl.json +10 -1
- package/esm2022/translations/pt.json +10 -1
- package/fesm2022/geonetwork-ui.mjs +1364 -966
- package/fesm2022/geonetwork-ui.mjs.map +1 -1
- package/libs/api/metadata-converter/src/lib/gn4/types/index.d.ts +1 -0
- package/libs/api/metadata-converter/src/lib/gn4/types/index.d.ts.map +1 -1
- package/libs/api/metadata-converter/src/lib/gn4/types/keywords.model.d.ts +31 -0
- package/libs/api/metadata-converter/src/lib/gn4/types/keywords.model.d.ts.map +1 -0
- package/libs/api/metadata-converter/src/lib/iso19139/read-parts.d.ts +3 -2
- package/libs/api/metadata-converter/src/lib/iso19139/read-parts.d.ts.map +1 -1
- package/libs/api/metadata-converter/src/lib/iso19139/utils/keyword.mapper.d.ts +1 -1
- package/libs/api/metadata-converter/src/lib/iso19139/utils/keyword.mapper.d.ts.map +1 -1
- package/libs/api/metadata-converter/src/lib/iso19139/write-parts.d.ts +3 -2
- package/libs/api/metadata-converter/src/lib/iso19139/write-parts.d.ts.map +1 -1
- package/libs/api/repository/src/lib/gn4/gn4-repository.d.ts +15 -3
- package/libs/api/repository/src/lib/gn4/gn4-repository.d.ts.map +1 -1
- package/libs/api/repository/src/lib/gn4/platform/gn4-platform.mapper.d.ts +3 -3
- package/libs/api/repository/src/lib/gn4/platform/gn4-platform.mapper.d.ts.map +1 -1
- package/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.d.ts +8 -5
- package/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.d.ts.map +1 -1
- package/libs/common/domain/src/lib/model/record/metadata.model.d.ts +4 -7
- package/libs/common/domain/src/lib/model/record/metadata.model.d.ts.map +1 -1
- package/libs/common/domain/src/lib/model/thesaurus/thesaurus.model.d.ts +12 -5
- package/libs/common/domain/src/lib/model/thesaurus/thesaurus.model.d.ts.map +1 -1
- package/libs/common/domain/src/lib/platform.service.interface.d.ts +3 -3
- package/libs/common/domain/src/lib/platform.service.interface.d.ts.map +1 -1
- package/libs/common/domain/src/lib/repository/records-repository.interface.d.ts +24 -1
- package/libs/common/domain/src/lib/repository/records-repository.interface.d.ts.map +1 -1
- package/libs/data-access/gn4/src/openapi/api/records.api.service.d.ts +6 -6
- package/libs/data-access/gn4/src/openapi/api/records.api.service.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/+state/editor.actions.d.ts +4 -0
- package/libs/feature/editor/src/lib/+state/editor.actions.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/+state/editor.effects.d.ts +5 -0
- package/libs/feature/editor/src/lib/+state/editor.effects.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/+state/editor.facade.d.ts +9 -8
- package/libs/feature/editor/src/lib/+state/editor.facade.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/+state/editor.reducer.d.ts +10 -0
- package/libs/feature/editor/src/lib/+state/editor.reducer.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/+state/editor.selectors.d.ts +2 -0
- package/libs/feature/editor/src/lib/+state/editor.selectors.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-keywords/form-field-keywords.component.d.ts +35 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-keywords/form-field-keywords.component.d.ts.map +1 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-date/form-field-temporal-extents-date.component.d.ts +8 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-date/form-field-temporal-extents-date.component.d.ts.map +1 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-range/form-field-temporal-extents-range.component.d.ts +8 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-range/form-field-temporal-extents-range.component.d.ts.map +1 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents.component.d.ts +31 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents.component.d.ts.map +1 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.d.ts +2 -1
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/components/record-form/form-field/index.d.ts +4 -1
- package/libs/feature/editor/src/lib/components/record-form/form-field/index.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/feature-editor.module.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/fields.config.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/services/editor.service.d.ts +6 -9
- package/libs/feature/editor/src/lib/services/editor.service.d.ts.map +1 -1
- package/libs/feature/record/src/lib/state/mdview.effects.d.ts.map +1 -1
- package/libs/feature/search/src/lib/results-table/results-table.component.d.ts +4 -1
- package/libs/feature/search/src/lib/results-table/results-table.component.d.ts.map +1 -1
- package/libs/ui/elements/src/index.d.ts +3 -2
- package/libs/ui/elements/src/index.d.ts.map +1 -1
- package/libs/ui/elements/src/lib/sortable-list/sortable-list.component.d.ts +22 -0
- package/libs/ui/elements/src/lib/sortable-list/sortable-list.component.d.ts.map +1 -0
- package/libs/ui/elements/src/lib/ui-elements.module.d.ts +2 -1
- package/libs/ui/elements/src/lib/ui-elements.module.d.ts.map +1 -1
- package/libs/ui/inputs/src/index.d.ts +1 -0
- package/libs/ui/inputs/src/index.d.ts.map +1 -1
- package/libs/ui/inputs/src/lib/badge/badge.component.d.ts +11 -0
- package/libs/ui/inputs/src/lib/badge/badge.component.d.ts.map +1 -0
- package/libs/ui/inputs/src/lib/date-picker/date-picker.component.d.ts.map +1 -1
- package/libs/ui/inputs/src/lib/date-range-picker/date-range-picker.component.d.ts +4 -4
- package/libs/ui/inputs/src/lib/date-range-picker/date-range-picker.component.d.ts.map +1 -1
- package/libs/ui/inputs/src/lib/ui-inputs.module.d.ts +2 -1
- package/libs/ui/inputs/src/lib/ui-inputs.module.d.ts.map +1 -1
- package/libs/ui/widgets/src/index.d.ts +0 -1
- package/libs/ui/widgets/src/index.d.ts.map +1 -1
- package/libs/ui/widgets/src/lib/ui-widgets.module.d.ts +10 -11
- package/libs/ui/widgets/src/lib/ui-widgets.module.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/libs/api/metadata-converter/src/lib/gn4/types/index.ts +1 -0
- package/src/libs/api/metadata-converter/src/lib/gn4/types/keywords.model.ts +31 -0
- package/src/libs/api/metadata-converter/src/lib/iso19139/read-parts.ts +2 -2
- package/src/libs/api/metadata-converter/src/lib/iso19139/utils/keyword.mapper.ts +1 -1
- package/src/libs/api/metadata-converter/src/lib/iso19139/write-parts.ts +2 -2
- package/src/libs/api/repository/src/lib/gn4/gn4-repository.ts +145 -7
- package/src/libs/api/repository/src/lib/gn4/platform/gn4-platform.mapper.ts +24 -3
- package/src/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.ts +70 -21
- package/src/libs/common/domain/src/lib/model/record/metadata.model.ts +4 -9
- package/src/libs/common/domain/src/lib/model/thesaurus/thesaurus.model.ts +13 -6
- package/src/libs/common/domain/src/lib/platform.service.interface.ts +3 -3
- package/src/libs/common/domain/src/lib/repository/records-repository.interface.ts +36 -3
- package/src/libs/common/fixtures/src/lib/records.fixtures.ts +203 -0
- package/src/libs/data-access/gn4/src/openapi/api/records.api.service.ts +9 -9
- package/src/libs/data-access/gn4/src/spec.yaml +4 -5
- package/src/libs/feature/editor/src/lib/+state/editor.actions.ts +5 -1
- package/src/libs/feature/editor/src/lib/+state/editor.effects.ts +31 -3
- package/src/libs/feature/editor/src/lib/+state/editor.facade.ts +13 -3
- package/src/libs/feature/editor/src/lib/+state/editor.reducer.ts +22 -5
- package/src/libs/feature/editor/src/lib/+state/editor.selectors.ts +10 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-keywords/form-field-keywords.component.html +20 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-keywords/form-field-keywords.component.ts +119 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-date/form-field-temporal-extents-date.component.html +7 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-date/form-field-temporal-extents-date.component.ts +16 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-range/form-field-temporal-extents-range.component.css +0 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-range/form-field-temporal-extents-range.component.html +13 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-range/form-field-temporal-extents-range.component.ts +16 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents.component.css +0 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents.component.html +6 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents.component.ts +130 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.html +9 -2
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.ts +14 -7
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/index.ts +4 -1
- package/src/libs/feature/editor/src/lib/feature-editor.module.ts +2 -1
- package/src/libs/feature/editor/src/lib/fields.config.ts +14 -0
- package/src/libs/feature/editor/src/lib/services/editor.service.ts +17 -52
- package/src/libs/feature/record/src/lib/state/mdview.effects.ts +1 -3
- package/src/libs/feature/search/src/lib/results-table/results-table.component.html +12 -1
- package/src/libs/feature/search/src/lib/results-table/results-table.component.ts +9 -2
- package/src/libs/ui/elements/src/index.ts +3 -2
- package/src/libs/ui/elements/src/lib/sortable-list/sortable-list.component.css +18 -0
- package/src/libs/ui/elements/src/lib/sortable-list/sortable-list.component.html +36 -0
- package/src/libs/ui/elements/src/lib/sortable-list/sortable-list.component.ts +56 -0
- package/src/libs/ui/elements/src/lib/ui-elements.module.ts +2 -1
- package/src/libs/ui/inputs/src/index.ts +1 -0
- package/src/libs/ui/inputs/src/lib/badge/badge.component.css +0 -0
- package/src/libs/ui/inputs/src/lib/badge/badge.component.html +18 -0
- package/src/libs/ui/inputs/src/lib/badge/badge.component.ts +27 -0
- package/src/libs/ui/inputs/src/lib/date-picker/date-picker.component.html +2 -1
- package/src/libs/ui/inputs/src/lib/date-picker/date-picker.component.ts +8 -1
- package/src/libs/ui/inputs/src/lib/date-range-picker/date-range-picker.component.html +7 -7
- package/src/libs/ui/inputs/src/lib/date-range-picker/date-range-picker.component.ts +13 -15
- package/src/libs/ui/inputs/src/lib/ui-inputs.module.ts +3 -0
- package/src/libs/ui/widgets/src/index.ts +0 -1
- package/src/libs/ui/widgets/src/lib/ui-widgets.module.ts +0 -3
- package/tailwind.base.css +26 -1
- package/translations/de.json +10 -1
- package/translations/en.json +10 -1
- package/translations/es.json +10 -1
- package/translations/fr.json +10 -1
- package/translations/it.json +10 -1
- package/translations/nl.json +10 -1
- package/translations/pt.json +10 -1
- package/translations/sk.json +10 -1
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extent/form-field-temporal-extent.component.mjs +0 -11
- package/esm2022/libs/ui/widgets/src/lib/badge/badge.component.mjs +0 -17
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extent/form-field-temporal-extent.component.d.ts +0 -6
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extent/form-field-temporal-extent.component.d.ts.map +0 -1
- package/libs/ui/widgets/src/lib/badge/badge.component.d.ts +0 -7
- package/libs/ui/widgets/src/lib/badge/badge.component.d.ts.map +0 -1
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extent/form-field-temporal-extent.component.html +0 -1
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extent/form-field-temporal-extent.component.ts +0 -10
- package/src/libs/ui/widgets/src/lib/badge/badge.component.html +0 -10
- package/src/libs/ui/widgets/src/lib/badge/badge.component.ts +0 -11
- /package/src/libs/feature/editor/src/lib/components/record-form/form-field/{form-field-temporal-extent/form-field-temporal-extent.component.css → form-field-keywords/form-field-keywords.component.css} +0 -0
- /package/src/libs/{ui/widgets/src/lib/badge/badge.component.css → feature/editor/src/lib/components/record-form/form-field/form-field-temporal-extents/form-field-temporal-extents-date/form-field-temporal-extents-date.component.css} +0 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, Input } from '@angular/core'
|
|
2
|
+
import { FormControl } from '@angular/forms'
|
|
3
|
+
import { DateRangePickerComponent } from '../../../../../../../../../../libs/ui/inputs/src'
|
|
4
|
+
import { TranslateModule } from '@ngx-translate/core'
|
|
5
|
+
|
|
6
|
+
@Component({
|
|
7
|
+
selector: 'gn-ui-form-field-temporal-extents-range',
|
|
8
|
+
templateUrl: './form-field-temporal-extents-range.component.html',
|
|
9
|
+
styleUrls: ['./form-field-temporal-extents-range.component.css'],
|
|
10
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
11
|
+
standalone: true,
|
|
12
|
+
imports: [DateRangePickerComponent, TranslateModule],
|
|
13
|
+
})
|
|
14
|
+
export class FormFieldTemporalExtentsRangeComponent {
|
|
15
|
+
@Input() control!: FormControl
|
|
16
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ChangeDetectionStrategy,
|
|
3
|
+
Component,
|
|
4
|
+
Input,
|
|
5
|
+
OnDestroy,
|
|
6
|
+
OnInit,
|
|
7
|
+
Type,
|
|
8
|
+
} from '@angular/core'
|
|
9
|
+
import { FormArray, FormControl } from '@angular/forms'
|
|
10
|
+
import { SortableListComponent } from '../../../../../../../../../libs/ui/elements/src'
|
|
11
|
+
import { Subscription, combineLatest, map } from 'rxjs'
|
|
12
|
+
import { FormFieldTemporalExtentsDateComponent } from './form-field-temporal-extents-date/form-field-temporal-extents-date.component'
|
|
13
|
+
import { FormFieldTemporalExtentsRangeComponent } from './form-field-temporal-extents-range/form-field-temporal-extents-range.component'
|
|
14
|
+
import { TranslateService } from '@ngx-translate/core'
|
|
15
|
+
import { CommonModule } from '@angular/common'
|
|
16
|
+
|
|
17
|
+
@Component({
|
|
18
|
+
selector: 'gn-ui-form-field-temporal-extents',
|
|
19
|
+
templateUrl: './form-field-temporal-extents.component.html',
|
|
20
|
+
styleUrls: ['./form-field-temporal-extents.component.css'],
|
|
21
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
22
|
+
standalone: true,
|
|
23
|
+
imports: [CommonModule, SortableListComponent],
|
|
24
|
+
})
|
|
25
|
+
export class FormFieldTemporalExtentsComponent implements OnInit, OnDestroy {
|
|
26
|
+
@Input() control!: FormControl
|
|
27
|
+
|
|
28
|
+
subscription: Subscription
|
|
29
|
+
|
|
30
|
+
array: FormArray = new FormArray([])
|
|
31
|
+
elements: Array<{
|
|
32
|
+
component: Type<any>
|
|
33
|
+
inputs: Record<string, any>
|
|
34
|
+
}>
|
|
35
|
+
|
|
36
|
+
addOptions$ = combineLatest([
|
|
37
|
+
this.translateService
|
|
38
|
+
.get('editor.record.form.temporalExtents.addDate')
|
|
39
|
+
.pipe(map((buttonLabel) => ({ buttonLabel, eventName: 'date' }))),
|
|
40
|
+
this.translateService
|
|
41
|
+
.get('editor.record.form.temporalExtents.addRange')
|
|
42
|
+
.pipe(map((buttonLabel) => ({ buttonLabel, eventName: 'range' }))),
|
|
43
|
+
])
|
|
44
|
+
|
|
45
|
+
constructor(private translateService: TranslateService) {}
|
|
46
|
+
|
|
47
|
+
ngOnInit() {
|
|
48
|
+
this.resetValueFromInput(this.control.value)
|
|
49
|
+
|
|
50
|
+
this.subscription = new Subscription()
|
|
51
|
+
|
|
52
|
+
this.subscription.add(
|
|
53
|
+
this.control.valueChanges.subscribe((value) => {
|
|
54
|
+
this.resetValueFromInput(value)
|
|
55
|
+
})
|
|
56
|
+
)
|
|
57
|
+
|
|
58
|
+
this.subscription.add(
|
|
59
|
+
this.array.valueChanges.subscribe((value) => {
|
|
60
|
+
this.control.setValue(value)
|
|
61
|
+
})
|
|
62
|
+
)
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
onElementsChange(elements: any) {
|
|
66
|
+
this.array.clear({ emitEvent: false })
|
|
67
|
+
elements.forEach((e: any, i: number) =>
|
|
68
|
+
this.array.push(e.inputs.control, {
|
|
69
|
+
emitEvent: i === elements.length - 1,
|
|
70
|
+
})
|
|
71
|
+
)
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
onAdd(eventName: string) {
|
|
75
|
+
switch (eventName) {
|
|
76
|
+
case 'date': {
|
|
77
|
+
const dateControl = new FormControl({ start: new Date() })
|
|
78
|
+
this.array.push(dateControl)
|
|
79
|
+
break
|
|
80
|
+
}
|
|
81
|
+
case 'range': {
|
|
82
|
+
const rangeControl = new FormControl({
|
|
83
|
+
start: new Date(),
|
|
84
|
+
end: new Date(),
|
|
85
|
+
})
|
|
86
|
+
this.array.push(rangeControl)
|
|
87
|
+
break
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
ngOnDestroy(): void {
|
|
93
|
+
this.subscription.unsubscribe()
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
private resetValueFromInput(value) {
|
|
97
|
+
this.array.clear({ emitEvent: false })
|
|
98
|
+
this.elements = []
|
|
99
|
+
value.forEach((v: any) => {
|
|
100
|
+
if ('start' in v && 'end' in v) {
|
|
101
|
+
const rangeControl = new FormControl({
|
|
102
|
+
start: v.start,
|
|
103
|
+
end: v.end,
|
|
104
|
+
})
|
|
105
|
+
this.array.push(rangeControl, { emitEvent: false })
|
|
106
|
+
this.elements = [
|
|
107
|
+
...this.elements,
|
|
108
|
+
{
|
|
109
|
+
component: FormFieldTemporalExtentsRangeComponent,
|
|
110
|
+
inputs: {
|
|
111
|
+
control: rangeControl,
|
|
112
|
+
},
|
|
113
|
+
},
|
|
114
|
+
]
|
|
115
|
+
} else {
|
|
116
|
+
const dateControl = new FormControl({ start: v.start })
|
|
117
|
+
this.array.push(dateControl, { emitEvent: false })
|
|
118
|
+
this.elements = [
|
|
119
|
+
...this.elements,
|
|
120
|
+
{
|
|
121
|
+
component: FormFieldTemporalExtentsDateComponent,
|
|
122
|
+
inputs: {
|
|
123
|
+
control: dateControl,
|
|
124
|
+
},
|
|
125
|
+
},
|
|
126
|
+
]
|
|
127
|
+
}
|
|
128
|
+
})
|
|
129
|
+
}
|
|
130
|
+
}
|
package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.html
CHANGED
|
@@ -61,6 +61,11 @@
|
|
|
61
61
|
[control]="formControl"
|
|
62
62
|
></gn-ui-form-field-update-frequency>
|
|
63
63
|
</ng-container>
|
|
64
|
+
<ng-container *ngIf="isTemporalExtents">
|
|
65
|
+
<gn-ui-form-field-temporal-extents
|
|
66
|
+
[control]="formControl"
|
|
67
|
+
></gn-ui-form-field-temporal-extents>
|
|
68
|
+
</ng-container>
|
|
64
69
|
<ng-container *ngIf="isSimpleField">
|
|
65
70
|
<gn-ui-form-field-simple
|
|
66
71
|
[type]="simpleType"
|
|
@@ -85,8 +90,10 @@
|
|
|
85
90
|
<ng-container *ngIf="isSpatialExtentField">
|
|
86
91
|
<gn-ui-form-field-spatial-extent></gn-ui-form-field-spatial-extent>
|
|
87
92
|
</ng-container>
|
|
88
|
-
<ng-container *ngIf="
|
|
89
|
-
<gn-ui-form-field-
|
|
93
|
+
<ng-container *ngIf="isKeywords">
|
|
94
|
+
<gn-ui-form-field-keywords
|
|
95
|
+
[control]="formControl"
|
|
96
|
+
></gn-ui-form-field-keywords>
|
|
90
97
|
</ng-container>
|
|
91
98
|
<div
|
|
92
99
|
*ngIf="isFieldInvalid && config.invalidHintKey"
|
package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.ts
CHANGED
|
@@ -14,17 +14,20 @@ import { EditableLabelDirective } from '../../../../../../../../libs/ui/inputs/s
|
|
|
14
14
|
import { FormFieldWrapperComponent } from '../../../../../../../../libs/ui/layout/src'
|
|
15
15
|
import { TranslateModule } from '@ngx-translate/core'
|
|
16
16
|
import { Observable } from 'rxjs'
|
|
17
|
+
import {
|
|
18
|
+
FormFieldLicenseComponent,
|
|
19
|
+
FormFieldResourceUpdatedComponent,
|
|
20
|
+
FormFieldTemporalExtentsComponent,
|
|
21
|
+
} from '.'
|
|
17
22
|
import { FormFieldArrayComponent } from './form-field-array/form-field-array.component'
|
|
18
23
|
import { FormFieldFileComponent } from './form-field-file/form-field-file.component'
|
|
19
|
-
import { FormFieldLicenseComponent } from './form-field-license/form-field-license.component'
|
|
20
24
|
import { FormFieldObjectComponent } from './form-field-object/form-field-object.component'
|
|
21
|
-
import { FormFieldResourceUpdatedComponent } from './form-field-resource-updated/form-field-resource-updated.component'
|
|
22
25
|
import { FormFieldRichComponent } from './form-field-rich/form-field-rich.component'
|
|
23
26
|
import { FormFieldSimpleComponent } from './form-field-simple/form-field-simple.component'
|
|
24
27
|
import { FormFieldSpatialExtentComponent } from './form-field-spatial-extent/form-field-spatial-extent.component'
|
|
25
|
-
import { FormFieldTemporalExtentComponent } from './form-field-temporal-extent/form-field-temporal-extent.component'
|
|
26
28
|
import { FormFieldConfig } from './form-field.model'
|
|
27
29
|
import { FormFieldUpdateFrequencyComponent } from './form-field-update-frequency/form-field-update-frequency.component'
|
|
30
|
+
import { FormFieldKeywordsComponent } from './form-field-keywords/form-field-keywords.component'
|
|
28
31
|
|
|
29
32
|
@Component({
|
|
30
33
|
selector: 'gn-ui-form-field',
|
|
@@ -42,13 +45,14 @@ import { FormFieldUpdateFrequencyComponent } from './form-field-update-frequency
|
|
|
42
45
|
FormFieldLicenseComponent,
|
|
43
46
|
FormFieldResourceUpdatedComponent,
|
|
44
47
|
FormFieldUpdateFrequencyComponent,
|
|
48
|
+
FormFieldTemporalExtentsComponent,
|
|
45
49
|
FormFieldSimpleComponent,
|
|
46
50
|
FormFieldRichComponent,
|
|
47
51
|
FormFieldObjectComponent,
|
|
48
52
|
FormFieldSpatialExtentComponent,
|
|
49
|
-
FormFieldTemporalExtentComponent,
|
|
50
53
|
FormFieldFileComponent,
|
|
51
54
|
FormFieldArrayComponent,
|
|
55
|
+
FormFieldKeywordsComponent,
|
|
52
56
|
TranslateModule,
|
|
53
57
|
],
|
|
54
58
|
})
|
|
@@ -100,9 +104,6 @@ export class FormFieldComponent {
|
|
|
100
104
|
get isSpatialExtentField() {
|
|
101
105
|
return this.config.type === 'spatial_extent'
|
|
102
106
|
}
|
|
103
|
-
get isTemporalExtentField() {
|
|
104
|
-
return this.config.type === 'temporal_extent'
|
|
105
|
-
}
|
|
106
107
|
get isArrayField() {
|
|
107
108
|
return this.config.type === 'array'
|
|
108
109
|
}
|
|
@@ -135,6 +136,12 @@ export class FormFieldComponent {
|
|
|
135
136
|
get isUpdateFrequency() {
|
|
136
137
|
return this.model === 'updateFrequency'
|
|
137
138
|
}
|
|
139
|
+
get isTemporalExtents() {
|
|
140
|
+
return this.model === 'temporalExtents'
|
|
141
|
+
}
|
|
142
|
+
get isKeywords() {
|
|
143
|
+
return this.model === 'keywords'
|
|
144
|
+
}
|
|
138
145
|
|
|
139
146
|
get withoutWrapper() {
|
|
140
147
|
return this.model === 'title' || this.model === 'abstract'
|
|
@@ -1,9 +1,12 @@
|
|
|
1
|
+
export * from './form-field-keywords/form-field-keywords.component'
|
|
2
|
+
export * from './form-field-license/form-field-license.component'
|
|
3
|
+
export * from './form-field-resource-updated/form-field-resource-updated.component'
|
|
4
|
+
export * from './form-field-temporal-extents/form-field-temporal-extents.component'
|
|
1
5
|
export * from './form-field-simple/form-field-simple.component'
|
|
2
6
|
export * from './form-field-file/form-field-file.component'
|
|
3
7
|
export * from './form-field-rich/form-field-rich.component'
|
|
4
8
|
export * from './form-field-object/form-field-object.component'
|
|
5
9
|
export * from './form-field-array/form-field-array.component'
|
|
6
10
|
export * from './form-field-spatial-extent/form-field-spatial-extent.component'
|
|
7
|
-
export * from './form-field-temporal-extent/form-field-temporal-extent.component'
|
|
8
11
|
export * from './form-field.component'
|
|
9
12
|
export * from './form-field.model'
|
|
@@ -15,6 +15,7 @@ import * as fromEditor from './+state/editor.reducer'
|
|
|
15
15
|
import { WizardFieldComponent } from './components/wizard-field/wizard-field.component'
|
|
16
16
|
import { WizardSummarizeComponent } from './components/wizard-summarize/wizard-summarize.component'
|
|
17
17
|
import { WizardComponent } from './components/wizard/wizard.component'
|
|
18
|
+
import { Gn4PlatformService } from '../../../../../libs/api/repository/src'
|
|
18
19
|
|
|
19
20
|
@NgModule({
|
|
20
21
|
declarations: [
|
|
@@ -39,7 +40,7 @@ import { WizardComponent } from './components/wizard/wizard.component'
|
|
|
39
40
|
EffectsModule.forFeature([EditorEffects]),
|
|
40
41
|
],
|
|
41
42
|
exports: [WizardComponent, WizardSummarizeComponent],
|
|
42
|
-
providers: [EditorFacade],
|
|
43
|
+
providers: [EditorFacade, Gn4PlatformService],
|
|
43
44
|
})
|
|
44
45
|
export class FeatureEditorModule {}
|
|
45
46
|
export * from './models/index'
|
|
@@ -54,4 +54,18 @@ export const DEFAULT_FIELDS: EditorFieldsConfig = [
|
|
|
54
54
|
type: 'text',
|
|
55
55
|
},
|
|
56
56
|
},
|
|
57
|
+
{
|
|
58
|
+
model: 'temporalExtents',
|
|
59
|
+
formFieldConfig: {
|
|
60
|
+
labelKey: marker('editor.record.form.temporalExtents'),
|
|
61
|
+
type: 'list',
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
model: 'keywords',
|
|
66
|
+
formFieldConfig: {
|
|
67
|
+
labelKey: marker('editor.record.form.keywords'),
|
|
68
|
+
type: 'list',
|
|
69
|
+
},
|
|
70
|
+
},
|
|
57
71
|
]
|
|
@@ -1,50 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
Iso19139Converter,
|
|
5
|
-
} from '../../../../../../libs/api/metadata-converter/src'
|
|
6
|
-
import { Configuration } from '../../../../../../libs/data-access/gn4/src'
|
|
7
|
-
import { from, Observable } from 'rxjs'
|
|
8
|
-
import { map, switchMap } from 'rxjs/operators'
|
|
9
|
-
import { HttpClient } from '@angular/common/http'
|
|
1
|
+
import { Injectable } from '@angular/core'
|
|
2
|
+
import { Observable } from 'rxjs'
|
|
3
|
+
import { map } from 'rxjs/operators'
|
|
10
4
|
import { CatalogRecord } from '../../../../../../libs/common/domain/src/lib/model/record'
|
|
11
5
|
import { EditorFieldsConfig } from '../models/fields.model'
|
|
12
6
|
import { evaluate } from '../expressions'
|
|
7
|
+
import { RecordsRepositoryInterface } from '../../../../../../libs/common/domain/src/lib/repository/records-repository.interface'
|
|
13
8
|
|
|
14
9
|
@Injectable({
|
|
15
10
|
providedIn: 'root',
|
|
16
11
|
})
|
|
17
12
|
export class EditorService {
|
|
18
|
-
private
|
|
13
|
+
constructor(private recordsRepository: RecordsRepositoryInterface) {}
|
|
19
14
|
|
|
20
|
-
|
|
21
|
-
private http: HttpClient,
|
|
22
|
-
@Optional()
|
|
23
|
-
@Inject(Configuration)
|
|
24
|
-
private apiConfiguration: Configuration
|
|
25
|
-
) {}
|
|
26
|
-
|
|
27
|
-
// TODO: use the catalog repository instead
|
|
28
|
-
loadRecordByUuid(uuid: string): Observable<CatalogRecord> {
|
|
29
|
-
return this.http
|
|
30
|
-
.get(`${this.apiUrl}/records/${uuid}/formatters/xml`, {
|
|
31
|
-
responseType: 'text',
|
|
32
|
-
headers: {
|
|
33
|
-
Accept: 'application/xml',
|
|
34
|
-
},
|
|
35
|
-
})
|
|
36
|
-
.pipe(
|
|
37
|
-
switchMap((response) =>
|
|
38
|
-
findConverterForDocument(response).readRecord(response.toString())
|
|
39
|
-
)
|
|
40
|
-
)
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
// returns the record as it was when saved
|
|
15
|
+
// returns the record as it was when saved, alongside its source
|
|
44
16
|
saveRecord(
|
|
45
17
|
record: CatalogRecord,
|
|
46
18
|
fieldsConfig: EditorFieldsConfig
|
|
47
|
-
): Observable<CatalogRecord> {
|
|
19
|
+
): Observable<[CatalogRecord, string]> {
|
|
48
20
|
const savedRecord = { ...record }
|
|
49
21
|
|
|
50
22
|
// run onSave processes
|
|
@@ -57,23 +29,16 @@ export class EditorService {
|
|
|
57
29
|
})
|
|
58
30
|
}
|
|
59
31
|
}
|
|
32
|
+
return this.recordsRepository
|
|
33
|
+
.saveRecord(savedRecord)
|
|
34
|
+
.pipe(map((recordSource) => [savedRecord, recordSource]))
|
|
35
|
+
}
|
|
60
36
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
recordXml,
|
|
68
|
-
{
|
|
69
|
-
headers: {
|
|
70
|
-
'Content-Type': 'application/xml',
|
|
71
|
-
},
|
|
72
|
-
withCredentials: true,
|
|
73
|
-
}
|
|
74
|
-
)
|
|
75
|
-
),
|
|
76
|
-
map(() => savedRecord)
|
|
77
|
-
)
|
|
37
|
+
// emits and completes once saving is done
|
|
38
|
+
// note: onSave processes are not run for drafts
|
|
39
|
+
saveRecordAsDraft(record: CatalogRecord): Observable<void> {
|
|
40
|
+
return this.recordsRepository
|
|
41
|
+
.saveRecordAsDraft(record)
|
|
42
|
+
.pipe(map(() => undefined))
|
|
78
43
|
}
|
|
79
44
|
}
|
|
@@ -20,9 +20,7 @@ export class MdViewEffects {
|
|
|
20
20
|
loadFullMetadata$ = createEffect(() =>
|
|
21
21
|
this.actions$.pipe(
|
|
22
22
|
ofType(MdViewActions.loadFullMetadata),
|
|
23
|
-
switchMap(({ uuid }) =>
|
|
24
|
-
this.recordsRepository.getByUniqueIdentifier(uuid)
|
|
25
|
-
),
|
|
23
|
+
switchMap(({ uuid }) => this.recordsRepository.getRecord(uuid)),
|
|
26
24
|
map((record) => {
|
|
27
25
|
if (record === null) {
|
|
28
26
|
return MdViewActions.loadFullMetadataFailure({ notFound: true })
|
|
@@ -34,7 +34,18 @@
|
|
|
34
34
|
<span translate>record.metadata.title</span>
|
|
35
35
|
</ng-template>
|
|
36
36
|
<ng-template #cell let-item>
|
|
37
|
-
|
|
37
|
+
<div class="flex flex-row items-center gap-2 max-w-full">
|
|
38
|
+
<span class="overflow-hidden text-ellipsis">{{ item.title }}</span>
|
|
39
|
+
<gn-ui-badge
|
|
40
|
+
*ngIf="hasDraft(item)"
|
|
41
|
+
[style.--gn-ui-badge-padding]="'0.4em 0.6em'"
|
|
42
|
+
[style.--gn-ui-badge-text-color]="'#3d2006'"
|
|
43
|
+
[style.--gn-ui-badge-background-color]="'#ffbc7b'"
|
|
44
|
+
[style.--gn-ui-badge-rounded]="'4px'"
|
|
45
|
+
>
|
|
46
|
+
<span translate>dashboard.records.hasDraft</span>
|
|
47
|
+
</gn-ui-badge>
|
|
48
|
+
</div>
|
|
38
49
|
</ng-template>
|
|
39
50
|
</gn-ui-interactive-table-column>
|
|
40
51
|
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
getFileFormat,
|
|
7
7
|
getFormatPriority,
|
|
8
8
|
} from '../../../../../../libs/util/shared/src'
|
|
9
|
-
import { UiInputsModule } from '../../../../../../libs/ui/inputs/src'
|
|
9
|
+
import { BadgeComponent, UiInputsModule } from '../../../../../../libs/ui/inputs/src'
|
|
10
10
|
import {
|
|
11
11
|
InteractiveTableColumnComponent,
|
|
12
12
|
InteractiveTableComponent,
|
|
@@ -20,6 +20,7 @@ import { CommonModule } from '@angular/common'
|
|
|
20
20
|
import { map, take } from 'rxjs/operators'
|
|
21
21
|
import { FieldSort } from '../../../../../../libs/common/domain/src/lib/model/search'
|
|
22
22
|
import { SearchService } from '../utils/service/search.service'
|
|
23
|
+
import { RecordsRepositoryInterface } from '../../../../../../libs/common/domain/src/lib/repository/records-repository.interface'
|
|
23
24
|
|
|
24
25
|
@Component({
|
|
25
26
|
selector: 'gn-ui-results-table',
|
|
@@ -33,6 +34,7 @@ import { SearchService } from '../utils/service/search.service'
|
|
|
33
34
|
InteractiveTableColumnComponent,
|
|
34
35
|
MatIconModule,
|
|
35
36
|
TranslateModule,
|
|
37
|
+
BadgeComponent,
|
|
36
38
|
],
|
|
37
39
|
})
|
|
38
40
|
export class ResultsTableComponent {
|
|
@@ -44,7 +46,8 @@ export class ResultsTableComponent {
|
|
|
44
46
|
constructor(
|
|
45
47
|
private searchFacade: SearchFacade,
|
|
46
48
|
private searchService: SearchService,
|
|
47
|
-
private selectionService: SelectionService
|
|
49
|
+
private selectionService: SelectionService,
|
|
50
|
+
private recordsRepository: RecordsRepositoryInterface
|
|
48
51
|
) {}
|
|
49
52
|
|
|
50
53
|
dateToString(date: Date): string {
|
|
@@ -161,4 +164,8 @@ export class ResultsTableComponent {
|
|
|
161
164
|
})
|
|
162
165
|
)
|
|
163
166
|
}
|
|
167
|
+
|
|
168
|
+
hasDraft(record: CatalogRecord): boolean {
|
|
169
|
+
return this.recordsRepository.recordHasDraft(record.uniqueIdentifier)
|
|
170
|
+
}
|
|
164
171
|
}
|
|
@@ -3,6 +3,7 @@ export * from './lib/avatar/avatar.component'
|
|
|
3
3
|
export * from './lib/content-ghost/content-ghost.component'
|
|
4
4
|
export * from './lib/download-item/download-item.component'
|
|
5
5
|
export * from './lib/downloads-list/downloads-list.component'
|
|
6
|
+
export * from './lib/error/error.component'
|
|
6
7
|
export * from './lib/image-overlay-preview/image-overlay-preview.component'
|
|
7
8
|
export * from './lib/link-card/link-card.component'
|
|
8
9
|
export * from './lib/markdown-editor/markdown-editor.component'
|
|
@@ -13,12 +14,12 @@ export * from './lib/metadata-contact/metadata-contact.component'
|
|
|
13
14
|
export * from './lib/metadata-info/metadata-info.component'
|
|
14
15
|
export * from './lib/metadata-quality-item/metadata-quality-item.component'
|
|
15
16
|
export * from './lib/metadata-quality/metadata-quality.component'
|
|
17
|
+
export * from './lib/notification/notification.component'
|
|
16
18
|
export * from './lib/pagination-buttons/pagination-buttons.component'
|
|
17
19
|
export * from './lib/pagination/pagination.component'
|
|
18
20
|
export * from './lib/record-api-form/record-api-form.component'
|
|
19
21
|
export * from './lib/related-record-card/related-record-card.component'
|
|
20
|
-
export * from './lib/
|
|
22
|
+
export * from './lib/sortable-list/sortable-list.component'
|
|
21
23
|
export * from './lib/thumbnail/thumbnail.component'
|
|
22
24
|
export * from './lib/ui-elements.module'
|
|
23
25
|
export * from './lib/user-preview/user-preview.component'
|
|
24
|
-
export * from './lib/notification/notification.component'
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
.cdk-drag-preview {
|
|
2
|
+
box-sizing: border-box;
|
|
3
|
+
border-radius: 4px;
|
|
4
|
+
box-shadow: 0 5px 5px -3px rgba(0, 0, 0, 0.2),
|
|
5
|
+
0 8px 10px 1px rgba(0, 0, 0, 0.14), 0 3px 14px 2px rgba(0, 0, 0, 0.12);
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.cdk-drag-placeholder {
|
|
9
|
+
opacity: 0;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.cdk-drag-animating {
|
|
13
|
+
transition: transform 250ms cubic-bezier(0, 0, 0.2, 1);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.sortable-list.cdk-drop-list-dragging .sortable-box:not(.cdk-drag-placeholder) {
|
|
17
|
+
transition: transform 250ms cubic-bezier(0, 0, 0.2, 1);
|
|
18
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<div class="flex gap-2 mb-2">
|
|
2
|
+
<gn-ui-button
|
|
3
|
+
*ngFor="let addOption of addOptions"
|
|
4
|
+
(buttonClick)="add.emit(addOption.eventName)"
|
|
5
|
+
>
|
|
6
|
+
<span class="material-symbols-outlined gn-ui-icon-small"> add </span>
|
|
7
|
+
{{ addOption.buttonLabel }}</gn-ui-button
|
|
8
|
+
>
|
|
9
|
+
</div>
|
|
10
|
+
<div
|
|
11
|
+
cdkDropList
|
|
12
|
+
class="sortable-list flex flex-col gap-3 p-2"
|
|
13
|
+
(cdkDropListDropped)="drop($event)"
|
|
14
|
+
>
|
|
15
|
+
<ng-container *ngFor="let element of elements; index as index">
|
|
16
|
+
<div class="sortable-box bg-white flex items-center" cdkDrag>
|
|
17
|
+
<span
|
|
18
|
+
cdkDragHandle
|
|
19
|
+
class="material-symbols-outlined mx-[10px] cursor-grab gn-ui-icon-medium flex-none"
|
|
20
|
+
>
|
|
21
|
+
drag_handle
|
|
22
|
+
</span>
|
|
23
|
+
<div class="flex-1">
|
|
24
|
+
<ng-container
|
|
25
|
+
*ngComponentOutlet="element.component; inputs: element.inputs"
|
|
26
|
+
></ng-container>
|
|
27
|
+
</div>
|
|
28
|
+
<span
|
|
29
|
+
(click)="removeElement(index)"
|
|
30
|
+
class="material-symbols-outlined mx-[10px] cursor-pointer gn-ui-icon-medium flex-none"
|
|
31
|
+
>
|
|
32
|
+
close
|
|
33
|
+
</span>
|
|
34
|
+
</div>
|
|
35
|
+
</ng-container>
|
|
36
|
+
</div>
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import {
|
|
2
|
+
CdkDrag,
|
|
3
|
+
CdkDragDrop,
|
|
4
|
+
CdkDragHandle,
|
|
5
|
+
CdkDropList,
|
|
6
|
+
moveItemInArray,
|
|
7
|
+
} from '@angular/cdk/drag-drop'
|
|
8
|
+
import { NgComponentOutlet, NgFor } from '@angular/common'
|
|
9
|
+
import {
|
|
10
|
+
ChangeDetectionStrategy,
|
|
11
|
+
Component,
|
|
12
|
+
EventEmitter,
|
|
13
|
+
Input,
|
|
14
|
+
Output,
|
|
15
|
+
Type,
|
|
16
|
+
} from '@angular/core'
|
|
17
|
+
import { MatIconModule } from '@angular/material/icon'
|
|
18
|
+
import { ButtonComponent } from '../../../../../../libs/ui/inputs/src'
|
|
19
|
+
|
|
20
|
+
type DynamicElement = {
|
|
21
|
+
component: Type<any>
|
|
22
|
+
inputs: Record<string, any>
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
@Component({
|
|
26
|
+
selector: 'gn-ui-sortable-list',
|
|
27
|
+
templateUrl: 'sortable-list.component.html',
|
|
28
|
+
styleUrls: ['sortable-list.component.css'],
|
|
29
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
30
|
+
standalone: true,
|
|
31
|
+
imports: [
|
|
32
|
+
NgFor,
|
|
33
|
+
NgComponentOutlet,
|
|
34
|
+
CdkDropList,
|
|
35
|
+
CdkDrag,
|
|
36
|
+
CdkDragHandle,
|
|
37
|
+
MatIconModule,
|
|
38
|
+
ButtonComponent,
|
|
39
|
+
],
|
|
40
|
+
})
|
|
41
|
+
export class SortableListComponent {
|
|
42
|
+
@Input() elements: Array<DynamicElement>
|
|
43
|
+
@Input() addOptions: Array<{ buttonLabel: string; eventName: string }>
|
|
44
|
+
@Output() elementsChange = new EventEmitter<Array<DynamicElement>>()
|
|
45
|
+
@Output() add = new EventEmitter<string>()
|
|
46
|
+
|
|
47
|
+
drop(event: CdkDragDrop<string[]>) {
|
|
48
|
+
moveItemInArray(this.elements, event.previousIndex, event.currentIndex)
|
|
49
|
+
this.elementsChange.emit(this.elements)
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
removeElement(index: number) {
|
|
53
|
+
this.elements = this.elements.filter((_, i) => i !== index)
|
|
54
|
+
this.elementsChange.emit(this.elements)
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -20,7 +20,7 @@ import { MetadataQualityItemComponent } from './metadata-quality-item/metadata-q
|
|
|
20
20
|
import { ErrorComponent } from './error/error.component'
|
|
21
21
|
import { PaginationComponent } from './pagination/pagination.component'
|
|
22
22
|
import { ThumbnailComponent } from './thumbnail/thumbnail.component'
|
|
23
|
-
import { UiInputsModule } from '../../../../../libs/ui/inputs/src'
|
|
23
|
+
import { BadgeComponent, UiInputsModule } from '../../../../../libs/ui/inputs/src'
|
|
24
24
|
import { FormsModule } from '@angular/forms'
|
|
25
25
|
import { AvatarComponent } from './avatar/avatar.component'
|
|
26
26
|
import { UserPreviewComponent } from './user-preview/user-preview.component'
|
|
@@ -49,6 +49,7 @@ import { TimeSincePipe } from './user-feedback-item/time-since.pipe'
|
|
|
49
49
|
MarkdownParserComponent,
|
|
50
50
|
ThumbnailComponent,
|
|
51
51
|
TimeSincePipe,
|
|
52
|
+
BadgeComponent,
|
|
52
53
|
],
|
|
53
54
|
declarations: [
|
|
54
55
|
MetadataInfoComponent,
|
|
File without changes
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<div
|
|
2
|
+
class="gn-ui-badge flex items-center gap-1.5"
|
|
3
|
+
[ngClass]="
|
|
4
|
+
clickable
|
|
5
|
+
? 'hover:bg-primary cursor-pointer transition-colors duration-100'
|
|
6
|
+
: ''
|
|
7
|
+
"
|
|
8
|
+
>
|
|
9
|
+
<span><ng-content></ng-content></span>
|
|
10
|
+
<gn-ui-button
|
|
11
|
+
class="material-symbols-outlined cursor-pointer text-xs"
|
|
12
|
+
*ngIf="removable"
|
|
13
|
+
(buttonClick)="removeBadge()"
|
|
14
|
+
extraClass="p-1 bg-transparent border-0 border-transparent "
|
|
15
|
+
>
|
|
16
|
+
close
|
|
17
|
+
</gn-ui-button>
|
|
18
|
+
</div>
|