mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-02-05 13:40:02 +00:00
Text-slicer: Make sliced documents collapsible
This commit is contained in:
parent
3592a9560b
commit
e62778a50f
@ -1,5 +1,9 @@
|
|||||||
title: $:/plugins/tiddlywiki/text-slicer/templates/interactive/document
|
title: $:/plugins/tiddlywiki/text-slicer/templates/interactive/document
|
||||||
|
|
||||||
|
\define config-document-status()
|
||||||
|
$:/config/plugins/tiddlywiki/text-slicer/show-preview-document/$(tv-heading-status-config-prefix)$/$(currentTiddler)$
|
||||||
|
\end
|
||||||
|
|
||||||
\define config-show-toolbar()
|
\define config-show-toolbar()
|
||||||
$:/config/plugins/tiddlywiki/text-slicer/show-toolbar/$(currentTiddler)$
|
$:/config/plugins/tiddlywiki/text-slicer/show-toolbar/$(currentTiddler)$
|
||||||
\end
|
\end
|
||||||
@ -15,6 +19,38 @@ $:/config/plugins/tiddlywiki/text-slicer/heading-status/$(currentTiddler)$
|
|||||||
|
|
||||||
<div class="tc-sliced-document">
|
<div class="tc-sliced-document">
|
||||||
|
|
||||||
|
<div class="tc-sliced-document-header">
|
||||||
|
|
||||||
|
<div class="tc-document-tiddler-toolbar">
|
||||||
|
|
||||||
|
<$reveal type="nomatch" state=<<config-document-status>> text="open" default="closed">
|
||||||
|
|
||||||
|
<$button set=<<config-document-status>> setTo="open" class="tc-btn-invisible">
|
||||||
|
|
||||||
|
{{$:/core/images/down-arrow}}
|
||||||
|
|
||||||
|
</$button>
|
||||||
|
|
||||||
|
</$reveal>
|
||||||
|
|
||||||
|
<$reveal type="match" state=<<config-document-status>> text="open" default="closed">
|
||||||
|
|
||||||
|
<$button set=<<config-document-status>> setTo="close" class="tc-btn-invisible">
|
||||||
|
|
||||||
|
{{$:/core/images/right-arrow}}
|
||||||
|
|
||||||
|
</$button>
|
||||||
|
|
||||||
|
</$reveal>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<h1 class="tc-sliced-document-title">''Document'': <$link><$view field="title"/></$link></h1>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<$reveal type="nomatch" state=<<config-document-status>> text="open" default="closed">
|
||||||
|
|
||||||
{{||$:/plugins/tiddlywiki/text-slicer/ui/document/header}}
|
{{||$:/plugins/tiddlywiki/text-slicer/ui/document/header}}
|
||||||
|
|
||||||
<div class='tc-sliced-document-body'>
|
<div class='tc-sliced-document-body'>
|
||||||
@ -31,6 +67,8 @@ $:/config/plugins/tiddlywiki/text-slicer/heading-status/$(currentTiddler)$
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
</$reveal>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</$set>
|
</$set>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
title: $:/plugins/tiddlywiki/text-slicer/templates/interactive/paragraph
|
title: $:/plugins/tiddlywiki/text-slicer/templates/interactive/paragraph
|
||||||
|
|
||||||
\define body()
|
\define body()
|
||||||
<$link tag="div" class="tc-document-tiddler-link">
|
<$link tag="div" class="tc-document-tiddler-link tc-document-tiddler">
|
||||||
|
|
||||||
<$list filter="""[all[current]] $(tv-exclude-filter)$ +[limit[1]]""" variable="item">
|
<$list filter="""[all[current]] $(tv-exclude-filter)$ +[limit[1]]""" variable="item">
|
||||||
|
|
||||||
|
@ -2,8 +2,6 @@ title: $:/plugins/tiddlywiki/text-slicer/ui/document/header
|
|||||||
|
|
||||||
<div class="tc-sliced-document-header">
|
<div class="tc-sliced-document-header">
|
||||||
|
|
||||||
''Document'': <$link><$view field="title"/></$link>
|
|
||||||
|
|
||||||
''Exclude filter'': <$edit-text field="toc-exclude-filter"/>
|
''Exclude filter'': <$edit-text field="toc-exclude-filter"/>
|
||||||
|
|
||||||
<$checkbox tiddler=<<config-show-toolbar>> field="text" checked="yes" unchecked="no" default="no"> Show toolbar</$checkbox>
|
<$checkbox tiddler=<<config-show-toolbar>> field="text" checked="yes" unchecked="no" default="no"> Show toolbar</$checkbox>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user