mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-01-22 19:04:38 +00:00
Compare commits
55 Commits
tm-http-re
...
v5.3.0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c101e9efe6 | ||
|
|
d893241ba9 | ||
|
|
3ec6c0eaf1 | ||
|
|
47813ae31f | ||
|
|
9589e3df33 | ||
|
|
ee1200bde1 | ||
|
|
419760a8e5 | ||
|
|
04950452fa | ||
|
|
3f4e301a20 | ||
|
|
2db0322a76 | ||
|
|
d6c77f549f | ||
|
|
7dbcab0192 | ||
|
|
823bcd7999 | ||
|
|
c24d1ef4fb | ||
|
|
b5d835e7dd | ||
|
|
5c5543815b | ||
|
|
28aef51855 | ||
|
|
158384867b | ||
|
|
a02d99a4c1 | ||
|
|
16ef1d84cd | ||
|
|
6bb0da07dc | ||
|
|
ebeb1a8956 | ||
|
|
bc07fd731c | ||
|
|
d46aa4ba4d | ||
|
|
f2d6c5a6eb | ||
|
|
4659b893d8 | ||
|
|
c499fff2a9 | ||
|
|
0d723d8b9d | ||
|
|
3825e2579f | ||
|
|
e5566543c9 | ||
|
|
a5c258ecac | ||
|
|
9b8db5dbb1 | ||
|
|
a05302da10 | ||
|
|
5647ad71b0 | ||
|
|
6fd2139376 | ||
|
|
13a895bd2d | ||
|
|
b90c9ef9a0 | ||
|
|
d8124ee82d | ||
|
|
190613ad29 | ||
|
|
5bef6d50bc | ||
|
|
f4626aa69e | ||
|
|
edaa3727d9 | ||
|
|
b61c01d8b0 | ||
|
|
73b23f48a0 | ||
|
|
f90eb386ae | ||
|
|
12f7b98c4f | ||
|
|
50315310f5 | ||
|
|
120c2f8136 | ||
|
|
f277493acd | ||
|
|
46d0aea0f2 | ||
|
|
5947140b61 | ||
|
|
86d45f1c3d | ||
|
|
106f121133 | ||
|
|
d1f90f075f | ||
|
|
a66b04f532 |
@@ -107,7 +107,7 @@ node $TW5_BUILD_TIDDLYWIKI \
|
||||
# /empty.html Empty
|
||||
# /empty.hta For Internet Explorer
|
||||
node $TW5_BUILD_TIDDLYWIKI \
|
||||
$TW5_BUILD_MAIN_EDITION \
|
||||
./editions/empty \
|
||||
--verbose \
|
||||
--output $TW5_BUILD_OUTPUT \
|
||||
--build empty \
|
||||
|
||||
11
core/images/network-activity.tid
Normal file
11
core/images/network-activity.tid
Normal file
@@ -0,0 +1,11 @@
|
||||
title: $:/core/images/network-activity
|
||||
tags: $:/tags/Image
|
||||
|
||||
<svg width="22pt" height="22pt" class="tc-image-network-activity tc-image-button" viewBox="0 0 128 128"><g class={{{ [{$:/state/http-requests}match[0]then[]else[tc-network-activity-background]] }}}>
|
||||
<$list filter="[{$:/state/http-requests}match[0]]" variable="ignore">
|
||||
<path d="M64.043 45.153a4.002 4.002 0 0 1 4.367 2.21l.084.188 30.403 73.4a4 4 0 0 1-7.307 3.25l-.084-.188-3.103-7.49-8.898 8.899a3.985 3.985 0 0 1-2.624 1.166l-.205.005a3.987 3.987 0 0 1-2.828-1.171l-9.849-9.848-9.847 9.848a3.985 3.985 0 0 1-2.624 1.166l-.204.005a3.987 3.987 0 0 1-2.829-1.171l-8.899-8.9-3.102 7.491a4 4 0 1 1-7.391-3.062l30.403-73.4a4.001 4.001 0 0 1 4.495-2.39l.042-.008Zm13.636 56.74-8.023 8.024 7.02 7.019 8.023-8.022-7.02-7.02Zm-27.353.008-7.019 7.019 8.016 8.016 7.019-7.02-8.016-8.015Zm13.68-13.68-8.023 8.023 8.016 8.016 8.023-8.023-8.016-8.016Zm-8.971-8.971-4.687 11.315 8.001-8.001-3.314-3.314Zm17.933.009-3.305 3.305 7.979 7.979-4.674-11.284ZM64 57.607l-5.666 13.68c.096.072.188.15.278.232l.133.126 5.261 5.262 5.262-5.262c.128-.127.261-.244.4-.35L64 57.607Zm0-34.69a8 8 0 1 1 0 16 8 8 0 0 1 0-16Z"/>
|
||||
</$list>
|
||||
<$list filter="[{$:/state/http-requests}!match[0]]" variable="ignore">
|
||||
<path d="M109.395.952a4.002 4.002 0 0 1 3.787 2.708C117.529 11.62 120 20.753 120 30.462c0 15.186-6.044 28.96-15.858 39.047a4 4 0 1 1-6.47-4.626l-.12-.094C106.466 56.074 112 43.914 112 30.462c0-8.492-2.205-16.469-6.074-23.39l.054-.036a4 4 0 0 1 3.415-6.084Zm-90.762 0a4 4 0 0 1 3.072 6.562l.093.06A47.786 47.786 0 0 0 16 30.463c0 13.315 5.42 25.363 14.176 34.058l-.01.007a4 4 0 1 1-6.312 4.863l-.063.05C14.017 59.359 8 45.613 8 30.462c0-9.77 2.502-18.956 6.9-26.952A4.002 4.002 0 0 1 18.634.952Z"/><path d="M64.043 44.698a4.002 4.002 0 0 1 4.367 2.21l.084.188 30.403 73.4a4 4 0 0 1-7.307 3.25l-.084-.188-3.103-7.49-8.898 8.9a3.985 3.985 0 0 1-2.624 1.166l-.205.005a3.987 3.987 0 0 1-2.828-1.172l-9.849-9.848-9.847 9.848a3.985 3.985 0 0 1-2.624 1.167l-.204.005a3.987 3.987 0 0 1-2.829-1.172l-8.899-8.899-3.102 7.49a4 4 0 0 1-7.391-3.061l30.403-73.4a4.001 4.001 0 0 1 4.495-2.39l.042-.009ZM77.68 101.44l-8.023 8.023 7.02 7.019 8.023-8.022-7.02-7.02Zm-27.353.007-7.019 7.019 8.016 8.016 7.019-7.019-8.016-8.016Zm13.68-13.68-8.023 8.023 8.016 8.016 8.023-8.023-8.016-8.016Zm-8.971-8.971L50.348 90.11l8.001-8.001-3.314-3.314Zm17.933.009-3.305 3.305 7.979 7.979-4.674-11.284ZM64 57.152l-5.666 13.68c.096.073.188.15.278.232l.133.127 5.261 5.261 5.262-5.261c.128-.128.261-.244.4-.351L64 57.152ZM38.503 1.058a4 4 0 0 1 2.7 6.952l.17-.175C35.582 13.625 32 21.625 32 30.462c0 8.838 3.582 16.838 9.374 22.629a4 4 0 0 1-5.659 5.658l-.01.01C28.473 51.52 24 41.526 24 30.485 24 19.567 28.374 9.67 35.466 2.453a3.995 3.995 0 0 1 3.037-1.395ZM89.369.952c1.14 0 2.17.478 2.899 1.244l.005-.006C99.518 9.43 104 19.434 104 30.485c0 10.826-4.3 20.648-11.287 27.85a4 4 0 1 1-6.054-5.213l-.032-.032C92.418 47.299 96 39.299 96 30.462c0-8.73-3.496-16.643-9.164-22.416A4 4 0 0 1 89.368.952Zm-39.282 11.14a4 4 0 0 1 2.59 7.048l.01.009A15.95 15.95 0 0 0 48 30.462a15.95 15.95 0 0 0 4.687 11.315l-.01.01a4 4 0 1 1-5.82 5.47l.173.177A23.925 23.925 0 0 1 40 30.462a23.925 23.925 0 0 1 7.03-16.97l.01.01a3.991 3.991 0 0 1 3.047-1.41Zm27.895.07a3.99 3.99 0 0 1 2.984 1.336l.006-.005A23.925 23.925 0 0 1 88 30.463a23.92 23.92 0 0 1-6.707 16.642l-.3.305a4 4 0 1 1-5.679-5.632v-.002A15.95 15.95 0 0 0 80 30.462a15.95 15.95 0 0 0-4.685-11.312 4.012 4.012 0 0 1-1.333-2.987 4 4 0 0 1 4-4ZM64 22.463a8 8 0 1 1 0 16 8 8 0 0 1 0-16Z"/>
|
||||
</$list>
|
||||
</g></svg>
|
||||
@@ -67,6 +67,8 @@ More/Caption: more
|
||||
More/Hint: More actions
|
||||
NewHere/Caption: new here
|
||||
NewHere/Hint: Create a new tiddler tagged with this one
|
||||
NetworkActivity/Caption: network activity
|
||||
NetworkActivity/Hint: Cancel all network activity
|
||||
NewJournal/Caption: new journal
|
||||
NewJournal/Hint: Create a new journal tiddler
|
||||
NewJournalHere/Caption: new journal here
|
||||
|
||||
@@ -4,7 +4,7 @@ description: Saves a wiki to a new wiki folder
|
||||
<<.from-version "5.1.20">> Saves the current wiki as a wiki folder, including tiddlers, plugins and configuration:
|
||||
|
||||
```
|
||||
--savewikifolder <wikifolderpath> [<filter>]
|
||||
--savewikifolder <wikifolderpath> [<filter>] [ [<name>=<value>] ]*
|
||||
```
|
||||
|
||||
* The target wiki folder must be empty or non-existent
|
||||
@@ -12,8 +12,23 @@ description: Saves a wiki to a new wiki folder
|
||||
* Plugins from the official plugin library are replaced with references to those plugins in the `tiddlywiki.info` file
|
||||
* Custom plugins are unpacked into their own folder
|
||||
|
||||
The following options are supported:
|
||||
|
||||
* ''filter'': a filter expression that defines the tiddlers to include in the output.
|
||||
* ''explodePlugins'': defaults to "yes"
|
||||
** ''yes'' will "explode" plugins into separate tiddler files and save them to the plugin directory within the wiki folder
|
||||
** ''no'' will suppress exploding plugins into their constituent tiddler files. It will save the plugin as a single JSON tiddler in the tiddlers folder
|
||||
|
||||
Note that both ''explodePlugins'' options will produce wiki folders that build the same exact same original wiki. The difference lies in how plugins are represented in the wiki folder.
|
||||
|
||||
A common usage is to convert a TiddlyWiki HTML file into a wiki folder:
|
||||
|
||||
```
|
||||
tiddlywiki --load ./mywiki.html --savewikifolder ./mywikifolder
|
||||
```
|
||||
|
||||
Save the plugin to the tiddlers directory of the target wiki folder:
|
||||
|
||||
```
|
||||
tiddlywiki --load ./mywiki.html --savewikifolder ./mywikifolder explodePlugins=no
|
||||
```
|
||||
@@ -5,7 +5,14 @@ module-type: command
|
||||
|
||||
Command to save the current wiki as a wiki folder
|
||||
|
||||
--savewikifolder <wikifolderpath> [<filter>]
|
||||
--savewikifolder <wikifolderpath> [ [<name>=<value>] ]*
|
||||
|
||||
The following options are supported:
|
||||
|
||||
* ''filter'': a filter expression defining the tiddlers to be included in the output
|
||||
* ''explodePlugins'': set to "no" to suppress exploding plugins into their constituent shadow tiddlers (defaults to "yes")
|
||||
|
||||
Supports backward compatibility with --savewikifolder <wikifolderpath> [<filter>] [ [<name>=<value>] ]*
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
@@ -35,14 +42,28 @@ Command.prototype.execute = function() {
|
||||
if(this.params.length < 1) {
|
||||
return "Missing wiki folder path";
|
||||
}
|
||||
var wikifoldermaker = new WikiFolderMaker(this.params[0],this.params[1],this.commander);
|
||||
var regFilter = /^[a-zA-Z0-9\.\-_]+=/g, // dynamic parameters
|
||||
namedParames,
|
||||
tiddlerFilter,
|
||||
options = {};
|
||||
if (regFilter.test(this.params[1])) {
|
||||
namedParames = this.commander.extractNamedParameters(this.params.slice(1));
|
||||
tiddlerFilter = namedParames.filter || "[all[tiddlers]]";
|
||||
} else {
|
||||
namedParames = this.commander.extractNamedParameters(this.params.slice(2));
|
||||
tiddlerFilter = this.params[1];
|
||||
}
|
||||
tiddlerFilter = tiddlerFilter || "[all[tiddlers]]";
|
||||
options.explodePlugins = namedParames.explodePlugins || "yes";
|
||||
var wikifoldermaker = new WikiFolderMaker(this.params[0],tiddlerFilter,this.commander,options);
|
||||
return wikifoldermaker.save();
|
||||
};
|
||||
|
||||
function WikiFolderMaker(wikiFolderPath,wikiFilter,commander) {
|
||||
function WikiFolderMaker(wikiFolderPath,wikiFilter,commander,options) {
|
||||
this.wikiFolderPath = wikiFolderPath;
|
||||
this.wikiFilter = wikiFilter || "[all[tiddlers]]";
|
||||
this.wikiFilter = wikiFilter;
|
||||
this.commander = commander;
|
||||
this.explodePlugins = options.explodePlugins;
|
||||
this.wiki = commander.wiki;
|
||||
this.savedPaths = []; // So that we can detect filename clashes
|
||||
}
|
||||
@@ -93,10 +114,13 @@ WikiFolderMaker.prototype.save = function() {
|
||||
self.log("Adding built-in plugin: " + libraryDetails.name);
|
||||
newWikiInfo[libraryDetails.type] = newWikiInfo[libraryDetails.type] || [];
|
||||
$tw.utils.pushTop(newWikiInfo[libraryDetails.type],libraryDetails.name);
|
||||
} else {
|
||||
} else if(self.explodePlugins !== "no") {
|
||||
// A custom plugin
|
||||
self.log("Processing custom plugin: " + title);
|
||||
self.saveCustomPlugin(tiddler);
|
||||
} else if(self.explodePlugins === "no") {
|
||||
self.log("Processing custom plugin to tiddlders folder: " + title);
|
||||
self.saveTiddler("tiddlers", tiddler);
|
||||
}
|
||||
} else {
|
||||
// Ordinary tiddler
|
||||
|
||||
32
core/modules/filterrunprefixes/then.js
Normal file
32
core/modules/filterrunprefixes/then.js
Normal file
@@ -0,0 +1,32 @@
|
||||
/*\
|
||||
title: $:/core/modules/filterrunprefixes/then.js
|
||||
type: application/javascript
|
||||
module-type: filterrunprefix
|
||||
|
||||
Replace results of previous runs unless empty
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
Export our filter prefix function
|
||||
*/
|
||||
exports.then = function(operationSubFunction) {
|
||||
return function(results,source,widget) {
|
||||
if(results.length !== 0) {
|
||||
// Only run if previous run(s) produced results
|
||||
var thisRunResult = operationSubFunction(source,widget);
|
||||
if(thisRunResult.length !== 0) {
|
||||
// Replace results only if this run actually produces a result
|
||||
results.clear();
|
||||
results.pushTop(thisRunResult);
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
})();
|
||||
36
core/modules/filters/substitute.js
Normal file
36
core/modules/filters/substitute.js
Normal file
@@ -0,0 +1,36 @@
|
||||
/*\
|
||||
title: $:/core/modules/filters/substitute.js
|
||||
type: application/javascript
|
||||
module-type: filteroperator
|
||||
|
||||
Filter operator for substituting variables and embedded filter expressions with their corresponding values
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
|
||||
/*jslint node: true, browser: true */
|
||||
/*global $tw: false */
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
Export our filter function
|
||||
*/
|
||||
exports.substitute = function(source,operator,options) {
|
||||
var results = [],
|
||||
operands = [];
|
||||
$tw.utils.each(operator.operands,function(operand,index){
|
||||
operands.push({
|
||||
name: (index + 1).toString(),
|
||||
value: operand
|
||||
});
|
||||
});
|
||||
source(function(tiddler,title) {
|
||||
if(title) {
|
||||
results.push(options.wiki.getSubstitutedText(title,options.widget,{substitutions:operands}));
|
||||
}
|
||||
});
|
||||
return results;
|
||||
};
|
||||
|
||||
})();
|
||||
|
||||
@@ -305,10 +305,11 @@ exports.parseAttribute = function(source,pos) {
|
||||
start: pos
|
||||
};
|
||||
// Define our regexps
|
||||
var reAttributeName = /([^\/\s>"'=]+)/g,
|
||||
reUnquotedAttribute = /([^\/\s<>"'=]+)/g,
|
||||
var reAttributeName = /([^\/\s>"'`=]+)/g,
|
||||
reUnquotedAttribute = /([^\/\s<>"'`=]+)/g,
|
||||
reFilteredValue = /\{\{\{([\S\s]+?)\}\}\}/g,
|
||||
reIndirectValue = /\{\{([^\}]+)\}\}/g;
|
||||
reIndirectValue = /\{\{([^\}]+)\}\}/g,
|
||||
reSubstitutedValue = /(?:```([\s\S]*?)```|`([^`]|[\S\s]*?)`)/g;
|
||||
// Skip whitespace
|
||||
pos = $tw.utils.skipWhiteSpace(source,pos);
|
||||
// Get the attribute name
|
||||
@@ -361,8 +362,15 @@ exports.parseAttribute = function(source,pos) {
|
||||
node.type = "macro";
|
||||
node.value = macroInvocation;
|
||||
} else {
|
||||
node.type = "string";
|
||||
node.value = "true";
|
||||
var substitutedValue = $tw.utils.parseTokenRegExp(source,pos,reSubstitutedValue);
|
||||
if(substitutedValue) {
|
||||
pos = substitutedValue.end;
|
||||
node.type = "substituted";
|
||||
node.rawValue = substitutedValue.match[1] || substitutedValue.match[2];
|
||||
} else {
|
||||
node.type = "string";
|
||||
node.value = "true";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,6 +15,7 @@ Startup logic concerned with managing plugins
|
||||
// Export name and synchronous status
|
||||
exports.name = "plugins";
|
||||
exports.after = ["load-modules"];
|
||||
exports.before = ["startup"];
|
||||
exports.synchronous = true;
|
||||
|
||||
var TITLE_REQUIRE_RELOAD_DUE_TO_PLUGIN_CHANGE = "$:/status/RequireReloadDueToPluginChange";
|
||||
|
||||
@@ -20,6 +20,38 @@ exports.before = ["story"];
|
||||
exports.synchronous = true;
|
||||
|
||||
exports.startup = function() {
|
||||
// Install the HTTP client event handler
|
||||
$tw.httpClient = new $tw.utils.HttpClient();
|
||||
var getPropertiesWithPrefix = function(properties,prefix) {
|
||||
var result = Object.create(null);
|
||||
$tw.utils.each(properties,function(value,name) {
|
||||
if(name.indexOf(prefix) === 0) {
|
||||
result[name.substring(prefix.length)] = properties[name];
|
||||
}
|
||||
});
|
||||
return result;
|
||||
};
|
||||
$tw.rootWidget.addEventListener("tm-http-request",function(event) {
|
||||
var params = event.paramObject || {};
|
||||
$tw.httpClient.initiateHttpRequest({
|
||||
wiki: event.widget.wiki,
|
||||
url: params.url,
|
||||
method: params.method,
|
||||
body: params.body,
|
||||
oncompletion: params.oncompletion,
|
||||
onprogress: params.onprogress,
|
||||
bindStatus: params["bind-status"],
|
||||
bindProgress: params["bind-progress"],
|
||||
variables: getPropertiesWithPrefix(params,"var-"),
|
||||
headers: getPropertiesWithPrefix(params,"header-"),
|
||||
passwordHeaders: getPropertiesWithPrefix(params,"password-header-"),
|
||||
queryStrings: getPropertiesWithPrefix(params,"query-"),
|
||||
passwordQueryStrings: getPropertiesWithPrefix(params,"password-query-")
|
||||
});
|
||||
});
|
||||
$tw.rootWidget.addEventListener("tm-http-cancel-all-requests",function(event) {
|
||||
$tw.httpClient.cancelAllHttpRequests();
|
||||
});
|
||||
// Install the modal message mechanism
|
||||
$tw.modal = new $tw.utils.Modal($tw.wiki);
|
||||
$tw.rootWidget.addEventListener("tm-modal",function(event) {
|
||||
|
||||
@@ -3,7 +3,7 @@ title: $:/core/modules/utils/dom/http.js
|
||||
type: application/javascript
|
||||
module-type: utils
|
||||
|
||||
Browser HTTP support
|
||||
HTTP support
|
||||
|
||||
\*/
|
||||
(function(){
|
||||
@@ -13,11 +13,204 @@ Browser HTTP support
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
A quick and dirty HTTP function; to be refactored later. Options are:
|
||||
Manage tm-http-request events. Options include:
|
||||
wiki: Reference to the wiki to be used for state tiddler tracking
|
||||
stateTrackerTitle: Title of tiddler to be used for state tiddler tracking
|
||||
*/
|
||||
function HttpClient(options) {
|
||||
options = options || {};
|
||||
this.nextId = 1;
|
||||
this.wiki = options.wiki || $tw.wiki;
|
||||
this.stateTrackerTitle = options.stateTrackerTitle || "$:/state/http-requests";
|
||||
this.requests = []; // Array of {id: string,request: HttpClientRequest}
|
||||
this.updateRequestTracker();
|
||||
}
|
||||
|
||||
/*
|
||||
Return the index into this.requests[] corresponding to a given ID. Returns null if not found
|
||||
*/
|
||||
HttpClient.prototype.getRequestIndex = function(targetId) {
|
||||
var targetIndex = null;
|
||||
$tw.utils.each(this.requests,function(requestInfo,index) {
|
||||
if(requestInfo.id === targetId) {
|
||||
targetIndex = index;
|
||||
}
|
||||
});
|
||||
return targetIndex;
|
||||
};
|
||||
|
||||
/*
|
||||
Update the state tiddler that is tracking the outstanding requests
|
||||
*/
|
||||
HttpClient.prototype.updateRequestTracker = function() {
|
||||
this.wiki.addTiddler({title: this.stateTrackerTitle, text: "" + this.requests.length});
|
||||
};
|
||||
|
||||
HttpClient.prototype.initiateHttpRequest = function(options) {
|
||||
var self = this,
|
||||
id = this.nextId,
|
||||
request = new HttpClientRequest(options);
|
||||
this.nextId += 1;
|
||||
this.requests.push({id: id, request: request});
|
||||
this.updateRequestTracker();
|
||||
request.send(function(err) {
|
||||
var targetIndex = self.getRequestIndex(id);
|
||||
if(targetIndex !== null) {
|
||||
self.requests.splice(targetIndex,1);
|
||||
self.updateRequestTracker();
|
||||
}
|
||||
});
|
||||
return id;
|
||||
};
|
||||
|
||||
HttpClient.prototype.cancelAllHttpRequests = function() {
|
||||
var self = this;
|
||||
if(this.requests.length > 0) {
|
||||
for(var t=this.requests.length - 1; t--; t>=0) {
|
||||
var requestInfo = this.requests[t];
|
||||
requestInfo.request.cancel();
|
||||
}
|
||||
}
|
||||
this.requests = [];
|
||||
this.updateRequestTracker();
|
||||
};
|
||||
|
||||
HttpClient.prototype.cancelHttpRequest = function(targetId) {
|
||||
var targetIndex = this.getRequestIndex(targetId);
|
||||
if(targetIndex !== null) {
|
||||
this.requests[targetIndex].request.cancel();
|
||||
this.requests.splice(targetIndex,1);
|
||||
this.updateRequestTracker();
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
Initiate an HTTP request. Options:
|
||||
wiki: wiki to be used for executing action strings
|
||||
url: URL for request
|
||||
method: method eg GET, POST
|
||||
body: text of request body
|
||||
oncompletion: action string to be invoked on completion
|
||||
onprogress: action string to be invoked on progress updates
|
||||
bindStatus: optional title of tiddler to which status ("pending", "complete", "error") should be written
|
||||
bindProgress: optional title of tiddler to which the progress of the request (0 to 100) should be bound
|
||||
variables: hashmap of variable name to string value passed to action strings
|
||||
headers: hashmap of header name to header value to be sent with the request
|
||||
passwordHeaders: hashmap of header name to password store name to be sent with the request
|
||||
queryStrings: hashmap of query string parameter name to parameter value to be sent with the request
|
||||
passwordQueryStrings: hashmap of query string parameter name to password store name to be sent with the request
|
||||
*/
|
||||
function HttpClientRequest(options) {
|
||||
var self = this;
|
||||
console.log("Initiating an HTTP request",options)
|
||||
this.wiki = options.wiki;
|
||||
this.completionActions = options.oncompletion;
|
||||
this.progressActions = options.onprogress;
|
||||
this.bindStatus = options["bind-status"];
|
||||
this.bindProgress = options["bind-progress"];
|
||||
this.method = options.method || "GET";
|
||||
this.body = options.body || "";
|
||||
this.variables = options.variables;
|
||||
var url = options.url;
|
||||
$tw.utils.each(options.queryStrings,function(value,name) {
|
||||
url = $tw.utils.setQueryStringParameter(url,name,value);
|
||||
});
|
||||
$tw.utils.each(options.passwordQueryStrings,function(value,name) {
|
||||
url = $tw.utils.setQueryStringParameter(url,name,$tw.utils.getPassword(value) || "");
|
||||
});
|
||||
this.url = url;
|
||||
this.requestHeaders = {};
|
||||
$tw.utils.each(options.headers,function(value,name) {
|
||||
self.requestHeaders[name] = value;
|
||||
});
|
||||
$tw.utils.each(options.passwordHeaders,function(value,name) {
|
||||
self.requestHeaders[name] = $tw.utils.getPassword(value) || "";
|
||||
});
|
||||
}
|
||||
|
||||
HttpClientRequest.prototype.send = function(callback) {
|
||||
var self = this,
|
||||
setBinding = function(title,text) {
|
||||
if(title) {
|
||||
this.wiki.addTiddler(new $tw.Tiddler({title: title, text: text}));
|
||||
}
|
||||
};
|
||||
if(this.url) {
|
||||
setBinding(this.bindStatus,"pending");
|
||||
setBinding(this.bindProgress,"0");
|
||||
// Set the request tracker tiddler
|
||||
var requestTrackerTitle = this.wiki.generateNewTitle("$:/temp/HttpRequest");
|
||||
this.wiki.addTiddler({
|
||||
title: requestTrackerTitle,
|
||||
tags: "$:/tags/HttpRequest",
|
||||
text: JSON.stringify({
|
||||
url: this.url,
|
||||
type: this.method,
|
||||
status: "inprogress",
|
||||
headers: this.requestHeaders,
|
||||
data: this.body
|
||||
})
|
||||
});
|
||||
this.xhr = $tw.utils.httpRequest({
|
||||
url: this.url,
|
||||
type: this.method,
|
||||
headers: this.requestHeaders,
|
||||
data: this.body,
|
||||
callback: function(err,data,xhr) {
|
||||
var hasSucceeded = xhr.status >= 200 && xhr.status < 300,
|
||||
completionCode = hasSucceeded ? "complete" : "error",
|
||||
headers = {};
|
||||
$tw.utils.each(xhr.getAllResponseHeaders().split("\r\n"),function(line) {
|
||||
var pos = line.indexOf(":");
|
||||
if(pos !== -1) {
|
||||
headers[line.substr(0,pos)] = line.substr(pos + 1).trim();
|
||||
}
|
||||
});
|
||||
setBinding(self.bindStatus,completionCode);
|
||||
setBinding(self.bindProgress,"100");
|
||||
var resultVariables = {
|
||||
status: xhr.status.toString(),
|
||||
statusText: xhr.statusText,
|
||||
error: (err || "").toString(),
|
||||
data: (data || "").toString(),
|
||||
headers: JSON.stringify(headers)
|
||||
};
|
||||
self.wiki.addTiddler(new $tw.Tiddler(self.wiki.getTiddler(requestTrackerTitle),{
|
||||
status: completionCode,
|
||||
}));
|
||||
self.wiki.invokeActionString(self.completionActions,undefined,$tw.utils.extend({},self.variables,resultVariables),{parentWidget: $tw.rootWidget});
|
||||
callback(hasSucceeded ? null : xhr.statusText);
|
||||
// console.log("Back!",err,data,xhr);
|
||||
},
|
||||
progress: function(lengthComputable,loaded,total) {
|
||||
if(lengthComputable) {
|
||||
setBinding(self.bindProgress,"" + Math.floor((loaded/total) * 100))
|
||||
}
|
||||
self.wiki.invokeActionString(self.progressActions,undefined,{
|
||||
lengthComputable: lengthComputable ? "yes" : "no",
|
||||
loaded: loaded,
|
||||
total: total
|
||||
},{parentWidget: $tw.rootWidget});
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
HttpClientRequest.prototype.cancel = function() {
|
||||
if(this.xhr) {
|
||||
this.xhr.abort();
|
||||
}
|
||||
};
|
||||
|
||||
exports.HttpClient = HttpClient;
|
||||
|
||||
/*
|
||||
Make an HTTP request. Options are:
|
||||
url: URL to retrieve
|
||||
headers: hashmap of headers to send
|
||||
type: GET, PUT, POST etc
|
||||
callback: function invoked with (err,data,xhr)
|
||||
progress: optional function invoked with (lengthComputable,loaded,total)
|
||||
returnProp: string name of the property to return as first argument of callback
|
||||
*/
|
||||
exports.httpRequest = function(options) {
|
||||
@@ -83,8 +276,16 @@ exports.httpRequest = function(options) {
|
||||
options.callback($tw.language.getString("Error/XMLHttpRequest") + ": " + this.status,null,this);
|
||||
}
|
||||
};
|
||||
// Handle progress
|
||||
if(options.progress) {
|
||||
request.onprogress = function(event) {
|
||||
console.log("Progress event",event)
|
||||
options.progress(event.lengthComputable,event.loaded,event.total);
|
||||
};
|
||||
}
|
||||
// Make the request
|
||||
request.open(type,url,true);
|
||||
// Headers
|
||||
if(headers) {
|
||||
$tw.utils.each(headers,function(header,headerTitle,object) {
|
||||
request.setRequestHeader(headerTitle,header);
|
||||
@@ -96,6 +297,7 @@ exports.httpRequest = function(options) {
|
||||
if(!hasHeader("X-Requested-With") && !isSimpleRequest(type,headers)) {
|
||||
request.setRequestHeader("X-Requested-With","TiddlyWiki");
|
||||
}
|
||||
// Send data
|
||||
try {
|
||||
request.send(data);
|
||||
} catch(e) {
|
||||
@@ -104,4 +306,19 @@ exports.httpRequest = function(options) {
|
||||
return request;
|
||||
};
|
||||
|
||||
exports.setQueryStringParameter = function(url,paramName,paramValue) {
|
||||
var URL = $tw.browser ? window.URL : require("url").URL,
|
||||
newUrl;
|
||||
try {
|
||||
newUrl = new URL(url);
|
||||
} catch(e) {
|
||||
}
|
||||
if(newUrl && paramName) {
|
||||
newUrl.searchParams.set(paramName,paramValue || "");
|
||||
return newUrl.toString();
|
||||
} else {
|
||||
return url;
|
||||
}
|
||||
};
|
||||
|
||||
})();
|
||||
|
||||
@@ -177,8 +177,7 @@ TranscludeWidget.prototype.getTransclusionTarget = function() {
|
||||
var variableInfo = this.getVariableInfo(this.transcludeVariable,{params: this.getOrderedTransclusionParameters()}),
|
||||
srcVariable = variableInfo && variableInfo.srcVariable;
|
||||
if(variableInfo.text) {
|
||||
if(srcVariable.isFunctionDefinition) {
|
||||
// Function to return parameters by name or position
|
||||
if(srcVariable && srcVariable.isFunctionDefinition) {
|
||||
var result = (variableInfo.resultList ? variableInfo.resultList[0] : variableInfo.text) || "";
|
||||
parser = {
|
||||
tree: [{
|
||||
@@ -208,7 +207,7 @@ TranscludeWidget.prototype.getTransclusionTarget = function() {
|
||||
if(variableInfo.isCacheable && srcVariable[cacheKey]) {
|
||||
parser = srcVariable[cacheKey];
|
||||
} else {
|
||||
parser = this.wiki.parseText(this.transcludeType,variableInfo.text || "",{parseAsInline: parseAsInline, configTrimWhiteSpace: srcVariable.configTrimWhiteSpace});
|
||||
parser = this.wiki.parseText(this.transcludeType,variableInfo.text || "",{parseAsInline: parseAsInline, configTrimWhiteSpace: srcVariable && srcVariable.configTrimWhiteSpace});
|
||||
if(variableInfo.isCacheable) {
|
||||
srcVariable[cacheKey] = parser;
|
||||
}
|
||||
@@ -216,7 +215,7 @@ TranscludeWidget.prototype.getTransclusionTarget = function() {
|
||||
}
|
||||
if(parser) {
|
||||
// Add parameters widget for procedures and custom widgets
|
||||
if(srcVariable.isProcedureDefinition || srcVariable.isWidgetDefinition) {
|
||||
if(srcVariable && (srcVariable.isProcedureDefinition || srcVariable.isWidgetDefinition)) {
|
||||
parser = {
|
||||
tree: [
|
||||
{
|
||||
@@ -235,7 +234,7 @@ TranscludeWidget.prototype.getTransclusionTarget = function() {
|
||||
}
|
||||
$tw.utils.addAttributeToParseTreeNode(parser.tree[0],name,param["default"])
|
||||
});
|
||||
} else {
|
||||
} else if(srcVariable && (srcVariable.isMacroDefinition || !srcVariable.isFunctionDefinition)) {
|
||||
// For macros and ordinary variables, wrap the parse tree in a vars widget assigning the parameters to variables named "__paramname__"
|
||||
parser = {
|
||||
tree: [
|
||||
|
||||
@@ -182,8 +182,7 @@ Widget.prototype.getVariableInfo = function(name,options) {
|
||||
}
|
||||
return {
|
||||
text: text,
|
||||
resultList: [text],
|
||||
srcVariable: {}
|
||||
resultList: [text]
|
||||
};
|
||||
};
|
||||
|
||||
@@ -380,6 +379,8 @@ Widget.prototype.computeAttribute = function(attribute) {
|
||||
} else if(attribute.type === "macro") {
|
||||
var variableInfo = this.getVariableInfo(attribute.value.name,{params: attribute.value.params});
|
||||
value = variableInfo.text;
|
||||
} else if(attribute.type === "substituted") {
|
||||
value = this.wiki.getSubstitutedText(attribute.rawValue,this) || "";
|
||||
} else { // String attribute
|
||||
value = attribute.value;
|
||||
}
|
||||
@@ -718,23 +719,44 @@ Widget.prototype.findFirstDomNode = function() {
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget or its children
|
||||
Entry into destroy procedure
|
||||
*/
|
||||
Widget.prototype.destroyChildren = function() {
|
||||
$tw.utils.each(this.children,function(childWidget) {
|
||||
childWidget.destroy();
|
||||
});
|
||||
};
|
||||
/*
|
||||
Legacy entry into destroy procedure
|
||||
*/
|
||||
Widget.prototype.removeChildDomNodes = function() {
|
||||
// If this widget has directly created DOM nodes, delete them and exit. This assumes that any child widgets are contained within the created DOM nodes, which would normally be the case
|
||||
this.destroy();
|
||||
};
|
||||
/*
|
||||
Default destroy
|
||||
*/
|
||||
Widget.prototype.destroy = function() {
|
||||
// call children to remove their resources
|
||||
this.destroyChildren();
|
||||
// remove our resources
|
||||
this.children = [];
|
||||
this.removeLocalDomNodes();
|
||||
};
|
||||
|
||||
/*
|
||||
Remove any DOM nodes created by this widget
|
||||
*/
|
||||
Widget.prototype.removeLocalDomNodes = function() {
|
||||
// If this widget has directly created DOM nodes, delete them and exit.
|
||||
if(this.domNodes.length > 0) {
|
||||
$tw.utils.each(this.domNodes,function(domNode) {
|
||||
domNode.parentNode.removeChild(domNode);
|
||||
});
|
||||
this.domNodes = [];
|
||||
} else {
|
||||
// Otherwise, ask the child widgets to delete their DOM nodes
|
||||
$tw.utils.each(this.children,function(childWidget) {
|
||||
childWidget.removeChildDomNodes();
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
Invoke the action widgets that are descendents of the current widget.
|
||||
*/
|
||||
|
||||
@@ -1063,6 +1063,34 @@ exports.getTextReferenceParserInfo = function(title,field,index,options) {
|
||||
return parserInfo;
|
||||
}
|
||||
|
||||
/*
|
||||
Parse a block of text of a specified MIME type
|
||||
text: text on which to perform substitutions
|
||||
widget
|
||||
options: see below
|
||||
Options include:
|
||||
substitutions: an optional array of substitutions
|
||||
*/
|
||||
exports.getSubstitutedText = function(text,widget,options) {
|
||||
options = options || {};
|
||||
text = text || "";
|
||||
var self = this,
|
||||
substitutions = options.substitutions || [],
|
||||
output;
|
||||
// Evaluate embedded filters and substitute with first result
|
||||
output = text.replace(/\$\{([\S\s]+?)\}\$/g, function(match,filter) {
|
||||
return self.filterTiddlers(filter,widget)[0] || "";
|
||||
});
|
||||
// Process any substitutions provided in options
|
||||
$tw.utils.each(substitutions,function(substitute) {
|
||||
output = $tw.utils.replaceString(output,new RegExp("\\$" + $tw.utils.escapeRegExp(substitute.name) + "\\$","mg"),substitute.value);
|
||||
});
|
||||
// Substitute any variable references with their values
|
||||
return output.replace(/\$\((\w+)\)\$/g, function(match,varname) {
|
||||
return widget.getVariable(varname,{defaultValue: ""})
|
||||
});
|
||||
};
|
||||
|
||||
/*
|
||||
Make a widget tree for a parse tree
|
||||
parser: parser object
|
||||
@@ -1415,6 +1443,14 @@ exports.checkTiddlerText = function(title,targetText,options) {
|
||||
return text === targetText;
|
||||
}
|
||||
|
||||
/*
|
||||
Execute an action string without an associated context widget
|
||||
*/
|
||||
exports.invokeActionString = function(actions,event,variables,options) {
|
||||
var widget = this.makeWidget(null,{parentWidget: options.parentWidget});
|
||||
widget.invokeActionString(actions,null,event,variables);
|
||||
};
|
||||
|
||||
/*
|
||||
Read an array of browser File objects, invoking callback(tiddlerFieldsArray) once they're all read
|
||||
*/
|
||||
|
||||
@@ -54,6 +54,7 @@ modal-footer-background: #f5f5f5
|
||||
modal-footer-border: #dddddd
|
||||
modal-header-border: #eeeeee
|
||||
muted-foreground: #bbb
|
||||
network-activity-foreground: #448844
|
||||
notification-background: #ffffdd
|
||||
notification-border: #999999
|
||||
page-background: #f4f4f4
|
||||
|
||||
@@ -3,6 +3,7 @@ tags: $:/tags/Exporter
|
||||
description: {{$:/language/Exporters/StaticRiver}}
|
||||
extension: .html
|
||||
|
||||
\define tv-config-static() yes
|
||||
\define tv-wikilink-template() #$uri_encoded$
|
||||
\define tv-config-toolbar-icons() no
|
||||
\define tv-config-toolbar-text() no
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
title: $:/core/templates/server/static.tiddler.html
|
||||
|
||||
\whitespace trim
|
||||
\define tv-config-static() yes
|
||||
\define tv-wikilink-template() $uri_encoded$
|
||||
\import [subfilter{$:/core/config/GlobalImportFilter}]
|
||||
<html>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
title: $:/core/templates/static.template.html
|
||||
type: text/vnd.tiddlywiki-html
|
||||
|
||||
\define tv-config-static() yes
|
||||
\define tv-wikilink-template() static/$uri_doubleencoded$.html
|
||||
\define tv-config-toolbar-icons() no
|
||||
\define tv-config-toolbar-text() no
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
title: $:/core/templates/static.tiddler.html
|
||||
|
||||
\define tv-wikilink-template() $uri_doubleencoded$.html
|
||||
\define tv-config-static() yes
|
||||
\define tv-config-toolbar-icons() no
|
||||
\define tv-config-toolbar-text() no
|
||||
\define tv-config-toolbar-class() tc-btn-invisible
|
||||
|
||||
@@ -18,7 +18,7 @@ title: $:/core/ui/EditorToolbar/link-dropdown
|
||||
|
||||
\define external-link()
|
||||
\whitespace trim
|
||||
<$button class="tc-btn-invisible" style="width: auto; display: inline-block; background-colour: inherit;" actions=<<add-link-actions>>>
|
||||
<$button class="tc-btn-invisible tc-btn-mini" style="width: auto; display: inline-block; background-colour: inherit;" actions=<<add-link-actions>>>
|
||||
{{$:/core/images/chevron-right}}
|
||||
</$button>
|
||||
\end
|
||||
@@ -45,7 +45,7 @@ title: $:/core/ui/EditorToolbar/link-dropdown
|
||||
<$reveal tag="span" state=<<storeTitle>> type="nomatch" text="">
|
||||
<<external-link>>
|
||||
 
|
||||
<$button class="tc-btn-invisible" style="width: auto; display: inline-block; background-colour: inherit;">
|
||||
<$button class="tc-btn-invisible tc-btn-mini" style="width: auto; display: inline-block; background-colour: inherit;">
|
||||
<<cancel-search-actions>><$set name="cssEscapedTitle" value={{{ [<storyTiddler>escapecss[]] }}}><$action-sendmessage $message="tm-focus-selector" $param=<<get-focus-selector>>/></$set>
|
||||
{{$:/core/images/close-button}}
|
||||
</$button>
|
||||
|
||||
@@ -3,15 +3,14 @@ tags: $:/tags/MoreSideBar
|
||||
caption: {{$:/language/SideBar/Tags/Caption}}
|
||||
|
||||
\whitespace trim
|
||||
|
||||
<$let tv-config-toolbar-icons="yes" tv-config-toolbar-text="yes" tv-config-toolbar-class="">
|
||||
<div class="tc-tiny-v-gap-bottom">
|
||||
{{$:/core/ui/Buttons/tag-manager}}
|
||||
{{$:/core/ui/Buttons/tag-manager}}
|
||||
</div>
|
||||
</$let>
|
||||
<$list filter={{$:/core/Filters/AllTags!!filter}}>
|
||||
<div class="tc-tiny-v-gap-bottom">
|
||||
<$transclude tiddler="$:/core/ui/TagTemplate"/>
|
||||
<$transclude tiddler="$:/core/ui/TagTemplate"/>
|
||||
</div>
|
||||
</$list>
|
||||
<hr class="tc-untagged-separator">
|
||||
|
||||
16
core/ui/PageControls/network-activity.tid
Normal file
16
core/ui/PageControls/network-activity.tid
Normal file
@@ -0,0 +1,16 @@
|
||||
title: $:/core/ui/Buttons/network-activity
|
||||
tags: $:/tags/PageControls
|
||||
caption: {{$:/core/images/network-activity}} {{$:/language/Buttons/NetworkActivity/Caption}}
|
||||
description: {{$:/language/Buttons/NetworkActivity/Hint}}
|
||||
|
||||
\whitespace trim
|
||||
<$button message="tm-http-cancel-all-requests" tooltip={{$:/language/Buttons/NetworkActivity/Hint}} aria-label={{$:/language/Buttons/NetworkActivity/Caption}} class=<<tv-config-toolbar-class>>>
|
||||
<$list filter="[<tv-config-toolbar-icons>match[yes]]">
|
||||
{{$:/core/images/network-activity}}
|
||||
</$list>
|
||||
<$list filter="[<tv-config-toolbar-text>match[yes]]">
|
||||
<span class="tc-btn-text">
|
||||
<$text text={{$:/language/Buttons/NetworkActivity/Caption}}/>
|
||||
</span>
|
||||
</$list>
|
||||
</$button>
|
||||
@@ -2,22 +2,29 @@ title: $:/core/ui/TagPickerTagTemplate
|
||||
|
||||
\whitespace trim
|
||||
<$button class=<<button-classes>> tag="a" tooltip={{$:/language/EditTemplate/Tags/Add/Button/Hint}}>
|
||||
<$list filter="[<saveTiddler>minlength[1]]">
|
||||
<$action-listops $tiddler=<<saveTiddler>> $field=<<tagField>> $subfilter="[<tag>]"/>
|
||||
</$list>
|
||||
<$set name="currentTiddlerCSSEscaped" value={{{ [<saveTiddler>escapecss[]] }}}>
|
||||
<$action-sendmessage $message="tm-focus-selector" $param=<<get-tagpicker-focus-selector>> preventScroll="true"/>
|
||||
</$set>
|
||||
<<delete-tag-state-tiddlers>>
|
||||
<$list filter="[<refreshTitle>minlength[1]]">
|
||||
<$action-setfield $tiddler=<<refreshTitle>> text="yes"/>
|
||||
</$list>
|
||||
<<actions>>
|
||||
<$set name="backgroundColor" value={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerColourFilter]!is[draft]get[text]] }}}>
|
||||
<$wikify name="foregroundColor" text="""<$macrocall $name="contrastcolour" target=<<backgroundColor>> fallbackTarget=<<fallbackTarget>> colourA=<<colourA>> colourB=<<colourB>>/>""">
|
||||
<span class="tc-tag-label tc-btn-invisible" style=<<tag-pill-styles>> data-tag-title=<<currentTiddler>> >
|
||||
{{||$:/core/ui/TiddlerIcon}}<$view field="title" format="text"/>
|
||||
</span>
|
||||
</$wikify>
|
||||
</$set>
|
||||
<$list filter="[<saveTiddler>minlength[1]]">
|
||||
<$action-listops $tiddler=<<saveTiddler>> $field=<<tagField>> $subfilter="[<tag>]"/>
|
||||
</$list>
|
||||
<$set name="currentTiddlerCSSEscaped" value={{{ [<saveTiddler>escapecss[]] }}}>
|
||||
<$action-sendmessage $message="tm-focus-selector" $param=<<get-tagpicker-focus-selector>> preventScroll="true"/>
|
||||
</$set>
|
||||
<<delete-tag-state-tiddlers>>
|
||||
<$list filter="[<refreshTitle>minlength[1]]">
|
||||
<$action-setfield $tiddler=<<refreshTitle>> text="yes"/>
|
||||
</$list>
|
||||
<<actions>>
|
||||
<$set name="backgroundColor"
|
||||
value={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerColourFilter]!is[draft]get[text]] }}}
|
||||
>
|
||||
<$wikify name="foregroundColor"
|
||||
text="""<$macrocall $name="contrastcolour" target=<<backgroundColor>> fallbackTarget=<<fallbackTarget>> colourA=<<colourA>> colourB=<<colourB>>/>"""
|
||||
>
|
||||
<span class="tc-tag-label tc-btn-invisible"
|
||||
style=<<tag-pill-styles>>
|
||||
data-tag-title=<<currentTiddler>>
|
||||
>
|
||||
{{||$:/core/ui/TiddlerIcon}}<$view field="title" format="text"/>
|
||||
</span>
|
||||
</$wikify>
|
||||
</$set>
|
||||
</$button>
|
||||
|
||||
@@ -3,16 +3,23 @@ title: $:/core/ui/TagTemplate
|
||||
\whitespace trim
|
||||
<span class="tc-tag-list-item" data-tag-title=<<currentTiddler>>>
|
||||
<$set name="transclusion" value=<<currentTiddler>>>
|
||||
<$macrocall $name="tag-pill-body" tag=<<currentTiddler>> icon={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerIconFilter]!is[draft]get[text]] }}} colour={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerColourFilter]!is[draft]get[text]] }}} palette={{$:/palette}} element-tag="""$button""" element-attributes="""popup=<<qualify "$:/state/popup/tag">> dragFilter='[all[current]tagging[]]' tag='span'"""/>
|
||||
<$reveal state=<<qualify "$:/state/popup/tag">> type="popup" position="below" animate="yes" class="tc-drop-down">
|
||||
<$set name="tv-show-missing-links" value="yes">
|
||||
<$transclude tiddler="$:/core/ui/ListItemTemplate"/>
|
||||
</$set>
|
||||
<$list filter="[all[shadows+tiddlers]tag[$:/tags/TagDropdown]!has[draft.of]]" variable="listItem">
|
||||
<$transclude tiddler=<<listItem>>/>
|
||||
</$list>
|
||||
<hr>
|
||||
<$macrocall $name="list-tagged-draggable" tag=<<currentTiddler>>/>
|
||||
</$reveal>
|
||||
<$macrocall $name="tag-pill-body"
|
||||
tag=<<currentTiddler>>
|
||||
icon={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerIconFilter]!is[draft]get[text]] }}}
|
||||
colour={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerColourFilter]!is[draft]get[text]] }}}
|
||||
palette={{$:/palette}}
|
||||
element-tag="$button"
|
||||
element-attributes="""popup=<<qualify "$:/state/popup/tag">> dragFilter="[all[current]tagging[]]" tag='span'"""
|
||||
/>
|
||||
<$reveal state=<<qualify "$:/state/popup/tag">> type="popup" position="below" animate="yes" class="tc-drop-down">
|
||||
<$set name="tv-show-missing-links" value="yes">
|
||||
<$transclude tiddler="$:/core/ui/ListItemTemplate"/>
|
||||
</$set>
|
||||
<$list filter="[all[shadows+tiddlers]tag[$:/tags/TagDropdown]!has[draft.of]]" variable="listItem">
|
||||
<$transclude tiddler=<<listItem>>/>
|
||||
</$list>
|
||||
<hr>
|
||||
<$macrocall $name="list-tagged-draggable" tag=<<currentTiddler>>/>
|
||||
</$reveal>
|
||||
</$set>
|
||||
</span>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
title: $:/config/OfficialPluginLibrary
|
||||
tags: $:/tags/PluginLibrary
|
||||
url: https://tiddlywiki.com/library/v5.2.8/index.html
|
||||
url: https://tiddlywiki.com/library/v5.3.0/index.html
|
||||
caption: {{$:/language/OfficialPluginLibrary}}
|
||||
|
||||
{{$:/language/OfficialPluginLibrary/Hint}}
|
||||
|
||||
@@ -13,6 +13,7 @@ core/ui/Buttons/language: hide
|
||||
core/ui/Buttons/tag-manager: hide
|
||||
core/ui/Buttons/manager: hide
|
||||
core/ui/Buttons/more-page-actions: hide
|
||||
core/ui/Buttons/network-activity: hide
|
||||
core/ui/Buttons/new-journal: hide
|
||||
core/ui/Buttons/new-image: hide
|
||||
core/ui/Buttons/palette: hide
|
||||
|
||||
@@ -9,26 +9,50 @@ color:$(foregroundColor)$;
|
||||
|
||||
<!-- This has no whitespace trim to avoid modifying $actions$. Closing tags omitted for brevity. -->
|
||||
\define tag-pill-inner(tag,icon,colour,fallbackTarget,colourA,colourB,element-tag,element-attributes,actions)
|
||||
\whitespace trim
|
||||
<$vars
|
||||
foregroundColor=<<contrastcolour target:"""$colour$""" fallbackTarget:"""$fallbackTarget$""" colourA:"""$colourA$""" colourB:"""$colourB$""">>
|
||||
backgroundColor="""$colour$"""
|
||||
><$element-tag$
|
||||
backgroundColor=<<__colour__>>
|
||||
>
|
||||
<$element-tag$
|
||||
$element-attributes$
|
||||
class="tc-tag-label tc-btn-invisible"
|
||||
style=<<tag-pill-styles>>
|
||||
>$actions$<$transclude tiddler="""$icon$"""/><$view tiddler=<<__tag__>> field="title" format="text" /></$element-tag$>
|
||||
>
|
||||
<<__actions__>>
|
||||
<$transclude tiddler=<<__icon__>>/>
|
||||
<$view tiddler=<<__tag__>> field="title" format="text" />
|
||||
</$element-tag$>
|
||||
\end
|
||||
|
||||
\define tag-pill-body(tag,icon,colour,palette,element-tag,element-attributes,actions)
|
||||
<$macrocall $name="tag-pill-inner" tag=<<__tag__>> icon="""$icon$""" colour="""$colour$""" fallbackTarget={{$palette$##tag-background}} colourA={{$palette$##foreground}} colourB={{$palette$##background}} element-tag="""$element-tag$""" element-attributes="""$element-attributes$""" actions="""$actions$"""/>
|
||||
\whitespace trim
|
||||
<$macrocall $name="tag-pill-inner"
|
||||
tag=<<__tag__>>
|
||||
icon=<<__icon__>>
|
||||
colour=<<__colour__>>
|
||||
fallbackTarget={{$palette$##tag-background}}
|
||||
colourA={{$palette$##foreground}}
|
||||
colourB={{$palette$##background}}
|
||||
element-tag=<<__element-tag__>>
|
||||
element-attributes=<<__element-attributes__>>
|
||||
actions=<<__actions__>>
|
||||
/>
|
||||
\end
|
||||
|
||||
\define tag-pill(tag,element-tag:"span",element-attributes:"",actions:"")
|
||||
\whitespace trim
|
||||
<span class="tc-tag-list-item" data-tag-title=<<__tag__>>>
|
||||
<$let currentTiddler=<<__tag__>>>
|
||||
<$macrocall $name="tag-pill-body" tag=<<__tag__>> icon={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerIconFilter]!is[draft]get[text]] }}} colour={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerColourFilter]!is[draft]get[text]] }}} palette={{$:/palette}} element-tag="""$element-tag$""" element-attributes="""$element-attributes$""" actions="""$actions$"""/>
|
||||
</$let>
|
||||
<$let currentTiddler=<<__tag__>>>
|
||||
<$macrocall $name="tag-pill-body"
|
||||
tag=<<__tag__>>
|
||||
icon={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerIconFilter]!is[draft]get[text]] }}}
|
||||
colour={{{ [<currentTiddler>] :cascade[all[shadows+tiddlers]tag[$:/tags/TiddlerColourFilter]!is[draft]get[text]] }}}
|
||||
palette={{$:/palette}}
|
||||
element-tag=<<__element-tag__>>
|
||||
element-attributes=<<__element-attributes__>>
|
||||
actions=<<__actions__>>/>
|
||||
</$let>
|
||||
</span>
|
||||
\end
|
||||
|
||||
|
||||
@@ -19,9 +19,9 @@ tags: $:/tags/Macro
|
||||
\define toc-body(tag,sort:"",itemClassFilter,exclude,path)
|
||||
\whitespace trim
|
||||
<ol class="tc-toc">
|
||||
<$list filter="""[all[shadows+tiddlers]tag<__tag__>!has[draft.of]$sort$] -[<__tag__>] -[enlist<__exclude__>]""">
|
||||
<$list filter="""[all[shadows+tiddlers]tag<__tag__>!has[draft.of]$sort$] -[<__tag__>] -[subfilter<__exclude__>]""">
|
||||
<$let item=<<currentTiddler>> path={{{ [<__path__>addsuffix[/]addsuffix<__tag__>] }}}>
|
||||
<$set name="excluded" filter="""[enlist<__exclude__>] [<__tag__>]""">
|
||||
<$set name="excluded" filter="[subfilter<__exclude__>] [<__tag__>]">
|
||||
<$set name="toc-item-class" filter=<<__itemClassFilter__>> emptyValue="toc-item-selected" value="toc-item">
|
||||
<li class=<<toc-item-class>>>
|
||||
<$list filter="[all[current]toc-link[no]]" emptyMessage="<$link to={{{ [<currentTiddler>get[target]else<currentTiddler>] }}}><<toc-caption>></$link>">
|
||||
@@ -36,8 +36,8 @@ tags: $:/tags/Macro
|
||||
</ol>
|
||||
\end
|
||||
|
||||
\define toc(tag,sort:"",itemClassFilter:"")
|
||||
<$macrocall $name="toc-body" tag=<<__tag__>> sort=<<__sort__>> itemClassFilter=<<__itemClassFilter__>> />
|
||||
\define toc(tag,sort:"",itemClassFilter:"", exclude)
|
||||
<$macrocall $name="toc-body" tag=<<__tag__>> sort=<<__sort__>> itemClassFilter=<<__itemClassFilter__>> exclude=<<__exclude__>>/>
|
||||
\end
|
||||
|
||||
\define toc-linked-expandable-body(tag,sort:"",itemClassFilter,exclude,path)
|
||||
@@ -75,7 +75,7 @@ tags: $:/tags/Macro
|
||||
<li class=<<toc-item-class>>>
|
||||
<$reveal type="nomatch" stateTitle=<<toc-state>> text="open">
|
||||
<$button setTitle=<<toc-state>> setTo="open" class="tc-btn-invisible tc-popup-keep">
|
||||
<$transclude tiddler=<<toc-closed-icon>> />
|
||||
<$transclude tiddler=<<toc-closed-icon>> />
|
||||
<<toc-caption>>
|
||||
</$button>
|
||||
</$reveal>
|
||||
@@ -100,9 +100,9 @@ tags: $:/tags/Macro
|
||||
\define toc-expandable(tag,sort:"",itemClassFilter:"",exclude,path)
|
||||
\whitespace trim
|
||||
<$let tag=<<__tag__>> sort=<<__sort__>> itemClassFilter=<<__itemClassFilter__>> path={{{ [<__path__>addsuffix[/]addsuffix<__tag__>] }}}>
|
||||
<$set name="excluded" filter="""[enlist<__exclude__>] [<__tag__>]""">
|
||||
<$set name="excluded" filter="[subfilter<__exclude__>] [<__tag__>]">
|
||||
<ol class="tc-toc toc-expandable">
|
||||
<$list filter="""[all[shadows+tiddlers]tag<__tag__>!has[draft.of]$sort$] -[<__tag__>] -[enlist<__exclude__>]""">
|
||||
<$list filter="""[all[shadows+tiddlers]tag<__tag__>!has[draft.of]$sort$] -[<__tag__>] -[subfilter<__exclude__>]""">
|
||||
<$list filter="[all[current]toc-link[no]]" emptyMessage=<<toc-expandable-empty-message>> >
|
||||
<$macrocall $name="toc-unlinked-expandable-body" tag=<<__tag__>> sort=<<__sort__>> itemClassFilter="""itemClassFilter""" exclude=<<excluded>> path=<<path>> />
|
||||
</$list>
|
||||
@@ -174,9 +174,9 @@ tags: $:/tags/Macro
|
||||
\define toc-selective-expandable(tag,sort:"",itemClassFilter,exclude,path)
|
||||
\whitespace trim
|
||||
<$let tag=<<__tag__>> sort=<<__sort__>> itemClassFilter=<<__itemClassFilter__>> path={{{ [<__path__>addsuffix[/]addsuffix<__tag__>] }}}>
|
||||
<$set name="excluded" filter="[enlist<__exclude__>] [<__tag__>]">
|
||||
<$set name="excluded" filter="[subfilter<__exclude__>] [<__tag__>]">
|
||||
<ol class="tc-toc toc-selective-expandable">
|
||||
<$list filter="""[all[shadows+tiddlers]tag<__tag__>!has[draft.of]$sort$] -[<__tag__>] -[enlist<__exclude__>]""">
|
||||
<$list filter="""[all[shadows+tiddlers]tag<__tag__>!has[draft.of]$sort$] -[<__tag__>] -[subfilter<__exclude__>]""">
|
||||
<$list filter="[all[current]toc-link[no]]" variable="ignore" emptyMessage=<<toc-selective-expandable-empty-message>> >
|
||||
<$macrocall $name="toc-unlinked-selective-expandable-body" tag=<<__tag__>> sort=<<__sort__>> itemClassFilter=<<__itemClassFilter__>> exclude=<<excluded>> path=<<path>>/>
|
||||
</$list>
|
||||
@@ -186,13 +186,13 @@ tags: $:/tags/Macro
|
||||
</$let>
|
||||
\end
|
||||
|
||||
\define toc-tabbed-external-nav(tag,sort:"",selectedTiddler:"$:/temp/toc/selectedTiddler",unselectedText,missingText,template:"")
|
||||
\define toc-tabbed-external-nav(tag,sort:"",selectedTiddler:"$:/temp/toc/selectedTiddler",unselectedText,missingText,template:"",exclude)
|
||||
\whitespace trim
|
||||
<$tiddler tiddler={{{ [<__selectedTiddler__>get[text]] }}}>
|
||||
<div class="tc-tabbed-table-of-contents">
|
||||
<$linkcatcher to=<<__selectedTiddler__>>>
|
||||
<div class="tc-table-of-contents">
|
||||
<$macrocall $name="toc-selective-expandable" tag=<<__tag__>> sort=<<__sort__>> itemClassFilter="[all[current]] -[<__selectedTiddler__>get[text]]"/>
|
||||
<$macrocall $name="toc-selective-expandable" tag=<<__tag__>> sort=<<__sort__>> itemClassFilter="[all[current]] -[<__selectedTiddler__>get[text]]" exclude=<<__exclude__>>/>
|
||||
</div>
|
||||
</$linkcatcher>
|
||||
<div class="tc-tabbed-table-of-contents-content">
|
||||
@@ -210,9 +210,9 @@ tags: $:/tags/Macro
|
||||
</$tiddler>
|
||||
\end
|
||||
|
||||
\define toc-tabbed-internal-nav(tag,sort:"",selectedTiddler:"$:/temp/toc/selectedTiddler",unselectedText,missingText,template:"")
|
||||
\define toc-tabbed-internal-nav(tag,sort:"",selectedTiddler:"$:/temp/toc/selectedTiddler",unselectedText,missingText,template:"",exclude)
|
||||
\whitespace trim
|
||||
<$linkcatcher to=<<__selectedTiddler__>>>
|
||||
<$macrocall $name="toc-tabbed-external-nav" tag=<<__tag__>> sort=<<__sort__>> selectedTiddler=<<__selectedTiddler__>> unselectedText=<<__unselectedText__>> missingText=<<__missingText__>> template=<<__template__>>/>
|
||||
<$macrocall $name="toc-tabbed-external-nav" tag=<<__tag__>> sort=<<__sort__>> selectedTiddler=<<__selectedTiddler__>> unselectedText=<<__unselectedText__>> missingText=<<__missingText__>> template=<<__template__>> exclude=<<__exclude__>> />
|
||||
</$linkcatcher>
|
||||
\end
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
title: $:/tags/PageControls
|
||||
list: [[$:/core/ui/Buttons/home]] [[$:/core/ui/Buttons/close-all]] [[$:/core/ui/Buttons/fold-all]] [[$:/core/ui/Buttons/unfold-all]] [[$:/core/ui/Buttons/permaview]] [[$:/core/ui/Buttons/new-tiddler]] [[$:/core/ui/Buttons/new-journal]] [[$:/core/ui/Buttons/new-image]] [[$:/core/ui/Buttons/import]] [[$:/core/ui/Buttons/export-page]] [[$:/core/ui/Buttons/control-panel]] [[$:/core/ui/Buttons/advanced-search]] [[$:/core/ui/Buttons/manager]] [[$:/core/ui/Buttons/tag-manager]] [[$:/core/ui/Buttons/language]] [[$:/core/ui/Buttons/palette]] [[$:/core/ui/Buttons/theme]] [[$:/core/ui/Buttons/layout]] [[$:/core/ui/Buttons/storyview]] [[$:/core/ui/Buttons/encryption]] [[$:/core/ui/Buttons/timestamp]] [[$:/core/ui/Buttons/full-screen]] [[$:/core/ui/Buttons/print]] [[$:/core/ui/Buttons/save-wiki]] [[$:/core/ui/Buttons/refresh]] [[$:/core/ui/Buttons/more-page-actions]]
|
||||
list: [[$:/core/ui/Buttons/home]] [[$:/core/ui/Buttons/close-all]] [[$:/core/ui/Buttons/fold-all]] [[$:/core/ui/Buttons/unfold-all]] [[$:/core/ui/Buttons/permaview]] [[$:/core/ui/Buttons/new-tiddler]] [[$:/core/ui/Buttons/new-journal]] [[$:/core/ui/Buttons/new-image]] [[$:/core/ui/Buttons/import]] [[$:/core/ui/Buttons/export-page]] [[$:/core/ui/Buttons/control-panel]] [[$:/core/ui/Buttons/advanced-search]] [[$:/core/ui/Buttons/manager]] [[$:/core/ui/Buttons/tag-manager]] [[$:/core/ui/Buttons/language]] [[$:/core/ui/Buttons/palette]] [[$:/core/ui/Buttons/theme]] [[$:/core/ui/Buttons/layout]] [[$:/core/ui/Buttons/storyview]] [[$:/core/ui/Buttons/encryption]] [[$:/core/ui/Buttons/timestamp]] [[$:/core/ui/Buttons/full-screen]] [[$:/core/ui/Buttons/print]] [[$:/core/ui/Buttons/save-wiki]] [[$:/core/ui/Buttons/refresh]] [[$:/core/ui/Buttons/network-activity]] [[$:/core/ui/Buttons/more-page-actions]]
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
{
|
||||
"tiddlers": [
|
||||
{
|
||||
"file": "../../../tw5.com/tiddlers/images/New Release Banner.png",
|
||||
"file": "../../../tw5.com/tiddlers/images/New Release Banner.jpg",
|
||||
"fields": {
|
||||
"type": "image/jpg",
|
||||
"type": "image/jpeg",
|
||||
"title": "New Release Banner",
|
||||
"tags": "picture"
|
||||
}
|
||||
|
||||
36
editions/dev/tiddlers/Widget `destroy` method examples.tid
Normal file
36
editions/dev/tiddlers/Widget `destroy` method examples.tid
Normal file
@@ -0,0 +1,36 @@
|
||||
created: 20230601123245916
|
||||
modified: 20230601125015463
|
||||
title: Widget `destroy` method examples
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
!! When using a v-dom library
|
||||
|
||||
Virtual DOM libraries manages its internal state and apply state to DOM periodically, this is so called [["controlled" component|https://react.dev/learn/sharing-state-between-components#controlled-and-uncontrolled-components]]. When Tiddlywiki remove a DOM element controlled by a v-dom library, it may throws error.
|
||||
|
||||
So when creating a plugin providing v-dom library binding, you need to tell v-dom library (for example, React.js) the DOM element is removed. We will use `destroy` method for this.
|
||||
|
||||
```js
|
||||
render() {
|
||||
// ...other render related code
|
||||
if (this.root === undefined || this.containerElement === undefined) {
|
||||
// initialize the v-dom library
|
||||
this.root = ReactDom.createRoot(document.createElement('div'));
|
||||
}
|
||||
}
|
||||
|
||||
destroy() {
|
||||
// end the lifecycle of v-dom library
|
||||
this.root && this.root.unmount();
|
||||
}
|
||||
```
|
||||
|
||||
The `destroy` method will be called by parent widget. If you widget don't have any child widget, you can just write your own tear down logic. If it may have some child widget, don't forget to call original `destroy` method in the `Widget` class to destroy children widgets.
|
||||
|
||||
```js
|
||||
Widget.prototype.destroy();
|
||||
this.root && this.root.unmount();
|
||||
/** if you are using ESNext
|
||||
super.destroy();
|
||||
this.root?.unmount();
|
||||
*/
|
||||
```
|
||||
@@ -1,7 +1,8 @@
|
||||
title: WidgetModules
|
||||
created: 20131101130700000
|
||||
modified: 20230601130631884
|
||||
tags: dev moduletypes
|
||||
created: 201311011307
|
||||
modified: 201311011307
|
||||
title: WidgetModules
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
! Introduction
|
||||
|
||||
@@ -78,4 +79,10 @@ The individual methods defined by the widget object are documented in the source
|
||||
!! Widget `refreshChildren` method
|
||||
!! Widget `findNextSiblingDomNode` method
|
||||
!! Widget `findFirstDomNode` method
|
||||
!! Widget `destroy` method
|
||||
|
||||
<<.from-version "5.3.0">> Gets called when any parent widget is unmounted from the widget tree.
|
||||
|
||||
[[Examples|Widget `destroy` method examples]]
|
||||
|
||||
!! Widget `removeChildDomNodes` method
|
||||
|
||||
40
editions/dev/tiddlers/system/doc-styles.tid
Normal file
40
editions/dev/tiddlers/system/doc-styles.tid
Normal file
@@ -0,0 +1,40 @@
|
||||
created: 20150117152612000
|
||||
modified: 20230325101137075
|
||||
tags: $:/tags/Stylesheet
|
||||
title: $:/editions/tw5.com/doc-styles
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
a.doc-from-version.tc-tiddlylink {
|
||||
display: inline-block;
|
||||
border-radius: 1em;
|
||||
background: <<colour muted-foreground>>;
|
||||
color: <<colour background>>;
|
||||
fill: <<colour background>>;
|
||||
padding: 0 0.4em;
|
||||
font-size: 0.7em;
|
||||
text-transform: uppercase;
|
||||
font-weight: bold;
|
||||
line-height: 1.5;
|
||||
vertical-align: text-bottom;
|
||||
}
|
||||
|
||||
a.doc-deprecated-version.tc-tiddlylink {
|
||||
display: inline-block;
|
||||
border-radius: 1em;
|
||||
background: red;
|
||||
color: <<colour background>>;
|
||||
fill: <<colour background>>;
|
||||
padding: 0 0.4em;
|
||||
font-size: 0.7em;
|
||||
text-transform: uppercase;
|
||||
font-weight: bold;
|
||||
line-height: 1.5;
|
||||
vertical-align: text-bottom;
|
||||
}
|
||||
|
||||
.doc-deprecated-version svg,
|
||||
.doc-from-version svg {
|
||||
width: 1em;
|
||||
height: 1em;
|
||||
vertical-align: text-bottom;
|
||||
}
|
||||
14
editions/dev/tiddlers/system/version-macros.tid
Normal file
14
editions/dev/tiddlers/system/version-macros.tid
Normal file
@@ -0,0 +1,14 @@
|
||||
code-body: yes
|
||||
created: 20161008085627406
|
||||
modified: 20221007122259593
|
||||
tags: $:/tags/Macro
|
||||
title: $:/editions/tw5.com/version-macros
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
\define .from-version(version)
|
||||
<$link to={{{ [<__version__>addprefix[Release ]] }}} class="doc-from-version">{{$:/core/images/warning}} New in: <$text text=<<__version__>>/></$link>
|
||||
\end
|
||||
|
||||
\define .deprecated-since(version, superseded:"TODO-Link")
|
||||
<$link to="Deprecated - What does it mean" class="doc-deprecated-version tc-btn-invisible">{{$:/core/images/warning}} Deprecated since: <$text text=<<__version__>>/></$link> (see <$link to=<<__superseded__>>><$text text=<<__superseded__>>/></$link>)
|
||||
\end
|
||||
56
editions/prerelease/tiddlers/Release 5.3.1.tid
Normal file
56
editions/prerelease/tiddlers/Release 5.3.1.tid
Normal file
@@ -0,0 +1,56 @@
|
||||
caption: 5.3.1
|
||||
created: 20230701133439630
|
||||
modified: 20230701133439630
|
||||
tags: ReleaseNotes
|
||||
title: Release 5.3.1
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
//[[See GitHub for detailed change history of this release|https://github.com/Jermolene/TiddlyWiki5/compare/v5.3.0...master]]//
|
||||
|
||||
! Overview of v5.3.1
|
||||
|
||||
|
||||
! Plugin Improvements
|
||||
|
||||
*
|
||||
|
||||
! Translation improvement
|
||||
|
||||
Improvements to the following translations:
|
||||
|
||||
*
|
||||
|
||||
! Usability Improvements
|
||||
|
||||
*
|
||||
|
||||
! Widget Improvements
|
||||
|
||||
*
|
||||
|
||||
! Filter improvements
|
||||
|
||||
*
|
||||
|
||||
! Hackability Improvements
|
||||
|
||||
*
|
||||
|
||||
! Bug Fixes
|
||||
|
||||
*
|
||||
|
||||
! Node.js Improvements
|
||||
|
||||
*
|
||||
|
||||
! Performance Improvements
|
||||
|
||||
*
|
||||
|
||||
! Acknowledgements
|
||||
|
||||
[[@Jermolene|https://github.com/Jermolene]] would like to thank the contributors to this release who have generously given their time to help improve TiddlyWiki:
|
||||
|
||||
<<.contributors """
|
||||
""">>
|
||||
@@ -1,6 +1,6 @@
|
||||
title: $:/config/OfficialPluginLibrary
|
||||
tags: $:/tags/PluginLibrary
|
||||
url: https://tiddlywiki.com/prerelease/library/v5.2.8/index.html
|
||||
url: https://tiddlywiki.com/prerelease/library/v5.3.0/index.html
|
||||
caption: {{$:/language/OfficialPluginLibrary}} (Prerelease)
|
||||
|
||||
The prerelease version of the official ~TiddlyWiki plugin library at tiddlywiki.com. Plugins, themes and language packs are maintained by the core team.
|
||||
|
||||
40
editions/test/tiddlers/tests/data/filters/substitute.tid
Normal file
40
editions/test/tiddlers/tests/data/filters/substitute.tid
Normal file
@@ -0,0 +1,40 @@
|
||||
title: Filters/substitute
|
||||
description: Test substitute operator
|
||||
type: text/vnd.tiddlywiki-multiple
|
||||
tags: [[$:/tags/wiki-test-spec]]
|
||||
|
||||
title: substitute filter data 1
|
||||
tags: Hello There [[Welcome to TiddlyWiki]] GettingStarted
|
||||
|
||||
TiddlyWiki
|
||||
+
|
||||
title: substitute filter data 2
|
||||
|
||||
The output of the filter `[[substitute filter data 1]tags[]]` is ${[[substitute filter data 1]tags[]]}$.
|
||||
+
|
||||
title: substitute filter data 3
|
||||
|
||||
Welcome to $(projectname)$ $1$ $2$ $3$. Tiddlers starting with `substitute`: ${[prefix[substitute]format:titlelist[]join[ ]]}$.
|
||||
+
|
||||
title: Output
|
||||
|
||||
\whitespace trim
|
||||
<$let projectname="TiddlyWiki">
|
||||
(<$text text={{{ [[]substitute[]] }}}/>)
|
||||
(<$text text={{{ [[Hello There, welcome to $TiddlyWiki$]substitute[]] }}}/>)
|
||||
(<$text text={{{ [[Welcome to $(projectname)$]substitute[]] }}}/>)
|
||||
(<$text text={{{ [[Welcome to $(projectname)$ $1$]substitute[today]] }}}/>)
|
||||
(<$text text={{{ [[This is not a valid embedded filter ${ hello )$]substitute[]] }}}/>)
|
||||
(<$text text={{{ [{substitute filter data 2}substitute[]] }}}/>)
|
||||
(<$text text={{{ [{substitute filter data 3}substitute[every],[day]] }}}/>)
|
||||
</$let>
|
||||
+
|
||||
title: ExpectedResult
|
||||
|
||||
<p>()
|
||||
(Hello There, welcome to $TiddlyWiki$)
|
||||
(Welcome to TiddlyWiki)
|
||||
(Welcome to TiddlyWiki today)
|
||||
(This is not a valid embedded filter ${ hello )$)
|
||||
(The output of the filter `[[substitute filter data 1]tags[]]` is Hello.)
|
||||
(Welcome to TiddlyWiki every day $3$. Tiddlers starting with `substitute`: [[substitute filter data 1]] [[substitute filter data 2]] [[substitute filter data 3]].)</p>
|
||||
@@ -0,0 +1,19 @@
|
||||
title: Widgets/SubstitutedAttributes
|
||||
description: Attributes specified as string that should have substitution performed.
|
||||
type: text/vnd.tiddlywiki-multiple
|
||||
tags: [[$:/tags/wiki-test-spec]]
|
||||
|
||||
title: Output
|
||||
|
||||
\whitespace trim
|
||||
<$let project="TiddlyWiki" disabled="true">
|
||||
<div class=`$(project)$
|
||||
${ [[Hello]addsuffix[There]] }$` attrib=`myvalue` otherattrib=`$(1)$` blankattrib=`` quoted="here" disabled=```$(disabled)$```>
|
||||
</div>
|
||||
</$let>
|
||||
|
||||
+
|
||||
title: ExpectedResult
|
||||
|
||||
<p><div attrib="myvalue" blankattrib="" class="TiddlyWiki
|
||||
HelloThere" disabled="true" otherattrib="" quoted="here"></div></p>
|
||||
@@ -1066,7 +1066,11 @@ Tests the filtering mechanism.
|
||||
});
|
||||
|
||||
it("should handle the deserializers operator", function() {
|
||||
expect(wiki.filterTiddlers("[deserializers[]]").join(",")).toBe("application/javascript,application/json,application/x-tiddler,application/x-tiddler-html-div,application/x-tiddlers,text/css,text/html,text/plain");
|
||||
var expectedDeserializers = ["application/javascript","application/json","application/x-tiddler","application/x-tiddler-html-div","application/x-tiddlers","text/css","text/html","text/plain"];
|
||||
if($tw.browser) {
|
||||
expectedDeserializers.unshift("(DOM)");
|
||||
}
|
||||
expect(wiki.filterTiddlers("[deserializers[]]").join(",")).toBe(expectedDeserializers.join(","));
|
||||
});
|
||||
|
||||
it("should handle the charcode operator", function() {
|
||||
|
||||
@@ -161,6 +161,16 @@ describe("HTML tag new parser tests", function() {
|
||||
expect($tw.utils.parseAttribute(" attrib1>",0)).toEqual(
|
||||
{ type : 'string', value : 'true', start : 0, name : 'attrib1', end : 8 }
|
||||
);
|
||||
expect($tw.utils.parseAttribute("p=`blah` ",1)).toEqual(null);
|
||||
expect($tw.utils.parseAttribute("p=`blah` ",0)).toEqual(
|
||||
{ start: 0, name: 'p', type: 'substituted', rawValue: 'blah', end: 8 }
|
||||
);
|
||||
expect($tw.utils.parseAttribute("p=```blah``` ",0)).toEqual(
|
||||
{ start: 0, name: 'p', type: 'substituted', rawValue: 'blah', end: 12 }
|
||||
);
|
||||
expect($tw.utils.parseAttribute("p=`Hello \"There\"`",0)).toEqual(
|
||||
{ start: 0, name: 'p', type: 'substituted', rawValue: 'Hello "There"', end: 17 }
|
||||
);
|
||||
});
|
||||
|
||||
it("should parse HTML tags", function() {
|
||||
|
||||
@@ -434,6 +434,15 @@ describe("'reduce' and 'intersection' filter prefix tests", function() {
|
||||
expect(wiki.filterTiddlers("[tag[shopping]] :map[get[title]addprefix[-]addprefix<length>addprefix[of]addprefix<index>]").join(",")).toBe("0of4-Brownies,1of4-Chick Peas,2of4-Milk,3of4-Rice Pudding");
|
||||
});
|
||||
|
||||
it("should handle the :then prefix", function() {
|
||||
expect(wiki.filterTiddlers("[[one]] :then[[two]]").join(",")).toBe("two");
|
||||
expect(wiki.filterTiddlers("[[one]] :then[tag[shopping]]").join(",")).toBe("Brownies,Chick Peas,Milk,Rice Pudding");
|
||||
expect(wiki.filterTiddlers("[[one]] [[two]] [[three]] :then[[four]]").join(",")).toBe("four");
|
||||
expect(wiki.filterTiddlers("[[one]] :then[tag[nonexistent]]").join(",")).toBe("one");
|
||||
expect(wiki.filterTiddlers(":then[[two]]").length).toBe(0);
|
||||
expect(wiki.filterTiddlers("[[notatiddler]is[tiddler]] :then[[two]]").length).toBe(0);
|
||||
});
|
||||
|
||||
it("should handle macro parameters for filter run prefixes",function() {
|
||||
var widget = require("$:/core/modules/widgets/widget.js");
|
||||
var rootWidget = new widget.widget({ type:"widget", children:[ {type:"widget", children:[]} ] },
|
||||
|
||||
@@ -9,9 +9,13 @@ tags: Concepts
|
||||
<$button actions=<<actions>>>$text$</$button>
|
||||
\end
|
||||
|
||||
ShadowTiddlers are tiddlers that are loaded from within [[Plugins]]. Unlike ordinary tiddlers, they don't appear in most lists.
|
||||
ShadowTiddlers are tiddlers that are loaded from [[Plugins]] at the wiki startup. Unlike ordinary tiddlers, they don't appear in most lists.
|
||||
|
||||
ShadowTiddlers can be overridden with an ordinary tiddler of the same name. If that tiddler is subsequently deleted then the original shadow tiddler is automatically restored.
|
||||
!! Overriding Shadow Tiddlers to modify plugins
|
||||
|
||||
A ShadowTiddler can be overridden with an ordinary tiddler of the same name. This leaves the shadow tiddler intact but the plugin will use the overriding tiddler in its place, effectively allowing users to modify the behaviour of plugins.
|
||||
|
||||
Users are cautioned against overriding shadow tiddlers because if the shadow tiddler is changed in a plugin update, the overriding tiddler may no longer perform as intended. To remedy this, the overriding tiddler may be modified or deleted. If the overriding tiddler is deleted, then the plugin falls back to using the original shadow tiddler.
|
||||
|
||||
!! Overridden Shadow Tiddlers
|
||||
|
||||
|
||||
20
editions/tw5.com/tiddlers/features/Deserializers.tid
Normal file
20
editions/tw5.com/tiddlers/features/Deserializers.tid
Normal file
@@ -0,0 +1,20 @@
|
||||
created: 20230627093650105
|
||||
modified: 20230627094356394
|
||||
tags: Features
|
||||
title: Deserializers
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
Deserializer [[modules|Modules]] parse text in various formats into their JSON representation as tiddlers. The deserializer modules available in a wiki can be seen using the [[deserializers operator|deserializers Operator]] and can be used with the [[deserialize Operator]].
|
||||
|
||||
The TiddlyWiki core provides the following deserializers:
|
||||
|
||||
|!Deserializer |!Description |
|
||||
|(DOM)|Extracts tiddlers from a DOM node, should not be used with the <<.op deserialize[]>> operator |
|
||||
|application/javascript|Parses a JavaScript module as a tiddler extracting fields from the header comment|
|
||||
|application/json|Parses [[JSON|JSON in TiddlyWiki]] into tiddlers|
|
||||
|application/x-tiddler|Parses the [[.tid file format|TiddlerFiles]] as a tiddler|
|
||||
|application/x-tiddler-html-div|Parses the [[<DIV>.tiddler file format|TiddlerFiles]] as a tiddler|
|
||||
|application/x-tiddlers|Parses the [[MultiTiddlerFile format|MultiTiddlerFiles]] as tiddlers|
|
||||
|text/css|Parses CSS as a tiddler extracting fields from the header comment|
|
||||
|text/html|Parses an HTML file into tiddlers. Supports ~TiddlyWiki Classic HTML files, ~TiddlyWiki5 HTML files and ordinary HTML files|
|
||||
|text/plain|Parses plain text as a tiddler|
|
||||
@@ -1,12 +1,12 @@
|
||||
created: 20190802113703788
|
||||
modified: 20190802132727925
|
||||
modified: 20230501175143648
|
||||
tags: Filters
|
||||
title: Conditional Operators
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<<.from-version "5.1.20">>The conditional filter operators allow ''if-then-else'' logic to be expressed within filters.
|
||||
<<.from-version "5.1.20">>The conditional filter operators allow for ''if-then-else'' logic to be expressed within filters.
|
||||
|
||||
The foundation is the convention that an empty list can be used to represent the boolean value ''false'' and a list with at one (or more) entries to represent ''true''.
|
||||
The foundation is the convention that an empty list can be used to represent the Boolean value <<.value false>> and a list with at one (or more) entries to represent <<.value true>>.
|
||||
|
||||
The conditional operators are:
|
||||
|
||||
@@ -19,10 +19,12 @@ The conditional operators are:
|
||||
|
||||
These operators can be combined. For example:
|
||||
|
||||
<<.inline-operator-example "[[New Tiddler]is[missing]then[I am missing]else[No I am not missing]]">>
|
||||
<<.operator-example 1 "[[New Tiddler]is[missing]then[I am missing]else[No I am not missing]]">>
|
||||
|
||||
The [[else Operator]] can be used to apply a defaults for missing values. In this example, we take advantage of the fact that the [[get Operator]] returns an empty list if the field or tiddler does not exist:
|
||||
The <<.olink else>> operator can be used to apply a defaults for missing values. In this example, we take advantage of the fact that the <<.olink get>> operator returns an empty list if the field or tiddler does not exist:
|
||||
|
||||
<<.inline-operator-example "[[HelloThere]get[custom-field]else[default-value]]">>
|
||||
<<.operator-example 2 "[[HelloThere]get[custom-field]else[default-value]]">>
|
||||
|
||||
<<list-links "[tag[Conditional Operators]]">>
|
||||
! Filter Run Prefixes
|
||||
|
||||
The [[:then|:then Filter Run Prefix]] and [[:else|:else Filter Run Prefix]] filter run prefixes serve a similar purpose as the conditional operators. Refer to their documentation for more information.
|
||||
@@ -1,7 +1,7 @@
|
||||
caption: deserialize
|
||||
created: 20230601195749377
|
||||
from-version: 5.3.0
|
||||
modified: 20230602105513132
|
||||
modified: 20230627094109762
|
||||
op-input: a selection of strings
|
||||
op-output: JSON representations of tiddlers extracted from input titles.
|
||||
op-parameter: the deserializer module to be used to extract tiddlers from the input
|
||||
@@ -10,17 +10,8 @@ tags: [[Filter Operators]] [[Special Operators]]
|
||||
title: deserialize Operator
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<<.tip "Deserializer modules parse text in various formats into their JSON representation as tiddlers. You can see the deserializers available in a wiki using the [[deserializers operator|deserializers Operator]].">>
|
||||
{{Deserializers}}
|
||||
|
||||
|
||||
|!Deserializer |!Description |
|
||||
|(DOM)|Extracts tiddlers from a DOM node, should not be used with the <<.op deserialize[]>> operator |
|
||||
|application/javascript|Parses a JavaScript module as a tiddler extracting fields from the header comment|
|
||||
|application/json|Parses [[JSON|JSON in TiddlyWiki]] into tiddlers|
|
||||
|application/x-tiddler|Parses the [[.tid file format|TiddlerFiles]] as a tiddler|
|
||||
|application/x-tiddler-html-div|Parses the [[<DIV>.tiddler file format|TiddlerFiles]] as a tiddler|
|
||||
|application/x-tiddlers|Parses the [[MultiTiddlerFile format|MultiTiddlerFiles]] as tiddlers|
|
||||
|text/css|Parses CSS as a tiddler extracting fields from the header comment|
|
||||
|text/html|Parses an HTML file into tiddlers. Supports ~TiddlyWiki Classic HTML files, ~TiddlyWiki5 HTML files and ordinary HTML files|
|
||||
|text/plain|Parses plain text as a tiddler|
|
||||
|
||||
<<.operator-examples "deserialize">>
|
||||
@@ -1,14 +1,14 @@
|
||||
caption: deserializers
|
||||
created: 20210506115203172
|
||||
from-version: 5.2.0
|
||||
modified: 20210506130322593
|
||||
modified: 20230627094238610
|
||||
op-input: ignored
|
||||
op-output: the title of each available deserializer
|
||||
op-parameter: none
|
||||
tags: [[Filter Operators]] [[Special Operators]] [[Selection Constructors]]
|
||||
tags: [[Filter Operators]] [[Special Operators]] [[Selection Constructors]]
|
||||
title: deserializers Operator
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<<.tip "You can specify a specific deserializer for a DropzoneWidget to use">>
|
||||
<<.tip "You can specify a specific [[deserializer|Deserializers]] for a DropzoneWidget to use">>
|
||||
|
||||
<<.operator-examples "deserializers">>
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
created: 20230614225302905
|
||||
modified: 20230614233448662
|
||||
tags: [[Operator Examples]] [[substitute Operator]]
|
||||
title: substitute Operator (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
\define time() morning
|
||||
\define field() modified
|
||||
\procedure sentence() This tiddler was last $(field)$ on ${[{!!modified}format:date[DDth MMM YYYY]]}$
|
||||
\define name() Bugs Bunny
|
||||
\define address() Rabbit Hole Hill
|
||||
|
||||
!Substitute <<.op substitute[]>> operator parameters
|
||||
<<.operator-example 1 "[[Hi, I'm $1$ and I live in $2$]substitute[Bugs Bunny],[Rabbit Hole Hill]]">>
|
||||
|
||||
!Substitute variables
|
||||
This example uses the following variables:
|
||||
|
||||
* name: <$codeblock code=<<name>>/>
|
||||
* address: <$codeblock code=<<address>>/>
|
||||
|
||||
<<.operator-example 2 "[[Hi, I'm $(name)$ and I live in $(address)$]substitute[]]">>
|
||||
|
||||
!Substitute variables and operator parameters
|
||||
This example uses the following variable:
|
||||
|
||||
* time: <$codeblock code=<<time>>/>
|
||||
|
||||
<<.operator-example 3 "[[Something in the $(time)$ at $2$ about $1$ ]substitute[Maths],[the Library]]">>
|
||||
|
||||
!Substitute a filter expression and a variable
|
||||
This example uses the following variables:
|
||||
|
||||
* field: <$codeblock code=<<field>>/>
|
||||
* sentence: <$codeblock code=<<sentence>>/>
|
||||
|
||||
<<.operator-example 4 "[<sentence>substitute[]]">>
|
||||
27
editions/tw5.com/tiddlers/filters/substitute Operator.tid
Normal file
27
editions/tw5.com/tiddlers/filters/substitute Operator.tid
Normal file
@@ -0,0 +1,27 @@
|
||||
caption: substitute
|
||||
created: 20230614223551834
|
||||
modified: 20230615173049692
|
||||
op-input: a [[selection of titles|Title Selection]]
|
||||
op-output: the input titles with placeholders for filter expressions, parameter and variables replaced with their corresponding values
|
||||
op-parameter: the <<.op substitute>> operator optionally accepts a variable number of parameters, see below for details
|
||||
op-purpose: returns each item in the list, replacing within each title placeholders for filters, parameters and variables with their corresponding values
|
||||
tags: [[Filter Operators]] [[String Operators]]
|
||||
title: substitute Operator
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<<.from-version "5.3.0">>
|
||||
|
||||
The <<.op substitute>> operator replaces any placeholders in the input titles in the following order:
|
||||
|
||||
# filter expressions
|
||||
# parameters to the <<.op substitute>> operator
|
||||
# variables
|
||||
|
||||
|placeholder syntax|description|h
|
||||
|`$n$`|Text substitution of a parameter provided to the operator, where n is the position of the parameter starting with 1 for the first parameter. Unmatched placeholders pass through unchanged.|
|
||||
|`$(varname)$`|Text substitution of a variable. Undefined variables are replaced with an empty string.|
|
||||
|`${ filter expression }$`|Text substitution with the first result of evaluating the filter expression. |
|
||||
|
||||
<<.tip """Placeholders that contain square bracket characters are not valid filter syntax when used directly in a filter expression. However they can be provided as input to the <$macrocall $name=".op" _="substitute"/> operator as text references or variables""">>
|
||||
|
||||
<<.operator-examples "substitute">>
|
||||
@@ -0,0 +1,49 @@
|
||||
created: 20230617183745774
|
||||
modified: 20230617183745774
|
||||
tags: [[Then Filter Run Prefix]]
|
||||
title: Then Filter Run Prefix (Examples)
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
|
||||
!! Conditional Execution
|
||||
|
||||
The <<.op :then>> filter run prefix can be used to avoid the need for nested [[ListWidget]]s or [[Macro Definitions in WikiText]].
|
||||
|
||||
<$macrocall $name='wikitext-example-without-html'
|
||||
src="""<$edit-text field="search" placeholder="Search title"/>
|
||||
|
||||
<$let searchTerm={{!!search}}>
|
||||
<$list filter="[<searchTerm>minlength[3]] :then[!is[system]search:title<searchTerm>]" template="$:/core/ui/ListItemTemplate"/>
|
||||
</$let>"""/>
|
||||
|
||||
|
||||
!! Conditional (Sub)Filters
|
||||
|
||||
The <<.op :then>> filter run prefix can be combined with the <<.op :else>> prefix to create conditional filters. In this example, the fields used in <<.var searchSubfilter>> for searching depend on the value of [[$:/temp/searchFields]] and the sort order used by <<.var sortSubfilter>> depends on the value of [[$:/temp/searchSort]]. Checkboxes are used to set the values of these tiddlers.
|
||||
|
||||
<<.tip "Note that each filter run of the subfilter receives the input of the <<.olink subfilter>> operator as input">>
|
||||
|
||||
Since the <<.olink then>> and <<.olink else>> operators cannot call subfilters or perform additional filter steps, they cannot be used for such applications.
|
||||
|
||||
<$macrocall $name='wikitext-example-without-html'
|
||||
src="""<$checkbox tiddler="$:/temp/searchSort"
|
||||
field="text"
|
||||
checked="chrono" unchecked="alpha" default="alpha">
|
||||
Sort chronologically (newest first)
|
||||
</$checkbox><br/>
|
||||
<$checkbox tiddler="$:/temp/searchFields"
|
||||
field="text"
|
||||
checked="title" unchecked="default" default="title">
|
||||
Search <<.field title>> only
|
||||
</$checkbox><p/>
|
||||
<$let searchSubfilter="[{$:/temp/searchFields}match[default]] :then[search[prefix]] :else[search:title[prefix]]"
|
||||
sortSubfilter="[{$:/temp/searchSort}match[chrono]] :then[!nsort[modified]] :else[sort[title]]"
|
||||
limit=10 >
|
||||
<$list filter="[all[tiddlers]!is[system]subfilter<searchSubfilter>subfilter<sortSubfilter>first<limit>]">
|
||||
<$link/> (<$text text={{{ [{!!modified}format:date[YYYY-0MM-0DD]] }}} />)<br/>
|
||||
</$list>
|
||||
<$list filter="[all[tiddlers]!is[system]subfilter<searchSubfilter>rest<limit>count[]]">
|
||||
... and <<currentTiddler>> more.
|
||||
</$list>
|
||||
</$let>"""/>
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
created: 20210618133745003
|
||||
from-version: 5.3.0
|
||||
modified: 20230506172920710
|
||||
rp-input: <<.olink all>> tiddler titles
|
||||
rp-output: the output of this filter run replaces the output of previous runs unless it is an empty list (see below)
|
||||
rp-purpose: replace any input to this filter run with its output, only evaluating the run when there is any input
|
||||
search:
|
||||
tags: [[Filter Run Prefix]] [[Filter Syntax]]
|
||||
title: Then Filter Run Prefix
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
\define .op-row()
|
||||
<$macrocall $name=".if"
|
||||
cond="""$(op-body)$"""
|
||||
then="""<tr><th align="left">$(op-head)$</th><td><<.op-place>>$(op-body)$</td></tr>"""
|
||||
else=""/>
|
||||
\end
|
||||
|
||||
<$list filter="[all[current]has[from-version]]" variable="listItem">
|
||||
<$macrocall $name=".from-version" version={{!!from-version}}/>
|
||||
</$list>
|
||||
<$let op-head="" op-body="" op-name="">
|
||||
<table class="doc-table">
|
||||
<!-- purpose -->
|
||||
<$let op-head="purpose" op-body={{!!rp-purpose}}>
|
||||
<<.op-row>>
|
||||
</$let>
|
||||
<!-- input -->
|
||||
<$let op-head="[[input|Filter Expression]]" op-body={{!!rp-input}}>
|
||||
<<.op-row>>
|
||||
</$let>
|
||||
<!-- suffix -->
|
||||
<$let op-head="suffix" op-body={{!!rp-suffix}} op-name={{!!rp-suffix-name}}>
|
||||
<<.op-row>>
|
||||
</$let>
|
||||
<!-- output -->
|
||||
<$let op-head="output" op-body={{!!rp-output}}>
|
||||
<<.op-row>>
|
||||
</$let>
|
||||
</table>
|
||||
</$let>
|
||||
|
||||
<$railroad text="""
|
||||
\start none
|
||||
\end none
|
||||
":then"
|
||||
[[run|"Filter Run"]]
|
||||
"""/>
|
||||
|
||||
!Introduction
|
||||
|
||||
The <<.op :then>> filter run prefix is used to replace the result of all previous filter runs with its output.
|
||||
|
||||
If the result of all previous runs is an empty list, the <<.op :then>> prefixed filter run is not evaluated.
|
||||
|
||||
If the output of a <<.op :then>> prefixed filter run is itself an empty list, the result of all previous filter runs is passed through unaltered.
|
||||
|
||||
<<.tip "Note that a list with a single empty string item is not an empty list.">>
|
||||
|
||||
|
||||
!! <<.op :then>> run prefix versus the <<.olink then>> operator
|
||||
|
||||
The major difference between the <<.op then>> operator and a <<.op :then>> prefixed filter run is that the operator will replace //each item// of the input [[Title List]] with its parameter while <<.op :then>> will replace the //whole input list// with the result of its run.
|
||||
|
||||
|doc-op-comparison tc-center|k
|
||||
| !<<.op :then>> Filter Run Prefix | !<<.op then>> Operator |
|
||||
|^<<.operator-example m1-1 "[tag[WikiText]] :then[[true]]">>|^<<.operator-example m1-2 "[tag[WikiText]then[true]]">><p>To make them equivalent, additional filter steps may be added:</p> <<.operator-example m1-3 "[tag[WikiText]count[]compare:number:gt[0]then[true]]">>|
|
||||
|
||||
|
||||
! [[Examples|Then Filter Run Prefix (Examples)]]
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
caption: then
|
||||
created: 20190802112756430
|
||||
modified: 20190802113849579
|
||||
modified: 20230501174334627
|
||||
op-input: a [[selection of titles|Title Selection]]
|
||||
op-output: the input titles with each one replaced by the string <<.place T>>
|
||||
op-parameter: a string
|
||||
@@ -12,4 +12,6 @@ type: text/vnd.tiddlywiki
|
||||
|
||||
<<.from-version "5.1.20">> See [[Conditional Operators]] for an overview.
|
||||
|
||||
<<.tip "The [[Then Filter Run Prefix]] has a similar purpose to the <<.op then>> operator. See its documentation for a comparison of usage.">>
|
||||
|
||||
<<.operator-examples "then">>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
created: 20130822170200000
|
||||
list: [[A Gentle Guide to TiddlyWiki]] [[Discover TiddlyWiki]] [[Some of the things you can do with TiddlyWiki]] [[Ten reasons to switch to TiddlyWiki]] Examples [[What happened to the original TiddlyWiki?]]
|
||||
modified: 20230326083239710
|
||||
modified: 20230701123439630
|
||||
tags: TableOfContents
|
||||
title: HelloThere
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
created: 20160424150551727
|
||||
modified: 20211230153027382
|
||||
modified: 20230615114519672
|
||||
tags: Learning
|
||||
title: Concatenating text and variables using macro substitution
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<<.from-version "5.3.0">> It is recommended to use [[substituted attributes|Substituted Attribute Values]] or the [[substitute filter operator|substitute Operator]] to concatenate text and variables.
|
||||
|
||||
It's a frequent use case in ~TiddlyWiki that you will want to put the results of variables together with various bits of strings of text. This process in some programming languages is often referred to as "concatenating" text.
|
||||
|
||||
|
||||
@@ -5,13 +5,13 @@ title: Using Excise
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
! Excise text
|
||||
From the EditorToolbar you can export selected text to a new tiddler and insert a [[link|Linking in WikiText]] [[Transclusion]] or [[macro|Macros]] in its place. Click ''Excise text'' (<<.icon $:/core/images/excise>>), input name of the new tiddler, and choose excise method.
|
||||
From the EditorToolbar you can export selected text to a new tiddler and insert a [[link|Linking in WikiText]], [[Transclusion]] or [[macro|Macros]] in its place. Click ''Excise text'' (<<.icon $:/core/images/excise>>), input name of the new tiddler, and choose excise method.
|
||||
|
||||
!! How to excise text
|
||||
# Highlight the relevant piece of text
|
||||
# Click ''Excise text'' (<<.icon $:/core/images/excise>>)
|
||||
# Give the new tiddler a title.
|
||||
# Chosse if the new tiddler will be tagged with the title of the current tiddler (see note below).
|
||||
# Choose if the new tiddler will be tagged with the title of the current tiddler (see note below).
|
||||
# Choose replacing method: [[link|Linking in WikiText]], [[transclusion|Transclusion]], or [[macro|Macros]].
|
||||
# Click the ''{{$:/language/Buttons/Excise/Caption/Excise}}'' button
|
||||
|
||||
|
||||
BIN
editions/tw5.com/tiddlers/images/New Release Banner.jpg
Normal file
BIN
editions/tw5.com/tiddlers/images/New Release Banner.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 42 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 49 KiB |
@@ -1,5 +1,5 @@
|
||||
created: 20140919155729620
|
||||
modified: 20220819093733569
|
||||
modified: 20230427125500432
|
||||
tags: Macros [[Core Macros]]
|
||||
title: Table-of-Contents Macros
|
||||
type: text/vnd.tiddlywiki
|
||||
@@ -53,15 +53,21 @@ These two parameters are combined into a single [[filter expression|Filter Expre
|
||||
|
||||
<<.var toc-tabbed-internal-nav>> and <<.var toc-tabbed-external-nav>> take additional parameters:
|
||||
|
||||
;selectedTiddler
|
||||
; selectedTiddler
|
||||
: The title of the [[state tiddler|StateMechanism]] for noting the currently selected tiddler, defaulting to `$:/temp/toc/selectedTiddler`. It is recommended that this be a [[system tiddler|SystemTiddlers]]
|
||||
;unselectedText
|
||||
|
||||
; unselectedText
|
||||
: The text to display when no tiddler is selected in the tree
|
||||
;missingText
|
||||
|
||||
; missingText
|
||||
: The text to display if the selected tiddler doesn't exist
|
||||
;template
|
||||
|
||||
; template
|
||||
: Optionally, the title of a tiddler to use as a [[template|TemplateTiddlers]] for transcluding the selected tiddler into the right-hand panel
|
||||
|
||||
; exclude <<.from-version "5.3.0">>
|
||||
: This optional parameter can be used to exclude tiddlers from the TOC list. It allows a [[Title List]] or a <<.olink subfilter>>. Eg: `exclude:"HelloThere [[Title with spaces]]"` or `exclude:"[has[excludeTOC]]"`. Where the former will exclude two tiddlers and the later would exclude every tiddler that has a field <<.field excludeTOC>> independent of its value.<br>''Be aware'' that eg: `[prefix[H]]` is a shortcut for `[all[tiddlers]prefix[H]]`, which can have a performance impact, if used carelessly. So use $:/AdvancedSearch -> ''Filters'' tab to test the <<.param exclude>> parameter
|
||||
|
||||
!! Custom Icons
|
||||
|
||||
<<.from-version "5.2.4">>
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
caption: tm-http-cancel-all-requests
|
||||
created: 20230429161453032
|
||||
modified: 20230429161453032
|
||||
tags: Messages
|
||||
title: WidgetMessage: tm-http-cancel-all-requests
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
The ''tm-http-cancel-all-requests'' message is used to cancel all outstanding HTTP requests initiated with [[WidgetMessage: tm-http-request]].
|
||||
|
||||
Note that the state tiddler $:/state/http-requests contains a number representing the number of outstanding HTTP requests in progress.
|
||||
|
||||
It does not take any parameters.
|
||||
@@ -0,0 +1,115 @@
|
||||
title: WidgetMessage: tm-http-request Example - Zotero
|
||||
tags: $:/tags/Macro
|
||||
|
||||
\procedure select-zotero-group()
|
||||
Specify the Zotero group ID to import
|
||||
<$edit-text tiddler="$:/config/zotero-group" tag="input"/> or
|
||||
<$select tiddler="$:/config/zotero-group">
|
||||
<option value="4813312">com216</option>
|
||||
<option value="4913310">pos252</option>
|
||||
<option value="4747244">idt575</option>
|
||||
</$select>
|
||||
\end
|
||||
|
||||
\procedure zotero-save-item(item)
|
||||
<$action-createtiddler
|
||||
$basetitle={{{ =[[_zotero_import ]] =[<item>jsonget[key]] =[[ ]] =[<item>jsonget[title]] +[join[]] }}}
|
||||
text={{{ [<item>jsonget[title]] }}}
|
||||
tags="$:/tags/ZoteroImport"
|
||||
>
|
||||
<$action-setmultiplefields $tiddler=<<createTiddler-title>> $fields="[<item>jsonindexes[]addprefix[zotero-]]" $values="[<item>jsonindexes[]] :map[<item>jsonget<currentTiddler>else[.XXXXX.]]"/>
|
||||
<$list filter="[<item>jsonindexes[creators]]" variable="creatorIndex">
|
||||
<$action-setmultiplefields $tiddler=<<createTiddler-title>> $fields="[<item>jsonget[creators],<creatorIndex>,[creatorType]addprefix[zotero-]]" $values="[<item>jsonget[creators],<creatorIndex>,[lastName]] [<item>jsonget[creators],<creatorIndex>,[firstName]] +[join[, ]] :else[<item>jsonget[creators],<creatorIndex>,[name]] "/>
|
||||
</$list>
|
||||
</$action-createtiddler>
|
||||
\end zotero-save-item
|
||||
|
||||
\procedure zotero-save-items(data)
|
||||
<$list filter="[<data>jsonindexes[]] :map[<data>jsonextract<currentTiddler>,[data]]" variable="item">
|
||||
<$macrocall $name="zotero-save-item" item=<<item>>/>
|
||||
</$list>
|
||||
\end zotero-save-items
|
||||
|
||||
\procedure zotero-get-items(start:"0",limit:"25")
|
||||
|
||||
\procedure completion()
|
||||
\import [[$:/core/ui/PageMacros]] [all[shadows+tiddlers]tag[$:/tags/Macro]!has[draft.of]]
|
||||
<$action-log msg="In completion"/>
|
||||
<$action-log/>
|
||||
<!-- Success -->
|
||||
<$list filter="[<status>compare:number:gteq[200]compare:number:lteq[299]]" variable="ignore">
|
||||
<!-- Import these items -->
|
||||
<$macrocall $name="zotero-save-items" data=<<data>>/>
|
||||
<!-- Check if there are any more items to download -->
|
||||
<$list filter="[<headers>jsonget[total-results]subtract<start>subtract<limit>compare:number:gt[0]]" variable="ignore">
|
||||
<$macrocall $name="zotero-get-items" start={{{ [<start>add<limit>] }}} limit=<<limit>>/>
|
||||
</$list>
|
||||
</$list>
|
||||
\end completion
|
||||
|
||||
\procedure progress()
|
||||
\import [[$:/core/ui/PageMacros]] [all[shadows+tiddlers]tag[$:/tags/Macro]!has[draft.of]]
|
||||
<$action-log message="In progress-actions"/>
|
||||
\end progress
|
||||
|
||||
\procedure request-url()
|
||||
\rules only transcludeinline transcludeblock filteredtranscludeinline filteredtranscludeblock
|
||||
https://api.zotero.org/groups/{{$:/config/zotero-group}}/items/
|
||||
\end request-url
|
||||
|
||||
<$wikify name="url" text=<<request-url>>>
|
||||
<$action-sendmessage
|
||||
$message="tm-http-request"
|
||||
url=<<url>>
|
||||
method="GET"
|
||||
query-format="json"
|
||||
query-sort="title"
|
||||
query-start=<<start>>
|
||||
query-limit=<<limit>>
|
||||
header-accept="application/json"
|
||||
bind-status="$:/temp/zotero/status"
|
||||
bind-progress="$:/temp/zotero/progress"
|
||||
oncompletion=<<completion>>
|
||||
onprogress=<<progress>>
|
||||
var-start=<<start>>
|
||||
var-limit=<<limit>>
|
||||
/>
|
||||
</$wikify>
|
||||
\end
|
||||
|
||||
\procedure zotero-actions()
|
||||
<$macrocall $name="zotero-get-items" start="0" limit="50"/>
|
||||
\end
|
||||
|
||||
<<select-zotero-group>>
|
||||
|
||||
<$button actions=<<zotero-actions>>>
|
||||
Start import from Zotero group
|
||||
</$button>
|
||||
|
||||
<$button message="tm-http-cancel-all-requests">
|
||||
Cancel all HTTP requests
|
||||
</$button> Outstanding requests: {{$:/state/http-requests}}
|
||||
|
||||
<$list filter="[tag[$:/tags/ZoteroImport]limit[1]]" variable="ignore">
|
||||
|
||||
!! Imported Tiddlers
|
||||
|
||||
<$button>
|
||||
<$action-deletetiddler $filter="[tag[$:/tags/ZoteroImport]]"/>
|
||||
Delete these tiddlers
|
||||
</$button>
|
||||
|
||||
Export: <$macrocall $name="exportButton" exportFilter="[tag[$:/tags/ZoteroImport]]" lingoBase="$:/language/Buttons/ExportTiddlers/"/>
|
||||
|
||||
</$list>
|
||||
|
||||
<ol>
|
||||
<$list filter="[tag[$:/tags/ZoteroImport]]">
|
||||
<li>
|
||||
<$link>
|
||||
<$view field="title"/>
|
||||
</$link>
|
||||
</li>
|
||||
</$list>
|
||||
</ol>
|
||||
@@ -0,0 +1,51 @@
|
||||
caption: tm-http-request
|
||||
created: 20230429161453032
|
||||
modified: 20230429161453032
|
||||
tags: Messages
|
||||
title: WidgetMessage: tm-http-request
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
The ''tm-http-request'' message is used to make an HTTP request to a server.
|
||||
|
||||
It uses the following properties on the `event` object:
|
||||
|
||||
|!Name |!Description |
|
||||
|param |Not used |
|
||||
|paramObject |Hashmap of parameters (see below) |
|
||||
|
||||
The following parameters are used:
|
||||
|
||||
|!Name |!Description |
|
||||
|method |HTTP method (eg "GET", "POST") |
|
||||
|body |String data to be sent with the request |
|
||||
|query-* |Query string parameters with string values |
|
||||
|header-* |Headers with string values |
|
||||
|password-header-* |Headers with values taken from the password store |
|
||||
|password-query-* |Query string parameters with values taken from the password store |
|
||||
|var-* |Variables to be passed to the completion and progress handlers (without the "var-" prefix) |
|
||||
|bind-status |Title of tiddler to which the status of the request ("pending", "complete", "error") should be bound |
|
||||
|bind-progress |Title of tiddler to which the progress of the request (0 to 100) should be bound |
|
||||
|oncompletion |Action strings to be executed when the request completes |
|
||||
|onprogress |Action strings to be executed when progress is reported |
|
||||
|
||||
The following variables are passed to the completion handler:
|
||||
|
||||
|!Name |!Description |
|
||||
|status |HTTP result status code (see [[MDN|https://developer.mozilla.org/en-US/docs/Web/HTTP/Status]]) |
|
||||
|statusText |HTTP result status text |
|
||||
|error |Error string |
|
||||
|data |Returned data |
|
||||
|headers |Response headers as a JSON object |
|
||||
|
||||
The following variables are passed to the progress handler:
|
||||
|
||||
|!Name |!Description |
|
||||
|lengthComputable |Whether the progress loaded and total figures are valid - "yes" or "no" |
|
||||
|loaded |Number of bytes loaded so far |
|
||||
|total |Total number bytes to be loaded |
|
||||
|
||||
Note that the state tiddler $:/state/http-requests contains a number representing the number of outstanding HTTP requests in progress.
|
||||
|
||||
!! Examples
|
||||
|
||||
* [[Zotero's|https://www.zotero.org/]] API for retrieving reference items: [[WidgetMessage: tm-http-request Example - Zotero]]
|
||||
@@ -0,0 +1,2 @@
|
||||
title: $:/config/zotero-group
|
||||
text: 4813312
|
||||
@@ -1,11 +1,18 @@
|
||||
caption: 5.3.0
|
||||
created: 20230506164543446
|
||||
modified: 20230506164543446
|
||||
created: 20230701123439630
|
||||
modified: 20230701123439630
|
||||
released: 20230701123439630
|
||||
tags: ReleaseNotes
|
||||
title: Release 5.3.0
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
//[[See GitHub for detailed change history of this release|https://github.com/Jermolene/TiddlyWiki5/compare/v5.2.7...master]]//
|
||||
//[[See GitHub for detailed change history of this release|https://github.com/Jermolene/TiddlyWiki5/compare/v5.2.7...v5.3.0]]//
|
||||
|
||||
<<.banner-credits
|
||||
credit:"""Congratulations to [[vilc|https://talk.tiddlywiki.org/u/vilc]] for their winning design for the banner for this release (here is the [[competition thread|https://talk.tiddlywiki.org/t/banner-image-competition-for-v5-3-0/7406/10]]).
|
||||
"""
|
||||
url:"https://raw.githubusercontent.com/Jermolene/TiddlyWiki5/04950452fab7d5cb86f893020355611c4711d361/editions/tw5.com/tiddlers/images/New%20Release%20Banner.jpg"
|
||||
>>
|
||||
|
||||
! Overview of v5.3.0
|
||||
|
||||
@@ -28,49 +35,76 @@ The approach taken by this release is to add new functionality by extending and
|
||||
|
||||
These changes lay the groundwork for macros and related features to be deprecated (which is the point at which users are advised not to use old features, and instead given clear pointers to the equivalent modern functionality).
|
||||
|
||||
The new transclusion architecture is not by itself sufficient to enable us to fully deprecate macros yet. To handle the remaining use cases we propose a new backtick quoted attribute format that allows for the substitution of variable values. See https://github.com/Jermolene/TiddlyWiki5/issues/6663 for details.
|
||||
! Text Substitution Improvements
|
||||
|
||||
<<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7526">> The new transclusion architecture is not by itself sufficient to enable us to fully deprecate macros yet. To handle most of the remaining use cases this release adds convenient new ways of using textual substitution without having to create a macro:
|
||||
|
||||
Firstly, the new [[text substitution syntax for widget attributes|Substituted Attribute Values]] allows widget attributes to be assigned the value of a string with certain placeholders being replaced by their processed contents. For example:
|
||||
|
||||
* Substitute variable names with the value: <$codeblock code="attr=`Current tiddler is $(currentTiddler)$`"/>
|
||||
* Substitute filter expressions with the first value they return: <$codeblock code="attr=```There are ${ [tag[Done]count[]] }$ completed tasks```"/>
|
||||
|
||||
Secondly, the new [[substitute operator|substitute Operator]] allows the same textual substitutions to be performed via a filter operator with the addition of positional parameters that use placeholders of the form `$1$`, `$2$`, `$3$` etc.
|
||||
|
||||
```
|
||||
[[https://$1$/$(currentTiddler)$]substitute<domain-name>]
|
||||
```
|
||||
|
||||
! HTTP Requests in WikiText
|
||||
|
||||
<<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7422">> new [[WidgetMessage: tm-http-request]] for performing HTTP requests in WikiText. This opens up some exciting new opportunities:
|
||||
|
||||
* Integration with Web-based APIs. The documentation includes an [[example of using the Zotero API|WidgetMessage: tm-http-request Example - Zotero]] to retrieve academic citation data
|
||||
* Dynamic content loading: additional tiddlers can be imported dynamically after the main wiki has loaded
|
||||
|
||||
! Defaulting to Disabling CamelCase Links
|
||||
|
||||
<<.link-badge-updated "https://github.com/Jermolene/TiddlyWiki5/pull/7513">> CamelCase linking is now disabled by default. (Note that this wiki has CamelCase linking explicitly enabled)
|
||||
<<.link-badge-updated "https://github.com/Jermolene/TiddlyWiki5/pull/7513">> CamelCase linking is now disabled by default for new wikis. (Note that this documentation wiki has CamelCase linking explicitly enabled because much of the old content was written relying on them).
|
||||
|
||||
! Plugin Improvements
|
||||
|
||||
* <<.link-badge-updated "https://github.com/Jermolene/TiddlyWiki5/pull/7554">> Google Analytics plugin to use new GA4 code. Note that the update requires manual configuration to use the new "measurement ID" instead of the old "account ID"
|
||||
* <<.link-badge-extended "https://github.com/Jermolene/TiddlyWiki5/pull/7260">> Dynannotate pugin to support three additional search modes
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7365">> problem with [[BrowserStorage Plugin]] unnecessarily saving shadow tiddlers
|
||||
|
||||
* <<.link-badge-improved "https://github.com/Jermolene/TiddlyWiki5/pull/7398">> [[BrowserStorage Plugin]] to request that browser storage be persisted without eviction
|
||||
* <<.link-badge-improved "https://github.com/Jermolene/TiddlyWiki5/pull/7493">> [[CodeMirror Plugin]] to add an option to make trailing spaces visible
|
||||
|
||||
! Translation improvement
|
||||
|
||||
Improvements to the following translations:
|
||||
|
||||
*
|
||||
|
||||
! Accessibility Improvements
|
||||
|
||||
*
|
||||
* French
|
||||
* German
|
||||
* Polish
|
||||
* Chinese
|
||||
|
||||
! Usability Improvements
|
||||
|
||||
*
|
||||
* <<.link-badge-improved "https://github.com/Jermolene/TiddlyWiki5/pull/7524">> consistency of layout of "Settings" tab in $:/ControlPanel
|
||||
|
||||
<!--
|
||||
|
||||
! Widget Improvements
|
||||
|
||||
*
|
||||
-->
|
||||
|
||||
! Filter improvements
|
||||
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7511"> new [[deserialize Operator]] for converting various textual representations of tiddlers into JSON data
|
||||
* <<.link-badge-extended "https://github.com/Jermolene/TiddlyWiki5/pull/7292">> [[format Operator]] to support converting Unix timestamps to TiddlyWiki's native date format
|
||||
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7392">> new [[':then' filter run prefix|Then Filter Run Prefix]]
|
||||
|
||||
! Hackability Improvements
|
||||
|
||||
* <<.link-badge-extended "https://github.com/Jermolene/TiddlyWiki5/pull/7413">> [[Core Icons]] to allow the size to be controlled with a parameter
|
||||
** <<.warning """This change can cause problems with non-standard usage of the core icons where the text is directly rendered instead of being transcluded""">>
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7182">> new [[thisTiddler Variable]] that refers to the tiddler currently being rendered
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7530">> `data-tag-title` attribute to all tag pills, allowing easier [[Custom tag pill styles]]
|
||||
* <<.link-badge-improved "https://github.com/Jermolene/TiddlyWiki5/pull/7332">> [[Story Tiddler Template Cascade]] handling to fall back to the default template if the output of the cascade is not valid
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7378">> missing file extensions for "audio/mpeg" files
|
||||
* <<.link-badge-extended "https://github.com/Jermolene/TiddlyWiki5/pull/7417">> [[Table-of-Contents Macros]] to add consistent support for an ''exclude'' parameter
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/commit/190613ad2989f70526f86eef17f524087f60eb72">> [[tv-config-static Variable]] for indicating static rendering
|
||||
|
||||
! Bug Fixes
|
||||
|
||||
@@ -79,21 +113,17 @@ Improvements to the following translations:
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7380">> crashes when using an invalid CSS selector for [[WidgetMessage: tm-focus-selector]] and [[WidgetMessage: tm-scroll]]
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7401">> bug whereby scrolling occurs if the linkcatcher widget triggers an action-navigate and the $scroll attribute is set to "no"
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7409">> problem switching between LTR and RTL text
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7448">> bug when checkbox widget's listField attribute was given the name of a date field (like <<.field created>> or <<.field modified>>)
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/pull/7448">> bug when the listField attribute of the CheckboxWidget was given the name of a date field (like <<.field created>> or <<.field modified>>)
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/issues/7529">> size of buttons in dropdown for editor "link" toolbar button
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/commit/8e132948b6bec623d81d300fbe6dc3a0307bcc6d">> crash when transcluding a lazily loaded tiddler as an attribute value
|
||||
* <<.link-badge-fixed "https://github.com/Jermolene/TiddlyWiki5/issues/7462">> DiffTextWidget crash with missing or empty attributes
|
||||
* <<.link-badge-improved "https://github.com/Jermolene/TiddlyWiki5/pull/7448">> CheckboxWidget to avoid writing to date fields
|
||||
|
||||
! Developer Improvements
|
||||
|
||||
*
|
||||
|
||||
! Node.js Improvements
|
||||
|
||||
* <<.link-badge-extended "https://github.com/Jermolene/TiddlyWiki5/pull/7471">> [[WebServer Parameter: authenticated-user-header]] to require URI encoding of authenticated username header, permitting non-ASCII characters in usernames
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7253">> support for `filepath` source attribute to [[tiddlywiki.files Files]]
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/commit/48b22abdaab62c281c207127c66883b50898f9dd">> a warning message for JSON errors in [[tiddlywiki.info Files]] or [[plugin.info Files|PluginFolders]]
|
||||
* <<.link-badge-added "https://github.com/Jermolene/TiddlyWiki5/pull/7490">> new "explodePlugins" option to SaveWikiFolderCommand
|
||||
|
||||
! Performance Improvements
|
||||
|
||||
@@ -104,10 +134,15 @@ Improvements to the following translations:
|
||||
[[@Jermolene|https://github.com/Jermolene]] would like to thank the contributors to this release who have generously given their time to help improve TiddlyWiki:
|
||||
|
||||
<<.contributors """
|
||||
AnthonyMuscio
|
||||
Arlen22
|
||||
BramChen
|
||||
btheado
|
||||
buggyj
|
||||
carlo-colombo
|
||||
cdruan
|
||||
donmor
|
||||
EvidentlyCube
|
||||
flibbles
|
||||
GameDungeon
|
||||
JoshuaFontany
|
||||
@@ -117,10 +152,13 @@ Marxsal
|
||||
mateuszwilczek
|
||||
michsa
|
||||
muzimuzhi
|
||||
oeyoews
|
||||
pmario
|
||||
rmunn
|
||||
saqimtiaz
|
||||
tavin
|
||||
twMat
|
||||
xcazin
|
||||
yaisog
|
||||
Zacharia2
|
||||
""">>
|
||||
@@ -285,6 +285,14 @@ ol.doc-github-contributors li {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
.doc-op-comparison {
|
||||
table-layout: fixed;
|
||||
width: 80%;
|
||||
}
|
||||
.doc-op-comparison th .doc-operator {
|
||||
background-color: unset;
|
||||
color: #666;
|
||||
}
|
||||
.doc-tabs.tc-tab-buttons button {
|
||||
font-size: 1rem;
|
||||
padding: 0.5em;
|
||||
@@ -295,4 +303,4 @@ ol.doc-github-contributors li {
|
||||
}
|
||||
.doc-tab-link .doc-attr {
|
||||
color: unset;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
created: 20150117152607000
|
||||
modified: 20220227210111054
|
||||
modified: 20230617183916622
|
||||
tags: $:/tags/Macro
|
||||
title: $:/editions/tw5.com/operator-macros
|
||||
|
||||
\define .operator-examples(op,text:"Examples") <$link to="$op$ Operator (Examples)">$text$</$link>
|
||||
|
||||
\define .operator-example-tryit-actions() <$action-setfield $tiddler=<<.state>> text="show" filter=<<__eg__>>/>
|
||||
\define .operator-example(n,eg,ie)
|
||||
\procedure .operator-example-tryit-actions() <$action-setfield $tiddler=<<.state>> text="show" filter=<<eg>>/>
|
||||
\procedure .operator-example(n,eg,ie)
|
||||
<div class="doc-example">
|
||||
<$list filter="[title<.state-prefix>addsuffix{!!title}addsuffix[/]addsuffix[$n$]]" variable=".state">
|
||||
<$list filter="[title<.state-prefix>addsuffix{!!title}addsuffix[/]addsuffix<n>]" variable=".state">
|
||||
<$reveal state=<<.state>> type="nomatch" text="show">
|
||||
`$eg$`
|
||||
<$macrocall $name=".if" cond="""$ie$""" then="""<dd>→ $ie$</dd>"""/>
|
||||
<code><$text text=<<eg>>/></code>
|
||||
<$macrocall $name=".if" cond=<<ie>> then={{{[[<dd>→ ]addsuffix<ie>addsuffix[</dd>]]}}}/>
|
||||
<dl>
|
||||
<dd><$button actions=<<.operator-example-tryit-actions>>>Try it</$button></dd>
|
||||
</dl>
|
||||
@@ -21,7 +21,7 @@ title: $:/editions/tw5.com/operator-macros
|
||||
<dl>
|
||||
<dd>
|
||||
<$button set=<<.state>> setTo="">Hide</$button>
|
||||
<$reveal stateTitle=<<.state>> stateField="filter" type="nomatch" text=<<__eg__>>>
|
||||
<$reveal stateTitle=<<.state>> stateField="filter" type="nomatch" text=<<eg>>>
|
||||
<$button actions=<<.operator-example-tryit-actions>>>Reset</$button>
|
||||
</$reveal>
|
||||
</dd>
|
||||
|
||||
@@ -151,4 +151,4 @@ Below is an example macro, procedure and function definition. All three forms o
|
||||
*''variables'' - \define, <<.wlink SetWidget>>, <<.wlink LetWidget>>, <<.wlink VarsWidget>>, \procedure, \widget, \function all create variables. If the same name is used, then later define will overwrite earlier defined
|
||||
*''<<.op function>> filter operator parameter'' - only variables defined using \function can be called using the <<.olink function>> operator
|
||||
*''filter operators'' - only the [[javascript defined filter operators|Filter Operators]] and variables defined using \function with name containing a dot can be called
|
||||
*''widgets'' - variables defined using \widget can be invoked using `<$widget/>` syntax ONLY if the name starts a dollar sign (to override existing javascript defined widgets) or double dollar sign (to define [[custom widgets|Custom Widgets]]). Without the dollar sign prefix, defining variables using \widget is no different than using \procedure.
|
||||
*''widgets'' - variables defined using \widget can be invoked using `<$widget/>` syntax ONLY if the name starts a dollar sign. Without the dollar sign prefix, defining variables using \widget is no different than using \procedure.
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
created: 20230617085524754
|
||||
modified: 20230617085524754
|
||||
title: tv-config-static Variable
|
||||
tags: Variables [[Core Variables]] [[Configuration Variables]]
|
||||
type: text/vnd.tiddlywiki
|
||||
caption: tv-config-static
|
||||
|
||||
<<.from-version "5.3.0">> The <<.def tv-config-static>> [[variable|Variables]] is set to `yes` within static rendering templates, and is unset in other contexts.
|
||||
|
||||
It is useful for selectively hiding or showing content depending on whether a rendering is static or interactive.
|
||||
@@ -0,0 +1,16 @@
|
||||
created: 20230615045132842
|
||||
modified: 20230615045231048
|
||||
tags: WikiText [[Widget Attributes]]
|
||||
title: Filtered Attribute Values
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
Filtered attribute values are indicated with triple curly braces around a [[Filter Expression]]. The value will be the first item in the resulting list, or the empty string if the list is empty.
|
||||
|
||||
<<.from-version "5.2.2">> To improve readability, newlines can be included anywhere that whitespace is allowed within filtered attributes.
|
||||
|
||||
This example shows how to add a prefix to a value:
|
||||
|
||||
```
|
||||
<$text text={{{ [<currentTiddler>addprefix[$:/myprefix/]] }}} />
|
||||
```
|
||||
<<.warning "The value of the attribute will be the exact text from the first item in the resulting list. Any wiki syntax in that text will be left as-is.">>
|
||||
@@ -1,6 +1,6 @@
|
||||
caption: HTML
|
||||
created: 20131205160816081
|
||||
modified: 20230115100934146
|
||||
modified: 20230615060119987
|
||||
tags: WikiText
|
||||
title: HTML in WikiText
|
||||
type: text/vnd.tiddlywiki
|
||||
@@ -58,12 +58,13 @@ If you do not close any other tag then it will behave as if the missing closing
|
||||
|
||||
! Attributes
|
||||
|
||||
In an extension of conventional HTML syntax, attributes of elements/widgets can be specified in several different ways:
|
||||
In an extension of conventional HTML syntax, attributes of elements and widgets can be specified in [[several different ways|Widget Attributes]]:
|
||||
|
||||
* a literal string
|
||||
* a transclusion of a TextReference
|
||||
* a transclusion of a [[macro/variable|Macros]]
|
||||
* as the result of a [[Filter Expression]]
|
||||
* [[a literal string|Literal Attribute Values]]
|
||||
* [[a transclusion of a textReference|Transcluded Attribute Values]]
|
||||
* [[a transclusion of a macro/variable|Transcluded Attribute Values]]
|
||||
* [[as the result of a filter expression|Filtered Attribute Values]]
|
||||
* <<.from-version "5.3.0">> [[as the result of performing filter and variable substitutions on the given string|Substituted Attribute Values]]
|
||||
|
||||
!! Style Attributes
|
||||
|
||||
@@ -85,64 +86,10 @@ The advantage of this syntax is that it simplifies assigning computed values to
|
||||
<div style.color={{!!color}}>Hello</div>
|
||||
```
|
||||
|
||||
!! Literal Attribute Values
|
||||
|
||||
Literal attribute values can use several different styles of quoting:
|
||||
|
||||
* Single quotes (eg `attr='value'`)
|
||||
* Double quotes (eg `attr="value"`)
|
||||
* Tripe double quotes (eg `attr="""value"""`)
|
||||
* No quoting is necessary for values that do not contain spaces (eg `attr=value`)
|
||||
|
||||
Literal attribute values can include line breaks. For example:
|
||||
|
||||
```
|
||||
<div data-address="Mouse House,
|
||||
Mouse Lane,
|
||||
Rodentville,
|
||||
Ratland."/>
|
||||
```
|
||||
|
||||
By using triple-double quotes you can specify attribute values that contain single double quotes. For example:
|
||||
|
||||
```
|
||||
<div data-address="""Mouse House,
|
||||
"Mouse" Lane,
|
||||
Rodentville,
|
||||
Ratland."""/>
|
||||
```
|
||||
|
||||
!! Transcluded Attribute Values
|
||||
|
||||
Transcluded attribute values are indicated with double curly braces around a TextReference. For example:
|
||||
|
||||
```
|
||||
attr={{tiddler}}
|
||||
attr={{!!field}}
|
||||
attr={{tiddler!!field}}
|
||||
```
|
||||
<<.warning "The value of the attribute value will be the exact text retrieved from the TextReference. Any wiki syntax in that text will be left as-is.">>
|
||||
|
||||
!! Variable Attribute Values
|
||||
|
||||
Variable attribute values are indicated with double angle brackets around a [[macro invocation|Macro Calls]]. For example:
|
||||
|
||||
```
|
||||
<div title=<<MyMacro "Brian">>>
|
||||
...
|
||||
</div>
|
||||
```
|
||||
<<.warning "The text from the definition of the macro will be retrieved and text substitution will be performed (i.e. <<.param $param$>> and <<.param $(...)$>> syntax). The value of the attribute value will be the resulting text. Any wiki syntax in that text (including further macro calls and variable references) will be left as-is.">>
|
||||
|
||||
!! Filtered Attribute Values
|
||||
|
||||
Filtered attribute values are indicated with triple curly braces around a [[Filter Expression]]. The value will be the first item in the resulting list, or the empty string if the list is empty.
|
||||
|
||||
<<.from-version "5.2.2">> To improve readability, newlines can be included anywhere that whitespace is allowed within filtered attributes.
|
||||
|
||||
This example shows how to add a prefix to a value:
|
||||
|
||||
```
|
||||
<$text text={{{ [<currentTiddler>addprefix[$:/myprefix/]] }}} />
|
||||
```
|
||||
<<.warning "The value of the attribute will be the exact text from the first item in the resulting list. Any wiki syntax in that text will be left as-is.">>
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
created: 20230615045409162
|
||||
modified: 20230615045432768
|
||||
tags: [[Widget Attributes]] WikiText
|
||||
title: Literal Attribute Values
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
Literal attribute values can use several different styles of quoting:
|
||||
|
||||
* Single quotes (eg `attr='value'`)
|
||||
* Double quotes (eg `attr="value"`)
|
||||
* Tripe double quotes (eg `attr="""value"""`)
|
||||
* No quoting is necessary for values that do not contain spaces (eg `attr=value`)
|
||||
|
||||
Literal attribute values can include line breaks. For example:
|
||||
|
||||
```
|
||||
<div data-address="Mouse House,
|
||||
Mouse Lane,
|
||||
Rodentville,
|
||||
Ratland."/>
|
||||
```
|
||||
|
||||
By using triple-double quotes you can specify attribute values that contain single double quotes. For example:
|
||||
|
||||
```
|
||||
<div data-address="""Mouse House,
|
||||
"Mouse" Lane,
|
||||
Rodentville,
|
||||
Ratland."""/>
|
||||
```
|
||||
@@ -0,0 +1,45 @@
|
||||
base-url: http://tiddlywiki.com/
|
||||
created: 20230615050814821
|
||||
modified: 20230615173033918
|
||||
tags: [[Widget Attributes]] WikiText
|
||||
title: Substituted Attribute Values
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
<<.from-version "5.3.0">>
|
||||
Substituted attribute values can use two different styles of quoting:
|
||||
|
||||
* Single backticks <$codeblock code="attr=`value`"/>
|
||||
* Triple backticks <$codeblock code="attr=```value```"/>
|
||||
|
||||
The value of the attribute will be the text denoted by the backticks with any of the placeholders for filter expressions and variables substituted with their corresponding values. Filter expression placeholders are substituted before variable placeholders, allowing for further variable substitution in their returned value.
|
||||
|
||||
<<.warning "Any other wiki syntax in that text will be left as-is.">>
|
||||
|
||||
|
||||
|placeholder syntax|description|h
|
||||
|`$(varname)$`|Text substitution of a variable. Undefined variables are replaced with an empty string. |
|
||||
|`${ filter expression }$`|Text substitution with the first result of evaluating the filter expression. |
|
||||
|
||||
! Examples
|
||||
|
||||
!! Substituting a variable value into a string
|
||||
|
||||
<$macrocall $name=wikitext-example-without-html src='<$text text=`Hello there this is the tiddler "$(currentTiddler)$"`/>'/>
|
||||
|
||||
|
||||
!! Substituting a variable value and the result of evaluating a filter expression into a string
|
||||
<$macrocall $name=wikitext-example-without-html src='<$text text=`This tiddler is titled "$(currentTiddler)$" and was last modified on ${[{!!modified}format:date[DDth MMM YYYY]]}$`/>'/>
|
||||
|
||||
!! Concatenating strings and variables to create a URL
|
||||
|
||||
<$macrocall $name=wikitext-example-without-html src='
|
||||
<$let hash={{{ [<currentTiddler>encodeuricomponent[]] }}}>
|
||||
<a href=`http://tiddlywiki.com/#$(hash)$`>this tiddler on tiddlywiki.com</a>
|
||||
</$let>'/>
|
||||
|
||||
!! Concatenating variables and a text reference to create a URL
|
||||
|
||||
<$macrocall $name=wikitext-example-without-html src='
|
||||
<$let hash={{{ [<currentTiddler>encodeuricomponent[]] }}}>
|
||||
<a href=`${ [{!!base-url}] }$#$(hash)$`>this tiddler on tiddlywiki.com</a>
|
||||
</$let>'/>
|
||||
@@ -0,0 +1,14 @@
|
||||
created: 20230615045327830
|
||||
modified: 20230615045353826
|
||||
tags: [[Widget Attributes]] WikiText
|
||||
title: Transcluded Attribute Values
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
Transcluded attribute values are indicated with double curly braces around a TextReference. For example:
|
||||
|
||||
```
|
||||
attr={{tiddler}}
|
||||
attr={{!!field}}
|
||||
attr={{tiddler!!field}}
|
||||
```
|
||||
<<.warning "The value of the attribute value will be the exact text retrieved from the TextReference. Any wiki syntax in that text will be left as-is.">>
|
||||
@@ -0,0 +1,14 @@
|
||||
created: 20230615045239825
|
||||
modified: 20230615045312961
|
||||
tags: [[Widget Attributes]] WikiText
|
||||
title: Variable Attribute Values
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
Variable attribute values are indicated with double angle brackets around a [[macro invocation|Macro Calls]]. For example:
|
||||
|
||||
```
|
||||
<div title=<<MyMacro "Brian">>>
|
||||
...
|
||||
</div>
|
||||
```
|
||||
<<.warning "The text from the definition of the macro will be retrieved and text substitution will be performed (i.e. <<.param $param$>> and <<.param $(...)$>> syntax). The value of the attribute value will be the resulting text. Any wiki syntax in that text (including further macro calls and variable references) will be left as-is.">>
|
||||
21
editions/tw5.com/tiddlers/wikitext/Widget Attributes.tid
Normal file
21
editions/tw5.com/tiddlers/wikitext/Widget Attributes.tid
Normal file
@@ -0,0 +1,21 @@
|
||||
created: 20230615045526689
|
||||
modified: 20230615060059476
|
||||
tags: WikiText
|
||||
title: Widget Attributes
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
Attributes of HTML elements and widgets can be specified in several different ways:
|
||||
|
||||
* [[a literal string|Literal Attribute Values]]
|
||||
* [[a transclusion of a textReference|Transcluded Attribute Values]]
|
||||
* [[a transclusion of a macro/variable|Transcluded Attribute Values]]
|
||||
* [[as the result of a filter expression|Filtered Attribute Values]]
|
||||
* <<.from-version "5.3.0">> [[as the result of performing filter and variable substitutions on the given string|Substituted Attribute Values]]
|
||||
|
||||
|attribute type|syntax|h
|
||||
|literal |single, double or triple quotes or no quotes for values without spaces |
|
||||
|transcluded |double curly braces around a text reference |
|
||||
|variable |double angle brackets around a macro or variable invocation |
|
||||
|filtered |triple curly braces around a filter expression|
|
||||
|substituted|single or triple backticks around the text to be processed for substitutions|
|
||||
|
||||
@@ -67,6 +67,8 @@ More/Caption: mehr
|
||||
More/Hint: Weitere Aktionen
|
||||
NewHere/Caption: Neu hier
|
||||
NewHere/Hint: Erstelle einen neuen Tiddler, der mit dem Namen dieses Tiddlers getaggt ist
|
||||
NetworkActivity/Caption: Netzwerk Aktivität
|
||||
NetworkActivity/Hint: Alle offen Netwerk Anfragen beenden
|
||||
NewJournal/Caption: Neues Journal
|
||||
NewJournal/Hint: Erstelle einen neuen Journal-Tiddler
|
||||
NewJournalHere/Caption: Neues Journal hier
|
||||
|
||||
@@ -1,11 +1,13 @@
|
||||
title: $:/language/Docs/Fields/
|
||||
|
||||
_canonical_uri: Die komplette URI eines externen Foto Tiddlers. URI = Uniform Resource Identifier, Identifikator für Ressourcen im Internet.
|
||||
author: Name des Plugin-Authors
|
||||
bag: Der Name eines ~TiddlyWeb "bags" von dem der Tiddler kam.
|
||||
code-body: Das "View Template" wird den Tiddler Text als "Code" anzeigen, wenn dieses Feld auf: ''"yes"'' gesetzt wird.
|
||||
caption: Der Text, der auf "Tab-Buttons" angezeigt wird.
|
||||
code-body: Das "View Template" wird den Tiddler Text als "Code" anzeigen, wenn dieses Feld auf: ''"yes"'' gesetzt wird.
|
||||
color: Der CSS Farbwert, der mit einem Tiddler assoziiert wird.
|
||||
component: Der Name einer Komponente, die für eine [[Alarm Anzeige|AlertMechanism]] verantwortlich ist.
|
||||
core-version: Zeigt die TiddlyWiki Version an, ab der ein Plugin verwendet werden kann.
|
||||
current-tiddler: Wird verwendet um den "obersten" Tiddler in der [[Tiddler Historie|HistoryMechanism]] zwischen zu speichern.
|
||||
created: Datum an dem der Tiddler erstellt wurde.
|
||||
creator: Name des Erstellers dieses Tiddlers.
|
||||
@@ -22,7 +24,9 @@ list-before: Dient zum Einfügen von Tiddler Titeln in das "list" Feld. Wenn ges
|
||||
list-after: Dient zum Einfügen von Tiddler Titeln in das "list" Feld. Wenn gesetzt, wird der neue Tiddler ''nach'' dem hier definierten Tiddler in die Liste eingefügt.
|
||||
modified: Datum, an dem der Tiddler zuletzt verändert wurde.
|
||||
modifier: Name der Person, die den Tiddler zuletzt verändert hat.
|
||||
module-type: Zeigt den Modul-typ bei JavaScript Tiddlern an.
|
||||
name: Ein Menschen lesbarer Name für einen "plugin" Tiddler.
|
||||
parent-plugin: Enthält den Namen des Übergeordneten Plugins.
|
||||
plugin-priority: Ein numerischer Wert, der die Priorität eines "plugins" festlegt.
|
||||
plugin-type: Der Typ eines "plugins".
|
||||
revision: Die Revisionsnummer eines Tiddlers. Wird von einem Server vergeben.
|
||||
|
||||
@@ -24,9 +24,10 @@ Hinweis: Die österreichische und deutsche Version unterscheiden sich momentan n
|
||||
|
||||
<div class="tc-control-panel">
|
||||
|
||||
|<$link to="$:/SiteTitle"><<lingo Title/Prompt>></$link> |<$edit-text tiddler="$:/SiteTitle" default="" tag="input"/> |
|
||||
|<$link to="$:/SiteSubtitle"><<lingo Subtitle/Prompt>></$link> |<$edit-text tiddler="$:/SiteSubtitle" default="" tag="input"/> |
|
||||
|<$link to="$:/DefaultTiddlers"><<lingo DefaultTiddlers/Prompt>></$link> |<<lingo DefaultTiddlers/TopHint>><br> <$edit-text tag="textarea" tiddler="$:/DefaultTiddlers"/><br>//<<lingo DefaultTiddlers/BottomHint>>// |
|
||||
|tc-table-no-border tc-first-col-min-width tc-first-link-nowrap|k
|
||||
| <$link to="$:/SiteTitle"><<lingo Title/Prompt>></$link>|<$edit-text tiddler="$:/SiteTitle" default="" tag="input"/> |
|
||||
| <$link to="$:/SiteSubtitle"><<lingo Subtitle/Prompt>></$link>|<$edit-text tiddler="$:/SiteSubtitle" default="" tag="input"/> |
|
||||
|^ <$link to="$:/DefaultTiddlers"><<lingo DefaultTiddlers/Prompt>></$link><br><<lingo DefaultTiddlers/TopHint>>| <$edit-text tag="textarea" tiddler="$:/DefaultTiddlers"/><br>//<<lingo DefaultTiddlers/BottomHint>>// |
|
||||
</div>
|
||||
|
||||
See the [[control panel|$:/ControlPanel]] for more options.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
title: $:/language/Help/import
|
||||
description: Importiert mehrere Tiddler aus einer Datei
|
||||
|
||||
Dieser Befehl importiert / extrahiert Tiddler aus folgenden Dateien:
|
||||
Dieser Befehl importiert / extrahiert Tiddler aus folgenden Dateien:
|
||||
|
||||
* ~TiddlyWiki `*.html`
|
||||
* `*.tiddler`
|
||||
|
||||
@@ -20,7 +20,7 @@ Mögliche Parameter:
|
||||
* ''anon-username'' - Name, der für anonymer Benutzer verwendet wird, um bearbeitete Tiddler zu markieren
|
||||
* ''username'' - Benutzername für die Basis-Authentifizierung
|
||||
* ''password'' - Passwort für die Basis-Authentifizierung
|
||||
* ''authenticated-user-header'' - HTTP Header-Name für vertrauenswürdige, authentifizierte Benutzer
|
||||
* ''authenticated-user-header'' - Optionaler HTTP Header-Name für vertrauenswürdige, authentifizierte Benutzer
|
||||
* ''readers'' - Komma-separierte Liste für Benutzer, mit Schreiberlaubnis
|
||||
* ''writers'' - Komma-separierte Liste für Benutzer, mit Leseerlaubnis
|
||||
* ''csrf-disable'' - "yes" bedeutet, dass CSRF checks deaktiviert sind. (Standard: "no")
|
||||
|
||||
@@ -3,7 +3,7 @@ description: Ausgabe eines individuellen Tiddlers, in einem spezifizierten Forma
|
||||
|
||||
''WICHTIG:''
|
||||
|
||||
* Der `--rendertiddler` Befehl wird ab V5.1.15 durch `--render` ersetzt.
|
||||
* Der `--rendertiddler` Befehl wird ab V5.1.15 durch `--render` ersetzt.
|
||||
* `--rendertiddler` wird auslaufen und sollte daher nicht mehr verwendet werden!
|
||||
|
||||
Ausgabe eines individuellen Tiddlers, in einem spezifizierten Format (standard: `text/html`) und Dateinamen.
|
||||
|
||||
@@ -3,7 +3,7 @@ description: Gefilterte Ausgabe von Tiddlern, in einem spezifizierten Format.
|
||||
|
||||
''WICHTIG:''
|
||||
|
||||
* Der `--rendertiddlers` Befehl wird ab V5.1.15 durch `--render` ersetzt.
|
||||
* Der `--rendertiddlers` Befehl wird ab V5.1.15 durch `--render` ersetzt.
|
||||
* `--rendertiddlers` wird auslaufen und sollte daher nicht mehr verwendet werden!
|
||||
|
||||
Gefilterte Ausgabe mehrerer Tiddler, in ein angegebenes Dateiformat (standard: `text/html`) mit spezifischer Erweiterung (Standard: `.html`).
|
||||
|
||||
@@ -4,7 +4,7 @@ description: Speichert ein Wiki in einen neues Verzeichnis
|
||||
<<.from-version "5.1.20">> Speichert das aktuelle Wiki als ein Wiki-Verzeichnis. Inklusive Tiddlern, Plugins und Konfiguration:
|
||||
|
||||
```
|
||||
--savewikifolder <wikifolderpath> [<filter>]
|
||||
--savewikifolder <wikifolderpath> [<filter>] [ [<name>=<value>] ]*
|
||||
```
|
||||
|
||||
* Das Zielverzeichnis muss leer sein, oder nicht existent
|
||||
@@ -12,8 +12,22 @@ description: Speichert ein Wiki in einen neues Verzeichnis
|
||||
* Plugins des offiziellen Plugin-Verzeichnisses werden durch Referenzen zu den Plugins in der `tiddlywiki.info` Datei ersetzt.
|
||||
* Drittanbieter Plugins werden in ihre eigenen Verzeichnisse entpackt
|
||||
|
||||
Diese Funktion wird vor allem dazu verwendet, eine Wiki-Datei in einzelne Tiddler in einem Wiki-Verzeichnis umzuwandeln.
|
||||
Folgende Optionen werden unterstützt:
|
||||
|
||||
* ''filter'': Ein "Filter-Run" der die Tiddler definiert, die ausgegeben werden sollen.
|
||||
|
||||
* ''explodePlugins'': Standard ist: "yes"
|
||||
** "yes": wird Plugins "aufspalten" und einzelne "Shadow Tiddler" in ein "tiddlers/<plugin>" Verzeichnis speichern.
|
||||
** "no": Wird das "aufspalten" von Plugins in einzelne "Shadow Tiddler" unterbinden. Das plugin selbst wird als 1 JSON Tiddler gespeichert.
|
||||
|
||||
Diese Funktionen werden vor allem dazu verwendet, eine Wiki-Datei in einzelne Tiddler in einem Wiki-Verzeichnis umzuwandeln:
|
||||
|
||||
```
|
||||
tiddlywiki --load ./mywiki.html --savewikifolder ./mywikifolder
|
||||
```
|
||||
|
||||
Der folgende Befehl wird das Plugin als JSON-Tiddler in das "tiddlers" Verzeichnis speichern:
|
||||
|
||||
```
|
||||
tiddlywiki --load ./mywiki.html --savewikifolder ./mywikifolder explodePlugins=no
|
||||
```
|
||||
@@ -1,4 +1,4 @@
|
||||
title: $:/language/Import/
|
||||
title: $:/language/Import/
|
||||
|
||||
Editor/Import/Heading: Bilder in den Editor importieren.
|
||||
Imported/Hint: Folgende Tiddler wurden importiert:
|
||||
|
||||
@@ -25,6 +25,8 @@ Encryption/RepeatPassword: Passwort wiederholen
|
||||
Encryption/PasswordNoMatch: Passwörter stimmen nicht überein
|
||||
Encryption/SetPassword: Passwort setzen
|
||||
Error/Caption: Fehler
|
||||
Error/DeserializeOperator/MissingOperand: Filter Fehler: Fehlender Operand für 'deserialize' Operator
|
||||
Error/DeserializeOperator/UnknownDeserializer: Filter Fehler: Unbekannter "deserializer" als Operand für 'deserialize' Operator verwendet
|
||||
Error/Filter: Filter Fehler
|
||||
Error/FilterSyntax: Syntax Fehler im Filter-Ausdruck
|
||||
Error/FilterRunPrefix: Filter Fehler: Unbekanntes Prefix für Filter lauf
|
||||
@@ -40,6 +42,7 @@ Error/RetrievingSkinny: Fehler beim Empfangen einer "skinny" Tiddler Liste
|
||||
Error/SavingToTWEdit: Fehler beim Speichern mit "TWEdit"
|
||||
Error/WhileSaving: Fehler beim Speichern
|
||||
Error/XMLHttpRequest: XMLHttpRequest Fehler-Code
|
||||
Error/ZoominTextNode: "Story View Error:" Es scheint Sie versuchen mit einem Tiddler zu interagieren, der in einem speziellen Container angezeigt wird. Dies wird wahrscheinlich durch den Tag: `$:/tags/StoryTiddlerTemplateFilter`verursacht. Wahrscheinlich enthält das Template reinen Text oder Leerzeilen am Anfang. Verwenden Sie das "Pragma" `\whitespace trim` oder stellen Sie sicher, dass der Template Inhalt in einem HTML-Element "eingeschlossen" ist. Der Text, der den Fehler verursacht ist:
|
||||
InternalJavaScriptError/Title: Interner JavaScript Fehler
|
||||
InternalJavaScriptError/Hint: Es tut uns leid, aber bitte starten Sie Ihr TiddlyWiki neu, indem sie die Seite im Browser neu laden.
|
||||
LayoutSwitcher/Description: "Layout" Selektor anzeigen
|
||||
|
||||
@@ -4,7 +4,7 @@ subtitle: Änderungen Speichern
|
||||
footer: <$button message="tm-close-tiddler">Schließen</$button>
|
||||
help: https://tiddlywiki.com/static/DownloadingChanges.html
|
||||
|
||||
Ihr Browser unterstützt nur manuelles Speichern.
|
||||
Ihr Browser unterstützt nur manuelles Speichern.
|
||||
|
||||
Um das geänderte Wiki zu speichern, machen Sie einen "rechts klick" auf den folgenden Link. Wählen Sie "Datei herunterladen" oder "Datei speichern" und wählen Sie Name und Verzeichnis.
|
||||
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/SiteTitle
|
||||
|
||||
Mein ~TiddlyWiki
|
||||
Mein TiddlyWiki
|
||||
@@ -3,6 +3,6 @@ tags: $:/tags/TextEditor/Snippet
|
||||
caption: Makro Definition
|
||||
|
||||
\define makroName(param1:"standard parameter", param2)
|
||||
Text des Makros. Zugriff auf den $param1$.
|
||||
$param2$
|
||||
Text des Makros. Zugriff auf den <<__param1__>>.
|
||||
<<__param2__>>
|
||||
\end
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
title: $:/language/Snippets/Table4x3
|
||||
tags: $:/tags/TextEditor/Snippet
|
||||
caption: Tabelle mit 5 Spalten, 4 Zeilen, Kopf- und Fußzeile
|
||||
caption: Tabelle -- 5 Spalten, 3 Zeilen, Kopf-, Fußzeile und Beschriftung
|
||||
|
||||
| |Alpha |Beta |Gamma |Delta |h
|
||||
|!Beta | | | | |
|
||||
|
||||
@@ -59,12 +59,16 @@ Home/Caption: accueil
|
||||
Home/Hint: Ouvre les tiddlers par défaut
|
||||
Language/Caption: langue
|
||||
Language/Hint: Choix de la langue pour l'interface utilisateur
|
||||
LayoutSwitcher/Hint: Choix de la mise en page
|
||||
LayoutSwitcher/Caption: mise en page
|
||||
Manager/Caption: gestionnaire de tiddlers
|
||||
Manager/Hint: Ouvre le gestionnaire de tiddlers
|
||||
More/Caption: plus
|
||||
More/Hint: Actions supplémentaires
|
||||
NewHere/Caption: nouveau, à partir d'ici
|
||||
NewHere/Hint: Crée un nouveau tiddler avec pour tag le titre du tiddler courant
|
||||
NetworkActivity/Caption: activité réseau
|
||||
NetworkActivity/Hint: Annule toute l'activité réseau
|
||||
NewJournal/Caption: nouveau journal
|
||||
NewJournal/Hint: Crée un nouveau tiddler journal
|
||||
NewJournalHere/Caption: nouveau journal, à partir d'ici
|
||||
|
||||
@@ -1,11 +1,13 @@
|
||||
title: $:/language/Docs/Fields/
|
||||
|
||||
_canonical_uri: L'URI complet vers le contenu externe d'un tiddler image
|
||||
author: Nom de l'auteur d'un plugin
|
||||
bag: Nom du <q>bag</q> d'où provient le tiddler
|
||||
caption: Texte à afficher sur un onglet ou un bouton
|
||||
code-body: Le template de visualisation affichera ce tiddler comme du code si la valeur est ''yes''
|
||||
color: Couleur CSS associée au tiddler
|
||||
component: Nom du composant responsable pour un [[tiddler d'alerte|AlertMechanism]]
|
||||
core-version: Dans le cas d'un plugin, indique la version de TiddlyWiki avec laquelle il est compatible
|
||||
current-tiddler: Sert à cacher le tiddler situé au début de l'[[historique|HistoryMechanism]]
|
||||
created: Date de création du tiddler
|
||||
creator: Nom de l'utilisateur qui a créé le tiddler
|
||||
@@ -13,7 +15,7 @@ dependents: Quand le tiddler est un plugin, énumère les titres des plugins dé
|
||||
description: Texte de description d'un plugin, ou d'une boîte de dialogue
|
||||
draft.of: Pour les tiddlers en cours d'édition, contient le titre du tiddler initial
|
||||
draft.title: Pour les tiddlers en cours d'édition, contient le nouveau titre prévu pour le tiddler
|
||||
footer: Texte de bas de page dans le cas d'un wizard
|
||||
footer: Texte de bas de page dans le cas d'une fenêtre modale
|
||||
hide-body: Le template de visualisation cachera le corps des tiddlers si la valeur est ''yes''
|
||||
icon: Titre du tiddler contenant l'icone associée à un tiddler
|
||||
library: Si la valeur est <q>yes</q>, indique qu'un tiddler doit être sauvegardé comme bibliothèque JavaScript
|
||||
@@ -22,13 +24,15 @@ list-before: Si présent, contient le titre du tiddler avant lequel ce tiddler d
|
||||
list-after: Si présent, contient le titre du tiddler après lequel ce tiddler doit être ajouté dans la liste ordonnée des titres de tiddlers.
|
||||
modified: Date et heure à laquelle le tiddler a été modifié pour la dernière fois
|
||||
modifier: Titre du tiddler associé à l'utilisateur qui a modifié ce tiddler pour la dernière fois
|
||||
name: Dans le cas d'un tiddler provenant d'un plugin, le nom de la personne associée à ce tiddler
|
||||
plugin-priority: Dans le cas d'un tiddler provenant d'un plugin, un nombre indiquant la priorité de ce tiddler
|
||||
plugin-type: Dans le cas d'un tiddler provenant d'un plugin, le type du plugin
|
||||
module-type: Pour les tiddlers javascript, spécifie de quel type est ce module
|
||||
name: Dans le cas d'un tiddler plugin, le nom associé à ce plugin
|
||||
parent-plugin: Dans le cas d'un tiddler plugin, spécifie de quel plugin il est un sous-plugin
|
||||
plugin-priority: Dans le cas d'un tiddler plugin, un nombre indiquant sa priorité
|
||||
plugin-type: Dans le cas d'un tiddler plugin, le type du plugin
|
||||
revision: Numéro de révision du tiddler présent sur le serveur
|
||||
released: Date de version d'un TiddlyWiki
|
||||
source: URL source associée à ce tiddler
|
||||
subtitle: Texte du sous-titre pour un wizard
|
||||
subtitle: Texte du sous-titre pour une fenêtre modale
|
||||
tags: Liste des tags associés à un tiddler
|
||||
text: Texte du corps de ce tiddler
|
||||
throttle.refresh: Si présent, ralentit les rafraîchissements de ce tiddler
|
||||
|
||||
18
languages/fr-FR/Help/commands.tid
Normal file
18
languages/fr-FR/Help/commands.tid
Normal file
@@ -0,0 +1,18 @@
|
||||
title: $:/language/Help/commands
|
||||
description: Lance les commandes retournées par un filtre
|
||||
|
||||
Lance la séquence des commandes retournées par un filtre
|
||||
|
||||
```
|
||||
--commands <filtre>
|
||||
```
|
||||
|
||||
Exemples
|
||||
|
||||
```
|
||||
--commands "[enlist{$:/commandes-build-sous-forme-de-texte}]"
|
||||
```
|
||||
|
||||
```
|
||||
--commands "[{$:/commandes-build-sous-forme-json}jsonindexes[]] :map[{$:/commandes-build-sous-forme-json}jsonget<currentTiddler>]"
|
||||
```
|
||||
@@ -25,6 +25,8 @@ Encryption/RepeatPassword: Répéter le mot de passe
|
||||
Encryption/PasswordNoMatch: Les mots de passe ne correspondent pas
|
||||
Encryption/SetPassword: Définir ce mot de passe
|
||||
Error/Caption: Erreur
|
||||
Error/DeserializeOperator/MissingOperand: Erreur de filtre: opérande manquant pour l'opérateur 'deserialize'
|
||||
Error/DeserializeOperator/UnknownDeserializer: Erreur de filtre: l'opérateur 'deserialize' a pour opérande un désérialiseur inconnu
|
||||
Error/Filter: Erreur de filtre
|
||||
Error/FilterSyntax: Erreur de syntaxe dans l'expression du filtre
|
||||
Error/FilterRunPrefix: Erreur de filtre : Préfixe de run inconnu pour le filtre
|
||||
@@ -40,6 +42,7 @@ Error/RetrievingSkinny: Erreur pendant la récupération de la liste des tiddler
|
||||
Error/SavingToTWEdit: Erreur lors de l'enregistrement vers TWEdit
|
||||
Error/WhileSaving: Erreur lors de l'enregistrement
|
||||
Error/XMLHttpRequest: Code d'erreur XMLHttpRequest
|
||||
Error/ZoominTextNode: Erreur de visualisation dans le déroulé : il semble que vous cherchiez à interagir avec un tiddler qui s'affiche dans un containeur personnalisé. Le problème vient probablement de l'utilisation de `$:/tags/StoryTiddlerTemplateFilter` avec un template qui commence par du texte ou des espaces. Merci d'utiliser le pragma `\whitespace trim` et de vous assurer que tout le contenu du tiddler est inclus dans un seul élément HTML. Voici le texte à l'origine du problème :
|
||||
InternalJavaScriptError/Title: Erreur interne JavaScript
|
||||
InternalJavaScriptError/Hint: C'est assez embarrassant. Il est recommandé de rafraîchir l'affichage de votre navigateur
|
||||
LayoutSwitcher/Description: Ouvre le commutateur de mise en page
|
||||
|
||||
@@ -67,6 +67,8 @@ More/Caption: więcej
|
||||
More/Hint: Więcej akcji
|
||||
NewHere/Caption: nowy tiddler tu
|
||||
NewHere/Hint: Stwórz nowego tiddlera otagowanego tym tiddlerem
|
||||
NetworkActivity/Caption: ruch sieciowy
|
||||
NetworkActivity/Hint: Anuluj cały ruch sieciowy
|
||||
NewJournal/Caption: nowy dziennik
|
||||
NewJournal/Hint: Tworzy nowego tiddlera o typie dziennika
|
||||
NewJournalHere/Caption: nowy dziennik tu
|
||||
|
||||
@@ -25,6 +25,8 @@ Encryption/RepeatPassword: Powtórz hasło
|
||||
Encryption/PasswordNoMatch: Hasła się nie zgadzają
|
||||
Encryption/SetPassword: Ustaw hasło
|
||||
Error/Caption: Bład
|
||||
Error/DeserializeOperator/MissingOperand: Błąd filtra: Nie podano argumentu dla operatora 'deserialize'
|
||||
Error/DeserializeOperator/UnknownDeserializer: Błąd filtra: Podano nieznany deserializator jako argument dla operatora 'deserialize'
|
||||
Error/Filter: Bład filtra
|
||||
Error/FilterSyntax: Bład składniowy filtra
|
||||
Error/FilterRunPrefix: Bład filtra: Nieznany prefiks dla filtra 'run'
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
title: $:/SiteTitle
|
||||
|
||||
Moja ~TiddlyWiki
|
||||
Moja TiddlyWiki
|
||||
|
||||
@@ -67,6 +67,8 @@ More/Caption: 更多
|
||||
More/Hint: 更多操作
|
||||
NewHere/Caption: 添加子条目
|
||||
NewHere/Hint: 创建一个标签为此条目名称的新条目
|
||||
NetworkActivity/Caption: 网络活动
|
||||
NetworkActivity/Hint: 取消所有网络活动
|
||||
NewJournal/Caption: 添加日志
|
||||
NewJournal/Hint: 创建一个新的日志条目
|
||||
NewJournalHere/Caption: 添加子日志
|
||||
|
||||
@@ -86,8 +86,8 @@ Plugins/Languages/Hint: 语言包插件
|
||||
Plugins/NoInfoFound/Hint: 无 ''"<$text text=<<currentTab>>/>"''
|
||||
Plugins/NoInformation/Hint: 未提供信息
|
||||
Plugins/NotInstalled/Hint: 尚未安装此插件
|
||||
Plugins/OpenPluginLibrary: 开启插件程式库
|
||||
Plugins/ClosePluginLibrary: 关闭插件程式库
|
||||
Plugins/OpenPluginLibrary: 打开插件库
|
||||
Plugins/ClosePluginLibrary: 关闭插件库
|
||||
Plugins/PluginWillRequireReload: (需要重新加载)
|
||||
Plugins/Plugins/Caption: 插件
|
||||
Plugins/Plugins/Hint: 插件
|
||||
@@ -229,4 +229,4 @@ Tools/Download/Full/Caption: 下载完整副本
|
||||
ViewTemplateBody/Caption: 查看模板主体
|
||||
ViewTemplateBody/Hint: 默认的查看模板使用此规则级联,动态选择模板以显示条目的主体。
|
||||
ViewTemplateTitle/Caption: 查看模板标题
|
||||
ViewTemplateTitle/Hint: 默认的查看模板使用此规则级联,动态选择模板以显示条目的标题。
|
||||
ViewTemplateTitle/Hint: 默认的查看模板使用此规则级联,动态选择模板以显示条目的标题。
|
||||
|
||||
@@ -4,7 +4,7 @@ description: 将维基保存到一个新的维基文件夹
|
||||
<<.from-version "5.1.20">> 将当前维基保存为一个维基文件夹,包含条目、插件和配置:
|
||||
|
||||
```
|
||||
--savewikifolder <wikifolderpath> [<filter>]
|
||||
--savewikifolder <wikifolderpath> [<filter>] [ [<name>=<value>] ]*
|
||||
```
|
||||
|
||||
* 目标维基文件夹必须为空或不存在
|
||||
@@ -12,8 +12,19 @@ description: 将维基保存到一个新的维基文件夹
|
||||
* 官方插件库中的插件,将替换为 `tiddlywiki.info` 文件中引用到的插件
|
||||
* 自订插件将解压缩到自己的文件夹中
|
||||
|
||||
支持以下选项:
|
||||
|
||||
* ''filter'':定义要包含在输出中的条目的筛选器操作符。
|
||||
* ''explodePlugins'':设置为 "no" 以将插件保存到目标维基文件夹的 tiddlers 目录中,以抑制破坏插件到其组成的影子条目中(默认为 "yes")。
|
||||
|
||||
常见的用法是将一个 TiddlyWiki HTML 文件转换成维基文件夹:
|
||||
|
||||
```
|
||||
tiddlywiki --load ./mywiki.html --savewikifolder ./mywikifolder
|
||||
```
|
||||
|
||||
将插件保存到目标维基文件夹的 tiddlers 目录中:
|
||||
|
||||
```
|
||||
tiddlywiki --load ./mywiki.html --savewikifolder ./mywikifolder explodePlugins=no
|
||||
```
|
||||
@@ -32,7 +32,7 @@ Error/FilterRunPrefix: 筛选器错误:筛选器 run 的未知首码
|
||||
Error/FilterSyntax: 筛选器运算式中的语法错误
|
||||
Error/FormatFilterOperator: 筛选器错误:`format` 筛选器运算符的未知尾码
|
||||
Error/IsFilterOperator: 筛选器错误︰'is' 筛选器运算符的未知操作数
|
||||
Error/LoadingPluginLibrary: 加载插件程式库时,发生错误
|
||||
Error/LoadingPluginLibrary: 加载插件库时,发生错误
|
||||
Error/NetworkErrorAlert: `<h2>''网络错误''</h2>与服务器的连缐似乎已中断。这可能表示您的网络连缐有问题。请尝试恢复网路连缐才能继续。<br><br>''恢复连缐时,所有未保存的更改,将自动同步''。`
|
||||
Error/PutEditConflict: 服务器上的文件已更改
|
||||
Error/PutForbidden: 没有权限
|
||||
@@ -67,8 +67,8 @@ Manager/Item/Tools: 工具
|
||||
Manager/Item/WikifiedText: Wikified 文字
|
||||
MissingTiddler/Hint: 佚失条目 "<$text text=<<currentTiddler>>/>" - 点击 {{||$:/core/ui/Buttons/edit}} 可创建此条目
|
||||
No: 否
|
||||
OfficialPluginLibrary: ~TiddlyWiki 官方插件程式库
|
||||
OfficialPluginLibrary/Hint: 此为在 tiddlywiki.com 的 ~TiddlyWiki 官方插件程式库。由核心团队维护的插件、主题和语言包。
|
||||
OfficialPluginLibrary: ~TiddlyWiki 官方插件库
|
||||
OfficialPluginLibrary/Hint: 此为在 tiddlywiki.com 的 ~TiddlyWiki 官方插件库。由核心团队维护的插件、主题和语言包。
|
||||
PageTemplate/Description: 默认的 ~Tiddlywiki 布局
|
||||
PageTemplate/Name: 默认的 ~PageTemplate
|
||||
PluginReloadWarning: 请保存 {{$:/core/ui/Buttons/save-wiki}} 并刷新页面 {{$:/core/ui/Buttons/refresh}} ,使 ~JavaScript 插件的更改生效
|
||||
@@ -95,5 +95,5 @@ TagManager/Icons/None: 无
|
||||
TagManager/Info/Heading: 信息
|
||||
TagManager/Tag/Heading: 标签
|
||||
Tiddler/DateFormat: YYYY年0MM月0DD日 0hh:0mm
|
||||
UnsavedChangesWarning: 在此 TiddlyWiki 您有尚未保存的变更
|
||||
UnsavedChangesWarning: 在此 TiddlyWiki 您有尚未保存的变动
|
||||
Yes: 是
|
||||
|
||||
@@ -67,6 +67,8 @@ More/Caption: 更多
|
||||
More/Hint: 更多動作
|
||||
NewHere/Caption: 新增子條目
|
||||
NewHere/Hint: 建立一個標籤為此條目名稱的新條目
|
||||
NetworkActivity/Caption: 網路活動
|
||||
NetworkActivity/Hint: 取消所有網路活動
|
||||
NewJournal/Caption: 新增日誌
|
||||
NewJournal/Hint: 建立一個新的日誌條目
|
||||
NewJournalHere/Caption: 新增子日誌
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user