Skip to content

[HOLD for payment 2023-11-09] [$500] Settings - Long email address appears differently on the Android & mWeb #30023

Description

@lanitochka17

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: 1.3.87-1

Reproducible in staging?: Yes

Reproducible in production?: Yes

If this was caught during regression testing, add the test name, ID and link from TestRail:

Email or phone of affected tester (no customers):

Logs: https://stackoverflow.com/c/expensify/questions/4856

Expensify/Expensify Issue URL:

Issue reported by: Applause - Internal Team

Slack conversation:

Action Performed:

Pre-condition: Use Long email address account

  1. Launch app
  2. Tap profile icon
  3. Note the way display name is truncated
  4. Go to https://staging.new.expensify.com/
  5. Tap profile icon
  6. Note the way display name is truncated

Expected Result:

An account with a long email address must appear in similar way in both Android & mWeb settings page

Actual Result:

An account with a long email address appears differently on the Android & mWeb settings page. The email address is truncated differently in mweb and Android

Workaround:

Unknown

Platforms:

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

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

Screenshots/Videos

Android: Native

Bug6243491_1697744147669!Screenshot_2023-10-19-18-56-24-885_com expensify chat-edit

Bug6243491_1697744147656!Screenshot_2023-10-19-18-56-56-838_com android chrome-edit

Bug6243491_1697744147661.dis.mp4
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01af2e4c9502542f72
  • Upwork Job ID: 1715099845001293824
  • Last Price Increase: 2023-10-19
  • Automatic offers:
    • jjcoffee | Reviewer | 27326758
    • akinwale | Contributor | 27326759

Activity

  1. added
    ExternalAdded to denote the issue can be worked on by a contributor
    BugSomething is broken. Auto assigns a BugZero manager.
    on Oct 19, 2023
  2. melvin-bot commented on Oct 19, 2023

    @melvin-bot

    Triggered auto assignment to @conorpendergrast (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

  3. changed the title [-]Settings - Long email address appears differently on the Android & mWeb[/-] [+][$500] Settings - Long email address appears differently on the Android & mWeb[/+] on Oct 19, 2023
  4. melvin-bot commented on Oct 19, 2023

    @melvin-bot
  5. melvin-bot commented on Oct 19, 2023

    @melvin-bot

    Bug0 Triage Checklist (Main S/O)

    • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
    • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
      • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
    • This bug is reproducible using the reproduction steps in the OP. S/O
      • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
      • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
    • This issue is filled out as thoroughly and clearly as possible
      • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
    • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync
  6. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Oct 19, 2023
  7. melvin-bot commented on Oct 19, 2023

    @melvin-bot

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

  8. akinwale commented on Oct 19, 2023

    @akinwale
    Contributor

    Proposal

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

    Long email address does not fill up the available width on the profile page on Android native as opposed to mWeb.

    What is the root cause of that problem?

    The Text component which displays the email address or display name in the InitialSetingsPage component does not automatically fill up the available space.

    <PressableWithoutFeedback
    style={[styles.mt1, styles.mw100]}
    onPress={openProfileSettings}
    accessibilityLabel={translate('common.profile')}
    accessibilityRole={CONST.ACCESSIBILITY_ROLE.LINK}
    >
    <Tooltip text={translate('common.profile')}>
    <Text
    style={[styles.textHeadline, styles.pre]}
    numberOfLines={1}
    >
    {props.currentUserPersonalDetails.displayName ? props.currentUserPersonalDetails.displayName : props.formatPhoneNumber(props.session.email)}
    </Text>
    </Tooltip>
    </PressableWithoutFeedback>

    This also happens in the ProfilePage component.

    <Text
    style={[styles.textHeadline, styles.mb6, styles.pre]}
    numberOfLines={1}
    >
    {displayName}
    </Text>

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

    In InitialSettingsPage, add styles.w100 to the PressableWithoutFeedback containing the Text component that shows the display name / email, and add the styles.textAlignCenter style to the Text component to keep the text center-aligned.

    Add the following styles to the Text component in ProfilePage.

    1. styles.w100 to make sure the component expands to fill up the container width
    2. styles.textAlignCenter to keep the text center-aligned.

    What alternative solutions did you explore? (Optional)

    None.

    Screenshot from 2023-10-19 21-55-16

  9. jjcoffee commented on Oct 20, 2023

    @jjcoffee
    Contributor

    @akinwale Thanks for the proposal! LGTM but wondering if you have any insight as to why the behaviour is different on mWeb vs native?

  10. akinwale commented on Oct 20, 2023

    @akinwale
    Contributor

    @akinwale Thanks for the proposal! LGTM but wondering if you have any insight as to why the behaviour is different on mWeb vs native?

    I'm not quite sure why it's happening on Android. There seems to be some sort of aggressive wrapping going on after the + sign in the text on native Android in order to display the ellipsis at the end.

    On Web, a div is used to display the text, which defaults to block display, resulting in the div taking up the full width of its container.

  11. situchan commented on Oct 20, 2023

    @situchan
    Contributor

    Same root cause - #24339

  12. 19 remaining items

  13. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Nov 2, 2023
  14. changed the title [-][$500] Settings - Long email address appears differently on the Android & mWeb[/-] [+][HOLD for payment 2023-11-09] [$500] Settings - Long email address appears differently on the Android & mWeb[/+] on Nov 2, 2023
  15. melvin-bot commented on Nov 2, 2023

    @melvin-bot

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

  16. melvin-bot commented on Nov 2, 2023

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.94-2 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 2023-11-09. 🎊

    After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.

    • External issue reporter
    • Contributor that fixed the issue
    • Contributor+ that helped on the issue and/or PR

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

  17. melvin-bot commented on Nov 2, 2023

    @melvin-bot

    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:

    • [@akinwale / @jjcoffee] The PR that introduced the bug has been identified. Link to the PR:
    • [@akinwale / @jjcoffee] 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:
    • [@akinwale / @jjcoffee] 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:
    • [@akinwale / @jjcoffee] Determine if we should create a regression test for this bug.
    • [@akinwale / @jjcoffee] 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.
    • [@conorpendergrast] Link the GH issue for creating/updating the regression test once above steps have been agreed upon: https://github.com/Expensify/Expensify/issues/334908
  18. jjcoffee commented on Nov 2, 2023

    @jjcoffee
    Contributor
    • The PR that introduced the bug has been identified. Link to the PR: N/A - looks like this style was always missing
    • 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: N/A
    • 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: N/A
    • Determine if we should create a regression test for this bug. Yes
    • 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.

    Regression test proposal

    1. Sign in to an account with a very long email address (e.g. applausetester+areallylongemailsuffix@gmail.com).
    2. Tap the profile icon and verify that the display name is not truncated half-way on Android native.
    3. Open the profile page of any account with the same email address format as in step 1.
    4. Verify that the display name is not truncated half-way on Android native.
      Do we agree 👍 or 👎
  19. conorpendergrast commented on Nov 9, 2023

    @conorpendergrast
    Contributor
  20. conorpendergrast commented on Nov 9, 2023

    @conorpendergrast
    Contributor

    Payouts due:

    Issue Reporter: N/A - Applause

    Eligible for 50% #urgency bonus? No (PR created before the announcement, but not merged within the urgency period)

    Upwork job is here.

  21. conorpendergrast commented on Nov 9, 2023

    @conorpendergrast
    Contributor

    All done, thanks everyone

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions