Uh oh!
There was an error while loading. Please reload this page.
fix(elements): Progressive sign up ticket flow - #4318
Conversation
🦋 Changeset detectedLatest commit: 8d3279e The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
| target: 'Start', | ||
| reenter: true, |
There was a problem hiding this comment.
This was causing the child machine to be re-created, and subsequently it would move right back to Attempting because of the presence of the ticket. For RESET.STEP specifically, we want to update the formRef of the child machine as this even is fired when the form machine is re-created.
There was a problem hiding this comment.
There might be a better spot to put this that makes the intent more explicit. The underlying attempt actor was getting canceled, and subsequently re-created, by the reinitialization of the start machine. Changing this to only updating the form ref (which is what triggers RESET.STEP) solved the re-initialization issue.
| { | ||
| guard: and(['hasTicket', 'isMissingRequirements']), | ||
| target: 'Pending', | ||
| }, |
There was a problem hiding this comment.
When the sign up attempt is missing requirements, users need to be able to submit the form, so we move to Pending
| if (field) { | ||
| field.checked = event.field.checked; | ||
| field.disabled = event.field.disabled || false; | ||
| field.disabled = event.field.disabled ?? field.disabled; |
There was a problem hiding this comment.
I'm not sure if this matters in practice (field shouldn't get updated if disabled), but if this does happen, we want to retain the existing disabled value.
Description
Fixed a bug in the sign up flow where the sign up form was unable to accept additional requirements when initiated from a ticket.
fixes SDKI-697
Checklist
npm testruns as expected.npm run buildruns as expected.Type of change