Skip to content

ADR: The phone header

ADR: The phone header

Status: accepted, 2026-09-02, shipped through the new pipeline as its first real passenger.

In plain words

On a phone the header's dropdown menus did not fit, so below 640 pixels they give way to one button that opens a full-height list of every menu. Both views draw from the same menu data, so they cannot drift apart.

What that is worth: a developer changes a menu in one place and a phone-sized test proves it still works, and the organization's site reads as well on a phone as on a laptop.

Context

The header grew four dropdown menus and an Admin tab in two days, and on a phone they did not fit. The site is on the resume, so a visitor's first look is as likely to be a phone as a laptop. His words on the problem: the UI is not mobile friendly with all the dropdowns and must be fixed.

Decision

Below 640 pixels the four dropdowns and the Admin button hide, and one hamburger button opens a full-height sheet that lists every menu as a headed section, then Admin, the resume, and the repository. Above 640 pixels nothing changes. The four choices inside that:

  • One data source. The dropdowns already rendered from a MENUS record. Instead of a second copy for the phone, that record and the links beside it are exported and the sheet renders from them. The two surfaces cannot drift apart, because there is nothing to drift.
  • A native dialog for the sheet. The browser's <dialog> element gives Escape, backdrop clicks, focus trapping and the top layer for free. No overlay library, no z-index arithmetic.
  • One doc viewer, shared. The fetch-render-cache dialog that lived inside each dropdown moved into a DocDialog component. The dropdowns and the sheet both open docs through it, and on a phone the viewer takes the whole screen.
  • The proof is a phone-sized test. A Playwright spec at 375 by 812 pixels asserts the dropdowns are gone, the sheet lists all four groups, a doc opens full-screen from it, Admin is reachable, and the footer still renders. The desktop specs stayed untouched, which is how the desktop is proven unchanged.

In the code

The samples below are read from this build's source each time the page is served (ADR: Live code samples). The header half of this record was superseded by ADR: The sidebar the same day, so what follows is the part that still stands, shown as it is today.

The sidebar renders its sections from the same record the dropdowns once used (src/library/sections.ts, in the order src/lib/siteMap.ts sets):

/** Section order, top to bottom: the sidebar and the landing grid both follow it. */
export const MENU_ORDER: readonly MenuVariant[] = SITE_MAP.sections.map((section) => section.menu);

Live from src/lib/siteMap.ts, region MENU_ORDER, read from this build at 99df7a8.

Opening a doc from the drawer closes the drawer and hands the request to the one shared viewer (src/components/layout/SideNav/SideNav.tsx):

// The drawer is a native dialog: useRail flips drawerOpen, this mirrors it.
useEffect(() => {
  const drawer = drawerRef.current;
  if (!drawer) return;
  if (drawerOpen && !drawer.open) drawer.showModal();
  if (!drawerOpen && drawer.open) drawer.close();
}, [drawerOpen, docked]);

const openDoc = (key: DocKey) => {
  drawerRef.current?.close();
  onDocChange(key);
};

Live from src/components/layout/SideNav/SideNav.tsx, region drawer-dialog, read from this build at 99df7a8.

Below the docking line the header carries the brand, Reset bids, and the hamburger; above it the rail makes a header redundant (src/app/Shell.tsx, drawn by src/app/Header.tsx):

{/* Below the docking line the header carries the brand, Reset bids,
    and the hamburger; the docked rail makes it redundant above it.
    What it draws is in Header.tsx. While a page drawn at build time is
    taken over, the line is not known yet, so both the header and the
    rail are drawn and the stylesheet shows the one the window wants
    (data-rail="auto", src/styles/drawn-page.css). */}
{rail.docked !== true && (
  <Header
    onHome={go.goHome}
    bidCount={bidCount}
    onResetBids={onResetBids}
    drawerOpen={rail.drawerOpen}
    onOpenDrawer={rail.openDrawer}
  />
)}

Live from src/app/Shell.tsx, region header-below-dock, read from this build at 99df7a8.

The doc viewer goes edge to edge on a phone (src/library/DocDialog.module.css):

/* Phones: the doc takes the whole screen; code blocks already scroll sideways.
   Pinned to all four edges of the viewport rather than sized to 100dvh from the
   top (on a phone in Chrome, the author's page opened from the home
   page: the dialog sat about 100 px high, its title bar above the
   screen and the home page's resume tile showing under its foot, the gap the
   phone's toolbars open between a height measured once and the screen). And the
   page behind is frosted, the reading panel's own ground, so whatever the
   phone's toolbars do, what shows round the sheet is frost, never the page. */
@media (max-width: 639.98px) {
  .dialog {
    position: fixed;
    inset: 0;
    width: auto;
    max-width: none;
    height: auto;
    max-height: none;
    margin: 0;
  }

  .dialog::backdrop {
    background: var(--dialog-page-bg);
    -webkit-backdrop-filter: var(--dialog-page-filter);
    backdrop-filter: var(--dialog-page-filter);
  }
}

Live from src/library/DocDialog.module.css, region phone-dialog, read from this build at 99df7a8.

The proof is tests/e2e/mobile.spec.ts, which runs at 375 by 812 pixels. The test tree sits outside the roots a live block may read, so it is linked rather than shown.

What this replaced

Nothing was removed. The alternative considered was a responsive dropdown (wrap the four triggers onto a second row on phones), which keeps four tiny menus a thumb cannot hit and does nothing for the docs dialog. A second alternative, a separate mobile route, would have duplicated the menu data, exactly the drift the one-data-source rule exists to prevent.

Consequences

  • Sixteen end-to-end checks now instead of thirteen; three of them run at phone size.
  • Every new doc or menu entry appears on the phone automatically, since the sheet has no list of its own.
  • The docs dialog and the sheet are both native dialogs, so opening a doc from the sheet closes the sheet first. A person taps the hamburger again to pick another doc, which is one tap and keeps the code simple.
  • The breakpoint is 640 pixels because the layout already switched its padding there; one breakpoint is easier to reason about than two.

Addendum, 2026-09-02: the sheet restyled to a reference

Shipped in 1.0.0.14, the same day as the original. Steve pointed at a reference, mentor/reference-mobile-menu.png in the working folder: a dark full-height panel, an icon leading every row, tall rows, muted section headers. The pattern was taken and the palette was not. The mockup is orange; The Yard stays navy and silver.

What changed:

  • A drawer instead of a full sheet. The panel slides in from the left, at most 360 pixels wide, over a dimmed page, so a person keeps their place. It is still the one native dialog, so Escape, the backdrop and the X close it exactly as before.
  • An icon per row kind, six in all: overview document, decision record, infrastructure, external link, Admin, changelog. Every doc in the shared record declares its kind and the row picks its icon from that. Six small inline SVGs reused across two dozen rows, none bespoke.
  • Touch targets of 48 pixels, above the 44 the guidelines ask for, with a hairline divider between rows the way the reference draws them.
  • Contrast measured, not guessed. The light text on the navy ground and on the raised hover row, and the muted header shade on both, were computed before being chosen: text 14.4:1 and 11.8:1, muted 6.3:1 and 5.2:1, all past the 4.5:1 that WCAG AA asks for normal text. The brand blue itself measures 3.1:1 against the navy, so the drawer uses a lighter blue for active icons and the focus ring. A unit test reads the tokens and asserts the ratios, so a future shade change cannot slip under AA.
  • The desktop header now renders from MENU_ORDER instead of four hand-placed dropdowns, so the Changelog menu (ADR: The changelog) appeared on both surfaces from one line of data. The dropdowns themselves are unchanged, and the desktop specs still say so.

In the code: the icon set is src/components/shared/SheetIcons/SheetIcons.tsx, the drawer is src/components/MobileDocs.tsx with its styles in src/components/MobileDocs.module.css, the palette lives in src/styles/colors.css with its proof in src/styles/colors.test.ts, and the phone spec tests/e2e/mobile.spec.ts now asserts the Changelog section, an icon on every row, and the row height. The header block excerpted above under "In the code" is the pre-addendum shape; today it reads:

<div className={styles.desktopActions}>
  {MENU_ORDER.map((menu) => (
    <DocsMenu key={menu} menu={menu} />
  ))}
  <button type="button" className={styles.adminTab} onClick={openAdmin}>
    Admin
  </button>
</div>

Note, 2026-09-02, later the same day: superseded on the desktop

Shipped as 1.0.0.15, the dropdowns are gone at every width and the drawer above became one shape of the sidebar. The record of that decision is ADR: The sidebar, under Best Practices. What this record still owns: the one-data-source rule, the native dialog, the shared viewer, the phone-sized proof, and the palette and icon rows from the addendum. The component moved from src/components/MobileDocs.tsx to src/components/layout/SideNav/SideNav.tsx with its styles in src/components/layout/SideNav/SideNav.module.css; the links above that name the old files now point at 587c9e9, the commit that shipped them, so they keep resolving.

Note, 2026-09-02, evening: the dark palette retired

1.0.0.19 made the sidebar light at Steve's request: he found the side panel too dark and asked for everything light and modern; ADR: The sidebar records the new palette. The icon rows, the 48-pixel targets and the measure-before-choosing rule from the addendum above stand; only the colors changed.

Where it sits

This is front end work only: SideNav.tsx draws the drawer, DocDialog.tsx is the one viewer, and the rows come from the data in src/library/sections.ts with the section order in src/lib/siteMap.ts. It follows the open/closed principle, adding behaviour by adding to the edges instead of editing the core, because a new document reaches the phone as one entry in the data while the drawer's code stays untouched. The cost is one more tap, since opening a document closes the drawer first. A phone that needed a different menu from the laptop would break the one-source rule and justify a second list.

Files

The look, from the live site

A 375 pixel phone: the header with the brand and the hamburger, the inventory below

The drawer open on the phone: icon-led rows under muted section headings

The icon per row kind, seven paths that cover every row (src/components/shared/SheetIcons/SheetIcons.tsx):

// One stroked path per row kind on a shared 20x20 grid, rather than an icon
// library: eight paths cover every row in the rail and the drawer, they inherit
// currentColor so a theme change needs no icon work, and the bundle carries no
// font or sprite (ADR-011).
const PATHS: Record<RowKind, string> = {
  overview:
    'M6 2.5h6.5L17 6.5v10a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1v-13a1 1 0 0 1 1-1zM12.5 2.5v4h4M8 10.5h5M8 13.5h5',
  adr: 'M6 2.5h6.5L17 6.5v10a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1v-13a1 1 0 0 1 1-1zM12.5 2.5v4h4M7.5 12.5l2 2 3.5-3.5',
  infra: 'M10 3.5 3.5 7 10 10.5 16.5 7 10 3.5zM3.5 10.5 10 14l6.5-3.5M3.5 13.5 10 17l6.5-3.5',
  changelog: 'M3.5 10.5v-6a1 1 0 0 1 1-1h6l6.5 6.5-7 7-6.5-6.5zM7.5 7.5h.01',
  external:
    'M11 4H5.5A1.5 1.5 0 0 0 4 5.5v9A1.5 1.5 0 0 0 5.5 16h9a1.5 1.5 0 0 0 1.5-1.5V9M12.5 3.5h4v4M16.5 3.5l-7 7',
  admin: 'M3 10.5h3.2l2-5.5 3.6 10 2-4.5H17',
  reset: 'M4.5 10a5.5 5.5 0 1 1 1.6 3.9M4.5 15v-4.5H9',
  account: 'M10 4a2.6 2.6 0 1 1 0 5.2A2.6 2.6 0 0 1 10 4zM4.9 16.4a5.1 5.1 0 0 1 10.2 0',
};

Live from src/components/shared/SheetIcons/SheetIcons.tsx, region icons, read from this build at 99df7a8.

Enforced by

Not machine-checked. Held by review.

Store

The Yard, home

Steven StoutStaff .NET engineerRemote

Production .NET that stays up. Built with AI, measured on every version.

Steven Stout

Hi, I'm Steve. I build the systems that make delivery boring in the best way, then coach people inside them.

  • 200+

    production releases, none took the platform down

    Conway Investment Research, 2019 to 2024. Sole engineer for the first three years on a live financial advisory platform.

    See how
  • 50%

    shorter release cycle

    Storee Construction, 2024 to 2026. Four ASP.NET applications onto one .NET 10 platform on Azure, with a four-person team I hired and mentored.

    See how

01Verified

Steven Stout

