-
Notifications
You must be signed in to change notification settings - Fork 14
Fix issue with sourceType overload on project vs silo images and disks #2097
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
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
This is looking really good. It fixes the bug. As we talked about in chat, I think it would be slightly better if your selection on each tab was preserved as you switch between tabs, so you could check what's on another tab without losing what you've done. This would require splitting |
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.
sweet. let’s do final review in #2076
* Create instance from existing boot disk * Remove setting undefined on tab change (for now) * Improve descriptions * copy tweaks * tweak empty states copy, fix diskList prefetch * Fix issue with sourceType overload on project vs silo images and disks (#2097) * Fix issue with sourceType collision on project vs silo images and disks * refactor * Refactoring, and updating types * Maintain state of fields across tab navigation (#2100) * Simplify test; make it work for Safari * Clean up and add comments * verify in test that correct image used * clean up comment * imageSize -> imageSizeGiB --------- Co-authored-by: David Crespo <david.crespo@oxidecomputer.com> Co-authored-by: Charlie Park <charlie@oxidecomputer.com>
This proposal addresses an issue we're seeing in the instance create form.
Currently, because the create-instance form has a default image selected when the form is initialized, the form will use that image as the foundation for the instance, even if the user clicks to a different image source tab, if they don't select a new image. So they might select the "Project images" tab but end up creating an instance using the default Silo image. This is also a problem when the user selects the new "existing disk" tab.
This PR addresses the issue by setting up each of the tabs as their own piece of the form, and setting up a
bootDiskSourceType
that keeps track of the desired boot disk source.This also allows us to maintain state across tab changes, so if the user has selected a source image and then clicks to a different tab, then clicks back, they don't lose their work.