diff --git a/js/impress.js b/js/impress.js index 44679c4..dce97a2 100644 --- a/js/impress.js +++ b/js/impress.js @@ -1204,7 +1204,8 @@ // Get id from url # by removing `#` or `#/` from the beginning, // so both "fallback" `#slide-id` and "enhanced" `#/slide-id` will work - return byId( window.location.hash.replace( /^#\/?/, "" ) ); + var encoded = window.location.hash.replace( /^#\/?/, "" ); + return byId( decodeURIComponent( encoded ) ); }; // `getUrlParamValue` return a given URL parameter value if it exists diff --git a/src/lib/util.js b/src/lib/util.js index b0d3a93..d9aa38e 100644 --- a/src/lib/util.js +++ b/src/lib/util.js @@ -46,7 +46,8 @@ // Get id from url # by removing `#` or `#/` from the beginning, // so both "fallback" `#slide-id` and "enhanced" `#/slide-id` will work - return byId( window.location.hash.replace( /^#\/?/, "" ) ); + var encoded = window.location.hash.replace( /^#\/?/, "" ); + return byId( decodeURIComponent( encoded ) ); }; // `getUrlParamValue` return a given URL parameter value if it exists