A real person, and the work is mine.

  • Identity

    Checked by LinkedIn, not by me.

    LinkedIn verified my government ID.

  • Running system

    You are looking at it.

    Version 1.0.5.273 is live. Nothing ships unless it passes the automated gates first.

That's who I am. Here's how I work.

02Strengths

Ten strengths, each with the proof beside it. The numbers match my resume and LinkedIn, and the live ones are read from this site as you look.

  • 01

    Keeps production alive

    200+ releases on a live financial platform, and none took it down. Sole engineer for the first three years.

    See the Conway work

  • 02

    Simplifies messy systems

    Four ASP.NET applications onto one .NET 10 platform on Azure, and a release cycle 50% shorter.

    See the Storee work

  • 03

    Marries dev and infrastructure

    Blue-green releases at Storee that flipped in about 5 seconds with nobody signed out, and Azure Front Door at two employers.

    See this site's cloud

  • 04

    Designs data that holds up

    White-label clients on one shared database, the isolation built into the data, and no cross-client issues.

    See the Conway work

  • 05

    Keeps AI-written code honest

    15 quality numbers that may only improve: 273 releases in a row with none worse.

    See the quality numbers

  • 06

    Resourceful

    $30,000+ cut from Azure and vendor spend at Conway. This site's Azure bill is public, resource by resource.

    See the bill

  • 07

    Builds people up

    Hired and mentored a four-person team. 13 colleagues recommend me by name.

    Read the recommendations

  • 08

    Takes ideas to production

    This site: designed, built and run solo, with 352 versions measured through one gate.

    How it was built

  • 09

    Writes clearly

    Posts on real engineering problems, in plain words.

    Read the blog

  • 10

    Owns decisions

    153 decision records, each with its tradeoff and the call I made.

    See the decision records

Built with AI. Gated so quality never slides.

Steven Stout’s showcase: a used-vehicle auction on .NET and React, built and run by one engineer, live on Azure, with its decisions written down.

No quality number has gotten worse at any release since 1.0.5.1 on 10 November: 273 releases in a row.

One engineer, an AI agent and a gate that checks 15 quality numbers on every release. 352 versions measured, with every result public, the worst days included.

82 releases in the last 7 days, each through the same gate.

Async methods with no CancellationToken, may only fall

11091.0.3.1391.0.5.2731.0.4.115, the ratchet
Every number, on the Quality page

TheYard, right nowLive

Answering in

unread

02505007501,000

server time at p95, the usual five minutes of the last day.

Azure this month

unread

the bill, by resource, read from Azure. The Admin tab shows every line.

Since the last roll

unread

 

rolled in place by the pipeline, behind one gate.

People who have visited

unread

30 days agotoday

Scanners, my own tools' and my own reads left out.

03Start here

04Where teams are heading

How I see engineering with AI, and the setup on this site that backs it.

AI-augmented teams · Architecture and ownership

AI writes more of the code. Someone still has to own what ships.

Teams are going to be heavily AI-augmented. That moves the senior job toward architecture and technical ownership: deciding what to build in pieces small enough to verify, and owning what ships.

  • Task tracking will get automated too. Judgment stays human: seeing a design fail at scale before it does.
  • On this site the AI's first design held the whole catalogue in memory. I caught it when the App Service plan hit 82 per cent and moved the work to the store.

What the AI wrote, what I decided

07Tech stack

  •    
  •    
  •    

Read from the build, never typed by hand

What TheYard runs on

What we use, where it runs, its AWS twin, the version as built, and the file that proves it.

Cloud patterns, not one vendor: every Azure piece in this stack has a named AWS twin. Mapped, not yet run on AWS.

  • .NET 1114 projects
  • React 19.3TypeScript 7.0
  • Azure9 Bicep files
  • 11GitHub Actions workflows
The whole stack, with the file that proves each line

The last release the gate stopped was 1.0.5.258 on 2 December, at its browser 1 of 2 job.

08How it is built

09How it is run

10Who and why

Next step

11What has to work, where is it today, and what does success look like?

Book 20 minutes opens an email to me with those three questions in it, and I answer with a time.

Book 20 minutes

Your email app should have opened with this message. If it did not, copy it and send it from any mailbox.

Or message me on LinkedIn