\define standardSearch()Standard search<br><!--for debugging--><$list filter="[search:title,caption,text[$(searchTerms)$]]"><$link/><br></$list>\end
\define filterSearch()Filter search<br><!--for debugging--><$list filter=<<searchTerms>> ><$link/><br></$list>\end
\define combo-search()<$vars pattern="^\[" stateTid="$:/temp/comboSearch"> <!--UI -->combo search <$edit-text tiddler=<<stateTid>> tag=input/>
<!-- show results if any--><$reveal state=<<stateTid>> type="nomatch" text=""><!--do not display when searchbox is empty--><$set name=searchTerms tiddler=<<stateTid>> field=text><$list filter="[<searchTerms>minlength[3]limit[1]]" emptyMessage="Search text too short" variable=ignore><!-- Check input search term --><$list filter="[<searchTerms>regexp<pattern>]" emptyMessage=<<standardSearch>> > <<filterSearch>></$list></$list></$set></$reveal></$vars>\end
<<combo-search>>
\define standardSearch()<$set name=searchFilter value="[all[tiddlers]!is[system]search:title,caption,text[$(searchTerms)$]]">//<small>Standard search: <$count filter=<<searchFilter>> /> matches</small>//<br><$list filter=<<searchFilter>> ><$link/><br></$list></$set>\end
\define filterSearch()//<small>Filter search: <$count filter=<<searchTerms>>/> matches</small>//<br><!--for debugging-->
<$list filter=<<searchTerms>> ><$link/><br></$list>\end
\define combo-search()<$vars pattern="^\[" stateTid="$:/temp/comboSearch"> <!--UI -->combo search <$edit-text tiddler=<<stateTid>> tag=input/> <!-- show results if any--><$reveal state=<<stateTid>> type="nomatch" text=""><!--do not display when searchbox is empty-->
<$button class="tc-btn-invisible"><$action-setfield $tiddler=<<stateTid>> $field="text" $value=""/>{{$:/core/images/close-button}}</$button><br>
<$set name=searchTerms tiddler=<<stateTid>> field=text>
<$list filter="[<searchTerms>trim[]minlength[3]limit[1]]" emptyMessage="Search text too short" variable=ignore>
<!-- Check input search term -->
<div class="tc-search-results"><$list filter="[<searchTerms>trim[]regexp<pattern>]" emptyMessage=<<standardSearch>> > <<filterSearch>></$list></div>
</$list></$set></$reveal></$vars>\end
<<combo-search>>
I have not tested your example yet but could you just test if the search string begins [ and use is as a filter instead?
perhaps not as a filter if /[ is the prefix remove / for an override?
I just created a number of different sesrches.
Tony
just like Lucifer & Sinatra, I must first figure and do it myself-- habit that's really hard to kick
Psat website or the tiddlywiki.psat.com.au has not had many updates but hopefully will soon.
Regards
Tony
In my examples the extended one is what I would like to propose to add to the default since it allows a system tiddler to appear in the standard search if it has a caption. You can add captions to the many tools you have shared and users can find them in the standard search.
I would like your view on this
Tony