how to copy a tid's tags by name searching a tid?

138 views
Skip to first unread message

Zhe Lee

unread,
Aug 1, 2020, 12:34:13 AM8/1/20
to TiddlyWiki
I have a lot of tid All related to one tid. Something like a parent node. So I need to inherit all the tags from the parents. But the parents have so many tags. It is very inconvenient to type them one by one.

So I'm looking for a function or a plugin Which can help me searching a tid and copy all the tags to the current one .

TW Tones

unread,
Aug 1, 2020, 4:00:16 AM8/1/20
to TiddlyWiki
Zhe,

I do not fully understand you question, however this may help.

<$list filter="[all[]tags[]]" variable=tag>
   <$checkbox tag=<
<tag>> ><$text text=<<tag>>/></$checkbox><br>
</$list>
This lists all tags in the wiki and allows you to add them to the current tiddler with a checkbox.
Use it to check your filter locates what you want

You can change "[all[]tags[]]" to what every you want to identify the tags.

Alternatively you would use a similar list inside a button with something like;
<$action-sendmessage $message="

tm-add-tag

" $param=<<tag>>/>
Eg
<$fieldmangler>
<$button tooltip="Add all tags found using [all[]tags[]prefix[a]]">
<$list filter="[all[]tags[]prefix[a]]" variable=tag>
   <$action-sendmessage $message="tm-add-tag" $param=<<tag>>/>
</$list>
Go
</$button>
</$fieldmangler>
Above tested with "[all[]tags[]prefix[a]]" on tiddlywiki.com

Regards
TW Tones


Zhe Lee

unread,
Aug 1, 2020, 9:54:25 AM8/1/20
to TiddlyWiki
Sorry for not make the question clear. 

What I want is I need a search bar to search all the tiddlers, when I select one in the search bar, I can copy all the tags of the target tiddlers to my current edit tiddler. 

Is there a way to make it? 

For example I am reading the story about Porter, Porter is a tiddler in my wiki with tag: A, B, C. 

Then I want to create another tiddler which topic is Porter's Youth. Means I need the tag A, B, C. But I don't want to type all of the tags again. So I need sth like plugin to search for a tiddler and copy all the tags to the current. 

Any way to make it? 

Zhe Lee

unread,
Aug 1, 2020, 10:07:29 AM8/1/20
to TiddlyWiki

I found sth useful in this link. 

<$button>
<$action-sendmessage $message="tm-new-tiddler" title="This is newly created
tiddler" tags={{!!tags}} text=<<now "Today is DDth, MMM YYYY">>/>
New Tiddler get the tags from the current tiddler.
</$button>

But I need this function everywhere. How to add this button to all tiddlers? 

On Saturday, August 1, 2020 at 4:00:16 PM UTC+8, TW Tones wrote:

Zhe Lee

unread,
Aug 1, 2020, 10:12:39 AM8/1/20
to TiddlyWiki
Almost solved 


Try this will add button to every tiddler when you edit. 

But Just one things seems not well. I need to edit the tiddler first then the button shows. If it Show the button without enter the edit mode will be better.

Atronoush Parsi

unread,
Aug 1, 2020, 11:32:55 AM8/1/20
to tiddl...@googlegroups.com
Zhe,
 Have you tried Tiddler-Commander?


See the Commander help
 
See the Commander in action

Atro.

On Sat, Aug 1, 2020 at 9:04 AM Zhe Lee <imleg...@gmail.com> wrote:
I have a lot of tid  All related to one tid.  Something like a parent node.  So I need to inherit all the tags from the parents.  But the parents have so many tags.  It is very inconvenient to type them one by one.

So I'm looking for a function or a plugin  Which can help me searching a tid and copy all the tags to the current one .

--
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+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/7f741bc1-96b9-4cda-b233-365822376c95o%40googlegroups.com.

TW Tones

unread,
Aug 1, 2020, 8:32:22 PM8/1/20
to TiddlyWiki
Zhe,

I can be done, quite easily where one copies the whole content of the tags field to a temporary location and then replace the current tiddlers tag field, a button for each. However a little more effort should ensure it adds the additional tags rather than replace existing tags. Also when creating buttons for the view toolbar a few extra steps so they can be seen and controlled in the Control Panel > Appearance > Toolbars pages is desirable.

Buttons: We could make one copy tags, and one paste tags button.

This seems somewhat useful, but I am tempted to make it capable of copying and pasting any field. That will come later.

Do you want me to make these buttons?

It would be easier than explaining.

Regards
TW Tones

Zhe Lee

unread,
Aug 2, 2020, 3:00:22 AM8/2/20
to TiddlyWiki
Yes of course, wonderful if you can make it. thanks for you effort. : )

Zhe Lee

unread,
Aug 2, 2020, 3:02:29 AM8/2/20
to TiddlyWiki
Thank you it is a powerful tool, but seems not that related to my case. Thank you a lot still.


On Saturday, August 1, 2020 at 11:32:55 PM UTC+8, Atronoush wrote:
Zhe,
 Have you tried Tiddler-Commander?


See the Commander help
 
See the Commander in action

Atro.

On Sat, Aug 1, 2020 at 9:04 AM Zhe Lee <imleg...@gmail.com> wrote:
I have a lot of tid  All related to one tid.  Something like a parent node.  So I need to inherit all the tags from the parents.  But the parents have so many tags.  It is very inconvenient to type them one by one.

So I'm looking for a function or a plugin  Which can help me searching a tid and copy all the tags to the current one .

--
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 tiddl...@googlegroups.com.

TW Tones

unread,
Aug 2, 2020, 8:07:41 PM8/2/20
to TiddlyWiki
Zhe,

I am mostly done on this, prototype attached, and tested on tiddlywiki.com

As usual I often take a little longer to make the solution even more functional and generic if possible
  1. A button to copy the current tiddlers tags to the clipboard and a temporary location
  2. If the temporary location has content
    1. A button to add the tags (in the temporary location) to the current tiddler
    2. A Button to remove the tags (in the temporary location) from the current tiddler if they are there
      • This allows 2.2 to reverse the actions of 2.1
      • But adds the ability to to remove one or more tags on other tiddlers with a click
Feedback please

TW Tones
copy-tags.json

Zhe Lee

unread,
Aug 6, 2020, 8:56:19 AM8/6/20
to TiddlyWiki
Very Useful thanks a lot~
Reply all
Reply to author
Forward
0 new messages