summaryrefslogtreecommitdiffhomepage
path: root/themes/docsy/assets/scss/_code.scss
diff options
context:
space:
mode:
authorIan Lewis <ianmlewis@gmail.com>2019-03-29 22:40:11 -0400
committerIan Lewis <ianmlewis@gmail.com>2019-03-29 22:40:11 -0400
commit22f1890a9beab11d8cfdceba3a4d66f8bbbb468c (patch)
tree110ec3a84a72560244ee4476852295b86a737eb0 /themes/docsy/assets/scss/_code.scss
Initial commit
Diffstat (limited to 'themes/docsy/assets/scss/_code.scss')
-rw-r--r--themes/docsy/assets/scss/_code.scss53
1 files changed, 53 insertions, 0 deletions
diff --git a/themes/docsy/assets/scss/_code.scss b/themes/docsy/assets/scss/_code.scss
new file mode 100644
index 000000000..a5633d353
--- /dev/null
+++ b/themes/docsy/assets/scss/_code.scss
@@ -0,0 +1,53 @@
+// Code formatting.
+
+.td-content {
+ // Highlighted code.
+ .highlight {
+ @extend .card;
+
+ margin: 2rem 0;
+ padding: 1rem;
+ background-color: $gray-100;
+
+ pre, div {
+ background-color: inherit !important;
+ }
+
+ pre {
+ margin: 0;
+ padding: 0;
+ }
+ }
+
+ // Inline code
+ p code, li > code {
+ color: inherit;
+ padding: 0.2em 0.4em;
+ margin: 0;
+ font-size: 85%;
+ background-color: rgba($black, 0.05);
+ border-radius: $border-radius;
+
+ br {
+ display: none;
+ }
+ }
+
+
+ // Code blocks
+ pre {
+ word-wrap: normal;
+ background-color: $gray-100;
+ padding: $spacer;
+
+
+ > code {
+ padding: 0;
+ margin: 0;
+ font-size: 100%;
+ word-break: normal;
+ white-space: pre;
+ border: 0;
+ }
+ }
+} \ No newline at end of file