1
0
Fork 0

improved markdown rendering

This commit is contained in:
Lukas Winkler 2017-09-20 18:49:49 +02:00
parent 9a1f774899
commit c4db4c06dd
2 changed files with 17 additions and 2 deletions

View file

@ -27,7 +27,7 @@ class Markdown extends \Parsedown {
private function purifyHtml($html) {
$config = \HTMLPurifier_Config::createDefault();
$config->set('HTML.Doctype', 'XHTML 1.0 Transitional');
$config->set('HTML.Allowed', 'p,strong,em,b,a[href],i,span,ul,ol,li,cite,code,pre');
$config->set('HTML.Allowed', 'p,strong,em,b,a[href],i,span,ul,ol,li,cite,code,pre,br,blockquote');
$config->set('URI.AllowedSchemes', array('http' => true, 'https' => true, 'mailto' => true, 'ftp' => true));
$config->set('HTML.TargetBlank', true);

View file

@ -14,7 +14,7 @@ $grid-gutter-width: 10px;
color: $gray-700;
}
text-decoration: none;
&:hover,&:focus,&:active {
&:hover, &:focus, &:active {
border: 1px solid rgba(0, 0, 0, 0.5);
background: $gray-200;
}
@ -22,3 +22,18 @@ $grid-gutter-width: 10px;
}
}
}
h1 a {
color: $gray-700;
&:hover, &:focus, &:active {
color: $gray-900;
}
}
blockquote { // bootstrap 3 like styling
padding: 10px 20px;
margin: 0 0 20px;
font-size: 17.5px;
border-left: 5px solid #eee;
}