@fundamental-ngx/core 0.58.0-rc.7 → 0.58.0-rc.70
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/button/index.d.ts +1 -1
- package/card/index.d.ts +8 -4
- package/combobox/index.d.ts +9 -1
- package/dialog/index.d.ts +2 -2
- package/feed-input/index.d.ts +1 -1
- package/fesm2022/fundamental-ngx-core-action-sheet.mjs +4 -4
- package/fesm2022/fundamental-ngx-core-action-sheet.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-avatar.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-avatar.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-button.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-card.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-combobox.mjs +44 -8
- package/fesm2022/fundamental-ngx-core-combobox.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-datetime.mjs +1 -1
- package/fesm2022/fundamental-ngx-core-datetime.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-dialog.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-dialog.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-feed-input.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-feed-input.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-flexible-column-layout.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-flexible-column-layout.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-form.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-form.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-illustrated-message.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-illustrated-message.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-input-group.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-list.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-menu.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-menu.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-message-box.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-multi-combobox.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-multi-input.mjs +1 -2
- package/fesm2022/fundamental-ngx-core-multi-input.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-nested-list.mjs +4 -4
- package/fesm2022/fundamental-ngx-core-nested-list.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-notification.mjs +3 -1
- package/fesm2022/fundamental-ngx-core-notification.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-object-status.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-object-status.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-overflow-layout.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-popover.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-popover.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-resizable-card-layout.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-resizable-card-layout.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-segmented-button.mjs +3 -3
- package/fesm2022/fundamental-ngx-core-segmented-button.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-shellbar.mjs +32 -5
- package/fesm2022/fundamental-ngx-core-shellbar.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-table.mjs +4 -4
- package/fesm2022/fundamental-ngx-core-table.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-tabs.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-theming.mjs +2 -3
- package/fesm2022/fundamental-ngx-core-theming.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-time-picker.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-time.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-toolbar.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-tree.mjs.map +1 -1
- package/fesm2022/fundamental-ngx-core-user-menu.mjs +2 -2
- package/fesm2022/fundamental-ngx-core-user-menu.mjs.map +1 -1
- package/form/index.d.ts +2 -2
- package/input-group/index.d.ts +1 -1
- package/list/index.d.ts +4 -4
- package/menu/index.d.ts +2 -2
- package/message-box/index.d.ts +1 -1
- package/multi-combobox/index.d.ts +2 -2
- package/multi-input/index.d.ts +1 -1
- package/nested-list/index.d.ts +11 -11
- package/notification/index.d.ts +2 -0
- package/overflow-layout/index.d.ts +4 -4
- package/package.json +19 -19
- package/popover/index.d.ts +2 -2
- package/segmented-button/index.d.ts +3 -3
- package/shellbar/index.d.ts +13 -2
- package/table/index.d.ts +2 -2
- package/tabs/index.d.ts +3 -3
- package/time/index.d.ts +1 -1
- package/time-picker/index.d.ts +1 -1
- package/toolbar/index.d.ts +1 -1
- package/tree/index.d.ts +3 -3
- package/schematics/add-animations/index.d.ts +0 -7
- package/schematics/add-animations/index.js +0 -83
- package/schematics/add-animations/index.js.map +0 -1
- package/schematics/add-animations/schema.json +0 -21
- package/schematics/add-dependencies/index.d.ts +0 -7
- package/schematics/add-dependencies/index.js +0 -105
- package/schematics/add-dependencies/index.js.map +0 -1
- package/schematics/add-dependencies/schema.json +0 -15
- package/schematics/add-styles/index.d.ts +0 -7
- package/schematics/add-styles/index.js +0 -97
- package/schematics/add-styles/index.js.map +0 -1
- package/schematics/add-styles/schema.json +0 -21
- package/schematics/add-theming/index.d.ts +0 -7
- package/schematics/add-theming/index.js +0 -108
- package/schematics/add-theming/index.js.map +0 -1
- package/schematics/add-theming/schema.json +0 -72
- package/schematics/collection.json +0 -40
- package/schematics/models/schema.d.ts +0 -6
- package/schematics/models/schema.js +0 -3
- package/schematics/models/schema.js.map +0 -1
- package/schematics/ng-add/index.d.ts +0 -9
- package/schematics/ng-add/index.js +0 -30
- package/schematics/ng-add/index.js.map +0 -1
- package/schematics/ng-add/schema.json +0 -84
- package/schematics/utils/calls-providers-function.d.ts +0 -11
- package/schematics/utils/calls-providers-function.js +0 -54
- package/schematics/utils/calls-providers-function.js.map +0 -1
- package/schematics/utils/file-utils.d.ts +0 -2
- package/schematics/utils/file-utils.js +0 -26
- package/schematics/utils/file-utils.js.map +0 -1
- package/schematics/utils/main-ts-file-path.d.ts +0 -2
- package/schematics/utils/main-ts-file-path.js +0 -27
- package/schematics/utils/main-ts-file-path.js.map +0 -1
- package/schematics/utils/ng-module-utils.d.ts +0 -6
- package/schematics/utils/ng-module-utils.js +0 -71
- package/schematics/utils/ng-module-utils.js.map +0 -1
- package/schematics/utils/one-time-packages.d.ts +0 -6
- package/schematics/utils/one-time-packages.js +0 -39
- package/schematics/utils/one-time-packages.js.map +0 -1
- package/schematics/utils/package-utils.d.ts +0 -10
- package/schematics/utils/package-utils.js +0 -25
- package/schematics/utils/package-utils.js.map +0 -1
- package/schematics/utils/workspace.d.ts +0 -40
- package/schematics/utils/workspace.js +0 -110
- package/schematics/utils/workspace.js.map +0 -1
|
@@ -9,7 +9,7 @@ import { TemplateDirective, InitialFocusDirective, KeyUtil, AutoCompleteDirectiv
|
|
|
9
9
|
import { BarMiddleDirective, BarElementDirective, ButtonBarComponent } from '@fundamental-ngx/core/bar';
|
|
10
10
|
import { DialogHeaderComponent, DialogCloseButtonComponent, DialogComponent, DialogBodyComponent, DialogFooterComponent } from '@fundamental-ngx/core/dialog';
|
|
11
11
|
import { TitleComponent } from '@fundamental-ngx/core/title';
|
|
12
|
-
import { asyncScheduler, Subscription } from 'rxjs';
|
|
12
|
+
import { asyncScheduler, Subscription, fromEvent } from 'rxjs';
|
|
13
13
|
import { ESCAPE, ENTER, LEFT_ARROW, RIGHT_ARROW, DOWN_ARROW, UP_ARROW, CONTROL, TAB, SHIFT, BACKSPACE, SPACE } from '@angular/cdk/keycodes';
|
|
14
14
|
import * as i4 from '@angular/forms';
|
|
15
15
|
import { FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
@@ -332,6 +332,8 @@ class ComboboxComponent {
|
|
|
332
332
|
/** @hidden */
|
|
333
333
|
this.clearInputBtnFocused = false;
|
|
334
334
|
/** @hidden */
|
|
335
|
+
this._itemMousedown = false;
|
|
336
|
+
/** @hidden */
|
|
335
337
|
this._subscriptions = new Subscription();
|
|
336
338
|
/** @hidden */
|
|
337
339
|
this.onChange = () => { };
|
|
@@ -362,6 +364,7 @@ class ComboboxComponent {
|
|
|
362
364
|
if (this.mobile) {
|
|
363
365
|
this._setUpMobileMode();
|
|
364
366
|
}
|
|
367
|
+
this._setupValueSynchronization();
|
|
365
368
|
}
|
|
366
369
|
/** @hidden */
|
|
367
370
|
onInputKeydownHandler(event) {
|
|
@@ -414,15 +417,23 @@ class ComboboxComponent {
|
|
|
414
417
|
/** @hidden */
|
|
415
418
|
onItemKeyDownHandler(event, value) {
|
|
416
419
|
if (KeyUtil.isKeyCode(event, ENTER) || KeyUtil.isKeyCode(event, SPACE)) {
|
|
420
|
+
this._itemMousedown = true;
|
|
417
421
|
event.preventDefault();
|
|
418
422
|
this.onMenuClickHandler(value);
|
|
419
423
|
}
|
|
420
424
|
}
|
|
421
425
|
/** @hidden */
|
|
422
|
-
|
|
426
|
+
onItemFocused(value) {
|
|
427
|
+
if (!this._itemMousedown && !this.mobile) {
|
|
428
|
+
this.onMenuClickHandler(value, false);
|
|
429
|
+
}
|
|
430
|
+
this._itemMousedown = false;
|
|
431
|
+
}
|
|
432
|
+
/** @hidden */
|
|
433
|
+
onMenuClickHandler(value, shouldClosePopover = true) {
|
|
423
434
|
if (value || value === 0) {
|
|
424
435
|
const index = this.dropdownValues.findIndex((_value) => _value === value);
|
|
425
|
-
this._handleClickActions(value);
|
|
436
|
+
this._handleClickActions(value, shouldClosePopover);
|
|
426
437
|
this.filterHighlight = false;
|
|
427
438
|
this.itemClicked.emit({ item: value, index });
|
|
428
439
|
}
|
|
@@ -648,8 +659,8 @@ class ComboboxComponent {
|
|
|
648
659
|
return contentArray || [];
|
|
649
660
|
}
|
|
650
661
|
/** @hidden */
|
|
651
|
-
_handleClickActions(term) {
|
|
652
|
-
if (this.closeOnSelect) {
|
|
662
|
+
_handleClickActions(term, shouldClosePopover = true) {
|
|
663
|
+
if (this.closeOnSelect && shouldClosePopover) {
|
|
653
664
|
this.isOpenChangeHandle(false);
|
|
654
665
|
}
|
|
655
666
|
if (this.fillOnSelect) {
|
|
@@ -661,7 +672,9 @@ class ComboboxComponent {
|
|
|
661
672
|
this._propagateChange();
|
|
662
673
|
}
|
|
663
674
|
}
|
|
664
|
-
|
|
675
|
+
if (shouldClosePopover) {
|
|
676
|
+
this.handleSearchTermChange();
|
|
677
|
+
}
|
|
665
678
|
}
|
|
666
679
|
/** @hidden */
|
|
667
680
|
_getOptionObjectByDisplayedValue(displayValue) {
|
|
@@ -717,6 +730,29 @@ class ComboboxComponent {
|
|
|
717
730
|
injector
|
|
718
731
|
});
|
|
719
732
|
}
|
|
733
|
+
/** @hidden */
|
|
734
|
+
_setupValueSynchronization() {
|
|
735
|
+
if (!this.searchInputElement) {
|
|
736
|
+
return;
|
|
737
|
+
}
|
|
738
|
+
// Listen for focus events to detect programmatic changes
|
|
739
|
+
this._subscriptions.add(fromEvent(this.searchInputElement.nativeElement, 'focus').subscribe(() => {
|
|
740
|
+
this._syncDomValueToModel();
|
|
741
|
+
}));
|
|
742
|
+
}
|
|
743
|
+
/** @hidden */
|
|
744
|
+
_syncDomValueToModel() {
|
|
745
|
+
if (!this.searchInputElement) {
|
|
746
|
+
return;
|
|
747
|
+
}
|
|
748
|
+
const domValue = this.searchInputElement.nativeElement.value;
|
|
749
|
+
if (domValue !== this.inputText) {
|
|
750
|
+
// Update the model and trigger change detection
|
|
751
|
+
this.inputText = domValue;
|
|
752
|
+
this.handleSearchTermChange();
|
|
753
|
+
this._cdRef.detectChanges();
|
|
754
|
+
}
|
|
755
|
+
}
|
|
720
756
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: ComboboxComponent, deps: [{ token: i1.Overlay }, { token: i0.ChangeDetectorRef }, { token: i0.Injector }, { token: i0.ViewContainerRef }, { token: i2.DynamicComponentService }, { token: i2.FocusTrapService }, { token: i3.ContentDensityObserver }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
721
757
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.4", type: ComboboxComponent, isStandalone: true, selector: "fd-combobox", inputs: { comboboxId: "comboboxId", inputId: "inputId", ariaLabel: "ariaLabel", ariaLabelledBy: "ariaLabelledBy", required: "required", dropdownValues: "dropdownValues", filterFn: "filterFn", disabled: "disabled", placeholder: "placeholder", isSearch: "isSearch", glyph: "glyph", glyphFont: "glyphFont", showClearButton: "showClearButton", triggers: "triggers", closeOnOutsideClick: "closeOnOutsideClick", openOnKeyboardEvent: "openOnKeyboardEvent", state: "state", itemTemplate: "itemTemplate", groupFn: "groupFn", maxHeight: "maxHeight", dropDownMaxWidthPx: "dropDownMaxWidthPx", noDropDownMaxWidth: "noDropDownMaxWidth", width: "width", searchFn: "searchFn", highlighting: "highlighting", closeOnSelect: "closeOnSelect", fillOnSelect: "fillOnSelect", autoComplete: "autoComplete", fillControlMode: "fillControlMode", communicateByObject: "communicateByObject", displayFn: "displayFn", buttonFocusable: "buttonFocusable", clearButtonFocusable: "clearButtonFocusable", readOnly: "readOnly", mobile: "mobile", mobileConfig: "mobileConfig", showDropdownButton: "showDropdownButton", includes: "includes", title: "title", byline: "byline", tabOutStrategy: "tabOutStrategy" }, outputs: { itemClicked: "itemClicked", openChange: "openChange", inputTextChange: "inputTextChange" }, host: { properties: { "class.fd-combobox-custom-class": "true", "class.fd-combobox-input": "true", "class.fd-combobox-custom-class--mobile": "mobile", "style.width": "width" } }, providers: [
|
|
722
758
|
{
|
|
@@ -732,7 +768,7 @@ class ComboboxComponent {
|
|
|
732
768
|
provide: FD_COMBOBOX_COMPONENT,
|
|
733
769
|
useExisting: ComboboxComponent
|
|
734
770
|
}
|
|
735
|
-
], queries: [{ propertyName: "_comboboxItemRenderer", first: true, predicate: ComboboxItemDirective, descendants: true }, { propertyName: "listMessages", predicate: FD_LIST_MESSAGE_DIRECTIVE }], viewQueries: [{ propertyName: "listComponent", first: true, predicate: ListComponent, descendants: true }, { propertyName: "searchInputElement", first: true, predicate: ["searchInputElement"], descendants: true }, { propertyName: "popoverComponent", first: true, predicate: PopoverComponent, descendants: true }, { propertyName: "inputGroup", first: true, predicate: InputGroupComponent, descendants: true }, { propertyName: "controlTemplate", first: true, predicate: ["controlTemplate"], descendants: true }, { propertyName: "listTemplate", first: true, predicate: ["listTemplate"], descendants: true }, { propertyName: "items", predicate: ["item"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<ng-template [ngTemplateOutlet]=\"mobile ? mobileTemplate : desktopTemplate\"></ng-template>\n<ng-template #desktopTemplate>\n <fd-popover\n additionalBodyClass=\"fd-popover-custom-list\"\n [class.fd-combobox-full-width]=\"isSearch || showClearButton\"\n [isOpen]=\"open && displayedValues && displayedValues.length > 0\"\n (isOpenChange)=\"isOpenChangeHandle($event)\"\n [fillControlMode]=\"fillControlMode\"\n [scrollStrategy]=\"_repositionScrollStrategy\"\n [focusTrapped]=\"true\"\n [triggers]=\"triggers\"\n [disabled]=\"disabled || readOnly\"\n [maxWidth]=\"!mobile && noDropDownMaxWidth ? null : dropDownMaxWidthPx\"\n [style.width]=\"width && '100%'\"\n [closeOnOutsideClick]=\"closeOnOutsideClick\"\n >\n <fd-popover-control>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n </fd-popover-control>\n <fd-popover-body [hidden]=\"!displayedValues.length\">\n <ng-template [ngTemplateOutlet]=\"listTemplate\"></ng-template>\n <ng-content></ng-content>\n </fd-popover-body>\n </fd-popover>\n</ng-template>\n<ng-template let-term=\"term\" #itemSource>\n @if (!_customRenderer) {\n <span\n fd-list-title\n fdTruncatedTitle\n [innerHTML]=\"term | displayFnPipe: displayFn | highlight: inputText : highlighting && filterHighlight\"\n >\n </span>\n } @else {\n <ng-template\n [ngTemplateOutlet]=\"_customRenderer\"\n [ngTemplateOutletContext]=\"{ $implicit: term, inputText: inputText }\"\n ></ng-template>\n }\n</ng-template>\n<ng-template #mobileTemplate>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n</ng-template>\n<ng-template #controlTemplate>\n <fd-input-group\n [button]=\"showDropdownButton\"\n [glyph]=\"showDropdownButton ? glyphValue : null\"\n [glyphFont]=\"isSearch ? _defaultFontFamily : glyphFont\"\n [state]=\"state\"\n [buttonFocusable]=\"buttonFocusable\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [isControl]=\"true\"\n [isExpanded]=\"!mobile && open && displayedValues.length > 0\"\n [showFocus]=\"!clearInputBtnFocused\"\n [glyphAriaLabel]=\"ariaLabel || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n [iconTitle]=\"title || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n (addOnButtonClicked)=\"onPrimaryButtonClick()\"\n (click)=\"mobile && isOpenChangeHandle(true)\"\n >\n <input\n #searchInputElement\n fdkAutoComplete\n fd-input-group-input\n type=\"text\"\n role=\"combobox\"\n autocomplete=\"off\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.aria-describedby]=\"comboboxId + '-list-results'\"\n [attr.aria-autocomplete]=\"autoComplete && !mobile ? 'list' : null\"\n [attr.aria-owns]=\"autoComplete && !mobile ? comboboxId + '-result' : null\"\n [attr.aria-haspopup]=\"autoComplete && !mobile\"\n [attr.aria-expanded]=\"!mobile && open && displayedValues.length\"\n [attr.aria-required]=\"required\"\n [attr.tabindex]=\"readOnly || disabled ? -1 : null\"\n [enable]=\"autoComplete && !mobile\"\n [displayFn]=\"displayFn\"\n [options]=\"dropdownValues\"\n [inputText]=\"inputText\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [attr.aria-readonly]=\"readOnly\"\n [placeholder]=\"placeholder\"\n [id]=\"inputId\"\n [(ngModel)]=\"inputText\"\n (onComplete)=\"handleAutoComplete($event)\"\n (keydown)=\"onInputKeydownHandler($event)\"\n (paste)=\"onInputKeydownHandler('fromPaste')\"\n (ngModelChange)=\"handleSearchTermChange()\"\n (blur)=\"handleBlur()\"\n />\n @if ((isSearch || showClearButton) && inputText && inputText.length > 0) {\n <span\n class=\"fd-input-group__addon fd-input-group__addon--button\"\n [class.fd-shellbar__input-group-addon]=\"inShellbar\"\n >\n <button\n fd-button\n class=\"fd-input-group__button\"\n type=\"button\"\n [fdType]=\"inShellbar ? 'standard' : 'transparent'\"\n title=\"Clear input\"\n [class.fd-shellbar__button]=\"inShellbar\"\n [attr.tabindex]=\"clearButtonFocusable ? 0 : -1\"\n (focus)=\"clearInputBtnFocus()\"\n (blur)=\"clearInputBtnBlur()\"\n (click)=\"_handleClearSearchTerm()\"\n >\n <fd-icon glyph=\"decline\"></fd-icon>\n </button>\n </span>\n }\n </fd-input-group>\n <div [id]=\"comboboxId + '-list-results'\" class=\"fd-combobox-count-list-results\">\n {{ displayedValues.length || 0 }} result list items\n </div>\n</ng-template>\n<ng-template #listTemplate>\n <ul\n fd-list\n class=\"fd-combobox-custom-list\"\n [dropdownMode]=\"true\"\n [id]=\"comboboxId + '-result'\"\n role=\"listbox\"\n [attr.aria-labelledby]=\"comboboxId + '-search'\"\n [style.maxHeight]=\"!mobile && maxHeight\"\n [hasMessage]=\"listMessages && listMessages.length > 0\"\n [byline]=\"byline\"\n [tabindex]=\"0\"\n (keydown.tab)=\"_close()\"\n (keydown.shift.tab)=\"_close()\"\n (focusEscapeList)=\"handleListFocusEscape($event)\"\n >\n <ng-content></ng-content>\n @if (groupFn) {\n @for (group of displayedValues | listGroupPipe: groupFn; track group.key; let groupIndex = $index) {\n <li\n fd-list-item\n fd-list-group-header\n ariaRole=\"group\"\n [attr.aria-roledescription]=\"'coreMultiComboBox.listGroupHeader' | fdTranslate\"\n [attr.aria-owns]=\"_getGroupItemIds(groupIndex)\"\n [attr.aria-label]=\"group.key\"\n >\n <span fd-list-title>{{ group.key }}</span>\n </li>\n @for (term of group.value; track term; let index = $index) {\n <li\n fd-list-item\n #item=\"fdListItem\"\n ariaRole=\"option\"\n [attr.aria-placeholder]=\"group.key\"\n [attr.aria-setsize]=\"group.value.length\"\n [attr.aria-posinset]=\"index + 1\"\n [attr.id-with-group-index]=\"item.id + '-group-' + groupIndex\"\n class=\"fd-combobox-list-item\"\n [selected]=\"isSelected(term)\"\n [value]=\"term\"\n (keydown)=\"onItemKeyDownHandler($event, term)\"\n (click)=\"onMenuClickHandler(term)\"\n >\n <ng-template\n [ngTemplateOutlet]=\"itemSource\"\n [ngTemplateOutletContext]=\"{ term: term }\"\n ></ng-template>\n </li>\n }\n }\n } @else {\n @for (term of displayedValues; track term) {\n <li\n fd-list-item\n role=\"option\"\n [tabindex]=\"0\"\n class=\"fd-combobox-list-item\"\n [selected]=\"isSelected(term)\"\n (keydown)=\"onItemKeyDownHandler($event, term)\"\n (click)=\"onMenuClickHandler(term)\"\n [value]=\"term\"\n >\n <ng-template\n [ngTemplateOutlet]=\"itemSource\"\n [ngTemplateOutletContext]=\"{ term: term }\"\n ></ng-template>\n </li>\n }\n }\n </ul>\n</ng-template>\n", styles: [".fd-combobox-custom-class,.fd-combobox-custom-class .fd-combobox-shellbar-custom{display:inline-block}.fd-list__item.fd-combobox-list-item{cursor:pointer}.fd-combobox-full-width{width:100%}.fd-combobox-count-list-results{position:absolute;opacity:0;z-index:-1}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: PopoverComponent, selector: "fd-popover", inputs: ["title", "trigger", "fixedPosition", "id", "mobile", "mobileConfig", "preventSpaceKeyScroll"] }, { kind: "component", type: PopoverControlComponent, selector: "fd-popover-control, [fdPopoverControl]" }, { kind: "component", type: PopoverBodyComponent, selector: "fd-popover-body", inputs: ["minWidth", "maxWidth", "minHeight", "maxHeight"] }, { kind: "component", type: ListComponent, selector: "[fd-list], [fdList]", inputs: ["dropdownMode", "multiInputMode", "mobileMode", "hasMessage", "noBorder", "navigationIndicator", "selection", "keyboardSupport", "byline", "subline", "theme", "unreadIndicator", "role", "settingsList", "settingsListFooter"], outputs: ["focusEscapeList"] }, { kind: "component", type: ListItemComponent, selector: "[fdListItem] ,[fd-list-item]", inputs: ["selected", "noData", "action", "interactive", "growing", "counter", "active", "unread", "byline", "ariaRole", "id", "preventClick", "settingsListTpl"], outputs: ["keyDown"], exportAs: ["fdListItem"] }, { kind: "directive", type: ListTitleDirective, selector: "[fd-list-title], [fdListTitle]", inputs: ["wrap", "truncate"] }, { kind: "directive", type: ListGroupHeaderDirective, selector: "[fdListGroupHeader], [fd-list-group-header]", inputs: ["nativeElementId"], outputs: ["keyDown"] }, { kind: "component", type: InputGroupComponent, selector: "fd-input-group", inputs: ["placement", "required", "inline", "addOnText", "buttonFocusable", "type", "glyph", "glyphFont", "button", "isControl", "showFocus", "isExpanded", "glyphAriaLabel", "addonButtonAriaHidden", "iconTitle", "ariaLabelledBy", "ariaLabel"], outputs: ["addOnButtonClicked", "search"] }, { kind: "directive", type: InputGroupInputDirective, selector: "[fdInputGroupInput], [fd-input-group-input]", inputs: ["class"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: AutoCompleteDirective, selector: "[fdkAutoComplete]", inputs: ["options", "inputText", "enable", "displayFn", "matcher"], outputs: ["onComplete"] }, { kind: "component", type: ButtonComponent, selector: "button[fd-button], a[fd-button], span[fd-button]", inputs: ["class", "id"], exportAs: ["fd-button"] }, { kind: "component", type: IconComponent, selector: "fd-icon", inputs: ["glyph", "font", "color", "background", "class", "ariaLabel", "ariaHidden"] }, { kind: "ngmodule", type: ContentDensityModule }, { kind: "directive", type: TruncatedTitleDirective, selector: "[fdkTruncatedTitle], [fdTruncatedTitle], [fd-truncate-title]" }, { kind: "pipe", type: DisplayFnPipe, name: "displayFnPipe" }, { kind: "pipe", type: SearchHighlightPipe, name: "highlight" }, { kind: "pipe", type: FdTranslatePipe, name: "fdTranslate" }, { kind: "pipe", type: ListGroupPipe, name: "listGroupPipe" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
771
|
+
], queries: [{ propertyName: "_comboboxItemRenderer", first: true, predicate: ComboboxItemDirective, descendants: true }, { propertyName: "listMessages", predicate: FD_LIST_MESSAGE_DIRECTIVE }], viewQueries: [{ propertyName: "listComponent", first: true, predicate: ListComponent, descendants: true }, { propertyName: "searchInputElement", first: true, predicate: ["searchInputElement"], descendants: true }, { propertyName: "popoverComponent", first: true, predicate: PopoverComponent, descendants: true }, { propertyName: "inputGroup", first: true, predicate: InputGroupComponent, descendants: true }, { propertyName: "controlTemplate", first: true, predicate: ["controlTemplate"], descendants: true }, { propertyName: "listTemplate", first: true, predicate: ["listTemplate"], descendants: true }, { propertyName: "items", predicate: ["item"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<ng-template [ngTemplateOutlet]=\"mobile ? mobileTemplate : desktopTemplate\"></ng-template>\n<ng-template #desktopTemplate>\n <fd-popover\n additionalBodyClass=\"fd-popover-custom-list\"\n [class.fd-combobox-full-width]=\"isSearch || showClearButton\"\n [isOpen]=\"open && displayedValues && displayedValues.length > 0\"\n (isOpenChange)=\"isOpenChangeHandle($event)\"\n [fillControlMode]=\"fillControlMode\"\n [scrollStrategy]=\"_repositionScrollStrategy\"\n [focusTrapped]=\"true\"\n [triggers]=\"triggers\"\n [disabled]=\"disabled || readOnly\"\n [maxWidth]=\"!mobile && noDropDownMaxWidth ? null : dropDownMaxWidthPx\"\n [style.width]=\"width && '100%'\"\n [closeOnOutsideClick]=\"closeOnOutsideClick\"\n >\n <fd-popover-control>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n </fd-popover-control>\n <fd-popover-body [hidden]=\"!displayedValues.length\">\n <ng-template [ngTemplateOutlet]=\"listTemplate\"></ng-template>\n <ng-content></ng-content>\n </fd-popover-body>\n </fd-popover>\n</ng-template>\n<ng-template let-term=\"term\" #itemSource>\n @if (!_customRenderer) {\n <span\n fd-list-title\n fdTruncatedTitle\n [innerHTML]=\"term | displayFnPipe: displayFn | highlight: inputText : highlighting && filterHighlight\"\n >\n </span>\n } @else {\n <ng-template\n [ngTemplateOutlet]=\"_customRenderer\"\n [ngTemplateOutletContext]=\"{ $implicit: term, inputText: inputText }\"\n ></ng-template>\n }\n</ng-template>\n<ng-template #mobileTemplate>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n</ng-template>\n<ng-template #controlTemplate>\n <fd-input-group\n [button]=\"showDropdownButton\"\n [glyph]=\"showDropdownButton ? glyphValue : null\"\n [glyphFont]=\"isSearch ? _defaultFontFamily : glyphFont\"\n [state]=\"state\"\n [buttonFocusable]=\"buttonFocusable\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [isControl]=\"true\"\n [isExpanded]=\"!mobile && open && displayedValues.length > 0\"\n [showFocus]=\"!clearInputBtnFocused\"\n [glyphAriaLabel]=\"ariaLabel || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n [iconTitle]=\"title || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n (addOnButtonClicked)=\"onPrimaryButtonClick()\"\n (click)=\"mobile && isOpenChangeHandle(true)\"\n >\n <input\n #searchInputElement\n fdkAutoComplete\n fd-input-group-input\n type=\"text\"\n role=\"combobox\"\n autocomplete=\"off\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.aria-describedby]=\"comboboxId + '-list-results'\"\n [attr.aria-autocomplete]=\"autoComplete && !mobile ? 'list' : null\"\n [attr.aria-haspopup]=\"autoComplete && !mobile\"\n [attr.aria-expanded]=\"!mobile && open && displayedValues.length\"\n [attr.aria-required]=\"required\"\n [attr.tabindex]=\"readOnly || disabled ? -1 : null\"\n [enable]=\"autoComplete && !mobile\"\n [displayFn]=\"displayFn\"\n [options]=\"dropdownValues\"\n [inputText]=\"inputText\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [attr.aria-readonly]=\"readOnly\"\n [placeholder]=\"placeholder\"\n [id]=\"inputId\"\n [(ngModel)]=\"inputText\"\n (onComplete)=\"handleAutoComplete($event)\"\n (keydown)=\"onInputKeydownHandler($event)\"\n (paste)=\"onInputKeydownHandler('fromPaste')\"\n (ngModelChange)=\"handleSearchTermChange()\"\n (blur)=\"handleBlur()\"\n />\n @if ((isSearch || showClearButton) && inputText && inputText.length > 0) {\n <span\n class=\"fd-input-group__addon fd-input-group__addon--button\"\n [class.fd-shellbar__input-group-addon]=\"inShellbar\"\n >\n <button\n fd-button\n class=\"fd-input-group__button\"\n type=\"button\"\n [fdType]=\"inShellbar ? 'standard' : 'transparent'\"\n title=\"Clear input\"\n [class.fd-shellbar__button]=\"inShellbar\"\n [attr.tabindex]=\"clearButtonFocusable ? 0 : -1\"\n (focus)=\"clearInputBtnFocus()\"\n (blur)=\"clearInputBtnBlur()\"\n (click)=\"_handleClearSearchTerm()\"\n >\n <fd-icon glyph=\"decline\"></fd-icon>\n </button>\n </span>\n }\n </fd-input-group>\n <div [id]=\"comboboxId + '-list-results'\" class=\"fd-combobox-count-list-results\">\n {{ displayedValues.length || 0 }} result list items\n </div>\n</ng-template>\n<ng-template #listTemplate>\n <ul\n fd-list\n class=\"fd-combobox-custom-list\"\n [dropdownMode]=\"true\"\n [id]=\"comboboxId + '-result'\"\n role=\"listbox\"\n [attr.aria-labelledby]=\"comboboxId + '-search'\"\n [style.maxHeight]=\"!mobile && maxHeight\"\n [hasMessage]=\"listMessages && listMessages.length > 0\"\n [byline]=\"byline\"\n [tabindex]=\"0\"\n (keydown.tab)=\"_close()\"\n (keydown.shift.tab)=\"_close()\"\n (focusEscapeList)=\"handleListFocusEscape($event)\"\n >\n <ng-content></ng-content>\n @if (groupFn) {\n @for (group of displayedValues | listGroupPipe: groupFn; track group.key; let groupIndex = $index) {\n <li\n fd-list-item\n fd-list-group-header\n ariaRole=\"group\"\n [attr.aria-roledescription]=\"'coreMultiComboBox.listGroupHeader' | fdTranslate\"\n [attr.aria-owns]=\"_getGroupItemIds(groupIndex)\"\n [attr.aria-label]=\"group.key\"\n >\n <span fd-list-title>{{ group.key }}</span>\n </li>\n @for (term of group.value; track $index; let index = $index) {\n <li\n fd-list-item\n #item=\"fdListItem\"\n ariaRole=\"option\"\n [attr.aria-placeholder]=\"group.key\"\n [attr.aria-setsize]=\"group.value.length\"\n [attr.aria-posinset]=\"index + 1\"\n [attr.id-with-group-index]=\"item.id + '-group-' + groupIndex\"\n class=\"fd-combobox-list-item\"\n [selected]=\"isSelected(term)\"\n [value]=\"term\"\n (keydown)=\"onItemKeyDownHandler($event, term)\"\n (mousedown)=\"_itemMousedown = true\"\n (click)=\"onMenuClickHandler(term)\"\n (focus)=\"onItemFocused(term)\"\n >\n <ng-template\n [ngTemplateOutlet]=\"itemSource\"\n [ngTemplateOutletContext]=\"{ term: term }\"\n ></ng-template>\n </li>\n }\n }\n } @else {\n @for (term of displayedValues; track $index) {\n <li\n fd-list-item\n ariaRole=\"option\"\n [tabindex]=\"0\"\n class=\"fd-combobox-list-item\"\n [selected]=\"isSelected(term)\"\n (keydown)=\"onItemKeyDownHandler($event, term)\"\n (mousedown)=\"_itemMousedown = true\"\n (click)=\"onMenuClickHandler(term)\"\n [value]=\"term\"\n (focus)=\"onItemFocused(term)\"\n >\n <ng-template\n [ngTemplateOutlet]=\"itemSource\"\n [ngTemplateOutletContext]=\"{ term: term }\"\n ></ng-template>\n </li>\n }\n }\n </ul>\n</ng-template>\n", styles: [".fd-combobox-custom-class,.fd-combobox-custom-class .fd-combobox-shellbar-custom{display:inline-block}.fd-list__item.fd-combobox-list-item{cursor:pointer}.fd-combobox-full-width{width:100%}.fd-combobox-count-list-results{position:absolute;opacity:0;z-index:-1}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: PopoverComponent, selector: "fd-popover", inputs: ["title", "trigger", "fixedPosition", "id", "mobile", "mobileConfig", "preventSpaceKeyScroll"] }, { kind: "component", type: PopoverControlComponent, selector: "fd-popover-control, [fdPopoverControl]" }, { kind: "component", type: PopoverBodyComponent, selector: "fd-popover-body", inputs: ["minWidth", "maxWidth", "minHeight", "maxHeight"] }, { kind: "component", type: ListComponent, selector: "[fd-list], [fdList]", inputs: ["dropdownMode", "multiInputMode", "mobileMode", "hasMessage", "noBorder", "navigationIndicator", "selection", "keyboardSupport", "byline", "subline", "theme", "unreadIndicator", "role", "settingsList", "settingsListFooter"], outputs: ["focusEscapeList"] }, { kind: "component", type: ListItemComponent, selector: "[fdListItem] ,[fd-list-item]", inputs: ["selected", "noData", "action", "interactive", "growing", "counter", "active", "unread", "byline", "ariaRole", "id", "preventClick", "settingsListTpl"], outputs: ["keyDown"], exportAs: ["fdListItem"] }, { kind: "directive", type: ListTitleDirective, selector: "[fd-list-title], [fdListTitle]", inputs: ["wrap", "truncate"] }, { kind: "directive", type: ListGroupHeaderDirective, selector: "[fdListGroupHeader], [fd-list-group-header]", inputs: ["nativeElementId"], outputs: ["keyDown"] }, { kind: "component", type: InputGroupComponent, selector: "fd-input-group", inputs: ["placement", "required", "inline", "addOnText", "buttonFocusable", "type", "glyph", "glyphFont", "button", "isControl", "showFocus", "isExpanded", "glyphAriaLabel", "addonButtonAriaHidden", "iconTitle", "ariaLabelledBy", "ariaLabel"], outputs: ["addOnButtonClicked", "search"] }, { kind: "directive", type: InputGroupInputDirective, selector: "[fdInputGroupInput], [fd-input-group-input]", inputs: ["class"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: AutoCompleteDirective, selector: "[fdkAutoComplete]", inputs: ["options", "inputText", "enable", "displayFn", "matcher"], outputs: ["onComplete"] }, { kind: "component", type: ButtonComponent, selector: "button[fd-button], a[fd-button], span[fd-button]", inputs: ["class", "id"], exportAs: ["fd-button"] }, { kind: "component", type: IconComponent, selector: "fd-icon", inputs: ["glyph", "font", "color", "background", "class", "ariaLabel", "ariaHidden"] }, { kind: "ngmodule", type: ContentDensityModule }, { kind: "directive", type: TruncatedTitleDirective, selector: "[fdkTruncatedTitle], [fdTruncatedTitle], [fd-truncate-title]" }, { kind: "pipe", type: DisplayFnPipe, name: "displayFnPipe" }, { kind: "pipe", type: SearchHighlightPipe, name: "highlight" }, { kind: "pipe", type: FdTranslatePipe, name: "fdTranslate" }, { kind: "pipe", type: ListGroupPipe, name: "listGroupPipe" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
736
772
|
}
|
|
737
773
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: ComboboxComponent, decorators: [{
|
|
738
774
|
type: Component,
|
|
@@ -776,7 +812,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.4", ngImpor
|
|
|
776
812
|
FdTranslatePipe,
|
|
777
813
|
ListGroupPipe,
|
|
778
814
|
TruncatedTitleDirective
|
|
779
|
-
], template: "<ng-template [ngTemplateOutlet]=\"mobile ? mobileTemplate : desktopTemplate\"></ng-template>\n<ng-template #desktopTemplate>\n <fd-popover\n additionalBodyClass=\"fd-popover-custom-list\"\n [class.fd-combobox-full-width]=\"isSearch || showClearButton\"\n [isOpen]=\"open && displayedValues && displayedValues.length > 0\"\n (isOpenChange)=\"isOpenChangeHandle($event)\"\n [fillControlMode]=\"fillControlMode\"\n [scrollStrategy]=\"_repositionScrollStrategy\"\n [focusTrapped]=\"true\"\n [triggers]=\"triggers\"\n [disabled]=\"disabled || readOnly\"\n [maxWidth]=\"!mobile && noDropDownMaxWidth ? null : dropDownMaxWidthPx\"\n [style.width]=\"width && '100%'\"\n [closeOnOutsideClick]=\"closeOnOutsideClick\"\n >\n <fd-popover-control>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n </fd-popover-control>\n <fd-popover-body [hidden]=\"!displayedValues.length\">\n <ng-template [ngTemplateOutlet]=\"listTemplate\"></ng-template>\n <ng-content></ng-content>\n </fd-popover-body>\n </fd-popover>\n</ng-template>\n<ng-template let-term=\"term\" #itemSource>\n @if (!_customRenderer) {\n <span\n fd-list-title\n fdTruncatedTitle\n [innerHTML]=\"term | displayFnPipe: displayFn | highlight: inputText : highlighting && filterHighlight\"\n >\n </span>\n } @else {\n <ng-template\n [ngTemplateOutlet]=\"_customRenderer\"\n [ngTemplateOutletContext]=\"{ $implicit: term, inputText: inputText }\"\n ></ng-template>\n }\n</ng-template>\n<ng-template #mobileTemplate>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n</ng-template>\n<ng-template #controlTemplate>\n <fd-input-group\n [button]=\"showDropdownButton\"\n [glyph]=\"showDropdownButton ? glyphValue : null\"\n [glyphFont]=\"isSearch ? _defaultFontFamily : glyphFont\"\n [state]=\"state\"\n [buttonFocusable]=\"buttonFocusable\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [isControl]=\"true\"\n [isExpanded]=\"!mobile && open && displayedValues.length > 0\"\n [showFocus]=\"!clearInputBtnFocused\"\n [glyphAriaLabel]=\"ariaLabel || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n [iconTitle]=\"title || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n (addOnButtonClicked)=\"onPrimaryButtonClick()\"\n (click)=\"mobile && isOpenChangeHandle(true)\"\n >\n <input\n #searchInputElement\n fdkAutoComplete\n fd-input-group-input\n type=\"text\"\n role=\"combobox\"\n autocomplete=\"off\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.aria-describedby]=\"comboboxId + '-list-results'\"\n [attr.aria-autocomplete]=\"autoComplete && !mobile ? 'list' : null\"\n [attr.aria-
|
|
815
|
+
], template: "<ng-template [ngTemplateOutlet]=\"mobile ? mobileTemplate : desktopTemplate\"></ng-template>\n<ng-template #desktopTemplate>\n <fd-popover\n additionalBodyClass=\"fd-popover-custom-list\"\n [class.fd-combobox-full-width]=\"isSearch || showClearButton\"\n [isOpen]=\"open && displayedValues && displayedValues.length > 0\"\n (isOpenChange)=\"isOpenChangeHandle($event)\"\n [fillControlMode]=\"fillControlMode\"\n [scrollStrategy]=\"_repositionScrollStrategy\"\n [focusTrapped]=\"true\"\n [triggers]=\"triggers\"\n [disabled]=\"disabled || readOnly\"\n [maxWidth]=\"!mobile && noDropDownMaxWidth ? null : dropDownMaxWidthPx\"\n [style.width]=\"width && '100%'\"\n [closeOnOutsideClick]=\"closeOnOutsideClick\"\n >\n <fd-popover-control>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n </fd-popover-control>\n <fd-popover-body [hidden]=\"!displayedValues.length\">\n <ng-template [ngTemplateOutlet]=\"listTemplate\"></ng-template>\n <ng-content></ng-content>\n </fd-popover-body>\n </fd-popover>\n</ng-template>\n<ng-template let-term=\"term\" #itemSource>\n @if (!_customRenderer) {\n <span\n fd-list-title\n fdTruncatedTitle\n [innerHTML]=\"term | displayFnPipe: displayFn | highlight: inputText : highlighting && filterHighlight\"\n >\n </span>\n } @else {\n <ng-template\n [ngTemplateOutlet]=\"_customRenderer\"\n [ngTemplateOutletContext]=\"{ $implicit: term, inputText: inputText }\"\n ></ng-template>\n }\n</ng-template>\n<ng-template #mobileTemplate>\n <ng-template [ngTemplateOutlet]=\"controlTemplate\"></ng-template>\n</ng-template>\n<ng-template #controlTemplate>\n <fd-input-group\n [button]=\"showDropdownButton\"\n [glyph]=\"showDropdownButton ? glyphValue : null\"\n [glyphFont]=\"isSearch ? _defaultFontFamily : glyphFont\"\n [state]=\"state\"\n [buttonFocusable]=\"buttonFocusable\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [isControl]=\"true\"\n [isExpanded]=\"!mobile && open && displayedValues.length > 0\"\n [showFocus]=\"!clearInputBtnFocused\"\n [glyphAriaLabel]=\"ariaLabel || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n [iconTitle]=\"title || ('platformMultiCombobox.inputGlyphAriaLabel' | fdTranslate)\"\n (addOnButtonClicked)=\"onPrimaryButtonClick()\"\n (click)=\"mobile && isOpenChangeHandle(true)\"\n >\n <input\n #searchInputElement\n fdkAutoComplete\n fd-input-group-input\n type=\"text\"\n role=\"combobox\"\n autocomplete=\"off\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.aria-describedby]=\"comboboxId + '-list-results'\"\n [attr.aria-autocomplete]=\"autoComplete && !mobile ? 'list' : null\"\n [attr.aria-haspopup]=\"autoComplete && !mobile\"\n [attr.aria-expanded]=\"!mobile && open && displayedValues.length\"\n [attr.aria-required]=\"required\"\n [attr.tabindex]=\"readOnly || disabled ? -1 : null\"\n [enable]=\"autoComplete && !mobile\"\n [displayFn]=\"displayFn\"\n [options]=\"dropdownValues\"\n [inputText]=\"inputText\"\n [disabled]=\"disabled\"\n [readonly]=\"readOnly\"\n [attr.aria-readonly]=\"readOnly\"\n [placeholder]=\"placeholder\"\n [id]=\"inputId\"\n [(ngModel)]=\"inputText\"\n (onComplete)=\"handleAutoComplete($event)\"\n (keydown)=\"onInputKeydownHandler($event)\"\n (paste)=\"onInputKeydownHandler('fromPaste')\"\n (ngModelChange)=\"handleSearchTermChange()\"\n (blur)=\"handleBlur()\"\n />\n @if ((isSearch || showClearButton) && inputText && inputText.length > 0) {\n <span\n class=\"fd-input-group__addon fd-input-group__addon--button\"\n [class.fd-shellbar__input-group-addon]=\"inShellbar\"\n >\n <button\n fd-button\n class=\"fd-input-group__button\"\n type=\"button\"\n [fdType]=\"inShellbar ? 'standard' : 'transparent'\"\n title=\"Clear input\"\n [class.fd-shellbar__button]=\"inShellbar\"\n [attr.tabindex]=\"clearButtonFocusable ? 0 : -1\"\n (focus)=\"clearInputBtnFocus()\"\n (blur)=\"clearInputBtnBlur()\"\n (click)=\"_handleClearSearchTerm()\"\n >\n <fd-icon glyph=\"decline\"></fd-icon>\n </button>\n </span>\n }\n </fd-input-group>\n <div [id]=\"comboboxId + '-list-results'\" class=\"fd-combobox-count-list-results\">\n {{ displayedValues.length || 0 }} result list items\n </div>\n</ng-template>\n<ng-template #listTemplate>\n <ul\n fd-list\n class=\"fd-combobox-custom-list\"\n [dropdownMode]=\"true\"\n [id]=\"comboboxId + '-result'\"\n role=\"listbox\"\n [attr.aria-labelledby]=\"comboboxId + '-search'\"\n [style.maxHeight]=\"!mobile && maxHeight\"\n [hasMessage]=\"listMessages && listMessages.length > 0\"\n [byline]=\"byline\"\n [tabindex]=\"0\"\n (keydown.tab)=\"_close()\"\n (keydown.shift.tab)=\"_close()\"\n (focusEscapeList)=\"handleListFocusEscape($event)\"\n >\n <ng-content></ng-content>\n @if (groupFn) {\n @for (group of displayedValues | listGroupPipe: groupFn; track group.key; let groupIndex = $index) {\n <li\n fd-list-item\n fd-list-group-header\n ariaRole=\"group\"\n [attr.aria-roledescription]=\"'coreMultiComboBox.listGroupHeader' | fdTranslate\"\n [attr.aria-owns]=\"_getGroupItemIds(groupIndex)\"\n [attr.aria-label]=\"group.key\"\n >\n <span fd-list-title>{{ group.key }}</span>\n </li>\n @for (term of group.value; track $index; let index = $index) {\n <li\n fd-list-item\n #item=\"fdListItem\"\n ariaRole=\"option\"\n [attr.aria-placeholder]=\"group.key\"\n [attr.aria-setsize]=\"group.value.length\"\n [attr.aria-posinset]=\"index + 1\"\n [attr.id-with-group-index]=\"item.id + '-group-' + groupIndex\"\n class=\"fd-combobox-list-item\"\n [selected]=\"isSelected(term)\"\n [value]=\"term\"\n (keydown)=\"onItemKeyDownHandler($event, term)\"\n (mousedown)=\"_itemMousedown = true\"\n (click)=\"onMenuClickHandler(term)\"\n (focus)=\"onItemFocused(term)\"\n >\n <ng-template\n [ngTemplateOutlet]=\"itemSource\"\n [ngTemplateOutletContext]=\"{ term: term }\"\n ></ng-template>\n </li>\n }\n }\n } @else {\n @for (term of displayedValues; track $index) {\n <li\n fd-list-item\n ariaRole=\"option\"\n [tabindex]=\"0\"\n class=\"fd-combobox-list-item\"\n [selected]=\"isSelected(term)\"\n (keydown)=\"onItemKeyDownHandler($event, term)\"\n (mousedown)=\"_itemMousedown = true\"\n (click)=\"onMenuClickHandler(term)\"\n [value]=\"term\"\n (focus)=\"onItemFocused(term)\"\n >\n <ng-template\n [ngTemplateOutlet]=\"itemSource\"\n [ngTemplateOutletContext]=\"{ term: term }\"\n ></ng-template>\n </li>\n }\n }\n </ul>\n</ng-template>\n", styles: [".fd-combobox-custom-class,.fd-combobox-custom-class .fd-combobox-shellbar-custom{display:inline-block}.fd-list__item.fd-combobox-list-item{cursor:pointer}.fd-combobox-full-width{width:100%}.fd-combobox-count-list-results{position:absolute;opacity:0;z-index:-1}\n"] }]
|
|
780
816
|
}], ctorParameters: () => [{ type: i1.Overlay }, { type: i0.ChangeDetectorRef }, { type: i0.Injector }, { type: i0.ViewContainerRef }, { type: i2.DynamicComponentService }, { type: i2.FocusTrapService }, { type: i3.ContentDensityObserver }], propDecorators: { comboboxId: [{
|
|
781
817
|
type: Input
|
|
782
818
|
}], inputId: [{
|