Anyway, you can begin with this:

Title: *PopulateStory*
Tags: *$:/tags/SideBar*
Text:
<$vars limit={{{ [[$:/state/limit]is[tiddler]then{$:/state/limit}else[10]] 
}}}>

<$range tiddler="$:/state/limit" min="10" max="100" default="10" 
increment="5"/><br>
limit: <$text text=<<limit>>/> tiddlers

<div class="tc-tags-wrapper">

<$macrocall $name="tag-pill" tag="All tiddlers" element-tag="$button" 
actions="""<$wikify name="filteredList" text="<$list 
filter='[!is[system]!sort[modified]limit<limit>]'><$text text='[['/><$text 
text={{!!title}}/><$text text=']] '/></$list>"><$action-setfield 
$tiddler="$:/StoryList" list=<<filteredList>>/></$wikify>"""/>
<$macrocall $name="tag-pill" tag="Journal" element-tag="$button" 
actions="""<$wikify name="filteredList" text="<$list 
filter='[!is[system]!sort[modified]tag[Journal]limit<limit>]'><$text 
text='[['/><$text text={{!!title}}/><$text text=']] 
'/></$list>"><$action-setfield $tiddler="$:/StoryList" 
list=<<filteredList>>/></$wikify>"""/>
<hr>

<$list filter="[tags[]sort[title]] -Journal" variable="tagItem">
<$macrocall $name="tag-pill" tag=<<tagItem>> element-tag="$button" 
actions="""<$wikify name="filteredList" text="<$list 
filter='[!is[system]!sort[modified]tag<tagItem>limit<limit>]'><$text 
text='[['/><$text text={{!!title}}/><$text text=']] 
'/></$list>"><$action-setfield $tiddler="$:/StoryList" 
list=<<filteredList>>/></$wikify>"""/>
</$list>

</div>

</$vars>

Before I go, please be aware this is not the only solution, there are many 
methods to do this, I think. Also, please be aware listing a lot of tag 
pills might cause your wiki to lag..! I tried the above code on 
Tiddlywiki.com itself, which has a lot of tagpills!

-jd

On Saturday, August 29, 2020 at 7:07:59 PM UTC+9, Jon Light wrote:
>
>
> Hi Noobie here,
>
> I asked my first question yesterday, I think I can better express it in 
> TiddlyWiki terminology.
>
> I would like to be able to create a list of tag-pills such that when I 
> click on one the story river is filtered to only show tiddlers that have 
> that tag.
>
> The project I have in mind breaks down into two parts.
>
> 1. Creation of a tiddler that displays a tag-pill for each of my tags. 
> Ideally I would also like to add options to not filter at all and one to 
> filter out tiddlers with tag "Journal". 
>
> 2. When one of the tag-pills mentioned in 1. is clicked I would like the 
> story river to be filtered so as to show only tiddlers that have the 
> corresponding tags. I might wish to look at only my journal tiddlers in 
> which case I would click the journal tag-pill.
>
> I might be fighting the intended flow of tiddlyWiki here, I note that 
> tag-pills when clicked on offer a drop down offering the user a list of all 
> corresponding tiddlers which they can then visit if they make a selection. 
> In a sense I am trying to create a tiddler where the pull-down is replaced 
> conceptually by a filtered story-river - the user then 'chooses' from the 
> list presented in the story river rather than from a pull down.  
>
> In my first attempt at asking this question I was talking of "views" but 
> now with a little more familiarity I think what I am really asking is... 
>
> how can I filter the story river according to a users choice of a single 
> nominated tag?
>
>
>
>
>
>
>
>
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/7f46a0b2-d673-495f-9faf-cd0841198363o%40googlegroups.com.

Reply via email to