You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$('.test-element').each(function(){$(this).visibility({once: false,onTopVisible: function(){console.log("onTopVisible for element",$(this).attr('id'))},onTopVisibleReverse: function(){console.log("onTopVisibleReverse for element",$(this).attr('id'))}});});
Expected Result
In Semantic-UI 2.2.10 it works as expected: reverse event was fired only when element goes back to same edge, where it was appeared.
I think, if event is named reverse it should be fired only when element goes back. At this moment it works as onTopInvisible.
Actual Result
reverse event is fired even if element goes through the screen and goes from another edge.
Version
2.2.10 - works as expected 2.3.3 - looks like broken
I think this is just down to some bad naming rather than the events being wrong. Maybe the event names should be changed to better represent why/when they are called.
Quick explanation
Steps
visibility
module on them:Expected Result
In Semantic-UI 2.2.10 it works as expected:
reverse
event was fired only when element goes back to same edge, where it was appeared.I think, if event is named
reverse
it should be fired only when element goes back. At this moment it works asonTopInvisible
.Actual Result
reverse
event is fired even if element goes through the screen and goes from another edge.Version
2.2.10
- works as expected2.3.3
- looks like brokenTestcase
https://jsfiddle.net/soarx/ugv49aLm/
The text was updated successfully, but these errors were encountered: