mirror of
https://github.com/TiddlyWiki/TiddlyWiki5.git
synced 2026-04-30 20:26:52 +00:00
Document the tv-* variables
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
created: 20150221141507000
|
||||
modified: 20150221144853000
|
||||
modified: 20150228103440000
|
||||
tags: [[transclusion Variable]] [[Variable Examples]]
|
||||
title: transclusion Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
This example shows how to distinguish between the sidebar and other environments:
|
||||
|
||||
<$macrocall $name=".example" n="3"
|
||||
<$macrocall $name=".example" n="1"
|
||||
eg="""We are
|
||||
<$list
|
||||
filter="[<transclusion>prefix[{|$:/core/ui/PageTemplate/sidebar|||}]]"
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
created: 20150228135051000
|
||||
modified: 20150228135737000
|
||||
tags: [[tv-config-toolbar-class Variable]] [[Variable Examples]]
|
||||
title: tv-config-toolbar-class Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<style>
|
||||
.green-background {
|
||||
background-color: green;
|
||||
fill: white;
|
||||
}
|
||||
</style>
|
||||
|
||||
<$macrocall $name=".example" n="1"
|
||||
eg="""<$set name="tv-config-toolbar-class" value="tc-btn-invisible">
|
||||
{{$:/core/ui/Buttons/new-tiddler}}
|
||||
</$set>
|
||||
"""/>
|
||||
|
||||
<$macrocall $name=".example" n="2"
|
||||
eg="""<$set name="tv-config-toolbar-class" value="green-background">
|
||||
{{$:/core/ui/Buttons/new-tiddler}}
|
||||
</$set>
|
||||
"""/>
|
||||
|
||||
The `green-background` [[CSS|Cascading Style Sheets]] class is declared in a stylesheet within this tiddler.
|
||||
@@ -0,0 +1,19 @@
|
||||
created: 20150228140420000
|
||||
modified: 20150228141418000
|
||||
tags: [[tv-config-toolbar-icons Variable]] [[Variable Examples]]
|
||||
title: tv-config-toolbar-icons Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<$macrocall $name=".example" n="1"
|
||||
eg="""<$set name="tv-config-toolbar-icons" value="no">
|
||||
<$set name="tv-config-toolbar-text" value="yes">
|
||||
{{$:/core/ui/Buttons/new-tiddler}}
|
||||
</$set>
|
||||
</$set>
|
||||
"""/>
|
||||
|
||||
<$macrocall $name=".example" n="2"
|
||||
eg="""<$set name="tv-config-toolbar-icons" value="yes">
|
||||
{{$:/core/ui/Buttons/new-tiddler}}
|
||||
</$set>
|
||||
"""/>
|
||||
@@ -0,0 +1,17 @@
|
||||
created: 20150228140420000
|
||||
modified: 20150228140516000
|
||||
tags: [[tv-config-toolbar-text Variable]] [[Variable Examples]]
|
||||
title: tv-config-toolbar-text Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<$macrocall $name=".example" n="1"
|
||||
eg="""<$set name="tv-config-toolbar-text" value="no">
|
||||
{{$:/core/ui/Buttons/new-tiddler}}
|
||||
</$set>
|
||||
"""/>
|
||||
|
||||
<$macrocall $name=".example" n="2"
|
||||
eg="""<$set name="tv-config-toolbar-text" value="yes">
|
||||
{{$:/core/ui/Buttons/new-tiddler}}
|
||||
</$set>
|
||||
"""/>
|
||||
@@ -0,0 +1,11 @@
|
||||
created: 20150228124038000
|
||||
tags: [[tv-get-export-image-link Variable]] [[Variable Examples]]
|
||||
title: tv-get-export-image-link Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
This example fetches [[the TiddlyWiki icon|http://www.tiddlywiki.com/favicon.ico]]:
|
||||
|
||||
<$importvariables filter="$:/editions/tw5.com/macro-examples/tv-get-export-image-link">
|
||||
<$codeblock code={{$:/editions/tw5.com/macro-examples/tv-get-export-image-link}}/>
|
||||
<$macrocall $name=".example" n="1" eg="""[img[favicon.ico]]"""/>
|
||||
</$importvariables>
|
||||
@@ -0,0 +1,14 @@
|
||||
created: 20150228115959000
|
||||
modified: 20150228120621000
|
||||
tags: [[tv-wikilink-tooltip Variable]] [[Variable Examples]]
|
||||
title: tv-wikilink-tooltip Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
This example shows a way of giving links a tooltip derived from the target tiddler's <<.field caption>> field:
|
||||
|
||||
<$importvariables filter="$:/editions/tw5.com/macro-examples/tv-wikilink-tooltip">
|
||||
<$codeblock code={{$:/editions/tw5.com/macro-examples/tv-wikilink-tooltip}}/>
|
||||
<$macrocall $name=".example" n="1" eg="""Here is a link to [[backlinks Operator]] with a custom tooltip."""/>
|
||||
</$importvariables>
|
||||
|
||||
Here is [[a standard link|HelloThere]] for comparison.
|
||||
@@ -0,0 +1,17 @@
|
||||
created: 20150228103411000
|
||||
modified: 20150228104438000
|
||||
tags: [[tv-wikilinks Variable]] [[Variable Examples]]
|
||||
title: tv-wikilinks Variable (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<$macrocall $name=".example" n="1"
|
||||
eg="""HelloThere,
|
||||
[[HelloThere]],
|
||||
<$link to="HelloThere">is //this// a link?</$link>"""/>
|
||||
|
||||
<$macrocall $name=".example" n="2"
|
||||
eg="""<$set name="tv-wikilinks" value="no">
|
||||
HelloThere,
|
||||
[[HelloThere]],
|
||||
<$link to="HelloThere">is //this// a link?</$link>
|
||||
</$set>"""/>
|
||||
Reference in New Issue
Block a user