Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions dist/filepond.esm.js
Original file line number Diff line number Diff line change
Expand Up @@ -833,7 +833,7 @@ const updateRect = (rect = {}, element = {}, style = {}) => {

rect.scrollTop = element.scrollTop;

rect.hidden = element.offsetParent === null;
rect.hidden = element.offsetParent === null || style.visibility === 'hidden';

return rect;
};
Expand Down Expand Up @@ -8734,7 +8734,11 @@ const createApp = (initialOptions = {}) => {

if (isHidden && isResting) {
// test if is no longer hidden
isResting = view.element.offsetParent === null;
// check both display:none (offsetParent) and visibility:hidden
const el = view.element;
const isStillHidden =
el.offsetParent === null || getComputedStyle(el).visibility === 'hidden';
isResting = isStillHidden;
}

// if resting, no need to read as numbers will still all be correct
Expand Down
2 changes: 1 addition & 1 deletion dist/filepond.esm.min.js

Large diffs are not rendered by default.

8 changes: 6 additions & 2 deletions dist/filepond.js
Original file line number Diff line number Diff line change
Expand Up @@ -950,7 +950,7 @@

rect.scrollTop = element.scrollTop;

rect.hidden = element.offsetParent === null;
rect.hidden = element.offsetParent === null || style.visibility === 'hidden';

return rect;
};
Expand Down Expand Up @@ -11605,7 +11605,11 @@

if (isHidden && isResting) {
// test if is no longer hidden
isResting = view.element.offsetParent === null;
// check both display:none (offsetParent) and visibility:hidden
var el = view.element;
var isStillHidden =
el.offsetParent === null || getComputedStyle(el).visibility === 'hidden';
isResting = isStillHidden;
}

// if resting, no need to read as numbers will still all be correct
Expand Down
2 changes: 1 addition & 1 deletion dist/filepond.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/js/app/frame/utils/updateRect.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export const updateRect = (rect = {}, element = {}, style = {}) => {

rect.scrollTop = element.scrollTop;

rect.hidden = element.offsetParent === null;
rect.hidden = element.offsetParent === null || style.visibility === 'hidden';

return rect;
};
6 changes: 5 additions & 1 deletion src/js/app/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,11 @@ export const createApp = (initialOptions = {}) => {

if (isHidden && isResting) {
// test if is no longer hidden
isResting = view.element.offsetParent === null;
// check both display:none (offsetParent) and visibility:hidden
const el = view.element;
const isStillHidden = el.offsetParent === null ||
getComputedStyle(el).visibility === 'hidden';
isResting = isStillHidden;
}

// if resting, no need to read as numbers will still all be correct
Expand Down