mirror of
https://github.com/goharbor/harbor.git
synced 2024-12-24 01:27:49 +01:00
Fix: helm chart results style
1. Do not show chart results if chart is not enabled 2. Fix style in scroll of results page Signed-off-by: Qian Deng <dengq@vmware.com>
This commit is contained in:
parent
8ca917291e
commit
d484025fa1
@ -6,11 +6,17 @@
|
||||
<!-- spinner -->
|
||||
<div class="spinner spinner-lg search-spinner" [hidden]="done">{{'SEARCH.IN_PROGRESS' | translate}}</div>
|
||||
<div id="results">
|
||||
<h2>{{'PROJECT.PROJECTS' | translate}}</h2>
|
||||
<list-project-ro [projects]="searchResults.project"></list-project-ro>
|
||||
<h2>{{'PROJECT_DETAIL.REPOSITORIES' | translate}}</h2>
|
||||
<list-repository-ro [repositories]="searchResults.repository"></list-repository-ro>
|
||||
<h2>{{'HELM_CHART.HELMCHARTS' | translate}}</h2>
|
||||
<list-chart-version-ro [charts]="searchResults.Chart"></list-chart-version-ro>
|
||||
<div class="project-results">
|
||||
<h2>{{'PROJECT.PROJECTS' | translate}}</h2>
|
||||
<list-project-ro [projects]="searchResults.project"></list-project-ro>
|
||||
</div>
|
||||
<div class="repo-results">
|
||||
<h2>{{'PROJECT_DETAIL.REPOSITORIES' | translate}}</h2>
|
||||
<list-repository-ro [repositories]="searchResults.repository"></list-repository-ro>
|
||||
</div>
|
||||
<div *ngIf="withHelmChart" class="chart-results">
|
||||
<h2>{{'HELM_CHART.HELMCHARTS' | translate}}</h2>
|
||||
<list-chart-version-ro [charts]="searchResults.Chart"></list-chart-version-ro>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
@ -18,6 +18,7 @@ import { GlobalSearchService } from './global-search.service';
|
||||
import { SearchResults } from './search-results';
|
||||
import { SearchTriggerService } from './search-trigger.service';
|
||||
|
||||
import { AppConfigService } from './../../app-config.service';
|
||||
import { MessageHandlerService } from '../../shared/message-handler/message-handler.service';
|
||||
|
||||
@Component({
|
||||
@ -49,7 +50,8 @@ export class SearchResultComponent implements OnInit, OnDestroy {
|
||||
constructor(
|
||||
private search: GlobalSearchService,
|
||||
private msgHandler: MessageHandlerService,
|
||||
private searchTrigger: SearchTriggerService) { }
|
||||
private searchTrigger: SearchTriggerService,
|
||||
private appConfigService: AppConfigService) { }
|
||||
|
||||
ngOnInit() {
|
||||
this.searchSub = this.searchTrigger.searchTriggerChan$.subscribe(term => {
|
||||
@ -143,4 +145,7 @@ export class SearchResultComponent implements OnInit, OnDestroy {
|
||||
this.msgHandler.handleError(error);
|
||||
});
|
||||
}
|
||||
get withHelmChart(): boolean {
|
||||
return this.appConfigService.getConfig().with_chartmuseum;
|
||||
}
|
||||
}
|
||||
|
@ -68,5 +68,5 @@
|
||||
|
||||
#results {
|
||||
overflow-y: auto;
|
||||
max-height: 99%;
|
||||
max-height: 85%;
|
||||
}
|
Loading…
Reference in New Issue
Block a user