mirror of
https://github.com/hacks-guide/minimal-mistakes.git
synced 2024-11-23 00:39:47 +00:00
Add target attribute for navigation link (#3056)
This commit is contained in:
parent
f1ffad4b5e
commit
ceeda03132
3
.gitignore
vendored
3
.gitignore
vendored
@ -2,6 +2,9 @@
|
||||
*~
|
||||
*.sw[p_]
|
||||
|
||||
# IntelliJ IDEA
|
||||
*.idea
|
||||
|
||||
# Sublime Text
|
||||
*.sublime-project
|
||||
*.sublime-workspace
|
||||
|
@ -14,7 +14,11 @@
|
||||
<ul class="visible-links">
|
||||
{%- for link in site.data.navigation.main -%}
|
||||
<li class="masthead__menu-item">
|
||||
<a href="{{ link.url | relative_url }}"{% if link.description %} title="{{ link.description }}"{% endif %}>{{ link.title }}</a>
|
||||
<a
|
||||
href="{{ link.url | relative_url }}"
|
||||
{% if link.description %} title="{{ link.description }}"{% endif %}
|
||||
{% if link.target %} target="{{ link.target }}"{% endif %}
|
||||
>{{ link.title }}</a>
|
||||
</li>
|
||||
{%- endfor -%}
|
||||
</ul>
|
||||
|
@ -30,6 +30,7 @@ main:
|
||||
url: /collection-archive/
|
||||
- title: "External Link"
|
||||
url: https://google.com
|
||||
target: _blank
|
||||
```
|
||||
|
||||
Which will give you a responsive masthead similar to this:
|
||||
|
Loading…
Reference in New Issue
Block a user