Cade,

I have a solution I am proud of that uses all the mechaisiums you are 
asking for. It is attached. Let me know if you need more instructions.

I am yet to polish it for publication but it is a tool to have local view 
templates specific to a tiddler, it works by only allowing you to edit the 
local-viewtemplate field in a multiline editor in edit mode. It gets hidden 
from the field in edit mode otherwise the you loose the line breaks.


   - Drop the package local-viewtemplate on a wiki. It does nothing without 
   further action.
   - Edit a tiddler and add a field "local-viewtemplate" with or without a 
   value, click add
   - Now the multiline editor of the local-viewtemplate field appears in 
   edit mode.
   - In this case there is a local view template that will display the 
   fields contents in view mode.

Not only does it demonstrate multiline fields it provides a quick and easy 
test bed for writing view Template tests that will not appear everywhere.

There is a possibility tiddler may not be saved correctly on node 
implementations. But I checked right now on Bobexe and it survived a save 
and reload.

Regards
Tones


On Thursday, 3 December 2020 at 04:19:10 UTC+11 Cade Roux wrote:

> I was wondering if anyone has done anything like this where a tiddler has 
> another field "promoted" to a "textarea"-type of field like the main text 
> field so that a tiddler has two text areas when it's in edit mode, where 
> one is the text of the tiddler and one is the field denoted to be edited in 
> a textarea instead of a textbox with all the other (shorter) fields.
>
> In my particular use case, the second field is directly related to the 
> first, but an alternate rendering or similar.  In my case, one is HTML and 
> the other is raw XML or some other related data but they differ such that 
> they aren't realistically directly transformable from one to the other 
> within the browser.
>
> In the past I have put that text in a separate tiddler that is directly 
> linked to the first, but I have found over time, that that technique has 
> grown unwieldy and I have moved many things back into fields in the main 
> tiddler (including these large bits of text/data - which are just very 
> difficult to read in edit mode in their fields - they are obviously fine 
> when transcluded or otherwise used).
>
> Thanks in advance,
>
> Cade
>

-- 
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/d73a2e89-6942-4f1c-9d1b-41dfee05ca22n%40googlegroups.com.

Attachment: local-viewtemplate.json
Description: application/json

Reply via email to