Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorRich Trott <rtrott@gmail.com>2019-12-23 23:05:47 +0300
committerRich Trott <rtrott@gmail.com>2019-12-27 08:31:52 +0300
commitfdec6bd7449c8ec975e94543133523af19f18162 (patch)
tree63023e91945baaeb35583c89a30ec729ab459e55 /doc
parentce0fb0faaa26aa0095393cb7f7a5a0506cd4cbd6 (diff)
doc: allow <code> in header elements
Allow use of <code> in header elements without styling side effects. We can add styling later if desired. The goal here is to allow code to be set off in markdown without needing to escape characters and do lint exceptions for terms. This is probably a win in terms of accessibility too although it would be moreso if we had some visual differentiation for <code> inside of headers. As mentioned above, that can always be added at a later time. PR-URL: https://github.com/nodejs/node/pull/31086 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'doc')
-rw-r--r--doc/api_assets/style.css35
1 files changed, 20 insertions, 15 deletions
diff --git a/doc/api_assets/style.css b/doc/api_assets/style.css
index 4f1f5c93840..09bc7c988b2 100644
--- a/doc/api_assets/style.css
+++ b/doc/api_assets/style.css
@@ -20,23 +20,28 @@ body {
background-color: #fff;
}
-h1 { font-size: 2.5rem; }
-h2 { font-size: 2rem; }
-h3 { font-size: 1.75rem; }
-h4 { font-size: 1.5rem; }
-h5 { font-size: 1.25rem; }
-h6 { font-size: 1rem; }
-
-h1,
-h2,
-h3,
-h4,
-h5,
-h6 {
- margin: 1.5rem 0 1rem;
- text-rendering: optimizeLegibility;
+h1, h1 code { font-size: 2.5rem; }
+h2, h2 code { font-size: 2rem; }
+h3, h3 code { font-size: 1.75rem; }
+h4, h4 code { font-size: 1.5rem; }
+h5, h5 code { font-size: 1.25rem; }
+h6, h6 code { font-size: 1rem; }
+
+h1, h1 code,
+h2, h2 code,
+h3, h3 code,
+h4, h4 code,
+h5, h5 code,
+h6, h6 code {
+ background-color: inherit;
+ color: inherit;
+ font-family: inherit;
font-weight: 700;
+ line-height: inherit;
position: relative;
+ margin: 1.5rem 0 1rem;
+ padding: inherit;
+ text-rendering: optimizeLegibility;
}
pre,