Skip to content

[HOLD for payment 2023-06-05] [$1000] Remove checkbox from Money request header #19332

Closed

Description

@kavimuru

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


Action Performed:

  1. Login with any account, go any request money report.
  2. Hover the header title.
  3. Notice a checkbox shows on the right side of the component

Expected Result:

No checkbox should appear

Actual Result:

A checkbox appears

Workaround:

Can the user still use Expensify without this being fixed? Have you informed them of the workaround?

Platforms:

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

  • Android / native
  • Android / Chrome
  • iOS / native
  • iOS / Safari
  • MacOS / Chrome / Safari
  • MacOS / Desktop

Version Number: 1.3.16-5
Reproducible in staging?: y
Reproducible in production?: y
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
Notes/Photos/Videos: Any additional supporting documentation

Screen.Recording.2023-05-17.at.17.14.38.mov
Recording.671.mp4

Expensify/Expensify Issue URL:
Issue reported by: @hungvu193
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1684318740704459

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0199442829f9113a36
  • Upwork Job ID: 1660914295792259072
  • Last Price Increase: 2023-05-23

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on May 19, 2023
  2. melvin-bot commented on May 19, 2023

    @melvin-bot

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

  3. melvin-bot commented on May 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
  4. PrashantMangukiya commented on May 20, 2023

    @PrashantMangukiya
    Contributor

    Proposal

    Posting proposal early as per new guidelines

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

    Money request header title has I beam cursor instead of pointer while hovering.

    What is the root cause of that problem?

    Money request header rendered via src/components/MoneyRequestHeader.js component. It consist two rows i.e. Requester and Payee.

    1. So requestor rows rendered via <HeaderWithCloseButton> at line 91

    <HeaderWithCloseButton

    Eventually HeaderWithCloseButton will render AvatarWithDisplayName via this:

    <AvatarWithDisplayName
    report={this.props.report}
    policies={this.props.policies}
    personalDetails={this.props.personalDetails}
    />

    AvatarWithDisplayName.js will render DisplayNames via this code:

    <DisplayNames
    fullTitle={title}
    displayNamesWithTooltips={displayNamesWithTooltips}
    tooltipEnabled
    numberOfLines={1}
    textStyles={[styles.headerText, styles.pre]}
    shouldUseFullTitle={isExpenseReport}
    />

    We can see at line 82 we are passing text styles without cursor style, So it is display I beam cursor due text being selectable by nature.

    2. Payee render from MoneyRequestHeader.js via this code:

    <Text
    style={[styles.headerText, styles.pre]}
    numberOfLines={1}
    >
    {payeeName}
    </Text>

    We can see at line 121 we are passing text styles without cursor style, So it display I beam cursor. So this is the root cause of the problem for both places.

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

    To solve this we have to set default cursor style at two place.
    i.e. Within AvatarWithDisplayName.js we have to set styles.cursorDefault style at line 82 as shown in code below.

    <DisplayNames 
       ...
       // textStyles={[styles.headerText, styles.pre]}   // *** Old  ***
       textStyles={[styles.headerText, styles.pre, styles.cursorDefault]} // *** Updated  ***
       ...
    /> 

    Within MoneyRequestHeader.js we have to set styles.cursorDefault style at line 121 as shown in code below.

     <Text 
         // style={[styles.headerText, styles.pre]}   // *** Old ***
         style={[styles.headerText, styles.pre, styles.cursorDefault]}  // *** Updated ***
         ...
     > 
         {payeeName} 
     </Text> 

    So it will solve the issue and shows default cursor for both Requester and Payee as shown in result video.

    Important: We can not set pointer cursor because there is not any action on click of the text. So we have to use default cursor.

    Proposal to Set Checkmark and Settled text

    Within MoneyRequestHeader.js set iou amount description conditionally and pass descriptionRightIcon prop as shown below at line 179 here.

    <MenuItemWithTopDescription
      title={formattedTransactionAmount}
      // description={`${props.translate('iou.amount')} • ${props.translate('iou.cash')}`}   // *** Old Code ***
      description={`${props.translate('iou.amount')} • ${props.translate('iou.cash')}${isSettled ? ` • ${props.translate('iou.settledExpensify')}` : ''}`}   // *** Updated Code ***
      descriptionRightIcon={isSettled ? Expensicons.Checkmark : false}   // *** Add this prop
      ....
    />

    We have remove old checkmark icon from code block here.

    Then we have to update this code as shown below:

    <View style={[styles.flexRow, styles.alignItemsCenter]}>
        {Boolean(props.title) && (
            <Text
                style={titleTextStyle}
                numberOfLines={1}
            >
                {convertToLTR(props.title)}
            </Text>
        )}
        {Boolean(props.descriptionRightIcon) && (
            <View style={[styles.ml2]}>
                <Icon
                    src={props.descriptionRightIcon}
                    fill={themeColors.iconSuccessFill}
                />
            </View>
        )}
    </View>

    So this will show the checkmark icon at right side of the amount and show Settled within text as shown in result below:

    Results Settled-Checkmark Unsetled

    What alternative solutions did you explore? (Optional)

    None.

    Results
    DefaultCursor.mp4
  5. daraksha-dk commented on May 20, 2023

    @daraksha-dk
    Contributor

    Proposal

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

    Money request header title has I beam cursor instead of pointer while hovering.

    What is the root cause of that problem?

    If the items in the header are not intended to be clickable, then there may not be an issue to fix. But if we plan to make any of the items clickable then the root cause of this issue is not defining pointer styles for those items.
    Additionally, there seems to be an inconsistency with the use of tooltips in both the Money Request and Task headers that should be addressed and made consistent.

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

    To fix these issues, we need to first confirm if any of these header items are going to be clickable in future.
    If so, we should apply styles.cursorpointer to corresponding items and leave other items as they are, since we already use I-beam cursors for text all over the app. cc: @shawnborton

    Few examples
    Screen.Recording.2023-05-20.at.6.46.11.PM.mov

    Also, we need to define Tooltips for all header items or follow the design team's suggestion.

    This is the current scenario:

    For Money Request Page

    • In first row
      - Avatar has default cursor and no tooltip
      - Name has I-Beam cursor and tooltip is present

    • In 2nd row
      - Avatar has default cursor and no tooltip
      - Name has I-Beam cursor and no tooltip

      money-request-page.mov

    For Task Pages

    • In first row
      - Avatar and Name both have default cursor and no tooltips

    • In 2nd row
      - Avatar and Name both have pointer cursor and no tooltips (it's clickable)

      task-page.mov

    We will be making these changes in HeaderView.js, HeaderViewWithCloseButton.js, MoneyRequestHeader.js, TaskHeader.js, AvatarWithDisplayName.js etc

    What alternative solutions did you explore? (Optional)

    We can also go with default cursors and consistent tooltips

  6. shawnborton commented on May 22, 2023

    @shawnborton
    Contributor

    Hmm why does the To field have a checkmark here? cc @JmillsExpensify @trjExpensify

    But I think this isn't really a bug if you can't actually click the header title to navigate anywhere, then no need for a pointer mouse.

  7. trjExpensify commented on May 22, 2023

    @trjExpensify
    Contributor

    Hmm why does the To field have a checkmark here? cc @JmillsExpensify @trjExpensify

    I think I'm blinded by EC3, can you link me to the vid showing that? 😅

    I agree it shouldn't have a pointer mouse if it's not clickable, and I don't think we have any immediate plans to add some kind of "room details" for a expense/iouReport.

  8. daraksha-dk commented on May 22, 2023

    @daraksha-dk
    Contributor

    @trjExpensify I think @shawnborton is referring to the first video here

  9. trjExpensify commented on May 22, 2023

    @trjExpensify
    Contributor

    Ah, I see it now. Yes, that's an error. The transaction view once settled should look like this:

    image

    @mountiny @luacmartins @Julesssss - I've been out of the loop at EC3 for a couple of days, is this fix up somewhere else?

  10. self-assigned this
    on May 22, 2023
  11. Julesssss commented on May 22, 2023

    @Julesssss
    Contributor

    is this fix up somewhere else?

    Not as far as I'm aware. Given that it's minor we can probably sneak the fix into this issue/proposal

  12. 30 remaining items

  13. changed the title [-][$1000] Remove checkbox from Money request header[/-] [+][HOLD for payment 2023-06-05] [$1000] Remove checkbox from Money request header[/+] on May 29, 2023
  14. melvin-bot commented on May 29, 2023

    @melvin-bot

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

  15. melvin-bot commented on May 29, 2023

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.19-7 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-06-05. 🎊

    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.

    As a reminder, here are the bonuses/penalties that should be applied for any External issue:

    • Merged PR within 3 business days of assignment - 50% bonus
    • Merged PR more than 9 business days after assignment - 50% penalty
  16. melvin-bot commented on May 29, 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:

    • [@aimane-chnaif] The PR that introduced the bug has been identified. Link to the PR:
    • [@aimane-chnaif] 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:
    • [@aimane-chnaif] 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:
    • [@aimane-chnaif] Determine if we should create a regression test for this bug.
    • [@aimane-chnaif] 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.
    • [@tjferriss] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
  17. PrashantMangukiya commented on Jun 7, 2023

    @PrashantMangukiya
    Contributor

    Ping for Upwork.

  18. tjferriss commented on Jun 7, 2023

    @tjferriss
    Contributor

    Sorry for the delay. All offers have been sent via Upworks and I'll process payment as they're accepted. @PrashantMangukiya and @aimane-chnaif will get the 50% speed bonus.

    @aimane-chnaif can you please help out with the checklist?

  19. PrashantMangukiya commented on Jun 7, 2023

    @PrashantMangukiya
    Contributor

    @tjferriss Offer accepted. Thank you.

  20. aimane-chnaif commented on Jun 8, 2023

    @aimane-chnaif
    Contributor

    can you please help out with the checklist?

    This is not a bug but feature.
    Regression tests will be updated more broadly for the manual requests redesign.
    So all items can be checked off.

  21. tjferriss commented on Jun 9, 2023

    @tjferriss
    Contributor

    All the payments have been sent.

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