How to open all AdvancedSearch search results to StoryList instead of exporting?

155 views
Skip to first unread message

tony

unread,
Sep 11, 2020, 1:05:19 AM9/11/20
to TiddlyWiki
Hi 

Does anyone know a way to open all the search matches from $:/AdvancedSearch or save them as a list in a separate tiddler? 

I was trying to evangelize Tiddlywiki and ran into a roadblock when they asked if there was a way to open all the results from AdvancedSearch instead of clicking them one by one to open in the StoryList. That seemed surprisingly straightforward since there is an Close All button, but I could figure out how to Open All.

I thought there was a plugin or macro that had an Open All from the Exporter menu which opened all the titles instead of exporting but maybe that was in TiddlyWiki Classic and I cannot recollect or find so in TiddlyWiki 5. 

Luckily Tobias Beer's SidebarStories [1] was somewhat a workaround to load a story and
setTo={{$:/StoryList!!list}}

And I also showed Duarte's Local Search engine to great effect and the search filter results open the tiddlers in the StoryList directly.[2] 

But I cannot figure out where the search results are stored ?
[!is[system]search{$(searchTiddler)$}]

or how to push them to the StoryList?

Any leads much obliged 

Thank you, 

tony 

TW Tones

unread,
Sep 11, 2020, 3:46:37 AM9/11/20
to TiddlyWiki
Tony,

Tony here, TW Tones for disambiguation. 

Attached is my first attempt at a solution. Please try and provide feedback

  • Install the attached JSON on a wiki, or tiddlywiki.com as well
  • Go to the "advanced search > filter" if you use a search with a result an eye will appear.
  • Clicking on the eye will open all listed into the story river (without navigating to them) 
Warning you could open so many tiddlers your wiki runs for a long time.

Future Improvements?
  • Also work for the sideBar search?
  • A better icon
  • Have some limits?
    • Like if you try and open more than 10 or 20, the icon goes red
    • Will not work if over 100 may be opened
  • Option to close all tiddlers including search and only open the selected?
I have a project called "advanced search indicators" to which I will add this feature for the sidebar search!

Regards
Tony
open-search-results.json

PMario

unread,
Sep 11, 2020, 5:44:26 AM9/11/20
to TiddlyWiki
Hi Tony, Tony,

@Tones. ... That's a nice function, but I did expect it be visible with every advanced search tab. It's only available with the filter tab.

just a thought.

-mario


TW Tones

unread,
Sep 11, 2020, 9:32:59 AM9/11/20
to TiddlyWiki
Mario,

I gave it a passing consideration, however the other tabs do not include the buttons represented by 

$:/tags/AdvancedSearch/FilterButton, 

So it would require a shadow overwrite.

But also I am building a much better solution for search, called advanced search indicators, it monitors the content in the search field and presents icons for what it knows about, if a filter is placed there it will recognise it and present the option to list, open them all, or in fact close them all, and a lot of other snazzy features, eg searching for a macros use and definition...

I am still to complete the filter and macro features, and a new tab in advanced search with the same feature, and also it each list item, can have various actions applied to them, edit, new window etc...
  • As a designer one of my favourite features is pasting a system tiddler in the search, provides a button to open it, without needing to resort to an advanced search tab.
  • Another is, given a search string will indicate if the string is a prefix, a suffix of one or more tiddlers and indicates if it is.
    • Thinking now perhaps a contains the string in the title would also be good.
    • Then with a click it will open my search tab with the filter [prefix[string]]
Following your lead, perhaps I should publish the prototype for feedback?


Regards
Tony

tony

unread,
Sep 11, 2020, 4:33:35 PM9/11/20
to TiddlyWiki
Wow, wow excellent, Tony (TW Tones) ! 

Thank you very much, more than I asked for!

There is much to unpack and learn here, good fun.

I like the fact that your magic button does not overwrite the current StoryList and appends to it instead. Since opening a big StoryList negatively impacts performance which i found depends on memory, your limit to the filter tab makes sense and the user can modify the filter to constrain the number of matches. 

I also love that your metadata reference fields carry the provenance of the inquiry and other details for easy future traceback. I often wonder, "where did this nifty macro i-dragged-into-x-years-ago came from?" This namespacing and best practice of field list style convention is something I'll have to start following to help find things and clean my messy wiki :-)

Thank you again for the solution and help :-)

Best,
another fellow tony

TW Tones

unread,
Sep 11, 2020, 7:28:36 PM9/11/20
to TiddlyWiki
Your welcome. 

Keep an eye out for my advanced search indicators package.

Regards
Tony

danraymond

unread,
Dec 14, 2020, 9:09:24 PM12/14/20
to TiddlyWiki
Hi Tones;

Have you had a chnace to do this?
Reply all
Reply to author
Forward
0 new messages