mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-15 06:14:53 +00:00
cc39a86430
* add KaTeX logo * add katex stamp button * add katex stamp dropdown * add a snippet so that the dropdown isn't empty * correct dropdown title * change tag * update snippets tag
54 lines
955 B
Plaintext
54 lines
955 B
Plaintext
title: $:/plugins/tiddlywiki/katex/ui/EditorToolbar/katex-dropdown
|
|
|
|
\define toolbar-button-stamp-inner()
|
|
<$button tag="a">
|
|
|
|
<$action-sendmessage
|
|
$message="tm-edit-text-operation"
|
|
$param="replace-selection"
|
|
text={{$(snippetTitle)$}}
|
|
/>
|
|
|
|
<$action-deletetiddler
|
|
$tiddler=<<dropdown-state>>
|
|
/>
|
|
|
|
<$view tiddler=<<snippetTitle>> field="caption" mode="inline">
|
|
|
|
<$transclude tiddler=<<snippetTitle>> mode="inline"/>
|
|
|
|
</$view>
|
|
|
|
</$button>
|
|
\end
|
|
|
|
<$list filter="[all[shadows+tiddlers]tag[$:/tags/KaTeX/Snippet]!has[draft.of]sort[caption]]" variable="snippetTitle">
|
|
|
|
<<toolbar-button-stamp-inner>>
|
|
|
|
</$list>
|
|
|
|
----
|
|
|
|
<$button tag="a">
|
|
|
|
<$action-sendmessage
|
|
$message="tm-new-tiddler"
|
|
tags="$:/tags/KaTeX/Snippet"
|
|
text="""$$snippet$$"""
|
|
/>
|
|
|
|
<$action-deletetiddler
|
|
$tiddler=<<dropdown-state>>
|
|
/>
|
|
|
|
<em>
|
|
|
|
<$text text={{$:/language/Buttons/Stamp/Caption/New}}/>
|
|
|
|
</em>
|
|
|
|
</$button>
|
|
|
|
[ext[KaTeX functions catalogue|https://khan.github.io/KaTeX/function-support.html]]
|