Skip to content
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

nested scrollable elemete #1543

Open
sanafathii opened this issue Apr 15, 2024 · 0 comments
Open

nested scrollable elemete #1543

sanafathii opened this issue Apr 15, 2024 · 0 comments

Comments

@sanafathii
Copy link

I have offcanvas in my page that scrolled and in offcanvas I have a select option that scroll too but when in offcanvas use PerfectScrollbar select option doesn't scroll . how can I fix it .

it's my js code :
let slice = Array.prototype.slice.call(document.querySelectorAll("*")).filter(
e => e.scrollHeight > e.offsetHeight
);

let elements = slice.filter(e => {
var style = window.getComputedStyle(e);
return [style.overflow, style.overflowX, style.overflowY].some(
e => e === "auto" || e === "scroll"
);
});
if (elements.length) {
elements.forEach(e => { new PerfectScrollbar(e, { wheelPropagation: true }); });
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant