@leanix/components 0.4.93 → 0.4.94

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.
@@ -20,12 +20,16 @@ export declare class OptionComponent {
20
20
  select: EventEmitter<any>;
21
21
  highlight: EventEmitter<boolean>;
22
22
  selectedClick: EventEmitter<any>;
23
+ keyDownAction: EventEmitter<KeyboardEvent>;
24
+ option?: ElementRef<HTMLElement>;
23
25
  hasSubdropdown: boolean;
24
26
  isSuboption: boolean;
27
+ readonly optionId: string;
25
28
  selectOption(event?: MouseEvent): void;
26
29
  constructor(group: OptionGroupComponent, elementRef: ElementRef<HTMLElement>);
27
30
  setSelected(value: boolean): void;
28
31
  setHighlighted(value: boolean): void;
32
+ handleKeyDown(event: KeyboardEvent): void;
29
33
  static ɵfac: i0.ɵɵFactoryDeclaration<OptionComponent, [{ optional: true; }, null]>;
30
- static ɵcmp: i0.ɵɵComponentDeclaration<OptionComponent, "lx-option", never, { "selected": { "alias": "selected"; "required": false; }; "isHighlighted": { "alias": "isHighlighted"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "value": { "alias": "value"; "required": false; }; "hasSelectedState": { "alias": "hasSelectedState"; "required": false; }; "selectIcon": { "alias": "selectIcon"; "required": false; }; }, { "select": "select"; "highlight": "highlight"; "selectedClick": "selectedClick"; }, never, ["*"], true, never>;
34
+ static ɵcmp: i0.ɵɵComponentDeclaration<OptionComponent, "lx-option", never, { "selected": { "alias": "selected"; "required": false; }; "isHighlighted": { "alias": "isHighlighted"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "value": { "alias": "value"; "required": false; }; "hasSelectedState": { "alias": "hasSelectedState"; "required": false; }; "selectIcon": { "alias": "selectIcon"; "required": false; }; }, { "select": "select"; "highlight": "highlight"; "selectedClick": "selectedClick"; "keyDownAction": "keyDownAction"; }, never, ["*"], true, never>;
31
35
  }
@@ -1,5 +1,5 @@
1
1
  import { ConnectedPosition, ScrollStrategy, ScrollStrategyOptions } from '@angular/cdk/overlay';
2
- import { AfterViewInit, ChangeDetectorRef, OnDestroy, QueryList } from '@angular/core';
2
+ import { AfterViewInit, ChangeDetectorRef, OnDestroy, QueryList, Renderer2 } from '@angular/core';
3
3
  import { Subject } from 'rxjs';
4
4
  import { KeyboardActionSourceDirective } from '../../directives/keyboard-action-source.directive';
5
5
  import { OptionComponent } from '../option/option.component';
@@ -7,6 +7,7 @@ import * as i0 from "@angular/core";
7
7
  export declare class OptionsDropdownComponent implements AfterViewInit, OnDestroy {
8
8
  private changeDetection;
9
9
  private readonly scrollStrategies;
10
+ private renderer;
10
11
  readonly NAME = "OptionsDropdownComponent";
11
12
  align: 'right' | 'left';
12
13
  closeOnScroll: boolean;
@@ -21,11 +22,14 @@ export declare class OptionsDropdownComponent implements AfterViewInit, OnDestro
21
22
  set open(value: boolean);
22
23
  get open(): boolean;
23
24
  get options(): OptionComponent[];
25
+ get optionIds(): string[];
26
+ get lxButton(): HTMLElement;
24
27
  private readonly highlightedOptionIndex$;
25
28
  private _open;
26
29
  private isSubdropdownExpanded;
30
+ readonly listboxId: string;
27
31
  readonly destroyed$: Subject<void>;
28
- constructor(changeDetection: ChangeDetectorRef, scrollStrategies: ScrollStrategyOptions);
32
+ constructor(changeDetection: ChangeDetectorRef, scrollStrategies: ScrollStrategyOptions, renderer: Renderer2);
29
33
  ngAfterViewInit(): void;
30
34
  ngOnDestroy(): void;
31
35
  closeDropdown(): void;
@@ -35,6 +39,12 @@ export declare class OptionsDropdownComponent implements AfterViewInit, OnDestro
35
39
  private expand;
36
40
  private collapse;
37
41
  private optionIsHighlightable;
42
+ /**
43
+ * Programmatically sets initial accessibility attributes on the trigger button so that we
44
+ * don't have to do it manually every time we declare a new instance of this component
45
+ */
46
+ private setInitialAccessibilityAttributes;
47
+ handleOptionKeyDown(event: KeyboardEvent): void;
38
48
  static ɵfac: i0.ɵɵFactoryDeclaration<OptionsDropdownComponent, never>;
39
49
  static ɵcmp: i0.ɵɵComponentDeclaration<OptionsDropdownComponent, "lx-options-dropdown", never, { "align": { "alias": "align"; "required": false; }; "closeOnScroll": { "alias": "closeOnScroll"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "maxHeight": { "alias": "maxHeight"; "required": false; }; "closeOnSelect": { "alias": "closeOnSelect"; "required": false; }; "overlayPositioning": { "alias": "overlayPositioning"; "required": false; }; }, {}, ["trigger", "_options"], ["[lxKeyboardActionSource]", "*"], true, never>;
40
50
  }
@@ -6,10 +6,11 @@ export declare class KeyboardActionSourceDirective implements OnDestroy {
6
6
  private element;
7
7
  dontEmit: boolean;
8
8
  readonly destroyed$: Subject<void>;
9
- keyboardActions$: import("rxjs").Observable<KeyboardSelectAction.PREV | KeyboardSelectAction.NEXT | KeyboardSelectAction.LEFT | KeyboardSelectAction.RIGHT | KeyboardSelectAction.EXECUTE | KeyboardSelectAction.CLOSE | null>;
9
+ keyboardActions$: import("rxjs").Observable<KeyboardSelectAction.PREV | KeyboardSelectAction.NEXT | KeyboardSelectAction.FIRST | KeyboardSelectAction.LAST | KeyboardSelectAction.LEFT | KeyboardSelectAction.RIGHT | KeyboardSelectAction.EXECUTE | KeyboardSelectAction.CLOSE | null>;
10
10
  constructor(element: ElementRef<HTMLElement>);
11
11
  blur(): void;
12
12
  ngOnDestroy(): void;
13
+ nativeElement(): HTMLElement;
13
14
  static ɵfac: i0.ɵɵFactoryDeclaration<KeyboardActionSourceDirective, never>;
14
15
  static ɵdir: i0.ɵɵDirectiveDeclaration<KeyboardActionSourceDirective, "[lxKeyboardActionSource]", ["keyboardActionSource"], {}, {}, never, never, true, never>;
15
16
  }
@@ -7,3 +7,5 @@ export declare const ARROW_RIGHT = 39;
7
7
  export declare const ENTER = 13;
8
8
  export declare const ESCAPE = 27;
9
9
  export declare const SPACE = 32;
10
+ export declare const HOME = 36;
11
+ export declare const END = 35;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leanix/components",
3
- "version": "0.4.93",
3
+ "version": "0.4.94",
4
4
  "license": "Apache-2.0",
5
5
  "author": "LeanIX GmbH",
6
6
  "repository": {