Skip to content
Snippets Groups Projects
Commit 5549a15d authored by Matthew Wang's avatar Matthew Wang
Browse files

adds option to make aux links open in new tab

parent 8bd2da55
No related branches found
No related tags found
No related merge requests found
......@@ -38,6 +38,9 @@ aux_links:
"Just the Docs on GitHub":
- "//github.com/pmarsceill/just-the-docs"
# Makes Aux links open in a new tab. Default is false
aux_links_new_tab: false
# Footer content appears at the bottom of every page's main content
footer_content: "Copyright &copy; 2017-2019 Patrick Marsceill. Distributed by an <a href=\"https://github.com/pmarsceill/just-the-docs/tree/master/LICENSE.txt\">MIT license.</a>"
......
......@@ -43,7 +43,15 @@ layout: table_wrappers
{% if site.aux_links != nil %}
<ul class="list-style-none text-small aux-nav">
{% for link in site.aux_links %}
<li class="d-inline-block my-0{% unless forloop.last %} mr-2{% endunless %}"><a href="{{ link.last }}">{{ link.first }}</a></li>
<li class="d-inline-block my-0{% unless forloop.last %} mr-2{% endunless %}">
{% if site.aux_links_new_tab %}
<a href="{{ link.last }}" target="_blank" rel="noopener noreferrer">
{% else %}
<a href="{{ link.last }}">
{% endif %}
{{ link.first }}
</a>
</li>
{% endfor %}
</ul>
{% endif %}
......
......@@ -48,6 +48,9 @@ search_tokenizer_separator: /[\s/]+/
aux_links:
"Just the Docs on GitHub":
- "//github.com/pmarsceill/just-the-docs"
# Makes Aux links open in a new tab. Default is false
aux_links_new_tab: false
```
## Heading anchor links
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment