Skip to content
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

[HOLD for payment 2024-10-17] [HOLD for payment 2024-10-16] Invoices - Balance is cut off when device font size is small #50374

Open
2 of 6 tasks
IuliiaHerets opened this issue Oct 8, 2024 · 22 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 Engineering Overdue

Comments

@IuliiaHerets
Copy link

IuliiaHerets commented Oct 8, 2024

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.46-1
Reproducible in staging?: Y
Reproducible in production?: N/A - new feature, doesn't exist in prod
Issue was found when executing this PR: #46813
Email or phone of affected tester (no customers): applausetester+kh051001@applause.expensifail.com
Issue reported by: Applause Internal Team

Action Performed:

Precondition:

  • Device font size should be small (depending on the screen size, might need to adjust font size to the smaller size).
  1. Launch New Expensify app.
  2. Go to workspace settings.
  3. Go to Invoices.

Expected Result:

The balance will not be cut off.

Actual Result:

The balance is cut off.

Workaround:

Unknown

Platforms:

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Bug6627975_1728363622395.invoice.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @stephanieelliott
@IuliiaHerets IuliiaHerets added DeployBlockerCash This issue or pull request should block deployment Bug Something is broken. Auto assigns a BugZero manager. labels Oct 8, 2024
Copy link

melvin-bot bot commented Oct 8, 2024

Triggered auto assignment to @mjasikowski (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

Copy link

melvin-bot bot commented Oct 8, 2024

Triggered auto assignment to @stephanieelliott (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.

@melvin-bot melvin-bot bot added the Daily KSv2 label Oct 8, 2024
@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Oct 8, 2024
Copy link
Contributor

github-actions bot commented Oct 8, 2024

👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

  1. Identify the pull request that introduced this issue and revert it.
  2. Find someone who can quickly fix the issue.
  3. Fix the issue yourself.

@IuliiaHerets
Copy link
Author

We think that this bug might be related to #vip-bills

@abzokhattab
Copy link
Contributor

Proposal

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

When the device font size is small, the balance on invoices appears cut off.

What is the root cause of that problem?

The issue is due to the use of a static font size in the balance component, specifically styles.textXXXLarge:

return <Text style={[styles.textHeadline, styles.textXXXLarge, textStyles]}>{formattedBalance}</Text>;

App/src/styles/index.ts

Lines 451 to 453 in 672a937

textXXXLarge: {
fontSize: variables.fontSizeXXXLarge,
},

fontSizeXXXLarge: 32,
The textHeadline style within the balance component adjusts line height based on screen scale, which in our caseresults in the line height becoming smaller than the font size, causing the text to look cut off.
lineHeight: variables.lineHeightXXXLarge,

lineHeightXXXLarge: getValueUsingPixelRatio(32, 37),

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

We should modify the fontSizeXXXLarge to utilize getValueUsingPixelRatio, as demonstrated here:

lineHeightXXXLarge: getValueUsingPixelRatio(32, 37),

Result image

What alternative solutions did you explore? (Optional)

We could override the line height to remain at a constant 32 across all cases.

To implement this, we could initialize a new variable lineHeightFixedLarge:32 and override the height by placing it at the end of the style array

Result image

@mjasikowski
Copy link
Contributor

Checking

@mjasikowski
Copy link
Contributor

#46813 this PR introduces the invoice balance view and is a part of this deployment

@madmax330
Copy link
Contributor

@rezkiy37 can you take a look?

@rezkiy37
Copy link
Contributor

rezkiy37 commented Oct 8, 2024

Hi, I am Michael (Mykhailo) from Callstack, an expert agency and I can work on this issue. I am the author of this PR (#46813).

@allroundexperts
Copy link
Contributor

@mjasikowski Can you please assign me this issue since I reviewed the PR? Thanks!

@mjasikowski
Copy link
Contributor

@allroundexperts done

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Oct 9, 2024
@melvin-bot melvin-bot bot changed the title Invoices - Balance is cut off when device font size is small [HOLD for payment 2024-10-16] Invoices - Balance is cut off when device font size is small Oct 9, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Oct 9, 2024
Copy link

melvin-bot bot commented Oct 9, 2024

Reviewing label has been removed, please complete the "BugZero Checklist".

Copy link

melvin-bot bot commented Oct 9, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.46-5 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2024-10-16. 🎊

For reference, here are some details about the assignees on this issue:

Copy link

melvin-bot bot commented Oct 9, 2024

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@allroundexperts] The PR that introduced the bug has been identified. Link to the PR:
  • [@allroundexperts] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
  • [@allroundexperts] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
  • [@allroundexperts] Determine if we should create a regression test for this bug.
  • [@allroundexperts] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
  • [@stephanieelliott] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@thienlnam thienlnam removed the DeployBlockerCash This issue or pull request should block deployment label Oct 9, 2024
@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Oct 10, 2024
@melvin-bot melvin-bot bot changed the title [HOLD for payment 2024-10-16] Invoices - Balance is cut off when device font size is small [HOLD for payment 2024-10-17] [HOLD for payment 2024-10-16] Invoices - Balance is cut off when device font size is small Oct 10, 2024
Copy link

melvin-bot bot commented Oct 10, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.47-4 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2024-10-17. 🎊

For reference, here are some details about the assignees on this issue:

Copy link

melvin-bot bot commented Oct 10, 2024

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@allroundexperts] The PR that introduced the bug has been identified. Link to the PR:
  • [@allroundexperts] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
  • [@allroundexperts] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
  • [@allroundexperts] Determine if we should create a regression test for this bug.
  • [@allroundexperts] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
  • [@stephanieelliott] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@stephanieelliott
Copy link
Contributor

Hey @allroundexperts can you complete the BZ checklist when you get a sec?

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Oct 16, 2024
Copy link

melvin-bot bot commented Oct 17, 2024

Payment Summary

Upwork Job

BugZero Checklist (@stephanieelliott)

  • I have verified the correct assignees and roles are listed above and updated the neccesary manual offers
  • I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants//hired)
  • I have paid out the Upwork contracts or cancelled the ones that are incorrect
  • I have verified the payment summary above is correct

@allroundexperts
Copy link
Contributor

allroundexperts commented Oct 20, 2024

Checklist

  1. Invoicing balance section #46813
  2. The author is aware of this, and fixed the issue himself in this PR.
  3. N/A
  4. A regression test would be helpful.

Regression test

  1. Set the device font size to be small.
  2. Launch New Expensify app.
  3. Go to workspace settings.
  4. Go to Invoices.

Verify that the balance amount is displayed correctly.

Do we 👍 or 👎 ?

@melvin-bot melvin-bot bot added the Overdue label Oct 20, 2024
@mjasikowski
Copy link
Contributor

@allroundexperts I would change "Verify that the balance will not be cut off." to "verify the balance amount is displayed correctly". Otherwise seems fine.

@allroundexperts
Copy link
Contributor

@mjasikowski Updated!

Copy link

melvin-bot bot commented Oct 21, 2024

@mjasikowski, @allroundexperts, @stephanieelliott, @rezkiy37 Eep! 4 days overdue now. Issues have feelings too...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 Engineering Overdue
Projects
Status: No status
Development

No branches or pull requests

8 participants