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

Function Toolbar

starters/hooks/src/Toolbar.tsx:11–23  ·  view source on GitHub ↗
(props: ToolbarProps)

Source from the content-addressed store, hash-verified

9}
10
11export function Toolbar(props: ToolbarProps) {
12 let {orientation = 'horizontal'} = props;
13 let ref = useRef<HTMLDivElement>(null);
14 /*- begin highlight -*/
15 let {toolbarProps} = useToolbar(props, ref);
16 /*- end highlight -*/
17
18 return (
19 <div {...toolbarProps} ref={ref} className="react-aria-Toolbar" data-orientation={orientation}>
20 {props.children}
21 </div>
22 );
23}

Callers

nothing calls this directly

Calls 1

useToolbarFunction · 0.90

Tested by

no test coverage detected