1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-05 09:36:18 +00:00

Make "Open" tab mutate into "History" tab when in STM

Instead of introducing a new "History" tab to the sidebar we make the existing "Open" tab mutate into a "History" tab when in Single Tiddler Mode.
This commit is contained in:
Jermolene 2018-08-30 12:38:13 +01:00
parent 33aa37f7dc
commit ee25af758e
3 changed files with 9 additions and 7 deletions

View File

@ -1,5 +0,0 @@
title: $:/core/ui/SideBar/History
tags: $:/tags/SideBar
caption: {{$:/language/SideBar/History/Caption}}
<$list filter="[list[$:/HistoryList]limit[100]]" template="$:/core/ui/ListItemTemplate"/>

View File

@ -1,6 +1,6 @@
title: $:/core/ui/SideBar/Open title: $:/core/ui/SideBar/Open
tags: $:/tags/SideBar tags: $:/tags/SideBar
caption: {{$:/language/SideBar/Open/Caption}} caption: <$list filter="[<tv-storyview-single-tiddler-mode>prefix[yes]]" emptyMessage="{{$:/language/SideBar/Open/Caption}}">{{$:/language/SideBar/History/Caption}}</$list>
\define lingo-base() $:/language/CloseAll/ \define lingo-base() $:/language/CloseAll/
@ -8,6 +8,7 @@ caption: {{$:/language/SideBar/Open/Caption}}
<$action-listops $tiddler="$:/StoryList" $subfilter="+[insertbefore:currentTiddler<actionTiddler>]"/> <$action-listops $tiddler="$:/StoryList" $subfilter="+[insertbefore:currentTiddler<actionTiddler>]"/>
\end \end
\define open()
<$list filter="[list[$:/StoryList]]" history="$:/HistoryList" storyview="pop"> <$list filter="[list[$:/StoryList]]" history="$:/HistoryList" storyview="pop">
<div style="position: relative;"> <div style="position: relative;">
<$droppable actions=<<drop-actions>>> <$droppable actions=<<drop-actions>>>
@ -28,3 +29,9 @@ caption: {{$:/language/SideBar/Open/Caption}}
<$button message="tm-close-all-tiddlers" class="tc-btn-invisible tc-btn-mini"><<lingo Button>></$button> <$button message="tm-close-all-tiddlers" class="tc-btn-invisible tc-btn-mini"><<lingo Button>></$button>
</$droppable> </$droppable>
</$tiddler> </$tiddler>
\end
<$list filter="[<tv-storyview-single-tiddler-mode>prefix[yes]]" emptyMessage=<<open>>>
<$list filter="[list[$:/HistoryList]limit[100]]" template="$:/core/ui/ListItemTemplate"/>
</$list>

View File

@ -1,3 +1,3 @@
title: $:/tags/SideBar title: $:/tags/SideBar
list: [[$:/core/ui/SideBar/Open]] [[$:/core/ui/SideBar/History]] [[$:/core/ui/SideBar/Recent]] [[$:/core/ui/SideBar/Tools]] [[$:/core/ui/SideBar/More]] list: [[$:/core/ui/SideBar/Open]] [[$:/core/ui/SideBar/Recent]] [[$:/core/ui/SideBar/Tools]] [[$:/core/ui/SideBar/More]]