impacts with keywords
All checks were successful
Deploy / Deploy to Production (push) Successful in 12s
All checks were successful
Deploy / Deploy to Production (push) Successful in 12s
This commit is contained in:
parent
0727519a5e
commit
1cc63b0725
9 changed files with 131 additions and 166 deletions
|
|
@ -31,4 +31,33 @@ window.onload = async function () {
|
|||
playVideo();
|
||||
initDropdowns(responsiveSmall);
|
||||
initSwipers();
|
||||
|
||||
|
||||
var elem = document.querySelector('.grid-masonry');
|
||||
var msnry = null;
|
||||
|
||||
function initMasonry() {
|
||||
if (!elem) return;
|
||||
if (window.innerWidth >= responsiveSmall) {
|
||||
if (!msnry) {
|
||||
msnry = new Masonry(elem, {
|
||||
itemSelector: '.card--impact',
|
||||
columnWidth: '.grid-sizer',
|
||||
percentPosition: true,
|
||||
gutter: 26
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if (msnry) {
|
||||
msnry.destroy();
|
||||
msnry = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
initMasonry();
|
||||
window.addEventListener('resize', initMasonry);
|
||||
|
||||
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue