diff options
Diffstat (limited to 'themes/tabi-lean/static/js/decodeMail.min.js')
| -rw-r--r-- | themes/tabi-lean/static/js/decodeMail.min.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/themes/tabi-lean/static/js/decodeMail.min.js b/themes/tabi-lean/static/js/decodeMail.min.js new file mode 100644 index 0000000..2b766a0 --- /dev/null +++ b/themes/tabi-lean/static/js/decodeMail.min.js @@ -0,0 +1 @@ +!function(){"use strict";document.querySelectorAll("[data-encoded-email]").forEach(function(e){var t=function(e){try{var t=[...atob(e)].map(e=>e.charCodeAt(0)),r=new Uint8Array(t.length);return r.set(t),new TextDecoder("utf-8").decode(r)}catch(e){return console.error("Failed to decode Base64 string: ",e),null}}(e.getAttribute("data-encoded-email"));t?e.setAttribute("href","mailto:"+t):e.style.display="none"})}(); |
