Preserve drawing buffer for gl3d scenes when using Safari 13#5351
Merged
Preserve drawing buffer for gl3d scenes when using Safari 13#5351
Conversation
Contributor
Author
src/plots/gl3d/scene.js
Outdated
| if(isNumeric(v)) v = +v; | ||
|
|
||
| // to fix https://github.com/plotly/plotly.js/issues/5158 | ||
| if(v >= 14) return true; |
Collaborator
There was a problem hiding this comment.
I don't understand navigator.userAgent... Here's what I see on my laptop browsers:
Chrome:
Mozilla/5.0 (Macintosh; Intel Mac OS X 11_1_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36
Safari:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.2 Safari/605.1.15
FireFox:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:84.0) Gecko/20100101 Firefox/84.0
Edge:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_16_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.121 Safari/537.36 Edg/85.0.564.68
Brave:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_16_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.163 Safari/537.36"
So by the test here, everything except FireFox would look like Safari >= 14 - Safari 80, Safari 87... That's probably not what we want.
(Amusingly they all have different ideas what OS version I'm running, and only Chrome is correct. Safari, Apple's own, is the farthest off)
Contributor
Author
There was a problem hiding this comment.
Good catch. Fixed in the commits below.
… config works in most cases
3da06dd to
c8ce9fa
Compare
alexcjohnson
approved these changes
Dec 18, 2020
Collaborator
alexcjohnson
left a comment
There was a problem hiding this comment.
That's quite a list of userAgent strings 😳
Looks great. 💃
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #5158.
@plotly/plotly_js