mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-18 07:44:51 +00:00
b882a0dff1
Thus making the export button a lot more useful
29 lines
1.1 KiB
Plaintext
29 lines
1.1 KiB
Plaintext
title: $:/core/macros/export
|
|
tags: $:/tags/Macro
|
|
|
|
\define exportButton(exportFilter:"[!is[system]sort[title]]",lingoBase)
|
|
<span class="tc-popup-keep">
|
|
<$button popup=<<qualify "$:/state/popup/export">> tooltip={{$lingoBase$Hint}} aria-label={{$lingoBase$Caption}} class=<<tv-config-toolbar-class>> selectedClass="tc-selected">
|
|
<$list filter="[<tv-config-toolbar-icons>prefix[yes]]">
|
|
{{$:/core/images/export-button}}
|
|
</$list>
|
|
<$list filter="[<tv-config-toolbar-text>prefix[yes]]">
|
|
<span class="tc-btn-text"><$text text={{$lingoBase$Caption}}/></span>
|
|
</$list>
|
|
</$button>
|
|
</span>
|
|
<$reveal state=<<qualify "$:/state/popup/export">> type="popup" position="below" animate="yes">
|
|
<div class="tc-drop-down">
|
|
<$list filter="[all[shadows+tiddlers]tag[$:/tags/Exporter]]">
|
|
<$set name="filename" value={{!!filename}}>
|
|
<$button class="tc-btn-invisible">
|
|
<$action-sendmessage $message="tm-download-file" $param=<<currentTiddler>> exportFilter="""$exportFilter$""" filename=<<filename>>/>
|
|
<$action-deletetiddler $tiddler=<<qualify "$:/state/popup/export">>/>
|
|
<$transclude field="description"/>
|
|
</$button>
|
|
</$set>
|
|
</$list>
|
|
</div>
|
|
</$reveal>
|
|
\end
|