Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.4k stars 2.79k forks source link

[$50] Payment - "Payment Complete" is not in Spanish. #49840

Open lanitochka17 opened 5 days ago

lanitochka17 commented 5 days ago

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 9.0.40-4 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: N/A Email or phone of affected tester (no customers): gibethlehem@gmail.com Issue reported by: Applause - Internal Team

Action Performed:

  1. Login in any account
  2. Change The language preference to Spanish
  3. Go to workspace chat
  4. Submit an expense
  5. Click Pay elsewhere button in the expense preview on the main chat

Expected Result:

"Payment completed" should be in Spanish

Actual Result:

It shows "Payment completed" animation. "Payment completed" is not changed to Spanish

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

Screenshots/Videos

Add any screenshot/video evidence

https://github.com/user-attachments/assets/ad22368e-314b-4b15-844a-d5269e3b1278

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021839725639165419380
  • Upwork Job ID: 1839725639165419380
  • Last Price Increase: 2024-09-30
  • Automatic offers:
    • Nodebrute | Contributor | 104193255
Issue OwnerCurrent Issue Owner: @getusha
melvin-bot[bot] commented 5 days ago

Triggered auto assignment to @alexpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

Nodebrute commented 5 days ago

Proposal

Please re-state the problem that we are trying to solve in this issue.

"Payment Complete" is not in Spanish.

What is the root cause of that problem?

We are not using a en.ts/es.ts variable here https://github.com/Expensify/App/blob/05ca35c015b268e495fe94eff36c9eda7afb78bc/src/components/SettlementButton/AnimatedSettlementButton.tsx#L80

What changes do you think we should make in order to solve the problem?

We should create a variable in both en.ts/es.ts files and use it here instead of payment complete https://github.com/Expensify/App/blob/05ca35c015b268e495fe94eff36c9eda7afb78bc/src/components/SettlementButton/AnimatedSettlementButton.tsx#L80

In es.ts file we'll use Spanish translation of payment complete

Optional: we can use payment completed instead of payment complete

What alternative solutions did you explore? (Optional)

Wr can check in both en.ts/es.ts files if we already have a variable for this then we can use it here https://github.com/Expensify/App/blob/05ca35c015b268e495fe94eff36c9eda7afb78bc/src/components/SettlementButton/AnimatedSettlementButton.tsx#L80

Bakhtiar85 commented 5 days ago

Proposal

Please re-state the problem that we are trying to solve in this issue.

The current issue is that the "Payment complete" text displayed after completing a payment in the workspace chat is not translated to Spanish, despite the user's language preference being set to Spanish.

What is the root cause of that problem?

The root cause of the issue is that the text "Payment complete" is hardcoded in the component AnimatedSettlementButton.tsx at line 80. Instead of using translation keys from en.ts and es.ts files, it directly displays the English text.

What changes do you think we should make in order to solve the problem?

We should refactor the code to replace the hardcoded "Payment complete" text with a variable that pulls the translation from the language files (en.ts for English and es.ts for Spanish).

Steps:

  1. Add a translation key for "Payment complete" in both en.ts and es.ts.
    • In en.ts, we will add something like: paymentComplete: 'Payment complete'.
    • In es.ts, we will add: paymentComplete: 'Pago completado' (which means "Payment completed" in Spanish).
  2. Modify the code in AnimatedSettlementButton.tsx to use the variable instead of the hardcoded text:

    
    <Text style={[styles.buttonMediumText]}>{translate('paymentComplete')}</Text>
melvin-bot[bot] commented 5 days ago

πŸ“£ @Bakhtiar85! πŸ“£ Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork. Please follow these steps:

  1. Make sure you've read and understood the contributing guidelines.
  2. Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
  3. Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
  4. Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details. Screen Shot 2022-11-16 at 4 42 54 PM Format:
    Contributor details
    Your Expensify account email: <REPLACE EMAIL HERE>
    Upwork Profile Link: <REPLACE LINK HERE>
Bakhtiar85 commented 5 days ago

Contributor details Your Expensify account email: makhdoomabubakar85@gmail.com Upwork Profile Link: https://www.upwork.com/freelancers/~017304c8ed7eb17c49

melvin-bot[bot] commented 5 days ago

βœ… Contributor details stored successfully. Thank you for contributing to Expensify!

melvin-bot[bot] commented 5 days ago

Job added to Upwork: https://www.upwork.com/jobs/~021839725639165419380

melvin-bot[bot] commented 5 days ago

Triggered auto assignment to Contributor-plus team member for initial proposal review - @getusha (External)

alexpensify commented 5 days ago

@getusha when you get a chance, can you please review if one of these proposals will fix this issue? Thanks!

ChavdaSachin commented 4 days ago

Proposal

Please re-state the problem that we are trying to solve in this issue.

What is the root cause of that problem?

Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.

getusha commented 3 days ago

@Nodebrute's proposal looks good to me. πŸŽ€ πŸ‘€ πŸŽ€ C+ Reviewed

melvin-bot[bot] commented 3 days ago

Triggered auto assignment to @flodnv, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

getusha commented 3 days ago

@flodnv we can adjust the price, as this is a relatively minor and straightforward change.

melvin-bot[bot] commented 2 days ago

Upwork job price has been updated to $50

melvin-bot[bot] commented 2 days ago

πŸ“£ @Nodebrute πŸŽ‰ An offer has been automatically sent to your Upwork account for the Contributor role πŸŽ‰ Thanks for contributing to the Expensify app!

Offer link Upwork job Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review πŸ§‘β€πŸ’» Keep in mind: Code of Conduct | Contributing πŸ“–

Nodebrute commented 2 days ago

PR will be ready in few hours