mirror of
https://github.com/litruv/lit.ruv.wtf.git
synced 2026-07-24 02:36:02 +10:00
Add "view more" button to main container and update styles
This commit is contained in:
@@ -531,7 +531,15 @@ function hideLoadingIndicator() {
|
||||
|
||||
function showViewMoreButton() {
|
||||
const postsContainer = document.getElementById("posts");
|
||||
const containerDiv = postsContainer.parentElement; // Get the main container
|
||||
|
||||
// Check if button already exists
|
||||
if (document.getElementById("view-more-button")) {
|
||||
return;
|
||||
}
|
||||
|
||||
const viewMoreDiv = document.createElement("a");
|
||||
viewMoreDiv.id = "view-more-button";
|
||||
viewMoreDiv.href = "https://bsky.app/profile/lit.mates.dev";
|
||||
viewMoreDiv.target = "_blank";
|
||||
viewMoreDiv.className = "view-more-posts";
|
||||
@@ -541,7 +549,7 @@ function showViewMoreButton() {
|
||||
<small>Follow @lit.mates.dev for more posts</small>
|
||||
</div>
|
||||
`;
|
||||
postsContainer.appendChild(viewMoreDiv);
|
||||
containerDiv.appendChild(viewMoreDiv); // Add to main container, not posts container
|
||||
}
|
||||
|
||||
async function fetchPosts() {
|
||||
|
||||
@@ -679,6 +679,8 @@ footer a:hover {
|
||||
cursor: pointer;
|
||||
text-decoration: none;
|
||||
display: block;
|
||||
clear: both;
|
||||
margin-top: 3rem;
|
||||
}
|
||||
|
||||
.view-more-posts:hover {
|
||||
|
||||
Reference in New Issue
Block a user