MCPcopy Create free account
hub / github.com/angular/components / constructor

Method constructor

src/cdk/a11y/focus-trap/focus-trap.ts:74–85  ·  view source on GitHub ↗
(
    readonly _element: HTMLElement,
    private _checker: InteractivityChecker,
    readonly _ngZone: NgZone,
    readonly _document: Document,
    deferAnchors = false,
    readonly _injector: Injector,
  )

Source from the content-addressed store, hash-verified

72 protected _enabled: boolean = true;
73
74 constructor(
75 readonly _element: HTMLElement,
76 private _checker: InteractivityChecker,
77 readonly _ngZone: NgZone,
78 readonly _document: Document,
79 deferAnchors = false,
80 readonly _injector: Injector,
81 ) {
82 if (!deferAnchors) {
83 this.attachAnchors();
84 }
85 }
86
87 /** Destroys the focus trap by cleaning up the anchors. */
88 destroy() {

Callers

nothing calls this directly

Calls 1

attachAnchorsMethod · 0.95

Tested by

no test coverage detected