-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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-04-27] [$1000] The attachment viewer loads every image again when switching with arrows #15922
Comments
Triggered auto assignment to @isabelastisser ( |
Bug0 Triage Checklist (Main S/O)
|
Job added to Upwork: https://www.upwork.com/jobs/~0136002576e7090b5b |
Current assignee @isabelastisser is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @thesahindia ( |
Triggered auto assignment to @johnmlee101 ( |
Hey @isabelastisser do you mind completing the checklist #15922 (comment) |
sorry, forgot to check the boxes before applying the external label! |
@johnmlee101 Are you sure this is a dupe of #6527 ? |
ProposalPlease re-state the problem that we are trying to solve in this issue.The spinner keeps shown on every image when switching even it loaded before. What is the root cause of that problem?Because in the App/src/components/ImageView/index.js Lines 63 to 69 in eedd92a
when isLoading state equal true, it shows spinner App/src/components/ImageView/index.js Lines 298 to 302 in eedd92a
What changes do you think we should make in order to solve the problem?I think we should apply delayed spinner pattern in this case. According to some UX tips, we should only show spinner if something is loaded > 1s, otherwise it will distract user. More details, I think about add an additional props import React, { useEffect, useState } from 'react';
const defaultProps = {
....
delayTime: 0,
};
const FullScreenLoadingIndicator = (props) => {
const [showable, setShowable] = useState(false);
useEffect(() => {
const timer = setTimeout(() => setShowable(true), props.delayTime);
return () => clearTimeout(timer);
});
return showable && <..../>;
};
export default FullScreenLoadingIndicator; so we can set delayTime in the loading part of component What alternative solutions did you explore? (Optional)Maybe cache loaded images, but it will be a fancy work. |
Proposal I think you need to render each You can cache image content or make Plus, if you will use style, you can use opacity and it is good for animation. Contributor details |
📣 @nefedov-dm! 📣 Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Format:
|
ProposalPlease re-state the problem that we are trying to solve in this issue.The attachment viewer loads every image again when switching with arrows What is the root cause of that problem?The
What changes do you think we should make in order to solve the problem?It will be fixed if we use it with the Or if we use it without It needs more investigation like why the debounce actually used to make sure that the fix won't break anything. What alternative solutions did you explore? (Optional) |
ProposalUpdated according to contributing guidelines. |
This is expected behavior, debounce here is added to ensure there is no flickering of the image while switching images fast. |
Not overdue, still discussing! @johnmlee101 is this a dupe or expected behavior? Let me know if I should close it. |
Still working, should be ready tomorrow A little teaser Android.Emulator.-.Pixel_4_API_31_5554.2023-04-04.22-58-24.mp4 |
Looks much better @kidroca! |
PR ready for review |
@johnmlee101, @kidroca, @isabelastisser, @thesahindia Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
PR is ready for review |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.2-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 2023-04-27. 🎊 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:
|
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:
|
There seems regression from PR which fixes this issue |
@situchan can you clarify what you mean. Are you saying the PR for this issue caused a regression? |
yes |
To confirm: @kidroca: approved proposal
The issue amount is $1000, but does it mean that the payment processed will be $500 because: @johnmlee101, I got the info above here, is this correct? |
Not overdue, still discussing this with @johnmlee101 ! |
@isabelastisser This was a fairly complex issue that had a lot of edge cases that were being tested, so I think the 50% penalty might not apply in this case. I'd be fine keeping it as the original $1000 for this. |
Update: Payments made in Upwork and contracts ended. @thesahindia, please complete your tasks on the |
Will do it soon
Let's add tests
Test steps -
|
QA issue here. All set! |
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:
Expected Result
The spinner should only display once when the image loads, after that, the image should not need to show the spinner and be shown instantly
Actual Result
The spinner is shown on every image when switching and images are loaded again every time.
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.2.83-1
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:
test.mov
Recording.1689.mp4
Expensify/Expensify Issue URL:
Issue reported by: @esh-g
Slack conversation:
https://expensify.slack.com/archives/C049HHMV9SM/p1678613459293019
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: