-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[NoQA] Feat/44307 card system messages #46281
[NoQA] Feat/44307 card system messages #46281
Conversation
@ahmedGaber93 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] |
@ahmedGaber93 , sorry for the ping, you can ignore it, this PR is a part of project. |
@koko57 can you try and fix typescript failure?, let's try to get it approved today 🚀 |
I guess merging main will solve the type failure, lets try that |
@allgandalf I've found a fix for that, will push it in a minute, if running typecheck locally passes |
@koko57 , can you request a review from me please? Not able to keep track of this PR as this is not in my K2 (idk if you have that access) |
@allgandalf no, unfortunately I cannot do that - I don't have access |
@allgandalf fixed |
@koko57 can you remove the QA testing steps and mark this No QA, there will be several cases like new account/ no workspace / free trail expired which will exist as we are testing this hardcoded, don't want the QA to fill up with deploy blocker related to these cases |
src/languages/es.ts
Outdated
@@ -2759,6 +2760,11 @@ export default { | |||
`Si cambias el tipo de límite de esta tarjeta a Límite inteligente, las nuevas transacciones serán rechazadas porque ya se ha alcanzado el límite de ${limit} no aprobado.`, | |||
changeCardMonthlyLimitTypeWarning: (limit: string) => | |||
`Si cambias el tipo de límite de esta tarjeta a Mensual, las nuevas transacciones serán rechazadas porque ya se ha alcanzado el límite de ${limit} mensual.`, | |||
addMailingAddress: 'Añadir dirección postal', |
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.
@@ -2707,6 +2708,11 @@ export default { | |||
`If you change this card's limit type to Smart Limit, new transactions will be declined because the ${limit} unapproved limit has already been reached.`, | |||
changeCardMonthlyLimitTypeWarning: (limit: string) => | |||
`If you change this card's limit type to Monthly, new transactions will be declined because the ${limit} monthly limit has already been reached.`, | |||
addMailingAddress: 'Add mailing address', | |||
issuedCard: (assignee: string) => `issued ${assignee} an Expensify Card! The card will arrive in 2-3 business days.`, |
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.
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 don't have the Admin's name in the message in Figma https://www.figma.com/design/9J4v6CzMVLQbzXMnXC5Izq/%23wave-collect%3A-Workspace-Card-Feeds?node-id=2565-32040&t=p5sUZgAYMIDW3Lsb-0
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.
Odd :) If we are matching with the figma mocks, I'm okay with the current state, thanks for mentioning
addMailingAddress: 'Add mailing address', | ||
issuedCard: (assignee: string) => `issued ${assignee} an Expensify Card! The card will arrive in 2-3 business days.`, | ||
issuedCardNoMailingAddress: (assignee: string) => `issued ${assignee} an Expensify Card! The card will be shipped once a mailing address is added.`, | ||
issuedCardVirtual: ({assignee, link}: IssueVirtualCardParams) => `issued ${assignee} a virtual ${link}! The card can be used right away.`, |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
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.
Okay i ready the convo #44307 (comment), I'll mark this as resolved
issuedCard: (assignee: string) => `issued ${assignee} an Expensify Card! The card will arrive in 2-3 business days.`, | ||
issuedCardNoMailingAddress: (assignee: string) => `issued ${assignee} an Expensify Card! The card will be shipped once a mailing address is added.`, | ||
issuedCardVirtual: ({assignee, link}: IssueVirtualCardParams) => `issued ${assignee} a virtual ${link}! The card can be used right away.`, | ||
addedAddress: (assignee: string) => `${assignee} added the address. Expensify Card will arrive in 2-3 business days.`, |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
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.
Okay i ready the convo #44307 (comment), I'll mark this as resolved
@@ -2707,6 +2708,11 @@ export default { | |||
`If you change this card's limit type to Smart Limit, new transactions will be declined because the ${limit} unapproved limit has already been reached.`, | |||
changeCardMonthlyLimitTypeWarning: (limit: string) => | |||
`If you change this card's limit type to Monthly, new transactions will be declined because the ${limit} monthly limit has already been reached.`, | |||
addMailingAddress: 'Add mailing address', | |||
issuedCard: (assignee: string) => `issued ${assignee} an Expensify Card! The card will arrive in 2-3 business days.`, | |||
issuedCardNoMailingAddress: (assignee: string) => `issued ${assignee} an Expensify Card! The card will be shipped once a mailing address is added.`, |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
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.
Okay i ready the convo #44307 (comment), I'll mark this as resolved
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.
The changes suggested above are majorly about the text and not related to functionality, so I will start with the testing, but will approve after the comments are addressed
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2024-07-29.at.4.59.06.PM.mov |
At the moment, we can type the hardcoded words Screen.Recording.2024-07-29.at.3.35.50.PM.mov |
@allgandalf no, for now you can type in any chat - I don't wanted to add unnecessary extra logic that will be removed later |
Works for me thanks 👍 |
case CONST.REPORT.ACTIONS.TYPE.CARD_MISSING_ADDRESS: | ||
return translate(`workspace.expensifyCard.${noMailingAddress ? 'issuedCardNoMailingAddress' : 'addedAddress'}`, assignee); |
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.
Bug
Wrong system message for CARD_MISSING_ADDRESS
it says the card will be delivered in few days instead of missing address message c.c @koko57
Screen.Recording.2024-07-29.at.4.25.24.PM.mov
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.
That's because you have your address added - if you wouldn't have it a proper message with button to add an address would be displayed. After you add the address it is displayed like this - that's why I added two additional cases to test regardless you have it added or not
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.
You can try to log into a new account that doesn't have address added to test it
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.
let me give it a try
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.
This occurs with new accounts as well:
Screen.Recording.2024-07-29.at.4.32.02.PM.mov
IMO noMailingAddress
is always returning false here. can you please take a look
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.
@allgandalf fixed! I forgot that I changed action?.originalMessage.html
for action?.actionName
(the proper condition). I added an extra check that will be removed later
@allgandalf without it it opens in a new tab. We also have it implemented this way in |
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.
This looks good to go into staging, we have only implemented the skeleton in here, still waiting for BE
implementation for integration. thanks for addressing the issues @koko57 !
Good start to the week!
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.
Nice, thanks!
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/mountiny in version: 9.0.15-0 🚀
|
🚀 Deployed to production by https://github.com/roryabraham in version: 9.0.15-9 🚀
|
Details
To test UI I've implemented a bit hacky ;) way to test - you need to type a certain message to see the report action you want. CARDISSUED, CARDISSUEDVIRTUAL, CARDMISSINGADDRESS are the actual action names that will be handled, I also added two more for testing convenience NOMAILINGADDRESS and ADDRESSADDED - they will work regardless you have your mailing address added or not.
Fixed Issues
$ #44307
PROPOSAL: -
Tests
note: for now the mention will be green as your profile is mentioned
Offline tests
QA Steps
n/a
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)/** comment above it */
this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
Simulator.Screen.Recording.-.iPhone.15.Pro.-.2024-07-26.at.14.09.06.mp4
iOS: mWeb Safari
Simulator.Screen.Recording.-.iPhone.15.Pro.-.2024-07-26.at.14.10.31.mp4
MacOS: Chrome / Safari
Screen.Recording.2024-07-26.at.13.46.44.mp4
MacOS: Desktop
Screen.Recording.2024-07-26.at.14.06.44.mp4