mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-23 10:07:19 +00:00
Cleaning up some macro definition wrinkles
This commit is contained in:
parent
306f305a25
commit
d89ea0abd7
@ -381,14 +381,15 @@ WikiStore.prototype.installMacros = function() {
|
||||
params: {
|
||||
},
|
||||
code: {
|
||||
"text/html": this.jsParser.parse("return '5.0.0';"),
|
||||
"text/html": this.jsParser.parse("return utils.htmlEncode('5.0.0');"),
|
||||
"text/plain": this.jsParser.parse("return '5.0.0';")
|
||||
}
|
||||
},
|
||||
tiddler: {
|
||||
cascadeParams: true, // Cascade names of named parameters to following anonymous parameters
|
||||
params: {
|
||||
target: {byName: "default", type: "tiddler", optional: false},
|
||||
"with": {byName: true, type: "text", optional: true, cascade: true}
|
||||
"with": {byName: true, type: "text", optional: true}
|
||||
},
|
||||
code: {
|
||||
"text/html": this.jsParser.parse("return store.renderTiddler('text/html',params.target);"),
|
||||
@ -397,10 +398,9 @@ WikiStore.prototype.installMacros = function() {
|
||||
},
|
||||
info: {
|
||||
params: {
|
||||
|
||||
},
|
||||
code: {
|
||||
"text/html": this.jsParser.parse("return store.tiddlerInfo(tiddler.fields.title);"),
|
||||
"text/html": this.jsParser.parse("return utils.htmlEncode(store.tiddlerInfo(tiddler.fields.title));"),
|
||||
"text/plain": this.jsParser.parse("return store.tiddlerInfo(tiddler.fields.title);")
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user