MCPcopy
hub / github.com/angular/components / ngAfterViewInit

Method ngAfterViewInit

src/material/tooltip/tooltip.ts:407–423  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

405 }
406
407 ngAfterViewInit() {
408 // This needs to happen after view init so the initial values for all inputs have been set.
409 this._viewInitialized = true;
410 this._setupPointerEnterEventsIfNeeded();
411
412 this._focusMonitor
413 .monitor(this._elementRef)
414 .pipe(takeUntil(this._destroyed))
415 .subscribe(origin => {
416 // Note that the focus monitor runs outside the Angular zone.
417 if (!origin) {
418 this._ngZone.run(() => this.hide(0));
419 } else if (origin === 'keyboard') {
420 this._ngZone.run(() => this.show());
421 }
422 });
423 }
424
425 /**
426 * Dispose the tooltip when destroyed.

Callers

nothing calls this directly

Calls 4

hideMethod · 0.95
showMethod · 0.95
monitorMethod · 0.45

Tested by

no test coverage detected