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

Design: an app's domain DNS records use the design system, and domain-records leaves §5d #3858

Parked opened this
Closed without merging

scout/forge:scout/3836-design-an-app-s-domain-dns-records-use-t → main 7 commits fork

  • Closed without merging. Nothing was applied to main.

Review

Sign in to review this change.
5 files changed +26 −11
docs/DESIGN.md +2 −2
@@ -391,8 +391,8 @@ gone, so this list only shrinks.
391391
392392 - **`style/base.ts`** — the page shell (topbar, main, footer) and the layout and text utilities every page leans on: `.bar` `.bare` `.foot` `.grow` `.hide-lg` `.hide-sm` `.js-only` `.live-pill` `.mark` `.mb` `.mt` `.muted` `.narrow` `.narrow-wide` `.num` `.reduced` `.shell` `.shell-wide` `.skip` `.small` `.spacer` `.sr-only` `.stack` `.stack-tight` `.topbar` `.topbar-tools` `.truncate` `.wordmark`
393393 - **`style/components.ts`** — parts of the §5 components that the table does not spell out — the palette's list, the menu's items, a dialog's head and foot, comments, the theme picker — and a few small helpers beside them: `.cat` `.clone` `.clone-text` `.comment` `.comment-body` `.comment-form` `.dash` `.dialog-body` `.dialog-foot` `.dialog-head` `.empty-title` `.error-note` `.field-row` `.form-actions` `.hex` `.ico` `.ico-loader` `.list` `.live-status` `.menu-item` `.menu-panel` `.menu-sep` `.menu-title` `.palette-empty` `.palette-foot` `.palette-group` `.palette-heading` `.palette-input` `.palette-item` `.palette-list` `.passkey` `.passkey-lead` `.passkey-note` `.passkey-off` `.passkey-on` `.preview` `.sep` `.split` `.sprite` `.swatch` `.table-scroll` `.tell-here` `.theme-apply` `.theme-option` `.tick` `.timeline` `.tl-dot` `.toast-body` `.topbar-search`
394 - **`style/components.ts`, settings rows** — a list whose rows are settings (limits, capacity): the `<ul class="list setting-list">` lets title and meta wrap instead of ellipsizing, and a row's controls take their own line under 640px. `.row-fields` is the form in that row's trail (input, Save, Default): always visible, never hover-gated, wrapping under the text before it would clip. Use both for any page whose rows show a name, a current value, and a control to change it; use `.row-actions` only for secondary actions (delete, wake, pin, revoke). Flags, telemetry, cloud, people, crew roles and subscription headroom/budget use `.row-fields`. Classes: `.row-fields` `.setting-list`
395 - **`style/content.ts`, page furniture** — what frames a page's content: page and repo heads, the merge box, the front page and its tiles, explore, backups, boards, the fleet chart's series colours, following, lineage: `.about` `.act` `.app-shelf` `.app-tile` `.app-tile-body` `.app-tile-desc` `.app-tile-look` `.app-tile-name` `.backups-drill` `.backups-error` `.backups-now` `.backups-restore` `.bform` `.bgrid` `.big` `.bmanage` `.boards-result` `.bp-h2` `.bp-h3` `.bp-w2` `.bp-w3` `.break` `.bt-bar` `.bt-grid` `.bt-group` `.bt-hist` `.bt-name` `.bt-procs` `.bt-row` `.bt-val` `.chart` `.chart-box` `.commit-body` `.commit-head` `.connect-more` `.connect-path` `.domain-records` `.explore-filters` `.explore-line` `.explore-main` `.explore-name` `.explore-row` `.fg-s0` `.fg-s1` `.fg-s2` `.fg-s3` `.fg-s4` `.fg-s5` `.fg-s6` `.fg-s7` `.filters` `.flag-form` `.following` `.following-actions` `.following-eyebrow` `.following-foot` `.following-head` `.following-sentence` `.fork-bar` `.front-admin` `.front-controls` `.front-crew` `.front-featured` `.front-featured-body` `.front-featured-look` `.front-issues` `.front-live` `.front-more` `.front-pick` `.front-pin-any` `.front-weights` `.frozen` `.frozen-form` `.frozen-sentence` `.handoff` `.handoff-links` `.headroom` `.hero` `.hero-terminal` `.issue-head` `.issue-meta` `.kv` `.lineage` `.lineage-children` `.lineage-here` `.merge-box` `.merge-form` `.merge-headline` `.merge-sub` `.mirror-form` `.number` `.origin-link` `.origin-mark` `.origin-name` `.origin-row` `.owner` `.page-head` `.path-head` `.policy-line` `.qf` `.quiet-details` `.repo-actions` `.repo-audience` `.repo-desc` `.repo-layout` `.repo-lineage` `.repo-title` `.search` `.slash` `.stage-detail` `.stage-dot` `.steps` `.sub` `.sys-pair` `.table-wrap` `.terminal-line` `.tok` `.tree-row` `.tree-total` `.wall-cells` `.where-sep`
394 - **`style/components.ts`, settings rows** — a list whose rows are settings (limits, capacity): the `<ul class="list setting-list">` lets title and meta wrap instead of ellipsizing, and a row's controls take their own line under 640px. `.row-fields` is the form in that row's trail (input, Save, Default): always visible, never hover-gated, wrapping under the text before it would clip. Use both for any page whose rows show a name, a current value, and a control to change it; use `.row-actions` only for secondary actions (delete, wake, pin, revoke). Flags, telemetry, cloud, people, crew roles and subscription headroom/budget use `.row-fields`. Classes: `.row-fields` `.record-value` `.setting-list`
395 - **`style/content.ts`, page furniture** — what frames a page's content: page and repo heads, the merge box, the front page and its tiles, explore, backups, boards, the fleet chart's series colours, following, lineage: `.about` `.act` `.app-shelf` `.app-tile` `.app-tile-body` `.app-tile-desc` `.app-tile-look` `.app-tile-name` `.backups-drill` `.backups-error` `.backups-now` `.backups-restore` `.bform` `.bgrid` `.big` `.bmanage` `.boards-result` `.bp-h2` `.bp-h3` `.bp-w2` `.bp-w3` `.break` `.bt-bar` `.bt-grid` `.bt-group` `.bt-hist` `.bt-name` `.bt-procs` `.bt-row` `.bt-val` `.chart` `.chart-box` `.commit-body` `.commit-head` `.connect-more` `.connect-path` `.explore-filters` `.explore-line` `.explore-main` `.explore-name` `.explore-row` `.fg-s0` `.fg-s1` `.fg-s2` `.fg-s3` `.fg-s4` `.fg-s5` `.fg-s6` `.fg-s7` `.filters` `.flag-form` `.following` `.following-actions` `.following-eyebrow` `.following-foot` `.following-head` `.following-sentence` `.fork-bar` `.front-admin` `.front-controls` `.front-crew` `.front-featured` `.front-featured-body` `.front-featured-look` `.front-issues` `.front-live` `.front-more` `.front-pick` `.front-pin-any` `.front-weights` `.frozen` `.frozen-form` `.frozen-sentence` `.handoff` `.handoff-links` `.headroom` `.hero` `.hero-terminal` `.issue-head` `.issue-meta` `.kv` `.lineage` `.lineage-children` `.lineage-here` `.merge-box` `.merge-form` `.merge-headline` `.merge-sub` `.mirror-form` `.number` `.origin-link` `.origin-mark` `.origin-name` `.origin-row` `.owner` `.page-head` `.path-head` `.policy-line` `.qf` `.quiet-details` `.repo-actions` `.repo-audience` `.repo-desc` `.repo-layout` `.repo-lineage` `.repo-title` `.search` `.slash` `.stage-detail` `.stage-dot` `.steps` `.sub` `.sys-pair` `.table-wrap` `.terminal-line` `.tok` `.tree-row` `.tree-total` `.wall-cells` `.where-sep`
396396 - **`style/content.ts`, code view** — the source view and the syntax-highlight token classes `highlight-html.ts` builds as `tok-${kind}`: `.blob-view` `.ln` `.tok-attribute` `.tok-comment` `.tok-constant` `.tok-decorator` `.tok-deleted` `.tok-emphasis` `.tok-function` `.tok-heading` `.tok-inserted` `.tok-keyword` `.tok-link` `.tok-meta` `.tok-number` `.tok-operator` `.tok-plain` `.tok-property` `.tok-punctuation` `.tok-regex` `.tok-string` `.tok-tag` `.tok-type` `.tok-variable`
397397 - **`style/content.ts`, prose (markdown)** — table cell alignment, built by `markdown.ts` as `ta-${align}`: `.ta-c` `.ta-r`
398398 - **`style/content.ts`, diff viewer** — the diff table: its gutters, line kinds, file head and inline review comments: `.add` `.del` `.dh` `.diff` `.diff-body` `.diff-head` `.diff-note` `.diff-path` `.diff-stat` `.diff-stub` `.diff-summary` `.diff-table` `.dl` `.dl-review` `.dn` `.dn-comment` `.nonl` `.rc-hidden` `.rc-resolve` `.rc-resolved` `.wd`
src/web/pages/settings.ts +14 −8
@@ -874,7 +874,7 @@ function appDomainsView(
874874 ${when(
875875 rows.length > 0,
876876 () =>
877 html`<ul class="list">
877 html`<ul class="list setting-list">
878878 ${rows}
879879 </ul>`,
880880 )}
@@ -919,13 +919,19 @@ function appDomainsView(
919919
920920 /** The records as a person copies them into a zone: type, name, value. */
921921 function recordsToPublish(records: DnsRecord[]): Html {
922 const width = Math.max(...records.map((r) => r.name.length)) + 2;
923 const lines = records
924 .map((r) => `${r.type.padEnd(6)} ${r.name.padEnd(width)} ${r.value}`)
925 .join("\n");
926 const notes = records.filter((r) => r.note !== undefined);
927 return html`<pre class="domain-records">${lines}</pre>
928 ${notes.map((r) => html`<span class="row-meta">${r.note}</span>`)}`;
922 return html`${records.map(
923 (r) =>
924 html`<span class="row-meta"
925 >${badge(r.type, { variant: "outline" })}
926 <span class="mono">${r.name}</span> →
927 <span class="mono record-value" title="${r.value}"
928 >${r.value}</span
929 ></span
930 >`,
931 )}
932 ${records
933 .filter((r) => r.note !== undefined)
934 .map((r) => html`<span class="row-meta">${r.note}</span>`)}`;
929935 }
930936
931937 const appValues = (repo: Repo, record: AppRecord | undefined): AppValues => ({
src/web/style/components.ts +1
@@ -425,6 +425,7 @@ details[open] > summary.row > .row-lead { transform: rotate(90deg); }
425425 .setting-list .row { flex-wrap: wrap; align-items: flex-start; }
426426 .setting-list .row-main { flex: 1 1 18rem; }
427427 .setting-list .row-title, .setting-list .row-meta { white-space: normal; overflow: visible; overflow-wrap: anywhere; }
428 .setting-list .record-value { user-select: all; }
428429 .setting-list .row-trail { flex: 0 1 auto; max-width: 100%; }
429430 @media (max-width: 640px) { .setting-list .row-trail { flex-basis: 100%; } }
430431 @media (pointer: coarse) { .row-actions { opacity: 1; } .row { min-height: 44px; } }
src/web/style/content.ts −1
@@ -401,7 +401,6 @@ a.origin-chip:hover { border-color: var(--border-strong); color: var(--fg); }
401401 .backups-error { display: flex; align-items: center; gap: 8px; color: var(--danger); }
402402 .backups-restore { margin: 8px 0 0; padding: 8px 10px; font-size: 12.5px; white-space: pre-wrap; word-break: break-all; background: var(--muted); border-radius: var(--radius); }
403403 /* The records a domain waits on: type, name, value — as a zone file reads. */
404 .domain-records { margin: 6px 0 2px; padding: 8px 10px; font-size: 12.5px; line-height: 1.6; white-space: pre; overflow-x: auto; scrollbar-width: thin; background: var(--muted); border-radius: var(--radius); }
405404 .policy-line {
406405 display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
407406 margin: 12px 0 0; font-size: 13px; color: var(--muted-fg);
test/app-domains.test.ts +9
@@ -595,6 +595,15 @@ describe("an app gets its own domain", () => {
595595 `forge-verify=${getDomain(app.db, "example.com")!.token}`,
596596 );
597597 expect(page).toContain("ALIAS");
598 expect(page).not.toContain("domain-records");
599 // The records wrap instead of truncating (.row-meta only wraps inside
600 // .setting-list), carry the type badge, and the whole value is selectable.
601 const token = getDomain(app.db, "example.com")!.token;
602 expect(page).toContain('<ul class="list setting-list">');
603 expect(page).toMatch(/badge[^>]*>\s*TXT\s*</);
604 expect(page).toMatch(
605 new RegExp(`class="mono record-value" title="forge-verify=${token}"`),
606 );
598607 expect(page).toContain(`${settings}/domains/example.com/check`);
599608 expect(page).toContain(
600609 encodeURIComponent(`${settings}/domains/example.com/delete`),

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs