On Mar 28, 9:24 am, rakugo <[email protected]> wrote:
> So essentially you want to make use of transclusion in templates to
> access tiddler attributes/fields?
No. I want to create a multi column view, using <<list filter
[tag[myTag]] [sort[sortField]] template:xx>>. Since I have a
widescreen, it is more readable that way.

*Since an old TW will ignore the named parameter, it just creates a
clickable list -> fall back.
*If the right macros are installed it creates a beautiful multicolum
view.

> .. If so I think the problem has always
> been syntax (although I believe Eric makes suggestions in some of his
> plugins for what this should be)
Some pointers? I don't know what you mean.

> If we were to follow the jquery templates suggestion ${text} would
> print the value of the text field on the current tiddler.
I think ${tiddler.text}. But as jQuery templating allows functions it
may be a TiddlySpace security issue. I didn't digg into this, but may
be.

> However don't we have this with the view macro? For instance <<view
> title text>> can be used to print tiddler anywhere. The only problem
> is when one wants to pass a parameter down to another tiddler. For
> instance you might want to do something equivalent to <<tiddler <<view
> image title>> >>.
Didn't think about multi level templates. But IMO it should work.
<<tsScan ...>> does. [1]

> I'm a bit confused by your example however.
> If I understand correctly:
> <<tiddler /%tiddler.title%/ 'dp50'>> wikifies the wikitext of the
> tiddler with a class dp50 
> (seehttp://macros.tiddlyspace.com/#%5B%5Btiddler%20macro%5D%5D)
right.
Since {{tiddler.title}} can't/shouldn't be used in TiddlySpace, I
used /%..%/ as a pseudocode.

> but the same could be achieved in a template via
> {{dp50{
> <<view text wikified>>}}}
>
> no?
no!
<<tiddler asdf 'dp50'>> produces
<span class="dp50" refresh="content" tiddler="asdf">..</span>

which does some nice refreshing if tiddler asdf is changed.

> {{dp50{
> <<view text wikified>>}}}
produces
<div class='dp50'> ...

> {{dp50{<<view text wikified>>}}}
produces
<span class='dp50'> ...

both have a different behaviour.

> I've not played with jquery templates before, but I'm guessing one
> could imagine updating the wikifier to support it.
May be TW5 should use it, instead of the existing ViewTemplate
EditTemplate approach.
@Jeremy?

> For example if we took {£ to signal jquery template markup:
> {£
> {$title}
> £}
> could be wikified to print the title of the current tiddler. This
> would then make the templating engine available to things such as the
> list macro... I'd urge you to attempt it if you have the interest :)
I'd be interested, if it would be possible to have a fallback for
existing TWs and TiddlySpaces, that don't include the right plugins.

I think about something like this %/

/%jQTemplate
!section
...
!
slice:
...
%/

If we (all plugin authors) could agree on a common structure / syntax
for the first line, this syntax has a fallback :)

-m

[1] http://news.tiddlyspace.com/NewsMap.txt

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/tiddlywikidev?hl=en.

Reply via email to