Monorepo for Tangled tangled.org

appview/pages/pulls: prevent overscrolling when bottom sheet is open

in mobile view, when the bottom sheet is open, overscrolling the sheet
would cause the underlying page to start scrolling. this adds a bit of
js to the page to avoid this behavior.

Signed-off-by: oppiliappan <me@oppi.li>

oppi.li 8fab832a 6721acdb

verified
+2
+2
appview/pages/templates/repo/pulls/pull.html
··· 31 if (details.open && !isDesktop()) { 32 backdrop.classList.remove('opacity-0', 'pointer-events-none'); 33 backdrop.classList.add('opacity-100', 'pointer-events-auto'); 34 } else { 35 backdrop.classList.remove('opacity-100', 'pointer-events-auto'); 36 backdrop.classList.add('opacity-0', 'pointer-events-none'); 37 } 38 } 39 };
··· 31 if (details.open && !isDesktop()) { 32 backdrop.classList.remove('opacity-0', 'pointer-events-none'); 33 backdrop.classList.add('opacity-100', 'pointer-events-auto'); 34 + document.body.style.overflow = 'hidden'; 35 } else { 36 backdrop.classList.remove('opacity-100', 'pointer-events-auto'); 37 backdrop.classList.add('opacity-0', 'pointer-events-none'); 38 + document.body.style.overflow = ''; 39 } 40 } 41 };