feat: Checkmark to toggle context-menu-items (#2645)

This commit is contained in:
Rene 2020-12-20 23:20:03 +01:00 committed by GitHub
parent aff817c667
commit 0faec7efb6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 27 additions and 17 deletions

View file

@ -3643,13 +3643,15 @@ class App extends React.Component<ExcalidrawProps, AppState> {
CANVAS_ONLY_ACTIONS.includes(action.name),
),
{
shortcutName: "toggleGridMode",
label: t("labels.toggleGridMode"),
checked: this.state.gridSize !== null,
shortcutName: "gridMode",
label: t("labels.gridMode"),
action: this.toggleGridMode,
},
{
shortcutName: "toggleStats",
label: t("labels.toggleStats"),
checked: this.state.showStats,
shortcutName: "stats",
label: t("labels.stats"),
action: this.toggleStats,
},
],