Skip to content

[Hold for Payment] Translation Inconsistency between balance in Settings page & payments page #4448

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

Closed
Santhosh-Sellavel opened this issue Aug 6, 2021 · 29 comments
Assignees
Labels
Engineering External Added to denote the issue can be worked on by a contributor Weekly KSv2

Comments

@Santhosh-Sellavel
Copy link
Collaborator

Santhosh-Sellavel commented Aug 6, 2021

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


https://expensify.slack.com/archives/C01GTK53T8Q/p1628198667040500

Action Performed:

  1. Select preferred language to Español in Settings -> preferences.
  2. In Settings Page Near payments option, we show a balance as $0.00 for English, but in Spanish, we show
    0,00 US$.
    But when we open the payments page, In there we show the balance as $0.00 for both languages.
  3. On Mobile for both pages we show $0.00 for Spanish, without any locale formatting.

Expected Result:

Should be consistent on all pages. @marklouisdeshaun

Actual Result:

Payments page: English
Screenshot 2021-08-06 at 2 46 13 AM

Payments page: Espanol
Screenshot 2021-08-06 at 2 46 33 AM

Settings page balance: English
Screenshot 2021-08-06 at 2 46 02 AM

Settings page balance: Espanol
Screenshot 2021-08-06 at 2 46 26 AM

Workaround:

Can the user still use Expensify without this being fixed? Yes

Platform:

Where is this issue occurring?

  • Web
  • iOS
  • Android
  • Desktop App
  • Mobile Web

Proposal

Based on @marklouisdeshaun inputs. Need to decide where changes need to be done.

Version Number:
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
Expensify/Expensify Issue URL:

View all open jobs on Upwork

@Santhosh-Sellavel Santhosh-Sellavel added AutoAssignerTriage Auto assign issues for triage to an available triage team member Daily KSv2 labels Aug 6, 2021
@MelvinBot
Copy link

Triggered auto assignment to @alexpensify (AutoAssignerTriage), see https://stackoverflow.com/c/expensify/questions/4749 for more details.

@MelvinBot MelvinBot removed the AutoAssignerTriage Auto assign issues for triage to an available triage team member label Aug 6, 2021
@marklouisdeshaun
Copy link
Contributor

This is actually a bit difficult since currency formatting varies by locale and not by language, i.e. among Spanish-speaking countries, the formatting can vary. This means they'll use commas or decimals as separators differently and place the currency symbol or abbreviation either before or after the amount.

For example, in Spain, the currency would be formatted to 1.205,34 € whereas in Mexico it would be $ 1,205.34.

To my knowledge, right now, we are not localizing at a country-specific level. (cc: @iwiznia to confirm)

Here's the formatting for Spanish-speaking countries (reference):
es_GT = Q1,205.34
es_IC = 1.205,34 €
es_AR = $1.205,34
es_PR = $1,205.34
es_NI = C$1,205.34
es_ES = 1.205,34 €
es_PY = ₲ 1.205
es_UY = $ 1.205,34
es_DO = $1,205.34
es_CL = $1.205
es_VE = Bs.1.205,34
es_HN = L1,205.34
es_CO = $1.205
es_PA = B/.1,205.34
es_SV = US$1,205.34
es_CR = ₡1.205
es_PE = S/.1,205.34
es_CU = $1,205.34
es_BO = Bs1.205,34
es_EC = $1.205,34
es_GQ = FCFA1.205
es_MX = $1,205.34

The majority place the currency symbol to the left. There's almost an even split between using commas or decimals as separators for grouping and fractions. 10 comma grouping/decimal fraction (1,205.34) vs 12 decimal grouping/comma fraction (1.205,34).

If we are not locale-specific and need to choose one format and want to go with the majority, then it appears we would need to go with:
currency symbol left
decimal for number groupings
comma for fractions
= $0,00 , $1,23 , $3.500,00 etc.

@Santhosh-Sellavel
Copy link
Collaborator Author

I drafted a PR based on the discussion we had earlier here.

One thing is clear here either the settings page or payment page needs a change. Waiting for confirmation, what needs to be done. I'll put PR on hold for now.

@marklouisdeshaun @iwiznia

@stitesExpensify
Copy link
Contributor

IMO given @marklouisdeshaun post we should just standardize on US formatting ($123,456.78) in both places since the wallet is always in USD for now

@stitesExpensify
Copy link
Contributor

Posting in the slack thread to get more discussion

@alexpensify alexpensify removed their assignment Aug 6, 2021
@alexpensify alexpensify added Engineering Weekly KSv2 and removed Daily KSv2 labels Aug 6, 2021
@MelvinBot
Copy link

Triggered auto assignment to @TomatoToaster (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

@iwiznia
Copy link
Contributor

iwiznia commented Aug 9, 2021

@marklouisdeshaun we only added Spanish (Spain) as a translation and locale, but the library already has configured all the number formatting options for every location in the world.

The fact that the currency is always USD does not mean that the format should always be the one in USA. So, the fix should be to use the locale aware methods to print the amount in both places.

@marklouisdeshaun
Copy link
Contributor

@iwiznia thanks for confirming. So, if we do have the ability to format numbers/dates/currencies at the locale-specific level, then we should definitely do so.

@Santhosh-Sellavel
Copy link
Collaborator Author

Santhosh-Sellavel commented Aug 9, 2021

@TomatoToaster proposed changes are available in #4461. I'll mark PR as ready for review once you say go ahead. Thanks

@TomatoToaster
Copy link
Contributor

Ah sorry, I thought this was already marked for exported. Marking it so the job could be made/proposal can be properly evaluated.

@TomatoToaster TomatoToaster added the External Added to denote the issue can be worked on by a contributor label Aug 10, 2021
@MelvinBot
Copy link

Triggered auto assignment to @dylanexpensify (External), see https://stackoverflow.com/c/expensify/questions/8582 for more details.

@dylanexpensify
Copy link
Contributor

Working on this now

@dylanexpensify
Copy link
Contributor

Upwork job issue: https://www.upwork.com/jobs/~01c99cb1728a0bcc52

@MelvinBot MelvinBot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 11, 2021
@MelvinBot
Copy link

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

@Santhosh-Sellavel
Copy link
Collaborator Author

@dylanexpensify applied for the job.

@Santhosh-Sellavel
Copy link
Collaborator Author

Proposal

Using the locale aware formatter as below,
Screenshot_20210812-023822_GitHub.jpg

es locale formatting was missing in mobile, changes to for that are below,
Screenshot_20210812-023839_GitHub.jpg

@stitesExpensify
Copy link
Contributor

Proposal looks good to me. Feel free to hire away if you haven't already @dylanexpensify !

@dylanexpensify
Copy link
Contributor

dylanexpensify commented Aug 12, 2021

@stitesExpensify sent offer!

@Santhosh-Sellavel
Copy link
Collaborator Author

Thanks, accepted the offer!
Opened a PR is ready for review, #4461
@stitesExpensify @dylanexpensify

@MelvinBot
Copy link

@johnmlee101 Huh... This is 4 days overdue. Who can take care of this?

@Christinadobrzyn Christinadobrzyn removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 17, 2021
@MelvinBot
Copy link

@johnmlee101 Still overdue 6 days?! Let's take care of this!

@Santhosh-Sellavel
Copy link
Collaborator Author

It's not overdue, everything is completed. Yet to close.

@MelvinBot
Copy link

@johnmlee101 Now this issue is 8 days overdue. Are you sure this should be a Daily? Feel free to change it!

@Santhosh-Sellavel
Copy link
Collaborator Author

@dylanexpensify can we close this or update the status?

@dylanexpensify
Copy link
Contributor

Waiting for 7 days after deploy to prod

@dylanexpensify dylanexpensify changed the title Translation Inconsistency between balance in Settings page & payments page [Hold for Payment] Translation Inconsistency between balance in Settings page & payments page Aug 23, 2021
@MelvinBot
Copy link

@johnmlee101 12 days overdue now... This issue's end is nigh!

@MelvinBot MelvinBot removed the Daily KSv2 label Aug 27, 2021
@MelvinBot
Copy link

This issue has not been updated in over 14 days. @johnmlee101 eroding to Weekly issue.

@Santhosh-Sellavel
Copy link
Collaborator Author

@dylanexpensify
We can close this out, as per comment #4461 (comment)

Kindly assign this to me, before closing out!

@arielgreen
Copy link
Contributor

Paid. @Santhosh-Sellavel I also added the bonus you receive for reporting AND fixing the issue to the total.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Engineering External Added to denote the issue can be worked on by a contributor Weekly KSv2
Projects
None yet
Development

No branches or pull requests