@fundamental-ngx/cdk 0.43.17 → 0.43.19

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,27 +1,25 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, Injectable, Optional, Inject, isDevMode, inject, Directive, EventEmitter, Input, Output, HostListener, NgModule, ContentChildren, forwardRef, HostBinding, ElementRef, INJECTOR, ContentChild, NgZone, Renderer2, Self, SkipSelf, PLATFORM_ID, QueryList, ViewContainerRef, Component, Injector, NgModuleFactory, Pipe, TemplateRef, ViewChild } from '@angular/core';
2
+ import { InjectionToken, Injectable, Optional, Inject, isDevMode, inject, ElementRef, INJECTOR, Directive, EventEmitter, Input, Output, NgModule, ContentChildren, forwardRef, HostBinding, HostListener, ContentChild, NgZone, Renderer2, Self, SkipSelf, PLATFORM_ID, QueryList, ViewContainerRef, Component, Injector, NgModuleFactory, Pipe, TemplateRef, ViewChild } from '@angular/core';
3
3
  import { DOCUMENT, CommonModule, AsyncPipe } from '@angular/common';
4
- import * as i1$3 from 'rxjs';
5
- import { BehaviorSubject, Subject, ReplaySubject, Observable, fromEvent, NEVER, merge, firstValueFrom, Subscription, takeUntil as takeUntil$1, startWith as startWith$1, switchMap, combineLatest, filter as filter$1, isObservable, of, map as map$1, take as take$1 } from 'rxjs';
4
+ import { BehaviorSubject, Subject, ReplaySubject, Observable, fromEvent, NEVER, merge, switchMap, first, map as map$1, takeUntil as takeUntil$1, Subscription, startWith as startWith$1, combineLatest, firstValueFrom, filter as filter$1, isObservable, of, take as take$1 } from 'rxjs';
6
5
  import { takeUntil, filter, distinctUntilChanged, startWith, map, tap, take, debounceTime, mapTo, pairwise, finalize, shareReplay, switchMap as switchMap$1, delay } from 'rxjs/operators';
7
6
  import * as i1 from '@angular/router';
8
7
  import * as i2 from '@angular/platform-browser';
9
8
  import { EVENT_MANAGER_PLUGINS } from '@angular/platform-browser';
10
9
  import { RIGHT_ARROW, DOWN_ARROW, LEFT_ARROW, UP_ARROW, SPACE, ESCAPE, DELETE, ENTER, MAC_ENTER, TAB, HOME, END, ALT, CONTROL, META, SHIFT, BACKSPACE, A, C, V, X, PAGE_UP, PAGE_DOWN, DASH, NUMPAD_MINUS, NUMPAD_ZERO, NUMPAD_ONE, NUMPAD_TWO, NUMPAD_THREE, NUMPAD_FOUR, NUMPAD_FIVE, NUMPAD_SIX, NUMPAD_SEVEN, NUMPAD_EIGHT, NUMPAD_NINE, F2, hasModifierKey } from '@angular/cdk/keycodes';
11
- import { coerceBooleanProperty, coerceElement, coerceNumberProperty, coerceArray, coerceCssPixelValue } from '@angular/cdk/coercion';
10
+ import { createFocusTrap } from 'focus-trap';
12
11
  import * as i1$1 from '@angular/cdk/a11y';
13
12
  import { FocusKeyManager, LiveAnnouncer } from '@angular/cdk/a11y';
14
- import { createFocusTrap } from 'focus-trap';
13
+ import { coerceElement, coerceBooleanProperty, coerceNumberProperty, coerceArray, coerceCssPixelValue } from '@angular/cdk/coercion';
15
14
  import * as i1$2 from '@angular/cdk/observers';
16
- import { __awaiter, __decorate, __metadata } from 'tslib';
17
- import { TranslationResolver, FD_LANGUAGE } from '@fundamental-ngx/i18n';
18
- import * as i1$4 from '@angular/cdk/overlay';
15
+ import * as i1$3 from '@angular/cdk/overlay';
19
16
  import { ViewportRuler, OverlayConfig, OverlayContainer } from '@angular/cdk/overlay';
17
+ import { __awaiter, __decorate, __metadata } from 'tslib';
20
18
  import { get, findLastIndex } from 'lodash-es';
21
19
  import equal from 'fast-deep-equal';
22
- import * as i1$5 from '@angular/cdk/drag-drop';
20
+ import * as i1$4 from '@angular/cdk/drag-drop';
23
21
  import { DragDrop, moveItemInArray, transferArrayItem, DragDropModule } from '@angular/cdk/drag-drop';
24
- import * as i1$6 from '@angular/cdk/portal';
22
+ import * as i1$5 from '@angular/cdk/portal';
25
23
  import { DomPortal, ComponentPortal, TemplatePortal, PortalModule, BasePortalOutlet, CdkPortalOutlet } from '@angular/cdk/portal';
26
24
  import escape from 'lodash-es/escape';
27
25
  import { trigger, state, style, transition, animate } from '@angular/animations';
@@ -320,638 +318,162 @@ class DeprecatedSelector {
320
318
  }
321
319
  }
322
320
 
323
- /* eslint-disable @typescript-eslint/member-ordering */
324
- class DeprecatedAutoCompleteDirective extends DeprecatedSelector {
321
+ /** Determines whether provided value is valid content density */
322
+ function isValidContentDensity(size) {
323
+ return size === 'cozy' || size === 'compact' || size === 'condensed';
325
324
  }
326
- DeprecatedAutoCompleteDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedAutoCompleteDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
327
- DeprecatedAutoCompleteDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedAutoCompleteDirective, isStandalone: true, selector: "[fdAutoComplete], [fd-auto-complete]", providers: [
328
- {
329
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
330
- useValue: getDeprecatedModel('[fdkAutoComplete]', '[fdAutoComplete], [fd-auto-complete]')
331
- }
332
- ], usesInheritance: true, ngImport: i0 });
333
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedAutoCompleteDirective, decorators: [{
334
- type: Directive,
335
- args: [{
336
- // eslint-disable-next-line @angular-eslint/directive-selector
337
- selector: '[fdAutoComplete], [fd-auto-complete]',
338
- standalone: true,
339
- providers: [
340
- {
341
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
342
- useValue: getDeprecatedModel('[fdkAutoComplete]', '[fdAutoComplete], [fd-auto-complete]')
343
- }
344
- ]
345
- }]
346
- }] });
347
- class AutoCompleteDirective {
348
- /** @hidden */
349
- constructor(_elementRef) {
350
- this._elementRef = _elementRef;
351
- /** Whether the auto complete directive should be enabled */
352
- this.enable = true;
353
- /** Matcher function for testing the str for a search term */
354
- this.matcher = (str, searchTerm) => str.startsWith(searchTerm);
355
- /** Display function. Accepts an object of the same type as the
356
- * items passed to dropdownValues as argument, and outputs a string.
357
- * An arrow function can be used to access the *this* keyword in the calling component.
358
- * See search input examples for details. */
359
- this.displayFn = this._defaultDisplay;
360
- /** Event thrown, when the auto ahead text is accepted */
361
- this.onComplete = new EventEmitter();
362
- /** @hidden */
363
- this._completeKeys = [ENTER];
364
- /** @hidden */
365
- this._fillKeys = [LEFT_ARROW, RIGHT_ARROW];
366
- /** @hidden */
367
- this._stopKeys = [BACKSPACE, DELETE, ESCAPE];
368
- }
325
+ /**
326
+ * Determines if "compact" styles should be applied based on provided content density
327
+ */
328
+ function isCompactDensity(size) {
329
+ return isValidContentDensity(size) && size !== 'cozy';
330
+ }
331
+
332
+ const DEFAULT_CONTENT_DENSITY = 'cozy';
333
+ /**
334
+ * Service taking care of ContentDensity
335
+ */
336
+ class ContentDensityService {
369
337
  /** @hidden */
370
- handleKeyboardEvent(event) {
371
- if (this.enable) {
372
- if (KeyUtil.isKeyCode(event, this._stopKeys)) {
373
- this._elementRef.nativeElement.value = this.inputText;
374
- }
375
- else if (KeyUtil.isKeyCode(event, this._completeKeys)) {
376
- this._sendCompleteEvent(true);
377
- this._moveIndicatorToLastCharacter();
378
- }
379
- else if (KeyUtil.isKeyCode(event, this._fillKeys)) {
380
- this._sendCompleteEvent(false);
381
- }
382
- else if (!this._isControlKey(event) && this.inputText) {
383
- /** Prevention from triggering typeahead, when having crtl/cmd + keys */
384
- if (!this._triggerTypeAhead()) {
385
- return;
386
- }
387
- this.oldValue = this.inputText;
388
- const item = this.options.find((option) => this.matcher(this.displayFn(option).toLocaleLowerCase(), this.inputText.toLocaleLowerCase()));
389
- if (item) {
390
- this._typeahead(this.displayFn(item));
391
- }
392
- }
338
+ constructor() {
339
+ /** Content Density BehaviourSubject */
340
+ this.contentDensity = new BehaviorSubject(DEFAULT_CONTENT_DENSITY);
341
+ if (isDevMode()) {
342
+ console.warn(`[Deprecated] ContentDensityService is deprecated and will be removed in the next major version.
343
+ Please use ContentDensityControllerService instead, or use the ContentDensityModule forRoot method.`);
393
344
  }
394
- this.lastKeyUpEvent = event;
395
345
  }
396
346
  /** @hidden */
397
- _typeahead(displayedValue) {
398
- this._elementRef.nativeElement.value = displayedValue;
399
- const selectionStartIndex = this.inputText.length;
400
- this._elementRef.nativeElement.setSelectionRange(selectionStartIndex, displayedValue.length);
347
+ get _contentDensityListener() {
348
+ return this.contentDensity.pipe(distinctUntilChanged(), startWith(this.contentDensity.getValue()));
401
349
  }
402
350
  /** @hidden */
403
- _isControlKey(event) {
404
- return KeyUtil.isKeyCode(event, CONTROL) || event.ctrlKey;
351
+ get _isCompactDensity() {
352
+ return this._contentDensityListener.pipe(map((density) => isCompactDensity(density)));
405
353
  }
354
+ }
355
+ ContentDensityService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ContentDensityService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
356
+ ContentDensityService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ContentDensityService });
357
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ContentDensityService, decorators: [{
358
+ type: Injectable
359
+ }], ctorParameters: function () { return []; } });
360
+
361
+ class DestroyedService extends ReplaySubject {
406
362
  /** @hidden */
407
- _defaultDisplay(value) {
408
- return value;
363
+ constructor() {
364
+ super(1);
409
365
  }
410
366
  /** @hidden */
411
- _triggerTypeAhead() {
412
- if (this.lastKeyUpEvent &&
413
- KeyUtil.isKeyCode(this.lastKeyUpEvent, CONTROL) &&
414
- this.inputText === this.oldValue) {
415
- return false;
367
+ ngOnDestroy() {
368
+ this.next();
369
+ this.complete();
370
+ }
371
+ }
372
+ DestroyedService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DestroyedService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
373
+ DestroyedService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DestroyedService });
374
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DestroyedService, decorators: [{
375
+ type: Injectable
376
+ }], ctorParameters: function () { return []; } });
377
+
378
+ /** Generate a UUID v4 */
379
+ function uuidv4() {
380
+ const modifier = 16;
381
+ return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
382
+ // eslint-disable-next-line no-bitwise
383
+ const r = (Math.random() * modifier) | 0,
384
+ // eslint-disable-next-line no-bitwise
385
+ v = c === 'x' ? r : (r & 0x3) | 0x8;
386
+ return v.toString(modifier);
387
+ });
388
+ }
389
+
390
+ class FocusTrapService {
391
+ constructor() {
392
+ /** @hidden */
393
+ this._focusTrapInstances = new Map();
394
+ }
395
+ /**
396
+ * Creates focus trap instance for defined element
397
+ * @param element Container for which to create focus trap
398
+ * @param userOptions Focus-trap specific configuration
399
+ * @returns {string} Unique ID of focus trap instance
400
+ */
401
+ createFocusTrap(element, userOptions) {
402
+ const uid = uuidv4();
403
+ const trap = createFocusTrap(element, userOptions);
404
+ this._focusTrapInstances.set(uid, trap);
405
+ this.activateFocusTrap(uid);
406
+ return uid;
407
+ }
408
+ /**
409
+ * Activates focus trap for defined ID
410
+ * @param id Unique ID of focus trap instance
411
+ */
412
+ activateFocusTrap(id) {
413
+ if (!this._focusTrapExists(id)) {
414
+ return;
416
415
  }
417
- else {
418
- return true;
416
+ const trap = this.getFocusTrapInstance(id);
417
+ trap === null || trap === void 0 ? void 0 : trap.activate();
418
+ }
419
+ /**
420
+ * Deactivates focus trap for defined ID
421
+ * @param id Unique ID of focus trap instance
422
+ */
423
+ deactivateFocusTrap(id) {
424
+ if (!this._focusTrapExists(id)) {
425
+ return;
426
+ }
427
+ const trap = this.getFocusTrapInstance(id);
428
+ trap === null || trap === void 0 ? void 0 : trap.deactivate();
429
+ this._focusTrapInstances.delete(id);
430
+ }
431
+ /**
432
+ * Pauses current focus trap.
433
+ */
434
+ pauseCurrentFocusTrap() {
435
+ if (this._focusTrapInstances.size === 0) {
436
+ return;
437
+ }
438
+ const trapItem = this._getLastTrapedItem();
439
+ trapItem === null || trapItem === void 0 ? void 0 : trapItem.pause();
440
+ }
441
+ /**
442
+ * Unpauses current focus trap.
443
+ */
444
+ unpauseCurrentFocusTrap() {
445
+ if (this._focusTrapInstances.size === 0) {
446
+ return;
419
447
  }
448
+ const trapItem = this._getLastTrapedItem();
449
+ trapItem === null || trapItem === void 0 ? void 0 : trapItem.unpause();
450
+ }
451
+ /**
452
+ * Get focus trap instance by ID.
453
+ * @param id ID of the instance.
454
+ * @returns Focus trap instance if exists.
455
+ */
456
+ getFocusTrapInstance(id) {
457
+ return this._focusTrapInstances.get(id);
420
458
  }
421
459
  /** @hidden */
422
- _sendCompleteEvent(forceClose) {
423
- this.onComplete.emit({
424
- term: this._elementRef.nativeElement.value,
425
- forceClose
426
- });
460
+ _getLastTrapedItem() {
461
+ const lastItem = Array.from(this._focusTrapInstances).pop();
462
+ return lastItem ? lastItem[1] : undefined;
427
463
  }
428
464
  /** @hidden */
429
- _moveIndicatorToLastCharacter() {
430
- var _a, _b;
431
- const inputTextLength = (_b = (_a = this.inputText) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0;
432
- this._elementRef.nativeElement.setSelectionRange(inputTextLength, inputTextLength);
465
+ _focusTrapExists(id) {
466
+ return this._focusTrapInstances.has(id);
433
467
  }
434
468
  }
435
- AutoCompleteDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
436
- AutoCompleteDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: AutoCompleteDirective, isStandalone: true, selector: "[fdkAutoComplete], [fdAutoComplete], [fd-auto-complete]", inputs: { options: "options", inputText: "inputText", enable: "enable", matcher: "matcher", displayFn: "displayFn" }, outputs: { onComplete: "onComplete" }, host: { listeners: { "keyup": "handleKeyboardEvent($event)" } }, ngImport: i0 });
437
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteDirective, decorators: [{
438
- type: Directive,
469
+ FocusTrapService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusTrapService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
470
+ FocusTrapService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusTrapService, providedIn: 'root' });
471
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusTrapService, decorators: [{
472
+ type: Injectable,
439
473
  args: [{
440
- selector: '[fdkAutoComplete], [fdAutoComplete], [fd-auto-complete]',
441
- standalone: true
474
+ providedIn: 'root'
442
475
  }]
443
- }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { options: [{
444
- type: Input
445
- }], inputText: [{
446
- type: Input
447
- }], enable: [{
448
- type: Input
449
- }], matcher: [{
450
- type: Input
451
- }], displayFn: [{
452
- type: Input
453
- }], onComplete: [{
454
- type: Output
455
- }], handleKeyboardEvent: [{
456
- type: HostListener,
457
- args: ['keyup', ['$event']]
458
- }] } });
459
-
460
- class AutoCompleteModule {
461
- }
462
- AutoCompleteModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
463
- AutoCompleteModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule, imports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective], exports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective] });
464
- AutoCompleteModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule });
465
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule, decorators: [{
466
- type: NgModule,
467
- args: [{
468
- imports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective],
469
- exports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective],
470
- declarations: []
471
- }]
472
- }] });
473
-
474
- const FOCUSABLE_ITEM = new InjectionToken('Focusable Option');
475
-
476
- class DeprecatedFocusKeyManagerListDirective extends DeprecatedSelector {
477
- }
478
- DeprecatedFocusKeyManagerListDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerListDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
479
- DeprecatedFocusKeyManagerListDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedFocusKeyManagerListDirective, isStandalone: true, selector: "[fd-focus-key-manager-list], [fdFocusKeyManagerList]", providers: [
480
- {
481
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
482
- useValue: getDeprecatedModel('[fdkFocusKeyManagerList]', '[fd-focus-key-manager-list], [fdFocusKeyManagerList]')
483
- }
484
- ], usesInheritance: true, ngImport: i0 });
485
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerListDirective, decorators: [{
486
- type: Directive,
487
- args: [{
488
- // eslint-disable-next-line @angular-eslint/directive-selector
489
- selector: '[fd-focus-key-manager-list], [fdFocusKeyManagerList]',
490
- standalone: true,
491
- providers: [
492
- {
493
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
494
- useValue: getDeprecatedModel('[fdkFocusKeyManagerList]', '[fd-focus-key-manager-list], [fdFocusKeyManagerList]')
495
- }
496
- ]
497
- }]
498
- }] });
499
- /** Directive to apply Angular Material FocusKeyManager to lists.
500
- * To be used with FocusKeyManagerItemDirective
501
- */
502
- class FocusKeyManagerListDirective {
503
- /** @hidden */
504
- get focusKeyManager() {
505
- return this._focusKeyManager;
506
- }
507
- /** @hidden */
508
- constructor(_rtlService, _cdr) {
509
- this._rtlService = _rtlService;
510
- this._cdr = _cdr;
511
- /** @hidden */
512
- this._onDestroy$ = new Subject();
513
- }
514
- /** @hidden */
515
- ngOnChanges(changes) {
516
- if (!this._focusKeyManager) {
517
- return;
518
- }
519
- if ('orientation' in changes) {
520
- this._applyOrientation();
521
- }
522
- if ('skiPredicate' in changes) {
523
- this._focusKeyManager.skipPredicate(this.skipPredicate);
524
- }
525
- }
526
- /** @hidden */
527
- ngAfterContentInit() {
528
- var _a;
529
- this._focusKeyManager = new FocusKeyManager(this._items).skipPredicate(this.skipPredicate);
530
- this._applyOrientation();
531
- this._cdr.detectChanges();
532
- (_a = this._rtlService) === null || _a === void 0 ? void 0 : _a.rtl.pipe(filter(() => this.orientation === 'horizontal'), takeUntil(this._onDestroy$)).subscribe(() => this._applyOrientation());
533
- }
534
- /** @hidden */
535
- ngOnDestroy() {
536
- this._onDestroy$.next();
537
- this._onDestroy$.complete();
538
- this._focusKeyManager.destroy();
539
- }
540
- /** Focus certain list's item */
541
- focusItem(item) {
542
- if (typeof item === 'number') {
543
- this._focusKeyManager.setActiveItem(item);
544
- }
545
- else {
546
- this._focusKeyManager.setActiveItem(item);
547
- }
548
- }
549
- /** @hidden */
550
- _applyOrientation() {
551
- var _a;
552
- switch (this.orientation) {
553
- case 'horizontal':
554
- this._focusKeyManager.withHorizontalOrientation(((_a = this._rtlService) === null || _a === void 0 ? void 0 : _a.rtl.value) ? 'rtl' : 'ltr');
555
- break;
556
- case 'vertical':
557
- this._focusKeyManager.withVerticalOrientation(true);
558
- break;
559
- }
560
- }
561
- }
562
- FocusKeyManagerListDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerListDirective, deps: [{ token: RtlService, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
563
- FocusKeyManagerListDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: FocusKeyManagerListDirective, isStandalone: true, selector: "[fdkFocusKeyManagerList], [fd-focus-key-manager-list], [fdFocusKeyManagerList]", inputs: { orientation: "orientation", skipPredicate: "skipPredicate" }, queries: [{ propertyName: "_items", predicate: FOCUSABLE_ITEM }], usesOnChanges: true, ngImport: i0 });
564
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerListDirective, decorators: [{
565
- type: Directive,
566
- args: [{
567
- selector: `[fdkFocusKeyManagerList], [fd-focus-key-manager-list], [fdFocusKeyManagerList]`,
568
- standalone: true
569
- }]
570
- }], ctorParameters: function () {
571
- return [{ type: RtlService, decorators: [{
572
- type: Optional
573
- }] }, { type: i0.ChangeDetectorRef }];
574
- }, propDecorators: { orientation: [{
575
- type: Input
576
- }], skipPredicate: [{
577
- type: Input
578
- }], _items: [{
579
- type: ContentChildren,
580
- args: [FOCUSABLE_ITEM]
581
- }] } });
582
-
583
- class DeprecatedFocusKeyManagerItemDirective extends DeprecatedSelector {
584
- }
585
- DeprecatedFocusKeyManagerItemDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerItemDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
586
- DeprecatedFocusKeyManagerItemDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedFocusKeyManagerItemDirective, isStandalone: true, selector: "[fd-focus-key-manager-item], [fdFocusKeyManagerItem]", providers: [
587
- {
588
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
589
- useValue: getDeprecatedModel('[fdkFocusKeyManagerItem]', '[fd-focus-key-manager-item], [fdFocusKeyManagerItem]')
590
- }
591
- ], usesInheritance: true, ngImport: i0 });
592
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerItemDirective, decorators: [{
593
- type: Directive,
594
- args: [{
595
- // eslint-disable-next-line @angular-eslint/directive-selector
596
- selector: '[fd-focus-key-manager-item], [fdFocusKeyManagerItem]',
597
- standalone: true,
598
- providers: [
599
- {
600
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
601
- useValue: getDeprecatedModel('[fdkFocusKeyManagerItem]', '[fd-focus-key-manager-item], [fdFocusKeyManagerItem]')
602
- }
603
- ]
604
- }]
605
- }] });
606
- /** Directive to apply Angular Material FocusKeyManager to lists.
607
- * To be used with FocusKeyManagerItemDirective
608
- */
609
- class FocusKeyManagerItemDirective {
610
- /** Whether item should be initially focused */
611
- set initialFocus(value) {
612
- this._initialFocus = coerceBooleanProperty(value);
613
- }
614
- /** @hidden */
615
- get _tabindex() {
616
- var _a, _b;
617
- if (this._initialFocus) {
618
- return 0;
619
- }
620
- return (_b = (_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.tabIndex) !== null && _b !== void 0 ? _b : -1;
621
- }
622
- /** Native element of the item */
623
- get nativeElement() {
624
- var _a;
625
- return (_a = this._elRef) === null || _a === void 0 ? void 0 : _a.nativeElement;
626
- }
627
- /** @hidden */
628
- get _focusKeyManager() {
629
- return this._list.focusKeyManager;
630
- }
631
- /** @hidden */
632
- constructor(_list, _elRef) {
633
- this._list = _list;
634
- this._elRef = _elRef;
635
- /** @hidden */
636
- this._initialFocus = false;
637
- }
638
- /** @hidden */
639
- _onFocus() {
640
- var _a;
641
- // For cases where initially selected item doesn't have 0 index
642
- (_a = this._focusKeyManager) === null || _a === void 0 ? void 0 : _a.updateActiveItem(this);
643
- }
644
- /** @hidden */
645
- _onKeydown(event) {
646
- var _a;
647
- (_a = this._focusKeyManager) === null || _a === void 0 ? void 0 : _a.onKeydown(event);
648
- }
649
- /** Focus current item native element */
650
- focus() {
651
- var _a;
652
- (_a = this._elRef) === null || _a === void 0 ? void 0 : _a.nativeElement.focus();
653
- }
654
- }
655
- FocusKeyManagerItemDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerItemDirective, deps: [{ token: FocusKeyManagerListDirective }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
656
- FocusKeyManagerItemDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: FocusKeyManagerItemDirective, isStandalone: true, selector: "[fdkFocusKeyManagerItem], [fd-focus-key-manager-item], [fdFocusKeyManagerItem]", inputs: { initialFocus: "initialFocus", _tabindex: "_tabindex" }, host: { listeners: { "focus": "_onFocus()", "keydown": "_onKeydown($event)" }, properties: { "attr.tabindex": "this._tabindex" } }, providers: [{ provide: FOCUSABLE_ITEM, useExisting: forwardRef(() => FocusKeyManagerItemDirective) }], ngImport: i0 });
657
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerItemDirective, decorators: [{
658
- type: Directive,
659
- args: [{
660
- selector: '[fdkFocusKeyManagerItem], [fd-focus-key-manager-item], [fdFocusKeyManagerItem]',
661
- standalone: true,
662
- providers: [{ provide: FOCUSABLE_ITEM, useExisting: forwardRef(() => FocusKeyManagerItemDirective) }]
663
- }]
664
- }], ctorParameters: function () { return [{ type: FocusKeyManagerListDirective }, { type: i0.ElementRef }]; }, propDecorators: { initialFocus: [{
665
- type: Input
666
- }], _tabindex: [{
667
- type: Input
668
- }, {
669
- type: HostBinding,
670
- args: ['attr.tabindex']
671
- }], _onFocus: [{
672
- type: HostListener,
673
- args: ['focus']
674
- }], _onKeydown: [{
675
- type: HostListener,
676
- args: ['keydown', ['$event']]
677
- }] } });
678
-
679
- class FocusKeyManagerHelpersModule {
680
- }
681
- FocusKeyManagerHelpersModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
682
- FocusKeyManagerHelpersModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule, imports: [FocusKeyManagerItemDirective,
683
- FocusKeyManagerListDirective,
684
- DeprecatedFocusKeyManagerItemDirective,
685
- DeprecatedFocusKeyManagerListDirective], exports: [FocusKeyManagerItemDirective,
686
- FocusKeyManagerListDirective,
687
- DeprecatedFocusKeyManagerItemDirective,
688
- DeprecatedFocusKeyManagerListDirective] });
689
- FocusKeyManagerHelpersModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule });
690
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule, decorators: [{
691
- type: NgModule,
692
- args: [{
693
- imports: [
694
- FocusKeyManagerItemDirective,
695
- FocusKeyManagerListDirective,
696
- DeprecatedFocusKeyManagerItemDirective,
697
- DeprecatedFocusKeyManagerListDirective
698
- ],
699
- exports: [
700
- FocusKeyManagerItemDirective,
701
- FocusKeyManagerListDirective,
702
- DeprecatedFocusKeyManagerItemDirective,
703
- DeprecatedFocusKeyManagerListDirective
704
- ]
705
- }]
706
- }] });
707
-
708
- const IgnoreClickOnSelectionDirectiveToken = new InjectionToken('Ignore click on selection directive');
709
-
710
- class DeprecatedIgnoreClickOnSelectionDirective extends DeprecatedSelector {
711
- }
712
- DeprecatedIgnoreClickOnSelectionDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedIgnoreClickOnSelectionDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
713
- DeprecatedIgnoreClickOnSelectionDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedIgnoreClickOnSelectionDirective, isStandalone: true, selector: "[fdIgnoreClickOnSelection]", providers: [
714
- {
715
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
716
- useValue: getDeprecatedModel('[fdkIgnoreClickOnSelection]', '[fdIgnoreClickOnSelection]')
717
- }
718
- ], usesInheritance: true, ngImport: i0 });
719
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedIgnoreClickOnSelectionDirective, decorators: [{
720
- type: Directive,
721
- args: [{
722
- // eslint-disable-next-line @angular-eslint/directive-selector
723
- selector: '[fdIgnoreClickOnSelection]',
724
- standalone: true,
725
- providers: [
726
- {
727
- provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
728
- useValue: getDeprecatedModel('[fdkIgnoreClickOnSelection]', '[fdIgnoreClickOnSelection]')
729
- }
730
- ]
731
- }]
732
- }] });
733
- /**
734
- * Directive will stop propagation and prevent default of click, if selected area is coming from
735
- * directive's host element. This gives ability to not cancel all clicks on element, just the ones
736
- * which include selection
737
- */
738
- class IgnoreClickOnSelectionDirective {
739
- /** @hidden */
740
- constructor(document, _elementRef) {
741
- this.document = document;
742
- this._elementRef = _elementRef;
743
- }
744
- /** Host click listener. Checks for selection existence and if finds one, checks anchor */
745
- clicked($event) {
746
- const selection = this.document.getSelection();
747
- if (selection === null || selection === void 0 ? void 0 : selection.toString()) {
748
- if (selection.anchorNode &&
749
- (this._elementRef.nativeElement.isSameNode(selection.anchorNode) ||
750
- this._elementRef.nativeElement.isSameNode(selection.anchorNode.parentElement))) {
751
- $event.stopPropagation();
752
- $event.preventDefault();
753
- }
754
- }
755
- }
756
- }
757
- IgnoreClickOnSelectionDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionDirective, deps: [{ token: DOCUMENT }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
758
- IgnoreClickOnSelectionDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: IgnoreClickOnSelectionDirective, isStandalone: true, selector: "[fdkIgnoreClickOnSelection], [fdIgnoreClickOnSelection]", host: { listeners: { "click": "clicked($event)" } }, providers: [
759
- {
760
- provide: IgnoreClickOnSelectionDirectiveToken,
761
- useExisting: IgnoreClickOnSelectionDirective
762
- }
763
- ], ngImport: i0 });
764
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionDirective, decorators: [{
765
- type: Directive,
766
- args: [{
767
- selector: '[fdkIgnoreClickOnSelection], [fdIgnoreClickOnSelection]',
768
- standalone: true,
769
- providers: [
770
- {
771
- provide: IgnoreClickOnSelectionDirectiveToken,
772
- useExisting: IgnoreClickOnSelectionDirective
773
- }
774
- ]
775
- }]
776
- }], ctorParameters: function () {
777
- return [{ type: Document, decorators: [{
778
- type: Inject,
779
- args: [DOCUMENT]
780
- }] }, { type: i0.ElementRef }];
781
- }, propDecorators: { clicked: [{
782
- type: HostListener,
783
- args: ['click', ['$event']]
784
- }] } });
785
-
786
- class IgnoreClickOnSelectionModule {
787
- }
788
- IgnoreClickOnSelectionModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
789
- IgnoreClickOnSelectionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule, imports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective], exports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective] });
790
- IgnoreClickOnSelectionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule });
791
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule, decorators: [{
792
- type: NgModule,
793
- args: [{
794
- imports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective],
795
- exports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective]
796
- }]
797
- }] });
798
-
799
- /** Determines whether provided value is valid content density */
800
- function isValidContentDensity(size) {
801
- return size === 'cozy' || size === 'compact' || size === 'condensed';
802
- }
803
- /**
804
- * Determines if "compact" styles should be applied based on provided content density
805
- */
806
- function isCompactDensity(size) {
807
- return isValidContentDensity(size) && size !== 'cozy';
808
- }
809
-
810
- const DEFAULT_CONTENT_DENSITY = 'cozy';
811
- /**
812
- * Service taking care of ContentDensity
813
- */
814
- class ContentDensityService {
815
- /** @hidden */
816
- constructor() {
817
- /** Content Density BehaviourSubject */
818
- this.contentDensity = new BehaviorSubject(DEFAULT_CONTENT_DENSITY);
819
- if (isDevMode()) {
820
- console.warn(`[Deprecated] ContentDensityService is deprecated and will be removed in the next major version.
821
- Please use ContentDensityControllerService instead, or use the ContentDensityModule forRoot method.`);
822
- }
823
- }
824
- /** @hidden */
825
- get _contentDensityListener() {
826
- return this.contentDensity.pipe(distinctUntilChanged(), startWith(this.contentDensity.getValue()));
827
- }
828
- /** @hidden */
829
- get _isCompactDensity() {
830
- return this._contentDensityListener.pipe(map((density) => isCompactDensity(density)));
831
- }
832
- }
833
- ContentDensityService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ContentDensityService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
834
- ContentDensityService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ContentDensityService });
835
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ContentDensityService, decorators: [{
836
- type: Injectable
837
- }], ctorParameters: function () { return []; } });
838
-
839
- class DestroyedService extends ReplaySubject {
840
- /** @hidden */
841
- constructor() {
842
- super(1);
843
- }
844
- /** @hidden */
845
- ngOnDestroy() {
846
- this.next();
847
- this.complete();
848
- }
849
- }
850
- DestroyedService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DestroyedService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
851
- DestroyedService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DestroyedService });
852
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DestroyedService, decorators: [{
853
- type: Injectable
854
- }], ctorParameters: function () { return []; } });
855
-
856
- /** Generate a UUID v4 */
857
- function uuidv4() {
858
- const modifier = 16;
859
- return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
860
- // eslint-disable-next-line no-bitwise
861
- const r = (Math.random() * modifier) | 0,
862
- // eslint-disable-next-line no-bitwise
863
- v = c === 'x' ? r : (r & 0x3) | 0x8;
864
- return v.toString(modifier);
865
- });
866
- }
867
-
868
- class FocusTrapService {
869
- constructor() {
870
- /** @hidden */
871
- this._focusTrapInstances = new Map();
872
- }
873
- /**
874
- * Creates focus trap instance for defined element
875
- * @param element Container for which to create focus trap
876
- * @param userOptions Focus-trap specific configuration
877
- * @returns {string} Unique ID of focus trap instance
878
- */
879
- createFocusTrap(element, userOptions) {
880
- const uid = uuidv4();
881
- const trap = createFocusTrap(element, userOptions);
882
- this._focusTrapInstances.set(uid, trap);
883
- this.activateFocusTrap(uid);
884
- return uid;
885
- }
886
- /**
887
- * Activates focus trap for defined ID
888
- * @param id Unique ID of focus trap instance
889
- */
890
- activateFocusTrap(id) {
891
- if (!this._focusTrapExists(id)) {
892
- return;
893
- }
894
- const trap = this.getFocusTrapInstance(id);
895
- trap === null || trap === void 0 ? void 0 : trap.activate();
896
- }
897
- /**
898
- * Deactivates focus trap for defined ID
899
- * @param id Unique ID of focus trap instance
900
- */
901
- deactivateFocusTrap(id) {
902
- if (!this._focusTrapExists(id)) {
903
- return;
904
- }
905
- const trap = this.getFocusTrapInstance(id);
906
- trap === null || trap === void 0 ? void 0 : trap.deactivate();
907
- this._focusTrapInstances.delete(id);
908
- }
909
- /**
910
- * Pauses current focus trap.
911
- */
912
- pauseCurrentFocusTrap() {
913
- if (this._focusTrapInstances.size === 0) {
914
- return;
915
- }
916
- const trapItem = this._getLastTrapedItem();
917
- trapItem === null || trapItem === void 0 ? void 0 : trapItem.pause();
918
- }
919
- /**
920
- * Unpauses current focus trap.
921
- */
922
- unpauseCurrentFocusTrap() {
923
- if (this._focusTrapInstances.size === 0) {
924
- return;
925
- }
926
- const trapItem = this._getLastTrapedItem();
927
- trapItem === null || trapItem === void 0 ? void 0 : trapItem.unpause();
928
- }
929
- /**
930
- * Get focus trap instance by ID.
931
- * @param id ID of the instance.
932
- * @returns Focus trap instance if exists.
933
- */
934
- getFocusTrapInstance(id) {
935
- return this._focusTrapInstances.get(id);
936
- }
937
- /** @hidden */
938
- _getLastTrapedItem() {
939
- const lastItem = Array.from(this._focusTrapInstances).pop();
940
- return lastItem ? lastItem[1] : undefined;
941
- }
942
- /** @hidden */
943
- _focusTrapExists(id) {
944
- return this._focusTrapInstances.has(id);
945
- }
946
- }
947
- FocusTrapService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusTrapService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
948
- FocusTrapService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusTrapService, providedIn: 'root' });
949
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusTrapService, decorators: [{
950
- type: Injectable,
951
- args: [{
952
- providedIn: 'root'
953
- }]
954
- }] });
476
+ }] });
955
477
 
956
478
  const pxToNum = (pixels) => Number(pixels.replace('px', '')) || 0;
957
479
  const toNativeElement = (element) => element instanceof ElementRef ? element.nativeElement : element;
@@ -1149,311 +671,803 @@ class KeyboardSupportService {
1149
671
  get keyManager() {
1150
672
  return this._keyManager;
1151
673
  }
1152
- /** @hidden */
1153
- setKeyboardService(queryList, wrap, tabKeyNavigation = true) {
1154
- this._itemList = queryList;
1155
- this._tabKeyNavigation = tabKeyNavigation;
1156
- this._keyManager = new FocusKeyManager(queryList).withWrap(wrap).withHomeAndEnd();
1157
- queryList.changes
1158
- .pipe(takeUntil(this._onDestroy$), startWith(0))
1159
- .subscribe(() => this._refreshEscapeLogic(queryList));
674
+ /** @hidden */
675
+ setKeyboardService(queryList, wrap, tabKeyNavigation = true) {
676
+ this._itemList = queryList;
677
+ this._tabKeyNavigation = tabKeyNavigation;
678
+ this._keyManager = new FocusKeyManager(queryList).withWrap(wrap).withHomeAndEnd();
679
+ queryList.changes
680
+ .pipe(takeUntil(this._onDestroy$), startWith(0))
681
+ .subscribe(() => this._refreshEscapeLogic(queryList));
682
+ }
683
+ /** @hidden */
684
+ onKeyDown(event) {
685
+ this._keyManager.onKeydown(event);
686
+ if (KeyUtil.isKeyCode(event, TAB)) {
687
+ if (KeyUtil.isKeyCode(event, TAB) && this._tabKeyNavigation) {
688
+ event.preventDefault();
689
+ hasModifierKey(event, 'shiftKey')
690
+ ? this.keyManager.setPreviousItemActive()
691
+ : this.keyManager.setNextItemActive();
692
+ }
693
+ }
694
+ }
695
+ /** Destroys KeyboardSupportService dependencies */
696
+ onDestroy() {
697
+ this._onDestroy$.next();
698
+ this._onDestroy$.complete();
699
+ this._keyManager.destroy();
700
+ }
701
+ /** @hidden */
702
+ _refreshEscapeLogic(queryList) {
703
+ const createEscapeListener = (listItem, onKeyCode, escapeDirection) => {
704
+ listItem.keyDown
705
+ .pipe(takeUntil(unsubscribe$), filter((event) => KeyUtil.isKeyCode(event, onKeyCode)), tap((event) => event.preventDefault()))
706
+ .subscribe(() => this.focusEscapeList.next(escapeDirection));
707
+ };
708
+ /** Finish all of the streams, form before */
709
+ this._onRefresh$.next();
710
+ const unsubscribe$ = merge(this._onRefresh$, this._onDestroy$);
711
+ if (queryList.length) {
712
+ createEscapeListener(queryList.last, DOWN_ARROW, 'down');
713
+ createEscapeListener(queryList.first, UP_ARROW, 'up');
714
+ }
715
+ }
716
+ }
717
+ KeyboardSupportService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: KeyboardSupportService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
718
+ KeyboardSupportService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: KeyboardSupportService, providedIn: 'root' });
719
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: KeyboardSupportService, decorators: [{
720
+ type: Injectable,
721
+ args: [{ providedIn: 'root' }]
722
+ }] });
723
+
724
+ class MockStorage {
725
+ // eslint-disable-next-line
726
+ key(index) { }
727
+ clear() { }
728
+ // eslint-disable-next-line
729
+ getItem(key) { }
730
+ // eslint-disable-next-line
731
+ removeItem(key) { }
732
+ // eslint-disable-next-line
733
+ setItem(key, value) { }
734
+ }
735
+ class LocalStorageService {
736
+ /** @hidden */
737
+ constructor() {
738
+ typeof localStorage !== 'undefined' ? (this._storage = localStorage) : (this._storage = new MockStorage());
739
+ }
740
+ /** Get item from local storage. */
741
+ get(key) {
742
+ const value = this._storage.getItem(key);
743
+ if (value) {
744
+ return JSON.parse(value);
745
+ }
746
+ return null;
747
+ }
748
+ /** Set item in local storage. */
749
+ set(key, value) {
750
+ this._storage.setItem(key, JSON.stringify(value));
751
+ }
752
+ }
753
+ LocalStorageService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: LocalStorageService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
754
+ LocalStorageService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: LocalStorageService, providedIn: 'root' });
755
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: LocalStorageService, decorators: [{
756
+ type: Injectable,
757
+ args: [{ providedIn: 'root' }]
758
+ }], ctorParameters: function () { return []; } });
759
+
760
+ class ResizeObserverFactory {
761
+ /** Factory to create ResizeObserver if it's present in browser. */
762
+ create(callback) {
763
+ return typeof ResizeObserver === 'undefined' ? null : new ResizeObserver(callback);
764
+ }
765
+ }
766
+ ResizeObserverFactory.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
767
+ ResizeObserverFactory.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverFactory, providedIn: 'root' });
768
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverFactory, decorators: [{
769
+ type: Injectable,
770
+ args: [{ providedIn: 'root' }]
771
+ }] });
772
+ class ResizeObserverService {
773
+ /** @hidden */
774
+ constructor(_resizeObserverFactory) {
775
+ this._resizeObserverFactory = _resizeObserverFactory;
776
+ /** @hidden */
777
+ this._observedElements = new Map();
778
+ }
779
+ /** @hidden */
780
+ ngOnDestroy() {
781
+ this._observedElements.forEach((_, element) => this._cleanupObserver(element));
782
+ }
783
+ /** Observe the given element and emit whenever its size changes. */
784
+ observe(elementOrRef) {
785
+ const element = coerceElement(elementOrRef);
786
+ return new Observable((observer) => {
787
+ const stream = this._observeElement(element);
788
+ const subscription = stream === null || stream === void 0 ? void 0 : stream.subscribe(observer);
789
+ return () => {
790
+ subscription === null || subscription === void 0 ? void 0 : subscription.unsubscribe();
791
+ this._unobserveElement(element);
792
+ };
793
+ });
794
+ }
795
+ /**
796
+ * Observes the given element by using the existing MutationObserver if available, or creating a
797
+ * new one if not.
798
+ */
799
+ _observeElement(element) {
800
+ let observedElement = this._observedElements.get(element);
801
+ if (!observedElement) {
802
+ const stream = new Subject();
803
+ const observer = this._resizeObserverFactory.create((mutations) => stream.next(mutations));
804
+ if (observer) {
805
+ observer.observe(element);
806
+ }
807
+ observedElement = { observer, stream, count: 0 };
808
+ this._observedElements.set(element, observedElement);
809
+ }
810
+ observedElement.count++;
811
+ return observedElement === null || observedElement === void 0 ? void 0 : observedElement.stream;
812
+ }
813
+ /**
814
+ * Un-observes the given element and cleans up the underlying MutationObserver if nobody else is
815
+ * observing this element.
816
+ */
817
+ _unobserveElement(element) {
818
+ const observedElement = this._observedElements.get(element);
819
+ if (!observedElement) {
820
+ return;
821
+ }
822
+ if (--observedElement.count) {
823
+ return;
824
+ }
825
+ this._cleanupObserver(element);
826
+ }
827
+ /** Clean up the underlying MutationObserver for the specified element. */
828
+ _cleanupObserver(element) {
829
+ const observedElement = this._observedElements.get(element);
830
+ if (!observedElement) {
831
+ return;
832
+ }
833
+ const { observer, stream } = observedElement;
834
+ if (observer) {
835
+ observer.disconnect();
836
+ }
837
+ stream.complete();
838
+ this._observedElements.delete(element);
839
+ }
840
+ }
841
+ ResizeObserverService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverService, deps: [{ token: ResizeObserverFactory }], target: i0.ɵɵFactoryTarget.Injectable });
842
+ ResizeObserverService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverService, providedIn: 'root' });
843
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverService, decorators: [{
844
+ type: Injectable,
845
+ args: [{ providedIn: 'root' }]
846
+ }], ctorParameters: function () { return [{ type: ResizeObserverFactory }]; } });
847
+
848
+ class TabbableElementService {
849
+ /** @hidden */
850
+ constructor(_checker, _document) {
851
+ this._checker = _checker;
852
+ this._document = _document;
853
+ }
854
+ /** Get the first tabbable element from a DOM subtree (inclusive). */
855
+ getTabbableElement(root, focusLastElement = false, skipSelf = false) {
856
+ var _a;
857
+ if (!skipSelf && this._checker.isFocusable(root) && this._checker.isTabbable(root)) {
858
+ return root;
859
+ }
860
+ // Iterate in DOM order. Note that IE doesn't have `children` for SVG, so we fall
861
+ // back to `childNodes` which includes text nodes, comments etc.
862
+ const rootChildren = root.children || root.childNodes;
863
+ const children = focusLastElement ? Array.from(rootChildren).reverse() : rootChildren;
864
+ for (let i = 0; i < children.length; i++) {
865
+ const tabbableChild = children[i].nodeType === ((_a = this._document) === null || _a === void 0 ? void 0 : _a.ELEMENT_NODE)
866
+ ? this.getTabbableElement(children[i], focusLastElement)
867
+ : null;
868
+ if (tabbableChild) {
869
+ return tabbableChild;
870
+ }
871
+ }
872
+ return null;
873
+ }
874
+ }
875
+ TabbableElementService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: TabbableElementService, deps: [{ token: i1$1.InteractivityChecker }, { token: DOCUMENT, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
876
+ TabbableElementService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: TabbableElementService, providedIn: 'root' });
877
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: TabbableElementService, decorators: [{
878
+ type: Injectable,
879
+ args: [{ providedIn: 'root' }]
880
+ }], ctorParameters: function () {
881
+ return [{ type: i1$1.InteractivityChecker }, { type: Document, decorators: [{
882
+ type: Optional
883
+ }, {
884
+ type: Inject,
885
+ args: [DOCUMENT]
886
+ }] }];
887
+ } });
888
+
889
+ /**
890
+ * Retrieves native element from ElementRef.
891
+ */
892
+ function getNativeElement(element) {
893
+ let coercible = element;
894
+ if (hasElementRef(element)) {
895
+ coercible = element.elementRef;
896
+ }
897
+ return coerceElement(coercible);
898
+ }
899
+ /**
900
+ * Checks whether object has element reference in it.
901
+ */
902
+ function hasElementRef(something) {
903
+ return something && something['elementRef'] instanceof ElementRef;
904
+ }
905
+
906
+ class AttributeObserver {
907
+ /** @hidden */
908
+ constructor(_mutationObserverFactory) {
909
+ this._mutationObserverFactory = _mutationObserverFactory;
910
+ /** @Hidden */
911
+ this._observedElements = new Map();
912
+ }
913
+ /** @hidden */
914
+ ngOnDestroy() {
915
+ this._observedElements.forEach((_, element) => this._cleanupObserver(element));
916
+ }
917
+ /** @Hidden */
918
+ observe(elementOrRef) {
919
+ const element = getNativeElement(elementOrRef);
920
+ return new Observable((observer) => {
921
+ const stream = this._observeElement(element);
922
+ const subscription = stream.subscribe(observer);
923
+ return () => {
924
+ subscription.unsubscribe();
925
+ this._unobserveElement(element);
926
+ };
927
+ });
928
+ }
929
+ /** @Hidden */
930
+ unobserve(element) {
931
+ this._unobserveElement(getNativeElement(element));
1160
932
  }
1161
933
  /** @hidden */
1162
- onKeyDown(event) {
1163
- this._keyManager.onKeydown(event);
1164
- if (KeyUtil.isKeyCode(event, TAB)) {
1165
- if (KeyUtil.isKeyCode(event, TAB) && this._tabKeyNavigation) {
1166
- event.preventDefault();
1167
- hasModifierKey(event, 'shiftKey')
1168
- ? this.keyManager.setPreviousItemActive()
1169
- : this.keyManager.setNextItemActive();
934
+ _observeElement(element) {
935
+ if (!this._observedElements.has(element)) {
936
+ const stream = new Subject();
937
+ const observer = this._mutationObserverFactory.create((mutations) => stream.next(mutations));
938
+ if (observer) {
939
+ observer.observe(element, {
940
+ attributes: true
941
+ });
1170
942
  }
943
+ this._observedElements.set(element, { observer, stream, count: 1 });
944
+ }
945
+ else {
946
+ this._observedElements.get(element).count++;
1171
947
  }
948
+ return this._observedElements.get(element).stream;
1172
949
  }
1173
- /** Destroys KeyboardSupportService dependencies */
1174
- onDestroy() {
1175
- this._onDestroy$.next();
1176
- this._onDestroy$.complete();
1177
- this._keyManager.destroy();
950
+ /** @Hidden */
951
+ _unobserveElement(element) {
952
+ if (this._observedElements.has(element)) {
953
+ this._observedElements.get(element).count--;
954
+ if (!this._observedElements.get(element).count) {
955
+ this._cleanupObserver(element);
956
+ }
957
+ }
1178
958
  }
1179
959
  /** @hidden */
1180
- _refreshEscapeLogic(queryList) {
1181
- const createEscapeListener = (listItem, onKeyCode, escapeDirection) => {
1182
- listItem.keyDown
1183
- .pipe(takeUntil(unsubscribe$), filter((event) => KeyUtil.isKeyCode(event, onKeyCode)), tap((event) => event.preventDefault()))
1184
- .subscribe(() => this.focusEscapeList.next(escapeDirection));
1185
- };
1186
- /** Finish all of the streams, form before */
1187
- this._onRefresh$.next();
1188
- const unsubscribe$ = merge(this._onRefresh$, this._onDestroy$);
1189
- if (queryList.length) {
1190
- createEscapeListener(queryList.last, DOWN_ARROW, 'down');
1191
- createEscapeListener(queryList.first, UP_ARROW, 'up');
960
+ _cleanupObserver(element) {
961
+ if (this._observedElements.has(element)) {
962
+ const { observer, stream } = this._observedElements.get(element);
963
+ if (observer) {
964
+ observer.disconnect();
965
+ }
966
+ stream.complete();
967
+ this._observedElements.delete(element);
1192
968
  }
1193
969
  }
1194
970
  }
1195
- KeyboardSupportService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: KeyboardSupportService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1196
- KeyboardSupportService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: KeyboardSupportService, providedIn: 'root' });
1197
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: KeyboardSupportService, decorators: [{
971
+ AttributeObserver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AttributeObserver, deps: [{ token: i1$2.MutationObserverFactory }], target: i0.ɵɵFactoryTarget.Injectable });
972
+ AttributeObserver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AttributeObserver, providedIn: 'root' });
973
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AttributeObserver, decorators: [{
1198
974
  type: Injectable,
1199
- args: [{ providedIn: 'root' }]
1200
- }] });
975
+ args: [{
976
+ providedIn: 'root'
977
+ }]
978
+ }], ctorParameters: function () { return [{ type: i1$2.MutationObserverFactory }]; } });
1201
979
 
1202
- class MockStorage {
1203
- // eslint-disable-next-line
1204
- key(index) { }
1205
- clear() { }
1206
- // eslint-disable-next-line
1207
- getItem(key) { }
1208
- // eslint-disable-next-line
1209
- removeItem(key) { }
1210
- // eslint-disable-next-line
1211
- setItem(key, value) { }
980
+ /* eslint-disable @typescript-eslint/member-ordering */
981
+ class DeprecatedAutoCompleteDirective extends DeprecatedSelector {
1212
982
  }
1213
- class LocalStorageService {
983
+ DeprecatedAutoCompleteDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedAutoCompleteDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
984
+ DeprecatedAutoCompleteDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedAutoCompleteDirective, isStandalone: true, selector: "[fdAutoComplete], [fd-auto-complete]", providers: [
985
+ DestroyedService,
986
+ {
987
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
988
+ useValue: getDeprecatedModel('[fdkAutoComplete]', '[fdAutoComplete], [fd-auto-complete]')
989
+ }
990
+ ], usesInheritance: true, ngImport: i0 });
991
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedAutoCompleteDirective, decorators: [{
992
+ type: Directive,
993
+ args: [{
994
+ // eslint-disable-next-line @angular-eslint/directive-selector
995
+ selector: '[fdAutoComplete], [fd-auto-complete]',
996
+ standalone: true,
997
+ providers: [
998
+ DestroyedService,
999
+ {
1000
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1001
+ useValue: getDeprecatedModel('[fdkAutoComplete]', '[fdAutoComplete], [fd-auto-complete]')
1002
+ }
1003
+ ]
1004
+ }]
1005
+ }] });
1006
+ class AutoCompleteDirective {
1214
1007
  /** @hidden */
1215
- constructor() {
1216
- typeof localStorage !== 'undefined' ? (this._storage = localStorage) : (this._storage = new MockStorage());
1008
+ // eslint-disable-next-line @typescript-eslint/member-ordering
1009
+ constructor(_elementRef, _zone, _destroy$) {
1010
+ this._elementRef = _elementRef;
1011
+ this._zone = _zone;
1012
+ this._destroy$ = _destroy$;
1013
+ /** Whether the auto complete directive should be enabled */
1014
+ this.enable = true;
1015
+ /** Matcher function for testing the str for a search term */
1016
+ this.matcher = (str, searchTerm) => str.startsWith(searchTerm);
1017
+ /** Display function. Accepts an object of the same type as the
1018
+ * items passed to dropdownValues as argument, and outputs a string.
1019
+ * An arrow function can be used to access the *this* keyword in the calling component.
1020
+ * See search input examples for details. */
1021
+ this.displayFn = this._defaultDisplay;
1022
+ /** Event thrown, when the auto ahead text is accepted */
1023
+ this.onComplete = new EventEmitter();
1024
+ /** @hidden */
1025
+ this._completeKeys = [ENTER];
1026
+ /** @hidden */
1027
+ this._fillKeys = [LEFT_ARROW, RIGHT_ARROW];
1028
+ /** @hidden */
1029
+ this._stopKeys = [BACKSPACE, DELETE, ESCAPE];
1030
+ /**
1031
+ * Fixes #10710
1032
+ * WIth chinese characters inputText property update was triggered after the keyup event trigger.
1033
+ * By ensuring that we set all properties we can proceed with stable data.
1034
+ */
1035
+ this._zone.runOutsideAngular(() => {
1036
+ const keyupEvent = fromEvent(this._elementRef.nativeElement, 'keyup');
1037
+ keyupEvent
1038
+ .pipe(switchMap((evt) => this._zone.onStable.pipe(first(), map$1(() => evt))), takeUntil$1(this._destroy$))
1039
+ .subscribe((evt) => {
1040
+ this._handleKeyboardEvent(evt);
1041
+ console.log(this.inputText);
1042
+ });
1043
+ });
1217
1044
  }
1218
- /** Get item from local storage. */
1219
- get(key) {
1220
- const value = this._storage.getItem(key);
1221
- if (value) {
1222
- return JSON.parse(value);
1045
+ /** @hidden */
1046
+ _handleKeyboardEvent(event) {
1047
+ if (this.enable) {
1048
+ if (KeyUtil.isKeyCode(event, this._stopKeys)) {
1049
+ this._elementRef.nativeElement.value = this.inputText;
1050
+ }
1051
+ else if (KeyUtil.isKeyCode(event, this._completeKeys)) {
1052
+ this._sendCompleteEvent(true);
1053
+ this._moveIndicatorToLastCharacter();
1054
+ }
1055
+ else if (KeyUtil.isKeyCode(event, this._fillKeys)) {
1056
+ this._sendCompleteEvent(false);
1057
+ }
1058
+ else if (!this._isControlKey(event) && this.inputText) {
1059
+ /** Prevention from triggering typeahead, when having crtl/cmd + keys */
1060
+ if (!this._triggerTypeAhead()) {
1061
+ return;
1062
+ }
1063
+ this.oldValue = this.inputText;
1064
+ const item = this.options.find((option) => this.matcher(this.displayFn(option).toLocaleLowerCase(), this.inputText.toLocaleLowerCase()));
1065
+ if (item) {
1066
+ this._typeahead(this.displayFn(item));
1067
+ }
1068
+ }
1223
1069
  }
1224
- return null;
1070
+ this.lastKeyUpEvent = event;
1225
1071
  }
1226
- /** Set item in local storage. */
1227
- set(key, value) {
1228
- this._storage.setItem(key, JSON.stringify(value));
1072
+ /** @hidden */
1073
+ _typeahead(displayedValue) {
1074
+ this._elementRef.nativeElement.value = displayedValue;
1075
+ const selectionStartIndex = this.inputText.length;
1076
+ this._elementRef.nativeElement.setSelectionRange(selectionStartIndex, displayedValue.length);
1077
+ }
1078
+ /** @hidden */
1079
+ _isControlKey(event) {
1080
+ return KeyUtil.isKeyCode(event, CONTROL) || event.ctrlKey;
1081
+ }
1082
+ /** @hidden */
1083
+ _defaultDisplay(value) {
1084
+ return value;
1085
+ }
1086
+ /** @hidden */
1087
+ _triggerTypeAhead() {
1088
+ if (this.lastKeyUpEvent &&
1089
+ KeyUtil.isKeyCode(this.lastKeyUpEvent, CONTROL) &&
1090
+ this.inputText === this.oldValue) {
1091
+ return false;
1092
+ }
1093
+ else {
1094
+ return true;
1095
+ }
1096
+ }
1097
+ /** @hidden */
1098
+ _sendCompleteEvent(forceClose) {
1099
+ this.onComplete.emit({
1100
+ term: this._elementRef.nativeElement.value,
1101
+ forceClose
1102
+ });
1103
+ }
1104
+ /** @hidden */
1105
+ _moveIndicatorToLastCharacter() {
1106
+ var _a, _b;
1107
+ const inputTextLength = (_b = (_a = this.inputText) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0;
1108
+ this._elementRef.nativeElement.setSelectionRange(inputTextLength, inputTextLength);
1229
1109
  }
1230
1110
  }
1231
- LocalStorageService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: LocalStorageService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1232
- LocalStorageService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: LocalStorageService, providedIn: 'root' });
1233
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: LocalStorageService, decorators: [{
1234
- type: Injectable,
1235
- args: [{ providedIn: 'root' }]
1236
- }], ctorParameters: function () { return []; } });
1111
+ AutoCompleteDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteDirective, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: DestroyedService }], target: i0.ɵɵFactoryTarget.Directive });
1112
+ AutoCompleteDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: AutoCompleteDirective, isStandalone: true, selector: "[fdkAutoComplete], [fdAutoComplete], [fd-auto-complete]", inputs: { options: "options", inputText: "inputText", enable: "enable", matcher: "matcher", displayFn: "displayFn" }, outputs: { onComplete: "onComplete" }, ngImport: i0 });
1113
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteDirective, decorators: [{
1114
+ type: Directive,
1115
+ args: [{
1116
+ selector: '[fdkAutoComplete], [fdAutoComplete], [fd-auto-complete]',
1117
+ standalone: true
1118
+ }]
1119
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: DestroyedService }]; }, propDecorators: { options: [{
1120
+ type: Input
1121
+ }], inputText: [{
1122
+ type: Input
1123
+ }], enable: [{
1124
+ type: Input
1125
+ }], matcher: [{
1126
+ type: Input
1127
+ }], displayFn: [{
1128
+ type: Input
1129
+ }], onComplete: [{
1130
+ type: Output
1131
+ }] } });
1132
+
1133
+ class AutoCompleteModule {
1134
+ }
1135
+ AutoCompleteModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1136
+ AutoCompleteModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule, imports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective], exports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective] });
1137
+ AutoCompleteModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule });
1138
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AutoCompleteModule, decorators: [{
1139
+ type: NgModule,
1140
+ args: [{
1141
+ imports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective],
1142
+ exports: [AutoCompleteDirective, DeprecatedAutoCompleteDirective],
1143
+ declarations: []
1144
+ }]
1145
+ }] });
1237
1146
 
1238
- class ResizeObserverFactory {
1239
- /** Factory to create ResizeObserver if it's present in browser. */
1240
- create(callback) {
1241
- return typeof ResizeObserver === 'undefined' ? null : new ResizeObserver(callback);
1242
- }
1147
+ const FOCUSABLE_ITEM = new InjectionToken('Focusable Option');
1148
+
1149
+ class DeprecatedFocusKeyManagerListDirective extends DeprecatedSelector {
1243
1150
  }
1244
- ResizeObserverFactory.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1245
- ResizeObserverFactory.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverFactory, providedIn: 'root' });
1246
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverFactory, decorators: [{
1247
- type: Injectable,
1248
- args: [{ providedIn: 'root' }]
1151
+ DeprecatedFocusKeyManagerListDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerListDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
1152
+ DeprecatedFocusKeyManagerListDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedFocusKeyManagerListDirective, isStandalone: true, selector: "[fd-focus-key-manager-list], [fdFocusKeyManagerList]", providers: [
1153
+ {
1154
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1155
+ useValue: getDeprecatedModel('[fdkFocusKeyManagerList]', '[fd-focus-key-manager-list], [fdFocusKeyManagerList]')
1156
+ }
1157
+ ], usesInheritance: true, ngImport: i0 });
1158
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerListDirective, decorators: [{
1159
+ type: Directive,
1160
+ args: [{
1161
+ // eslint-disable-next-line @angular-eslint/directive-selector
1162
+ selector: '[fd-focus-key-manager-list], [fdFocusKeyManagerList]',
1163
+ standalone: true,
1164
+ providers: [
1165
+ {
1166
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1167
+ useValue: getDeprecatedModel('[fdkFocusKeyManagerList]', '[fd-focus-key-manager-list], [fdFocusKeyManagerList]')
1168
+ }
1169
+ ]
1170
+ }]
1249
1171
  }] });
1250
- class ResizeObserverService {
1172
+ /** Directive to apply Angular Material FocusKeyManager to lists.
1173
+ * To be used with FocusKeyManagerItemDirective
1174
+ */
1175
+ class FocusKeyManagerListDirective {
1251
1176
  /** @hidden */
1252
- constructor(_resizeObserverFactory) {
1253
- this._resizeObserverFactory = _resizeObserverFactory;
1254
- /** @hidden */
1255
- this._observedElements = new Map();
1177
+ get focusKeyManager() {
1178
+ return this._focusKeyManager;
1256
1179
  }
1257
1180
  /** @hidden */
1258
- ngOnDestroy() {
1259
- this._observedElements.forEach((_, element) => this._cleanupObserver(element));
1260
- }
1261
- /** Observe the given element and emit whenever its size changes. */
1262
- observe(elementOrRef) {
1263
- const element = coerceElement(elementOrRef);
1264
- return new Observable((observer) => {
1265
- const stream = this._observeElement(element);
1266
- const subscription = stream === null || stream === void 0 ? void 0 : stream.subscribe(observer);
1267
- return () => {
1268
- subscription === null || subscription === void 0 ? void 0 : subscription.unsubscribe();
1269
- this._unobserveElement(element);
1270
- };
1271
- });
1272
- }
1273
- /**
1274
- * Observes the given element by using the existing MutationObserver if available, or creating a
1275
- * new one if not.
1276
- */
1277
- _observeElement(element) {
1278
- let observedElement = this._observedElements.get(element);
1279
- if (!observedElement) {
1280
- const stream = new Subject();
1281
- const observer = this._resizeObserverFactory.create((mutations) => stream.next(mutations));
1282
- if (observer) {
1283
- observer.observe(element);
1284
- }
1285
- observedElement = { observer, stream, count: 0 };
1286
- this._observedElements.set(element, observedElement);
1287
- }
1288
- observedElement.count++;
1289
- return observedElement === null || observedElement === void 0 ? void 0 : observedElement.stream;
1181
+ constructor(_rtlService, _cdr) {
1182
+ this._rtlService = _rtlService;
1183
+ this._cdr = _cdr;
1184
+ /** @hidden */
1185
+ this._onDestroy$ = new Subject();
1290
1186
  }
1291
- /**
1292
- * Un-observes the given element and cleans up the underlying MutationObserver if nobody else is
1293
- * observing this element.
1294
- */
1295
- _unobserveElement(element) {
1296
- const observedElement = this._observedElements.get(element);
1297
- if (!observedElement) {
1187
+ /** @hidden */
1188
+ ngOnChanges(changes) {
1189
+ if (!this._focusKeyManager) {
1298
1190
  return;
1299
1191
  }
1300
- if (--observedElement.count) {
1301
- return;
1192
+ if ('orientation' in changes) {
1193
+ this._applyOrientation();
1194
+ }
1195
+ if ('skiPredicate' in changes) {
1196
+ this._focusKeyManager.skipPredicate(this.skipPredicate);
1302
1197
  }
1303
- this._cleanupObserver(element);
1304
1198
  }
1305
- /** Clean up the underlying MutationObserver for the specified element. */
1306
- _cleanupObserver(element) {
1307
- const observedElement = this._observedElements.get(element);
1308
- if (!observedElement) {
1309
- return;
1199
+ /** @hidden */
1200
+ ngAfterContentInit() {
1201
+ var _a;
1202
+ this._focusKeyManager = new FocusKeyManager(this._items).skipPredicate(this.skipPredicate);
1203
+ this._applyOrientation();
1204
+ this._cdr.detectChanges();
1205
+ (_a = this._rtlService) === null || _a === void 0 ? void 0 : _a.rtl.pipe(filter(() => this.orientation === 'horizontal'), takeUntil(this._onDestroy$)).subscribe(() => this._applyOrientation());
1206
+ }
1207
+ /** @hidden */
1208
+ ngOnDestroy() {
1209
+ this._onDestroy$.next();
1210
+ this._onDestroy$.complete();
1211
+ this._focusKeyManager.destroy();
1212
+ }
1213
+ /** Focus certain list's item */
1214
+ focusItem(item) {
1215
+ if (typeof item === 'number') {
1216
+ this._focusKeyManager.setActiveItem(item);
1310
1217
  }
1311
- const { observer, stream } = observedElement;
1312
- if (observer) {
1313
- observer.disconnect();
1218
+ else {
1219
+ this._focusKeyManager.setActiveItem(item);
1314
1220
  }
1315
- stream.complete();
1316
- this._observedElements.delete(element);
1317
1221
  }
1318
- }
1319
- ResizeObserverService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverService, deps: [{ token: ResizeObserverFactory }], target: i0.ɵɵFactoryTarget.Injectable });
1320
- ResizeObserverService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverService, providedIn: 'root' });
1321
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: ResizeObserverService, decorators: [{
1322
- type: Injectable,
1323
- args: [{ providedIn: 'root' }]
1324
- }], ctorParameters: function () { return [{ type: ResizeObserverFactory }]; } });
1325
-
1326
- class TabbableElementService {
1327
1222
  /** @hidden */
1328
- constructor(_checker, _document) {
1329
- this._checker = _checker;
1330
- this._document = _document;
1331
- }
1332
- /** Get the first tabbable element from a DOM subtree (inclusive). */
1333
- getTabbableElement(root, focusLastElement = false, skipSelf = false) {
1223
+ _applyOrientation() {
1334
1224
  var _a;
1335
- if (!skipSelf && this._checker.isFocusable(root) && this._checker.isTabbable(root)) {
1336
- return root;
1337
- }
1338
- // Iterate in DOM order. Note that IE doesn't have `children` for SVG, so we fall
1339
- // back to `childNodes` which includes text nodes, comments etc.
1340
- const rootChildren = root.children || root.childNodes;
1341
- const children = focusLastElement ? Array.from(rootChildren).reverse() : rootChildren;
1342
- for (let i = 0; i < children.length; i++) {
1343
- const tabbableChild = children[i].nodeType === ((_a = this._document) === null || _a === void 0 ? void 0 : _a.ELEMENT_NODE)
1344
- ? this.getTabbableElement(children[i], focusLastElement)
1345
- : null;
1346
- if (tabbableChild) {
1347
- return tabbableChild;
1348
- }
1225
+ switch (this.orientation) {
1226
+ case 'horizontal':
1227
+ this._focusKeyManager.withHorizontalOrientation(((_a = this._rtlService) === null || _a === void 0 ? void 0 : _a.rtl.value) ? 'rtl' : 'ltr');
1228
+ break;
1229
+ case 'vertical':
1230
+ this._focusKeyManager.withVerticalOrientation(true);
1231
+ break;
1349
1232
  }
1350
- return null;
1351
1233
  }
1352
1234
  }
1353
- TabbableElementService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: TabbableElementService, deps: [{ token: i1$1.InteractivityChecker }, { token: DOCUMENT, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
1354
- TabbableElementService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: TabbableElementService, providedIn: 'root' });
1355
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: TabbableElementService, decorators: [{
1356
- type: Injectable,
1357
- args: [{ providedIn: 'root' }]
1235
+ FocusKeyManagerListDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerListDirective, deps: [{ token: RtlService, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
1236
+ FocusKeyManagerListDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: FocusKeyManagerListDirective, isStandalone: true, selector: "[fdkFocusKeyManagerList], [fd-focus-key-manager-list], [fdFocusKeyManagerList]", inputs: { orientation: "orientation", skipPredicate: "skipPredicate" }, queries: [{ propertyName: "_items", predicate: FOCUSABLE_ITEM }], usesOnChanges: true, ngImport: i0 });
1237
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerListDirective, decorators: [{
1238
+ type: Directive,
1239
+ args: [{
1240
+ selector: `[fdkFocusKeyManagerList], [fd-focus-key-manager-list], [fdFocusKeyManagerList]`,
1241
+ standalone: true
1242
+ }]
1358
1243
  }], ctorParameters: function () {
1359
- return [{ type: i1$1.InteractivityChecker }, { type: Document, decorators: [{
1244
+ return [{ type: RtlService, decorators: [{
1360
1245
  type: Optional
1361
- }, {
1362
- type: Inject,
1363
- args: [DOCUMENT]
1364
- }] }];
1365
- } });
1246
+ }] }, { type: i0.ChangeDetectorRef }];
1247
+ }, propDecorators: { orientation: [{
1248
+ type: Input
1249
+ }], skipPredicate: [{
1250
+ type: Input
1251
+ }], _items: [{
1252
+ type: ContentChildren,
1253
+ args: [FOCUSABLE_ITEM]
1254
+ }] } });
1366
1255
 
1367
- /**
1368
- * Retrieves native element from ElementRef.
1369
- */
1370
- function getNativeElement(element) {
1371
- let coercible = element;
1372
- if (hasElementRef(element)) {
1373
- coercible = element.elementRef;
1374
- }
1375
- return coerceElement(coercible);
1256
+ class DeprecatedFocusKeyManagerItemDirective extends DeprecatedSelector {
1376
1257
  }
1377
- /**
1378
- * Checks whether object has element reference in it.
1258
+ DeprecatedFocusKeyManagerItemDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerItemDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
1259
+ DeprecatedFocusKeyManagerItemDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedFocusKeyManagerItemDirective, isStandalone: true, selector: "[fd-focus-key-manager-item], [fdFocusKeyManagerItem]", providers: [
1260
+ {
1261
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1262
+ useValue: getDeprecatedModel('[fdkFocusKeyManagerItem]', '[fd-focus-key-manager-item], [fdFocusKeyManagerItem]')
1263
+ }
1264
+ ], usesInheritance: true, ngImport: i0 });
1265
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedFocusKeyManagerItemDirective, decorators: [{
1266
+ type: Directive,
1267
+ args: [{
1268
+ // eslint-disable-next-line @angular-eslint/directive-selector
1269
+ selector: '[fd-focus-key-manager-item], [fdFocusKeyManagerItem]',
1270
+ standalone: true,
1271
+ providers: [
1272
+ {
1273
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1274
+ useValue: getDeprecatedModel('[fdkFocusKeyManagerItem]', '[fd-focus-key-manager-item], [fdFocusKeyManagerItem]')
1275
+ }
1276
+ ]
1277
+ }]
1278
+ }] });
1279
+ /** Directive to apply Angular Material FocusKeyManager to lists.
1280
+ * To be used with FocusKeyManagerItemDirective
1379
1281
  */
1380
- function hasElementRef(something) {
1381
- return something && something['elementRef'] instanceof ElementRef;
1382
- }
1383
-
1384
- class AttributeObserver {
1282
+ class FocusKeyManagerItemDirective {
1283
+ /** Whether item should be initially focused */
1284
+ set initialFocus(value) {
1285
+ this._initialFocus = coerceBooleanProperty(value);
1286
+ }
1385
1287
  /** @hidden */
1386
- constructor(_mutationObserverFactory) {
1387
- this._mutationObserverFactory = _mutationObserverFactory;
1388
- /** @Hidden */
1389
- this._observedElements = new Map();
1288
+ get _tabindex() {
1289
+ var _a, _b;
1290
+ if (this._initialFocus) {
1291
+ return 0;
1292
+ }
1293
+ return (_b = (_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.tabIndex) !== null && _b !== void 0 ? _b : -1;
1294
+ }
1295
+ /** Native element of the item */
1296
+ get nativeElement() {
1297
+ var _a;
1298
+ return (_a = this._elRef) === null || _a === void 0 ? void 0 : _a.nativeElement;
1390
1299
  }
1391
1300
  /** @hidden */
1392
- ngOnDestroy() {
1393
- this._observedElements.forEach((_, element) => this._cleanupObserver(element));
1301
+ get _focusKeyManager() {
1302
+ return this._list.focusKeyManager;
1394
1303
  }
1395
- /** @Hidden */
1396
- observe(elementOrRef) {
1397
- const element = getNativeElement(elementOrRef);
1398
- return new Observable((observer) => {
1399
- const stream = this._observeElement(element);
1400
- const subscription = stream.subscribe(observer);
1401
- return () => {
1402
- subscription.unsubscribe();
1403
- this._unobserveElement(element);
1404
- };
1405
- });
1304
+ /** @hidden */
1305
+ constructor(_list, _elRef) {
1306
+ this._list = _list;
1307
+ this._elRef = _elRef;
1308
+ /** @hidden */
1309
+ this._initialFocus = false;
1406
1310
  }
1407
- /** @Hidden */
1408
- unobserve(element) {
1409
- this._unobserveElement(getNativeElement(element));
1311
+ /** @hidden */
1312
+ _onFocus() {
1313
+ var _a;
1314
+ // For cases where initially selected item doesn't have 0 index
1315
+ (_a = this._focusKeyManager) === null || _a === void 0 ? void 0 : _a.updateActiveItem(this);
1410
1316
  }
1411
1317
  /** @hidden */
1412
- _observeElement(element) {
1413
- if (!this._observedElements.has(element)) {
1414
- const stream = new Subject();
1415
- const observer = this._mutationObserverFactory.create((mutations) => stream.next(mutations));
1416
- if (observer) {
1417
- observer.observe(element, {
1418
- attributes: true
1419
- });
1420
- }
1421
- this._observedElements.set(element, { observer, stream, count: 1 });
1422
- }
1423
- else {
1424
- this._observedElements.get(element).count++;
1425
- }
1426
- return this._observedElements.get(element).stream;
1318
+ _onKeydown(event) {
1319
+ var _a;
1320
+ (_a = this._focusKeyManager) === null || _a === void 0 ? void 0 : _a.onKeydown(event);
1427
1321
  }
1428
- /** @Hidden */
1429
- _unobserveElement(element) {
1430
- if (this._observedElements.has(element)) {
1431
- this._observedElements.get(element).count--;
1432
- if (!this._observedElements.get(element).count) {
1433
- this._cleanupObserver(element);
1434
- }
1435
- }
1322
+ /** Focus current item native element */
1323
+ focus() {
1324
+ var _a;
1325
+ (_a = this._elRef) === null || _a === void 0 ? void 0 : _a.nativeElement.focus();
1436
1326
  }
1327
+ }
1328
+ FocusKeyManagerItemDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerItemDirective, deps: [{ token: FocusKeyManagerListDirective }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
1329
+ FocusKeyManagerItemDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: FocusKeyManagerItemDirective, isStandalone: true, selector: "[fdkFocusKeyManagerItem], [fd-focus-key-manager-item], [fdFocusKeyManagerItem]", inputs: { initialFocus: "initialFocus", _tabindex: "_tabindex" }, host: { listeners: { "focus": "_onFocus()", "keydown": "_onKeydown($event)" }, properties: { "attr.tabindex": "this._tabindex" } }, providers: [{ provide: FOCUSABLE_ITEM, useExisting: forwardRef(() => FocusKeyManagerItemDirective) }], ngImport: i0 });
1330
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerItemDirective, decorators: [{
1331
+ type: Directive,
1332
+ args: [{
1333
+ selector: '[fdkFocusKeyManagerItem], [fd-focus-key-manager-item], [fdFocusKeyManagerItem]',
1334
+ standalone: true,
1335
+ providers: [{ provide: FOCUSABLE_ITEM, useExisting: forwardRef(() => FocusKeyManagerItemDirective) }]
1336
+ }]
1337
+ }], ctorParameters: function () { return [{ type: FocusKeyManagerListDirective }, { type: i0.ElementRef }]; }, propDecorators: { initialFocus: [{
1338
+ type: Input
1339
+ }], _tabindex: [{
1340
+ type: Input
1341
+ }, {
1342
+ type: HostBinding,
1343
+ args: ['attr.tabindex']
1344
+ }], _onFocus: [{
1345
+ type: HostListener,
1346
+ args: ['focus']
1347
+ }], _onKeydown: [{
1348
+ type: HostListener,
1349
+ args: ['keydown', ['$event']]
1350
+ }] } });
1351
+
1352
+ class FocusKeyManagerHelpersModule {
1353
+ }
1354
+ FocusKeyManagerHelpersModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1355
+ FocusKeyManagerHelpersModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule, imports: [FocusKeyManagerItemDirective,
1356
+ FocusKeyManagerListDirective,
1357
+ DeprecatedFocusKeyManagerItemDirective,
1358
+ DeprecatedFocusKeyManagerListDirective], exports: [FocusKeyManagerItemDirective,
1359
+ FocusKeyManagerListDirective,
1360
+ DeprecatedFocusKeyManagerItemDirective,
1361
+ DeprecatedFocusKeyManagerListDirective] });
1362
+ FocusKeyManagerHelpersModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule });
1363
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FocusKeyManagerHelpersModule, decorators: [{
1364
+ type: NgModule,
1365
+ args: [{
1366
+ imports: [
1367
+ FocusKeyManagerItemDirective,
1368
+ FocusKeyManagerListDirective,
1369
+ DeprecatedFocusKeyManagerItemDirective,
1370
+ DeprecatedFocusKeyManagerListDirective
1371
+ ],
1372
+ exports: [
1373
+ FocusKeyManagerItemDirective,
1374
+ FocusKeyManagerListDirective,
1375
+ DeprecatedFocusKeyManagerItemDirective,
1376
+ DeprecatedFocusKeyManagerListDirective
1377
+ ]
1378
+ }]
1379
+ }] });
1380
+
1381
+ const IgnoreClickOnSelectionDirectiveToken = new InjectionToken('Ignore click on selection directive');
1382
+
1383
+ class DeprecatedIgnoreClickOnSelectionDirective extends DeprecatedSelector {
1384
+ }
1385
+ DeprecatedIgnoreClickOnSelectionDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedIgnoreClickOnSelectionDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
1386
+ DeprecatedIgnoreClickOnSelectionDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DeprecatedIgnoreClickOnSelectionDirective, isStandalone: true, selector: "[fdIgnoreClickOnSelection]", providers: [
1387
+ {
1388
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1389
+ useValue: getDeprecatedModel('[fdkIgnoreClickOnSelection]', '[fdIgnoreClickOnSelection]')
1390
+ }
1391
+ ], usesInheritance: true, ngImport: i0 });
1392
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedIgnoreClickOnSelectionDirective, decorators: [{
1393
+ type: Directive,
1394
+ args: [{
1395
+ // eslint-disable-next-line @angular-eslint/directive-selector
1396
+ selector: '[fdIgnoreClickOnSelection]',
1397
+ standalone: true,
1398
+ providers: [
1399
+ {
1400
+ provide: FD_DEPRECATED_DIRECTIVE_SELECTOR,
1401
+ useValue: getDeprecatedModel('[fdkIgnoreClickOnSelection]', '[fdIgnoreClickOnSelection]')
1402
+ }
1403
+ ]
1404
+ }]
1405
+ }] });
1406
+ /**
1407
+ * Directive will stop propagation and prevent default of click, if selected area is coming from
1408
+ * directive's host element. This gives ability to not cancel all clicks on element, just the ones
1409
+ * which include selection
1410
+ */
1411
+ class IgnoreClickOnSelectionDirective {
1437
1412
  /** @hidden */
1438
- _cleanupObserver(element) {
1439
- if (this._observedElements.has(element)) {
1440
- const { observer, stream } = this._observedElements.get(element);
1441
- if (observer) {
1442
- observer.disconnect();
1413
+ constructor(document, _elementRef) {
1414
+ this.document = document;
1415
+ this._elementRef = _elementRef;
1416
+ }
1417
+ /** Host click listener. Checks for selection existence and if finds one, checks anchor */
1418
+ clicked($event) {
1419
+ const selection = this.document.getSelection();
1420
+ if (selection === null || selection === void 0 ? void 0 : selection.toString()) {
1421
+ if (selection.anchorNode &&
1422
+ (this._elementRef.nativeElement.isSameNode(selection.anchorNode) ||
1423
+ this._elementRef.nativeElement.isSameNode(selection.anchorNode.parentElement))) {
1424
+ $event.stopPropagation();
1425
+ $event.preventDefault();
1443
1426
  }
1444
- stream.complete();
1445
- this._observedElements.delete(element);
1446
1427
  }
1447
1428
  }
1448
1429
  }
1449
- AttributeObserver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AttributeObserver, deps: [{ token: i1$2.MutationObserverFactory }], target: i0.ɵɵFactoryTarget.Injectable });
1450
- AttributeObserver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AttributeObserver, providedIn: 'root' });
1451
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: AttributeObserver, decorators: [{
1452
- type: Injectable,
1430
+ IgnoreClickOnSelectionDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionDirective, deps: [{ token: DOCUMENT }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
1431
+ IgnoreClickOnSelectionDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: IgnoreClickOnSelectionDirective, isStandalone: true, selector: "[fdkIgnoreClickOnSelection], [fdIgnoreClickOnSelection]", host: { listeners: { "click": "clicked($event)" } }, providers: [
1432
+ {
1433
+ provide: IgnoreClickOnSelectionDirectiveToken,
1434
+ useExisting: IgnoreClickOnSelectionDirective
1435
+ }
1436
+ ], ngImport: i0 });
1437
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionDirective, decorators: [{
1438
+ type: Directive,
1453
1439
  args: [{
1454
- providedIn: 'root'
1440
+ selector: '[fdkIgnoreClickOnSelection], [fdIgnoreClickOnSelection]',
1441
+ standalone: true,
1442
+ providers: [
1443
+ {
1444
+ provide: IgnoreClickOnSelectionDirectiveToken,
1445
+ useExisting: IgnoreClickOnSelectionDirective
1446
+ }
1447
+ ]
1455
1448
  }]
1456
- }], ctorParameters: function () { return [{ type: i1$2.MutationObserverFactory }]; } });
1449
+ }], ctorParameters: function () {
1450
+ return [{ type: Document, decorators: [{
1451
+ type: Inject,
1452
+ args: [DOCUMENT]
1453
+ }] }, { type: i0.ElementRef }];
1454
+ }, propDecorators: { clicked: [{
1455
+ type: HostListener,
1456
+ args: ['click', ['$event']]
1457
+ }] } });
1458
+
1459
+ class IgnoreClickOnSelectionModule {
1460
+ }
1461
+ IgnoreClickOnSelectionModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1462
+ IgnoreClickOnSelectionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule, imports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective], exports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective] });
1463
+ IgnoreClickOnSelectionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule });
1464
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: IgnoreClickOnSelectionModule, decorators: [{
1465
+ type: NgModule,
1466
+ args: [{
1467
+ imports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective],
1468
+ exports: [IgnoreClickOnSelectionDirective, DeprecatedIgnoreClickOnSelectionDirective]
1469
+ }]
1470
+ }] });
1457
1471
 
1458
1472
  class DeprecatedInitialFocusDirective extends DeprecatedSelector {
1459
1473
  constructor() {
@@ -1897,102 +1911,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
1897
1911
  }]
1898
1912
  }] });
1899
1913
 
1900
- class MultiAnnouncerDirective {
1901
- /** @hidden */
1902
- constructor(_language$) {
1903
- this._language$ = _language$;
1904
- /** @hidden */
1905
- this._translationResolver = new TranslationResolver();
1906
- /** @hidden */
1907
- this._noResultsAnnounced = false;
1908
- /** @hidden */
1909
- this._resultsAnnounced = false;
1910
- /** @hidden */
1911
- this._announcement = '';
1912
- /** @hidden */
1913
- this._liveAnnouncer = inject(LiveAnnouncer);
1914
- this._init();
1915
- }
1916
- /** @hidden */
1917
- _init() {
1918
- return __awaiter(this, void 0, void 0, function* () {
1919
- this._language = yield firstValueFrom(this._language$);
1920
- });
1921
- }
1922
- /** @hidden */
1923
- _makeSearchTermChangeAnnouncements(event) {
1924
- if (KeyUtil.isKeyType(event, 'alphabetical') || KeyUtil.isKeyType(event, 'numeric')) {
1925
- this._liveAnnouncer.clear();
1926
- if (!this.multiAnnouncerOptions.length && !this._noResultsAnnounced) {
1927
- this._buildAnnouncement('noResults');
1928
- this._noResultsAnnounced = true;
1929
- this._resultsAnnounced = false;
1930
- }
1931
- else if (this.multiAnnouncerOptions.length) {
1932
- this._buildAnnouncement(this.multiAnnouncerOptions.length);
1933
- if (!this._resultsAnnounced) {
1934
- this._buildAnnouncement('navigateSelectionsWithArrows');
1935
- this._noResultsAnnounced = false;
1936
- this._resultsAnnounced = true;
1937
- }
1938
- }
1939
- this._buildAnnouncement('escapeNavigateTokens');
1940
- this._makeAnnouncement(this._announcement);
1941
- }
1942
- }
1943
- /** @hidden */
1944
- _buildAnnouncement(message) {
1945
- this._announcement =
1946
- this._announcement +
1947
- this._translationResolver.resolve(this._language, typeof message === 'string'
1948
- ? 'coreMultiInput.' + message
1949
- : message === 1
1950
- ? 'coreMultiInput.countListResultsSingular'
1951
- : 'coreMultiInput.countListResultsPlural', { count: message }) +
1952
- ' ';
1953
- }
1954
- /** @hidden */
1955
- _makeAnnouncement(message) {
1956
- return __awaiter(this, void 0, void 0, function* () {
1957
- yield this._liveAnnouncer.announce(message, 'assertive').then(() => {
1958
- this._announcement = '';
1959
- });
1960
- });
1961
- }
1962
- }
1963
- MultiAnnouncerDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: MultiAnnouncerDirective, deps: [{ token: FD_LANGUAGE }], target: i0.ɵɵFactoryTarget.Directive });
1964
- MultiAnnouncerDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: MultiAnnouncerDirective, isStandalone: true, selector: "[fdkMultiAnnouncer]", inputs: { multiAnnouncerOptions: "multiAnnouncerOptions" }, host: { listeners: { "keyup": "_makeSearchTermChangeAnnouncements($event)" } }, exportAs: ["fdkMultiAnnouncer"], ngImport: i0 });
1965
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: MultiAnnouncerDirective, decorators: [{
1966
- type: Directive,
1967
- args: [{
1968
- selector: '[fdkMultiAnnouncer]',
1969
- exportAs: 'fdkMultiAnnouncer',
1970
- standalone: true
1971
- }]
1972
- }], ctorParameters: function () {
1973
- return [{ type: i1$3.Observable, decorators: [{
1974
- type: Inject,
1975
- args: [FD_LANGUAGE]
1976
- }] }];
1977
- }, propDecorators: { multiAnnouncerOptions: [{
1978
- type: Input
1979
- }], _makeSearchTermChangeAnnouncements: [{
1980
- type: HostListener,
1981
- args: ['keyup', ['$event']]
1982
- }] } });
1983
- class MultiAnnouncerModule {
1984
- }
1985
- MultiAnnouncerModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: MultiAnnouncerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1986
- MultiAnnouncerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.9", ngImport: i0, type: MultiAnnouncerModule, imports: [MultiAnnouncerDirective], exports: [MultiAnnouncerDirective] });
1987
- MultiAnnouncerModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: MultiAnnouncerModule });
1988
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: MultiAnnouncerModule, decorators: [{
1989
- type: NgModule,
1990
- args: [{
1991
- imports: [MultiAnnouncerDirective],
1992
- exports: [MultiAnnouncerDirective]
1993
- }]
1994
- }] });
1995
-
1996
1914
  class DeprecatedOnlyDigitsDirective extends DeprecatedSelector {
1997
1915
  }
1998
1916
  DeprecatedOnlyDigitsDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DeprecatedOnlyDigitsDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
@@ -2373,7 +2291,7 @@ class OverflowListDirective {
2373
2291
  });
2374
2292
  }
2375
2293
  }
2376
- OverflowListDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: OverflowListDirective, deps: [{ token: i0.ElementRef }, { token: i1$4.ViewportRuler }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
2294
+ OverflowListDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: OverflowListDirective, deps: [{ token: i0.ElementRef }, { token: i1$3.ViewportRuler }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
2377
2295
  OverflowListDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: OverflowListDirective, isStandalone: true, selector: "[fdkOverflowList], [fdOverflowList], [fd-overflow-list]", inputs: { overflowOffset: "overflowOffset", isRtl: "isRtl", itemCssBlockValue: "itemCssBlockValue" }, outputs: { overflowChanged: "overflowChanged" }, queries: [{ propertyName: "overflowItems", predicate: OverflowListItemDirective }], ngImport: i0 });
2378
2296
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: OverflowListDirective, decorators: [{
2379
2297
  type: Directive,
@@ -2381,7 +2299,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
2381
2299
  selector: '[fdkOverflowList], [fdOverflowList], [fd-overflow-list]',
2382
2300
  standalone: true
2383
2301
  }]
2384
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$4.ViewportRuler }, { type: i0.NgZone }]; }, propDecorators: { overflowOffset: [{
2302
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$3.ViewportRuler }, { type: i0.NgZone }]; }, propDecorators: { overflowOffset: [{
2385
2303
  type: Input
2386
2304
  }], isRtl: [{
2387
2305
  type: Input
@@ -6057,7 +5975,7 @@ class DndItemDirective {
6057
5975
  }));
6058
5976
  }
6059
5977
  }
6060
- DndItemDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DndItemDirective, deps: [{ token: i0.ElementRef }, { token: i1$5.DragDrop }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
5978
+ DndItemDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DndItemDirective, deps: [{ token: i0.ElementRef }, { token: i1$4.DragDrop }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
6061
5979
  DndItemDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.9", type: DndItemDirective, selector: "[fdkDndItem], [fd-dnd-item]", inputs: { item: ["fdkDndItem", "item"], applyDragItemClass: "applyDragItemClass", containerSelector: "containerSelector", stickInPlace: "stickInPlace", draggable: "draggable", classWhenElementDragged: "classWhenElementDragged" }, outputs: { moved: "moved", released: "released", started: "started" }, host: { properties: { "class.fd-dnd-item": "this.applyDragItemClass" } }, providers: [DragDrop, { provide: DND_ITEM, useExisting: forwardRef(() => DndItemDirective) }], ngImport: i0 });
6062
5980
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DndItemDirective, decorators: [{
6063
5981
  type: Directive,
@@ -6065,7 +5983,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
6065
5983
  selector: '[fdkDndItem], [fd-dnd-item]',
6066
5984
  providers: [DragDrop, { provide: DND_ITEM, useExisting: forwardRef(() => DndItemDirective) }]
6067
5985
  }]
6068
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$5.DragDrop }, { type: i0.Renderer2 }]; }, propDecorators: { item: [{
5986
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$4.DragDrop }, { type: i0.Renderer2 }]; }, propDecorators: { item: [{
6069
5987
  type: Input,
6070
5988
  args: ['fdkDndItem']
6071
5989
  }], applyDragItemClass: [{
@@ -6509,7 +6427,7 @@ class DynamicPortalComponent {
6509
6427
  }
6510
6428
  }
6511
6429
  DynamicPortalComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DynamicPortalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
6512
- DynamicPortalComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DynamicPortalComponent, isStandalone: true, selector: "fdk-dynamic-portal", inputs: { domElement: "domElement", component: "component", template: "template" }, usesOnChanges: true, ngImport: i0, template: ` <ng-template [cdkPortalOutlet]="portal"></ng-template>`, isInline: true, dependencies: [{ kind: "ngmodule", type: PortalModule }, { kind: "directive", type: i1$6.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }] });
6430
+ DynamicPortalComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: DynamicPortalComponent, isStandalone: true, selector: "fdk-dynamic-portal", inputs: { domElement: "domElement", component: "component", template: "template" }, usesOnChanges: true, ngImport: i0, template: ` <ng-template [cdkPortalOutlet]="portal"></ng-template>`, isInline: true, dependencies: [{ kind: "ngmodule", type: PortalModule }, { kind: "directive", type: i1$5.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }] });
6513
6431
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: DynamicPortalComponent, decorators: [{
6514
6432
  type: Component,
6515
6433
  args: [{
@@ -7263,11 +7181,11 @@ class BaseToastService {
7263
7181
  return !!position.boundTo;
7264
7182
  }
7265
7183
  }
7266
- BaseToastService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BaseToastService, deps: [{ token: i1$4.Overlay }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
7184
+ BaseToastService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BaseToastService, deps: [{ token: i1$3.Overlay }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
7267
7185
  BaseToastService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BaseToastService });
7268
7186
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BaseToastService, decorators: [{
7269
7187
  type: Injectable
7270
- }], ctorParameters: function () { return [{ type: i1$4.Overlay }, { type: i0.Injector }]; } });
7188
+ }], ctorParameters: function () { return [{ type: i1$3.Overlay }, { type: i0.Injector }]; } });
7271
7189
 
