Skip to content

Commit

Permalink
markdown预览样式添加
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Jul 3, 2015
1 parent 2db3b3e commit b34eff8
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 1 deletion.
31 changes: 31 additions & 0 deletions themes/default/css/MDEditor.min.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
.mdeditor {
position: relative;
font-size: 12px;
font: 13px/1.4 Helvetica, arial, nimbussansl, liberationsans, freesans, clean, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
}
.mdeditor .mde_textarea,
.mdeditor .mde_preview {
Expand Down Expand Up @@ -114,6 +115,7 @@
padding-bottom: 0.3em;
font-size: 1.75em;
line-height: 1.225;
border-bottom: 1px dashed #eee;
}
.markdown_body blockquote {
padding: 0 15px;
Expand Down Expand Up @@ -149,3 +151,32 @@
background-color: #f7f7f7;
border-radius: 3px;
}
.markdown_body pre code {
background-color: transparent;
color: inherit;
}
.markdown_body pre code:before,
.markdown_body pre code:after,
.markdown_body pre tt:before,
.markdown_body pre tt:after {
letter-spacing: 0;
content: "";
}
.markdown_body code,
.markdown_body tt {
padding: 0;
padding-top: 0.2em;
padding-bottom: 0.2em;
margin: 0;
font-size: 85%;
background-color: rgba(0,0,0,0.04);
border-radius: 3px;
color: #c7254e;
}
.markdown_body code:before,
.markdown_body code:after,
.markdown_body tt:before,
.markdown_body tt:after {
letter-spacing: -0.2em;
content: "\00a0";
}
23 changes: 22 additions & 1 deletion themes/default/stylus/MDEditor.styl
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ min-height=200px
.mdeditor
position:relative
font-size:12px
font: 13px/1.4 Helvetica, arial, nimbussansl, liberationsans, freesans, clean, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
.mde_textarea,.mde_preview
min-height:min-height
border-radius: 5px
Expand Down Expand Up @@ -93,6 +94,7 @@ min-height=200px
padding-bottom: 0.3em
font-size: 1.75em
line-height: 1.225
border-bottom:1px dashed #eee
blockquote
padding: 0 15px;
color: #777;
Expand All @@ -113,4 +115,23 @@ min-height=200px
font-size: 85%;
line-height: 1.45;
background-color: #f7f7f7;
border-radius: 3px;
border-radius: 3px;
code
background-color:transparent
color: inherit;

code:before,code:after,tt:before,tt:after
letter-spacing: 0;
content: "";
code,tt
padding: 0
padding-top: 0.2em
padding-bottom: 0.2em
margin: 0
font-size: 85%
background-color: rgba(0,0,0,0.04)
border-radius: 3px
color: #c7254e;
code:before,code:after,tt:before,tt:after
letter-spacing: -0.2em;
content: "\00a0";

0 comments on commit b34eff8

Please sign in to comment.