Skip to content

Commit

Permalink
Implement Undo & Redo keyboard shortcuts (#382)
Browse files Browse the repository at this point in the history
* Implement `Undo` & `Redo` keyboard shortcuts

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update selector to `.jp-jupytercad-panel`

* Remove logging statements

* Use `body` as selector for all keybindings for now

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
arjxn-py and pre-commit-ci[bot] authored Jul 30, 2024
1 parent 3fee6cf commit bbccb3d
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions packages/base/src/keybindings.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
[
{
"command": "jupytercad:removeObject",
"keys": ["Delete"],
"selector": ".jp-jupytercad-panel"
"command": "jupytercad:undo",
"keys": ["Accel Z"],
"selector": "body"
},
{
"command": "jupytercad:redo",
"keys": ["Accel Y"],
"selector": "body"
},
{
"command": "jupytercad:removeObject",
"keys": ["Delete"],
"selector": ".jpcad-treeview-wrapper"
"selector": "body"
}
]

0 comments on commit bbccb3d

Please sign in to comment.