mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-07-19 18:34:23 +00:00
![Jermolene](/assets/img/avatar_default.png)
A first pass at a plugin that splits formatted text into individual tiddlers according to lists and headings.
24 lines
434 B
Plaintext
24 lines
434 B
Plaintext
title: $:/plugins/tiddlywiki/text-slicer/macros
|
|
tags: $:/tags/Macro
|
|
|
|
\define display-heading-tiddler(level:"h1")
|
|
<$level$><$view field="title"/></$level$>
|
|
<$list filter='[tag<currentTiddler>]'>
|
|
<$tiddler>
|
|
<$transclude mode='block'/>
|
|
</$tiddler>
|
|
</$list>
|
|
\end
|
|
|
|
\define display-list-tiddler(type:"ol")
|
|
<$type$>
|
|
<$list filter='[tag<currentTiddler>]'>
|
|
<li>
|
|
<$tiddler>
|
|
<$transclude mode='block'/>
|
|
</$tiddler>
|
|
</li>
|
|
</$list>
|
|
</$type$>
|
|
\end
|