refactor(web): disable shortcut when writting (#4057)
* Revert "fix: disable shortcut when writting text (#4053)"
This reverts commit fd6ade2b5d.
* refactor: disable shortcut when writting
* pr feedback
* pr feedback
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
import { browser } from '$app/environment';
|
||||
import { assetViewingStore } from '$lib/stores/asset-viewing.store';
|
||||
import { preventRaceConditionSearchBar } from '$lib/stores/search.store';
|
||||
import { shouldIgnoreShortcut } from '$lib/utils/shortcut';
|
||||
|
||||
export let data: PageData;
|
||||
|
||||
@@ -51,6 +52,9 @@
|
||||
});
|
||||
|
||||
const handleKeyboardPress = (event: KeyboardEvent) => {
|
||||
if (shouldIgnoreShortcut(event)) {
|
||||
return;
|
||||
}
|
||||
if (!$showAssetViewer) {
|
||||
switch (event.key) {
|
||||
case 'Escape':
|
||||
|
||||
Reference in New Issue
Block a user