This is an automated email from the ASF dual-hosted git repository.

slachiewicz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-fluido-skin.git

commit bb06de2a79b17fe194897e82177c7a3ce9f76fa7
Author: Sylwester Lachiewicz <[email protected]>
AuthorDate: Tue Nov 3 21:40:19 2026 +0100

    Darken link colours again to reach 4.5:1 on tinted boxes
    
    The move to Bootstrap 5 brought back Bootstrap's link blue #0d6efd,
    which reaches 4.5:1 only on pure white: links in code blocks, cards and
    callouts fell to 4.1-4.3:1. Links are #0a58ca (5.9:1 or more on the
    light boxes) with a darker hover; the dark colour mode keeps Bootstrap's
---
 src/it/sidebar/verify.groovy           |  4 ++++
 src/main/resources/css/maven-theme.css | 18 ++++++++++++++++++
 2 files changed, 22 insertions(+)

diff --git a/src/it/sidebar/verify.groovy b/src/it/sidebar/verify.groovy
index dd492d1..ded5add 100644
--- a/src/it/sidebar/verify.groovy
+++ b/src/it/sidebar/verify.groovy
@@ -83,3 +83,7 @@ assert new File( basedir, "target/site/plugins.html" 
).text.contains( 'id="leftC
 
 // a page in a subdirectory is named by its path from the site root
 assert !new File( basedir, "target/site/guide/overview.html" ).text.contains( 
'id="leftColumn"' )
+
+// links reach 4.5:1 on the light tinted boxes too, not only on white 
(Bootstrap's own #0d6efd does not)
+def fluidoCss = new File( basedir, "target/site/css" ).listFiles().find { 
it.name.startsWith( 'apache-maven-fluido-' ) }
+assert fluidoCss != null && fluidoCss.text.contains( '--bs-link-color: 
#0a58ca;' )
diff --git a/src/main/resources/css/maven-theme.css 
b/src/main/resources/css/maven-theme.css
index f958f0e..1a73b34 100644
--- a/src/main/resources/css/maven-theme.css
+++ b/src/main/resources/css/maven-theme.css
@@ -19,6 +19,24 @@
 
 /* Details on top of Bootstrap 5, in Bootstrap's custom properties so they 
follow the colour mode. */
 
+/* links: Bootstrap's #0d6efd reaches 4.5:1 only on pure white and falls below 
it on the light tinted boxes pages
+   use (code blocks #f8f9fa, cards #fafafa, callouts #fdf3ef). #0a58ca keeps 
5.9:1 or more on all of them, hover
+   #084298 more. In the dark colour mode Bootstrap's #6ea8fe keeps 4.7:1 or 
more up to #343a40; hover #9ec5fe.
+   Links stay underlined in running text (WCAG 1.4.1). */
+:root,
+[data-bs-theme=light] {
+  --bs-link-color: #0a58ca;
+  --bs-link-color-rgb: 10, 88, 202;
+  --bs-link-hover-color: #084298;
+  --bs-link-hover-color-rgb: 8, 66, 152;
+}
+[data-bs-theme=dark] {
+  --bs-link-color: #6ea8fe;
+  --bs-link-color-rgb: 110, 168, 254;
+  --bs-link-hover-color: #9ec5fe;
+  --bs-link-hover-color-rgb: 158, 197, 254;
+}
+
 /* code blocks in a box, as in Fluido 2 */
 pre {
   padding: 9.5px;

Reply via email to