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 2023-05-09] [$1000] Chat - Password protected PDF file doesn't look correct in view mode #15896

Closed
4 of 6 tasks
kbecciv opened this issue Mar 13, 2023 · 42 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 External Added to denote the issue can be worked on by a contributor

Comments

@kbecciv
Copy link

kbecciv commented Mar 13, 2023

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. Go to URL https://staging.new.expensify.com/
    or launch the app
  2. Login with any account
  3. Navigate to any conversation
  4. Send password protected PDF file
  5. Send another file into the same chat
  6. Click on it
  7. Tap "Enter the password"

Expected Result:

Text should not be covered by arrow buttons.

Actual Result:

Arrows buttons overlaps the text and "Confirm" button

Workaround:

Unknown

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.2.83.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

Notes/Photos/Videos: Any additional supporting documentation

Bug5975951_Screen_Recording_20230313_181013_Chrome.mp4

Expensify/Expensify Issue URL:

Issue reported by: Applause - Internal Team

Slack conversation:

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~016158f319cae83fe0
  • Upwork Job ID: 1638202017946087424
  • Last Price Increase: 2023-03-31
@kbecciv kbecciv added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Mar 13, 2023
@MelvinBot
Copy link

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

@melvin-bot melvin-bot bot locked and limited conversation to collaborators Mar 13, 2023
@MelvinBot
Copy link

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

@melvin-bot melvin-bot bot added the Overdue label Mar 15, 2023
@MelvinBot
Copy link

@kevinksullivan Whoops! This issue is 2 days overdue. Let's get this updated quick!

@MelvinBot
Copy link

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

@kevinksullivan
Copy link
Contributor

Looks like this only occurs when there are multiple files to switch between. Updating the OP and making external.

RPReplay_Final1679412718.MP4

@melvin-bot melvin-bot bot removed the Overdue label Mar 21, 2023
@kevinksullivan kevinksullivan added the External Added to denote the issue can be worked on by a contributor label Mar 21, 2023
@melvin-bot melvin-bot bot unlocked this conversation Mar 21, 2023
@kevinksullivan kevinksullivan added the Help Wanted Apply this label when an issue is open to proposals by contributors label Mar 21, 2023
@melvin-bot melvin-bot bot changed the title Chat - Password protected PDF file doesn't look correct in view mode [$1000] Chat - Password protected PDF file doesn't look correct in view mode Mar 21, 2023
@MelvinBot
Copy link

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

@MelvinBot
Copy link

Current assignee @kevinksullivan is eligible for the External assigner, not assigning anyone new.

@MelvinBot
Copy link

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

@MelvinBot
Copy link

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

@tienifr
Copy link
Contributor

tienifr commented Mar 21, 2023

Proposal

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

Arrows buttons overlaps the text and Confirm button

What is the root cause of that problem?

In

<View style={[styles.flex1, styles.justifyContentCenter]}>
we're using justifyContentCenter that make the arrows buttons overlap the text when user use small device

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

I suggest we should remove styles.justifyContentCenter in

<View style={[styles.flex1, styles.justifyContentCenter]}>
and apply margin-top if needed

We should hide arrow if we open the keyboard by adding the following lines in

<AttachmentView
onPress={() => this.toggleArrowsVisibility(!this.state.shouldShowArrow)}
source={authSource}
file={this.state.file}
/>

onToggleKeyboard={(isKeyboardOpen)=>{
                            if(!isKeyboardOpen) return;
                            this.setState({
                                shouldShowArrow:false
                            })
                        }}

Result

Here's is my result after removing justifyContentCenter and add margin-top: 50px
Screen Shot 2023-03-21 at 22 55 08
Screen Shot 2023-03-21 at 22 57 24

@bernhardoj
Copy link
Contributor

Proposal

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

The attachment carousel arrow covers some text and submit button

What is the root cause of that problem?

The arrow always show when we can navigate through the attachment, except when we click the screen.

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

We can make the button opacity lower. Currently, user can toggle the arrow visibility by pressing the screen (only for touch screen device). I think maybe we need to have a proper design for the carousel. I feel like the button is too big and maybe we can also hide the arrow automatically after no interaction for a few seconds (for touch screen device). Here is what we need to do:

  1. Create a new function (scheduleHideArrow) to set a timeout to call toggleArrowsVisibility(false). The function will only run if it's a touch screen device (this.canUseTouchScreen)
  2. When the component mounts, call scheduleHideArrow.
  3. Inside toggleArrowsVisibility, call scheduleHideArrow if the shouldShowArrow is true. Else, cancel the timeout (clearTimeout()).

@parasharrajat
Copy link
Member

Opened a discussion https://expensify.slack.com/archives/C049HHMV9SM/p1679435904636059. I think these arrows are in general a bad UI.

@melvin-bot melvin-bot bot added the Overdue label Mar 23, 2023
@parasharrajat
Copy link
Member

parasharrajat commented Mar 23, 2023

Bumped the discussion. Shawn is OOO so not sure whom to tag.

@MelvinBot
Copy link

@Beamanator @kevinksullivan @parasharrajat this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

@MelvinBot
Copy link

📣 @bernhardoj You have been assigned to this job by @Beamanator!
Please apply to this job in Upwork 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 📖

@Beamanator
Copy link
Contributor

Makes sense to me, thanks for pushing this forward @parasharrajat

@bernhardoj
Copy link
Contributor

bernhardoj commented Apr 11, 2023

Will open the PR soon.

Test shrinking the PDF password form(We will observe if that looks good).

@parasharrajat by shrinking, do you mean when we open the keyboard? After this PR https://github.com/Expensify/App/pull/16332/files merged, showing the keyboard won't resize the screen anymore (except Android Chrome).

@parasharrajat
Copy link
Member

Not. I mean to reduce the width of the form so that button does not overlap with it.

@kevinksullivan
Copy link
Contributor

Offers sent in upwork @parasharrajat @bernhardoj

@MelvinBot
Copy link

@Beamanator, @kevinksullivan, @parasharrajat, @bernhardoj Whoops! This issue is 2 days overdue. Let's get this updated quick!

@MelvinBot
Copy link

@Beamanator, @kevinksullivan, @parasharrajat, @bernhardoj Huh... This is 4 days overdue. Who can take care of this?

@parasharrajat
Copy link
Member

Will test the PR today. There have been several updates to the original solution.

@parasharrajat
Copy link
Member

parasharrajat commented Apr 26, 2023

Note: PR #17269 took more than the expected time to be approved because we worked on improving the arrow hidden functionality which was not required for this issue but useful for the app.

From #15896 (comment)

Ok, so we have a suggestion on Slack that says to reduce the button size and edge gap. I tried it and came up with this which is approved.

The main solution to this issue was to only reduce the arrow size and gap so that they don't overlap, improving the arrow auto-hide is an addon. That addon might have come up as an additional issue in the future. Thus I request that we don't apply a 50% penalty for late merging.

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Daily KSv2 labels May 2, 2023
@melvin-bot melvin-bot bot changed the title [$1000] Chat - Password protected PDF file doesn't look correct in view mode [HOLD for payment 2023-05-09] [$1000] Chat - Password protected PDF file doesn't look correct in view mode May 2, 2023
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label May 2, 2023
@MelvinBot
Copy link

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

@MelvinBot
Copy link

MelvinBot commented May 2, 2023

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.8-8 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-05-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

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

@MelvinBot
Copy link

MelvinBot commented May 2, 2023

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:

  • [@parasharrajat] The PR that introduced the bug has been identified. Link to the PR:
  • [@parasharrajat] 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:
  • [@parasharrajat] 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:
  • [@parasharrajat] Determine if we should create a regression test for this bug.
  • [@parasharrajat] 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.
  • [@kevinksullivan] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@kevinksullivan
Copy link
Contributor

@parasharrajat can you finish out the remaining steps above? Thanks!

@parasharrajat
Copy link
Member

parasharrajat commented May 9, 2023

[@parasharrajat] The PR that introduced the bug has been identified. Link to the PR: #9279

[@parasharrajat] 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: #9279 (comment)

[@parasharrajat] 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: https://expensify.slack.com/archives/C049HHMV9SM/p1683662751831229

[@parasharrajat] Determine if we should create a regression test for this bug. Yes

[@parasharrajat] 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. #15896 (comment)

@parasharrajat
Copy link
Member

Regression Test Steps

Android|iOS|mweb

  1. Open any chat
  2. Send an image, a protected pdf, and another image
  3. Open the protected PDF
  4. Verify the arrows don't cover the Form Content.
  5. Verify the arrows are hidden after 3 seconds.
  6. Tap the attachment to show the arrows.
  7. Hold down the arrows and verify the arrows don't hide even after 3 seconds.
  8. Stop and wait for 3 seconds & Verify the arrows now are hidden.
  9. Click once on the prev button and observe that attachment is navigated back.
  10. Click once on the next button and observe that attachment is navigated forward.
  11. Tap on the screen and notice that the buttons are hidden.

Web| Desktop

  1. Open any chat
  2. Send an image, a protected pdf, and another image
  3. Open the protected PDF
  4. Verify the arrows don't cover the Form Content.
  5. Click once on the prev button and observe that attachment is navigated back.
  6. Click once on the next button and observe that attachment is navigated forward.
  7. Move the cursor in and out of the attachment modal and observe that buttons show and hide respectively.

Do you agree 👍 or 👎 ?

@parasharrajat
Copy link
Member

@kevinksullivan Any update?

@kevinksullivan
Copy link
Contributor

Paid @parasharrajat and @bernhardoj

@kevinksullivan
Copy link
Contributor

Regression test GH created, going to close this out.

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 External Added to denote the issue can be worked on by a contributor
Projects
None yet
Development

No branches or pull requests

7 participants