Skip to content
This repository
Browse code

Use html5 spec stylesheet for docs

  • Loading branch information...
commit 6dbf49110b518b9c8d5d2673a6bd40de501c388e 1 parent 464f5d4
ry ry authored
217 doc/api_assets/specification.css
... ... @@ -0,0 +1,217 @@
  1 +/* WHATWG Green: sRGB #3c790a, rgb(60, 121, 10) */
  2 +
  3 +html { margin: 0; padding: 0; color: black; background: #eeeeee; }
  4 +body { margin: 0 0 30%; padding: 0 1em 2em 8.5em; line-height: 1.35; color: black; background: white top left repeat-y; border-bottom: thin solid #3c790a; }
  5 +
  6 +:link { color: #00C; background: transparent }
  7 +:visited { color: #609; background: transparent }
  8 +:link:active, :visited:active { color: #C00; background: transparent }
  9 +:link:hover, :visited:hover { background: #ffa; }
  10 +code :link, code :visited { color: inherit; }
  11 +
  12 +body, th, td { font-family: sans-serif; }
  13 +
  14 +h1, h2, h3, h4, h5, h6 { text-align: left }
  15 +h1, h2, h3 { color: #3c790a; background: transparent; }
  16 +h1 { font: 900 170% sans-serif }
  17 +h2 { font: 800 140% sans-serif }
  18 +h3 { font: 800 125% sans-serif }
  19 +h4 { font: 800 110% sans-serif }
  20 +h5 { font: 800 100% sans-serif }
  21 +h6 { font: 600 italic 100% sans-serif }
  22 +
  23 +pre { margin-left: 2em; white-space: pre-wrap; }
  24 +h2 { margin: 3em 0 1em 0; }
  25 +h3 { margin: 2.5em 0 1em 0; }
  26 +h4 { margin: 2.5em 0 0.75em 0; }
  27 +h5, h6 { margin: 2.5em 0 1em; }
  28 +h1 + h2, h2 + h3, h3 + h4, h4 + h5, h5 + h6 { margin-top: 0.5em; }
  29 +p { margin: 1em 0; }
  30 +hr { display: block; background: none; border: none; padding: 0; margin: 2em 0; height: auto; }
  31 +dl, dd { margin-top: 0; margin-bottom: 0; }
  32 +dt { margin-top: 0.75em; margin-bottom: 0.25em; clear: left; }
  33 +dt + dt { margin-top: 0; }
  34 +dd dt { margin-top: 0.25em; margin-bottom: 0; }
  35 +dd p { margin-top: 0; }
  36 +dd dl + p { margin-top: 1em; }
  37 +dd table + p { margin-top: 1em; }
  38 +p + * > li, dd li { margin: 1em 0; }
  39 +dt, dfn { font-weight: bold; font-style: normal; }
  40 +dt dfn { font-style: italic; }
  41 +pre, code { font-size: inherit; font-family: monospace; font-variant: normal; }
  42 +pre strong { color: black; font: inherit; font-weight: bold; background: yellow; }
  43 +pre em { font-weight: bolder; font-style: normal; }
  44 +@media screen { code { color: orangered; } }
  45 +var sub { vertical-align: bottom; font-size: smaller; position: relative; top: 0.1em; }
  46 +table { border-collapse: collapse; border-style: hidden hidden none hidden; }
  47 +table thead { border-bottom: solid; }
  48 +table tbody th:first-child { border-left: solid; }
  49 +table td, table th { border-left: solid; border-right: solid; border-bottom: solid thin; vertical-align: top; padding: 0.2em; }
  50 +blockquote { margin: 0 0 0 2em; border: 0; padding: 0; font-style: italic; }
  51 +ins { background: green; color: white; /* color: green; border: solid thin lime; padding: 0.3em; line-height: 1.6em; */ text-decoration: none; }
  52 +del { background: maroon; color: white; /* color: maroon; border: solid thin red; padding: 0.3em; line-height: 1.6em; */ text-decoration: line-through; }
  53 +body ins, body del { display: block; }
  54 +body * ins, body * del { display: inline; }
  55 +
  56 +
  57 +/* classes and other specifics */
  58 +
  59 +.toc dfn, h1 dfn, h2 dfn, h3 dfn, h4 dfn, h5 dfn, h6 dfn { font: inherit; }
  60 +img.extra { float: right; }
  61 +hr.bookmark { border: dashed 2em black; background: yellow; }
  62 +pre.idl { border: solid thin; background: #EEEEEE; color: black; padding: 0.5em 1em; }
  63 +pre.idl :link, pre.idl :visited { color: inherit; background: transparent; }
  64 +pre.css { border: solid thin; background: #FFFFEE; color: black; padding: 0.5em 1em; }
  65 +pre.css:first-line { color: #AAAA50; }
  66 +dl.domintro { color: green; margin: 2em 0 2em 2em; padding: 0.5em 1em; border: none; background: #EEFFEE; }
  67 +hr + dl.domintro, div.impl + dl.domintro { margin-top: 2.5em; margin-bottom: 1.5em; }
  68 +dl.domintro dt, dl.domintro dt * { color: black; text-decoration: none; }
  69 +dl.domintro dd { margin: 0.5em 0 1em 2em; padding: 0; }
  70 +dl.domintro dd p { margin: 0.5em 0; }
  71 +dl.switch { padding-left: 2em; }
  72 +dl.switch > dt { text-indent: -1.5em; }
  73 +dl.switch > dt:before { content: '\21AA'; padding: 0 0.5em 0 0; display: inline-block; width: 1em; text-align: right; line-height: 0.5em; }
  74 +.diff-old { text-decoration: line-through; color: silver; background: transparent; }
  75 +.diff-chg, .diff-new { text-decoration: underline; color: green; background: transparent; }
  76 +a .diff-new { border-bottom: 1px blue solid; }
  77 +
  78 +h2 { page-break-before: always; }
  79 +h1 + h2, hr + h2.no-toc { page-break-before: auto; }
  80 +
  81 +div.head { margin: 0 0 1em; padding: 1em 0 0 0; }
  82 +div.head p { margin: 0; }
  83 +div.head h1 { margin: 0; }
  84 +div.head .logo { float: right; margin: 0 1em; }
  85 +div.head .logo img { border: none } /* remove border from top image */
  86 +div.head dl { margin: 1em 0; }
  87 +p.copyright { font-size: x-small; font-style: oblique; margin: 0; }
  88 +
  89 +body > .toc > li { margin-top: 1em; margin-bottom: 1em; }
  90 +body > .toc.brief > li { margin-top: 0.35em; margin-bottom: 0.35em; }
  91 +body > .toc > li > * { margin-bottom: 0.5em; }
  92 +body > .toc > li > * > li > * { margin-bottom: 0.25em; }
  93 +.toc, .toc li { list-style: none; }
  94 +
  95 +.brief { margin-top: 1em; margin-bottom: 1em; line-height: 1.1; }
  96 +.brief li { margin: 0; padding: 0; }
  97 +.brief li p { margin: 0; padding: 0; }
  98 +
  99 +[title=WIP], [title=TBW] { background: red; color: yellow; padding: 0.1em 0.3em; border: dotted white; margin: 0 0.7em 0 0.2em; }
  100 +[title=SCS] { background: green; color: white; padding: 0.1em 0.3em; border-style: none dashed; margin: 0 0.7em 0 0.2em; }
  101 +[title=WIP] :link, [title=WIP] :visited,
  102 +[title=TBW] :link, [title=TBW] :visited,
  103 +[title=SCS] :link, [title=SCS] :visited { background: transparent; color: inherit; }
  104 +
  105 +.big-issue, .XXX { color: #E50000; background: white; border: solid red; padding: 0.5em; margin: 1em 0; }
  106 +.big-issue > :first-child, .XXX > :first-child { margin-top: 0; }
  107 +p .big-issue, p .XXX { line-height: 3em; }
  108 +.note { color: green; background: transparent; font-family: sans-serif; }
  109 +.warning { color: red; background: transparent; }
  110 +.note, .warning { font-weight: bolder; font-style: italic; }
  111 +p.note, div.note { padding: 0.5em 2em; }
  112 +span.note { padding: 0 2em; }
  113 +.note p:first-child, .warning p:first-child { margin-top: 0; }
  114 +.note p:last-child, .warning p:last-child { margin-bottom: 0; }
  115 +.warning:before { font-style: normal; }
  116 +
  117 +.XXX:before, .XXX:after { content: " ** "; position: absolute; left: 0; width: 8em; text-align: right; }
  118 +p.note:before { content: 'Note: '; }
  119 +p.warning:before { content: '\26A0 Warning! '; }
  120 +
  121 +.applies thead code { display: block; }
  122 +.applies td { text-align: center; }
  123 +.applies .yes { background: yellow; }
  124 +
  125 +.bookkeeping:before { display: block; content: 'Bookkeeping details'; font-weight: bolder; font-style: italic; }
  126 +.bookkeeping { font-size: 0.8em; margin: 2em 0; }
  127 +.bookkeeping p { margin: 0.5em 2em; display: list-item; list-style: square; }
  128 +
  129 +.critical { margin: 1em; border: double thick red; padding: 1em; background: #FFFFCC; }
  130 +.critical > :first-child { margin-top: 0; }
  131 +
  132 +h4 { position: relative; z-index: 3; }
  133 +h4 + .element, h4 + div + .element { margin-top: -2.5em; padding-top: 2em; }
  134 +.element { background: #EEFFEE; color: black; margin: 0 0 1em 0.15em; padding: 0 1em 0.25em 0.75em; border-left: solid #99FF99 0.25em; position: relative; z-index: 1; }
  135 +.element:before { position: absolute; z-index: 2; top: 0; left: -1.15em; height: 2em; width: 0.9em; background: #EEFFEE; content: ' '; border-style: none none solid solid; border-color: #99FF99; border-width: 0.25em; }
  136 +
  137 +.example {
  138 + display: block;
  139 + color: #222222;
  140 + background: #FCFCFC;
  141 + border-left: double;
  142 + margin-left: 2em;
  143 + padding-left: 1em;
  144 +}
  145 +
  146 +.tall-and-narrow {
  147 + font-size: 0.6em;
  148 + column-width: 25em;
  149 + column-gap: 1em;
  150 + -moz-column-width: 25em;
  151 + -moz-column-gap: 1em;
  152 + -webkit-column-width: 25em;
  153 + -webkit-column-gap: 1em;
  154 +}
  155 +
  156 +.hide { display: none }
  157 +
  158 +body.dfnEnabled dfn { cursor: pointer; }
  159 +.dfnPanel {
  160 + display: inline;
  161 + position: absolute;
  162 + height: auto;
  163 + width: auto;
  164 + padding: 0.5em 0.75em;
  165 + font: small sans-serif;
  166 + background: #DDDDDD;
  167 + color: black;
  168 + border: outset 0.2em;
  169 +}
  170 +.dfnPanel * { margin: 0; padding: 0; font: inherit; text-indent: 0; }
  171 +.dfnPanel :link, .dfnPanel :visited { color: black; }
  172 +.dfnPanel p { font-weight: bolder; }
  173 +.dfnPanel * + p { margin-top: 0.25em; }
  174 +.dfnPanel li { list-style-position: inside; }
  175 +
  176 +@media aural {
  177 + h1, h2, h3 { stress: 20; richness: 90 }
  178 + .hide { speak: none }
  179 + p.copyright { volume: x-soft; speech-rate: x-fast }
  180 + dt { pause-before: 20% }
  181 + code, pre { speak-punctuation: code }
  182 +}
  183 +
  184 +@media screen {
  185 + body.draft { background-image: url(http://whatwg.org/images/WD); }
  186 + body.cfc { background-image: url(http://whatwg.org/images/CFC); }
  187 + body.cfi { background-image: url(http://whatwg.org/images/CFI); }
  188 + body.spec { background-image: url(http://whatwg.org/images/REC); }
  189 +}
  190 +
  191 +@media print {
  192 + html { font-size: 10pt; }
  193 + @page { margin: 2cm 0.5cm 2cm 0.5cm; }
  194 + @page :left {
  195 + @bottom-left {
  196 + font: 10pt sans-serif;
  197 + content: counter(page);
  198 + padding-top: 0em;
  199 + vertical-align: top;
  200 + }
  201 + }
  202 + @page :right {
  203 + @bottom-right {
  204 + font: 10pt sans-serif;
  205 + content: counter(page);
  206 + text-align: right;
  207 + vertical-align: top;
  208 + padding-top: 0em;
  209 + }
  210 + }
  211 + .toc a::after { content: leader('.') target-counter(attr(href), page); }
  212 + a[href^="#"]::after { content: " (page " target-counter(attr(href), page) ")"; }
  213 + pre a[href^="#"]::after, blockquote a[href^="#"]::after, var a[href^="#"]::after,
  214 + code a[href^="#"]::after, a[href^="#refs"]::after { content: ""; }
  215 + table { font-size: smaller; }
  216 + :link, :visited { text-decoration: none; color: inherit; background: transparent; }
  217 +}
235 doc/api_assets/style.css
... ... @@ -1,235 +0,0 @@
1   -/*--------------------- Layout and Typography ----------------------------*/
2   -body {
3   -// font-family: "Helvetica Neue", Helvetica, FreeSans, Arial, sans-serif;
4   - font-family: Georgia, FreeSerif, Times, serif;
5   - font-size: 0.9375em;
6   - line-height: 1.4667em;
7   - color: #222;
8   - margin: 0; padding: 0;
9   -}
10   -a {
11   - color: #0050c0;
12   - text-decoration: underline;
13   -}
14   - a:visited {
15   - color: #b950b7;
16   - text-decoration: underline;
17   - }
18   - a:hover, a:focus {
19   - text-decoration: none;
20   - }
21   -
22   - code a:hover {
23   - background: none;
24   - color: #b950b7;
25   - }
26   -
27   -#changelog #gtoc {
28   - display: none;
29   -}
30   -
31   -.notice {
32   - display: block;
33   - padding: 1em;
34   - margin: 1.4667em 0 2.9334em;
35   - background:#FFF6BF;
36   - color:#514721;
37   - border:1px solid #FFD324;
38   -}
39   - .notice p {
40   - margin: 0;
41   - }
42   -
43   -ul.plain {
44   - list-style: none;
45   -}
46   -
47   -abbr {
48   - border-bottom: 1px dotted #454545;
49   -}
50   -
51   -p {
52   - margin: 0 0 1.4667em 0;
53   - position: relative;
54   - text-rendering: optimizeLegibility;
55   -}
56   -
57   -ol, ul, dl {
58   - margin: 0 0 1em 0;
59   - padding: 0;
60   -}
61   -
62   -ol ul, ol ol, ol dl,
63   -ul ul, ul ol, ul dl,
64   -dl ul, dl ol, dl dl {
65   - margin-bottom: 0;
66   -}
67   -
68   -ol p:first-child, ul p:first-child, dl p:first-child {
69   - margin-bottom: 0;
70   -}
71   -
72   -ul, ol {
73   - margin-left: 2em;
74   -}
75   -
76   -
77   -dl dt {
78   - position: relative;
79   - margin: 1.5em 0 0;
80   -}
81   -
82   -dl dd {
83   - position: relative;
84   - margin: 0 1em 0;
85   -}
86   -
87   -dd + dt.pre {
88   - margin-top: 1.6em;
89   -}
90   -
91   -h1, h2, h3, h4, h5, h6 {
92   - font-family: Georgia, FreeSerif, Times, serif;
93   - color: #000;
94   - text-rendering: optimizeLegibility;
95   - position: relative;
96   -}
97   -
98   -h1 {
99   - font-size: 2.55em;
100   - line-height: 1.375em;
101   -}
102   -
103   -h2 {
104   - font-size: 1.9em;
105   - line-height: 1.227em;
106   - margin: 0 0 0.5em;
107   -}
108   -
109   -h3 {
110   - font-size: 1.5em;
111   - line-height: 1.0909em;
112   - margin: 1.5em 0 0.5em;
113   -}
114   -
115   -h3 + h3 {
116   - margin: 0 0 0.5em;
117   -}
118   -
119   -h4 {
120   - font-size: 1.3em;
121   - line-height: 1.1282em;
122   - margin: 2.2em 0 0.5em;
123   -}
124   -
125   -h4 + h4 {
126   - margin: 0 0 0.5em;
127   -}
128   -
129   -h5 {
130   - font-size: 1.125em;
131   - line-height: 1.4em;
132   -}
133   -
134   -h6 {
135   - font-size: 1em;
136   - line-height: 1.4667em;
137   -}
138   -
139   - pre, tt, code {
140   - font-size: 0.95em;
141   - line-height: 1.5438em;
142   - font-family: Monaco, Consolas, "Lucida Console", monospace;
143   - margin: 0; padding: 0;
144   - }
145   -
146   - .pre {
147   - font-family: Monaco, Consolas, "Lucida Console", monospace;
148   - line-height: 1.5438em;
149   - font-size: 0.95em;
150   - }
151   -
152   - pre {
153   - padding: 2em 1.6em 2em 1.2em;
154   - vertical-align: top;
155   - background: #f8f8f8;
156   - border: 1px solid #e8e8e8;
157   - border-width: 1px 1px 1px 6px;
158   - margin: -0.5em 0 1.1em;
159   - }
160   -
161   - pre + h3 {
162   - margin-top: 2.225em;
163   - }
164   -
165   -code.pre {
166   - white-space: pre;
167   -}
168   -
169   -#container {
170   - position: relative;
171   - padding: 6em;
172   - max-width: 50em;
173   - text-align: left;
174   -}
175   -
176   -#container header {
177   - margin: 1.25em -0.5em 1.3em;
178   - padding: 0 0.5em 0.225em;
179   -}
180   -
181   -hr {
182   - background: none;
183   - border: medium none;
184   - border-bottom: 1px solid #ccc;
185   - margin: 5em 0 2em;
186   -}
187   -
188   -#container header hr {
189   - margin: 0;
190   - padding: 0;
191   -}
192   -
193   -#toc {
194   -
195   -}
196   -
197   - #toc h2 {
198   - font-size: 1em;
199   - line-height: 1.4em;
200   - }
201   -
202   - #toc h2 a {
203   - float: right;
204   - }
205   -
206   - #toc hr {
207   - margin: 1em 0 2em;
208   - }
209   -
210   -p tt, p code {
211   - background: #f8f8ff;
212   - border: 1px solid #dedede;
213   - padding: 0 0.2em;
214   -}
215   -
216   -a.octothorpe {
217   - text-decoration: none;
218   - color: #777;
219   - position: absolute;
220   - top: 0; left: -1.4em;
221   - padding: 1px 2px;
222   - opacity: 0;
223   - -webkit-transition: opacity 0.2s linear;
224   -}
225   - p:hover > a.octothorpe,
226   - dt:hover > a.octothorpe,
227   - dd:hover > a.octothorpe,
228   - h1:hover > a.octothorpe,
229   - h2:hover > a.octothorpe,
230   - h3:hover > a.octothorpe,
231   - h4:hover > a.octothorpe,
232   - h5:hover > a.octothorpe,
233   - h6:hover > a.octothorpe {
234   - opacity: 1;
235   - }
5 doc/template.html
@@ -2,8 +2,9 @@
2 2 <html>
3 3 <head>
4 4 <title>{{section}}Node.js Manual &amp; Documentation</title>
5   - <link rel="stylesheet" href="assets/style.css" type="text/css" media="all" />
  5 + <link href="assets/specification.css" rel=stylesheet />
6 6 <link rel="stylesheet" href="assets/sh.css" type="text/css" media="all"/>
  7 +
7 8 </head>
8 9 <body>
9 10 <div id="container">
@@ -20,4 +21,4 @@
20 21 <script type="text/javascript" src="assets/sh_javascript.min.js"></script>
21 22 <script type="text/javascript">highlight(undefined, undefined, 'pre');</script>
22 23 </body>
23   -</html>
  24 +</html>

0 comments on commit 6dbf491

Please sign in to comment.
Something went wrong with that request. Please try again.