feat: improve expiration date input format by auto-inserting slash after month#65079
Conversation
This comment was marked as resolved.
This comment was marked as resolved.
|
@samranahm Also, it would be great if you could add some automated tests for the table of test cases, as this is a perfect case where automated tests can work a lot more efficiently than human testers! |
This comment was marked as resolved.
This comment was marked as resolved.
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppN/A - payment can't be updated on native Android: mWeb Chromeandroid-chrome-2025-06-28_19.15.08.mp4iOS: HybridAppN/A - payment can't be updated on native iOS: mWeb Safariios-safari-2025-06-28_18.33.04.mp4MacOS: Chrome / Safaridesktop-chrome-2025-06-28_18.18.11.mp4MacOS: Desktopdesktop-app-2025-06-28_18.22.54.mp4 |
@jjcoffee Add payment card feature isn't available on Native devices, that's why I skip them. |
This comment was marked as resolved.
This comment was marked as resolved.
|
@samranahm Did you check for any other date fields where we can apply this fix? |
When we directly pasts a value equal or greater then 5 digits |
|
Hey @jjcoffee, added the unit test, let me know what you think! |
|
@jjcoffee gentle bump |
|
@samranahm Oh sorry, I missed the notifications for this! I will get back to this next week. |
|
@MonilBhavsar friendly bump |
|
@samranahm Looks like he's away until Monday. |
|
Alright 🙌 |
Yes, I was. Looking now... |
Co-authored-by: Monil Bhavsar <monilbhavsar25@gmail.com>
MonilBhavsar
left a comment
There was a problem hiding this comment.
Thanks for addressing changes. Let us know when it's ready for re-review
|
@MonilBhavsar All yours — please re-review and let me know if you think any further improvements are needed. Thank you |
MonilBhavsar
left a comment
There was a problem hiding this comment.
Nice work. Looking good and works well!
|
🚀 Deployed to staging by https://github.com/MonilBhavsar in version: 9.1.81-0 🚀
|
|
🚀 Deployed to production by https://github.com/luacmartins in version: 9.1.81-7 🚀
|
Explanation of Change
This PR introduce a feature to automatically format the Expiration date of payment card by inserting
/after the month.Fixed Issues
$ #64608
PROPOSAL: #64608 (comment)
Tests
Offline tests
QA Steps
Same as test section
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
N/A
Android: mWeb Chrome
Android.mWeb.chrome.mp4
iOS: Native
N/A
iOS: mWeb Safari
IOS.mWeb.safari.mp4
MacOS: Chrome / Safari
macOS.chrome.mp4
MacOS: Desktop
macOS.desktop.mp4