markdown.less 4.2 KB
.fmt {
  line-height: 1.6;
  word-wrap: break-word;
  color: @mainColor;
}
.fmt a {
  color: #009a61;
  text-decoration: none;
}
.fmt h1 {
  font-size: 2.25em;
}

.fmt h2 {
  font-size: 1.75em;
}

.fmt h3 {
  font-size: 1.5em;
}

.fmt h4 {
  font-size: 1.25em;
}

.fmt h5 {
  font-size: 1em;
}

.fmt h6 {
  font-size: 0.86em;
}
.fmt p {
  margin-top: 0.86em;
  line-height: 1.8em;
}

.fmt h1,
.fmt h2,
.fmt h3,
.fmt h4,
.fmt h5,
.fmt h6 {
  margin-top: 1.2em;
}

.fmt h1 + .widget-codetool + pre,
.fmt h2 + .widget-codetool + pre,
.fmt h3 + .widget-codetool + pre {
  margin-top: 1.2em !important;
}

.fmt h1,
.fmt h2 {
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
}

.fmt > h1:first-child,
.fmt h2:first-child,
.fmt h3:first-child,
.fmt h4:first-child,
.fmt p:first-child,
.fmt ul:first-child,
.fmt ol:first-child,
.fmt blockquote:first-child {
  margin-top: 0;
}

.fmt ul,
.fmt ol {
  margin-left: 2em;
  margin-top: 0.86em;
  padding-left: 0;
}

.fmt ul li,
.fmt ol li {
  margin: 0.3em 0;
  list-style: unset;
}

.fmt ul ul,
.fmt ul ol,
.fmt ol ul,
.fmt ol ol {
  margin-top: 0;
  margin-bottom: 0;
}

.fmt ul p,
.fmt ol p {
  margin: 0;
}

.fmt p:last-child {
  margin-bottom: 0;
}

.fmt p > p:empty,
.fmt div > p:empty,
.fmt p > div:empty,
.fmt div > div:empty,
.fmt div > br:only-child,
.fmt p + br,
.fmt img + br {
  display: none;
}

.fmt img,
.fmt video,
.fmt audio {
  position: static !important;
  max-width: 100%;
}

.fmt img {
  padding: 3px;
  border: 1px solid #ddd;
}

.fmt img.emoji {
  padding: 0;
  border: none;
}

.fmt blockquote {
  border-left: 2px solid #009a61;
  background: @thinBgColor;
  color: @thinColor;
  font-size: 1em;
}

.fmt pre,
.fmt code {
  font-size: 0.93em;
  margin-top: 0.86em;
}

.fmt pre {
  font-family: "Source Code Pro", Consolas, Menlo, Monaco, "Courier New",
    monospace;
  padding: 1em;
  margin-top: 0.86em;
  border: none;
  overflow: auto;
  line-height: 1.45;
  max-height: 35em;
  position: relative;
  background: url("../../images/blueprint.png") rgba(233, 234, 237, 0.5);
  background-size: 30px, 30px;

  font-size: 12px;
  -webkit-overflow-scrolling: touch;
  border-radius: 5px;
}

.fmt pre code {
  background: none;
  font-size: 1em;
  overflow-wrap: normal;
  white-space: inherit;
}

.fmt hr {
  margin: 1.5em auto;
  border-top: 2px dotted #eee;
}

.fmt kbd {
  margin: 0 4px;
  padding: 3px 4px;
  background: #eee;
  color: @thinColor;
}

.fmt .x-scroll {
  overflow-x: auto;
}

.fmt table {
  width: 100%;
}

.fmt table th,
.fmt table td {
  border: 1px solid #e6e6e6;
  padding: 5px 8px;
  word-break: normal;
}

.fmt table th {
  background: #f3f3f3;
}

.fmt a:not(.btn) {
  border-bottom: 1px solid rgba(0, 154, 97, 0.25);
  padding-bottom: 1px;
}

.fmt a:not(.btn):hover {
  border-bottom: 1px solid #009a61;
  text-decoration: none;
}

/*

github.com style (c) Vasily Polovnyov <vast@whiteants.net>

*/

.hljs {
  display: block;
  overflow-x: auto;
  padding: 0.5em;
  color: @mainColor;
  background: #f8f8f8;
}

.hljs-comment,
.hljs-quote {
  color: #998;
  font-style: italic;
}

.hljs-keyword,
.hljs-selector-tag,
.hljs-subst {
  color: @mainColor;
  font-weight: bold;
}

.hljs-number,
.hljs-literal,
.hljs-variable,
.hljs-template-variable,
.hljs-tag .hljs-attr {
  color: #008080;
}

.hljs-string,
.hljs-doctag {
  color: #d14;
}

.hljs-title,
.hljs-section,
.hljs-selector-id {
  color: #900;
  font-weight: bold;
}

.hljs-subst {
  font-weight: normal;
}

.hljs-type,
.hljs-class .hljs-title {
  color: #458;
  font-weight: bold;
}

.hljs-tag,
.hljs-name,
.hljs-attribute {
  color: #000080;
  font-weight: normal;
}

.hljs-regexp,
.hljs-link {
  color: #009926;
}

.hljs-symbol,
.hljs-bullet {
  color: #990073;
}

.hljs-built_in,
.hljs-builtin-name {
  color: #0086b3;
}

.hljs-meta {
  color: @assistColor;
  font-weight: bold;
}

.hljs-deletion {
  background: #fdd;
}

.hljs-addition {
  background: #dfd;
}

.hljs-emphasis {
  font-style: italic;
}

.hljs-strong {
  font-weight: bold;
}