Fix broken scrolling on non-map pages

Remove overly aggressive CSS overrides that set height: auto and
overflow: auto on html/body. These forced the html element to expand
to full content height, preventing the browser's native viewport
scrolling. The browser handles non-map page scrolling correctly by
default — only map pages need explicit overflow: hidden.
This commit is contained in:
Graham McIntire 2026-02-19 15:08:16 -06:00
parent bb6c24856d
commit 15e6fda5ac
No known key found for this signature in database

View file

@ -1,29 +1,6 @@
<% assigns = assign_new(assigns, :map_page, fn -> false end) %>
<style>
/* Default scrolling behavior for all pages */
html, body {
overflow: auto !important;
height: auto !important;
min-height: 100vh !important;
}
/* Reset constraints for non-map pages */
body:not(:has(#main-content[data-map-page="true"])) main,
body:not(:has(#main-content[data-map-page="true"])) .phx-main,
body:not(:has(#main-content[data-map-page="true"])) div[data-phx-main="true"] {
overflow: visible !important;
height: auto !important;
max-height: none !important;
min-height: 100vh !important;
}
/* Ensure proper scrolling for non-map pages */
body:not(:has(#main-content[data-map-page="true"])) {
overflow-y: auto !important;
height: auto !important;
}
/* Only apply map constraints to map pages */
/* Map page constraints */
body:has(#main-content[data-map-page="true"]) {
overflow: hidden !important;
height: 100vh !important;