Re: [tw] Using the List Widget for OR Operations?

2016-09-18 Thread Jeremy Ruston
Hi Tobias

> How can I do the negating counterpart, e.g. does NOT have any of...?

It's messy; one has to use the emptyMessage attribute:

<$list filter="[is[current] -[has[posters]] -[has[lobbycards]]" 
emptyMessage=<>/>

(Typed on my phone, so may not be 100% correct!)

Best wishes

Jeremy

> 
> There's a PR that would possibly address that use case:
> 
> is[empty] filter operator
> https://github.com/Jermolene/TiddlyWiki5/pull/2186
> 
> I'll leave a comment there to see if I can spark some feedback.
> 
> Best wishes,
> 
> Tobias. 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "TiddlyWiki" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to tiddlywiki+unsubscr...@googlegroups.com.
> To post to this group, send email to tiddlywiki@googlegroups.com.
> Visit this group at https://groups.google.com/group/tiddlywiki.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/fcd6e81d-a394-4ec5-b8ad-35b644bb2326%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/CB7E2A78-1B40-458A-9C58-66DCFDA283CB%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw] Using the List Widget for OR Operations?

2016-09-18 Thread Tobias Beer
Hi Jeremy, 
 

> Try this:
>
> <$list filter="[has[posters]] [
> has[lobbycards]] [has[disccovers]] 
> [has[misc]] 
> +[limit[1]]">
> 
> <$transclude tiddler="$:/_Layout_ButtonSection3"/>
> 
> 
>

How can I do the negating counterpart, e.g. does NOT have any of...?

There's a PR that would possibly address that use case:

*is[empty] filter operator*
https://github.com/Jermolene/TiddlyWiki5/pull/2186

I'll leave a comment there to see if I can spark some feedback.

Best wishes,

Tobias. 

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/fcd6e81d-a394-4ec5-b8ad-35b644bb2326%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw] Using the List Widget for OR Operations?

2016-09-18 Thread PMario
On Saturday, September 17, 2016 at 2:31:02 AM UTC+2, Zaphod Beeblebrox 
wrote:
>
> *PMario said:*
>
>> There are always several methods to achieve something in TW. Using the 
>> list widget as you do here is one of them.
>> IMO the $reveal widget in combination with the tw transclude mechanism 
>> and the transclude widget would be a better fit here. 
>>
>> But this is my impression having a very fast view at the problem. So I'd 
>> need to do some experiments - later today - to be sure.
>>
>  
> I'm always open to new suggestions from those that know more than me 
> (which, when it comes to TW, includes just about everyone! :-P ).
>

I did make some tests, but with the existing reveal widget, it gets more 
complicated than using the list filter to mimic the reveal behaviour. .. So 
imo no different possibility from my side :)

-m



-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/ff0cdb6d-5667-4187-8972-35b283dce9c2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw] Using the List Widget for OR Operations?

2016-09-16 Thread Zaphod Beeblebrox
On Monday, September 12, 2016 at 4:39:57 AM UTC-4, Jeremy Ruston wrote:
>
> Hi Zaphod
>
> Try this:
>
> <$list filter="[has[posters]] [
> has[lobbycards]] [has[disccovers]] 
> [has[misc]] 
> +[limit[1]]">
> 
> <$transclude tiddler="$:/_Layout_ButtonSection3"/>
> 
> 
>
 
Thank You so much, Jeremy - That did the trick nicely :)


*PMario said:*

> There are always several methods to achieve something in TW. Using the 
> list widget as you do here is one of them.
> IMO the $reveal widget in combination with the tw transclude mechanism and 
> the transclude widget would be a better fit here. 
>
> But this is my impression having a very fast view at the problem. So I'd 
> need to do some experiments - later today - to be sure.
>
 
I'm always open to new suggestions from those that know more than me 
(which, when it comes to TW, includes just about everyone! :-P ).

--Zaphod

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/08f669f6-9a72-4897-89a9-11d65ad6edfd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [tw] Using the List Widget for OR Operations?

2016-09-12 Thread Jeremy Ruston
Hi Zaphod

Try this:

<$list filter="[has[posters]] [has[lobbycards]] 
[has[disccovers]] [has[misc]] +[limit[1]]">

<$transclude tiddler="$:/_Layout_ButtonSection3"/>



Best wishes

Jeremy

--
Jeremy Ruston
jer...@jermolene.com
http://jermolene.com

> On 12 Sep 2016, at 08:00, Zaphod Beeblebrox  wrote:
> 
> Hello, everyone :)
> 
> I have been using the List Widget to great effect for determining whether or 
> not to display a particular item, section, link, etc., based on the presence 
> or lack of a certain field within a tiddler:
> 
> <$list filter="[has[zcheader]]">
> {{!!zcheader}}: 
> {{!!zcomment}}
> 
> 
> 
> But now I've run into a dilemma with the last part of a template tiddler that 
> must make a choice of whether to display a section or not, depending on 
> whether ANY ONE of four different fields exist.
> 
> I just can't figure out the syntax to combine three list filters into one (if 
> that can even be done), nor does having three nested lists work.
> 
> Here's the (non-working) last test I made:
> 
> <$list filter="[has[posters]]">
> <$list filter="[has[lobbycards]]">
> <$list filter="[has[disccovers]]">
> <$list filter="[has[misc]]">
> 
> <$transclude tiddler="$:/_Layout_ButtonSection3"/>
> 
> 
> 
> 
> 
> 
> Can anyone shed some light on a solution?
> 
> Thankees in Advance :)
> 
> --Zaphod

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/7C75C57E-8940-4223-B0C6-D015354E7313%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Using the List Widget for OR Operations?

2016-09-12 Thread Zaphod Beeblebrox
Hello, everyone :)

I have been using the List Widget to great effect for determining whether 
or not to display a particular item, section, link, etc., based on the 
presence or lack of a certain field within a tiddler:

<$list filter="[has[zcheader]]">
{{!!zcheader}}: 
{{!!zcomment}}



But now I've run into a dilemma with the last part of a template tiddler 
that must make a choice of whether to display a section or not, depending 
on whether ANY ONE of four different fields exist.

I just can't figure out the syntax to combine three list filters into one 
(if that can even be done), nor does having three nested lists work.

Here's the (non-working) last test I made:

<$list filter="[has[posters]]">
<$list filter="[has[lobbycards]]">
<$list filter="[has[disccovers]]">
<$list filter="[has[misc]]">

<$transclude tiddler="$:/_Layout_ButtonSection3"/>






Can anyone shed some light on a solution?

Thankees in Advance :)

--Zaphod

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/b577e413-c297-43f2-8e22-d16680cbd178%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.