feat(esl-utils): ScrollIntoView new implementation#1001
Open
fshovchko wants to merge 26 commits intoepic/scroll-into-viewfrom
Open
feat(esl-utils): ScrollIntoView new implementation#1001fshovchko wants to merge 26 commits intoepic/scroll-into-viewfrom
fshovchko wants to merge 26 commits intoepic/scroll-into-viewfrom
Conversation
ala-n
requested changes
May 29, 2022
Collaborator
ala-n
left a comment
There was a problem hiding this comment.
There is a couple of critical structural notes here.
But, basically, I'd want to hold the final review here with the architectural rework first. The final API doesn't look great to me at this point.
So just let me summarize the tech requironments, I need a little bit more time to rethink the API first, so marking PR as not ready for merge right now
ala-n
requested changes
Jun 4, 2022
Collaborator
ala-n
left a comment
There was a problem hiding this comment.
@fshovchko, please see the use case example pushed to the branch
It looks like scrollIntoView currently does not pass successfully for the dynamic content scenario when page scroll is used (the testing wasn't successful on the clients' side for the same reason).
dshovchko
reviewed
Jun 8, 2022
Collaborator
|
Needs presentational updates from #1022 |
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.
In the scope of this PR i added promisified version for scrollIntoView().
Parameters:
element - the element which should become visible
options (Optional)
For boolean value:
If true, the top of the element will be aligned to the top of the visible area of the scrollable ancestor. Corresponds to scrollIntoViewOptions: {block: "start", inline: "nearest"}. This is the default value.
If false, the bottom of the element will be aligned to the bottom of the visible area of the scrollable ancestor. Corresponds to scrollIntoViewOptions: {block: "end", inline: "nearest"}.
For Object with the following properties:
behavior (Optional) - defines the transition animation. One of auto or smooth. Defaults to auto.
block (Optional) - defines vertical alignment. One of start, center, end, or nearest. Defaults to start.
inline (Optional) - defines horizontal alignment. One of start, center, end, or nearest. Defaults to nearest.