commit 82e2737cb7ccb05840755961b5e181a828ce9832
parent c3bc4f0ba29a1dde36a305240abf813c73e64937
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date: Sun, 1 Nov 2026 15:17:03 -0500
umtool finale: a subsection's flag on the large rail is `sub` too -- a thinner stick, a smaller head, its words at 0.72 -- carried from the footer's deckMarkers; a cut without one draws exactly as before
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Diffstat:
4 files changed, 22 insertions(+), 4 deletions(-)
diff --git a/umtool/report-to-video/README.md b/umtool/report-to-video/README.md
@@ -567,7 +567,8 @@ timeline itself:
subsection sits inside the section before it: on the rail a shorter flag
(or a half-height tick), its label at 14 px (`MARKER_SUB_LABEL_SIZE`) and
quieter, and in sections no colour of its own — its pips, fuse bar and ring
- keep its parent's (a flag with no `color` wears the parent's too). The
+ keep its parent's (a flag with no `color` wears the parent's too); the
+ finale's large rail draws its flag thinner and its words quieter. The
section title says "Section › Sub" inside it. To every edit (umtool's
section ops, Play's strip, the Cut tab) it is a section like any other: a
boundary that is dragged, never left empty, never crossed. The cut's first
diff --git a/umtool/report-to-video/chrome-finale.mjs b/umtool/report-to-video/chrome-finale.mjs
@@ -410,7 +410,7 @@ export function finaleHtml(schedule, render, window, opts = {}) {
? `<div class="ml" data-k="ml${j}" style="top:${top - Y}px; ${mk.side === "right" ? "left:18px" : "right:18px"}; max-width:${mk.max}px">${esc(mk.label)}</div>`
: "";
return (
- `<div class="mf" data-k="mk${j}" style="left:${r2(mk.x)}px; top:${Y}px; --mc:${esc(mk.color)}">` +
+ `<div class="mf${mk.level === 2 ? " sub" : ""}" data-k="mk${j}" style="left:${r2(mk.x)}px; top:${Y}px; --mc:${esc(mk.color)}">` +
`<div class="ms" style="top:${-stick}px; height:${stick}px"></div>` +
`<div class="mh${mk.side === "left" ? " left" : ""}" style="top:${-stick}px"></div>${label}</div>`
);
@@ -522,7 +522,11 @@ export function finaleHtml(schedule, render, window, opts = {}) {
.mh.left { left: -18px; clip-path: polygon(100% 0%, 0% 50%, 100% 100%); }
.ml { position: absolute; height: ${Math.round(rail.markerSize * 1.25)}px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
font-family: 'DeckSansBold', sans-serif; font-size: ${rail.markerSize}px; line-height: ${Math.round(rail.markerSize * 1.25)}px;
- letter-spacing: 0.04em; text-transform: uppercase; color: var(--mc); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6); margin-top: -${Math.round(rail.markerSize * 0.2)}px; }${fq ? fq.css : ""}
+ letter-spacing: 0.04em; text-transform: uppercase; color: var(--mc); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6); margin-top: -${Math.round(rail.markerSize * 0.2)}px; }${L.marks.some((mk) => mk.level === 2) ? `
+ /* A subsection's flag (\`level: 2\`): a thinner stick, a smaller head, its words quieter. */
+ .mf.sub .ms { left: -1.5px; width: 3px; }
+ .mf.sub .mh { width: 12px; height: 10px; }
+ .mf.sub .ml { opacity: 0.72; }` : ""}${fq ? fq.css : ""}
.tc { position: absolute; border-radius: 14px; background: ${rgba(pal.fg, 0.045)}; box-shadow: inset 0 0 0 2px var(--vr);
overflow: hidden; transform-origin: 0 0; }
.tbar { position: absolute; left: 0; top: 0; width: 100%; height: 8px; background: var(--vc); }
diff --git a/umtool/report-to-video/deck.mjs b/umtool/report-to-video/deck.mjs
@@ -1676,7 +1676,7 @@ function finaleRailAt(schedule, render, railBottom, textScale) {
const toBig = (x) => r2(x0 + ((x - lay.pipTrack.x0) * (rail.x1 - x0)) / (span || 1));
const footMarks = deckMarkers(schedule, render, fxs, pipped, lay);
const marks = railMarkerLayout(footMarks.map((mk) => ({ x: toBig(mk.x), label: mk.label, color: mk.color })), base, { layout: deck.markerLayout })
- .map((mk, j) => ({ ...mk, foot: { x: r2(footMarks[j].x) } }));
+ .map((mk, j) => ({ ...mk, foot: { x: r2(footMarks[j].x) }, ...(footMarks[j].level === 2 ? { level: 2 } : {}) }));
// The claim checks: in turn or all at once, packed in the rows over the markers'.
const fcl = claimsLayout(schedule, render, fxs, pipped, lay);
const slots = fcl ? finaleClaimSlots(fin, fcl.items.length, f.claims) : null;
diff --git a/umtool/report-to-video/finale-room.test.mjs b/umtool/report-to-video/finale-room.test.mjs
@@ -262,3 +262,16 @@ test("placeAbove: a label slides along its row, or rises with its stick kept in
assert.equal(aboveLine(), 30);
assert.ok(textWidth("x", 24) > 0);
});
+
+test("a subsection on the large rail: its flag `sub` (a thinner stick, quieter words); a cut without one draws none of it", () => {
+ const r = renderWith({ markers: [MARKERS[0], { ...MARKERS[1], level: 2 }] });
+ const s = built(r);
+ const L = finaleLayout(s, r);
+ assert.deepEqual(L.marks.map((mk) => mk.level ?? 1), [1, 2]);
+ const win = snapWindow({ segment: "finale", from: s.finale.from, to: s.finale.to }, { fps: 30, total: s.total });
+ const html = finaleHtml(s, r, win, {});
+ assert.equal((html.match(/class="mf sub"/g) ?? []).length, 1);
+ assert.match(html, /\.mf\.sub \.ml \{ opacity: 0\.72; \}/);
+ const plain = finaleHtml(built(renderWith()), renderWith(), win, {});
+ assert.doesNotMatch(plain, /\.mf\.sub|class="mf sub"/);
+});