mirror of
https://github.com/chartdb/chartdb.git
synced 2026-05-07 04:40:16 -05:00
fix(readonly): fix zoom out on readonly (#818)
This commit is contained in:
@@ -82,13 +82,15 @@ export const CanvasContextMenu: React.FC<React.PropsWithChildren> = ({
|
||||
openCreateRelationshipDialog();
|
||||
}, [openCreateRelationshipDialog]);
|
||||
|
||||
if (!isDesktop || readonly) {
|
||||
if (!isDesktop) {
|
||||
return <>{children}</>;
|
||||
}
|
||||
|
||||
return (
|
||||
<ContextMenu>
|
||||
<ContextMenuTrigger>{children}</ContextMenuTrigger>
|
||||
<ContextMenuTrigger disabled={readonly}>
|
||||
{children}
|
||||
</ContextMenuTrigger>
|
||||
<ContextMenuContent>
|
||||
<ContextMenuItem
|
||||
onClick={createTableHandler}
|
||||
|
||||
Reference in New Issue
Block a user