-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Fix issue 359 (zoom overlay drawn beneath shapes) #448
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 an 8000 d privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
.then(done); | ||
}); | ||
|
||
it('should be appended to the the shape layer', function() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you mean: to the zoom layer ?
Visual confirmation (mock): |
expect(d3.selectAll('.zoomlayer > .zoombox-corners').size()) | ||
.toEqual(0); | ||
expect(d3.selectAll('.zoomlayer > .select-outline').size()) | ||
.toEqual(2); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe add an assertion after doubleClick
making sure that the select-outline
are cleared.
@n-riesco I made a few minor comments, but this PR looks great. 🍻 to our new shape expert. |
Skimming through the numbers made me think this was a case of a comparison with too many digits. I set the precision to This PR is not ready. I need to investigate further the reason for this random failures. |
e2fa52f
to
04ef33e
Compare
|
This PR is ready again for review/merging. |
@@ -180,7 +180,9 @@ describe('Test click interactions:', function() { | |||
|
|||
describe('drag interactions', function() { | |||
beforeEach(function(done) { | |||
Plotly.plot(gd, mockCopy.data, mockCopy.layout).then(done); | |||
Plotly.plot(gd, mockCopy.data, mockCopy.layout).then(function() { | |||
setTimeout(done, 200); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think #445 solves the same problem?
Looks great! |
All reactions
Sorry, something went wrong.
cbee319
to
85c9948
Compare
Fixes plotly#359
* Test whether select elements are appended to the zoom layer. * Test whether lasso elements are appended to the zoom layer.
* Ensured the zoombox corners have been removed before emitting 'plotly_deselect' or 'plotly_selected'.
* Test that a double click removes a selection.
85c9948
to
a360992
Compare
* The drag interaction tests in click_test.js may fail when run by `npm run test-jasmine` while they succeed if run by `npm run test-jasmine -- tests/click_test.js`. * These failures disappear when a pause of 200ms is introduced in the `beforeEach` after creating the plot. * Shorter pauses of 0, 10, 20, 50 and 100 ms fail.
This reverts commit 9032cb7.
* In the drag interactions tests, make sure the notifier doesn't hide the drag elements.
This PR is ready again for review/merging. |
All reactions
Sorry, something went wrong.
var tooltip = document.querySelector('.notifier-note'); | ||
if(tooltip) tooltip.style.display = 'None'; | ||
|
||
done(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Beautiful. Thanks for figuring this out 🍻
Sorry, something went wrong.
All reactions
@n-riesco Great PR. Thanks! |
All reactions
-
👍 1 reaction -
😄 1 reaction
Sorry, something went wrong.
- broken since #448 - 🔒 down with test
Successfully merging this pull request may close these issues.
This PR comes from #395 . I couldn't rebase it, and I ended up cherry-picking the commits.
I followed @alexcjohnson 's advice and created a zoom layer between the info and the hover layers.
The PR is ready for review.