mirror of
https://github.com/dawidd6/action-send-mail.git
synced 2024-12-28 03:53:05 +07:00
2095e6ffe3
Co-authored-by: Dawid Dziurla <dawidd0811@gmail.com>
16 lines
529 B
JavaScript
16 lines
529 B
JavaScript
/**
|
|
* Swap back in all the special characters we've hidden.
|
|
*/
|
|
showdown.subParser('unescapeSpecialChars', function (text, options, globals) {
|
|
'use strict';
|
|
text = globals.converter._dispatch('unescapeSpecialChars.before', text, options, globals);
|
|
|
|
text = text.replace(/¨E(\d+)E/g, function (wholeMatch, m1) {
|
|
var charCodeToReplace = parseInt(m1);
|
|
return String.fromCharCode(charCodeToReplace);
|
|
});
|
|
|
|
text = globals.converter._dispatch('unescapeSpecialChars.after', text, options, globals);
|
|
return text;
|
|
});
|