MCPcopy Create free account
hub / github.com/adobe/react-spectrum / last

Function last

packages/react-aria/src/grid/useGridCell.ts:418–428  ·  view source on GitHub ↗
(walker: TreeWalker)

Source from the content-addressed store, hash-verified

416}
417
418function last(walker: TreeWalker) {
419 let next: FocusableElement | null = null;
420 let last: FocusableElement | null = null;
421 do {
422 last = walker.lastChild() as FocusableElement | null;
423 if (last) {
424 next = last;
425 }
426 } while (last);
427 return next;
428}

Callers 2

focusFunction · 0.70
onKeyDownCaptureFunction · 0.70

Calls 1

lastChildMethod · 0.45

Tested by

no test coverage detected