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
I think the issues is due to the Chrome/Edge return floats for $(el).scrollTop().
Just for testing, I change
isComponentScrollBarAtBottom: function(id) {
var el = $("#" + id);
// offsetheight : element height
// scrolltop : height of scroll from top
// scroll-height:height of the scroll view of an element
return ($(el).prop("offsetHeight") + $(el).scrollTop() >= $(el).prop("scrollHeight"));
}
for
isComponentScrollBarAtBottom: function(id) {
var el = $("#" + id);
// offsetheight : element height
// scrolltop : height of scroll from top
// scroll-height:height of the scroll view of an element return (Math.round($(el).prop("offsetHeight")) + Math.round($(el).scrollTop()) >= Math.round($(el).prop("scrollHeight")));
}
and it works on Chrome and Edge.
Thx.
The text was updated successfully, but these errors were encountered:
Chromium based browsers return float for `scrollTop` and this seems to break `isComponentScrollBarAtBottom` method.
(cherry picked from commit 7b5704f)
Hi,
I noticed that the https://github.com/wicketstuff/core/blob/master/quickview-parent/quickview-examples/src/main/java/org/wicketstuff/examples/ParentScrollBar.java does not works on Edge and Chrome Browsers.
I tested it on chrome/edge and I saw that the function isComponentScrollBarAtBottom on the https://github.com/wicketstuff/core/blob/master/quickview-parent/quickview/src/main/java/org/wicketstuff/repeater.js always return false for Edge and Chome. For Firefox works ok.
I think the issues is due to the Chrome/Edge return floats for $(el).scrollTop().
Just for testing, I change
isComponentScrollBarAtBottom: function(id) {$(el).prop("offsetHeight") + $ (el).scrollTop() >= $(el).prop("scrollHeight"));
var el = $("#" + id);
// offsetheight : element height
// scrolltop : height of scroll from top
// scroll-height:height of the scroll view of an element
return (
}
for
isComponentScrollBarAtBottom: function(id) {
var el = $("#" + id);
// offsetheight : element height
// scrolltop : height of scroll from top
// scroll-height:height of the scroll view of an element
return (Math.round($(el).prop("offsetHeight")) + Math.round($(el).scrollTop()) >= Math.round($(el).prop("scrollHeight")));
}
and it works on Chrome and Edge.
Thx.
The text was updated successfully, but these errors were encountered: