-
Notifications
You must be signed in to change notification settings - Fork 11.1k
fix: Onboarding v3 - create team then invite. #25364
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
base: main
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
| return redirect("/onboarding/teams/invite/email"); | ||
| const redirectUrl = teamId | ||
| ? `/onboarding/teams/invite/email?teamId=${teamId}` | ||
| : "/onboarding/teams/invite/email"; |
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.
We will try to pull from context if this part of the flow happens (it never should)
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.
5 issues found across 7 files
Prompt for AI agents (all 5 issues)
Understand the root cause of the following 5 issues and fix them.
<file name="apps/web/modules/onboarding/hooks/useCreateTeam.ts">
<violation number="1" location="apps/web/modules/onboarding/hooks/useCreateTeam.ts:67">
User-facing error text should use t() instead of a hard-coded English string per the localization guideline.</violation>
<violation number="2" location="apps/web/modules/onboarding/hooks/useCreateTeam.ts:77">
Localize this validation error with t() instead of embedding English text directly.</violation>
<violation number="3" location="apps/web/modules/onboarding/hooks/useCreateTeam.ts:118">
Use the t() localization helper for this fallback invite error instead of a hard-coded string.</violation>
</file>
<file name="apps/web/modules/onboarding/teams/details/team-details-view.tsx">
<violation number="1" location="apps/web/modules/onboarding/teams/details/team-details-view.tsx:84">
createTeam is invoked with a stale onboarding-store snapshot, so the newly entered team name/slug never reach the mutation and the flow bounces the user back to the details step.</violation>
</file>
<file name="apps/web/modules/onboarding/teams/invite/email/team-invite-email-view.tsx">
<violation number="1" location="apps/web/modules/onboarding/teams/invite/email/team-invite-email-view.tsx:81">
Remove the hardcoded English fallback so this toast message always comes from `t()` and remains localizable.</violation>
</file>
Reply to cubic to teach it or ask questions. Re-run a review with @cubic-dev-ai review this PR
apps/web/modules/onboarding/teams/invite/email/team-invite-email-view.tsx
Show resolved
Hide resolved
E2E results are ready! |
eunjae-lee
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.
looks good. it worked well on my machine.
What does this PR do?
This PR changes the order of creating the team -> paying -> invite users.
The old approach was create team -> invite -> pay. But we are matching the current implementation of how billing works with usage based billing
How should this be tested?
Enable onboarding-v3 flag on your instance
Ensure you have stripe enabled + stripe:listen running
login as [email protected], onboarding
Go through the team setup flow
Pay
Invite
Ensure uers were added to team
Create a new account
disable billing
Test again
Checklist