jquery.appear
jquery.appear copied to clipboard
jQuery plugin for tracking element's appearance in browser viewport
I added the ability to pass in scroll_selector, such as '#people'. Also refactored static "check_binded" variable to be stored as data on the scrollable element.
I need something to fire a settimeout when item appears, but 0.3.6 fires that every time you scroll with it in view too. This keeps track of if the element...
added a new option scroll_selector, where you can specify a different viewport (default = window) you can now also use multiple instances (f.ex. window and any another srollable container) but...
To solve this issue: https://github.com/morr/jquery.appear/issues/58
I found a bug when running multiple instances of appear for example something like this ``` $('.selector1').appear({force_process: true}) .on('appear', function() { console.log('hi 1'); }) .on('disappear', function() { console.log('bye 1'); });...
In case appear() is called on multiple DOM elements, $prior_appeared did not remember the prior appeared elements for ALL selectors. Thus $disappeared was calculated incorrectly which caused weird behaviour. Fixed...
Just to save copy-paste-users the effort of minimizing the plugin.
If the scrollable parent is not the main window then you can specify it. For example: .appear({scrolling_parent: $('#column1')})
when the browser falls back to quirksmode (through invalid html/doctype/whatever) jquery calculates window height using availableheight, instead of screen.height, which should always work