From 4c856bd5a07cce27e50b3c32ea95075f3b887558 Mon Sep 17 00:00:00 2001 From: alex-ketch Date: Thu, 12 Sep 2019 16:20:56 -0400 Subject: [PATCH] fix(Stencila): Add common theme dependencies --- src/common/styles/common.css | 13 +++++-------- src/themes/stencila/styles.css | 13 ++++++++++++- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/src/common/styles/common.css b/src/common/styles/common.css index d05ae62e3..9bc9545aa 100644 --- a/src/common/styles/common.css +++ b/src/common/styles/common.css @@ -6,14 +6,11 @@ @import './citations.css'; -article { - label:first-of-type { - position: sticky; - top: 0; - text-align: right; - padding: 12px 24px; - background: #fff; - z-index: 1; +:--code-chunk { + pre, + pre[class*='language-'] { + background-color: transparent; + height: 100%; } } diff --git a/src/themes/stencila/styles.css b/src/themes/stencila/styles.css index 63fa8c8a8..fc464986d 100644 --- a/src/themes/stencila/styles.css +++ b/src/themes/stencila/styles.css @@ -1,3 +1,4 @@ +@import '../../common/styles/common.css'; @import 'prismjs/themes/prism.css'; @import '../../common/fonts/merriweather/merriweather.css'; @@ -217,10 +218,20 @@ article > figure, :--code-chunk { max-width: var(--max-width-media); + + pre, + code, + pre[class*='language-'], + code[class*='language-'] { + font-family: var(--font-family-mono); + } } -article > pre { +article > pre, +body > pre, +main > pre { background-color: #fff; + padding: 1rem; } pre {