File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 126126</template >
127127
128128<script setup>
129- import { ref , onMounted , computed } from ' vue'
129+ import { ref , onMounted , onBeforeUnmount , computed } from ' vue'
130130import { useSpamProtection } from ' ../composables/useSpamProtection'
131131import { useRoomApi } from ' ../composables/useRoomApi'
132132
@@ -183,6 +183,9 @@ const backgroundStyle = computed(() => {
183183})
184184
185185onMounted (async () => {
186+ // Add classes to prevent zoom and scrolling on mobile
187+ document .body .classList .add (' h-svh' , ' overflow-hidden' , ' touch-manipulation' )
188+
186189 // Fetch room data
187190 try {
188191 roomData .value = await fetchRoom (props .roomId )
@@ -194,6 +197,10 @@ onMounted(async () => {
194197 }
195198})
196199
200+ onBeforeUnmount (() => {
201+ document .body .classList .remove (' h-svh' , ' overflow-hidden' , ' touch-manipulation' )
202+ })
203+
197204async function submitReaction (emoji ) {
198205 // Only check cooldown, allow multiple API calls in progress
199206 if (! canSubmit .value ) {
You can’t perform that action at this time.
0 commit comments