mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-15 13:30:06 +02:00
feat: move contextMenu into the component tree and control via appState (#6021)
This commit is contained in:
@@ -18,6 +18,9 @@ export const actionToggleViewMode = register({
|
||||
};
|
||||
},
|
||||
checked: (appState) => appState.viewModeEnabled,
|
||||
contextItemPredicate: (elements, appState, appProps) => {
|
||||
return typeof appProps.viewModeEnabled === "undefined";
|
||||
},
|
||||
contextItemLabel: "labels.viewMode",
|
||||
keyTest: (event) =>
|
||||
!event[KEYS.CTRL_OR_CMD] && event.altKey && event.code === CODES.R,
|
||||
|
Reference in New Issue
Block a user