diff --git a/layouts/partials/css/academic.css b/layouts/partials/css/academic.css index 068f4b6e..a5d9b0af 100644 --- a/layouts/partials/css/academic.css +++ b/layouts/partials/css/academic.css @@ -48,6 +48,19 @@ body { } } +.max-width-640 { + max-width: 640px; +} + +.margin-auto { + margin-left: auto; + margin-right: auto; +} + +.center-text { + text-align: center; +} + /* Body text */ p { margin-top: 0; @@ -606,14 +619,19 @@ article { } .article-metadata { - margin-bottom: 20px; - line-height: 30px; /* Match share bar line height. */ + margin-bottom: 15px; overflow: hidden; font-size: 14px; letter-spacing: 0.03em; color: #888; } +/* For article page only, not lists. */ +article .article-metadata { + margin-bottom: 20px; + line-height: 30px; /* Match share bar line height. */ +} + .article-metadata a { color: #888; } @@ -622,18 +640,6 @@ article { color: {{ .Get "primary" }}; } -.article-list-item { - margin-bottom: 40px; -} - -.article-list-item:last-child { - margin-bottom: 0 !important; -} - -.article-list-item .article-metadata { - margin-bottom: 5px; -} - .middot-divider { padding-right: .45em; padding-left: .45em; @@ -706,10 +712,6 @@ article { margin-right: auto; } -.pub .pub-title { - margin-bottom: 5px; -} - .pub .pub-authors { font-style: italic; line-height: 30px; /* Match share bar line height. */ @@ -719,10 +721,6 @@ article { font-weight: bold; } -.pub-list-item { - margin-bottom: 40px; -} - .pub-list-item .pub-abstract { font-size: 1rem; } @@ -811,6 +809,29 @@ article { * Card component **************************************************/ +.card-simple { + background: #fff; + box-shadow: 0 1px 4px rgba(0,0,0,.04); + border: 1px solid rgba(0,0,0,.09); + border-radius: 3px; + margin-top: 20px; + padding: 15px 20px 15px 20px; +} + +.card-simple:first-of-type { + margin-top: 0; +} + +.card-simple p.read-more { + margin: 0; +} + +.dark .card-simple { + background: rgb(40, 42, 54); + box-shadow: 0 1px 4px rgba(0,0,0,.04); + border: 1px solid rgb(68, 71, 90); +} + .card { margin-bottom: 1.5rem; overflow: hidden; diff --git a/layouts/partials/post_li.html b/layouts/partials/post_li.html index 92ea55e0..c457e66f 100644 --- a/layouts/partials/post_li.html +++ b/layouts/partials/post_li.html @@ -1,6 +1,8 @@ {{ $post := .post }} -
+
+ {{ partial "article_metadata" (dict "content" $post "is_list" 1) }} + {{ $preview := $post.Params.header.preview | default true }} {{ if and $post.Params.header.image $preview }} @@ -10,7 +12,6 @@

- {{ partial "article_metadata" (dict "content" $post "is_list" 1) }}
{{ if $post.Params.summary }}

{{ printf "%s" $post.Params.summary | markdownify }}

diff --git a/layouts/partials/publication_li_detailed.html b/layouts/partials/publication_li_detailed.html index 4a426583..4746da33 100644 --- a/layouts/partials/publication_li_detailed.html +++ b/layouts/partials/publication_li_detailed.html @@ -1,62 +1,47 @@ -
-
+
- {{ if .Params.image_preview }} - -
- - - -
-
- - {{ else if .Params.header.image}} - -
- - - -
-
- - {{ else }} - -
- - {{ end }} - -

- -

- -
- {{ if .Params.abstract_short }} - {{ .Params.abstract_short | markdownify }} - {{ else }} - {{ .Params.abstract | markdownify}} - {{ end }} -
- - - -
- {{ if .Params.publication_short }} - {{- .Params.publication_short | markdownify -}}, - {{ else if .Params.publication }} - {{- .Params.publication | markdownify -}}, - {{- end -}} - {{- .Date.Format "2006" -}} -
- - - -
+ {{ if .Params.image_preview }} + {{ .Scratch.Set "image" .Params.image_preview }} + {{ else if .Params.header.image }} + {{ .Scratch.Set "image" .Params.header.image }} + {{ end }} + {{ if .Scratch.Get "image" }} + + {{ end }} + +

+ +

+ +
+ {{ if .Params.abstract_short }} + {{ .Params.abstract_short | markdownify }} + {{ else }} + {{ .Params.abstract | markdownify}} + {{ end }} +
+ + + +
+ {{ if .Params.publication_short }} + {{- .Params.publication_short | markdownify -}}, + {{ else if .Params.publication }} + {{- .Params.publication | markdownify -}}, + {{- end -}} + {{- .Date.Format "2006" -}} +
+ + +
diff --git a/layouts/partials/talk_li_detailed.html b/layouts/partials/talk_li_detailed.html index 2e9f091a..35a9998f 100644 --- a/layouts/partials/talk_li_detailed.html +++ b/layouts/partials/talk_li_detailed.html @@ -1,66 +1,51 @@ -
-
+
- {{ if .Params.image_preview }} - -
- - - -
-
- - {{ else if .Params.header.image}} - -
- - - -
-
- - {{ else }} - -
- - {{ end }} - -

- -

- - - - - -
- {{ if .Params.abstract_short }} - {{ .Params.abstract_short | markdownify }} - {{ else }} - {{ .Params.abstract | markdownify }} - {{ end }} -
- - - -
+ {{ if .Params.image_preview }} + {{ .Scratch.Set "image" .Params.image_preview }} + {{ else if .Params.header.image }} + {{ .Scratch.Set "image" .Params.header.image }} + {{ end }} + {{ if .Scratch.Get "image" }} + + {{ end }} + +

+ +

+ + + + + +
+ {{ if .Params.abstract_short }} + {{ .Params.abstract_short | markdownify }} + {{ else }} + {{ .Params.abstract | markdownify }} + {{ end }} +
+ + +