From 4bd4344b71e9459b2d50e29a354915a4eb894e6b Mon Sep 17 00:00:00 2001 From: Andrew Gioia Date: Tue, 2 May 2017 17:13:35 -0400 Subject: [PATCH] URLs are now rewritten when an icon is clicked --- icons.html | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/icons.html b/icons.html index bb3182e..f9ebdb0 100644 --- a/icons.html +++ b/icons.html @@ -78,8 +78,8 @@
Seventh Edition (7ed)
-
- Eigth Edition (8ed) +
+ Eighth Edition (8ed)
Ninth Edition (9ed) @@ -766,6 +766,10 @@ // show the modal $( '#overlay' ).show(); $( '#modal' ).show(); + + // update the url query string + var newurl = window.location.origin + window.location.pathname + '?icon='+icon; + window.history.pushState( {path:newurl}, '', newurl ); } // toggle rarity controls @@ -785,6 +789,7 @@ // close modal button $( '#closeModal' ).on( 'click', function( e ) { $( '#overlay' ).hide(); + $( '#toggleGradient' ).prop( 'checked', false ); $( '#modal' ).hide(); });