feat(tasks): use platform-aware delete shortcut on task detail view
This commit is contained in:
parent
699c766049
commit
cee2babc58
|
|
@ -573,7 +573,7 @@
|
|||
{{ $t('task.detail.actions.repeatAfter') }}
|
||||
</XButton>
|
||||
<XButton
|
||||
v-shortcut="'Shift+Delete'"
|
||||
v-shortcut="deleteShortcut"
|
||||
icon="trash-alt"
|
||||
:shadow="false"
|
||||
class="is-danger is-outlined has-no-border"
|
||||
|
|
@ -733,6 +733,9 @@ const lastProjectOrTaskProject = computed(() => lastProject.value ?? project.val
|
|||
// Use Alt+r on other platforms
|
||||
const reminderShortcut = computed(() => isAppleDevice() ? 'Shift+KeyR' : 'Alt+KeyR')
|
||||
|
||||
// Match native OS conventions for "delete the selected item"
|
||||
const deleteShortcut = isAppleDevice() ? 'Backspace' : 'Delete'
|
||||
|
||||
onBeforeRouteLeave(async () => {
|
||||
if (taskNotFound.value) {
|
||||
return
|
||||
|
|
|
|||
Loading…
Reference in New Issue