From 2f15368918c829983dba4ec8acc54eb27d5e8e97 Mon Sep 17 00:00:00 2001 From: casjay Date: Sun, 22 Nov 2026 12:52:26 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Keep=20cookie=20consent=20banner?= =?UTF-8?q?=20full=20width=20on=20mobile=20=F0=9F=90=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit cookieconsent 3.0.3 forces the floating layout on mobile user agents, which is capped at 24em wide above 414px. Make both the banner and floating layouts full width at the bottom so the banner is consistent at every viewport. - rootfs/tmp/usr/local/share/caddy/htdocs/www/css/cookieconsent.css: add full-width consent banner rules - rootfs/tmp/usr/local/share/caddy/htdocs/www/index.php: add inline full-width override for the consent banner - README.md: N/A — no user-facing change --- .../caddy/htdocs/www/css/cookieconsent.css | 27 +++++++++++++++++++ .../local/share/caddy/htdocs/www/index.php | 27 +++++++++++++++++++ 2 files changed, 54 insertions(+) diff --git a/rootfs/tmp/usr/local/share/caddy/htdocs/www/css/cookieconsent.css b/rootfs/tmp/usr/local/share/caddy/htdocs/www/css/cookieconsent.css index 51666cf..60ecdfc 100644 --- a/rootfs/tmp/usr/local/share/caddy/htdocs/www/css/cookieconsent.css +++ b/rootfs/tmp/usr/local/share/caddy/htdocs/www/css/cookieconsent.css @@ -273,3 +273,30 @@ .cc-floating.cc-theme-edgeless .cc-btn + .cc-btn { margin-left: 0; } + +/* Keep the consent banner full width on mobile user agents, where the library forces the floating layout */ +.cc-window.cc-banner, +.cc-window.cc-floating { + width: 100%; + max-width: 100%; + left: 0; + right: 0; + box-sizing: border-box; +} +@media screen and (min-width: 415px) { + .cc-window.cc-floating { + bottom: 0; + flex-direction: row; + align-items: center; + } + .cc-window.cc-floating:not(.cc-theme-edgeless) { + padding: 1em 1.8em; + } + .cc-window.cc-floating .cc-message { + flex: 1; + margin-bottom: 0; + } + .cc-window.cc-floating .cc-compliance { + flex: 0 0 auto; + } +} diff --git a/rootfs/tmp/usr/local/share/caddy/htdocs/www/index.php b/rootfs/tmp/usr/local/share/caddy/htdocs/www/index.php index d00a563..7c3227e 100644 --- a/rootfs/tmp/usr/local/share/caddy/htdocs/www/index.php +++ b/rootfs/tmp/usr/local/share/caddy/htdocs/www/index.php @@ -43,6 +43,33 @@ +