-
Notifications
You must be signed in to change notification settings - Fork 54
Add flow to create a new site from remote site #1997
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
📊 Performance Test ResultsComparing 82ae588 vs trunk site-editor
site-startup
Results are median values from multiple test runs. Legend: 🟢 Improvement (faster) | 🔴 Regression (slower) | ⚪ No change |
…add-create-new-site-from-remote
…add-create-new-site-from-remote
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a new "Import an existing website" feature that allows users to pull remote sites from WordPress.com or Pressable directly during the add site flow. This streamlines the onboarding process by integrating site sync capabilities into the initial site creation workflow.
Key Changes
- Added a new
/pullRemotenavigation flow with two steps: site selection and site details configuration - Integrated sync functionality into the site creation process, automatically connecting and pulling from the selected remote site
- Extended the add site workflow to support the new remote import option alongside existing create, blueprint, and backup flows
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/modules/sync/components/sync-sites-modal-selector.tsx | Exported ListSites component for reuse and added text color class for improved styling |
| src/modules/add-site/tests/add-site.test.tsx | Added mock setup for new sync-related hooks used in the add site flow |
| src/modules/add-site/index.tsx | Added /pullRemote routes, handlers, and state management for remote site selection |
| src/modules/add-site/hooks/use-stepper.ts | Extended stepper logic to support the new pull remote flow |
| src/modules/add-site/components/stepper.tsx | Added props to support pull remote continue action and validation |
| src/modules/add-site/components/pull-remote-site.tsx | New component providing UI for selecting remote sites to pull, with authentication handling |
| src/modules/add-site/components/options.tsx | Added new "Import an existing website" option button and minor styling adjustments |
| src/hooks/use-add-site.ts | Integrated sync site connection and pull functionality into site creation callback |
| src/hooks/tests/use-add-site.test.tsx | Added test coverage for remote site pull workflow |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
epeicher
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @sejas, this is a great functionality! I have tested it, and it works as expected. I can create a site from a WP.com site, and the Pull starts automatically.
One suggestion to consider for a follow-up is to add the search box to the list of sites to connect. I assume that is not a common scenario to have that many sites, but I think it would be helpful.
Another suggestion to avoid errors during the import when opening the site or wp-admin is to disable the links, but again, this could be a follow-up only if we think it's helpful.
I have left a minor nit comment, but I think this is ready for merging 🙌 . LGTM! ![]()
| Select site | Site creating | Site importing | Site Imported 🎉 |
|---|---|---|---|
![]() |
![]() |
![]() ![]() |
![]() |





Related issues
Proposed Changes
Testing Instructions
streamlineOnboardingfrom the UI or from CLI env.Add sitecreate-site-and-start-pulling.mp4
Pre-merge Checklist