[tw5] Re: LetWidget with filter attribute value that has spaces
Télumire, I don't need it now, no. But *super* useful to know for the instances where I will need it. Thank you! On Monday, February 7, 2022 at 3:43:17 PM UTC Télumire wrote: > You might also want to throw in a format:titlelist[] just before the join[ > ] if you want to get the titles back later on. > On Monday, 7 February 2022 at 16:35:12 UTC+1 PMario wrote: > >> On Monday, February 7, 2022 at 4:27:17 PM UTC+1 andres@gmail.com >> wrote: >> >>> Thank you so much for your help, Mario! >>> >> >> You are welcome! >> >> >>> This conversation did kick a cog into gear in my head and I realized >>> that the filtered transclusion was returning a list and that is distinct >>> from a string with spaces. so I added a +[join[ ]] to my expression and >>> that got me the result I wanted. >>> >> >> You are right. I could have thought about this myself ... ;) >> >> Thanks for sharing your solution, so others may find it in the future. >> -mario >> > -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/f704b125-8da8-4675-85c4-c205cec45410n%40googlegroups.com.
[tw5] Re: LetWidget with filter attribute value that has spaces
You might also want to throw in a format:titlelist[] just before the join[ ] if you want to get the titles back later on. On Monday, 7 February 2022 at 16:35:12 UTC+1 PMario wrote: > On Monday, February 7, 2022 at 4:27:17 PM UTC+1 andres@gmail.com > wrote: > >> Thank you so much for your help, Mario! >> > > You are welcome! > > >> This conversation did kick a cog into gear in my head and I realized that >> the filtered transclusion was returning a list and that is distinct from a >> string with spaces. so I added a +[join[ ]] to my expression and that got >> me the result I wanted. >> > > You are right. I could have thought about this myself ... ;) > > Thanks for sharing your solution, so others may find it in the future. > -mario > -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/e7595974-6bda-4b79-95f0-f451e6360fb8n%40googlegroups.com.
[tw5] Re: LetWidget with filter attribute value that has spaces
On Monday, February 7, 2022 at 4:27:17 PM UTC+1 andres@gmail.com wrote: > Thank you so much for your help, Mario! > You are welcome! > This conversation did kick a cog into gear in my head and I realized that > the filtered transclusion was returning a list and that is distinct from a > string with spaces. so I added a +[join[ ]] to my expression and that got > me the result I wanted. > You are right. I could have thought about this myself ... ;) Thanks for sharing your solution, so others may find it in the future. -mario -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/dce009f4-8486-446c-9549-f53af22c023cn%40googlegroups.com.
[tw5] Re: LetWidget with filter attribute value that has spaces
Thank you so much for your help, Mario! This conversation did kick a cog into gear in my head and I realized that the filtered transclusion was returning a list and that is distinct from a string with spaces. so I added a +[join[ ]] to my expression and that got me the result I wanted. Which, for the use case where I first encountered this, that actually worked perfectly. <$let n={{{ [[foo]][[bar]] }}}> <> <$let n={{{ [[foo]][[bar]] +[join[ ]] }}}> <> On Monday, February 7, 2022 at 1:59:16 PM UTC PMario wrote: > On Monday, February 7, 2022 at 2:28:54 PM UTC+1 andres@gmail.com > wrote: > >> Thank you. I did solve it already with a SetWidget. I was hoping for a >> solution that would use the LetWidget as is. >> > > If {{{xx}}} is used and there are several results it will always only > apply the first result. That's by design. > > So the following code will all have the same result: *n=foo* > > ``` > <$let n={{{ [[foo]][[bar]] }}}> > <> > > > <$vars n={{{ [[foo]][[bar]] }}}> > <> > > > <$set name=n value={{{ [[foo]][[bar]] }}}> > <> > > ``` > > > >> Essentially I am wondering if the LetWidget is limited to filter results >> with only one returned title. >> > > No. As written above it's how {{{..filter..}}} is resolved. It doesn't > matter which widget you use. You have to use the `<$set name=n > filter="..."` or `<$list filter="..."`, to get several results. > > -mario > -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/9c5ff613-0c1d-4808-ba19-f72db8293ad9n%40googlegroups.com.
[tw5] Re: LetWidget with filter attribute value that has spaces
On Monday, February 7, 2022 at 2:28:54 PM UTC+1 andres@gmail.com wrote: > Thank you. I did solve it already with a SetWidget. I was hoping for a > solution that would use the LetWidget as is. > If {{{xx}}} is used and there are several results it will always only apply the first result. That's by design. So the following code will all have the same result: *n=foo* ``` <$let n={{{ [[foo]][[bar]] }}}> <> <$vars n={{{ [[foo]][[bar]] }}}> <> <$set name=n value={{{ [[foo]][[bar]] }}}> <> ``` > Essentially I am wondering if the LetWidget is limited to filter results > with only one returned title. > No. As written above it's how {{{..filter..}}} is resolved. It doesn't matter which widget you use. You have to use the `<$set name=n filter="..."` or `<$list filter="..."`, to get several results. -mario -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/5a55072b-7074-4105-ace5-30d46520733bn%40googlegroups.com.
[tw5] Re: LetWidget with filter attribute value that has spaces
> Essentially I am wondering if the LetWidget is limited to filter results with only one returned title. Or if there is something that I could learn about writing the expressions or how to quote it. There is always a new way to skin a cat in tiddlywiki! :D! On Monday, February 7, 2022 at 1:28:54 PM UTC andres@gmail.com wrote: > Thank you. I did solve it already with a SetWidget. I was hoping for a > solution that would use the LetWidget as is. > Essentially I am wondering if the LetWidget is limited to filter results > with only one returned title. > > On Monday, February 7, 2022 at 7:44:55 AM UTC PMario wrote: > >> That's a better example >> >> ``` >> <$set name=n filter=" [[foo]][[bar bas]]"> >> >> {{{ [enlist] }}} >> >> <$text text=<>/> >> >> >> ``` >> >> On Monday, February 7, 2022 at 8:43:28 AM UTC+1 PMario wrote: >> >>> Try this >>> >>> ``` >>> <$set name=n filter=" [[foo]][[bar]]"> >>> >>> {{{ [enlist] }}} >>> >>> <> >>> >>> >>> ``` >>> >>> -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/f3528b60-7e4a-4fe9-ad5b-df0239414f3fn%40googlegroups.com.
[tw5] Re: LetWidget with filter attribute value that has spaces
Thank you. I did solve it already with a SetWidget. I was hoping for a solution that would use the LetWidget as is. Essentially I am wondering if the LetWidget is limited to filter results with only one returned title. On Monday, February 7, 2022 at 7:44:55 AM UTC PMario wrote: > That's a better example > > ``` > <$set name=n filter=" [[foo]][[bar bas]]"> > > {{{ [enlist] }}} > > <$text text=<>/> > > > ``` > > On Monday, February 7, 2022 at 8:43:28 AM UTC+1 PMario wrote: > >> Try this >> >> ``` >> <$set name=n filter=" [[foo]][[bar]]"> >> >> {{{ [enlist] }}} >> >> <> >> >> >> ``` >> >> -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/f28d652f-a737-49ca-8597-89a5584ff901n%40googlegroups.com.