We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a0bb511 + 4cb4859 commit e2aaa86Copy full SHA for e2aaa86
src/ShortcutsManager/index.js
@@ -58,6 +58,11 @@ export const defaultHotkeys = [
58
description: "Delete selected region",
59
binding: "Delete",
60
},
61
+ {
62
+ id: "undo",
63
+ description: "Undo latest change",
64
+ binding: "Ctrl+z",
65
+ },
66
]
67
export const defaultKeyMap = {}
68
for (const { id, binding } of defaultHotkeys) defaultKeyMap[id] = binding
@@ -130,6 +135,11 @@ export const useDispatchHotkeyHandlers = ({ dispatch }) => {
130
135
type: "DELETE_SELECTED_REGION",
131
136
})
132
137
138
+ undo: () => {
139
+ dispatch({
140
+ type: "RESTORE_HISTORY",
141
+ })
142
133
143
// TODO
134
144
// exit_sample: () => {
145
// dispatch({
0 commit comments