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

Function TabPanel

packages/react-aria/stories/tabs/example.tsx:75–83  ·  view source on GitHub ↗
({state, ...props})

Source from the content-addressed store, hash-verified

73}
74
75function TabPanel({state, ...props}) {
76 let ref = React.useRef(null);
77 let {tabPanelProps} = useTabPanel(props, state, ref);
78 return (
79 <div {...tabPanelProps} ref={ref} style={{padding: '10px'}}>
80 {state.selectedItem?.props.children}
81 </div>
82 );
83}

Callers

nothing calls this directly

Calls 1

useTabPanelFunction · 0.90

Tested by

no test coverage detected