feat: add public entry and authenticated workspace dashboard

This commit is contained in:
2026-10-16 10:48:51 +09:00
parent b8b12442a0
commit a060ffada8
32 changed files with 1702 additions and 368 deletions
@@ -11,6 +11,8 @@ import { dashboardFixture } from "../../src/lib/workspace/home/dashboard.test-fi
Deno.serve({ hostname: "127.0.0.1", port }, async (request) => {
const url = new URL(request.url);
if (url.pathname === "/api/auth/whoami") return Response.json({ actor: { user_id: "fixture-user", account_id: "fixture-owner", handle: "alice", display_name: "Alice", auth_method: "browser_session" } });
if (url.pathname === "/api/hosting/access") return Response.json({ is_admin: false });
if (url.pathname === "/api/workspaces" && request.method === "POST") {
return Response.json({
message:
@@ -61,7 +61,7 @@ Deno.test("production empty Workspace supports optional Git validation, reopenin
creationBodies.push(route.request().postDataJSON());
await route.fulfill({ json: creationResponse() });
});
await page.goto(scenario.baseUrl!);
await page.goto(scenario.baseUrl! + "/dashboard#workspace-create-title");
const name = page.getByLabel("Workspace display name");
await name.fill("New Workspace");
const toggle = page.getByRole("checkbox", {
@@ -119,7 +119,7 @@ Deno.test("production empty Workspace supports optional Git validation, reopenin
await page.locator("[data-feed-ready=home-active]").waitFor();
assertEquals(await page.locator("main [role=alert]").count(), 0);
// Reopening is based on Workspace identity, not a repository record.
await page.goto(scenario.baseUrl!);
await page.goto(scenario.baseUrl! + "/dashboard");
await page.locator('a.workspace-catalog-card[href="/w/home-empty"]')
.click();
await page.waitForURL("**/w/home-empty");
@@ -35,7 +35,7 @@
{
"id": "catalog",
"label": "Create Workspace without a repository",
"path": "/",
"path": "/dashboard#workspace-create-title",
"goal": "Reopen a zero-repository Workspace or create a new Workspace without configuring Git.",
"dataState": "Opt-in Git fields followed by intentional HTTP400 creation validation failure; no actual resources are created.",
"ready": {
@@ -35,7 +35,7 @@
{
"id": "catalog",
"label": "Create Workspace without a repository",
"path": "/",
"path": "/dashboard#workspace-create-title",
"goal": "Reopen a zero-repository Workspace or create a new Workspace without configuring Git.",
"dataState": "Accessible Workspaces with no repositories and blank creation form.",
"ready": {