Repository navigation
[Payment due @bernhardoj] Update NewDot onboarding employee ranges - #97021
Conversation
|
Hey, I noticed you changed If you want to automatically generate translations for other locales, an Expensify employee will have to:
Alternatively, if you are an external contributor, you can run the translation script locally with your own OpenAI API key. To learn more, try running: npx ts-node ./scripts/generateTranslations.ts --helpTypically, you'd want to translate only what you changed by running |
|
@bernhardoj Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8570a3a13c
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Persisted onboarding data can still contain 5-10 and 11-50. Keep both values valid for analytics and experiment classification. Hide them from new selections.
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppiOS: mWeb Safariios.mweb.mp4 |
|
🎯 @bernhardoj, thanks for reviewing and testing this PR! 🎉 A payment issue will be created for your review once this PR is deployed to production. If payment is not needed (e.g., regression PR review fix etc), react with 👎 to this comment to prevent the payment issue from being created. |
| !!canUserPerformWriteAction(report, isReportArchived) && | ||
| !isChatThread && | ||
| introSelected?.companySize !== CONST.ONBOARDING_COMPANY_SIZE.MICRO && | ||
| introSelected?.companySize !== CONST.ONBOARDING_COMPANY_SIZE.LEGACY_MICRO && |
There was a problem hiding this comment.
Shouldn't we compare against the 4 values here? The 2 existing and the 2 legacy?
There was a problem hiding this comment.
I think I can help answer this. So, we previously used CONST.ONBOARDING_COMPANY_SIZE.MICRO here. MICRO value is 1-10, and this value is unchanged in this PR; it's just the name renamed to be prefixed with LEGACY_. So, the logic stays identical.
There was a problem hiding this comment.
Oh I see. So shouldn't this look at the new 1-9 values here? Specifically, why aren't we adding MICRO_MEDIUM to these conditions?
There was a problem hiding this comment.
Maybe because we are now showing the guide booking options for 5+ company size?
@trjExpensify Any idea?
There was a problem hiding this comment.
Yeah, I bet that's it. I believe before we didn't assign a guide to anyone that selected the 1-9 signUpQualifier on the homepage, but @MitchExpensify I believe led an initiative to change that and start assigning one to 5+, so this had to be split out.
There was a problem hiding this comment.
Probably separate to this PR, but I'm somewhat surprised this code block doesn't have logic about if the deal is marked as won. Am I right in thinking that the "Book a call" button to book time on a Guide's calendar shows forever?
There was a problem hiding this comment.
Should LEGACY_MICRO keep showing the webinar option?
There was a problem hiding this comment.
Yes the button isn't dependent on any deal status (is that even available on the frontend?)
There was a problem hiding this comment.
Should LEGACY_MICRO keep showing the webinar option?
Yeah, that appears to be what we showed to 1-10 prior to this, so continuing to show that instead of showing nothing makes sense.
Yes the button isn't dependent on any deal status (is that even available on the frontend?)
Not sure, it's the wonTimestamp in the assignedGuide NVP IIRC. You can take this to Slack and tag someone like Mitch from Sales to understand what's going on here. It's NAB for this PR though as it seems like an implementation detail missed (or there's some other way the Book a call button is removed when the deal is won) with this feature whenever it was added.
| const isChatUsedForOnboarding = isChatUsedForOnboardingReportUtils(report, onboarding, conciergeReportID, onboardingPurposeSelected); | ||
| const shouldShowRegisterForWebinar = | ||
| (introSelected?.companySize === CONST.ONBOARDING_COMPANY_SIZE.MICRO || introSelected?.companySize === CONST.ONBOARDING_COMPANY_SIZE.MICRO_SMALL) && | ||
| (introSelected?.companySize === CONST.ONBOARDING_COMPANY_SIZE.LEGACY_MICRO || introSelected?.companySize === CONST.ONBOARDING_COMPANY_SIZE.MICRO_SMALL) && |
There was a problem hiding this comment.
Bump. It looks to me like the same problem exists here. Aren't we missing at least 1 value?
There was a problem hiding this comment.
MICRO_MEDIUM (5-9) is intentionally excluded because those users get the guide booking button, not the webinar
|
Hey, I noticed you changed If you want to automatically generate translations for other locales, an Expensify employee will have to:
Alternatively, if you are an external contributor, you can run the translation script locally with your own OpenAI API key. To learn more, try running: npx bun ./scripts/generateTranslations.ts --helpTypically, you'd want to translate only what you changed by running |
| .filter((size) => { | ||
| // Always hide the deprecated 1-10 option. | ||
| if (size === CONST.ONBOARDING_COMPANY_SIZE.MICRO) { | ||
| // Always hide deprecated options. |
There was a problem hiding this comment.
Resumed onboarding can continue with no visible selection. BaseOnboardingEmployees hides legacy 5-10 and 11-50 values, but the component initializes its selection from the persisted Onyx value. A user who selected either range before updating sees no selected option, yet can press Continue and submit the hidden legacy value. Clear invalid legacy selections on load (requiring a new selection) or render the persisted legacy selection.
Does this matter? 🤔
There was a problem hiding this comment.
Not really, very specific scenario - looks like it will happen if a user drops after selecting the company size before this is deployed
|
I could not review this diff, so I did not approve the workflow runs. An Expensify employee will review it and approve them manually. |
This reverts commit 1d92a16.
…y-size-ranges # Conflicts: # tests/unit/ReportUtilsTest.ts
|
🚧 flodnv has triggered a test Expensify/App build. You can view the workflow run here. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/flodnv in version: 9.4.91-0 🚀
|
|
🤖 No help site changes are required for this PR, so I didn't create a docs PR. This PR only changes in-app onboarding option labels ( How I verified thisWhat the PR changes
Searches across the help site (all returned nothing)
The only article that mentions the onboarding questionnaire at all is
|
|
🚀 Deployed to production by https://github.com/lakchote in version: 9.4.91-3 🚀
Bundle Size Analysis (Sentry): |
|
🤖 Payment issue created: #101975 |



Explanation of Change
NewDot onboarding used the employee ranges
1-4,5-10, and11-50, while the OldDot homepage splits users at 9 employees.This updates the NewDot options to
1-4,5-9, and10-50. It also updates the stored company-size values, translations, onboarding comments, and existing test descriptions. The deprecated1-10value remains unchanged for saved-data compatibility.Fixed Issues
$ https://github.com/Expensify/Expensify/issues/647670
PROPOSAL:
Tests
1-4,5-9,10-50,51-100,101-1,000, andMore than 1,000 employees.1-9 employeesoption.1-4and5-9.10+ employeesoption.10-50.Offline tests
QA Steps
Same as tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
MacOS: Chrome / Safari