managedFocusComponent.d.ts 1.5 KB

123456789101112131415161718192021222324252627282930313233343536
  1. import { Component } from "./component";
  2. import { FocusController } from "../focusController";
  3. /**
  4. * This provides logic to override the default browser focus logic.
  5. *
  6. * When the component gets focus, it uses the grid logic to find out what should be focused,
  7. * and then focuses that instead.
  8. *
  9. * This is how we ensure when user tabs into the relevant section, we focus the correct item.
  10. * For example GridCore extends ManagedFocusComponent, and it ensures when it receives focus
  11. * that focus goes to the first cell of the first header row.
  12. */
  13. export declare class ManagedFocusComponent extends Component {
  14. protected onTabKeyDown?(e: KeyboardEvent): void;
  15. protected handleKeyDown?(e: KeyboardEvent): void;
  16. static FOCUS_MANAGED_CLASS: string;
  17. private topTabGuard;
  18. private bottomTabGuard;
  19. private skipTabGuardFocus;
  20. protected focusController: FocusController;
  21. protected postConstruct(): void;
  22. protected wireFocusManagement(): void;
  23. protected isFocusableContainer(): boolean;
  24. protected focusInnerElement(fromBottom?: boolean): void;
  25. protected onFocusIn(e: FocusEvent): void;
  26. protected onFocusOut(e: FocusEvent): void;
  27. forceFocusOutOfContainer(): void;
  28. appendChild(newChild: HTMLElement | Component, container?: HTMLElement): void;
  29. private createTabGuard;
  30. private addTabGuards;
  31. private forEachTabGuard;
  32. private addKeyDownListeners;
  33. private onFocus;
  34. private activateTabGuards;
  35. private deactivateTabGuards;
  36. }