浏览代码

Parse Markdown in abstracts (#238)

Janis Klaise 8 年之前
父节点
当前提交
1f69fa61f5
共有 2 个文件被更改,包括 3 次插入3 次删除
  1. 2 2
      layouts/partials/publication_li_detailed.html
  2. 1 1
      layouts/publication/single.html

+ 2 - 2
layouts/partials/publication_li_detailed.html

@@ -32,9 +32,9 @@
 
       <div class="pub-abstract" itemprop="text">
         {{ if .Params.abstract_short }}
-        {{ .Params.abstract_short }}
+        {{ .Params.abstract_short | markdownify }}
         {{ else }}
-        {{ .Params.abstract }}
+        {{ .Params.abstract | markdownify}}
         {{ end }}
       </div>
 

+ 1 - 1
layouts/publication/single.html

@@ -24,7 +24,7 @@
   {{end}}
 
   <h3>{{ i18n "abstract" }}</h3>
-  <p class="pub-abstract" itemprop="text">{{ .Params.abstract }}</p>
+  <p class="pub-abstract" itemprop="text">{{ .Params.abstract | markdownify }}</p>
 
   {{ if (.Params.publication_types) and (ne (index .Params.publication_types 0) "0") }}
   <div class="row">