feat(pref): add ability to hide verfied badges

This commit is contained in:
2025-11-18 19:23:45 -03:00
parent 8d87371763
commit 57a1fc6820
3 changed files with 15 additions and 1 deletions

View File

@@ -54,6 +54,10 @@ genPrefs:
theme(select, "Nitter"):
"Theme"
verifiedBadge(select, "Show all"):
"Verified badges"
options: @["Show all", "Show official only", "Hide all"]
infiniteScroll(checkbox, false):
"Infinite scrolling (experimental, requires JavaScript)"

View File

@@ -169,6 +169,14 @@ ul {
}
}
body.hide-verified-all .verified-icon {
display: none !important;
}
body.hide-verified-blue .verified-icon.blue {
display: none !important;
}
@media(max-width: 600px) {
.preferences-container {
max-width: 95vw;

View File

@@ -130,7 +130,9 @@ proc renderMain*(body: VNode; req: Request; cfg: Config; prefs=defaultPrefs;
renderHead(prefs, cfg, req, titleText, desc, video, images, banner, ogTitle,
rss, canonical)
body:
body(class=if prefs.verifiedBadge == "Hide all": "hide-verified-all"
elif prefs.verifiedBadge == "Show official only": "hide-verified-blue"
else: ""):
renderNavbar(cfg, req, rss, canonical)
tdiv(class="container"):