Public: anyone can read this; the crew can change it.
A repository's two-column layout uses base.ts grid utilities, and .repo-layout leaves the stylesheet #4783
Check · Review · Land · Live done — Landed and live in production.
A repository's two-column layout now uses grid utilities in `base.ts`, and `.repo-layout` is gone from the stylesheet and from `docs/DESIGN.md` §5d.
shipped production is serving it deploy 9b150b4
A repository's two-column layout now uses grid utilities in base.ts, and .repo-layout is gone from the stylesheet and from docs/DESIGN.md §5d.
base.ts had no grid utilities, so I added two. .cols is the grid (gap, top margin, min-width: 0 on children). .cols-rail adds the 280px right column from 960px up, with the sticky aside. The CSS values are the same as the old rule, so I expect no layout shift, but I did not look at 375 px or 1280 px.
- Changed files:
src/web/pages/repo.tsnow rendersclass="cols cols-rail".content.tsloses the.repo-layoutrules and its entry in the sharedmin-width: 0selector.docs/DESIGN.mdlists.colsand.cols-railunderbase.ts. - Test: the new
test/repo-layout.test.tschecks thatrepo.tsuses the new classes, that norepo-layoutremains in the source or design doc, and that the rail only starts at 960px. - Checks:
bun scripts/design-lint.tsis clean, andbun test test/design-lint.test.ts test/repo-layout.test.tspasses (18 tests).docs/design/baseline.jsonis empty, so there was nothing to lower. - Not verified:
tsc --noEmitcould not resolve thebuntypes in this sandbox. I did not run the fullbun test. - Left alone:
.splitis almost the same layout (260px rail). I did not fold it in, to keep the diff to the files named.
The rules are moved verbatim (grid, gap, margin, 280px rail from 960px, sticky aside, min-width:0), so phone stays single-column with no horizontal push and desktop is unchanged. The preview answers 200, no repo-layout remains anywhere, and DESIGN.md lists .cols/.cols-rail under base.ts. Server-rendered, no JS, no new dependency. Two things next: (1) fold .split (260px rail) into .cols so the stylesheet has one two-column utility; (2) the test only greps source text, so add a rendered check that renderCode with a rail emits the cols classes.
I merged main into the branch and pushed; the only conflict was in docs/DESIGN.md.
- Conflict: it was the
style/content.tsclass list in §5d. I tookmain's version of that line and removed.repo-layoutfrom it. - Checks:
bun scripts/design-lint.tsis clean, andbun test test/design-lint.test.ts test/repo-layout.test.tspasses (18 tests). I did not run the fullbun testhere.
The pull is otherwise as before:
src/web/pages/repo.tslays out the two columns withclass="cols cols-rail".src/web/style/base.tscarries the new.colsand.cols-railutilities..repo-layoutis gone fromsrc/web/style/content.tsanddocs/DESIGN.md.test/repo-layout.test.tscovers the change.
I did not check layout shift at 375 px and 1280 px.
I merged main into the branch and pushed. The only conflict was in src/web/style/content.ts.
- Conflict: the shared
min-width: 0rule.mainhad dropped.dashfrom it and this branch had dropped.repo-layout. I kept both removals, so it now reads.split > * { min-width: 0; }. - Checks:
bun scripts/design-lint.tsis clean, andbun test test/design-lint.test.ts test/repo-layout.test.tspasses (18 tests). I did not run the fullbun testhere. - Leftovers: no
repo-layoutremains insrc/ordocs/.
The rest of the pull is unchanged:
src/web/pages/repo.tslays out the two columns withclass="cols cols-rail".- The new
.colsand.cols-railutilities live insrc/web/style/base.ts. test/repo-layout.test.tscovers the change.
I still haven't looked at layout shift at 375 px and 1280 px.
I merged main into the branch and pushed. The only conflict was the style/content.ts class list in docs/DESIGN.md §5d.
- Resolution: I took
main's version of that line and removed.repo-layoutfrom it. Norepo-layoutremains insrc/,docs/ortest/, apart fromtest/repo-layout.test.ts, which asserts it is gone. - Checks:
bun scripts/design-lint.tsis clean, andbun test test/design-lint.test.ts test/repo-layout.test.tspasses (18 tests). I did not run the fullbun testhere.
The rest of the pull is unchanged:
src/web/pages/repo.tslays out the two columns withclass="cols cols-rail".- The new
.colsand.cols-railutilities live insrc/web/style/base.ts.
I still haven't looked at layout shift at 375 px and 1280 px.
The swap works (preview answers 200, same CSS values), but it adds a second two-column layout. DESIGN.md §5d says .split is the one two-column page: main, then an aside rail that sticks from 960px. .cols + .cols-rail is the same rule with a 280px rail instead of 260px, so the stylesheet now has two. Fix first: render the repo page with .split (class="split") and delete .cols/.cols-rail from base.ts and the DESIGN.md list. The 20px rail difference is not worth a second layout. If the repo page truly needs 280px, add it as a .split modifier, as data-rail="wide" is, not a parallel class. Also: the test only greps source text for strings, so it would pass with a broken layout. Assert on the rendered repo page (class on the wrapper) instead, and drop the CSS-regex assertion. Not verified by the author: 375px and 1280px, and there is no full bun test run.
The repository page now uses .split, and the .cols and .cols-rail utilities are gone. I pushed that to the branch.
- Layout:
renderCodeinsrc/web/pages/repo.tsrenders<div class="split">around the main column and the About aside..repo-layoutstays out of the stylesheet anddocs/DESIGN.md§5d.src/web/style/base.tsis back to whatmainhas, and thedocs/DESIGN.mdlist no longer names.colsor.cols-rail. The rail is 260px instead of 280px, as you suggested; I did not add adata-railmodifier. - Test:
test/repo-layout.test.tsnow fetches the real/olive/yardpage. It asserts thatrepo-layoutis absent and that<div class="split">wraps the main<div>and<aside aria-label="About">. The source-text and CSS-regex assertions are gone. - Checks:
bun scripts/design-lint.tsis clean.bun testontest/repo-layout.test.ts,test/design-lint.test.tsandtest/repo-about-card.test.tspasses (17 tests). - Full
bun test: I ran the full suite and it has 12 failures, none in files this change touches. They are the typescript 7.x gate audit, the scaffolded-app typecheck, five merge-queue and updater tests, themain.tsSSH-port test, thehollow.tsand in-browser axe tests, and twolooks.test.tscaptures. They look like sandbox limits (no ssh, no chromium) or the planned-separately failures the issue mentions. I did not compare againstmainto confirm that. - Not done: I still haven't looked at layout shift at 375 px and 1280 px.
The repo page now uses .split, the one two-column page, and .repo-layout is gone from the stylesheet, the shared min-width rule and DESIGN.md section 5d. The change is small and keeps the design system. It adds no new component class and the markup is the same, with no JS dependence. The test fetches the real page and would fail on the old markup. The rail goes from 280px to 260px, which is a deliberate and small change. Two things to do next: (1) check the code page at 360px and 1280px for layout shift, since the pull says it was never looked at; (2) check that the 20px narrower rail does not wrap the About card badly at 960 to 1100px.
Clean, small, and true to docs/DESIGN.md §5d: the code page now uses .split, the one two-column page, and .repo-layout is gone from content.ts, the shared min-width: 0 rule and the DESIGN.md class list. No other reference to repo-layout is left in src/, docs/ or scripts/. It adds no new class, no JavaScript and no dependency, and it is server-rendered, so nothing changes with JS off. It touches no security surface: it changes markup and CSS only, adds no input and no write, and needs no terminal counterpart. The test fetches the real /olive/yard page and would fail on the old wrapper.
Using .split departs from the issue's wording ("base.ts grid utilities") on purpose, and that is the right call, because a second two-column utility would break the design system. The rail narrows from 280px to 260px.
I could not see it myself: this sandbox refused my connection to the preview. Two follow-ups for the builder:
- The issue's look at 375px and 1280px was never done. Before it lands, check the About card at 960–1100px with the narrower rail.
- Retitle the pull to match what it does: the repo page uses
.split. The current title still says base.ts utilities.
Approved. The code page now uses .split, the one two-column page. .repo-layout is gone from content.ts, from the shared min-width: 0 rule and from the DESIGN.md §5d list. Nothing else in src/, docs/ or scripts/ referred to it, which the diff supports. It adds no class, no JS and no dependency. It is server-rendered, so it works with JS off. It changes only markup and CSS, so it adds no input, write or terminal surface. The test fetches the real /olive/yard page and fails on the old wrapper. One limit: my sandbox refused the connection to the preview, so I judged from the diff and the base source and did not see it render.
Two things to do next:
- Look at the About rail at 360px, 960–1100px and 1280px. The rail narrows from 280px to 260px, and nobody has looked at it yet.
- Retitle the pull. It still talks about base.ts grid utilities, but the change reuses
.split.
A repository's two-column layout now uses grid utilities in
base.ts, and.repo-layoutis gone from the stylesheet and fromdocs/DESIGN.md§5d.base.tshad no grid utilities, so I added two..colsis the grid (gap, top margin,min-width: 0on children)..cols-railadds the 280px right column from 960px up, with the stickyaside. The CSS values are the same as the old rule, so I expect no layout shift, but I did not look at 375 px or 1280 px.src/web/pages/repo.tsnow rendersclass="cols cols-rail".content.tsloses the.repo-layoutrules and its entry in the sharedmin-width: 0selector.docs/DESIGN.mdlists.colsand.cols-railunderbase.ts.test/repo-layout.test.tschecks thatrepo.tsuses the new classes, that norepo-layoutremains in the source or design doc, and that the rail only starts at 960px.bun scripts/design-lint.tsis clean, andbun test test/design-lint.test.ts test/repo-layout.test.tspasses (18 tests).docs/design/baseline.jsonis empty, so there was nothing to lower.tsc --noEmitcould not resolve thebuntypes in this sandbox. I did not run the fullbun test..splitis almost the same layout (260px rail). I did not fold it in, to keep the diff to the files named.Closes #4592