In kookma Utility Plugin, the $genesis
is used to create the html5 widget details as below:
<$genesis $type="details" $names="open" $values={{{ [tag[show-content]] [tag[show-source]] :and[match<currentTiddler>] :then[[open]] }}} title="Show/hide tiddler source code" >
<summary>Code</summary>
<$macrocall $name="code" language={{{ [{!!type}else[xml]] }}} src={{!!text}} />
</$genesis>
NOTE: The filter transclusion result determines the state of details (expanded or collapsed).
This code is implemented within a viewtemplate to unveil the source code of a tiddler using the HTML5 details widget.
The problem arises when I activate the details to show a tiddler’s code in the story river; any subsequent interaction causes the details to close.
This indicates that the $genesis
is refreshed, which resets the details. Such interactions include clicking the search input box or opening a tiddler in the story river.
How resolve the issue?