mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-10-01 14:41:32 +00:00
[ADF-5062] Content Node Selector - show inputs based on configuration (#5368)
* toggle search and dropdown list by configuration * update docs * tests * fix inputs setter * rename
This commit is contained in:
committed by
Eugenio Romano
parent
3cf12fca49
commit
b931c4a85c
@@ -54,6 +54,9 @@ export class ContentNodeSelectorPanelComponent implements OnInit, OnDestroy {
|
||||
hasMoreItems: false
|
||||
});
|
||||
|
||||
private showSiteList = true;
|
||||
private showSearchField = true;
|
||||
|
||||
/** Node ID of the folder currently listed. */
|
||||
@Input()
|
||||
currentFolderId: string = null;
|
||||
@@ -136,6 +139,30 @@ export class ContentNodeSelectorPanelComponent implements OnInit, OnDestroy {
|
||||
@Input()
|
||||
breadcrumbTransform: (node) => any;
|
||||
|
||||
/** Toggle search input rendering */
|
||||
@Input()
|
||||
set showSearch(value: boolean) {
|
||||
if (value !== undefined && value !== null) {
|
||||
this.showSearchField = value;
|
||||
}
|
||||
}
|
||||
|
||||
get showSearch(): boolean {
|
||||
return this.showSearchField;
|
||||
}
|
||||
|
||||
/** Toggle sites list dropdown rendering */
|
||||
@Input()
|
||||
set showDropdownSiteList(value: boolean) {
|
||||
if (value !== undefined && value !== null) {
|
||||
this.showSiteList = value;
|
||||
}
|
||||
}
|
||||
|
||||
get showDropdownSiteList(): boolean {
|
||||
return this.showSiteList;
|
||||
}
|
||||
|
||||
/** Emitted when the user has chosen an item. */
|
||||
@Output()
|
||||
select: EventEmitter<Node[]> = new EventEmitter<Node[]>();
|
||||
|
Reference in New Issue
Block a user