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

Function TableCell

starters/hooks/src/Table.tsx:134–147  ·  view source on GitHub ↗
({cell, state}: {cell: Node<object>; state: TableState<object>})

Source from the content-addressed store, hash-verified

132}
133
134function TableCell({cell, state}: {cell: Node<object>; state: TableState<object>}) {
135 let ref = useRef<HTMLTableCellElement>(null);
136 let {gridCellProps} = useTableCell({node: cell}, state, ref);
137 let {isFocusVisible, focusProps} = useFocusRing();
138 return (
139 <td
140 {...mergeProps(gridCellProps, focusProps)}
141 ref={ref}
142 className="react-aria-Cell"
143 data-focus-visible={isFocusVisible || undefined}>
144 {cell.rendered}
145 </td>
146 );
147}

Callers

nothing calls this directly

Calls 3

useTableCellFunction · 0.90
useFocusRingFunction · 0.90
mergePropsFunction · 0.90

Tested by

no test coverage detected