Skip to content

feat(ui): create-workspace dialog + single-source the form across surfaces#257

Merged
luokerenx4 merged 3 commits into
masterfrom
harness-issue
Jun 3, 2026
Merged

feat(ui): create-workspace dialog + single-source the form across surfaces#257
luokerenx4 merged 3 commits into
masterfrom
harness-issue

Conversation

@luokerenx4
Copy link
Copy Markdown
Contributor

Summary

  • The create-workspace form was hand-written on three surfaces (Workspaces sidebar, Chat section, template detail page) — each rewiring useCreateWorkspace + template selection + the field JSX. Adding a create-time option meant editing all three, and the sidebar's inline stack had no room to grow.
  • Extract one CreateWorkspaceForm that owns useCreateWorkspace and the template-selection state, so a surface renders <CreateWorkspaceForm /> and writes zero form logic. Wrap it in CreateWorkspaceDialog (reusing the existing uta/Dialog shell) for the two sidebar surfaces — a popup with room to grow instead of a cramped column. The template detail page renders the same form inline in its panel.
  • Behavior preserved: Chat section keeps its date-based default tag (chat-jun3) + autofocus; per-template reset on the detail page is now a key={templateName} remount. The 3 surfaces shrank ~245 lines; future options are a one-place edit.

Test plan

  • cd ui && tsc -b clean
  • vitest --project ui passes (38/38); no spec renders these components, hook + api unchanged
  • manual: created workspaces from the sidebar, Chat section, and template detail page

Boundary touch

None — UI-only. No trading / auth / broker / migration surface.

🤖 Generated with Claude Code

Ame and others added 3 commits June 3, 2026 10:44
The Tools dropdown was only on the Template detail page. The sidebar
quick-create and the Chat workspace section share useCreateWorkspace (the
toolAccess state was already wired) but didn't render the selector — so on
those surfaces the launcher option wasn't choosable. Add the dropdown to both.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…faces

The create form was hand-written three times (Workspaces sidebar, Chat
section, template detail page) — each wiring useCreateWorkspace + template
selection + the field JSX itself. Adding a create-time option meant editing
all three, and the sidebar's inline stack had no room to grow.

Extract one CreateWorkspaceForm that owns useCreateWorkspace AND the
template-selection state, so a surface renders <CreateWorkspaceForm /> and
writes zero form logic. Wrap it in CreateWorkspaceDialog (reusing the
existing uta/Dialog shell) for the two sidebar surfaces — a popup with room
to grow instead of a cramped column. The template detail page renders the
same form inline in its panel.

Behavior preserved: the Chat section keeps its date-based default tag
(chat-jun3) + autofocus; per-template reset on the detail page is now a
key={templateName} remount. Future create options are a one-place edit.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Jun 3, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
openalice-demo Ready Ready Preview, Comment Jun 3, 2026 5:25am

Request Review

@luokerenx4 luokerenx4 merged commit 0e399db into master Jun 3, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant