Skip to content

Commit 034c233

Browse files
committed
_scss: combine some overlapping rules, and move some to the right section
Signed-off-by: Sebastiaan van Stijn <[email protected]>
1 parent 5cdbdac commit 034c233

File tree

4 files changed

+36
-89
lines changed

4 files changed

+36
-89
lines changed

_scss/_content.scss

Lines changed: 14 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -11,35 +11,39 @@
1111
/*
1212
* Code formatting *************************************************************
1313
*/
14+
pre, code {
15+
background-color: #f5f8fa!important;
16+
color: #0c5176 !important;
17+
}
1418

1519
pre {
16-
background-color: #F5F8FA!important;
20+
border: 0;
21+
border-radius: 4px;
1722
display: block;
1823
padding: 20.5px!important;
1924
margin: 0 0 10px;
2025
font-size: 13px;
2126
line-height: 1.42857143;
22-
color: #333;
2327
word-break: normal !important;
2428
word-wrap: break-word;
25-
border: 0!important;
26-
border-radius: 4px;
29+
30+
code {
31+
overflow-x: auto;
32+
overflow-wrap: normal;
33+
white-space: pre;
34+
}
2735
}
2836

2937
code {
30-
background-color: #F5F8FA!important;
3138
border-radius: 2px;
32-
color: #0c5176 !important;
3339
font-size: 90%;
3440
padding: 3px 7px;
3541
overflow-x: scroll;
3642
white-space: nowrap;
3743
}
3844

39-
pre code {
40-
overflow-x: auto;
41-
overflow-wrap: normal;
42-
white-space: pre;
45+
.highlighter-rouge {
46+
margin: 15px 0;
4347
}
4448

4549
/*
@@ -130,29 +134,3 @@ a.glossary {
130134
text-decoration: none;
131135
}
132136
}
133-
134-
.highlighter-rouge {
135-
margin: 15px 0;
136-
}
137-
138-
code {
139-
padding: 3px 7px;
140-
font-size: 90%;
141-
color: #0c5176!important;
142-
background-color: rgba(12, 81, 118, 0.1);
143-
border-radius: 2px;
144-
}
145-
146-
pre {
147-
display: block;
148-
padding: 9.5px;
149-
margin: 0 0 10px;
150-
font-size: 13px;
151-
line-height: 1.42857143;
152-
color: #333;
153-
word-break: normal!important;
154-
word-wrap: break-word;
155-
background-color: #f5f5f5;
156-
border: 1px solid #ccc;
157-
border-radius: 4px;
158-
}

_scss/_night-mode.scss

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -181,25 +181,21 @@ body.night {
181181
background-color: #2f2f2f;
182182
}
183183
/* force blockquote styles */
184-
blockquote.warning {
184+
blockquote.warning, blockquote.warning p:first-child {
185185
color: #ff7e7a!important;
186186
}
187-
blockquote.warning p:first-child {
188-
color: #ff7e7a!important;
189-
}
190-
blockquote.important {
191-
border-left-color: #f5ac45!important;
192-
}
193-
blockquote.important p:first-child {
187+
blockquote.important, blockquote.important p:first-child {
194188
color: #f5ac45!important;
195189
}
196190

197191
/* syntax highlighting */
198-
.highlight .nt {
192+
.highlight {
193+
.nt {
199194
color: #e8a0e8;
200-
}
201-
.highlight .k {
195+
}
196+
.k {
202197
color: #da5ada;
198+
}
203199
}
204200

205201
/* Primary Global Menu Overrides */

_scss/_overrides.scss

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -148,9 +148,8 @@ img.with-border {
148148
border: 1px solid #eaeaea;
149149
}
150150

151-
.cse input.gsc-search-button:focus,
152-
input.gsc-search-button:focus {
153-
box-shadow:inset 0 0 0 1px rgba(255,255,255,0.5);
151+
input.gsc-search-button, input.gsc-search-button:hover, input.gsc-search-button:focus {
152+
display: none!important;
154153
}
155154

156155
.cse .gsc-search-button input.gsc-search-button-v2,

_scss/_utilities.scss

Lines changed: 13 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,7 @@ table>tbody>tr:nth-of-type(even) {
4040
background-color: #f7f7f7;
4141
}
4242

43-
td,
44-
th {
43+
td {
4544
padding: 10px;
4645
}
4746

@@ -56,6 +55,12 @@ thead {
5655
background: $table-head;
5756
}
5857

58+
/* give tables some breathing room */
59+
.content table {
60+
margin-top: 20px;
61+
margin-bottom: 20px;
62+
}
63+
5964
i.fa.fa-indent,
6065
i.fa.fa-outdent {
6166
color: $white;
@@ -147,10 +152,8 @@ input[type=text] {
147152
*/
148153

149154
div#autocompleteResults {
150-
display: none;
151-
}
155+
display: none; /* toggled through javascript */
152156

153-
div#autocompleteResults {
154157
background: #E6F5FD;
155158
border: 1px solid #eee;
156159
box-shadow: 1px 2px 2px rgba(0, 0, 0, 0.28);
@@ -217,33 +220,11 @@ div#autocompleteResults span {
217220
margin: 0;
218221
}
219222

220-
/*
221-
* google-Results *************************************************************
222-
*/
223-
224-
input.gsc-search-button, input.gsc-search-button:hover, input.gsc-search-button:focus {
225-
display: none!important;
226-
}
227-
228-
229-
@media print
230-
{
231-
.footer
232-
{
233-
display: none !important;
234-
}
235-
.col-toc
236-
{
237-
display: none !important;
238-
}
239-
.col-nav
240-
{
241-
display: none !important;
242-
}
243-
.glyphicon-tags
244-
{
245-
display: none !important;
246-
}
223+
@media print {
224+
.col-nav,
225+
.col-toc,
226+
.footer,
227+
.glyphicon-tags,
247228
.ratings-div
248229
{
249230
display: none !important;
@@ -274,10 +255,3 @@ input.gsc-search-button, input.gsc-search-button:hover, input.gsc-search-button:
274255
opacity: .2;
275256
margin: 10px 15px 0 0;
276257
}
277-
278-
/* Make table headings bold, give tables some breathing room */
279-
280-
.content table {
281-
margin-top: 20px;
282-
margin-bottom: 20px;
283-
}

0 commit comments

Comments
 (0)