From dcc3cd4d49746484662cb9c00b19c2f74c2b0a58 Mon Sep 17 00:00:00 2001 From: Ryan Stafford Date: Tue, 11 Jul 2023 13:49:29 -0400 Subject: [PATCH] noscript pager fixes --- public/style.css | 4 ++-- public/utils.js | 3 +++ templates/frontpage.html | 4 ++-- templates/main.html | 11 +++++++---- 4 files changed, 14 insertions(+), 8 deletions(-) diff --git a/public/style.css b/public/style.css index b61b969..7d6debf 100644 --- a/public/style.css +++ b/public/style.css @@ -377,7 +377,7 @@ form.nsfw div { top: 1px; } .pager { - margin: 10px; + margin: 20px 0px; } .pager a { padding: 1px 4px; @@ -471,7 +471,7 @@ form.nsfw div { .expando-button:hover{ background-color: #466599; } -.expando-button.hidden, .children.hidden { +.expando-button.hidden, .children.hidden .comment { display: none; } .hidechildren .show { diff --git a/public/utils.js b/public/utils.js index be30024..0f650a3 100644 --- a/public/utils.js +++ b/public/utils.js @@ -304,6 +304,9 @@ function setup() { hidechildren.addEventListener("click", hideAllChildComments) } if (lmc = document.getElementById("lmc")){ + if (pager = document.getElementsByClassName("pager")){ + pager[0].style.display = "none"; + } lmc.addEventListener("click", loadMoreComments) } var posts = document.getElementsByClassName("post") diff --git a/templates/frontpage.html b/templates/frontpage.html index 26509ad..95b1e1f 100644 --- a/templates/frontpage.html +++ b/templates/frontpage.html @@ -2,7 +2,7 @@ {{ if and .Community (ne .Community.CommunityView.Community.Title "")}}{{.Community.CommunityView.Community.Title}}{{else if ne .CommunityName ""}}/c/{{.CommunityName}}{{ else if .User}}overview for {{.User.PersonView.Person.Name}}{{else}}{{ host .Host }}{{end}} - + @@ -56,6 +56,6 @@ {{ template "sidebar.html" . }} {{ end }} - + diff --git a/templates/main.html b/templates/main.html index b6596b6..dfa359a 100644 --- a/templates/main.html +++ b/templates/main.html @@ -3,7 +3,7 @@ {{if and .Posts .PostID }}{{ (index .Posts 0).Post.Name}} : {{.CommunityName}}{{else if and .Community (ne .Community.CommunityView.Community.Title "")}}{{.Community.CommunityView.Community.Title}}{{else if ne .CommunityName ""}}/c/{{.CommunityName}}{{ else if .User}}overview for {{.User.PersonView.Person.Name}}{{else}}{{ host .Host }}{{end}} - +