diff --git a/core/templates/store.injected.template.html.tid b/core/templates/store.injected.template.html.tid new file mode 100644 index 000000000..b372973b0 --- /dev/null +++ b/core/templates/store.injected.template.html.tid @@ -0,0 +1,21 @@ +title: $:/core/templates/store.injected.template.html + +\whitespace trim + +<$list filter="[[$:/isEncrypted]get[text]else[no]match[no]]"> + <$list filter="[[storeAreaFormat]is[variable]getvariable[]else[json]match[json]]"> + + `` + + diff --git a/core/templates/store.injected.timestamps.template.tid b/core/templates/store.injected.timestamps.template.tid new file mode 100644 index 000000000..bc0744995 --- /dev/null +++ b/core/templates/store.injected.timestamps.template.tid @@ -0,0 +1,23 @@ +title: $:/core/templates/store.injected.timestamps.template +caption: Inject last-saved and server-created timestamps +tags: $:/tags/InjectCustomTiddlers + + +\whitespace trim +\procedure readableFormat() [UTC]YYYY-0MM-0DD 0hh:0mm:0ss.0XXX UTC TZD + + +<$let + timestamp={{{ [] }}} + timeReadable={{{ [format:date] }}} +> + <% if [{$:/info/browser}match[yes]] %> + `{"title": "$:/info/last-saved/timestamp", "created":"`<>`", "modified":"`<>`", "text":"`<>`"}` + <$text text=<>/> + `{"title": "$:/info/last-saved/date", "created":"`<>`", "modified":"`<>`", "text":"`<>`"}` + <% elseif [{$:/info/node}match[yes]] %> + `{"title": "$:/info/server-created-wiki/timestamp", "created":"`<>`", "modified":"`<>`", "text":"`<>`"}` + <$text text=<>/> + `{"title": "$:/info/server-created-wiki/date", "created":"`<>`", "modified":"`<>`", "text":"`<>`"}` + <% endif %> + \ No newline at end of file diff --git a/core/templates/tiddlywiki5.html.tid b/core/templates/tiddlywiki5.html.tid index 721b3d9ce..bc28d4a1a 100644 --- a/core/templates/tiddlywiki5.html.tid +++ b/core/templates/tiddlywiki5.html.tid @@ -41,6 +41,7 @@ title: $:/core/templates/tiddlywiki5.html `{{$:/core/templates/store.area.template.html}}` +`{{$:/core/templates/store.injected.template.html}}`