mito-ds / mito

The mitosheet package, trymito.io, and other public Mito code.
https://trymito.io
Other
2.29k stars 156 forks source link

Fullscreen mito disappears on streamlit on safari #842

Open naterush opened 1 year ago

naterush commented 1 year ago

On Safari, but not Chrome when you exit full screen mode (escape or clicking the toolbar button), the Mito sheet disappears from the app until you reload the page

https://github.com/mito-ds/monorepo/assets/18709905/cde7dd2e-9a92-4a6a-91da-53517cd3bd1c

EDIT: Opened an issue for this. Safari is <2% market share, so I think it's not worth worrying about.

aarondr77 commented 7 months ago

I'm not able to replicate this anymore on Safari locally or on a deployed app, however, I just saw a user on Chrome running a streamlit app locally who had this issue.

I am unable to replicate it on Chrome.

aarondr77 commented 7 months ago

I am able to replicate this consistently on FireFox 123.0.1, using the streamlit app (https://mito-for-st-demo.streamlit.app/?utm_medium=oembed) hosted on the trymito.io website.

To replicate:

  1. Open full screen mode
  2. Make an edit to the data fame (it only occurs if you make an edit while in fullscreen mode)
  3. Close full screen mode
  4. Notice that Mito is gone until the app reruns

I can't replicate on Chrome Version 116.0.5845.179 (Official Build) (arm64) or Safari with the same steps, but I saw it occur to a user on Chrome Version 120.0.6099.62 today.

Even when I upgraded to Chrome Version 122.0.6261.112 (Official Build) (arm64) it is still occurring.

Feels like a race condition somewhere.

https://github.com/mito-ds/mito/assets/18709905/85e57e01-2f91-42e8-b4b3-501e8d724105

naterush commented 7 months ago

@aarondr77 most likely we have a log for opening fullscreen we should just turn off.

naterush commented 7 months ago

Ok, updating my thinking here: I don't think this is a sheet crashing bug. I think it's actually probably a focus handling issue with respect to fullscreen mode in browsers.

Unfortunately, I can't replicate it with the above instructions, so it's making it hard to dig in further.