Compare commits

...
Author SHA1 Message Date
Calum H. (IMB11) 03c6df44b2 fix: use next tick in delete confirm 2026-07-06 12:40:17 +01:00
@@ -18,7 +18,7 @@ import {
TextCursorInputIcon,
TrashIcon,
} from '@modrinth/assets'
import { computed, ref, watch } from 'vue'
import { computed, nextTick, ref, watch } from 'vue'
import ButtonStyled from '#ui/components/base/ButtonStyled.vue'
import EmptyState from '#ui/components/base/EmptyState.vue'
@@ -389,10 +389,11 @@ async function promptDeleteItems(items: ContentItem[], event?: MouseEvent) {
showDeletionConfirmation(event)
}
function showDeletionConfirmation(event?: MouseEvent) {
async function showDeletionConfirmation(event?: MouseEvent) {
if ((event?.shiftKey || skipNonEssentialWarnings.value) && !ctx.isBusy.value) {
confirmDelete()
} else {
await nextTick()
confirmDeletionModal.value?.show()
}
}