Spaces epic batch 1: identity registry (A0), ID-keyed spacemeta (A), subtitle/description split + space header (G) #768

Closed
opened 2026-09-26 16:02:03 +00:00 by Cordy · 0 comments
Owner

Opening batch of the Spaces epic (rev3 mockup approved; #695 round 13 lineage; ADR 0002 lands with this batch's first commit).

A0 — identity registry (internal/spaceids): age-encrypted statestore doc mapping immutable time-ordered IDs → {name, backendDir, kind: app-owned|directory, aliases}. Lazy stamping: app-owned spaces at create/open migration, directory spaces at first sighting in fillSpaceStates/union. backendDir always equals name until batch 4 wires the resolver into the hot path — zero hot-path change in this batch.

A — spacemeta (internal/spacemeta): cosmetics keyed by space ID from birth: subtitle (≤80 runes), description (≤4000 runes, newlines preserved), image (reserved for batch 3). Single source of cosmetics for BOTH kinds.

G — split + header + migration:

  • Endpoints POST /api/v1/spaces/{name}/subtitle and /description, storage moves to spacemeta; guards: app-owned → owner or admin; directory → admin only. Existing #765 endpoint/tests updated accordingly (spacestore.SetDescription retires; struct field stays decode-only for migration).
  • One-time idempotent boot migration: #765 Space.Description ≤80 runes → subtitle, longer → description; field cleared after move.
  • Union + listing decoration carry subtitle + description; rows/tiles render SUBTITLE only.
  • Space header at space root (name, bold subtitle, paragraph description via pre-line/textContent, members button, kebab); collapses when empty. Two edit dialogs replace the single #765 one. Details pane: Subtitle row + wrapping Description row.
  • Audit verbs: space-set-subtitle (registered in verbs.go), space-set-description exists.

Batch gate before tag: invariants workflow — registry stamping idempotence, name→id resolution incl. case, guard matrix (owner/admin/member × app-owned/directory), migration run-twice no-op, subtitle/description limits, both suites green.

i18n ×4 throughout. Release: v0.6.286 to both dogfoods.

Opening batch of the Spaces epic (rev3 mockup approved; #695 round 13 lineage; ADR 0002 lands with this batch's first commit). **A0 — identity registry** (`internal/spaceids`): age-encrypted statestore doc mapping immutable time-ordered IDs → `{name, backendDir, kind: app-owned|directory, aliases}`. Lazy stamping: app-owned spaces at create/open migration, directory spaces at first sighting in `fillSpaceStates`/union. `backendDir` always equals `name` until batch 4 wires the resolver into the hot path — zero hot-path change in this batch. **A — spacemeta** (`internal/spacemeta`): cosmetics keyed by space ID from birth: `subtitle` (≤80 runes), `description` (≤4000 runes, newlines preserved), `image` (reserved for batch 3). Single source of cosmetics for BOTH kinds. **G — split + header + migration:** - Endpoints `POST /api/v1/spaces/{name}/subtitle` and `/description`, storage moves to spacemeta; guards: app-owned → owner or admin; directory → admin only. Existing #765 endpoint/tests updated accordingly (`spacestore.SetDescription` retires; struct field stays decode-only for migration). - One-time idempotent boot migration: #765 `Space.Description` ≤80 runes → subtitle, longer → description; field cleared after move. - Union + listing decoration carry `subtitle` + `description`; rows/tiles render SUBTITLE only. - Space header at space root (name, bold subtitle, paragraph description via pre-line/textContent, members button, kebab); collapses when empty. Two edit dialogs replace the single #765 one. Details pane: Subtitle row + wrapping Description row. - Audit verbs: `space-set-subtitle` (registered in verbs.go), `space-set-description` exists. **Batch gate before tag:** invariants workflow — registry stamping idempotence, name→id resolution incl. case, guard matrix (owner/admin/member × app-owned/directory), migration run-twice no-op, subtitle/description limits, both suites green. i18n ×4 throughout. Release: v0.6.286 to both dogfoods.
Cordy closed this issue 2026-09-26 16:58:32 +00:00
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Cordy/Cairn#768
No description provided.