forked from github.com/GenderDysphoria.fyi
Initial site commit
This commit is contained in:
10
js/_header.js
Normal file
10
js/_header.js
Normal file
@@ -0,0 +1,10 @@
|
||||
$(function () {
|
||||
let active = false;
|
||||
window.addEventListener('scroll', function () {
|
||||
const state = window.scrollY > 10;
|
||||
if (active !== state) {
|
||||
$('header').toggleClass('active', state);
|
||||
active = state;
|
||||
}
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user