add details search reset button

This commit is contained in:
pmario 2024-05-01 13:01:55 +02:00
parent 0662aa34f4
commit cfbd4bace0
2 changed files with 15 additions and 0 deletions

View File

@ -37,6 +37,7 @@ Variables/FoldAll: Fold all:
Variables/Filter: Search:
Variables/Filter/Hint: Search Variable Name eg: .attr
Variables/Hint: Filter global variables
Variables/Info/Reset: Reset details search input
Variables/Info/Toggle/Show: Show details search input
Variables/Info/Toggle/Hide: Hide details search input
Variables/Matches: //<small><<resultCount>> matches</small>//

View File

@ -69,6 +69,14 @@ tags: $:/tags/Global
/>
\end
\procedure dv-setDetailsSearchText()
<!-- Existing user modified "search text details" should be preserved. If empty use default formatted signature -->
<!-- Be aware that the "format" filter operator uses $var-name$ for compatibility reasons -->
<$action-setfield $tiddler=<<tf.dv-detailsSearch>>
text={{{ [<varname>format:variable[$type$ $name$($params$)]] }}}
/>
\end
\procedure dv-clearStatesButton()
<span class="tc-small-gap"><<lingo FoldAll>></span>
<$button class="tc-btn-invisible tc-tiny-gap-left" tooltip={{$:/language/Search/Variables/FoldAll}}>
@ -200,6 +208,12 @@ tags: $:/tags/Global
<div class="tc-labeled-input-wrapper">
<span tabindex="0" class="tc-fixed-label tc-align-right"><<lingo Search/Details>></span>
<$edit-text tiddler=<<tf.dv-detailsSearch>> tag=input class="tc-fluid-input tc-small-gap-left"/>
<$button actions=<<dv-setDetailsSearchText>>
class="tc-btn-invisible tc-tiny-gap-left"
tooltip={{$:/language/Search/Variables/Info/Reset}}
>
{{$:/core/images/refresh-button}}
</$button>
</div>
<<dv-info>>
<% endif %>