1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-12-03 23:09:56 +00:00
TiddlyWiki5/core/wiki/macros/translink.tid
2024-11-21 22:03:15 +08:00

29 lines
761 B
Plaintext

title: $:/core/macros/translink
tags: $:/tags/Macro
\procedure translink(title,mode:"block")
\whitespace trim
<%if [<mode>match[block]] %>
<div class="tc-translink">
<div>
<$link to=<<title>>>
<h1><$text text=<<title>>/></h1>
</$link>
<$transclude tiddler=<<title>> mode="block">
<$set name="currentTiddler" value=<<title>>><$transclude tiddler="$:/language/MissingTiddler/Hint"/></$set>
</$transclude>
</div>
</div>
<%endif%>
<%if [<mode>match[inline]] %>
<span class="tc-translink">
<$link to=<<title>> class="tc-small-gap-right">
<$text text=<<title>>/>
</$link>
(<$transclude tiddler=<<title>> mode="inline">
<$set name="currentTiddler" value=<<title>>><$transclude tiddler="$:/language/MissingTiddler/Hint"/></$set>
</$transclude>)
</span>
<%endif%>
\end