mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-08 02:24:11 +00:00
Fixed home news facets sidebar & home content section alignment when facets are disabled
This commit is contained in:
@@ -1 +1 @@
|
|||||||
<ds-configuration-search-page configuration="administrativeView" [context]="context"></ds-configuration-search-page>
|
<ds-themed-configuration-search-page configuration="administrativeView" [context]="context"></ds-themed-configuration-search-page>
|
||||||
|
@@ -6,7 +6,7 @@ import {
|
|||||||
} from '@angular/core/testing';
|
} from '@angular/core/testing';
|
||||||
import { ActivatedRoute } from '@angular/router';
|
import { ActivatedRoute } from '@angular/router';
|
||||||
|
|
||||||
import { ConfigurationSearchPageComponent } from '../../search-page/configuration-search-page.component';
|
import { ThemedConfigurationSearchPageComponent } from '../../search-page/themed-configuration-search-page.component';
|
||||||
import { ActivatedRouteStub } from '../../shared/testing/active-router.stub';
|
import { ActivatedRouteStub } from '../../shared/testing/active-router.stub';
|
||||||
import { AdminSearchPageComponent } from './admin-search-page.component';
|
import { AdminSearchPageComponent } from './admin-search-page.component';
|
||||||
|
|
||||||
@@ -23,7 +23,7 @@ describe('AdminSearchPageComponent', () => {
|
|||||||
schemas: [NO_ERRORS_SCHEMA],
|
schemas: [NO_ERRORS_SCHEMA],
|
||||||
}).overrideComponent(AdminSearchPageComponent, {
|
}).overrideComponent(AdminSearchPageComponent, {
|
||||||
remove: {
|
remove: {
|
||||||
imports: [ConfigurationSearchPageComponent],
|
imports: [ThemedConfigurationSearchPageComponent],
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
.compileComponents();
|
.compileComponents();
|
||||||
|
@@ -1,14 +1,14 @@
|
|||||||
import { Component } from '@angular/core';
|
import { Component } from '@angular/core';
|
||||||
|
|
||||||
import { Context } from '../../core/shared/context.model';
|
import { Context } from '../../core/shared/context.model';
|
||||||
import { ConfigurationSearchPageComponent } from '../../search-page/configuration-search-page.component';
|
import { ThemedConfigurationSearchPageComponent } from '../../search-page/themed-configuration-search-page.component';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'ds-admin-search-page',
|
selector: 'ds-admin-search-page',
|
||||||
templateUrl: './admin-search-page.component.html',
|
templateUrl: './admin-search-page.component.html',
|
||||||
styleUrls: ['./admin-search-page.component.scss'],
|
styleUrls: ['./admin-search-page.component.scss'],
|
||||||
standalone: true,
|
standalone: true,
|
||||||
imports: [ConfigurationSearchPageComponent],
|
imports: [ThemedConfigurationSearchPageComponent],
|
||||||
})
|
})
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -1 +1 @@
|
|||||||
<ds-configuration-search-page configuration="supervision" [context]="context"></ds-configuration-search-page>
|
<ds-themed-configuration-search-page configuration="supervision" [context]="context"></ds-themed-configuration-search-page>
|
||||||
|
@@ -5,7 +5,7 @@ import {
|
|||||||
waitForAsync,
|
waitForAsync,
|
||||||
} from '@angular/core/testing';
|
} from '@angular/core/testing';
|
||||||
|
|
||||||
import { ConfigurationSearchPageComponent } from '../../search-page/configuration-search-page.component';
|
import { ThemedConfigurationSearchPageComponent } from '../../search-page/themed-configuration-search-page.component';
|
||||||
import { AdminWorkflowPageComponent } from './admin-workflow-page.component';
|
import { AdminWorkflowPageComponent } from './admin-workflow-page.component';
|
||||||
|
|
||||||
describe('AdminSearchPageComponent', () => {
|
describe('AdminSearchPageComponent', () => {
|
||||||
@@ -20,7 +20,7 @@ describe('AdminSearchPageComponent', () => {
|
|||||||
.overrideComponent(AdminWorkflowPageComponent, {
|
.overrideComponent(AdminWorkflowPageComponent, {
|
||||||
remove: {
|
remove: {
|
||||||
imports: [
|
imports: [
|
||||||
ConfigurationSearchPageComponent,
|
ThemedConfigurationSearchPageComponent,
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
@@ -1,14 +1,14 @@
|
|||||||
import { Component } from '@angular/core';
|
import { Component } from '@angular/core';
|
||||||
|
|
||||||
import { Context } from '../../core/shared/context.model';
|
import { Context } from '../../core/shared/context.model';
|
||||||
import { ConfigurationSearchPageComponent } from '../../search-page/configuration-search-page.component';
|
import { ThemedConfigurationSearchPageComponent } from '../../search-page/themed-configuration-search-page.component';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'ds-admin-workflow-page',
|
selector: 'ds-admin-workflow-page',
|
||||||
templateUrl: './admin-workflow-page.component.html',
|
templateUrl: './admin-workflow-page.component.html',
|
||||||
styleUrls: ['./admin-workflow-page.component.scss'],
|
styleUrls: ['./admin-workflow-page.component.scss'],
|
||||||
standalone: true,
|
standalone: true,
|
||||||
imports: [ConfigurationSearchPageComponent],
|
imports: [ThemedConfigurationSearchPageComponent],
|
||||||
})
|
})
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -1,19 +1,28 @@
|
|||||||
<ds-themed-home-news></ds-themed-home-news>
|
<ds-themed-home-news></ds-themed-home-news>
|
||||||
<div [ngClass]="appConfig.homePage.showDiscoverFilters ? 'container-fluid' : 'container'">
|
<div [ngClass]="showDiscoverFilters ? 'container-fluid' : 'container'">
|
||||||
<div class="row m-5">
|
<ds-page-with-sidebar [sidebarContent]="sidebar" [sideBarWidth]="3" [class]="showDiscoverFilters ? 'row mx-3' : ''">
|
||||||
<div class="col-sm-3" *ngIf="appConfig.homePage.showDiscoverFilters">
|
<div [class.col-sm-12]="showDiscoverFilters">
|
||||||
<ds-configuration-search-page [sideBarWidth]="12" [showViewModes]="false" [searchEnabled]="false"
|
<button *ngIf="(isXsOrSm$ | async) && sidebarService.isCollapsed" (click)="sidebarService.expand()"
|
||||||
[inPlaceSearch]="false" [showScopeSelector]="false"></ds-configuration-search-page>
|
class="btn btn-outline-primary d-block ml-auto mb-3">
|
||||||
</div>
|
<i class="fas fa-sliders"></i> {{ 'search.sidebar.open' | translate }}
|
||||||
<div [ngClass]="appConfig.homePage.showDiscoverFilters ? 'col-sm-9' : 'col-sm-12'">
|
</button>
|
||||||
<ng-container *ngIf="(site$ | async) as site">
|
<ng-container *ngIf="(site$ | async) as site">
|
||||||
<ds-view-tracker [object]="site"></ds-view-tracker>
|
<ds-view-tracker [object]="site"></ds-view-tracker>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ds-themed-search-form [inPlaceSearch]="false"
|
<ds-themed-search-form [inPlaceSearch]="false"
|
||||||
[searchPlaceholder]="'home.search-form.placeholder' | translate"></ds-themed-search-form>
|
[searchPlaceholder]="'home.search-form.placeholder' | translate">
|
||||||
|
</ds-themed-search-form>
|
||||||
<ds-themed-top-level-community-list></ds-themed-top-level-community-list>
|
<ds-themed-top-level-community-list></ds-themed-top-level-community-list>
|
||||||
<ds-recent-item-list *ngIf="recentSubmissionspageSize>0"></ds-recent-item-list>
|
<ds-recent-item-list *ngIf="recentSubmissionspageSize>0"></ds-recent-item-list>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</ds-page-with-sidebar>
|
||||||
</div>
|
</div>
|
||||||
<ds-suggestions-popup></ds-suggestions-popup>
|
<ds-suggestions-popup></ds-suggestions-popup>
|
||||||
|
|
||||||
|
<ng-template #sidebar>
|
||||||
|
<div *ngIf="showDiscoverFilters">
|
||||||
|
<ds-themed-configuration-search-page [sideBarWidth]="12" [showViewModes]="false" [searchEnabled]="false"
|
||||||
|
[inPlaceSearch]="false" [showScopeSelector]="false">
|
||||||
|
</ds-themed-configuration-search-page>
|
||||||
|
</div>
|
||||||
|
</ng-template>
|
||||||
|
@@ -1,2 +1,5 @@
|
|||||||
:host {
|
:host ::ng-deep {
|
||||||
|
.container-fluid .container {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
}
|
}
|
@@ -12,6 +12,10 @@ import {
|
|||||||
PLATFORM_ID,
|
PLATFORM_ID,
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { ActivatedRoute } from '@angular/router';
|
import { ActivatedRoute } from '@angular/router';
|
||||||
|
import { Observable } from 'rxjs';
|
||||||
|
import { Site } from '../core/shared/site.model';
|
||||||
|
import { isPlatformServer } from '@angular/common';
|
||||||
|
import { ServerResponseService } from '../core/services/server-response.service';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
import {
|
import {
|
||||||
EMPTY,
|
EMPTY,
|
||||||
@@ -37,6 +41,10 @@ import { Site } from '../core/shared/site.model';
|
|||||||
import { SuggestionsPopupComponent } from '../notifications/suggestions-popup/suggestions-popup.component';
|
import { SuggestionsPopupComponent } from '../notifications/suggestions-popup/suggestions-popup.component';
|
||||||
import { ConfigurationSearchPageComponent } from '../search-page/configuration-search-page.component';
|
import { ConfigurationSearchPageComponent } from '../search-page/configuration-search-page.component';
|
||||||
import { isNotEmpty } from '../shared/empty.util';
|
import { isNotEmpty } from '../shared/empty.util';
|
||||||
|
import { APP_CONFIG, AppConfig } from 'src/config/app-config.interface';
|
||||||
|
import { HostWindowService } from '../shared/host-window.service';
|
||||||
|
import { SidebarService } from '../shared/sidebar/sidebar.service';
|
||||||
|
|
||||||
import { ThemedSearchFormComponent } from '../shared/search-form/themed-search-form.component';
|
import { ThemedSearchFormComponent } from '../shared/search-form/themed-search-form.component';
|
||||||
import { ViewTrackerComponent } from '../statistics/angulartics/dspace/view-tracker.component';
|
import { ViewTrackerComponent } from '../statistics/angulartics/dspace/view-tracker.component';
|
||||||
import { ThemedHomeNewsComponent } from './home-news/themed-home-news.component';
|
import { ThemedHomeNewsComponent } from './home-news/themed-home-news.component';
|
||||||
@@ -53,7 +61,9 @@ import { ThemedTopLevelCommunityListComponent } from './top-level-community-list
|
|||||||
export class HomePageComponent implements OnInit, OnDestroy {
|
export class HomePageComponent implements OnInit, OnDestroy {
|
||||||
|
|
||||||
site$: Observable<Site>;
|
site$: Observable<Site>;
|
||||||
|
isXsOrSm$: Observable<boolean>;
|
||||||
recentSubmissionspageSize: number;
|
recentSubmissionspageSize: number;
|
||||||
|
showDiscoverFilters: boolean;
|
||||||
/**
|
/**
|
||||||
* An array of LinkDefinition objects representing inbox links for the home page.
|
* An array of LinkDefinition objects representing inbox links for the home page.
|
||||||
*/
|
*/
|
||||||
@@ -61,13 +71,17 @@ export class HomePageComponent implements OnInit, OnDestroy {
|
|||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
@Inject(APP_CONFIG) protected appConfig: AppConfig,
|
@Inject(APP_CONFIG) protected appConfig: AppConfig,
|
||||||
private route: ActivatedRoute,
|
protected route: ActivatedRoute,
|
||||||
private responseService: ServerResponseService,
|
protected responseService: ServerResponseService,
|
||||||
private notifyInfoService: NotifyInfoService,
|
protected notifyInfoService: NotifyInfoService,
|
||||||
protected linkHeadService: LinkHeadService,
|
protected linkHeadService: LinkHeadService,
|
||||||
@Inject(PLATFORM_ID) private platformId: string,
|
@Inject(PLATFORM_ID) private platformId: string,
|
||||||
|
protected sidebarService: SidebarService,
|
||||||
|
protected windowService: HostWindowService,
|
||||||
|
@Inject(PLATFORM_ID) protected platformId: string,
|
||||||
) {
|
) {
|
||||||
this.recentSubmissionspageSize = environment.homePage.recentSubmissions.pageSize;
|
this.recentSubmissionspageSize = this.appConfig.homePage.recentSubmissions.pageSize;
|
||||||
|
this.showDiscoverFilters = this.appConfig.homePage.showDiscoverFilters;
|
||||||
// Get COAR REST API URLs from REST configuration
|
// Get COAR REST API URLs from REST configuration
|
||||||
// only if COAR configuration is enabled
|
// only if COAR configuration is enabled
|
||||||
this.notifyInfoService.isCoarConfigEnabled().pipe(
|
this.notifyInfoService.isCoarConfigEnabled().pipe(
|
||||||
@@ -86,6 +100,7 @@ export class HomePageComponent implements OnInit, OnDestroy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
|
this.isXsOrSm$ = this.windowService.isXsOrSm();
|
||||||
this.site$ = this.route.data.pipe(
|
this.site$ = this.route.data.pipe(
|
||||||
map((data) => data.site as Site),
|
map((data) => data.site as Site),
|
||||||
);
|
);
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
<ds-configuration-search-page
|
<ds-themed-configuration-search-page
|
||||||
[fixedFilterQuery]="fixedFilter"
|
[fixedFilterQuery]="fixedFilter"
|
||||||
[configuration]="configuration"
|
[configuration]="configuration"
|
||||||
[searchEnabled]="searchEnabled"
|
[searchEnabled]="searchEnabled"
|
||||||
[sideBarWidth]="sideBarWidth"
|
[sideBarWidth]="sideBarWidth"
|
||||||
[showCsvExport]="true">
|
[showCsvExport]="true">
|
||||||
</ds-configuration-search-page>
|
</ds-themed-configuration-search-page>
|
||||||
|
@@ -9,7 +9,7 @@ import { NoopAnimationsModule } from '@angular/platform-browser/animations';
|
|||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
|
|
||||||
import { Item } from '../../../../core/shared/item.model';
|
import { Item } from '../../../../core/shared/item.model';
|
||||||
import { ConfigurationSearchPageComponent } from '../../../../search-page/configuration-search-page.component';
|
import { ThemedConfigurationSearchPageComponent } from '../../../../search-page/themed-configuration-search-page.component';
|
||||||
import { RelatedEntitiesSearchComponent } from './related-entities-search.component';
|
import { RelatedEntitiesSearchComponent } from './related-entities-search.component';
|
||||||
|
|
||||||
describe('RelatedEntitiesSearchComponent', () => {
|
describe('RelatedEntitiesSearchComponent', () => {
|
||||||
@@ -30,7 +30,7 @@ describe('RelatedEntitiesSearchComponent', () => {
|
|||||||
})
|
})
|
||||||
.overrideComponent(RelatedEntitiesSearchComponent, {
|
.overrideComponent(RelatedEntitiesSearchComponent, {
|
||||||
remove: {
|
remove: {
|
||||||
imports: [ConfigurationSearchPageComponent],
|
imports: [ThemedConfigurationSearchPageComponent],
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
.compileComponents();
|
.compileComponents();
|
||||||
|
@@ -5,7 +5,7 @@ import {
|
|||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
|
|
||||||
import { Item } from '../../../../core/shared/item.model';
|
import { Item } from '../../../../core/shared/item.model';
|
||||||
import { ConfigurationSearchPageComponent } from '../../../../search-page/configuration-search-page.component';
|
import { ThemedConfigurationSearchPageComponent } from '../../../../search-page/themed-configuration-search-page.component';
|
||||||
import { isNotEmpty } from '../../../../shared/empty.util';
|
import { isNotEmpty } from '../../../../shared/empty.util';
|
||||||
import { getFilterByRelation } from '../../../../shared/utils/relation-query.utils';
|
import { getFilterByRelation } from '../../../../shared/utils/relation-query.utils';
|
||||||
|
|
||||||
@@ -13,7 +13,7 @@ import { getFilterByRelation } from '../../../../shared/utils/relation-query.uti
|
|||||||
selector: 'ds-related-entities-search',
|
selector: 'ds-related-entities-search',
|
||||||
templateUrl: './related-entities-search.component.html',
|
templateUrl: './related-entities-search.component.html',
|
||||||
standalone: true,
|
standalone: true,
|
||||||
imports: [ConfigurationSearchPageComponent],
|
imports: [ThemedConfigurationSearchPageComponent],
|
||||||
})
|
})
|
||||||
/**
|
/**
|
||||||
* A component to show related items as search results.
|
* A component to show related items as search results.
|
||||||
|
@@ -2,9 +2,12 @@ import {
|
|||||||
Component,
|
Component,
|
||||||
Input,
|
Input,
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { Observable } from 'rxjs';
|
|
||||||
|
|
||||||
import { Context } from '../core/shared/context.model';
|
import { Context } from '../core/shared/context.model';
|
||||||
|
import { ViewMode } from '../core/shared/view-mode.model';
|
||||||
|
import { CollectionElementLinkType } from '../shared/object-collection/collection-element-link.type';
|
||||||
|
import { SelectionConfig } from '../shared/search/search-results/search-results.component';
|
||||||
|
import { SearchConfigurationOption } from '../shared/search/search-switch-configuration/search-configuration-option.model';
|
||||||
import { ThemedComponent } from '../shared/theme-support/themed.component';
|
import { ThemedComponent } from '../shared/theme-support/themed.component';
|
||||||
import { ConfigurationSearchPageComponent } from './configuration-search-page.component';
|
import { ConfigurationSearchPageComponent } from './configuration-search-page.component';
|
||||||
|
|
||||||
@@ -13,53 +16,85 @@ import { ConfigurationSearchPageComponent } from './configuration-search-page.co
|
|||||||
*/
|
*/
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'ds-themed-configuration-search-page',
|
selector: 'ds-themed-configuration-search-page',
|
||||||
styleUrls: [],
|
|
||||||
templateUrl: '../shared/theme-support/themed.component.html',
|
templateUrl: '../shared/theme-support/themed.component.html',
|
||||||
standalone: true,
|
standalone: true,
|
||||||
})
|
})
|
||||||
export class ThemedConfigurationSearchPageComponent extends ThemedComponent<ConfigurationSearchPageComponent> {
|
export class ThemedConfigurationSearchPageComponent extends ThemedComponent<ConfigurationSearchPageComponent> {
|
||||||
/**
|
|
||||||
* The configuration to use for the search options
|
@Input() configurationList: SearchConfigurationOption[] = [];
|
||||||
* If empty, the configuration will be determined by the route parameter called 'configuration'
|
|
||||||
*/
|
@Input() context: Context;
|
||||||
|
|
||||||
@Input() configuration: string;
|
@Input() configuration: string;
|
||||||
|
|
||||||
/**
|
|
||||||
* The actual query for the fixed filter.
|
|
||||||
* If empty, the query will be determined by the route parameter called 'filter'
|
|
||||||
*/
|
|
||||||
@Input() fixedFilterQuery: string;
|
@Input() fixedFilterQuery: string;
|
||||||
|
|
||||||
/**
|
@Input() useCachedVersionIfAvailable: boolean;
|
||||||
* True when the search component should show results on the current page
|
|
||||||
*/
|
|
||||||
@Input() inPlaceSearch: boolean;
|
@Input() inPlaceSearch: boolean;
|
||||||
|
|
||||||
/**
|
@Input() linkType: CollectionElementLinkType;
|
||||||
* Whether or not the search bar should be visible
|
|
||||||
*/
|
@Input() paginationId: string;
|
||||||
|
|
||||||
@Input() searchEnabled: boolean;
|
@Input() searchEnabled: boolean;
|
||||||
|
|
||||||
/**
|
@Input() sideBarWidth: number;
|
||||||
* The width of the sidebar (bootstrap columns)
|
|
||||||
*/
|
|
||||||
@Input()
|
|
||||||
sideBarWidth: number;
|
|
||||||
|
|
||||||
/**
|
@Input() searchFormPlaceholder: string;
|
||||||
* The currently applied configuration (determines title of search)
|
|
||||||
*/
|
|
||||||
@Input()
|
|
||||||
configuration$: Observable<string>;
|
|
||||||
|
|
||||||
/**
|
@Input() selectable: boolean;
|
||||||
* The current context
|
|
||||||
*/
|
|
||||||
@Input()
|
|
||||||
context: Context;
|
|
||||||
|
|
||||||
protected inAndOutputNames: (keyof ConfigurationSearchPageComponent & keyof this)[] =
|
@Input() selectionConfig: SelectionConfig;
|
||||||
['context', 'configuration', 'fixedFilterQuery', 'inPlaceSearch', 'searchEnabled', 'sideBarWidth'];
|
|
||||||
|
@Input() showCsvExport: boolean;
|
||||||
|
|
||||||
|
@Input() showSidebar: boolean;
|
||||||
|
|
||||||
|
@Input() showThumbnails: boolean;
|
||||||
|
|
||||||
|
@Input() showViewModes: boolean;
|
||||||
|
|
||||||
|
@Input() useUniquePageId: boolean;
|
||||||
|
|
||||||
|
@Input() viewModeList: ViewMode[];
|
||||||
|
|
||||||
|
@Input() showScopeSelector: boolean;
|
||||||
|
|
||||||
|
@Input() trackStatistics: boolean;
|
||||||
|
|
||||||
|
@Input() query: string;
|
||||||
|
|
||||||
|
@Input() scope: string;
|
||||||
|
|
||||||
|
@Input() hideScopeInUrl: boolean;
|
||||||
|
|
||||||
|
protected inAndOutputNames: (keyof ConfigurationSearchPageComponent & keyof this)[] = [
|
||||||
|
'configurationList',
|
||||||
|
'context',
|
||||||
|
'configuration',
|
||||||
|
'fixedFilterQuery',
|
||||||
|
'useCachedVersionIfAvailable',
|
||||||
|
'inPlaceSearch',
|
||||||
|
'linkType',
|
||||||
|
'paginationId',
|
||||||
|
'searchEnabled',
|
||||||
|
'sideBarWidth',
|
||||||
|
'searchFormPlaceholder',
|
||||||
|
'selectable',
|
||||||
|
'selectionConfig',
|
||||||
|
'showCsvExport',
|
||||||
|
'showSidebar',
|
||||||
|
'showThumbnails',
|
||||||
|
'showViewModes',
|
||||||
|
'useUniquePageId',
|
||||||
|
'viewModeList',
|
||||||
|
'showScopeSelector',
|
||||||
|
'trackStatistics',
|
||||||
|
'query',
|
||||||
|
'scope',
|
||||||
|
'hideScopeInUrl',
|
||||||
|
];
|
||||||
|
|
||||||
protected getComponentName(): string {
|
protected getComponentName(): string {
|
||||||
return 'ConfigurationSearchPageComponent';
|
return 'ConfigurationSearchPageComponent';
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
<div class="container" *ngIf="(isXsOrSm$ | async)">
|
<div class="container" *ngIf="searchEnabled && (isXsOrSm$ | async)">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-12">
|
<div class="col-12">
|
||||||
<ng-template *ngTemplateOutlet="searchForm"></ng-template>
|
<ng-template *ngTemplateOutlet="searchForm"></ng-template>
|
||||||
@@ -18,7 +18,9 @@
|
|||||||
<ng-template #searchContent>
|
<ng-template #searchContent>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-12" *ngIf="(isXsOrSm$ | async) !== true">
|
<div class="col-12" *ngIf="(isXsOrSm$ | async) !== true">
|
||||||
|
<ng-container *ngIf="searchEnabled">
|
||||||
<ng-template *ngTemplateOutlet="searchForm"></ng-template>
|
<ng-template *ngTemplateOutlet="searchForm"></ng-template>
|
||||||
|
</ng-container>
|
||||||
<ng-content select="[additionalSearchOptions]"></ng-content>
|
<ng-content select="[additionalSearchOptions]"></ng-content>
|
||||||
</div>
|
</div>
|
||||||
<div id="search-content" class="col-12">
|
<div id="search-content" class="col-12">
|
||||||
@@ -84,7 +86,7 @@
|
|||||||
</ng-template>
|
</ng-template>
|
||||||
|
|
||||||
<ng-template #searchForm>
|
<ng-template #searchForm>
|
||||||
<ds-themed-search-form *ngIf="searchEnabled" id="search-form"
|
<ds-themed-search-form id="search-form"
|
||||||
[query]="(searchOptions$ | async)?.query"
|
[query]="(searchOptions$ | async)?.query"
|
||||||
[scope]="(searchOptions$ | async)?.scope"
|
[scope]="(searchOptions$ | async)?.scope"
|
||||||
[hideScopeInUrl]="hideScopeInUrl"
|
[hideScopeInUrl]="hideScopeInUrl"
|
||||||
@@ -95,7 +97,7 @@
|
|||||||
</ds-themed-search-form>
|
</ds-themed-search-form>
|
||||||
<div class="row mb-3 mb-md-1">
|
<div class="row mb-3 mb-md-1">
|
||||||
<div class="labels col-sm-9">
|
<div class="labels col-sm-9">
|
||||||
<ds-search-labels *ngIf="searchEnabled" [inPlaceSearch]="inPlaceSearch"></ds-search-labels>
|
<ds-search-labels [inPlaceSearch]="inPlaceSearch"></ds-search-labels>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
|
@@ -12,7 +12,9 @@ import { RecentItemListComponent } from '../../../../app/home-page/recent-item-l
|
|||||||
import { ThemedTopLevelCommunityListComponent } from '../../../../app/home-page/top-level-community-list/themed-top-level-community-list.component';
|
import { ThemedTopLevelCommunityListComponent } from '../../../../app/home-page/top-level-community-list/themed-top-level-community-list.component';
|
||||||
import { SuggestionsPopupComponent } from '../../../../app/notifications/suggestions-popup/suggestions-popup.component';
|
import { SuggestionsPopupComponent } from '../../../../app/notifications/suggestions-popup/suggestions-popup.component';
|
||||||
import { ConfigurationSearchPageComponent } from '../../../../app/search-page/configuration-search-page.component';
|
import { ConfigurationSearchPageComponent } from '../../../../app/search-page/configuration-search-page.component';
|
||||||
|
import { ThemedConfigurationSearchPageComponent } from '../../../../app/search-page/themed-configuration-search-page.component';
|
||||||
import { ThemedSearchFormComponent } from '../../../../app/shared/search-form/themed-search-form.component';
|
import { ThemedSearchFormComponent } from '../../../../app/shared/search-form/themed-search-form.component';
|
||||||
|
import { PageWithSidebarComponent } from '../../../../app/shared/sidebar/page-with-sidebar.component';
|
||||||
import { ViewTrackerComponent } from '../../../../app/statistics/angulartics/dspace/view-tracker.component';
|
import { ViewTrackerComponent } from '../../../../app/statistics/angulartics/dspace/view-tracker.component';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
@@ -22,7 +24,7 @@ import { ViewTrackerComponent } from '../../../../app/statistics/angulartics/dsp
|
|||||||
// templateUrl: './home-page.component.html'
|
// templateUrl: './home-page.component.html'
|
||||||
templateUrl: '../../../../app/home-page/home-page.component.html',
|
templateUrl: '../../../../app/home-page/home-page.component.html',
|
||||||
standalone: true,
|
standalone: true,
|
||||||
imports: [ThemedHomeNewsComponent, NgIf, ViewTrackerComponent, ThemedSearchFormComponent, ThemedTopLevelCommunityListComponent, RecentItemListComponent, AsyncPipe, TranslateModule, NgClass, ConfigurationSearchPageComponent, SuggestionsPopupComponent],
|
imports: [ThemedHomeNewsComponent, NgIf, ViewTrackerComponent, ThemedSearchFormComponent, ThemedTopLevelCommunityListComponent, RecentItemListComponent, AsyncPipe, TranslateModule, NgClass, ConfigurationSearchPageComponent, SuggestionsPopupComponent, ThemedConfigurationSearchPageComponent, PageWithSidebarComponent],
|
||||||
})
|
})
|
||||||
export class HomePageComponent extends BaseComponent {
|
export class HomePageComponent extends BaseComponent {
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user