fix: Properly scroll on mobile devices

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2024-08-31 11:42:57 +02:00
parent d9d75fdfe4
commit c1ed33848c

View File

@@ -4,7 +4,7 @@
--> -->
<template> <template>
<div class="board-wrapper" :tabindex="-1"> <div class="board-wrapper" :tabindex="-1" @touchend="fixActionRestriction">
<Controls :board="board" /> <Controls :board="board" />
<transition name="fade" mode="out-in"> <transition name="fade" mode="out-in">
@@ -217,6 +217,13 @@ export default {
window.removeEventListener('mouseup', this.stopMouseDrag) window.removeEventListener('mouseup', this.stopMouseDrag)
window.removeEventListener('mouseleave', this.stopMouseDrag) window.removeEventListener('mouseleave', this.stopMouseDrag)
}, },
fixActionRestriction() {
document.body.classList.remove(
'smooth-dnd-no-user-select',
'smooth-dnd-disable-touch-action',
)
},
}, },
} }
</script> </script>