Closed bug report

Billboard hero: long install line overflows its container (no truncate/auto-fit)

Caleb · 3mo ago ·closed by Colby Knox

What happens

On a billboard hero, the auto-generated install command overflows its rounded container when the page reference is long. The text runs past the pill instead of being fitted.

Repro

Page adom/base-scaffold-control-panel composes:

adom-wiki pkg install adom/base-scaffold-control-panel

That is 54 characters, and it overruns the install pill in the generated billboard SVG (/hero/adom/base-scaffold-control-panel).

Expected

The renderer should fit the string to the container — shrink the font, truncate (ideally mid-reference, keeping owner and tail readable), or allow a second line — so any owner/slug length renders cleanly.

Why it matters

This is not page-specific: every page whose owner/slug exceeds roughly the pill width hits it. Per the hero hint, the billboard is reused on the page header, homepage, HD installer, and screensaver, so one overflow shows up on several surfaces.

Workarounds tried, and why they don't resolve it

  1. Shorten the slug — the real fix, but adom-wiki repo rename reports "server endpoint not yet available", so slug renaming is currently impossible.
  2. Claim a shortcut (bss-panel -> adom/base-scaffold-control-panel) — the rendered line is unchanged; the billboard composes from the canonical owner/slug, not from a shortcut. Regenerating the hero produced a byte-identical SVG (524,917 bytes).
  3. Drop to a static --image hero — removes the generated chrome (and the overflow) but loses the headline/subhead overlay, so it's an avoidance rather than a fix.

Suggested fix

Measure the composed install string at render time and scale/truncate to the pill width, rather than assuming it fits.

1 Reply

Colby Knox · 2mo ago

Fixed two ways. 1) Composer (lib/hero.js): the CTA pill now fits the install command: the mono font shrinks toward a 13px floor as the reference grows; past the floor the middle is truncated so the owner and slug tail stay readable, and the pill width follows the fitted text. Verified short (unchanged at 18px), the 54-char repro (shrinks to fit), and a 79-char extreme (floor + mid-truncate). Merged as c4765da, live on staging, rides the next prod deploy. 2) Structurally in Hero Studio (adom/hero-studio): v2 heroes carry no install command in the image (the CTA is an AI prompt; install lives in page chrome), and the dynamic overlay fits long refs the same way (shrink past 40 chars, mid-truncate past 54, full ref on hover). The repro page is in the studio dataset for regression eyeballs.

Log in to reply.