From 856fe9e8c74e7c8096f7fb04d7b0932171223752 Mon Sep 17 00:00:00 2001 From: r Date: Sun, 8 Nov 2020 13:13:05 +0000 Subject: Fix CSS issues - fix text wrapping on reply popup - fix margin for media links --- static/fluoride.js | 20 ++++++++++---------- static/style.css | 18 +++++++----------- 2 files changed, 17 insertions(+), 21 deletions(-) (limited to 'static') diff --git a/static/fluoride.js b/static/fluoride.js index e055b6d..c1eb06f 100644 --- a/static/fluoride.js +++ b/static/fluoride.js @@ -132,13 +132,13 @@ function isInView(el) { return false; } -function handleReplyToLink(div) { - if (!div) +function handleReplyToLink(a) { + if (!a) return; - var id = div.firstElementChild.getAttribute("href"); + var id = a.getAttribute("href"); if (!id || id[0] != "#") return; - div.firstElementChild.onmouseenter = function(event) { + a.onmouseenter = function(event) { var id = event.target.getAttribute("href"); var status = document.querySelector(id); if (!status) @@ -156,7 +156,7 @@ function handleReplyToLink(div) { event.target.parentElement.appendChild(copy); } } - div.firstElementChild.onmouseleave = function(event) { + a.onmouseleave = function(event) { var popup = document.getElementById("reply-to-popup"); if (popup) { event.target.parentElement.removeChild(popup); @@ -168,8 +168,8 @@ function handleReplyToLink(div) { } } -function handleReplyLink(div) { - div.firstElementChild.onmouseenter = function(event) { +function handleReplyLink(a) { + a.onmouseenter = function(event) { var id = event.target.getAttribute("href"); var status = document.querySelector(id); if (!status) @@ -187,7 +187,7 @@ function handleReplyLink(div) { event.target.parentElement.appendChild(copy); } } - div.firstElementChild.onmouseleave = function(event) { + a.onmouseleave = function(event) { var popup = document.getElementById("reply-popup"); if (popup) { event.target.parentElement.removeChild(popup); @@ -219,10 +219,10 @@ document.addEventListener("DOMContentLoaded", function() { var retweetForm = s.querySelector(".status-retweet"); handleRetweetForm(id, retweetForm); - var replyToLink = s.querySelector(".status-reply-to"); + var replyToLink = s.querySelector(".status-reply-to-link"); handleReplyToLink(replyToLink); - var replyLinks = s.querySelectorAll(".status-reply"); + var replyLinks = s.querySelectorAll(".status-reply-link"); for (var j = 0; j < replyLinks.length; j++) { handleReplyLink(replyLinks[j]); } diff --git a/static/style.css b/static/style.css index 9d4c94c..cd37067 100644 --- a/static/style.css +++ b/static/style.css @@ -41,7 +41,6 @@ max-width: 280px; vertical-align: bottom; object-fit: contain; - margin-bottom: 5px; } .status-media-container { @@ -49,6 +48,11 @@ overflow: auto; } +.status-media-container>a { + margin-bottom: 5px; + display: inline-block; +} + .status-profile-img-container { margin-right: 8px; display: inline-block; @@ -187,16 +191,12 @@ margin-left: 8px; } -.status-reply-to { - display: inline-block; -} - .status-reply-to-link { font-size: 10pt } .status-reply-container { - word-break: break-all; + overflow-wrap: break-word; } .status-reply-container .fa { @@ -209,10 +209,6 @@ font-size: 10pt; } -.status-reply { - display: inline-block; -} - .status-reply-link { font-size: 10pt; } @@ -256,6 +252,7 @@ } .user-profile-decription { + overflow-wrap: break-word; margin: 8px 0; } @@ -315,7 +312,6 @@ a:hover, bottom: 0; left: 0; right: 0; - margin-bottom: 5px; } .img-link:hover .status-nsfw-overlay { -- cgit v1.2.3 From 37b1c750454a780ef31a26d19005e5c94a39ae9b Mon Sep 17 00:00:00 2001 From: r Date: Sat, 14 Nov 2020 17:58:34 +0000 Subject: Fix link targets --- static/fluoride.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'static') diff --git a/static/fluoride.js b/static/fluoride.js index c1eb06f..36a374f 100644 --- a/static/fluoride.js +++ b/static/fluoride.js @@ -200,8 +200,9 @@ function handleReplyLink(a) { function handleStatusLink(a) { if (a.classList.contains("mention")) - return; - a.target = "_blank"; + a.removeAttribute("target"); + else + a.target = "_blank"; } document.addEventListener("DOMContentLoaded", function() { @@ -232,6 +233,11 @@ document.addEventListener("DOMContentLoaded", function() { handleStatusLink(links[j]); } } + + var links = document.querySelectorAll(".user-profile-decription a"); + for (var j = 0; j < links.length; j++) { + links[j].target = "_blank"; + } }); // @license-end -- cgit v1.2.3 From 7f2df6c2047b81bc7476293ceba3df9aec15dfd6 Mon Sep 17 00:00:00 2001 From: r Date: Sun, 22 Nov 2020 17:40:19 +0000 Subject: Fix CSS --- static/style.css | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'static') diff --git a/static/style.css b/static/style.css index cd37067..610ecbf 100644 --- a/static/style.css +++ b/static/style.css @@ -231,7 +231,7 @@ .user-profile-img-container { display: inline-block; - margin: 0 4px 0 0; + margin: 0 4px 4px 0; } .user-profile-details-container { @@ -321,7 +321,7 @@ a:hover, .status-video-container { display: inline-block; position: relative; - margin: 2.5px 0; + margin-bottom: 5px; } .status-video-container:hover .status-nsfw-overlay { @@ -422,7 +422,7 @@ img.emoji { margin: 4px 0; } -.settings-form-field * { +.settings-form-field>* { vertical-align: middle; } -- cgit v1.2.3 From 87e31dbd6688f8e4492d3dc17783c26f2d926e4b Mon Sep 17 00:00:00 2001 From: r Date: Sat, 16 Jan 2021 10:25:34 +0000 Subject: Make like/retweet notification content semi-transparent --- static/style.css | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'static') diff --git a/static/style.css b/static/style.css index 610ecbf..c313c80 100644 --- a/static/style.css +++ b/static/style.css @@ -173,6 +173,17 @@ font-size: 13pt; } +.notification-container { + margin: 0 -4px 12px -4px; + padding: 4px; + border-left: 4px solid transparent; +} + +.notification-container.favourite .status-container, +.notification-container.reblog .status-container { + opacity: 0.6; +} + .notification-info-text span { vertical-align: middle; } -- cgit v1.2.3 From e8bfd3093b0bf16c2ce56b3905ea640aa26d0127 Mon Sep 17 00:00:00 2001 From: r Date: Sat, 16 Jan 2021 18:30:23 +0000 Subject: Fix unread notification indicator --- static/style.css | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'static') diff --git a/static/style.css b/static/style.css index c313c80..5002fd6 100644 --- a/static/style.css +++ b/static/style.css @@ -4,8 +4,7 @@ border-left: 4px solid transparent; } -.status-container-container:target, -.status-container-container.unread { +.status-container-container:target { border-color: #777777; } @@ -179,6 +178,10 @@ border-left: 4px solid transparent; } +.notification-container.unread { + border-color: #777777; +} + .notification-container.favourite .status-container, .notification-container.reblog .status-container { opacity: 0.6; -- cgit v1.2.3 From ace344b66ac42a3fa80c8e0dffb485dbeb88ff92 Mon Sep 17 00:00:00 2001 From: r Date: Sun, 17 Jan 2021 08:55:19 +0000 Subject: Change default theme colors --- static/style.css | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'static') diff --git a/static/style.css b/static/style.css index 5002fd6..1921f5e 100644 --- a/static/style.css +++ b/static/style.css @@ -1,3 +1,7 @@ +body { + background-color: #d2d2d2; +} + .status-container-container { margin: 0 -4px 12px -4px; padding: 4px; @@ -295,7 +299,7 @@ a, .btn-link { a:hover, .btn-link:hover { - color: #9899c4; + color: #8387bf; } .status-visibility { @@ -446,7 +450,7 @@ img.emoji { #reply-popup { position: absolute; - background: #ffffff; + background-color: #d2d2d2; border: 1px solid #aaaaaa; padding: 4px 8px; z-index: 3; @@ -455,7 +459,7 @@ img.emoji { #reply-to-popup { position: absolute; - background: #ffffff; + background-color: #d2d2d2; border: 1px solid #aaaaaa; padding: 4px 8px; z-index: 3; @@ -475,7 +479,7 @@ img.emoji { .more-content { display: none; position: absolute; - background-color: #ffffff; + background-color: #d2d2d2; padding: 2px 4px; border: 1px solid #aaaaaa; } -- cgit v1.2.3