Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(72)

Side by Side Diff: chrome/common/extensions/docs/static/sass/_article.scss

Issue 148663007: Updated DCC navigation Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 $toc-width: 240px; 1 $article-width: 70%;
2 $toc-margin-left: 195px; 2 $toc-width: 20%;
3 3
4 // Site navigation on all pages
5 .inline-site-toc {
6 line-height: 1.3em;
7
8 a,
9 a:link,
10 a:visited {
11 color: $gray-medium;
12 font-weight: normal;
13
14 &:hover,
15 &:focus {
16 color: $black;
17 }
18 }
19 li li a,
20 li li a:link,
21 li li a:visited {
22 color: $gray-medium;
23
24 &:hover,
25 &:focus {
26 color: $black;
27 }
28 }
29
30 a {
31 @include display-flex();
32 padding: 0.5em 0;
33 }
34
35 .site-related {
36 display: block;
37 background-color: $gray-light;
38 padding: 1em 1em 0.5em 1em;
39 margin-bottom: 1em; /* so the box shadow doesn't get cut off */
40
41 h3 {
42 margin-top: 0;
43 }
44
45 li a {
46 &.active {
47 color: $black;
48 }
49 }
50 }
51
52 #toc {
53 display: block;
54
55 .toplevel {
56 > a {
57 font-weight: bold;
58 color: $black;
59
60 &.hastoc::after {
61 content: '+';
62 @include flex(1);
63 text-align: right;
64 }
65 }
66 }
67
68 //> .toc > li {
69 .toplevel {
70 &.active {
71 .toc {
72 display: block;
73 }
74 > a.hastoc {
75 &::after {
76 content: ''; /* don't make it look like you can toggle it closed */
77 }
78 }
79 }
80 }
81 }
82
83 .toc {
84 margin: 0;
85 padding: 0.3em 0 0 0;
86 border-top: $default-border;
87
88 .toc {
89 display: block;
90 }
91
92 .toc li {
93 padding-left: 1em;
94 border-bottom: $default-border;
95 }
96 }
97 }
98
4 // TOC on article pages 99 // TOC on article pages
5 .inline-toc { 100 .inline-toc {
6 line-height: 1.3em; 101 line-height: 1.3em;
7 102
8 a, 103 a,
9 a:link, 104 a:link,
10 a:visited { 105 a:visited {
11 color: $gray-medium; 106 color: $gray-medium;
12 font-weight: normal; 107 font-weight: normal;
13 108
(...skipping 13 matching lines...) Expand all
27 } 122 }
28 } 123 }
29 124
30 a { 125 a {
31 @include display-flex(); 126 @include display-flex();
32 padding: 0.5em 0; 127 padding: 0.5em 0;
33 } 128 }
34 129
35 .related { 130 .related {
36 display: block; 131 display: block;
132 background-color: $gray-light;
133 padding: 1em 1em 0.5em 1em;
134 margin-bottom: 1em; /* so the box shadow doesn't get cut off */
135
136 h3 {
137 margin-top: 0;
138 }
37 139
38 li a { 140 li a {
39 &.active { 141 &.active {
40 color: $black; 142 color: $black;
41 } 143 }
42 } 144 }
43 } 145 }
44 146
45 #toc { 147 #toc {
46 display: none; 148 display: none;
47 149
48 .toplevel { 150 .toplevel {
49 > a { 151 > a {
50 font-weight: bold; 152 font-weight: bold;
51 color: $black; 153 color: $black;
52 154
53 &.hastoc::after { 155 &.hastoc::after {
54 content: '+'; 156 content: '+';
55 @include flex(1); 157 @include flex(1);
56 text-align: right; 158 text-align: right;
57 } 159 }
58 } 160 }
59 } 161 }
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 width: 90px; 203 width: 90px;
102 height: 32px; 204 height: 32px;
103 } 205 }
104 .last-updated { 206 .last-updated {
105 @include flex(1); 207 @include flex(1);
106 } 208 }
107 } 209 }
108 210
109 // Large than mobile. 211 // Large than mobile.
110 @media only screen and (min-width: $break-small) { 212 @media only screen and (min-width: $break-small) {
111 .inline-toc { 213 .inline-site-toc {
112 position: absolute; 214 position: absolute;
113 top: 0; 215 top: 0;
114 left: 50%;
115 margin-left: $toc-margin-left;
116 width: $toc-width; 216 width: $toc-width;
117 overflow: auto; 217 overflow: auto;
118 overflow-x: hidden; 218 overflow-x: hidden;
119 219
120 // scroll.js adds and removes the floating class depending on the scroll pos ition. 220 #toc {
121 &.sticky { 221 display: block;
122 position: fixed; 222 // article.js adds and removes the fixed nav depending on the scroll posit ion.
123 } 223 }
224 }
225
226 .inline-toc {
227 position: absolute;
228 top: 0;
229 right: 0;
230 width: $toc-width;
231 overflow: auto;
232 overflow-x: hidden;
124 233
125 #toc { 234 #toc {
126 display: block; 235 display: block;
236 // article.js adds and removes the fixed nav depending on the scroll posit ion.
237 &.sticky {
238 top: 0;
239 position: fixed;
240 -webkit-transform: translateZ(0); /* repaint issue */
241 }
127 } 242 }
128 } 243 }
129 .article-content { 244 .article-content {
130 width: 70%; 245 //position: fixed;
246 width: $article-width;
131 padding-right: 5%; 247 padding-right: 5%;
132 border-right: 1px solid $gray-light; 248 border-right: 1px solid $gray-light;
249 min-height: 250px; /* add min-height so fatnav and sidenav doesn't overlap b adly */
133 } 250 }
134 .cc-logo { 251 .cc-logo {
135 margin: 0 0 0 auto; 252 margin: 0 0 0 auto;
136 } 253 }
137 } 254 }
138 255
139 // Tablet 256 // Tablet
140 @media only screen and (min-width: $break-small + 1) and (max-width: $break-larg e) { 257 @media only screen and (min-width: $break-small + 1) and (max-width: $break-larg e) {
141 .inline-toc { 258 .inline-toc {
142 width: $toc-width - 40; 259 width: $toc-width - 40;
143 margin-left: $toc-margin-left - 30; 260 //margin-left: $toc-margin-left - 30;
144 } 261 }
145 } 262 }
146 263
147 // Phone 264 // Phone
148 @media only screen and (max-width: $break-small) { 265 @media only screen and (max-width: $break-small) {
149 .article-content [itemprop="articleBody"] { 266 .article-content [itemprop="articleBody"] {
150 > .collapsible { 267 > .collapsible {
151 height: 58px; 268 height: 58px;
152 overflow: hidden; 269 overflow: hidden;
153 270
(...skipping 17 matching lines...) Expand all
171 position: absolute; 288 position: absolute;
172 right: 0; 289 right: 0;
173 content: '+'; 290 content: '+';
174 } 291 }
175 } 292 }
176 } 293 }
177 .related { 294 .related {
178 margin: $default-padding 0; 295 margin: $default-padding 0;
179 } 296 }
180 } 297 }
298 .hidden {
299 display: none
300 }
181 } 301 }
182 302
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698