kopia lustrzana https://github.com/miklobit/TiddlyWiki5
Make static links to tiddlers with spaces work
A bit of a hack - the savetiddlers command should generate filenames betterprint-window-tiddler
rodzic
b1d218065e
commit
0d2ac57ff7
|
@ -70,6 +70,7 @@ LinkWidget.prototype.generate = function() {
|
|||
var wikiLinkTemplateMacro = this.renderer.findMacroDefinition("tw-wikilink-template"),
|
||||
wikiLinkTemplate = wikiLinkTemplateMacro ? wikiLinkTemplateMacro.text.trim() : "$uri_encoded$",
|
||||
wikiLinkText = wikiLinkTemplate.replace("$uri_encoded$",encodeURIComponent(this.to));
|
||||
wikiLinkText = wikiLinkText.replace("$uri_doubleencoded$",encodeURIComponent(encodeURIComponent(this.to)));
|
||||
this.attributes.href = wikiLinkText;
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
title: $:/core/templates/static.template.html
|
||||
type: text/vnd.tiddlywiki-html
|
||||
|
||||
\define tw-wikilink-template() static/$uri_encoded$.html
|
||||
\define tw-wikilink-template() static/$uri_doubleencoded$.html
|
||||
\rules only filteredtranscludeinline transcludeinline
|
||||
<!doctype html>
|
||||
<head>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
title: $:/core/templates/static.tiddler.html
|
||||
|
||||
\define tw-wikilink-template() $uri_encoded$.html
|
||||
\define tw-wikilink-template() $uri_doubleencoded$.html
|
||||
`<!doctype html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
|
|
Ładowanie…
Reference in New Issue