Context. surface studio · domain hathor · route /studio/hathor/workbench-locations · auth signed-in + studio entitlement · source apps/oshun/web/src/app/studio/hathor/workbench-locations/page.tsx
Last walked. 2026-05-29 automated runtime walk (Playwright headless) — render, /v1 data (2xx), console/page-errors, expected content, screenshot verified; live screen-reader, touch, offline, and telemetry-delivery checks pending a manual AT pass. Evidence: WALKTHROUGH/results/runtime-sweep-2026-05-29.md; body re-derived 2026-06-03 from current source (lane-console architecture)
Purpose#
Admin lane console for the @hathor/domain-models location scorers. The assess
lane describes a location (condition, danger level, atmosphere, services,
economy, districts, defenses) and returns its habitability, prosperity, safety,
and defensive-strength scores, each out of 100. Admin-scoped and fail-closed.
Entry points#
- Direct URL / bookmark —
/studio/hathor/workbench-locations;alternates.canonicalis set. - Quick-action from siblings — this page links to the Workbench Characters lane.
- Studio overview — see
../../studio-overview.md.
Layout regions#
page.tsx renders inside <ShellLayout active="studio">:
- Workspace (
StudioHathorWorkbenchLocationsWorkspace,data-hathor-workbench-locations-workspace):<h1>WorkspaceHeading— "Hathor Workbench Locations Workspace"- Summary
<p data-hathor-workbench-locations-summary> - The catalog state, then the location form (with a reference-enumerations
<details>) + the four scored metric bars.
- Route Map panel (
<section data-hathor-workbench-locations-route-map>,<h2>Route Map</h2>): 5 entries fromSTUDIO_HATHOR_WORKBENCH_LOCATIONS_ROUTE_MAP(path + purpose). - Quick-action lane (
className="quickAction"Links): Workbench Characters, Back to Studio workspace index.
States#
- Loading —
<p data-hathor-wl-loading>"Loading location engine…". - Unauthorized —
data-hathor-wl-unauthorizedon 401/403 (admin-scope). - Error —
data-hathor-wl-erroron a non-OK catalog response or network failure. - Ready (form) —
data-hathor-wl-formwith the location textarea and the reference-enumerations disclosure (data-hathor-wl-conditions,data-hathor-wl-dangers). - Result —
data-hathor-wl-resultwithdata-hathor-wl-nameand fourdata-hathor-wl-metricbars (habitability / prosperity / safety / defensive). - Validation error —
data-hathor-wl-assess-errorfor malformed JSON or a failed POST.
Interactions#
-
data-hathor-wl-location(textarea,aria-label="location json") — edit the location JSON. -
data-hathor-wl-submit("Assess location") — parses the JSON and POSTs{ location }; on 200 with a validresultrenders the four scores. - Route Map entries — verify against
STUDIO_HATHOR_WORKBENCH_LOCATIONS_ROUTE_MAP(5 entries). - Quick-action links — Workbench Characters
(
/studio/hathor/workbench-characters), Back to Studio (/studio).
Data & contracts#
- Reads:
GET /v1/admin/hathor/workbench-locations(catalog:conditions,dangerLevels,atmospheres,fortificationLevels). - Writes:
POST /v1/admin/hathor/workbench-locations/assesswith{ location }. - Realtime: none.
- Caching: client fetch on mount,
cache: 'no-store',buildBffAuthHeaders(),AbortControlleron unmount. - Auth: admin-scoped, fail-closed (401/403 → unauthorized); route is behind the signed-in + studio proxy gate.
Cross-references#
- Parent:
../../studio-overview.md - Component sources:
apps/oshun/web/src/components/studio/StudioHathorWorkbenchLocationsWorkspace.tsxapps/oshun/web/src/components/studio/StudioHathorWorkbenchLocationsRouteMap.ts
- Siblings:
./studio-hathor-workbench-characters.md,./studio-hathor-location-modeling.md,./studio-hathor-workbench-worlds.md
Open questions / known gaps#
- Hathor is
unconfirmed-v1perWALKTHROUGH/matrix/routes.csv; confirm whether the dedicated/studio/hathor/*admin lanes ship V1 or are internal-only.