Skip to content

Commit

Permalink
Feat: Support the use of the 'Delete' key to remove nodes (#66)
Browse files Browse the repository at this point in the history
  • Loading branch information
Bowen7 authored Mar 14, 2023
1 parent 151e5f9 commit be881ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/editor/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ const Editor = ({ defaultTab }: Props) => {
useEvent("keydown", (e: Event) => {
const event = e as KeyboardEvent
const { key } = event
if (key === "Backspace") {
if (key === "Backspace" || key === "Delete") {
e.preventDefault()
return remove()
}
Expand Down

1 comment on commit be881ea

@vercel
Copy link

@vercel vercel bot commented on be881ea Mar 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

regex-vis – ./

regex-vis-git-master-bowen.vercel.app
regex-vis-bowen.vercel.app
regex-vis.com

Please sign in to comment.