1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-19 00:04:51 +00:00
TiddlyWiki5/core/ui/Manager.tid

120 lines
4.0 KiB
Plaintext

title: $:/Manager
icon: $:/core/images/list
color: #bbb
\define tag-checkbox-actions()
<$action-listops
$tiddler="$:/config/Tagger/RecentTags"
$subfilter="[<tag>] [list[$:/config/Tagger/RecentTags]] +[limit[12]]"
/>
\end
\define tag-picker-actions()
<<tag-checkbox-actions>>
<$action-listops
$tiddler=<<currentTiddler>>
$field="tags"
$subfilter="[<tag>] [all[current]tags[]]"
/>
\end
<div class="tc-manager-wrapper">
<div class="tc-manager-controls">
<div class="tc-manager-control">
Search: <$edit-text tiddler="$:/config/Tagger/Filter" tag="input" default="" placeholder="Search"/>
</div>
<div class="tc-manager-control">
Filter by tag: <$select tiddler="$:/config/Tagger/Tag" default="">
<option value="">(none)</option>
<$list filter="[!is{$:/config/Tagger/System}tags[]!is[system]sort[title]]" variable="tag">
<option value=<<tag>>><$text text=<<tag>>/></option>
</$list>
</$select>
</div>
<div class="tc-manager-control">
Sort by: <$select tiddler="$:/config/Tagger/Sort" default="title">
<optgroup label="Common">
<$list filter="title modified modifier created creator created" variable="field">
<option value=<<field>>><$text text=<<field>>/></option>
</$list>
</optgroup>
<optgroup label="All">
<$list filter="[!is{$:/config/Tagger/System}fields[]sort[title]] -title -modified -modifier -created -creator -created" variable="field">
<option value=<<field>>><$text text=<<field>>/></option>
</$list>
</optgroup>
</$select>
<$checkbox tiddler="$:/config/Tagger/Order" field="text" checked="reverse" unchecked="forward" default="forward">
Reverse order
</$checkbox>
</div>
<div class="tc-manager-control">
<$checkbox tiddler="$:/config/Tagger/Untagged" field="text" checked="yes" unchecked="no" default="no">
Only show untagged tiddlers
</$checkbox>
</div>
<div class="tc-manager-control">
<$checkbox tiddler="$:/config/Tagger/System" field="text" checked="missing" unchecked="system" default="system">
Show system tiddlers
</$checkbox>
</div>
<div class="tc-manager-control">
<$checkbox tiddler="$:/config/Tagger/View" field="text" checked="plain" unchecked="wikified" default="wikified">
Show raw text
</$checkbox>
</div>
</div>
<div class="tc-manager-list">
<$list filter="[!is{$:/config/Tagger/System}search{$:/config/Tagger/Filter}tag:strict{$:/config/Tagger/Tag}untagged:no{$:/config/Tagger/Untagged}sort{$:/config/Tagger/Sort}order{$:/config/Tagger/Order}]">
<$vars transclusion=<<currentTiddler>>>
<div style="tc-manager-list-item">
<$button popup=<<qualify "$:/state/manager/popup">> class="tc-btn-invisible tc-manager-list-item-heading">
<$text text=<<currentTiddler>>/>
</$button>
<$reveal state=<<qualify "$:/state/manager/popup">> type="nomatch" text="" default="" tag="div" class="tc-manager-list-item-content tc-popup-handle">
<div class="tc-manager-list-item-content-tiddler">
<div class="tc-manager-list-item-content-tiddler-item">
<$reveal state="$:/config/Tagger/View" type="nomatch" text="plain">
<$transclude mode="block"/>
</$reveal>
<$reveal state="$:/config/Tagger/View" type="match" text="plain">
<pre>
<code>
<$view/>
</code>
</pre>
</$reveal>
</div>
<table class="tc-manager-list-item-content-tiddler-item tc-manager-list-item-content-tiddler-item-table">
<tbody>
<$list filter="[all[current]fields[]sort[title]] -text" template="$:/core/ui/TiddlerFieldTemplate" variable="listItem"/>
</tbody>
</table>
</div>
<div class="tc-manager-list-item-content-sidebar">
<div class="tc-manager-list-item-content-sidebar-item">
<$list filter="[is[current]tags[]] [list[$:/config/Tagger/RecentTags]] +[sort[title]] " variable="tag">
<div>
<$checkbox tiddler=<<currentTiddler>> tag=<<tag>> actions=<<tag-checkbox-actions>>>
<$macrocall $name="tag-pill" tag=<<tag>>/>
</$checkbox>
</div>
</$list>
<$macrocall $name="tag-picker" actions=<<tag-picker-actions>>/>
</div>
<div class="tc-manager-list-item-content-sidebar-item">
<p>
<$button to=<<currentTiddler>>>{{$:/core/images/link}} open</$button>
</p>
<p>
<$button message="tm-edit-tiddler" param=<<currentTiddler>>>{{$:/core/images/edit-button}} edit</$button>
</p>
</div>
</div>
</$reveal>
</div>
</$vars>
</$list>
</div>
</div>