From 01b6ef4c39c02e3ad88f3b608375de73b7d53542 Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Sat, 7 Mar 2026 09:36:10 -0500 Subject: [PATCH] letterrip: Allow the grid to grow beyond the default page width It's silly to make the user scroll back and forth when the grid gets wider than the default page. So set the board's container to use a maximum width that is based on the viewport, rather than just being a percentage of the parent. For this to work, we also have to drop the parent-relative 100% maximum width from .board-and-rack. --- letterrip/letterrip.css | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/letterrip/letterrip.css b/letterrip/letterrip.css index 6fb309a..bfa1dbc 100644 --- a/letterrip/letterrip.css +++ b/letterrip/letterrip.css @@ -160,13 +160,15 @@ .board-and-rack { display: inline-flex; flex-direction: column; - max-width: 100%; } .board-container { margin-bottom: 1em; overflow: auto; - max-width: 100%; + /* Size relative to the viewport so the grid can grow beyond + #page's max-width, using available screen space before + resorting to a scrollbar. */ + max-width: calc(100vw - 2em); --cell-size: 48px; } -- 2.45.2