@amro93/ngb-select 0.1.6 → 0.1.7
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.
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { input, model, output,
|
|
2
|
+
import { inject, ElementRef, ChangeDetectorRef, input, model, output, contentChild, viewChild, computed, signal, forwardRef, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { CommonModule } from '@angular/common';
|
|
5
5
|
import { FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
6
6
|
|
|
7
|
-
const NGB_SELECT_VERSION = '0.1.
|
|
7
|
+
const NGB_SELECT_VERSION = '0.1.7';
|
|
8
8
|
|
|
9
9
|
class NgbSelectComponent {
|
|
10
|
-
elementRef;
|
|
11
|
-
cdr;
|
|
12
|
-
ngZone;
|
|
13
10
|
static VERSION = NGB_SELECT_VERSION;
|
|
11
|
+
// --- Dependency Injection ---
|
|
12
|
+
elementRef = inject(ElementRef);
|
|
13
|
+
cdr = inject(ChangeDetectorRef);
|
|
14
14
|
// --- Basic & Data Inputs ---
|
|
15
15
|
options = input([], ...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
|
|
16
16
|
optionLabel = input('label', ...(ngDevMode ? [{ debugName: "optionLabel" }] : /* istanbul ignore next */ []));
|
|
@@ -61,7 +61,7 @@ class NgbSelectComponent {
|
|
|
61
61
|
direction = input(undefined, ...(ngDevMode ? [{ debugName: "direction" }] : /* istanbul ignore next */ []));
|
|
62
62
|
size = input(undefined, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
63
63
|
variant = input('outlined', ...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
64
|
-
fluid = input(
|
|
64
|
+
fluid = input(true, ...(ngDevMode ? [{ debugName: "fluid" }] : /* istanbul ignore next */ []));
|
|
65
65
|
scrollHeight = input('200px', ...(ngDevMode ? [{ debugName: "scrollHeight" }] : /* istanbul ignore next */ []));
|
|
66
66
|
style = input(undefined, ...(ngDevMode ? [{ debugName: "style" }] : /* istanbul ignore next */ []));
|
|
67
67
|
styleClass = input(undefined, ...(ngDevMode ? [{ debugName: "styleClass" }] : /* istanbul ignore next */ []));
|
|
@@ -96,23 +96,23 @@ class NgbSelectComponent {
|
|
|
96
96
|
onRemoveChip = output();
|
|
97
97
|
onLazyLoad = output();
|
|
98
98
|
// --- Custom Content Templates ---
|
|
99
|
-
itemTemplate;
|
|
100
|
-
selectedItemTemplate;
|
|
101
|
-
labelTemplate;
|
|
102
|
-
chipTemplate;
|
|
103
|
-
headerCheckboxTemplate;
|
|
104
|
-
headerTemplate;
|
|
105
|
-
footerTemplate;
|
|
106
|
-
groupTemplate;
|
|
107
|
-
emptyTemplate;
|
|
108
|
-
clearIconTemplate;
|
|
109
|
-
dropdownIconTemplate;
|
|
110
|
-
filterIconTemplate;
|
|
99
|
+
itemTemplate = contentChild('item', ...(ngDevMode ? [{ debugName: "itemTemplate" }] : /* istanbul ignore next */ []));
|
|
100
|
+
selectedItemTemplate = contentChild('selectedItem', ...(ngDevMode ? [{ debugName: "selectedItemTemplate" }] : /* istanbul ignore next */ []));
|
|
101
|
+
labelTemplate = contentChild('label', ...(ngDevMode ? [{ debugName: "labelTemplate" }] : /* istanbul ignore next */ []));
|
|
102
|
+
chipTemplate = contentChild('chip', ...(ngDevMode ? [{ debugName: "chipTemplate" }] : /* istanbul ignore next */ []));
|
|
103
|
+
headerCheckboxTemplate = contentChild('headerCheckbox', ...(ngDevMode ? [{ debugName: "headerCheckboxTemplate" }] : /* istanbul ignore next */ []));
|
|
104
|
+
headerTemplate = contentChild('header', ...(ngDevMode ? [{ debugName: "headerTemplate" }] : /* istanbul ignore next */ []));
|
|
105
|
+
footerTemplate = contentChild('footer', ...(ngDevMode ? [{ debugName: "footerTemplate" }] : /* istanbul ignore next */ []));
|
|
106
|
+
groupTemplate = contentChild('group', ...(ngDevMode ? [{ debugName: "groupTemplate" }] : /* istanbul ignore next */ []));
|
|
107
|
+
emptyTemplate = contentChild('empty', ...(ngDevMode ? [{ debugName: "emptyTemplate" }] : /* istanbul ignore next */ []));
|
|
108
|
+
clearIconTemplate = contentChild('clearIcon', ...(ngDevMode ? [{ debugName: "clearIconTemplate" }] : /* istanbul ignore next */ []));
|
|
109
|
+
dropdownIconTemplate = contentChild('dropdownIcon', ...(ngDevMode ? [{ debugName: "dropdownIconTemplate" }] : /* istanbul ignore next */ []));
|
|
110
|
+
filterIconTemplate = contentChild('filterIcon', ...(ngDevMode ? [{ debugName: "filterIconTemplate" }] : /* istanbul ignore next */ []));
|
|
111
111
|
// --- View References ---
|
|
112
|
-
filterInputElement;
|
|
113
|
-
triggerFilterInputElement;
|
|
114
|
-
editableInputElement;
|
|
115
|
-
dropdownMenuElement;
|
|
112
|
+
filterInputElement = viewChild('filterInput', ...(ngDevMode ? [{ debugName: "filterInputElement" }] : /* istanbul ignore next */ []));
|
|
113
|
+
triggerFilterInputElement = viewChild('triggerFilterInput', ...(ngDevMode ? [{ debugName: "triggerFilterInputElement" }] : /* istanbul ignore next */ []));
|
|
114
|
+
editableInputElement = viewChild('editableInput', ...(ngDevMode ? [{ debugName: "editableInputElement" }] : /* istanbul ignore next */ []));
|
|
115
|
+
dropdownMenuElement = viewChild('dropdownMenu', ...(ngDevMode ? [{ debugName: "dropdownMenuElement" }] : /* istanbul ignore next */ []));
|
|
116
116
|
// --- Computed UI & Accessibility State ---
|
|
117
117
|
effectiveSearchPlaceholder = computed(() => {
|
|
118
118
|
return (this.searchPlaceholder() || this.filterPlaceholder() || this.placeholder() || 'Search...');
|
|
@@ -298,34 +298,28 @@ class NgbSelectComponent {
|
|
|
298
298
|
onModelTouched = () => { };
|
|
299
299
|
unlistenWindow;
|
|
300
300
|
unlistenDocumentClick;
|
|
301
|
-
constructor(elementRef, cdr, ngZone) {
|
|
302
|
-
this.elementRef = elementRef;
|
|
303
|
-
this.cdr = cdr;
|
|
304
|
-
this.ngZone = ngZone;
|
|
305
|
-
}
|
|
306
301
|
ngOnInit() {
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
const handleWindowReposition = () => {
|
|
313
|
-
if (this.overlayVisible()) {
|
|
314
|
-
this.calculateDropdownPosition();
|
|
315
|
-
if (this.appendTo()) {
|
|
316
|
-
this.repositionOverlay();
|
|
317
|
-
}
|
|
302
|
+
const handleWindowReposition = () => {
|
|
303
|
+
if (this.overlayVisible()) {
|
|
304
|
+
this.calculateDropdownPosition();
|
|
305
|
+
if (this.appendTo()) {
|
|
306
|
+
this.repositionOverlay();
|
|
318
307
|
}
|
|
319
|
-
};
|
|
320
|
-
if (typeof window !== 'undefined') {
|
|
321
|
-
window.addEventListener('resize', handleWindowReposition, { passive: true });
|
|
322
|
-
window.addEventListener('scroll', handleWindowReposition, { passive: true, capture: true });
|
|
323
|
-
this.unlistenWindow = () => {
|
|
324
|
-
window.removeEventListener('resize', handleWindowReposition);
|
|
325
|
-
window.removeEventListener('scroll', handleWindowReposition, { capture: true });
|
|
326
|
-
};
|
|
327
308
|
}
|
|
328
|
-
}
|
|
309
|
+
};
|
|
310
|
+
if (typeof window !== 'undefined') {
|
|
311
|
+
window.addEventListener('resize', handleWindowReposition, { passive: true });
|
|
312
|
+
window.addEventListener('scroll', handleWindowReposition, { passive: true, capture: true });
|
|
313
|
+
this.unlistenWindow = () => {
|
|
314
|
+
window.removeEventListener('resize', handleWindowReposition);
|
|
315
|
+
window.removeEventListener('scroll', handleWindowReposition, { capture: true });
|
|
316
|
+
};
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
ngAfterViewInit() {
|
|
320
|
+
if (this.autofocus()) {
|
|
321
|
+
this.focus();
|
|
322
|
+
}
|
|
329
323
|
}
|
|
330
324
|
ngOnDestroy() {
|
|
331
325
|
if (this.unlistenWindow) {
|
|
@@ -541,8 +535,9 @@ class NgbSelectComponent {
|
|
|
541
535
|
const spaceBelow = window.innerHeight - triggerRect.bottom;
|
|
542
536
|
const spaceAbove = triggerRect.top;
|
|
543
537
|
let panelHeight = 200;
|
|
544
|
-
|
|
545
|
-
|
|
538
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
539
|
+
if (dropdownMenuEl?.nativeElement?.offsetHeight) {
|
|
540
|
+
panelHeight = dropdownMenuEl.nativeElement.offsetHeight;
|
|
546
541
|
}
|
|
547
542
|
else if (this.scrollHeight()) {
|
|
548
543
|
const parsed = parseInt(this.scrollHeight(), 10);
|
|
@@ -573,18 +568,17 @@ class NgbSelectComponent {
|
|
|
573
568
|
this.onShow.emit(event || null);
|
|
574
569
|
this.onModelTouched();
|
|
575
570
|
this.bindDocumentClickListener();
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
});
|
|
571
|
+
const triggerFilterInputEl = this.triggerFilterInputElement();
|
|
572
|
+
const filterInputEl = this.filterInputElement();
|
|
573
|
+
if (this.filterInTrigger() && triggerFilterInputEl) {
|
|
574
|
+
triggerFilterInputEl.nativeElement.focus();
|
|
575
|
+
}
|
|
576
|
+
else if (this.filter() && filterInputEl) {
|
|
577
|
+
filterInputEl.nativeElement.focus();
|
|
578
|
+
}
|
|
579
|
+
this.handleFocusOnOpen();
|
|
580
|
+
this.handleAppendTo();
|
|
581
|
+
this.cdr.markForCheck();
|
|
588
582
|
}
|
|
589
583
|
closeOverlay(event) {
|
|
590
584
|
if (!this.overlayVisible())
|
|
@@ -602,12 +596,11 @@ class NgbSelectComponent {
|
|
|
602
596
|
if (typeof document === 'undefined' || this.unlistenDocumentClick)
|
|
603
597
|
return;
|
|
604
598
|
const clickHandler = (event) => {
|
|
599
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
605
600
|
if (!this.elementRef.nativeElement.contains(event.target) &&
|
|
606
|
-
(!
|
|
607
|
-
!
|
|
608
|
-
this.
|
|
609
|
-
this.closeOverlay(event);
|
|
610
|
-
});
|
|
601
|
+
(!dropdownMenuEl ||
|
|
602
|
+
!dropdownMenuEl.nativeElement.contains(event.target))) {
|
|
603
|
+
this.closeOverlay(event);
|
|
611
604
|
}
|
|
612
605
|
};
|
|
613
606
|
document.addEventListener('click', clickHandler, { capture: true });
|
|
@@ -638,9 +631,10 @@ class NgbSelectComponent {
|
|
|
638
631
|
else if (this.autoOptionFocus()) {
|
|
639
632
|
targetIndex = selectedIdx !== -1 ? selectedIdx : 0;
|
|
640
633
|
}
|
|
641
|
-
|
|
634
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
635
|
+
if (targetIndex !== -1 && dropdownMenuEl) {
|
|
642
636
|
this.focusedIndex.set(targetIndex);
|
|
643
|
-
const elements =
|
|
637
|
+
const elements = dropdownMenuEl.nativeElement.querySelectorAll('.dropdown-item[role="option"]');
|
|
644
638
|
const targetElement = elements[targetIndex];
|
|
645
639
|
if (targetElement && typeof targetElement.scrollIntoView === 'function') {
|
|
646
640
|
targetElement.scrollIntoView({ block: 'nearest', inline: 'start' });
|
|
@@ -673,8 +667,9 @@ class NgbSelectComponent {
|
|
|
673
667
|
this.updateModel(val, event);
|
|
674
668
|
if (this.filterInTrigger()) {
|
|
675
669
|
this.filterValue.set('');
|
|
676
|
-
|
|
677
|
-
|
|
670
|
+
const triggerFilterInputEl = this.triggerFilterInputElement();
|
|
671
|
+
if (triggerFilterInputEl) {
|
|
672
|
+
triggerFilterInputEl.nativeElement.value = '';
|
|
678
673
|
}
|
|
679
674
|
}
|
|
680
675
|
this.closeOverlay(event);
|
|
@@ -728,8 +723,9 @@ class NgbSelectComponent {
|
|
|
728
723
|
this.updateModel(inputVal, event);
|
|
729
724
|
}
|
|
730
725
|
onEditableFocus(event) {
|
|
731
|
-
|
|
732
|
-
|
|
726
|
+
const editableInputEl = this.editableInputElement();
|
|
727
|
+
if (this.selectOnFocus() && editableInputEl) {
|
|
728
|
+
editableInputEl.nativeElement.select();
|
|
733
729
|
}
|
|
734
730
|
this.onFocus.emit(event);
|
|
735
731
|
}
|
|
@@ -828,9 +824,9 @@ class NgbSelectComponent {
|
|
|
828
824
|
case 'Enter':
|
|
829
825
|
case ' ':
|
|
830
826
|
if (event.key === ' ' &&
|
|
831
|
-
((this.filter() && this.filterInputElement?.nativeElement === document.activeElement) ||
|
|
827
|
+
((this.filter() && this.filterInputElement()?.nativeElement === document.activeElement) ||
|
|
832
828
|
(this.filterInTrigger() &&
|
|
833
|
-
this.triggerFilterInputElement?.nativeElement === document.activeElement))) {
|
|
829
|
+
this.triggerFilterInputElement()?.nativeElement === document.activeElement))) {
|
|
834
830
|
return;
|
|
835
831
|
}
|
|
836
832
|
event.preventDefault();
|
|
@@ -882,8 +878,9 @@ class NgbSelectComponent {
|
|
|
882
878
|
}
|
|
883
879
|
if (nextIdx >= 0 && nextIdx < flatItems.length) {
|
|
884
880
|
this.focusedIndex.set(nextIdx);
|
|
885
|
-
|
|
886
|
-
|
|
881
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
882
|
+
if (dropdownMenuEl) {
|
|
883
|
+
const elements = dropdownMenuEl.nativeElement.querySelectorAll('.dropdown-item[role="option"]');
|
|
887
884
|
const targetElement = elements[nextIdx];
|
|
888
885
|
if (targetElement && typeof targetElement.scrollIntoView === 'function') {
|
|
889
886
|
targetElement.scrollIntoView({ block: 'nearest', inline: 'start' });
|
|
@@ -913,23 +910,25 @@ class NgbSelectComponent {
|
|
|
913
910
|
}
|
|
914
911
|
handleAppendTo() {
|
|
915
912
|
const appendTo = this.appendTo();
|
|
916
|
-
|
|
913
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
914
|
+
if (!appendTo || !dropdownMenuEl)
|
|
917
915
|
return;
|
|
918
916
|
if (appendTo === 'body') {
|
|
919
|
-
document.body.appendChild(
|
|
917
|
+
document.body.appendChild(dropdownMenuEl.nativeElement);
|
|
920
918
|
this.repositionOverlay();
|
|
921
919
|
}
|
|
922
920
|
else if (appendTo instanceof HTMLElement) {
|
|
923
|
-
appendTo.appendChild(
|
|
921
|
+
appendTo.appendChild(dropdownMenuEl.nativeElement);
|
|
924
922
|
this.repositionOverlay();
|
|
925
923
|
}
|
|
926
924
|
}
|
|
927
925
|
repositionOverlay() {
|
|
928
|
-
|
|
926
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
927
|
+
if (!dropdownMenuEl || this.isModalMode())
|
|
929
928
|
return;
|
|
930
929
|
this.calculateDropdownPosition();
|
|
931
930
|
const triggerRect = this.elementRef.nativeElement.getBoundingClientRect();
|
|
932
|
-
const dropdown =
|
|
931
|
+
const dropdown = dropdownMenuEl.nativeElement;
|
|
933
932
|
dropdown.style.position = 'fixed';
|
|
934
933
|
dropdown.style.left = `${triggerRect.left}px`;
|
|
935
934
|
dropdown.style.width = `${triggerRect.width}px`;
|
|
@@ -947,8 +946,9 @@ class NgbSelectComponent {
|
|
|
947
946
|
}
|
|
948
947
|
}
|
|
949
948
|
cleanAppendTo() {
|
|
950
|
-
|
|
951
|
-
|
|
949
|
+
const dropdownMenuEl = this.dropdownMenuElement();
|
|
950
|
+
if (this.appendTo() && dropdownMenuEl) {
|
|
951
|
+
const el = dropdownMenuEl.nativeElement;
|
|
952
952
|
if (el.parentElement) {
|
|
953
953
|
el.parentElement.removeChild(el);
|
|
954
954
|
}
|
|
@@ -961,11 +961,13 @@ class NgbSelectComponent {
|
|
|
961
961
|
this.onBlur.emit(event);
|
|
962
962
|
}
|
|
963
963
|
focus() {
|
|
964
|
-
|
|
965
|
-
|
|
964
|
+
const triggerFilterInputEl = this.triggerFilterInputElement();
|
|
965
|
+
const editableInputEl = this.editableInputElement();
|
|
966
|
+
if (this.filterInTrigger() && triggerFilterInputEl) {
|
|
967
|
+
triggerFilterInputEl.nativeElement.focus();
|
|
966
968
|
}
|
|
967
|
-
else if (this.editable() && !this.multiple() &&
|
|
968
|
-
|
|
969
|
+
else if (this.editable() && !this.multiple() && editableInputEl) {
|
|
970
|
+
editableInputEl.nativeElement.focus();
|
|
969
971
|
}
|
|
970
972
|
else {
|
|
971
973
|
const trigger = this.elementRef.nativeElement.querySelector('.form-select');
|
|
@@ -973,14 +975,14 @@ class NgbSelectComponent {
|
|
|
973
975
|
trigger.focus();
|
|
974
976
|
}
|
|
975
977
|
}
|
|
976
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: NgbSelectComponent, deps: [
|
|
978
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: NgbSelectComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
977
979
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.21", type: NgbSelectComponent, isStandalone: true, selector: "ngb-select", inputs: { options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null }, optionLabel: { classPropertyName: "optionLabel", publicName: "optionLabel", isSignal: true, isRequired: false, transformFunction: null }, optionValue: { classPropertyName: "optionValue", publicName: "optionValue", isSignal: true, isRequired: false, transformFunction: null }, optionDisabled: { classPropertyName: "optionDisabled", publicName: "optionDisabled", isSignal: true, isRequired: false, transformFunction: null }, optionGroupLabel: { classPropertyName: "optionGroupLabel", publicName: "optionGroupLabel", isSignal: true, isRequired: false, transformFunction: null }, optionGroupChildren: { classPropertyName: "optionGroupChildren", publicName: "optionGroupChildren", isSignal: true, isRequired: false, transformFunction: null }, group: { classPropertyName: "group", publicName: "group", isSignal: true, isRequired: false, transformFunction: null }, dataKey: { classPropertyName: "dataKey", publicName: "dataKey", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, display: { classPropertyName: "display", publicName: "display", isSignal: true, isRequired: false, transformFunction: null }, showSelectAll: { classPropertyName: "showSelectAll", publicName: "showSelectAll", isSignal: true, isRequired: false, transformFunction: null }, maxSelectedLabels: { classPropertyName: "maxSelectedLabels", publicName: "maxSelectedLabels", isSignal: true, isRequired: false, transformFunction: null }, selectedItemsLabel: { classPropertyName: "selectedItemsLabel", publicName: "selectedItemsLabel", isSignal: true, isRequired: false, transformFunction: null }, selectionLimit: { classPropertyName: "selectionLimit", publicName: "selectionLimit", isSignal: true, isRequired: false, transformFunction: null }, closeOnSelect: { classPropertyName: "closeOnSelect", publicName: "closeOnSelect", isSignal: true, isRequired: false, transformFunction: null }, filter: { classPropertyName: "filter", publicName: "filter", isSignal: true, isRequired: false, transformFunction: null }, filterBy: { classPropertyName: "filterBy", publicName: "filterBy", isSignal: true, isRequired: false, transformFunction: null }, filterMatchMode: { classPropertyName: "filterMatchMode", publicName: "filterMatchMode", isSignal: true, isRequired: false, transformFunction: null }, filterLocale: { classPropertyName: "filterLocale", publicName: "filterLocale", isSignal: true, isRequired: false, transformFunction: null }, filterNormalizeArabic: { classPropertyName: "filterNormalizeArabic", publicName: "filterNormalizeArabic", isSignal: true, isRequired: false, transformFunction: null }, filterPlaceholder: { classPropertyName: "filterPlaceholder", publicName: "filterPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholder: { classPropertyName: "searchPlaceholder", publicName: "searchPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, filterInTrigger: { classPropertyName: "filterInTrigger", publicName: "filterInTrigger", isSignal: true, isRequired: false, transformFunction: null }, resetFilterOnHide: { classPropertyName: "resetFilterOnHide", publicName: "resetFilterOnHide", isSignal: true, isRequired: false, transformFunction: null }, emptyMessage: { classPropertyName: "emptyMessage", publicName: "emptyMessage", isSignal: true, isRequired: false, transformFunction: null }, emptyFilterMessage: { classPropertyName: "emptyFilterMessage", publicName: "emptyFilterMessage", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, floatLabel: { classPropertyName: "floatLabel", publicName: "floatLabel", isSignal: true, isRequired: false, transformFunction: null }, floatLabelVariant: { classPropertyName: "floatLabelVariant", publicName: "floatLabelVariant", isSignal: true, isRequired: false, transformFunction: null }, autofocus: { classPropertyName: "autofocus", publicName: "autofocus", isSignal: true, isRequired: false, transformFunction: null }, tabindex: { classPropertyName: "tabindex", publicName: "tabindex", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledBy: { classPropertyName: "ariaLabelledBy", publicName: "ariaLabelledBy", isSignal: true, isRequired: false, transformFunction: null }, dir: { classPropertyName: "dir", publicName: "dir", isSignal: true, isRequired: false, transformFunction: null }, dropdownPosition: { classPropertyName: "dropdownPosition", publicName: "dropdownPosition", isSignal: true, isRequired: false, transformFunction: null }, dropdownDirection: { classPropertyName: "dropdownDirection", publicName: "dropdownDirection", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, fluid: { classPropertyName: "fluid", publicName: "fluid", isSignal: true, isRequired: false, transformFunction: null }, scrollHeight: { classPropertyName: "scrollHeight", publicName: "scrollHeight", isSignal: true, isRequired: false, transformFunction: null }, style: { classPropertyName: "style", publicName: "style", isSignal: true, isRequired: false, transformFunction: null }, styleClass: { classPropertyName: "styleClass", publicName: "styleClass", isSignal: true, isRequired: false, transformFunction: null }, panelStyle: { classPropertyName: "panelStyle", publicName: "panelStyle", isSignal: true, isRequired: false, transformFunction: null }, panelStyleClass: { classPropertyName: "panelStyleClass", publicName: "panelStyleClass", isSignal: true, isRequired: false, transformFunction: null }, appendTo: { classPropertyName: "appendTo", publicName: "appendTo", isSignal: true, isRequired: false, transformFunction: null }, modal: { classPropertyName: "modal", publicName: "modal", isSignal: true, isRequired: false, transformFunction: null }, popup: { classPropertyName: "popup", publicName: "popup", isSignal: true, isRequired: false, transformFunction: null }, touchUI: { classPropertyName: "touchUI", publicName: "touchUI", isSignal: true, isRequired: false, transformFunction: null }, popupTitle: { classPropertyName: "popupTitle", publicName: "popupTitle", isSignal: true, isRequired: false, transformFunction: null }, modalTitle: { classPropertyName: "modalTitle", publicName: "modalTitle", isSignal: true, isRequired: false, transformFunction: null }, editable: { classPropertyName: "editable", publicName: "editable", isSignal: true, isRequired: false, transformFunction: null }, maxLength: { classPropertyName: "maxLength", publicName: "maxLength", isSignal: true, isRequired: false, transformFunction: null }, selectOnFocus: { classPropertyName: "selectOnFocus", publicName: "selectOnFocus", isSignal: true, isRequired: false, transformFunction: null }, autoOptionFocus: { classPropertyName: "autoOptionFocus", publicName: "autoOptionFocus", isSignal: true, isRequired: false, transformFunction: null }, focusOnOpen: { classPropertyName: "focusOnOpen", publicName: "focusOnOpen", isSignal: true, isRequired: false, transformFunction: null }, focusOnOpenStrategy: { classPropertyName: "focusOnOpenStrategy", publicName: "focusOnOpenStrategy", isSignal: true, isRequired: false, transformFunction: null }, lazy: { classPropertyName: "lazy", publicName: "lazy", isSignal: true, isRequired: false, transformFunction: null }, overlayVisible: { classPropertyName: "overlayVisible", publicName: "overlayVisible", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { disabled: "disabledChange", overlayVisible: "overlayVisibleChange", onChange: "onChange", onFilter: "onFilter", onFocus: "onFocus", onBlur: "onBlur", onShow: "onShow", onHide: "onHide", onClear: "onClear", onSelectAllChange: "onSelectAllChange", onRemoveChip: "onRemoveChip", onLazyLoad: "onLazyLoad" }, providers: [
|
|
978
980
|
{
|
|
979
981
|
provide: NG_VALUE_ACCESSOR,
|
|
980
982
|
useExisting: forwardRef(() => NgbSelectComponent),
|
|
981
983
|
multi: true,
|
|
982
984
|
},
|
|
983
|
-
], queries: [{ propertyName: "itemTemplate", first: true, predicate: ["item"], descendants: true }, { propertyName: "selectedItemTemplate", first: true, predicate: ["selectedItem"], descendants: true }, { propertyName: "labelTemplate", first: true, predicate: ["label"], descendants: true }, { propertyName: "chipTemplate", first: true, predicate: ["chip"], descendants: true }, { propertyName: "headerCheckboxTemplate", first: true, predicate: ["headerCheckbox"], descendants: true }, { propertyName: "headerTemplate", first: true, predicate: ["header"], descendants: true }, { propertyName: "footerTemplate", first: true, predicate: ["footer"], descendants: true }, { propertyName: "groupTemplate", first: true, predicate: ["group"], descendants: true }, { propertyName: "emptyTemplate", first: true, predicate: ["empty"], descendants: true }, { propertyName: "clearIconTemplate", first: true, predicate: ["clearIcon"], descendants: true }, { propertyName: "dropdownIconTemplate", first: true, predicate: ["dropdownIcon"], descendants: true }, { propertyName: "filterIconTemplate", first: true, predicate: ["filterIcon"], descendants: true }], viewQueries: [{ propertyName: "filterInputElement", first: true, predicate: ["filterInput"], descendants: true }, { propertyName: "triggerFilterInputElement", first: true, predicate: ["triggerFilterInput"], descendants: true }, { propertyName: "editableInputElement", first: true, predicate: ["editableInput"], descendants: true }, { propertyName: "dropdownMenuElement", first: true, predicate: ["dropdownMenu"], descendants: true }], ngImport: i0, template: "<div\n class=\"ngb-select-container position-relative\"\n [class.form-floating]=\"floatLabel()\"\n [class.float-variant-on]=\"floatLabel() && floatLabelVariant() === 'on'\"\n [class.float-variant-in]=\"floatLabel() && floatLabelVariant() === 'in'\"\n [class.float-variant-over]=\"floatLabel() && floatLabelVariant() === 'over'\"\n [class.floating-active]=\"hasSelectedValue() || overlayVisible()\"\n [class.dropup]=\"isDropup()\"\n [class.dropdown-up]=\"isDropup()\"\n [class.w-100]=\"fluid()\"\n [attr.dir]=\"dir() || null\"\n [ngStyle]=\"style()\"\n [ngClass]=\"styleClass()\"\n (keydown)=\"onKeydown($event)\"\n>\n <!-- Select Trigger Box -->\n <div\n class=\"form-select d-flex align-items-center justify-content-between\"\n [class.is-invalid]=\"invalid()\"\n [class.disabled]=\"disabled()\"\n [class.form-select-sm]=\"size() === 'small'\"\n [class.form-select-lg]=\"size() === 'large'\"\n [class.bg-light]=\"variant() === 'filled'\"\n [attr.id]=\"id()\"\n [attr.tabindex]=\"disabled() ? -1 : tabindex()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-expanded]=\"overlayVisible()\"\n [attr.aria-haspopup]=\"'listbox'\"\n role=\"combobox\"\n (click)=\"onTriggerClick($event)\"\n (focus)=\"onTriggerFocus($event)\"\n (blur)=\"onTriggerBlur($event)\"\n >\n <!-- Selected Value / Input / Chips Area -->\n <span class=\"text-truncate flex-grow-1 me-2 d-flex flex-wrap align-items-center gap-1\">\n <!-- Filter directly in Trigger Box -->\n @if (filterInTrigger()) {\n <!-- Chips in multiple mode when filterInTrigger is active -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n }\n <!-- Search Filter Input embedded inside the trigger -->\n <input\n #triggerFilterInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none flex-grow-1\"\n style=\"min-width: 80px\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [value]=\"effectiveFilterValue()\"\n [placeholder]=\"\n multiple() && hasSelectedValue()\n ? ''\n : hasSelectedValue() && !overlayVisible()\n ? displayLabel()\n : effectiveSearchPlaceholder()\n \"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n (focus)=\"openOverlay($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Editable Input (Single mode only) -->\n @if (editable() && !multiple()) {\n <input\n #editableInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [attr.maxlength]=\"maxLength()\"\n [value]=\"displayLabel()\"\n [placeholder]=\"placeholder() || ''\"\n (input)=\"onEditableInput($event)\"\n (focus)=\"onEditableFocus($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Multi-Select Chips Display Mode -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n } @else {\n @if (hasSelectedValue()) {\n @if (selectedItemTemplate || labelTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n selectedItemTemplate || labelTemplate;\n context: { $implicit: findOptionByValue(value()) ?? value(), value: value() }\n \"\n ></ng-container>\n } @else {\n <span>{{ displayLabel() }}</span>\n }\n } @else {\n <span class=\"text-muted\">{{ floatLabel() ? '' : placeholder() || '' }}</span>\n }\n }\n <!-- Standard Single or Comma Multi-Select Text -->\n }\n }\n </span>\n\n <!-- Icons & Spinners Area -->\n <div class=\"d-flex align-items-center flex-shrink-0 gap-1 ms-auto\">\n <!-- Clear Icon -->\n @if (showClear() && hasSelectedValue() && !disabled() && !readonly()) {\n <span\n class=\"ngb-select-clear-icon text-muted me-1\"\n (click)=\"onClearClick($event)\"\n title=\"Clear\"\n tabindex=\"0\"\n role=\"button\"\n aria-label=\"Clear value\"\n >\n @if (clearIconTemplate) {\n <ng-container *ngTemplateOutlet=\"clearIconTemplate\"></ng-container>\n } @else {\n <i class=\"bi bi-x-circle-fill\"></i>\n }\n </span>\n }\n\n <!-- Loading Spinner -->\n @if (loading()) {\n <div class=\"spinner-border spinner-border-sm text-secondary\" role=\"status\">\n <span class=\"visually-hidden\">Loading...</span>\n </div>\n }\n\n <!-- Dropdown Caret Icon -->\n @if (!loading()) {\n <span class=\"ngb-select-dropdown-icon text-secondary\">\n @if (dropdownIconTemplate) {\n <ng-container *ngTemplateOutlet=\"dropdownIconTemplate\"></ng-container>\n } @else {\n <i class=\"bi bi-chevron-down\" [class.rotate-180]=\"overlayVisible()\"></i>\n }\n </span>\n }\n </div>\n </div>\n\n <!-- Float Label Support -->\n @if (floatLabel() && placeholder()) {\n <label [attr.for]=\"id()\">{{ placeholder() }}</label>\n }\n\n <ng-template #dropdownContent>\n <!-- Header Template -->\n @if (headerTemplate) {\n <div class=\"p-2 border-bottom\">\n <ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container>\n </div>\n }\n\n <!-- Header: Select All Checkbox & Search / Filter Box -->\n @if ((filter() && !filterInTrigger()) || (multiple() && showSelectAll())) {\n <div class=\"p-2 border-bottom bg-light bg-opacity-50\">\n <!-- Select All Checkbox -->\n @if (multiple() && showSelectAll()) {\n <div class=\"d-flex align-items-center mb-2 px-1\">\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0 cursor-pointer\"\n [checked]=\"selectAll()\"\n (change)=\"toggleSelectAll($event)\"\n id=\"selectAllCheckbox\"\n />\n <label\n class=\"form-check-label small fw-semibold cursor-pointer user-select-none\"\n for=\"selectAllCheckbox\"\n >\n @if (headerCheckboxTemplate) {\n <ng-container\n *ngTemplateOutlet=\"headerCheckboxTemplate; context: { $implicit: selectAll() }\"\n ></ng-container>\n } @else {\n Select All\n }\n </label>\n </div>\n }\n <!-- Search Box -->\n @if (filter() && !filterInTrigger()) {\n <div class=\"input-group input-group-sm\">\n <span class=\"input-group-text bg-transparent border-end-0\">\n @if (filterIconTemplate) {\n <ng-container *ngTemplateOutlet=\"filterIconTemplate\"></ng-container>\n } @else {\n <i class=\"bi bi-search text-muted\"></i>\n }\n </span>\n <input\n #filterInput\n type=\"text\"\n class=\"form-control border-start-0\"\n [placeholder]=\"effectiveSearchPlaceholder()\"\n [value]=\"filterValue()\"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n />\n </div>\n }\n </div>\n }\n\n <!-- Grouped Options Mode -->\n @if (group()) {\n @for (\n groupOption of filteredOptions();\n track resolveOptionGroupLabel(groupOption) || $index\n ) {\n <div>\n <!-- Group Header -->\n <h6\n class=\"dropdown-header text-muted py-2 px-3 m-0 bg-light bg-opacity-75 d-flex align-items-center\"\n >\n @if (groupTemplate) {\n <ng-container\n *ngTemplateOutlet=\"groupTemplate; context: { $implicit: groupOption }\"\n ></ng-container>\n } @else {\n {{ resolveOptionGroupLabel(groupOption) }}\n }\n </h6>\n <!-- Group Items -->\n @for (\n option of resolveOptionGroupChildren(groupOption);\n track resolveOptionTrackKey(option, $index)\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n </div>\n }\n } @else {\n @for (\n option of filteredOptions();\n track resolveOptionTrackKey(option, $index);\n let i = $index\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n }\n\n <!-- Empty State Message -->\n @if (isOptionsEmpty()) {\n <div class=\"dropdown-item text-muted text-center py-3\">\n @if (emptyTemplate) {\n <ng-container *ngTemplateOutlet=\"emptyTemplate\"></ng-container>\n } @else {\n <small>{{\n filterValue()\n ? emptyFilterMessage() || 'No results found'\n : emptyMessage() || 'No results found'\n }}</small>\n }\n </div>\n }\n </ng-template>\n\n @if (isModalMode()) {\n <!-- Bootstrap Modal Overlay -->\n @if (overlayVisible()) {\n <div\n class=\"modal fade show d-block\"\n tabindex=\"-1\"\n role=\"dialog\"\n aria-modal=\"true\"\n style=\"background-color: rgba(0, 0, 0, 0.45); z-index: 1075\"\n (click)=\"closeOverlay($event)\"\n >\n <div\n class=\"modal-dialog modal-dialog-centered modal-dialog-scrollable\"\n role=\"document\"\n (click)=\"$event.stopPropagation()\"\n >\n <div class=\"modal-content shadow\" [ngClass]=\"panelStyleClass()\" [ngStyle]=\"panelStyle()\">\n <!-- Modal Header -->\n <div class=\"modal-header bg-light bg-opacity-50 py-2 px-3\">\n <h6 class=\"modal-title m-0 fw-semibold text-truncate\">{{ effectivePopupTitle() }}</h6>\n <button\n type=\"button\"\n class=\"btn-close\"\n aria-label=\"Close\"\n (click)=\"closeOverlay($event)\"\n ></button>\n </div>\n\n <!-- Modal Body (Options Content) -->\n <div\n class=\"modal-body p-0\"\n #dropdownMenu\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n </div>\n\n <!-- Modal Footer (Custom Template or Done Button) -->\n @if (footerTemplate || multiple()) {\n <div\n class=\"modal-footer p-2 bg-light bg-opacity-50 d-flex align-items-center justify-content-end\"\n >\n @if (footerTemplate) {\n <div class=\"w-100\">\n <ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container>\n </div>\n } @else {\n <button\n type=\"button\"\n class=\"btn btn-sm btn-primary px-3\"\n (click)=\"closeOverlay($event)\"\n >\n Done\n </button>\n }\n </div>\n }\n </div>\n </div>\n </div>\n }\n } @else {\n <!-- Standard Dropdown Menu -->\n <div\n #dropdownMenu\n class=\"dropdown-menu shadow-sm p-0\"\n [class.show]=\"overlayVisible()\"\n [ngStyle]=\"panelStyle()\"\n [ngClass]=\"panelStyleClass()\"\n [style.max-height]=\"scrollHeight()\"\n style=\"overflow-y: auto\"\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n (click)=\"$event.stopPropagation()\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n\n <!-- Footer Template -->\n @if (footerTemplate) {\n <div class=\"p-2 border-top\">\n <ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container>\n </div>\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}:host.inline{display:inline-block;width:auto}.ngb-select-container{position:relative;-webkit-user-select:none;user-select:none;width:100%}.ngb-select-container .form-select{cursor:pointer;min-height:38px;background-image:none;padding-right:.75rem;padding-left:.75rem}.ngb-select-container .form-select.form-select-sm{min-height:31px;padding-right:.5rem;padding-left:.5rem}.ngb-select-container .form-select.form-select-lg{min-height:48px;padding-right:1rem;padding-left:1rem}.ngb-select-container .form-select.disabled,.ngb-select-container .form-select:disabled{cursor:not-allowed;background-color:var(--bs-secondary-bg);opacity:.65}.ngb-select-container.form-floating{display:block;width:100%;position:relative}.ngb-select-container.form-floating.float-variant-on,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over){margin-top:.35rem}.ngb-select-container.form-floating.float-variant-on .form-select,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-sm,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-sm{min-height:31px;padding-top:.25rem;padding-bottom:.25rem}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-lg,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-lg{min-height:48px;padding-top:.5rem;padding-bottom:.5rem}.ngb-select-container.form-floating.float-variant-on>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over)>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0 .35rem;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;border-radius:var(--bs-border-radius);background-color:transparent;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out,background-color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-on.floating-active>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over).floating-active>label{top:0;transform:translateY(-50%) scale(.85);background-color:var(--bs-body-bg);color:var(--bs-primary);font-weight:600}.ngb-select-container.form-floating.float-variant-in .form-select{height:calc(3.5rem + 2px);min-height:calc(3.5rem + 2px);padding:1.625rem .75rem .5rem;align-items:flex-end}.ngb-select-container.form-floating.float-variant-in>label{position:absolute;top:0;left:0;z-index:2;height:100%;padding:1rem .75rem;overflow:hidden;text-align:start;text-overflow:ellipsis;white-space:nowrap;pointer-events:none;border:var(--bs-border-width) solid transparent;transform-origin:0 0;transition:opacity .15s ease-in-out,transform .15s ease-in-out,color .15s ease-in-out;color:rgba(var(--bs-body-color-rgb),.65);transform:scale(1) translateY(0)}.ngb-select-container.form-floating.float-variant-in.floating-active>label{transform:scale(.85) translateY(-.65rem) translate(.15rem);color:var(--bs-primary);font-weight:500}.ngb-select-container.form-floating.float-variant-over{margin-top:1.25rem}.ngb-select-container.form-floating.float-variant-over .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-sm{min-height:31px}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-lg{min-height:48px}.ngb-select-container.form-floating.float-variant-over>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-over.floating-active>label{top:-.75rem;transform:scale(.85);color:var(--bs-primary);font-weight:600}.ngb-select-container .ngb-select-clear-icon,.ngb-select-container .ngb-select-dropdown-icon{cursor:pointer;display:inline-flex;align-items:center;justify-content:center;line-height:1;font-size:.875rem}.ngb-select-container .ngb-select-clear-icon i,.ngb-select-container .ngb-select-dropdown-icon i{transition:transform .2s ease-in-out}.ngb-select-container .ngb-select-clear-icon i.rotate-180,.ngb-select-container .ngb-select-dropdown-icon i.rotate-180{transform:rotate(180deg)}.ngb-select-container .ngb-select-clear-icon{opacity:.6;transition:opacity .15s ease}.ngb-select-container .ngb-select-clear-icon:hover{opacity:1}.ngb-select-container.dropup .dropdown-menu,.ngb-select-container.dropdown-up .dropdown-menu{top:auto;bottom:100%;margin-top:0;margin-bottom:.125rem}.dropdown-menu{top:100%;left:0;width:100%;min-width:100%;margin-top:.125rem;z-index:1060;box-sizing:border-box;text-align:inherit}.dropdown-menu .dropdown-item{cursor:pointer;white-space:normal;word-break:break-word;text-align:inherit}.dropdown-menu .dropdown-item.disabled,.dropdown-menu .dropdown-item:disabled{cursor:not-allowed;opacity:.5}.dropdown-menu .dropdown-item.focus,.dropdown-menu .dropdown-item.focused,.dropdown-menu .dropdown-item:focus{color:var(--bs-dropdown-link-hover-color, inherit);background-color:var(--bs-dropdown-link-hover-bg, var(--bs-tertiary-bg))!important}.dropdown-menu .dropdown-item.active{color:var(--bs-dropdown-link-active-color)!important;background-color:var(--bs-dropdown-link-active-bg)!important}.dropdown-menu .dropdown-header{font-weight:600;text-transform:uppercase;font-size:.75rem;letter-spacing:.05em;text-align:inherit}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: FormsModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
985
|
+
], queries: [{ propertyName: "itemTemplate", first: true, predicate: ["item"], descendants: true, isSignal: true }, { propertyName: "selectedItemTemplate", first: true, predicate: ["selectedItem"], descendants: true, isSignal: true }, { propertyName: "labelTemplate", first: true, predicate: ["label"], descendants: true, isSignal: true }, { propertyName: "chipTemplate", first: true, predicate: ["chip"], descendants: true, isSignal: true }, { propertyName: "headerCheckboxTemplate", first: true, predicate: ["headerCheckbox"], descendants: true, isSignal: true }, { propertyName: "headerTemplate", first: true, predicate: ["header"], descendants: true, isSignal: true }, { propertyName: "footerTemplate", first: true, predicate: ["footer"], descendants: true, isSignal: true }, { propertyName: "groupTemplate", first: true, predicate: ["group"], descendants: true, isSignal: true }, { propertyName: "emptyTemplate", first: true, predicate: ["empty"], descendants: true, isSignal: true }, { propertyName: "clearIconTemplate", first: true, predicate: ["clearIcon"], descendants: true, isSignal: true }, { propertyName: "dropdownIconTemplate", first: true, predicate: ["dropdownIcon"], descendants: true, isSignal: true }, { propertyName: "filterIconTemplate", first: true, predicate: ["filterIcon"], descendants: true, isSignal: true }], viewQueries: [{ propertyName: "filterInputElement", first: true, predicate: ["filterInput"], descendants: true, isSignal: true }, { propertyName: "triggerFilterInputElement", first: true, predicate: ["triggerFilterInput"], descendants: true, isSignal: true }, { propertyName: "editableInputElement", first: true, predicate: ["editableInput"], descendants: true, isSignal: true }, { propertyName: "dropdownMenuElement", first: true, predicate: ["dropdownMenu"], descendants: true, isSignal: true }], ngImport: i0, template: "<div\n class=\"ngb-select-container position-relative\"\n [class.form-floating]=\"floatLabel()\"\n [class.float-variant-on]=\"floatLabel() && floatLabelVariant() === 'on'\"\n [class.float-variant-in]=\"floatLabel() && floatLabelVariant() === 'in'\"\n [class.float-variant-over]=\"floatLabel() && floatLabelVariant() === 'over'\"\n [class.floating-active]=\"hasSelectedValue() || overlayVisible()\"\n [class.dropup]=\"isDropup()\"\n [class.dropdown-up]=\"isDropup()\"\n [class.w-100]=\"fluid()\"\n [attr.dir]=\"dir() || null\"\n [ngStyle]=\"style()\"\n [ngClass]=\"styleClass()\"\n (keydown)=\"onKeydown($event)\"\n>\n <!-- Select Trigger Box -->\n <div\n class=\"form-select d-flex align-items-center justify-content-between\"\n [class.is-invalid]=\"invalid()\"\n [class.disabled]=\"disabled()\"\n [class.form-select-sm]=\"size() === 'small'\"\n [class.form-select-lg]=\"size() === 'large'\"\n [class.bg-light]=\"variant() === 'filled'\"\n [attr.id]=\"id()\"\n [attr.tabindex]=\"disabled() ? -1 : tabindex()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-expanded]=\"overlayVisible()\"\n [attr.aria-haspopup]=\"'listbox'\"\n role=\"combobox\"\n (click)=\"onTriggerClick($event)\"\n (focus)=\"onTriggerFocus($event)\"\n (blur)=\"onTriggerBlur($event)\"\n >\n <!-- Selected Value / Input / Chips Area -->\n <span class=\"text-truncate flex-grow-1 me-2 d-flex flex-wrap align-items-center gap-1\">\n <!-- Filter directly in Trigger Box -->\n @if (filterInTrigger()) {\n <!-- Chips in multiple mode when filterInTrigger is active -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate()!;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n }\n <!-- Search Filter Input embedded inside the trigger -->\n <input\n #triggerFilterInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none flex-grow-1\"\n style=\"min-width: 80px\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [value]=\"effectiveFilterValue()\"\n [placeholder]=\"\n multiple() && hasSelectedValue()\n ? ''\n : hasSelectedValue() && !overlayVisible()\n ? displayLabel()\n : effectiveSearchPlaceholder()\n \"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n (focus)=\"openOverlay($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Editable Input (Single mode only) -->\n @if (editable() && !multiple()) {\n <input\n #editableInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [attr.maxlength]=\"maxLength()\"\n [value]=\"displayLabel()\"\n [placeholder]=\"placeholder() || ''\"\n (input)=\"onEditableInput($event)\"\n (focus)=\"onEditableFocus($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Multi-Select Chips Display Mode -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate()!;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n } @else {\n @if (hasSelectedValue()) {\n @if (selectedItemTemplate() || labelTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n selectedItemTemplate() || labelTemplate()!;\n context: { $implicit: findOptionByValue(value()) ?? value(), value: value() }\n \"\n ></ng-container>\n } @else {\n <span>{{ displayLabel() }}</span>\n }\n } @else {\n <span class=\"text-muted\">{{ floatLabel() ? '' : placeholder() || '' }}</span>\n }\n }\n <!-- Standard Single or Comma Multi-Select Text -->\n }\n }\n </span>\n\n <!-- Icons & Spinners Area -->\n <div class=\"d-flex align-items-center flex-shrink-0 gap-1 ms-auto\">\n <!-- Clear Icon -->\n @if (showClear() && hasSelectedValue() && !disabled() && !readonly()) {\n <span\n class=\"ngb-select-clear-icon text-muted me-1\"\n (click)=\"onClearClick($event)\"\n title=\"Clear\"\n tabindex=\"0\"\n role=\"button\"\n aria-label=\"Clear value\"\n >\n @if (clearIconTemplate()) {\n <ng-container *ngTemplateOutlet=\"clearIconTemplate()!\"></ng-container>\n } @else {\n <i class=\"bi bi-x-circle-fill\"></i>\n }\n </span>\n }\n\n <!-- Loading Spinner -->\n @if (loading()) {\n <div class=\"spinner-border spinner-border-sm text-secondary\" role=\"status\">\n <span class=\"visually-hidden\">Loading...</span>\n </div>\n }\n\n <!-- Dropdown Caret Icon -->\n @if (!loading()) {\n <span class=\"ngb-select-dropdown-icon text-secondary\">\n @if (dropdownIconTemplate()) {\n <ng-container *ngTemplateOutlet=\"dropdownIconTemplate()!\"></ng-container>\n } @else {\n <i class=\"bi bi-chevron-down\" [class.rotate-180]=\"overlayVisible()\"></i>\n }\n </span>\n }\n </div>\n </div>\n\n <!-- Float Label Support -->\n @if (floatLabel() && placeholder()) {\n <label [attr.for]=\"id()\">{{ placeholder() }}</label>\n }\n\n <ng-template #dropdownContent>\n <!-- Header Template -->\n @if (headerTemplate()) {\n <div class=\"p-2 border-bottom\">\n <ng-container *ngTemplateOutlet=\"headerTemplate()!\"></ng-container>\n </div>\n }\n\n <!-- Header: Select All Checkbox & Search / Filter Box -->\n @if ((filter() && !filterInTrigger()) || (multiple() && showSelectAll())) {\n <div class=\"p-2 border-bottom bg-light bg-opacity-50\">\n <!-- Select All Checkbox -->\n @if (multiple() && showSelectAll()) {\n <div class=\"d-flex align-items-center mb-2 px-1\">\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0 cursor-pointer\"\n [checked]=\"selectAll()\"\n (change)=\"toggleSelectAll($event)\"\n id=\"selectAllCheckbox\"\n />\n <label\n class=\"form-check-label small fw-semibold cursor-pointer user-select-none\"\n for=\"selectAllCheckbox\"\n >\n @if (headerCheckboxTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"headerCheckboxTemplate()!; context: { $implicit: selectAll() }\"\n ></ng-container>\n } @else {\n Select All\n }\n </label>\n </div>\n }\n <!-- Search Box -->\n @if (filter() && !filterInTrigger()) {\n <div class=\"input-group input-group-sm\">\n <span class=\"input-group-text bg-transparent border-end-0\">\n @if (filterIconTemplate()) {\n <ng-container *ngTemplateOutlet=\"filterIconTemplate()!\"></ng-container>\n } @else {\n <i class=\"bi bi-search text-muted\"></i>\n }\n </span>\n <input\n #filterInput\n type=\"text\"\n class=\"form-control border-start-0\"\n [placeholder]=\"effectiveSearchPlaceholder()\"\n [value]=\"filterValue()\"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n />\n </div>\n }\n </div>\n }\n\n <!-- Grouped Options Mode -->\n @if (group()) {\n @for (\n groupOption of filteredOptions();\n track resolveOptionGroupLabel(groupOption) || $index\n ) {\n <div>\n <!-- Group Header -->\n <h6\n class=\"dropdown-header text-muted py-2 px-3 m-0 bg-light bg-opacity-75 d-flex align-items-center\"\n >\n @if (groupTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"groupTemplate()!; context: { $implicit: groupOption }\"\n ></ng-container>\n } @else {\n {{ resolveOptionGroupLabel(groupOption) }}\n }\n </h6>\n <!-- Group Items -->\n @for (\n option of resolveOptionGroupChildren(groupOption);\n track resolveOptionTrackKey(option, $index)\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate()!; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n </div>\n }\n } @else {\n @for (\n option of filteredOptions();\n track resolveOptionTrackKey(option, $index);\n let i = $index\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate()!; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n }\n\n <!-- Empty State Message -->\n @if (isOptionsEmpty()) {\n <div class=\"dropdown-item text-muted text-center py-3\">\n @if (emptyTemplate()) {\n <ng-container *ngTemplateOutlet=\"emptyTemplate()!\"></ng-container>\n } @else {\n <small>{{\n filterValue()\n ? emptyFilterMessage() || 'No results found'\n : emptyMessage() || 'No results found'\n }}</small>\n }\n </div>\n }\n </ng-template>\n\n @if (isModalMode()) {\n <!-- Bootstrap Modal Overlay -->\n @if (overlayVisible()) {\n <div\n class=\"modal fade show d-block\"\n tabindex=\"-1\"\n role=\"dialog\"\n aria-modal=\"true\"\n style=\"background-color: rgba(0, 0, 0, 0.45); z-index: 1075\"\n (click)=\"closeOverlay($event)\"\n >\n <div\n class=\"modal-dialog modal-dialog-centered modal-dialog-scrollable\"\n role=\"document\"\n (click)=\"$event.stopPropagation()\"\n >\n <div class=\"modal-content shadow\" [ngClass]=\"panelStyleClass()\" [ngStyle]=\"panelStyle()\">\n <!-- Modal Header -->\n <div class=\"modal-header bg-light bg-opacity-50 py-2 px-3\">\n <h6 class=\"modal-title m-0 fw-semibold text-truncate\">{{ effectivePopupTitle() }}</h6>\n <button\n type=\"button\"\n class=\"btn-close\"\n aria-label=\"Close\"\n (click)=\"closeOverlay($event)\"\n ></button>\n </div>\n\n <!-- Modal Body (Options Content) -->\n <div\n class=\"modal-body p-0\"\n #dropdownMenu\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n </div>\n\n <!-- Modal Footer (Custom Template or Done Button) -->\n @if (footerTemplate() || multiple()) {\n <div\n class=\"modal-footer p-2 bg-light bg-opacity-50 d-flex align-items-center justify-content-end\"\n >\n @if (footerTemplate()) {\n <div class=\"w-100\">\n <ng-container *ngTemplateOutlet=\"footerTemplate()!\"></ng-container>\n </div>\n } @else {\n <button\n type=\"button\"\n class=\"btn btn-sm btn-primary px-3\"\n (click)=\"closeOverlay($event)\"\n >\n Done\n </button>\n }\n </div>\n }\n </div>\n </div>\n </div>\n }\n } @else {\n <!-- Standard Dropdown Menu -->\n <div\n #dropdownMenu\n class=\"dropdown-menu shadow-sm p-0\"\n [class.show]=\"overlayVisible()\"\n [ngStyle]=\"panelStyle()\"\n [ngClass]=\"panelStyleClass()\"\n [style.max-height]=\"scrollHeight()\"\n style=\"overflow-y: auto\"\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n (click)=\"$event.stopPropagation()\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n\n <!-- Footer Template -->\n @if (footerTemplate()) {\n <div class=\"p-2 border-top\">\n <ng-container *ngTemplateOutlet=\"footerTemplate()!\"></ng-container>\n </div>\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}:host.inline{display:inline-block;width:auto}.ngb-select-container{position:relative;-webkit-user-select:none;user-select:none;width:100%}.ngb-select-container .form-select{cursor:pointer;min-height:38px;background-image:none;padding-right:.75rem;padding-left:.75rem}.ngb-select-container .form-select.form-select-sm{min-height:31px;padding-right:.5rem;padding-left:.5rem}.ngb-select-container .form-select.form-select-lg{min-height:48px;padding-right:1rem;padding-left:1rem}.ngb-select-container .form-select.disabled,.ngb-select-container .form-select:disabled{cursor:not-allowed;background-color:var(--bs-secondary-bg);opacity:.65}.ngb-select-container.form-floating{display:block;width:100%;position:relative}.ngb-select-container.form-floating.float-variant-on,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over){margin-top:.35rem}.ngb-select-container.form-floating.float-variant-on .form-select,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-sm,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-sm{min-height:31px;padding-top:.25rem;padding-bottom:.25rem}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-lg,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-lg{min-height:48px;padding-top:.5rem;padding-bottom:.5rem}.ngb-select-container.form-floating.float-variant-on>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over)>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0 .35rem;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;border-radius:var(--bs-border-radius);background-color:transparent;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out,background-color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-on.floating-active>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over).floating-active>label{top:0;transform:translateY(-50%) scale(.85);background-color:var(--bs-body-bg);color:var(--bs-primary);font-weight:600}.ngb-select-container.form-floating.float-variant-in .form-select{height:calc(3.5rem + 2px);min-height:calc(3.5rem + 2px);padding:1.625rem .75rem .5rem;align-items:flex-end}.ngb-select-container.form-floating.float-variant-in>label{position:absolute;top:0;left:0;z-index:2;height:100%;padding:1rem .75rem;overflow:hidden;text-align:start;text-overflow:ellipsis;white-space:nowrap;pointer-events:none;border:var(--bs-border-width) solid transparent;transform-origin:0 0;transition:opacity .15s ease-in-out,transform .15s ease-in-out,color .15s ease-in-out;color:rgba(var(--bs-body-color-rgb),.65);transform:scale(1) translateY(0)}.ngb-select-container.form-floating.float-variant-in.floating-active>label{transform:scale(.85) translateY(-.65rem) translate(.15rem);color:var(--bs-primary);font-weight:500}.ngb-select-container.form-floating.float-variant-over{margin-top:1.25rem}.ngb-select-container.form-floating.float-variant-over .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-sm{min-height:31px}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-lg{min-height:48px}.ngb-select-container.form-floating.float-variant-over>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-over.floating-active>label{top:-.75rem;transform:scale(.85);color:var(--bs-primary);font-weight:600}.ngb-select-container .ngb-select-clear-icon,.ngb-select-container .ngb-select-dropdown-icon{cursor:pointer;display:inline-flex;align-items:center;justify-content:center;line-height:1;font-size:.875rem}.ngb-select-container .ngb-select-clear-icon i,.ngb-select-container .ngb-select-dropdown-icon i{transition:transform .2s ease-in-out}.ngb-select-container .ngb-select-clear-icon i.rotate-180,.ngb-select-container .ngb-select-dropdown-icon i.rotate-180{transform:rotate(180deg)}.ngb-select-container .ngb-select-clear-icon{opacity:.6;transition:opacity .15s ease}.ngb-select-container .ngb-select-clear-icon:hover{opacity:1}.ngb-select-container.dropup .dropdown-menu,.ngb-select-container.dropdown-up .dropdown-menu{top:auto;bottom:100%;margin-top:0;margin-bottom:.125rem}.dropdown-menu{top:100%;left:0;width:100%;min-width:100%;margin-top:.125rem;z-index:1060;box-sizing:border-box;text-align:inherit}.dropdown-menu .dropdown-item{cursor:pointer;white-space:normal;word-break:break-word;text-align:inherit}.dropdown-menu .dropdown-item.disabled,.dropdown-menu .dropdown-item:disabled{cursor:not-allowed;opacity:.5}.dropdown-menu .dropdown-item.focus,.dropdown-menu .dropdown-item.focused,.dropdown-menu .dropdown-item:focus{color:var(--bs-dropdown-link-hover-color, inherit);background-color:var(--bs-dropdown-link-hover-bg, var(--bs-tertiary-bg))!important}.dropdown-menu .dropdown-item.active{color:var(--bs-dropdown-link-active-color)!important;background-color:var(--bs-dropdown-link-active-bg)!important}.dropdown-menu .dropdown-header{font-weight:600;text-transform:uppercase;font-size:.75rem;letter-spacing:.05em;text-align:inherit}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: FormsModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
984
986
|
}
|
|
985
987
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: NgbSelectComponent, decorators: [{
|
|
986
988
|
type: Component,
|
|
@@ -990,56 +992,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.21", ngImpo
|
|
|
990
992
|
useExisting: forwardRef(() => NgbSelectComponent),
|
|
991
993
|
multi: true,
|
|
992
994
|
},
|
|
993
|
-
], template: "<div\n class=\"ngb-select-container position-relative\"\n [class.form-floating]=\"floatLabel()\"\n [class.float-variant-on]=\"floatLabel() && floatLabelVariant() === 'on'\"\n [class.float-variant-in]=\"floatLabel() && floatLabelVariant() === 'in'\"\n [class.float-variant-over]=\"floatLabel() && floatLabelVariant() === 'over'\"\n [class.floating-active]=\"hasSelectedValue() || overlayVisible()\"\n [class.dropup]=\"isDropup()\"\n [class.dropdown-up]=\"isDropup()\"\n [class.w-100]=\"fluid()\"\n [attr.dir]=\"dir() || null\"\n [ngStyle]=\"style()\"\n [ngClass]=\"styleClass()\"\n (keydown)=\"onKeydown($event)\"\n>\n <!-- Select Trigger Box -->\n <div\n class=\"form-select d-flex align-items-center justify-content-between\"\n [class.is-invalid]=\"invalid()\"\n [class.disabled]=\"disabled()\"\n [class.form-select-sm]=\"size() === 'small'\"\n [class.form-select-lg]=\"size() === 'large'\"\n [class.bg-light]=\"variant() === 'filled'\"\n [attr.id]=\"id()\"\n [attr.tabindex]=\"disabled() ? -1 : tabindex()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-expanded]=\"overlayVisible()\"\n [attr.aria-haspopup]=\"'listbox'\"\n role=\"combobox\"\n (click)=\"onTriggerClick($event)\"\n (focus)=\"onTriggerFocus($event)\"\n (blur)=\"onTriggerBlur($event)\"\n >\n <!-- Selected Value / Input / Chips Area -->\n <span class=\"text-truncate flex-grow-1 me-2 d-flex flex-wrap align-items-center gap-1\">\n <!-- Filter directly in Trigger Box -->\n @if (filterInTrigger()) {\n <!-- Chips in multiple mode when filterInTrigger is active -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n }\n <!-- Search Filter Input embedded inside the trigger -->\n <input\n #triggerFilterInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none flex-grow-1\"\n style=\"min-width: 80px\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [value]=\"effectiveFilterValue()\"\n [placeholder]=\"\n multiple() && hasSelectedValue()\n ? ''\n : hasSelectedValue() && !overlayVisible()\n ? displayLabel()\n : effectiveSearchPlaceholder()\n \"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n (focus)=\"openOverlay($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Editable Input (Single mode only) -->\n @if (editable() && !multiple()) {\n <input\n #editableInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [attr.maxlength]=\"maxLength()\"\n [value]=\"displayLabel()\"\n [placeholder]=\"placeholder() || ''\"\n (input)=\"onEditableInput($event)\"\n (focus)=\"onEditableFocus($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Multi-Select Chips Display Mode -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n } @else {\n @if (hasSelectedValue()) {\n @if (selectedItemTemplate || labelTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n selectedItemTemplate || labelTemplate;\n context: { $implicit: findOptionByValue(value()) ?? value(), value: value() }\n \"\n ></ng-container>\n } @else {\n <span>{{ displayLabel() }}</span>\n }\n } @else {\n <span class=\"text-muted\">{{ floatLabel() ? '' : placeholder() || '' }}</span>\n }\n }\n <!-- Standard Single or Comma Multi-Select Text -->\n }\n }\n </span>\n\n <!-- Icons & Spinners Area -->\n <div class=\"d-flex align-items-center flex-shrink-0 gap-1 ms-auto\">\n <!-- Clear Icon -->\n @if (showClear() && hasSelectedValue() && !disabled() && !readonly()) {\n <span\n class=\"ngb-select-clear-icon text-muted me-1\"\n (click)=\"onClearClick($event)\"\n title=\"Clear\"\n tabindex=\"0\"\n role=\"button\"\n aria-label=\"Clear value\"\n >\n @if (clearIconTemplate) {\n <ng-container *ngTemplateOutlet=\"clearIconTemplate\"></ng-container>\n } @else {\n <i class=\"bi bi-x-circle-fill\"></i>\n }\n </span>\n }\n\n <!-- Loading Spinner -->\n @if (loading()) {\n <div class=\"spinner-border spinner-border-sm text-secondary\" role=\"status\">\n <span class=\"visually-hidden\">Loading...</span>\n </div>\n }\n\n <!-- Dropdown Caret Icon -->\n @if (!loading()) {\n <span class=\"ngb-select-dropdown-icon text-secondary\">\n @if (dropdownIconTemplate) {\n <ng-container *ngTemplateOutlet=\"dropdownIconTemplate\"></ng-container>\n } @else {\n <i class=\"bi bi-chevron-down\" [class.rotate-180]=\"overlayVisible()\"></i>\n }\n </span>\n }\n </div>\n </div>\n\n <!-- Float Label Support -->\n @if (floatLabel() && placeholder()) {\n <label [attr.for]=\"id()\">{{ placeholder() }}</label>\n }\n\n <ng-template #dropdownContent>\n <!-- Header Template -->\n @if (headerTemplate) {\n <div class=\"p-2 border-bottom\">\n <ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container>\n </div>\n }\n\n <!-- Header: Select All Checkbox & Search / Filter Box -->\n @if ((filter() && !filterInTrigger()) || (multiple() && showSelectAll())) {\n <div class=\"p-2 border-bottom bg-light bg-opacity-50\">\n <!-- Select All Checkbox -->\n @if (multiple() && showSelectAll()) {\n <div class=\"d-flex align-items-center mb-2 px-1\">\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0 cursor-pointer\"\n [checked]=\"selectAll()\"\n (change)=\"toggleSelectAll($event)\"\n id=\"selectAllCheckbox\"\n />\n <label\n class=\"form-check-label small fw-semibold cursor-pointer user-select-none\"\n for=\"selectAllCheckbox\"\n >\n @if (headerCheckboxTemplate) {\n <ng-container\n *ngTemplateOutlet=\"headerCheckboxTemplate; context: { $implicit: selectAll() }\"\n ></ng-container>\n } @else {\n Select All\n }\n </label>\n </div>\n }\n <!-- Search Box -->\n @if (filter() && !filterInTrigger()) {\n <div class=\"input-group input-group-sm\">\n <span class=\"input-group-text bg-transparent border-end-0\">\n @if (filterIconTemplate) {\n <ng-container *ngTemplateOutlet=\"filterIconTemplate\"></ng-container>\n } @else {\n <i class=\"bi bi-search text-muted\"></i>\n }\n </span>\n <input\n #filterInput\n type=\"text\"\n class=\"form-control border-start-0\"\n [placeholder]=\"effectiveSearchPlaceholder()\"\n [value]=\"filterValue()\"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n />\n </div>\n }\n </div>\n }\n\n <!-- Grouped Options Mode -->\n @if (group()) {\n @for (\n groupOption of filteredOptions();\n track resolveOptionGroupLabel(groupOption) || $index\n ) {\n <div>\n <!-- Group Header -->\n <h6\n class=\"dropdown-header text-muted py-2 px-3 m-0 bg-light bg-opacity-75 d-flex align-items-center\"\n >\n @if (groupTemplate) {\n <ng-container\n *ngTemplateOutlet=\"groupTemplate; context: { $implicit: groupOption }\"\n ></ng-container>\n } @else {\n {{ resolveOptionGroupLabel(groupOption) }}\n }\n </h6>\n <!-- Group Items -->\n @for (\n option of resolveOptionGroupChildren(groupOption);\n track resolveOptionTrackKey(option, $index)\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n </div>\n }\n } @else {\n @for (\n option of filteredOptions();\n track resolveOptionTrackKey(option, $index);\n let i = $index\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n }\n\n <!-- Empty State Message -->\n @if (isOptionsEmpty()) {\n <div class=\"dropdown-item text-muted text-center py-3\">\n @if (emptyTemplate) {\n <ng-container *ngTemplateOutlet=\"emptyTemplate\"></ng-container>\n } @else {\n <small>{{\n filterValue()\n ? emptyFilterMessage() || 'No results found'\n : emptyMessage() || 'No results found'\n }}</small>\n }\n </div>\n }\n </ng-template>\n\n @if (isModalMode()) {\n <!-- Bootstrap Modal Overlay -->\n @if (overlayVisible()) {\n <div\n class=\"modal fade show d-block\"\n tabindex=\"-1\"\n role=\"dialog\"\n aria-modal=\"true\"\n style=\"background-color: rgba(0, 0, 0, 0.45); z-index: 1075\"\n (click)=\"closeOverlay($event)\"\n >\n <div\n class=\"modal-dialog modal-dialog-centered modal-dialog-scrollable\"\n role=\"document\"\n (click)=\"$event.stopPropagation()\"\n >\n <div class=\"modal-content shadow\" [ngClass]=\"panelStyleClass()\" [ngStyle]=\"panelStyle()\">\n <!-- Modal Header -->\n <div class=\"modal-header bg-light bg-opacity-50 py-2 px-3\">\n <h6 class=\"modal-title m-0 fw-semibold text-truncate\">{{ effectivePopupTitle() }}</h6>\n <button\n type=\"button\"\n class=\"btn-close\"\n aria-label=\"Close\"\n (click)=\"closeOverlay($event)\"\n ></button>\n </div>\n\n <!-- Modal Body (Options Content) -->\n <div\n class=\"modal-body p-0\"\n #dropdownMenu\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n </div>\n\n <!-- Modal Footer (Custom Template or Done Button) -->\n @if (footerTemplate || multiple()) {\n <div\n class=\"modal-footer p-2 bg-light bg-opacity-50 d-flex align-items-center justify-content-end\"\n >\n @if (footerTemplate) {\n <div class=\"w-100\">\n <ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container>\n </div>\n } @else {\n <button\n type=\"button\"\n class=\"btn btn-sm btn-primary px-3\"\n (click)=\"closeOverlay($event)\"\n >\n Done\n </button>\n }\n </div>\n }\n </div>\n </div>\n </div>\n }\n } @else {\n <!-- Standard Dropdown Menu -->\n <div\n #dropdownMenu\n class=\"dropdown-menu shadow-sm p-0\"\n [class.show]=\"overlayVisible()\"\n [ngStyle]=\"panelStyle()\"\n [ngClass]=\"panelStyleClass()\"\n [style.max-height]=\"scrollHeight()\"\n style=\"overflow-y: auto\"\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n (click)=\"$event.stopPropagation()\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n\n <!-- Footer Template -->\n @if (footerTemplate) {\n <div class=\"p-2 border-top\">\n <ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container>\n </div>\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}:host.inline{display:inline-block;width:auto}.ngb-select-container{position:relative;-webkit-user-select:none;user-select:none;width:100%}.ngb-select-container .form-select{cursor:pointer;min-height:38px;background-image:none;padding-right:.75rem;padding-left:.75rem}.ngb-select-container .form-select.form-select-sm{min-height:31px;padding-right:.5rem;padding-left:.5rem}.ngb-select-container .form-select.form-select-lg{min-height:48px;padding-right:1rem;padding-left:1rem}.ngb-select-container .form-select.disabled,.ngb-select-container .form-select:disabled{cursor:not-allowed;background-color:var(--bs-secondary-bg);opacity:.65}.ngb-select-container.form-floating{display:block;width:100%;position:relative}.ngb-select-container.form-floating.float-variant-on,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over){margin-top:.35rem}.ngb-select-container.form-floating.float-variant-on .form-select,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-sm,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-sm{min-height:31px;padding-top:.25rem;padding-bottom:.25rem}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-lg,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-lg{min-height:48px;padding-top:.5rem;padding-bottom:.5rem}.ngb-select-container.form-floating.float-variant-on>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over)>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0 .35rem;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;border-radius:var(--bs-border-radius);background-color:transparent;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out,background-color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-on.floating-active>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over).floating-active>label{top:0;transform:translateY(-50%) scale(.85);background-color:var(--bs-body-bg);color:var(--bs-primary);font-weight:600}.ngb-select-container.form-floating.float-variant-in .form-select{height:calc(3.5rem + 2px);min-height:calc(3.5rem + 2px);padding:1.625rem .75rem .5rem;align-items:flex-end}.ngb-select-container.form-floating.float-variant-in>label{position:absolute;top:0;left:0;z-index:2;height:100%;padding:1rem .75rem;overflow:hidden;text-align:start;text-overflow:ellipsis;white-space:nowrap;pointer-events:none;border:var(--bs-border-width) solid transparent;transform-origin:0 0;transition:opacity .15s ease-in-out,transform .15s ease-in-out,color .15s ease-in-out;color:rgba(var(--bs-body-color-rgb),.65);transform:scale(1) translateY(0)}.ngb-select-container.form-floating.float-variant-in.floating-active>label{transform:scale(.85) translateY(-.65rem) translate(.15rem);color:var(--bs-primary);font-weight:500}.ngb-select-container.form-floating.float-variant-over{margin-top:1.25rem}.ngb-select-container.form-floating.float-variant-over .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-sm{min-height:31px}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-lg{min-height:48px}.ngb-select-container.form-floating.float-variant-over>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-over.floating-active>label{top:-.75rem;transform:scale(.85);color:var(--bs-primary);font-weight:600}.ngb-select-container .ngb-select-clear-icon,.ngb-select-container .ngb-select-dropdown-icon{cursor:pointer;display:inline-flex;align-items:center;justify-content:center;line-height:1;font-size:.875rem}.ngb-select-container .ngb-select-clear-icon i,.ngb-select-container .ngb-select-dropdown-icon i{transition:transform .2s ease-in-out}.ngb-select-container .ngb-select-clear-icon i.rotate-180,.ngb-select-container .ngb-select-dropdown-icon i.rotate-180{transform:rotate(180deg)}.ngb-select-container .ngb-select-clear-icon{opacity:.6;transition:opacity .15s ease}.ngb-select-container .ngb-select-clear-icon:hover{opacity:1}.ngb-select-container.dropup .dropdown-menu,.ngb-select-container.dropdown-up .dropdown-menu{top:auto;bottom:100%;margin-top:0;margin-bottom:.125rem}.dropdown-menu{top:100%;left:0;width:100%;min-width:100%;margin-top:.125rem;z-index:1060;box-sizing:border-box;text-align:inherit}.dropdown-menu .dropdown-item{cursor:pointer;white-space:normal;word-break:break-word;text-align:inherit}.dropdown-menu .dropdown-item.disabled,.dropdown-menu .dropdown-item:disabled{cursor:not-allowed;opacity:.5}.dropdown-menu .dropdown-item.focus,.dropdown-menu .dropdown-item.focused,.dropdown-menu .dropdown-item:focus{color:var(--bs-dropdown-link-hover-color, inherit);background-color:var(--bs-dropdown-link-hover-bg, var(--bs-tertiary-bg))!important}.dropdown-menu .dropdown-item.active{color:var(--bs-dropdown-link-active-color)!important;background-color:var(--bs-dropdown-link-active-bg)!important}.dropdown-menu .dropdown-header{font-weight:600;text-transform:uppercase;font-size:.75rem;letter-spacing:.05em;text-align:inherit}\n"] }]
|
|
994
|
-
}],
|
|
995
|
-
type: ContentChild,
|
|
996
|
-
args: ['item']
|
|
997
|
-
}], selectedItemTemplate: [{
|
|
998
|
-
type: ContentChild,
|
|
999
|
-
args: ['selectedItem']
|
|
1000
|
-
}], labelTemplate: [{
|
|
1001
|
-
type: ContentChild,
|
|
1002
|
-
args: ['label']
|
|
1003
|
-
}], chipTemplate: [{
|
|
1004
|
-
type: ContentChild,
|
|
1005
|
-
args: ['chip']
|
|
1006
|
-
}], headerCheckboxTemplate: [{
|
|
1007
|
-
type: ContentChild,
|
|
1008
|
-
args: ['headerCheckbox']
|
|
1009
|
-
}], headerTemplate: [{
|
|
1010
|
-
type: ContentChild,
|
|
1011
|
-
args: ['header']
|
|
1012
|
-
}], footerTemplate: [{
|
|
1013
|
-
type: ContentChild,
|
|
1014
|
-
args: ['footer']
|
|
1015
|
-
}], groupTemplate: [{
|
|
1016
|
-
type: ContentChild,
|
|
1017
|
-
args: ['group']
|
|
1018
|
-
}], emptyTemplate: [{
|
|
1019
|
-
type: ContentChild,
|
|
1020
|
-
args: ['empty']
|
|
1021
|
-
}], clearIconTemplate: [{
|
|
1022
|
-
type: ContentChild,
|
|
1023
|
-
args: ['clearIcon']
|
|
1024
|
-
}], dropdownIconTemplate: [{
|
|
1025
|
-
type: ContentChild,
|
|
1026
|
-
args: ['dropdownIcon']
|
|
1027
|
-
}], filterIconTemplate: [{
|
|
1028
|
-
type: ContentChild,
|
|
1029
|
-
args: ['filterIcon']
|
|
1030
|
-
}], filterInputElement: [{
|
|
1031
|
-
type: ViewChild,
|
|
1032
|
-
args: ['filterInput']
|
|
1033
|
-
}], triggerFilterInputElement: [{
|
|
1034
|
-
type: ViewChild,
|
|
1035
|
-
args: ['triggerFilterInput']
|
|
1036
|
-
}], editableInputElement: [{
|
|
1037
|
-
type: ViewChild,
|
|
1038
|
-
args: ['editableInput']
|
|
1039
|
-
}], dropdownMenuElement: [{
|
|
1040
|
-
type: ViewChild,
|
|
1041
|
-
args: ['dropdownMenu']
|
|
1042
|
-
}] } });
|
|
995
|
+
], template: "<div\n class=\"ngb-select-container position-relative\"\n [class.form-floating]=\"floatLabel()\"\n [class.float-variant-on]=\"floatLabel() && floatLabelVariant() === 'on'\"\n [class.float-variant-in]=\"floatLabel() && floatLabelVariant() === 'in'\"\n [class.float-variant-over]=\"floatLabel() && floatLabelVariant() === 'over'\"\n [class.floating-active]=\"hasSelectedValue() || overlayVisible()\"\n [class.dropup]=\"isDropup()\"\n [class.dropdown-up]=\"isDropup()\"\n [class.w-100]=\"fluid()\"\n [attr.dir]=\"dir() || null\"\n [ngStyle]=\"style()\"\n [ngClass]=\"styleClass()\"\n (keydown)=\"onKeydown($event)\"\n>\n <!-- Select Trigger Box -->\n <div\n class=\"form-select d-flex align-items-center justify-content-between\"\n [class.is-invalid]=\"invalid()\"\n [class.disabled]=\"disabled()\"\n [class.form-select-sm]=\"size() === 'small'\"\n [class.form-select-lg]=\"size() === 'large'\"\n [class.bg-light]=\"variant() === 'filled'\"\n [attr.id]=\"id()\"\n [attr.tabindex]=\"disabled() ? -1 : tabindex()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-expanded]=\"overlayVisible()\"\n [attr.aria-haspopup]=\"'listbox'\"\n role=\"combobox\"\n (click)=\"onTriggerClick($event)\"\n (focus)=\"onTriggerFocus($event)\"\n (blur)=\"onTriggerBlur($event)\"\n >\n <!-- Selected Value / Input / Chips Area -->\n <span class=\"text-truncate flex-grow-1 me-2 d-flex flex-wrap align-items-center gap-1\">\n <!-- Filter directly in Trigger Box -->\n @if (filterInTrigger()) {\n <!-- Chips in multiple mode when filterInTrigger is active -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate()!;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n }\n <!-- Search Filter Input embedded inside the trigger -->\n <input\n #triggerFilterInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none flex-grow-1\"\n style=\"min-width: 80px\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [value]=\"effectiveFilterValue()\"\n [placeholder]=\"\n multiple() && hasSelectedValue()\n ? ''\n : hasSelectedValue() && !overlayVisible()\n ? displayLabel()\n : effectiveSearchPlaceholder()\n \"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n (focus)=\"openOverlay($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Editable Input (Single mode only) -->\n @if (editable() && !multiple()) {\n <input\n #editableInput\n type=\"text\"\n class=\"form-control border-0 bg-transparent p-0 shadow-none\"\n [class.form-control-sm]=\"size() === 'small'\"\n [class.form-control-lg]=\"size() === 'large'\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n [attr.maxlength]=\"maxLength()\"\n [value]=\"displayLabel()\"\n [placeholder]=\"placeholder() || ''\"\n (input)=\"onEditableInput($event)\"\n (focus)=\"onEditableFocus($event)\"\n (click)=\"$event.stopPropagation()\"\n />\n } @else {\n <!-- Multi-Select Chips Display Mode -->\n @if (multiple() && display() === 'chip' && hasSelectedValue()) {\n @for (val of value(); track val) {\n <span\n class=\"badge bg-light text-dark border d-inline-flex align-items-center gap-1 py-1 px-2\"\n >\n @if (chipTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n chipTemplate()!;\n context: { $implicit: findOptionByValue(val) ?? val, value: val }\n \"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabelByValue(val) }}</span>\n }\n @if (!disabled() && !readonly()) {\n <i\n class=\"bi bi-x ms-1 cursor-pointer fw-bold\"\n (click)=\"removeChip(val, $event)\"\n ></i>\n }\n </span>\n }\n } @else {\n @if (hasSelectedValue()) {\n @if (selectedItemTemplate() || labelTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n selectedItemTemplate() || labelTemplate()!;\n context: { $implicit: findOptionByValue(value()) ?? value(), value: value() }\n \"\n ></ng-container>\n } @else {\n <span>{{ displayLabel() }}</span>\n }\n } @else {\n <span class=\"text-muted\">{{ floatLabel() ? '' : placeholder() || '' }}</span>\n }\n }\n <!-- Standard Single or Comma Multi-Select Text -->\n }\n }\n </span>\n\n <!-- Icons & Spinners Area -->\n <div class=\"d-flex align-items-center flex-shrink-0 gap-1 ms-auto\">\n <!-- Clear Icon -->\n @if (showClear() && hasSelectedValue() && !disabled() && !readonly()) {\n <span\n class=\"ngb-select-clear-icon text-muted me-1\"\n (click)=\"onClearClick($event)\"\n title=\"Clear\"\n tabindex=\"0\"\n role=\"button\"\n aria-label=\"Clear value\"\n >\n @if (clearIconTemplate()) {\n <ng-container *ngTemplateOutlet=\"clearIconTemplate()!\"></ng-container>\n } @else {\n <i class=\"bi bi-x-circle-fill\"></i>\n }\n </span>\n }\n\n <!-- Loading Spinner -->\n @if (loading()) {\n <div class=\"spinner-border spinner-border-sm text-secondary\" role=\"status\">\n <span class=\"visually-hidden\">Loading...</span>\n </div>\n }\n\n <!-- Dropdown Caret Icon -->\n @if (!loading()) {\n <span class=\"ngb-select-dropdown-icon text-secondary\">\n @if (dropdownIconTemplate()) {\n <ng-container *ngTemplateOutlet=\"dropdownIconTemplate()!\"></ng-container>\n } @else {\n <i class=\"bi bi-chevron-down\" [class.rotate-180]=\"overlayVisible()\"></i>\n }\n </span>\n }\n </div>\n </div>\n\n <!-- Float Label Support -->\n @if (floatLabel() && placeholder()) {\n <label [attr.for]=\"id()\">{{ placeholder() }}</label>\n }\n\n <ng-template #dropdownContent>\n <!-- Header Template -->\n @if (headerTemplate()) {\n <div class=\"p-2 border-bottom\">\n <ng-container *ngTemplateOutlet=\"headerTemplate()!\"></ng-container>\n </div>\n }\n\n <!-- Header: Select All Checkbox & Search / Filter Box -->\n @if ((filter() && !filterInTrigger()) || (multiple() && showSelectAll())) {\n <div class=\"p-2 border-bottom bg-light bg-opacity-50\">\n <!-- Select All Checkbox -->\n @if (multiple() && showSelectAll()) {\n <div class=\"d-flex align-items-center mb-2 px-1\">\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0 cursor-pointer\"\n [checked]=\"selectAll()\"\n (change)=\"toggleSelectAll($event)\"\n id=\"selectAllCheckbox\"\n />\n <label\n class=\"form-check-label small fw-semibold cursor-pointer user-select-none\"\n for=\"selectAllCheckbox\"\n >\n @if (headerCheckboxTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"headerCheckboxTemplate()!; context: { $implicit: selectAll() }\"\n ></ng-container>\n } @else {\n Select All\n }\n </label>\n </div>\n }\n <!-- Search Box -->\n @if (filter() && !filterInTrigger()) {\n <div class=\"input-group input-group-sm\">\n <span class=\"input-group-text bg-transparent border-end-0\">\n @if (filterIconTemplate()) {\n <ng-container *ngTemplateOutlet=\"filterIconTemplate()!\"></ng-container>\n } @else {\n <i class=\"bi bi-search text-muted\"></i>\n }\n </span>\n <input\n #filterInput\n type=\"text\"\n class=\"form-control border-start-0\"\n [placeholder]=\"effectiveSearchPlaceholder()\"\n [value]=\"filterValue()\"\n (input)=\"onFilterChange($event)\"\n (keydown)=\"onFilterKeydown($event)\"\n />\n </div>\n }\n </div>\n }\n\n <!-- Grouped Options Mode -->\n @if (group()) {\n @for (\n groupOption of filteredOptions();\n track resolveOptionGroupLabel(groupOption) || $index\n ) {\n <div>\n <!-- Group Header -->\n <h6\n class=\"dropdown-header text-muted py-2 px-3 m-0 bg-light bg-opacity-75 d-flex align-items-center\"\n >\n @if (groupTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"groupTemplate()!; context: { $implicit: groupOption }\"\n ></ng-container>\n } @else {\n {{ resolveOptionGroupLabel(groupOption) }}\n }\n </h6>\n <!-- Group Items -->\n @for (\n option of resolveOptionGroupChildren(groupOption);\n track resolveOptionTrackKey(option, $index)\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate()!; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n </div>\n }\n } @else {\n @for (\n option of filteredOptions();\n track resolveOptionTrackKey(option, $index);\n let i = $index\n ) {\n <button\n type=\"button\"\n class=\"dropdown-item d-flex align-items-center py-2 px-3\"\n [class.active]=\"!multiple() && isSelected(option)\"\n [class.bg-light]=\"multiple() && isSelected(option)\"\n [class.fw-semibold]=\"multiple() && isSelected(option)\"\n [class.focus]=\"isOptionFocused(option)\"\n [class.bg-body-secondary]=\"isOptionFocused(option) && !isSelected(option)\"\n [class.disabled]=\"isOptionDisabled(option)\"\n [disabled]=\"isOptionDisabled(option)\"\n role=\"option\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-checked]=\"multiple() ? isSelected(option) : null\"\n (click)=\"onOptionClick(option, $event)\"\n >\n <!-- Checkbox in Multiple Mode synced to selection -->\n @if (multiple()) {\n <input\n type=\"checkbox\"\n class=\"form-check-input me-2 mt-0\"\n style=\"pointer-events: none\"\n [checked]=\"isSelected(option)\"\n tabindex=\"-1\"\n />\n }\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"itemTemplate()!; context: { $implicit: option }\"\n ></ng-container>\n } @else {\n <span>{{ resolveOptionLabel(option) }}</span>\n }\n </button>\n }\n }\n\n <!-- Empty State Message -->\n @if (isOptionsEmpty()) {\n <div class=\"dropdown-item text-muted text-center py-3\">\n @if (emptyTemplate()) {\n <ng-container *ngTemplateOutlet=\"emptyTemplate()!\"></ng-container>\n } @else {\n <small>{{\n filterValue()\n ? emptyFilterMessage() || 'No results found'\n : emptyMessage() || 'No results found'\n }}</small>\n }\n </div>\n }\n </ng-template>\n\n @if (isModalMode()) {\n <!-- Bootstrap Modal Overlay -->\n @if (overlayVisible()) {\n <div\n class=\"modal fade show d-block\"\n tabindex=\"-1\"\n role=\"dialog\"\n aria-modal=\"true\"\n style=\"background-color: rgba(0, 0, 0, 0.45); z-index: 1075\"\n (click)=\"closeOverlay($event)\"\n >\n <div\n class=\"modal-dialog modal-dialog-centered modal-dialog-scrollable\"\n role=\"document\"\n (click)=\"$event.stopPropagation()\"\n >\n <div class=\"modal-content shadow\" [ngClass]=\"panelStyleClass()\" [ngStyle]=\"panelStyle()\">\n <!-- Modal Header -->\n <div class=\"modal-header bg-light bg-opacity-50 py-2 px-3\">\n <h6 class=\"modal-title m-0 fw-semibold text-truncate\">{{ effectivePopupTitle() }}</h6>\n <button\n type=\"button\"\n class=\"btn-close\"\n aria-label=\"Close\"\n (click)=\"closeOverlay($event)\"\n ></button>\n </div>\n\n <!-- Modal Body (Options Content) -->\n <div\n class=\"modal-body p-0\"\n #dropdownMenu\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n </div>\n\n <!-- Modal Footer (Custom Template or Done Button) -->\n @if (footerTemplate() || multiple()) {\n <div\n class=\"modal-footer p-2 bg-light bg-opacity-50 d-flex align-items-center justify-content-end\"\n >\n @if (footerTemplate()) {\n <div class=\"w-100\">\n <ng-container *ngTemplateOutlet=\"footerTemplate()!\"></ng-container>\n </div>\n } @else {\n <button\n type=\"button\"\n class=\"btn btn-sm btn-primary px-3\"\n (click)=\"closeOverlay($event)\"\n >\n Done\n </button>\n }\n </div>\n }\n </div>\n </div>\n </div>\n }\n } @else {\n <!-- Standard Dropdown Menu -->\n <div\n #dropdownMenu\n class=\"dropdown-menu shadow-sm p-0\"\n [class.show]=\"overlayVisible()\"\n [ngStyle]=\"panelStyle()\"\n [ngClass]=\"panelStyleClass()\"\n [style.max-height]=\"scrollHeight()\"\n style=\"overflow-y: auto\"\n role=\"listbox\"\n (scroll)=\"onOverlayScroll($event)\"\n (click)=\"$event.stopPropagation()\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownContent\"></ng-container>\n\n <!-- Footer Template -->\n @if (footerTemplate()) {\n <div class=\"p-2 border-top\">\n <ng-container *ngTemplateOutlet=\"footerTemplate()!\"></ng-container>\n </div>\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}:host.inline{display:inline-block;width:auto}.ngb-select-container{position:relative;-webkit-user-select:none;user-select:none;width:100%}.ngb-select-container .form-select{cursor:pointer;min-height:38px;background-image:none;padding-right:.75rem;padding-left:.75rem}.ngb-select-container .form-select.form-select-sm{min-height:31px;padding-right:.5rem;padding-left:.5rem}.ngb-select-container .form-select.form-select-lg{min-height:48px;padding-right:1rem;padding-left:1rem}.ngb-select-container .form-select.disabled,.ngb-select-container .form-select:disabled{cursor:not-allowed;background-color:var(--bs-secondary-bg);opacity:.65}.ngb-select-container.form-floating{display:block;width:100%;position:relative}.ngb-select-container.form-floating.float-variant-on,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over){margin-top:.35rem}.ngb-select-container.form-floating.float-variant-on .form-select,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-sm,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-sm{min-height:31px;padding-top:.25rem;padding-bottom:.25rem}.ngb-select-container.form-floating.float-variant-on .form-select.form-select-lg,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over) .form-select.form-select-lg{min-height:48px;padding-top:.5rem;padding-bottom:.5rem}.ngb-select-container.form-floating.float-variant-on>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over)>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0 .35rem;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;border-radius:var(--bs-border-radius);background-color:transparent;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out,background-color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-on.floating-active>label,.ngb-select-container.form-floating:not(.float-variant-in):not(.float-variant-over).floating-active>label{top:0;transform:translateY(-50%) scale(.85);background-color:var(--bs-body-bg);color:var(--bs-primary);font-weight:600}.ngb-select-container.form-floating.float-variant-in .form-select{height:calc(3.5rem + 2px);min-height:calc(3.5rem + 2px);padding:1.625rem .75rem .5rem;align-items:flex-end}.ngb-select-container.form-floating.float-variant-in>label{position:absolute;top:0;left:0;z-index:2;height:100%;padding:1rem .75rem;overflow:hidden;text-align:start;text-overflow:ellipsis;white-space:nowrap;pointer-events:none;border:var(--bs-border-width) solid transparent;transform-origin:0 0;transition:opacity .15s ease-in-out,transform .15s ease-in-out,color .15s ease-in-out;color:rgba(var(--bs-body-color-rgb),.65);transform:scale(1) translateY(0)}.ngb-select-container.form-floating.float-variant-in.floating-active>label{transform:scale(.85) translateY(-.65rem) translate(.15rem);color:var(--bs-primary);font-weight:500}.ngb-select-container.form-floating.float-variant-over{margin-top:1.25rem}.ngb-select-container.form-floating.float-variant-over .form-select{min-height:38px;height:auto;padding:.375rem .75rem;align-items:center}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-sm{min-height:31px}.ngb-select-container.form-floating.float-variant-over .form-select.form-select-lg{min-height:48px}.ngb-select-container.form-floating.float-variant-over>label{position:absolute;top:50%;left:.75rem;transform:translateY(-50%);height:auto;padding:0;margin:0;line-height:1;font-size:.95rem;color:var(--bs-secondary-color);pointer-events:none;transform-origin:left center;transition:transform .2s cubic-bezier(.25,.8,.25,1),top .2s cubic-bezier(.25,.8,.25,1),color .2s ease-in-out;z-index:5}.ngb-select-container.form-floating.float-variant-over.floating-active>label{top:-.75rem;transform:scale(.85);color:var(--bs-primary);font-weight:600}.ngb-select-container .ngb-select-clear-icon,.ngb-select-container .ngb-select-dropdown-icon{cursor:pointer;display:inline-flex;align-items:center;justify-content:center;line-height:1;font-size:.875rem}.ngb-select-container .ngb-select-clear-icon i,.ngb-select-container .ngb-select-dropdown-icon i{transition:transform .2s ease-in-out}.ngb-select-container .ngb-select-clear-icon i.rotate-180,.ngb-select-container .ngb-select-dropdown-icon i.rotate-180{transform:rotate(180deg)}.ngb-select-container .ngb-select-clear-icon{opacity:.6;transition:opacity .15s ease}.ngb-select-container .ngb-select-clear-icon:hover{opacity:1}.ngb-select-container.dropup .dropdown-menu,.ngb-select-container.dropdown-up .dropdown-menu{top:auto;bottom:100%;margin-top:0;margin-bottom:.125rem}.dropdown-menu{top:100%;left:0;width:100%;min-width:100%;margin-top:.125rem;z-index:1060;box-sizing:border-box;text-align:inherit}.dropdown-menu .dropdown-item{cursor:pointer;white-space:normal;word-break:break-word;text-align:inherit}.dropdown-menu .dropdown-item.disabled,.dropdown-menu .dropdown-item:disabled{cursor:not-allowed;opacity:.5}.dropdown-menu .dropdown-item.focus,.dropdown-menu .dropdown-item.focused,.dropdown-menu .dropdown-item:focus{color:var(--bs-dropdown-link-hover-color, inherit);background-color:var(--bs-dropdown-link-hover-bg, var(--bs-tertiary-bg))!important}.dropdown-menu .dropdown-item.active{color:var(--bs-dropdown-link-active-color)!important;background-color:var(--bs-dropdown-link-active-bg)!important}.dropdown-menu .dropdown-header{font-weight:600;text-transform:uppercase;font-size:.75rem;letter-spacing:.05em;text-align:inherit}\n"] }]
|
|
996
|
+
}], propDecorators: { options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: false }] }], optionLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionLabel", required: false }] }], optionValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionValue", required: false }] }], optionDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionDisabled", required: false }] }], optionGroupLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionGroupLabel", required: false }] }], optionGroupChildren: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionGroupChildren", required: false }] }], group: [{ type: i0.Input, args: [{ isSignal: true, alias: "group", required: false }] }], dataKey: [{ type: i0.Input, args: [{ isSignal: true, alias: "dataKey", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], multiple: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiple", required: false }] }], display: [{ type: i0.Input, args: [{ isSignal: true, alias: "display", required: false }] }], showSelectAll: [{ type: i0.Input, args: [{ isSignal: true, alias: "showSelectAll", required: false }] }], maxSelectedLabels: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxSelectedLabels", required: false }] }], selectedItemsLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectedItemsLabel", required: false }] }], selectionLimit: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectionLimit", required: false }] }], closeOnSelect: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnSelect", required: false }] }], filter: [{ type: i0.Input, args: [{ isSignal: true, alias: "filter", required: false }] }], filterBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterBy", required: false }] }], filterMatchMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterMatchMode", required: false }] }], filterLocale: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterLocale", required: false }] }], filterNormalizeArabic: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterNormalizeArabic", required: false }] }], filterPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterPlaceholder", required: false }] }], searchPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholder", required: false }] }], filterInTrigger: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterInTrigger", required: false }] }], resetFilterOnHide: [{ type: i0.Input, args: [{ isSignal: true, alias: "resetFilterOnHide", required: false }] }], emptyMessage: [{ type: i0.Input, args: [{ isSignal: true, alias: "emptyMessage", required: false }] }], emptyFilterMessage: [{ type: i0.Input, args: [{ isSignal: true, alias: "emptyFilterMessage", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }, { type: i0.Output, args: ["disabledChange"] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], showClear: [{ type: i0.Input, args: [{ isSignal: true, alias: "showClear", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], floatLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "floatLabel", required: false }] }], floatLabelVariant: [{ type: i0.Input, args: [{ isSignal: true, alias: "floatLabelVariant", required: false }] }], autofocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autofocus", required: false }] }], tabindex: [{ type: i0.Input, args: [{ isSignal: true, alias: "tabindex", required: false }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], ariaLabelledBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelledBy", required: false }] }], dir: [{ type: i0.Input, args: [{ isSignal: true, alias: "dir", required: false }] }], dropdownPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropdownPosition", required: false }] }], dropdownDirection: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropdownDirection", required: false }] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], fluid: [{ type: i0.Input, args: [{ isSignal: true, alias: "fluid", required: false }] }], scrollHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "scrollHeight", required: false }] }], style: [{ type: i0.Input, args: [{ isSignal: true, alias: "style", required: false }] }], styleClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "styleClass", required: false }] }], panelStyle: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelStyle", required: false }] }], panelStyleClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelStyleClass", required: false }] }], appendTo: [{ type: i0.Input, args: [{ isSignal: true, alias: "appendTo", required: false }] }], modal: [{ type: i0.Input, args: [{ isSignal: true, alias: "modal", required: false }] }], popup: [{ type: i0.Input, args: [{ isSignal: true, alias: "popup", required: false }] }], touchUI: [{ type: i0.Input, args: [{ isSignal: true, alias: "touchUI", required: false }] }], popupTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "popupTitle", required: false }] }], modalTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "modalTitle", required: false }] }], editable: [{ type: i0.Input, args: [{ isSignal: true, alias: "editable", required: false }] }], maxLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxLength", required: false }] }], selectOnFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectOnFocus", required: false }] }], autoOptionFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoOptionFocus", required: false }] }], focusOnOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusOnOpen", required: false }] }], focusOnOpenStrategy: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusOnOpenStrategy", required: false }] }], lazy: [{ type: i0.Input, args: [{ isSignal: true, alias: "lazy", required: false }] }], overlayVisible: [{ type: i0.Input, args: [{ isSignal: true, alias: "overlayVisible", required: false }] }, { type: i0.Output, args: ["overlayVisibleChange"] }], onChange: [{ type: i0.Output, args: ["onChange"] }], onFilter: [{ type: i0.Output, args: ["onFilter"] }], onFocus: [{ type: i0.Output, args: ["onFocus"] }], onBlur: [{ type: i0.Output, args: ["onBlur"] }], onShow: [{ type: i0.Output, args: ["onShow"] }], onHide: [{ type: i0.Output, args: ["onHide"] }], onClear: [{ type: i0.Output, args: ["onClear"] }], onSelectAllChange: [{ type: i0.Output, args: ["onSelectAllChange"] }], onRemoveChip: [{ type: i0.Output, args: ["onRemoveChip"] }], onLazyLoad: [{ type: i0.Output, args: ["onLazyLoad"] }], itemTemplate: [{ type: i0.ContentChild, args: ['item', { isSignal: true }] }], selectedItemTemplate: [{ type: i0.ContentChild, args: ['selectedItem', { isSignal: true }] }], labelTemplate: [{ type: i0.ContentChild, args: ['label', { isSignal: true }] }], chipTemplate: [{ type: i0.ContentChild, args: ['chip', { isSignal: true }] }], headerCheckboxTemplate: [{ type: i0.ContentChild, args: ['headerCheckbox', { isSignal: true }] }], headerTemplate: [{ type: i0.ContentChild, args: ['header', { isSignal: true }] }], footerTemplate: [{ type: i0.ContentChild, args: ['footer', { isSignal: true }] }], groupTemplate: [{ type: i0.ContentChild, args: ['group', { isSignal: true }] }], emptyTemplate: [{ type: i0.ContentChild, args: ['empty', { isSignal: true }] }], clearIconTemplate: [{ type: i0.ContentChild, args: ['clearIcon', { isSignal: true }] }], dropdownIconTemplate: [{ type: i0.ContentChild, args: ['dropdownIcon', { isSignal: true }] }], filterIconTemplate: [{ type: i0.ContentChild, args: ['filterIcon', { isSignal: true }] }], filterInputElement: [{ type: i0.ViewChild, args: ['filterInput', { isSignal: true }] }], triggerFilterInputElement: [{ type: i0.ViewChild, args: ['triggerFilterInput', { isSignal: true }] }], editableInputElement: [{ type: i0.ViewChild, args: ['editableInput', { isSignal: true }] }], dropdownMenuElement: [{ type: i0.ViewChild, args: ['dropdownMenu', { isSignal: true }] }] } });
|
|
1043
997
|
|
|
1044
998
|
/**
|
|
1045
999
|
* Generated bundle index. Do not edit.
|