diff --git a/share/static/js/util.js b/share/static/js/util.js index 238ab018b5..89bf4437e4 100644 --- a/share/static/js/util.js +++ b/share/static/js/util.js @@ -818,7 +818,7 @@ jQuery(function() { if ( evt.detail.value ) { for ( const action of evt.detail.value ) { // Need to decode action that is UTF-8 encoded - jQuery.jGrowl(decodeURIComponent(encodeURIComponent(action)), { themeState: 'none' }); + jQuery.jGrowl(decodeURIComponent(escape(action)), { themeState: 'none' }); } const history_container = document.querySelector('.history-container'); @@ -854,7 +854,7 @@ jQuery(function() { }); document.body.addEventListener('titleChanged', function(evt) { - document.title = decodeURIComponent(encodeURIComponent(evt.detail.value)); + document.title = decodeURIComponent(escape(evt.detail.value)); }); document.body.addEventListener('triggerChanged', function(evt) { @@ -865,7 +865,7 @@ jQuery(function() { document.body.addEventListener('widgetTitleChanged', function(evt) { const title = evt.detail.elt.closest('div.titlebox').querySelector('.titlebox-title a'); if ( title ) { - title.innerHTML = decodeURIComponent(encodeURIComponent(evt.detail.value)); + title.innerHTML = decodeURIComponent(escape(evt.detail.value)); } });