Skip to content

feat(frontend): add required dc selector to onboaring#4474

Merged
jog1t merged 1 commit intomainfrom
03-22-feat_frontend_add_required_dc_selector_to_onboaring
Mar 22, 2026
Merged

feat(frontend): add required dc selector to onboaring#4474
jog1t merged 1 commit intomainfrom
03-22-feat_frontend_add_required_dc_selector_to_onboaring

Conversation

@jog1t
Copy link
Contributor

@jog1t jog1t commented Mar 22, 2026

Description

This pull request improves the getting started flow and form components with several enhancements:

  • Added a safe parameter to runnerConfigQueryOptions to allow graceful handling of missing configurations without throwing errors
  • Enhanced the stepper form component with support for custom previous button text and improved control layout
  • Improved the serverless connection form with better field descriptions, proper form validation structure, and enhanced datacenter selection messaging
  • Updated the getting started flow to pre-populate forms with existing runner configurations when available
  • Fixed combobox behavior to only close on single selection, keeping it open for multiple selections
  • Reorganized the backend setup step to show configuration options before the endpoint field
  • Enhanced the frontend setup waiting state with better layout and additional manual creation option

Type of change

  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes.

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4474 March 22, 2026 00:44 Destroyed
Copy link
Contributor Author

jog1t commented Mar 22, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@railway-app
Copy link

railway-app bot commented Mar 22, 2026

🚅 Deployed to the rivet-pr-4474 environment in rivet-frontend

Service Status Web Updated (UTC)
kitchen-sink ❌ Build Failed (View Logs) Web Mar 22, 2026 at 12:51 am
ladle 🕒 Building (View Logs) Web Mar 22, 2026 at 12:51 am
frontend-cloud 🕒 Building (View Logs) Web Mar 22, 2026 at 12:51 am
frontend-inspector 🕒 Building (View Logs) Web Mar 22, 2026 at 12:51 am
website ✅ Success (View Logs) Web Mar 22, 2026 at 12:48 am
mcp-hub ✅ Success (View Logs) Web Mar 22, 2026 at 12:45 am

@claude
Copy link

claude bot commented Mar 22, 2026

PR Review: feat(frontend): add required dc selector to onboarding

Overall this PR improves UX nicely. Pre-populating forms with existing config, better datacenter messaging, and fixing the combobox multi-select behavior are all good additions.

Bugs

1. datacenters default value is wrong type (getting-started.tsx)

The defaultValues object sets datacenters: [] (an array) as the fallback, but the field expects a plain object. The RegionSelect component reads this via Object.keys(field.value || {}) and the onChange handler produces an object via Object.fromEntries(...). Using [] as the fallback will produce incorrect behavior when no existing config is found. Should be datacenters: {}.

2. Missing runnerName in base defaults (getting-started.tsx)

The original defaultValues always included runnerName: default. In the new code it only appears when initialRunnerConfig is non-null (spread from it). When the user has no existing config, runnerName will be undefined in the form, which may break form submission. The base defaults should include runnerName: default before the spread.

Code Quality

3. Datacenters component missing FormItem wrapper (connect-manual-serverless-form.tsx)

The refactored Datacenters component's FormField render prop returns a bare fragment without a FormItem wrapper. All other form fields in this file use FormItem for consistent spacing and layout. This will likely cause alignment issues with the rest of the form.

4. Removed debug console.log

Good catch on removing console.log(formState.errors, formState.isValid, watch()) from StepContent. It should not have been committed.

Minor

  • Commit message typo: onboaring should be onboarding
  • The previous button rendering in stepper-form.tsx checks step.previous three separate times (for size, startIcon, and children). This could be simplified to reduce duplication.

Positive Notes

  • The safe param on runnerConfigQueryOptions is a clean API. Returning null instead of throwing is the right pattern for optional pre-population.
  • Fixing the combobox to only close on single-select is a correct bug fix.
  • The || to ?? change for MinRunners input value properly preserves 0 as a valid value.
  • Moving defaultValues out of JSX is good for readability and avoids unnecessary re-creation on each render.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Mar 22, 2026

More templates

@rivetkit/virtual-websocket

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/virtual-websocket@4474

@rivetkit/cloudflare-workers

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/cloudflare-workers@4474

@rivetkit/framework-base

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/framework-base@4474

@rivetkit/next-js

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/next-js@4474

@rivetkit/react

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/react@4474

rivetkit

pnpm add https://pkg.pr.new/rivet-dev/rivet/rivetkit@4474

@rivetkit/sql-loader

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/sql-loader@4474

@rivetkit/sqlite-vfs

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/sqlite-vfs@4474

@rivetkit/traces

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/traces@4474

@rivetkit/workflow-engine

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/workflow-engine@4474

@rivetkit/engine-runner

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/engine-runner@4474

@rivetkit/engine-runner-protocol

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/engine-runner-protocol@4474

commit: 28be5f8

@jog1t jog1t marked this pull request as ready for review March 22, 2026 00:48
@jog1t jog1t force-pushed the 03-22-feat_frontend_add_required_dc_selector_to_onboaring branch from 28be5f8 to cf36c16 Compare March 22, 2026 00:50
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4474 March 22, 2026 00:50 Destroyed
Copy link
Contributor Author

jog1t commented Mar 22, 2026

Merge activity

  • Mar 22, 12:51 AM UTC: A user started a stack merge that includes this pull request via Graphite.
  • Mar 22, 12:51 AM UTC: @jog1t merged this pull request with Graphite.

@jog1t jog1t merged commit 75e9e75 into main Mar 22, 2026
12 of 19 checks passed
@jog1t jog1t deleted the 03-22-feat_frontend_add_required_dc_selector_to_onboaring branch March 22, 2026 00:51
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