Toolbar
A toolbar for the CodeBlock
component that displays the filename, a source link, and copy button.
API Reference
Toolbar
(props: ToolbarProps) => JSX.Element
A toolbar for the CodeBlock
component that displays the filename, a source link, and copy button.
Parameters
ToolbarProps
Returns
ElementToolbarProps
ToolbarProps
Properties
value
string | undefined
The value of the code block.
allowCopy
boolean | undefined
Whether or not to allow copying the code block value.
css
CSSObject | undefined
CSS object to apply to the toolbar.
className
string | undefined
Class name to apply to the toolbar.
style
React.CSSProperties | undefined
Style to apply to the toolbar.
children
React.ReactNode
The children of the toolbar rendered at the start.
Last updated