// blockquotes
$color-callout: #f4fd9c !default;
+$color-caution: #cf000e !default;
$color-challenge: #eec275 !default;
$color-checklist: #dfd2a0 !default;
$color-discussion: #eec275 !default;
border-radius: 4px 0 0 4px;
}
-.error { @include cdSetup($color-error); }
-.warning { @include cdSetup($color-warning); }
-.output { @include cdSetup($color-output); }
-.source { @include cdSetup($color-source); }
-
-.bash, .language-bash { @include cdSetup($color-source); }
-.make, .language-make { @include cdSetup($color-source); }
-.matlab, .language-matlab { @include cdSetup($color-source); }
-.python, .language-python { @include cdSetup($color-source); }
-.r, .language-r { @include cdSetup($color-source); }
-.sql, .language-sql { @include cdSetup($color-source); }
-
-.error::before,
-.warning:before,
-.output::before,
-.source::before,
-.bash::before, .language-bash::before,
-.make::before, .language-make::before,
-.matlab::before, .language-matlab::before,
-.python::before, .language-python::before,
-.r::before, .language-r::before,
-.sql::before, .language-sql::before {
+// Generic setup. Has to come before .error, .warning, and .output
+div[class^='language-'] { @include cdSetup($color-source); }
+
+div.source { @include cdSetup($color-source); }
+div.error { @include cdSetup($color-error); }
+div.warning { @include cdSetup($color-warning); }
+div.output { @include cdSetup($color-output); }
+
+div.error::before,
+div.warning:before,
+div.output::before,
+div.source::before,
+div[class^='language-']::before {
background-color: #f2eff6;
display: block;
font-weight: bold;
padding: 5px 10px;
}
-.error::before { background-color: #ffebe6; content: "Error"; }
-.warning:before { background-color: #f8f4e8; content:" Warning"; }
-.output::before { background-color: #efefef; content: "Output"; }
-.source::before { content: "Code"; }
-.bash::before, .language-bash::before { content: "Bash"; }
-.make::before, .language-make::before { content: "Make"; }
-.matlab::before, .language-matlab::before { content: "Matlab"; }
-.python::before, .language-python::before { content: "Python"; }
-.r::before, .language-r::before { content: "R"; }
-.sql::before, .language-sql::before { content: "SQL"; }
+div[class^='language-']::before,
+div.source::before { content: "Code"; }
+
+div.error::before { background-color: #ffebe6; content: "Error"; }
+div.warning:before { background-color: #f8f4e8; content:" Warning"; }
+div.output::before { background-color: #efefef; content: "Output"; }
+
+div.language-bash::before { content: "Bash"; }
+div.language-c::before { content: "C"; }
+div.language-cmake::before { content: "CMake"; }
+div.language-cpp::before { content: "C++"; }
+div.language-make::before { content: "Make"; }
+div.language-matlab::before { content: "MATLAB"; }
+div.language-python::before { content: "Python"; }
+div.language-r::before { content: "R"; }
+div.language-sql::before { content: "SQL"; }
// Tab panels are used on Setup pages to show instructions for different Operating Systems
.tab-pane {
border-radius: 4px 4px 0 0; // 4px == @border-radius-base
}
+// adjust line height of links so that clickable area (of OS tabs) is 44px high
+ul.nav.nav-tabs li a { line-height: 24px; } // or 1.714285716
+
// This color provides better contrast ratio on most backgrounds used on Carpentries websites
// 9.24 on FFFFFF: https://webaim.org/resources/contrastchecker/?fcolor=204A6F&bcolor=FFFFFF&api (body)
// 8.78 on F9F9F9: https://webaim.org/resources/contrastchecker/?fcolor=204A6F&bcolor=F9F9F9&api (tables)
// 7.07 on E1E1E1: https://webaim.org/resources/contrastchecker/?fcolor=204A6F&bcolor=E1E1E1&api (tab panels)
a { color: #204A6F; }
+// .yt-wrapper2 can be used for limiting maximum width of YouTube iframes only
+.yt-wrapper2 { max-width: 100%; margin: 0 auto; }
+
+// Use full width on small displays
+@media only screen and (max-width: 600px) { .yt-wrapper2 { max-width: 100%; } }
+
+.yt-wrapper {
+ height: 0;
+ margin-top: 10px;
+ padding-bottom: 56.25%;
+ position: relative;
+ width: 100%;
+}
+
+.yt-frame {
+ height: 100%;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 100%;
+}
+
//----------------------------------------
// Specialized blockquote environments for learning objectives, callouts, etc.
//----------------------------------------
}
.callout{ @include bkSetup($color-callout, "\e146"); }
+.caution{ @include bkSetup($color-caution, "\e107"); }
.challenge{ @include bkSetup($color-challenge, "\270f"); }
.checklist{ @include bkSetup($color-checklist, "\e067"); }
.discussion{ @include bkSetup($color-discussion, "\e123"); }
blockquote { font-size: inherit; }
+a code {
+ color: #006cad;
+}
+
code {
white-space: nowrap;
padding: 2px 5px;
- color: #006cad;
+ color: #24292e;
background-color: #e7e7e7;
}
max-width: 100%;
}
+li img {
+ display: inline;
+ margin: 3px auto;
+ max-width: 100%;
+}
+
article h2 {
margin: 48px 0 16px;
border-bottom: solid 1px #eaecef;
background: #d9edf7;
}
+// Remove border around spans of text within code blocks
+// that the highlighter (rouge) failed to recognize.
+pre.highlight span.err {
+ border: none;
+}
+
//----------------------------------------
// keyboard key style, from StackExchange.