Sfoglia il codice sorgente

style: improve contrast of links in dark sections

George Cushen 6 anni fa
parent
commit
d821bfec76
2 ha cambiato i file con 24 aggiunte e 2 eliminazioni
  1. 23 1
      layouts/partials/css/academic.css
  2. 1 1
      layouts/partials/widget_page.html

+ 23 - 1
layouts/partials/css/academic.css

@@ -490,10 +490,32 @@ a[data-fancybox] img {
 /* Override dark colors that may be inherited from body.dark */
 .home-section.dark,
 .home-section.dark h1,
-.home-section.dark h3 {
+.home-section.dark h2,
+.home-section.dark h3,
+.home-section.dark a:not(.btn):not(.alert a) {
   color: rgb(248, 248, 242);
 }
 
+/* Underline links in dark sections to separate them from text */
+.home-section.dark a:not(.btn):not(.hero-cta-alt):not(.alert a) {
+  text-decoration: underline;
+}
+
+/* Big underline style for links in dark sections */
+.home-section.dark.big-underline a:not(.btn):not(.hero-cta-alt):not(.alert a) {
+  text-decoration: none;
+  position: relative;
+}
+.home-section.dark.big-underline a:not(.btn):not(.hero-cta-alt):not(.alert a):after {
+  background: #fff;
+  content: "";
+  height: 2px;
+  left: 0;
+  right: 0;
+  position: absolute;
+  top: 100%;
+}
+
 /* Create the parallax scrolling effect */
 .parallax {
   height: 100%;

+ 1 - 1
layouts/partials/widget_page.html

@@ -34,7 +34,7 @@
     {{ $style = printf "%sbackground-image: %s url('%s');" $style $darken (printf "img/%s" $bg.image | absURL) }}
   {{ end }}
 
-  {{ with $st.Params.advanced.css_custom }}
+  {{ with $st.Params.advanced.css_style }}
     {{ $style = print $style . }}
   {{ end }}