Public: anyone can read this; the crew can change it.
The signed-out first page offers one clear Sign in button under the example clock, and says what signing in shows #265
Check · Review · Land · Live done — Landed and live in production.
mason/deal-clock:mason/264-the-signed-out-first-page-offers-one-cle → main 1 commit fork
4 files
changed +10
−2
docs/design/areas/welcome.md +1
| @@ -4,3 +4,4 @@ New classes on the signed-out `/`: | ||
| 4 | 4 | |
| 5 | 5 | - `.welcome` — the page's wrapper; its headline is capped at 40rem. |
| 6 | 6 | - `.points` — the three short points under the headline, a plain list. |
| 7 | - `.start` — the line under the example clock: a primary Sign in button and one sentence. |
src/pages/welcome.ts +2 −1
| @@ -1,6 +1,6 @@ | ||
| 1 | 1 | /** |
| 2 | 2 | * What a signed-out visitor sees at `/`: what the app does, three short |
| 3 | * points, a picture of the clock. The one Sign in button is the layout's. The picture is drawn | |
| 3 | * points, a picture of the clock. A primary Sign in sits under the picture (the header keeps its quiet one). The picture is drawn | |
| 4 | 4 | * with the clock's own markup and classes from a made-up deal written here; |
| 5 | 5 | * no row is read from the database, so nothing about `deal` opens to anon. |
| 6 | 6 | */ |
| @@ -62,6 +62,7 @@ export function welcomePage(input: { who: Who; agent?: Agent | undefined; on: st | ||
| 62 | 62 | <section class="card clock" aria-label="An example of the clock"> |
| 63 | 63 | ${picture(input.on)} |
| 64 | 64 | </section> |
| 65 | <p class="start"><a class="button" href="/__forge/signin?to=%2F">Sign in</a> to see your own deals on this clock. Nothing is sent without your approval.</p> | |
| 65 | 66 | </section>`; |
| 66 | 67 | return layout({ body, who: input.who, agent: input.agent, path: "/", live: false }); |
| 67 | 68 | } |
src/server.test.ts +4 −1
| @@ -59,7 +59,10 @@ test("the clock knows who you are and offers the right door", async () => { | ||
| 59 | 59 | const guest = await (await fetch(base + "/")).text(); |
| 60 | 60 | expect(guest).toContain("Every deadline of every deal on one timeline"); |
| 61 | 61 | expect(guest).toContain('href="/__forge/signin?to=%2F"'); |
| 62 | expect(guest.match(/>Sign in</g)).toHaveLength(1); | |
| 62 | // Two doors on purpose: the quiet one in the header, the primary one under the example clock. | |
| 63 | expect(guest.match(/>Sign in</g)).toHaveLength(2); | |
| 64 | expect(guest).toContain('<p class="start"><a class="button" href="/__forge/signin?to=%2F">Sign in</a>'); | |
| 65 | expect(guest).toContain("Nothing is sent without your approval"); | |
| 63 | 66 | expect(guest).toContain('class="marker"'); |
| 64 | 67 | expect(guest).not.toContain("<script"); |
| 65 | 68 | expect(guest).not.toContain("Maya"); |
static/app.css +3
| @@ -846,6 +846,9 @@ a.week-row { | ||
| 846 | 846 | .welcome .card { |
| 847 | 847 | margin-top: var(); |
| 848 | 848 | } |
| 849 | .welcome .start { | |
| 850 | margin: var() 0 0; | |
| 851 | } | |
| 849 | 852 | .welcome .marker { |
| 850 | 853 | cursor: default; |
| 851 | 854 | } |
new above
offline