In tiddler A, access the draft text in the editor of "Drafts of 'B'"

I’m wondering if it is possible to access the drafting text in the editor of a draft?

Basically, if I in tiddler A have {{Draft of 'B'}} and I open B to edit it, I’m hoping the content will appear in A via that transclusion. A first attempt indicates it is not possible but I’m thinking that the drafting text is maybe temporarily stored elsewhere in some place that can be accessed - ?

The reason why I want this is because I want to super quickly be able to add stuff in an editor and have manipulations be performed in it elsewhere right away.

1 Like

This should already work.

…but it doesn’t. Again, it is without closing/saving B. The text being edited is what should appear in the other tiddler.

Can you provide a working demo that shows the problem? In my admittedly brief testing just now, it works.

Hm. Here’s my attempt. I am hoping that if I type into the open editor, there will appear something in the lower tiddler, as I type.

Odd, it doesn’t work in your demo but it works just fine if I do the following on tiddlywiki.com:

  • create a tiddler called B with contents: {{Draft of 'New Tiddler'}}
  • click the new tiddler button and start typing

Hmm, that is strange. I’ll set up a totally clean tiddlyhosted wiki. That one is really for something else.

EDIT 1: a brand new wiki on TH does not work, to do it in. I will now attempt with a copy of tiddlywiki.com

EDIT2: In a local wiki on my computer it works. On TH with a copy of tiddlywiki.com it does not work.

Well… a bit confused.

@saqimtiaz Where is the temporary text in an active editor stored, if at all? Or is it simply in the editor itself as it is seen?

In the text field of the draft tiddler as you rightly assumed, there is no magic involved.

It works on my wiki on TiddlyHost, though its a 5.1.24 pre-release version:

https://saq-twlinks.tiddlyhost.com/

OK. Is your guess that this is a TW issue or an TH issue? Does it make sense for me to bring it up with TH admin Simon? Does it not make sense to pursue at all or is it totally unlikely that it can affect anything?
Thanks.

I am honestly not sure. Given that we have only reproduced the issue on TH that would suggest it might be a TH issue. However, I cannot think off the top of my head what it might be and to be fair our testing has been fairly limited.

I would probably wait to report it to Simon, not only does it feel unlikely that Th is causing the problem, but also given that Simon does not use TiddlyWiki5 he wont be well placed to figure out what is going on.

Hi @twMat the issue is that the wiki at https://proportions.tiddlyhost.com/ has a username set in $:/status/UserName. In those cases, the draft is titled "Draft of ‘[title]’ by [username]`, as you can see at your demo.

2 Likes

DOH! Facepalm… :man_facepalming: :man_facepalming: :man_facepalming:

Thanks everyone!

To avoid the problem with $:/status/UserName being added to draft tiddlers:

Instead of using

{{Draft of 'raw'}}

try using

<$transclude tiddler={{{ [prefix[Draft of 'raw']] }}}/>

-e

3 Likes