fill categories panel
This commit is contained in:
parent
a2722a0264
commit
93a628ec57
5 changed files with 108 additions and 47 deletions
|
|
@ -91,7 +91,7 @@ function enableToggleEntriesVisibility() {
|
|||
});
|
||||
};
|
||||
|
||||
const top = verticalUnit * 6;
|
||||
const top = verticalUnit * 8;
|
||||
|
||||
const observer = new IntersectionObserver(toggleVisibility, {
|
||||
root: null,
|
||||
|
|
@ -114,7 +114,17 @@ function toggleLogoState() {
|
|||
|
||||
function togglePanel(side) {
|
||||
document.querySelector(`.panel--${side}`).classList.toggle("open");
|
||||
document.querySelector("#main-header").classList.remove("minimized");
|
||||
const isOpen = document
|
||||
.querySelector(`.panel--${side}`)
|
||||
.classList.contains("open");
|
||||
|
||||
const scrollY = window.scrollY || window.pageYOffset;
|
||||
|
||||
if (isOpen) {
|
||||
document.querySelector("#main-header").classList.remove("minimized");
|
||||
} else if (scrollY > 10) {
|
||||
document.querySelector("#main-header").classList.add("minimized");
|
||||
}
|
||||
}
|
||||
|
||||
document.addEventListener("DOMContentLoaded", () => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue