mirror of
https://github.com/snachodog/just-the-docs.git
synced 2025-09-13 05:13:33 -06:00
Add configuration options for opening external links in new tab (#1360)
I've whipped up a solution that solves #1103. I've added a config option `nav_external_links_new_tab`, which is off by default. When turned on, it'll pop external nav links into a new tab. The idea was borrowed from how [aux_nav.html](https://github.com/just-the-docs/just-the-docs/blob/main/_includes/components/aux_nav.html) does it with `aux_links_new_tab`. --------- Co-authored-by: Matt Wang <matt@matthewwang.me>
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
Results in: HTML for the side bar.
|
||||
Includes:
|
||||
title.html, components/site_nav.html, nav_footer_custom.html
|
||||
Overwrites:
|
||||
Overwrites:
|
||||
nav_footer_custom.
|
||||
Should not be cached, because nav_footer_custom.html might depend on page.
|
||||
{%- endcomment -%}
|
||||
@@ -16,9 +16,9 @@
|
||||
<svg viewBox="0 0 24 24" class="icon" aria-hidden="true"><use xlink:href="#svg-menu"></use></svg>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
{% include_cached components/site_nav.html %}
|
||||
|
||||
|
||||
{% capture nav_footer_custom %}
|
||||
{%- include nav_footer_custom.html -%}
|
||||
{% endcapture %}
|
||||
|
Reference in New Issue
Block a user