Skip to main content

max / goingson

Take the print tracks from the column description too The print block restated the task table's seven tracks by hand, positionally and with !important. That is the third pass over one column set, and the one that would have gone stale silently: the screen passes come out of build.rs now, so a column inserted there would have left print laying the new column out as whichever old one sat in its place. It keeps every column, unlike the narrow pass. Paper has no scrollbar and no kebab to reach for, so a column that is optional on screen is exactly what a printed table is for. One real change, from `1fr` to `minmax(0, 1fr)` on the description track: the generated form lets it shrink past its content, where the hand-written one would not, which is what kept the fixed columns off the page when a description was long.
Co-Authored-By
Claude Opus 5 (1M context) <noreply@anthropic.com>
Author: Max Johnson <me@maxj.phd> · 2026-07-30 15:55 UTC
Signed with PGP, not checked
Commit: df44f844be4a18e85f1a62fe35df8396ea340175
Parent: 6fa37da
2 files changed, +34 insertions, -4 deletions
@@ -196,6 +196,21 @@
196 196 fallback: "",
197 197 };
198 198
199 + // Paper is narrower than a window and nothing is hidden on it, so every
200 + // column has to fit: the third set of lengths for the same seven columns.
201 + let task_print = Sizing {
202 + lengths: &[
203 + ("description", "0"),
204 + ("project", "100px"),
205 + ("priority", "40px"),
206 + ("due", "80px"),
207 + ("recurrence", "60px"),
208 + ("progress", "80px"),
209 + ("actions", "60px"),
210 + ],
211 + fallback: "",
212 + };
213 +
199 214 let mut css = String::from(
200 215 "/* Generated by makeover-webview from the column descriptions in\n \
201 216 build.rs. Do not edit. Columns narrow by priority, never by position:\n \
@@ -251,6 +266,23 @@
251 266 &opts,
252 267 ));
253 268 }
269 +
270 + // The print pass keeps every column -- a printed table is read without a
271 + // scrollbar, so a column that is merely optional on screen is the one thing
272 + // paper is good at carrying -- and only restates the lengths. It had been a
273 + // seven-track list written by hand inside @media print, which is the same
274 + // fact the description already holds and the same shape that put the mobile
275 + // rule one track out.
276 + css.push_str("\n@media print {\n");
277 + css.push_str(&narrowing_css(
278 + TASK_COLUMNS,
279 + ".task-header-row, .task-row",
280 + &task_print,
281 + Priority::Optional,
282 + &opts,
283 + ));
284 + css.push_str("}\n");
285 +
254 286 css
255 287 }
256 288
@@ -5579,10 +5579,8 @@
5579 5579 overflow: visible !important;
5580 5580 }
5581 5581
5582 - .task-header-row,
5583 - .task-row {
5584 - grid-template-columns: 1fr 100px 40px 80px 60px 80px 60px !important;
5585 - }
5582 + /* Print tracks come from css/tables.css too, out of the same column
5583 + description as the screen ones. */
5586 5584
5587 5585 .task-header-row .task-cell,
5588 5586 .task-row .task-cell {