Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete table with backspace, if whole table is selected. #1583

Merged
merged 3 commits into from
Feb 17, 2023

Conversation

juliaroldi
Copy link
Contributor

@juliaroldi juliaroldi commented Feb 16, 2023

If the whole table is selected, delete the table if backspaced was pressed.
deleteTableBackspace

@juliaroldi juliaroldi force-pushed the u/juliaroldi/delete-table branch from cb7db7c to 99c09e3 Compare February 16, 2023 17:01
@juliaroldi juliaroldi marked this pull request as ready for review February 16, 2023 21:09
@juliaroldi juliaroldi changed the title delete table Delete table with backspace, if whole table is selected. Feb 16, 2023
keys: [Keys.BACKSPACE],
shouldHandleEvent: (event: PluginKeyboardEvent, editor: IEditor) =>
cacheIsWholeTableSelected(event, editor) &&
editor.isFeatureEnabled(ExperimentalFeatures.DeleteTableWithBackspace),
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we check editor.isFeatureEnabled(ExperimentalFeatures.DeleteTableWithBackspace), first? Since it could take less time that trying to create a VTable and check if it is selected

@juliaroldi juliaroldi merged commit 1884e38 into master Feb 17, 2023
@JiuqingSong JiuqingSong deleted the u/juliaroldi/delete-table branch September 8, 2023 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants