mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-11-22 10:14:51 +00:00
Adds $tw.utils.decodeURISafe and $tw.utils.decodeURIComponentSafe (#5999)
* call self.displayError
* Revert "call self.displayError"
This reverts commit 5d599aa979.
* fixes decodeURI & decodeURIComponent
This commit is contained in:
@@ -149,7 +149,7 @@ function convertNodes(remarkableTree, isStartOfInline) {
|
||||
out.push({
|
||||
type: "link",
|
||||
attributes: {
|
||||
to: { type: "string", value: decodeURI(currentNode.href.substr(1)) }
|
||||
to: { type: "string", value: $tw.utils.decodeURISafe(currentNode.href.substr(1)) }
|
||||
},
|
||||
children: children
|
||||
});
|
||||
@@ -180,7 +180,7 @@ function convertNodes(remarkableTree, isStartOfInline) {
|
||||
type: "image",
|
||||
attributes: {
|
||||
tooltip: { type: "string", value: currentNode.alt },
|
||||
source: { type: "string", value: decodeURIComponent(currentNode.src) }
|
||||
source: { type: "string", value: $tw.utils.decodeURIComponentSafe(currentNode.src) }
|
||||
}
|
||||
});
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user