UX: hide select-kits when the parent element is outside the viewport

If the select-kit header is not in the viewport (scrolled out of view), popper adds a data-popper-reference-hidden attribute.

This PR adds the recommended styles to "hide" the select-kit body when that happens. See

https://popper.js.org/docs/v2/modifiers/hide/
This commit is contained in:
Joe 2022-06-07 16:57:10 +08:00 committed by GitHub
parent 7da074d591
commit 98671445a7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 0 deletions

View File

@ -175,6 +175,11 @@
max-height: 300px;
overflow-y: auto;
}
&[data-popper-reference-hidden] {
visibility: hidden;
pointer-events: none;
}
}
.select-kit-row {