Stackedit/src/styles/base.scss

278 lines
3.9 KiB
SCSS
Raw Normal View History

2018-05-06 00:46:33 +00:00
@import '../../node_modules/normalize-scss/sass/normalize';
@import './variables';
2017-07-23 18:42:08 +00:00
@include normalize();
html,
body {
2018-01-14 16:27:06 +00:00
color: $body-color-light;
font-size: 16px;
2017-07-25 18:20:52 +00:00
font-family: $font-family-main;
2017-07-23 18:42:08 +00:00
font-variant-ligatures: common-ligatures;
2017-07-25 23:34:01 +00:00
line-height: $line-height-base;
2017-07-23 18:42:08 +00:00
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
2018-01-14 16:27:06 +00:00
.app--dark .layout__panel--editor,
.app--dark .layout__panel--preview {
color: $body-color-dark;
}
2017-07-23 18:42:08 +00:00
p,
blockquote,
pre,
ul,
ol,
dl {
margin: 1.2em 0;
}
2017-07-25 18:20:52 +00:00
h1,
h2,
h3,
h4,
h5,
h6 {
margin: 1.8em 0;
2017-07-25 23:34:01 +00:00
line-height: $line-height-title;
2017-07-25 18:20:52 +00:00
}
h1,
h2 {
&::after {
content: '';
display: block;
position: relative;
top: 0.33em;
border-bottom: 1px solid $hr-color;
}
2017-07-25 23:34:01 +00:00
}
2017-07-23 18:42:08 +00:00
ol ul,
ul ol,
ul ul,
ol ol {
margin: 0;
}
dt {
font-weight: bold;
}
2017-07-23 18:42:08 +00:00
a {
color: $link-color;
text-decoration: underline;
text-decoration-skip: ink;
2017-07-25 18:20:52 +00:00
&:hover,
&:focus {
text-decoration: none;
2017-07-25 18:20:52 +00:00
}
2017-07-23 18:42:08 +00:00
}
code,
pre,
samp {
font-family: $font-family-monospace;
font-size: $font-size-monospace;
* {
font-size: inherit;
}
}
blockquote {
2017-07-25 08:19:39 +00:00
color: rgba(0, 0, 0, 0.5);
padding-left: 1.5em;
border-left: 5px solid rgba(0, 0, 0, 0.075);
2018-01-14 16:27:06 +00:00
.app--dark .layout__panel--editor &,
.app--dark .layout__panel--preview & {
color: rgba(255, 255, 255, 0.4);
border-left-color: rgba(255, 255, 255, 0.075);
}
2017-07-23 18:42:08 +00:00
}
code {
background-color: $code-bg;
border-radius: $border-radius-base;
padding: 2px 4px;
}
hr {
border: 0;
2017-07-25 18:20:52 +00:00
border-top: 1px solid $hr-color;
2017-07-23 18:42:08 +00:00
margin: 2em 0;
}
pre > code {
background-color: $code-bg;
display: block;
padding: 0.5em;
-webkit-text-size-adjust: none;
2018-04-05 22:57:50 +00:00
overflow-x: auto;
white-space: pre;
2017-07-23 18:42:08 +00:00
}
.toc ul {
list-style-type: none;
padding-left: 20px;
}
table {
background-color: transparent;
border-collapse: collapse;
border-spacing: 0;
}
td,
th {
border-right: 1px solid #dcdcdc;
2017-07-23 18:42:08 +00:00
padding: 8px 12px;
&:last-child {
border-right: 0;
}
}
td {
border-top: 1px solid #dcdcdc;
2017-07-23 18:42:08 +00:00
}
2018-04-15 17:13:03 +00:00
mark {
background-color: #f8f840;
}
2017-07-23 18:42:08 +00:00
kbd {
font-family: $font-family-main;
2017-07-23 18:42:08 +00:00
background-color: #fff;
border: 1px solid rgba(63, 63, 63, 0.25);
border-radius: 3px;
box-shadow: 0 1px 0 rgba(63, 63, 63, 0.25);
color: #333;
display: inline-block;
font-size: 0.8em;
2017-07-23 18:42:08 +00:00
margin: 0 0.1em;
padding: 0.1em 0.6em;
white-space: nowrap;
}
abbr {
&[title] {
border-bottom: 1px dotted #777;
cursor: help;
}
}
img {
max-width: 100%;
}
2018-04-06 13:07:30 +00:00
.task-list-item {
list-style-type: none;
}
.task-list-item-checkbox {
margin: 0 0.2em 0 -1.3em;
}
2017-07-23 18:42:08 +00:00
.footnote {
font-size: 0.8em;
position: relative;
top: -0.25em;
vertical-align: top;
}
2017-11-17 00:38:55 +00:00
.page-break-after {
page-break-after: always;
}
.stackedit__html {
2017-07-23 18:42:08 +00:00
margin-bottom: 180px;
margin-left: auto;
margin-right: auto;
padding-left: 30px;
padding-right: 30px;
2017-11-05 01:21:35 +00:00
max-width: 750px;
}
.stackedit__toc {
ul {
padding: 0;
a {
margin: 0.5rem 0;
padding: 0.5rem 1rem;
}
ul {
color: #888;
font-size: 0.9em;
a {
margin: 0;
padding: 0.1rem 1rem;
}
}
}
li {
display: block;
}
a {
display: block;
color: inherit;
text-decoration: none;
&:active,
&:focus,
&:hover {
background-color: rgba(0, 0, 0, 0.075);
border-radius: $border-radius-base;
}
}
}
.stackedit__left {
position: fixed;
display: none;
width: 250px;
2018-03-09 21:18:20 +00:00
height: 100%;
top: 0;
left: 0;
overflow-x: hidden;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
-ms-overflow-style: none;
2017-07-23 18:42:08 +00:00
@media (min-width: 1060px) {
display: block;
2017-07-23 18:42:08 +00:00
}
}
.stackedit__right {
position: absolute;
right: 0;
top: 0;
left: 0;
@media (min-width: 1060px) {
left: 250px;
}
}
.stackedit--pdf {
blockquote {
// wkhtmltopdf doesn't like borders with transparency
border-left-color: #ececec;
}
.stackedit__html {
padding-left: 0;
padding-right: 0;
2017-11-05 01:21:35 +00:00
max-width: none;
2017-07-23 18:42:08 +00:00
}
}