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

Function getVisibleTreeItems

src/aria/combobox/combobox.spec.ts:711–723  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

709 }
710
711 function getVisibleTreeItems(): HTMLElement[] {
712 return fixture.debugElement
713 .queryAll(By.directive(TreeItem))
714 .map((debugEl: DebugElement) => debugEl.nativeElement as HTMLElement)
715 .filter(el => {
716 if (el.parentElement?.role === 'group') {
717 return (
718 el.parentElement.previousElementSibling?.getAttribute('aria-expanded') === 'true'
719 );
720 }
721 return true;
722 });
723 }
724
725 afterEach(async () => {
726 await runAccessibilityChecks(fixture.nativeElement);

Callers 1

combobox.spec.tsFile · 0.85

Calls 2

getAttributeMethod · 0.65
filterMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…