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

Function click

src/aria/listbox/listbox.spec.ts:36–44  ·  view source on GitHub ↗
(index: number, eventInit?: PointerEventInit, targets?: HTMLElement[])

Source from the content-addressed store, hash-verified

34 };
35
36 const click = async (index: number, eventInit?: PointerEventInit, targets?: HTMLElement[]) => {
37 (targets || optionElements)[index].dispatchEvent(
38 new PointerEvent('click', {
39 bubbles: true,
40 ...eventInit,
41 }),
42 );
43 await fixture.whenStable();
44 };
45
46 const space = async (modifierKeys?: ModifierKeys) => await keydown(' ', modifierKeys);
47 const enter = async (modifierKeys?: ModifierKeys) => await keydown('Enter', modifierKeys);

Callers 2

listbox.spec.tsFile · 0.70
runNavigationTestsFunction · 0.70

Calls 1

dispatchEventMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…