From 99dbe80fdb8795076fb8a7a91feef021bae0fcbe Mon Sep 17 00:00:00 2001 From: "hehihoho3@gmail.com" Date: Thu, 25 Jun 2026 18:25:41 +0900 Subject: [PATCH] =?UTF-8?q?fix(rework):=20=EC=9E=90=EB=A7=89=20=ED=95=98?= =?UTF-8?q?=EC=9D=B4=EB=9D=BC=EC=9D=B4=ED=8A=B8=EA=B0=80=20=ED=8E=98?= =?UTF-8?q?=EC=9D=B4=EC=A7=80=20=EC=A0=84=EC=B2=B4=EB=A5=BC=20=EC=8A=A4?= =?UTF-8?q?=ED=81=AC=EB=A1=A4=ED=95=B4=20=EC=98=81=EC=83=81=EC=9D=B4=20?= =?UTF-8?q?=ED=9D=94=EB=93=A4=EB=A6=AC=EB=8D=98=20=EB=AC=B8=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 재생 중 활성 세그먼트로 이동할 때 scrollIntoView가 페이지를 스크롤해 sticky 영상이 위아래로 튀던 현상 수정. 세그먼트 박스(#segmentList) 내부에서만 스크롤하도록 변경. Co-Authored-By: Claude Opus 4.8 (1M context) --- src/main/resources/templates/rework.html | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/resources/templates/rework.html b/src/main/resources/templates/rework.html index 2a50042..92044b4 100644 --- a/src/main/resources/templates/rework.html +++ b/src/main/resources/templates/rework.html @@ -420,7 +420,15 @@ rows.forEach(r=>{ const on = Number(r.dataset.i)===activeIdx; r.classList.toggle('active', on); - if(on) r.scrollIntoView({block:'nearest'}); + if(on){ + // 페이지 전체가 아니라 세그먼트 박스 안에서만 스크롤(영상 sticky 흔들림 방지) + const box = document.getElementById('segmentList'); + if(box){ + const br = box.getBoundingClientRect(), rr = r.getBoundingClientRect(); + if(rr.top < br.top) box.scrollTop -= (br.top - rr.top); + else if(rr.bottom > br.bottom) box.scrollTop += (rr.bottom - br.bottom); + } + } }); }