mirror of
https://github.com/gcushen/hugo-academic.git
synced 2025-07-26 19:15:16 +02:00
Improve rendering of post summaries
This commit is contained in:
parent
ea14475b1f
commit
1f77c0572b
4 changed files with 10 additions and 4 deletions
|
@ -18,7 +18,7 @@ Key features:
|
||||||
- Responsive and mobile friendly
|
- Responsive and mobile friendly
|
||||||
- Simple and refreshing one page design
|
- Simple and refreshing one page design
|
||||||
- Easy to customize
|
- Easy to customize
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ title = "Writing content with Markdown, LaTeX, and Shortcodes"
|
||||||
math = true
|
math = true
|
||||||
+++
|
+++
|
||||||
|
|
||||||
Content can be written using [Markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet), [LaTeX math](https://en.wikibooks.org/wiki/LaTeX/Mathematics), and [Hugo Shortcodes](http://gohugo.io/extras/shortcodes/). Additionally, HTML may be used for advanced formatting.
|
Content can be written using [Markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet), [LaTeX math](https://en.wikibooks.org/wiki/LaTeX/Mathematics), and [Hugo Shortcodes](http://gohugo.io/extras/shortcodes/). Additionally, HTML may be used for advanced formatting.<!--more-->
|
||||||
|
|
||||||
## Sub-headings
|
## Sub-headings
|
||||||
|
|
||||||
|
|
|
@ -112,7 +112,7 @@
|
||||||
{{ partial "article_metadata" (dict "content" . "is_list" 1) }}
|
{{ partial "article_metadata" (dict "content" . "is_list" 1) }}
|
||||||
<p class="article-style" itemprop="articleBody">
|
<p class="article-style" itemprop="articleBody">
|
||||||
{{ if .Truncated }}
|
{{ if .Truncated }}
|
||||||
{{ .Summary }}
|
{{ printf "%s" .Summary | markdownify }}
|
||||||
{{ else }}
|
{{ else }}
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
|
@ -14,7 +14,13 @@
|
||||||
{{end}}
|
{{end}}
|
||||||
<h2><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
|
<h2><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
|
||||||
{{ partial "article_metadata" (dict "content" . "is_list" 1) }}
|
{{ partial "article_metadata" (dict "content" . "is_list" 1) }}
|
||||||
<div class="article-style"><p>{{ .Summary }}</p></div>
|
<div class="article-style"><p>
|
||||||
|
{{ if .Truncated }}
|
||||||
|
{{ printf "%s" .Summary | markdownify }}
|
||||||
|
{{ else }}
|
||||||
|
{{ .Content }}
|
||||||
|
{{ end }}
|
||||||
|
</p></div>
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue