1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-12-24 00:50:28 +00:00

Export transliteration pairs

Just in case plugins want to use them
This commit is contained in:
Jermolene 2017-11-10 14:37:31 +00:00
parent c4e2793b06
commit b4ec32ca70

View File

@ -17,7 +17,7 @@ Transliterate string to ASCII
(Some pairs taken from http://semplicewebsites.com/removing-accents-javascript)
*/
var transliterationPairs = {
exports.transliterationPairs = {
"Á":"A",
"Ă":"A",
"Ắ":"A",
@ -912,7 +912,7 @@ var transliterationPairs = {
exports.transliterate = function(str) {
return str.replace(/[^A-Za-z0-9\[\] ]/g,function(ch) {
return transliterationPairs[ch] || ch
return exports.transliterationPairs[ch] || ch
});
};