Public: anyone can read this; the crew can change it.

Design: the family and chain pages' lineage uses §5's row, and lineage/lineage-children/lineage-here leave §5d #4024

Parked opened this
Closed without merging

The lineage lists on /family, the chain page and the following panel (the fork tree) are now §5 rows, and .lineage, .lineage-children and .lineage-here are gone. I couldn't run tsc or take screenshots here, so the type check and the before/after images are missing.

Notes

stopped parked by the crew deploy 039377f

opened this

The lineage lists on /family, the chain page and the following panel (the fork tree) are now §5 rows, and .lineage, .lineage-children and .lineage-here are gone. I couldn't run tsc or take screenshots here, so the type check and the before/after images are missing.

What changed

  • All three pages draw each entry with row() from src/web/ui.ts. "You are here" is now a badge, in the row's trail next to the fork's standing badge.
  • row() gained an optional children option, which puts a nested <ul class="list"> inside the row's <li>. Screen readers still hear the nesting.
  • src/web/style/components.ts gained two generic rules: a list inside a list gets a rule and an indent (12px at 390 px wide), and the current row gets a muted background. This replaces the old nesting and highlight rules.
  • The three class names and their rules are removed from src/web/style/content.ts. They are also gone from the style/content.ts bullet in docs/DESIGN.md §5d.
  • No other file used these names, so nothing had to stay.
  • test/following.test.ts: the "you are here" test now looks for aria-current="true" on the row, because row() puts it on the <li>, not the link. It also checks that the old class names are absent from the page HTML. That is the one test I changed, and the old marker was what was wrong.
  • bun test passes for the following, family, chain and spawn-chain suites and the design tests. bun scripts/design-lint.ts passes, and --update left baseline.json unchanged. I did not run the whole suite.

Not done

  • No screenshots: the sandbox can't screenshot, so the pull has no before/after images in light and dark at desktop and 390 px. Please check the previews.
  • No type check: bun install and tsc can't write to the temp directory here, so I couldn't run tsc --noEmit. The forge's check will.
  • External links: the parent and child links on /family no longer carry rel="noopener noreferrer", because row() doesn't emit it. The Referrer-Policy header still applies, and browsers treat noopener as the default.

To try it: open /family, a fork's /<owner>/<repo>/following, and a repository's /<owner>/<repo>/chain page.

🤖 Generated with Claude Code

Closes #3868

3 earlier comments
commented

The lineage lists on /family, the chain page and the following panel (the fork tree) are now §5 rows, and .lineage, .lineage-children and .lineage-here are gone. I couldn't run tsc or take screenshots here, so the type check and the before/after images are missing.

What changed

  • All three pages draw each entry with row() from src/web/ui.ts. "You are here" is now a badge, in the row's trail next to the fork's standing badge.
  • row() gained an optional children option, which puts a nested <ul class="list"> inside the row's <li>. Screen readers still hear the nesting.
  • src/web/style/components.ts gained two generic rules: a list inside a list gets a rule and an indent (12px at 390 px wide), and the current row gets a muted background. This replaces the old nesting and highlight rules.
  • The three class names and their rules are removed from src/web/style/content.ts. They are also gone from the style/content.ts bullet in docs/DESIGN.md §5d.
  • No other file used these names, so nothing had to stay.
  • test/following.test.ts: the "you are here" test now looks for aria-current="true" on the row, because row() puts it on the <li>, not the link. It also checks that the old class names are absent from the page HTML. That is the one test I changed, and the old marker was what was wrong.
  • bun test passes for the following, family, chain and spawn-chain suites and the design tests. bun scripts/design-lint.ts passes, and --update left baseline.json unchanged. I did not run the whole suite.

Not done

  • No screenshots: the sandbox can't screenshot, so the pull has no before/after images in light and dark at desktop and 390 px. Please check the previews.
  • No type check: bun install and tsc can't write to the temp directory here, so I couldn't run tsc --noEmit. The forge's check will.
  • External links: the parent and child links on /family no longer carry rel="noopener noreferrer", because row() doesn't emit it. The Referrer-Policy header still applies, and browsers treat noopener as the default.

To try it: open /family, a fork's /<owner>/<repo>/following, and a repository's /<owner>/<repo>/chain page.

🤖 Generated with Claude Code

commented

The check failed on type errors in the family, chain and following pages, and I've fixed them and pushed. I didn't run the forge's full check, so that verdict is still to come.

What changed: the family, chain and following pages pass optional values (href, meta, trail, children) that can be undefined into row(). exactOptionalPropertyTypes rejects that, because RowOptions in src/web/ui.ts didn't allow an explicit undefined. I widened those four fields to T | undefined. I left the pages unchanged and added no behaviour.

Verified: tsc --noEmit is clean, and the following, family-timing, chain-timing and following-card tests pass (30 tests).

Left out: I didn't run the whole suite, since the forge runs it on push.

commented

This pull replaces the lineage-specific CSS classes with ordinary list rows on the family, chain and following pages. I pushed fixes for two failed checks, but I haven't seen a new verdict from the forge yet.

What changed:

  • The family, chain and following pages now draw their lineage from shared row() rows. The lineage classes in src/web/style/content.ts are removed.
  • row() in src/web/ui.ts gains an optional children field, which nests a list under a row. href, meta, trail and children now accept an explicit undefined, because the pages pass optional values and exactOptionalPropertyTypes rejected them. That was the first check failure.
  • The second failure was the milestones golden test. My first fix for the type errors added whitespace after every row, which changed the pinned HTML. children now appends inline, so the milestones output is byte-identical to before. I didn't change the golden file.

Tested: the type check is clean. The milestones golden, following, web-ui, family-timing and chain-timing tests pass (53 tests). I didn't run the whole suite, because the forge runs it on push.

Left out: no new behaviour beyond the lineage redraw.

Try it: open a family, chain or following page on the preview at https://lab--4024--forge-trevato-apps.open-platform.sh.

commented

Parked by the crew: the check stayed red through 2 automatic tries

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs