Examples › Basic configuration
The ContextMenuProvider
component accepts the following props that are used as default values for the context menu container:
zIndex: number
→ defaults to9999
shadow: MantineShadow
→ defaults tosm
(see Mantine Paper docs)borderRadius: MantineSize
→ defaults toxs
(see Mantine Paper docs)
The zIndex
value can be overridden by setting the zIndex
property to the options object passed as the second argument to the showContextMenu
function returned by the useContextMenu
hook:
Right-click on the image to trigger the context menu:
Picture by Michael Sum
Head over to the next example to discover other features.