From 1491e975c20e81afdd2407fee9c8dcd2597cc815 Mon Sep 17 00:00:00 2001 From: jordi fita mas Date: Sat, 3 Feb 2024 01:32:07 +0100 Subject: [PATCH] Better control of scroll snap for calendar months on mobile It is not a problem in desktop, because there is no scroll bar, but in mobile you can scroll with touch, and i need the months to snap to the start for the next and previous buttons to work. --- web/static/public.css | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web/static/public.css b/web/static/public.css index 006efc9..6115b6b 100644 --- a/web/static/public.css +++ b/web/static/public.css @@ -1125,12 +1125,14 @@ body > footer > div, .campsite_type_features, .campsite_type_detail { scrollbar-width: none; -webkit-overflow-scrolling: touch; -ms-overflow-style: -ms-autohiding-scrollbar; + scroll-snap-type: x proximity; } .campsite_type_calendar table { border-collapse: collapse; flex: 0 0 27rem; height: 100%; + scroll-snap-align: center start; } .campsite_type_calendar td {