7272
7190
  const toastConnectedTopPosition = {
7273
7191
  originX: 'center',
@@ -7756,5 +7674,5 @@ class BaseToastDurationDismissibleConfig extends BaseToastConfig {
7756
7674
  * Generated bundle index. Do not edit.
7757
7675
  */
7758
7676
 
7759
- export { ANY_LANGUAGE_LETTERS_GROUP_REGEX, ANY_LANGUAGE_LETTERS_REGEX, AbstractFdNgxClass, AsyncOrSyncPipe, AttributeObserver, AutoCompleteDirective, AutoCompleteModule, BaseAnimatedToastConfig, BaseDismissibleToastService, BaseToastActionDismissibleRef, BaseToastConfig, BaseToastContainerComponent, BaseToastDurationDismissibleConfig, BaseToastDurationDismissibleContainerComponent, BaseToastDurationDismissibleRef, BaseToastOverlayContainer, BaseToastPosition, BaseToastRef, BaseToastService, BreakpointDirective, BreakpointModule, ClickedBehaviorModule, ClickedDirective, ContentDensityService, DECIMAL_NUMBER_UNICODE_GROUP_REGEX, DECIMAL_NUMBER_UNICODE_RANGE, DECIMAL_NUMBER_UNICODE_REGEX, DEFAULT_CONTENT_DENSITY, DND_ITEM, DND_LIST, DefaultReadonlyViewModifier, DeprecatedAutoCompleteDirective, DeprecatedClickedDirective, DeprecatedDisabledBehaviorDirective, DeprecatedFocusKeyManagerItemDirective, DeprecatedFocusKeyManagerListDirective, DeprecatedFocusableItemDirective, DeprecatedFocusableListDirective, DeprecatedIgnoreClickOnSelectionDirective, DeprecatedInitialFocusDirective, DeprecatedLineClampDirective, DeprecatedLineClampTargetDirective, DeprecatedOnlyDigitsDirective, DeprecatedOverflowListDirective, DeprecatedOverflowListItemDirective, DeprecatedReadonlyBehaviorDirective, DeprecatedRepeatDirective, DeprecatedResizeDirective, DeprecatedResizeHandleDirective, DeprecatedTemplateSelectorDirective, DeprecatedTruncateSelectorDirective, DestroyedService, DisabledBehaviorDirective, DisabledBehaviorModule, DisabledObserver, DisplayFnPipe, DndItemDirective, DndKeyboardGroupDirective, DndKeyboardItemDirective, DndListDirective, DragAndDropModule, DynamicComponentContainer, DynamicComponentInjector, DynamicComponentService, DynamicPortalComponent, ELEMENT_REF_EXCEPTION, FDK_DISABLED_DIRECTIVE, FDK_FOCUSABLE_GRID_DIRECTIVE, FDK_FOCUSABLE_ITEM_DIRECTIVE, FDK_FOCUSABLE_LIST_DIRECTIVE, FDK_READONLY_DIRECTIVE, FDK_SELECTABLE_ITEM_PROVIDER, FOCUSABLE_ITEM, FdkClickedProvider, FdkDisabledProvider, FdkReadonlyProvider, FilterStringsPipe, FocusKeyManagerHelpersModule, FocusKeyManagerItemDirective, FocusKeyManagerListDirective, FocusTrapService, FocusableGridDirective, FocusableGridModule, FocusableItemDirective, FocusableItemModule, FocusableListDirective, FocusableListModule, FocusableObserver, FunctionStrategy, INVALID_DATE_ERROR, IgnoreClickOnSelectionDirective, IgnoreClickOnSelectionDirectiveToken, IgnoreClickOnSelectionModule, InitialFocusDirective, InitialFocusModule, IntersectionSpyDirective, IsCompactDensityPipe, KeyUtil, KeyboardSupportService, LETTERS_UNICODE_RANGE, LIST_ITEM_COMPONENT, LineClampDirective, LineClampModule, LineClampTargetDirective, LocalStorageService, MOBILE_CONFIG_ERROR, MakeAsyncPipe, ModuleDeprecations, MultiAnnouncerDirective, MultiAnnouncerModule, OVERFLOW_PRIORITY_SCORE, ObservableStrategy, OnlyDigitsDirective, OnlyDigitsModule, OverflowListDirective, OverflowListItemDirective, OverflowListModule, PipeModule, PromiseStrategy, RTL_LANGUAGE, RangeSelector, ReadonlyBehaviorDirective, ReadonlyBehaviorModule, ReadonlyObserver, RepeatDirective, RepeatModule, ResizeDirective, ResizeHandleDirective, ResizeModule, ResizeObserverFactory, ResizeObserverService, ResponsiveBreakpoints, RtlService, SafePipe, SearchHighlightPipe, SelectComponentRootToken, SelectableItemDirective, SelectableItemToken, SelectableListDirective, SelectableListModule, SelectionService, THEME_SWITCHER_ROUTER_MISSING_ERROR, TabbableElementService, TemplateDirective, TemplateModule, ThemesService, ToastBottomCenterPosition, ToastBottomLeftPosition, ToastBottomRightPosition, ToastTopCenterPosition, ToastTopLeftPosition, ToastTopRightPosition, TruncateDirective, TruncateModule, TruncatePipe, TwoDigitsPipe, UtilsModule, ValueByPathPipe, ValueStrategy, ViewportSizeObservable, alternateSetter, applyCssClass, applyCssStyle, baseToastAnimations, coerceArraySafe, coerceBoolean, coerceCssPixel, consumerProviderFactory, dfs, getBreakpointName, getDocumentFontSize, getElementCapacity, getElementWidth, getNativeElement, getRandomColorAccent, hasElementRef, intersectionObservable, isBlank, isBoolean, isCompactDensity, isFunction, isJsObject, isNumber, isObject, isOdd, isPresent, isPromise, isString, isStringMap, isSubscribable, isType, isValidContentDensity, moduleDeprecationsFactory, moduleDeprecationsProvider, parserFileSize, pxToNum, resizeObservable, scrollIntoView, scrollTop, selectStrategy, setDisabledState, setReadonlyState, toNativeElement, toastConnectedBottomLeftPosition, toastConnectedBottomPosition, toastConnectedBottomRightPosition, toastConnectedTopLeftPosition, toastConnectedTopPosition, toastConnectedTopRightPosition, uuidv4 };
7677
+ export { ANY_LANGUAGE_LETTERS_GROUP_REGEX, ANY_LANGUAGE_LETTERS_REGEX, AbstractFdNgxClass, AsyncOrSyncPipe, AttributeObserver, AutoCompleteDirective, AutoCompleteModule, BaseAnimatedToastConfig, BaseDismissibleToastService, BaseToastActionDismissibleRef, BaseToastConfig, BaseToastContainerComponent, BaseToastDurationDismissibleConfig, BaseToastDurationDismissibleContainerComponent, BaseToastDurationDismissibleRef, BaseToastOverlayContainer, BaseToastPosition, BaseToastRef, BaseToastService, BreakpointDirective, BreakpointModule, ClickedBehaviorModule, ClickedDirective, ContentDensityService, DECIMAL_NUMBER_UNICODE_GROUP_REGEX, DECIMAL_NUMBER_UNICODE_RANGE, DECIMAL_NUMBER_UNICODE_REGEX, DEFAULT_CONTENT_DENSITY, DND_ITEM, DND_LIST, DefaultReadonlyViewModifier, DeprecatedAutoCompleteDirective, DeprecatedClickedDirective, DeprecatedDisabledBehaviorDirective, DeprecatedFocusKeyManagerItemDirective, DeprecatedFocusKeyManagerListDirective, DeprecatedFocusableItemDirective, DeprecatedFocusableListDirective, DeprecatedIgnoreClickOnSelectionDirective, DeprecatedInitialFocusDirective, DeprecatedLineClampDirective, DeprecatedLineClampTargetDirective, DeprecatedOnlyDigitsDirective, DeprecatedOverflowListDirective, DeprecatedOverflowListItemDirective, DeprecatedReadonlyBehaviorDirective, DeprecatedRepeatDirective, DeprecatedResizeDirective, DeprecatedResizeHandleDirective, DeprecatedTemplateSelectorDirective, DeprecatedTruncateSelectorDirective, DestroyedService, DisabledBehaviorDirective, DisabledBehaviorModule, DisabledObserver, DisplayFnPipe, DndItemDirective, DndKeyboardGroupDirective, DndKeyboardItemDirective, DndListDirective, DragAndDropModule, DynamicComponentContainer, DynamicComponentInjector, DynamicComponentService, DynamicPortalComponent, ELEMENT_REF_EXCEPTION, FDK_DISABLED_DIRECTIVE, FDK_FOCUSABLE_GRID_DIRECTIVE, FDK_FOCUSABLE_ITEM_DIRECTIVE, FDK_FOCUSABLE_LIST_DIRECTIVE, FDK_READONLY_DIRECTIVE, FDK_SELECTABLE_ITEM_PROVIDER, FOCUSABLE_ITEM, FdkClickedProvider, FdkDisabledProvider, FdkReadonlyProvider, FilterStringsPipe, FocusKeyManagerHelpersModule, FocusKeyManagerItemDirective, FocusKeyManagerListDirective, FocusTrapService, FocusableGridDirective, FocusableGridModule, FocusableItemDirective, FocusableItemModule, FocusableListDirective, FocusableListModule, FocusableObserver, FunctionStrategy, INVALID_DATE_ERROR, IgnoreClickOnSelectionDirective, IgnoreClickOnSelectionDirectiveToken, IgnoreClickOnSelectionModule, InitialFocusDirective, InitialFocusModule, IntersectionSpyDirective, IsCompactDensityPipe, KeyUtil, KeyboardSupportService, LETTERS_UNICODE_RANGE, LIST_ITEM_COMPONENT, LineClampDirective, LineClampModule, LineClampTargetDirective, LocalStorageService, MOBILE_CONFIG_ERROR, MakeAsyncPipe, ModuleDeprecations, OVERFLOW_PRIORITY_SCORE, ObservableStrategy, OnlyDigitsDirective, OnlyDigitsModule, OverflowListDirective, OverflowListItemDirective, OverflowListModule, PipeModule, PromiseStrategy, RTL_LANGUAGE, RangeSelector, ReadonlyBehaviorDirective, ReadonlyBehaviorModule, ReadonlyObserver, RepeatDirective, RepeatModule, ResizeDirective, ResizeHandleDirective, ResizeModule, ResizeObserverFactory, ResizeObserverService, ResponsiveBreakpoints, RtlService, SafePipe, SearchHighlightPipe, SelectComponentRootToken, SelectableItemDirective, SelectableItemToken, SelectableListDirective, SelectableListModule, SelectionService, THEME_SWITCHER_ROUTER_MISSING_ERROR, TabbableElementService, TemplateDirective, TemplateModule, ThemesService, ToastBottomCenterPosition, ToastBottomLeftPosition, ToastBottomRightPosition, ToastTopCenterPosition, ToastTopLeftPosition, ToastTopRightPosition, TruncateDirective, TruncateModule, TruncatePipe, TwoDigitsPipe, UtilsModule, ValueByPathPipe, ValueStrategy, ViewportSizeObservable, alternateSetter, applyCssClass, applyCssStyle, baseToastAnimations, coerceArraySafe, coerceBoolean, coerceCssPixel, consumerProviderFactory, dfs, getBreakpointName, getDocumentFontSize, getElementCapacity, getElementWidth, getNativeElement, getRandomColorAccent, hasElementRef, intersectionObservable, isBlank, isBoolean, isCompactDensity, isFunction, isJsObject, isNumber, isObject, isOdd, isPresent, isPromise, isString, isStringMap, isSubscribable, isType, isValidContentDensity, moduleDeprecationsFactory, moduleDeprecationsProvider, parserFileSize, pxToNum, resizeObservable, scrollIntoView, scrollTop, selectStrategy, setDisabledState, setReadonlyState, toNativeElement, toastConnectedBottomLeftPosition, toastConnectedBottomPosition, toastConnectedBottomRightPosition, toastConnectedTopLeftPosition, toastConnectedTopPosition, toastConnectedTopRightPosition, uuidv4 };
7760
7678
  //# sourceMappingURL=fundamental-ngx-cdk-utils.mjs.map