Skip to content

Commit d985848

Browse files
committed
change(shortcodes/ref): add title attribute
1 parent c77db91 commit d985848

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

templates/shortcodes/ref.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{# NOTE: This file MUST NOT contain ANY line-breaks, else shortcode inlining wont work properly. #}{% if not id %}{{ throw(message="Missing id for reference shortcode.") }}{% endif %}{% set defs = load_data(path="@/wiki/references.toml") %}{% if id not in defs %}{% set message = "Definition-Id '" ~ id ~ "' does not exist. Check <a href='/wiki/references'>references</a> file?" %}{{ throw(message=message) }}{% endif %}{% set def = defs[id] %}{% if body %}{% set link_text = body %}{% elif raw %}{% set link_text = def.url %}{% elif def.title %}{% set link_text = def.title %}{% else %}{% set link_text = id %}{% endif %}<a href="{{ def.url | safe }}" target="_blank">{{ link_text | markdown(inline=true) }}</a>
1+
{# NOTE: This file MUST NOT contain ANY line-breaks, else shortcode inlining wont work properly. #}{% if not id %}{{ throw(message="Missing id for reference shortcode.") }}{% endif %}{% set defs = load_data(path="@/wiki/references.toml") %}{% if id not in defs %}{% set message = "Definition-Id '" ~ id ~ "' does not exist. Check <a href='/wiki/references'>references</a> file?" %}{{ throw(message=message) }}{% endif %}{% set def = defs[id] %}{% if body %}{% set link_text = body %}{% elif raw %}{% set link_text = def.url %}{% elif def.title %}{% set link_text = def.title %}{% else %}{% set link_text = id %}{% endif %}<a href="{{ def.url | safe }}" target="_blank" title="{{ def.title }}&#13;#{{id}}&#13;{{ def.url | safe }}">{{ link_text | markdown(inline=true) }}</a>

0 commit comments

Comments
 (0)