You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replace the Create Deployment modal (currently inline in the deployments index page) with a dedicated page at /projects/$projectName/deployments/new. The modal has too many form fields (8+) for a dialog, and users lose their work by accidentally clicking outside.
Acceptance Criteria
New route at /_authenticated/projects/$projectName/deployments/new renders a Create Deployment page
Page contains all existing form fields: Display Name, Name (slug), Description, Template select, Image, Tag, Command (StringListInput), Args (StringListInput), Environment Variables (EnvVarEditor)
"Create Deployment" button on deployments list page navigates to the new page (not a modal)
Empty state on deployments list page also links to the new page
When no templates exist, show a link to /projects/$projectName/templates/new instead of opening a sub-modal
On successful creation, navigates to the deployment detail page (/projects/$projectName/deployments/$deploymentName)
Form validation preserved (name, template, image, tag required)
Unit tests for the new page component with mocked query hooks
Tests pass: make test
Implementation Notes
Files to create
frontend/src/routes/_authenticated/projects/$projectName/deployments/new.tsx — the new Create Deployment page route
frontend/src/routes/_authenticated/projects/$projectName/deployments/-new.test.tsx — unit tests
Parent Issue
Part of #394
Goal
Replace the Create Deployment modal (currently inline in the deployments index page) with a dedicated page at
/projects/$projectName/deployments/new. The modal has too many form fields (8+) for a dialog, and users lose their work by accidentally clicking outside.Acceptance Criteria
/_authenticated/projects/$projectName/deployments/newrenders a Create Deployment page/projects/$projectName/templates/newinstead of opening a sub-modal/projects/$projectName/deployments/$deploymentName)make testImplementation Notes
Files to create
frontend/src/routes/_authenticated/projects/$projectName/deployments/new.tsx— the new Create Deployment page routefrontend/src/routes/_authenticated/projects/$projectName/deployments/-new.test.tsx— unit testsFiles to modify
frontend/src/routes/_authenticated/projects/$projectName/deployments/index.tsx— remove inline modal code (~120 lines), replace "Create Deployment" button with<Link to="new">navigationKey patterns to follow
createFileRoute('/_authenticated/projects/$projectName/deployments/new')for the route definitionuseNavigate()to redirect after successful creationuseCreateDeploymentfrom@/queries/deploymentsanduseListDeploymentTemplatesfrom@/queries/deployment-templatesStringListInput,EnvVarEditor,filterEnvVarsTesting approach
@/queries/deploymentsand@/queries/deployment-templateswithvi.mock()andvi.fn()-index.test.tsxfileDependencies
Depends on #395 (Create Template page) — the "no templates" link targets the new template creation page.