Repository navigation
Localize the ordinal long date - #105864
Conversation
Switch CONST.DATE.MONTH_DAY_YEAR_ORDINAL_FORMAT to date-fns' localized PPP token so other languages use their own component order. English output is unchanged because en-US's PPP already carries the ordinal day.
Parse the subscription end date with parseISO so the yyyy-MM-dd value is read as a local calendar day instead of UTC midnight, which showed the previous day in timezones behind UTC. Add the renewal date test from Expensify#105846.
|
@linhvovan29546 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] |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: mWeb Safari |
A date-only snapshot start is a calendar boundary, so format it directly instead of converting device-local midnight into the user's timezone, which showed the previous day for timezones behind the device's. UTC datetimes still convert into the user's timezone.
garrettmknight
left a comment
There was a problem hiding this comment.
Looks good from a product perspective.
|
@shubham1206agra conflicts |
|
@roryabraham Resolved |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚧 roryabraham has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/roryabraham in version: 9.5.35-0 🚀
|
|
No FullStory changes needed — this PR only fixes date localization and timezone-related day shifts in existing renewal and violation snapshot displays, without adding new screens, interactions, or user data. |
|
No help site update needed — this PR fixes date localization and incorrect day shifts in existing displays, restoring expected behavior without adding a workflow or making existing article text incorrect. |
|
Hi @shubham1206agra. QA team doesn't see any auto-renewal date displayed under Workspaces > Overview > Plan type. Is there a specific account QA should use for this test, or could you please advise how to proceed? cc @roryabraham @garrettmknight @linhvovan29546 bandicam.2026-11-10.11-39-35-234.mp4 |
|
🚀 Deployed to production by https://github.com/yuwenmemon in version: 9.5.35-3 🚀
Bundle Size Analysis (Sentry): |




Explanation of Change
CONST.DATE.MONTH_DAY_YEAR_ORDINAL_FORMATwas the hand-written date-fns patternMMMM do, yyyy. The pattern fixes the US component order, so other languages showed their own month name in an English shape, for exampleJuni 20., 2026in German.It now uses date-fns' localized long date token
PPP. In EnglishPPPalready includes the ordinal day, so English output does not change:This constant is used in two places: the auto-renewal date on the workspace plan type page, and the violation snapshot start date in the empty Search view.
This is one of a set of small, independent PRs that split up the date-localization work in #105846. They can merge in any order.
Update: renewal day-shift fix
This PR now also fixes the annual renewal date on the workspace plan type page.
privateSubscription.endDateis ayyyy-MM-ddvalue, and passing the string straight toformatread it as UTC midnight, so the page showed the previous day in timezones behind UTC. It is now parsed withparseISO, which reads it as a local calendar day. This fix comes from #105846. I verified it by runningtests/ui/WorkspacePlanRenewalDateTest.tsxwithTZ=America/Los_Angeles: it fails without the fix and passes with it. CI runs in UTC, so the test there only checks the German order.Update: violation snapshot day-shift fix
This PR now also includes the fix from #105872, which is closed in favor of this PR since both change how
MONTH_DAY_YEAR_ORDINAL_FORMATdates are shown.formatViolationSnapshotStartedAtDateread a date-only snapshot (yyyy-MM-dd) as the device's local midnight and then moved that instant into the user's timezone, so a user whose timezone is behind the device's saw the previous day. A date-only value is a calendar day, so it is now formatted as is; datetime values are still shown in the user's timezone. The newDateUtilsTestcase forAmerica/New_Yorkfails without the fix in CI's UTC runner.Fixed Issues
$ #98088
PROPOSAL:
Tests
20. Juni 2026.June 20th, 2026, the same as before.Offline tests
Same as tests. Formatting is local and does not depend on the network.
QA Steps
Same as tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)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
Screen.Recording.2026-11-05.at.12.13.01.PM.mov