From b9ef8b78396803aa95a2a0e639a90c52bfb760fe Mon Sep 17 00:00:00 2001 From: silverwind Date: Sat, 16 Mar 2024 17:58:58 +0100 Subject: [PATCH] add `.suppressed` link class (#29847) Extract from https://github.com/go-gitea/gitea/pull/29344. With this class it's possible to have links that don't color on hover. It will be useful for https://github.com/go-gitea/gitea/pull/29429. (cherry picked from commit ffeaf2d0bd6c99c486aa7869779bb9ceb0aedad6) --- web_src/css/base.css | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/web_src/css/base.css b/web_src/css/base.css index 4f4aac8a28..07b62c3905 100644 --- a/web_src/css/base.css +++ b/web_src/css/base.css @@ -160,24 +160,32 @@ a { text-decoration-skip-ink: all; } -/* muted link = only colored when hovered */ -/* silenced link = never colored */ +/* a = always colored, underlined on hover */ +/* a.muted = colored on hover, underlined on hover */ +/* a.suppressed = never colored, underlined on hover */ +/* a.silenced = never colored, never underlined */ a.muted, +a.suppressed, a.silenced, .muted-links a { color: inherit; } a:hover, +a.suppressed:hover, a.muted:hover, a.muted:hover [class*="color-text"], .muted-links a:hover { color: var(--color-primary); } -a.silenced:hover { +a.silenced:hover, +a.suppressed:hover { color: inherit; +} + +a.silenced:hover { text-decoration: none; }