@agorapulse/ui-components 20.4.27 → 20.4.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/agorapulse-ui-components-20.4.29.tgz +0 -0
- package/fesm2022/agorapulse-ui-components-selection-dropdown.mjs +27 -12
- package/fesm2022/agorapulse-ui-components-selection-dropdown.mjs.map +1 -1
- package/package.json +1 -1
- package/selection-dropdown/index.d.ts +13 -5
- package/agorapulse-ui-components-20.4.27.tgz +0 -0
|
Binary file
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { inject, ElementRef, input, HostListener, Directive, viewChild, contentChild, output, effect, untracked, linkedSignal, signal, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { inject, ElementRef, input, HostListener, Directive, viewChild, contentChild, output, model, effect, untracked, linkedSignal, signal, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
3
|
import { CheckboxComponent } from '@agorapulse/ui-components/checkbox';
|
|
4
4
|
import { createDropdownOverlay } from '@agorapulse/ui-components/dropdown-base';
|
|
5
5
|
import { InputSearchComponent } from '@agorapulse/ui-components/input-search';
|
|
@@ -19,8 +19,12 @@ class SelectionDropdownTriggerDirective {
|
|
|
19
19
|
elementRef = inject((ElementRef));
|
|
20
20
|
/** Reference to the SelectionDropdown component that this trigger controls */
|
|
21
21
|
apSelectionDropdownTrigger = input.required(...(ngDevMode ? [{ debugName: "apSelectionDropdownTrigger" }] : []));
|
|
22
|
+
/** Prevents the trigger from opening/toggling the dropdown when true */
|
|
23
|
+
apSelectionDropdownTriggerDisable = input(false, ...(ngDevMode ? [{ debugName: "apSelectionDropdownTriggerDisable" }] : []));
|
|
22
24
|
/** Handles click events to toggle the dropdown */
|
|
23
25
|
onClick(event) {
|
|
26
|
+
if (this.apSelectionDropdownTriggerDisable())
|
|
27
|
+
return;
|
|
24
28
|
event.preventDefault();
|
|
25
29
|
event.stopPropagation();
|
|
26
30
|
this.apSelectionDropdownTrigger().toggle(this.elementRef.nativeElement);
|
|
@@ -32,6 +36,8 @@ class SelectionDropdownTriggerDirective {
|
|
|
32
36
|
case 'Enter':
|
|
33
37
|
case ' ':
|
|
34
38
|
case 'ArrowDown':
|
|
39
|
+
if (this.apSelectionDropdownTriggerDisable())
|
|
40
|
+
return;
|
|
35
41
|
event.preventDefault();
|
|
36
42
|
dropdown.open(this.elementRef.nativeElement);
|
|
37
43
|
break;
|
|
@@ -42,14 +48,14 @@ class SelectionDropdownTriggerDirective {
|
|
|
42
48
|
}
|
|
43
49
|
}
|
|
44
50
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: SelectionDropdownTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
45
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.18", type: SelectionDropdownTriggerDirective, isStandalone: true, selector: "[apSelectionDropdownTrigger]", inputs: { apSelectionDropdownTrigger: { classPropertyName: "apSelectionDropdownTrigger", publicName: "apSelectionDropdownTrigger", isSignal: true, isRequired: true, transformFunction: null } }, host: { listeners: { "click": "onClick($event)", "keydown": "onKeyDown($event)" } }, ngImport: i0 });
|
|
51
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.18", type: SelectionDropdownTriggerDirective, isStandalone: true, selector: "[apSelectionDropdownTrigger]", inputs: { apSelectionDropdownTrigger: { classPropertyName: "apSelectionDropdownTrigger", publicName: "apSelectionDropdownTrigger", isSignal: true, isRequired: true, transformFunction: null }, apSelectionDropdownTriggerDisable: { classPropertyName: "apSelectionDropdownTriggerDisable", publicName: "apSelectionDropdownTriggerDisable", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "onClick($event)", "keydown": "onKeyDown($event)" } }, ngImport: i0 });
|
|
46
52
|
}
|
|
47
53
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: SelectionDropdownTriggerDirective, decorators: [{
|
|
48
54
|
type: Directive,
|
|
49
55
|
args: [{
|
|
50
56
|
selector: '[apSelectionDropdownTrigger]',
|
|
51
57
|
}]
|
|
52
|
-
}], propDecorators: { apSelectionDropdownTrigger: [{ type: i0.Input, args: [{ isSignal: true, alias: "apSelectionDropdownTrigger", required: true }] }], onClick: [{
|
|
58
|
+
}], propDecorators: { apSelectionDropdownTrigger: [{ type: i0.Input, args: [{ isSignal: true, alias: "apSelectionDropdownTrigger", required: true }] }], apSelectionDropdownTriggerDisable: [{ type: i0.Input, args: [{ isSignal: true, alias: "apSelectionDropdownTriggerDisable", required: false }] }], onClick: [{
|
|
53
59
|
type: HostListener,
|
|
54
60
|
args: ['click', ['$event']]
|
|
55
61
|
}], onKeyDown: [{
|
|
@@ -104,6 +110,12 @@ class SelectionDropdownComponent {
|
|
|
104
110
|
headerButtonClick = output();
|
|
105
111
|
/** Emits when the search input is changed */
|
|
106
112
|
searchInputChange = output();
|
|
113
|
+
/**
|
|
114
|
+
* Two-way bindable, clearable search term. Consumers can read it and reset it (set to '')
|
|
115
|
+
* to clear the search and restore the full item list — letting them drive the search
|
|
116
|
+
* declaratively instead of reaching into the rendered `ap-input-search`.
|
|
117
|
+
*/
|
|
118
|
+
searchTerm = model('', ...(ngDevMode ? [{ debugName: "searchTerm" }] : []));
|
|
107
119
|
destroy$ = new Subject();
|
|
108
120
|
searchTermSubject = new Subject();
|
|
109
121
|
inputSearchComponent = viewChild('inputSearchElement', ...(ngDevMode ? [{ debugName: "inputSearchComponent" }] : []));
|
|
@@ -117,7 +129,6 @@ class SelectionDropdownComponent {
|
|
|
117
129
|
});
|
|
118
130
|
}, ...(ngDevMode ? [{ debugName: "focusInput" }] : []));
|
|
119
131
|
internalItems = linkedSignal(() => this.items(), ...(ngDevMode ? [{ debugName: "internalItems" }] : []));
|
|
120
|
-
searchTerm = '';
|
|
121
132
|
filteredItems = signal([], ...(ngDevMode ? [{ debugName: "filteredItems" }] : []));
|
|
122
133
|
initiallySelectedItems = signal([], ...(ngDevMode ? [{ debugName: "initiallySelectedItems" }] : []));
|
|
123
134
|
// Computed properties for template usage
|
|
@@ -173,10 +184,13 @@ class SelectionDropdownComponent {
|
|
|
173
184
|
const items = this.internalItems();
|
|
174
185
|
this.updateFilteredItems(term?.toLowerCase() ?? '', items);
|
|
175
186
|
});
|
|
187
|
+
// Feed the debounced filter pipeline from the search term signal, so the list re-filters
|
|
188
|
+
// both on user typing and on an external set (a consumer resetting searchTerm to '').
|
|
189
|
+
effect(() => this.searchTermSubject.next(this.searchTerm() ?? ''));
|
|
176
190
|
// Initialize filtered items when items change
|
|
177
191
|
effect(() => {
|
|
178
192
|
const items = this.internalItems();
|
|
179
|
-
if (!this.searchTerm) {
|
|
193
|
+
if (!this.searchTerm()) {
|
|
180
194
|
this.filteredItems.set(items);
|
|
181
195
|
}
|
|
182
196
|
});
|
|
@@ -250,10 +264,11 @@ class SelectionDropdownComponent {
|
|
|
250
264
|
this.headerButtonClick.emit();
|
|
251
265
|
}
|
|
252
266
|
}
|
|
253
|
-
/** Handles search input changes
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
this.
|
|
267
|
+
/** Handles search input changes from the rendered field. Filtering is driven by the
|
|
268
|
+
* `searchTerm` effect, so this only updates the term and notifies listeners. */
|
|
269
|
+
onSearchTermChange(term) {
|
|
270
|
+
this.searchTerm.set(term ?? '');
|
|
271
|
+
this.searchInputChange.emit(term ?? '');
|
|
257
272
|
}
|
|
258
273
|
/** Handles group toggle events, selecting/deselecting all items within the group */
|
|
259
274
|
onGroupToggle(groupLabel, checked) {
|
|
@@ -279,7 +294,7 @@ class SelectionDropdownComponent {
|
|
|
279
294
|
this.filteredItems.set(filtered);
|
|
280
295
|
}
|
|
281
296
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: SelectionDropdownComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
282
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.18", type: SelectionDropdownComponent, isStandalone: true, selector: "ap-selection-dropdown", inputs: { headerButtonId: { classPropertyName: "headerButtonId", publicName: "headerButtonId", isSignal: true, isRequired: false, transformFunction: null }, footerButtonId: { classPropertyName: "footerButtonId", publicName: "footerButtonId", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, footerButtonText: { classPropertyName: "footerButtonText", publicName: "footerButtonText", isSignal: true, isRequired: false, transformFunction: null }, footerButtonSymbolId: { classPropertyName: "footerButtonSymbolId", publicName: "footerButtonSymbolId", isSignal: true, isRequired: false, transformFunction: null }, headerButtonText: { classPropertyName: "headerButtonText", publicName: "headerButtonText", isSignal: true, isRequired: false, transformFunction: null }, headerButtonSymbolId: { classPropertyName: "headerButtonSymbolId", publicName: "headerButtonSymbolId", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholderText: { classPropertyName: "searchPlaceholderText", publicName: "searchPlaceholderText", isSignal: true, isRequired: false, transformFunction: null }, noSearchResultsText: { classPropertyName: "noSearchResultsText", publicName: "noSearchResultsText", isSignal: true, isRequired: false, transformFunction: null }, showBackdrop: { classPropertyName: "showBackdrop", publicName: "showBackdrop", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, defaultPosition: { classPropertyName: "defaultPosition", publicName: "defaultPosition", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { opened: "opened", closed: "closed", selectionChange: "selectionChange", footerButtonClick: "footerButtonClick", headerButtonClick: "headerButtonClick", searchInputChange: "searchInputChange" }, queries: [{ propertyName: "trigger", first: true, predicate: ["trigger"], descendants: true, isSignal: true }], viewQueries: [{ propertyName: "selectionDropdownTemplate", first: true, predicate: ["selectionDropdownTemplate"], descendants: true, isSignal: true }, { propertyName: "inputSearchComponent", first: true, predicate: ["inputSearchElement"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #selectionDropdownTemplate>\n <div class=\"ap-selection-dropdown__content\">\n <!-- Header -->\n <div class=\"ap-selection-dropdown__header\">\n <div class=\"ap-selection-dropdown__header-top\">\n @if (title()) {\n <h3 class=\"ap-selection-dropdown__title\">\n {{ title() }}\n </h3>\n }\n @if (headerButtonText()) {\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"headerButtonId()\"\n (click)=\"onHeaderButtonClick()\"\n (keydown)=\"onHeaderButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"headerButtonSymbolId()\" />\n {{ headerButtonText() }}\n </a>\n }\n </div>\n <ap-input-search\n #inputSearchElement\n [placeholder]=\"searchPlaceholderText()\"\n [clearable]=\"true\"\n [(ngModel)]=\"searchTerm\"\n (ngModelChange)=\"onSearchTermChange()\" />\n </div>\n\n <!-- Selection dropdown items -->\n <div class=\"ap-selection-dropdown__items\">\n @if (filteredItems().length === 0 && searchTerm) {\n <div class=\"ap-selection-dropdown__no-results\">\n {{ noSearchResultsText() }}\n </div>\n } @else {\n <!-- Selected items section (at the top) -->\n @if (selectedItems().length > 0) {\n <div class=\"ap-selection-dropdown__selected-section\">\n @for (item of selectedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n\n <!-- Ungrouped unselected items -->\n @for (item of ungroupedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n\n <!-- Groups -->\n @for (groupLabel of groupLabels(); track groupLabel) {\n <div class=\"ap-selection-dropdown__group\">\n <!-- Group header with checkbox -->\n <div class=\"ap-selection-dropdown__group-header\">\n <div class=\"ap-selection-dropdown__group-label\">\n <ap-checkbox\n [name]=\"groupLabel\"\n [checked]=\"groupSelectionStates()[groupLabel] === 'selected'\"\n [indeterminate]=\"groupSelectionStates()[groupLabel] === 'partial'\"\n (change)=\"onGroupToggle(groupLabel, $event)\">\n {{ groupLabel }}\n </ap-checkbox>\n </div>\n </div>\n\n <!-- Group items -->\n @for (item of groupItemsMap()[groupLabel]; track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item ap-selection-dropdown__item--grouped\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n @if (footerButtonText()) {\n <div class=\"ap-selection-dropdown__footer\">\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"footerButtonId()\"\n (click)=\"onFooterButtonClick()\"\n (keydown)=\"onFooterButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"footerButtonSymbolId()\" />\n {{ footerButtonText() }}\n </a>\n </div>\n }\n </div>\n</ng-template>\n", styles: [":host{display:none}.ap-selection-dropdown__content{background-color:var(--ref-color-white);border-radius:var(--sys-border-radius-sm);box-shadow:0 4px 25px -2px #34456326,0 4px 6px -2px #34456326;overflow:hidden;z-index:1000;width:370px;display:flex;flex-direction:column;max-height:400px}.ap-selection-dropdown__item-button{display:block;width:100%;padding:0;margin:0;border:none;background:transparent;text-align:left;cursor:pointer;outline:none}.ap-selection-dropdown__item-button:hover{background-color:var(--ref-color-electric-blue-10)}.ap-selection-dropdown__item-button:active{background-color:var(--ref-color-electric-blue-20)}.ap-selection-dropdown__item-button:focus{outline:none}.ap-selection-dropdown__item-button:focus-visible{outline:none}.ap-selection-dropdown__item-button.ap-selection-dropdown__item-button--disabled{pointer-events:none}.ap-selection-dropdown__item{display:flex;align-items:center;width:100%;min-height:40px;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);background:transparent;cursor:pointer;font-family:Averta}.ap-selection-dropdown__group-header{display:flex;align-items:center;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);background:var(--ref-color-grey-bg)}.ap-selection-dropdown__group-label{display:flex;align-items:center;flex:1;font-weight:700;color:var(--ref-color-grey-100)}.ap-selection-dropdown__group-label ap-checkbox{--comp-forms-label-font-weight: 700}.ap-selection-dropdown__header{border-bottom:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;flex-direction:column}.ap-selection-dropdown__header .ap-selection-dropdown__header-top{display:flex;align-items:center;justify-content:space-between;padding:var(--ref-spacing-xs) var(--ref-spacing-sm)}.ap-selection-dropdown__header .ap-selection-dropdown__title{margin:0;font-size:var(--ref-font-size-md);font-weight:var(--ref-font-weight-bold);color:var(--ref-color-grey-100);flex:1}.ap-selection-dropdown__header ap-input-search{width:100%;padding:0 var(--ref-spacing-xxs) var(--ref-spacing-xxs)}.ap-selection-dropdown__items{padding:var(--ref-spacing-xxs) 0;flex:1;overflow-y:auto;min-height:0}.ap-selection-dropdown__no-results{padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);color:var(--ref-color-grey-80);font-size:var(--ref-font-size-sm);font-style:italic}.ap-selection-dropdown__footer{height:40px;padding:var(--ref-spacing-xs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;align-items:center;justify-content:flex-start}.ap-selection-dropdown__selected-section{margin-bottom:var(--ref-spacing-xxs);border-bottom:1px solid var(--ref-color-grey-10);padding-bottom:var(--ref-spacing-xxs)}.ap-selection-dropdown__selected-section ::ng-deep ap-checkbox{--comp-forms-label-font-weight: 700}\n"], dependencies: [{ kind: "component", type: CheckboxComponent, selector: "ap-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "disabled", "indeterminate", "checked", "required", "name"], outputs: ["change"] }, { kind: "component", type: DropdownItemMultipleOneLineComponent, selector: "ap-dropdown-item-multiple-one-line", inputs: ["text", "selected", "htmlId", "disabled", "avatarUrl", "symbolId", "disabledTooltip", "badgeText", "dividerEnabled", "onlyEnabled", "onlyText", "isFeatureLocked", "roundedAvatar", "network", "symbolColor", "symbolTooltipText"], outputs: ["selectOnly", "selectionChange", "lockedFeatureClicked"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: InputSearchComponent, selector: "ap-input-search", inputs: ["id", "placeholder", "clearable"], outputs: ["focus", "blur", "keyup"] }, { kind: "component", type: SymbolComponent, selector: "ap-symbol", inputs: ["symbolId", "color", "size"], outputs: ["sizeChange"] }, { kind: "directive", type: TooltipDirective, selector: "[apTooltip]", inputs: ["apTooltip", "apTooltipPosition", "apTooltipShowDelay", "apTooltipHideDelay", "apTooltipDuration", "apTooltipDisabled", "apTooltipTruncatedTextOnly", "apTooltipTemplateContext", "apTooltipVirtualScrollElement", "apTooltipTrigger", "apTooltipType", "apTooltipPresentationContext", "apTooltipListItems", "apTooltipShowAvatarCaption"], exportAs: ["apTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
297
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.18", type: SelectionDropdownComponent, isStandalone: true, selector: "ap-selection-dropdown", inputs: { headerButtonId: { classPropertyName: "headerButtonId", publicName: "headerButtonId", isSignal: true, isRequired: false, transformFunction: null }, footerButtonId: { classPropertyName: "footerButtonId", publicName: "footerButtonId", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, footerButtonText: { classPropertyName: "footerButtonText", publicName: "footerButtonText", isSignal: true, isRequired: false, transformFunction: null }, footerButtonSymbolId: { classPropertyName: "footerButtonSymbolId", publicName: "footerButtonSymbolId", isSignal: true, isRequired: false, transformFunction: null }, headerButtonText: { classPropertyName: "headerButtonText", publicName: "headerButtonText", isSignal: true, isRequired: false, transformFunction: null }, headerButtonSymbolId: { classPropertyName: "headerButtonSymbolId", publicName: "headerButtonSymbolId", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholderText: { classPropertyName: "searchPlaceholderText", publicName: "searchPlaceholderText", isSignal: true, isRequired: false, transformFunction: null }, noSearchResultsText: { classPropertyName: "noSearchResultsText", publicName: "noSearchResultsText", isSignal: true, isRequired: false, transformFunction: null }, showBackdrop: { classPropertyName: "showBackdrop", publicName: "showBackdrop", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, defaultPosition: { classPropertyName: "defaultPosition", publicName: "defaultPosition", isSignal: true, isRequired: false, transformFunction: null }, searchTerm: { classPropertyName: "searchTerm", publicName: "searchTerm", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { opened: "opened", closed: "closed", selectionChange: "selectionChange", footerButtonClick: "footerButtonClick", headerButtonClick: "headerButtonClick", searchInputChange: "searchInputChange", searchTerm: "searchTermChange" }, queries: [{ propertyName: "trigger", first: true, predicate: ["trigger"], descendants: true, isSignal: true }], viewQueries: [{ propertyName: "selectionDropdownTemplate", first: true, predicate: ["selectionDropdownTemplate"], descendants: true, isSignal: true }, { propertyName: "inputSearchComponent", first: true, predicate: ["inputSearchElement"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #selectionDropdownTemplate>\n <div class=\"ap-selection-dropdown__content\">\n <!-- Header -->\n <div class=\"ap-selection-dropdown__header\">\n <div class=\"ap-selection-dropdown__header-top\">\n @if (title()) {\n <h3 class=\"ap-selection-dropdown__title\">\n {{ title() }}\n </h3>\n }\n @if (headerButtonText()) {\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"headerButtonId()\"\n (click)=\"onHeaderButtonClick()\"\n (keydown)=\"onHeaderButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"headerButtonSymbolId()\" />\n {{ headerButtonText() }}\n </a>\n }\n </div>\n <ap-input-search\n #inputSearchElement\n [placeholder]=\"searchPlaceholderText()\"\n [clearable]=\"true\"\n [ngModel]=\"searchTerm()\"\n (ngModelChange)=\"onSearchTermChange($event)\" />\n </div>\n\n <!-- Selection dropdown items -->\n <div class=\"ap-selection-dropdown__items\">\n @if (filteredItems().length === 0 && searchTerm()) {\n <div class=\"ap-selection-dropdown__no-results\">\n {{ noSearchResultsText() }}\n </div>\n } @else {\n <!-- Selected items section (at the top) -->\n @if (selectedItems().length > 0) {\n <div class=\"ap-selection-dropdown__selected-section\">\n @for (item of selectedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n\n <!-- Ungrouped unselected items -->\n @for (item of ungroupedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n\n <!-- Groups -->\n @for (groupLabel of groupLabels(); track groupLabel) {\n <div class=\"ap-selection-dropdown__group\">\n <!-- Group header with checkbox -->\n <div class=\"ap-selection-dropdown__group-header\">\n <div class=\"ap-selection-dropdown__group-label\">\n <ap-checkbox\n [name]=\"groupLabel\"\n [checked]=\"groupSelectionStates()[groupLabel] === 'selected'\"\n [indeterminate]=\"groupSelectionStates()[groupLabel] === 'partial'\"\n (change)=\"onGroupToggle(groupLabel, $event)\">\n {{ groupLabel }}\n </ap-checkbox>\n </div>\n </div>\n\n <!-- Group items -->\n @for (item of groupItemsMap()[groupLabel]; track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item ap-selection-dropdown__item--grouped\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n @if (footerButtonText()) {\n <div class=\"ap-selection-dropdown__footer\">\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"footerButtonId()\"\n (click)=\"onFooterButtonClick()\"\n (keydown)=\"onFooterButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"footerButtonSymbolId()\" />\n {{ footerButtonText() }}\n </a>\n </div>\n }\n </div>\n</ng-template>\n", styles: [":host{display:none}.ap-selection-dropdown__content{background-color:var(--ref-color-white);border-radius:var(--sys-border-radius-sm);box-shadow:0 4px 25px -2px #34456326,0 4px 6px -2px #34456326;overflow:hidden;z-index:1000;width:370px;display:flex;flex-direction:column;max-height:400px}.ap-selection-dropdown__item-button{display:block;width:100%;padding:0;margin:0;border:none;background:transparent;text-align:left;cursor:pointer;outline:none}.ap-selection-dropdown__item-button:hover{background-color:var(--ref-color-electric-blue-10)}.ap-selection-dropdown__item-button:active{background-color:var(--ref-color-electric-blue-20)}.ap-selection-dropdown__item-button:focus{outline:none}.ap-selection-dropdown__item-button:focus-visible{outline:none}.ap-selection-dropdown__item-button.ap-selection-dropdown__item-button--disabled{pointer-events:none}.ap-selection-dropdown__item{display:flex;align-items:center;width:100%;min-height:40px;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);background:transparent;cursor:pointer;font-family:Averta}.ap-selection-dropdown__group-header{display:flex;align-items:center;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);background:var(--ref-color-grey-bg)}.ap-selection-dropdown__group-label{display:flex;align-items:center;flex:1;font-weight:700;color:var(--ref-color-grey-100)}.ap-selection-dropdown__group-label ap-checkbox{--comp-forms-label-font-weight: 700}.ap-selection-dropdown__header{border-bottom:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;flex-direction:column}.ap-selection-dropdown__header .ap-selection-dropdown__header-top{display:flex;align-items:center;justify-content:space-between;padding:var(--ref-spacing-xs) var(--ref-spacing-sm)}.ap-selection-dropdown__header .ap-selection-dropdown__title{margin:0;font-size:var(--ref-font-size-md);font-weight:var(--ref-font-weight-bold);color:var(--ref-color-grey-100);flex:1}.ap-selection-dropdown__header ap-input-search{width:100%;padding:0 var(--ref-spacing-xxs) var(--ref-spacing-xxs)}.ap-selection-dropdown__items{padding:var(--ref-spacing-xxs) 0;flex:1;overflow-y:auto;min-height:0}.ap-selection-dropdown__no-results{padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);color:var(--ref-color-grey-80);font-size:var(--ref-font-size-sm);font-style:italic}.ap-selection-dropdown__footer{height:40px;padding:var(--ref-spacing-xs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;align-items:center;justify-content:flex-start}.ap-selection-dropdown__selected-section{margin-bottom:var(--ref-spacing-xxs);border-bottom:1px solid var(--ref-color-grey-10);padding-bottom:var(--ref-spacing-xxs)}.ap-selection-dropdown__selected-section ::ng-deep ap-checkbox{--comp-forms-label-font-weight: 700}\n"], dependencies: [{ kind: "component", type: CheckboxComponent, selector: "ap-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "disabled", "indeterminate", "checked", "required", "name"], outputs: ["change"] }, { kind: "component", type: DropdownItemMultipleOneLineComponent, selector: "ap-dropdown-item-multiple-one-line", inputs: ["text", "selected", "htmlId", "disabled", "avatarUrl", "symbolId", "disabledTooltip", "badgeText", "dividerEnabled", "onlyEnabled", "onlyText", "isFeatureLocked", "roundedAvatar", "network", "symbolColor", "symbolTooltipText"], outputs: ["selectOnly", "selectionChange", "lockedFeatureClicked"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: InputSearchComponent, selector: "ap-input-search", inputs: ["id", "placeholder", "clearable"], outputs: ["focus", "blur", "keyup"] }, { kind: "component", type: SymbolComponent, selector: "ap-symbol", inputs: ["symbolId", "color", "size"], outputs: ["sizeChange"] }, { kind: "directive", type: TooltipDirective, selector: "[apTooltip]", inputs: ["apTooltip", "apTooltipPosition", "apTooltipShowDelay", "apTooltipHideDelay", "apTooltipDuration", "apTooltipDisabled", "apTooltipTruncatedTextOnly", "apTooltipTemplateContext", "apTooltipVirtualScrollElement", "apTooltipTrigger", "apTooltipType", "apTooltipPresentationContext", "apTooltipListItems", "apTooltipShowAvatarCaption"], exportAs: ["apTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
283
298
|
}
|
|
284
299
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: SelectionDropdownComponent, decorators: [{
|
|
285
300
|
type: Component,
|
|
@@ -290,8 +305,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImpo
|
|
|
290
305
|
InputSearchComponent,
|
|
291
306
|
SymbolComponent,
|
|
292
307
|
TooltipDirective,
|
|
293
|
-
], template: "<ng-template #selectionDropdownTemplate>\n <div class=\"ap-selection-dropdown__content\">\n <!-- Header -->\n <div class=\"ap-selection-dropdown__header\">\n <div class=\"ap-selection-dropdown__header-top\">\n @if (title()) {\n <h3 class=\"ap-selection-dropdown__title\">\n {{ title() }}\n </h3>\n }\n @if (headerButtonText()) {\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"headerButtonId()\"\n (click)=\"onHeaderButtonClick()\"\n (keydown)=\"onHeaderButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"headerButtonSymbolId()\" />\n {{ headerButtonText() }}\n </a>\n }\n </div>\n <ap-input-search\n #inputSearchElement\n [placeholder]=\"searchPlaceholderText()\"\n [clearable]=\"true\"\n [(ngModel)]=\"searchTerm\"\n (ngModelChange)=\"onSearchTermChange()\" />\n </div>\n\n <!-- Selection dropdown items -->\n <div class=\"ap-selection-dropdown__items\">\n @if (filteredItems().length === 0 && searchTerm) {\n <div class=\"ap-selection-dropdown__no-results\">\n {{ noSearchResultsText() }}\n </div>\n } @else {\n <!-- Selected items section (at the top) -->\n @if (selectedItems().length > 0) {\n <div class=\"ap-selection-dropdown__selected-section\">\n @for (item of selectedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n\n <!-- Ungrouped unselected items -->\n @for (item of ungroupedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n\n <!-- Groups -->\n @for (groupLabel of groupLabels(); track groupLabel) {\n <div class=\"ap-selection-dropdown__group\">\n <!-- Group header with checkbox -->\n <div class=\"ap-selection-dropdown__group-header\">\n <div class=\"ap-selection-dropdown__group-label\">\n <ap-checkbox\n [name]=\"groupLabel\"\n [checked]=\"groupSelectionStates()[groupLabel] === 'selected'\"\n [indeterminate]=\"groupSelectionStates()[groupLabel] === 'partial'\"\n (change)=\"onGroupToggle(groupLabel, $event)\">\n {{ groupLabel }}\n </ap-checkbox>\n </div>\n </div>\n\n <!-- Group items -->\n @for (item of groupItemsMap()[groupLabel]; track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item ap-selection-dropdown__item--grouped\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n @if (footerButtonText()) {\n <div class=\"ap-selection-dropdown__footer\">\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"footerButtonId()\"\n (click)=\"onFooterButtonClick()\"\n (keydown)=\"onFooterButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"footerButtonSymbolId()\" />\n {{ footerButtonText() }}\n </a>\n </div>\n }\n </div>\n</ng-template>\n", styles: [":host{display:none}.ap-selection-dropdown__content{background-color:var(--ref-color-white);border-radius:var(--sys-border-radius-sm);box-shadow:0 4px 25px -2px #34456326,0 4px 6px -2px #34456326;overflow:hidden;z-index:1000;width:370px;display:flex;flex-direction:column;max-height:400px}.ap-selection-dropdown__item-button{display:block;width:100%;padding:0;margin:0;border:none;background:transparent;text-align:left;cursor:pointer;outline:none}.ap-selection-dropdown__item-button:hover{background-color:var(--ref-color-electric-blue-10)}.ap-selection-dropdown__item-button:active{background-color:var(--ref-color-electric-blue-20)}.ap-selection-dropdown__item-button:focus{outline:none}.ap-selection-dropdown__item-button:focus-visible{outline:none}.ap-selection-dropdown__item-button.ap-selection-dropdown__item-button--disabled{pointer-events:none}.ap-selection-dropdown__item{display:flex;align-items:center;width:100%;min-height:40px;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);background:transparent;cursor:pointer;font-family:Averta}.ap-selection-dropdown__group-header{display:flex;align-items:center;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);background:var(--ref-color-grey-bg)}.ap-selection-dropdown__group-label{display:flex;align-items:center;flex:1;font-weight:700;color:var(--ref-color-grey-100)}.ap-selection-dropdown__group-label ap-checkbox{--comp-forms-label-font-weight: 700}.ap-selection-dropdown__header{border-bottom:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;flex-direction:column}.ap-selection-dropdown__header .ap-selection-dropdown__header-top{display:flex;align-items:center;justify-content:space-between;padding:var(--ref-spacing-xs) var(--ref-spacing-sm)}.ap-selection-dropdown__header .ap-selection-dropdown__title{margin:0;font-size:var(--ref-font-size-md);font-weight:var(--ref-font-weight-bold);color:var(--ref-color-grey-100);flex:1}.ap-selection-dropdown__header ap-input-search{width:100%;padding:0 var(--ref-spacing-xxs) var(--ref-spacing-xxs)}.ap-selection-dropdown__items{padding:var(--ref-spacing-xxs) 0;flex:1;overflow-y:auto;min-height:0}.ap-selection-dropdown__no-results{padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);color:var(--ref-color-grey-80);font-size:var(--ref-font-size-sm);font-style:italic}.ap-selection-dropdown__footer{height:40px;padding:var(--ref-spacing-xs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;align-items:center;justify-content:flex-start}.ap-selection-dropdown__selected-section{margin-bottom:var(--ref-spacing-xxs);border-bottom:1px solid var(--ref-color-grey-10);padding-bottom:var(--ref-spacing-xxs)}.ap-selection-dropdown__selected-section ::ng-deep ap-checkbox{--comp-forms-label-font-weight: 700}\n"] }]
|
|
294
|
-
}], ctorParameters: () => [], propDecorators: { selectionDropdownTemplate: [{ type: i0.ViewChild, args: ['selectionDropdownTemplate', { isSignal: true }] }], trigger: [{ type: i0.ContentChild, args: ['trigger', { isSignal: true }] }], headerButtonId: [{ type: i0.Input, args: [{ isSignal: true, alias: "headerButtonId", required: false }] }], footerButtonId: [{ type: i0.Input, args: [{ isSignal: true, alias: "footerButtonId", required: false }] }], items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], footerButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "footerButtonText", required: false }] }], footerButtonSymbolId: [{ type: i0.Input, args: [{ isSignal: true, alias: "footerButtonSymbolId", required: false }] }], headerButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "headerButtonText", required: false }] }], headerButtonSymbolId: [{ type: i0.Input, args: [{ isSignal: true, alias: "headerButtonSymbolId", required: false }] }], searchPlaceholderText: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholderText", required: false }] }], noSearchResultsText: [{ type: i0.Input, args: [{ isSignal: true, alias: "noSearchResultsText", required: false }] }], showBackdrop: [{ type: i0.Input, args: [{ isSignal: true, alias: "showBackdrop", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], defaultPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultPosition", required: false }] }], opened: [{ type: i0.Output, args: ["opened"] }], closed: [{ type: i0.Output, args: ["closed"] }], selectionChange: [{ type: i0.Output, args: ["selectionChange"] }], footerButtonClick: [{ type: i0.Output, args: ["footerButtonClick"] }], headerButtonClick: [{ type: i0.Output, args: ["headerButtonClick"] }], searchInputChange: [{ type: i0.Output, args: ["searchInputChange"] }], inputSearchComponent: [{ type: i0.ViewChild, args: ['inputSearchElement', { isSignal: true }] }] } });
|
|
308
|
+
], template: "<ng-template #selectionDropdownTemplate>\n <div class=\"ap-selection-dropdown__content\">\n <!-- Header -->\n <div class=\"ap-selection-dropdown__header\">\n <div class=\"ap-selection-dropdown__header-top\">\n @if (title()) {\n <h3 class=\"ap-selection-dropdown__title\">\n {{ title() }}\n </h3>\n }\n @if (headerButtonText()) {\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"headerButtonId()\"\n (click)=\"onHeaderButtonClick()\"\n (keydown)=\"onHeaderButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"headerButtonSymbolId()\" />\n {{ headerButtonText() }}\n </a>\n }\n </div>\n <ap-input-search\n #inputSearchElement\n [placeholder]=\"searchPlaceholderText()\"\n [clearable]=\"true\"\n [ngModel]=\"searchTerm()\"\n (ngModelChange)=\"onSearchTermChange($event)\" />\n </div>\n\n <!-- Selection dropdown items -->\n <div class=\"ap-selection-dropdown__items\">\n @if (filteredItems().length === 0 && searchTerm()) {\n <div class=\"ap-selection-dropdown__no-results\">\n {{ noSearchResultsText() }}\n </div>\n } @else {\n <!-- Selected items section (at the top) -->\n @if (selectedItems().length > 0) {\n <div class=\"ap-selection-dropdown__selected-section\">\n @for (item of selectedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n\n <!-- Ungrouped unselected items -->\n @for (item of ungroupedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n\n <!-- Groups -->\n @for (groupLabel of groupLabels(); track groupLabel) {\n <div class=\"ap-selection-dropdown__group\">\n <!-- Group header with checkbox -->\n <div class=\"ap-selection-dropdown__group-header\">\n <div class=\"ap-selection-dropdown__group-label\">\n <ap-checkbox\n [name]=\"groupLabel\"\n [checked]=\"groupSelectionStates()[groupLabel] === 'selected'\"\n [indeterminate]=\"groupSelectionStates()[groupLabel] === 'partial'\"\n (change)=\"onGroupToggle(groupLabel, $event)\">\n {{ groupLabel }}\n </ap-checkbox>\n </div>\n </div>\n\n <!-- Group items -->\n @for (item of groupItemsMap()[groupLabel]; track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item ap-selection-dropdown__item--grouped\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n @if (footerButtonText()) {\n <div class=\"ap-selection-dropdown__footer\">\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"footerButtonId()\"\n (click)=\"onFooterButtonClick()\"\n (keydown)=\"onFooterButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"footerButtonSymbolId()\" />\n {{ footerButtonText() }}\n </a>\n </div>\n }\n </div>\n</ng-template>\n", styles: [":host{display:none}.ap-selection-dropdown__content{background-color:var(--ref-color-white);border-radius:var(--sys-border-radius-sm);box-shadow:0 4px 25px -2px #34456326,0 4px 6px -2px #34456326;overflow:hidden;z-index:1000;width:370px;display:flex;flex-direction:column;max-height:400px}.ap-selection-dropdown__item-button{display:block;width:100%;padding:0;margin:0;border:none;background:transparent;text-align:left;cursor:pointer;outline:none}.ap-selection-dropdown__item-button:hover{background-color:var(--ref-color-electric-blue-10)}.ap-selection-dropdown__item-button:active{background-color:var(--ref-color-electric-blue-20)}.ap-selection-dropdown__item-button:focus{outline:none}.ap-selection-dropdown__item-button:focus-visible{outline:none}.ap-selection-dropdown__item-button.ap-selection-dropdown__item-button--disabled{pointer-events:none}.ap-selection-dropdown__item{display:flex;align-items:center;width:100%;min-height:40px;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);background:transparent;cursor:pointer;font-family:Averta}.ap-selection-dropdown__group-header{display:flex;align-items:center;padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);background:var(--ref-color-grey-bg)}.ap-selection-dropdown__group-label{display:flex;align-items:center;flex:1;font-weight:700;color:var(--ref-color-grey-100)}.ap-selection-dropdown__group-label ap-checkbox{--comp-forms-label-font-weight: 700}.ap-selection-dropdown__header{border-bottom:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;flex-direction:column}.ap-selection-dropdown__header .ap-selection-dropdown__header-top{display:flex;align-items:center;justify-content:space-between;padding:var(--ref-spacing-xs) var(--ref-spacing-sm)}.ap-selection-dropdown__header .ap-selection-dropdown__title{margin:0;font-size:var(--ref-font-size-md);font-weight:var(--ref-font-weight-bold);color:var(--ref-color-grey-100);flex:1}.ap-selection-dropdown__header ap-input-search{width:100%;padding:0 var(--ref-spacing-xxs) var(--ref-spacing-xxs)}.ap-selection-dropdown__items{padding:var(--ref-spacing-xxs) 0;flex:1;overflow-y:auto;min-height:0}.ap-selection-dropdown__no-results{padding:var(--ref-spacing-xxs) var(--ref-spacing-sm);color:var(--ref-color-grey-80);font-size:var(--ref-font-size-sm);font-style:italic}.ap-selection-dropdown__footer{height:40px;padding:var(--ref-spacing-xs) var(--ref-spacing-sm);border-top:1px solid var(--ref-color-grey-10);flex-shrink:0;display:flex;align-items:center;justify-content:flex-start}.ap-selection-dropdown__selected-section{margin-bottom:var(--ref-spacing-xxs);border-bottom:1px solid var(--ref-color-grey-10);padding-bottom:var(--ref-spacing-xxs)}.ap-selection-dropdown__selected-section ::ng-deep ap-checkbox{--comp-forms-label-font-weight: 700}\n"] }]
|
|
309
|
+
}], ctorParameters: () => [], propDecorators: { selectionDropdownTemplate: [{ type: i0.ViewChild, args: ['selectionDropdownTemplate', { isSignal: true }] }], trigger: [{ type: i0.ContentChild, args: ['trigger', { isSignal: true }] }], headerButtonId: [{ type: i0.Input, args: [{ isSignal: true, alias: "headerButtonId", required: false }] }], footerButtonId: [{ type: i0.Input, args: [{ isSignal: true, alias: "footerButtonId", required: false }] }], items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], footerButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "footerButtonText", required: false }] }], footerButtonSymbolId: [{ type: i0.Input, args: [{ isSignal: true, alias: "footerButtonSymbolId", required: false }] }], headerButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "headerButtonText", required: false }] }], headerButtonSymbolId: [{ type: i0.Input, args: [{ isSignal: true, alias: "headerButtonSymbolId", required: false }] }], searchPlaceholderText: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholderText", required: false }] }], noSearchResultsText: [{ type: i0.Input, args: [{ isSignal: true, alias: "noSearchResultsText", required: false }] }], showBackdrop: [{ type: i0.Input, args: [{ isSignal: true, alias: "showBackdrop", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], defaultPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultPosition", required: false }] }], opened: [{ type: i0.Output, args: ["opened"] }], closed: [{ type: i0.Output, args: ["closed"] }], selectionChange: [{ type: i0.Output, args: ["selectionChange"] }], footerButtonClick: [{ type: i0.Output, args: ["footerButtonClick"] }], headerButtonClick: [{ type: i0.Output, args: ["headerButtonClick"] }], searchInputChange: [{ type: i0.Output, args: ["searchInputChange"] }], searchTerm: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchTerm", required: false }] }, { type: i0.Output, args: ["searchTermChange"] }], inputSearchComponent: [{ type: i0.ViewChild, args: ['inputSearchElement', { isSignal: true }] }] } });
|
|
295
310
|
|
|
296
311
|
/**
|
|
297
312
|
* Generated bundle index. Do not edit.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agorapulse-ui-components-selection-dropdown.mjs","sources":["../../../libs/ui-components/selection-dropdown/src/selection-dropdown-trigger.directive.ts","../../../libs/ui-components/selection-dropdown/src/selection-dropdown.component.ts","../../../libs/ui-components/selection-dropdown/src/selection-dropdown.component.html","../../../libs/ui-components/selection-dropdown/src/agorapulse-ui-components-selection-dropdown.ts"],"sourcesContent":["import { Directive, ElementRef, HostListener, inject, input } from '@angular/core';\nimport { SelectionDropdownComponent } from './selection-dropdown.component';\n\n/**\n * Directive that turns any element into a trigger for a SelectionDropdown component.\n * Handles click and keyboard interactions to open/close the dropdown.\n */\n@Directive({\n selector: '[apSelectionDropdownTrigger]',\n})\nexport class SelectionDropdownTriggerDirective {\n private readonly elementRef = inject(ElementRef<HTMLElement>);\n\n /** Reference to the SelectionDropdown component that this trigger controls */\n apSelectionDropdownTrigger = input.required<SelectionDropdownComponent>();\n\n /** Handles click events to toggle the dropdown */\n @HostListener('click', ['$event'])\n onClick(event: MouseEvent): void {\n event.preventDefault();\n event.stopPropagation();\n\n this.apSelectionDropdownTrigger().toggle(this.elementRef.nativeElement);\n }\n\n /** Handles keyboard events for accessibility (Enter, Space, Arrow Down, Escape) */\n @HostListener('keydown', ['$event'])\n onKeyDown(event: KeyboardEvent): void {\n const dropdown = this.apSelectionDropdownTrigger();\n\n switch (event.key) {\n case 'Enter':\n case ' ':\n case 'ArrowDown':\n event.preventDefault();\n dropdown.open(this.elementRef.nativeElement);\n break;\n\n case 'Escape':\n event.preventDefault();\n dropdown.close();\n break;\n }\n }\n}\n","import { CheckboxComponent } from '@agorapulse/ui-components/checkbox';\nimport { createDropdownOverlay, DropdownOverlay } from '@agorapulse/ui-components/dropdown-base';\nimport { InputSearchComponent } from '@agorapulse/ui-components/input-search';\nimport { UI_COMPONENTS_SYMBOLS } from '@agorapulse/ui-components/providers';\nimport { DropdownItemMultipleOneLineComponent } from '@agorapulse/ui-components/select';\nimport { TooltipDirective } from '@agorapulse/ui-components/tooltip';\nimport { SymbolComponent, SymbolRegistry } from '@agorapulse/ui-symbol';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChild,\n effect,\n inject,\n input,\n linkedSignal,\n OnDestroy,\n output,\n signal,\n TemplateRef, untracked,\n viewChild,\n} from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { debounceTime, distinctUntilChanged, Subject, takeUntil } from 'rxjs';\n\nexport interface SelectionDropdownItem {\n /** Unique HTML ID for the item */\n htmlId: string;\n /** Display text for the item */\n text: string;\n /** Whether the item is selected */\n selected: boolean;\n /** Whether the item is disabled and non-interactive */\n disabled?: boolean;\n /** Avatar URL to display */\n avatarUrl?: string;\n /** Symbol ID to display */\n symbolId?: string;\n /** Tooltip text displayed when item is disabled */\n disabledTooltip?: string;\n /** Text displayed in a badge next to the item */\n badgeText?: string;\n /** Whether the feature is locked */\n isFeatureLocked?: boolean;\n /** Whether avatar should be rounded */\n roundedAvatar?: boolean;\n /** Avatar network type */\n network?: any;\n /** Symbol color */\n symbolColor?: string;\n /** Symbol tooltip text */\n symbolTooltipText?: string;\n /** Group label - items with the same groupLabel will be grouped together */\n groupLabel?: string;\n}\n\n/**\n * A dropdown component that displays a list of selectable items with checkboxes,\n * badges, tooltips, and keyboard navigation.\n */\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-selection-dropdown',\n templateUrl: './selection-dropdown.component.html',\n styleUrls: ['./selection-dropdown.component.scss'],\n imports: [\n CheckboxComponent,\n DropdownItemMultipleOneLineComponent,\n FormsModule,\n InputSearchComponent,\n SymbolComponent,\n TooltipDirective,\n ],\n})\nexport class SelectionDropdownComponent implements DropdownOverlay, OnDestroy {\n private readonly symbolRegistry = inject(SymbolRegistry);\n private readonly overlay = createDropdownOverlay();\n\n selectionDropdownTemplate = viewChild<TemplateRef<unknown>>('selectionDropdownTemplate');\n trigger = contentChild<TemplateRef<unknown>>('trigger');\n\n /** ID for the header button */\n headerButtonId = input<string>();\n /** ID for the footer button */\n footerButtonId = input<string>();\n /** Array of items to display in the dropdown menu */\n items = input<SelectionDropdownItem[]>([]);\n /** Title to display in the header */\n title = input<string>();\n /** Text for the footer button */\n footerButtonText = input<string>();\n /** Symbol ID for the footer button */\n footerButtonSymbolId = input<string>();\n /** Text for the header button */\n headerButtonText = input<string>();\n /** Symbol ID for the header button */\n headerButtonSymbolId = input<string>();\n /** Placeholder text for the search input */\n searchPlaceholderText = input('Search');\n /** Text to display when no search results are found */\n noSearchResultsText = input('No results found');\n\n /** Whether to show a backdrop that closes the dropdown when clicked */\n showBackdrop = input(true);\n /** Whether the dropdown is disabled and cannot be opened */\n disabled = input(false);\n /** Default position for the dropdown relative to the trigger element */\n defaultPosition = input<'right' | 'left'>('right');\n\n /** Emits when the dropdown menu is opened */\n opened = output<void>();\n /** Emits when the dropdown menu is closed */\n closed = output<void>();\n /** Emits when a dropdown item selection changes */\n selectionChange = output<SelectionDropdownItem[]>();\n /** Emits when the footer button is clicked */\n footerButtonClick = output<void>();\n /** Emits when the header button is clicked */\n headerButtonClick = output<void>();\n /** Emits when the search input is changed */\n searchInputChange = output<string>();\n\n private readonly destroy$ = new Subject<void>();\n private readonly searchTermSubject = new Subject<string>();\n\n protected readonly inputSearchComponent = viewChild<InputSearchComponent>('inputSearchElement');\n\n readonly isOpen = this.overlay.isOpen;\n\n focusInput = effect(() => {\n const inputSearch = this.inputSearchComponent();\n untracked(() => {\n if (this.isOpen() && inputSearch) {\n inputSearch.focusInput();\n }\n })\n })\n\n private readonly internalItems = linkedSignal(() => this.items());\n\n protected searchTerm = '';\n protected readonly filteredItems = signal<SelectionDropdownItem[]>([]);\n protected readonly initiallySelectedItems = signal<SelectionDropdownItem[]>([]);\n\n // Computed properties for template usage\n protected readonly selectedItems = computed(() => {\n const initiallySelectedIds = this.initiallySelectedItems().map(item => item.htmlId);\n return this.filteredItems().filter(item => initiallySelectedIds.includes(item.htmlId));\n });\n\n protected readonly unselectedItems = computed(() => {\n const initiallySelectedIds = this.initiallySelectedItems().map(item => item.htmlId);\n return this.filteredItems().filter(item => !initiallySelectedIds.includes(item.htmlId));\n });\n\n protected readonly groupLabels = computed(() => {\n const groupLabels = this.unselectedItems()\n .map(item => item.groupLabel)\n .filter((label): label is string => !!label);\n return [...new Set(groupLabels)];\n });\n\n protected readonly ungroupedItems = computed(() => {\n return this.unselectedItems().filter(item => !item.groupLabel);\n });\n\n // Computed maps for template optimization\n protected readonly groupSelectionStates = computed(() => {\n const states: Record<string, 'selected' | 'partial' | 'unselected'> = {};\n for (const groupLabel of this.groupLabels()) {\n const groupItems = this.filteredItems().filter(item => item.groupLabel === groupLabel);\n const selectableItems = groupItems.filter(item => !item.disabled && !item.isFeatureLocked);\n\n if (selectableItems.length === 0) {\n states[groupLabel] = 'unselected';\n } else {\n const selectedCount = selectableItems.filter(item => item.selected).length;\n if (selectedCount === 0) states[groupLabel] = 'unselected';\n else if (selectedCount === selectableItems.length) states[groupLabel] = 'selected';\n else states[groupLabel] = 'partial';\n }\n }\n return states;\n });\n\n protected readonly groupItemsMap = computed(() => {\n const map: Record<string, SelectionDropdownItem[]> = {};\n for (const groupLabel of this.groupLabels()) {\n map[groupLabel] = this.unselectedItems().filter(item => item.groupLabel === groupLabel);\n }\n return map;\n });\n\n constructor() {\n this.symbolRegistry.withSymbols(...(inject(UI_COMPONENTS_SYMBOLS, { optional: true })?.flat() ?? []));\n\n // Set up debounced search\n this.searchTermSubject.pipe(debounceTime(100), distinctUntilChanged(), takeUntil(this.destroy$)).subscribe(term => {\n const items = this.internalItems();\n this.updateFilteredItems(term?.toLowerCase() ?? '', items);\n });\n\n // Initialize filtered items when items change\n effect(() => {\n const items = this.internalItems();\n if (!this.searchTerm) {\n this.filteredItems.set(items);\n }\n });\n }\n\n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n }\n\n /** Opens the dropdown menu at the specified trigger element */\n open(triggerElement?: HTMLElement): void {\n const template = this.selectionDropdownTemplate();\n if (this.disabled() || this.isOpen() || !template) return;\n\n this.overlay.open(template, triggerElement, {\n showBackdrop: this.showBackdrop(),\n defaultPosition: this.defaultPosition(),\n onClose: () => this.close(),\n });\n\n // Capture initially selected items as a static snapshot\n const selectedItems = this.internalItems().filter(item => item.selected);\n this.initiallySelectedItems.set(selectedItems);\n\n this.opened.emit();\n }\n\n /** Closes the dropdown menu and cleans up overlay resources */\n close(): void {\n if (!this.isOpen()) return;\n this.initiallySelectedItems.set([]);\n this.overlay.close();\n this.closed.emit();\n }\n\n /** Toggles the dropdown menu open or closed state */\n toggle(triggerElement?: HTMLElement): void {\n if (this.isOpen()) {\n this.close();\n } else {\n this.open(triggerElement);\n }\n }\n\n /** Handles item toggle events, updating selection and emitting changes */\n onItemToggle(item: SelectionDropdownItem, checked: boolean): void {\n if (item.disabled || item.isFeatureLocked) {\n return;\n }\n\n const updatedItems = this.internalItems().map(i => (i.htmlId === item.htmlId ? { ...i, selected: checked } : i));\n this.internalItems.set(updatedItems);\n this.selectionChange.emit(updatedItems);\n\n // Update the state of the filtered item that has been selected\n this.filteredItems.update(items => items.map(filteredItem => filteredItem.htmlId === item.htmlId ? { ...filteredItem, selected: checked } : filteredItem));\n }\n\n /** Handles footer button clicks */\n onFooterButtonClick(): void {\n this.footerButtonClick.emit();\n }\n\n /** Handles footer button keyboard events */\n onFooterButtonKeydown(event: KeyboardEvent): void {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.footerButtonClick.emit();\n }\n }\n\n /** Handles header button clicks */\n onHeaderButtonClick(): void {\n this.headerButtonClick.emit();\n }\n\n /** Handles header button keyboard events */\n onHeaderButtonKeydown(event: KeyboardEvent): void {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.headerButtonClick.emit();\n }\n }\n\n /** Handles search input changes */\n onSearchTermChange(): void {\n this.searchTermSubject.next(this.searchTerm);\n this.searchInputChange.emit(this.searchTerm);\n }\n\n /** Handles group toggle events, selecting/deselecting all items within the group */\n onGroupToggle(groupLabel: string, checked: boolean): void {\n if (typeof checked !== 'boolean') {\n return;\n }\n const updatedItems = this.internalItems().map(item => {\n if (item.groupLabel === groupLabel && !item.disabled && !item.isFeatureLocked) {\n return { ...item, selected: checked };\n }\n return item;\n });\n this.internalItems.set(updatedItems);\n this.selectionChange.emit(updatedItems);\n }\n\n /** Updates the filtered items based on search term */\n private updateFilteredItems(searchTerm: string, items: SelectionDropdownItem[]): void {\n if (!searchTerm) {\n this.filteredItems.set(items);\n return;\n }\n\n const filtered = items.filter(item => item.text.toLowerCase().includes(searchTerm));\n this.filteredItems.set(filtered);\n }\n\n}","<ng-template #selectionDropdownTemplate>\n <div class=\"ap-selection-dropdown__content\">\n <!-- Header -->\n <div class=\"ap-selection-dropdown__header\">\n <div class=\"ap-selection-dropdown__header-top\">\n @if (title()) {\n <h3 class=\"ap-selection-dropdown__title\">\n {{ title() }}\n </h3>\n }\n @if (headerButtonText()) {\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"headerButtonId()\"\n (click)=\"onHeaderButtonClick()\"\n (keydown)=\"onHeaderButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"headerButtonSymbolId()\" />\n {{ headerButtonText() }}\n </a>\n }\n </div>\n <ap-input-search\n #inputSearchElement\n [placeholder]=\"searchPlaceholderText()\"\n [clearable]=\"true\"\n [(ngModel)]=\"searchTerm\"\n (ngModelChange)=\"onSearchTermChange()\" />\n </div>\n\n <!-- Selection dropdown items -->\n <div class=\"ap-selection-dropdown__items\">\n @if (filteredItems().length === 0 && searchTerm) {\n <div class=\"ap-selection-dropdown__no-results\">\n {{ noSearchResultsText() }}\n </div>\n } @else {\n <!-- Selected items section (at the top) -->\n @if (selectedItems().length > 0) {\n <div class=\"ap-selection-dropdown__selected-section\">\n @for (item of selectedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n\n <!-- Ungrouped unselected items -->\n @for (item of ungroupedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n\n <!-- Groups -->\n @for (groupLabel of groupLabels(); track groupLabel) {\n <div class=\"ap-selection-dropdown__group\">\n <!-- Group header with checkbox -->\n <div class=\"ap-selection-dropdown__group-header\">\n <div class=\"ap-selection-dropdown__group-label\">\n <ap-checkbox\n [name]=\"groupLabel\"\n [checked]=\"groupSelectionStates()[groupLabel] === 'selected'\"\n [indeterminate]=\"groupSelectionStates()[groupLabel] === 'partial'\"\n (change)=\"onGroupToggle(groupLabel, $event)\">\n {{ groupLabel }}\n </ap-checkbox>\n </div>\n </div>\n\n <!-- Group items -->\n @for (item of groupItemsMap()[groupLabel]; track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item ap-selection-dropdown__item--grouped\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n @if (footerButtonText()) {\n <div class=\"ap-selection-dropdown__footer\">\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"footerButtonId()\"\n (click)=\"onFooterButtonClick()\"\n (keydown)=\"onFooterButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"footerButtonSymbolId()\" />\n {{ footerButtonText() }}\n </a>\n </div>\n }\n </div>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;AAGA;;;AAGG;MAIU,iCAAiC,CAAA;AACzB,IAAA,UAAU,GAAG,MAAM,EAAC,UAAuB,EAAC;;AAG7D,IAAA,0BAA0B,GAAG,KAAK,CAAC,QAAQ,qEAA8B;;AAIzE,IAAA,OAAO,CAAC,KAAiB,EAAA;QACrB,KAAK,CAAC,cAAc,EAAE;QACtB,KAAK,CAAC,eAAe,EAAE;AAEvB,QAAA,IAAI,CAAC,0BAA0B,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,aAAa,CAAC;IAC3E;;AAIA,IAAA,SAAS,CAAC,KAAoB,EAAA;AAC1B,QAAA,MAAM,QAAQ,GAAG,IAAI,CAAC,0BAA0B,EAAE;AAElD,QAAA,QAAQ,KAAK,CAAC,GAAG;AACb,YAAA,KAAK,OAAO;AACZ,YAAA,KAAK,GAAG;AACR,YAAA,KAAK,WAAW;gBACZ,KAAK,CAAC,cAAc,EAAE;gBACtB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,aAAa,CAAC;gBAC5C;AAEJ,YAAA,KAAK,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AA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,MAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,QAAA,CAAA,EAAA,CAAA,EAAA,MAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,QAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,iBAAA,CAAA,EAAA,CAAA,EAAA,iBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,CAAA,EAAA,iBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,CAAA,EAAA,iBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,CAAA,EAAA,oBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CA8CoB,oBAAoB,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AE7HlG;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"agorapulse-ui-components-selection-dropdown.mjs","sources":["../../../libs/ui-components/selection-dropdown/src/selection-dropdown-trigger.directive.ts","../../../libs/ui-components/selection-dropdown/src/selection-dropdown.component.ts","../../../libs/ui-components/selection-dropdown/src/selection-dropdown.component.html","../../../libs/ui-components/selection-dropdown/src/agorapulse-ui-components-selection-dropdown.ts"],"sourcesContent":["import { Directive, ElementRef, HostListener, inject, input } from '@angular/core';\nimport { SelectionDropdownComponent } from './selection-dropdown.component';\n\n/**\n * Directive that turns any element into a trigger for a SelectionDropdown component.\n * Handles click and keyboard interactions to open/close the dropdown.\n */\n@Directive({\n selector: '[apSelectionDropdownTrigger]',\n})\nexport class SelectionDropdownTriggerDirective {\n private readonly elementRef = inject(ElementRef<HTMLElement>);\n\n /** Reference to the SelectionDropdown component that this trigger controls */\n apSelectionDropdownTrigger = input.required<SelectionDropdownComponent>();\n\n /** Prevents the trigger from opening/toggling the dropdown when true */\n apSelectionDropdownTriggerDisable = input(false);\n\n /** Handles click events to toggle the dropdown */\n @HostListener('click', ['$event'])\n onClick(event: MouseEvent): void {\n if (this.apSelectionDropdownTriggerDisable()) return;\n\n event.preventDefault();\n event.stopPropagation();\n\n this.apSelectionDropdownTrigger().toggle(this.elementRef.nativeElement);\n }\n\n /** Handles keyboard events for accessibility (Enter, Space, Arrow Down, Escape) */\n @HostListener('keydown', ['$event'])\n onKeyDown(event: KeyboardEvent): void {\n const dropdown = this.apSelectionDropdownTrigger();\n\n switch (event.key) {\n case 'Enter':\n case ' ':\n case 'ArrowDown':\n if (this.apSelectionDropdownTriggerDisable()) return;\n event.preventDefault();\n dropdown.open(this.elementRef.nativeElement);\n break;\n\n case 'Escape':\n event.preventDefault();\n dropdown.close();\n break;\n }\n }\n}\n","import { CheckboxComponent } from '@agorapulse/ui-components/checkbox';\nimport { createDropdownOverlay, DropdownOverlay } from '@agorapulse/ui-components/dropdown-base';\nimport { InputSearchComponent } from '@agorapulse/ui-components/input-search';\nimport { UI_COMPONENTS_SYMBOLS } from '@agorapulse/ui-components/providers';\nimport { DropdownItemMultipleOneLineComponent } from '@agorapulse/ui-components/select';\nimport { TooltipDirective } from '@agorapulse/ui-components/tooltip';\nimport { SymbolComponent, SymbolRegistry } from '@agorapulse/ui-symbol';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChild,\n effect,\n inject,\n input,\n linkedSignal,\n model,\n OnDestroy,\n output,\n signal,\n TemplateRef, untracked,\n viewChild,\n} from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { debounceTime, distinctUntilChanged, Subject, takeUntil } from 'rxjs';\n\nexport interface SelectionDropdownItem {\n /** Unique HTML ID for the item */\n htmlId: string;\n /** Display text for the item */\n text: string;\n /** Whether the item is selected */\n selected: boolean;\n /** Whether the item is disabled and non-interactive */\n disabled?: boolean;\n /** Avatar URL to display */\n avatarUrl?: string;\n /** Symbol ID to display */\n symbolId?: string;\n /** Tooltip text displayed when item is disabled */\n disabledTooltip?: string;\n /** Text displayed in a badge next to the item */\n badgeText?: string;\n /** Whether the feature is locked */\n isFeatureLocked?: boolean;\n /** Whether avatar should be rounded */\n roundedAvatar?: boolean;\n /** Avatar network type */\n network?: any;\n /** Symbol color */\n symbolColor?: string;\n /** Symbol tooltip text */\n symbolTooltipText?: string;\n /** Group label - items with the same groupLabel will be grouped together */\n groupLabel?: string;\n}\n\n/**\n * A dropdown component that displays a list of selectable items with checkboxes,\n * badges, tooltips, and keyboard navigation.\n */\n@Component({\n changeDetection: ChangeDetectionStrategy.OnPush,\n selector: 'ap-selection-dropdown',\n templateUrl: './selection-dropdown.component.html',\n styleUrls: ['./selection-dropdown.component.scss'],\n imports: [\n CheckboxComponent,\n DropdownItemMultipleOneLineComponent,\n FormsModule,\n InputSearchComponent,\n SymbolComponent,\n TooltipDirective,\n ],\n})\nexport class SelectionDropdownComponent implements DropdownOverlay, OnDestroy {\n private readonly symbolRegistry = inject(SymbolRegistry);\n private readonly overlay = createDropdownOverlay();\n\n selectionDropdownTemplate = viewChild<TemplateRef<unknown>>('selectionDropdownTemplate');\n trigger = contentChild<TemplateRef<unknown>>('trigger');\n\n /** ID for the header button */\n headerButtonId = input<string>();\n /** ID for the footer button */\n footerButtonId = input<string>();\n /** Array of items to display in the dropdown menu */\n items = input<SelectionDropdownItem[]>([]);\n /** Title to display in the header */\n title = input<string>();\n /** Text for the footer button */\n footerButtonText = input<string>();\n /** Symbol ID for the footer button */\n footerButtonSymbolId = input<string>();\n /** Text for the header button */\n headerButtonText = input<string>();\n /** Symbol ID for the header button */\n headerButtonSymbolId = input<string>();\n /** Placeholder text for the search input */\n searchPlaceholderText = input('Search');\n /** Text to display when no search results are found */\n noSearchResultsText = input('No results found');\n\n /** Whether to show a backdrop that closes the dropdown when clicked */\n showBackdrop = input(true);\n /** Whether the dropdown is disabled and cannot be opened */\n disabled = input(false);\n /** Default position for the dropdown relative to the trigger element */\n defaultPosition = input<'right' | 'left'>('right');\n\n /** Emits when the dropdown menu is opened */\n opened = output<void>();\n /** Emits when the dropdown menu is closed */\n closed = output<void>();\n /** Emits when a dropdown item selection changes */\n selectionChange = output<SelectionDropdownItem[]>();\n /** Emits when the footer button is clicked */\n footerButtonClick = output<void>();\n /** Emits when the header button is clicked */\n headerButtonClick = output<void>();\n /** Emits when the search input is changed */\n searchInputChange = output<string>();\n\n /**\n * Two-way bindable, clearable search term. Consumers can read it and reset it (set to '')\n * to clear the search and restore the full item list — letting them drive the search\n * declaratively instead of reaching into the rendered `ap-input-search`.\n */\n readonly searchTerm = model<string>('');\n\n private readonly destroy$ = new Subject<void>();\n private readonly searchTermSubject = new Subject<string>();\n\n protected readonly inputSearchComponent = viewChild<InputSearchComponent>('inputSearchElement');\n\n readonly isOpen = this.overlay.isOpen;\n\n focusInput = effect(() => {\n const inputSearch = this.inputSearchComponent();\n untracked(() => {\n if (this.isOpen() && inputSearch) {\n inputSearch.focusInput();\n }\n })\n })\n\n private readonly internalItems = linkedSignal(() => this.items());\n\n protected readonly filteredItems = signal<SelectionDropdownItem[]>([]);\n protected readonly initiallySelectedItems = signal<SelectionDropdownItem[]>([]);\n\n // Computed properties for template usage\n protected readonly selectedItems = computed(() => {\n const initiallySelectedIds = this.initiallySelectedItems().map(item => item.htmlId);\n return this.filteredItems().filter(item => initiallySelectedIds.includes(item.htmlId));\n });\n\n protected readonly unselectedItems = computed(() => {\n const initiallySelectedIds = this.initiallySelectedItems().map(item => item.htmlId);\n return this.filteredItems().filter(item => !initiallySelectedIds.includes(item.htmlId));\n });\n\n protected readonly groupLabels = computed(() => {\n const groupLabels = this.unselectedItems()\n .map(item => item.groupLabel)\n .filter((label): label is string => !!label);\n return [...new Set(groupLabels)];\n });\n\n protected readonly ungroupedItems = computed(() => {\n return this.unselectedItems().filter(item => !item.groupLabel);\n });\n\n // Computed maps for template optimization\n protected readonly groupSelectionStates = computed(() => {\n const states: Record<string, 'selected' | 'partial' | 'unselected'> = {};\n for (const groupLabel of this.groupLabels()) {\n const groupItems = this.filteredItems().filter(item => item.groupLabel === groupLabel);\n const selectableItems = groupItems.filter(item => !item.disabled && !item.isFeatureLocked);\n\n if (selectableItems.length === 0) {\n states[groupLabel] = 'unselected';\n } else {\n const selectedCount = selectableItems.filter(item => item.selected).length;\n if (selectedCount === 0) states[groupLabel] = 'unselected';\n else if (selectedCount === selectableItems.length) states[groupLabel] = 'selected';\n else states[groupLabel] = 'partial';\n }\n }\n return states;\n });\n\n protected readonly groupItemsMap = computed(() => {\n const map: Record<string, SelectionDropdownItem[]> = {};\n for (const groupLabel of this.groupLabels()) {\n map[groupLabel] = this.unselectedItems().filter(item => item.groupLabel === groupLabel);\n }\n return map;\n });\n\n constructor() {\n this.symbolRegistry.withSymbols(...(inject(UI_COMPONENTS_SYMBOLS, { optional: true })?.flat() ?? []));\n\n // Set up debounced search\n this.searchTermSubject.pipe(debounceTime(100), distinctUntilChanged(), takeUntil(this.destroy$)).subscribe(term => {\n const items = this.internalItems();\n this.updateFilteredItems(term?.toLowerCase() ?? '', items);\n });\n\n // Feed the debounced filter pipeline from the search term signal, so the list re-filters\n // both on user typing and on an external set (a consumer resetting searchTerm to '').\n effect(() => this.searchTermSubject.next(this.searchTerm() ?? ''));\n\n // Initialize filtered items when items change\n effect(() => {\n const items = this.internalItems();\n if (!this.searchTerm()) {\n this.filteredItems.set(items);\n }\n });\n }\n\n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n }\n\n /** Opens the dropdown menu at the specified trigger element */\n open(triggerElement?: HTMLElement): void {\n const template = this.selectionDropdownTemplate();\n if (this.disabled() || this.isOpen() || !template) return;\n\n this.overlay.open(template, triggerElement, {\n showBackdrop: this.showBackdrop(),\n defaultPosition: this.defaultPosition(),\n onClose: () => this.close(),\n });\n\n // Capture initially selected items as a static snapshot\n const selectedItems = this.internalItems().filter(item => item.selected);\n this.initiallySelectedItems.set(selectedItems);\n\n this.opened.emit();\n }\n\n /** Closes the dropdown menu and cleans up overlay resources */\n close(): void {\n if (!this.isOpen()) return;\n this.initiallySelectedItems.set([]);\n this.overlay.close();\n this.closed.emit();\n }\n\n /** Toggles the dropdown menu open or closed state */\n toggle(triggerElement?: HTMLElement): void {\n if (this.isOpen()) {\n this.close();\n } else {\n this.open(triggerElement);\n }\n }\n\n /** Handles item toggle events, updating selection and emitting changes */\n onItemToggle(item: SelectionDropdownItem, checked: boolean): void {\n if (item.disabled || item.isFeatureLocked) {\n return;\n }\n\n const updatedItems = this.internalItems().map(i => (i.htmlId === item.htmlId ? { ...i, selected: checked } : i));\n this.internalItems.set(updatedItems);\n this.selectionChange.emit(updatedItems);\n\n // Update the state of the filtered item that has been selected\n this.filteredItems.update(items => items.map(filteredItem => filteredItem.htmlId === item.htmlId ? { ...filteredItem, selected: checked } : filteredItem));\n }\n\n /** Handles footer button clicks */\n onFooterButtonClick(): void {\n this.footerButtonClick.emit();\n }\n\n /** Handles footer button keyboard events */\n onFooterButtonKeydown(event: KeyboardEvent): void {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.footerButtonClick.emit();\n }\n }\n\n /** Handles header button clicks */\n onHeaderButtonClick(): void {\n this.headerButtonClick.emit();\n }\n\n /** Handles header button keyboard events */\n onHeaderButtonKeydown(event: KeyboardEvent): void {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.headerButtonClick.emit();\n }\n }\n\n /** Handles search input changes from the rendered field. Filtering is driven by the\n * `searchTerm` effect, so this only updates the term and notifies listeners. */\n onSearchTermChange(term: string): void {\n this.searchTerm.set(term ?? '');\n this.searchInputChange.emit(term ?? '');\n }\n\n /** Handles group toggle events, selecting/deselecting all items within the group */\n onGroupToggle(groupLabel: string, checked: boolean): void {\n if (typeof checked !== 'boolean') {\n return;\n }\n const updatedItems = this.internalItems().map(item => {\n if (item.groupLabel === groupLabel && !item.disabled && !item.isFeatureLocked) {\n return { ...item, selected: checked };\n }\n return item;\n });\n this.internalItems.set(updatedItems);\n this.selectionChange.emit(updatedItems);\n }\n\n /** Updates the filtered items based on search term */\n private updateFilteredItems(searchTerm: string, items: SelectionDropdownItem[]): void {\n if (!searchTerm) {\n this.filteredItems.set(items);\n return;\n }\n\n const filtered = items.filter(item => item.text.toLowerCase().includes(searchTerm));\n this.filteredItems.set(filtered);\n }\n\n}","<ng-template #selectionDropdownTemplate>\n <div class=\"ap-selection-dropdown__content\">\n <!-- Header -->\n <div class=\"ap-selection-dropdown__header\">\n <div class=\"ap-selection-dropdown__header-top\">\n @if (title()) {\n <h3 class=\"ap-selection-dropdown__title\">\n {{ title() }}\n </h3>\n }\n @if (headerButtonText()) {\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"headerButtonId()\"\n (click)=\"onHeaderButtonClick()\"\n (keydown)=\"onHeaderButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"headerButtonSymbolId()\" />\n {{ headerButtonText() }}\n </a>\n }\n </div>\n <ap-input-search\n #inputSearchElement\n [placeholder]=\"searchPlaceholderText()\"\n [clearable]=\"true\"\n [ngModel]=\"searchTerm()\"\n (ngModelChange)=\"onSearchTermChange($event)\" />\n </div>\n\n <!-- Selection dropdown items -->\n <div class=\"ap-selection-dropdown__items\">\n @if (filteredItems().length === 0 && searchTerm()) {\n <div class=\"ap-selection-dropdown__no-results\">\n {{ noSearchResultsText() }}\n </div>\n } @else {\n <!-- Selected items section (at the top) -->\n @if (selectedItems().length > 0) {\n <div class=\"ap-selection-dropdown__selected-section\">\n @for (item of selectedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n\n <!-- Ungrouped unselected items -->\n @for (item of ungroupedItems(); track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n\n <!-- Groups -->\n @for (groupLabel of groupLabels(); track groupLabel) {\n <div class=\"ap-selection-dropdown__group\">\n <!-- Group header with checkbox -->\n <div class=\"ap-selection-dropdown__group-header\">\n <div class=\"ap-selection-dropdown__group-label\">\n <ap-checkbox\n [name]=\"groupLabel\"\n [checked]=\"groupSelectionStates()[groupLabel] === 'selected'\"\n [indeterminate]=\"groupSelectionStates()[groupLabel] === 'partial'\"\n (change)=\"onGroupToggle(groupLabel, $event)\">\n {{ groupLabel }}\n </ap-checkbox>\n </div>\n </div>\n\n <!-- Group items -->\n @for (item of groupItemsMap()[groupLabel]; track item.htmlId) {\n <div [apTooltip]=\"item.disabledTooltip\">\n <button\n type=\"button\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n class=\"ap-selection-dropdown__item-button\"\n [class.ap-selection-dropdown__item-button--disabled]=\"item.disabled || item.isFeatureLocked\"\n (click)=\"onItemToggle(item, !item.selected)\">\n <ap-dropdown-item-multiple-one-line\n class=\"ap-selection-dropdown__item ap-selection-dropdown__item--grouped\"\n [text]=\"item.text\"\n [selected]=\"item.selected\"\n [htmlId]=\"item.htmlId\"\n [disabled]=\"item.disabled || false\"\n [avatarUrl]=\"item.avatarUrl\"\n [symbolId]=\"item.symbolId\"\n [badgeText]=\"item.badgeText\"\n [isFeatureLocked]=\"item.isFeatureLocked || false\"\n [roundedAvatar]=\"!!item.roundedAvatar\"\n [network]=\"item.network\"\n [symbolColor]=\"item.symbolColor\"\n [symbolTooltipText]=\"item.symbolTooltipText\" />\n </button>\n </div>\n }\n </div>\n }\n }\n </div>\n\n <!-- Footer -->\n @if (footerButtonText()) {\n <div class=\"ap-selection-dropdown__footer\">\n <a\n class=\"standalone\"\n role=\"link\"\n tabindex=\"0\"\n [id]=\"footerButtonId()\"\n (click)=\"onFooterButtonClick()\"\n (keydown)=\"onFooterButtonKeydown($event)\">\n <ap-symbol [symbolId]=\"footerButtonSymbolId()\" />\n {{ footerButtonText() }}\n </a>\n </div>\n }\n </div>\n</ng-template>\n","/**\n *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CAAA,EAAA,oBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAqDoB,oBAAoB,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AErIlG;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -80,13 +80,18 @@ declare class SelectionDropdownComponent implements DropdownOverlay, OnDestroy {
|
|
|
80
80
|
headerButtonClick: _angular_core.OutputEmitterRef<void>;
|
|
81
81
|
/** Emits when the search input is changed */
|
|
82
82
|
searchInputChange: _angular_core.OutputEmitterRef<string>;
|
|
83
|
+
/**
|
|
84
|
+
* Two-way bindable, clearable search term. Consumers can read it and reset it (set to '')
|
|
85
|
+
* to clear the search and restore the full item list — letting them drive the search
|
|
86
|
+
* declaratively instead of reaching into the rendered `ap-input-search`.
|
|
87
|
+
*/
|
|
88
|
+
readonly searchTerm: _angular_core.ModelSignal<string>;
|
|
83
89
|
private readonly destroy$;
|
|
84
90
|
private readonly searchTermSubject;
|
|
85
91
|
protected readonly inputSearchComponent: _angular_core.Signal<InputSearchComponent | undefined>;
|
|
86
92
|
readonly isOpen: _angular_core.Signal<boolean>;
|
|
87
93
|
focusInput: _angular_core.EffectRef;
|
|
88
94
|
private readonly internalItems;
|
|
89
|
-
protected searchTerm: string;
|
|
90
95
|
protected readonly filteredItems: _angular_core.WritableSignal<SelectionDropdownItem[]>;
|
|
91
96
|
protected readonly initiallySelectedItems: _angular_core.WritableSignal<SelectionDropdownItem[]>;
|
|
92
97
|
protected readonly selectedItems: _angular_core.Signal<SelectionDropdownItem[]>;
|
|
@@ -113,14 +118,15 @@ declare class SelectionDropdownComponent implements DropdownOverlay, OnDestroy {
|
|
|
113
118
|
onHeaderButtonClick(): void;
|
|
114
119
|
/** Handles header button keyboard events */
|
|
115
120
|
onHeaderButtonKeydown(event: KeyboardEvent): void;
|
|
116
|
-
/** Handles search input changes
|
|
117
|
-
|
|
121
|
+
/** Handles search input changes from the rendered field. Filtering is driven by the
|
|
122
|
+
* `searchTerm` effect, so this only updates the term and notifies listeners. */
|
|
123
|
+
onSearchTermChange(term: string): void;
|
|
118
124
|
/** Handles group toggle events, selecting/deselecting all items within the group */
|
|
119
125
|
onGroupToggle(groupLabel: string, checked: boolean): void;
|
|
120
126
|
/** Updates the filtered items based on search term */
|
|
121
127
|
private updateFilteredItems;
|
|
122
128
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SelectionDropdownComponent, never>;
|
|
123
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SelectionDropdownComponent, "ap-selection-dropdown", never, { "headerButtonId": { "alias": "headerButtonId"; "required": false; "isSignal": true; }; "footerButtonId": { "alias": "footerButtonId"; "required": false; "isSignal": true; }; "items": { "alias": "items"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "footerButtonText": { "alias": "footerButtonText"; "required": false; "isSignal": true; }; "footerButtonSymbolId": { "alias": "footerButtonSymbolId"; "required": false; "isSignal": true; }; "headerButtonText": { "alias": "headerButtonText"; "required": false; "isSignal": true; }; "headerButtonSymbolId": { "alias": "headerButtonSymbolId"; "required": false; "isSignal": true; }; "searchPlaceholderText": { "alias": "searchPlaceholderText"; "required": false; "isSignal": true; }; "noSearchResultsText": { "alias": "noSearchResultsText"; "required": false; "isSignal": true; }; "showBackdrop": { "alias": "showBackdrop"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "defaultPosition": { "alias": "defaultPosition"; "required": false; "isSignal": true; }; }, { "opened": "opened"; "closed": "closed"; "selectionChange": "selectionChange"; "footerButtonClick": "footerButtonClick"; "headerButtonClick": "headerButtonClick"; "searchInputChange": "searchInputChange"; }, ["trigger"], never, true, never>;
|
|
129
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SelectionDropdownComponent, "ap-selection-dropdown", never, { "headerButtonId": { "alias": "headerButtonId"; "required": false; "isSignal": true; }; "footerButtonId": { "alias": "footerButtonId"; "required": false; "isSignal": true; }; "items": { "alias": "items"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "footerButtonText": { "alias": "footerButtonText"; "required": false; "isSignal": true; }; "footerButtonSymbolId": { "alias": "footerButtonSymbolId"; "required": false; "isSignal": true; }; "headerButtonText": { "alias": "headerButtonText"; "required": false; "isSignal": true; }; "headerButtonSymbolId": { "alias": "headerButtonSymbolId"; "required": false; "isSignal": true; }; "searchPlaceholderText": { "alias": "searchPlaceholderText"; "required": false; "isSignal": true; }; "noSearchResultsText": { "alias": "noSearchResultsText"; "required": false; "isSignal": true; }; "showBackdrop": { "alias": "showBackdrop"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "defaultPosition": { "alias": "defaultPosition"; "required": false; "isSignal": true; }; "searchTerm": { "alias": "searchTerm"; "required": false; "isSignal": true; }; }, { "opened": "opened"; "closed": "closed"; "selectionChange": "selectionChange"; "footerButtonClick": "footerButtonClick"; "headerButtonClick": "headerButtonClick"; "searchInputChange": "searchInputChange"; "searchTerm": "searchTermChange"; }, ["trigger"], never, true, never>;
|
|
124
130
|
}
|
|
125
131
|
|
|
126
132
|
/**
|
|
@@ -131,12 +137,14 @@ declare class SelectionDropdownTriggerDirective {
|
|
|
131
137
|
private readonly elementRef;
|
|
132
138
|
/** Reference to the SelectionDropdown component that this trigger controls */
|
|
133
139
|
apSelectionDropdownTrigger: _angular_core.InputSignal<SelectionDropdownComponent>;
|
|
140
|
+
/** Prevents the trigger from opening/toggling the dropdown when true */
|
|
141
|
+
apSelectionDropdownTriggerDisable: _angular_core.InputSignal<boolean>;
|
|
134
142
|
/** Handles click events to toggle the dropdown */
|
|
135
143
|
onClick(event: MouseEvent): void;
|
|
136
144
|
/** Handles keyboard events for accessibility (Enter, Space, Arrow Down, Escape) */
|
|
137
145
|
onKeyDown(event: KeyboardEvent): void;
|
|
138
146
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SelectionDropdownTriggerDirective, never>;
|
|
139
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<SelectionDropdownTriggerDirective, "[apSelectionDropdownTrigger]", never, { "apSelectionDropdownTrigger": { "alias": "apSelectionDropdownTrigger"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
147
|
+
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<SelectionDropdownTriggerDirective, "[apSelectionDropdownTrigger]", never, { "apSelectionDropdownTrigger": { "alias": "apSelectionDropdownTrigger"; "required": true; "isSignal": true; }; "apSelectionDropdownTriggerDisable": { "alias": "apSelectionDropdownTriggerDisable"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
140
148
|
}
|
|
141
149
|
|
|
142
150
|
export { SelectionDropdownComponent, SelectionDropdownTriggerDirective };
|
|
Binary file
|