mirror of
https://github.com/gcushen/hugo-academic.git
synced 2025-07-26 03:00:50 +02:00
about widget: Support organization link (#108)
* Add optional `organization_url` to config
This commit is contained in:
parent
823a1bf11b
commit
b7b20820e6
2 changed files with 9 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
baseurl = "https://example.com"
|
||||
title = "Academic Theme"
|
||||
title = "Academic"
|
||||
copyright = "© 2016 Your Name"
|
||||
theme = "academic"
|
||||
enableEmoji = true
|
||||
|
@ -22,6 +22,7 @@ defaultContentLanguageInSubdir = false
|
|||
name = "Lena Smith"
|
||||
role = "Professor of Artificial Intelligence"
|
||||
organization = "Stanford University"
|
||||
organization_url = ""
|
||||
avatar = "portrait.jpg"
|
||||
email = "test@example.org"
|
||||
address = "Building 1 Room 1, Stanford University, California, 90210, USA"
|
||||
|
|
|
@ -15,7 +15,13 @@
|
|||
<div class="portrait-title">
|
||||
<h2 itemprop="name">{{ $.Site.Params.name }}</h2>
|
||||
<h3 itemprop="jobTitle">{{ $.Site.Params.role }}</h3>
|
||||
{{ with $.Site.Params.organization }}<h3 itemprop="worksFor">{{ . }}</h3>{{ end }}
|
||||
{{ if $.Site.Params.organization }}
|
||||
<h3 itemprop="worksFor">
|
||||
{{ with $.Site.Params.organization_url }}<a href="{{ . }}" target="_blank">{{ end }}
|
||||
{{ $.Site.Params.organization }}
|
||||
{{ if $.Site.Params.organization_url }}</a>{{ end }}
|
||||
</h3>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<ul class="social-icon" aria-hidden="true">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue