mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-10-01 14:41:32 +00:00
Title moved to within fieldset as legend.
This commit is contained in:
@@ -1,21 +1,13 @@
|
|||||||
<div class="checklist">
|
<fieldset>
|
||||||
<fieldset>
|
<legend class="adf-search-check-list-title">{{ name | translate }}</legend>
|
||||||
<mat-checkbox
|
<mat-checkbox *ngFor="let option of options" [checked]="option.checked"
|
||||||
*ngFor="let option of options"
|
(keydown.enter)="option.checked = !option.checked" [attr.data-automation-id]="'checkbox-' + (option.name)"
|
||||||
[checked]="option.checked"
|
[attr.aria-label]="option.name | translate" (change)="changeHandler($event, option)" class="adf-facet-filter">
|
||||||
(keydown.enter)="option.checked = !option.checked"
|
<div matTooltip="{{ option.name | translate }}" matTooltipPosition="right" class="facet-name">
|
||||||
[attr.data-automation-id]="'checkbox-' + (option.name)"
|
|
||||||
[attr.aria-label]="option.name | translate"
|
|
||||||
(change)="changeHandler($event, option)"
|
|
||||||
class="adf-facet-filter">
|
|
||||||
<div matTooltip="{{ option.name | translate }}"
|
|
||||||
matTooltipPosition="right"
|
|
||||||
class="facet-name">
|
|
||||||
{{ option.name | translate }}
|
{{ option.name | translate }}
|
||||||
</div>
|
</div>
|
||||||
</mat-checkbox>
|
</mat-checkbox>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="adf-facet-buttons" *ngIf="options.fitsPage && !settings?.hideDefaultAction">
|
<div class="adf-facet-buttons" *ngIf="options.fitsPage && !settings?.hideDefaultAction">
|
||||||
<button mat-button color="primary" (click)="clear()">
|
<button mat-button color="primary" (click)="clear()">
|
||||||
@@ -24,20 +16,14 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="adf-facet-buttons" *ngIf="!options.fitsPage">
|
<div class="adf-facet-buttons" *ngIf="!options.fitsPage">
|
||||||
<button mat-icon-button
|
<button mat-icon-button title="{{ 'SEARCH.FILTER.ACTIONS.CLEAR-ALL' | translate }}" (click)="clear()">
|
||||||
title="{{ 'SEARCH.FILTER.ACTIONS.CLEAR-ALL' | translate }}"
|
|
||||||
(click)="clear()">
|
|
||||||
<mat-icon>clear</mat-icon>
|
<mat-icon>clear</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
<button mat-icon-button
|
<button mat-icon-button *ngIf="options.canShowLessItems" title="{{ 'SEARCH.FILTER.ACTIONS.SHOW-LESS' | translate }}"
|
||||||
*ngIf="options.canShowLessItems"
|
|
||||||
title="{{ 'SEARCH.FILTER.ACTIONS.SHOW-LESS' | translate }}"
|
|
||||||
(click)="options.showLessItems()">
|
(click)="options.showLessItems()">
|
||||||
<mat-icon>keyboard_arrow_up</mat-icon>
|
<mat-icon>keyboard_arrow_up</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
<button mat-icon-button
|
<button mat-icon-button *ngIf="options.canShowMoreItems" title="{{ 'SEARCH.FILTER.ACTIONS.SHOW-MORE' | translate }}"
|
||||||
*ngIf="options.canShowMoreItems"
|
|
||||||
title="{{ 'SEARCH.FILTER.ACTIONS.SHOW-MORE' | translate }}"
|
|
||||||
(click)="options.showMoreItems()">
|
(click)="options.showMoreItems()">
|
||||||
<mat-icon>keyboard_arrow_down</mat-icon>
|
<mat-icon>keyboard_arrow_down</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
.adf-search-check-list > div {
|
.adf-search-check-list > fieldset {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
||||||
@@ -25,6 +25,15 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.adf-search-check-list {
|
||||||
|
&-title {
|
||||||
|
font-size: 1.1em;
|
||||||
|
padding-bottom: 5px;
|
||||||
|
color: var(--theme-text-bold-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
fieldset {
|
fieldset {
|
||||||
border: 0 none;
|
border: 0 none;
|
||||||
}
|
}
|
||||||
|
@@ -40,6 +40,7 @@ export interface SearchListOption {
|
|||||||
export class SearchCheckListComponent implements SearchWidget, OnInit {
|
export class SearchCheckListComponent implements SearchWidget, OnInit {
|
||||||
|
|
||||||
id: string;
|
id: string;
|
||||||
|
name: string;
|
||||||
settings?: SearchWidgetSettings;
|
settings?: SearchWidgetSettings;
|
||||||
context?: SearchQueryBuilderService;
|
context?: SearchQueryBuilderService;
|
||||||
options: SearchFilterList<SearchListOption>;
|
options: SearchFilterList<SearchListOption>;
|
||||||
|
@@ -26,9 +26,9 @@
|
|||||||
(keydown.tab)="$event.stopPropagation();">
|
(keydown.tab)="$event.stopPropagation();">
|
||||||
<div (click)="$event.stopPropagation()"
|
<div (click)="$event.stopPropagation()"
|
||||||
class="adf-filter-container">
|
class="adf-filter-container">
|
||||||
<div class="adf-filter-title">{{ category?.name | translate }}</div>
|
|
||||||
<adf-search-widget-container (keypress)="onKeyPressed($event, menuTrigger)"
|
<adf-search-widget-container (keypress)="onKeyPressed($event, menuTrigger)"
|
||||||
[id]="category?.id"
|
[id]="category?.id"
|
||||||
|
[name]="category?.name"
|
||||||
[selector]="category?.component?.selector"
|
[selector]="category?.component?.selector"
|
||||||
[settings]="category?.component?.settings"
|
[settings]="category?.component?.settings"
|
||||||
[value]="initialValue">
|
[value]="initialValue">
|
||||||
|
@@ -47,12 +47,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&-title {
|
|
||||||
font-size: 1.1em;
|
|
||||||
padding-bottom: 5px;
|
|
||||||
color: var(--theme-text-bold-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
&-actions {
|
&-actions {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-end;
|
justify-content: flex-end;
|
||||||
|
@@ -45,6 +45,9 @@ export class SearchWidgetContainerComponent implements OnInit, OnDestroy, OnChan
|
|||||||
@Input()
|
@Input()
|
||||||
id: string;
|
id: string;
|
||||||
|
|
||||||
|
@Input()
|
||||||
|
name: string;
|
||||||
|
|
||||||
@Input()
|
@Input()
|
||||||
selector: string;
|
selector: string;
|
||||||
|
|
||||||
@@ -87,6 +90,7 @@ export class SearchWidgetContainerComponent implements OnInit, OnDestroy, OnChan
|
|||||||
private setupWidget(ref: ComponentRef<any>) {
|
private setupWidget(ref: ComponentRef<any>) {
|
||||||
if (ref && ref.instance) {
|
if (ref && ref.instance) {
|
||||||
ref.instance.id = this.id;
|
ref.instance.id = this.id;
|
||||||
|
ref.instance.name = this.name;
|
||||||
ref.instance.settings = {...this.settings};
|
ref.instance.settings = {...this.settings};
|
||||||
ref.instance.context = this.queryBuilder;
|
ref.instance.context = this.queryBuilder;
|
||||||
if (this.value) {
|
if (this.value) {
|
||||||
|
Reference in New Issue
Block a user