theme: support defining target=_blank in theme_config

add "target": "_blank" to the JSON
This commit is contained in:
Peter Cai 2020-04-11 21:01:23 +08:00
parent f45bd92258
commit 9077e10876
No known key found for this signature in database
GPG key ID: 71F5FB4E4F3FD54F

View file

@ -8,7 +8,7 @@
<section class="links with-divider with-divider-right with-divider-center-mobile"> <section class="links with-divider with-divider-right with-divider-center-mobile">
<ul> <ul>
{{ #each blog.theme_config.nav_links }} {{ #each blog.theme_config.nav_links }}
<li><a href="{{ this.url }}">{{ this.name }}</a></li> <li><a {{ #if this.target }}target="{{ this.target }}"{{ /if }} href="{{ this.url }}">{{ this.name }}</a></li>
{{ /each }} {{ /each }}
</ul> </ul>
</section> </section>