This repository was archived by the owner on Nov 25, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
feat: add HoverifyOptions.scrollBoundaries #196
Merged
Merged
Conversation
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
Rel [RFC 76](https://docs.google.com/document/d/1albi6HaAU9JAqdQXjsE-50NidxG4icE-36XqxxKgfM4/edit) Introduces `HoverifyOptions.scrollBoundaries`, an array of `HTMLElement`, which would typically contain elements with a lower z-index than the hover overlay but a higher z-index than the code view, such as a sticky file header. At runtime, in reaction to scroll events, hide the hover overlay when it overlaps with a hover boundary. `IntersectionObserver` could not be used here, as it requires an ancestor relationship between the root and target elements.
lguychard
pushed a commit
to sourcegraph/sourcegraph-public-snapshot
that referenced
this pull request
Dec 3, 2019
Codecov Report
@@ Coverage Diff @@
## master #196 +/- ##
==========================================
+ Coverage 84.06% 84.98% +0.91%
==========================================
Files 13 13
Lines 546 566 +20
Branches 135 141 +6
==========================================
+ Hits 459 481 +22
+ Misses 87 85 -2
Continue to review full report at Codecov.
|
ghost
approved these changes
Dec 4, 2019
7 tasks
felixfbecker
reviewed
Dec 5, 2019
felixfbecker
reviewed
Dec 5, 2019
Co-Authored-By: Felix Becker <felix.b@outlook.com>
Contributor
|
Could this be unit tested in Karma? |
lguychard
commented
Dec 6, 2019
eseliger
approved these changes
Dec 16, 2019
|
🎉 This PR is included in version 6.3.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
lguychard
pushed a commit
to sourcegraph/sourcegraph-public-snapshot
that referenced
this pull request
Dec 16, 2019
lguychard
pushed a commit
to sourcegraph/sourcegraph-public-snapshot
that referenced
this pull request
Dec 16, 2019
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Rel RFC 76
Introduces
HoverifyOptions.scrollBoundaries, an array ofHTMLElement, which would typically contain elements with a lower z-index than the hover overlay but a higher z-index than the code view, such as a sticky file header.At runtime, in reaction to scroll events, hide the hover overlay when it overlaps with a hover boundary.
IntersectionObservercould not be used here, as it requires an ancestor relationship between the root and target elements.Before:
After: