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

Fix hover on mobile and tablet devices for gl3d subplots #5239

Merged
merged 5 commits into from
Nov 2, 2020

Conversation

jdpaterson
Copy link
Contributor

Update gl-plot3d version to fix #4550 .
Related to gl-vis/gl-plot3d#31

@archmoj
Copy link
Contributor

archmoj commented Oct 29, 2020

Thanks very much for the PR!
There is only one test failing now.

it('@gl should not scroll document while panning', function(done) {
var mock = {
data: [
{ type: 'scatter3d' }
],
layout: {
width: 500,
height: 500,
scene: { camera: { eye: { x: 0.1, y: 0.1, z: 1 }}}
}
};
var sceneTarget;
var relayoutCallback = jasmine.createSpy('relayoutCallback');
function assertEvent(e) {
expect(e.defaultPrevented).toEqual(true);
relayoutCallback();
}
gd.addEventListener('touchend', assertEvent);
gd.addEventListener('touchstart', assertEvent);
gd.addEventListener('touchmove', assertEvent);
gd.addEventListener('wheel', assertEvent);
Plotly.plot(gd, mock)
.then(function() {
sceneTarget = gd.querySelector('.svg-container .gl-container #scene');
return drag({touch: true, node: sceneTarget, pos0: [100, 100], posN: [0, 0], noCover: true});
})
.then(function() {
return drag({node: sceneTarget, pos0: [100, 100], posN: [0, 0], noCover: true});
})
.then(function() {
return scroll(sceneTarget);
})
.then(function() {
expect(relayoutCallback).toHaveBeenCalledTimes(3);
})
.catch(failTest)
.then(done);
});

@jdpaterson could you please investigate why?

@archmoj archmoj changed the title update gl-plot3d version Fix hover on mobile and tablet devices for gl3d subplots Oct 29, 2020
@archmoj archmoj added status: in progress bug something broken regression this used to work labels Oct 29, 2020
use non-blocking assert syntax
@jdpaterson
Copy link
Contributor Author

@archmoj the test-bundle timed out during the mapbox plot tests. Is this something I should be concerned about here?

@archmoj
Copy link
Contributor

archmoj commented Oct 29, 2020

@archmoj the test-bundle timed out during the mapbox plot tests. Is this something I should be concerned about here?

@jdpaterson No. I'll re-run the container tomorrow.
Also I'll spend more time testing.
Thanks again for the fantastic work.

@archmoj
Copy link
Contributor

archmoj commented Nov 2, 2020

Nicely done! 🥇 🎖️ @jdpaterson
💃

@archmoj archmoj merged commit 0d79ea9 into plotly:master Nov 2, 2020
@archmoj archmoj added this to the v1.58.0 milestone Dec 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something broken regression this used to work
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Gl3d hover not working on mobile and tablet since v1.34.0
2 participants