From 3a062af469f7dfbc5a05c837bb8e070d7d00d183 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Paul=20O=E2=80=99Shannessy?= Date: Tue, 5 Nov 2013 15:04:57 -0800 Subject: [PATCH] Move header link styling out of documentation only It's used in blog posts too. I also constrained it to just the anchor class to avoid any other headers we have. --- _css/react.scss | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/_css/react.scss b/_css/react.scss index 78fb3d7a..a2e0aab3 100644 --- a/_css/react.scss +++ b/_css/react.scss @@ -74,6 +74,24 @@ li { margin-left: 20px; } +// Make header navigation linkable and on the screen. Used in documentation and +// blog posts. +h1, h2, h3, h4, h5, h6 { + &.anchor { + position: relative; + top: -$navHeight; + > a { + color: $darkTextColor; + position: relative; + top: $navHeight; + + &:hover { + text-decoration: underline; + } + } + } +} + // Main Nav .nav-main { @@ -392,22 +410,6 @@ section.black content { font-size: 24px; } - h1, h2, h3, h4, h5, h6 { - &.anchor { - position: relative; - top: -$navHeight; - } - - > a { - color: $darkTextColor; - position: relative; - top: $navHeight; - - &:hover { - text-decoration: underline; - } - } - } // H2s form documentation topic dividers. Extra space helps. h2 {