+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ 'explore.counters-section.' + counter.label | translate }}
+
+
+ {{ counter.count }}
+
-
- {{'explore.counters-section.' + counter.label | translate}}
-
-
- {{counter.count}}
-
-
+
+
diff --git a/src/app/shared/explore/section-component/counters-section/counters-section.component.scss b/src/app/shared/explore/section-component/counters-section/counters-section.component.scss
new file mode 100644
index 00000000000..c08f994bbe7
--- /dev/null
+++ b/src/app/shared/explore/section-component/counters-section/counters-section.component.scss
@@ -0,0 +1,13 @@
+.counters-section {
+ min-width: 120px;
+ max-width: 140px;
+ color: var(--bs-gray-800);
+
+ &:hover {
+ color: #{darken($gray-800, 20%)};
+ }
+}
+
+.counters-label {
+ line-height: 1.25;
+}
diff --git a/src/app/shared/explore/section-component/counters-section/counters-section.component.ts b/src/app/shared/explore/section-component/counters-section/counters-section.component.ts
index 3d7860d5e38..19273bbb627 100644
--- a/src/app/shared/explore/section-component/counters-section/counters-section.component.ts
+++ b/src/app/shared/explore/section-component/counters-section/counters-section.component.ts
@@ -4,7 +4,6 @@ import { isPlatformServer } from '@angular/common';
import { BehaviorSubject, forkJoin, Observable } from 'rxjs';
import { map } from 'rxjs/operators';
-import { NativeWindowRef, NativeWindowService } from '../../../../core/services/window.service';
import { DSpaceObject } from '../../../../core/shared/dspace-object.model';
import { SearchObjects } from '../../../search/models/search-objects.model';
import { getFirstSucceededRemoteDataPayload } from '../../../../core/shared/operators';
@@ -12,11 +11,12 @@ import { PaginationComponentOptions } from '../../../pagination/pagination-compo
import { SectionComponent } from '../../../../core/layout/models/section.model';
import { SearchService } from '../../../../core/shared/search/search.service';
import { PaginatedSearchOptions } from '../../../search/models/paginated-search-options.model';
-import { hasValue } from '../../../empty.util';
import { UUIDService } from '../../../../core/shared/uuid.service';
+import { InternalLinkService } from 'src/app/core/services/internal-link.service';
@Component({
selector: 'ds-counters-section',
+ styleUrls: ['./counters-section.component.scss'],
templateUrl: './counters-section.component.html'
})
export class CountersSectionComponent implements OnInit {
@@ -38,10 +38,12 @@ export class CountersSectionComponent implements OnInit {
});
- constructor(private searchService: SearchService,
+ constructor(
+ public internalLinkService: InternalLinkService,
+ private searchService: SearchService,
private uuidService: UUIDService,
@Inject(PLATFORM_ID) private platformId: Object,
- @Inject(NativeWindowService) protected _window: NativeWindowRef,) {
+ ) {
}
@@ -69,12 +71,6 @@ export class CountersSectionComponent implements OnInit {
)));
this.counterData$.subscribe(() => this.isLoading$.next(false));
}
-
- goToLink(link: string) {
- if (hasValue(link)) {
- this._window.nativeWindow.location.href = link;
- }
- }
}