Skip to content

Conversation

@ivan-ottinger
Copy link
Contributor

@ivan-ottinger ivan-ottinger commented Oct 15, 2025

Related issues

Proposed Changes

  • introduce handleStepClick to handle clicks on the previous step that is already complete
  • ensure the selected import file is remembered when navigating between steps
  • adjust styling of the previous step label
Screen.Capture.on.2025-10-15.at.17-24-50.mp4

Testing Instructions

  1. Check out the PR branch and build the app with npm install && npm start.
  2. Click the Add site button in the app sidebar and try to navigate through the steps of Start from Blueprint and Import from backup flows.
  3. When you complete the first step and get to the second one by clicking the Continue button, it should be possible to get back to the first step by clicking the step label (not just the Back button).
  4. When you are in the Import from backup flow and navigating back to the step where the import file is selected, it should be remembered.
  5. When you review how the step labels are animated during transition between steps, there should be no odd movement / shift in those labels.

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?

@ivan-ottinger ivan-ottinger self-assigned this Oct 15, 2025
className={ cx(
`text-sm`,
isCurrent ? 'text-gray-900 font-medium' : 'text-gray-500'
`text-sm font-medium`,
Copy link
Contributor Author

@ivan-ottinger ivan-ottinger Oct 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am curios to hear what you think about this change.

Before (you can see slight shift / movement in labels):

Screen.Capture.on.2025-10-15.at.17-17-26.mov

After (there's no shift in the labels; instead the unselected label has thinner font size):

Screen.Capture.on.2025-10-15.at.17-16-26.mp4

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch!

@ivan-ottinger ivan-ottinger marked this pull request as ready for review October 15, 2025 15:26
@ivan-ottinger ivan-ottinger requested a review from a team October 15, 2025 15:26
@github-actions
Copy link
Contributor

github-actions bot commented Oct 15, 2025

📊 Performance Test Results

Comparing a4bb4c0 vs trunk

site-editor

Metric trunk a4bb4c0 Diff Change
load 16639.00 ms 14375.00 ms -2264.00 ms 🟢 -13.6%

site-startup

Metric trunk a4bb4c0 Diff Change
siteCreation 23444.00 ms 23218.00 ms -226.00 ms 🟢 -1.0%
siteStartup 9051.00 ms 8104.00 ms -947.00 ms 🟢 -10.5%

Results are median values from multiple test runs.

Legend: 🟢 Improvement (faster) | 🔴 Regression (slower) | ⚪ No change

Copy link
Contributor

@bcotrim bcotrim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍
Added some suggestions, but feel free to merge as is.

{ steps.map( ( step, index ) => {
const isCurrent = step.status === 'current';
const isCompleted = step.status === 'completed';
const isClickable = isCompleted && step.path;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would also move this logic to the useStepper hook.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the suggestions, Bernardo. I agree, it make sense to move these. I have moved the click handler as well: ad724a7.

Copy link
Contributor

@gcsecsey gcsecsey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes LGTM and work well. I can navigate back using the labels, and the file selection in earlier step is also preserved. 👍

@ivan-ottinger
Copy link
Contributor Author

Thank you for your reviews, Bernardo and Gergely!

@ivan-ottinger ivan-ottinger merged commit 1c1e091 into trunk Oct 16, 2025
12 checks passed
@ivan-ottinger ivan-ottinger deleted the add/click-handler-to-complete-steps branch October 16, 2025 14:30
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.

5 participants