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 #10894] Windows - Chat -Photo preview screen disappears after resizing window to full screen #20522

Closed
1 of 6 tasks
lanitochka17 opened this issue Jun 9, 2023 · 22 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Monthly KSv2

Comments

@lanitochka17
Copy link

lanitochka17 commented Jun 9, 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!


Issue found when executing PR #20440

Action Performed:

  1. Go to https://staging.new.expensify.com/
  2. Resize the window to a smaller window
  3. Drag and drop a photo to the chat
  4. On photo preview screen, resize the window to full screen

Expected Result:

Photo preview screen does not disappear

Actual Result:

Photo preview screen disappears

Workaround:

Unknown

Platforms:

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

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

Version Number: 1.3.26.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

Bug6086774_bandicam_2023-06-09_22-19-16-181.mp4

Expensify/Expensify Issue URL:

Issue reported by: Applause Internal Team

Slack conversation:

View all open jobs on GitHub

@lanitochka17 lanitochka17 added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Jun 9, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jun 9, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Jun 9, 2023

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

@s-alves10
Copy link
Contributor

Proposal

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

Image preview screen disappears after resizing window from small to full screen or vice versa

What is the root cause of that problem?

For responsiveness, we use withWindowDimensions HOC in the project.
AttachModal component is remounted when isSmallScreenWidth props(from withWindowDimensions) is changed due to the following code lines.

key={props.isSmallScreenWidth ? 'small' : 'big'}

return props.isSmallScreenWidth ? (
<NavigationContent>
<StackView
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
state={state}
descriptors={descriptors}
navigation={navigation}
/>
</NavigationContent>
) : (
<NavigationContent>
<ThreePaneView
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
state={state}
descriptors={descriptors}
navigation={navigation}
/>
</NavigationContent>
);

This is the root cause of this issue.

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

We store draft comments in Oynx store. Similarly, we can store the attachment in Oynx store and load attachment info when page refreshing or remounting.
In order to do this

  1. Add Oynx key for storing pending attachment
  2. Store the attachment in Oynx store when picked file is valid
  3. Load the attachment info from Oynx store when mounting
Result
20522_mac_chrome.mp4

What alternative solutions did you explore? (Optional)

@melvin-bot melvin-bot bot added the Overdue label Jun 11, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jun 11, 2023

Looks like something related to react-navigation may have been mentioned in this issue discussion.

As a reminder, please make sure that all proposals are not workarounds and that any and all attempt to fix the issue holistically have been made before proceeding with a solution. Proposals to change our DeprecatedCustomActions.js files should not be accepted.

Feel free to drop a note in #expensify-open-source with any questions.

@melvin-bot
Copy link

melvin-bot bot commented Jun 12, 2023

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

@roryabraham
Copy link
Contributor

Similarly, we can store the attachment in Oynx store and load attachment info when page refreshing or remounting

I like the idea, but I don't think we have a straightforward way to do that for now. I believe that this should be on HOLD for something in #10894. @Beamanator can you confirm / help find the specific issue this should be on HOLD for that will enable us to support offline image caching?

@JmillsExpensify
Copy link

Yes, I agree. Doing that now, in fact.

@melvin-bot melvin-bot bot removed the Overdue label Jun 14, 2023
@JmillsExpensify JmillsExpensify changed the title Windows - Chat -Photo preview screen disappears after resizing window to full screen [HOLD #10894] Windows - Chat -Photo preview screen disappears after resizing window to full screen Jun 14, 2023
@Beamanator
Copy link
Contributor

Huh, I don't quite understand why this is an "offline image caching" issue - it seems like it's just about resizing the browser, right?

@melvin-bot
Copy link

melvin-bot bot commented Jun 19, 2023

@JmillsExpensify Eep! 4 days overdue now. Issues have feelings too...

@JmillsExpensify
Copy link

Still on hold. Updating this one to weekly given the hold. Should have done that earlier, in fact.

@JmillsExpensify
Copy link

Still on hold.

@melvin-bot melvin-bot bot removed the Overdue label Jul 5, 2023
@melvin-bot melvin-bot bot added the Overdue label Jul 13, 2023
@JmillsExpensify
Copy link

Still on hold.

@melvin-bot melvin-bot bot removed the Overdue label Jul 19, 2023
@melvin-bot melvin-bot bot added the Overdue label Jul 27, 2023
@JmillsExpensify
Copy link

Hold

@melvin-bot melvin-bot bot removed the Overdue label Aug 2, 2023
@melvin-bot melvin-bot bot added the Overdue label Aug 10, 2023
@JmillsExpensify
Copy link

Hold

@melvin-bot melvin-bot bot removed the Overdue label Aug 16, 2023
@melvin-bot melvin-bot bot added the Overdue label Aug 25, 2023
@JmillsExpensify
Copy link

Same

@melvin-bot melvin-bot bot removed the Overdue label Aug 30, 2023
@melvin-bot melvin-bot bot added the Overdue label Sep 11, 2023
@JmillsExpensify
Copy link

Same

@melvin-bot melvin-bot bot removed the Overdue label Sep 13, 2023
@melvin-bot melvin-bot bot added the Overdue label Sep 21, 2023
@melvin-bot melvin-bot bot removed the Weekly KSv2 label Oct 6, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 6, 2023

This issue has not been updated in over 15 days. @JmillsExpensify eroding to Monthly issue.

P.S. Is everyone reading this sure this is really a near-term priority? Be brave: if you disagree, go ahead and close it out. If someone disagrees, they'll reopen it, and if they don't: one less thing to do!

@melvin-bot melvin-bot bot added Monthly KSv2 and removed Overdue labels Oct 6, 2023
@JmillsExpensify
Copy link

Still on hold for the image improvements.

@JmillsExpensify
Copy link

Still held on image improvements

@JmillsExpensify
Copy link

Holding for image initiative.

@JmillsExpensify
Copy link

Same

@JmillsExpensify
Copy link

Closing this issue in line with our decision to not prioritize resizing issues anytime soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. Monthly KSv2
Projects
None yet
Development

No branches or pull requests

5 participants