Stop iOS nested scroll snap-back on Studio and Queue.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Towsty
2026-08-28 18:49:58 -05:00
co-authored by Cursor
parent 88360ec3f6
commit 6b6e5cd277
4 changed files with 14 additions and 6 deletions
+4 -4
View File
@@ -1,5 +1,5 @@
<template>
<div class="min-h-screen min-w-0 overflow-x-hidden">
<div class="min-h-dvh min-w-0">
<header class="sticky top-0 z-20 border-b border-white/5 bg-zinc-950/70 backdrop-blur-xl">
<div class="mx-auto flex max-w-7xl items-center justify-between px-4 py-4 sm:px-6">
<div class="flex items-center gap-3">
@@ -2816,7 +2816,7 @@ onMounted(async () => {
if (savedPreset) recommendPresetId.value = savedPreset
} catch { /* ignore */ }
applyInstancePrivacy()
window.addEventListener('pointerdown', onSitePointerDown, true)
window.addEventListener('click', onSitePointerDown, true)
const [health, me] = await Promise.all([
$fetch<{ comfy?: { ok?: boolean; busy?: boolean } }>('/api/health').catch(() => ({ comfy: { ok: false, busy: false } })),
$fetch<{ user?: { name?: string; email?: string }; authEnabled?: boolean; authMode?: string; instanceName?: string }>('/api/auth/me').catch(() => ({ user: null })),
@@ -2845,7 +2845,7 @@ onMounted(async () => {
})
onBeforeUnmount(() => {
window.removeEventListener('pointerdown', onSitePointerDown, true)
window.removeEventListener('click', onSitePointerDown, true)
window.removeEventListener('keydown', onEditLightboxKey)
if (healthTimer) clearInterval(healthTimer)
healthTimer = null
@@ -3951,7 +3951,7 @@ function onEditLightboxKey(event: KeyboardEvent) {
if (event.key === 'Escape') closeEditLightbox()
}
function onSitePointerDown(event: PointerEvent) {
function onSitePointerDown(event: Event) {
const target = event.target as Node | null
if (editLightbox.value && target && editLightbox.value.contains(target)) return
if (editLightboxUrl.value) closeEditLightbox()