Skip to content

Commit

Permalink
Revised the code to dynamically adjust the gallery size based on the…
Browse files Browse the repository at this point in the history
… screen dimensions.
  • Loading branch information
PatrickJnr committed Mar 3, 2024
1 parent 3ad8527 commit 77e8b2b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
3 changes: 1 addition & 2 deletions _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,7 @@ <h1><strong>{{ page.title }}</strong></h1>
}
return imageUrls.imageFull;
},
columns: 3,
addAnchorTag: true,
addAnchorTag: true,
anchorTargetDir: "",
anchorClass: "swipebox"
}).enable();
Expand Down
8 changes: 4 additions & 4 deletions js/pig.js
Original file line number Diff line number Diff line change
Expand Up @@ -323,13 +323,13 @@

//Desktop
if (lastWindowWidth <= 640) {
return 1;
return 3;
} else if (lastWindowWidth <= 1280) {
return 1.5;
return 6;
} else if (lastWindowWidth <= 1920) {
return 2;
return 9;
}
return 7;
return 12;
},

//We are not using this for now, and instead handle the size directly on the given urlForSize
Expand Down

0 comments on commit 77e8b2b

Please sign in to comment.