diff --git a/src/app/core/data/access-status-data.service.ts b/src/app/core/data/access-status-data.service.ts index d6361dd3516..1563e10e97c 100644 --- a/src/app/core/data/access-status-data.service.ts +++ b/src/app/core/data/access-status-data.service.ts @@ -4,8 +4,8 @@ import { AccessStatusObject } from 'src/app/shared/object-collection/shared/badg import { RemoteDataBuildService } from '../cache/builders/remote-data-build.service'; import { ObjectCacheService } from '../cache/object-cache.service'; -import { HALEndpointService } from '../shared/hal-endpoint.service'; import { Bitstream } from '../shared/bitstream.model'; +import { HALEndpointService } from '../shared/hal-endpoint.service'; import { Item } from '../shared/item.model'; import { BaseDataService } from './base/base-data.service'; import { RemoteData } from './remote-data'; diff --git a/src/app/core/shared/bitstream.model.ts b/src/app/core/shared/bitstream.model.ts index 506212b0f97..7bc6ef964b7 100644 --- a/src/app/core/shared/bitstream.model.ts +++ b/src/app/core/shared/bitstream.model.ts @@ -5,13 +5,13 @@ import { } from 'cerialize'; import { Observable } from 'rxjs'; +import { AccessStatusObject } from '../../shared/object-collection/shared/badges/access-status-badge/access-status.model'; +import { ACCESS_STATUS } from '../../shared/object-collection/shared/badges/access-status-badge/access-status.resource-type'; import { link, typedObject, } from '../cache/builders/build-decorators'; import { RemoteData } from '../data/remote-data'; -import { AccessStatusObject } from '../../shared/object-collection/shared/badges/access-status-badge/access-status.model'; -import { ACCESS_STATUS } from '../../shared/object-collection/shared/badges/access-status-badge/access-status.resource-type'; import { BITSTREAM } from './bitstream.resource-type'; import { BitstreamFormat } from './bitstream-format.model'; import { BITSTREAM_FORMAT } from './bitstream-format.resource-type'; diff --git a/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata-field-values/dso-edit-metadata-field-values.component.html b/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata-field-values/dso-edit-metadata-field-values.component.html index aee9fb980cf..3f0408ab536 100644 --- a/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata-field-values/dso-edit-metadata-field-values.component.html +++ b/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata-field-values/dso-edit-metadata-field-values.component.html @@ -1,6 +1,6 @@
- - + -
{{ dsoType + '.edit.metadata.headers.field' | translate }}
-
+
+
{{ dsoType + '.edit.metadata.headers.field' | translate }}
+
{{ dsoType + '.edit.metadata.headers.value' | translate }}
{{ dsoType + '.edit.metadata.headers.language' | translate }}
diff --git a/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata.component.html b/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata.component.html index 54392a00b05..686604c8088 100644 --- a/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata.component.html +++ b/src/app/dso-shared/dso-edit-metadata/dso-edit-metadata.component.html @@ -38,7 +38,7 @@
- + { ], }) .overrideComponent(FileDownloadLinkComponent, { - remove: { imports: [RouterLink] }, + remove: { imports: [RouterLink, ThemedAccessStatusBadgeComponent] }, add: { imports: [RouterLinkDirectiveStub] }, }) .compileComponents(); diff --git a/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts b/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts index 7ca5800a803..4c53f3598de 100644 --- a/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts +++ b/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts @@ -21,8 +21,8 @@ import { LinkService } from '../../../../../core/cache/builders/link.service'; import { Bitstream } from '../../../../../core/shared/bitstream.model'; import { Item } from '../../../../../core/shared/item.model'; import { getFirstSucceededRemoteDataPayload } from '../../../../../core/shared/operators'; -import { followLink } from '../../../../utils/follow-link-config.model'; import { hasValue } from '../../../../empty.util'; +import { followLink } from '../../../../utils/follow-link-config.model'; import { AccessStatusObject } from './access-status.model'; @Component({ diff --git a/src/app/thumbnail/thumbnail.component.spec.ts b/src/app/thumbnail/thumbnail.component.spec.ts index 38eceb84276..3698a103efb 100644 --- a/src/app/thumbnail/thumbnail.component.spec.ts +++ b/src/app/thumbnail/thumbnail.component.spec.ts @@ -288,6 +288,7 @@ describe('ThumbnailComponent', () => { format: { href: 'format.url' }, content: { href: CONTENT }, thumbnail: undefined, + accessStatus: { href: 'accessStatus.url' }, }; comp.thumbnail = thumbnail; }); @@ -324,6 +325,7 @@ describe('ThumbnailComponent', () => { format: { href: 'format.url' }, content: { href: CONTENT }, thumbnail: undefined, + accessStatus: { href: 'accessStatus.url' }, }; }); diff --git a/src/themes/custom/app/shared/file-download-link/file-download-link.component.ts b/src/themes/custom/app/shared/file-download-link/file-download-link.component.ts index 8bf76056d5e..2f5a887d60e 100644 --- a/src/themes/custom/app/shared/file-download-link/file-download-link.component.ts +++ b/src/themes/custom/app/shared/file-download-link/file-download-link.component.ts @@ -8,8 +8,8 @@ import { Component } from '@angular/core'; import { RouterLink } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; -import { ThemedAccessStatusBadgeComponent } from '../../../../../app/shared/object-collection/shared/badges/access-status-badge/themed-access-status-badge.component'; import { FileDownloadLinkComponent as BaseComponent } from '../../../../../app/shared/file-download-link/file-download-link.component'; +import { ThemedAccessStatusBadgeComponent } from '../../../../../app/shared/object-collection/shared/badges/access-status-badge/themed-access-status-badge.component'; @Component({ selector: 'ds-themed-file-download-link', diff --git a/src/themes/datashare/app/item-page/simple/field-components/file-section/file-section.component.ts b/src/themes/datashare/app/item-page/simple/field-components/file-section/file-section.component.ts index 895dfc9107c..e9d32d5d139 100644 --- a/src/themes/datashare/app/item-page/simple/field-components/file-section/file-section.component.ts +++ b/src/themes/datashare/app/item-page/simple/field-components/file-section/file-section.component.ts @@ -18,11 +18,13 @@ import { } from 'rxjs'; import { DSONameService } from '../../../../../../../app/core/breadcrumbs/dso-name.service'; +import { AccessStatusDataService } from '../../../../../../../app/core/data/access-status-data.service'; import { BitstreamDataService } from '../../../../../../../app/core/data/bitstream-data.service'; import { PaginatedList } from '../../../../../../../app/core/data/paginated-list.model'; import { RemoteData } from '../../../../../../../app/core/data/remote-data'; import { PaginationService } from '../../../../../../../app/core/pagination/pagination.service'; import { Bitstream } from '../../../../../../../app/core/shared/bitstream.model'; +import { getFirstCompletedRemoteData } from '../../../../../../../app/core/shared/operators'; import { DownloadLinkService } from '../../../../../../../app/datashare/download-link.service'; import { FileSectionComponent as BaseComponent } from '../../../../../../../app/item-page/simple/field-components/file-section/file-section.component'; import { GenericItemPageFieldComponent } from '../../../../../../../app/item-page/simple/field-components/specific-field/generic/generic-item-page-field.component'; @@ -34,18 +36,6 @@ import { import { ThemedFileDownloadLinkComponent } from '../../../../../../../app/shared/file-download-link/themed-file-download-link.component'; import { ThemedLoadingComponent } from '../../../../../../../app/shared/loading/themed-loading.component'; import { MetadataFieldWrapperComponent } from '../../../../../../../app/shared/metadata-field-wrapper/metadata-field-wrapper.component'; -import { FileSizePipe } from '../../../../../../../app/shared/utils/file-size-pipe'; -import { VarDirective } from '../../../../../../../app/shared/utils/var.directive'; -import { getFirstCompletedRemoteData } from '../../../../../../../app/core/shared/operators'; -import { filter, map, Observable, switchMap, tap } from 'rxjs'; -import { RemoteData } from '../../../../../../../app/core/data/remote-data'; -import { PaginatedList } from '../../../../../../../app/core/data/paginated-list.model'; -import { Bitstream } from '../../../../../../../app/core/shared/bitstream.model'; -import { hasValue, isEmpty } from '../../../../../../../app/shared/empty.util'; -import { PaginationComponentOptions } from '../../../../../../../app/shared/pagination/pagination-component-options.model'; -import { followLink } from '../../../../../../../app/shared/utils/follow-link-config.model'; -import { BitstreamDataService } from '../../../../../../../app/core/data/bitstream-data.service'; -import { AccessStatusDataService } from '../../../../../../../app/core/data/access-status-data.service'; import { NotificationsService } from '../../../../../../../app/shared/notifications/notifications.service'; import { PaginationComponent } from '../../../../../../../app/shared/pagination/pagination.component'; import { PaginationComponentOptions } from '../../../../../../../app/shared/pagination/pagination-component-options.model'; diff --git a/src/themes/datashare/app/shared/file-download-link/file-download-link.component.ts b/src/themes/datashare/app/shared/file-download-link/file-download-link.component.ts index 8bf76056d5e..2f5a887d60e 100644 --- a/src/themes/datashare/app/shared/file-download-link/file-download-link.component.ts +++ b/src/themes/datashare/app/shared/file-download-link/file-download-link.component.ts @@ -8,8 +8,8 @@ import { Component } from '@angular/core'; import { RouterLink } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; -import { ThemedAccessStatusBadgeComponent } from '../../../../../app/shared/object-collection/shared/badges/access-status-badge/themed-access-status-badge.component'; import { FileDownloadLinkComponent as BaseComponent } from '../../../../../app/shared/file-download-link/file-download-link.component'; +import { ThemedAccessStatusBadgeComponent } from '../../../../../app/shared/object-collection/shared/badges/access-status-badge/themed-access-status-badge.component'; @Component({ selector: 'ds-themed-file-download-link',