portal: the portal entry boots by host and shows the faces — PT-S0 signed out, PT-S0r resting/unreachable, PT-S2 session ended, PT-S3 not here (spec #1361 s1–6, 25–26, 36) #1365

Closed
opened 2026-09-10 00:56:34 +00:00 by ben · 2 comments
Owner

Parent

Spec #1361 (the Portal); program map #1336; design contract DDR 0232 / ADR 0233, flow docs/ux/flows/portal.mermaid, wireframes docs/ux/wireframes/portal/. Slice portal-entry-faces in docs/slices/portal.yaml.

What to build

One bundle, host-aware boot (apex → the portal entry; admin. → the operator SPA — path alone never decides). The portal entry's face chooser over /me: no session → PT-S0 (brand kit + one Sign in door → /authz/signin ?rd=/); resting → PT-S0r resting-line; /me unreachable → PT-S0r unreachable-line; live → a HOME PLACEHOLDER (the home is the next slice); 401 under a loaded page → PT-S2 (sign-in-again with rd); not-live → cookie cleared → PT-S0; unknown path → PT-S3. Sign out → /authz/signout. Entry seam tests with injected routing + fetch doubles. Wireframes PT-S0, PT-S0r, PT-S2, PT-S3 are the contract.

Acceptance criteria

  • Given the served bundle, when location.host is the apex, then the portal entry boots; when it is admin. the operator SPA boots — path alone never decides.
  • Given /me answers 401 (no session), when the Portal loads, then PT-S0 renders: community-logo, community-name, greeting, one sign-in action → /authz/signin?rd=/ — no service list, no Join door, no tier hint.
  • Given /me answers resting:true, when the Portal loads, then PT-S0r renders the resting-line (data-status=resting) and NO sign-in action.
  • Given /me does not answer (network/5xx), when the Portal loads, then PT-S0r renders the unreachable-line (data-status=unreachable) and NO sign-in action.
  • Given /me answers live:false, when the Portal loads, then the cookie is cleared and PT-S0 renders with no refusal copy.
  • Given /me answers live:true, when the Portal loads, then a home placeholder renders carrying signed-in-as and sign-out (the home proper is home-doors).
  • Given a loaded page whose next /me call answers 401, when the answer arrives, then PT-S2 replaces it (data-status=session-ended, headline, what-it-means, sign-in-again with rd back to place) and nothing else remains on screen.
  • Given an unknown apex path, when the Portal loads, then PT-S3 renders (not-here, go-home).
  • Given sign-out is pressed, when it runs, then the browser goes to /authz/signout and lands on PT-S0.
  • Given design-verify, when it runs, then the built faces match PT-S0, S0r, S2, S3 by data-field/data-action/data-status.

Blocked by

Task manifest

task: portal-entry-faces
implements_flow: portal
implements_edge: PT-S0 · PT-S0r · PT-S2 · PT-S3 (the faces; host-aware boot)
wireframe: docs/ux/wireframes/portal/pt-s0-signed-out.html
interface: ''
seam: dashboard entry seam tests (routing + fetch doubles)
acceptance:
- given: the served bundle
  when: location.host is the apex
  then: the portal entry boots; when it is admin.<apex> the operator SPA boots — path alone never decides
- given: /me answers 401 (no session)
  when: the Portal loads
  then: 'PT-S0 renders: community-logo, community-name, greeting, one sign-in action → /authz/signin?rd=/
    — no service list, no Join door, no tier hint'
- given: /me answers resting:true
  when: the Portal loads
  then: PT-S0r renders the resting-line (data-status=resting) and NO sign-in action
- given: /me does not answer (network/5xx)
  when: the Portal loads
  then: PT-S0r renders the unreachable-line (data-status=unreachable) and NO sign-in action
- given: /me answers live:false
  when: the Portal loads
  then: the cookie is cleared and PT-S0 renders with no refusal copy
- given: /me answers live:true
  when: the Portal loads
  then: a home placeholder renders carrying signed-in-as and sign-out (the home proper is home-doors)
- given: a loaded page whose next /me call answers 401
  when: the answer arrives
  then: PT-S2 replaces it (data-status=session-ended, headline, what-it-means, sign-in-again with rd back
    to place) and nothing else remains on screen
- given: an unknown apex path
  when: the Portal loads
  then: PT-S3 renders (not-here, go-home)
- given: sign-out is pressed
  when: it runs
  then: the browser goes to /authz/signout and lands on PT-S0
- given: design-verify
  when: it runs
  then: the built faces match PT-S0, S0r, S2, S3 by data-field/data-action/data-status
depends_on:
- me-route
- signout-route
out_of_scope:
- operator truth on the Portal
- operator notices / per-service public switch
- IDIP identity door
- mail on IDIP (stated limit)
- IDIP browser sign-in UX (#1302)
needs_human_decision: []
## Parent Spec **#1361** (the Portal); program map **#1336**; design contract DDR 0232 / ADR 0233, flow `docs/ux/flows/portal.mermaid`, wireframes `docs/ux/wireframes/portal/`. Slice `portal-entry-faces` in `docs/slices/portal.yaml`. ## What to build One bundle, host-aware boot (apex → the portal entry; admin.<apex> → the operator SPA — path alone never decides). The portal entry's face chooser over /me: no session → PT-S0 (brand kit + one Sign in door → /authz/signin ?rd=/); resting → PT-S0r resting-line; /me unreachable → PT-S0r unreachable-line; live → a HOME PLACEHOLDER (the home is the next slice); 401 under a loaded page → PT-S2 (sign-in-again with rd); not-live → cookie cleared → PT-S0; unknown path → PT-S3. Sign out → /authz/signout. Entry seam tests with injected routing + fetch doubles. Wireframes PT-S0, PT-S0r, PT-S2, PT-S3 are the contract. ## Acceptance criteria - [ ] Given the served bundle, when location.host is the apex, then the portal entry boots; when it is admin.<apex> the operator SPA boots — path alone never decides. - [ ] Given /me answers 401 (no session), when the Portal loads, then PT-S0 renders: community-logo, community-name, greeting, one sign-in action → /authz/signin?rd=/ — no service list, no Join door, no tier hint. - [ ] Given /me answers resting:true, when the Portal loads, then PT-S0r renders the resting-line (data-status=resting) and NO sign-in action. - [ ] Given /me does not answer (network/5xx), when the Portal loads, then PT-S0r renders the unreachable-line (data-status=unreachable) and NO sign-in action. - [ ] Given /me answers live:false, when the Portal loads, then the cookie is cleared and PT-S0 renders with no refusal copy. - [ ] Given /me answers live:true, when the Portal loads, then a home placeholder renders carrying signed-in-as and sign-out (the home proper is home-doors). - [ ] Given a loaded page whose next /me call answers 401, when the answer arrives, then PT-S2 replaces it (data-status=session-ended, headline, what-it-means, sign-in-again with rd back to place) and nothing else remains on screen. - [ ] Given an unknown apex path, when the Portal loads, then PT-S3 renders (not-here, go-home). - [ ] Given sign-out is pressed, when it runs, then the browser goes to /authz/signout and lands on PT-S0. - [ ] Given design-verify, when it runs, then the built faces match PT-S0, S0r, S2, S3 by data-field/data-action/data-status. ## Blocked by - #1362 - #1363 ## Task manifest ```yaml task: portal-entry-faces implements_flow: portal implements_edge: PT-S0 · PT-S0r · PT-S2 · PT-S3 (the faces; host-aware boot) wireframe: docs/ux/wireframes/portal/pt-s0-signed-out.html interface: '' seam: dashboard entry seam tests (routing + fetch doubles) acceptance: - given: the served bundle when: location.host is the apex then: the portal entry boots; when it is admin.<apex> the operator SPA boots — path alone never decides - given: /me answers 401 (no session) when: the Portal loads then: 'PT-S0 renders: community-logo, community-name, greeting, one sign-in action → /authz/signin?rd=/ — no service list, no Join door, no tier hint' - given: /me answers resting:true when: the Portal loads then: PT-S0r renders the resting-line (data-status=resting) and NO sign-in action - given: /me does not answer (network/5xx) when: the Portal loads then: PT-S0r renders the unreachable-line (data-status=unreachable) and NO sign-in action - given: /me answers live:false when: the Portal loads then: the cookie is cleared and PT-S0 renders with no refusal copy - given: /me answers live:true when: the Portal loads then: a home placeholder renders carrying signed-in-as and sign-out (the home proper is home-doors) - given: a loaded page whose next /me call answers 401 when: the answer arrives then: PT-S2 replaces it (data-status=session-ended, headline, what-it-means, sign-in-again with rd back to place) and nothing else remains on screen - given: an unknown apex path when: the Portal loads then: PT-S3 renders (not-here, go-home) - given: sign-out is pressed when: it runs then: the browser goes to /authz/signout and lands on PT-S0 - given: design-verify when: it runs then: the built faces match PT-S0, S0r, S2, S3 by data-field/data-action/data-status depends_on: - me-route - signout-route out_of_scope: - operator truth on the Portal - operator notices / per-service public switch - IDIP identity door - mail on IDIP (stated limit) - IDIP browser sign-in UX (#1302) needs_human_decision: [] ```

swarm-claim host=matou-dev-server-01 run=20996
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=matou-dev-server-01 run=20996 (automated multi-host claim — lowest live claim id works this ticket)

close-report for #1365 — status success

✅ close-report gates passed — every claim verified against main; issue closed.

envelope
{
  "issue": 1365,
  "status": "success",
  "commits": [
    "66e1e066"
  ],
  "changed_files": [
    "STATUS.md",
    "dashboard/src/components/portal/PortalBrandHeader.vue",
    "dashboard/src/components/portal/PortalHomePlaceholder.vue",
    "dashboard/src/components/portal/PortalNotHere.vue",
    "dashboard/src/components/portal/PortalResting.vue",
    "dashboard/src/components/portal/PortalSessionEnded.vue",
    "dashboard/src/components/portal/PortalSignedOut.vue",
    "dashboard/src/components/portal/PortalSurface.vue",
    "dashboard/src/entry/main.ts",
    "dashboard/src/entry/portal.ts",
    "dashboard/src/lib/api/portalClient.ts",
    "dashboard/src/lib/portal.ts",
    "dashboard/src/lib/portalRouting.ts",
    "dashboard/tests/unit/portalEntry.test.ts"
  ],
  "tests": [
    {
      "command": "npx vitest run tests/unit/portalEntry.test.ts",
      "exit_code": 0
    },
    {
      "command": "npx vitest run (full dashboard suite, 1432 tests)",
      "exit_code": 0
    },
    {
      "command": "npx vue-tsc -p tsconfig.json --noEmit",
      "exit_code": 0
    },
    {
      "command": "npx vite build",
      "exit_code": 0
    },
    {
      "command": "CI=true npx eslint .",
      "exit_code": 0
    }
  ],
  "criteria": {
    "host-aware boot (apex → Portal entry; admin.<apex> → operator SPA; path alone never decides)": "main.ts host-aware dispatch on isAdminHost(location.host); src/lib/portalRouting.ts isAdminHost; portalEntry.test.ts 'the boot is host-aware — path alone never decides (AC1)'",
    "/me 401 → PT-S0 (community-logo, community-name, greeting, sign-in → /authz/signin?rd=/, no service list/Join/tier hint)": "PortalSignedOut.vue + PortalBrandHeader.vue; portalEntry.test.ts 'PT-S0 — the signed-out face' asserts the data-fields, the sign-in href /authz/signin?rd=/, and the absence of my-doors/join/tier",
    "/me resting:true → PT-S0r resting-line (data-status=resting), NO sign-in": "PortalResting.vue status=resting; portalEntry.test.ts 'renders the resting-line and NO sign-in'",
    "/me does not answer (network/5xx) → PT-S0r unreachable-line (data-status=unreachable), NO sign-in": "portalClient.ts maps fetch throw + 5xx to unreachable; PortalResting.vue status=unreachable; portalEntry.test.ts 'unreachable-line ... network' and 'on a 5xx too'",
    "/me live:false → cookie cleared + PT-S0 with no refusal copy": "cookie is cleared by the /me route's Set-Cookie (ClearSessionCookie, me.go #1362); the face drops to PT-S0 quietly — PortalSurface.vue 'not-live' → 's0'; portalEntry.test.ts 'a not-live standing drops to PT-S0 quietly' asserts PT-S0, no session-ended, no suspend/removed copy",
    "/me live:true → home placeholder carrying signed-in-as and sign-out": "PortalHomePlaceholder.vue (signed-in-as + sign-out → /authz/signout); portalEntry.test.ts 'a live session lands on the home placeholder'",
    "loaded page whose next /me answers 401 → PT-S2 replaces it (session-ended, headline, what-it-means, sign-in-again with rd) and nothing else remains": "PortalSurface.vue hasBeenLive → 's2'; PortalSessionEnded.vue; the re-check poll (bootPortalEntry); portalEntry.test.ts 'PT-S2 — the session ends under the loaded home' asserts the replacement, the fields, sign-in-again rd, and that portal-home/sign-out are gone",
    "unknown apex path → PT-S3 (not-here, go-home)": "bootPortalEntry notHere = !isPortalHomePath(path); PortalNotHere.vue; PortalSurface makes no read when notHere; portalEntry.test.ts 'PT-S3 — an unknown apex path is not-here' asserts not-here + go-home + zero /me calls",
    "sign-out pressed → browser goes to /authz/signout and lands on PT-S0": "PortalHomePlaceholder.vue sign-out anchor href=/authz/signout (the browser navigation, ending the community leg per #1363; a following 401 /me renders PT-S0 as proven by the PT-S0 case); portalEntry.test.ts asserts the /authz/signout href",
    "design-verify: the built faces match PT-S0/S0r/S2/S3 by data-field/data-action/data-status": "the built components carry the acceptance-criteria element contract (portal-signed-out/community-logo/community-name/greeting/sign-in; portal-resting/resting|unreachable; portal-session-ended/session-ended/headline/what-it-means/sign-in-again; portal-not-here/not-here/go-home; portal-home/signed-in-as/sign-out) asserted by portalEntry.test.ts — see DESIGN NOTE in reason on the absent wireframe files"
  },
  "summary": "Ship the Portal's member-facing bundle: host-aware boot + the four faces (PT-S0/S0r/S2/S3) and the signed-in home placeholder, chosen by the /me fact, at the dashboard entry seam.",
  "reason": "DESIGN NOTE: the design artifacts the ticket references (docs/ux/wireframes/portal/*, docs/ux/flows/portal.mermaid, DDR 0232, ADR 0233, docs/slices/portal.yaml) do not exist in the repo and never have in git history — the same state under which the backend dependencies #1362/#1363/#1370 landed. The parent spec #1361 and this ticket's acceptance criteria fully enumerate the data-field/data-action/data-status contract for PT-S0/S0r/S2/S3 and the home placeholder, so the screens were built to that contract. Proceeding rather than blocking is a two-way door under ADR 0174 (revertible; a later commit realigns field names if a wireframe is authored) and is provable by the seam test asserting every element hook. Recorded in STATUS.md and the commit message.",
  "blockers": []
}
**close-report** for #1365 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 1365, "status": "success", "commits": [ "66e1e066" ], "changed_files": [ "STATUS.md", "dashboard/src/components/portal/PortalBrandHeader.vue", "dashboard/src/components/portal/PortalHomePlaceholder.vue", "dashboard/src/components/portal/PortalNotHere.vue", "dashboard/src/components/portal/PortalResting.vue", "dashboard/src/components/portal/PortalSessionEnded.vue", "dashboard/src/components/portal/PortalSignedOut.vue", "dashboard/src/components/portal/PortalSurface.vue", "dashboard/src/entry/main.ts", "dashboard/src/entry/portal.ts", "dashboard/src/lib/api/portalClient.ts", "dashboard/src/lib/portal.ts", "dashboard/src/lib/portalRouting.ts", "dashboard/tests/unit/portalEntry.test.ts" ], "tests": [ { "command": "npx vitest run tests/unit/portalEntry.test.ts", "exit_code": 0 }, { "command": "npx vitest run (full dashboard suite, 1432 tests)", "exit_code": 0 }, { "command": "npx vue-tsc -p tsconfig.json --noEmit", "exit_code": 0 }, { "command": "npx vite build", "exit_code": 0 }, { "command": "CI=true npx eslint .", "exit_code": 0 } ], "criteria": { "host-aware boot (apex → Portal entry; admin.<apex> → operator SPA; path alone never decides)": "main.ts host-aware dispatch on isAdminHost(location.host); src/lib/portalRouting.ts isAdminHost; portalEntry.test.ts 'the boot is host-aware — path alone never decides (AC1)'", "/me 401 → PT-S0 (community-logo, community-name, greeting, sign-in → /authz/signin?rd=/, no service list/Join/tier hint)": "PortalSignedOut.vue + PortalBrandHeader.vue; portalEntry.test.ts 'PT-S0 — the signed-out face' asserts the data-fields, the sign-in href /authz/signin?rd=/, and the absence of my-doors/join/tier", "/me resting:true → PT-S0r resting-line (data-status=resting), NO sign-in": "PortalResting.vue status=resting; portalEntry.test.ts 'renders the resting-line and NO sign-in'", "/me does not answer (network/5xx) → PT-S0r unreachable-line (data-status=unreachable), NO sign-in": "portalClient.ts maps fetch throw + 5xx to unreachable; PortalResting.vue status=unreachable; portalEntry.test.ts 'unreachable-line ... network' and 'on a 5xx too'", "/me live:false → cookie cleared + PT-S0 with no refusal copy": "cookie is cleared by the /me route's Set-Cookie (ClearSessionCookie, me.go #1362); the face drops to PT-S0 quietly — PortalSurface.vue 'not-live' → 's0'; portalEntry.test.ts 'a not-live standing drops to PT-S0 quietly' asserts PT-S0, no session-ended, no suspend/removed copy", "/me live:true → home placeholder carrying signed-in-as and sign-out": "PortalHomePlaceholder.vue (signed-in-as + sign-out → /authz/signout); portalEntry.test.ts 'a live session lands on the home placeholder'", "loaded page whose next /me answers 401 → PT-S2 replaces it (session-ended, headline, what-it-means, sign-in-again with rd) and nothing else remains": "PortalSurface.vue hasBeenLive → 's2'; PortalSessionEnded.vue; the re-check poll (bootPortalEntry); portalEntry.test.ts 'PT-S2 — the session ends under the loaded home' asserts the replacement, the fields, sign-in-again rd, and that portal-home/sign-out are gone", "unknown apex path → PT-S3 (not-here, go-home)": "bootPortalEntry notHere = !isPortalHomePath(path); PortalNotHere.vue; PortalSurface makes no read when notHere; portalEntry.test.ts 'PT-S3 — an unknown apex path is not-here' asserts not-here + go-home + zero /me calls", "sign-out pressed → browser goes to /authz/signout and lands on PT-S0": "PortalHomePlaceholder.vue sign-out anchor href=/authz/signout (the browser navigation, ending the community leg per #1363; a following 401 /me renders PT-S0 as proven by the PT-S0 case); portalEntry.test.ts asserts the /authz/signout href", "design-verify: the built faces match PT-S0/S0r/S2/S3 by data-field/data-action/data-status": "the built components carry the acceptance-criteria element contract (portal-signed-out/community-logo/community-name/greeting/sign-in; portal-resting/resting|unreachable; portal-session-ended/session-ended/headline/what-it-means/sign-in-again; portal-not-here/not-here/go-home; portal-home/signed-in-as/sign-out) asserted by portalEntry.test.ts — see DESIGN NOTE in reason on the absent wireframe files" }, "summary": "Ship the Portal's member-facing bundle: host-aware boot + the four faces (PT-S0/S0r/S2/S3) and the signed-in home placeholder, chosen by the /me fact, at the dashboard entry seam.", "reason": "DESIGN NOTE: the design artifacts the ticket references (docs/ux/wireframes/portal/*, docs/ux/flows/portal.mermaid, DDR 0232, ADR 0233, docs/slices/portal.yaml) do not exist in the repo and never have in git history — the same state under which the backend dependencies #1362/#1363/#1370 landed. The parent spec #1361 and this ticket's acceptance criteria fully enumerate the data-field/data-action/data-status contract for PT-S0/S0r/S2/S3 and the home placeholder, so the screens were built to that contract. Proceeding rather than blocking is a two-way door under ADR 0174 (revertible; a later commit realigns field names if a wireframe is authored) and is provable by the seam test asserting every element hook. Recorded in STATUS.md and the commit message.", "blockers": [] } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#1365
No description provided.