2022-04-30 09:00:38 +00:00
|
|
|
title: Transclude/CustomWidget/OverrideTransclude
|
|
|
|
description: Custom widget definition attempting to override transclude
|
|
|
|
type: text/vnd.tiddlywiki-multiple
|
|
|
|
tags: [[$:/tags/wiki-test-spec]]
|
|
|
|
|
|
|
|
title: Output
|
|
|
|
|
|
|
|
\whitespace trim
|
|
|
|
<$transclude $tiddler='TiddlerOne' one='Ferret'>
|
|
|
|
</$transclude>
|
|
|
|
_
|
|
|
|
title: TiddlerZero
|
|
|
|
|
|
|
|
Antelope
|
|
|
|
_
|
|
|
|
title: TiddlerOne
|
|
|
|
|
|
|
|
\whitespace trim
|
|
|
|
<!-- Redefine the <$transclude> widget by defining a transcludable variable with that name -->
|
2022-05-02 09:56:22 +00:00
|
|
|
\function <$transclude>(one:'Jaguar')
|
|
|
|
\whitespace trim
|
|
|
|
<$text text=<<one>>/>
|
|
|
|
<$slot $name="body">
|
|
|
|
Whale
|
|
|
|
</$slot>
|
|
|
|
\end
|
|
|
|
<$transclude $tiddler="TiddlerZero">
|
|
|
|
Crocodile
|
|
|
|
</$transclude>
|
2022-04-30 09:00:38 +00:00
|
|
|
_
|
|
|
|
title: ExpectedResult
|
|
|
|
|
|
|
|
<p>Antelope</p>
|