How to create a tiddler to create a new tiddler with a customize name?

Yes, but not with the tm-new-tiddler message. Because it is hardcoded that way.

We will need to use the action-createtiddler widget for that one.

  • Replace title → with $basetitle
  • And we need to use the <<createTiddler-title>> variable, which is set by the action-createtiddler widget

This variable can only be used within the action-createtiddler body text.

You need to replace <$action-sendmessage → with <$action-createtiddler and add the <$action-navigate` widget in the body.

  <$action-createtiddler
    $basetitle=<<f.getNewTitle>>
    tags=<<f.getTags>>
    text="Este es un tiddler con etiqueta"
  >
    <$action-navigate $to=<<createTiddler-title>>/>
  </$action-createtiddler>

That should do the trick.

have fun!
mario

PS: Tested Code
<!-- Define temporary tiddler titles -->
\function f.tempTiddler() $:/temp/rosi/new-tiddler-title

\function f.tempTag()     $:/temp/rosi/new-tiddler-tag
\function f.tempDomain()  $:/temp/rosi/new-tiddler-domain

<!-- Function to "get" a whitespace trimmed new tiddler title. 
  Trimming whitespace here is important, since users can enter the new title.
  If they accidentally use a leading or trailins space, that can cause problems.
--> 
\function f.getNewTitle() [<f.tempTiddler>get[text]trim[]]

<!-- Function to "get" multiple tags and format them as a titlelist
  titlelist see: https://tiddlywiki.com/#format%20Operator
--> 
\function f.getTags() [<f.tempTag>get[text]] [<f.tempDomain>get[text]] +[format:titlelist[]join[ ]]

<!-- Helper procedures -->
\procedure deleteTempTiddlers()
<$action-deletetiddler $filter="[prefix[$:/temp/rosi/]]" />
\end

\procedure newTiddlerActions()
<% if [<f.getNewTitle>has[text]] %>
  <$action-navigate $to=<<f.getNewTitle>>/>
<%else%>
  <$action-createtiddler
    $basetitle=<<f.getNewTitle>>
    tags=<<f.getTags>>
    text="Este es un tiddler con etiqueta"
  >
    <$action-navigate $to=<<createTiddler-title>>/>
  </$action-createtiddler>

  <!-- delete all temporary tiddlers -->
  <<deleteTempTiddlers>>

<%endif%>
\end

<!-- Campo para introducir el título del nuevo tiddler -->
1. Introduce un título:<br>

<$edit-text tiddler=<<f.tempTiddler>> field="text" tag="input" class="tc-edit-textinput"/>

<!-- Dropdown para seleccionar una etiqueta sobre el tipo de OBJETO-->
2. Elige una de las etiquetas del menú desplegable. <br>
<$select tiddler=<<f.tempTag>> field="text" default="">
  <option disabled>Selecciona una etiqueta</option>
  <option value="">-none-</option>
  <option value="Costs">Costs</option>
  <option value="Issues">Issues</option>
  <option value="Parameter">Parameter</option>
  <option value="Community">Community</option>
</$select>

<!-- Dropdown para seleccionar una etiqueta sobre el tipo de DOMINIO -->
Elige un tipo de DOMINIO: 
<$select tiddler=<<f.tempDomain>> field="text"  default="">
  <option disabled>Selecciona una etiqueta</option>
  <option value="">-none-</option>
  <option value="Regulation">Regulation</option>
  <option value="Envi.& Nature">Nature</option>
  <option value="Wellness">Wellness</option>
  <option value="Water">Water</option>
</$select>

<!-- Botón para crear el tiddler con ese nombre -->
3. Presiona el botón "Crear nuevo tiddler" <br>
<$button actions=<<newTiddlerActions>> >
  Crear nuevo tiddler
</$button>
1 Like

Yeah!! Very helpfull!! Great!!
Thanks so much!!
Rosi