fix: prevent backspace from accidentally triggering delete modals (#25858)

* fix: prevent backspace from accidentally triggering delete modals

* ignore input fields instead of removing shortcut
This commit is contained in:
Michel Heusschen
2026-02-03 17:42:46 +01:00
committed by GitHub
parent 3870ebc3c6
commit af1ecaf5cc
2 changed files with 2 additions and 0 deletions

View File

@@ -67,6 +67,7 @@ export const getLibraryActions = ($t: MessageFormatter, library: LibraryResponse
color: 'danger',
onAction: () => handleDeleteLibrary(library),
shortcuts: { key: 'Backspace' },
shortcutOptions: { ignoreInputFields: true },
};
const AddFolder: ActionItem = {

View File

@@ -67,6 +67,7 @@ export const getUserAdminActions = ($t: MessageFormatter, user: UserAdminRespons
$if: () => get(authUser).id !== user.id && !user.deletedAt,
onAction: () => modalManager.show(UserDeleteConfirmModal, { user }),
shortcuts: { key: 'Backspace' },
shortcutOptions: { ignoreInputFields: true },
};
const getDeleteDate = (deletedAt: string): Date =>