-
-
Notifications
You must be signed in to change notification settings - Fork 983
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
Function scrollToIFrame #115
Comments
Rather than change the current function, it would make more sense to create a new one called scrollToOffset. So people have the option of which one to use. Happy to take a pull request if you want to do that, but please also include a test. |
Yes it was also my intent to create another version of the existing function. I will try to find some time to implement it. |
Thanks. I also think that the min/max height checks acting on these values is a bug. That check should be disabled for |
Just had a look at the code. I'm going to move these lines ensureInRange('Height');
ensureInRange('Width'); So they are only called if we are resizing the iFrame. |
Great it would make it really easy to implement. |
OK fix released as v2.6.3 |
Added |
I think a very nice feature could be scrollToIFrame, where the scroll in the parent is relative to the iframe, it may be more usefull than scrollTo, because scrolling the parent is often when you want to highlight something in the iframe.
I have added it manually to your latest min version, I wont post the sourcecode because it is so trivial, it is just the scrollTo function but adding the iframes offset top. I would make a change request, but I ran into an issue where you use width and height to transfer the scroll values, and they do not accept negative values by default (in case you want to scroll like 10px above the iframe it is -10), and I just fixed this pretty dirty by changed minHeight to 1/0, you would probably like a more correct solution.
The text was updated successfully, but these errors were encountered: