projects/storefrontlib/layout/a11y/keyboard-focus/focus.directive.ts
| Selector | [cxFocus] |
Properties |
|
Inputs |
constructor(elementRef: ElementRef, service: KeyboardFocusService, renderer: Renderer2)
|
||||||||||||
|
Parameters :
|
| cxFocus | |
Type : FocusConfig
|
|
Default value : {}
|
|
| config |
Type : FocusConfig
|
Default value : {}
|
Decorators :
@Input('cxFocus')
|
| Protected defaultConfig |
Type : FocusConfig
|
Default value : {}
|
import { Directive, ElementRef, Input, Renderer2 } from '@angular/core';
import { FocusConfig } from './keyboard-focus.model';
import { LockFocusDirective } from './lock/lock-focus.directive';
import { KeyboardFocusService } from './services/keyboard-focus.service';
@Directive({
selector: '[cxFocus]',
})
export class FocusDirective extends LockFocusDirective {
protected defaultConfig: FocusConfig = {};
@Input('cxFocus') config: FocusConfig = {};
constructor(
protected elementRef: ElementRef,
protected service: KeyboardFocusService,
protected renderer: Renderer2
) {
super(elementRef, service, renderer);
}
}