diff --git a/.gitignore b/.gitignore
index cc1328d..5d0bbf3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -63,4 +63,5 @@ typings/
 **.sublime-*
 *.bat
 **.zip
-test/
\ No newline at end of file
+test/
+src/wrap/min.js
\ No newline at end of file
diff --git a/dist/harlowe-audio.min.js b/dist/harlowe-audio.min.js
index 57cc95b..944f368 100644
--- a/dist/harlowe-audio.min.js
+++ b/dist/harlowe-audio.min.js
@@ -1,6 +1,6 @@
 ;(function () {
     /**
-     * Harlowe Audio Library, by Chapel, v1.1.2
+     * Harlowe Audio Library, by Chapel, v1.3.0
      *
      * Released under the Unlicense, and dedicated to the public domain.
     **/
@@ -25,6 +25,6 @@
         }
     };
 
-    !function(){"use strict";var e=$(document.createElement("div")).attr("id","audio-container").css("display","none").appendTo(document.body),t=function(t,e){if(window.localStorage)try{t=""+t,"string"!=typeof e&&(e=JSON.stringify(e)),window.localStorage.setItem(t,e)}catch(t){console.error(t)}},o=function(t){if(window.localStorage)try{return t=""+t,window.localStorage.getItem(t)}catch(t){console.error(t)}},n=function(t){if(window.localStorage)try{t=""+t,window.localStorage.removeItem(t)}catch(t){console.error(t)}};function i(e,o){if("object"!=typeof e||"object"!=typeof o)throw new Error("Invalid extension.");Object.keys(o).forEach(function(t){if(void 0!==e[t])throw new Error('Invalid extension: cannot clobber existing property "'+t+'"');e[t]=o[t]})}var a={loaded:[],classes:{},master:{volume:options.startingVol,mute:!1},groups:{playing:[],looping:[],custom:{}},mute:function(t){a.master.mute=!!t,$(document).trigger({type:":master-mute",mute:!!t})},isMuted:function(){return!!a.master.mute},volume:function(t){t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),a.master.volume=t),$(document).trigger({type:":master-volume",volume:t})},getVolume:function(){return a.master.volume},stopAll:function(){c.list.forEach(function(t){t.stop()})},audioPlaying:function(){return!!a.groups.playing.length},savePrefs:function(){t(options.storagekey,a.master)},loadPrefs:function(){var t=o(options.storagekey);t&&"object"==typeof t&&t.hasOwnProperty("volume")&&"number"==typeof t.volume&&t.hasOwnProperty("mute")&&"boolean"==typeof t.volume&&(delete a.master,a.master=t)},clearPrefs:function(){n(options.storagekey)}},r={track:[":available",":loaded",":play",":stop",":mute",":volume"],master:[":master-mute",":master-volume"]},u={aac:"audio/aac",caf:"audio/x-caf","x-caf":"audio/x-caf",mp3:'audio/mpeg; codecs="mp3"',mpeg:'audio/mpeg; codecs="mp3"',m4a:"audio/mp4",mp4:"audio/mp4","x-m4a":"audio/mp4","x-mp4":"audio/mp4",oga:"audio/ogg",ogg:"audio/ogg",opus:'audio/ogg; codecs="opus"',wav:"audio/wav",wave:"audio/wav",weba:"audio/webm",webm:"audio/webm"};function s(t){throw new Error(t)}function c(t,e,o){this instanceof c||s("Track: called without `new` operator"),t||s("Track: no id specified"),"string"!=typeof t&&s("Track: track id is not a string"),(!e||Array.isArray(e)&&!e.length)&&s("Track: no sources specified"),o&&(e=[].slice.call(arguments).slice(1));var i=$(document.createElement("audio"));e.forEach(function(t){var e,o,n;$(document.createElement("source")).attr({src:t,type:(e=t,o=e.split("."),n=o[o.length-1],n.includes("?")&&(n=n.split("?")[0]),n=n.toLowerCase().trim(),Object.keys(u).includes(n)||s('Track: unsupported file type "'+n+'"'),u[n])}).appendTo(i)}),i.attr({"data-track":"id","data-volume":1,"data-mute":!1}).one("canplay",function(){a.loaded.push(t)}),options.preload&&i.attr("preload","auto"),i[0].volume=1*a.master.volume,this.id=t,this.$el=i,this.unwrap=i[0],this.sources=e}c.list=[],c.is=function(t){return t instanceof c},c.has=function(e){return c.list.some(function(t){return t.id===e})},c.emit=function(t,e){$(document).trigger({type:t,track:e}),e.emit(t)},c.add=function(t){var e=new c(t,[].slice.call(arguments).slice(1));return c.list.push(e),e.$el.on("canplay",function(){c.emit(":available",e)}),e.$el.on("canplaythrough",function(){c.emit(":loaded",e)}),e.attach(),e},c.renew=function(){c.list.forEach(function(t){t.mute(t.isMuted()),t.volume(t.getVolume())})},c.getIdx=function(e){return c.list.findIndex(function(t){return t.id===e})},c.get=function(e){return c.list.find(function(t){return t.id===e})},c.extend=function(t){i(c,t)},c.extendPrototype=function(t){i(c.prototype,t)},c.removeFromDOM=function(t){"string"==typeof t&&(t=c.get(t)),t&&c.is(t)?t.unattach():e.remove()},c.prototype={constructor:c,emit:function(t){this.$el.trigger({type:t,track:this})},clone:function(){return new c(this.id,this.sources)},isAttached:function(){return $.contains(e[0],this.unwrap)},attach:function(){return this.isAttached()||this.$el.appendTo(e),this},unattach:function(){return this.isAttached()&&this.$el.remove(),this},isPlaying:function(){return!this.unwrap.paused},play:function(){var t=this;return this.unwrap.play(),c.emit(":play",this),this.$el.on("ended",function(){t.unwrap.loop||(t.unwrap.currentTime=0,c.emit(":stop",t))}),this},playWhenPossible:function(){var e=this;return this.unwrap.play().then(function(){c.emit(":play",e),e.$el.on("ended",function(){e.unwrap.loop||(e.unwrap.currentTime=0,c.emit(":stop",e))})},function(t){$(document).one("click mousedown keydown touchstart",function(){e.play()})}).catch(function(t){console.error(t)}),this},forcePlay:function(){var t=this,e=$(document.createElement("a")).css("display","none").appendTo(document.body).on("click",function(){t.play()});setTimeout(function(){e.trigger("click")},100)},pause:function(){return this.unwrap.pause(),c.emit(":pause",this),this},stop:function(){return this.unwrap.pause(),this.unwrap.currentTime=0,c.emit(":stop",this),this},mute:function(t){return t=!!t,this.$el.attr("data-mute",t),a.master.mute?this.unwrap.muted=!0:this.unwrap.muted=t,c.emit(":mute",this),this},isMuted:function(){var t=this.$el.attr("data-mute");return"boolean"==typeof t?t:"false"!==t},toggleMute:function(){return this.mute(!this.isMuted()),this},volume:function(t){return t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),this.$el.attr("data-volume",t),this.unwrap.volume=t*a.master.volume),c.emit(":volume",this),this},getVolume:function(){return Number(this.$el.attr("data-volume"))},addToGroup:function(t,e){var o=this,n=e?a.groups.custom[t]:a.groups[t];return n.some(function(t){return o.id===t.id})||n.push(this),this},removeFromGroup:function(t,e){var o=this,n=e?a.groups.custom[t]:a.groups[t],i=n.findIndex(function(t){return t.id&&t.id===o.id});return n.splice(i,1),this},loop:function(t){return this.unwrap.loop=!!t,this.unwrap.loop?this.addToGroup("looping"):this.removeFromGroup("looping"),this},isLooping:function(){return!!this.unwrap.loop},toggleLoop:function(){return this.loop(!this.isLooping()),this},seek:function(t){return t<0?t=this.unwrap.duration-t:t>this.unwrap.duration&&(t=this.unwrap.duration),this.unwrap.currentTime=t,this},fadeIn:function(t){var e=this;t=t||1;var o=this.getVolume();return this.volume(0),this.play(),this.$el.animate({volume:o*a.master.volume},1e3*t,function(){e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeOut:function(t){t=t||1;var e=this,o=this.getVolume();return this.$el.animate({volume:0},1e3*t,function(){e.stop(),e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeTo:function(t,e){var o=this;if(t=t||1,e=Number(e),!Number.isNaN(e))return 1<e?e=1:e<0&&(e=0),this.$el.animate({volume:e*a.master.volume},1e3*t,function(){o.volume(e),c.emit(":volume",o),c.emit(":fade",o)}),this;alert("ivalid volume level")},delay:function(t,e){var o=this;"function"==typeof e&&(t=Number(t),(Number.isNaN(t)||t<0)&&(t=0),setTimeout(function(){e.call(o,o,t)},t))},on:function(t,e){return e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),r.track.includes(t)?void this.$el.on(t,e):(console.error("<track>.on() -> invalid event type"),this)):(console.error("<track>.on() -> invalid callback"),this)},one:function(){return cb&&"function"==typeof cb?(type=type.trim().toLowerCase(),":"!==type[0]&&(type=":"+type),r.track.includes(type)?void this.$el.one(type,cb):(console.error("<track>.one() -> invalid event type"),this)):(console.error("<track>.one() -> invalid callback"),this)}};var l=r.track.concat(r.master);function p(t,e){if(!(this instanceof p))return new p(t,e);this.id=t,this.tracks=e.map(function(t){return c.get(t)}),this.looping=!1,this.current="",this.playing=!1}a.on=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).on(t,e):console.error("Chapel.Audio.on() -> invalid event type")):console.error("Chapel.Audio.on() -> invalid callback")},a.one=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).one(t,e):console.error("Chapel.Audio.one() -> invalid event type")):console.error("Chapel.Audio.one() -> invalid callback")},a.on(":master-mute",c.renew),a.on(":master-volume",c.renew),options.persistPrefs&&(a.on(":master-mute",a.savePrefs),a.on(":master-volume",a.savePrefs)),a.on(":play",function(t){t.track.addToGroup("playing")}),a.on(":stop",function(t){t.track.removeFromGroup("playing")}),options.muteOnBlur&&$(window).on("blur",function(){a.isMuted()||(a.mute(!0),$(window).one("focus",function(){a.mute(!1)}))}),a.classes.Track=c,a.newTrack=c.add,a.track=c.get,a.createGroup=function(t,e,o){var n,i,r;n=o?[].slice.call(arguments).slice(1):e,i=t,(r=n)&&Array.isArray(r)||(r=[]),a.groups.custom[i]=r.map(function(t){return c.get(t)})},a.group=function(t){if(!(this instanceof a.group))return new a.group(t);Object.keys(a.groups.custom).includes(t)?this.members=a.groups.custom[t]:this.members=a.groups[t],Array.isArray(this.members)||(this.members=[],console.error('Could not find members for track group "'+t+'"!'))},a.group.is=function(t){return this instanceof a.group},a.group.runOnAll=function(t,e,o){t.members.forEach(function(t){t[e].apply(t,o&&Array.isArray(o)?o:[])})},a.group.extend=function(t){i(a.group,t)},a.group.extendPrototype=function(t){i(a.group.prototype,t)},a.group.prototype={constructor:a.group,run:function(t,e,o){null!=o&&(e=[].slice.call(arguments).slice(1)),c.prototype.hasOwnProperty(t)&&a.group.runOnAll(this,t,e)},play:function(){return this.run("play"),this},pause:function(){return this.run("pause"),this},stop:function(){return this.run("stop"),this},mute:function(t){return this.run("mute",[t]),this},volume:function(t){return this.run("volume",[t]),this},loop:function(t){return this.run("loop",[t]),this}},p.list={},p.is=function(t){return t instanceof p},p.add=function(t,e,o){return o&&(e=[].slice.call(arguments).slice(1)),p.list[t]=new p(t,e),p.list[t]},p.extend=function(t){i(p,t)},p.extendPrototype=function(t){i(p.prototype,t)},p.prototype={constructor:p,clone:function(){return new p(this.id,this.tracks.map(function(t){return t.id}))},shuffle:function(){var t,e,o,n=this.tracks;for(o=n.length-1;0<o;o--)t=Math.floor(Math.random()*(o+1)),e=n[o],n[o]=n[t],n[t]=e;return this.tracks=n,this},random:function(){return this.tracks[Math.floor(Math.random()*this.tracks.length)]},isPlaying:function(){return this.playing},play:function(t){var e=this;if((t=t||(e.current?e.tracks.findIndex(function(t){return t.id===e.current}):0))>=e.tracks.length&&e.looping)t=0;else if(t>=e.tracks.length)return e.current="",void(e.playing=!1);var o=e.tracks[t],n=o.isLooping();return o.loop(!1),o.play(),e.playing=!0,setTimeout(function(){o.isPlaying()||(e.playing=!1)},20),e.current=o.id,o.$el.one("ended.playlist",function(){t++,o.loop(n),e.play(t)}),e},loop:function(t){return this.looping=!!t,this},stop:function(){var t=c.get(this.current);return t.stop(),t.$el.off(".playlist"),this.current="",this.playing=!1,this},pause:function(){return c.get(this.current).pause(),this.playing=!1,this}},a.classes.Playlist=p,a.createPlaylist=p.add,a.playlist=function(t){return p.list[t]||null},a.extend=function(t){i(a,t)},a.extendTrack=c.extend,a.extendTrackProto=c.extendPrototype,a.extendGroup=a.group.extend,a.extendGroupProto=a.group.extendPrototype,a.extendPlaylist=p.extend,a.extendPlaylistProto=p.extendPrototype,window.Chapel=window.Chapel||{},window.Chapel.Audio=a,options.persistPrefs&&a.loadPrefs()}(),function(){"use strict";if(options.controls.show){var t=$(document.createElement("div")).attr("id","story-menu").css("display","none"),e=$(document.createElement("span")).attr("id","vol-title").append("Volume");options.controls.volumeDisplay||e.css("display","none");var o=$(document.createElement("input")).attr({id:"audio-volume",type:"range",min:1,max:99,step:1,title:"Volume"}),n=Math.trunc(100*window.Chapel.Audio.master.volume);n<0?n=0:100<n&&(n=100),o.attr("value",n);var i=function(t){void 0===t&&(t=o.val()),e.empty().append("Volume "+t)};o.on("input",function(){window.Chapel.Audio.volume($(this).val()/100),i($(this).val())});var r=$(document.createElement("tw-link")).attr({id:"audio-mute",title:"Mute"}).append("Mute <span></span>").on("click",function(t){t.preventDefault(),$(this).toggleClass("muted"),Chapel.Audio.mute(!Chapel.Audio.isMuted())});Chapel.Audio.isMuted()&&r.addClass("muted");var a=$(document.createElement("tw-link")).attr("id","audio-panel-toggle").on("click",function(t){t.preventDefault(),u.toggleClass("closed")}),u=$(document.createElement("div")).attr("id","audio-controls").append(t,e,o,r,a).appendTo(document.body);options.controls.startClosed&&u.addClass("closed"),window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.controls={$panel:u,$volume:o,$mute:r,$user:t,close:function(){u.addClass("closed")},open:function(){u.removeClass("closed")},toggle:function(){u.toggleClass("closed")},hide:function(){u.css("display","none")},show:function(){u.css("display","block")},updateVolume:i}}}(),function(t){(jQuery.browser=jQuery.browser||{}).mobile=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4))}(navigator.userAgent||navigator.vendor||window.opera),function(){"use strict";var e=State,t=$(document.createElement("div")).attr("id","audio-overlay").css("display","none").appendTo(document.body);function o(){t.css("display","block").append('<div class="lds-ring"><div></div><div></div><div></div><div></div></div>')}function u(){t.fadeOut(function(){t.empty()})}window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.loadScreen={show:o,dismiss:u,kill:function(){$("#audio-overlay").remove()}},window.Chapel.Audio.$overlay=t,window.Chapel.Audio.preload=function(){if(!(e.pastLength||e.futureLength||$.browser.mobile)){$(document).ready(function(){o()});var i=100+options.loadDelay,t=Chapel.Audio.classes.Track.list,r=Chapel.Audio.loaded;if(t.length){var a=t.map(function(t){return t.id});options.forceDismiss&&setTimeout(function(){u()},options.loadLimit.total),function t(){if(a.length){var e=a.shift();if(r.includes(e))t();else{var o=Chapel.Audio.classes.Track.get(e);if(o.unwrap.readyState<2){var n=!1;o.$el.one("canplay",function(){t(),n=!0}),setTimeout(function(){n||(o.$el.off("canplay"),t())},options.loadLimit.track)}else r.includes(e)||r.push(e),t()}}else setTimeout(u,i)}()}else setTimeout(u,i)}}}(),function(){"use strict";options.globalA&&void 0===window.A&&(window.A=window.Chapel.Audio),$(document).on("unload",function(){window.Chapel.Audio.savePrefs()}),Chapel.Audio.classes.Track.renew(),Chapel.Audio.controls&&Chapel.Audio.controls.updateVolume()}(),function(){"use strict";if(options.controls.show){var u=Engine,s=Chapel.Audio.controls.$user,t=function(){return"none"!==s.css("display")},c=function(){return t()||s.css("display","block"),s},e=function(){return t()&&s.css("display","none"),s};Chapel.Audio.menu={hide:e,show:c,isShown:t,links:{add:function(t,e,o){var n,i;if(!t||"string"!=typeof t){var r="undefined";return alert(r),void console.error(r)}o||"function"!=typeof e?(e&&"string"==typeof e&&(n=e),o&&"function"==typeof o&&(i=o)):(i=e,n=null);var a=$(document.createElement("tw-link")).append(t).attr({tabindex:"0",name:t.toLowerCase().trim()}).on("click",function(){n&&u.goToPassage(n),i&&i()}).addClass("story-menu").appendTo(s);return c(),a},clear:function(){return s.empty(),e()},hide:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').addClass("hide")},show:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').removeClass("hide")},toggle:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').toggleClass("hide")},remove:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').remove()}}}}}(),function(){"use strict";var n=window.prompt;window.prompt=function(){var t,e,o=n.apply(null,[].slice.call(arguments));return t=o,e=(new DOMParser).parseFromString(t,"text/html"),Array.from(e.body.childNodes).some(function(t){return 1===t.nodeType})?o.replace(/[<>]/g,""):o}}();
+    !function(){"use strict";var t,e=$("tw-storydata");window.Chapel=window.Chapel||{},window.Chapel.Get={isHarlowe3OrLater:3<=(t=e.attr("format-version").split(".")[0],t=Number(t),Number.isNaN(t)&&(t=3),t<1&&(t=3),t),storyTitle:e.attr("name"),IFID:e.attr("ifid")},options.storagekey=options.storagekey+"-"+Chapel.Get.IFID+"-{"+Chapel.Get.storyTitle+"}"}(),function(){"use strict";var e=$(document.createElement("div")).attr("id","audio-container").css("display","none").appendTo(document.body),t=function(t,e){if(window.localStorage)try{t=""+t,"string"!=typeof e&&(e=JSON.stringify(e)),window.localStorage.setItem(t,e)}catch(t){console.error(t)}},o=function(t){if(window.localStorage)try{return t=""+t,window.localStorage.getItem(t)}catch(t){console.error(t)}},n=function(t){if(window.localStorage)try{t=""+t,window.localStorage.removeItem(t)}catch(t){console.error(t)}};function i(e,o){if("object"!=typeof e||"object"!=typeof o)throw new Error("Invalid extension.");Object.keys(o).forEach(function(t){if(void 0!==e[t])throw new Error('Invalid extension: cannot clobber existing property "'+t+'"');e[t]=o[t]})}var r={loaded:[],classes:{},master:{volume:options.startingVol,mute:!1},groups:{playing:[],looping:[],custom:{}},mute:function(t){r.master.mute=!!t,$(document).trigger({type:":master-mute",mute:!!t})},isMuted:function(){return!!r.master.mute},volume:function(t){t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),r.master.volume=t),$(document).trigger({type:":master-volume",volume:t})},getVolume:function(){return r.master.volume},stopAll:function(){c.list.forEach(function(t){t.stop()})},audioPlaying:function(){return!!r.groups.playing.length},savePrefs:function(){t(options.storagekey,r.master)},loadPrefs:function(){var t=o(options.storagekey);t&&"object"==typeof t&&t.hasOwnProperty("volume")&&"number"==typeof t.volume&&t.hasOwnProperty("mute")&&"boolean"==typeof t.volume&&(delete r.master,r.master=t)},clearPrefs:function(){n(options.storagekey)}},a={track:[":available",":loaded",":play",":stop",":mute",":volume"],master:[":master-mute",":master-volume"]},s={aac:"audio/aac",caf:"audio/x-caf","x-caf":"audio/x-caf",mp3:'audio/mpeg; codecs="mp3"',mpeg:'audio/mpeg; codecs="mp3"',m4a:"audio/mp4",mp4:"audio/mp4","x-m4a":"audio/mp4","x-mp4":"audio/mp4",oga:"audio/ogg",ogg:"audio/ogg",opus:'audio/ogg; codecs="opus"',wav:"audio/wav",wave:"audio/wav",weba:"audio/webm",webm:"audio/webm"};function u(t){throw new Error(t)}function c(t,e,o){this instanceof c||u("Track: called without `new` operator"),t||u("Track: no id specified"),"string"!=typeof t&&u("Track: track id is not a string"),e&&(!Array.isArray(e)||e.length)||u("Track: no sources specified"),o&&(e=[].slice.call(arguments).slice(1));var n=$(document.createElement("audio"));e.forEach(function(t){$(document.createElement("source")).attr({src:t,type:function(t){var e=t.split("."),o=e[e.length-1];return o.includes("?")&&(o=o.split("?")[0]),o=o.toLowerCase().trim(),Object.keys(s).includes(o)||u('Track: unsupported file type "'+o+'"'),s[o]}(t)}).appendTo(n)}),n.attr({"data-track":"id","data-volume":1,"data-mute":!1}).one("canplay",function(){r.loaded.push(t)}),options.preload&&n.attr("preload","auto"),n[0].volume=1*r.master.volume,this.id=t,this.$el=n,this.unwrap=n[0],this.sources=e}c.list=[],c.is=function(t){return t instanceof c},c.has=function(e){return c.list.some(function(t){return t.id===e})},c.emit=function(t,e){$(document).trigger({type:t,track:e}),e.emit(t)},c.add=function(t){var e=new c(t,[].slice.call(arguments).slice(1));return c.list.push(e),e.$el.on("canplay",function(){c.emit(":available",e)}),e.$el.on("canplaythrough",function(){c.emit(":loaded",e)}),e.attach(),e},c.renew=function(){c.list.forEach(function(t){t.mute(t.isMuted()),t.volume(t.getVolume())})},c.getIdx=function(e){return c.list.findIndex(function(t){return t.id===e})},c.get=function(e){return c.list.find(function(t){return t.id===e})},c.extend=function(t){i(c,t)},c.extendPrototype=function(t){i(c.prototype,t)},c.removeFromDOM=function(t){"string"==typeof t&&(t=c.get(t)),t&&c.is(t)?t.unattach():e.remove()},c.prototype={constructor:c,emit:function(t){this.$el.trigger({type:t,track:this})},clone:function(){return new c(this.id,this.sources)},isAttached:function(){return $.contains(e[0],this.unwrap)},attach:function(){return this.isAttached()||this.$el.appendTo(e),this},unattach:function(){return this.isAttached()&&this.$el.remove(),this},isPlaying:function(){return!this.unwrap.paused},play:function(){var t=this;return this.unwrap.play(),c.emit(":play",this),this.$el.on("ended",function(){t.unwrap.loop||(t.unwrap.currentTime=0,c.emit(":stop",t))}),this},playWhenPossible:function(){var e=this;return this.unwrap.play().then(function(){c.emit(":play",e),e.$el.on("ended",function(){e.unwrap.loop||(e.unwrap.currentTime=0,c.emit(":stop",e))})},function(t){$(document).one("click mousedown keydown touchstart",function(){e.play()})}).catch(function(t){console.error(t)}),this},forcePlay:function(){var t=this,e=$(document.createElement("a")).css("display","none").appendTo(document.body).on("click",function(){t.play()});setTimeout(function(){e.trigger("click")},100)},pause:function(){return this.unwrap.pause(),c.emit(":pause",this),this},stop:function(){return this.unwrap.pause(),this.unwrap.currentTime=0,c.emit(":stop",this),this},mute:function(t){return t=!!t,this.$el.attr("data-mute",t),r.master.mute?this.unwrap.muted=!0:this.unwrap.muted=t,c.emit(":mute",this),this},isMuted:function(){var t=this.$el.attr("data-mute");return"boolean"==typeof t?t:"false"!==t},toggleMute:function(){return this.mute(!this.isMuted()),this},volume:function(t){return t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),this.$el.attr("data-volume",t),this.unwrap.volume=t*r.master.volume),c.emit(":volume",this),this},getVolume:function(){return Number(this.$el.attr("data-volume"))},addToGroup:function(t,e){var o=this,n=e?r.groups.custom[t]:r.groups[t];return n.some(function(t){return o.id===t.id})||n.push(this),this},removeFromGroup:function(t,e){var o=this,n=e?r.groups.custom[t]:r.groups[t],i=n.findIndex(function(t){return t.id&&t.id===o.id});return n.splice(i,1),this},loop:function(t){return this.unwrap.loop=!!t,this.unwrap.loop?this.addToGroup("looping"):this.removeFromGroup("looping"),this},isLooping:function(){return!!this.unwrap.loop},toggleLoop:function(){return this.loop(!this.isLooping()),this},seek:function(t){return t<0?t=this.unwrap.duration-t:t>this.unwrap.duration&&(t=this.unwrap.duration),this.unwrap.currentTime=t,this},fadeIn:function(t){var e=this;t=t||1;var o=this.getVolume();return this.volume(0),this.play(),this.$el.animate({volume:o*r.master.volume},1e3*t,function(){e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeOut:function(t){t=t||1;var e=this,o=this.getVolume();return this.$el.animate({volume:0},1e3*t,function(){e.stop(),e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeTo:function(t,e){var o=this;if(t=t||1,e=Number(e),!Number.isNaN(e))return 1<e?e=1:e<0&&(e=0),this.$el.animate({volume:e*r.master.volume},1e3*t,function(){o.volume(e),c.emit(":volume",o),c.emit(":fade",o)}),this;alert("ivalid volume level")},delay:function(t,e){var o=this;"function"==typeof e&&(t=Number(t),(Number.isNaN(t)||t<0)&&(t=0),setTimeout(function(){e.call(o,o,t)},t))},on:function(t,e){return e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),a.track.includes(t)?void this.$el.on(t,e):(console.error("<track>.on() -> invalid event type"),this)):(console.error("<track>.on() -> invalid callback"),this)},one:function(t,e){return e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),a.track.includes(t)?void this.$el.one(t,e):(console.error("<track>.one() -> invalid event type"),this)):(console.error("<track>.one() -> invalid callback"),this)}};var l=a.track.concat(a.master);function d(t,e){if(!(this instanceof d))return new d(t,e);this.id=t,this.tracks=e.map(function(t){return c.get(t)}),this.looping=!1,this.current="",this.playing=!1}r.on=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).on(t,e):console.error("Chapel.Audio.on() -> invalid event type")):console.error("Chapel.Audio.on() -> invalid callback")},r.one=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).one(t,e):console.error("Chapel.Audio.one() -> invalid event type")):console.error("Chapel.Audio.one() -> invalid callback")},r.on(":master-mute",c.renew),r.on(":master-volume",c.renew),options.persistPrefs&&(r.on(":master-mute",r.savePrefs),r.on(":master-volume",r.savePrefs)),r.on(":play",function(t){t.track.addToGroup("playing")}),r.on(":stop",function(t){t.track.removeFromGroup("playing")}),options.muteOnBlur&&$(window).on("blur",function(){r.isMuted()||(r.mute(!0),$(window).one("focus",function(){r.mute(!1)}))}),r.classes.Track=c,r.newTrack=c.add,r.track=c.get,r.createGroup=function(t,e,o){!function(t,e){e&&Array.isArray(e)||(e=[]),r.groups.custom[t]=e.map(function(t){return c.get(t)})}(t,o?[].slice.call(arguments).slice(1):e)},r.group=function(t){if(!(this instanceof r.group))return new r.group(t);Object.keys(r.groups.custom).includes(t)?this.members=r.groups.custom[t]:this.members=r.groups[t],Array.isArray(this.members)||(this.members=[],console.error('Could not find members for track group "'+t+'"!'))},r.group.is=function(t){return this instanceof r.group},r.group.runOnAll=function(t,e,o){t.members.forEach(function(t){t[e].apply(t,o&&Array.isArray(o)?o:[])})},r.group.extend=function(t){i(r.group,t)},r.group.extendPrototype=function(t){i(r.group.prototype,t)},r.group.prototype={constructor:r.group,run:function(t,e,o){null!=o&&(e=[].slice.call(arguments).slice(1)),c.prototype.hasOwnProperty(t)&&r.group.runOnAll(this,t,e)},play:function(){return this.run("play"),this},pause:function(){return this.run("pause"),this},stop:function(){return this.run("stop"),this},mute:function(t){return this.run("mute",[t]),this},volume:function(t){return this.run("volume",[t]),this},loop:function(t){return this.run("loop",[t]),this}},d.list={},d.is=function(t){return t instanceof d},d.add=function(t,e,o){return o&&(e=[].slice.call(arguments).slice(1)),d.list[t]=new d(t,e),d.list[t]},d.extend=function(t){i(d,t)},d.extendPrototype=function(t){i(d.prototype,t)},d.prototype={constructor:d,clone:function(){return new d(this.id,this.tracks.map(function(t){return t.id}))},shuffle:function(){var t,e,o,n=this.tracks;for(o=n.length-1;0<o;o--)t=Math.floor(Math.random()*(o+1)),e=n[o],n[o]=n[t],n[t]=e;return this.tracks=n,this},random:function(){return this.tracks[Math.floor(Math.random()*this.tracks.length)]},isPlaying:function(){return this.playing},play:function(t){var e=this;if((t=t||(e.current?e.tracks.findIndex(function(t){return t.id===e.current}):0))>=e.tracks.length&&e.looping)t=0;else if(t>=e.tracks.length)return e.current="",void(e.playing=!1);var o=e.tracks[t],n=o.isLooping();return o.loop(!1),o.play(),e.playing=!0,setTimeout(function(){o.isPlaying()||(e.playing=!1)},20),e.current=o.id,o.$el.one("ended.playlist",function(){t++,o.loop(n),e.play(t)}),e},loop:function(t){return this.looping=!!t,this},stop:function(){var t=c.get(this.current);return t.stop(),t.$el.off(".playlist"),this.current="",this.playing=!1,this},pause:function(){return c.get(this.current).pause(),this.playing=!1,this}},r.classes.Playlist=d,r.createPlaylist=d.add,r.playlist=function(t){return d.list[t]||null},r.extend=function(t){i(r,t)},r.extendTrack=c.extend,r.extendTrackProto=c.extendPrototype,r.extendGroup=r.group.extend,r.extendGroupProto=r.group.extendPrototype,r.extendPlaylist=d.extend,r.extendPlaylistProto=d.extendPrototype,window.Chapel=window.Chapel||{},window.Chapel.Audio=r,options.persistPrefs&&r.loadPrefs()}(),function(){"use strict";if(options.controls.show){var t=$(document.createElement("div")).attr("id","story-menu").css("display","none"),e=$(document.createElement("span")).attr("id","vol-title").append("Volume");options.controls.volumeDisplay||e.css("display","none");var o=$(document.createElement("input")).attr({id:"audio-volume",type:"range",min:1,max:99,step:1,title:"Volume"}),n=Math.trunc(100*window.Chapel.Audio.master.volume);n<0?n=0:100<n&&(n=100),o.attr("value",n);var i=function(t){void 0===t&&(t=o.val()),e.empty().append("Volume "+t)};o.on("input",function(){window.Chapel.Audio.volume($(this).val()/100),i($(this).val())});var r=$(document.createElement("tw-link")).attr({id:"audio-mute",title:"Mute"}).append("Mute <span></span>").on("click",function(t){t.preventDefault(),$(this).toggleClass("muted"),Chapel.Audio.mute(!Chapel.Audio.isMuted())});Chapel.Audio.isMuted()&&r.addClass("muted");var a=$(document.createElement("tw-link")).attr("id","audio-panel-toggle").on("click",function(t){t.preventDefault(),s.toggleClass("closed")}),s=$(document.createElement("div")).attr("id","audio-controls").append(t,e,o,r,a).appendTo(document.body);options.controls.startClosed&&s.addClass("closed"),window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.controls={$panel:s,$volume:o,$mute:r,$user:t,close:function(){s.addClass("closed")},open:function(){s.removeClass("closed")},toggle:function(){s.toggleClass("closed")},hide:function(){s.css("display","none")},show:function(){s.css("display","block")},updateVolume:i}}}(),function(t){(jQuery.browser=jQuery.browser||{}).mobile=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4))}(navigator.userAgent||navigator.vendor||window.opera),function(){"use strict";var e=State,t=$(document.createElement("div")).attr("id","audio-overlay").css("display","none").appendTo(document.body);function o(){t.css("display","block").append('<div class="lds-ring"><div></div><div></div><div></div><div></div></div>')}function s(){t.fadeOut(function(){t.empty()})}window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.loadScreen={show:o,dismiss:s,kill:function(){$("#audio-overlay").remove()}},window.Chapel.Audio.$overlay=t,window.Chapel.Audio.preload=function(){if(!(e.pastLength||e.futureLength||$.browser.mobile)){$(document).ready(function(){o()});var i=100+options.loadDelay,t=Chapel.Audio.classes.Track.list,r=Chapel.Audio.loaded;if(t.length){var a=t.map(function(t){return t.id});options.forceDismiss&&setTimeout(function(){s()},options.loadLimit.total),function t(){if(a.length){var e=a.shift();if(r.includes(e))t();else{var o=Chapel.Audio.classes.Track.get(e);if(o.unwrap.readyState<2){var n=!1;o.$el.one("canplay",function(){t(),n=!0}),setTimeout(function(){n||(o.$el.off("canplay"),t())},options.loadLimit.track)}else r.includes(e)||r.push(e),t()}}else setTimeout(s,i)}()}else setTimeout(s,i)}}}(),function(){"use strict";var t,e,o=options.storagekey+"_hal_restart_",n=(window.sessionStorage?(t=function(t,e){window.sessionStorage.setItem(o+t,e)},e=function(t){return window.sessionStorage.getItem(o+t)}):(t=function(){},e=function(){},console.warn("Session storage is unavailable...")),{save:t,load:e});window.Chapel.Audio.state={_store:n,saveTracks:function(){var t;try{t=Chapel.Audio.classes.Track.list.map(function(t){return{id:t.id,sources:t.sources}}),t=JSON.stringify(t),n.save("tracks",t)}catch(t){console.error(t.message)}},loadTracks:function(){var t;try{t=(t=n.load("tracks"))&&JSON.parse(t),Array.isArray(t)&&t.length&&t.forEach(function(t){t.id&&t.sources&&!Chapel.Audio.classes.Track.has(t.id)?Chapel.Audio.newTrack.apply(null,[t.id].concat(t.sources)):console.warn("Track reload failed...")})}catch(t){console.error(t.message)}},savePlaylists:function(){var t;try{var o=Chapel.Audio.classes.Playlist.list;t=Object.keys(o).map(function(t){var e={};return e.tracks=o[t].tracks.map(function(t){return t.id}),e.id=o[t].id,e}),t=JSON.stringify(t),n.save("playlists",t)}catch(t){console.error(t.message)}},loadPlaylists:function(){var t;try{(t=(t=n.load("playlists"))&&JSON.parse(t))&&Array.isArray(t)&&t.length&&t.forEach(function(t){t.id&&t.tracks&&Chapel.Audio.createPlaylist(t.id,t.tracks)})}catch(t){console.error(t.message)}},saveGroups:function(){var e;try{e={},Object.keys(Chapel.Audio.groups.custom).forEach(function(t){e[t]=Chapel.Audio.groups.custom[t].map(function(t){return"string"==typeof t?t:t.id})}),e=JSON.stringify(e),n.save("groups",e)}catch(t){console.error(t.message)}},loadGroups:function(){var e;try{(e=(e=n.load("groups"))&&JSON.parse(e))&&"object"==typeof e&&(Object.keys(e).forEach(function(t){e[t].map(function(t){return Chapel.Audio.classes.Track.get(t)})}),Chapel.Audio.groups.custom=e)}catch(t){console.error(t.message)}}}}(),function(){"use strict";options.globalA&&void 0===window.A&&(window.A=window.Chapel.Audio),$(document).on("unload",function(){window.Chapel.Audio.savePrefs()}),Chapel.Audio.classes.Track.renew(),Chapel.Audio.controls&&Chapel.Audio.controls.updateVolume(),Chapel.Get.isHarlowe3OrLater&&($(window).on("unload",function(){Chapel.Audio.state.saveTracks(),Chapel.Audio.state.savePlaylists(),Chapel.Audio.state.saveGroups()}),Chapel.Audio.state.loadTracks(),Chapel.Audio.state.loadPlaylists(),Chapel.Audio.state.loadGroups())}(),function(){"use strict";if(options.controls.show){var s=Engine,u=Chapel.Audio.controls.$user,t=function(){return"none"!==u.css("display")},c=function(){return t()||u.css("display","block"),u},e=function(){return t()&&u.css("display","none"),u};Chapel.Audio.menu={hide:e,show:c,isShown:t,links:{add:function(t,e,o){var n,i;if(!t||"string"!=typeof t){var r="undefined";return alert(r),void console.error(r)}o||"function"!=typeof e?(e&&"string"==typeof e&&(n=e),o&&"function"==typeof o&&(i=o)):(i=e,n=null);var a=$(document.createElement("tw-link")).append(t).attr({tabindex:"0",name:t.toLowerCase().trim()}).on("click",function(){n&&s.goToPassage(n),i&&i()}).addClass("story-menu").appendTo(u);return c(),a},clear:function(){return u.empty(),e()},hide:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').addClass("hide")},show:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').removeClass("hide")},toggle:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').toggleClass("hide")},remove:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').remove()}}}}}(),function(){"use strict";if(options.includeFixes){var e=window.prompt;window.prompt=function(){var t=e.apply(null,[].slice.call(arguments));return function(t){var e=(new DOMParser).parseFromString(t,"text/html");return Array.from(e.body.childNodes).some(function(t){return 1===t.nodeType})}(t)?t.replace(/[<>]/g,""):t}}}();
 
 }());
\ No newline at end of file
diff --git a/docs/API.md b/docs/API.md
index eee93be..3ab5f88 100644
--- a/docs/API.md
+++ b/docs/API.md
@@ -1227,4 +1227,130 @@ Dismisses the loading screen.
 
 Completely removes the loading screen from the DOM.
 
----
\ No newline at end of file
+---
+
+## The Menu API
+
+---
+
+- **the `A.menu.hide()` method**
+
+- Arguments: none.
+
+- Returns: the `#story-menu` element (jQuery).
+
+Hides the story menu portion of the side bar.
+
+---
+
+- **the `A.menu.show()` method**
+
+- Arguments: none.
+
+- Returns: the `#story-menu` element (jQuery).
+
+Shows the story menu portion of the side bar.
+
+---
+
+- **the `A.menu.isShown()` method**
+
+- Arguments: none.
+
+- Returns: boolean.
+
+Returns whether the story menu portion of the side bar is currently visible.
+
+---
+
+- **the `A.menu.links.add(linkText, [passageName], [callback])` method**
+
+- Arguments: 
+    - `linkText`: (string) the text of the link.
+    - `passageName`: (optional) (string) a passage name to navigate to when the link is clicked.
+    - `callback`: (optional) (string) a function to run when the link is clicked.
+
+- Returns: the generated link (jQuery).
+
+This method creates a story menu link. You must pass it text to display or it will raise an error. You can then pass it a passage name to navigate to, a callback function to run on click, both, or neither. If you include both, they must be included in the indicated order.
+
+---
+
+- **the `A.menu.links.clear()` method**
+
+- Arguments: none.
+
+- Returns: the `#story-menu` element (jQuery).
+
+This method removes all of the links from the story menu.
+
+---
+
+- **the `A.menu.links.hide(text)` method**
+
+- Arguments: 
+    - `text`: the text of the link you want to alter.
+
+- Returns: nothing.
+
+This method hides a story menu link. If there are multiple links with the same link text, all of them will be hidden.
+
+---
+
+- **the `A.menu.links.show(text)` method**
+
+- Arguments: 
+    - `text`: the text of the link you want to alter.
+
+- Returns: nothing.
+
+This method shows a hidden story menu link. If there are multiple links with the same link text, all of them will be shown.
+
+---
+
+- **the `A.menu.links.toggle(text)` method**
+
+- Arguments: 
+    - `text`: the text of the link you want to alter.
+
+- Returns: nothing.
+
+This method toggles the visibility a story menu link (hiding it if it's visible, showing it if it is hidden). If there are multiple links with the same link text, all of them will be toggled.
+
+---
+
+- **the `A.menu.links.remove(text)` method**
+
+- Arguments: 
+    - `text`: the text of the link you want to alter.
+
+- Returns: nothing.
+
+This method removes a story menu link. If there are multiple links with the same link text, all of them will be removed. Hidden links can be re-shown later, removed links are gone for good and will need to be recreated via `A.menu.links.add()`.
+
+---
+
+# Events
+
+## List of Track Events
+
+| Event        | Description                                |
+| ---          | ---                                        |
+| `:available` | a track's metadata is loaded               |
+| `:loaded`    | a track can be played from start to finish |
+| `:play`      | a track starts playing                     |
+| `:pause`     | a track is paused                          |
+| `:stop`      | a track reaches the end or is stopped      |
+| `:mute`      | a track is muted or unmuted                |
+| `:volume`    | a track's volume is changed                |
+
+## List of Master Audio Events
+
+| Event            | Description                                 |
+| ---              | ---                                         |
+| `:master-mute`   | the master mute control is muted or unmuted |
+| `:master-volume` | the master volume is changed                |
+
+## Event Objects
+
+Track event objects are given a `track` property, which contains the track instance that triggered the event.
\ No newline at end of file
diff --git a/docs/README.md b/docs/README.md
index f868b49..4d74943 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -5,7 +5,7 @@
 [Complete API Reference](./API.md)
 
 > [!WARNING]
-> If you're using **Harlowe v3.x (or later)**, some updates to the way the engine preserves state via reloads may cause parts of this library to stop functioning correctly when used outside of the Story JavaScript or equivalent; particularly things that need initialized. There is not much I can do to fix this on my end--for now, it's recommended that you define all your tracks and menu links in Story JavaScript, not in `startup`-tagged passages. All other commands, like playing or stopping audio, should continue to work as expected.
+> If you're using **Harlowe v3.x (or later)**, it is strongly recommended that you define tracks, groups, playlists, and menu links in your Story JavaScript area (or equivalent for your compiler) rather than in `startup`-tagged passages.
 
 If you just need some audio and don't need anything too complex, start at [Installation](#installation) and then read some of the [examples](#detailed-examples) to see if what you want to do is covered. If you want anything more complex than that, or if you have grand, complex ideas, you'll need to read the whole thing.
 
@@ -38,7 +38,7 @@ The best place to ask for help if the issue is on your end is [the Twine Q&A](ht
 
 ## Installation
 
-All you need to install this library is the code. There are two ways to get it: [copy and pasting from GitHub](https://github.com/ChapelR/harlowe-audio/tree/master/dist), or [via a Google Drive download](https://drive.google.com/file/d/1ThjHsBDzAwYNLc0p8g_V1fC-dLhBc8EH/view?usp=sharing). If you download the code, be sure to open it and mess with it in a text editor, *not* a word processor. Once you've got the code, you'll need to put in in your project.
+All you need to install this library is the code. Download the most recent version of HAL here, on the [releases page](https://github.com/ChapelR/harlowe-audio/releases). If you download the code, be sure to open it and mess with it in a text editor, *not* a word processor. Once you've got the code, you'll need to put in in your project.
 
 **In Twine 2 (online or standalone)**, copy and paste the code in `harlowe-audio.min.js` into your [Story JavaScript area](https://twinery.org/wiki/twine2:adding_custom_javascript_and_css), and the code in `harlowe-audio.min.css` into your Story Stylesheet area.
 
@@ -192,7 +192,7 @@ To setup a track, use the `A.newTrack()` method, and provide your track a name a
 A.newTrack('piano', 'http://www.kozco.com/tech/piano2.wav');
 ```
 
-~~You can also use a script element in a `startup`-tagged passage:~~ (See warning below.)
+You can also use a script element in a `startup`-tagged passage (though doing so in your Story JavaScript is still strongly recommended):
 ```
 :: audio-init [startup]
 <script>
@@ -201,9 +201,6 @@ A.newTrack('beep', 'audio/beep.mp3');
 </script>
 ```
 
-> [!DANGER]
-> In Harlowe v3.x, you should **always** define your tracks in your Story JavaScript, or your compiler's equivalent script section.
-
 The *sources* of your audio files are urls or paths to the audio resources. These can be relative paths or absolute paths, depending on your needs.
 
 You should try to provide multiple sources to each sound: they'll be the same sound, just in different file formats, to help improve browser support. For example, most browsers can play `.mp3` files just fine, but Chromium users can't without a special plug-in they may not have. But they can play `.ogg` files, but Safari doesn't support `.ogg`...
@@ -233,9 +230,6 @@ A.preload(); // shows a load screen and dismisses it when the audio has loaded
 </script>
 ```
 
-> [!DANGER]
-> In Harlowe v3.x, you should **always** define your tracks in your Story JavaScript, or your compiler's equivalent script section.
-
 Once you have some tracks set up and named, you're ready to do things with them!
 
 ## Track Methods
@@ -821,10 +815,8 @@ This library adds a loading screen to Harlowe that is superficially similar to S
 > [!TIP]
 > These APIs are completely unavailable if `options.controls.show` is `false`.
 
-?> **TODO:** Add this to the API section. Improve this aspect of the demo. Write code examples.
-
 > [!DANGER]
-> In Harlowe v3.x, you should **always** define your menu links Story JavaScript, or your compiler's equivalent script section.
+> You should **always** define your menu links Story JavaScript, or your compiler's equivalent script section, never in passages.
 
 This API allows you to add links to the sidebar as a 'story menu', similar to what can be done in SugarCube. THese links can be used to navigate to a passage, run a JavaScript function, or both. They can be hidden, shown, toggled, and removed at any time.
 
@@ -1121,16 +1113,13 @@ Then:
 
 ## Looping Background Music
 
-The `<track>.loop()` method can be used to make music loop. If all you're after is a a backing track, this is all you need. Just place it in your JavaScript (after the library) ~~or in a `<script>` in a `startup`-tagged passage element~~:
+The `<track>.loop()` method can be used to make music loop. If all you're after is a a backing track, this is all you need. Just place it in your JavaScript (after the library):
 
 ```javascript
 A.newTrack('theme', 'url/to-you-track.mp3');
 A.track('theme').loop(true).playWhenPossible();
 ```
 
-> [!DANGER]
-> In Harlowe v3.x, you should **always** define your tracks in your Story JavaScript, or your compiler's equivalent script section.
-
 
 That's it; you're done.
 
@@ -1259,9 +1248,6 @@ You can abuse the set macro, however to run code in order:
 <script>A.track('piano').loop(true).playWhenPossible();</script>
 ```
 
-> [!DANGER]
-> In Harlowe v3.x, you should **always** define your tracks in your Story JavaScript, or your compiler's equivalent script section.
-
 The `(set:)` will force the function to be evaluated in order, and the `(print:)` will print `false` as expected. However, this is a hack, and may not be possible in future versions of Harlowe.
 
 I generally recommend using `<script>` elements where ever possible, and only resorting to this trick when there's no other easy way to achieve the desired results.
diff --git a/docs/changelog.md b/docs/changelog.md
index 3c01f32..6095d8d 100644
--- a/docs/changelog.md
+++ b/docs/changelog.md
@@ -1,3 +1,12 @@
+## v1.3.0
+
+This version of HAL should address most issues related to Harlowe v3's refresh/reload persistence for tracks, playlists, and groups. The Menu API calls still need to be set up in Story JavaScript; there's simply too much that can go wrong there.
+
+- Added session persistence for `track`, `playlist`, and `group` instances.
+- Fixed a bug with `track#one()`.
+- Updated documentation.
+- Other internal improvements and updates.
+
 ## v1.2.0
 
 This version adds event handler methods to the `track` prototype and to the root `A` object.
diff --git a/docs/demo/audio/battle5.ogg b/docs/demo/audio/battle5.ogg
new file mode 100644
index 0000000..d097abe
Binary files /dev/null and b/docs/demo/audio/battle5.ogg differ
diff --git a/docs/demo/audio/beep.ogg b/docs/demo/audio/beep.ogg
index 10557c1..25c1c21 100644
Binary files a/docs/demo/audio/beep.ogg and b/docs/demo/audio/beep.ogg differ
diff --git a/docs/demo/index.html b/docs/demo/index.html
index 23c59c8..c369e37 100644
--- a/docs/demo/index.html
+++ b/docs/demo/index.html
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>Audio Test</title>
-<style title="Twine CSS">@-webkit-keyframes appear{0%{opacity:0}to{opacity:1}}@keyframes appear{0%{opacity:0}to{opacity:1}}@-webkit-keyframes fade-in-out{0%,to{opacity:0}50%{opacity:1}}@keyframes fade-in-out{0%,to{opacity:0}50%{opacity:1}}@-webkit-keyframes rumble{50%{-webkit-transform:translateY(-0.2em);transform:translateY(-0.2em)}}@keyframes rumble{50%{-webkit-transform:translateY(-0.2em);transform:translateY(-0.2em)}}@-webkit-keyframes shudder{50%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@keyframes shudder{50%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@-webkit-keyframes box-flash{0%{background-color:white;color:white}}@keyframes box-flash{0%{background-color:white;color:white}}@-webkit-keyframes pulse{0%{-webkit-transform:scale(0, 0);transform:scale(0, 0)}20%{-webkit-transform:scale(1.2, 1.2);transform:scale(1.2, 1.2)}40%{-webkit-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}60%{-webkit-transform:scale(1.05, 1.05);transform:scale(1.05, 1.05)}80%{-webkit-transform:scale(0.925, 0.925);transform:scale(0.925, 0.925)}to{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@keyframes pulse{0%{-webkit-transform:scale(0, 0);transform:scale(0, 0)}20%{-webkit-transform:scale(1.2, 1.2);transform:scale(1.2, 1.2)}40%{-webkit-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}60%{-webkit-transform:scale(1.05, 1.05);transform:scale(1.05, 1.05)}80%{-webkit-transform:scale(0.925, 0.925);transform:scale(0.925, 0.925)}to{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@-webkit-keyframes shudder-in{0%, to{-webkit-transform:translateX(0em);transform:translateX(0em)}5%, 25%, 45%{-webkit-transform:translateX(-1em);transform:translateX(-1em)}15%, 35%, 55%{-webkit-transform:translateX(1em);transform:translateX(1em)}65%{-webkit-transform:translateX(-0.6em);transform:translateX(-0.6em)}75%{-webkit-transform:translateX(0.6em);transform:translateX(0.6em)}85%{-webkit-transform:translateX(-0.2em);transform:translateX(-0.2em)}95%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@keyframes shudder-in{0%, to{-webkit-transform:translateX(0em);transform:translateX(0em)}5%, 25%, 45%{-webkit-transform:translateX(-1em);transform:translateX(-1em)}15%, 35%, 55%{-webkit-transform:translateX(1em);transform:translateX(1em)}65%{-webkit-transform:translateX(-0.6em);transform:translateX(-0.6em)}75%{-webkit-transform:translateX(0.6em);transform:translateX(0.6em)}85%{-webkit-transform:translateX(-0.2em);transform:translateX(-0.2em)}95%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}.debug-mode tw-expression[type=hookref]{background-color:rgba(115,123,140,0.15)}.debug-mode tw-expression[type=hookref]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"?" attr(name)}.debug-mode tw-expression[type=variable]{background-color:rgba(140,128,115,0.15)}.debug-mode tw-expression[type=variable]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"$" attr(name)}.debug-mode tw-expression[type=tempVariable]{background-color:rgba(140,128,115,0.15)}.debug-mode tw-expression[type=tempVariable]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"_" attr(name)}.debug-mode tw-expression[type=macro]:nth-of-type(4n+0){background-color:rgba(136,153,102,0.15)}.debug-mode tw-expression[type=macro]:nth-of-type(2n+1){background-color:rgba(102,153,102,0.15)}.debug-mode tw-expression[type=macro]:nth-of-type(4n+2){background-color:rgba(102,153,136,0.15)}.debug-mode tw-expression[type=macro][name="display"]{background-color:rgba(0,170,255,0.1) !important}.debug-mode tw-expression[type=macro][name="if"],.debug-mode tw-expression[type=macro][name="if"]+tw-hook:not([name]),.debug-mode tw-expression[type=macro][name="unless"],.debug-mode tw-expression[type=macro][name="unless"]+tw-hook:not([name]),.debug-mode tw-expression[type=macro][name="elseif"],.debug-mode tw-expression[type=macro][name="elseif"]+tw-hook:not([name]),.debug-mode tw-expression[type=macro][name="else"],.debug-mode tw-expression[type=macro][name="else"]+tw-hook:not([name]){background-color:rgba(0,255,0,0.1) !important}.debug-mode tw-expression[type=macro].false{background-color:rgba(255,0,0,0.2) !important}.debug-mode tw-expression[type=macro].false+tw-hook:not([name]){display:none}.debug-mode tw-expression[type=macro][name="a"],.debug-mode tw-expression[type=macro][name="array"],.debug-mode tw-expression[type=macro][name="datamap"],.debug-mode tw-expression[type=macro][name="dataset"],.debug-mode tw-expression[type=macro][name="colour"],.debug-mode tw-expression[type=macro][name="color"],.debug-mode tw-expression[type=macro][name="num"],.debug-mode tw-expression[type=macro][name="number"],.debug-mode tw-expression[type=macro][name="text"],.debug-mode tw-expression[type=macro][name="print"]{background-color:rgba(255,255,0,0.2) !important}.debug-mode tw-expression[type=macro][name="put"],.debug-mode tw-expression[type=macro][name="set"]{background-color:rgba(255,128,0,0.2) !important}.debug-mode tw-expression[type=macro][name="script"]{background-color:rgba(255,191,0,0.2) !important}.debug-mode tw-expression[type=macro][name="style"]{background-color:rgba(185,198,198,0.2) !important}.debug-mode tw-expression[type=macro][name^="link"],.debug-mode tw-expression[type=macro][name^="click"],.debug-mode tw-expression[type=macro][name^="mouseover"],.debug-mode tw-expression[type=macro][name^="mouseout"]{background-color:rgba(128,223,32,0.2) !important}.debug-mode tw-expression[type=macro][name^="replace"],.debug-mode tw-expression[type=macro][name^="prepend"],.debug-mode tw-expression[type=macro][name^="append"],.debug-mode tw-expression[type=macro][name^="remove"]{background-color:rgba(223,96,32,0.2) !important}.debug-mode tw-expression[type=macro][name="live"]{background-color:rgba(32,96,223,0.2) !important}.debug-mode tw-expression[type=macro]::before{content:"(" attr(name) ":)";padding:0 0.5rem;font-size:1rem;vertical-align:middle;line-height:normal;background-color:inherit;border:1px solid rgba(255,255,255,0.5)}.debug-mode tw-hook{background-color:rgba(0,85,255,0.1) !important}.debug-mode tw-hook::before{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"["}.debug-mode tw-hook::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"]"}.debug-mode tw-hook[name]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"]<" attr(name) "|"}.debug-mode tw-pseudo-hook{background-color:rgba(255,170,0,0.1) !important}.debug-mode tw-collapsed::before{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"{"}.debug-mode tw-collapsed::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"}"}.debug-mode tw-verbatim::before,.debug-mode tw-verbatim::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"`"}.debug-mode tw-align[style*="text-align: center"]{background:linear-gradient(to right, rgba(255,204,189,0) 0%, rgba(255,204,189,0.25) 50%, rgba(255,204,189,0) 100%)}.debug-mode tw-align[style*="text-align: left"]{background:linear-gradient(to right, rgba(255,204,189,0.25) 0%, rgba(255,204,189,0) 100%)}.debug-mode tw-align[style*="text-align: right"]{background:linear-gradient(to right, rgba(255,204,189,0) 0%, rgba(255,204,189,0.25) 100%)}.debug-mode tw-column{background-color:rgba(189,228,255,0.2)}.debug-mode tw-enchantment{animation:enchantment 0.5s infinite;-webkit-animation:enchantment 0.5s infinite;border:1px solid}.debug-mode tw-link::after,.debug-mode tw-broken-link::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:attr(passage-name)}.debug-mode tw-include{background-color:rgba(204,128,51,0.1)}.debug-mode tw-include::before{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:attr(type) ' "' attr(title) '"'}@keyframes enchantment{0%,to{border-color:#ffb366}50%{border-color:#6fc}}@-webkit-keyframes enchantment{0%,to{border-color:#ffb366}50%{border-color:#6fc}}tw-debugger{position:fixed;box-sizing:border-box;bottom:0;right:0;z-index:999999;min-width:10em;min-height:1em;padding:1em;font-size:1.25em;font-family:sans-serif;border-left:solid #000 2px;border-top:solid #000 2px;border-top-left-radius:.5em;background:#fff;opacity:1}tw-debugger select{margin-right:1em;width:12em}tw-debugger button{border-radius:3px;border:solid #999 1px;margin:auto 4px;background-color:#fff;font-size:inherit}tw-debugger button.enabled{background-color:#eee;box-shadow:inset #ddd 3px 5px 0.5em}tw-debugger .variables{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:vertical;-webkit-flex-direction:column;-moz-flex-direction:column;-ms-flex-direction:column;flex-direction:column;position:absolute;bottom:100%;left:-2px;right:0;padding:1em;max-height:40vh;overflow-y:scroll;overflow-x:hidden;z-index:999998;background:#fff;border:inherit;border-top-left-radius:.5em;border-bottom-left-radius:.5em;font-size:0.8em}tw-debugger .variables:empty,tw-debugger .variables[hidden]{display:none}tw-debugger .variables .variable-row{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:horizontal;-webkit-flex-direction:row;-moz-flex-direction:row;-ms-flex-direction:row;flex-direction:row;flex-shrink:0}tw-debugger .variables .variable-row:nth-child(2n){background:#EEE}tw-debugger .variables .variable-name{display:inline-block;width:50%}tw-debugger .variables .variable-name::before{content:"$"}tw-debugger .variables .variable-name.temporary::before{content:"_"}tw-debugger .variables .variable-name .temporary-variable-scope{opacity:0.8;font-size:0.75em}tw-debugger .variables .variable-name .temporary-variable-scope::before{content:" in "}tw-debugger .variables .variable-value{display:inline-block;width:50%}tw-link,.link,tw-icon,.enchantment-clickblock{cursor:pointer}tw-link,.enchantment-link{color:#4169E1;font-weight:bold;text-decoration:none;transition:color 0.2s ease-in-out}tw-enchantment[style^="color"] tw-link:not(:hover),tw-enchantment[style*=" color"] tw-link:not(:hover),tw-enchantment[style^="color"] .enchantment-link:not(:hover),tw-enchantment[style*=" color"] .enchantment-link:not(:hover){color:inherit}tw-link:hover,.enchantment-link:hover{color:#00bfff}tw-link:active,.enchantment-link:active{color:#DD4B39}.visited{color:#6941e1}tw-enchantment[style^="color"] .visited:not(:hover),tw-enchantment[style*=" color"] .visited:not(:hover){color:inherit}.visited:hover{color:#E3E}tw-broken-link{color:#993333;border-bottom:2px solid #993333;cursor:not-allowed}tw-enchantment[style^="color"] tw-broken-link:not(:hover),tw-enchantment[style*=" color"] tw-broken-link:not(:hover){color:inherit}.enchantment-mouseover{border-bottom:1px dashed #666}.enchantment-mouseout{border:rgba(64,149,191,0.25) 1px solid}.enchantment-mouseout:hover{background-color:rgba(64,149,191,0.25);border:transparent 1px solid;border-radius:0.2em}.enchantment-clickblock{box-shadow:inset 0 0 0 0.5vmax;display:block;color:rgba(65,105,225,0.5);transition:color 0.2s ease-in-out}.enchantment-clickblock:hover{color:rgba(0,191,255,0.5)}.enchantment-clickblock:active{color:rgba(222,78,59,0.5)}html{margin:0;height:100%;overflow-x:hidden}*,:before,:after{position:relative;box-sizing:inherit}body{margin:0;height:100%}tw-storydata{display:none}tw-story{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:vertical;-webkit-flex-direction:column;-moz-flex-direction:column;-ms-flex-direction:column;flex-direction:column;font:100% Georgia, serif;box-sizing:border-box;width:100%;min-height:100%;font-size:1.5em;line-height:1.5em;padding:5% 20%;margin:0;background-color:#000;color:#fff}tw-passage{display:block}br+br{display:block;height:0;margin:0.8ex 0}tw-sidebar{left:-5em;width:3em;position:absolute;text-align:center;display:block}tw-icon{display:block;margin:0.5em 0;opacity:0.1;font-size:2.75em}tw-icon:hover{opacity:0.3}tw-hook:empty,tw-expression:empty{display:none}tw-error{display:inline-block;border-radius:0.2em;padding:0.2em;font-size:1rem;cursor:help}tw-error.error{background-color:rgba(223,58,190,0.4);color:#fff}tw-error.warning{background-color:rgba(223,140,58,0.4);color:#fff;display:none}.debug-mode tw-error.warning{display:inline}tw-error-explanation{display:block;font-size:0.8rem;line-height:1rem}tw-error-explanation-button{cursor:pointer;line-height:0em;border-radius:1px;border:1px solid black;font-size:0.8rem;margin:0 0.4rem;opacity:0.5}tw-error-explanation-button .folddown-arrowhead{display:inline-block}tw-notifier{border-radius:0.2em;padding:0.2em;font-size:1rem;background-color:rgba(223,182,58,0.4);display:none}.debug-mode tw-notifier{display:inline}tw-notifier::before{content:attr(message)}tw-colour{border:1px solid black;display:inline-block;width:1em;height:1em}h1{font-size:3em}h2{font-size:2.25em}h3{font-size:1.75em}h1,h2,h3,h4,h5,h6{line-height:1em;margin:0.3em 0 0.6em 0}pre{font-size:1rem}small{font-size:70%}big{font-size:120%}mark{color:rgba(0,0,0,0.6);background-color:#ff9}ins{color:rgba(0,0,0,0.6);background-color:rgba(255,242,204,0.5);border-radius:0.5em;box-shadow:0em 0em 0.2em #ffe699;text-decoration:none}center{text-align:center;margin:0 auto;width:60%}blink{text-decoration:none;animation:fade-in-out 1s steps(1, end) infinite alternate;-webkit-animation:fade-in-out 1s steps(1, end) infinite alternate}tw-align{display:block}tw-columns{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:horizontal;-webkit-flex-direction:row;-moz-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;-moz-justify-content:space-between;justify-content:space-between}tw-outline{color:white;text-shadow:-1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000}tw-shadow{text-shadow:0.08em 0.08em 0.08em #000}tw-emboss{text-shadow:0.08em 0.08em 0em #000;color:white}tw-condense{letter-spacing:-0.08em}tw-expand{letter-spacing:0.1em}tw-blur{color:transparent;text-shadow:0em 0em 0.08em #000}tw-blurrier{color:transparent;text-shadow:0em 0em 0.2em #000}tw-blurrier::selection{background-color:transparent;color:transparent}tw-blurrier::-moz-selection{background-color:transparent;color:transparent}tw-smear{color:transparent;text-shadow:0em 0em 0.02em rgba(0,0,0,0.75),-0.2em 0em 0.5em rgba(0,0,0,0.5),0.2em 0em 0.5em rgba(0,0,0,0.5)}tw-mirror{display:inline-block;transform:scaleX(-1);-webkit-transform:scaleX(-1)}tw-upside-down{display:inline-block;transform:scaleY(-1);-webkit-transform:scaleY(-1)}tw-fade-in-out{text-decoration:none;animation:fade-in-out 2s ease-in-out infinite alternate;-webkit-animation:fade-in-out 2s ease-in-out infinite alternate}tw-rumble{-webkit-animation:rumble linear 0.1s 0s infinite;animation:rumble linear 0.1s 0s infinite;display:inline-block}tw-shudder{-webkit-animation:shudder linear 0.1s 0s infinite;animation:shudder linear 0.1s 0s infinite;display:inline-block}tw-shudder-in{animation:shudder-in 1s ease-out;-webkit-animation:shudder-in 1s ease-out}.transition-in{-webkit-animation:appear 0ms step-start;animation:appear 0ms step-start}.transition-out{-webkit-animation:appear 0ms step-end;animation:appear 0ms step-end}[data-t8n^=fade-in].transition-in{-webkit-animation:appear .8s;animation:appear .8s}[data-t8n^=fade-in].transition-out{display:none}[data-t8n^=dissolve].transition-in{-webkit-animation:appear .8s;animation:appear .8s}[data-t8n^=dissolve].transition-out{-webkit-animation:appear .8s reverse;animation:appear .8s reverse}[data-t8n^=shudder-in].transition-in,.transition-in[data-t8n^=shudder]{display:inline-block;-webkit-animation:shudder-in .8s;animation:shudder-in .8s}[data-t8n^=shudder-out].transition-out,.transition-out[data-t8n^=shudder]{display:inline-block;-webkit-animation:shudder-out .8s;animation:shudder-out .8s}[data-t8n^=boxflash].transition-in{-webkit-animation:box-flash .8s;animation:box-flash .8s}[data-t8n^=pulse].transition-in{-webkit-animation:pulse .8s;animation:pulse .8s;display:inline-block}[data-t8n^=pulse].transition-out{-webkit-animation:pulse .8s reverse;animation:pulse .8s reverse;display:inline-block}[data-t8n$=fast]{animation-duration:.4s;-webkit-animation-duration:.4s}[data-t8n$=slow]{animation-duration:1.6s;-webkit-animation-duration:1.6s}
+<style title="Twine CSS">@-webkit-keyframes appear{0%{opacity:0}to{opacity:1}}@keyframes appear{0%{opacity:0}to{opacity:1}}@-webkit-keyframes fade-in-out{0%,to{opacity:0}50%{opacity:1}}@keyframes fade-in-out{0%,to{opacity:0}50%{opacity:1}}@-webkit-keyframes rumble{50%{-webkit-transform:translateY(-0.2em);transform:translateY(-0.2em)}}@keyframes rumble{50%{-webkit-transform:translateY(-0.2em);transform:translateY(-0.2em)}}@-webkit-keyframes shudder{50%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@keyframes shudder{50%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@-webkit-keyframes box-flash{0%{background-color:white;color:white}}@keyframes box-flash{0%{background-color:white;color:white}}@-webkit-keyframes pulse{0%{-webkit-transform:scale(0, 0);transform:scale(0, 0)}20%{-webkit-transform:scale(1.2, 1.2);transform:scale(1.2, 1.2)}40%{-webkit-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}60%{-webkit-transform:scale(1.05, 1.05);transform:scale(1.05, 1.05)}80%{-webkit-transform:scale(0.925, 0.925);transform:scale(0.925, 0.925)}to{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@keyframes pulse{0%{-webkit-transform:scale(0, 0);transform:scale(0, 0)}20%{-webkit-transform:scale(1.2, 1.2);transform:scale(1.2, 1.2)}40%{-webkit-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}60%{-webkit-transform:scale(1.05, 1.05);transform:scale(1.05, 1.05)}80%{-webkit-transform:scale(0.925, 0.925);transform:scale(0.925, 0.925)}to{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@-webkit-keyframes shudder-in{0%, to{-webkit-transform:translateX(0em);transform:translateX(0em)}5%, 25%, 45%{-webkit-transform:translateX(-1em);transform:translateX(-1em)}15%, 35%, 55%{-webkit-transform:translateX(1em);transform:translateX(1em)}65%{-webkit-transform:translateX(-0.6em);transform:translateX(-0.6em)}75%{-webkit-transform:translateX(0.6em);transform:translateX(0.6em)}85%{-webkit-transform:translateX(-0.2em);transform:translateX(-0.2em)}95%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@keyframes shudder-in{0%, to{-webkit-transform:translateX(0em);transform:translateX(0em)}5%, 25%, 45%{-webkit-transform:translateX(-1em);transform:translateX(-1em)}15%, 35%, 55%{-webkit-transform:translateX(1em);transform:translateX(1em)}65%{-webkit-transform:translateX(-0.6em);transform:translateX(-0.6em)}75%{-webkit-transform:translateX(0.6em);transform:translateX(0.6em)}85%{-webkit-transform:translateX(-0.2em);transform:translateX(-0.2em)}95%{-webkit-transform:translateX(0.2em);transform:translateX(0.2em)}}@-webkit-keyframes rumble-in{0%, to{-webkit-transform:translateY(0em);transform:translateY(0em)}5%, 25%, 45%{-webkit-transform:translateY(-1em);transform:translateY(-1em)}15%, 35%, 55%{-webkit-transform:translateY(1em);transform:translateY(1em)}65%{-webkit-transform:translateY(-0.6em);transform:translateY(-0.6em)}75%{-webkit-transform:translateY(0.6em);transform:translateY(0.6em)}85%{-webkit-transform:translateY(-0.2em);transform:translateY(-0.2em)}95%{-webkit-transform:translateY(0.2em);transform:translateY(0.2em)}}@keyframes rumble-in{0%, to{-webkit-transform:translateY(0em);transform:translateY(0em)}5%, 25%, 45%{-webkit-transform:translateY(-1em);transform:translateY(-1em)}15%, 35%, 55%{-webkit-transform:translateY(1em);transform:translateY(1em)}65%{-webkit-transform:translateY(-0.6em);transform:translateY(-0.6em)}75%{-webkit-transform:translateY(0.6em);transform:translateY(0.6em)}85%{-webkit-transform:translateY(-0.2em);transform:translateY(-0.2em)}95%{-webkit-transform:translateY(0.2em);transform:translateY(0.2em)}}@-webkit-keyframes slide-right{0%{-webkit-transform:translateX(-100vw);transform:translateX(-100vw)}}@keyframes slide-right{0%{-webkit-transform:translateX(-100vw);transform:translateX(-100vw)}}@-webkit-keyframes slide-left{0%{-webkit-transform:translateX(100vw);transform:translateX(100vw)}}@keyframes slide-left{0%{-webkit-transform:translateX(100vw);transform:translateX(100vw)}}@-webkit-keyframes slide-up{0%{-webkit-transform:translateY(100vh);transform:translateY(100vh)}}@keyframes slide-up{0%{-webkit-transform:translateY(100vh);transform:translateY(100vh)}}@-webkit-keyframes slide-down{0%{-webkit-transform:translateY(-100vh);transform:translateY(-100vh)}}@keyframes slide-down{0%{-webkit-transform:translateY(-100vh);transform:translateY(-100vh)}}@-webkit-keyframes flicker{0%,29%,31%,63%,65%,77%,79%,86%,88%,91%,93%{opacity:0}30%{opacity:0.2}64%{opacity:0.4}78%{opacity:0.6}87%{opacity:0.8}92%, to{opacity:1}}@keyframes flicker{0%,29%,31%,63%,65%,77%,79%,86%,88%,91%,93%{opacity:0}30%{opacity:0.2}64%{opacity:0.4}78%{opacity:0.6}87%{opacity:0.8}92%, to{opacity:1}}.debug-mode tw-expression[type=hookref]{background-color:rgba(115,123,140,0.15)}.debug-mode tw-expression[type=hookref]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"?" attr(name)}.debug-mode tw-expression[type=variable]{background-color:rgba(140,128,115,0.15)}.debug-mode tw-expression[type=variable]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"$" attr(name)}.debug-mode tw-expression[type=tempVariable]{background-color:rgba(140,128,115,0.15)}.debug-mode tw-expression[type=tempVariable]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"_" attr(name)}.debug-mode tw-expression[type=macro]:nth-of-type(4n+0){background-color:rgba(136,153,102,0.15)}.debug-mode tw-expression[type=macro]:nth-of-type(2n+1){background-color:rgba(102,153,102,0.15)}.debug-mode tw-expression[type=macro]:nth-of-type(4n+2){background-color:rgba(102,153,136,0.15)}.debug-mode tw-expression[type=macro][name="display"]{background-color:rgba(0,170,255,0.1) !important}.debug-mode tw-expression[type=macro][name="if"],.debug-mode tw-expression[type=macro][name="if"]+tw-hook:not([name]),.debug-mode tw-expression[type=macro][name="unless"],.debug-mode tw-expression[type=macro][name="unless"]+tw-hook:not([name]),.debug-mode tw-expression[type=macro][name="elseif"],.debug-mode tw-expression[type=macro][name="elseif"]+tw-hook:not([name]),.debug-mode tw-expression[type=macro][name="else"],.debug-mode tw-expression[type=macro][name="else"]+tw-hook:not([name]){background-color:rgba(0,255,0,0.1) !important}.debug-mode tw-expression[type=macro].false{background-color:rgba(255,0,0,0.2) !important}.debug-mode tw-expression[type=macro].false+tw-hook:not([name]){display:none}.debug-mode tw-expression[type=macro][name="a"],.debug-mode tw-expression[type=macro][name="array"],.debug-mode tw-expression[type=macro][name="datamap"],.debug-mode tw-expression[type=macro][name="dataset"],.debug-mode tw-expression[type=macro][name="colour"],.debug-mode tw-expression[type=macro][name="color"],.debug-mode tw-expression[type=macro][name="num"],.debug-mode tw-expression[type=macro][name="number"],.debug-mode tw-expression[type=macro][name="text"],.debug-mode tw-expression[type=macro][name="print"]{background-color:rgba(255,255,0,0.2) !important}.debug-mode tw-expression[type=macro][name="put"],.debug-mode tw-expression[type=macro][name="set"]{background-color:rgba(255,128,0,0.2) !important}.debug-mode tw-expression[type=macro][name="script"]{background-color:rgba(255,191,0,0.2) !important}.debug-mode tw-expression[type=macro][name="style"]{background-color:rgba(185,198,198,0.2) !important}.debug-mode tw-expression[type=macro][name^="link"],.debug-mode tw-expression[type=macro][name^="click"],.debug-mode tw-expression[type=macro][name^="mouseover"],.debug-mode tw-expression[type=macro][name^="mouseout"]{background-color:rgba(128,223,32,0.2) !important}.debug-mode tw-expression[type=macro][name^="replace"],.debug-mode tw-expression[type=macro][name^="prepend"],.debug-mode tw-expression[type=macro][name^="append"],.debug-mode tw-expression[type=macro][name^="remove"]{background-color:rgba(223,96,32,0.2) !important}.debug-mode tw-expression[type=macro][name="live"]{background-color:rgba(32,96,223,0.2) !important}.debug-mode tw-expression[type=macro]::before{content:"(" attr(name) ":)";padding:0 0.5rem;font-size:1rem;vertical-align:middle;line-height:normal;background-color:inherit;border:1px solid rgba(255,255,255,0.5)}.debug-mode tw-hook{background-color:rgba(0,85,255,0.1) !important}.debug-mode tw-hook::before{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"["}.debug-mode tw-hook::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"]"}.debug-mode tw-hook[name]::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"]<" attr(name) "|"}.debug-mode tw-pseudo-hook{background-color:rgba(255,170,0,0.1) !important}.debug-mode tw-collapsed::before{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"{"}.debug-mode tw-collapsed::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"}"}.debug-mode tw-verbatim::before,.debug-mode tw-verbatim::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:"`"}.debug-mode tw-align[style*="text-align: center"]{background:linear-gradient(to right, rgba(255,204,189,0) 0%, rgba(255,204,189,0.25) 50%, rgba(255,204,189,0) 100%)}.debug-mode tw-align[style*="text-align: left"]{background:linear-gradient(to right, rgba(255,204,189,0.25) 0%, rgba(255,204,189,0) 100%)}.debug-mode tw-align[style*="text-align: right"]{background:linear-gradient(to right, rgba(255,204,189,0) 0%, rgba(255,204,189,0.25) 100%)}.debug-mode tw-column{background-color:rgba(189,228,255,0.2)}.debug-mode tw-enchantment{animation:enchantment 0.5s infinite;-webkit-animation:enchantment 0.5s infinite;border:1px solid}.debug-mode tw-link::after,.debug-mode tw-broken-link::after{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:attr(passage-name)}.debug-mode tw-include{background-color:rgba(204,128,51,0.1)}.debug-mode tw-include::before{font-size:0.8rem;padding-left:0.2rem;padding-right:0.2rem;vertical-align:top;content:attr(type) ' "' attr(title) '"'}@keyframes enchantment{0%,to{border-color:#ffb366}50%{border-color:#6fc}}@-webkit-keyframes enchantment{0%,to{border-color:#ffb366}50%{border-color:#6fc}}tw-debugger{position:fixed;box-sizing:border-box;bottom:0;right:0;z-index:999999;min-width:10em;min-height:1em;padding:1em;font-size:1.25em;font-family:sans-serif;border-left:solid #000 2px;border-top:solid #000 2px;border-top-left-radius:.5em;background:#fff;opacity:1}tw-debugger select{margin-right:1em;width:12em}tw-debugger button{border-radius:3px;border:solid #999 1px;margin:auto 4px;background-color:#fff;font-size:inherit}tw-debugger button.enabled{background-color:#eee;box-shadow:inset #ddd 3px 5px 0.5em}tw-debugger .variables{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:vertical;-webkit-flex-direction:column;-moz-flex-direction:column;-ms-flex-direction:column;flex-direction:column;position:absolute;bottom:100%;left:-2px;right:0;padding:1em;max-height:40vh;overflow-y:scroll;overflow-x:hidden;z-index:999998;background:#fff;border:inherit;border-top-left-radius:.5em;border-bottom-left-radius:.5em;font-size:0.8em}tw-debugger .variables:empty,tw-debugger .variables[hidden]{display:none}tw-debugger .variables .variable-row{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:horizontal;-webkit-flex-direction:row;-moz-flex-direction:row;-ms-flex-direction:row;flex-direction:row;flex-shrink:0}tw-debugger .variables .variable-row:nth-child(2n){background:#EEE}tw-debugger .variables .variable-name{display:inline-block;width:50%}tw-debugger .variables .variable-name::before{content:"$"}tw-debugger .variables .variable-name.temporary::before{content:"_"}tw-debugger .variables .variable-name .temporary-variable-scope{opacity:0.8;font-size:0.75em}tw-debugger .variables .variable-name .temporary-variable-scope::before{content:" in "}tw-debugger .variables .variable-value{display:inline-block;width:50%}tw-link,.link,tw-icon,.enchantment-clickblock{cursor:pointer}tw-link,.enchantment-link{color:#4169E1;font-weight:bold;text-decoration:none;transition:color 0.2s ease-in-out}tw-enchantment[style^="color"] tw-link:not(:hover),tw-enchantment[style*=" color"] tw-link:not(:hover),tw-enchantment[style^="color"] .enchantment-link:not(:hover),tw-enchantment[style*=" color"] .enchantment-link:not(:hover){color:inherit}tw-link:hover,.enchantment-link:hover{color:#00bfff}tw-link:active,.enchantment-link:active{color:#DD4B39}.visited{color:#6941e1}tw-enchantment[style^="color"] .visited:not(:hover),tw-enchantment[style*=" color"] .visited:not(:hover){color:inherit}.visited:hover{color:#E3E}tw-broken-link{color:#993333;border-bottom:2px solid #993333;cursor:not-allowed}tw-enchantment[style^="color"] tw-broken-link:not(:hover),tw-enchantment[style*=" color"] tw-broken-link:not(:hover){color:inherit}.enchantment-mouseover{border-bottom:1px dashed #666}.enchantment-mouseout{border:rgba(64,149,191,0.25) 1px solid}.enchantment-mouseout:hover{background-color:rgba(64,149,191,0.25);border:transparent 1px solid;border-radius:0.2em}.enchantment-clickblock{box-shadow:inset 0 0 0 0.5vmax;display:block;color:rgba(65,105,225,0.5);transition:color 0.2s ease-in-out}.enchantment-clickblock:hover{color:rgba(0,191,255,0.5)}.enchantment-clickblock:active{color:rgba(222,78,59,0.5)}html{margin:0;height:100%;overflow-x:hidden}*,:before,:after{position:relative;box-sizing:inherit}body{margin:0;height:100%}tw-storydata{display:none}tw-story{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:vertical;-webkit-flex-direction:column;-moz-flex-direction:column;-ms-flex-direction:column;flex-direction:column;font:100% Georgia, serif;box-sizing:border-box;width:100%;min-height:100%;font-size:1.5em;line-height:1.5em;padding:5% 20%;margin:0;overflow:hidden;background-color:#000;color:#fff}tw-passage{display:block}br+br{display:block;height:0;margin:0.8ex 0}tw-sidebar{left:-5em;width:3em;position:absolute;text-align:center;display:block}tw-icon{display:block;margin:0.5em 0;opacity:0.2;font-size:2.75em}tw-icon:hover{opacity:0.4}tw-hook:empty,tw-expression:empty{display:none}tw-error{display:inline-block;border-radius:0.2em;padding:0.2em;font-size:1rem;cursor:help}tw-error.error{background-color:rgba(223,58,190,0.4);color:#fff}tw-error.warning{background-color:rgba(223,140,58,0.4);color:#fff;display:none}.debug-mode tw-error.warning{display:inline}tw-error-explanation{display:block;font-size:0.8rem;line-height:1rem}tw-error-explanation-button{cursor:pointer;line-height:0em;border-radius:1px;border:1px solid black;font-size:0.8rem;margin:0 0.4rem;opacity:0.5}tw-error-explanation-button .folddown-arrowhead{display:inline-block}tw-notifier{border-radius:0.2em;padding:0.2em;font-size:1rem;background-color:rgba(223,182,58,0.4);display:none}.debug-mode tw-notifier{display:inline}tw-notifier::before{content:attr(message)}tw-colour{border:1px solid black;display:inline-block;width:1em;height:1em}select{background-color:transparent;font:inherit;border-style:solid;padding:2px}select:not([disabled]){color:inherit}h1{font-size:3em}h2{font-size:2.25em}h3{font-size:1.75em}h1,h2,h3,h4,h5,h6{line-height:1em;margin:0.3em 0 0.6em 0}pre{font-size:1rem}small{font-size:70%}big{font-size:120%}mark{color:rgba(0,0,0,0.6);background-color:#ff9}ins{color:rgba(0,0,0,0.6);background-color:rgba(255,242,204,0.5);border-radius:0.5em;box-shadow:0em 0em 0.2em #ffe699;text-decoration:none}center{text-align:center;margin:0 auto;width:60%}blink{text-decoration:none;animation:fade-in-out 1s steps(1, end) infinite alternate;-webkit-animation:fade-in-out 1s steps(1, end) infinite alternate}tw-align{display:block}tw-columns{display:-webkit-box;display:-webkit-flex;display:-moz-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-webkit-box-orient:horizontal;-webkit-flex-direction:row;-moz-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;-moz-justify-content:space-between;justify-content:space-between}tw-outline{color:white;text-shadow:-1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000}tw-shadow{text-shadow:0.08em 0.08em 0.08em #000}tw-emboss{text-shadow:0.08em 0.08em 0em #000;color:white}tw-condense{letter-spacing:-0.08em}tw-expand{letter-spacing:0.1em}tw-blur{color:transparent;text-shadow:0em 0em 0.08em #000}tw-blurrier{color:transparent;text-shadow:0em 0em 0.2em #000}tw-blurrier::selection{background-color:transparent;color:transparent}tw-blurrier::-moz-selection{background-color:transparent;color:transparent}tw-smear{color:transparent;text-shadow:0em 0em 0.02em rgba(0,0,0,0.75),-0.2em 0em 0.5em rgba(0,0,0,0.5),0.2em 0em 0.5em rgba(0,0,0,0.5)}tw-mirror{display:inline-block;transform:scaleX(-1);-webkit-transform:scaleX(-1)}tw-upside-down{display:inline-block;transform:scaleY(-1);-webkit-transform:scaleY(-1)}tw-fade-in-out{text-decoration:none;animation:fade-in-out 2s ease-in-out infinite alternate;-webkit-animation:fade-in-out 2s ease-in-out infinite alternate}tw-rumble{-webkit-animation:rumble linear 0.1s 0s infinite;animation:rumble linear 0.1s 0s infinite;display:inline-block}tw-shudder{-webkit-animation:shudder linear 0.1s 0s infinite;animation:shudder linear 0.1s 0s infinite;display:inline-block}tw-shudder-in{animation:shudder-in 1s ease-out;-webkit-animation:shudder-in 1s ease-out}.transition-in{-webkit-animation:appear 0ms step-start;animation:appear 0ms step-start}.transition-out{-webkit-animation:appear 0ms step-end;animation:appear 0ms step-end}[data-t8n^=dissolve].transition-in{-webkit-animation:appear .8s;animation:appear .8s}[data-t8n^=dissolve].transition-out{-webkit-animation:appear .8s reverse;animation:appear .8s reverse}[data-t8n^=shudder].transition-in{display:inline-block;-webkit-animation:shudder-in .8s;animation:shudder-in .8s}[data-t8n^=shudder].transition-out{display:inline-block;-webkit-animation:shudder-in .8s reverse;animation:shudder-in .8s reverse}[data-t8n^=rumble].transition-in{display:inline-block;-webkit-animation:rumble-in .8s;animation:rumble-in .8s}[data-t8n^=rumble].transition-out{display:inline-block;-webkit-animation:rumble-in .8s reverse;animation:rumble-in .8s reverse}[data-t8n^=boxflash].transition-in{-webkit-animation:box-flash .8s;animation:box-flash .8s}[data-t8n^=pulse].transition-in{-webkit-animation:pulse .8s;animation:pulse .8s;display:inline-block}[data-t8n^=pulse].transition-out{-webkit-animation:pulse .8s reverse;animation:pulse .8s reverse;display:inline-block}[data-t8n^=slideleft].transition-in{-webkit-animation:slide-left .8s;animation:slide-left .8s;display:inline-block}[data-t8n^=slideleft].transition-out{-webkit-animation:slide-right .8s reverse;animation:slide-right .8s reverse;display:inline-block}[data-t8n^=slideright].transition-in{-webkit-animation:slide-right .8s;animation:slide-right .8s;display:inline-block}[data-t8n^=slideright].transition-out{-webkit-animation:slide-left .8s reverse;animation:slide-left .8s reverse;display:inline-block}[data-t8n^=slideup].transition-in{-webkit-animation:slide-up .8s;animation:slide-up .8s;display:inline-block}[data-t8n^=slideup].transition-out{-webkit-animation:slide-down .8s reverse;animation:slide-down .8s reverse;display:inline-block}[data-t8n^=slidedown].transition-in{-webkit-animation:slide-down .8s;animation:slide-down .8s;display:inline-block}[data-t8n^=slidedown].transition-out{-webkit-animation:slide-up .8s reverse;animation:slide-up .8s reverse;display:inline-block}[data-t8n^=flicker].transition-in{-webkit-animation:flicker .8s;animation:flicker .8s}[data-t8n^=flicker].transition-out{-webkit-animation:flicker .8s reverse;animation:flicker .8s reverse}[data-t8n$=fast]{animation-duration:.4s;-webkit-animation-duration:.4s}[data-t8n$=slow]{animation-duration:1.6s;-webkit-animation-duration:1.6s}
 </style>
 <meta content="width=device-width, initial-scale=1" name="viewport" />
 </head>
@@ -12,11 +12,11 @@
 
 <tw-story></tw-story>
 
-<tw-storydata name="Audio Test" startnode="3" creator="Tweego" creator-version="1.3.0" ifid="E3A052C4-CF40-4AD0-86CF-032559E42A42" zoom="1" format="Harlowe" format-version="2.1.0" options="" hidden><style role="stylesheet" id="twine-user-stylesheet" type="text/twine-css">/* twine-user-stylesheet #1: "harlowe-audio.min.css" */
+<tw-storydata name="Audio Test" startnode="2" creator="Tweego" creator-version="1.3.0" ifid="E3A052C4-CF40-4AD0-86CF-032559E42A42" zoom="1" format="Harlowe" format-version="3.0.2" options="" hidden><style role="stylesheet" id="twine-user-stylesheet" type="text/twine-css">/* twine-user-stylesheet #1: "harlowe-audio.min.css" */
 #audio-overlay{position:fixed;top:0;right:0;left:0;bottom:0;z-index:100000;background:#111}.lds-ring{display:block;position:relative;top:20%;margin:auto;width:20em;height:20em}.lds-ring div{box-sizing:border-box;display:block;position:absolute;width:18em;height:18em;margin:6px;border:6px solid #fff;border-radius:50%;-webkit-animation:lds-ring 1.2s cubic-bezier(.5,0,.5,1) infinite;animation:lds-ring 1.2s cubic-bezier(.5,0,.5,1) infinite;border-color:#fff transparent transparent transparent}.lds-ring div:nth-child(1){-webkit-animation-delay:-.45s;animation-delay:-.45s}.lds-ring div:nth-child(2){-webkit-animation-delay:-.3s;animation-delay:-.3s}.lds-ring div:nth-child(3){-webkit-animation-delay:-.15s;animation-delay:-.15s}@-webkit-keyframes lds-ring{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes lds-ring{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}input#audio-volume{width:100%;padding:2em 0}span#vol-title{position:relative;bottom:-2em;font-size:1rem;float:left}tw-link#audio-mute{display:inline-block;padding:.3em;width:90%;text-decoration:none;color:#111;background:#eee;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;border:1px solid #000}tw-link#audio-mute:hover{opacity:.8}tw-link#audio-mute:active{opacity:.6}tw-link#audio-mute span{display:inline-block;width:1em;position:relative;height:1em;top:.2em;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAQAAABLCVATAAABF0lEQVR4Ae2VJVREYRSEB3ftuFUaLhF6I22iF7TgLr1XvAc849CwiBac9Xtm3e97cefp/Pec7+mdH0mZrGtMoBomyAEHfjGHXKg07gNxeUS3BuMAqGZswE7YcOIYgqgG7BFlSQgTAgKysC2jNjQmghFQCOpMxq+QmQgmFATU4kcq/YlgfKB1lALUqFSukRIbEwpy4BTZPM/Bu9TaQ362KAsl56sAtSR+Sgv6RCFdr/gjBYiuj65c3J0eNEmXz95TgybocvmoJj3avf5l59L1iD/WglZCP7/uh8zgeQ6epdahaZENFIPCCFvEYNPW4JdNazBGzhkj6caCbSc02DRRu0+8RR/+rb7wx6D505HxCVKvG0zpp+yknHe8MBDkT/s8AAAAAElFTkSuQmCC);background-size:contain}tw-link#audio-mute.muted span{right:4px;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAASElEQVR4Ae3WsQ0AMAjAsJ7ez9MTGEmlRGL3BJzPq6prw2DDYMNgw2DDYMOwh1kAMUygQIEC2RejANVxnVE9aDOqJ39GVZWqB5Z3r1ndBX5oAAAAAElFTkSuQmCC)}div#audio-volume{float:left}div#audio-controls{font:100% Georgia,serif;font-size:1.5em;position:fixed;width:8em;height:100%;padding:1em 2em;z-index:10000;top:0;left:0;bottom:0;background:#333;color:#eee;transition:left .3s;text-align:center}div#audio-controls.closed{left:-10.5em}div#audio-controls tw-link#audio-panel-toggle{display:inline-block;width:1.5em;position:absolute;height:1.5em;top:0;right:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;text-decoration:none;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAQAAABLCVATAAAAYklEQVR4Ae3MsQFAMAAEQMDEagCgN4EuVTrbPcACeUBugDNeSdMQomI0PmYdTEYD9DA5jcVoBKuxGY1kNQ6jGRSaGaIj8gw1aI/KYVUSNqsSzMpiVT2zMjlVN0fqVW5o2luMGHqkQmD9cPYAAAAASUVORK5CYII=);background-size:contain}div#audio-controls.closed tw-link#audio-panel-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAQAAABLCVATAAAAZElEQVR4Ae3TpwGAMBQAUfrEeHB0cDhcXBSO7ehlgBw9N8BL/YZO95r6uA/UEbOv+ylfHRJ9z1BWLynKJqmWohyS6ijKOygKCpmjZYqXTTA2xUiCsShGAMw8/Q3ArFgFMHek0w3WCaR74eO2YQAAAABJRU5ErkJggg==)}@media screen and (max-width:800px){div#audio-controls.closed{left:-12em}div#audio-controls.closed tw-link#audio-panel-toggle{right:-1.5em}}div#story-menu{margin:1em 0}tw-link.story-menu{width:100%;display:block;font-weight:400;background:#ccc;font-size:.9em;padding:.1em 0;color:#111;border:1px solid #333}tw-link.story-menu.hide{display:none}tw-link.story-menu:hover{opacity:.8}tw-link.story-menu:active{opacity:.6}</style><script role="script" id="twine-user-script" type="text/twine-javascript">/* twine-user-script #1: "harlowe-audio.min.js" */
 ;(function () {
     /**
-     * Harlowe Audio Library, by Chapel, v1.0.0
+     * Harlowe Audio Library, by Chapel, v1.3.0
      *
      * Released under the Unlicense, and dedicated to the public domain.
     **/
@@ -41,9 +41,20 @@
         }
     };
 
-    !function(){"use strict";var e=$(document.createElement("div")).attr("id","audio-container").css("display","none").appendTo(document.body),t=function(t,e){if(window.localStorage)try{t=""+t,"string"!=typeof e&&(e=JSON.stringify(e)),window.localStorage.setItem(t,e)}catch(t){console.error(t)}},o=function(t){if(window.localStorage)try{return t=""+t,window.localStorage.getItem(t)}catch(t){console.error(t)}},n=function(t){if(window.localStorage)try{t=""+t,window.localStorage.removeItem(t)}catch(t){console.error(t)}};function i(e,o){if("object"!=typeof e||"object"!=typeof o)throw new Error("Invalid extension.");Object.keys(o).forEach(function(t){if(void 0!==e[t])throw new Error('Invalid extension: cannot clobber existing property "'+t+'"');e[t]=o[t]})}var a={loaded:[],classes:{},master:{volume:options.startingVol,mute:!1},groups:{playing:[],looping:[],custom:{}},mute:function(t){a.master.mute=!!t,$(document).trigger({type:":master-mute",mute:!!t})},isMuted:function(){return!!a.master.mute},volume:function(t){t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),a.master.volume=t),$(document).trigger({type:":master-volume",volume:t})},getVolume:function(){return a.master.volume},stopAll:function(){s.list.forEach(function(t){t.stop()})},audioPlaying:function(){return!!a.groups.playing.length},savePrefs:function(){t(options.storagekey,a.master)},loadPrefs:function(){var t=o(options.storagekey);t&&"object"==typeof t&&t.hasOwnProperty("volume")&&"number"==typeof t.volume&&t.hasOwnProperty("mute")&&"boolean"==typeof t.volume&&(delete a.master,a.master=t)},clearPrefs:function(){n(options.storagekey)}},r={aac:"audio/aac",caf:"audio/x-caf","x-caf":"audio/x-caf",mp3:'audio/mpeg; codecs="mp3"',mpeg:'audio/mpeg; codecs="mp3"',m4a:"audio/mp4",mp4:"audio/mp4","x-m4a":"audio/mp4","x-mp4":"audio/mp4",oga:"audio/ogg",ogg:"audio/ogg",opus:'audio/ogg; codecs="opus"',wav:"audio/wav",wave:"audio/wav",weba:"audio/webm",webm:"audio/webm"};function u(t){throw new Error(t)}function s(t,e,o){this instanceof s||u("Track: called without `new` operator"),t||u("Track: no id specified"),"string"!=typeof t&&u("Track: track id is not a string"),(!e||Array.isArray(e)&&!e.length)&&u("Track: no sources specified"),o&&(e=[].slice.call(arguments).slice(1));var i=$(document.createElement("audio"));e.forEach(function(t){var e,o,n;$(document.createElement("source")).attr({src:t,type:(e=t,o=e.split("."),n=o[o.length-1],n.includes("?")&&(n=n.split("?")[0]),n=n.toLowerCase().trim(),Object.keys(r).includes(n)||u('Track: unsupported file type "'+n+'"'),r[n])}).appendTo(i)}),i.attr({"data-track":"id","data-volume":1,"data-mute":!1}).one("canplay",function(){a.loaded.push(t)}),options.preload&&i.attr("preload","auto"),i[0].volume=1*a.master.volume,this.id=t,this.$el=i,this.unwrap=i[0],this.sources=e}function c(t,e){if(!(this instanceof c))return new c(t,e);this.id=t,this.tracks=e.map(function(t){return s.get(t)}),this.looping=!1,this.current="",this.playing=!1}s.list=[],s.is=function(t){return t instanceof s},s.has=function(e){return s.list.some(function(t){return t.id===e})},s.emit=function(t,e){$(document).trigger({type:t,track:e}),e.emit(t)},s.add=function(t){var e=new s(t,[].slice.call(arguments).slice(1));return s.list.push(e),e.$el.on("canplay",function(){s.emit(":available",e)}),e.$el.on("canplaythrough",function(){s.emit(":loaded",e)}),e.attach(),e},s.renew=function(){s.list.forEach(function(t){t.mute(t.isMuted()),t.volume(t.getVolume())})},s.getIdx=function(e){return s.list.findIndex(function(t){return t.id===e})},s.get=function(e){return s.list.find(function(t){return t.id===e})},s.extend=function(t){i(s,t)},s.extendPrototype=function(t){i(s.prototype,t)},s.removeFromDOM=function(t){"string"==typeof t&&(t=s.get(t)),t&&s.is(t)?t.unattach():e.remove()},s.prototype={constructor:s,emit:function(t){this.$el.trigger({type:t,track:this})},clone:function(){return new s(this.id,this.sources)},isAttached:function(){return $.contains(e[0],this.unwrap)},attach:function(){return this.isAttached()||this.$el.appendTo(e),this},unattach:function(){return this.isAttached()&&this.$el.remove(),this},isPlaying:function(){return!this.unwrap.paused},play:function(){var t=this;return this.unwrap.play(),s.emit(":play",this),this.$el.on("ended",function(){t.unwrap.loop||(t.unwrap.currentTime=0,s.emit(":stop",t))}),this},playWhenPossible:function(){var e=this;return this.unwrap.play().then(function(){s.emit(":play",e),e.$el.on("ended",function(){e.unwrap.loop||(e.unwrap.currentTime=0,s.emit(":stop",e))})},function(t){$(document).one("click mousedown keydown touchstart",function(){e.play()})}).catch(function(t){console.error(t)}),this},forcePlay:function(){var t=this,e=$(document.createElement("a")).css("display","none").appendTo(document.body).on("click",function(){t.play()});setTimeout(function(){e.trigger("click")},100)},pause:function(){return this.unwrap.pause(),s.emit(":pause",this),this},stop:function(){return this.unwrap.pause(),this.unwrap.currentTime=0,s.emit(":stop",this),this},mute:function(t){return t=!!t,this.$el.attr("data-mute",t),a.master.mute?this.unwrap.muted=!0:this.unwrap.muted=t,s.emit(":mute",this),this},isMuted:function(){var t=this.$el.attr("data-mute");return"boolean"==typeof t?t:"false"!==t},toggleMute:function(){return this.mute(!this.isMuted()),this},volume:function(t){return t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),this.$el.attr("data-volume",t),this.unwrap.volume=t*a.master.volume),s.emit(":volume",this),this},getVolume:function(){return Number(this.$el.attr("data-volume"))},addToGroup:function(t,e){var o=this,n=e?a.groups.custom[t]:a.groups[t];return n.some(function(t){return o.id===t.id})||n.push(this),this},removeFromGroup:function(t,e){var o=this,n=e?a.groups.custom[t]:a.groups[t],i=n.findIndex(function(t){return t.id&&t.id===o.id});return n.splice(i,1),this},loop:function(t){return this.unwrap.loop=!!t,this.unwrap.loop?this.addToGroup("looping"):this.removeFromGroup("looping"),this},isLooping:function(){return!!this.unwrap.loop},toggleLoop:function(){return this.loop(!this.isLooping()),this},seek:function(t){return t<0?t=this.unwrap.duration-t:t>this.unwrap.duration&&(t=this.unwrap.duration),this.unwrap.currentTime=t,this},fadeIn:function(t){var e=this;t=t||1;var o=this.getVolume();return this.volume(0),this.play(),this.$el.animate({volume:o*a.master.volume},1e3*t,function(){e.volume(o),s.emit(":volume",e),s.emit(":fade",e)}),this},fadeOut:function(t){t=t||1;var e=this,o=this.getVolume();return this.$el.animate({volume:0},1e3*t,function(){e.stop(),e.volume(o),s.emit(":volume",e),s.emit(":fade",e)}),this},fadeTo:function(t,e){var o=this;if(t=t||1,e=Number(e),!Number.isNaN(e))return 1<e?e=1:e<0&&(e=0),this.$el.animate({volume:e*a.master.volume},1e3*t,function(){o.volume(e),s.emit(":volume",o),s.emit(":fade",o)}),this;alert("ivalid volume level")},delay:function(t,e){var o=this;"function"==typeof e&&(t=Number(t),(Number.isNaN(t)||t<0)&&(t=0),setTimeout(function(){e.call(o,o,t)},t))}},$(document).on(":master-mute",s.renew),$(document).on(":master-volume",s.renew),options.persistPrefs&&($(document).on(":master-mute",a.savePrefs),$(document).on(":master-volume",a.savePrefs)),$(document).on(":play",function(t){t.track.addToGroup("playing")}),$(document).on(":stop",function(t){t.track.removeFromGroup("playing")}),options.muteOnBlur&&$(window).on("blur",function(){a.isMuted()||(a.mute(!0),$(window).one("focus",function(){a.mute(!1)}))}),a.classes.Track=s,a.newTrack=s.add,a.track=s.get,a.createGroup=function(t,e,o){var n,i,r;n=o?[].slice.call(arguments).slice(1):e,i=t,(r=n)&&Array.isArray(r)||(r=[]),a.groups.custom[i]=r.map(function(t){return s.get(t)})},a.group=function(t){if(!(this instanceof a.group))return new a.group(t);Object.keys(a.groups.custom).includes(t)?this.members=a.groups.custom[t]:this.members=a.groups[t],Array.isArray(this.members)||(this.members=[],console.error('Could not find members for track group "'+t+'"!'))},a.group.is=function(t){return this instanceof a.group},a.group.runOnAll=function(t,e,o){t.members.forEach(function(t){t[e].apply(t,o&&Array.isArray(o)?o:[])})},a.group.extend=function(t){i(a.group,t)},a.group.extendPrototype=function(t){i(a.group.prototype,t)},a.group.prototype={constructor:a.group,run:function(t,e,o){null!=o&&(e=[].slice.call(arguments).slice(1)),s.prototype.hasOwnProperty(t)&&a.group.runOnAll(this,t,e)},play:function(){return this.run("play"),this},pause:function(){return this.run("pause"),this},stop:function(){return this.run("stop"),this},mute:function(t){return this.run("mute",[t]),this},volume:function(t){return this.run("volume",[t]),this},loop:function(t){return this.run("loop",[t]),this}},c.list={},c.is=function(t){return t instanceof c},c.add=function(t,e,o){return o&&(e=[].slice.call(arguments).slice(1)),c.list[t]=new c(t,e),c.list[t]},c.extend=function(t){i(c,t)},c.extendPrototype=function(t){i(c.prototype,t)},c.prototype={constructor:c,clone:function(){return new c(this.id,this.tracks.map(function(t){return t.id}))},shuffle:function(){var t,e,o,n=this.tracks;for(o=n.length-1;0<o;o--)t=Math.floor(Math.random()*(o+1)),e=n[o],n[o]=n[t],n[t]=e;return this.tracks=n,this},random:function(){return this.tracks[Math.floor(Math.random()*this.tracks.length)]},isPlaying:function(){return this.playing},play:function(t){var e=this;if((t=t||(e.current?e.tracks.findIndex(function(t){return t.id===e.current}):0))>=e.tracks.length&&e.looping)t=0;else if(t>=e.tracks.length)return e.current="",void(e.playing=!1);var o=e.tracks[t],n=o.isLooping();return o.loop(!1),o.play(),e.playing=!0,setTimeout(function(){o.isPlaying()||(e.playing=!1)},20),e.current=o.id,o.$el.one("ended.playlist",function(){t++,o.loop(n),e.play(t)}),e},loop:function(t){return this.looping=!!t,this},stop:function(){var t=s.get(this.current);return t.stop(),t.$el.off(".playlist"),this.current="",this.playing=!1,this},pause:function(){return s.get(this.current).pause(),this.playing=!1,this}},a.classes.Playlist=c,a.createPlaylist=c.add,a.playlist=function(t){return c.list[t]||null},a.extend=function(t){i(a,t)},a.extendTrack=s.extend,a.extendTrackProto=s.extendPrototype,a.extendGroup=a.group.extend,a.extendGroupProto=a.group.extendPrototype,a.extendPlaylist=c.extend,a.extendPlaylistProto=c.extendPrototype,window.Chapel=window.Chapel||{},window.Chapel.Audio=a,options.persistPrefs&&a.loadPrefs()}(),function(){"use strict";if(options.controls.show){var t=$(document.createElement("div")).attr("id","story-menu").css("display","none"),e=$(document.createElement("span")).attr("id","vol-title").append("Volume");options.controls.volumeDisplay||e.css("display","none");var o=$(document.createElement("input")).attr({id:"audio-volume",type:"range",min:1,max:99,step:1,title:"Volume"}),n=Math.trunc(100*window.Chapel.Audio.master.volume);n<0?n=0:100<n&&(n=100),o.attr("value",n);var i=function(t){void 0===t&&(t=o.val()),e.empty().append("Volume "+t)};o.on("input",function(){window.Chapel.Audio.volume($(this).val()/100),i($(this).val())});var r=$(document.createElement("tw-link")).attr({id:"audio-mute",title:"Mute"}).append("Mute <span></span>").on("click",function(t){t.preventDefault(),$(this).toggleClass("muted"),Chapel.Audio.mute(!Chapel.Audio.isMuted())});Chapel.Audio.isMuted()&&r.addClass("muted");var a=$(document.createElement("tw-link")).attr("id","audio-panel-toggle").on("click",function(t){t.preventDefault(),u.toggleClass("closed")}),u=$(document.createElement("div")).attr("id","audio-controls").append(t,e,o,r,a).appendTo(document.body);options.controls.startClosed&&u.addClass("closed"),window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.controls={$panel:u,$volume:o,$mute:r,$user:t,close:function(){u.addClass("closed")},open:function(){u.removeClass("closed")},toggle:function(){u.toggleClass("closed")},hide:function(){u.css("display","none")},show:function(){u.css("display","block")},updateVolume:i}}}(),function(t){(jQuery.browser=jQuery.browser||{}).mobile=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4))}(navigator.userAgent||navigator.vendor||window.opera),function(){"use strict";var e=State,t=$(document.createElement("div")).attr("id","audio-overlay").css("display","none").appendTo(document.body);function o(){t.css("display","block").append('<div class="lds-ring"><div></div><div></div><div></div><div></div></div>')}function u(){t.fadeOut(function(){t.empty()})}window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.loadScreen={show:o,dismiss:u,kill:function(){$("#audio-overlay").remove()}},window.Chapel.Audio.$overlay=t,window.Chapel.Audio.preload=function(){if(!(e.pastLength||e.futureLength||$.browser.mobile)){$(document).ready(function(){o()});var i=100+options.loadDelay,t=Chapel.Audio.classes.Track.list,r=Chapel.Audio.loaded;if(t.length){var a=t.map(function(t){return t.id});options.forceDismiss&&setTimeout(function(){u()},options.loadLimit.total),function t(){if(a.length){var e=a.shift();if(r.includes(e))t();else{var o=Chapel.Audio.classes.Track.get(e);if(o.unwrap.readyState<2){var n=!1;o.$el.one("canplay",function(){t(),n=!0}),setTimeout(function(){n||(o.$el.off("canplay"),t())},options.loadLimit.track)}else r.includes(e)||r.push(e),t()}}else setTimeout(u,i)}()}else setTimeout(u,i)}}}(),function(){"use strict";options.globalA&&void 0===window.A&&(window.A=window.Chapel.Audio),$(document).on("unload",function(){window.Chapel.Audio.savePrefs()}),Chapel.Audio.classes.Track.renew(),Chapel.Audio.controls.updateVolume()}(),function(){"use strict";var u=Engine,s=Chapel.Audio.controls.$user;function t(){return"none"!==s.css("display")}function c(){return t()||s.css("display","block"),s}function e(){return t()&&s.css("display","none"),s}Chapel.Audio.menu={hide:e,show:c,isShown:t,links:{add:function(t,e,o){var n,i;if(!t||"string"!=typeof t){var r="undefined";return alert(r),void console.error(r)}o||"function"!=typeof e?(e&&"string"==typeof e&&(n=e),o&&"function"==typeof o&&(i=o)):(i=e,n=null);var a=$(document.createElement("tw-link")).append(t).attr({tabindex:"0",name:t.toLowerCase().trim()}).on("click",function(){n&&u.goToPassage(n),i&&i()}).addClass("story-menu").appendTo(s);return c(),a},clear:function(){return s.empty(),e()},hide:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').addClass("hide")},show:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').removeClass("hide")},toggle:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').toggleClass("hide")},remove:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').remove()}}}}(),function(){"use strict";var n=window.prompt;window.prompt=function(){var t,e,o=n.apply(null,[].slice.call(arguments));return t=o,e=(new DOMParser).parseFromString(t,"text/html"),Array.from(e.body.childNodes).some(function(t){return 1===t.nodeType})?o.replace(/[<>]/g,""):o}}();
-
-}());</script><tw-passagedata pid="1" name="audio-init" tags="startup" position="100,100">&lt;script&gt;
+    !function(){"use strict";var t,e=$("tw-storydata");window.Chapel=window.Chapel||{},window.Chapel.Get={isHarlowe3OrLater:3<=(t=e.attr("format-version").split(".")[0],t=Number(t),Number.isNaN(t)&&(t=3),t<1&&(t=3),t),storyTitle:e.attr("name"),IFID:e.attr("ifid")}}(),function(){"use strict";var e=$(document.createElement("div")).attr("id","audio-container").css("display","none").appendTo(document.body),t=function(t,e){if(window.localStorage)try{t=""+t,"string"!=typeof e&&(e=JSON.stringify(e)),window.localStorage.setItem(t,e)}catch(t){console.error(t)}},o=function(t){if(window.localStorage)try{return t=""+t,window.localStorage.getItem(t)}catch(t){console.error(t)}},n=function(t){if(window.localStorage)try{t=""+t,window.localStorage.removeItem(t)}catch(t){console.error(t)}};function i(e,o){if("object"!=typeof e||"object"!=typeof o)throw new Error("Invalid extension.");Object.keys(o).forEach(function(t){if(void 0!==e[t])throw new Error('Invalid extension: cannot clobber existing property "'+t+'"');e[t]=o[t]})}var r={loaded:[],classes:{},master:{volume:options.startingVol,mute:!1},groups:{playing:[],looping:[],custom:{}},mute:function(t){r.master.mute=!!t,$(document).trigger({type:":master-mute",mute:!!t})},isMuted:function(){return!!r.master.mute},volume:function(t){t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),r.master.volume=t),$(document).trigger({type:":master-volume",volume:t})},getVolume:function(){return r.master.volume},stopAll:function(){c.list.forEach(function(t){t.stop()})},audioPlaying:function(){return!!r.groups.playing.length},savePrefs:function(){t(options.storagekey,r.master)},loadPrefs:function(){var t=o(options.storagekey);t&&"object"==typeof t&&t.hasOwnProperty("volume")&&"number"==typeof t.volume&&t.hasOwnProperty("mute")&&"boolean"==typeof t.volume&&(delete r.master,r.master=t)},clearPrefs:function(){n(options.storagekey)}},a={track:[":available",":loaded",":play",":stop",":mute",":volume"],master:[":master-mute",":master-volume"]},s={aac:"audio/aac",caf:"audio/x-caf","x-caf":"audio/x-caf",mp3:'audio/mpeg; codecs="mp3"',mpeg:'audio/mpeg; codecs="mp3"',m4a:"audio/mp4",mp4:"audio/mp4","x-m4a":"audio/mp4","x-mp4":"audio/mp4",oga:"audio/ogg",ogg:"audio/ogg",opus:'audio/ogg; codecs="opus"',wav:"audio/wav",wave:"audio/wav",weba:"audio/webm",webm:"audio/webm"};function u(t){throw new Error(t)}function c(t,e,o){this instanceof c||u("Track: called without `new` operator"),t||u("Track: no id specified"),"string"!=typeof t&&u("Track: track id is not a string"),e&&(!Array.isArray(e)||e.length)||u("Track: no sources specified"),o&&(e=[].slice.call(arguments).slice(1));var n=$(document.createElement("audio"));e.forEach(function(t){$(document.createElement("source")).attr({src:t,type:function(t){var e=t.split("."),o=e[e.length-1];return o.includes("?")&&(o=o.split("?")[0]),o=o.toLowerCase().trim(),Object.keys(s).includes(o)||u('Track: unsupported file type "'+o+'"'),s[o]}(t)}).appendTo(n)}),n.attr({"data-track":"id","data-volume":1,"data-mute":!1}).one("canplay",function(){r.loaded.push(t)}),options.preload&&n.attr("preload","auto"),n[0].volume=1*r.master.volume,this.id=t,this.$el=n,this.unwrap=n[0],this.sources=e}c.list=[],c.is=function(t){return t instanceof c},c.has=function(e){return c.list.some(function(t){return t.id===e})},c.emit=function(t,e){$(document).trigger({type:t,track:e}),e.emit(t)},c.add=function(t){var e=new c(t,[].slice.call(arguments).slice(1));return c.list.push(e),e.$el.on("canplay",function(){c.emit(":available",e)}),e.$el.on("canplaythrough",function(){c.emit(":loaded",e)}),e.attach(),e},c.renew=function(){c.list.forEach(function(t){t.mute(t.isMuted()),t.volume(t.getVolume())})},c.getIdx=function(e){return c.list.findIndex(function(t){return t.id===e})},c.get=function(e){return c.list.find(function(t){return t.id===e})},c.extend=function(t){i(c,t)},c.extendPrototype=function(t){i(c.prototype,t)},c.removeFromDOM=function(t){"string"==typeof t&&(t=c.get(t)),t&&c.is(t)?t.unattach():e.remove()},c.prototype={constructor:c,emit:function(t){this.$el.trigger({type:t,track:this})},clone:function(){return new c(this.id,this.sources)},isAttached:function(){return $.contains(e[0],this.unwrap)},attach:function(){return this.isAttached()||this.$el.appendTo(e),this},unattach:function(){return this.isAttached()&&this.$el.remove(),this},isPlaying:function(){return!this.unwrap.paused},play:function(){var t=this;return this.unwrap.play(),c.emit(":play",this),this.$el.on("ended",function(){t.unwrap.loop||(t.unwrap.currentTime=0,c.emit(":stop",t))}),this},playWhenPossible:function(){var e=this;return this.unwrap.play().then(function(){c.emit(":play",e),e.$el.on("ended",function(){e.unwrap.loop||(e.unwrap.currentTime=0,c.emit(":stop",e))})},function(t){$(document).one("click mousedown keydown touchstart",function(){e.play()})}).catch(function(t){console.error(t)}),this},forcePlay:function(){var t=this,e=$(document.createElement("a")).css("display","none").appendTo(document.body).on("click",function(){t.play()});setTimeout(function(){e.trigger("click")},100)},pause:function(){return this.unwrap.pause(),c.emit(":pause",this),this},stop:function(){return this.unwrap.pause(),this.unwrap.currentTime=0,c.emit(":stop",this),this},mute:function(t){return t=!!t,this.$el.attr("data-mute",t),r.master.mute?this.unwrap.muted=!0:this.unwrap.muted=t,c.emit(":mute",this),this},isMuted:function(){var t=this.$el.attr("data-mute");return"boolean"==typeof t?t:"false"!==t},toggleMute:function(){return this.mute(!this.isMuted()),this},volume:function(t){return t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),this.$el.attr("data-volume",t),this.unwrap.volume=t*r.master.volume),c.emit(":volume",this),this},getVolume:function(){return Number(this.$el.attr("data-volume"))},addToGroup:function(t,e){var o=this,n=e?r.groups.custom[t]:r.groups[t];return n.some(function(t){return o.id===t.id})||n.push(this),this},removeFromGroup:function(t,e){var o=this,n=e?r.groups.custom[t]:r.groups[t],i=n.findIndex(function(t){return t.id&&t.id===o.id});return n.splice(i,1),this},loop:function(t){return this.unwrap.loop=!!t,this.unwrap.loop?this.addToGroup("looping"):this.removeFromGroup("looping"),this},isLooping:function(){return!!this.unwrap.loop},toggleLoop:function(){return this.loop(!this.isLooping()),this},seek:function(t){return t<0?t=this.unwrap.duration-t:t>this.unwrap.duration&&(t=this.unwrap.duration),this.unwrap.currentTime=t,this},fadeIn:function(t){var e=this;t=t||1;var o=this.getVolume();return this.volume(0),this.play(),this.$el.animate({volume:o*r.master.volume},1e3*t,function(){e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeOut:function(t){t=t||1;var e=this,o=this.getVolume();return this.$el.animate({volume:0},1e3*t,function(){e.stop(),e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeTo:function(t,e){var o=this;if(t=t||1,e=Number(e),!Number.isNaN(e))return 1<e?e=1:e<0&&(e=0),this.$el.animate({volume:e*r.master.volume},1e3*t,function(){o.volume(e),c.emit(":volume",o),c.emit(":fade",o)}),this;alert("ivalid volume level")},delay:function(t,e){var o=this;"function"==typeof e&&(t=Number(t),(Number.isNaN(t)||t<0)&&(t=0),setTimeout(function(){e.call(o,o,t)},t))},on:function(t,e){return e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),a.track.includes(t)?void this.$el.on(t,e):(console.error("<track>.on() -> invalid event type"),this)):(console.error("<track>.on() -> invalid callback"),this)},one:function(t,e){return e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),a.track.includes(t)?void this.$el.one(t,e):(console.error("<track>.one() -> invalid event type"),this)):(console.error("<track>.one() -> invalid callback"),this)}};var l=a.track.concat(a.master);function d(t,e){if(!(this instanceof d))return new d(t,e);this.id=t,this.tracks=e.map(function(t){return c.get(t)}),this.looping=!1,this.current="",this.playing=!1}r.on=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).on(t,e):console.error("Chapel.Audio.on() -> invalid event type")):console.error("Chapel.Audio.on() -> invalid callback")},r.one=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).one(t,e):console.error("Chapel.Audio.one() -> invalid event type")):console.error("Chapel.Audio.one() -> invalid callback")},r.on(":master-mute",c.renew),r.on(":master-volume",c.renew),options.persistPrefs&&(r.on(":master-mute",r.savePrefs),r.on(":master-volume",r.savePrefs)),r.on(":play",function(t){t.track.addToGroup("playing")}),r.on(":stop",function(t){t.track.removeFromGroup("playing")}),options.muteOnBlur&&$(window).on("blur",function(){r.isMuted()||(r.mute(!0),$(window).one("focus",function(){r.mute(!1)}))}),r.classes.Track=c,r.newTrack=c.add,r.track=c.get,r.createGroup=function(t,e,o){!function(t,e){e&&Array.isArray(e)||(e=[]),r.groups.custom[t]=e.map(function(t){return c.get(t)})}(t,o?[].slice.call(arguments).slice(1):e)},r.group=function(t){if(!(this instanceof r.group))return new r.group(t);Object.keys(r.groups.custom).includes(t)?this.members=r.groups.custom[t]:this.members=r.groups[t],Array.isArray(this.members)||(this.members=[],console.error('Could not find members for track group "'+t+'"!'))},r.group.is=function(t){return this instanceof r.group},r.group.runOnAll=function(t,e,o){t.members.forEach(function(t){t[e].apply(t,o&&Array.isArray(o)?o:[])})},r.group.extend=function(t){i(r.group,t)},r.group.extendPrototype=function(t){i(r.group.prototype,t)},r.group.prototype={constructor:r.group,run:function(t,e,o){null!=o&&(e=[].slice.call(arguments).slice(1)),c.prototype.hasOwnProperty(t)&&r.group.runOnAll(this,t,e)},play:function(){return this.run("play"),this},pause:function(){return this.run("pause"),this},stop:function(){return this.run("stop"),this},mute:function(t){return this.run("mute",[t]),this},volume:function(t){return this.run("volume",[t]),this},loop:function(t){return this.run("loop",[t]),this}},d.list={},d.is=function(t){return t instanceof d},d.add=function(t,e,o){return o&&(e=[].slice.call(arguments).slice(1)),d.list[t]=new d(t,e),d.list[t]},d.extend=function(t){i(d,t)},d.extendPrototype=function(t){i(d.prototype,t)},d.prototype={constructor:d,clone:function(){return new d(this.id,this.tracks.map(function(t){return t.id}))},shuffle:function(){var t,e,o,n=this.tracks;for(o=n.length-1;0<o;o--)t=Math.floor(Math.random()*(o+1)),e=n[o],n[o]=n[t],n[t]=e;return this.tracks=n,this},random:function(){return this.tracks[Math.floor(Math.random()*this.tracks.length)]},isPlaying:function(){return this.playing},play:function(t){var e=this;if((t=t||(e.current?e.tracks.findIndex(function(t){return t.id===e.current}):0))>=e.tracks.length&&e.looping)t=0;else if(t>=e.tracks.length)return e.current="",void(e.playing=!1);var o=e.tracks[t],n=o.isLooping();return o.loop(!1),o.play(),e.playing=!0,setTimeout(function(){o.isPlaying()||(e.playing=!1)},20),e.current=o.id,o.$el.one("ended.playlist",function(){t++,o.loop(n),e.play(t)}),e},loop:function(t){return this.looping=!!t,this},stop:function(){var t=c.get(this.current);return t.stop(),t.$el.off(".playlist"),this.current="",this.playing=!1,this},pause:function(){return c.get(this.current).pause(),this.playing=!1,this}},r.classes.Playlist=d,r.createPlaylist=d.add,r.playlist=function(t){return d.list[t]||null},r.extend=function(t){i(r,t)},r.extendTrack=c.extend,r.extendTrackProto=c.extendPrototype,r.extendGroup=r.group.extend,r.extendGroupProto=r.group.extendPrototype,r.extendPlaylist=d.extend,r.extendPlaylistProto=d.extendPrototype,window.Chapel=window.Chapel||{},window.Chapel.Audio=r,options.persistPrefs&&r.loadPrefs()}(),function(){"use strict";if(options.controls.show){var t=$(document.createElement("div")).attr("id","story-menu").css("display","none"),e=$(document.createElement("span")).attr("id","vol-title").append("Volume");options.controls.volumeDisplay||e.css("display","none");var o=$(document.createElement("input")).attr({id:"audio-volume",type:"range",min:1,max:99,step:1,title:"Volume"}),n=Math.trunc(100*window.Chapel.Audio.master.volume);n<0?n=0:100<n&&(n=100),o.attr("value",n);var i=function(t){void 0===t&&(t=o.val()),e.empty().append("Volume "+t)};o.on("input",function(){window.Chapel.Audio.volume($(this).val()/100),i($(this).val())});var r=$(document.createElement("tw-link")).attr({id:"audio-mute",title:"Mute"}).append("Mute <span></span>").on("click",function(t){t.preventDefault(),$(this).toggleClass("muted"),Chapel.Audio.mute(!Chapel.Audio.isMuted())});Chapel.Audio.isMuted()&&r.addClass("muted");var a=$(document.createElement("tw-link")).attr("id","audio-panel-toggle").on("click",function(t){t.preventDefault(),s.toggleClass("closed")}),s=$(document.createElement("div")).attr("id","audio-controls").append(t,e,o,r,a).appendTo(document.body);options.controls.startClosed&&s.addClass("closed"),window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.controls={$panel:s,$volume:o,$mute:r,$user:t,close:function(){s.addClass("closed")},open:function(){s.removeClass("closed")},toggle:function(){s.toggleClass("closed")},hide:function(){s.css("display","none")},show:function(){s.css("display","block")},updateVolume:i}}}(),function(t){(jQuery.browser=jQuery.browser||{}).mobile=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4))}(navigator.userAgent||navigator.vendor||window.opera),function(){"use strict";var e=State,t=$(document.createElement("div")).attr("id","audio-overlay").css("display","none").appendTo(document.body);function o(){t.css("display","block").append('<div class="lds-ring"><div></div><div></div><div></div><div></div></div>')}function s(){t.fadeOut(function(){t.empty()})}window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.loadScreen={show:o,dismiss:s,kill:function(){$("#audio-overlay").remove()}},window.Chapel.Audio.$overlay=t,window.Chapel.Audio.preload=function(){if(!(e.pastLength||e.futureLength||$.browser.mobile)){$(document).ready(function(){o()});var i=100+options.loadDelay,t=Chapel.Audio.classes.Track.list,r=Chapel.Audio.loaded;if(t.length){var a=t.map(function(t){return t.id});options.forceDismiss&&setTimeout(function(){s()},options.loadLimit.total),function t(){if(a.length){var e=a.shift();if(r.includes(e))t();else{var o=Chapel.Audio.classes.Track.get(e);if(o.unwrap.readyState<2){var n=!1;o.$el.one("canplay",function(){t(),n=!0}),setTimeout(function(){n||(o.$el.off("canplay"),t())},options.loadLimit.track)}else r.includes(e)||r.push(e),t()}}else setTimeout(s,i)}()}else setTimeout(s,i)}}}(),function(){"use strict";var t,e,o=options.storagekey+"_hal_restart_",n=(window.sessionStorage?(t=function(t,e){window.sessionStorage.setItem(o+t,e)},e=function(t){return window.sessionStorage.getItem(o+t)}):(t=function(){},e=function(){},console.warn("Session storage is unavailable...")),{save:t,load:e});window.Chapel.Audio.state={_store:n,saveTracks:function(){var t;try{t=Chapel.Audio.classes.Track.list.map(function(t){return{id:t.id,sources:t.sources}}),t=JSON.stringify(t),n.save("tracks",t)}catch(t){console.error(t.message)}},loadTracks:function(){var t;try{t=(t=n.load("tracks"))&&JSON.parse(t),Array.isArray(t)&&t.length&&t.forEach(function(t){t.id&&t.sources&&!Chapel.Audio.classes.Track.has(t.id)?Chapel.Audio.newTrack.apply(null,[t.id].concat(t.sources)):console.warn("Track reload failed...")})}catch(t){console.error(t.message)}},savePlaylists:function(){var t;try{var o=Chapel.Audio.classes.Playlist.list;t=Object.keys(o).map(function(t){var e={};return e.tracks=o[t].tracks.map(function(t){return t.id}),e.id=o[t].id,e}),t=JSON.stringify(t),n.save("playlists",t)}catch(t){console.error(t.message)}},loadPlaylists:function(){var t;try{(t=(t=n.load("playlists"))&&JSON.parse(t))&&Array.isArray(t)&&t.length&&t.forEach(function(t){t.id&&t.tracks&&Chapel.Audio.createPlaylist(t.id,t.tracks)})}catch(t){console.error(t.message)}},saveGroups:function(){var e;try{e={},Object.keys(Chapel.Audio.groups.custom).forEach(function(t){e[t]=Chapel.Audio.groups.custom[t].map(function(t){return"string"==typeof t?t:t.id})}),e=JSON.stringify(e),n.save("groups",e)}catch(t){console.error(t.message)}},loadGroups:function(){var e;try{(e=(e=n.load("groups"))&&JSON.parse(e))&&"object"==typeof e&&(Object.keys(e).forEach(function(t){e[t].map(function(t){return Chapel.Audio.classes.Track.get(t)})}),Chapel.Audio.groups.custom=e)}catch(t){console.error(t.message)}}}}(),function(){"use strict";options.globalA&&void 0===window.A&&(window.A=window.Chapel.Audio),$(document).on("unload",function(){window.Chapel.Audio.savePrefs()}),Chapel.Audio.classes.Track.renew(),Chapel.Audio.controls&&Chapel.Audio.controls.updateVolume(),Chapel.Get.isHarlowe3OrLater&&($(window).on("unload",function(){Chapel.Audio.state.saveTracks(),Chapel.Audio.state.savePlaylists(),Chapel.Audio.state.saveGroups()}),Chapel.Audio.state.loadTracks(),Chapel.Audio.state.loadPlaylists(),Chapel.Audio.state.loadGroups())}(),function(){"use strict";if(options.controls.show){var s=Engine,u=Chapel.Audio.controls.$user,t=function(){return"none"!==u.css("display")},c=function(){return t()||u.css("display","block"),u},e=function(){return t()&&u.css("display","none"),u};Chapel.Audio.menu={hide:e,show:c,isShown:t,links:{add:function(t,e,o){var n,i;if(!t||"string"!=typeof t){var r="undefined";return alert(r),void console.error(r)}o||"function"!=typeof e?(e&&"string"==typeof e&&(n=e),o&&"function"==typeof o&&(i=o)):(i=e,n=null);var a=$(document.createElement("tw-link")).append(t).attr({tabindex:"0",name:t.toLowerCase().trim()}).on("click",function(){n&&s.goToPassage(n),i&&i()}).addClass("story-menu").appendTo(u);return c(),a},clear:function(){return u.empty(),e()},hide:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').addClass("hide")},show:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').removeClass("hide")},toggle:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').toggleClass("hide")},remove:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').remove()}}}}}(),function(){"use strict";var e=window.prompt;window.prompt=function(){var t=e.apply(null,[].slice.call(arguments));return function(t){var e=(new DOMParser).parseFromString(t,"text/html");return Array.from(e.body.childNodes).some(function(t){return 1===t.nodeType})}(t)?t.replace(/[<>]/g,""):t}}();
+
+}());
+/* twine-user-script #2: "story-menu" */
+A.menu.links.add('Navigate', 'other passage');
+A.menu.links.add('Alert', function () {
+    alert('This is an alert.');
+});
+A.menu.links.add('Both', 'other passage', function () {
+    alert('This is an alert.');
+});
+A.menu.links.add('Removes self.', function () {
+    A.menu.links.remove('Removes self.');
+});</script><tw-passagedata pid="1" name="audio-init" tags="startup" position="100,100">&lt;script&gt;
     A.newTrack(&#39;beep&#39;, &#39;./audio/beep.mp3&#39;, &#39;./audio/beep.ogg&#39;);
     A.newTrack(&#39;nope&#39;, &#39;./audio/no.mp3&#39;, &#39;./audio/no.ogg&#39;);
     A.newTrack(&#39;cibelle&#39;, &#39;./audio/cibelle.mp3&#39;, &#39;./audio/cibelle.ogg&#39;);
@@ -52,20 +63,10 @@
     A.createGroup(&#39;tests&#39;, &#39;beep&#39;, &#39;nope&#39;);
     A.createGroup(&#39;bgm&#39;, &#39;cibelle&#39;, &#39;que-pena&#39;);
     A.createPlaylist(&#39;bgm&#39;, &#39;cibelle&#39;, &#39;que-pena&#39;);
+    A.createPlaylist(&#39;test&#39;, &#39;beep&#39;, &#39;nope&#39;);
 
     A.preload();
-&lt;/script&gt;</tw-passagedata><tw-passagedata pid="2" name="story-menu" tags="startup" position="225,100">&lt;script&gt;
-    A.menu.links.add(&#39;Navigate&#39;, &#39;other passage&#39;);
-    A.menu.links.add(&#39;Alert&#39;, function () {
-        alert(&#39;This is an alert.&#39;);
-    });
-    A.menu.links.add(&#39;Both&#39;, &#39;other passage&#39;, function () {
-        alert(&#39;This is an alert.&#39;);
-    });
-    A.menu.links.add(&#39;Removes self.&#39;, function () {
-        A.menu.links.remove(&#39;Removes self.&#39;);
-    });
-&lt;/script&gt;</tw-passagedata><tw-passagedata pid="3" name="Start" tags="" position="350,100">&lt;script&gt;A.playlist(&#39;bgm&#39;).random().loop(true).playWhenPossible();&lt;/script&gt;\
+&lt;/script&gt;</tw-passagedata><tw-passagedata pid="2" name="Start" tags="" position="225,100">&lt;script&gt;A.playlist(&#39;bgm&#39;).random().loop(true).playWhenPossible();&lt;/script&gt;\
 Welcome to the Harlowe Audio Library demo!
 
 * (link-repeat: &quot;View this demo&#39;s source code.&quot;)[(open-url: &#39;https://github.com/ChapelR/harlowe-audio/tree/master/docs/demo&#39;)]
@@ -130,17 +131,34 @@
         A.group(&#39;bgm&#39;).mute(false);
     &lt;/script&gt;
 ]
-}</tw-passagedata><tw-passagedata pid="4" name="other passage" tags="" position="475,100">This is another passage!
+}
+&lt;!--
+[[stop test]]
+[[playlist test]]
+--&gt;</tw-passagedata><tw-passagedata pid="3" name="other passage" tags="" position="350,100">This is another passage!
 
-[[Go back.|Start]]</tw-passagedata></tw-storydata>
+[[Go back.|Start]]</tw-passagedata><tw-passagedata pid="4" name="stop test" tags="" position="475,100">&lt;span id=&#39;counter-test&#39;&gt;0&lt;/span&gt;
+(link-repeat: &#39;test&#39;)[
+    &lt;script&gt;
+        A.track(&#39;beep&#39;).play();
+        A.track(&#39;beep&#39;).one(&#39;:stop&#39;, function () {
+            var x = Number($(&#39;#counter-test&#39;).text())
+            $(&#39;#counter-test&#39;).empty().append(++x);
+        });
+    &lt;/script&gt;
+]</tw-passagedata><tw-passagedata pid="5" name="playlist test" tags="" position="600,100">(link-repeat: &#39;test&#39;)[
+    &lt;script&gt;
+        A.playlist(&#39;test&#39;).loop(true).play();
+    &lt;/script&gt;
+]</tw-passagedata></tw-storydata>
 
 <script title="Twine engine code" data-main="harlowe">"use strict";function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _toConsumableArray(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var _slicedToArray=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(){/**
  * @license almond 0.3.3 Copyright jQuery Foundation and other contributors.
  * Released under MIT license, http://github.com/requirejs/almond/LICENSE
  */
-var requirejs,require,define;!function(e){function t(e,t){return v.call(e,t)}function n(e,t){var n,r,i,o,a,s,u,c,l,f,p,d,h=t&&t.split("/"),m=g.map,y=m&&m["*"]||{};if(e){for(e=e.split("/"),a=e.length-1,g.nodeIdCompat&&w.test(e[a])&&(e[a]=e[a].replace(w,"")),"."===e[0].charAt(0)&&h&&(d=h.slice(0,h.length-1),e=d.concat(e)),l=0;l<e.length;l++)if(p=e[l],"."===p)e.splice(l,1),l-=1;else if(".."===p){if(0===l||1===l&&".."===e[2]||".."===e[l-1])continue;l>0&&(e.splice(l-1,2),l-=2)}e=e.join("/")}if((h||y)&&m){for(n=e.split("/"),l=n.length;l>0;l-=1){if(r=n.slice(0,l).join("/"),h)for(f=h.length;f>0;f-=1)if(i=m[h.slice(0,f).join("/")],i&&(i=i[r])){o=i,s=l;break}if(o)break;!u&&y&&y[r]&&(u=y[r],c=l)}!o&&u&&(o=u,s=c),o&&(n.splice(0,s,o),e=n.join("/"))}return e}function r(t,n){return function(){var r=b.call(arguments,0);return"string"!=typeof r[0]&&1===r.length&&r.push(null),f.apply(e,r.concat([t,n]))}}function i(e){return function(t){return n(t,e)}}function o(e){return function(t){h[e]=t}}function a(n){if(t(m,n)){var r=m[n];delete m[n],y[n]=!0,l.apply(e,r)}if(!t(h,n)&&!t(y,n))throw new Error("No "+n);return h[n]}function s(e){var t,n=e?e.indexOf("!"):-1;return n>-1&&(t=e.substring(0,n),e=e.substring(n+1,e.length)),[t,e]}function u(e){return e?s(e):[]}function c(e){return function(){return g&&g.config&&g.config[e]||{}}}var l,f,p,d,h={},m={},g={},y={},v=Object.prototype.hasOwnProperty,b=[].slice,w=/\.js$/;p=function(e,t){var r,o=s(e),u=o[0],c=t[1];return e=o[1],u&&(u=n(u,c),r=a(u)),u?e=r&&r.normalize?r.normalize(e,i(c)):n(e,c):(e=n(e,c),o=s(e),u=o[0],e=o[1],u&&(r=a(u))),{f:u?u+"!"+e:e,n:e,pr:u,p:r}},d={require:function(e){return r(e)},exports:function(e){var t=h[e];return"undefined"!=typeof t?t:h[e]={}},module:function(e){return{id:e,uri:"",exports:h[e],config:c(e)}}},l=function(n,i,s,c){var l,f,g,v,b,w,x,T=[],S="undefined"==typeof s?"undefined":_typeof(s);if(c=c||n,w=u(c),"undefined"===S||"function"===S){for(i=!i.length&&s.length?["require","exports","module"]:i,b=0;b<i.length;b+=1)if(v=p(i[b],w),f=v.f,"require"===f)T[b]=d.require(n);else if("exports"===f)T[b]=d.exports(n),x=!0;else if("module"===f)l=T[b]=d.module(n);else if(t(h,f)||t(m,f)||t(y,f))T[b]=a(f);else{if(!v.p)throw new Error(n+" missing "+f);v.p.load(v.n,r(c,!0),o(f),{}),T[b]=h[f]}g=s?s.apply(h[n],T):void 0,n&&(l&&l.exports!==e&&l.exports!==h[n]?h[n]=l.exports:g===e&&x||(h[n]=g))}else n&&(h[n]=s)},requirejs=require=f=function(t,n,r,i,o){if("string"==typeof t)return d[t]?d[t](n):a(p(t,u(n)).f);if(!t.splice){if(g=t,g.deps&&f(g.deps,g.callback),!n)return;n.splice?(t=n,n=r,r=null):t=e}return n=n||function(){},"function"==typeof r&&(r=i,i=o),i?l(e,t,n,r):setTimeout(function(){l(e,t,n,r)},4),f},f.config=function(e){return f(e)},requirejs._defined=h,define=function(e,n,r){if("string"!=typeof e)throw new Error("See almond README: incorrect module build, no module name");n.splice||(r=n,n=[]),t(h,e)||t(m,e)||(m[e]=[e,n,r])},define.amd={jQuery:!0}}(),define("almond",function(){}),function(e,t){"object"===("undefined"==typeof module?"undefined":_typeof(module))&&"object"===_typeof(module.exports)?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){function n(e,t){t=t||te;var n=t.createElement("script");n.text=e,t.head.appendChild(n).parentNode.removeChild(n)}function r(e){var t=!!e&&"length"in e&&e.length,n=he.type(e);return"function"===n||he.isWindow(e)?!1:"array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e}function i(e,t,n){return he.isFunction(t)?he.grep(e,function(e,r){return!!t.call(e,r,e)!==n}):t.nodeType?he.grep(e,function(e){return e===t!==n}):"string"!=typeof t?he.grep(e,function(e){return ae.call(t,e)>-1!==n}):Oe.test(t)?he.filter(t,e,n):(t=he.filter(t,e),he.grep(e,function(e){return ae.call(t,e)>-1!==n&&1===e.nodeType}))}function o(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}function a(e){var t={};return he.each(e.match(Ne)||[],function(e,n){t[n]=!0}),t}function s(e){return e}function u(e){throw e}function c(e,t,n){var r;try{e&&he.isFunction(r=e.promise)?r.call(e).done(t).fail(n):e&&he.isFunction(r=e.then)?r.call(e,t,n):t.call(void 0,e)}catch(e){n.call(void 0,e)}}function l(){te.removeEventListener("DOMContentLoaded",l),e.removeEventListener("load",l),he.ready()}function f(){this.expando=he.expando+f.uid++}function p(e){return"true"===e?!0:"false"===e?!1:"null"===e?null:e===+e+""?+e:De.test(e)?JSON.parse(e):e}function d(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(qe,"-$&").toLowerCase(),n=e.getAttribute(r),"string"==typeof n){try{n=p(n)}catch(e){}Fe.set(e,t,n)}else n=void 0;return n}function h(e,t,n,r){var i,o=1,a=20,s=r?function(){return r.cur()}:function(){return he.css(e,t,"")},u=s(),c=n&&n[3]||(he.cssNumber[t]?"":"px"),l=(he.cssNumber[t]||"px"!==c&&+u)&&He.exec(he.css(e,t));if(l&&l[3]!==c){c=c||l[3],n=n||[],l=+u||1;do o=o||".5",l/=o,he.style(e,t,l+c);while(o!==(o=s()/u)&&1!==o&&--a)}return n&&(l=+l||+u||0,i=n[1]?l+(n[1]+1)*n[2]:+n[2],r&&(r.unit=c,r.start=l,r.end=i)),i}function m(e){var t,n=e.ownerDocument,r=e.nodeName,i=We[r];return i?i:(t=n.body.appendChild(n.createElement(r)),i=he.css(t,"display"),t.parentNode.removeChild(t),"none"===i&&(i="block"),We[r]=i,i)}function g(e,t){for(var n,r,i=[],o=0,a=e.length;a>o;o++)r=e[o],r.style&&(n=r.style.display,t?("none"===n&&(i[o]=Le.get(r,"display")||null,i[o]||(r.style.display="")),""===r.style.display&&Be(r)&&(i[o]=m(r))):"none"!==n&&(i[o]="none",Le.set(r,"display",n)));for(o=0;a>o;o++)null!=i[o]&&(e[o].style.display=i[o]);return e}function y(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&he.nodeName(e,t)?he.merge([e],n):n}function v(e,t){for(var n=0,r=e.length;r>n;n++)Le.set(e[n],"globalEval",!t||Le.get(t[n],"globalEval"))}function b(e,t,n,r,i){for(var o,a,s,u,c,l,f=t.createDocumentFragment(),p=[],d=0,h=e.length;h>d;d++)if(o=e[d],o||0===o)if("object"===he.type(o))he.merge(p,o.nodeType?[o]:o);else if(Je.test(o)){for(a=a||f.appendChild(t.createElement("div")),s=(Ue.exec(o)||["",""])[1].toLowerCase(),u=Xe[s]||Xe._default,a.innerHTML=u[1]+he.htmlPrefilter(o)+u[2],l=u[0];l--;)a=a.lastChild;he.merge(p,a.childNodes),a=f.firstChild,a.textContent=""}else p.push(t.createTextNode(o));for(f.textContent="",d=0;o=p[d++];)if(r&&he.inArray(o,r)>-1)i&&i.push(o);else if(c=he.contains(o.ownerDocument,o),a=y(f.appendChild(o),"script"),c&&v(a),n)for(l=0;o=a[l++];)Ge.test(o.type||"")&&n.push(o);return f}function w(){return!0}function x(){return!1}function T(){try{return te.activeElement}catch(e){}}function S(e,t,n,r,i,o){var a,s;if("object"===("undefined"==typeof t?"undefined":_typeof(t))){"string"!=typeof n&&(r=r||n,n=void 0);for(s in t)S(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),i===!1)i=x;else if(!i)return e;return 1===o&&(a=i,i=function(e){return he().off(e),a.apply(this,arguments)},i.guid=a.guid||(a.guid=he.guid++)),e.each(function(){he.event.add(this,t,i,r,n)})}function O(e,t){return he.nodeName(e,"table")&&he.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e:e}function j(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function k(e){var t=rt.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function C(e,t){var n,r,i,o,a,s,u,c;if(1===t.nodeType){if(Le.hasData(e)&&(o=Le.access(e),a=Le.set(t,o),c=o.events)){delete a.handle,a.events={};for(i in c)for(n=0,r=c[i].length;r>n;n++)he.event.add(t,i,c[i][n])}Fe.hasData(e)&&(s=Fe.access(e),u=he.extend({},s),Fe.set(t,u))}}function A(e,t){var n=t.nodeName.toLowerCase();"input"===n&&ze.test(e.type)?t.checked=e.checked:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}function E(e,t,r,i){t=ie.apply([],t);var o,a,s,u,c,l,f=0,p=e.length,d=p-1,h=t[0],m=he.isFunction(h);if(m||p>1&&"string"==typeof h&&!pe.checkClone&&nt.test(h))return e.each(function(n){var o=e.eq(n);m&&(t[0]=h.call(this,n,o.html())),E(o,t,r,i)});if(p&&(o=b(t,e[0].ownerDocument,!1,e,i),a=o.firstChild,1===o.childNodes.length&&(o=a),a||i)){for(s=he.map(y(o,"script"),j),u=s.length;p>f;f++)c=o,f!==d&&(c=he.clone(c,!0,!0),u&&he.merge(s,y(c,"script"))),r.call(e[f],c,f);if(u)for(l=s[s.length-1].ownerDocument,he.map(s,k),f=0;u>f;f++)c=s[f],Ge.test(c.type||"")&&!Le.access(c,"globalEval")&&he.contains(l,c)&&(c.src?he._evalUrl&&he._evalUrl(c.src):n(c.textContent.replace(it,""),l))}return e}function N(e,t,n){for(var r,i=t?he.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||he.cleanData(y(r)),r.parentNode&&(n&&he.contains(r.ownerDocument,r)&&v(y(r,"script")),r.parentNode.removeChild(r));return e}function _(e,t,n){var r,i,o,a,s=e.style;return n=n||st(e),n&&(a=n.getPropertyValue(t)||n[t],""!==a||he.contains(e.ownerDocument,e)||(a=he.style(e,t)),!pe.pixelMarginRight()&&at.test(a)&&ot.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function P(e,t){return{get:function(){return e()?void delete this.get:(this.get=t).apply(this,arguments)}}}function I(e){if(e in pt)return e;for(var t=e[0].toUpperCase()+e.slice(1),n=ft.length;n--;)if(e=ft[n]+t,e in pt)return e}function M(e,t,n){var r=He.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function L(e,t,n,r,i){var o,a=0;for(o=n===(r?"border":"content")?4:"width"===t?1:0;4>o;o+=2)"margin"===n&&(a+=he.css(e,n+$e[o],!0,i)),r?("content"===n&&(a-=he.css(e,"padding"+$e[o],!0,i)),"margin"!==n&&(a-=he.css(e,"border"+$e[o]+"Width",!0,i))):(a+=he.css(e,"padding"+$e[o],!0,i),"padding"!==n&&(a+=he.css(e,"border"+$e[o]+"Width",!0,i)));return a}function F(e,t,n){var r,i=!0,o=st(e),a="border-box"===he.css(e,"boxSizing",!1,o);if(e.getClientRects().length&&(r=e.getBoundingClientRect()[t]),0>=r||null==r){if(r=_(e,t,o),(0>r||null==r)&&(r=e.style[t]),at.test(r))return r;i=a&&(pe.boxSizingReliable()||r===e.style[t]),r=parseFloat(r)||0}return r+L(e,t,n||(a?"border":"content"),i,o)+"px"}function D(e,t,n,r,i){return new D.prototype.init(e,t,n,r,i)}function q(){ht&&(e.requestAnimationFrame(q),he.fx.tick())}function R(){return e.setTimeout(function(){dt=void 0}),dt=he.now()}function H(e,t){var n,r=0,i={height:e};for(t=t?1:0;4>r;r+=2-t)n=$e[r],i["margin"+n]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function $(e,t,n){for(var r,i=(W.tweeners[t]||[]).concat(W.tweeners["*"]),o=0,a=i.length;a>o;o++)if(r=i[o].call(n,t,e))return r}function B(e,t,n){var r,i,o,a,s,u,c,l,f="width"in t||"height"in t,p=this,d={},h=e.style,m=e.nodeType&&Be(e),y=Le.get(e,"fxshow");n.queue||(a=he._queueHooks(e,"fx"),null==a.unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,he.queue(e,"fx").length||a.empty.fire()})}));for(r in t)if(i=t[r],mt.test(i)){if(delete t[r],o=o||"toggle"===i,i===(m?"hide":"show")){if("show"!==i||!y||void 0===y[r])continue;m=!0}d[r]=y&&y[r]||he.style(e,r)}if(u=!he.isEmptyObject(t),u||!he.isEmptyObject(d)){f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],c=y&&y.display,null==c&&(c=Le.get(e,"display")),l=he.css(e,"display"),"none"===l&&(c?l=c:(g([e],!0),c=e.style.display||c,l=he.css(e,"display"),g([e]))),("inline"===l||"inline-block"===l&&null!=c)&&"none"===he.css(e,"float")&&(u||(p.done(function(){h.display=c}),null==c&&(l=h.display,c="none"===l?"":l)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),u=!1;for(r in d)u||(y?"hidden"in y&&(m=y.hidden):y=Le.access(e,"fxshow",{display:c}),o&&(y.hidden=!m),m&&g([e],!0),p.done(function(){m||g([e]),Le.remove(e,"fxshow");for(r in d)he.style(e,r,d[r])})),u=$(m?y[r]:0,r,p),r in y||(y[r]=u.start,m&&(u.end=u.start,u.start=0))}}function V(e,t){var n,r,i,o,a;for(n in e)if(r=he.camelCase(n),i=t[r],o=e[n],he.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=he.cssHooks[r],a&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}function W(e,t,n){var r,i,o=0,a=W.prefilters.length,s=he.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;for(var t=dt||R(),n=Math.max(0,c.startTime+c.duration-t),r=n/c.duration||0,o=1-r,a=0,u=c.tweens.length;u>a;a++)c.tweens[a].run(o);return s.notifyWith(e,[c,o,n]),1>o&&u?n:(s.resolveWith(e,[c]),!1)},c=s.promise({elem:e,props:he.extend({},t),opts:he.extend(!0,{specialEasing:{},easing:he.easing._default},n),originalProperties:t,originalOptions:n,startTime:dt||R(),duration:n.duration,tweens:[],createTween:function(t,n){var r=he.Tween(e,c.opts,t,n,c.opts.specialEasing[t]||c.opts.easing);return c.tweens.push(r),r},stop:function(t){var n=0,r=t?c.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)c.tweens[n].run(1);return t?(s.notifyWith(e,[c,1,0]),s.resolveWith(e,[c,t])):s.rejectWith(e,[c,t]),this}}),l=c.props;for(V(l,c.opts.specialEasing);a>o;o++)if(r=W.prefilters[o].call(c,e,l,c.opts))return he.isFunction(r.stop)&&(he._queueHooks(c.elem,c.opts.queue).stop=he.proxy(r.stop,r)),r;return he.map(l,$,c),he.isFunction(c.opts.start)&&c.opts.start.call(e,c),he.fx.timer(he.extend(u,{elem:e,anim:c,queue:c.opts.queue})),c.progress(c.opts.progress).done(c.opts.done,c.opts.complete).fail(c.opts.fail).always(c.opts.always)}function z(e){var t=e.match(Ne)||[];return t.join(" ")}function U(e){return e.getAttribute&&e.getAttribute("class")||""}function G(e,t,n,r){var i;if(he.isArray(t))he.each(t,function(t,i){n||kt.test(e)?r(e,i):G(e+"["+("object"===("undefined"==typeof i?"undefined":_typeof(i))&&null!=i?t:"")+"]",i,n,r)});else if(n||"object"!==he.type(t))r(e,t);else for(i in t)G(e+"["+i+"]",t[i],n,r)}function X(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(Ne)||[];if(he.isFunction(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function J(e,t,n,r){function i(s){var u;return o[s]=!0,he.each(e[s]||[],function(e,s){var c=s(t,n,r);return"string"!=typeof c||a||o[c]?a?!(u=c):void 0:(t.dataTypes.unshift(c),i(c),!1)}),u}var o={},a=e===qt;return i(t.dataTypes[0])||!o["*"]&&i("*")}function Y(e,t){var n,r,i=he.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&he.extend(!0,e,r),e}function Z(e,t,n){for(var r,i,o,a,s=e.contents,u=e.dataTypes;"*"===u[0];)u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+" "+u[0]]){o=i;break}a||(a=i)}o=o||a}return o?(o!==u[0]&&u.unshift(o),n[o]):void 0}function Q(e,t,n,r){var i,o,a,s,u,c={},l=e.dataTypes.slice();if(l[1])for(a in e.converters)c[a.toLowerCase()]=e.converters[a];for(o=l.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=l.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(a=c[u+" "+o]||c["* "+o],!a)for(i in c)if(s=i.split(" "),s[1]===o&&(a=c[u+" "+s[0]]||c["* "+s[0]])){a===!0?a=c[i]:c[i]!==!0&&(o=s[0],l.unshift(s[1]));break}if(a!==!0)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}function K(e){return he.isWindow(e)?e:9===e.nodeType&&e.defaultView}var ee=[],te=e.document,ne=Object.getPrototypeOf,re=ee.slice,ie=ee.concat,oe=ee.push,ae=ee.indexOf,se={},ue=se.toString,ce=se.hasOwnProperty,le=ce.toString,fe=le.call(Object),pe={},de="3.1.1",he=function e(t,n){return new e.fn.init(t,n)},me=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,ge=/^-ms-/,ye=/-([a-z])/g,ve=function(e,t){return t.toUpperCase()};he.fn=he.prototype={jquery:de,constructor:he,length:0,toArray:function(){return re.call(this)},get:function(e){return null==e?re.call(this):0>e?this[e+this.length]:this[e]},pushStack:function(e){var t=he.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return he.each(this,e)},map:function(e){return this.pushStack(he.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(re.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:oe,sort:ee.sort,splice:ee.splice},he.extend=he.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,c=!1;for("boolean"==typeof a&&(c=a,a=arguments[s]||{},s++),"object"===("undefined"==typeof a?"undefined":_typeof(a))||he.isFunction(a)||(a={}),s===u&&(a=this,s--);u>s;s++)if(null!=(e=arguments[s]))for(t in e)n=a[t],r=e[t],a!==r&&(c&&r&&(he.isPlainObject(r)||(i=he.isArray(r)))?(i?(i=!1,o=n&&he.isArray(n)?n:[]):o=n&&he.isPlainObject(n)?n:{},a[t]=he.extend(c,o,r)):void 0!==r&&(a[t]=r));return a},he.extend({expando:"jQuery"+(de+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===he.type(e)},isArray:Array.isArray,isWindow:function(e){return null!=e&&e===e.window},isNumeric:function(e){var t=he.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},isPlainObject:function(e){var t,n;return e&&"[object Object]"===ue.call(e)?(t=ne(e))?(n=ce.call(t,"constructor")&&t.constructor,"function"==typeof n&&le.call(n)===fe):!0:!1},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},type:function(e){return null==e?e+"":"object"===("undefined"==typeof e?"undefined":_typeof(e))||"function"==typeof e?se[ue.call(e)]||"object":"undefined"==typeof e?"undefined":_typeof(e)},globalEval:function(e){n(e)},camelCase:function(e){return e.replace(ge,"ms-").replace(ye,ve)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t){var n,i=0;if(r(e))for(n=e.length;n>i&&t.call(e[i],i,e[i])!==!1;i++);else for(i in e)if(t.call(e[i],i,e[i])===!1)break;return e},trim:function(e){return null==e?"":(e+"").replace(me,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(r(Object(e))?he.merge(n,"string"==typeof e?[e]:e):oe.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:ae.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;n>r;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r,i=[],o=0,a=e.length,s=!n;a>o;o++)r=!t(e[o],o),r!==s&&i.push(e[o]);return i},map:function(e,t,n){var i,o,a=0,s=[];if(r(e))for(i=e.length;i>a;a++)o=t(e[a],a,n),null!=o&&s.push(o);else for(a in e)o=t(e[a],a,n),null!=o&&s.push(o);return ie.apply([],s)},guid:1,proxy:function e(t,n){var r,i,e;return"string"==typeof n&&(r=t[n],n=t,t=r),he.isFunction(t)?(i=re.call(arguments,2),e=function(){return t.apply(n||this,i.concat(re.call(arguments)))},e.guid=t.guid=t.guid||he.guid++,e):void 0},now:Date.now,support:pe}),"function"==typeof Symbol&&(he.fn[Symbol.iterator]=ee[Symbol.iterator]),he.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){se["[object "+t+"]"]=t.toLowerCase()});var be=function(e){function t(e,t,n,r){var i,o,a,s,u,c,l,p=t&&t.ownerDocument,h=t?t.nodeType:9;if(n=n||[],"string"!=typeof e||!e||1!==h&&9!==h&&11!==h)return n;if(!r&&((t?t.ownerDocument||t:$)!==I&&P(t),t=t||I,L)){if(11!==h&&(u=ye.exec(e)))if(i=u[1]){if(9===h){if(!(a=t.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(p&&(a=p.getElementById(i))&&R(t,a)&&a.id===i)return n.push(a),n}else{if(u[2])return Q.apply(n,t.getElementsByTagName(e)),n;if((i=u[3])&&T.getElementsByClassName&&t.getElementsByClassName)return Q.apply(n,t.getElementsByClassName(i)),n}if(!(!T.qsa||U[e+" "]||F&&F.test(e))){if(1!==h)p=t,l=e;else if("object"!==t.nodeName.toLowerCase()){for((s=t.getAttribute("id"))?s=s.replace(xe,Te):t.setAttribute("id",s=H),c=k(e),o=c.length;o--;)c[o]="#"+s+" "+d(c[o]);l=c.join(","),p=ve.test(e)&&f(t.parentNode)||t}if(l)try{return Q.apply(n,p.querySelectorAll(l)),n}catch(e){}finally{s===H&&t.removeAttribute("id")}}}return A(e.replace(se,"$1"),t,n,r)}function n(){function e(n,r){return t.push(n+" ")>S.cacheLength&&delete e[t.shift()],e[n+" "]=r}var t=[];return e}function r(e){return e[H]=!0,e}function i(e){var t=I.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function o(e,t){for(var n=e.split("|"),r=n.length;r--;)S.attrHandle[n[r]]=t}function a(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function s(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function u(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function c(e){return function(t){return"form"in t?t.parentNode&&t.disabled===!1?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&Oe(t)===e:t.disabled===e:"label"in t?t.disabled===e:!1}}function l(e){return r(function(t){return t=+t,r(function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function f(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}function p(){}function d(e){for(var t=0,n=e.length,r="";n>t;t++)r+=e[t].value;return r}function h(e,t,n){var r=t.dir,i=t.next,o=i||r,a=n&&"parentNode"===o,s=V++;return t.first?function(t,n,i){for(;t=t[r];)if(1===t.nodeType||a)return e(t,n,i);return!1}:function(t,n,u){var c,l,f,p=[B,s];if(u){for(;t=t[r];)if((1===t.nodeType||a)&&e(t,n,u))return!0}else for(;t=t[r];)if(1===t.nodeType||a)if(f=t[H]||(t[H]={}),l=f[t.uniqueID]||(f[t.uniqueID]={}),i&&i===t.nodeName.toLowerCase())t=t[r]||t;else{if((c=l[o])&&c[0]===B&&c[1]===s)return p[2]=c[2];if(l[o]=p,p[2]=e(t,n,u))return!0}return!1}}function m(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function g(e,n,r){for(var i=0,o=n.length;o>i;i++)t(e,n[i],r);return r}function y(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,c=null!=t;u>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),c&&t.push(s));return a}function v(e,t,n,i,o,a){return i&&!i[H]&&(i=v(i)),o&&!o[H]&&(o=v(o,a)),r(function(r,a,s,u){var c,l,f,p=[],d=[],h=a.length,m=r||g(t||"*",s.nodeType?[s]:s,[]),v=!e||!r&&t?m:y(m,p,e,s,u),b=n?o||(r?e:h||i)?[]:a:v;if(n&&n(v,b,s,u),i)for(c=y(b,d),i(c,[],s,u),l=c.length;l--;)(f=c[l])&&(b[d[l]]=!(v[d[l]]=f));if(r){if(o||e){if(o){for(c=[],l=b.length;l--;)(f=b[l])&&c.push(v[l]=f);o(null,b=[],c,u)}for(l=b.length;l--;)(f=b[l])&&(c=o?ee(r,f):p[l])>-1&&(r[c]=!(a[c]=f))}}else b=y(b===a?b.splice(h,b.length):b),o?o(null,a,b,u):Q.apply(a,b)})}function b(e){for(var t,n,r,i=e.length,o=S.relative[e[0].type],a=o||S.relative[" "],s=o?1:0,u=h(function(e){return e===t},a,!0),c=h(function(e){return ee(t,e)>-1},a,!0),l=[function(e,n,r){var i=!o&&(r||n!==E)||((t=n).nodeType?u(e,n,r):c(e,n,r));return t=null,i}];i>s;s++)if(n=S.relative[e[s].type])l=[h(m(l),n)];else{if(n=S.filter[e[s].type].apply(null,e[s].matches),n[H]){for(r=++s;i>r&&!S.relative[e[r].type];r++);return v(s>1&&m(l),s>1&&d(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(se,"$1"),n,r>s&&b(e.slice(s,r)),i>r&&b(e=e.slice(r)),i>r&&d(e))}l.push(n)}return m(l)}function w(e,n){var i=n.length>0,o=e.length>0,a=function(r,a,s,u,c){var l,f,p,d=0,h="0",m=r&&[],g=[],v=E,b=r||o&&S.find.TAG("*",c),w=B+=null==v?1:Math.random()||.1,x=b.length;for(c&&(E=a===I||a||c);h!==x&&null!=(l=b[h]);h++){if(o&&l){for(f=0,a||l.ownerDocument===I||(P(l),s=!L);p=e[f++];)if(p(l,a||I,s)){u.push(l);break}c&&(B=w)}i&&((l=!p&&l)&&d--,r&&m.push(l))}if(d+=h,i&&h!==d){for(f=0;p=n[f++];)p(m,g,a,s);if(r){if(d>0)for(;h--;)m[h]||g[h]||(g[h]=Y.call(u));g=y(g)}Q.apply(u,g),c&&!r&&g.length>0&&d+n.length>1&&t.uniqueSort(u)}return c&&(B=w,E=v),m};return i?r(a):a}var x,T,S,O,j,k,C,A,E,N,_,P,I,M,L,F,D,q,R,H="sizzle"+1*new Date,$=e.document,B=0,V=0,W=n(),z=n(),U=n(),G=function(e,t){return e===t&&(_=!0),0},X={}.hasOwnProperty,J=[],Y=J.pop,Z=J.push,Q=J.push,K=J.slice,ee=function(e,t){for(var n=0,r=e.length;r>n;n++)if(e[n]===t)return n;return-1},te="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",ne="[\\x20\\t\\r\\n\\f]",re="(?:\\\\.|[\\w-]|[^\x00-\\xa0])+",ie="\\["+ne+"*("+re+")(?:"+ne+"*([*^$|!~]?=)"+ne+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+re+"))|)"+ne+"*\\]",oe=":("+re+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+ie+")*)|.*)\\)|)",ae=new RegExp(ne+"+","g"),se=new RegExp("^"+ne+"+|((?:^|[^\\\\])(?:\\\\.)*)"+ne+"+$","g"),ue=new RegExp("^"+ne+"*,"+ne+"*"),ce=new RegExp("^"+ne+"*([>+~]|"+ne+")"+ne+"*"),le=new RegExp("="+ne+"*([^\\]'\"]*?)"+ne+"*\\]","g"),fe=new RegExp(oe),pe=new RegExp("^"+re+"$"),de={ID:new RegExp("^#("+re+")"),CLASS:new RegExp("^\\.("+re+")"),TAG:new RegExp("^("+re+"|[*])"),ATTR:new RegExp("^"+ie),PSEUDO:new RegExp("^"+oe),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+ne+"*(even|odd|(([+-]|)(\\d*)n|)"+ne+"*(?:([+-]|)"+ne+"*(\\d+)|))"+ne+"*\\)|)","i"),bool:new RegExp("^(?:"+te+")$","i"),needsContext:new RegExp("^"+ne+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+ne+"*((?:-\\d)?\\d*)"+ne+"*\\)|)(?=[^-]|$)","i")},he=/^(?:input|select|textarea|button)$/i,me=/^h\d$/i,ge=/^[^{]+\{\s*\[native \w/,ye=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ve=/[+~]/,be=new RegExp("\\\\([\\da-f]{1,6}"+ne+"?|("+ne+")|.)","ig"),we=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},xe=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,Te=function(e,t){return t?"\x00"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},Se=function(){P()},Oe=h(function(e){return e.disabled===!0&&("form"in e||"label"in e)},{dir:"parentNode",next:"legend"});try{Q.apply(J=K.call($.childNodes),$.childNodes),J[$.childNodes.length].nodeType}catch(e){Q={apply:J.length?function(e,t){Z.apply(e,K.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}T=t.support={},j=t.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},P=t.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:$;return r!==I&&9===r.nodeType&&r.documentElement?(I=r,M=I.documentElement,L=!j(I),$!==I&&(n=I.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",Se,!1):n.attachEvent&&n.attachEvent("onunload",Se)),T.attributes=i(function(e){return e.className="i",!e.getAttribute("className")}),T.getElementsByTagName=i(function(e){return e.appendChild(I.createComment("")),!e.getElementsByTagName("*").length}),T.getElementsByClassName=ge.test(I.getElementsByClassName),T.getById=i(function(e){return M.appendChild(e).id=H,!I.getElementsByName||!I.getElementsByName(H).length}),T.getById?(S.filter.ID=function(e){var t=e.replace(be,we);return function(e){return e.getAttribute("id")===t}},S.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&L){var n=t.getElementById(e);return n?[n]:[]}}):(S.filter.ID=function(e){var t=e.replace(be,we);return function(e){var n="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}},S.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&L){var n,r,i,o=t.getElementById(e);if(o){if(n=o.getAttributeNode("id"),n&&n.value===e)return[o];for(i=t.getElementsByName(e),r=0;o=i[r++];)if(n=o.getAttributeNode("id"),n&&n.value===e)return[o]}return[]}}),S.find.TAG=T.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):T.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},S.find.CLASS=T.getElementsByClassName&&function(e,t){return"undefined"!=typeof t.getElementsByClassName&&L?t.getElementsByClassName(e):void 0},D=[],F=[],(T.qsa=ge.test(I.querySelectorAll))&&(i(function(e){M.appendChild(e).innerHTML="<a id='"+H+"'></a><select id='"+H+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&F.push("[*^$]="+ne+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||F.push("\\["+ne+"*(?:value|"+te+")"),e.querySelectorAll("[id~="+H+"-]").length||F.push("~="),e.querySelectorAll(":checked").length||F.push(":checked"),e.querySelectorAll("a#"+H+"+*").length||F.push(".#.+[+~]")}),i(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=I.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&F.push("name"+ne+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&F.push(":enabled",":disabled"),M.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&F.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),F.push(",.*:")})),(T.matchesSelector=ge.test(q=M.matches||M.webkitMatchesSelector||M.mozMatchesSelector||M.oMatchesSelector||M.msMatchesSelector))&&i(function(e){T.disconnectedMatch=q.call(e,"*"),q.call(e,"[s!='']:x"),D.push("!=",oe)}),F=F.length&&new RegExp(F.join("|")),D=D.length&&new RegExp(D.join("|")),t=ge.test(M.compareDocumentPosition),R=t||ge.test(M.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},G=t?function(e,t){if(e===t)return _=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n?n:(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&n||!T.sortDetached&&t.compareDocumentPosition(e)===n?e===I||e.ownerDocument===$&&R($,e)?-1:t===I||t.ownerDocument===$&&R($,t)?1:N?ee(N,e)-ee(N,t):0:4&n?-1:1)}:function(e,t){if(e===t)return _=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,s=[e],u=[t];if(!i||!o)return e===I?-1:t===I?1:i?-1:o?1:N?ee(N,e)-ee(N,t):0;if(i===o)return a(e,t);for(n=e;n=n.parentNode;)s.unshift(n);for(n=t;n=n.parentNode;)u.unshift(n);for(;s[r]===u[r];)r++;return r?a(s[r],u[r]):s[r]===$?-1:u[r]===$?1:0},I):I},t.matches=function(e,n){return t(e,null,null,n)},t.matchesSelector=function(e,n){if((e.ownerDocument||e)!==I&&P(e),n=n.replace(le,"='$1']"),!(!T.matchesSelector||!L||U[n+" "]||D&&D.test(n)||F&&F.test(n)))try{var r=q.call(e,n);if(r||T.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){}return t(n,I,null,[e]).length>0},t.contains=function(e,t){return(e.ownerDocument||e)!==I&&P(e),R(e,t)},t.attr=function(e,t){(e.ownerDocument||e)!==I&&P(e);var n=S.attrHandle[t.toLowerCase()],r=n&&X.call(S.attrHandle,t.toLowerCase())?n(e,t,!L):void 0;return void 0!==r?r:T.attributes||!L?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},t.escape=function(e){return(e+"").replace(xe,Te)},t.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},t.uniqueSort=function(e){var t,n=[],r=0,i=0;if(_=!T.detectDuplicates,N=!T.sortStable&&e.slice(0),e.sort(G),_){for(;t=e[i++];)t===e[i]&&(r=n.push(i));for(;r--;)e.splice(n[r],1)}return N=null,e},O=t.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=O(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r++];)n+=O(t);return n},S=t.selectors={cacheLength:50,createPseudo:r,match:de,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(be,we),e[3]=(e[3]||e[4]||e[5]||"").replace(be,we),
-"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||t.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&t.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return de.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&fe.test(n)&&(t=k(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(be,we).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=W[e+" "];return t||(t=new RegExp("(^|"+ne+")"+e+"("+ne+"|$)"))&&W(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,n,r){return function(i){var o=t.attr(i,e);return null==o?"!="===n:n?(o+="","="===n?o===r:"!="===n?o!==r:"^="===n?r&&0===o.indexOf(r):"*="===n?r&&o.indexOf(r)>-1:"$="===n?r&&o.slice(-r.length)===r:"~="===n?(" "+o.replace(ae," ")+" ").indexOf(r)>-1:"|="===n?o===r||o.slice(0,r.length+1)===r+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var c,l,f,p,d,h,m=o!==a?"nextSibling":"previousSibling",g=t.parentNode,y=s&&t.nodeName.toLowerCase(),v=!u&&!s,b=!1;if(g){if(o){for(;m;){for(p=t;p=p[m];)if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=m="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?g.firstChild:g.lastChild],a&&v){for(p=g,f=p[H]||(p[H]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),c=l[e]||[],d=c[0]===B&&c[1],b=d&&c[2],p=d&&g.childNodes[d];p=++d&&p&&p[m]||(b=d=0)||h.pop();)if(1===p.nodeType&&++b&&p===t){l[e]=[B,d,b];break}}else if(v&&(p=t,f=p[H]||(p[H]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),c=l[e]||[],d=c[0]===B&&c[1],b=d),b===!1)for(;(p=++d&&p&&p[m]||(b=d=0)||h.pop())&&((s?p.nodeName.toLowerCase()!==y:1!==p.nodeType)||!++b||(v&&(f=p[H]||(p[H]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),l[e]=[B,b]),p!==t)););return b-=i,b===r||b%r===0&&b/r>=0}}},PSEUDO:function(e,n){var i,o=S.pseudos[e]||S.setFilters[e.toLowerCase()]||t.error("unsupported pseudo: "+e);return o[H]?o(n):o.length>1?(i=[e,e,"",n],S.setFilters.hasOwnProperty(e.toLowerCase())?r(function(e,t){for(var r,i=o(e,n),a=i.length;a--;)r=ee(e,i[a]),e[r]=!(t[r]=i[a])}):function(e){return o(e,0,i)}):o}},pseudos:{not:r(function(e){var t=[],n=[],i=C(e.replace(se,"$1"));return i[H]?r(function(e,t,n,r){for(var o,a=i(e,null,r,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,r,o){return t[0]=e,i(t,null,o,n),t[0]=null,!n.pop()}}),has:r(function(e){return function(n){return t(e,n).length>0}}),contains:r(function(e){return e=e.replace(be,we),function(t){return(t.textContent||t.innerText||O(t)).indexOf(e)>-1}}),lang:r(function(e){return pe.test(e||"")||t.error("unsupported lang: "+e),e=e.replace(be,we).toLowerCase(),function(t){var n;do if(n=L?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===M},focus:function(e){return e===I.activeElement&&(!I.hasFocus||I.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:c(!1),disabled:c(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!S.pseudos.empty(e)},header:function(e){return me.test(e.nodeName)},input:function(e){return he.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:l(function(){return[0]}),last:l(function(e,t){return[t-1]}),eq:l(function(e,t,n){return[0>n?n+t:n]}),even:l(function(e,t){for(var n=0;t>n;n+=2)e.push(n);return e}),odd:l(function(e,t){for(var n=1;t>n;n+=2)e.push(n);return e}),lt:l(function(e,t,n){for(var r=0>n?n+t:n;--r>=0;)e.push(r);return e}),gt:l(function(e,t,n){for(var r=0>n?n+t:n;++r<t;)e.push(r);return e})}},S.pseudos.nth=S.pseudos.eq;for(x in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})S.pseudos[x]=s(x);for(x in{submit:!0,reset:!0})S.pseudos[x]=u(x);return p.prototype=S.filters=S.pseudos,S.setFilters=new p,k=t.tokenize=function(e,n){var r,i,o,a,s,u,c,l=z[e+" "];if(l)return n?0:l.slice(0);for(s=e,u=[],c=S.preFilter;s;){(!r||(i=ue.exec(s)))&&(i&&(s=s.slice(i[0].length)||s),u.push(o=[])),r=!1,(i=ce.exec(s))&&(r=i.shift(),o.push({value:r,type:i[0].replace(se," ")}),s=s.slice(r.length));for(a in S.filter)!(i=de[a].exec(s))||c[a]&&!(i=c[a](i))||(r=i.shift(),o.push({value:r,type:a,matches:i}),s=s.slice(r.length));if(!r)break}return n?s.length:s?t.error(e):z(e,u).slice(0)},C=t.compile=function(e,t){var n,r=[],i=[],o=U[e+" "];if(!o){for(t||(t=k(e)),n=t.length;n--;)o=b(t[n]),o[H]?r.push(o):i.push(o);o=U(e,w(i,r)),o.selector=e}return o},A=t.select=function(e,t,n,r){var i,o,a,s,u,c="function"==typeof e&&e,l=!r&&k(e=c.selector||e);if(n=n||[],1===l.length){if(o=l[0]=l[0].slice(0),o.length>2&&"ID"===(a=o[0]).type&&9===t.nodeType&&L&&S.relative[o[1].type]){if(t=(S.find.ID(a.matches[0].replace(be,we),t)||[])[0],!t)return n;c&&(t=t.parentNode),e=e.slice(o.shift().value.length)}for(i=de.needsContext.test(e)?0:o.length;i--&&(a=o[i],!S.relative[s=a.type]);)if((u=S.find[s])&&(r=u(a.matches[0].replace(be,we),ve.test(o[0].type)&&f(t.parentNode)||t))){if(o.splice(i,1),e=r.length&&d(o),!e)return Q.apply(n,r),n;break}}return(c||C(e,l))(r,t,!L,n,!t||ve.test(e)&&f(t.parentNode)||t),n},T.sortStable=H.split("").sort(G).join("")===H,T.detectDuplicates=!!_,P(),T.sortDetached=i(function(e){return 1&e.compareDocumentPosition(I.createElement("fieldset"))}),i(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||o("type|href|height|width",function(e,t,n){return n?void 0:e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),T.attributes&&i(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||o("value",function(e,t,n){return n||"input"!==e.nodeName.toLowerCase()?void 0:e.defaultValue}),i(function(e){return null==e.getAttribute("disabled")})||o(te,function(e,t,n){var r;return n?void 0:e[t]===!0?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),t}(e);he.find=be,he.expr=be.selectors,he.expr[":"]=he.expr.pseudos,he.uniqueSort=he.unique=be.uniqueSort,he.text=be.getText,he.isXMLDoc=be.isXML,he.contains=be.contains,he.escapeSelector=be.escape;var we=function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&he(e).is(n))break;r.push(e)}return r},xe=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},Te=he.expr.match.needsContext,Se=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i,Oe=/^.[^:#\[\.,]*$/;he.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?he.find.matchesSelector(r,e)?[r]:[]:he.find.matches(e,he.grep(t,function(e){return 1===e.nodeType}))},he.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(he(e).filter(function(){for(t=0;r>t;t++)if(he.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;r>t;t++)he.find(e,i[t],n);return r>1?he.uniqueSort(n):n},filter:function(e){return this.pushStack(i(this,e||[],!1))},not:function(e){return this.pushStack(i(this,e||[],!0))},is:function(e){return!!i(this,"string"==typeof e&&Te.test(e)?he(e):e||[],!1).length}});var je,ke=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,Ce=he.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||je,"string"==typeof e){if(r="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:ke.exec(e),!r||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof he?t[0]:t,he.merge(this,he.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:te,!0)),Se.test(r[1])&&he.isPlainObject(t))for(r in t)he.isFunction(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return i=te.getElementById(r[2]),i&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):he.isFunction(e)?void 0!==n.ready?n.ready(e):e(he):he.makeArray(e,this)};Ce.prototype=he.fn,je=he(te);var Ae=/^(?:parents|prev(?:Until|All))/,Ee={children:!0,contents:!0,next:!0,prev:!0};he.fn.extend({has:function(e){var t=he(e,this),n=t.length;return this.filter(function(){for(var e=0;n>e;e++)if(he.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&he(e);if(!Te.test(e))for(;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&he.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?he.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?ae.call(he(e),this[0]):ae.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(he.uniqueSort(he.merge(this.get(),he(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),he.each({parent:function e(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(e){return we(e,"parentNode")},parentsUntil:function(e,t,n){return we(e,"parentNode",n)},next:function(e){return o(e,"nextSibling")},prev:function(e){return o(e,"previousSibling")},nextAll:function(e){return we(e,"nextSibling")},prevAll:function(e){return we(e,"previousSibling")},nextUntil:function(e,t,n){return we(e,"nextSibling",n)},prevUntil:function(e,t,n){return we(e,"previousSibling",n)},siblings:function(e){return xe((e.parentNode||{}).firstChild,e)},children:function(e){return xe(e.firstChild)},contents:function(e){return e.contentDocument||he.merge([],e.childNodes)}},function(e,t){he.fn[e]=function(n,r){var i=he.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=he.filter(r,i)),this.length>1&&(Ee[e]||he.uniqueSort(i),Ae.test(e)&&i.reverse()),this.pushStack(i)}});var Ne=/[^\x20\t\r\n\f]+/g;he.Callbacks=function(e){e="string"==typeof e?a(e):he.extend({},e);var t,n,r,i,o=[],s=[],u=-1,c=function(){for(i=e.once,r=t=!0;s.length;u=-1)for(n=s.shift();++u<o.length;)o[u].apply(n[0],n[1])===!1&&e.stopOnFalse&&(u=o.length,n=!1);e.memory||(n=!1),t=!1,i&&(o=n?[]:"")},l={add:function(){return o&&(n&&!t&&(u=o.length-1,s.push(n)),function t(n){he.each(n,function(n,r){he.isFunction(r)?e.unique&&l.has(r)||o.push(r):r&&r.length&&"string"!==he.type(r)&&t(r)})}(arguments),n&&!t&&c()),this},remove:function(){return he.each(arguments,function(e,t){for(var n;(n=he.inArray(t,o,n))>-1;)o.splice(n,1),u>=n&&u--}),this},has:function(e){return e?he.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=s=[],o=n="",this},disabled:function(){return!o},lock:function(){return i=s=[],n||t||(o=n=""),this},locked:function(){return!!i},fireWith:function(e,n){return i||(n=n||[],n=[e,n.slice?n.slice():n],s.push(n),t||c()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!r}};return l},he.extend({Deferred:function(t){var n=[["notify","progress",he.Callbacks("memory"),he.Callbacks("memory"),2],["resolve","done",he.Callbacks("once memory"),he.Callbacks("once memory"),0,"resolved"],["reject","fail",he.Callbacks("once memory"),he.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return i.then(null,e)},pipe:function(){var e=arguments;return he.Deferred(function(t){he.each(n,function(n,r){var i=he.isFunction(e[r[4]])&&e[r[4]];o[r[1]](function(){var e=i&&i.apply(this,arguments);e&&he.isFunction(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[r[0]+"With"](this,i?[e]:arguments)})}),e=null}).promise()},then:function(t,r,i){function o(t,n,r,i){return function(){var c=this,l=arguments,f=function(){var e,f;if(!(a>t)){if(e=r.apply(c,l),e===n.promise())throw new TypeError("Thenable self-resolution");f=e&&("object"===("undefined"==typeof e?"undefined":_typeof(e))||"function"==typeof e)&&e.then,he.isFunction(f)?i?f.call(e,o(a,n,s,i),o(a,n,u,i)):(a++,f.call(e,o(a,n,s,i),o(a,n,u,i),o(a,n,s,n.notifyWith))):(r!==s&&(c=void 0,l=[e]),(i||n.resolveWith)(c,l))}},p=i?f:function(){try{f()}catch(e){he.Deferred.exceptionHook&&he.Deferred.exceptionHook(e,p.stackTrace),t+1>=a&&(r!==u&&(c=void 0,l=[e]),n.rejectWith(c,l))}};t?p():(he.Deferred.getStackHook&&(p.stackTrace=he.Deferred.getStackHook()),e.setTimeout(p))}}var a=0;return he.Deferred(function(e){n[0][3].add(o(0,e,he.isFunction(i)?i:s,e.notifyWith)),n[1][3].add(o(0,e,he.isFunction(t)?t:s)),n[2][3].add(o(0,e,he.isFunction(r)?r:u))}).promise()},promise:function(e){return null!=e?he.extend(e,i):i}},o={};return he.each(n,function(e,t){var a=t[2],s=t[5];i[t[1]]=a.add,s&&a.add(function(){r=s},n[3-e][2].disable,n[0][2].lock),a.add(t[3].fire),o[t[0]]=function(){return o[t[0]+"With"](this===o?void 0:this,arguments),this},o[t[0]+"With"]=a.fireWith}),i.promise(o),t&&t.call(o,o),o},when:function(e){var t=arguments.length,n=t,r=Array(n),i=re.call(arguments),o=he.Deferred(),a=function(e){return function(n){r[e]=this,i[e]=arguments.length>1?re.call(arguments):n,--t||o.resolveWith(r,i)}};if(1>=t&&(c(e,o.done(a(n)).resolve,o.reject),"pending"===o.state()||he.isFunction(i[n]&&i[n].then)))return o.then();for(;n--;)c(i[n],a(n),o.reject);return o.promise()}});var _e=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;he.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&_e.test(t.name)&&e.console.warn("jQuery.Deferred exception: "+t.message,t.stack,n)},he.readyException=function(t){e.setTimeout(function(){throw t})};var Pe=he.Deferred();he.fn.ready=function(e){return Pe.then(e).catch(function(e){he.readyException(e)}),this},he.extend({isReady:!1,readyWait:1,holdReady:function(e){e?he.readyWait++:he.ready(!0)},ready:function(e){(e===!0?--he.readyWait:he.isReady)||(he.isReady=!0,e!==!0&&--he.readyWait>0||Pe.resolveWith(te,[he]))}}),he.ready.then=Pe.then,"complete"===te.readyState||"loading"!==te.readyState&&!te.documentElement.doScroll?e.setTimeout(he.ready):(te.addEventListener("DOMContentLoaded",l),e.addEventListener("load",l));var Ie=function e(t,n,r,i,o,a,s){var u=0,c=t.length,l=null==r;if("object"===he.type(r)){o=!0;for(u in r)e(t,n,u,r[u],!0,a,s)}else if(void 0!==i&&(o=!0,he.isFunction(i)||(s=!0),l&&(s?(n.call(t,i),n=null):(l=n,n=function(e,t,n){return l.call(he(e),n)})),n))for(;c>u;u++)n(t[u],r,s?i:i.call(t[u],u,n(t[u],r)));return o?t:l?n.call(t):c?n(t[0],r):a},Me=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};f.uid=1,f.prototype={cache:function(e){var t=e[this.expando];return t||(t={},Me(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[he.camelCase(t)]=n;else for(r in t)i[he.camelCase(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][he.camelCase(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){he.isArray(t)?t=t.map(he.camelCase):(t=he.camelCase(t),t=t in r?[t]:t.match(Ne)||[]),n=t.length;for(;n--;)delete r[t[n]]}(void 0===t||he.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!he.isEmptyObject(t)}};var Le=new f,Fe=new f,De=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,qe=/[A-Z]/g;he.extend({hasData:function(e){return Fe.hasData(e)||Le.hasData(e)},data:function(e,t,n){return Fe.access(e,t,n)},removeData:function(e,t){Fe.remove(e,t)},_data:function(e,t,n){return Le.access(e,t,n)},_removeData:function(e,t){Le.remove(e,t)}}),he.fn.extend({data:function e(t,n){var r,i,e,o=this[0],a=o&&o.attributes;if(void 0===t){if(this.length&&(e=Fe.get(o),1===o.nodeType&&!Le.get(o,"hasDataAttrs"))){for(r=a.length;r--;)a[r]&&(i=a[r].name,0===i.indexOf("data-")&&(i=he.camelCase(i.slice(5)),d(o,i,e[i])));Le.set(o,"hasDataAttrs",!0)}return e}return"object"===("undefined"==typeof t?"undefined":_typeof(t))?this.each(function(){Fe.set(this,t)}):Ie(this,function(e){var n;if(o&&void 0===e){if(n=Fe.get(o,t),void 0!==n)return n;if(n=d(o,t),void 0!==n)return n}else this.each(function(){Fe.set(this,t,e)})},null,n,arguments.length>1,null,!0)},removeData:function(e){return this.each(function(){Fe.remove(this,e)})}}),he.extend({queue:function e(t,n,r){var e;return t?(n=(n||"fx")+"queue",e=Le.get(t,n),r&&(!e||he.isArray(r)?e=Le.access(t,n,he.makeArray(r)):e.push(r)),e||[]):void 0},dequeue:function(e,t){t=t||"fx";var n=he.queue(e,t),r=n.length,i=n.shift(),o=he._queueHooks(e,t),a=function(){he.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Le.get(e,n)||Le.access(e,n,{empty:he.Callbacks("once memory").add(function(){Le.remove(e,[t+"queue",n])})})}}),he.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?he.queue(this[0],e):void 0===t?this:this.each(function(){var n=he.queue(this,e,t);he._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&he.dequeue(this,e)})},dequeue:function(e){return this.each(function(){he.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=he.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)n=Le.get(o[a],e+"queueHooks"),n&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var Re=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,He=new RegExp("^(?:([+-])=|)("+Re+")([a-z%]*)$","i"),$e=["Top","Right","Bottom","Left"],Be=function(e,t){return e=t||e,"none"===e.style.display||""===e.style.display&&he.contains(e.ownerDocument,e)&&"none"===he.css(e,"display")},Ve=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i},We={};he.fn.extend({show:function(){return g(this,!0)},hide:function(){return g(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){Be(this)?he(this).show():he(this).hide()})}});var ze=/^(?:checkbox|radio)$/i,Ue=/<([a-z][^\/\0>\x20\t\r\n\f]+)/i,Ge=/^$|\/(?:java|ecma)script/i,Xe={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Xe.optgroup=Xe.option,Xe.tbody=Xe.tfoot=Xe.colgroup=Xe.caption=Xe.thead,Xe.th=Xe.td;var Je=/<|&#?\w+;/;!function(){var e=te.createDocumentFragment(),t=e.appendChild(te.createElement("div")),n=te.createElement("input");n.setAttribute("type","radio"),n.setAttribute("checked","checked"),n.setAttribute("name","t"),t.appendChild(n),pe.checkClone=t.cloneNode(!0).cloneNode(!0).lastChild.checked,t.innerHTML="<textarea>x</textarea>",pe.noCloneChecked=!!t.cloneNode(!0).lastChild.defaultValue}();var Ye=te.documentElement,Ze=/^key/,Qe=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ke=/^([^.]*)(?:\.(.+)|)/;he.event={global:{},add:function(e,t,n,r,i){var o,a,s,u,c,l,f,p,d,h,m,g=Le.get(e);if(g)for(n.handler&&(o=n,n=o.handler,i=o.selector),i&&he.find.matchesSelector(Ye,i),n.guid||(n.guid=he.guid++),(u=g.events)||(u=g.events={}),(a=g.handle)||(a=g.handle=function(t){return"undefined"!=typeof he&&he.event.triggered!==t.type?he.event.dispatch.apply(e,arguments):void 0}),t=(t||"").match(Ne)||[""],c=t.length;c--;)s=Ke.exec(t[c])||[],d=m=s[1],h=(s[2]||"").split(".").sort(),d&&(f=he.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=he.event.special[d]||{},l=he.extend({type:d,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&he.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||(p=u[d]=[],p.delegateCount=0,f.setup&&f.setup.call(e,r,h,a)!==!1||e.addEventListener&&e.addEventListener(d,a)),f.add&&(f.add.call(e,l),l.handler.guid||(l.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,l):p.push(l),he.event.global[d]=!0)},remove:function(e,t,n,r,i){var o,a,s,u,c,l,f,p,d,h,m,g=Le.hasData(e)&&Le.get(e);if(g&&(u=g.events)){for(t=(t||"").match(Ne)||[""],c=t.length;c--;)if(s=Ke.exec(t[c])||[],d=m=s[1],h=(s[2]||"").split(".").sort(),d){for(f=he.event.special[d]||{},d=(r?f.delegateType:f.bindType)||d,p=u[d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;o--;)l=p[o],!i&&m!==l.origType||n&&n.guid!==l.guid||s&&!s.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(p.splice(o,1),l.selector&&p.delegateCount--,f.remove&&f.remove.call(e,l));a&&!p.length&&(f.teardown&&f.teardown.call(e,h,g.handle)!==!1||he.removeEvent(e,d,g.handle),delete u[d])}else for(d in u)he.event.remove(e,d+t[c],n,r,!0);he.isEmptyObject(u)&&Le.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=he.event.fix(e),u=new Array(arguments.length),c=(Le.get(this,"events")||{})[s.type]||[],l=he.event.special[s.type]||{};for(u[0]=s,t=1;t<arguments.length;t++)u[t]=arguments[t];if(s.delegateTarget=this,!l.preDispatch||l.preDispatch.call(this,s)!==!1){for(a=he.event.handlers.call(this,s,c),t=0;(i=a[t++])&&!s.isPropagationStopped();)for(s.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!s.isImmediatePropagationStopped();)(!s.rnamespace||s.rnamespace.test(o.namespace))&&(s.handleObj=o,s.data=o.data,r=((he.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,u),void 0!==r&&(s.result=r)===!1&&(s.preventDefault(),s.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,s),s.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,c=e.target;if(u&&c.nodeType&&!("click"===e.type&&e.button>=1))for(;c!==this;c=c.parentNode||this)if(1===c.nodeType&&("click"!==e.type||c.disabled!==!0)){for(o=[],a={},n=0;u>n;n++)r=t[n],i=r.selector+" ",void 0===a[i]&&(a[i]=r.needsContext?he(i,this).index(c)>-1:he.find(i,this,null,[c]).length),a[i]&&o.push(r);o.length&&s.push({elem:c,handlers:o})}return c=this,u<t.length&&s.push({elem:c,handlers:t.slice(u)}),s},addProp:function(e,t){Object.defineProperty(he.Event.prototype,e,{enumerable:!0,configurable:!0,get:he.isFunction(t)?function(){return this.originalEvent?t(this.originalEvent):void 0}:function(){return this.originalEvent?this.originalEvent[e]:void 0},set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(e){return e[he.expando]?e:new he.Event(e)},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==T()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===T()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&he.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(e){return he.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},he.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},he.Event=function(e,t){return this instanceof he.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&e.returnValue===!1?w:x,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&he.extend(this,t),this.timeStamp=e&&e.timeStamp||he.now(),void(this[he.expando]=!0)):new he.Event(e,t)},he.Event.prototype={constructor:he.Event,isDefaultPrevented:x,isPropagationStopped:x,isImmediatePropagationStopped:x,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=w,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=w,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=w,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},he.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&Ze.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Qe.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},he.event.addProp),he.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){he.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!he.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),he.fn.extend({on:function(e,t,n,r){return S(this,e,t,n,r)},one:function(e,t,n,r){return S(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,he(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"===("undefined"==typeof e?"undefined":_typeof(e))){for(i in e)this.off(i,t,e[i]);return this}return(t===!1||"function"==typeof t)&&(n=t,t=void 0),n===!1&&(n=x),this.each(function(){he.event.remove(this,e,n,t)})}});var et=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,tt=/<script|<style|<link/i,nt=/checked\s*(?:[^=]|=\s*.checked.)/i,rt=/^true\/(.*)/,it=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;he.extend({htmlPrefilter:function(e){return e.replace(et,"<$1></$2>")},clone:function e(t,n,r){var i,o,a,s,e=t.cloneNode(!0),u=he.contains(t.ownerDocument,t);if(!(pe.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||he.isXMLDoc(t)))for(s=y(e),a=y(t),i=0,o=a.length;o>i;i++)A(a[i],s[i]);if(n)if(r)for(a=a||y(t),s=s||y(e),i=0,o=a.length;o>i;i++)C(a[i],s[i]);else C(t,e);return s=y(e,"script"),s.length>0&&v(s,!u&&y(t,"script")),e},cleanData:function(e){for(var t,n,r,i=he.event.special,o=0;void 0!==(n=e[o]);o++)if(Me(n)){if(t=n[Le.expando]){if(t.events)for(r in t.events)i[r]?he.event.remove(n,r):he.removeEvent(n,r,t.handle);n[Le.expando]=void 0}n[Fe.expando]&&(n[Fe.expando]=void 0)}}}),he.fn.extend({detach:function(e){return N(this,e,!0)},remove:function(e){return N(this,e)},text:function(e){return Ie(this,function(e){return void 0===e?he.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=e)})},null,e,arguments.length)},append:function(){return E(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=O(this,e);t.appendChild(e)}})},prepend:function(){return E(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=O(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return E(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return E(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(he.cleanData(y(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return he.clone(this,e,t)})},html:function(e){return Ie(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!tt.test(e)&&!Xe[(Ue.exec(e)||["",""])[1].toLowerCase()]){e=he.htmlPrefilter(e);try{for(;r>n;n++)t=this[n]||{},1===t.nodeType&&(he.cleanData(y(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=[];return E(this,arguments,function(t){var n=this.parentNode;he.inArray(this,e)<0&&(he.cleanData(y(this)),n&&n.replaceChild(t,this))},e)}}),he.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){he.fn[e]=function(e){for(var n,r=[],i=he(e),o=i.length-1,a=0;o>=a;a++)n=a===o?this:this.clone(!0),he(i[a])[t](n),oe.apply(r,n.get());return this.pushStack(r)}});var ot=/^margin/,at=new RegExp("^("+Re+")(?!px)[a-z%]+$","i"),st=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)};!function(){function t(){if(s){s.style.cssText="box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",s.innerHTML="",Ye.appendChild(a);var t=e.getComputedStyle(s);n="1%"!==t.top,o="2px"===t.marginLeft,r="4px"===t.width,s.style.marginRight="50%",i="4px"===t.marginRight,Ye.removeChild(a),s=null}}var n,r,i,o,a=te.createElement("div"),s=te.createElement("div");s.style&&(s.style.backgroundClip="content-box",s.cloneNode(!0).style.backgroundClip="",pe.clearCloneStyle="content-box"===s.style.backgroundClip,a.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",a.appendChild(s),he.extend(pe,{pixelPosition:function(){return t(),n},boxSizingReliable:function(){return t(),r},pixelMarginRight:function(){return t(),i},reliableMarginLeft:function(){return t(),o}}))}();var ut=/^(none|table(?!-c[ea]).+)/,ct={position:"absolute",visibility:"hidden",display:"block"},lt={letterSpacing:"0",fontWeight:"400"},ft=["Webkit","Moz","ms"],pt=te.createElement("div").style;he.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=_(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{float:"cssFloat"},style:function e(t,n,r,i){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var o,a,s,u=he.camelCase(n),e=t.style;return n=he.cssProps[u]||(he.cssProps[u]=I(u)||u),s=he.cssHooks[n]||he.cssHooks[u],void 0===r?s&&"get"in s&&void 0!==(o=s.get(t,!1,i))?o:e[n]:(a="undefined"==typeof r?"undefined":_typeof(r),"string"===a&&(o=He.exec(r))&&o[1]&&(r=h(t,n,o),a="number"),null!=r&&r===r&&("number"===a&&(r+=o&&o[3]||(he.cssNumber[u]?"":"px")),pe.clearCloneStyle||""!==r||0!==n.indexOf("background")||(e[n]="inherit"),s&&"set"in s&&void 0===(r=s.set(t,r,i))||(e[n]=r)),void 0)}},css:function(e,t,n,r){var i,o,a,s=he.camelCase(t);return t=he.cssProps[s]||(he.cssProps[s]=I(s)||s),a=he.cssHooks[t]||he.cssHooks[s],a&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=_(e,t,r)),"normal"===i&&t in lt&&(i=lt[t]),""===n||n?(o=parseFloat(i),n===!0||isFinite(o)?o||0:i):i}}),he.each(["height","width"],function(e,t){he.cssHooks[t]={get:function(e,n,r){return n?!ut.test(he.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?F(e,t,r):Ve(e,ct,function(){return F(e,t,r)}):void 0},set:function(e,n,r){var i,o=r&&st(e),a=r&&L(e,t,r,"border-box"===he.css(e,"boxSizing",!1,o),o);return a&&(i=He.exec(n))&&"px"!==(i[3]||"px")&&(e.style[t]=n,n=he.css(e,t)),M(e,n,a)}}}),he.cssHooks.marginLeft=P(pe.reliableMarginLeft,function(e,t){return t?(parseFloat(_(e,"marginLeft"))||e.getBoundingClientRect().left-Ve(e,{
-marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px":void 0}),he.each({margin:"",padding:"",border:"Width"},function(e,t){he.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];4>r;r++)i[e+$e[r]+t]=o[r]||o[r-2]||o[0];return i}},ot.test(e)||(he.cssHooks[e+t].set=M)}),he.fn.extend({css:function(e,t){return Ie(this,function(e,t,n){var r,i,o={},a=0;if(he.isArray(t)){for(r=st(e),i=t.length;i>a;a++)o[t[a]]=he.css(e,t[a],!1,r);return o}return void 0!==n?he.style(e,t,n):he.css(e,t)},e,t,arguments.length>1)}}),he.Tween=D,D.prototype={constructor:D,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||he.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(he.cssNumber[n]?"":"px")},cur:function(){var e=D.propHooks[this.prop];return e&&e.get?e.get(this):D.propHooks._default.get(this)},run:function(e){var t,n=D.propHooks[this.prop];return this.pos=t=this.options.duration?he.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):D.propHooks._default.set(this),this}},D.prototype.init.prototype=D.prototype,D.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=he.css(e.elem,e.prop,""),t&&"auto"!==t?t:0)},set:function(e){he.fx.step[e.prop]?he.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[he.cssProps[e.prop]]&&!he.cssHooks[e.prop]?e.elem[e.prop]=e.now:he.style(e.elem,e.prop,e.now+e.unit)}}},D.propHooks.scrollTop=D.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},he.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},he.fx=D.prototype.init,he.fx.step={};var dt,ht,mt=/^(?:toggle|show|hide)$/,gt=/queueHooks$/;he.Animation=he.extend(W,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return h(n.elem,e,He.exec(t),n),n}]},tweener:function(e,t){he.isFunction(e)?(t=e,e=["*"]):e=e.match(Ne);for(var n,r=0,i=e.length;i>r;r++)n=e[r],W.tweeners[n]=W.tweeners[n]||[],W.tweeners[n].unshift(t)},prefilters:[B],prefilter:function(e,t){t?W.prefilters.unshift(e):W.prefilters.push(e)}}),he.speed=function(e,t,n){var r=e&&"object"===("undefined"==typeof e?"undefined":_typeof(e))?he.extend({},e):{complete:n||!n&&t||he.isFunction(e)&&e,duration:e,easing:n&&t||t&&!he.isFunction(t)&&t};return he.fx.off||te.hidden?r.duration=0:"number"!=typeof r.duration&&(r.duration=r.duration in he.fx.speeds?he.fx.speeds[r.duration]:he.fx.speeds._default),(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){he.isFunction(r.old)&&r.old.call(this),r.queue&&he.dequeue(this,r.queue)},r},he.fn.extend({fadeTo:function(e,t,n,r){return this.filter(Be).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=he.isEmptyObject(e),o=he.speed(t,n,r),a=function(){var t=W(this,he.extend({},e),o);(i||Le.get(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,i=null!=e&&e+"queueHooks",o=he.timers,a=Le.get(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&gt.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));(t||!n)&&he.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=Le.get(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=he.timers,a=r?r.length:0;for(n.finish=!0,he.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),he.each(["toggle","show","hide"],function(e,t){var n=he.fn[t];he.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(H(t,!0),e,r,i)}}),he.each({slideDown:H("show"),slideUp:H("hide"),slideToggle:H("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){he.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),he.timers=[],he.fx.tick=function(){var e,t=0,n=he.timers;for(dt=he.now();t<n.length;t++)e=n[t],e()||n[t]!==e||n.splice(t--,1);n.length||he.fx.stop(),dt=void 0},he.fx.timer=function(e){he.timers.push(e),e()?he.fx.start():he.timers.pop()},he.fx.interval=13,he.fx.start=function(){ht||(ht=e.requestAnimationFrame?e.requestAnimationFrame(q):e.setInterval(he.fx.tick,he.fx.interval))},he.fx.stop=function(){e.cancelAnimationFrame?e.cancelAnimationFrame(ht):e.clearInterval(ht),ht=null},he.fx.speeds={slow:600,fast:200,_default:400},he.fn.delay=function(t,n){return t=he.fx?he.fx.speeds[t]||t:t,n=n||"fx",this.queue(n,function(n,r){var i=e.setTimeout(n,t);r.stop=function(){e.clearTimeout(i)}})},function(){var e=te.createElement("input"),t=te.createElement("select"),n=t.appendChild(te.createElement("option"));e.type="checkbox",pe.checkOn=""!==e.value,pe.optSelected=n.selected,e=te.createElement("input"),e.value="t",e.type="radio",pe.radioValue="t"===e.value}();var yt,vt=he.expr.attrHandle;he.fn.extend({attr:function(e,t){return Ie(this,he.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){he.removeAttr(this,e)})}}),he.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?he.prop(e,t,n):(1===o&&he.isXMLDoc(e)||(i=he.attrHooks[t.toLowerCase()]||(he.expr.match.bool.test(t)?yt:void 0)),void 0!==n?null===n?void he.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:(r=he.find.attr(e,t),null==r?void 0:r))},attrHooks:{type:{set:function(e,t){if(!pe.radioValue&&"radio"===t&&he.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(Ne);if(i&&1===e.nodeType)for(;n=i[r++];)e.removeAttribute(n)}}),yt={set:function(e,t,n){return t===!1?he.removeAttr(e,n):e.setAttribute(n,n),n}},he.each(he.expr.match.bool.source.match(/\w+/g),function(e,t){var n=vt[t]||he.find.attr;vt[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=vt[a],vt[a]=i,i=null!=n(e,t,r)?a:null,vt[a]=o),i}});var bt=/^(?:input|select|textarea|button)$/i,wt=/^(?:a|area)$/i;he.fn.extend({prop:function(e,t){return Ie(this,he.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each(function(){delete this[he.propFix[e]||e]})}}),he.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&he.isXMLDoc(e)||(t=he.propFix[t]||t,i=he.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=he.find.attr(e,"tabindex");return t?parseInt(t,10):bt.test(e.nodeName)||wt.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),pe.optSelected||(he.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),he.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){he.propFix[this.toLowerCase()]=this}),he.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,u=0;if(he.isFunction(e))return this.each(function(t){he(this).addClass(e.call(this,t,U(this)))});if("string"==typeof e&&e)for(t=e.match(Ne)||[];n=this[u++];)if(i=U(n),r=1===n.nodeType&&" "+z(i)+" "){for(a=0;o=t[a++];)r.indexOf(" "+o+" ")<0&&(r+=o+" ");s=z(r),i!==s&&n.setAttribute("class",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,u=0;if(he.isFunction(e))return this.each(function(t){he(this).removeClass(e.call(this,t,U(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof e&&e)for(t=e.match(Ne)||[];n=this[u++];)if(i=U(n),r=1===n.nodeType&&" "+z(i)+" "){for(a=0;o=t[a++];)for(;r.indexOf(" "+o+" ")>-1;)r=r.replace(" "+o+" "," ");s=z(r),i!==s&&n.setAttribute("class",s)}return this},toggleClass:function(e,t){var n="undefined"==typeof e?"undefined":_typeof(e);return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):this.each(he.isFunction(e)?function(n){he(this).toggleClass(e.call(this,n,U(this),t),t)}:function(){var t,r,i,o;if("string"===n)for(r=0,i=he(this),o=e.match(Ne)||[];t=o[r++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else(void 0===e||"boolean"===n)&&(t=U(this),t&&Le.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||e===!1?"":Le.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;for(t=" "+e+" ";n=this[r++];)if(1===n.nodeType&&(" "+z(U(n))+" ").indexOf(t)>-1)return!0;return!1}});var xt=/\r/g;he.fn.extend({val:function(e){var t,n,r,i=this[0];{if(arguments.length)return r=he.isFunction(e),this.each(function(n){var i;1===this.nodeType&&(i=r?e.call(this,n,he(this).val()):e,null==i?i="":"number"==typeof i?i+="":he.isArray(i)&&(i=he.map(i,function(e){return null==e?"":e+""})),t=he.valHooks[this.type]||he.valHooks[this.nodeName.toLowerCase()],t&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))});if(i)return t=he.valHooks[i.type]||he.valHooks[i.nodeName.toLowerCase()],t&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:(n=i.value,"string"==typeof n?n.replace(xt,""):null==n?"":n)}}}),he.extend({valHooks:{option:{get:function(e){var t=he.find.attr(e,"value");return null!=t?t:z(he.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=0>o?u:a?o:0;u>r;r++)if(n=i[r],!(!n.selected&&r!==o||n.disabled||n.parentNode.disabled&&he.nodeName(n.parentNode,"optgroup"))){if(t=he(n).val(),a)return t;s.push(t)}return s},set:function(e,t){for(var n,r,i=e.options,o=he.makeArray(t),a=i.length;a--;)r=i[a],(r.selected=he.inArray(he.valHooks.option.get(r),o)>-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),he.each(["radio","checkbox"],function(){he.valHooks[this]={set:function(e,t){return he.isArray(t)?e.checked=he.inArray(he(e).val(),t)>-1:void 0}},pe.checkOn||(he.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Tt=/^(?:focusinfocus|focusoutblur)$/;he.extend(he.event,{trigger:function(t,n,r,i){var o,a,s,u,c,l,f,p=[r||te],d=ce.call(t,"type")?t.type:t,h=ce.call(t,"namespace")?t.namespace.split("."):[];if(a=s=r=r||te,3!==r.nodeType&&8!==r.nodeType&&!Tt.test(d+he.event.triggered)&&(d.indexOf(".")>-1&&(h=d.split("."),d=h.shift(),h.sort()),c=d.indexOf(":")<0&&"on"+d,t=t[he.expando]?t:new he.Event(d,"object"===("undefined"==typeof t?"undefined":_typeof(t))&&t),t.isTrigger=i?2:3,t.namespace=h.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:he.makeArray(n,[t]),f=he.event.special[d]||{},i||!f.trigger||f.trigger.apply(r,n)!==!1)){if(!i&&!f.noBubble&&!he.isWindow(r)){for(u=f.delegateType||d,Tt.test(u+d)||(a=a.parentNode);a;a=a.parentNode)p.push(a),s=a;s===(r.ownerDocument||te)&&p.push(s.defaultView||s.parentWindow||e)}for(o=0;(a=p[o++])&&!t.isPropagationStopped();)t.type=o>1?u:f.bindType||d,l=(Le.get(a,"events")||{})[t.type]&&Le.get(a,"handle"),l&&l.apply(a,n),l=c&&a[c],l&&l.apply&&Me(a)&&(t.result=l.apply(a,n),t.result===!1&&t.preventDefault());return t.type=d,i||t.isDefaultPrevented()||f._default&&f._default.apply(p.pop(),n)!==!1||!Me(r)||c&&he.isFunction(r[d])&&!he.isWindow(r)&&(s=r[c],s&&(r[c]=null),he.event.triggered=d,r[d](),he.event.triggered=void 0,s&&(r[c]=s)),t.result}},simulate:function(e,t,n){var r=he.extend(new he.Event,n,{type:e,isSimulated:!0});he.event.trigger(r,null,t)}}),he.fn.extend({trigger:function(e,t){return this.each(function(){he.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];return n?he.event.trigger(e,t,n,!0):void 0}}),he.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,t){he.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),he.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),pe.focusin="onfocusin"in e,pe.focusin||he.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){he.event.simulate(t,e.target,he.event.fix(e))};he.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=Le.access(r,t);i||r.addEventListener(e,n,!0),Le.access(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=Le.access(r,t)-1;i?Le.access(r,t,i):(r.removeEventListener(e,n,!0),Le.remove(r,t))}}});var St=e.location,Ot=he.now(),jt=/\?/;he.parseXML=function(t){var n;if(!t||"string"!=typeof t)return null;try{n=(new e.DOMParser).parseFromString(t,"text/xml")}catch(e){n=void 0}return(!n||n.getElementsByTagName("parsererror").length)&&he.error("Invalid XML: "+t),n};var kt=/\[\]$/,Ct=/\r?\n/g,At=/^(?:submit|button|image|reset|file)$/i,Et=/^(?:input|select|textarea|keygen)/i;he.param=function(e,t){var n,r=[],i=function(e,t){var n=he.isFunction(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(he.isArray(e)||e.jquery&&!he.isPlainObject(e))he.each(e,function(){i(this.name,this.value)});else for(n in e)G(n,e[n],t,i);return r.join("&")},he.fn.extend({serialize:function(){return he.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=he.prop(this,"elements");return e?he.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!he(this).is(":disabled")&&Et.test(this.nodeName)&&!At.test(e)&&(this.checked||!ze.test(e))}).map(function(e,t){var n=he(this).val();return null==n?null:he.isArray(n)?he.map(n,function(e){return{name:t.name,value:e.replace(Ct,"\r\n")}}):{name:t.name,value:n.replace(Ct,"\r\n")}}).get()}});var Nt=/%20/g,_t=/#.*$/,Pt=/([?&])_=[^&]*/,It=/^(.*?):[ \t]*([^\r\n]*)$/gm,Mt=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Lt=/^(?:GET|HEAD)$/,Ft=/^\/\//,Dt={},qt={},Rt="*/".concat("*"),Ht=te.createElement("a");Ht.href=St.href,he.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:St.href,type:"GET",isLocal:Mt.test(St.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Rt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":he.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Y(Y(e,he.ajaxSettings),t):Y(he.ajaxSettings,e)},ajaxPrefilter:X(Dt),ajaxTransport:X(qt),ajax:function(t,n){function r(t,n,r,s){var c,p,d,w,x,T=n;l||(l=!0,u&&e.clearTimeout(u),i=void 0,a=s||"",S.readyState=t>0?4:0,c=t>=200&&300>t||304===t,r&&(w=Z(h,S,r)),w=Q(h,w,S,c),c?(h.ifModified&&(x=S.getResponseHeader("Last-Modified"),x&&(he.lastModified[o]=x),x=S.getResponseHeader("etag"),x&&(he.etag[o]=x)),204===t||"HEAD"===h.type?T="nocontent":304===t?T="notmodified":(T=w.state,p=w.data,d=w.error,c=!d)):(d=T,(t||!T)&&(T="error",0>t&&(t=0))),S.status=t,S.statusText=(n||T)+"",c?y.resolveWith(m,[p,T,S]):y.rejectWith(m,[S,T,d]),S.statusCode(b),b=void 0,f&&g.trigger(c?"ajaxSuccess":"ajaxError",[S,h,c?p:d]),v.fireWith(m,[S,T]),f&&(g.trigger("ajaxComplete",[S,h]),--he.active||he.event.trigger("ajaxStop")))}"object"===("undefined"==typeof t?"undefined":_typeof(t))&&(n=t,t=void 0),n=n||{};var i,o,a,s,u,c,l,f,p,d,h=he.ajaxSetup({},n),m=h.context||h,g=h.context&&(m.nodeType||m.jquery)?he(m):he.event,y=he.Deferred(),v=he.Callbacks("once memory"),b=h.statusCode||{},w={},x={},T="canceled",S={readyState:0,getResponseHeader:function(e){var t;if(l){if(!s)for(s={};t=It.exec(a);)s[t[1].toLowerCase()]=t[2];t=s[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return l?a:null},setRequestHeader:function(e,t){return null==l&&(e=x[e.toLowerCase()]=x[e.toLowerCase()]||e,w[e]=t),this},overrideMimeType:function(e){return null==l&&(h.mimeType=e),this},statusCode:function(e){var t;if(e)if(l)S.always(e[S.status]);else for(t in e)b[t]=[b[t],e[t]];return this},abort:function(e){var t=e||T;return i&&i.abort(t),r(0,t),this}};if(y.promise(S),h.url=((t||h.url||St.href)+"").replace(Ft,St.protocol+"//"),h.type=n.method||n.type||h.method||h.type,h.dataTypes=(h.dataType||"*").toLowerCase().match(Ne)||[""],null==h.crossDomain){c=te.createElement("a");try{c.href=h.url,c.href=c.href,h.crossDomain=Ht.protocol+"//"+Ht.host!=c.protocol+"//"+c.host}catch(e){h.crossDomain=!0}}if(h.data&&h.processData&&"string"!=typeof h.data&&(h.data=he.param(h.data,h.traditional)),J(Dt,h,n,S),l)return S;f=he.event&&h.global,f&&0===he.active++&&he.event.trigger("ajaxStart"),h.type=h.type.toUpperCase(),h.hasContent=!Lt.test(h.type),o=h.url.replace(_t,""),h.hasContent?h.data&&h.processData&&0===(h.contentType||"").indexOf("application/x-www-form-urlencoded")&&(h.data=h.data.replace(Nt,"+")):(d=h.url.slice(o.length),h.data&&(o+=(jt.test(o)?"&":"?")+h.data,delete h.data),h.cache===!1&&(o=o.replace(Pt,"$1"),d=(jt.test(o)?"&":"?")+"_="+Ot++ +d),h.url=o+d),h.ifModified&&(he.lastModified[o]&&S.setRequestHeader("If-Modified-Since",he.lastModified[o]),he.etag[o]&&S.setRequestHeader("If-None-Match",he.etag[o])),(h.data&&h.hasContent&&h.contentType!==!1||n.contentType)&&S.setRequestHeader("Content-Type",h.contentType),S.setRequestHeader("Accept",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+("*"!==h.dataTypes[0]?", "+Rt+"; q=0.01":""):h.accepts["*"]);for(p in h.headers)S.setRequestHeader(p,h.headers[p]);if(h.beforeSend&&(h.beforeSend.call(m,S,h)===!1||l))return S.abort();if(T="abort",v.add(h.complete),S.done(h.success),S.fail(h.error),i=J(qt,h,n,S)){if(S.readyState=1,f&&g.trigger("ajaxSend",[S,h]),l)return S;h.async&&h.timeout>0&&(u=e.setTimeout(function(){S.abort("timeout")},h.timeout));try{l=!1,i.send(w,r)}catch(e){if(l)throw e;r(-1,e)}}else r(-1,"No Transport");return S},getJSON:function(e,t,n){return he.get(e,t,n,"json")},getScript:function(e,t){return he.get(e,void 0,t,"script")}}),he.each(["get","post"],function(e,t){he[t]=function(e,n,r,i){return he.isFunction(n)&&(i=i||r,r=n,n=void 0),he.ajax(he.extend({url:e,type:t,dataType:i,data:n,success:r},he.isPlainObject(e)&&e))}}),he._evalUrl=function(e){return he.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},he.fn.extend({wrapAll:function(e){var t;return this[0]&&(he.isFunction(e)&&(e=e.call(this[0])),t=he(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(e){return this.each(he.isFunction(e)?function(t){he(this).wrapInner(e.call(this,t))}:function(){var t=he(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=he.isFunction(e);return this.each(function(n){he(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(e){return this.parent(e).not("body").each(function(){he(this).replaceWith(this.childNodes)}),this}}),he.expr.pseudos.hidden=function(e){return!he.expr.pseudos.visible(e)},he.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},he.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var $t={0:200,1223:204},Bt=he.ajaxSettings.xhr();pe.cors=!!Bt&&"withCredentials"in Bt,pe.ajax=Bt=!!Bt,he.ajaxTransport(function(t){var n,r;return pe.cors||Bt&&!t.crossDomain?{send:function(i,o){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");for(a in i)s.setRequestHeader(a,i[a]);n=function(e){return function(){n&&(n=r=s.onload=s.onerror=s.onabort=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!=typeof s.status?o(0,"error"):o(s.status,s.statusText):o($t[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=n(),r=s.onerror=n("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&e.setTimeout(function(){n&&r()})},n=n("abort");try{s.send(t.hasContent&&t.data||null)}catch(e){if(n)throw e}},abort:function(){n&&n()}}:void 0}),he.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),he.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return he.globalEval(e),e}}}),he.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),he.ajaxTransport("script",function(e){if(e.crossDomain){var t,n;return{send:function(r,i){t=he("<script>").prop({charset:e.scriptCharset,src:e.url}).on("load error",n=function(e){t.remove(),n=null,e&&i("error"===e.type?404:200,e.type)}),te.head.appendChild(t[0])},abort:function(){n&&n()}}}});var Vt=[],Wt=/(=)\?(?=&|$)|\?\?/;he.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Vt.pop()||he.expando+"_"+Ot++;return this[e]=!0,e}}),he.ajaxPrefilter("json jsonp",function(t,n,r){var i,o,a,s=t.jsonp!==!1&&(Wt.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Wt.test(t.data)&&"data");return s||"jsonp"===t.dataTypes[0]?(i=t.jsonpCallback=he.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Wt,"$1"+i):t.jsonp!==!1&&(t.url+=(jt.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||he.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always(function(){void 0===o?he(e).removeProp(i):e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,Vt.push(i)),a&&he.isFunction(o)&&o(a[0]),a=o=void 0}),"script"):void 0}),pe.createHTMLDocument=function(){var e=te.implementation.createHTMLDocument("").body;return e.innerHTML="<form></form><form></form>",2===e.childNodes.length}(),he.parseHTML=function(e,t,n){if("string"!=typeof e)return[];"boolean"==typeof t&&(n=t,t=!1);var r,i,o;return t||(pe.createHTMLDocument?(t=te.implementation.createHTMLDocument(""),r=t.createElement("base"),r.href=te.location.href,t.head.appendChild(r)):t=te),i=Se.exec(e),o=!n&&[],i?[t.createElement(i[1])]:(i=b([e],t,o),o&&o.length&&he(o).remove(),he.merge([],i.childNodes))},he.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return s>-1&&(r=z(e.slice(s)),e=e.slice(0,s)),he.isFunction(t)?(n=t,t=void 0):t&&"object"===("undefined"==typeof t?"undefined":_typeof(t))&&(i="POST"),a.length>0&&he.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?he("<div>").append(he.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},he.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){he.fn[t]=function(e){return this.on(t,e)}}),he.expr.pseudos.animated=function(e){return he.grep(he.timers,function(t){return e===t.elem}).length},he.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,c,l=he.css(e,"position"),f=he(e),p={};"static"===l&&(e.style.position="relative"),s=f.offset(),o=he.css(e,"top"),u=he.css(e,"left"),c=("absolute"===l||"fixed"===l)&&(o+u).indexOf("auto")>-1,c?(r=f.position(),a=r.top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),he.isFunction(t)&&(t=t.call(e,n,he.extend({},s))),null!=t.top&&(p.top=t.top-s.top+a),null!=t.left&&(p.left=t.left-s.left+i),"using"in t?t.using.call(e,p):f.css(p)}},he.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){he.offset.setOffset(this,e,t)});var t,n,r,i,o=this[0];if(o)return o.getClientRects().length?(r=o.getBoundingClientRect(),r.width||r.height?(i=o.ownerDocument,n=K(i),t=i.documentElement,{top:r.top+n.pageYOffset-t.clientTop,left:r.left+n.pageXOffset-t.clientLeft}):r):{top:0,left:0}},position:function(){if(this[0]){var e,t,n=this[0],r={top:0,left:0};return"fixed"===he.css(n,"position")?t=n.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),he.nodeName(e[0],"html")||(r=e.offset()),r={top:r.top+he.css(e[0],"borderTopWidth",!0),left:r.left+he.css(e[0],"borderLeftWidth",!0)}),{top:t.top-r.top-he.css(n,"marginTop",!0),left:t.left-r.left-he.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent;e&&"static"===he.css(e,"position");)e=e.offsetParent;return e||Ye})}}),he.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n="pageYOffset"===t;he.fn[e]=function(r){return Ie(this,function(e,r,i){var o=K(e);return void 0===i?o?o[t]:e[r]:void(o?o.scrollTo(n?o.pageXOffset:i,n?i:o.pageYOffset):e[r]=i)},e,r,arguments.length)}}),he.each(["top","left"],function(e,t){he.cssHooks[t]=P(pe.pixelPosition,function(e,n){return n?(n=_(e,t),at.test(n)?he(e).position()[t]+"px":n):void 0})}),he.each({Height:"height",Width:"width"},function(e,t){he.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){he.fn[r]=function(i,o){var a=arguments.length&&(n||"boolean"!=typeof i),s=n||(i===!0||o===!0?"margin":"border");return Ie(this,function(t,n,i){var o;return he.isWindow(t)?0===r.indexOf("outer")?t["inner"+e]:t.document.documentElement["client"+e]:9===t.nodeType?(o=t.documentElement,Math.max(t.body["scroll"+e],o["scroll"+e],t.body["offset"+e],o["offset"+e],o["client"+e])):void 0===i?he.css(t,n,s):he.style(t,n,i,s)},t,a?i:void 0,a)}})}),he.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),he.parseJSON=JSON.parse,"function"==typeof define&&define.amd&&define("jquery",[],function(){return he});var zt=e.jQuery,Ut=e.$;return he.noConflict=function(t){return e.$===he&&(e.$=Ut),t&&e.jQuery===he&&(e.jQuery=zt),he},t||(e.jQuery=e.$=he),he}),/*!
+var requirejs,require,define;!function(e){function t(e,t){return v.call(e,t)}function n(e,t){var n,r,i,o,a,s,c,u,l,f,p,d,h=t&&t.split("/"),y=g.map,m=y&&y["*"]||{};if(e){for(e=e.split("/"),a=e.length-1,g.nodeIdCompat&&w.test(e[a])&&(e[a]=e[a].replace(w,"")),"."===e[0].charAt(0)&&h&&(d=h.slice(0,h.length-1),e=d.concat(e)),l=0;l<e.length;l++)if("."===(p=e[l]))e.splice(l,1),l-=1;else if(".."===p){if(0===l||1===l&&".."===e[2]||".."===e[l-1])continue;l>0&&(e.splice(l-1,2),l-=2)}e=e.join("/")}if((h||m)&&y){for(n=e.split("/"),l=n.length;l>0;l-=1){if(r=n.slice(0,l).join("/"),h)for(f=h.length;f>0;f-=1)if((i=y[h.slice(0,f).join("/")])&&(i=i[r])){o=i,s=l;break}if(o)break;!c&&m&&m[r]&&(c=m[r],u=l)}!o&&c&&(o=c,s=u),o&&(n.splice(0,s,o),e=n.join("/"))}return e}function r(t,n){return function(){var r=b.call(arguments,0);return"string"!=typeof r[0]&&1===r.length&&r.push(null),f.apply(e,r.concat([t,n]))}}function i(e){return function(t){return n(t,e)}}function o(e){return function(t){h[e]=t}}function a(n){if(t(y,n)){var r=y[n];delete y[n],m[n]=!0,l.apply(e,r)}if(!t(h,n)&&!t(m,n))throw new Error("No "+n);return h[n]}function s(e){var t,n=e?e.indexOf("!"):-1;return n>-1&&(t=e.substring(0,n),e=e.substring(n+1,e.length)),[t,e]}function c(e){return e?s(e):[]}function u(e){return function(){return g&&g.config&&g.config[e]||{}}}var l,f,p,d,h={},y={},g={},m={},v=Object.prototype.hasOwnProperty,b=[].slice,w=/\.js$/;p=function(e,t){var r,o=s(e),c=o[0],u=t[1];return e=o[1],c&&(c=n(c,u),r=a(c)),c?e=r&&r.normalize?r.normalize(e,i(u)):n(e,u):(e=n(e,u),o=s(e),c=o[0],e=o[1],c&&(r=a(c))),{f:c?c+"!"+e:e,n:e,pr:c,p:r}},d={require:function(e){return r(e)},exports:function(e){var t=h[e];return void 0!==t?t:h[e]={}},module:function(e){return{id:e,uri:"",exports:h[e],config:u(e)}}},l=function(n,i,s,u){var l,f,g,v,b,w,x,T=[],S=void 0===s?"undefined":_typeof(s);if(u=u||n,w=c(u),"undefined"===S||"function"===S){for(i=!i.length&&s.length?["require","exports","module"]:i,b=0;b<i.length;b+=1)if(v=p(i[b],w),"require"===(f=v.f))T[b]=d.require(n);else if("exports"===f)T[b]=d.exports(n),x=!0;else if("module"===f)l=T[b]=d.module(n);else if(t(h,f)||t(y,f)||t(m,f))T[b]=a(f);else{if(!v.p)throw new Error(n+" missing "+f);v.p.load(v.n,r(u,!0),o(f),{}),T[b]=h[f]}g=s?s.apply(h[n],T):void 0,n&&(l&&l.exports!==e&&l.exports!==h[n]?h[n]=l.exports:g===e&&x||(h[n]=g))}else n&&(h[n]=s)},requirejs=require=f=function(t,n,r,i,o){if("string"==typeof t)return d[t]?d[t](n):a(p(t,c(n)).f);if(!t.splice){if(g=t,g.deps&&f(g.deps,g.callback),!n)return;n.splice?(t=n,n=r,r=null):t=e}return n=n||function(){},"function"==typeof r&&(r=i,i=o),i?l(e,t,n,r):setTimeout(function(){l(e,t,n,r)},4),f},f.config=function(e){return f(e)},requirejs._defined=h,define=function(e,n,r){if("string"!=typeof e)throw new Error("See almond README: incorrect module build, no module name");n.splice||(r=n,n=[]),t(h,e)||t(y,e)||(y[e]=[e,n,r])},define.amd={jQuery:!0}}(),define("almond",function(){}),function(e,t){"object"===("undefined"==typeof module?"undefined":_typeof(module))&&"object"===_typeof(module.exports)?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){function n(e,t,n){t=t||ae;var r,i=t.createElement("script");if(i.text=e,n)for(r in we)n[r]&&(i[r]=n[r]);t.head.appendChild(i).parentNode.removeChild(i)}function r(e){return null==e?e+"":"object"===(void 0===e?"undefined":_typeof(e))||"function"==typeof e?pe[de.call(e)]||"object":void 0===e?"undefined":_typeof(e)}function i(e){var t=!!e&&"length"in e&&e.length,n=r(e);return!ve(e)&&!be(e)&&("array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e)}function o(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}function a(e,t,n){return ve(t)?xe.grep(e,function(e,r){return!!t.call(e,r,e)!==n}):t.nodeType?xe.grep(e,function(e){return e===t!==n}):"string"!=typeof t?xe.grep(e,function(e){return fe.call(t,e)>-1!==n}):xe.filter(t,e,n)}function s(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}function c(e){var t={};return xe.each(e.match(Ie)||[],function(e,n){t[n]=!0}),t}function u(e){return e}function l(e){throw e}function f(e,t,n,r){var i;try{e&&ve(i=e.promise)?i.call(e).done(t).fail(n):e&&ve(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}function p(){ae.removeEventListener("DOMContentLoaded",p),e.removeEventListener("load",p),xe.ready()}function d(e,t){return t.toUpperCase()}function h(e){return e.replace(Le,"ms-").replace(qe,d)}function y(){this.expando=xe.expando+y.uid++}function g(e){return"true"===e||"false"!==e&&("null"===e?null:e===+e+""?+e:Ve.test(e)?JSON.parse(e):e)}function m(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace($e,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n=g(n)}catch(e){}He.set(e,t,n)}else n=void 0;return n}function v(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return xe.css(e,t,"")},c=s(),u=n&&n[3]||(xe.cssNumber[t]?"":"px"),l=(xe.cssNumber[t]||"px"!==u&&+c)&&ze.exec(xe.css(e,t));if(l&&l[3]!==u){for(c/=2,u=u||l[3],l=+c||1;a--;)xe.style(e,t,l+u),(1-o)*(1-(o=s()/c||.5))<=0&&(a=0),l/=o;l*=2,xe.style(e,t,l+u),n=n||[]}return n&&(l=+l||+c||0,i=n[1]?l+(n[1]+1)*n[2]:+n[2],r&&(r.unit=u,r.start=l,r.end=i)),i}function b(e){var t,n=e.ownerDocument,r=e.nodeName,i=Xe[r];return i||(t=n.body.appendChild(n.createElement(r)),i=xe.css(t,"display"),t.parentNode.removeChild(t),"none"===i&&(i="block"),Xe[r]=i,i)}function w(e,t){for(var n,r,i=[],o=0,a=e.length;o<a;o++)r=e[o],r.style&&(n=r.style.display,t?("none"===n&&(i[o]=Fe.get(r,"display")||null,i[o]||(r.style.display="")),""===r.style.display&&Ue(r)&&(i[o]=b(r))):"none"!==n&&(i[o]="none",Fe.set(r,"display",n)));for(o=0;o<a;o++)null!=i[o]&&(e[o].style.display=i[o]);return e}function x(e,t){var n;return n=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&o(e,t)?xe.merge([e],n):n}function T(e,t){for(var n=0,r=e.length;n<r;n++)Fe.set(e[n],"globalEval",!t||Fe.get(t[n],"globalEval"))}function S(e,t,n,i,o){for(var a,s,c,u,l,f,p=t.createDocumentFragment(),d=[],h=0,y=e.length;h<y;h++)if((a=e[h])||0===a)if("object"===r(a))xe.merge(d,a.nodeType?[a]:a);else if(Ke.test(a)){for(s=s||p.appendChild(t.createElement("div")),c=(Je.exec(a)||["",""])[1].toLowerCase(),u=Qe[c]||Qe._default,s.innerHTML=u[1]+xe.htmlPrefilter(a)+u[2],f=u[0];f--;)s=s.lastChild;xe.merge(d,s.childNodes),s=p.firstChild,s.textContent=""}else d.push(t.createTextNode(a));for(p.textContent="",h=0;a=d[h++];)if(i&&xe.inArray(a,i)>-1)o&&o.push(a);else if(l=xe.contains(a.ownerDocument,a),s=x(p.appendChild(a),"script"),l&&T(s),n)for(f=0;a=s[f++];)Ze.test(a.type||"")&&n.push(a);return p}function O(){return!0}function j(){return!1}function k(){try{return ae.activeElement}catch(e){}}function A(e,t,n,r,i,o){var a,s;if("object"===(void 0===t?"undefined":_typeof(t))){"string"!=typeof n&&(r=r||n,n=void 0);for(s in t)A(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=j;else if(!i)return e;return 1===o&&(a=i,i=function(e){return xe().off(e),a.apply(this,arguments)},i.guid=a.guid||(a.guid=xe.guid++)),e.each(function(){xe.event.add(this,t,i,r,n)})}function C(e,t){return o(e,"table")&&o(11!==t.nodeType?t:t.firstChild,"tr")?xe(e).children("tbody")[0]||e:e}function E(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function N(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function _(e,t){var n,r,i,o,a,s,c,u;if(1===t.nodeType){if(Fe.hasData(e)&&(o=Fe.access(e),a=Fe.set(t,o),u=o.events)){delete a.handle,a.events={};for(i in u)for(n=0,r=u[i].length;n<r;n++)xe.event.add(t,i,u[i][n])}He.hasData(e)&&(s=He.access(e),c=xe.extend({},s),He.set(t,c))}}function I(e,t){var n=t.nodeName.toLowerCase();"input"===n&&Ye.test(e.type)?t.checked=e.checked:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}function P(e,t,r,i){t=ue.apply([],t);var o,a,s,c,u,l,f=0,p=e.length,d=p-1,h=t[0],y=ve(h);if(y||p>1&&"string"==typeof h&&!me.checkClone&&at.test(h))return e.each(function(n){var o=e.eq(n);y&&(t[0]=h.call(this,n,o.html())),P(o,t,r,i)});if(p&&(o=S(t,e[0].ownerDocument,!1,e,i),a=o.firstChild,1===o.childNodes.length&&(o=a),a||i)){for(s=xe.map(x(o,"script"),E),c=s.length;f<p;f++)u=o,f!==d&&(u=xe.clone(u,!0,!0),c&&xe.merge(s,x(u,"script"))),r.call(e[f],u,f);if(c)for(l=s[s.length-1].ownerDocument,xe.map(s,N),f=0;f<c;f++)u=s[f],Ze.test(u.type||"")&&!Fe.access(u,"globalEval")&&xe.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?xe._evalUrl&&xe._evalUrl(u.src):n(u.textContent.replace(st,""),l,u))}return e}function M(e,t,n){for(var r,i=t?xe.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||xe.cleanData(x(r)),r.parentNode&&(n&&xe.contains(r.ownerDocument,r)&&T(x(r,"script")),r.parentNode.removeChild(r));return e}function D(e,t,n){var r,i,o,a,s=e.style;return n=n||ut(e),n&&(a=n.getPropertyValue(t)||n[t],""!==a||xe.contains(e.ownerDocument,e)||(a=xe.style(e,t)),!me.pixelBoxStyles()&&ct.test(a)&&lt.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function L(e,t){return{get:function(){return e()?void delete this.get:(this.get=t).apply(this,arguments)}}}function q(e){if(e in gt)return e;for(var t=e[0].toUpperCase()+e.slice(1),n=yt.length;n--;)if((e=yt[n]+t)in gt)return e}function R(e){var t=xe.cssProps[e];return t||(t=xe.cssProps[e]=q(e)||e),t}function F(e,t,n){var r=ze.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function H(e,t,n,r,i,o){var a="width"===t?1:0,s=0,c=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(c+=xe.css(e,n+We[a],!0,i)),r?("content"===n&&(c-=xe.css(e,"padding"+We[a],!0,i)),"margin"!==n&&(c-=xe.css(e,"border"+We[a]+"Width",!0,i))):(c+=xe.css(e,"padding"+We[a],!0,i),"padding"!==n?c+=xe.css(e,"border"+We[a]+"Width",!0,i):s+=xe.css(e,"border"+We[a]+"Width",!0,i));return!r&&o>=0&&(c+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-c-s-.5))),c}function V(e,t,n){var r=ut(e),i=D(e,t,r),o="border-box"===xe.css(e,"boxSizing",!1,r),a=o;if(ct.test(i)){if(!n)return i;i="auto"}return a=a&&(me.boxSizingReliable()||i===e.style[t]),("auto"===i||!parseFloat(i)&&"inline"===xe.css(e,"display",!1,r))&&(i=e["offset"+t[0].toUpperCase()+t.slice(1)],a=!0),(i=parseFloat(i)||0)+H(e,t,n||(o?"border":"content"),a,r,i)+"px"}function $(e,t,n,r,i){return new $.prototype.init(e,t,n,r,i)}function B(){vt&&(!1===ae.hidden&&e.requestAnimationFrame?e.requestAnimationFrame(B):e.setTimeout(B,xe.fx.interval),xe.fx.tick())}function z(){return e.setTimeout(function(){mt=void 0}),mt=Date.now()}function W(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)n=We[r],i["margin"+n]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function U(e,t,n){for(var r,i=(Y.tweeners[t]||[]).concat(Y.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function G(e,t,n){var r,i,o,a,s,c,u,l,f="width"in t||"height"in t,p=this,d={},h=e.style,y=e.nodeType&&Ue(e),g=Fe.get(e,"fxshow");n.queue||(a=xe._queueHooks(e,"fx"),null==a.unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,xe.queue(e,"fx").length||a.empty.fire()})}));for(r in t)if(i=t[r],bt.test(i)){if(delete t[r],o=o||"toggle"===i,i===(y?"hide":"show")){if("show"!==i||!g||void 0===g[r])continue;y=!0}d[r]=g&&g[r]||xe.style(e,r)}if((c=!xe.isEmptyObject(t))||!xe.isEmptyObject(d)){f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],u=g&&g.display,null==u&&(u=Fe.get(e,"display")),l=xe.css(e,"display"),"none"===l&&(u?l=u:(w([e],!0),u=e.style.display||u,l=xe.css(e,"display"),w([e]))),("inline"===l||"inline-block"===l&&null!=u)&&"none"===xe.css(e,"float")&&(c||(p.done(function(){h.display=u}),null==u&&(l=h.display,u="none"===l?"":l)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),c=!1;for(r in d)c||(g?"hidden"in g&&(y=g.hidden):g=Fe.access(e,"fxshow",{display:u}),o&&(g.hidden=!y),y&&w([e],!0),p.done(function(){y||w([e]),Fe.remove(e,"fxshow");for(r in d)xe.style(e,r,d[r])})),c=U(y?g[r]:0,r,p),r in g||(g[r]=c.start,y&&(c.end=c.start,c.start=0))}}function X(e,t){var n,r,i,o,a;for(n in e)if(r=h(n),i=t[r],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=xe.cssHooks[r])&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}function Y(e,t,n){var r,i,o=0,a=Y.prefilters.length,s=xe.Deferred().always(function(){delete c.elem}),c=function(){if(i)return!1;for(var t=mt||z(),n=Math.max(0,u.startTime+u.duration-t),r=n/u.duration||0,o=1-r,a=0,c=u.tweens.length;a<c;a++)u.tweens[a].run(o);return s.notifyWith(e,[u,o,n]),o<1&&c?n:(c||s.notifyWith(e,[u,1,0]),s.resolveWith(e,[u]),!1)},u=s.promise({elem:e,props:xe.extend({},t),opts:xe.extend(!0,{specialEasing:{},easing:xe.easing._default},n),originalProperties:t,originalOptions:n,startTime:mt||z(),duration:n.duration,tweens:[],createTween:function(t,n){var r=xe.Tween(e,u.opts,t,n,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(r),r},stop:function(t){var n=0,r=t?u.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)u.tweens[n].run(1);return t?(s.notifyWith(e,[u,1,0]),s.resolveWith(e,[u,t])):s.rejectWith(e,[u,t]),this}}),l=u.props;for(X(l,u.opts.specialEasing);o<a;o++)if(r=Y.prefilters[o].call(u,e,l,u.opts))return ve(r.stop)&&(xe._queueHooks(u.elem,u.opts.queue).stop=r.stop.bind(r)),r;return xe.map(l,U,u),ve(u.opts.start)&&u.opts.start.call(e,u),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always),xe.fx.timer(xe.extend(c,{elem:e,anim:u,queue:u.opts.queue})),u}function J(e){return(e.match(Ie)||[]).join(" ")}function Z(e){return e.getAttribute&&e.getAttribute("class")||""}function Q(e){return Array.isArray(e)?e:"string"==typeof e?e.match(Ie)||[]:[]}function K(e,t,n,i){var o;if(Array.isArray(t))xe.each(t,function(t,r){n||_t.test(e)?i(e,r):K(e+"["+("object"===(void 0===r?"undefined":_typeof(r))&&null!=r?t:"")+"]",r,n,i)});else if(n||"object"!==r(t))i(e,t);else for(o in t)K(e+"["+o+"]",t[o],n,i)}function ee(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(Ie)||[];if(ve(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function te(e,t,n,r){function i(s){var c;return o[s]=!0,xe.each(e[s]||[],function(e,s){var u=s(t,n,r);return"string"!=typeof u||a||o[u]?a?!(c=u):void 0:(t.dataTypes.unshift(u),i(u),!1)}),c}var o={},a=e===Bt;return i(t.dataTypes[0])||!o["*"]&&i("*")}function ne(e,t){var n,r,i=xe.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&xe.extend(!0,e,r),e}function re(e,t,n){for(var r,i,o,a,s=e.contents,c=e.dataTypes;"*"===c[0];)c.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){c.unshift(i);break}if(c[0]in n)o=c[0];else{for(i in n){if(!c[0]||e.converters[i+" "+c[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==c[0]&&c.unshift(o),n[o]}function ie(e,t,n,r){var i,o,a,s,c,u={},l=e.dataTypes.slice();if(l[1])for(a in e.converters)u[a.toLowerCase()]=e.converters[a];for(o=l.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!c&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),c=o,o=l.shift())if("*"===o)o=c;else if("*"!==c&&c!==o){if(!(a=u[c+" "+o]||u["* "+o]))for(i in u)if(s=i.split(" "),s[1]===o&&(a=u[c+" "+s[0]]||u["* "+s[0]])){!0===a?a=u[i]:!0!==u[i]&&(o=s[0],l.unshift(s[1]));break}if(!0!==a)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+c+" to "+o}}}return{state:"success",data:t}}var oe=[],ae=e.document,se=Object.getPrototypeOf,ce=oe.slice,ue=oe.concat,le=oe.push,fe=oe.indexOf,pe={},de=pe.toString,he=pe.hasOwnProperty,ye=he.toString,ge=ye.call(Object),me={},ve=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},be=function(e){return null!=e&&e===e.window},we={type:!0,src:!0,noModule:!0},xe=function e(t,n){return new e.fn.init(t,n)},Te=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;xe.fn=xe.prototype={jquery:"3.3.1",constructor:xe,length:0,toArray:function(){return ce.call(this)},get:function(e){return null==e?ce.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=xe.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return xe.each(this,e)},map:function(e){return this.pushStack(xe.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(ce.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:le,sort:oe.sort,splice:oe.splice},xe.extend=xe.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,c=arguments.length,u=!1;for("boolean"==typeof a&&(u=a,a=arguments[s]||{},s++),"object"===(void 0===a?"undefined":_typeof(a))||ve(a)||(a={}),s===c&&(a=this,s--);s<c;s++)if(null!=(e=arguments[s]))for(t in e)n=a[t],r=e[t],a!==r&&(u&&r&&(xe.isPlainObject(r)||(i=Array.isArray(r)))?(i?(i=!1,o=n&&Array.isArray(n)?n:[]):o=n&&xe.isPlainObject(n)?n:{},a[t]=xe.extend(u,o,r)):void 0!==r&&(a[t]=r));return a},xe.extend({expando:"jQuery"+("3.3.1"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==de.call(e))&&(!(t=se(e))||"function"==typeof(n=he.call(t,"constructor")&&t.constructor)&&ye.call(n)===ge)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e){n(e)},each:function(e,t){var n,r=0;if(i(e))for(n=e.length;r<n&&!1!==t.call(e[r],r,e[r]);r++);else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},trim:function(e){return null==e?"":(e+"").replace(Te,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(i(Object(e))?xe.merge(n,"string"==typeof e?[e]:e):le.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:fe.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,o,a=0,s=[];if(i(e))for(r=e.length;a<r;a++)null!=(o=t(e[a],a,n))&&s.push(o);else for(a in e)null!=(o=t(e[a],a,n))&&s.push(o);return ue.apply([],s)},guid:1,support:me}),"function"==typeof Symbol&&(xe.fn[Symbol.iterator]=oe[Symbol.iterator]),xe.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){pe["[object "+t+"]"]=t.toLowerCase()});var Se=function(e){function t(e,t,n,r){var i,o,a,s,c,l,p,d=t&&t.ownerDocument,h=t?t.nodeType:9;if(n=n||[],"string"!=typeof e||!e||1!==h&&9!==h&&11!==h)return n;if(!r&&((t?t.ownerDocument||t:F)!==_&&N(t),t=t||_,P)){if(11!==h&&(c=ye.exec(e)))if(i=c[1]){if(9===h){if(!(a=t.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(d&&(a=d.getElementById(i))&&q(t,a)&&a.id===i)return n.push(a),n}else{if(c[2])return J.apply(n,t.getElementsByTagName(e)),n;if((i=c[3])&&w.getElementsByClassName&&t.getElementsByClassName)return J.apply(n,t.getElementsByClassName(i)),n}if(w.qsa&&!z[e+" "]&&(!M||!M.test(e))){if(1!==h)d=t,p=e;else if("object"!==t.nodeName.toLowerCase()){for((s=t.getAttribute("id"))?s=s.replace(be,we):t.setAttribute("id",s=R),l=O(e),o=l.length;o--;)l[o]="#"+s+" "+f(l[o]);p=l.join(","),d=ge.test(e)&&u(t.parentNode)||t}if(p)try{return J.apply(n,d.querySelectorAll(p)),n}catch(e){}finally{s===R&&t.removeAttribute("id")}}}return k(e.replace(oe,"$1"),t,n,r)}function n(){function e(n,r){return t.push(n+" ")>x.cacheLength&&delete e[t.shift()],e[n+" "]=r}var t=[];return e}function r(e){return e[R]=!0,e}function i(e){var t=_.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function o(e,t){for(var n=e.split("|"),r=n.length;r--;)x.attrHandle[n[r]]=t}function a(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function s(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&Te(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function c(e){return r(function(t){return t=+t,r(function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function u(e){return e&&void 0!==e.getElementsByTagName&&e}function l(){}function f(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function p(e,t,n){var r=t.dir,i=t.next,o=i||r,a=n&&"parentNode"===o,s=V++;return t.first?function(t,n,i){for(;t=t[r];)if(1===t.nodeType||a)return e(t,n,i);return!1}:function(t,n,c){var u,l,f,p=[H,s];if(c){for(;t=t[r];)if((1===t.nodeType||a)&&e(t,n,c))return!0}else for(;t=t[r];)if(1===t.nodeType||a)if(f=t[R]||(t[R]={}),l=f[t.uniqueID]||(f[t.uniqueID]={}),i&&i===t.nodeName.toLowerCase())t=t[r]||t;else{if((u=l[o])&&u[0]===H&&u[1]===s)return p[2]=u[2];if(l[o]=p,p[2]=e(t,n,c))return!0}return!1}}function d(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function h(e,n,r){for(var i=0,o=n.length;i<o;i++)t(e,n[i],r);return r}function y(e,t,n,r,i){for(var o,a=[],s=0,c=e.length,u=null!=t;s<c;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),u&&t.push(s)));return a}function g(e,t,n,i,o,a){return i&&!i[R]&&(i=g(i)),o&&!o[R]&&(o=g(o,a)),r(function(r,a,s,c){var u,l,f,p=[],d=[],g=a.length,m=r||h(t||"*",s.nodeType?[s]:s,[]),v=!e||!r&&t?m:y(m,p,e,s,c),b=n?o||(r?e:g||i)?[]:a:v;if(n&&n(v,b,s,c),i)for(u=y(b,d),i(u,[],s,c),l=u.length;l--;)(f=u[l])&&(b[d[l]]=!(v[d[l]]=f));if(r){if(o||e){if(o){for(u=[],l=b.length;l--;)(f=b[l])&&u.push(v[l]=f);o(null,b=[],u,c)}for(l=b.length;l--;)(f=b[l])&&(u=o?Q(r,f):p[l])>-1&&(r[u]=!(a[u]=f))}}else b=y(b===a?b.splice(g,b.length):b),o?o(null,a,b,c):J.apply(a,b)})}function m(e){for(var t,n,r,i=e.length,o=x.relative[e[0].type],a=o||x.relative[" "],s=o?1:0,c=p(function(e){return e===t},a,!0),u=p(function(e){return Q(t,e)>-1},a,!0),l=[function(e,n,r){var i=!o&&(r||n!==A)||((t=n).nodeType?c(e,n,r):u(e,n,r));return t=null,i}];s<i;s++)if(n=x.relative[e[s].type])l=[p(d(l),n)];else{if(n=x.filter[e[s].type].apply(null,e[s].matches),n[R]){for(r=++s;r<i&&!x.relative[e[r].type];r++);return g(s>1&&d(l),s>1&&f(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(oe,"$1"),n,s<r&&m(e.slice(s,r)),r<i&&m(e=e.slice(r)),r<i&&f(e))}l.push(n)}return d(l)}function v(e,n){var i=n.length>0,o=e.length>0,a=function(r,a,s,c,u){var l,f,p,d=0,h="0",g=r&&[],m=[],v=A,b=r||o&&x.find.TAG("*",u),w=H+=null==v?1:Math.random()||.1,T=b.length;for(u&&(A=a===_||a||u);h!==T&&null!=(l=b[h]);h++){if(o&&l){for(f=0,a||l.ownerDocument===_||(N(l),s=!P);p=e[f++];)if(p(l,a||_,s)){c.push(l);break}u&&(H=w)}i&&((l=!p&&l)&&d--,r&&g.push(l))}if(d+=h,i&&h!==d){for(f=0;p=n[f++];)p(g,m,a,s);if(r){if(d>0)for(;h--;)g[h]||m[h]||(m[h]=X.call(c));m=y(m)}J.apply(c,m),u&&!r&&m.length>0&&d+n.length>1&&t.uniqueSort(c)}return u&&(H=w,A=v),g};return i?r(a):a}var b,w,x,T,S,O,j,k,A,C,E,N,_,I,P,M,D,L,q,R="sizzle"+1*new Date,F=e.document,H=0,V=0,$=n(),B=n(),z=n(),W=function(e,t){return e===t&&(E=!0),0},U={}.hasOwnProperty,G=[],X=G.pop,Y=G.push,J=G.push,Z=G.slice,Q=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",ee="[\\x20\\t\\r\\n\\f]",te="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",ne="\\["+ee+"*("+te+")(?:"+ee+"*([*^$|!~]?=)"+ee+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+te+"))|)"+ee+"*\\]",re=":("+te+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+ne+")*)|.*)\\)|)",ie=new RegExp(ee+"+","g"),oe=new RegExp("^"+ee+"+|((?:^|[^\\\\])(?:\\\\.)*)"+ee+"+$","g"),ae=new RegExp("^"+ee+"*,"+ee+"*"),se=new RegExp("^"+ee+"*([>+~]|"+ee+")"+ee+"*"),ce=new RegExp("="+ee+"*([^\\]'\"]*?)"+ee+"*\\]","g"),ue=new RegExp(re),le=new RegExp("^"+te+"$"),fe={ID:new RegExp("^#("+te+")"),CLASS:new RegExp("^\\.("+te+")"),TAG:new RegExp("^("+te+"|[*])"),ATTR:new RegExp("^"+ne),PSEUDO:new RegExp("^"+re),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+ee+"*(even|odd|(([+-]|)(\\d*)n|)"+ee+"*(?:([+-]|)"+ee+"*(\\d+)|))"+ee+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+ee+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+ee+"*((?:-\\d)?\\d*)"+ee+"*\\)|)(?=[^-]|$)","i")},pe=/^(?:input|select|textarea|button)$/i,de=/^h\d$/i,he=/^[^{]+\{\s*\[native \w/,ye=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ge=/[+~]/,me=new RegExp("\\\\([\\da-f]{1,6}"+ee+"?|("+ee+")|.)","ig"),ve=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},be=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,we=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},xe=function(){N()},Te=p(function(e){return!0===e.disabled&&("form"in e||"label"in e)},{dir:"parentNode",next:"legend"});try{J.apply(G=Z.call(F.childNodes),F.childNodes),G[F.childNodes.length].nodeType}catch(e){J={apply:G.length?function(e,t){Y.apply(e,Z.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}w=t.support={},S=t.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},N=t.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:F;return r!==_&&9===r.nodeType&&r.documentElement?(_=r,I=_.documentElement,P=!S(_),F!==_&&(n=_.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",xe,!1):n.attachEvent&&n.attachEvent("onunload",xe)),w.attributes=i(function(e){return e.className="i",!e.getAttribute("className")}),w.getElementsByTagName=i(function(e){return e.appendChild(_.createComment("")),!e.getElementsByTagName("*").length}),w.getElementsByClassName=he.test(_.getElementsByClassName),w.getById=i(function(e){return I.appendChild(e).id=R,!_.getElementsByName||!_.getElementsByName(R).length}),w.getById?(x.filter.ID=function(e){var t=e.replace(me,ve);return function(e){return e.getAttribute("id")===t}},x.find.ID=function(e,t){if(void 0!==t.getElementById&&P){var n=t.getElementById(e);return n?[n]:[]}}):(x.filter.ID=function(e){var t=e.replace(me,ve);return function(e){var n=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}},x.find.ID=function(e,t){if(void 0!==t.getElementById&&P){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];for(i=t.getElementsByName(e),r=0;o=i[r++];)if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),x.find.TAG=w.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):w.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},x.find.CLASS=w.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&P)return t.getElementsByClassName(e)},D=[],M=[],(w.qsa=he.test(_.querySelectorAll))&&(i(function(e){I.appendChild(e).innerHTML="<a id='"+R+"'></a><select id='"+R+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&M.push("[*^$]="+ee+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||M.push("\\["+ee+"*(?:value|"+K+")"),e.querySelectorAll("[id~="+R+"-]").length||M.push("~="),e.querySelectorAll(":checked").length||M.push(":checked"),e.querySelectorAll("a#"+R+"+*").length||M.push(".#.+[+~]")}),i(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=_.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&M.push("name"+ee+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&M.push(":enabled",":disabled"),I.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&M.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),M.push(",.*:")})),(w.matchesSelector=he.test(L=I.matches||I.webkitMatchesSelector||I.mozMatchesSelector||I.oMatchesSelector||I.msMatchesSelector))&&i(function(e){w.disconnectedMatch=L.call(e,"*"),L.call(e,"[s!='']:x"),D.push("!=",re)}),M=M.length&&new RegExp(M.join("|")),D=D.length&&new RegExp(D.join("|")),t=he.test(I.compareDocumentPosition),q=t||he.test(I.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},W=t?function(e,t){if(e===t)return E=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&n||!w.sortDetached&&t.compareDocumentPosition(e)===n?e===_||e.ownerDocument===F&&q(F,e)?-1:t===_||t.ownerDocument===F&&q(F,t)?1:C?Q(C,e)-Q(C,t):0:4&n?-1:1)}:function(e,t){if(e===t)return E=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,s=[e],c=[t];if(!i||!o)return e===_?-1:t===_?1:i?-1:o?1:C?Q(C,e)-Q(C,t):0;if(i===o)return a(e,t);for(n=e;n=n.parentNode;)s.unshift(n);for(n=t;n=n.parentNode;)c.unshift(n);for(;s[r]===c[r];)r++;return r?a(s[r],c[r]):s[r]===F?-1:c[r]===F?1:0},_):_},t.matches=function(e,n){return t(e,null,null,n)},t.matchesSelector=function(e,n){if((e.ownerDocument||e)!==_&&N(e),n=n.replace(ce,"='$1']"),w.matchesSelector&&P&&!z[n+" "]&&(!D||!D.test(n))&&(!M||!M.test(n)))try{var r=L.call(e,n);if(r||w.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){}return t(n,_,null,[e]).length>0},t.contains=function(e,t){return(e.ownerDocument||e)!==_&&N(e),q(e,t)},t.attr=function(e,t){(e.ownerDocument||e)!==_&&N(e);var n=x.attrHandle[t.toLowerCase()],r=n&&U.call(x.attrHandle,t.toLowerCase())?n(e,t,!P):void 0;return void 0!==r?r:w.attributes||!P?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},t.escape=function(e){return(e+"").replace(be,we)},t.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},t.uniqueSort=function(e){var t,n=[],r=0,i=0;if(E=!w.detectDuplicates,C=!w.sortStable&&e.slice(0),e.sort(W),E){for(;t=e[i++];)t===e[i]&&(r=n.push(i));for(;r--;)e.splice(n[r],1)}return C=null,e},T=t.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=T(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r++];)n+=T(t);return n},x=t.selectors={cacheLength:50,createPseudo:r,match:fe,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(me,ve),e[3]=(e[3]||e[4]||e[5]||"").replace(me,ve),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||t.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&t.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return fe.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&ue.test(n)&&(t=O(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){
+var t=e.replace(me,ve).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=$[e+" "];return t||(t=new RegExp("(^|"+ee+")"+e+"("+ee+"|$)"))&&$(e,function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,n,r){return function(i){var o=t.attr(i,e);return null==o?"!="===n:!n||(o+="","="===n?o===r:"!="===n?o!==r:"^="===n?r&&0===o.indexOf(r):"*="===n?r&&o.indexOf(r)>-1:"$="===n?r&&o.slice(-r.length)===r:"~="===n?(" "+o.replace(ie," ")+" ").indexOf(r)>-1:"|="===n&&(o===r||o.slice(0,r.length+1)===r+"-"))}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,c){var u,l,f,p,d,h,y=o!==a?"nextSibling":"previousSibling",g=t.parentNode,m=s&&t.nodeName.toLowerCase(),v=!c&&!s,b=!1;if(g){if(o){for(;y;){for(p=t;p=p[y];)if(s?p.nodeName.toLowerCase()===m:1===p.nodeType)return!1;h=y="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?g.firstChild:g.lastChild],a&&v){for(p=g,f=p[R]||(p[R]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),u=l[e]||[],d=u[0]===H&&u[1],b=d&&u[2],p=d&&g.childNodes[d];p=++d&&p&&p[y]||(b=d=0)||h.pop();)if(1===p.nodeType&&++b&&p===t){l[e]=[H,d,b];break}}else if(v&&(p=t,f=p[R]||(p[R]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),u=l[e]||[],d=u[0]===H&&u[1],b=d),!1===b)for(;(p=++d&&p&&p[y]||(b=d=0)||h.pop())&&((s?p.nodeName.toLowerCase()!==m:1!==p.nodeType)||!++b||(v&&(f=p[R]||(p[R]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),l[e]=[H,b]),p!==t)););return(b-=i)===r||b%r==0&&b/r>=0}}},PSEUDO:function(e,n){var i,o=x.pseudos[e]||x.setFilters[e.toLowerCase()]||t.error("unsupported pseudo: "+e);return o[R]?o(n):o.length>1?(i=[e,e,"",n],x.setFilters.hasOwnProperty(e.toLowerCase())?r(function(e,t){for(var r,i=o(e,n),a=i.length;a--;)r=Q(e,i[a]),e[r]=!(t[r]=i[a])}):function(e){return o(e,0,i)}):o}},pseudos:{not:r(function(e){var t=[],n=[],i=j(e.replace(oe,"$1"));return i[R]?r(function(e,t,n,r){for(var o,a=i(e,null,r,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,r,o){return t[0]=e,i(t,null,o,n),t[0]=null,!n.pop()}}),has:r(function(e){return function(n){return t(e,n).length>0}}),contains:r(function(e){return e=e.replace(me,ve),function(t){return(t.textContent||t.innerText||T(t)).indexOf(e)>-1}}),lang:r(function(e){return le.test(e||"")||t.error("unsupported lang: "+e),e=e.replace(me,ve).toLowerCase(),function(t){var n;do{if(n=P?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===I},focus:function(e){return e===_.activeElement&&(!_.hasFocus||_.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:s(!1),disabled:s(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!x.pseudos.empty(e)},header:function(e){return de.test(e.nodeName)},input:function(e){return pe.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:c(function(){return[0]}),last:c(function(e,t){return[t-1]}),eq:c(function(e,t,n){return[n<0?n+t:n]}),even:c(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:c(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:c(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:c(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}},x.pseudos.nth=x.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})x.pseudos[b]=function(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}(b);for(b in{submit:!0,reset:!0})x.pseudos[b]=function(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}(b);return l.prototype=x.filters=x.pseudos,x.setFilters=new l,O=t.tokenize=function(e,n){var r,i,o,a,s,c,u,l=B[e+" "];if(l)return n?0:l.slice(0);for(s=e,c=[],u=x.preFilter;s;){r&&!(i=ae.exec(s))||(i&&(s=s.slice(i[0].length)||s),c.push(o=[])),r=!1,(i=se.exec(s))&&(r=i.shift(),o.push({value:r,type:i[0].replace(oe," ")}),s=s.slice(r.length));for(a in x.filter)!(i=fe[a].exec(s))||u[a]&&!(i=u[a](i))||(r=i.shift(),o.push({value:r,type:a,matches:i}),s=s.slice(r.length));if(!r)break}return n?s.length:s?t.error(e):B(e,c).slice(0)},j=t.compile=function(e,t){var n,r=[],i=[],o=z[e+" "];if(!o){for(t||(t=O(e)),n=t.length;n--;)o=m(t[n]),o[R]?r.push(o):i.push(o);o=z(e,v(i,r)),o.selector=e}return o},k=t.select=function(e,t,n,r){var i,o,a,s,c,l="function"==typeof e&&e,p=!r&&O(e=l.selector||e);if(n=n||[],1===p.length){if(o=p[0]=p[0].slice(0),o.length>2&&"ID"===(a=o[0]).type&&9===t.nodeType&&P&&x.relative[o[1].type]){if(!(t=(x.find.ID(a.matches[0].replace(me,ve),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}for(i=fe.needsContext.test(e)?0:o.length;i--&&(a=o[i],!x.relative[s=a.type]);)if((c=x.find[s])&&(r=c(a.matches[0].replace(me,ve),ge.test(o[0].type)&&u(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&f(o)))return J.apply(n,r),n;break}}return(l||j(e,p))(r,t,!P,n,!t||ge.test(e)&&u(t.parentNode)||t),n},w.sortStable=R.split("").sort(W).join("")===R,w.detectDuplicates=!!E,N(),w.sortDetached=i(function(e){return 1&e.compareDocumentPosition(_.createElement("fieldset"))}),i(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||o("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),w.attributes&&i(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||o("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),i(function(e){return null==e.getAttribute("disabled")})||o(K,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),t}(e);xe.find=Se,xe.expr=Se.selectors,xe.expr[":"]=xe.expr.pseudos,xe.uniqueSort=xe.unique=Se.uniqueSort,xe.text=Se.getText,xe.isXMLDoc=Se.isXML,xe.contains=Se.contains,xe.escapeSelector=Se.escape;var Oe=function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&xe(e).is(n))break;r.push(e)}return r},je=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},ke=xe.expr.match.needsContext,Ae=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;xe.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?xe.find.matchesSelector(r,e)?[r]:[]:xe.find.matches(e,xe.grep(t,function(e){return 1===e.nodeType}))},xe.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(xe(e).filter(function(){for(t=0;t<r;t++)if(xe.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)xe.find(e,i[t],n);return r>1?xe.uniqueSort(n):n},filter:function(e){return this.pushStack(a(this,e||[],!1))},not:function(e){return this.pushStack(a(this,e||[],!0))},is:function(e){return!!a(this,"string"==typeof e&&ke.test(e)?xe(e):e||[],!1).length}});var Ce,Ee=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(xe.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||Ce,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:Ee.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof xe?t[0]:t,xe.merge(this,xe.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:ae,!0)),Ae.test(r[1])&&xe.isPlainObject(t))for(r in t)ve(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return i=ae.getElementById(r[2]),i&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):ve(e)?void 0!==n.ready?n.ready(e):e(xe):xe.makeArray(e,this)}).prototype=xe.fn,Ce=xe(ae);var Ne=/^(?:parents|prev(?:Until|All))/,_e={children:!0,contents:!0,next:!0,prev:!0};xe.fn.extend({has:function(e){var t=xe(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(xe.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&xe(e);if(!ke.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&xe.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?xe.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?fe.call(xe(e),this[0]):fe.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(xe.uniqueSort(xe.merge(this.get(),xe(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),xe.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return Oe(e,"parentNode")},parentsUntil:function(e,t,n){return Oe(e,"parentNode",n)},next:function(e){return s(e,"nextSibling")},prev:function(e){return s(e,"previousSibling")},nextAll:function(e){return Oe(e,"nextSibling")},prevAll:function(e){return Oe(e,"previousSibling")},nextUntil:function(e,t,n){return Oe(e,"nextSibling",n)},prevUntil:function(e,t,n){return Oe(e,"previousSibling",n)},siblings:function(e){return je((e.parentNode||{}).firstChild,e)},children:function(e){return je(e.firstChild)},contents:function(e){return o(e,"iframe")?e.contentDocument:(o(e,"template")&&(e=e.content||e),xe.merge([],e.childNodes))}},function(e,t){xe.fn[e]=function(n,r){var i=xe.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=xe.filter(r,i)),this.length>1&&(_e[e]||xe.uniqueSort(i),Ne.test(e)&&i.reverse()),this.pushStack(i)}});var Ie=/[^\x20\t\r\n\f]+/g;xe.Callbacks=function(e){e="string"==typeof e?c(e):xe.extend({},e);var t,n,i,o,a=[],s=[],u=-1,l=function(){for(o=o||e.once,i=t=!0;s.length;u=-1)for(n=s.shift();++u<a.length;)!1===a[u].apply(n[0],n[1])&&e.stopOnFalse&&(u=a.length,n=!1);e.memory||(n=!1),t=!1,o&&(a=n?[]:"")},f={add:function(){return a&&(n&&!t&&(u=a.length-1,s.push(n)),function t(n){xe.each(n,function(n,i){ve(i)?e.unique&&f.has(i)||a.push(i):i&&i.length&&"string"!==r(i)&&t(i)})}(arguments),n&&!t&&l()),this},remove:function(){return xe.each(arguments,function(e,t){for(var n;(n=xe.inArray(t,a,n))>-1;)a.splice(n,1),n<=u&&u--}),this},has:function(e){return e?xe.inArray(e,a)>-1:a.length>0},empty:function(){return a&&(a=[]),this},disable:function(){return o=s=[],a=n="",this},disabled:function(){return!a},lock:function(){return o=s=[],n||t||(a=n=""),this},locked:function(){return!!o},fireWith:function(e,n){return o||(n=n||[],n=[e,n.slice?n.slice():n],s.push(n),t||l()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!i}};return f},xe.extend({Deferred:function(t){var n=[["notify","progress",xe.Callbacks("memory"),xe.Callbacks("memory"),2],["resolve","done",xe.Callbacks("once memory"),xe.Callbacks("once memory"),0,"resolved"],["reject","fail",xe.Callbacks("once memory"),xe.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return i.then(null,e)},pipe:function(){var e=arguments;return xe.Deferred(function(t){xe.each(n,function(n,r){var i=ve(e[r[4]])&&e[r[4]];o[r[1]](function(){var e=i&&i.apply(this,arguments);e&&ve(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[r[0]+"With"](this,i?[e]:arguments)})}),e=null}).promise()},then:function(t,r,i){function o(t,n,r,i){return function(){var s=this,c=arguments,f=function(){var e,f;if(!(t<a)){if((e=r.apply(s,c))===n.promise())throw new TypeError("Thenable self-resolution");f=e&&("object"===(void 0===e?"undefined":_typeof(e))||"function"==typeof e)&&e.then,ve(f)?i?f.call(e,o(a,n,u,i),o(a,n,l,i)):(a++,f.call(e,o(a,n,u,i),o(a,n,l,i),o(a,n,u,n.notifyWith))):(r!==u&&(s=void 0,c=[e]),(i||n.resolveWith)(s,c))}},p=i?f:function(){try{f()}catch(e){xe.Deferred.exceptionHook&&xe.Deferred.exceptionHook(e,p.stackTrace),t+1>=a&&(r!==l&&(s=void 0,c=[e]),n.rejectWith(s,c))}};t?p():(xe.Deferred.getStackHook&&(p.stackTrace=xe.Deferred.getStackHook()),e.setTimeout(p))}}var a=0;return xe.Deferred(function(e){n[0][3].add(o(0,e,ve(i)?i:u,e.notifyWith)),n[1][3].add(o(0,e,ve(t)?t:u)),n[2][3].add(o(0,e,ve(r)?r:l))}).promise()},promise:function(e){return null!=e?xe.extend(e,i):i}},o={};return xe.each(n,function(e,t){var a=t[2],s=t[5];i[t[1]]=a.add,s&&a.add(function(){r=s},n[3-e][2].disable,n[3-e][3].disable,n[0][2].lock,n[0][3].lock),a.add(t[3].fire),o[t[0]]=function(){return o[t[0]+"With"](this===o?void 0:this,arguments),this},o[t[0]+"With"]=a.fireWith}),i.promise(o),t&&t.call(o,o),o},when:function(e){var t=arguments.length,n=t,r=Array(n),i=ce.call(arguments),o=xe.Deferred(),a=function(e){return function(n){r[e]=this,i[e]=arguments.length>1?ce.call(arguments):n,--t||o.resolveWith(r,i)}};if(t<=1&&(f(e,o.done(a(n)).resolve,o.reject,!t),"pending"===o.state()||ve(i[n]&&i[n].then)))return o.then();for(;n--;)f(i[n],a(n),o.reject);return o.promise()}});var Pe=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;xe.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&Pe.test(t.name)&&e.console.warn("jQuery.Deferred exception: "+t.message,t.stack,n)},xe.readyException=function(t){e.setTimeout(function(){throw t})};var Me=xe.Deferred();xe.fn.ready=function(e){return Me.then(e).catch(function(e){xe.readyException(e)}),this},xe.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--xe.readyWait:xe.isReady)||(xe.isReady=!0,!0!==e&&--xe.readyWait>0||Me.resolveWith(ae,[xe]))}}),xe.ready.then=Me.then,"complete"===ae.readyState||"loading"!==ae.readyState&&!ae.documentElement.doScroll?e.setTimeout(xe.ready):(ae.addEventListener("DOMContentLoaded",p),e.addEventListener("load",p));var De=function e(t,n,i,o,a,s,c){var u=0,l=t.length,f=null==i;if("object"===r(i)){a=!0;for(u in i)e(t,n,u,i[u],!0,s,c)}else if(void 0!==o&&(a=!0,ve(o)||(c=!0),f&&(c?(n.call(t,o),n=null):(f=n,n=function(e,t,n){return f.call(xe(e),n)})),n))for(;u<l;u++)n(t[u],i,c?o:o.call(t[u],u,n(t[u],i)));return a?t:f?n.call(t):l?n(t[0],i):s},Le=/^-ms-/,qe=/-([a-z])/g,Re=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};y.uid=1,y.prototype={cache:function(e){var t=e[this.expando];return t||(t={},Re(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[h(t)]=n;else for(r in t)i[h(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][h(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){Array.isArray(t)?t=t.map(h):(t=h(t),t=t in r?[t]:t.match(Ie)||[]),n=t.length;for(;n--;)delete r[t[n]]}(void 0===t||xe.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!xe.isEmptyObject(t)}};var Fe=new y,He=new y,Ve=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,$e=/[A-Z]/g;xe.extend({hasData:function(e){return He.hasData(e)||Fe.hasData(e)},data:function(e,t,n){return He.access(e,t,n)},removeData:function(e,t){He.remove(e,t)},_data:function(e,t,n){return Fe.access(e,t,n)},_removeData:function(e,t){Fe.remove(e,t)}}),xe.fn.extend({data:function(e,t){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(i=He.get(o),1===o.nodeType&&!Fe.get(o,"hasDataAttrs"))){for(n=a.length;n--;)a[n]&&(r=a[n].name,0===r.indexOf("data-")&&(r=h(r.slice(5)),m(o,r,i[r])));Fe.set(o,"hasDataAttrs",!0)}return i}return"object"===(void 0===e?"undefined":_typeof(e))?this.each(function(){He.set(this,e)}):De(this,function(t){var n;if(o&&void 0===t){if(void 0!==(n=He.get(o,e)))return n;if(void 0!==(n=m(o,e)))return n}else this.each(function(){He.set(this,e,t)})},null,t,arguments.length>1,null,!0)},removeData:function(e){return this.each(function(){He.remove(this,e)})}}),xe.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=Fe.get(e,t),n&&(!r||Array.isArray(n)?r=Fe.access(e,t,xe.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=xe.queue(e,t),r=n.length,i=n.shift(),o=xe._queueHooks(e,t),a=function(){xe.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Fe.get(e,n)||Fe.access(e,n,{empty:xe.Callbacks("once memory").add(function(){Fe.remove(e,[t+"queue",n])})})}}),xe.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?xe.queue(this[0],e):void 0===t?this:this.each(function(){var n=xe.queue(this,e,t);xe._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&xe.dequeue(this,e)})},dequeue:function(e){return this.each(function(){xe.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=xe.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)(n=Fe.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var Be=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ze=new RegExp("^(?:([+-])=|)("+Be+")([a-z%]*)$","i"),We=["Top","Right","Bottom","Left"],Ue=function(e,t){return e=t||e,"none"===e.style.display||""===e.style.display&&xe.contains(e.ownerDocument,e)&&"none"===xe.css(e,"display")},Ge=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i},Xe={};xe.fn.extend({show:function(){return w(this,!0)},hide:function(){return w(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){Ue(this)?xe(this).show():xe(this).hide()})}});var Ye=/^(?:checkbox|radio)$/i,Je=/<([a-z][^\/\0>\x20\t\r\n\f]+)/i,Ze=/^$|^module$|\/(?:java|ecma)script/i,Qe={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Qe.optgroup=Qe.option,Qe.tbody=Qe.tfoot=Qe.colgroup=Qe.caption=Qe.thead,Qe.th=Qe.td;var Ke=/<|&#?\w+;/;!function(){var e=ae.createDocumentFragment(),t=e.appendChild(ae.createElement("div")),n=ae.createElement("input");n.setAttribute("type","radio"),n.setAttribute("checked","checked"),n.setAttribute("name","t"),t.appendChild(n),me.checkClone=t.cloneNode(!0).cloneNode(!0).lastChild.checked,t.innerHTML="<textarea>x</textarea>",me.noCloneChecked=!!t.cloneNode(!0).lastChild.defaultValue}();var et=ae.documentElement,tt=/^key/,nt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,rt=/^([^.]*)(?:\.(.+)|)/;xe.event={global:{},add:function(e,t,n,r,i){var o,a,s,c,u,l,f,p,d,h,y,g=Fe.get(e);if(g)for(n.handler&&(o=n,n=o.handler,i=o.selector),i&&xe.find.matchesSelector(et,i),n.guid||(n.guid=xe.guid++),(c=g.events)||(c=g.events={}),(a=g.handle)||(a=g.handle=function(t){return void 0!==xe&&xe.event.triggered!==t.type?xe.event.dispatch.apply(e,arguments):void 0}),t=(t||"").match(Ie)||[""],u=t.length;u--;)s=rt.exec(t[u])||[],d=y=s[1],h=(s[2]||"").split(".").sort(),d&&(f=xe.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=xe.event.special[d]||{},l=xe.extend({type:d,origType:y,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&xe.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=c[d])||(p=c[d]=[],p.delegateCount=0,f.setup&&!1!==f.setup.call(e,r,h,a)||e.addEventListener&&e.addEventListener(d,a)),f.add&&(f.add.call(e,l),l.handler.guid||(l.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,l):p.push(l),xe.event.global[d]=!0)},remove:function(e,t,n,r,i){var o,a,s,c,u,l,f,p,d,h,y,g=Fe.hasData(e)&&Fe.get(e);if(g&&(c=g.events)){for(t=(t||"").match(Ie)||[""],u=t.length;u--;)if(s=rt.exec(t[u])||[],d=y=s[1],h=(s[2]||"").split(".").sort(),d){for(f=xe.event.special[d]||{},d=(r?f.delegateType:f.bindType)||d,p=c[d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;o--;)l=p[o],!i&&y!==l.origType||n&&n.guid!==l.guid||s&&!s.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(p.splice(o,1),l.selector&&p.delegateCount--,f.remove&&f.remove.call(e,l));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,g.handle)||xe.removeEvent(e,d,g.handle),delete c[d])}else for(d in c)xe.event.remove(e,d+t[u],n,r,!0);xe.isEmptyObject(c)&&Fe.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=xe.event.fix(e),c=new Array(arguments.length),u=(Fe.get(this,"events")||{})[s.type]||[],l=xe.event.special[s.type]||{};for(c[0]=s,t=1;t<arguments.length;t++)c[t]=arguments[t];if(s.delegateTarget=this,!l.preDispatch||!1!==l.preDispatch.call(this,s)){for(a=xe.event.handlers.call(this,s,u),t=0;(i=a[t++])&&!s.isPropagationStopped();)for(s.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!s.isImmediatePropagationStopped();)s.rnamespace&&!s.rnamespace.test(o.namespace)||(s.handleObj=o,s.data=o.data,void 0!==(r=((xe.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,c))&&!1===(s.result=r)&&(s.preventDefault(),s.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,s),s.result}},handlers:function(e,t){var n,r,i,o,a,s=[],c=t.delegateCount,u=e.target;if(c&&u.nodeType&&!("click"===e.type&&e.button>=1))for(;u!==this;u=u.parentNode||this)if(1===u.nodeType&&("click"!==e.type||!0!==u.disabled)){for(o=[],a={},n=0;n<c;n++)r=t[n],i=r.selector+" ",void 0===a[i]&&(a[i]=r.needsContext?xe(i,this).index(u)>-1:xe.find(i,this,null,[u]).length),a[i]&&o.push(r);o.length&&s.push({elem:u,handlers:o})}return u=this,c<t.length&&s.push({elem:u,handlers:t.slice(c)}),s},addProp:function(e,t){Object.defineProperty(xe.Event.prototype,e,{enumerable:!0,configurable:!0,get:ve(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[e]},set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(e){return e[xe.expando]?e:new xe.Event(e)},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==k()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===k()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&o(this,"input"))return this.click(),!1},_default:function(e){return o(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},xe.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},xe.Event=function(e,t){if(!(this instanceof xe.Event))return new xe.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?O:j,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&xe.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[xe.expando]=!0},xe.Event.prototype={constructor:xe.Event,isDefaultPrevented:j,isPropagationStopped:j,isImmediatePropagationStopped:j,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=O,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=O,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=O,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},xe.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&tt.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&nt.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},xe.event.addProp),xe.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){xe.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return i&&(i===r||xe.contains(r,i))||(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),xe.fn.extend({on:function(e,t,n,r){return A(this,e,t,n,r)},one:function(e,t,n,r){return A(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,xe(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"===(void 0===e?"undefined":_typeof(e))){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=j),this.each(function(){xe.event.remove(this,e,n,t)})}});var it=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,ot=/<script|<style|<link/i,at=/checked\s*(?:[^=]|=\s*.checked.)/i,st=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;xe.extend({htmlPrefilter:function(e){return e.replace(it,"<$1></$2>")},clone:function(e,t,n){var r,i,o,a,s=e.cloneNode(!0),c=xe.contains(e.ownerDocument,e);if(!(me.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||xe.isXMLDoc(e)))for(a=x(s),o=x(e),r=0,i=o.length;r<i;r++)I(o[r],a[r]);if(t)if(n)for(o=o||x(e),a=a||x(s),r=0,i=o.length;r<i;r++)_(o[r],a[r]);else _(e,s);return a=x(s,"script"),a.length>0&&T(a,!c&&x(e,"script")),s},cleanData:function(e){for(var t,n,r,i=xe.event.special,o=0;void 0!==(n=e[o]);o++)if(Re(n)){if(t=n[Fe.expando]){if(t.events)for(r in t.events)i[r]?xe.event.remove(n,r):xe.removeEvent(n,r,t.handle);n[Fe.expando]=void 0}n[He.expando]&&(n[He.expando]=void 0)}}}),xe.fn.extend({detach:function(e){return M(this,e,!0)},remove:function(e){return M(this,e)},text:function(e){return De(this,function(e){return void 0===e?xe.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return P(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){C(this,e).appendChild(e)}})},prepend:function(){return P(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=C(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return P(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return P(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(xe.cleanData(x(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return xe.clone(this,e,t)})},html:function(e){return De(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!ot.test(e)&&!Qe[(Je.exec(e)||["",""])[1].toLowerCase()]){e=xe.htmlPrefilter(e);try{for(;n<r;n++)t=this[n]||{},1===t.nodeType&&(xe.cleanData(x(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=[];return P(this,arguments,function(t){var n=this.parentNode;xe.inArray(this,e)<0&&(xe.cleanData(x(this)),n&&n.replaceChild(t,this))},e)}}),xe.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){xe.fn[e]=function(e){for(var n,r=[],i=xe(e),o=i.length-1,a=0;a<=o;a++)n=a===o?this:this.clone(!0),xe(i[a])[t](n),le.apply(r,n.get());return this.pushStack(r)}});var ct=new RegExp("^("+Be+")(?!px)[a-z%]+$","i"),ut=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)},lt=new RegExp(We.join("|"),"i");!function(){function t(){if(u){c.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",u.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",et.appendChild(c).appendChild(u);var t=e.getComputedStyle(u);r="1%"!==t.top,s=12===n(t.marginLeft),u.style.right="60%",a=36===n(t.right),i=36===n(t.width),u.style.position="absolute",o=36===u.offsetWidth||"absolute",et.removeChild(c),u=null}}function n(e){return Math.round(parseFloat(e))}var r,i,o,a,s,c=ae.createElement("div"),u=ae.createElement("div");u.style&&(u.style.backgroundClip="content-box",u.cloneNode(!0).style.backgroundClip="",me.clearCloneStyle="content-box"===u.style.backgroundClip,xe.extend(me,{boxSizingReliable:function(){return t(),i},pixelBoxStyles:function(){return t(),a},pixelPosition:function(){return t(),r},reliableMarginLeft:function(){return t(),s},scrollboxSize:function(){return t(),o}}))}();var ft=/^(none|table(?!-c[ea]).+)/,pt=/^--/,dt={position:"absolute",visibility:"hidden",display:"block"},ht={letterSpacing:"0",fontWeight:"400"},yt=["Webkit","Moz","ms"],gt=ae.createElement("div").style;xe.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=D(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=h(t),c=pt.test(t),u=e.style;if(c||(t=R(s)),a=xe.cssHooks[t]||xe.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:u[t];o=void 0===n?"undefined":_typeof(n),"string"===o&&(i=ze.exec(n))&&i[1]&&(n=v(e,t,i),o="number"),null!=n&&n===n&&("number"===o&&(n+=i&&i[3]||(xe.cssNumber[s]?"":"px")),me.clearCloneStyle||""!==n||0!==t.indexOf("background")||(u[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(c?u.setProperty(t,n):u[t]=n))}},css:function(e,t,n,r){var i,o,a,s=h(t);return pt.test(t)||(t=R(s)),a=xe.cssHooks[t]||xe.cssHooks[s],a&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=D(e,t,r)),"normal"===i&&t in ht&&(i=ht[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),xe.each(["height","width"],function(e,t){xe.cssHooks[t]={get:function(e,n,r){if(n)return!ft.test(xe.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?V(e,t,r):Ge(e,dt,function(){return V(e,t,r)})},set:function(e,n,r){var i,o=ut(e),a="border-box"===xe.css(e,"boxSizing",!1,o),s=r&&H(e,t,r,a,o);return a&&me.scrollboxSize()===o.position&&(s-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-H(e,t,"border",!1,o)-.5)),s&&(i=ze.exec(n))&&"px"!==(i[3]||"px")&&(e.style[t]=n,n=xe.css(e,t)),F(e,n,s)}}}),xe.cssHooks.marginLeft=L(me.reliableMarginLeft,function(e,t){if(t)return(parseFloat(D(e,"marginLeft"))||e.getBoundingClientRect().left-Ge(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),xe.each({margin:"",padding:"",border:"Width"},function(e,t){xe.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];r<4;r++)i[e+We[r]+t]=o[r]||o[r-2]||o[0];return i}},"margin"!==e&&(xe.cssHooks[e+t].set=F)}),xe.fn.extend({css:function(e,t){return De(this,function(e,t,n){var r,i,o={},a=0
+;if(Array.isArray(t)){for(r=ut(e),i=t.length;a<i;a++)o[t[a]]=xe.css(e,t[a],!1,r);return o}return void 0!==n?xe.style(e,t,n):xe.css(e,t)},e,t,arguments.length>1)}}),xe.Tween=$,$.prototype={constructor:$,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||xe.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(xe.cssNumber[n]?"":"px")},cur:function(){var e=$.propHooks[this.prop];return e&&e.get?e.get(this):$.propHooks._default.get(this)},run:function(e){var t,n=$.propHooks[this.prop];return this.options.duration?this.pos=t=xe.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):$.propHooks._default.set(this),this}},$.prototype.init.prototype=$.prototype,$.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=xe.css(e.elem,e.prop,""),t&&"auto"!==t?t:0)},set:function(e){xe.fx.step[e.prop]?xe.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[xe.cssProps[e.prop]]&&!xe.cssHooks[e.prop]?e.elem[e.prop]=e.now:xe.style(e.elem,e.prop,e.now+e.unit)}}},$.propHooks.scrollTop=$.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},xe.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},xe.fx=$.prototype.init,xe.fx.step={};var mt,vt,bt=/^(?:toggle|show|hide)$/,wt=/queueHooks$/;xe.Animation=xe.extend(Y,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return v(n.elem,e,ze.exec(t),n),n}]},tweener:function(e,t){ve(e)?(t=e,e=["*"]):e=e.match(Ie);for(var n,r=0,i=e.length;r<i;r++)n=e[r],Y.tweeners[n]=Y.tweeners[n]||[],Y.tweeners[n].unshift(t)},prefilters:[G],prefilter:function(e,t){t?Y.prefilters.unshift(e):Y.prefilters.push(e)}}),xe.speed=function(e,t,n){var r=e&&"object"===(void 0===e?"undefined":_typeof(e))?xe.extend({},e):{complete:n||!n&&t||ve(e)&&e,duration:e,easing:n&&t||t&&!ve(t)&&t};return xe.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in xe.fx.speeds?r.duration=xe.fx.speeds[r.duration]:r.duration=xe.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){ve(r.old)&&r.old.call(this),r.queue&&xe.dequeue(this,r.queue)},r},xe.fn.extend({fadeTo:function(e,t,n,r){return this.filter(Ue).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=xe.isEmptyObject(e),o=xe.speed(t,n,r),a=function(){var t=Y(this,xe.extend({},e),o);(i||Fe.get(this,"finish"))&&t.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&!1!==e&&this.queue(e||"fx",[]),this.each(function(){var t=!0,i=null!=e&&e+"queueHooks",o=xe.timers,a=Fe.get(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&wt.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));!t&&n||xe.dequeue(this,e)})},finish:function(e){return!1!==e&&(e=e||"fx"),this.each(function(){var t,n=Fe.get(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=xe.timers,a=r?r.length:0;for(n.finish=!0,xe.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;t<a;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),xe.each(["toggle","show","hide"],function(e,t){var n=xe.fn[t];xe.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(W(t,!0),e,r,i)}}),xe.each({slideDown:W("show"),slideUp:W("hide"),slideToggle:W("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){xe.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),xe.timers=[],xe.fx.tick=function(){var e,t=0,n=xe.timers;for(mt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||xe.fx.stop(),mt=void 0},xe.fx.timer=function(e){xe.timers.push(e),xe.fx.start()},xe.fx.interval=13,xe.fx.start=function(){vt||(vt=!0,B())},xe.fx.stop=function(){vt=null},xe.fx.speeds={slow:600,fast:200,_default:400},xe.fn.delay=function(t,n){return t=xe.fx?xe.fx.speeds[t]||t:t,n=n||"fx",this.queue(n,function(n,r){var i=e.setTimeout(n,t);r.stop=function(){e.clearTimeout(i)}})},function(){var e=ae.createElement("input"),t=ae.createElement("select"),n=t.appendChild(ae.createElement("option"));e.type="checkbox",me.checkOn=""!==e.value,me.optSelected=n.selected,e=ae.createElement("input"),e.value="t",e.type="radio",me.radioValue="t"===e.value}();var xt,Tt=xe.expr.attrHandle;xe.fn.extend({attr:function(e,t){return De(this,xe.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){xe.removeAttr(this,e)})}}),xe.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?xe.prop(e,t,n):(1===o&&xe.isXMLDoc(e)||(i=xe.attrHooks[t.toLowerCase()]||(xe.expr.match.bool.test(t)?xt:void 0)),void 0!==n?null===n?void xe.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:(r=xe.find.attr(e,t),null==r?void 0:r))},attrHooks:{type:{set:function(e,t){if(!me.radioValue&&"radio"===t&&o(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(Ie);if(i&&1===e.nodeType)for(;n=i[r++];)e.removeAttribute(n)}}),xt={set:function(e,t,n){return!1===t?xe.removeAttr(e,n):e.setAttribute(n,n),n}},xe.each(xe.expr.match.bool.source.match(/\w+/g),function(e,t){var n=Tt[t]||xe.find.attr;Tt[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=Tt[a],Tt[a]=i,i=null!=n(e,t,r)?a:null,Tt[a]=o),i}});var St=/^(?:input|select|textarea|button)$/i,Ot=/^(?:a|area)$/i;xe.fn.extend({prop:function(e,t){return De(this,xe.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each(function(){delete this[xe.propFix[e]||e]})}}),xe.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&xe.isXMLDoc(e)||(t=xe.propFix[t]||t,i=xe.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=xe.find.attr(e,"tabindex");return t?parseInt(t,10):St.test(e.nodeName)||Ot.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),me.optSelected||(xe.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),xe.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){xe.propFix[this.toLowerCase()]=this}),xe.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,c=0;if(ve(e))return this.each(function(t){xe(this).addClass(e.call(this,t,Z(this)))});if(t=Q(e),t.length)for(;n=this[c++];)if(i=Z(n),r=1===n.nodeType&&" "+J(i)+" "){for(a=0;o=t[a++];)r.indexOf(" "+o+" ")<0&&(r+=o+" ");s=J(r),i!==s&&n.setAttribute("class",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,c=0;if(ve(e))return this.each(function(t){xe(this).removeClass(e.call(this,t,Z(this)))});if(!arguments.length)return this.attr("class","");if(t=Q(e),t.length)for(;n=this[c++];)if(i=Z(n),r=1===n.nodeType&&" "+J(i)+" "){for(a=0;o=t[a++];)for(;r.indexOf(" "+o+" ")>-1;)r=r.replace(" "+o+" "," ");s=J(r),i!==s&&n.setAttribute("class",s)}return this},toggleClass:function(e,t){var n=void 0===e?"undefined":_typeof(e),r="string"===n||Array.isArray(e);return"boolean"==typeof t&&r?t?this.addClass(e):this.removeClass(e):ve(e)?this.each(function(n){xe(this).toggleClass(e.call(this,n,Z(this),t),t)}):this.each(function(){var t,i,o,a;if(r)for(i=0,o=xe(this),a=Q(e);t=a[i++];)o.hasClass(t)?o.removeClass(t):o.addClass(t);else void 0!==e&&"boolean"!==n||(t=Z(this),t&&Fe.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===e?"":Fe.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;for(t=" "+e+" ";n=this[r++];)if(1===n.nodeType&&(" "+J(Z(n))+" ").indexOf(t)>-1)return!0;return!1}});var jt=/\r/g;xe.fn.extend({val:function(e){var t,n,r,i=this[0];{if(arguments.length)return r=ve(e),this.each(function(n){var i;1===this.nodeType&&(i=r?e.call(this,n,xe(this).val()):e,null==i?i="":"number"==typeof i?i+="":Array.isArray(i)&&(i=xe.map(i,function(e){return null==e?"":e+""})),(t=xe.valHooks[this.type]||xe.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))});if(i)return(t=xe.valHooks[i.type]||xe.valHooks[i.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:(n=i.value,"string"==typeof n?n.replace(jt,""):null==n?"":n)}}}),xe.extend({valHooks:{option:{get:function(e){var t=xe.find.attr(e,"value");return null!=t?t:J(xe.text(e))}},select:{get:function(e){var t,n,r,i=e.options,a=e.selectedIndex,s="select-one"===e.type,c=s?null:[],u=s?a+1:i.length;for(r=a<0?u:s?a:0;r<u;r++)if(n=i[r],(n.selected||r===a)&&!n.disabled&&(!n.parentNode.disabled||!o(n.parentNode,"optgroup"))){if(t=xe(n).val(),s)return t;c.push(t)}return c},set:function(e,t){for(var n,r,i=e.options,o=xe.makeArray(t),a=i.length;a--;)r=i[a],(r.selected=xe.inArray(xe.valHooks.option.get(r),o)>-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),xe.each(["radio","checkbox"],function(){xe.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=xe.inArray(xe(e).val(),t)>-1}},me.checkOn||(xe.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),me.focusin="onfocusin"in e;var kt=/^(?:focusinfocus|focusoutblur)$/,At=function(e){e.stopPropagation()};xe.extend(xe.event,{trigger:function(t,n,r,i){var o,a,s,c,u,l,f,p,d=[r||ae],h=he.call(t,"type")?t.type:t,y=he.call(t,"namespace")?t.namespace.split("."):[];if(a=p=s=r=r||ae,3!==r.nodeType&&8!==r.nodeType&&!kt.test(h+xe.event.triggered)&&(h.indexOf(".")>-1&&(y=h.split("."),h=y.shift(),y.sort()),u=h.indexOf(":")<0&&"on"+h,t=t[xe.expando]?t:new xe.Event(h,"object"===(void 0===t?"undefined":_typeof(t))&&t),t.isTrigger=i?2:3,t.namespace=y.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+y.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:xe.makeArray(n,[t]),f=xe.event.special[h]||{},i||!f.trigger||!1!==f.trigger.apply(r,n))){if(!i&&!f.noBubble&&!be(r)){for(c=f.delegateType||h,kt.test(c+h)||(a=a.parentNode);a;a=a.parentNode)d.push(a),s=a;s===(r.ownerDocument||ae)&&d.push(s.defaultView||s.parentWindow||e)}for(o=0;(a=d[o++])&&!t.isPropagationStopped();)p=a,t.type=o>1?c:f.bindType||h,l=(Fe.get(a,"events")||{})[t.type]&&Fe.get(a,"handle"),l&&l.apply(a,n),(l=u&&a[u])&&l.apply&&Re(a)&&(t.result=l.apply(a,n),!1===t.result&&t.preventDefault());return t.type=h,i||t.isDefaultPrevented()||f._default&&!1!==f._default.apply(d.pop(),n)||!Re(r)||u&&ve(r[h])&&!be(r)&&(s=r[u],s&&(r[u]=null),xe.event.triggered=h,t.isPropagationStopped()&&p.addEventListener(h,At),r[h](),t.isPropagationStopped()&&p.removeEventListener(h,At),xe.event.triggered=void 0,s&&(r[u]=s)),t.result}},simulate:function(e,t,n){var r=xe.extend(new xe.Event,n,{type:e,isSimulated:!0});xe.event.trigger(r,null,t)}}),xe.fn.extend({trigger:function(e,t){return this.each(function(){xe.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return xe.event.trigger(e,t,n,!0)}}),me.focusin||xe.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){xe.event.simulate(t,e.target,xe.event.fix(e))};xe.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=Fe.access(r,t);i||r.addEventListener(e,n,!0),Fe.access(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=Fe.access(r,t)-1;i?Fe.access(r,t,i):(r.removeEventListener(e,n,!0),Fe.remove(r,t))}}});var Ct=e.location,Et=Date.now(),Nt=/\?/;xe.parseXML=function(t){var n;if(!t||"string"!=typeof t)return null;try{n=(new e.DOMParser).parseFromString(t,"text/xml")}catch(e){n=void 0}return n&&!n.getElementsByTagName("parsererror").length||xe.error("Invalid XML: "+t),n};var _t=/\[\]$/,It=/\r?\n/g,Pt=/^(?:submit|button|image|reset|file)$/i,Mt=/^(?:input|select|textarea|keygen)/i;xe.param=function(e,t){var n,r=[],i=function(e,t){var n=ve(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(Array.isArray(e)||e.jquery&&!xe.isPlainObject(e))xe.each(e,function(){i(this.name,this.value)});else for(n in e)K(n,e[n],t,i);return r.join("&")},xe.fn.extend({serialize:function(){return xe.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=xe.prop(this,"elements");return e?xe.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!xe(this).is(":disabled")&&Mt.test(this.nodeName)&&!Pt.test(e)&&(this.checked||!Ye.test(e))}).map(function(e,t){var n=xe(this).val();return null==n?null:Array.isArray(n)?xe.map(n,function(e){return{name:t.name,value:e.replace(It,"\r\n")}}):{name:t.name,value:n.replace(It,"\r\n")}}).get()}});var Dt=/%20/g,Lt=/#.*$/,qt=/([?&])_=[^&]*/,Rt=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ft=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Ht=/^(?:GET|HEAD)$/,Vt=/^\/\//,$t={},Bt={},zt="*/".concat("*"),Wt=ae.createElement("a");Wt.href=Ct.href,xe.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ct.href,type:"GET",isLocal:Ft.test(Ct.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":zt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":xe.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?ne(ne(e,xe.ajaxSettings),t):ne(xe.ajaxSettings,e)},ajaxPrefilter:ee($t),ajaxTransport:ee(Bt),ajax:function(t,n){function r(t,n,r,s){var u,p,d,w,x,T=n;l||(l=!0,c&&e.clearTimeout(c),i=void 0,a=s||"",S.readyState=t>0?4:0,u=t>=200&&t<300||304===t,r&&(w=re(h,S,r)),w=ie(h,w,S,u),u?(h.ifModified&&(x=S.getResponseHeader("Last-Modified"),x&&(xe.lastModified[o]=x),(x=S.getResponseHeader("etag"))&&(xe.etag[o]=x)),204===t||"HEAD"===h.type?T="nocontent":304===t?T="notmodified":(T=w.state,p=w.data,d=w.error,u=!d)):(d=T,!t&&T||(T="error",t<0&&(t=0))),S.status=t,S.statusText=(n||T)+"",u?m.resolveWith(y,[p,T,S]):m.rejectWith(y,[S,T,d]),S.statusCode(b),b=void 0,f&&g.trigger(u?"ajaxSuccess":"ajaxError",[S,h,u?p:d]),v.fireWith(y,[S,T]),f&&(g.trigger("ajaxComplete",[S,h]),--xe.active||xe.event.trigger("ajaxStop")))}"object"===(void 0===t?"undefined":_typeof(t))&&(n=t,t=void 0),n=n||{};var i,o,a,s,c,u,l,f,p,d,h=xe.ajaxSetup({},n),y=h.context||h,g=h.context&&(y.nodeType||y.jquery)?xe(y):xe.event,m=xe.Deferred(),v=xe.Callbacks("once memory"),b=h.statusCode||{},w={},x={},T="canceled",S={readyState:0,getResponseHeader:function(e){var t;if(l){if(!s)for(s={};t=Rt.exec(a);)s[t[1].toLowerCase()]=t[2];t=s[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return l?a:null},setRequestHeader:function(e,t){return null==l&&(e=x[e.toLowerCase()]=x[e.toLowerCase()]||e,w[e]=t),this},overrideMimeType:function(e){return null==l&&(h.mimeType=e),this},statusCode:function(e){var t;if(e)if(l)S.always(e[S.status]);else for(t in e)b[t]=[b[t],e[t]];return this},abort:function(e){var t=e||T;return i&&i.abort(t),r(0,t),this}};if(m.promise(S),h.url=((t||h.url||Ct.href)+"").replace(Vt,Ct.protocol+"//"),h.type=n.method||n.type||h.method||h.type,h.dataTypes=(h.dataType||"*").toLowerCase().match(Ie)||[""],null==h.crossDomain){u=ae.createElement("a");try{u.href=h.url,u.href=u.href,h.crossDomain=Wt.protocol+"//"+Wt.host!=u.protocol+"//"+u.host}catch(e){h.crossDomain=!0}}if(h.data&&h.processData&&"string"!=typeof h.data&&(h.data=xe.param(h.data,h.traditional)),te($t,h,n,S),l)return S;f=xe.event&&h.global,f&&0==xe.active++&&xe.event.trigger("ajaxStart"),h.type=h.type.toUpperCase(),h.hasContent=!Ht.test(h.type),o=h.url.replace(Lt,""),h.hasContent?h.data&&h.processData&&0===(h.contentType||"").indexOf("application/x-www-form-urlencoded")&&(h.data=h.data.replace(Dt,"+")):(d=h.url.slice(o.length),h.data&&(h.processData||"string"==typeof h.data)&&(o+=(Nt.test(o)?"&":"?")+h.data,delete h.data),!1===h.cache&&(o=o.replace(qt,"$1"),d=(Nt.test(o)?"&":"?")+"_="+Et+++d),h.url=o+d),h.ifModified&&(xe.lastModified[o]&&S.setRequestHeader("If-Modified-Since",xe.lastModified[o]),xe.etag[o]&&S.setRequestHeader("If-None-Match",xe.etag[o])),(h.data&&h.hasContent&&!1!==h.contentType||n.contentType)&&S.setRequestHeader("Content-Type",h.contentType),S.setRequestHeader("Accept",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+("*"!==h.dataTypes[0]?", "+zt+"; q=0.01":""):h.accepts["*"]);for(p in h.headers)S.setRequestHeader(p,h.headers[p]);if(h.beforeSend&&(!1===h.beforeSend.call(y,S,h)||l))return S.abort();if(T="abort",v.add(h.complete),S.done(h.success),S.fail(h.error),i=te(Bt,h,n,S)){if(S.readyState=1,f&&g.trigger("ajaxSend",[S,h]),l)return S;h.async&&h.timeout>0&&(c=e.setTimeout(function(){S.abort("timeout")},h.timeout));try{l=!1,i.send(w,r)}catch(e){if(l)throw e;r(-1,e)}}else r(-1,"No Transport");return S},getJSON:function(e,t,n){return xe.get(e,t,n,"json")},getScript:function(e,t){return xe.get(e,void 0,t,"script")}}),xe.each(["get","post"],function(e,t){xe[t]=function(e,n,r,i){return ve(n)&&(i=i||r,r=n,n=void 0),xe.ajax(xe.extend({url:e,type:t,dataType:i,data:n,success:r},xe.isPlainObject(e)&&e))}}),xe._evalUrl=function(e){return xe.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},xe.fn.extend({wrapAll:function(e){var t;return this[0]&&(ve(e)&&(e=e.call(this[0])),t=xe(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(e){return ve(e)?this.each(function(t){xe(this).wrapInner(e.call(this,t))}):this.each(function(){var t=xe(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=ve(e);return this.each(function(n){xe(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(e){return this.parent(e).not("body").each(function(){xe(this).replaceWith(this.childNodes)}),this}}),xe.expr.pseudos.hidden=function(e){return!xe.expr.pseudos.visible(e)},xe.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},xe.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var Ut={0:200,1223:204},Gt=xe.ajaxSettings.xhr();me.cors=!!Gt&&"withCredentials"in Gt,me.ajax=Gt=!!Gt,xe.ajaxTransport(function(t){var n,r;if(me.cors||Gt&&!t.crossDomain)return{send:function(i,o){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");for(a in i)s.setRequestHeader(a,i[a]);n=function(e){return function(){n&&(n=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!=typeof s.status?o(0,"error"):o(s.status,s.statusText):o(Ut[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=n(),r=s.onerror=s.ontimeout=n("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&e.setTimeout(function(){n&&r()})},n=n("abort");try{s.send(t.hasContent&&t.data||null)}catch(e){if(n)throw e}},abort:function(){n&&n()}}}),xe.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),xe.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return xe.globalEval(e),e}}}),xe.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),xe.ajaxTransport("script",function(e){if(e.crossDomain){var t,n;return{send:function(r,i){t=xe("<script>").prop({charset:e.scriptCharset,src:e.url}).on("load error",n=function(e){t.remove(),n=null,e&&i("error"===e.type?404:200,e.type)}),ae.head.appendChild(t[0])},abort:function(){n&&n()}}}});var Xt=[],Yt=/(=)\?(?=&|$)|\?\?/;xe.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||xe.expando+"_"+Et++;return this[e]=!0,e}}),xe.ajaxPrefilter("json jsonp",function(t,n,r){var i,o,a,s=!1!==t.jsonp&&(Yt.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Yt.test(t.data)&&"data");if(s||"jsonp"===t.dataTypes[0])return i=t.jsonpCallback=ve(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Yt,"$1"+i):!1!==t.jsonp&&(t.url+=(Nt.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||xe.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always(function(){void 0===o?xe(e).removeProp(i):e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,Xt.push(i)),a&&ve(o)&&o(a[0]),a=o=void 0}),"script"}),me.createHTMLDocument=function(){var e=ae.implementation.createHTMLDocument("").body;return e.innerHTML="<form></form><form></form>",2===e.childNodes.length}(),xe.parseHTML=function(e,t,n){if("string"!=typeof e)return[];"boolean"==typeof t&&(n=t,t=!1);var r,i,o;return t||(me.createHTMLDocument?(t=ae.implementation.createHTMLDocument(""),r=t.createElement("base"),r.href=ae.location.href,t.head.appendChild(r)):t=ae),i=Ae.exec(e),o=!n&&[],i?[t.createElement(i[1])]:(i=S([e],t,o),o&&o.length&&xe(o).remove(),xe.merge([],i.childNodes))},xe.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return s>-1&&(r=J(e.slice(s)),e=e.slice(0,s)),ve(t)?(n=t,t=void 0):t&&"object"===(void 0===t?"undefined":_typeof(t))&&(i="POST"),a.length>0&&xe.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?xe("<div>").append(xe.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},xe.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){xe.fn[t]=function(e){return this.on(t,e)}}),xe.expr.pseudos.animated=function(e){return xe.grep(xe.timers,function(t){return e===t.elem}).length},xe.offset={setOffset:function(e,t,n){var r,i,o,a,s,c,u,l=xe.css(e,"position"),f=xe(e),p={};"static"===l&&(e.style.position="relative"),s=f.offset(),o=xe.css(e,"top"),c=xe.css(e,"left"),u=("absolute"===l||"fixed"===l)&&(o+c).indexOf("auto")>-1,u?(r=f.position(),a=r.top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(c)||0),ve(t)&&(t=t.call(e,n,xe.extend({},s))),null!=t.top&&(p.top=t.top-s.top+a),null!=t.left&&(p.left=t.left-s.left+i),"using"in t?t.using.call(e,p):f.css(p)}},xe.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){xe.offset.setOffset(this,e,t)});var t,n,r=this[0];if(r)return r.getClientRects().length?(t=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:t.top+n.pageYOffset,left:t.left+n.pageXOffset}):{top:0,left:0}},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===xe.css(r,"position"))t=r.getBoundingClientRect();else{for(t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;e&&(e===n.body||e===n.documentElement)&&"static"===xe.css(e,"position");)e=e.parentNode;e&&e!==r&&1===e.nodeType&&(i=xe(e).offset(),i.top+=xe.css(e,"borderTopWidth",!0),i.left+=xe.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-xe.css(r,"marginTop",!0),left:t.left-i.left-xe.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent;e&&"static"===xe.css(e,"position");)e=e.offsetParent;return e||et})}}),xe.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n="pageYOffset"===t;xe.fn[e]=function(r){return De(this,function(e,r,i){var o;if(be(e)?o=e:9===e.nodeType&&(o=e.defaultView),void 0===i)return o?o[t]:e[r];o?o.scrollTo(n?o.pageXOffset:i,n?i:o.pageYOffset):e[r]=i},e,r,arguments.length)}}),xe.each(["top","left"],function(e,t){xe.cssHooks[t]=L(me.pixelPosition,function(e,n){if(n)return n=D(e,t),ct.test(n)?xe(e).position()[t]+"px":n})}),xe.each({Height:"height",Width:"width"},function(e,t){xe.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){xe.fn[r]=function(i,o){var a=arguments.length&&(n||"boolean"!=typeof i),s=n||(!0===i||!0===o?"margin":"border");return De(this,function(t,n,i){var o;return be(t)?0===r.indexOf("outer")?t["inner"+e]:t.document.documentElement["client"+e]:9===t.nodeType?(o=t.documentElement,Math.max(t.body["scroll"+e],o["scroll"+e],t.body["offset"+e],o["offset"+e],o["client"+e])):void 0===i?xe.css(t,n,s):xe.style(t,n,i,s)},t,a?i:void 0,a)}})}),xe.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,t){xe.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),xe.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),xe.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),xe.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),ve(e))return r=ce.call(arguments,2),i=function(){return e.apply(t||this,r.concat(ce.call(arguments)))},i.guid=e.guid=e.guid||xe.guid++,i},xe.holdReady=function(e){e?xe.readyWait++:xe.ready(!0)},xe.isArray=Array.isArray,xe.parseJSON=JSON.parse,xe.nodeName=o,xe.isFunction=ve,xe.isWindow=be,xe.camelCase=h,xe.type=r,xe.now=Date.now,xe.isNumeric=function(e){var t=xe.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},"function"==typeof define&&define.amd&&define("jquery",[],function(){return xe});var Jt=e.jQuery,Zt=e.$;return xe.noConflict=function(t){return e.$===xe&&(e.$=Zt),t&&e.jQuery===xe&&(e.jQuery=Jt),xe},t||(e.jQuery=e.$=xe),xe}),/*!
   * https://github.com/paulmillr/es6-shim
   * @license es6-shim Copyright 2013-2016 by Paul Miller (http://paulmillr.com)
   *   and contributors,  MIT License
@@ -149,14 +167,13 @@
   * Details and documentation:
   * https://github.com/paulmillr/es6-shim/
   */
-function(e,t){"function"==typeof define&&define.amd?define("es6-shim",t):"object"===("undefined"==typeof exports?"undefined":_typeof(exports))?module.exports=t():e.returnExports=t()}(this,function(){var e,t=Function.call.bind(Function.apply),n=Function.call.bind(Function.call),r=Array.isArray,i=Object.keys,o=function(e){return function(){return!t(e,this,arguments)}},a=function(e){try{return e(),!1}catch(e){return!0}},s=function(e){try{return e()}catch(e){return!1}},u=o(a),c=function(){return!a(function(){Object.defineProperty({},"x",{get:function(){}})})},l=!!Object.defineProperty&&c(),f="foo"===function(){}.name,p=Function.call.bind(Array.prototype.forEach),d=Function.call.bind(Array.prototype.reduce),h=Function.call.bind(Array.prototype.filter),m=Function.call.bind(Array.prototype.some),g=function(e,t,n,r){!r&&t in e||(l?Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:!0,value:n}):e[t]=n)},y=function(e,t,n){p(i(t),function(r){var i=t[r];g(e,r,i,!!n)})},v=Function.call.bind(Object.prototype.toString),b="function"==typeof/abc/?function(e){return"function"==typeof e&&"[object Function]"===v(e)}:function(e){return"function"==typeof e},w={getter:function(e,t,n){if(!l)throw new TypeError("getters require true ES5 support");Object.defineProperty(e,t,{configurable:!0,enumerable:!1,get:n})},proxy:function(e,t,n){if(!l)throw new TypeError("getters require true ES5 support");var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,{configurable:r.configurable,enumerable:r.enumerable,get:function(){return e[t]},set:function(n){e[t]=n}})},redefine:function(e,t,n){if(l){var r=Object.getOwnPropertyDescriptor(e,t);r.value=n,Object.defineProperty(e,t,r)}else e[t]=n},defineByDescriptor:function(e,t,n){l?Object.defineProperty(e,t,n):"value"in n&&(e[t]=n.value)},preserveToString:function(e,t){t&&b(t.toString)&&g(e,"toString",t.toString.bind(t),!0)}},x=Object.create||function(e,t){var n=function(){};n.prototype=e;var r=new n;return"undefined"!=typeof t&&i(t).forEach(function(e){w.defineByDescriptor(r,e,t[e])}),r},T=function(e,t){return Object.setPrototypeOf?s(function(){var n=function t(n){var r=new e(n);return Object.setPrototypeOf(r,t.prototype),r};return Object.setPrototypeOf(n,e),n.prototype=x(e.prototype,{constructor:{value:n}}),t(n)}):!1},S=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if("undefined"!=typeof global)return global;throw new Error("unable to locate global object")},O=S(),j=O.isFinite,k=Function.call.bind(String.prototype.indexOf),C=Function.apply.bind(Array.prototype.indexOf),A=Function.call.bind(Array.prototype.concat),E=Function.call.bind(String.prototype.slice),N=Function.call.bind(Array.prototype.push),_=Function.apply.bind(Array.prototype.push),P=Function.call.bind(Array.prototype.shift),I=Math.max,M=Math.min,L=Math.floor,F=Math.abs,D=Math.exp,q=Math.log,R=Math.sqrt,H=Function.call.bind(Object.prototype.hasOwnProperty),$=function(){},B=O.Symbol||{},V=B.species||"@@species",W=Number.isNaN||function(e){return e!==e},z=Number.isFinite||function(e){return"number"==typeof e&&j(e)},U=b(Math.sign)?Math.sign:function(e){var t=Number(e);return 0===t?t:W(t)?t:0>t?-1:1},G=function(e){return"[object Arguments]"===v(e)},X=function(e){return null!==e&&"object"===("undefined"==typeof e?"undefined":_typeof(e))&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==v(e)&&"[object Function]"===v(e.callee)},J=G(arguments)?G:X,Y={primitive:function(e){return null===e||"function"!=typeof e&&"object"!==("undefined"==typeof e?"undefined":_typeof(e))},string:function(e){return"[object String]"===v(e)},regex:function(e){return"[object RegExp]"===v(e)},symbol:function(e){return"function"==typeof O.Symbol&&"symbol"===("undefined"==typeof e?"undefined":_typeof(e))}},Z=function(e,t,n){var r=e[t];g(e,t,n,!0),w.preserveToString(e[t],r)},Q="function"==typeof B&&"function"==typeof B.for&&Y.symbol(B()),K=Y.symbol(B.iterator)?B.iterator:"_es6-shim iterator_";O.Set&&"function"==typeof(new O.Set)["@@iterator"]&&(K="@@iterator"),O.Reflect||g(O,"Reflect",{},!0);var ee=O.Reflect,te=String,ne={Call:function(e,n){var r=arguments.length>2?arguments[2]:[];if(!ne.IsCallable(e))throw new TypeError(e+" is not a function");return t(e,n,r)},RequireObjectCoercible:function(e,t){if(null==e)throw new TypeError(t||"Cannot call method on "+e);return e},TypeIsObject:function(e){return void 0===e||null===e||e===!0||e===!1?!1:"function"==typeof e||"object"===("undefined"==typeof e?"undefined":_typeof(e))},ToObject:function(e,t){return Object(ne.RequireObjectCoercible(e,t))},IsCallable:b,IsConstructor:function(e){return ne.IsCallable(e)},ToInt32:function(e){return ne.ToNumber(e)>>0},ToUint32:function(e){return ne.ToNumber(e)>>>0},ToNumber:function(e){if("[object Symbol]"===v(e))throw new TypeError("Cannot convert a Symbol value to a number");return+e},ToInteger:function(e){var t=ne.ToNumber(e);return W(t)?0:0!==t&&z(t)?(t>0?1:-1)*L(F(t)):t},ToLength:function(e){var t=ne.ToInteger(e);return 0>=t?0:t>Number.MAX_SAFE_INTEGER?Number.MAX_SAFE_INTEGER:t},SameValue:function(e,t){return e===t?0===e?1/e===1/t:!0:W(e)&&W(t)},SameValueZero:function(e,t){return e===t||W(e)&&W(t)},IsIterable:function(e){return ne.TypeIsObject(e)&&("undefined"!=typeof e[K]||J(e))},GetIterator:function(t){if(J(t))return new e(t,"value");var n=ne.GetMethod(t,K);if(!ne.IsCallable(n))throw new TypeError("value is not an iterable");var r=ne.Call(n,t);if(!ne.TypeIsObject(r))throw new TypeError("bad iterator");return r},GetMethod:function(e,t){var n=ne.ToObject(e)[t];if(void 0===n||null===n)return void 0;if(!ne.IsCallable(n))throw new TypeError("Method not callable: "+t);return n},IteratorComplete:function(e){return!!e.done},IteratorClose:function(e,t){var n=ne.GetMethod(e,"return");if(void 0!==n){var r,i;try{r=ne.Call(n,e)}catch(e){i=e}if(!t){if(i)throw i;if(!ne.TypeIsObject(r))throw new TypeError("Iterator's return method returned a non-object.")}}},IteratorNext:function(e){var t=arguments.length>1?e.next(arguments[1]):e.next();if(!ne.TypeIsObject(t))throw new TypeError("bad iterator");return t},IteratorStep:function(e){var t=ne.IteratorNext(e),n=ne.IteratorComplete(t);return n?!1:t},Construct:function(e,t,n,r){var i="undefined"==typeof n?e:n;if(!r&&ee.construct)return ee.construct(e,t,i);var o=i.prototype;ne.TypeIsObject(o)||(o=Object.prototype);var a=x(o),s=ne.Call(e,a,t);return ne.TypeIsObject(s)?s:a},SpeciesConstructor:function(e,t){var n=e.constructor;if(void 0===n)return t;if(!ne.TypeIsObject(n))throw new TypeError("Bad constructor");var r=n[V];if(void 0===r||null===r)return t;if(!ne.IsConstructor(r))throw new TypeError("Bad @@species");return r},CreateHTML:function(e,t,n,r){var i=ne.ToString(e),o="<"+t;if(""!==n){var a=ne.ToString(r),s=a.replace(/"/g,"&quot;");o+=" "+n+'="'+s+'"'}var u=o+">",c=u+i;return c+"</"+t+">"},IsRegExp:function(e){if(!ne.TypeIsObject(e))return!1;var t=e[B.match];return"undefined"!=typeof t?!!t:Y.regex(e)},ToString:function(e){return te(e)}};if(l&&Q){var re=function(e){if(Y.symbol(B[e]))return B[e];var t=B.for("Symbol."+e);return Object.defineProperty(B,e,{configurable:!1,enumerable:!1,writable:!1,value:t}),t};if(!Y.symbol(B.search)){var ie=re("search"),oe=String.prototype.search;g(RegExp.prototype,ie,function(e){return ne.Call(oe,e,[this])});var ae=function(e){var t=ne.RequireObjectCoercible(this);if(null!==e&&"undefined"!=typeof e){var n=ne.GetMethod(e,ie);if("undefined"!=typeof n)return ne.Call(n,e,[t])}return ne.Call(oe,t,[ne.ToString(e)])};Z(String.prototype,"search",ae)}if(!Y.symbol(B.replace)){var se=re("replace"),ue=String.prototype.replace;g(RegExp.prototype,se,function(e,t){return ne.Call(ue,e,[this,t])});var ce=function(e,t){var n=ne.RequireObjectCoercible(this);if(null!==e&&"undefined"!=typeof e){var r=ne.GetMethod(e,se);if("undefined"!=typeof r)return ne.Call(r,e,[n,t])}return ne.Call(ue,n,[ne.ToString(e),t])};Z(String.prototype,"replace",ce)}if(!Y.symbol(B.split)){var le=re("split"),fe=String.prototype.split;g(RegExp.prototype,le,function(e,t){return ne.Call(fe,e,[this,t])});var pe=function(e,t){var n=ne.RequireObjectCoercible(this);if(null!==e&&"undefined"!=typeof e){var r=ne.GetMethod(e,le);if("undefined"!=typeof r)return ne.Call(r,e,[n,t])}return ne.Call(fe,n,[ne.ToString(e),t])};Z(String.prototype,"split",pe)}var de=Y.symbol(B.match),he=de&&function(){var e={};return e[B.match]=function(){return 42},42!=="a".match(e)}();if(!de||he){var me=re("match"),ge=String.prototype.match;g(RegExp.prototype,me,function(e){return ne.Call(ge,e,[this])});var ye=function(e){var t=ne.RequireObjectCoercible(this);if(null!==e&&"undefined"!=typeof e){var n=ne.GetMethod(e,me);if("undefined"!=typeof n)return ne.Call(n,e,[t])}return ne.Call(ge,t,[ne.ToString(e)])};Z(String.prototype,"match",ye)}}var ve=function(e,t,n){w.preserveToString(t,e),Object.setPrototypeOf&&Object.setPrototypeOf(e,t),l?p(Object.getOwnPropertyNames(e),function(r){r in $||n[r]||w.proxy(e,r,t)}):p(Object.keys(e),function(r){r in $||n[r]||(t[r]=e[r])}),t.prototype=e.prototype,w.redefine(e.prototype,"constructor",t)},be=function(){return this},we=function(e){l&&!H(e,V)&&w.getter(e,V,be)},xe=function(e,t){var n=t||function(){return this};g(e,K,n),!e[K]&&Y.symbol(K)&&(e[K]=n)},Te=function(e,t,n){l?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n},Se=function(e,t,n){if(Te(e,t,n),!ne.SameValue(e[t],n))throw new TypeError("property is nonconfigurable")},Oe=function(e,t,n,r){if(!ne.TypeIsObject(e))throw new TypeError("Constructor requires `new`: "+t.name);var i=t.prototype;ne.TypeIsObject(i)||(i=n);var o=x(i);for(var a in r)if(H(r,a)){var s=r[a];g(o,a,s,!0)}return o};if(String.fromCodePoint&&1!==String.fromCodePoint.length){var je=String.fromCodePoint;Z(String,"fromCodePoint",function(){return ne.Call(je,this,arguments)})}var ke={fromCodePoint:function(){for(var e,t=[],n=0,r=arguments.length;r>n;n++){if(e=Number(arguments[n]),!ne.SameValue(e,ne.ToInteger(e))||0>e||e>1114111)throw new RangeError("Invalid code point "+e);65536>e?N(t,String.fromCharCode(e)):(e-=65536,N(t,String.fromCharCode((e>>10)+55296)),N(t,String.fromCharCode(e%1024+56320)))}return t.join("")},raw:function(e){var t=ne.ToObject(e,"bad callSite"),n=ne.ToObject(t.raw,"bad raw value"),r=n.length,i=ne.ToLength(r);if(0>=i)return"";for(var o,a,s,u,c=[],l=0;i>l&&(o=ne.ToString(l),s=ne.ToString(n[o]),N(c,s),!(l+1>=i));)a=l+1<arguments.length?arguments[l+1]:"",u=ne.ToString(a),N(c,u),l+=1;return c.join("")}};String.raw&&"xy"!==String.raw({raw:{0:"x",1:"y",length:2}})&&Z(String,"raw",ke.raw),y(String,ke);var Ce=function e(t,n){if(1>n)return"";if(n%2)return e(t,n-1)+t;var r=e(t,n/2);return r+r},Ae=1/0,Ee={repeat:function(e){var t=ne.ToString(ne.RequireObjectCoercible(this)),n=ne.ToInteger(e);if(0>n||n>=Ae)throw new RangeError("repeat count must be less than infinity and not overflow maximum string size");return Ce(t,n)},startsWith:function(e){var t=ne.ToString(ne.RequireObjectCoercible(this));if(ne.IsRegExp(e))throw new TypeError('Cannot call method "startsWith" with a regex');var n,r=ne.ToString(e);arguments.length>1&&(n=arguments[1]);var i=I(ne.ToInteger(n),0);return E(t,i,i+r.length)===r},endsWith:function(e){var t=ne.ToString(ne.RequireObjectCoercible(this));if(ne.IsRegExp(e))throw new TypeError('Cannot call method "endsWith" with a regex');var n,r=ne.ToString(e),i=t.length;arguments.length>1&&(n=arguments[1]);var o="undefined"==typeof n?i:ne.ToInteger(n),a=M(I(o,0),i);return E(t,a-r.length,a)===r},includes:function(e){if(ne.IsRegExp(e))throw new TypeError('"includes" does not accept a RegExp');var t,n=ne.ToString(e);return arguments.length>1&&(t=arguments[1]),-1!==k(this,n,t)},codePointAt:function(e){var t=ne.ToString(ne.RequireObjectCoercible(this)),n=ne.ToInteger(e),r=t.length;if(n>=0&&r>n){var i=t.charCodeAt(n),o=n+1===r;if(55296>i||i>56319||o)return i;var a=t.charCodeAt(n+1);return 56320>a||a>57343?i:1024*(i-55296)+(a-56320)+65536}}};if(String.prototype.includes&&"a".includes("a",1/0)!==!1&&Z(String.prototype,"includes",Ee.includes),String.prototype.startsWith&&String.prototype.endsWith){var Ne=a(function(){"/a/".startsWith(/a/)}),_e=s(function(){return"abc".startsWith("a",1/0)===!1});Ne&&_e||(Z(String.prototype,"startsWith",Ee.startsWith),Z(String.prototype,"endsWith",Ee.endsWith))}if(Q){var Pe=s(function(){var e=/a/;return e[B.match]=!1,"/a/".startsWith(e)});Pe||Z(String.prototype,"startsWith",Ee.startsWith);var Ie=s(function(){var e=/a/;return e[B.match]=!1,"/a/".endsWith(e)});Ie||Z(String.prototype,"endsWith",Ee.endsWith);var Me=s(function(){var e=/a/;return e[B.match]=!1,"/a/".includes(e)});Me||Z(String.prototype,"includes",Ee.includes)}y(String.prototype,Ee);var Le=["	\n\f\r \xa0\u1680\u180e\u2000\u2001\u2002\u2003","\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028","\u2029\ufeff"].join(""),Fe=new RegExp("(^["+Le+"]+)|(["+Le+"]+$)","g"),De=function(){return ne.ToString(ne.RequireObjectCoercible(this)).replace(Fe,"")},qe=["\x85","\u200b","\ufffe"].join(""),Re=new RegExp("["+qe+"]","g"),He=/^[\-+]0x[0-9a-f]+$/i,$e=qe.trim().length!==qe.length;g(String.prototype,"trim",De,$e);var Be=function(e){return{value:e,done:0===arguments.length}},Ve=function(e){ne.RequireObjectCoercible(e),this._s=ne.ToString(e),this._i=0};Ve.prototype.next=function(){var e=this._s,t=this._i;if("undefined"==typeof e||t>=e.length)return this._s=void 0,Be();var n,r,i=e.charCodeAt(t);return 55296>i||i>56319||t+1===e.length?r=1:(n=e.charCodeAt(t+1),r=56320>n||n>57343?1:2),this._i=t+r,Be(e.substr(t,r))},xe(Ve.prototype),xe(String.prototype,function(){return new Ve(this)});var We={from:function(e){var t,r=this;arguments.length>1&&(t=arguments[1]);var i,o;if("undefined"==typeof t)i=!1;else{if(!ne.IsCallable(t))throw new TypeError("Array.from: when provided, the second argument must be a function");arguments.length>2&&(o=arguments[2]),i=!0}var a,s,u,c="undefined"!=typeof(J(e)||ne.GetMethod(e,K));if(c){s=ne.IsConstructor(r)?Object(new r):[];var l,f,p=ne.GetIterator(e);for(u=0;;){if(l=ne.IteratorStep(p),l===!1)break;f=l.value;try{i&&(f="undefined"==typeof o?t(f,u):n(t,o,f,u)),s[u]=f}catch(e){throw ne.IteratorClose(p,!0),e}u+=1}a=u}else{var d=ne.ToObject(e);a=ne.ToLength(d.length),s=ne.IsConstructor(r)?Object(new r(a)):new Array(a);var h;for(u=0;a>u;++u)h=d[u],i&&(h="undefined"==typeof o?t(h,u):n(t,o,h,u)),Se(s,u,h)}return s.length=a,s},of:function(){for(var e=arguments.length,t=this,n=r(t)||!ne.IsCallable(t)?new Array(e):ne.Construct(t,[e]),i=0;e>i;++i)Se(n,i,arguments[i]);return n.length=e,n}};y(Array,We),we(Array),e=function(e,t){this.i=0,this.array=e,this.kind=t},y(e.prototype,{next:function(){var t=this.i,n=this.array;if(!(this instanceof e))throw new TypeError("Not an ArrayIterator");if("undefined"!=typeof n)for(var r=ne.ToLength(n.length);r>t;t++){var i,o=this.kind;return"key"===o?i=t:"value"===o?i=n[t]:"entry"===o&&(i=[t,n[t]]),this.i=t+1,Be(i)}return this.array=void 0,Be()}}),xe(e.prototype);var ze=Array.of===We.of||function(){var e=function(e){this.length=e};e.prototype=[];var t=Array.of.apply(e,[1,2]);return t instanceof e&&2===t.length}();ze||Z(Array,"of",We.of);var Ue={copyWithin:function(e,t){var n,r=ne.ToObject(this),i=ne.ToLength(r.length),o=ne.ToInteger(e),a=ne.ToInteger(t),s=0>o?I(i+o,0):M(o,i),u=0>a?I(i+a,0):M(a,i);arguments.length>2&&(n=arguments[2]);var c="undefined"==typeof n?i:ne.ToInteger(n),l=0>c?I(i+c,0):M(c,i),f=M(l-u,i-s),p=1;for(s>u&&u+f>s&&(p=-1,u+=f-1,s+=f-1);f>0;)u in r?r[s]=r[u]:delete r[s],u+=p,s+=p,f-=1;return r},fill:function(e){var t;arguments.length>1&&(t=arguments[1]);var n;arguments.length>2&&(n=arguments[2]);var r=ne.ToObject(this),i=ne.ToLength(r.length);t=ne.ToInteger("undefined"==typeof t?0:t),n=ne.ToInteger("undefined"==typeof n?i:n);for(var o=0>t?I(i+t,0):M(t,i),a=0>n?i+n:n,s=o;i>s&&a>s;++s)r[s]=e;return r},find:function(e){var t=ne.ToObject(this),r=ne.ToLength(t.length);if(!ne.IsCallable(e))throw new TypeError("Array#find: predicate must be a function");for(var i,o=arguments.length>1?arguments[1]:null,a=0;r>a;a++)if(i=t[a],o){if(n(e,o,i,a,t))return i}else if(e(i,a,t))return i},findIndex:function(e){var t=ne.ToObject(this),r=ne.ToLength(t.length);if(!ne.IsCallable(e))throw new TypeError("Array#findIndex: predicate must be a function");for(var i=arguments.length>1?arguments[1]:null,o=0;r>o;o++)if(i){if(n(e,i,t[o],o,t))return o}else if(e(t[o],o,t))return o;return-1},keys:function(){return new e(this,"key")},values:function(){return new e(this,"value")},entries:function(){return new e(this,"entry")}};if(Array.prototype.keys&&!ne.IsCallable([1].keys().next)&&delete Array.prototype.keys,Array.prototype.entries&&!ne.IsCallable([1].entries().next)&&delete Array.prototype.entries,Array.prototype.keys&&Array.prototype.entries&&!Array.prototype.values&&Array.prototype[K]&&(y(Array.prototype,{values:Array.prototype[K]}),Y.symbol(B.unscopables)&&(Array.prototype[B.unscopables].values=!0)),f&&Array.prototype.values&&"values"!==Array.prototype.values.name){var Ge=Array.prototype.values;Z(Array.prototype,"values",function(){return ne.Call(Ge,this,arguments)}),g(Array.prototype,K,Array.prototype.values,!0)}y(Array.prototype,Ue),1/[!0].indexOf(!0,-0)<0&&g(Array.prototype,"indexOf",function(){var e=C(this,arguments);return 0===e&&0>1/e?0:e},!0),xe(Array.prototype,function(){return this.values()}),Object.getPrototypeOf&&xe(Object.getPrototypeOf([].values()));var Xe=function(){return s(function(){return 0===Array.from({length:-1}).length})}(),Je=function(){var e=Array.from([0].entries());return 1===e.length&&r(e[0])&&0===e[0][0]&&0===e[0][1]}();Xe&&Je||Z(Array,"from",We.from);var Ye=function(){return s(function(){return Array.from([0],void 0)})}();if(!Ye){var Ze=Array.from;Z(Array,"from",function(e){return arguments.length>1&&"undefined"!=typeof arguments[1]?ne.Call(Ze,this,arguments):n(Ze,this,e)})}var Qe=-(Math.pow(2,32)-1),Ke=function(e,t){var r={length:Qe};return r[t?(r.length>>>0)-1:0]=!0,s(function(){return n(e,r,function(){throw new RangeError("should not reach here")},[]),!0})};if(!Ke(Array.prototype.forEach)){var et=Array.prototype.forEach;Z(Array.prototype,"forEach",function(){return ne.Call(et,this.length>=0?this:[],arguments)},!0)}if(!Ke(Array.prototype.map)){var tt=Array.prototype.map;Z(Array.prototype,"map",function(){return ne.Call(tt,this.length>=0?this:[],arguments)},!0)}if(!Ke(Array.prototype.filter)){var nt=Array.prototype.filter;Z(Array.prototype,"filter",function(){return ne.Call(nt,this.length>=0?this:[],arguments)},!0)}if(!Ke(Array.prototype.some)){var rt=Array.prototype.some;Z(Array.prototype,"some",function(){return ne.Call(rt,this.length>=0?this:[],arguments)},!0)}if(!Ke(Array.prototype.every)){var it=Array.prototype.every;Z(Array.prototype,"every",function(){return ne.Call(it,this.length>=0?this:[],arguments)},!0)}if(!Ke(Array.prototype.reduce)){var ot=Array.prototype.reduce;Z(Array.prototype,"reduce",function(){return ne.Call(ot,this.length>=0?this:[],arguments)},!0)}if(!Ke(Array.prototype.reduceRight,!0)){var at=Array.prototype.reduceRight;Z(Array.prototype,"reduceRight",function(){return ne.Call(at,this.length>=0?this:[],arguments)},!0)}var st=8!==Number("0o10"),ut=2!==Number("0b10"),ct=m(qe,function(e){return 0===Number(e+0+e)});if(st||ut||ct){var lt=Number,ft=/^0b[01]+$/i,pt=/^0o[0-7]+$/i,dt=ft.test.bind(ft),ht=pt.test.bind(pt),mt=function(e){var t;if("function"==typeof e.valueOf&&(t=e.valueOf(),Y.primitive(t)))return t;if("function"==typeof e.toString&&(t=e.toString(),Y.primitive(t)))return t;throw new TypeError("No default value")},gt=Re.test.bind(Re),yt=He.test.bind(He),vt=function(){var e=function(t){var n;n=arguments.length>0?Y.primitive(t)?t:mt(t,"number"):0,"string"==typeof n&&(n=ne.Call(De,n),dt(n)?n=parseInt(E(n,2),2):ht(n)?n=parseInt(E(n,2),8):(gt(n)||yt(n))&&(n=0/0));var r=this,i=s(function(){return lt.prototype.valueOf.call(r),!0});return r instanceof e&&!i?new lt(n):lt(n)};return e}();ve(lt,vt,{}),y(vt,{NaN:lt.NaN,MAX_VALUE:lt.MAX_VALUE,MIN_VALUE:lt.MIN_VALUE,NEGATIVE_INFINITY:lt.NEGATIVE_INFINITY,POSITIVE_INFINITY:lt.POSITIVE_INFINITY}),Number=vt,w.redefine(O,"Number",vt)}var bt=Math.pow(2,53)-1;y(Number,{MAX_SAFE_INTEGER:bt,MIN_SAFE_INTEGER:-bt,EPSILON:2.220446049250313e-16,parseInt:O.parseInt,parseFloat:O.parseFloat,isFinite:z,isInteger:function(e){return z(e)&&ne.ToInteger(e)===e},isSafeInteger:function(e){return Number.isInteger(e)&&F(e)<=Number.MAX_SAFE_INTEGER},isNaN:W}),g(Number,"parseInt",O.parseInt,Number.parseInt!==O.parseInt),[,1].find(function(e,t){return 0===t})||Z(Array.prototype,"find",Ue.find),0!==[,1].findIndex(function(e,t){return 0===t})&&Z(Array.prototype,"findIndex",Ue.findIndex);var wt=Function.bind.call(Function.bind,Object.prototype.propertyIsEnumerable),xt=function(e,t){l&&wt(e,t)&&Object.defineProperty(e,t,{enumerable:!1})},Tt=function(){for(var e=Number(this),t=arguments.length,n=t-e,r=new Array(0>n?0:n),i=e;t>i;++i)r[i-e]=arguments[i];return r},St=function(e){return function(t,n){return t[n]=e[n],t}},Ot=function(e,t){var n,r=i(Object(t));return ne.IsCallable(Object.getOwnPropertySymbols)&&(n=h(Object.getOwnPropertySymbols(Object(t)),wt(t))),d(A(r,n||[]),St(t),e)},jt={assign:function(e){var t=ne.ToObject(e,"Cannot convert undefined or null to object");return d(ne.Call(Tt,1,arguments),Ot,t)},is:function(e,t){return ne.SameValue(e,t)}},kt=Object.assign&&Object.preventExtensions&&function(){var e=Object.preventExtensions({1:2});try{Object.assign(e,"xy")}catch(t){return"y"===e[1]}}();if(kt&&Z(Object,"assign",jt.assign),y(Object,jt),l){var Ct={setPrototypeOf:function(e,t){var r,i=function(e,t){if(!ne.TypeIsObject(e))throw new TypeError("cannot set prototype on a non-object");if(null!==t&&!ne.TypeIsObject(t))throw new TypeError("can only set prototype to an object or null"+t)},o=function(e,t){return i(e,t),n(r,e,t),e};try{r=e.getOwnPropertyDescriptor(e.prototype,t).set,n(r,{},null)}catch(n){if(e.prototype!=={}[t])return;r=function(e){this[t]=e},o.polyfill=o(o({},null),e.prototype)instanceof e}return o}(Object,"__proto__")};y(Object,Ct)}Object.setPrototypeOf&&Object.getPrototypeOf&&null!==Object.getPrototypeOf(Object.setPrototypeOf({},null))&&null===Object.getPrototypeOf(Object.create(null))&&!function(){var e=Object.create(null),t=Object.getPrototypeOf,n=Object.setPrototypeOf;Object.getPrototypeOf=function(n){var r=t(n);return r===e?null:r},Object.setPrototypeOf=function(t,r){var i=null===r?e:r;return n(t,i)},Object.setPrototypeOf.polyfill=!1}();var At=!a(function(){Object.keys("foo")});if(!At){var Et=Object.keys;Z(Object,"keys",function(e){return Et(ne.ToObject(e))}),i=Object.keys}var Nt=a(function(){Object.keys(/a/g)});if(Nt){var _t=Object.keys;Z(Object,"keys",function(e){if(Y.regex(e)){var t=[];for(var n in e)H(e,n)&&N(t,n);return t}return _t(e)}),i=Object.keys}if(Object.getOwnPropertyNames){var Pt=!a(function(){Object.getOwnPropertyNames("foo")});if(!Pt){var It="object"===("undefined"==typeof window?"undefined":_typeof(window))?Object.getOwnPropertyNames(window):[],Mt=Object.getOwnPropertyNames;Z(Object,"getOwnPropertyNames",function(e){var t=ne.ToObject(e);if("[object Window]"===v(t))try{return Mt(t)}catch(e){return A([],It)}return Mt(t)})}}if(Object.getOwnPropertyDescriptor){var Lt=!a(function(){Object.getOwnPropertyDescriptor("foo","bar")});if(!Lt){var Ft=Object.getOwnPropertyDescriptor;Z(Object,"getOwnPropertyDescriptor",function(e,t){return Ft(ne.ToObject(e),t)})}}if(Object.seal){var Dt=!a(function(){Object.seal("foo")});if(!Dt){var qt=Object.seal;Z(Object,"seal",function(e){return ne.TypeIsObject(e)?qt(e):e})}}if(Object.isSealed){var Rt=!a(function(){Object.isSealed("foo")});if(!Rt){var Ht=Object.isSealed;Z(Object,"isSealed",function(e){return ne.TypeIsObject(e)?Ht(e):!0})}}if(Object.freeze){var $t=!a(function(){Object.freeze("foo")});if(!$t){var Bt=Object.freeze;Z(Object,"freeze",function(e){return ne.TypeIsObject(e)?Bt(e):e})}}if(Object.isFrozen){var Vt=!a(function(){Object.isFrozen("foo")});if(!Vt){var Wt=Object.isFrozen;Z(Object,"isFrozen",function(e){return ne.TypeIsObject(e)?Wt(e):!0})}}if(Object.preventExtensions){var zt=!a(function(){Object.preventExtensions("foo")});if(!zt){var Ut=Object.preventExtensions;Z(Object,"preventExtensions",function(e){return ne.TypeIsObject(e)?Ut(e):e})}}if(Object.isExtensible){var Gt=!a(function(){Object.isExtensible("foo")});if(!Gt){var Xt=Object.isExtensible;Z(Object,"isExtensible",function(e){return ne.TypeIsObject(e)?Xt(e):!1})}}if(Object.getPrototypeOf){var Jt=!a(function(){Object.getPrototypeOf("foo")});if(!Jt){var Yt=Object.getPrototypeOf;Z(Object,"getPrototypeOf",function(e){return Yt(ne.ToObject(e))})}}var Zt=l&&function(){var e=Object.getOwnPropertyDescriptor(RegExp.prototype,"flags");return e&&ne.IsCallable(e.get)}();if(l&&!Zt){var Qt=function(){if(!ne.TypeIsObject(this))throw new TypeError("Method called on incompatible type: must be an object.");var e="";return this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.unicode&&(e+="u"),this.sticky&&(e+="y"),e};w.getter(RegExp.prototype,"flags",Qt)}var Kt=l&&s(function(){return"/a/i"===String(new RegExp(/a/g,"i"))}),en=Q&&l&&function(){var e=/./;return e[B.match]=!1,RegExp(e)===e}(),tn=s(function(){return"/abc/"===RegExp.prototype.toString.call({source:"abc"})}),nn=tn&&s(function(){return"/a/b"===RegExp.prototype.toString.call({source:"a",flags:"b"})});if(!tn||!nn){var rn=RegExp.prototype.toString;g(RegExp.prototype,"toString",function(){var e=ne.RequireObjectCoercible(this);if(Y.regex(e))return n(rn,e);var t=te(e.source),r=te(e.flags);return"/"+t+"/"+r},!0),w.preserveToString(RegExp.prototype.toString,rn)}if(l&&(!Kt||en)){var on=Object.getOwnPropertyDescriptor(RegExp.prototype,"flags").get,an=Object.getOwnPropertyDescriptor(RegExp.prototype,"source")||{},sn=function(){return this.source},un=ne.IsCallable(an.get)?an.get:sn,cn=RegExp,ln=function(){return function e(t,n){var r=ne.IsRegExp(t),i=this instanceof e;if(!i&&r&&"undefined"==typeof n&&t.constructor===e)return t;var o=t,a=n;return Y.regex(t)?(o=ne.Call(un,t),a="undefined"==typeof n?ne.Call(on,t):n,new e(o,a)):(r&&(o=t.source,a="undefined"==typeof n?t.flags:n),new cn(t,n))}}();ve(cn,ln,{$input:!0}),RegExp=ln,w.redefine(O,"RegExp",ln)}if(l){var fn={input:"$_",lastMatch:"$&",lastParen:"$+",leftContext:"$`",rightContext:"$'"};p(i(fn),function(e){e in RegExp&&!(fn[e]in RegExp)&&w.getter(RegExp,fn[e],function(){return RegExp[e]})})}we(RegExp);var pn=1/Number.EPSILON,dn=function(e){return e+pn-pn},hn=Math.pow(2,-23),mn=Math.pow(2,127)*(2-hn),gn=Math.pow(2,-126),yn=Math.E,vn=Math.LOG2E,bn=Math.LOG10E,wn=Number.prototype.clz;delete Number.prototype.clz;var xn={acosh:function(e){var t=Number(e);return W(t)||1>e?0/0:1===t?0:t===1/0?t:q(t/yn+R(t+1)*R(t-1)/yn)+1},asinh:function e(t){var n=Number(t);return 0!==n&&j(n)?0>n?-e(-n):q(n+R(n*n+1)):n},atanh:function(e){var t=Number(e);return W(t)||-1>t||t>1?0/0:-1===t?-(1/0):1===t?1/0:0===t?t:.5*q((1+t)/(1-t))},cbrt:function(e){var t=Number(e);if(0===t)return t;var n,r=0>t;return r&&(t=-t),t===1/0?n=1/0:(n=D(q(t)/3),n=(t/(n*n)+2*n)/3),r?-n:n},clz32:function(e){var t=Number(e),n=ne.ToUint32(t);return 0===n?32:wn?ne.Call(wn,n):31-L(q(n+.5)*vn)},cosh:function(e){var t=Number(e);return 0===t?1:W(t)?0/0:j(t)?(0>t&&(t=-t),t>21?D(t)/2:(D(t)+D(-t))/2):1/0},expm1:function(e){var t=Number(e);if(t===-(1/0))return-1;if(!j(t)||0===t)return t;if(F(t)>.5)return D(t)-1;for(var n=t,r=0,i=1;r+n!==r;)r+=n,i+=1,n*=t/i;return r},hypot:function(){for(var e=0,t=0,n=0;n<arguments.length;++n){var r=F(Number(arguments[n]));r>t?(e*=t/r*(t/r),e+=1,t=r):e+=r>0?r/t*(r/t):r}return t===1/0?1/0:t*R(e)},log2:function(e){return q(e)*vn},log10:function(e){return q(e)*bn},log1p:function(e){var t=Number(e);return-1>t||W(t)?0/0:0===t||t===1/0?t:-1===t?-(1/0):1+t-1===0?t:t*(q(1+t)/(1+t-1))},sign:U,sinh:function(e){var t=Number(e);return j(t)&&0!==t?F(t)<1?(Math.expm1(t)-Math.expm1(-t))/2:(D(t-1)-D(-t-1))*yn/2:t},tanh:function(e){var t=Number(e);return W(t)||0===t?t:t>=20?1:-20>=t?-1:(Math.expm1(t)-Math.expm1(-t))/(D(t)+D(-t))},trunc:function(e){var t=Number(e);return 0>t?-L(-t):L(t)},imul:function(e,t){var n=ne.ToUint32(e),r=ne.ToUint32(t),i=n>>>16&65535,o=65535&n,a=r>>>16&65535,s=65535&r;return o*s+(i*s+o*a<<16>>>0)|0},fround:function(e){var t=Number(e);if(0===t||t===1/0||t===-(1/0)||W(t))return t;var n=U(t),r=F(t);if(gn>r)return n*dn(r/gn/hn)*gn*hn;var i=(1+hn/Number.EPSILON)*r,o=i-(i-r);return o>mn||W(o)?n*(1/0):n*o}};y(Math,xn),g(Math,"log1p",xn.log1p,-1e-17!==Math.log1p(-1e-17)),g(Math,"asinh",xn.asinh,Math.asinh(-1e7)!==-Math.asinh(1e7)),g(Math,"tanh",xn.tanh,-2e-17!==Math.tanh(-2e-17)),g(Math,"acosh",xn.acosh,Math.acosh(Number.MAX_VALUE)===1/0),g(Math,"cbrt",xn.cbrt,Math.abs(1-Math.cbrt(1e-300)/1e-100)/Number.EPSILON>8),g(Math,"sinh",xn.sinh,-2e-17!==Math.sinh(-2e-17));var Tn=Math.expm1(10);g(Math,"expm1",xn.expm1,Tn>22025.465794806718||22025.465794806718>Tn);var Sn=Math.round,On=0===Math.round(.5-Number.EPSILON/4)&&1===Math.round(-.5+Number.EPSILON/3.99),jn=pn+1,kn=2*pn-1,Cn=[jn,kn].every(function(e){return Math.round(e)===e});g(Math,"round",function(e){var t=L(e),n=-1===t?-0:t+1;return.5>e-t?t:n},!On||!Cn),w.preserveToString(Math.round,Sn);var An=Math.imul;-5!==Math.imul(4294967295,5)&&(Math.imul=xn.imul,w.preserveToString(Math.imul,An)),2!==Math.imul.length&&Z(Math,"imul",function(){return ne.Call(An,Math,arguments)});var En=function(){var e=O.setTimeout;if("function"==typeof e||"object"===("undefined"==typeof e?"undefined":_typeof(e))){ne.IsPromise=function(e){return ne.TypeIsObject(e)?"undefined"==typeof e._promise?!1:!0:!1};var t,r=function(e){if(!ne.IsConstructor(e))throw new TypeError("Bad promise constructor");var t=this,n=function(e,n){if(void 0!==t.resolve||void 0!==t.reject)throw new TypeError("Bad Promise implementation!");t.resolve=e,t.reject=n};if(t.resolve=void 0,t.reject=void 0,t.promise=new e(n),!ne.IsCallable(t.resolve)||!ne.IsCallable(t.reject))throw new TypeError("Bad promise constructor")};"undefined"!=typeof window&&ne.IsCallable(window.postMessage)&&(t=function(){var e=[],t="zero-timeout-message",n=function(n){N(e,n),window.postMessage(t,"*")},r=function(n){if(n.source===window&&n.data===t){if(n.stopPropagation(),0===e.length)return;var r=P(e);r()}};return window.addEventListener("message",r,!0),n});var i,o,a=function(){var e=O.Promise,t=e&&e.resolve&&e.resolve();return t&&function(e){return t.then(e)}},s=ne.IsCallable(O.setImmediate)?O.setImmediate:"object"===("undefined"==typeof process?"undefined":_typeof(process))&&process.nextTick?process.nextTick:a()||(ne.IsCallable(t)?t():function(t){e(t,0)}),u=function(e){return e},c=function(e){throw e},l=0,f=1,p=2,d=0,h=1,m=2,g={},v=function(e,t,n){s(function(){b(e,t,n)})},b=function(e,t,n){var r,i;if(t===g)return e(n);try{r=e(n),i=t.resolve}catch(e){r=e,i=t.reject}i(r)},w=function(e,t){var n=e._promise,r=n.reactionLength;if(r>0&&(v(n.fulfillReactionHandler0,n.reactionCapability0,t),n.fulfillReactionHandler0=void 0,n.rejectReactions0=void 0,n.reactionCapability0=void 0,r>1))for(var i=1,o=0;r>i;i++,o+=3)v(n[o+d],n[o+m],t),e[o+d]=void 0,e[o+h]=void 0,e[o+m]=void 0;n.result=t,n.state=f,n.reactionLength=0},x=function(e,t){var n=e._promise,r=n.reactionLength;if(r>0&&(v(n.rejectReactionHandler0,n.reactionCapability0,t),n.fulfillReactionHandler0=void 0,n.rejectReactions0=void 0,n.reactionCapability0=void 0,r>1))for(var i=1,o=0;r>i;i++,o+=3)v(n[o+h],n[o+m],t),e[o+d]=void 0,e[o+h]=void 0,e[o+m]=void 0;n.result=t,n.state=p,n.reactionLength=0},T=function(e){var t=!1,n=function(n){var r;if(!t){if(t=!0,n===e)return x(e,new TypeError("Self resolution"));if(!ne.TypeIsObject(n))return w(e,n);try{r=n.then}catch(t){return x(e,t)}return ne.IsCallable(r)?void s(function(){j(e,n,r)}):w(e,n)}},r=function(n){return t?void 0:(t=!0,x(e,n))};return{resolve:n,reject:r}},S=function(e,t,r,i){e===o?n(e,t,r,i,g):n(e,t,r,i)},j=function(e,t,n){var r=T(e),i=r.resolve,o=r.reject;try{S(n,t,i,o)}catch(e){o(e)}},k=function(){var e=function(t){if(!(this instanceof e))throw new TypeError('Constructor Promise requires "new"');
-
-if(this&&this._promise)throw new TypeError("Bad construction");if(!ne.IsCallable(t))throw new TypeError("not a valid resolver");var n=Oe(this,e,i,{_promise:{result:void 0,state:l,reactionLength:0,fulfillReactionHandler0:void 0,rejectReactionHandler0:void 0,reactionCapability0:void 0}}),r=T(n),o=r.reject;try{t(r.resolve,o)}catch(e){o(e)}return n};return e}();i=k.prototype;var C=function(e,t,n,r){var i=!1;return function(o){if(!i&&(i=!0,t[e]=o,0===--r.count)){var a=n.resolve;a(t)}}},A=function(e,t,n){for(var r,i,o=e.iterator,a=[],s={count:1},u=0;;){try{if(r=ne.IteratorStep(o),r===!1){e.done=!0;break}i=r.value}catch(t){throw e.done=!0,t}a[u]=void 0;var c=t.resolve(i),l=C(u,a,n,s);s.count+=1,S(c.then,c,l,n.reject),u+=1}if(0===--s.count){var f=n.resolve;f(a)}return n.promise},E=function(e,t,n){for(var r,i,o,a=e.iterator;;){try{if(r=ne.IteratorStep(a),r===!1){e.done=!0;break}i=r.value}catch(t){throw e.done=!0,t}o=t.resolve(i),S(o.then,o,n.resolve,n.reject)}return n.promise};return y(k,{all:function(e){var t=this;if(!ne.TypeIsObject(t))throw new TypeError("Promise is not object");var n,i,o=new r(t);try{return n=ne.GetIterator(e),i={iterator:n,done:!1},A(i,t,o)}catch(e){var a=e;if(i&&!i.done)try{ne.IteratorClose(n,!0)}catch(e){a=e}var s=o.reject;return s(a),o.promise}},race:function(e){var t=this;if(!ne.TypeIsObject(t))throw new TypeError("Promise is not object");var n,i,o=new r(t);try{return n=ne.GetIterator(e),i={iterator:n,done:!1},E(i,t,o)}catch(e){var a=e;if(i&&!i.done)try{ne.IteratorClose(n,!0)}catch(e){a=e}var s=o.reject;return s(a),o.promise}},reject:function(e){var t=this;if(!ne.TypeIsObject(t))throw new TypeError("Bad promise constructor");var n=new r(t),i=n.reject;return i(e),n.promise},resolve:function(e){var t=this;if(!ne.TypeIsObject(t))throw new TypeError("Bad promise constructor");if(ne.IsPromise(e)){var n=e.constructor;if(n===t)return e}var i=new r(t),o=i.resolve;return o(e),i.promise}}),y(i,{catch:function(e){return this.then(null,e)},then:function(e,t){var n=this;if(!ne.IsPromise(n))throw new TypeError("not a promise");var i,o=ne.SpeciesConstructor(n,k),a=arguments.length>2&&arguments[2]===g;i=a&&o===k?g:new r(o);var s,y=ne.IsCallable(e)?e:u,b=ne.IsCallable(t)?t:c,w=n._promise;if(w.state===l){if(0===w.reactionLength)w.fulfillReactionHandler0=y,w.rejectReactionHandler0=b,w.reactionCapability0=i;else{var x=3*(w.reactionLength-1);w[x+d]=y,w[x+h]=b,w[x+m]=i}w.reactionLength+=1}else if(w.state===f)s=w.result,v(y,i,s);else{if(w.state!==p)throw new TypeError("unexpected Promise state");s=w.result,v(b,i,s)}return i.promise}}),g=new r(k),o=i.then,k}}();if(O.Promise&&(delete O.Promise.accept,delete O.Promise.defer,delete O.Promise.prototype.chain),"function"==typeof En){y(O,{Promise:En});var Nn=T(O.Promise,function(e){return e.resolve(42).then(function(){})instanceof e}),_n=!a(function(){O.Promise.reject(42).then(null,5).then(null,$)}),Pn=a(function(){O.Promise.call(3,$)}),In=function(e){var t=e.resolve(5);t.constructor={};var n=e.resolve(t);try{n.then(null,$).then(null,$)}catch(e){return!0}return t===n}(O.Promise),Mn=l&&function(){var e=0,t=Object.defineProperty({},"then",{get:function(){e+=1}});return Promise.resolve(t),1===e}(),Ln=function e(t){var n=new Promise(t);t(3,function(){}),this.then=n.then,this.constructor=e};Ln.prototype=Promise.prototype,Ln.all=Promise.all;var Fn=s(function(){return!!Ln.all([1,2])});if(Nn&&_n&&Pn&&!In&&Mn&&!Fn||(Promise=En,Z(O,"Promise",En)),1!==Promise.all.length){var Dn=Promise.all;Z(Promise,"all",function(){return ne.Call(Dn,this,arguments)})}if(1!==Promise.race.length){var qn=Promise.race;Z(Promise,"race",function(){return ne.Call(qn,this,arguments)})}if(1!==Promise.resolve.length){var Rn=Promise.resolve;Z(Promise,"resolve",function(){return ne.Call(Rn,this,arguments)})}if(1!==Promise.reject.length){var Hn=Promise.reject;Z(Promise,"reject",function(){return ne.Call(Hn,this,arguments)})}xt(Promise,"all"),xt(Promise,"race"),xt(Promise,"resolve"),xt(Promise,"reject"),we(Promise)}var $n=function(e){var t=i(d(e,function(e,t){return e[t]=!0,e},{}));return e.join(":")===t.join(":")},Bn=$n(["z","a","bb"]),Vn=$n(["z",1,"a","3",2]);if(l){var Wn=function(e){return Bn?"undefined"==typeof e||null===e?"^"+ne.ToString(e):"string"==typeof e?"$"+e:"number"==typeof e?Vn?e:"n"+e:"boolean"==typeof e?"b"+e:null:null},zn=function(){return Object.create?Object.create(null):{}},Un=function(e,t,i){if(r(i)||Y.string(i))p(i,function(e){if(!ne.TypeIsObject(e))throw new TypeError("Iterator value "+e+" is not an entry object");t.set(e[0],e[1])});else if(i instanceof e)n(e.prototype.forEach,i,function(e,n){t.set(n,e)});else{var o,a;if(null!==i&&"undefined"!=typeof i){if(a=t.set,!ne.IsCallable(a))throw new TypeError("bad map");o=ne.GetIterator(i)}if("undefined"!=typeof o)for(;;){var s=ne.IteratorStep(o);if(s===!1)break;var u=s.value;try{if(!ne.TypeIsObject(u))throw new TypeError("Iterator value "+u+" is not an entry object");n(a,t,u[0],u[1])}catch(e){throw ne.IteratorClose(o,!0),e}}}},Gn=function(e,t,i){if(r(i)||Y.string(i))p(i,function(e){t.add(e)});else if(i instanceof e)n(e.prototype.forEach,i,function(e){t.add(e)});else{var o,a;if(null!==i&&"undefined"!=typeof i){if(a=t.add,!ne.IsCallable(a))throw new TypeError("bad set");o=ne.GetIterator(i)}if("undefined"!=typeof o)for(;;){var s=ne.IteratorStep(o);if(s===!1)break;var u=s.value;try{n(a,t,u)}catch(e){throw ne.IteratorClose(o,!0),e}}}},Xn={Map:function(){var e={},t=function(e,t){this.key=e,this.value=t,this.next=null,this.prev=null};t.prototype.isRemoved=function(){return this.key===e};var r=function(e){return!!e._es6map},i=function(e,t){if(!ne.TypeIsObject(e)||!r(e))throw new TypeError("Method Map.prototype."+t+" called on incompatible receiver "+ne.ToString(e))},o=function(e,t){i(e,"[[MapIterator]]"),this.head=e._head,this.i=this.head,this.kind=t};o.prototype={next:function(){var e=this.i,t=this.kind,n=this.head;if("undefined"==typeof this.i)return Be();for(;e.isRemoved()&&e!==n;)e=e.prev;for(var r;e.next!==n;)if(e=e.next,!e.isRemoved())return r="key"===t?e.key:"value"===t?e.value:[e.key,e.value],this.i=e,Be(r);return this.i=void 0,Be()}},xe(o.prototype);var a,s=function e(){if(!(this instanceof e))throw new TypeError('Constructor Map requires "new"');if(this&&this._es6map)throw new TypeError("Bad construction");var n=Oe(this,e,a,{_es6map:!0,_head:null,_storage:zn(),_size:0}),r=new t(null,null);return r.next=r.prev=r,n._head=r,arguments.length>0&&Un(e,n,arguments[0]),n};return a=s.prototype,w.getter(a,"size",function(){if("undefined"==typeof this._size)throw new TypeError("size method called on incompatible Map");return this._size}),y(a,{get:function(e){i(this,"get");var t=Wn(e);if(null!==t){var n=this._storage[t];return n?n.value:void 0}for(var r=this._head,o=r;(o=o.next)!==r;)if(ne.SameValueZero(o.key,e))return o.value},has:function(e){i(this,"has");var t=Wn(e);if(null!==t)return"undefined"!=typeof this._storage[t];for(var n=this._head,r=n;(r=r.next)!==n;)if(ne.SameValueZero(r.key,e))return!0;return!1},set:function(e,n){i(this,"set");var r,o=this._head,a=o,s=Wn(e);if(null!==s){if("undefined"!=typeof this._storage[s])return this._storage[s].value=n,this;r=this._storage[s]=new t(e,n),a=o.prev}for(;(a=a.next)!==o;)if(ne.SameValueZero(a.key,e))return a.value=n,this;return r=r||new t(e,n),ne.SameValue(-0,e)&&(r.key=0),r.next=this._head,r.prev=this._head.prev,r.prev.next=r,r.next.prev=r,this._size+=1,this},delete:function(t){i(this,"delete");var n=this._head,r=n,o=Wn(t);if(null!==o){if("undefined"==typeof this._storage[o])return!1;r=this._storage[o].prev,delete this._storage[o]}for(;(r=r.next)!==n;)if(ne.SameValueZero(r.key,t))return r.key=r.value=e,r.prev.next=r.next,r.next.prev=r.prev,this._size-=1,!0;return!1},clear:function(){i(this,"clear"),this._size=0,this._storage=zn();for(var t=this._head,n=t,r=n.next;(n=r)!==t;)n.key=n.value=e,r=n.next,n.next=n.prev=t;t.next=t.prev=t},keys:function(){return i(this,"keys"),new o(this,"key")},values:function(){return i(this,"values"),new o(this,"value")},entries:function(){return i(this,"entries"),new o(this,"key+value")},forEach:function(e){i(this,"forEach");for(var t=arguments.length>1?arguments[1]:null,r=this.entries(),o=r.next();!o.done;o=r.next())t?n(e,t,o.value[1],o.value[0],this):e(o.value[1],o.value[0],this)}}),xe(a,a.entries),s}(),Set:function(){var e,t=function(e){return e._es6set&&"undefined"!=typeof e._storage},r=function(e,n){if(!ne.TypeIsObject(e)||!t(e))throw new TypeError("Set.prototype."+n+" called on incompatible receiver "+ne.ToString(e))},o=function t(){if(!(this instanceof t))throw new TypeError('Constructor Set requires "new"');if(this&&this._es6set)throw new TypeError("Bad construction");var n=Oe(this,t,e,{_es6set:!0,"[[SetData]]":null,_storage:zn()});if(!n._es6set)throw new TypeError("bad set");return arguments.length>0&&Gn(t,n,arguments[0]),n};e=o.prototype;var a=function(e){var t=e;if("^null"===t)return null;if("^undefined"===t)return void 0;var n=t.charAt(0);return"$"===n?E(t,1):"n"===n?+E(t,1):"b"===n?"btrue"===t:+t},s=function(e){if(!e["[[SetData]]"]){var t=e["[[SetData]]"]=new Xn.Map;p(i(e._storage),function(e){var n=a(e);t.set(n,n)}),e["[[SetData]]"]=t}e._storage=null};return w.getter(o.prototype,"size",function(){return r(this,"size"),this._storage?i(this._storage).length:(s(this),this["[[SetData]]"].size)}),y(o.prototype,{has:function(e){r(this,"has");var t;return this._storage&&null!==(t=Wn(e))?!!this._storage[t]:(s(this),this["[[SetData]]"].has(e))},add:function(e){r(this,"add");var t;return this._storage&&null!==(t=Wn(e))?(this._storage[t]=!0,this):(s(this),this["[[SetData]]"].set(e,e),this)},delete:function(e){r(this,"delete");var t;if(this._storage&&null!==(t=Wn(e))){var n=H(this._storage,t);return delete this._storage[t]&&n}return s(this),this["[[SetData]]"].delete(e)},clear:function(){r(this,"clear"),this._storage&&(this._storage=zn()),this["[[SetData]]"]&&this["[[SetData]]"].clear()},values:function(){return r(this,"values"),s(this),this["[[SetData]]"].values()},entries:function(){return r(this,"entries"),s(this),this["[[SetData]]"].entries()},forEach:function(e){r(this,"forEach");var t=arguments.length>1?arguments[1]:null,i=this;s(i),this["[[SetData]]"].forEach(function(r,o){t?n(e,t,o,o,i):e(o,o,i)})}}),g(o.prototype,"keys",o.prototype.values,!0),xe(o.prototype,o.prototype.values),o}()};if(O.Map||O.Set){var Jn=s(function(){return 2===new Map([[1,2]]).get(1)});if(!Jn){var Yn=O.Map;O.Map=function e(){if(!(this instanceof e))throw new TypeError('Constructor Map requires "new"');var t=new Yn;return arguments.length>0&&Un(e,t,arguments[0]),delete t.constructor,Object.setPrototypeOf(t,O.Map.prototype),t},O.Map.prototype=x(Yn.prototype),g(O.Map.prototype,"constructor",O.Map,!0),w.preserveToString(O.Map,Yn)}var Zn=new Map,Qn=function(){var e=new Map([[1,0],[2,0],[3,0],[4,0]]);return e.set(-0,e),e.get(0)===e&&e.get(-0)===e&&e.has(0)&&e.has(-0)}(),Kn=Zn.set(1,2)===Zn;if(!Qn||!Kn){var er=Map.prototype.set;Z(Map.prototype,"set",function(e,t){return n(er,this,0===e?0:e,t),this})}if(!Qn){var tr=Map.prototype.get,nr=Map.prototype.has;y(Map.prototype,{get:function(e){return n(tr,this,0===e?0:e)},has:function(e){return n(nr,this,0===e?0:e)}},!0),w.preserveToString(Map.prototype.get,tr),w.preserveToString(Map.prototype.has,nr)}var rr=new Set,ir=function(e){return e.delete(0),e.add(-0),!e.has(0)}(rr),or=rr.add(1)===rr;if(!ir||!or){var ar=Set.prototype.add;Set.prototype.add=function(e){return n(ar,this,0===e?0:e),this},w.preserveToString(Set.prototype.add,ar)}if(!ir){var sr=Set.prototype.has;Set.prototype.has=function(e){return n(sr,this,0===e?0:e)},w.preserveToString(Set.prototype.has,sr);var ur=Set.prototype.delete;Set.prototype.delete=function(e){return n(ur,this,0===e?0:e)},w.preserveToString(Set.prototype.delete,ur)}var cr=T(O.Map,function(e){var t=new e([]);return t.set(42,42),t instanceof e}),lr=Object.setPrototypeOf&&!cr,fr=function(){try{return!(O.Map()instanceof O.Map)}catch(e){return e instanceof TypeError}}();if(0!==O.Map.length||lr||!fr){var pr=O.Map;O.Map=function e(){if(!(this instanceof e))throw new TypeError('Constructor Map requires "new"');var t=new pr;return arguments.length>0&&Un(e,t,arguments[0]),delete t.constructor,Object.setPrototypeOf(t,e.prototype),t},O.Map.prototype=pr.prototype,g(O.Map.prototype,"constructor",O.Map,!0),w.preserveToString(O.Map,pr)}var dr=T(O.Set,function(e){var t=new e([]);return t.add(42,42),t instanceof e}),hr=Object.setPrototypeOf&&!dr,mr=function(){try{return!(O.Set()instanceof O.Set)}catch(e){return e instanceof TypeError}}();if(0!==O.Set.length||hr||!mr){var gr=O.Set;O.Set=function e(){if(!(this instanceof e))throw new TypeError('Constructor Set requires "new"');var t=new gr;return arguments.length>0&&Gn(e,t,arguments[0]),delete t.constructor,Object.setPrototypeOf(t,e.prototype),t},O.Set.prototype=gr.prototype,g(O.Set.prototype,"constructor",O.Set,!0),w.preserveToString(O.Set,gr)}var yr=new O.Map,vr=!s(function(){return yr.keys().next().done});if(("function"!=typeof O.Map.prototype.clear||0!==(new O.Set).size||0!==yr.size||"function"!=typeof O.Map.prototype.keys||"function"!=typeof O.Set.prototype.keys||"function"!=typeof O.Map.prototype.forEach||"function"!=typeof O.Set.prototype.forEach||u(O.Map)||u(O.Set)||"function"!=typeof yr.keys().next||vr||!cr)&&y(O,{Map:Xn.Map,Set:Xn.Set},!0),O.Set.prototype.keys!==O.Set.prototype.values&&g(O.Set.prototype,"keys",O.Set.prototype.values,!0),xe(Object.getPrototypeOf((new O.Map).keys())),xe(Object.getPrototypeOf((new O.Set).keys())),f&&"has"!==O.Set.prototype.has.name){var br=O.Set.prototype.has;Z(O.Set.prototype,"has",function(e){return n(br,this,e)})}}y(O,Xn),we(O.Map),we(O.Set)}var wr=function(e){if(!ne.TypeIsObject(e))throw new TypeError("target must be an object")},xr={apply:function(){return ne.Call(ne.Call,null,arguments)},construct:function(e,t){if(!ne.IsConstructor(e))throw new TypeError("First argument must be a constructor.");var n=arguments.length>2?arguments[2]:e;if(!ne.IsConstructor(n))throw new TypeError("new.target must be a constructor.");return ne.Construct(e,t,n,"internal")},deleteProperty:function(e,t){if(wr(e),l){var n=Object.getOwnPropertyDescriptor(e,t);if(n&&!n.configurable)return!1}return delete e[t]},has:function(e,t){return wr(e),t in e}};Object.getOwnPropertyNames&&Object.assign(xr,{ownKeys:function(e){wr(e);var t=Object.getOwnPropertyNames(e);return ne.IsCallable(Object.getOwnPropertySymbols)&&_(t,Object.getOwnPropertySymbols(e)),t}});var Tr=function(e){return!a(e)};if(Object.preventExtensions&&Object.assign(xr,{isExtensible:function(e){return wr(e),Object.isExtensible(e)},preventExtensions:function(e){return wr(e),Tr(function(){Object.preventExtensions(e)})}}),l){var Sr=function(e,t,n){var r=Object.getOwnPropertyDescriptor(e,t);if(!r){var i=Object.getPrototypeOf(e);return null===i?void 0:Sr(i,t,n)}return"value"in r?r.value:r.get?ne.Call(r.get,n):void 0},Or=function(e,t,r,i){var o=Object.getOwnPropertyDescriptor(e,t);if(!o){var a=Object.getPrototypeOf(e);if(null!==a)return Or(a,t,r,i);o={value:void 0,writable:!0,enumerable:!0,configurable:!0}}if("value"in o){if(!o.writable)return!1;if(!ne.TypeIsObject(i))return!1;var s=Object.getOwnPropertyDescriptor(i,t);return s?ee.defineProperty(i,t,{value:r}):ee.defineProperty(i,t,{value:r,writable:!0,enumerable:!0,configurable:!0})}return o.set?(n(o.set,i,r),!0):!1};Object.assign(xr,{defineProperty:function(e,t,n){return wr(e),Tr(function(){Object.defineProperty(e,t,n)})},getOwnPropertyDescriptor:function(e,t){return wr(e),Object.getOwnPropertyDescriptor(e,t)},get:function(e,t){wr(e);var n=arguments.length>2?arguments[2]:e;return Sr(e,t,n)},set:function(e,t,n){wr(e);var r=arguments.length>3?arguments[3]:e;return Or(e,t,n,r)}})}if(Object.getPrototypeOf){var jr=Object.getPrototypeOf;xr.getPrototypeOf=function(e){return wr(e),jr(e)}}if(Object.setPrototypeOf&&xr.getPrototypeOf){var kr=function(e,t){for(var n=t;n;){if(e===n)return!0;n=xr.getPrototypeOf(n)}return!1};Object.assign(xr,{setPrototypeOf:function(e,t){if(wr(e),null!==t&&!ne.TypeIsObject(t))throw new TypeError("proto must be an object or null");return t===ee.getPrototypeOf(e)?!0:ee.isExtensible&&!ee.isExtensible(e)?!1:kr(e,t)?!1:(Object.setPrototypeOf(e,t),!0)}})}var Cr=function(e,t){if(ne.IsCallable(O.Reflect[e])){var n=s(function(){return O.Reflect[e](1),O.Reflect[e](0/0),O.Reflect[e](!0),!0});n&&Z(O.Reflect,e,t)}else g(O.Reflect,e,t)};Object.keys(xr).forEach(function(e){Cr(e,xr[e])});var Ar=O.Reflect.getPrototypeOf;if(f&&Ar&&"getPrototypeOf"!==Ar.name&&Z(O.Reflect,"getPrototypeOf",function(e){return n(Ar,O.Reflect,e)}),O.Reflect.setPrototypeOf&&s(function(){return O.Reflect.setPrototypeOf(1,{}),!0})&&Z(O.Reflect,"setPrototypeOf",xr.setPrototypeOf),O.Reflect.defineProperty&&(s(function(){var e=!O.Reflect.defineProperty(1,"test",{value:1}),t="function"!=typeof Object.preventExtensions||!O.Reflect.defineProperty(Object.preventExtensions({}),"test",{});return e&&t})||Z(O.Reflect,"defineProperty",xr.defineProperty)),O.Reflect.construct&&(s(function(){var e=function(){};return O.Reflect.construct(function(){},[],e)instanceof e})||Z(O.Reflect,"construct",xr.construct)),"Invalid Date"!==String(new Date(0/0))){var Er=Date.prototype.toString,Nr=function(){var e=+this;return e!==e?"Invalid Date":ne.Call(Er,this)};Z(Date.prototype,"toString",Nr)}var _r={anchor:function(e){return ne.CreateHTML(this,"a","name",e)},big:function(){return ne.CreateHTML(this,"big","","")},blink:function(){return ne.CreateHTML(this,"blink","","")},bold:function(){return ne.CreateHTML(this,"b","","")},fixed:function(){return ne.CreateHTML(this,"tt","","")},fontcolor:function(e){return ne.CreateHTML(this,"font","color",e)},fontsize:function(e){return ne.CreateHTML(this,"font","size",e)},italics:function(){return ne.CreateHTML(this,"i","","")},link:function(e){return ne.CreateHTML(this,"a","href",e)},small:function(){return ne.CreateHTML(this,"small","","")},strike:function(){return ne.CreateHTML(this,"strike","","")},sub:function(){return ne.CreateHTML(this,"sub","","")},sup:function(){return ne.CreateHTML(this,"sup","","")}};p(Object.keys(_r),function(e){var t=String.prototype[e],r=!1;if(ne.IsCallable(t)){var i=n(t,"",' " '),o=A([],i.match(/"/g)).length;r=i!==i.toLowerCase()||o>2}else r=!0;r&&Z(String.prototype,e,_r[e])});var Pr=function(){if(!Q)return!1;var e="object"===("undefined"==typeof JSON?"undefined":_typeof(JSON))&&"function"==typeof JSON.stringify?JSON.stringify:null;if(!e)return!1;if("undefined"!=typeof e(B()))return!0;if("[null]"!==e([B()]))return!0;var t={a:B()};return t[B()]=!0,"{}"!==e(t)?!0:!1}(),Ir=s(function(){return Q?"{}"===JSON.stringify(Object(B()))&&"[{}]"===JSON.stringify([Object(B())]):!0});if(Pr||!Ir){var Mr=JSON.stringify;Z(JSON,"stringify",function(e){if("symbol"!==("undefined"==typeof e?"undefined":_typeof(e))){var t;arguments.length>1&&(t=arguments[1]);var i=[e];if(r(t))i.push(t);else{var o=ne.IsCallable(t)?t:null,a=function(e,t){var r=o?n(o,this,e,t):t;return"symbol"!==("undefined"==typeof r?"undefined":_typeof(r))?Y.symbol(r)?St({})(r):r:void 0};i.push(a)}return arguments.length>2&&i.push(arguments[2]),Mr.apply(this,i)}})}return O}),define("jqueryplugins",["jquery"],function(e){e.prototype.extend({popAttr:function(e){var t=this.attr(e);return this.removeAttr(e),t},popData:function(e){var t=this.data(e);return this.removeData(e),t},tag:function(){return this[0]&&this[0].tagName&&this[0].tagName.toLowerCase()},textNodes:function(){return 1===this.length&&this[0]instanceof Text?[this[0]]:Array.from(this.add(this.contents().add(this.find("*").contents())).filter(function(){return this instanceof Text})).sort(function(e,t){return 2&e.compareDocumentPosition(t)?1:-1})},findAndFilter:function(e){return this.filter(e).add(this.find(e))}})}),function(){function e(){for(var e=0;e<arguments.length;e++)for(var t in arguments[e])this[t]=arguments[e][t]}function t(e,t){e.childAt=e.childAt||{};for(var n=t.start;n<t.end;n+=1)e.childAt[n]=t}function n(e,t,n,r){return!(e.canFollow&&!(e.canFollow.indexOf(n&&n.type)>-1)||e.cannotFollow&&(-1!==e.cannotFollow.indexOf(n&&n.type)||e.cannotFollow.indexOf("text")>-1&&r)||e.peek&&e.peek.toLowerCase()!==t.slice(0,e.peek.length).toLowerCase())}function r(e){for(var t=e.innerText,r=[],o=0,s=o,u=t.length,c=null;u>o;){for(var l=t.slice(o),f=(r.length?r[0]:e).innerMode,p=0,d=f.length;d>p;p+=1){var h=a[f[p]];if(n(h,l,c,o>s)&&h.pattern.test(l)){var m=h.pattern.exec(l),g=h.fn(m),y=!1,v=0;if(g.matches){for(;v<r.length;v+=1){var b=r[v].type;if(b in g.matches){y=!0;break}0===b.indexOf("verbatim")&&(b="verbatimOpener"),g.cannotCross&&g.cannotCross.indexOf(b)>-1&&(v=r.length-1)}if(v>=r.length&&!g.isFront)continue}o>s&&e.addChild({type:"text",text:t.slice(s,o),innerMode:f}),c=e.addChild(g),o+=c.text.length,s=o,y&&(i(e,c,r[v]),r=r.slice(v+1)),c.isFrontToken()&&r.unshift(c);break}}p===d&&(o+=1,null===c&&(c={type:"text"}))}for(o>s&&e.addChild({type:"text",text:t.slice(s,o),innerMode:(r.length?r[0]:e).innerMode});r.length>0;)r.shift().demote();return e}function i(e,n,r){var i=e.children.indexOf(n),o=e.children.indexOf(r);n.children=e.children.splice(o+1,i-(o+1)),n.children.forEach(function(e){t(n,e)}),n.type=n.matches[r.type],n.innerText="";for(var a=0,s=n.children.length;s>a;a++)n.innerText+=n.children[a].text;n.start=r.start,n.text=r.text+n.innerText+n.text,Object.keys(r).forEach(function(e){Object.hasOwnProperty.call(n,e)||(n[e]=r[e])}),n.isFront&&(n.isFront=!1),e.children.splice(o,1),t(e,n)}var o=void 0,a={};e.prototype={constructor:e,addChild:function(n){var i=this.lastChildEnd(),o=new e({start:i,end:n.text&&i+n.text.length,children:[]},n);return o.innerText&&r(o),this.children.push(o),t(this,o),o},lastChild:function(){return this.children?this.children[this.children.length-1]||null:null},lastChildEnd:function(){var e=this.lastChild();return e?e.end:this.start+Math.max(0,this.text.indexOf(this.innerText))},tokenAt:function(e){if(e<this.start||e>=this.end)return null;if(this.childAt)return this.childAt[e]&&this.childAt[e].tokenAt(e)||this;if(this.children.length)for(var t=0;t<this.children.length;t+=1){var n=this.children[t].tokenAt(e);if(n)return n}return this},pathAt:function(e){if(e<this.start||e>=this.end)return[];if(this.childAt)return(this.childAt[e]&&this.childAt[e].pathAt(e)||[]).concat(this);var t=[];if(this.children.length)for(var n=0;n<this.children.length;n+=1){var r=this.children[n].pathAt(e);if(r.length){t.concat(r);break}}return t.concat(this)},nearestTokenAt:function(e){return e<this.start||e>=this.end?null:this.children?this.children.reduce(function(t,n){return t||(e>=n.start&&e<n.end?n:null)},null):this},everyLeaf:function(e){return this.children&&0!==this.children.length?this.children.reduce(function(t,n){return n.everyLeaf(e)&&t},!0):!!e(this)},isWhitespace:function(){return this.everyLeaf(function(e){return"whitespace"===e.type||!e.text.trim()})},isFrontToken:function(){return this.isFront},isBackToken:function(){return"matches"in this},demote:function(){this.type="text"},error:function(e){this.type="error",this.message=e},toString:function(){var e=this.type+"("+this.start+"\u2192"+this.end+")";return this.children&&this.children.length>0&&(e+="["+this.children+"]"),e}},o={lex:function(t,n){return r(new e({type:"root",start:n||0,end:t.length,text:t,innerText:t,children:[],childAt:{},innerMode:o.modes.start}))},rules:a,modes:{}},"object"===("undefined"==typeof module?"undefined":_typeof(module))?module.exports=o:"function"==typeof define&&define.amd?define("lexer",[],function(){return o}):this&&this.loaded?(this.modules||(this.modules={}),this.modules.Lexer=o):this.TwineLexer=o}.call(eval("this")||("undefined"!=typeof global?global:window)),function(){function e(t){return t&&"object"===("undefined"==typeof t?"undefined":_typeof(t))?(Object.keys(t).forEach(function(n){t[n]=e(t[n])}),t):(t+"").replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function t(){return"[^"+Array.apply(0,arguments).map(e).join("")+"]*"}function n(e){return function(){return"("+e+Array.apply(0,arguments).join("|")+")"}}var r=void 0,i=n("?:"),o=n("?!"),a=n("?="),s="[ \\f\\t\\v\\u00a0\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000]*",u=s.replace("*","+"),c="\\b",l="\\\\\\n\\\\?|\\n\\\\",f="\\n(?!\\\\)",p="[\\w\\-\\u00c0-\\u00de\\u00df-\\u00ff\\u0150\\u0170\\u0151\\u0171\\uD800-\\uDFFF]",d=p.replace("\\-",""),h=i("\\n","$"),m="("+i(l,"[^\\n]")+"+)",g="\\*",y=s+"("+g+"+)"+u+m+h,v="(?:0\\.)",b=s+"("+v+"+)"+u+m+h,w=s+"-{3,}"+s+h,x=s+"(#{1,6})"+s+m+h,T=s+"(==+>|<=+|=+><=+|<==+>)"+s+h,S=s+"(=+\\|+|\\|+=+|=+\\|+=+|\\|=+\\|)"+s+h,O={opener:"\\[\\[(?!\\[)",text:"("+t("]")+")",rightSeparator:i("\\->","\\|"),leftSeparator:"<\\-",closer:"\\]\\]",legacySeparator:"\\|",legacyText:"("+i("[^\\|\\]]","\\]"+o("\\]"))+"+)"},j=d+"*"+d.replace("\\w","a-zA-Z")+d+"*",k="\\$("+j+")",C="'s"+u+"("+j+")",A="("+j+")"+u+"of"+c+o("it"+c),E="'s"+u,N="of"+c,_=i("it","time")+c,P="its"+u+"("+j+")",I="its"+u,M="("+j+")"+u+"of"+u+"it"+c,L="of"+c+u+"it"+c,F={opener:"\\(",name:"("+i(p+"+",k)+"):"+o("\\/"),closer:"\\)"},D="<<[^>\\s]+\\s*(?:\\\\.|'(?:[^'\\\\]*\\\\.)*[^'\\\\]*'|\"(?:[^\"\\\\]*\\\\.)*[^\"\\\\]*\"|[^'\"\\\\>]|>(?!>))*>>",q=i("=<","=>","[gl]te?"+c,"n?eq"+c,"isnot"+c,"are"+c,"x"+c),R={name:"[a-zA-Z][\\w\\-]*",attrs:"(?:\"[^\"]*\"|'[^']*'|[^'\">])*?"},H="\\|("+p+"+)(>|\\))",$="(<|\\()("+p+"+)\\|",B="_("+j+")"+c,V="\\b(\\d+(?:\\.\\d+)?(?:[eE][+\\-]?\\d+)?)"+o("m?s")+c;O.main=O.opener+i(O.text+O.rightSeparator,O.text.replace("*","*?")+O.leftSeparator)+O.text,r={upperLetter:"[A-Z\\u00c0-\\u00de\\u0150\\u0170]",lowerLetter:"[a-z0-9_\\-\\u00df-\\u00ff\\u0151\\u0171]",anyLetter:p,anyLetterStrict:d,whitespace:u,escapedLine:l,br:f,commentFront:"<!--",commentBack:"-->",tag:"<\\/?"+R.name+R.attrs+">",tagPeek:"<",scriptStyleTag:"<("+i("script","style")+")"+R.attrs+">[^]*?<\\/\\1>",scriptStyleTagOpener:"<",url:"("+i("https?","mailto","javascript","ftp","data")+":\\/\\/[^\\s<]+[^<.,:;\"')\\]\\s])",bullet:g,hr:w,heading:x,align:T,column:S,bulleted:y,numbered:b,strikeOpener:e("~~"),italicOpener:e("//"),boldOpener:e("''"),supOpener:e("^^"),strongFront:e("**"),strongBack:e("**"),emFront:e("*"),emBack:e("*"),verbatimOpener:"`+",collapsedFront:"{",collapsedBack:"}",hookAppendedFront:"\\[",hookPrependedFront:H+"\\[",hookFront:"\\[",hookBack:"\\]"+o($),hookAppendedBack:"\\]"+$,passageLink:O.main+O.closer,passageLinkPeek:"[[",legacyLink:O.opener+O.legacyText+O.legacySeparator+O.legacyText+O.closer,legacyLinkPeek:"[[",simpleLink:O.opener+O.legacyText+O.closer,simpleLinkPeek:"[[",macroFront:F.opener+a(F.name),macroFrontPeek:"(",macroName:F.name,groupingFront:"\\("+o(F.name),groupingFrontPeek:"(",groupingBack:"\\)",twine1Macro:D,twine1MacroPeek:"<<",property:C,propertyPeek:"'s",belongingProperty:A,possessiveOperator:E,belongingOperator:N,belongingOperatorPeek:"of",itsOperator:I,itsOperatorPeek:"its",belongingItOperator:L,belongingItOperatorPeek:"of",variable:k,variablePeek:"$",tempVariable:B,tempVariablePeek:"_",hookRef:"\\?("+p+"+)\\b",hookRefPeek:"?",cssTime:"(\\d+\\.?\\d*|\\d*\\.?\\d+)(m?s)"+c,colour:i(i("Red","Orange","Yellow","Lime","Green","Cyan","Aqua","Blue","Navy","Purple","Fuchsia","Magenta","White","Gray","Grey","Black"),"#[\\dA-Fa-f]{3}(?:[\\dA-Fa-f]{3})?"),number:V,boolean:i("true","false")+c,identifier:_,itsProperty:P,itsPropertyPeek:"its",belongingItProperty:M,escapedStringChar:"\\\\[^\\n]",singleStringOpener:"'",doubleStringOpener:'"',is:"is"+o(u+"not",u+"in",u+"<",u+">")+c,isNot:"is"+u+"not"+c,and:"and"+c,or:"or"+c,not:"not"+c,inequality:"((?:is(?:"+u+"not)?"+s+")*)("+i("<(?!=)","<=",">(?!=)",">=")+")",isIn:"is"+u+"in"+c,contains:"contains"+c,addition:e("+")+o("="),subtraction:e("-")+o("="),multiplication:e("*")+o("="),division:i("/","%")+o("="),comma:",",spread:"\\.\\.\\."+o("\\."),to:i("to"+c,"="),into:"into"+c,making:"making"+c,where:"where"+c,via:"via"+c,with:"with"+c,each:"each"+c,augmentedAssign:i("\\+","\\-","\\*","\\/","%")+"=",incorrectOperator:q},"object"===("undefined"==typeof module?"undefined":_typeof(module))?module.exports=r:"function"==typeof define&&define.amd?define("patterns",[],function(){return r}):this&&this.loaded?(this.modules||(this.modules={}),this.modules.Patterns=r):this.Patterns=r}.call(eval("this")||("undefined"!=typeof global?global:window)),function(){function e(e){function t(e){return e=e||"innerText",function(t){var n=t.reduceRight(function(e,t,n){return e||(n?t:"")},""),r={};return r[e]=n,r}}function r(e,t){var n={};return n[e]=t,function(){return{isFront:!0,matches:n,cannotCross:["verbatimOpener"]}}}function i(e,t){return Object.keys(t).forEach(function(n){var r=t[n].fn;t[n].fn=function(t){var i=r(t);return i.text||(i.text=t[0]),i.type||(i.type=n),i.innerMode||(i.innerMode=e),i}}),t}var o=Object.bind(0,null),a=[],s=[],u=i(a,{hr:{fn:o},bulleted:{fn:function(e){return{depth:e[1].length,innerText:e[2]}}},numbered:{fn:function(e){return{depth:e[1].length/2,innerText:e[2]}}},heading:{fn:function(e){return{depth:e[1].length,innerText:e[2]}}},align:{fn:function(e){var t=void 0,n=e[1],r=n.indexOf("><");return~r?(t=Math.round(r/(n.length-2)*50),25===t&&(t="center")):"<"===n[0]&&">"===n.slice(-1)?t="justify":n.indexOf(">")>-1?t="right":n.indexOf("<")>-1&&(t="left"),{align:t}}},column:{fn:function(e){var t=void 0,n=e[1],r=n.indexOf("|");return r&&r<n.length-1?t="center":"|"===n[0]&&"|"===n.slice(-1)?t="none":r===n.length-1?t="right":r||(t="left"),{column:t,width:/\|+/.exec(n)[0].length,marginLeft:/^=*/.exec(n)[0].length,marginRight:/=*$/.exec(n)[0].length}}}});Object.keys(u).forEach(function(e){u[e].canFollow=[null,"br","hr","bulleted","numbered","heading","align"],u[e].cannotFollow=["text"]});var c=i(a,{twine1Macro:{fn:function(){return{type:"error",message:"Harlowe macros use a different syntax to Twine 1 and SugarCube macros."}}},emBack:{fn:function(){return{matches:{emFront:"em"},cannotCross:["verbatimOpener"]}}},strongBack:{fn:function(){return{matches:{strongFront:"strong"},cannotCross:["verbatimOpener"]}}},strongFront:{fn:function(){return{isFront:!0}}},emFront:{fn:function(){return{isFront:!0}}},boldOpener:{fn:r("boldOpener","bold")},italicOpener:{fn:r("italicOpener","italic")},strikeOpener:{fn:r("strikeOpener","strike")},supOpener:{fn:r("supOpener","sup")},commentFront:{fn:function(){return{isFront:!0}}},commentBack:{fn:function(){return{matches:{commentFront:"comment"}}}},scriptStyleTag:{fn:o},tag:{fn:o},url:{fn:o},hookPrependedFront:{fn:function(e){return{name:e[1],hidden:")"===e[2],isFront:!0,tagPosition:"prepended"}}},hookFront:{fn:function(){return{isFront:!0}}},hookBack:{fn:function(){return{matches:{hookPrependedFront:"hook",hookFront:"hook"},cannotCross:["verbatimOpener"]}}},hookAppendedBack:{fn:function(e){return{name:e[2],hidden:"("===e[1],tagPosition:"appended",matches:{hookFront:"hook"},cannotCross:["verbatimOpener"]}}},verbatimOpener:{fn:function(e){var t=e[0].length,n={};return n["verbatim"+t]="verbatim",{type:"verbatim"+t,isFront:!0,matches:n}}},collapsedFront:{fn:function(){return{isFront:!0}}},collapsedBack:{fn:function(){return{matches:{collapsedFront:"collapsed"},cannotCross:["verbatimOpener"]}}},escapedLine:{fn:o},legacyLink:{fn:function(e){return{type:"twineLink",innerText:e[1],passage:e[2]}}},br:{fn:o}}),l=i(s,{macroFront:{fn:function(e){return{isFront:!0,name:e[1]}}},groupingBack:{fn:function(){return{matches:{groupingFront:"grouping",macroFront:"macro"},cannotCross:["singleStringOpener","doubleStringOpener"]}}},passageLink:{fn:function(e){var t=e[1],n=e[2],r=e[3];return{type:"twineLink",innerText:n?r:t,passage:t?r:n}}},simpleLink:{fn:function(e){return{type:"twineLink",innerText:e[1],passage:e[1]}}},variable:{fn:t("name")},tempVariable:{fn:t("name")}}),f=i(s,Object.assign({macroName:{canFollow:["macroFront"],fn:function(e){return e[2]?{isMethodCall:!0,innerText:e[2]}:{isMethodCall:!1}}},groupingFront:{fn:function(){return{isFront:!0}}},property:{fn:t("name"),canFollow:["variable","hookRef","property","tempVariable","colour","itsProperty","belongingItProperty","macro","grouping","string","boolean","number"]},possessiveOperator:{
-fn:o},itsProperty:{cannotFollow:["text"],fn:t("name")},itsOperator:{cannotFollow:["text"],fn:o},belongingItProperty:{cannotFollow:["text"],fn:t("name")},belongingItOperator:{cannotFollow:["text"],fn:o},belongingProperty:{cannotFollow:["text"],fn:t("name")},belongingOperator:{cannotFollow:["text"],fn:o},escapedStringChar:{fn:function(){return{type:"text"}}},singleStringOpener:{fn:function(){return{isFront:!0,matches:{singleStringOpener:"string"}}}},doubleStringOpener:{fn:function(){return{isFront:!0,matches:{doubleStringOpener:"string"}}}},hookRef:{fn:t("name")},cssTime:{fn:function(e){return{value:+e[1]*("s"===e[2].toLowerCase()?1e3:1)}}},colour:{cannotFollow:["text"],fn:function(e){var t,n=e[0].toLowerCase(),r={red:"e61919",orange:"e68019",yellow:"e5e619",lime:"80e619",green:"19e619",cyan:"19e5e6",aqua:"19e5e6",blue:"197fe6",navy:"1919e6",purple:"7f19e6",fuchsia:"e619e5",magenta:"e619e5",white:"fff",black:"000",gray:"888",grey:"888"};return t=Object.hasOwnProperty.call(r,n)?"#"+r[n]:n,{colour:t}}},number:{fn:function(e){return{value:parseFloat(e[0])}}},addition:{fn:o},subtraction:{fn:o},multiplication:{fn:o},division:{fn:o},inequality:{fn:function(e){return{operator:e[2],negate:e[1].indexOf("not")>-1}}},augmentedAssign:{fn:function(e){return{operator:e[0][0]}}},identifier:{fn:t("name"),cannotFollow:["text"]},whitespace:{fn:o,cannotFollow:"text"},incorrectOperator:{fn:function(e){var t={"=>":">=","=<":"<=",gte:">=",lte:"<=",gt:">",lt:"<",eq:"is",isnot:"is not",neq:"is not",are:"is",x:"*"}[e[0].toLowerCase()];return{type:"error",message:"Please say "+(t?"'"+t+"'":"something else")+" instead of '"+e[0]+"'."}},cannotFollow:"text"}},["boolean","is","to","into","where","via","with","making","each","and","or","not","isNot","contains","isIn"].reduce(function(e,t){return e[t]={fn:o,cannotFollow:["text"]},e},{}),["comma","spread","addition","subtraction","multiplication","division"].reduce(function(e,t){return e[t]={fn:o},e},{})));a.push.apply(a,_toConsumableArray(Object.keys(u)).concat(_toConsumableArray(Object.keys(l)),_toConsumableArray(Object.keys(c)))),s.push.apply(s,_toConsumableArray(Object.keys(l)).concat(_toConsumableArray(Object.keys(f))));var p=Object.assign({},u,c,l,f);return Object.keys(p).forEach(function(e){var t=n[e];p[e].pattern="string"!=typeof t?t:new RegExp("^(?:"+t+")","i"),n[e+"Peek"]&&(p[e].peek=n[e+"Peek"])}),Object.assign(e.rules,p),e.modes.start=e.modes.markup=a,e.modes.macro=s,e}function t(t){return Object.freeze({lex:e(t).lex,Patterns:n})}var n=void 0;Object.assign=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},"object"===("undefined"==typeof module?"undefined":_typeof(module))?(n=require("./patterns"),module.exports=t(require("./lexer"))):"function"==typeof define&&define.amd?define("markup",["lexer","patterns"],function(e,r){return n=r,t(e)}):this&&this.loaded&&this.modules?(n=this.modules.Patterns,this.modules.Markup=t(this.modules.Lexer)):(n=this.Patterns,this.TwineMarkup=t(this.TwineLexer))}.call(eval("this")||("undefined"!=typeof global?global:window)),define("utils/selectors",[],function(){return Object.freeze({passage:"tw-passage",story:"tw-story",sidebar:"tw-sidebar",internalLink:"tw-link",brokenLink:"tw-broken-link",hook:"tw-hook",enchantment:"tw-enchantment",expression:"tw-expression",script:"[role=script]",stylesheet:"[role=stylesheet]",storyData:"tw-storydata",passageData:"tw-passagedata",collapsed:"tw-collapsed"})}),define("utils/polyfills",[],function(){var e=Array.prototype;"function"!=typeof e.includes&&(e.includes=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(!Number.isNaN(t)&&Number.isFinite(n)&&"undefined"!=typeof t)return e.indexOf.call(this,t,n)>-1;var r=Object(this),i=parseInt(r.length);if(0>=i)return!1;for(var o=n>=0?n:Math.max(0,i+n);i>o;){if(Object.is(t,r[o]))return!0;o+=1}return!1})}),define("utils",["jquery","markup","utils/selectors","utils/polyfills"],function(e,t,n){function r(t,n){var r=o[n];if(!r[t]){var i=e("<p>").appendTo(document.body).attr("data-t8n",t).addClass(n);r[t]=c.cssTimeUnit(i.css("animation-duration"))+c.cssTimeUnit(i.css("animation-delay")),i.remove()}return r[t]}var i={configurable:0,writable:0},o={"transition-in":Object.create(null),"transition-out":Object.create(null)},a="audio,blockquote,canvas,div,h1,h2,h3,h4,h5,hr,ol,p,pre,table,ul,video,tw-align,tw-story,tw-passage".split(","),s="a,b,i,em,strong,sup,sub,abbr,acronym,s,strike,del,big,small,script,img,button,input,tw-link,tw-broken-link,tw-verbatim,tw-collapsed,tw-error".split(","),u=["audio"],c=void 0,l=void 0;return c={lockProperty:function(e,t,n){var r=Object.create(i);return n&&(r.value=n),Object.defineProperty(e,t,r),e},toJSLiteral:function(e){return e instanceof Map?"(new Map("+c.toJSLiteral([].concat(_toConsumableArray(e.entries())))+"))":e instanceof Set?"(new Set("+c.toJSLiteral([].concat(_toConsumableArray(e.values())))+"))":JSON.stringify(e)},cssTimeUnit:function(e){return e=e.toLowerCase(),"ms"===e.slice(-2)?+e.slice(0,-2)||0:"s"===e.slice(-1)?1e3*+e.slice(0,-1)||0:0},nth:function(e){var t=(+e+"").slice(-1);return e+("1"===t?"st":"2"===t?"nd":"3"===t?"rd":"th")},plural:function(e,t){return e+" "+t+(e>1?"s":"")},andList:function(e){return 1===e.length?e[0]:e.slice(0,-1).join(", ")+" and "+e[e.length-1]},realWhitespace:"[ \\n\\r\\f\\t\\v\\u00a0\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000]",anyRealLetter:"[\\dA-Za-z\\u00c0-\\u00de\\u00df-\\u00ff\\u0150\\u0170\\u0151\\u0171\\uD800-\\uDFFF]",unescape:function(e){return e.replace(/&(?:amp|lt|gt|quot|nbsp|zwnj|#39|#96);/g,function(e){return{"&amp;":"&","&gt;":">","&lt;":"<","&quot;":'"',"&#39;":"'","&nbsp;":String.fromCharCode(160),"&zwnj;":String.fromCharCode(8204)}[e]})},escape:function(e){return e.replace(/[&><"']/g,function(e){return{"&":"&amp;",">":"&gt;","<":"&lt;",'"':"&quot;","'":"&#39;"}[e]})},insensitiveName:function(e){return(e+"").toLowerCase().replace(/-|_/g,"")},childrenProbablyInline:function(e){var t=[];return Array.prototype.every.call(e.find("*"),function(e){return e.hidden||/none|inline/.test(e.style.display)?!0:a.includes(e.tagName.toLowerCase())||/none|inline/.test(e.style.display)?!1:s.includes(e.tagName.toLowerCase())?!0:(t.push(e),!0)})&&t.every(function(e){return/none|inline/.test(e.style.display)})},transitionReplace:function(t,r,i){var o=t.closest(n.hook);o.length>0&&(t=o);var a=e("<tw-transition-container>").css("position","relative");a.insertBefore(t.first());var s=void 0;r&&(s=e("<tw-transition-container>").appendTo(a),r.appendTo(s));var u=e("<tw-transition-container>").css("position","absolute").prependTo(a);t.detach().appendTo(u),c.transitionOut(u,i),r&&c.transitionIn(s,i,function(){s.unwrap().children().first().unwrap()})},transitionOut:function(e,t,n){function i(){e.remove()}var o=c.childrenProbablyInline(e),a=e.length>1||!o||!["tw-hook","tw-passage"].includes(e.tag());a&&(e=e.wrapAll("<tw-transition-container>").parent()),e.attr("data-t8n",t).addClass("transition-out"),c.childrenProbablyInline(e)&&e.css("display","inline-block"),"number"==typeof n&&e.css("animation-duration",n+"ms");var s=n||r(t,"transition-out");s?window.setTimeout(i,s):i()},transitionIn:function(e,t,n){function i(){var t=0===e.findAndFilter(u.join(",")).length;a&&t?e.contents().unwrap():e.removeClass("transition-in").removeAttr("data-t8n")}var o=c.childrenProbablyInline(e),a=e.length>1||!o||!["tw-hook","tw-passage"].includes(e.tag());a&&(e=e.wrapAll("<tw-transition-container>").parent()),e.attr("data-t8n",t).addClass("transition-in"),"number"==typeof n&&e.css("animation-duration",n+"ms"),c.childrenProbablyInline(e)&&e.css("display","inline-block");var s=n||r(t,"transition-in");s?window.setTimeout(i,s):i()},$:function(t,n){return e(t,n||c.storyElement).not(".transition-out, .transition-out *")},impossible:function(e,t){window.console&&console.error(e+"(): "+t)},assertMustHave:function(e,t){if(window.console)for(var n=0;n<t.length;n+=1)t[n]in e||console.error("Assertion failed: object lacks property "+t[n])},assertOnlyHas:function(e,t){if(window.console)for(var n in e)t.includes(n)||console.error("Assertion failed: object had unexpected property '"+n+"'!")},get storyElement(){return l}},e(function(){return l=e(n.story)}),Object.freeze(c)}),define("passages",["jquery","utils","utils/selectors"],function(e,t,n){function r(e){return Object.assign(new Map([["source",i(e.html())],["tags",(e.attr("tags")||"").split(/\s/)||[]],["name",e.attr("name")]]),{TwineScript_TypeName:"passage datamap",TwineScript_ObjectName:"a passage datamap"})}var i=t.unescape,o=Object.assign(new Map,{TwineScript_ObjectName:"the Passages datamap",getTagged:function(e){var t=[];return this.forEach(function(n){var r=n instanceof Map&&n.get("tags");Array.isArray(r)&&r.includes(e)&&t.push(n)}),t.sort(function(e,t){return e.get("name")>t.get("name")})},create:r});return e(function(){Array.from(e(n.storyData+" > "+n.passageData)).forEach(function(t){t=e(t),o.set(t.attr("name"),new r(t))})}),o}),define("datatypes/hookset",["jquery","utils","utils/selectors","markup"],function(e,t,n,r){function i(e,t,n){var r=e.textContent.length;if(!(t>=r)){var i=void 0,o=[i=0===t?e:e.splitText(t)];return n&&(0>=n&&(n=r-n),r>n&&o.push(i.splitText(n-t))),o}}function o(e,t){var n=[],r="",a=[];if(!e.length||!t)return a;for(;e.length>0;){n.push(e[0]),r+=e[0].textContent,e.shift();var s=r.indexOf(t);if(s>-1){for(var u,c=r.length-(s+t.length);s>=n[0].textContent.length;)s-=n[0].textContent.length,n.shift();if(1===n.length){var l=i(n[0],s,s+t.length);a.push(l[0]),l[1]&&e.unshift(l[1]);break}a.push(i(n[0],s,n[0].length)[0]),(u=a).push.apply(u,_toConsumableArray(n.slice(1,-1)));var f=i(n[n.length-1],0,n[n.length-1].textContent.length-c);a.push(f[0]),f[1]&&e.unshift(f[1]),a=a.filter(Boolean);break}}return[a].concat(_toConsumableArray(o(e,t)))}function a(t,n,r){var i=o(n.textNodes(),t),a=e();return i.forEach(function(t){a=a.add(e(t).wrapAll(r))}),a.parent()}function s(e){e=t.insensitiveName(e).replace(/\?/g,"").replace(/"/g,"&quot;");var r=n.hook+'[name="'+e+'"]';return r+={page:", tw-story",passage:", tw-passage",sidebar:", tw-sidebar",link:", tw-link, .enchantment-link"}[e]||""}function u(n){var r=n.dom,i=e();this.prev&&(i=i.add(u.call(this.prev,{dom:r})));var o=function(t,n){return Array.isArray(n)?n.reduce(function(e,n){return e.add(t.get(n))},e()):e(t.get(n))};if(this.selector){var c=void 0;c=this.selector.match("^"+f.hookRef+"$")?r.add(r.parentsUntil(t.storyElement.parent())).findAndFilter(s(this.selector)):a(this.selector,r,"<tw-pseudo-hook>"),i=i.add(this.properties.length?this.properties.reduce(o,c):c)}return this.base&&(i=i.add(this.properties.reduce(o,u.call(this.base,{dom:r})))),i}function c(e){var n=e.dom;t.$("tw-pseudo-hook",n).contents().unwrap().parent().each(function(){this.normalize()})}function l(e){if(!e)return[];var n=e.selector,r=e.base,i=e.properties,o=e.prev;return[JSON.stringify([t.insensitiveName(n)||"",l(r),[].concat(_toConsumableArray(i)).sort()])].concat(_toConsumableArray(l(o))).sort()}var f=r.Patterns,p=Object.freeze({forEach:function(t,n){var r=u.call(this,t).each(function(t){n(e(this),t)});return c.call(this,t),r},get TwineScript_ObjectName(){return this.properties.length>0||this.prev?"a complex hook name":this.selector+" (a hook name)"},TwineScript_TypeName:"a hook name (like ?this)",TwineScript_Unstorable:!0,"TwineScript_+":function(e){var t=e.TwineScript_Clone();return t.prev=this,t},TwineScript_is:function(e){return l(this)+""==l(e)+""},TwineScript_GetElement:function(e){return p.create(void 0,this,[e],void 0)},TwineScript_Clone:function(){return p.create(this.selector,this.base,this.properties,this.prev)},create:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:void 0;return Object.assign(Object.create(this||p),{selector:e,base:t,properties:n,prev:r})},from:function(e){return p.isPrototypeOf(e)?e:p.create(e)}});return p}),define("internaltypes/twineerror",["jquery","utils"],function(e,t){var n=t.impossible,r=t.escape,i={syntax:"The markup seems to contain a mistake.",saving:"I tried to save or load the game, but I couldn't do it.",operation:"I tried to perform an operation on some data, but the data's type was incorrect.",macrocall:"I tried to use a macro, but its call wasn't written correctly.",datatype:"I tried to use a macro, but was given the wrong type of data to it.",keyword:"I was given a keyword in a way that I didn't understand.",infinite:"I almost ended up doing the same thing over and over, forever.",property:"I tried to access a value in a string/array/datamap, but I couldn't find it.",unimplemented:"I currently don't have this particular feature. I'm sorry.",javascript:"This error message was reported by your browser's Javascript engine. I don't understand it either, but it usually means that an expression was badly written."},o={create:function(e,t,r){return t||n("TwineError.create","called with only 1 string."),r||e in i||n("TwineError.create","no error explanation given"),Object.assign(Object.create(this),{type:e,message:t,explanation:r})},fromError:function(e){return o.create("javascript","\u2615 "+e.message)},containsError:function(){for(var e=arguments.length,t=Array(e),n=0;e>n;n++)t[n]=arguments[n];return t.reduce(function(e,t){return e?e:t instanceof Error?t:o.isPrototypeOf(t)?t:Array.isArray(t)?o.containsError.apply(o,_toConsumableArray(t)):!1},!1)},createWarning:function(e,t){return Object.assign(this.create(e,t),{warning:!0})},render:function(t){t=t||"";var n=e("<tw-error class='"+("javascript"===this.type?"javascript ":"")+(this.warning?"warning":"error")+"' title='"+r(t)+"'>"+r(this.message)+"</tw-error>"),o=e("<tw-error-explanation>").text(this.explanation||i[this.type]).hide(),a=e("<tw-error-explanation-button tabindex=0>").html("<span class='folddown-arrowhead'>&#9658;</span>");return a.on("click",function(){o.toggle(),a.children(".folddown-arrowhead").css("transform","rotate("+(o.is(":visible")?"90deg":"0deg")+")")}),n.append(a).append(o),n}};return o}),define("utils/operationutils",["utils","datatypes/hookset","internaltypes/twineerror"],function(e,t,n){function r(e){return!!e&&("object"===("undefined"==typeof e?"undefined":_typeof(e))||"function"==typeof e)}function i(e){return Array.isArray(e)?"array":e instanceof Map?"datamap":e instanceof Set?"dataset":"string"==typeof e?"string":e&&"object"===("undefined"==typeof e?"undefined":_typeof(e))?"object":""}function o(e,t){if(e instanceof Map||g("isValidDatamapName","called with non-Map"),"string"!=typeof t&&"number"!=typeof t)return n.create("property","Only strings and numbers can be used as data names for "+l(e)+", not "+l(t)+".");var r="string"==typeof t?+t:""+t;return!Number.isNaN(r)&&e.has(r)?n.create("property","You mustn't use both "+l(t)+" and "+l(r)+" as data names in the same datamap."):!0}function a(e,t){if(null===t)return void 0===e;if(t.innerType){if("optional"===t.pattern||"zero or more"===t.pattern)return void 0===e?!0:a(e,t.innerType);if("either"===t.pattern)return t.innerType.some(function(t){return a(e,t)});if("lambda"===t.pattern&&a(e,t.innerType))return"string"!=typeof t.clauses&&g("singleTypeCheck","lambda signature had non-string clauses"),t.clauses.includes("where")==="where"in e&&t.clauses.includes("making")==="making"in e&&t.clauses.includes("via")==="via"in e&&t.clauses.includes("with")==="with"in e;if("wrapped"===t.pattern)return a(e,t.innerType)}return void 0!==t&&void 0===e?!1:"anything"!==t.TwineScript_TypeName||void 0===e||e.TwineScript_Unstorable?t===String?"string"==typeof e:t===Boolean?"boolean"==typeof e:t===parseInt?"number"==typeof e&&!Number.isNaN(e)&&!(e+"").includes("."):t===Number?"number"==typeof e&&!Number.isNaN(e):t===Array?Array.isArray(e):t===Map||t===Set?e instanceof t:Object.isPrototypeOf.call(t,e):!0}function s(e){return"string"==typeof e||Array.isArray(e)||t.isPrototypeOf(e)}function u(e){if(!r(e))return e;if("function"==typeof e.TwineScript_Clone)return e.TwineScript_Clone();if(Array.isArray(e))return[].concat(_toConsumableArray(e));if(e instanceof Map)return new Map(e);if(e instanceof Set)return new Set(e);if("function"==typeof e)return Object.assign(e.bind(),e);switch(Object.getPrototypeOf(e)){case Object.prototype:return Object.assign({},e);case null:return Object.assign(Object.create(null),e)}return g("OperationUtils.clone","The value "+(e.toSource?e.toSource():e)+" cannot be cloned!"),e}function c(e,t,n){return"string"==typeof t&&r(n)&&"TwineScript_ToString"in n?e(t,n.TwineScript_ToString()):"string"==typeof n&&r(t)&&"TwineScript_ToString"in t?e(t.TwineScript_ToString(),n):!1}function l(e){return r(e)&&"TwineScript_ObjectName"in e?e.TwineScript_ObjectName:Array.isArray(e)?"an array":e instanceof Map?"a datamap":e instanceof Set?"a dataset":"boolean"==typeof e?"the boolean value '"+e+"'":"string"==typeof e||"number"==typeof e?"the "+("undefined"==typeof e?"undefined":_typeof(e))+" "+y(e):void 0===e?"an empty variable":"...whatever this is"}function f(e){return e.innerType?"either"===e.pattern?(Array.isArray(e.innerType)||g("typeName",'"either" pattern had non-array inner type'),e.innerType.map(f).join(" or ")):"optional"===e.pattern?"(an optional) "+f(e.innerType):f(e.innerType):e===String||e===Number||e===Boolean?"a "+_typeof(e()):e===parseInt?"a non-fractional number":e===Map?"a datamap":e===Set?"a dataset":e===Array?"an array":r(e)&&"TwineScript_TypeName"in e?e.TwineScript_TypeName:l(e)}function p(e,t){return"object"!==("undefined"==typeof e?"undefined":_typeof(e))&&"object"!==("undefined"==typeof t?"undefined":_typeof(t))?e===t:Array.isArray(e)&&Array.isArray(t)?e.length!==t.length?!1:e.every(function(e,n){return p(t[n],e)}):e instanceof Map&&t instanceof Map?p(Array.from(e.entries()).sort(),Array.from(t.entries()).sort()):e instanceof Set&&t instanceof Set?p([].concat(_toConsumableArray(e)),[].concat(_toConsumableArray(t))):e&&"function"==typeof e.TwineScript_is?e.TwineScript_is(t):e&&"object"===("undefined"==typeof e?"undefined":_typeof(e))&&t&&"object"===("undefined"==typeof t?"undefined":_typeof(t))&&Object.getPrototypeOf(e)===Object.prototype&&Object.getPrototypeOf(t)===Object.prototype?p(Object.getOwnPropertyNames(e).map(function(t){return[t,e[t]]}),Object.getOwnPropertyNames(t).map(function(e){return[e,t[e]]})):Object.is(e,t)}function d(e,t){if(e){if("string"==typeof e)return e.includes(t);if(Array.isArray(e))return e.some(function(e){return p(e,t)});if(e instanceof Set||e instanceof Map)return Array.from(e.keys()).some(function(e){return p(e,t)})}return n.create("operation",l(e)+" cannot contain any values, let alone "+l(t))}function h(e,t,r){if(!t||!r)return n.create("macrocall","The sub"+i(e)+" index values must not be 0 or NaN.");if(0>t&&(t=e.length+t+1),0>r&&(r=e.length+r+1),t>r)return h(e,r,t);var o="string"==typeof e;o&&(e=Array.from(e));var a=e.slice(t>0?t-1:t,r).map(u);return o?a.join(""):a}function m(e){return n.containsError(e)?e:e&&"function"==typeof e.TwineScript_Print?e.TwineScript_Print():e instanceof Map?(e=Array.from(e.entries()),n.containsError(e)?e:e.reduce(function(e,t){var n=_slicedToArray(t,2),r=n[0],i=n[1];return e+"<tr><td>`"+m(r)+"`</td><td>`"+m(i)+"`</td></tr>"},"<table class=datamap>")+"</table>"):e instanceof Set?Array.from(e.values()).map(m)+"":Array.isArray(e)?e.map(m)+"":r(e)?n.create("unimplemented","I don't know how to print this value yet."):e+""}var g=e.impossible,y=e.toJSLiteral,v=Object.freeze({isObject:r,singleTypeCheck:a,isValidDatamapName:o,collectionType:i,isSequential:s,clone:u,coerceToString:c,objectName:l,typeName:f,is:p,contains:d,subset:h,printBuiltinValue:m,numericIndex:/^(?:[1-9]\d*|0)$/,unique:function(e,t,n){return!n.slice(t+1).some(function(t){return p(e,t)})}});return v}),define("twinescript/compiler",["utils"],function(e){function t(e,t){for(var n=0;n<e.length;n+=1)if(t.includes(e[n].type))return n;return 0/0}function n(e,n){return e.length-1-t.apply(void 0,[[].concat(_toConsumableArray(e)).reverse(),n])}function r(e,r){var i=[];return e.length?([["error"],["comma"],["spread"],["to"],["into"],{rightAssociative:["where","via"]},{rightAssociative:["with","making","each"]},["augmentedAssign"],["and","or"],["is","isNot"],["contains","isIn"],["inequality"],["addition","subtraction"],["multiplication","division"],["not"],["belongingProperty"],["belongingOperator","belongingItOperator"],{rightAssociative:["property"]},{rightAssociative:["itsProperty"]},["belongingItProperty"],{rightAssociative:["possessiveOperator","itsOperator"]},["twineLink"],["macro"],["grouping"]]["most"===r?"reverse":"valueOf"]().some(function(r){var o=void 0;return o=r.rightAssociative?n(e,r.rightAssociative):t(e,r),!Number.isNaN(o)&&o>-1?(i=[e[o],o],!0):void 0}),i):i}function i(e){if("inequality"===e.type){var t=e.operator;return e.negate?{">":"<=","<":">=",">=":"<","<=":">"}[t]:t}return e.type}function o(e){var t=i(e);return{">":"<","<":">",">=":"<=","<=":">=",contains:"isIn",isIn:"contains",is:"isNot",isNot:"is"}[t]}function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.isVarRef,c=t.whitespaceError,l=t.elidedComparison;if(e=[].concat(e),!e.length)return n&&c?"TwineError.create('operation',"+s(c)+")":"";var f=e[0];if(1===e.length){if("identifier"===f.type)return n?"VarRef.create(Operations.Identifiers,"+s(f.text)+")":" Operations.Identifiers."+f.text.toLowerCase()+" ";if("variable"===f.type)return"VarRef.create(State.variables,"+s(f.name)+")"+(n?"":".get()");if("tempVariable"===f.type)return"VarRef.create(section.stack[0].tempVariables,"+s(f.name)+")"+(n?"":".get()");if("hookRef"===f.type)return" HookSet.create('?"+f.name+"') ";if("string"===f.type)return f.text.replace(/\n/g,"\\n");if("colour"===f.type)return"Colour.create("+s(f.colour)+")";if("root"===f.type)return a(f.children);if("whitespace"===f.type&&n&&c)return"TwineError.create('operation',"+s(c)+")"}var p=void 0,d=r(e,"least"),h=_slicedToArray(d,2);f=h[0],p=h[1];var m=(f||{}).type,g=function(e){return{isVarRef:!0,whitespaceError:"I need usable data to be on the "+e+' of "'+f.text+'".'}},y=void 0,v=void 0,b=void 0,w=void 0,x=void 0,T=void 0,S=!0,O=!0,j=!1;if(m){if("error"===m)return"TwineError.create('syntax',"+s(f.message)+")";if("comma"===m)b=",",O=!1;else if("spread"===m)b="Operations.makeSpreader(",v=a(e.slice(p+1))+")",S=!1;else if("to"===m)x="to",v=a(e.slice(p+1),g("right")),y="Operations.setIt("+a(e.slice(0,p),g("left"))+")";else if("into"===m)x="into",v=a(e.slice(0,p),g("left")),y="Operations.setIt("+a(e.slice(p+1),g("right"))+")";else if("where"===m||"via"===m)y="Lambda.create("+(a(e.slice(0,p),{isVarRef:!0,whitespaceError:null}).trim()||"undefined")+",",b=s(f.type)+",",v=s(a(e.slice(p+1)))+")";else if("with"===m||"making"===m||"each"===m){var k=e.slice(p+1);![2,3].includes(k.length)||"whitespace"!==k[0].type||"tempVariable"!==k[1].type||k[2]&&"whitespace"!==k[2].type?(y="TwineError.create('operation','I need a temporary variable to the right of \\'",b=f.type,v="\\'.')"):"each"===m?(y="Lambda.create(",b=a(k,g("right")).trim(),v=",'where','true')"):(y="Lambda.create("+(a(e.slice(0,p),{isVarRef:!0,whitespaceError:null}).trim()||"undefined")+",",b=s(f.type)+",",v=s(k[1].name)+")")}else if("augmentedAssign"===m)x=f.operator,y=a(e.slice(0,p),g("left")),v="Operations['"+x+"']("+(a(e.slice(0,p))+","+a(e.slice(p+1)))+")";else if("and"===m||"or"===m){var C=function(){var t=function e(t){var n=r(t,"least"),i=_slicedToArray(n,2),o=i[0],a=i[1];if(o)return["inequality","is","isNot","isIn","contains"].includes(o.type)?o:["and","or"].includes(o.type)?e(t.slice(0,a))||e(t.slice(a+1)):void 0},u=t(e.slice(0,p)),c=t(e.slice(p+1)),d="TwineError.create('operation', 'This use of \"is not\" and \""+m+"\" is grammatically ambiguous','Maybe try rewriting this as \"__ is not __ "+m+" __ is not __\"') ";if(w=f.type,l===f.type)w="",y=a(e.slice(0,p),{isVarRef:n,elidedComparison:l}).trim(),b=",",v=a(e.slice(p+1),{elidedComparison:l}).trim();else if(u&&!c){var h=r(e.slice(0,p),"least"),g=_slicedToArray(h,1),x=g[0],T=s(i(x));if("isNot"===x.type)return{v:d};v="Operations.elidedComparisonOperator("+s(f.type)+","+T+","+a(e.slice(p+1),{elidedComparison:m})+")"}else if(!u&&c){var S=c,O=e.indexOf(S),j=s(o(S));if("isNot"===S.type)return{v:d};v="Operations.elidedComparisonOperator("+s(f.type)+","+j+","+a(e.slice(0,p),{elidedComparison:m})+")",y=a([].concat(_toConsumableArray(e.slice(O+1)),[Object.assign(Object.create(S),_defineProperty({},"inequality"===S.type?"operator":"type",o(S)))],_toConsumableArray(e.slice(p+1,O))))}}();if("object"===("undefined"==typeof C?"undefined":_typeof(C)))return C.v}else if("is"===m||"isNot"===m||"contains"===m||"isIn"===m||"inequality"===m)j=!0,w=i(f);else if("addition"===m||"subtraction"===m)w=f.text,y=a(e.slice(0,p)),y.trim()||(y="0");else if("multiplication"===m||"division"===m)w=f.text;else if("not"===m)b=" ",v="Operations.not("+a(e.slice(p+1))+")",S=!1;else if("belongingProperty"===m)v="VarRef.create("+a(e.slice(p+1),g("right"))+","+s(f.name)+")"+(n?"":".get()"),b=" ",S=O=!1;else if("belongingOperator"===m||"belongingItOperator"===m)f.type.includes("It")?(v="Operations.Identifiers.it",O=!1):v=a(e.slice(p+1),g("right")),T="belonging";else if("property"===m)y="VarRef.create("+a(e.slice(0,p),g("left"))+","+s(f.name)+")"+(n?"":".get()"),b=" ",S=O=!1;else if("itsProperty"===m||"belongingItProperty"===m)y="VarRef.create(Operations.Identifiers.it,"+s(f.name)+").get()",b=" ",S=O=!1;else if("possessiveOperator"===m||"itsOperator"===m)f.type.includes("it")&&(y="Operations.Identifiers.it",S=!1),T="possessive";else if("twineLink"===m)b='Macros.run("link-goto", [section,'+s(f.innerText)+","+s(f.passage)+"])",S=O=!1;else if("macro"===m){var A=f.children[0];"macroName"!==A.type&&u("Compiler.compile","macro token had no macroName child token"),b="Macros.run("+(A.isMethodCall?a(A.children):'"'+f.name+'"')+", [section,"+a(f.children.slice(1))+"])",S=O=!1}else"grouping"===m&&(b="("+a(f.children,{isVarRef:n})+")",S=O=!1)}else;return p>-1?(w&&(n=!1),y=y||a(e.slice(0,p),{isVarRef:n}).trim(),v=v||a(e.slice(p+1)).trim(),j&&!y&&(y=" Operations.Identifiers.it "),S&&!y||O&&!v?"TwineError.create('operation','I need some code to be "+(S?"left ":"")+(S&&O?"and ":"")+(O?"right ":"")+'of "'+f.text+"\"')":b?y+b+v:x?"Operations.makeAssignmentRequest("+[y,v,s(x)]+")":T?"VarRef.create("+("belonging"===T?v:y)+",{computed:true,value:"+("belonging"===T?y:v)+"})"+(n?"":".get()"):w?" Operations["+s(w)+"]("+y+","+v+") ":""):1===e.length?(("value"in e[0]?e[0].value:e[0].text)+"").trim()||" ":e.reduce(function(e,t){return e+a(t,{isVarRef:n})},"")}var s=e.toJSLiteral,u=e.impossible;return a}),define("renderer",["utils","markup","twinescript/compiler","internaltypes/twineerror"],function(e,t,n,r){function i(e,t){return"<"+t+">"+e+"</"+t+">"}function o(e,t){var n=l.render(e.children);return n&&i(n,t)}var a=e.escape,s=e.impossible,u=e.toJSLiteral,c=e.insensitiveName,l=void 0,f="text-align: center; max-width:50%; ";return l={options:{},exec:function(){var e=void 0,n=void 0;return function(r){return"string"!=typeof r?(s("Renderer.exec","source was not a string, but "+("undefined"==typeof r?"undefined":_typeof(r))),""):r===e?n:(e=r,n=l.render(t.lex(r).children))}}(),render:function e(s){var p="",d=[];if(!s)return p;for(var h=s.length,m=0;h>m;m+=1){var g=s[m];switch(g.type){case"error":p+=r.create("syntax",g.message).render(a(g.text))[0].outerHTML;break;case"numbered":case"bulleted":var y="numbered"===g.type?"ol":"ul";p+="<"+y+">";for(var v=1;h>m&&s[m]&&s[m].type===g.type;)p+=("<"+y+">").repeat(Math.max(0,s[m].depth-v)),p+=("</"+y+">").repeat(Math.max(0,v-s[m].depth)),v=s[m].depth,p+=o(s[m],"li"),m+=1;m-=1,p+=("</"+y+">").repeat(v+1);break;case"align":for(;g&&"align"===g.type;){var b=g,w=b.align,x=m+=1;if("left"===w){m-=1;break}for(;h>m&&s[m]&&"align"!==s[m].type;)m+=1;var T=e(s.slice(x,m)),S="";switch(w){case"center":S+=f+"margin-left: auto; margin-right: auto;";break;case"justify":case"right":S+="text-align: "+w+";";break;default:+w&&(S+=f+"margin-left: "+w+"%;")}p+="<tw-align "+(S?'style="'+S+'"':"")+(l.options.debug?' title="'+g.text+'"':"")+">"+T+"</tw-align>\n",g=s[m]}break;case"column":for(var O=[];g&&"column"===g.type;){var j=g,k=j.column,C=m+=1;if("none"===k){m-=1;break}for(;h>m&&s[m]&&"column"!==s[m].type;)m+=1;O.push({text:g.text,type:k,body:e(s.slice(C,m)),width:g.width,marginLeft:g.marginLeft,marginRight:g.marginRight}),g=s[m]}O.length&&!function(){var e=O.reduce(function(e,t){return e+t.width},0);p+="<tw-columns>"+O.map(function(t){return"<tw-column type="+t.type+'  style="width:'+t.width/e*100+"%; margin-left: "+t.marginLeft+"em; margin-right: "+t.marginRight+'em;" '+(l.options.debug?' title="'+t.text+'"':"")+">"+t.body+"</tw-column>\n"}).join("")+"</tw-columns>"}();break;case"heading":p+=o(g,"h"+g.depth);break;case"br":(!d.length||/td|th/.test(d[0]))&&(p+="<br>");break;case"hr":p+="<hr>";break;case"escapedLine":case"comment":break;case"inlineUrl":p+='<a class="link" href="'+a(g.text)+'">'+g.text+"</a>";break;case"scriptStyleTag":case"tag":var A=g.text.toLowerCase();/^<\/?(?:table|thead|tbody|tr|tfoot|td|th)\b/.test(A)&&d[g.text.startsWith("</")?"shift":"unshift"](A),p+=g.text.startsWith("</")?g.text:g.text.replace(/>$/," data-raw>");break;case"sub":case"sup":case"strong":case"em":p+=o(g,g.type);break;case"strike":p+=o(g,"s");break;case"bold":p+=o(g,"b");break;case"italic":p+=o(g,"i");break;case"twineLink":var E=t.lex("(link-goto:"+u(g.innerText)+","+u(g.passage)+")");p+=e(E.children);break;case"hook":p+="<tw-hook "+(g.hidden?"hidden ":"")+(g.name?'name="'+c(g.name)+'"':"")+(l.options.debug&&g.name?' title="Hook: ?'+g.name+'"':"")+' source="'+a(g.innerText)+'"></tw-hook>';break;case"verbatim":p+=i(a(g.innerText).replace(/\n/g,"<br>"),"tw-verbatim");break;case"collapsed":p+=o(g,"tw-collapsed");break;case"variable":case"tempVariable":case"macro":p+='<tw-expression type="'+g.type+'" name="'+a(g.name||g.text)+'"'+(l.options.debug?' title="'+a(g.text)+'"':"")+' js="'+a(n(g))+'"></tw-expression>';break;default:p+=g.children&&g.children.length?e(g.children):g.text}}return p}},Object.freeze(l)}),define("internaltypes/changedescriptor",["jquery","utils","renderer","datatypes/hookset"],function(e,t,n,r){var i=t.assertOnlyHas,o=t.impossible,a=t.transitionIn,s=n.exec,u=void 0,c={source:"",innerSource:"",enabled:!0,target:null,append:"append",newTargets:null,transition:"instant",transitionTime:null,loopVars:null,styles:null,attr:null,data:null,section:null,summary:function(){var e=this;return["source","innerSource","enabled","target","append","newTargets","transition","transitionTime"].filter(function(t){return e.hasOwnProperty(t)}).concat([this.attr.length&&"attr",this.styles.length&&"styles",Object.keys(this.loopVars).length&&"loopVars",Object.keys(this.data).length&&"data"].filter(Boolean))},create:function(e,t){var n=Object.assign(Object.create(this),{attr:[].concat(this.attr||[]),styles:[].concat(this.styles||[]),loopVars:this.loopVars||{},data:this.data||{}},e);return t&&t.run(n),n},update:function(){var e=this,t=this.section,n=this.newTargets,i=this.target,o=function(t){Array.isArray(e.styles)&&e.styles.length>0&&setTimeout(function(){return t.css(Object.assign.apply(Object,_toConsumableArray([{}].concat(e.styles))))}),e.attr&&e.attr.forEach(function(e){return t.attr(e)}),e.data&&t.data(e.data)};Array.isArray(n)&&n.length&&(i=n.map(function(e){return e.target})),[].concat(i).forEach(function(e){r.isPrototypeOf(e)?e.forEach(t,o):o(e)})},render:function(){var t=this,n=this.source,l=this.transition,f=this.transitionTime,p=this.enabled,d=this.section,h=this.newTargets,m=this.target,g=this.append;if(i(this,u),!p||void 0!==m.popAttr("hidden"))return c.create({target:m,data:{hiddenSource:n}}).update(),e();if(Array.isArray(h)&&h.length&&(m=h),!m)return o("ChangeDescriptor.render","ChangeDescriptor has source but not a target!"),e();var y=e(),v=function(e){return function(n){y=y.add(t.create({target:n,append:e,
-newTargets:null}).render())}};if([].concat(m).forEach(function t(n,i,o){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:g;r.isPrototypeOf(n)?n.forEach(d,v(a)):n.jquery&&n.length>1?Array.from(n).map(e).forEach(v(a)):n.target&&n.append&&t(n.target,i,o,n.append)}),y.length||Array.isArray(m)||r.isPrototypeOf(m))return y;if(!(g in m)){if("replace"!==g)return o("Section.render","The target doesn't have a '"+g+"' method."),e();m.empty(),g="append"}return y=e(n&&e.parseHTML(s(n),document,!0)),m[g](y.length?y:void 0),this.update(),l&&a("replace"===g?m:y,l,f),y}};return u=Object.keys(c),Object.seal(c)}),define("datatypes/changercommand",["utils","utils/operationutils","internaltypes/changedescriptor"],function(e,t,n){var r=e.impossible,i=t.is,o={},a={changer:!0,TwineScript_TypeName:"a changer command",TwineScript_Print:function(){return"`[A '"+this.macroName+"' command]`"},summary:function(){var e=n.create();return this.run(e),e.summary()},create:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return Array.isArray(t)||r("ChangerCommand.create","params was not an array"),Object.assign(Object.create(this),{macroName:e,params:t,next:n,TwineScript_ObjectName:"a ("+e+":) command"})},"TwineScript_+":function(e){for(var t=this.TwineScript_Clone(),n=t;n.next;)n=n.next;return n.next=e,t},TwineScript_is:function(e){return a.isPrototypeOf(e)?this.macroName===e.macroName&&i(this.params,e.params)&&i(this.next,e.next):void 0},TwineScript_Clone:function(){return this.create(this.macroName,this.params,this.next)},run:function(e){o[this.macroName].apply(o,[e].concat(_toConsumableArray(this.params))),this.next&&this.next.run(e)},register:function(e,t){o[e]=t}};return Object.freeze(a)}),define("state",["utils","passages","datatypes/changercommand","internaltypes/twineerror","utils/operationutils"],function(e,t,n,r,i){function o(e){p=(l[f]||c).create(e)}var a=e.impossible,s=i.objectName,u={TwineScript_ObjectName:"this story's variables",TwineScript_VariableStore:!0},c={passage:"",variables:u,create:function(e,t){var n=Object.create(c);return n.passage=e||"",n.variables=Object.assign(Object.create(this.variables),t),n}},l=[],f=-1,p=c.create(),d=void 0,h={forward:[],back:[],load:[]},m=Object.assign({get passage(){return p.passage},get variables(){return p.variables},get pastLength(){return f},get futureLength(){return l.length-1-f},passageNameVisited:function(e){var n=0;if(!t.get(e))return 0;for(var r=0;f>=r;r++)n+=+(e===l[r].passage);return n},passageNameLastVisited:function(e){if(!t.get(e))return 1/0;if(e===p.passage)return 0;for(var n=f;n>0;n--)if(l[n].passage===e)return f-n+1;return 1/0},pastPassageNames:function(){for(var e=[],t=f-1;t>=0;t--)e.unshift(l[t].passage);return e},play:function(e){p||a("State.play","present is undefined!"),p.passage=e,l=l.slice(0,f+1).concat(p),f+=1,o(e),h.forward.forEach(function(t){return t(e)})},rewind:function(e){var t=1,n=!1;if(e)if("string"==typeof e){if(t=this.passageNameLastVisited(e),t===1/0)return}else"number"==typeof e&&(t=e);for(;t>0&&f>0;t--)n=!0,f-=1;return n&&(o(l[f].passage),h.back.forEach(function(e){return e()})),n},fastForward:function(e){var t=1,n=!1;for("number"==typeof e&&(t=e);t>0&&l.length>0;t--)n=!0,f+=1;return n&&(o(l[f].passage),h.forward.forEach(function(e){return e(l[f].passage,"fastForward")})),n},on:function(e,t){return e in h?("function"!=typeof t||h[e].includes(t)||h[e].push(t),m):void a("State.on","invalid event name")},reset:function(){window.jasmine&&(l=[],f=-1,p=c.create(),d=void 0,h.load.forEach(function(e){return e(l)}))}},function(){function e(t){return"number"==typeof t||"boolean"==typeof t||"string"==typeof t||null===t||Array.isArray(t)&&t.every(e)||t instanceof Set&&Array.from(t).every(e)||t instanceof Map&&Array.from(t.values()).every(e)||n.isPrototypeOf(t)}function t(e,t){return t instanceof Set?{"(dataset:)":Array.from(t)}:t instanceof Map?{"(datamap:)":Array.from(t)}:n.isPrototypeOf(t)?{changer:{name:t.macroName,params:t.params,next:t.next}}:t}function i(e,t){if(t&&"object"===("undefined"==typeof t?"undefined":_typeof(t))){if(Array.isArray(t["(dataset:)"]))return new Set(t["(dataset:)"]);if(Array.isArray(t["(datamap:)"]))return new Map(t["(datamap:)"]);if(t.changer&&"object"===_typeof(t.changer)){var r=t.changer,i=r.name,o=r.params,a=r.next;return n.create(i,o,a)}}return t}function a(){var n=l.slice(0,f+1),i=n.map(function(t){return Object.keys(t.variables).filter(function(n){return t.variables[n]&&!e(t.variables[n])}).map(function(e){return[e,t.variables[e]]})});if(d||(d=i.reduce(function(e,t,n){var r=_slicedToArray(t,2),i=r[0],o=r[1];return e||i&&[i,o,n+1]},void 0)),d){var o=d,a=_slicedToArray(o,3),u=a[0],c=a[1],p=a[2];return r.create("saving","The variable $"+u+" holds "+s(c)+" (which is, or contains, a complex data value) on turn "+p+"; the game can no longer be saved.")}try{return JSON.stringify(n,t)}catch(e){return!1}}function p(e){var t=void 0,n=u;try{t=JSON.parse(e,i)}catch(e){return!1}return Array.isArray(t)?(t=t.map(function(e){return"object"===("undefined"==typeof e?"undefined":_typeof(e))&&e.hasOwnProperty("passage")&&e.hasOwnProperty("variables")?(e.variables=Object.assign(Object.create(n),e.variables),n=e.variables,Object.assign(Object.create(c),e)):!1})).includes(!1)?!1:(l=t,h.load.forEach(function(e){return e(l)}),f=l.length-1,void o(l[f].passage)):!1}return{serialise:a,deserialise:p}}());return Object.seal(c),Object.freeze(m)}),define("datatypes/colour",["jquery"],function(e){function t(t){if(t in s)return s[t];var n=e("<p>").css("background-color",t).css("background-color");return n=n.startsWith("rgb")?n.match(/\d+/g).reduce(function(e,t,n){return e["rgb"[n]]=+t,e},{}):{r:192,g:192,b:192},s[t]=n,n}function n(e){return"string"!=typeof e?e:(e=e.replace("#",""),e=e.replace(o,"$1$1$2$2$3$3"),{r:parseInt(e.slice(0,2),16),g:parseInt(e.slice(2,4),16),b:parseInt(e.slice(4,6),16)})}function r(e){var t=e.r,n=e.g,r=e.b,i=e.a;t/=255,n/=255,r/=255;var o=Math.max(t,n,r),a=Math.min(t,n,r),s=(o+a)/2,u=o-a;if(o===a)return{h:0,s:0,l:s};var c=void 0;switch(o){case t:c=(n-r)/u+(r>n?6:0);break;case n:c=(r-t)/u+2;break;case r:c=(t-n)/u+4}c=Math.round(60*c);var l=s>.5?u/(2-o-a):u/(o+a);return{h:c,s:l,l:s,a:i}}function i(e){function t(e){return 0>e&&(e+=1),e>1&&(e-=1),1/6>e?u+6*(s-u)*e:.5>e?s:2/3>e?u+(s-u)*(2/3-e)*6:u}var n=e.h,r=e.s,i=e.l,o=e.a;if(0===r){var a=Math.floor(255*i);return{r:a,g:a,b:a}}n/=360;var s=.5>i?i*(1+r):i+r-i*r,u=2*i-s;return{r:Math.floor(255*t(n+1/3)),g:Math.floor(255*t(n)),b:Math.floor(255*t(n-1/3)),a:o}}var o=/^([\da-fA-F])([\da-fA-F])([\da-fA-F])$/,a=/^([\da-fA-F])([\da-fA-F])([\da-fA-F])([\da-fA-F])([\da-fA-F])([\da-fA-F])$/,s=Object.create(null),u=Object.freeze({TwineScript_TypeName:"a colour",TwineScript_ObjectName:"a colour","TwineScript_+":function(e){var t=this,n=e;return u.create({r:Math.min(Math.round(.6*(t.r+n.r)),255),g:Math.min(Math.round(.6*(t.g+n.g)),255),b:Math.min(Math.round(.6*(t.b+n.b)),255),a:(t.a+n.a)/2})},TwineScript_Print:function(){return"<tw-colour style='background-color:rgba("+[this.r,this.g,this.b,this.a].join(",")+");'></span>"},TwineScript_is:function(e){return u.isPrototypeOf(e)&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a},TwineScript_Clone:function(){return u.create(this)},toRGBAString:function(){return"rgba("+this.r+", "+this.g+", "+this.b+", "+this.a+")"},get h(){return r(this).h},get s(){return r(this).s},get l(){return r(this).l},create:function(e){return"string"==typeof e?this.create(u.isHexString(e)?n(e):t(e)):!("h"in e&&"s"in e&&"l"in e)||"r"in e||"g"in e||"b"in e?("a"in e&&"number"==typeof e.a||(e.a=1),Object.assign(Object.create(this),e)):this.create(i(e))},isHexString:function(e){return"string"==typeof e&&"#"===e[0]&&(e.slice(1).match(o)||e.slice(1).match(a))},isCSS3Function:function(e){return"string"==typeof e&&/^(?:rgb|hsl)a?\(\s*\d+\s*,\s*\d+%?\s*,\s*\d+%?(?:,\s*\d+(?:\.\d+)?\s*)?\)$/.test(e)}});return u}),define("internaltypes/varref",["state","internaltypes/twineerror","utils","utils/operationutils","datatypes/hookset","datatypes/colour"],function(e,t,n,r,i,o){function a(e,n){var r=void 0;if(e instanceof Map&&(r=t.containsError(j(e,n))))return r;if(w(e)){var o=void 0;if("number"==typeof n){if(0===n)return t.create("property","You can't access elements at position 0 of "+x(e)+".","Only positive and negative position values exist.");n>0&&(n-=1)}else if("string"==typeof n&&(o=/(\d+)(?:st|[nr]d|th)last/i.exec(n)))n=-o[1]+"";else if("string"==typeof n&&(o=/(\d+)(?:st|[nr]d|th)/i.exec(n)))n=o[1]-1+"";else if("last"===n)n=-1;else if(!["length","any","all"].includes(n)||i.isPrototypeOf(e))return t.create("property","You can only access position strings/numbers ('4th', 'last', '2ndlast', (2), etc.)"+(i.isPrototypeOf(e)?"":", 'length', 'any' and 'all'")+" of "+x(e)+", not "+x(n)+".")}else if(e instanceof Set){if(!["length","any","all"].includes(n))return t.create("property","You can only get the 'length', 'any' and 'all' of a "+x(e)+".","To check contained values, use the 'contains' operator.");"length"===n&&(n="size")}else if("number"==typeof e||"boolean"==typeof e)return t.create("property","You can't get data values from "+x(e)+".");return n}function s(e,n){var r=n.reduce(function(r,i,o){i.computed&&(i=i.value),k.isPrototypeOf(i)&&(i=i.get()),i=Array.isArray(i)?i.map(function(t){return a(e,t)}):a(e,i);var s=void 0;return(s=t.containsError(r,i))?s:(o<n.length-1&&(e=g(e,i)),r.push(i),r)},[]);return{compiledPropertyChain:r,deepestObject:e}}function u(e,t){return 0>t-0&&Math.abs(t)<=e.length?e.length+(t-0):t}function c(e,t){var n={any:"'any' value of ",all:"'all' values of "}[t];return{determiner:t,array:[].concat(_toConsumableArray(e)),TwineScript_ObjectName:n+x(e),TwineScript_TypeName:n+"a data structure",TwineScript_Unstorable:!0,TwineScript_Print:function(){return"`["+this.TwineScript_TypeName+"]`"}}}function l(e,t){if(void 0===e)return e;if(e instanceof Map)return e.get(t);if(w(e)&&(t=u(e,t)),"any"===t||"all"===t)return c(e,t);if(e.TwineScript_GetElement&&Number.isFinite(+t))return e.TwineScript_GetElement(t);var n=e[t];return"function"!=typeof n?n:void 0}function f(e){return e.computed?"string"==typeof e.value?"('"+e.value+"')":"("+e.value+")":"'"+e+"'"}function p(e,n){if(Array.isArray(n))return n.map(function(t){return p(e,t)});if(i.isPrototypeOf(e))return t.create("operation","I can't modify "+x(e),"You should alter hooks indirectly using macros like (replace:) or (enchant:).");if(e instanceof Set)return t.create("operation","I can't modify "+x(e),"You should use an (array:) if you need to modify the data inside this dataset.");if(o.isPrototypeOf(e))return t.create("operation","I can't modify the components of "+x(e));if(e instanceof Map)return!0;if(w(e)){if(["length","any","all"].includes(n))return t.create("operation","I can't forcibly alter the '"+n+"' of "+x(e)+".");if(+n!==(0|n))return t.create("property",x(e)+" can only have position keys ('3rd', '1st', (5), etc.), not "+f(n)+".")}return e.TwineScript_Identifiers&&n in e?t.create("keyword","I can't alter the value of the '"+n+"' identifier.","You can only alter data in variables and hooks, not fixed identifiers."):"number"==typeof e||"boolean"==typeof e?t.create("operation","You can't alter the data values of "+x(e)+"."):!0}function d(e,t,n){var r=t;e instanceof Map?e.set(t,n):(w(e)&&(t=u(e,t)),e.TwineScript_Set?e.TwineScript_Set(t):e[t]=n),A.set.forEach(function(t){return t(e,r,n)})}function h(e,t){var n=t;w(e)&&(t=u(e,t)),Array.isArray(e)&&O.exec(t)?e.splice(t,1):e instanceof Map||e instanceof Set?e.delete(t):delete e[t],A.delete.forEach(function(t){return t(e,n)})}function m(e){function t(){return e}return{get:t,set:t,delete:t,varref:!0}}function g(n,r,o){if(Array.isArray(r))return i.isPrototypeOf(n)?n.TwineScript_GetElement(r):r.map(function(e){return g(n,e,e)})["string"==typeof n?"join":"valueOf"]("");"string"==typeof n&&(n=[].concat(_toConsumableArray(n)));var a=l(n,r);return void 0===a?n===e.variables?C:n.TwineScript_VariableStore?t.create("property","There isn't a temp variable named _"+o+" in this place.","Temp variables only exist inside the same passage and hook in which they're (set:)."):t.create("property","I can't find a "+f(o)+" data name in "+x(n)):a}function y(e,n){var r=this,i=this.compiledPropertyChain.reduce(function(e,t){var n=void 0;return n=0===e.length?r.object:g.apply(void 0,_toConsumableArray(e[e.length-1])),e.push([n,t])&&e},[]).reduceRight(e,n);return t.containsError(i)?i:void 0}var v=n.impossible,b=r.isObject,w=r.isSequential,x=r.objectName,T=r.typeName,S=r.clone,O=r.numericIndex,j=r.isValidDatamapName,k=void 0,C=0,A={set:[],delete:[]};return k=Object.freeze({varref:!0,get:function(){return g(this.deepestObject,this.compiledPropertyChain.slice(-1)[0],this.propertyChain.slice(-1)[0])},set:function(e){return!this.object||this.object.TwineScript_VariableStore||this.object.TwineScript_Identifiers?y.call(this,function(e,n,r){var i=_slicedToArray(n,2),o=i[0],a=i[1],s=void 0;if(s=t.containsError(e,o,a)||t.containsError(p(o,a)))return s;if(e&&e.TwineScript_Unstorable)return t.create("operation",T(e)+" can't be stored.");if(r>0&&(o=S(o)),"string"==typeof o){var u=function(){if("string"!=typeof e||e.length!==(Array.isArray(a)?a.length:1))return{v:t.create("datatype","I can't put this non-string value, "+x(e)+", in a string.")};o=[].concat(_toConsumableArray(o));var n=[].concat(_toConsumableArray(e));[].concat(a).forEach(function(e){0>0+e&&(e=o.length+(0+e)),o=[].concat(_toConsumableArray(o.slice(0,e)),[n.shift()],_toConsumableArray(o.slice(e+1)))}),o=o.join("")}();if("object"===("undefined"==typeof u?"undefined":_typeof(u)))return u.v}else b(o)&&(Array.isArray(a)&&w(e)?("string"==typeof e&&(e=[].concat(_toConsumableArray(e))),a.map(function(t,n){return[t,e[n]]}).forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=t[1];return d(o,n,r)})):d(o,a,e));return o},e):t.create("macrocall","I can't (set:) "+x(this)+", if the "+(x(this.object).match(/ (.+$)/)||["","value"])[1]+" isn't stored in a variable.","Modifying data structures that aren't in variables won't change the game state at all.")},delete:function(){return y.call(this,function(e,n,r){var i=_slicedToArray(n,2),o=i[0],a=i[1],s=void 0;if(s=t.containsError(e,o,a)||t.containsError(p(o,a)))return s;if(r>0&&(o=S(o)),null===e){var c="string"==typeof o;c&&(o=[].concat(_toConsumableArray(o))),Array.isArray(a)?(w(o)&&(a=[].concat(_toConsumableArray(new Set(a))),a.sort(function(e,t){return u(o,t)-u(o,e)})),a.forEach(function(e){return h(o,e)})):h(o,a),c&&(o=o.join(""))}else d(o,a,e);return o},null)},create:function(e,n){var r=void 0;if(r=t.containsError(e))return m(r);n=[].concat(n),k.isPrototypeOf(e)&&(n=e.propertyChain.concat(n),e=e.object);var i=s(e,n),o=i.compiledPropertyChain,a=i.deepestObject;return(r=t.containsError(o,a))?m(r):Object.assign(Object.create(k),{object:e,propertyChain:n,compiledPropertyChain:o,deepestObject:a})},get TwineScript_ObjectName(){var t=this,n=function(n,r){return r||t.object!==e.variables&&!t.object.TwineScript_VariableStore?f(n):n};return(this.object===e.variables?"$":this.object.TwineScript_VariableStore?"_":x(this.object)+"'s ")+(1===this.propertyChain.length?n(this.propertyChain[0]):this.propertyChain.reduce(function(e,t,r){return e+"'s "+n(t,r)}))+(this.object.TwineScript_VariableStore?" in "+this.object.TwineScript_VariableStoreName:"")},on:function(e,t){return e in A?("function"!=typeof t||A[e].includes(t)||A[e].push(t),k):void v("VarRef.on","invalid event name")}})}),define("utils/naturalsort",[],function(){return function(e){return function t(n,r){var i,o,a,s,u=/(^-?[0-9]+(\.?[0-9]*)[df]?e?[0-9]?$|^0x[0-9a-f]+$|[0-9]+)/gi,c=/(^[ ]*|[ ]*$)/g,l=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,f=/^0x[0-9a-f]+$/i,p=/^0/,d=function(e){return t.insensitive&&(""+e).toLowerCase()||""+e},h=d(n).replace(c,"")||"",m=d(r).replace(c,"")||"",g=h.replace(u,"\x00$1\x00").replace(/\0$/,"").replace(/^\0/,"").split("\x00"),y=m.replace(u,"\x00$1\x00").replace(/\0$/,"").replace(/^\0/,"").split("\x00"),v=parseInt(h.match(f))||1!==g.length&&h.match(l)&&Date.parse(h),b=parseInt(m.match(f))||v&&m.match(l)&&Date.parse(m)||null;if(e&&window.Intl&&window.Intl.Collator&&(a=window.Intl.Collator(e)),b){if(b>v)return-1;if(v>b)return 1}for(var w=0,x=Math.max(g.length,y.length);x>w;w++){if(i=!(g[w]||"").match(p)&&parseFloat(g[w])||g[w]||0,o=!(y[w]||"").match(p)&&parseFloat(y[w])||y[w]||0,isNaN(i)!==isNaN(o))return isNaN(i)?1:-1;if(("undefined"==typeof i?"undefined":_typeof(i))!==("undefined"==typeof o?"undefined":_typeof(o)))i+="",o+="";else if("string"==typeof i&&a&&(s=a.compare(i,o),0!==s))return s;if(o>i)return-1;if(i>o)return 1}return 0}}}),define("internaltypes/varscope",[],function(){return{TwineScript_ObjectName:"the temporary variables",TwineScript_VariableStore:!0}}),define("datatypes/lambda",["utils","utils/operationutils","internaltypes/varscope","internaltypes/twineerror"],function(e,t,n,r){var i=e.toJSLiteral,o=e.insensitiveName,a=(e.plural,t.typeName,t.objectName,t.singleTypeCheck,Object.freeze({lambda:!0,TwineScript_TypeName:"a lambda",TwineScript_ObjectName:function(){return'a "'+("making"in this?"making ... ":"")+("with"in this?"with ... ":"")+("where"in this?"where ... ":"")+("via"in this?"via ... ":"")+'" lambda'},TwineScript_Print:function(){return"`[A lambda]`"},TwineScript_is:function(e){return e===this},TypeSignature:function(e){return{pattern:"lambda",innerType:a,clauses:e}},create:function(e,t,i){var s=void 0;if(r.containsError(e))return e;if(a.isPrototypeOf(e)){if(t in e&&("where"!==t||"true"!==e[t]))return r.create("syntax","This lambda has two '"+t+"' clauses.");s=e}else{if(void 0!==e&&(!e||!e.varref||!n.isPrototypeOf(e.object)||e.propertyChain.length>1))return r.create("syntax","This lambda needs to start with a single temporary variable.");s=Object.create(this),s.loop=e?e.propertyChain[0]:""}s[t]=i;var u=[s.making,s.with,s.loop].filter(function(e,t,n){return e&&n.indexOf(o(e))!==t});return u.length?r.create("syntax","This lambda has two variables named '"+u[0]+"'.","Lambdas should have all-unique parameter names."):s},apply:function(e,t){var o=t.loop,a=t.with,s=t.making,u=t.fail,c=t.pass,l=t.ignoreVia,f=Object.create(n);[[this.loop,o],[this.with,a],[this.making,s]].forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=t[1];return n&&(f[n]=r)}),e.stack.unshift(Object.assign(Object.create(null),{tempVariables:f})),e.eval("Operations").initialiseIt(!o||this.with||this.making?r.create("operation","I can't use 'it', or an implied 'it', in "+this.TwineScript_ObjectName()):o);var p=!l&&this.via,d=e.eval("where"in this?"Operations.where("+this.where+","+(p||i(c))+","+i(u)+")":p||i(c));return e.stack.shift(),d},filter:function(e,t){var n=this;return t.reduce(function(t,i){var o=void 0;if(o=r.containsError(t))return o;var a=n.apply(e,{loop:i,pass:!0,fail:!1,ignoreVia:!0});return(o=r.containsError(a))?o:t.concat(a?[i]:[])},[])}}));return a}),define("macros",["jquery","utils/naturalsort","utils","utils/operationutils","datatypes/changercommand","datatypes/lambda","datatypes/hookset","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s){function u(e){return function(n){n=n.reduce(function(e,n){if(n&&n.spreader===!0){var r=n.value;if(Array.isArray(r)||"string"==typeof r)for(var i=0;i<r.length;i++)e.push(r[i]);else r instanceof Set?e.push.apply(e,_toConsumableArray(Array.from(r).sort(t("en")))):e.push(s.create("operation","I can't spread out "+g(r)+", because it is not a string, dataset, or array."))}else e.push(n);return e},[]);var r=s.containsError(n);return r?r:e.apply(void 0,_toConsumableArray(n))}}function c(e,t,n){n=[].concat(n||[]),e="("+(Array.isArray(e)&&e.length>1?e[0]:e)+":)";var r=void 0;return r=n.length>0?"The "+e+" macro must only be given "+n.map(y).reduce(function(e,t,n,r){return e+(0===n?"":n<r.length-1?", ":", and ")+t},"")+(n.length>1?", in that order":"."):"The macro must not be given any data - just write "+e+".",function(i){for(var a=arguments.length,u=Array(a>1?a-1:0),c=1;a>c;c++)u[c-1]=arguments[c];for(var l=void 0,f=(function(t){var i=n[t],a=u[t];return t>=n.length&&!l?{v:s.create("datatype",u.length-n.length+" too many values were given to this "+e+" macro.",r)}:(i||(i=l),!i.innerType||"rest"!==i.pattern&&"zero or more"!==i.pattern||(l=i.innerType,"rest"===i.pattern&&(i=i.innerType)),v(a,i)?void 0:void 0===a?{v:s.create("datatype","The "+e+" macro needs "+d(n.length-t,"more value")+".",r)}:a&&a.TwineScript_Unstorable&&(i===b.TypeSignature.Any||i.innerType&&i.innerType===b.TypeSignature.Any)?{v:s.create("datatype",e+"'s "+p(t+1)+" value, "+g(a)+", is not valid data for this macro.",r)}:a&&o.isPrototypeOf(a)&&"lambda"===i.pattern?{v:s.create("datatype",e+"'s "+p(t+1)+" value (a lambda) should have "+h(["where","making","via","with"].filter(function(e){return i.clauses.includes(e)}).map(function(e){return"a '"+e+"' clause"}))+", not "+h(["where","making","via","with"].filter(function(e){return e in a}).map(function(e){return"a '"+e+"' clause"}))+".")}:{v:s.create("datatype",e+"'s "+p(t+1)+" value is "+g(a)+", but should be "+y(i)+".",i.message||r)})}),m=0,w=Math.max(u.length,n.length);w>m;m+=1){var x=f(m,w);if("object"===("undefined"==typeof x?"undefined":_typeof(x)))return x.v}return t.apply(void 0,[i].concat(u))}}function l(e,t){Array.isArray(e)?e.forEach(function(e){return m(w,f(e),t)}):m(w,f(e),t)}var f=n.insensitiveName,p=n.nth,d=n.plural,h=n.andList,m=n.lockProperty,g=r.objectName,y=r.typeName,v=r.singleTypeCheck,b=void 0,w={};return b={has:function(e){return e=f(e),w.hasOwnProperty(e)},get:function(e){return e=f(e),w.hasOwnProperty(e)&&w[e]},add:function e(t,n,r){return l(t,u(c(t,n,r))),e},addChanger:function e(t,n,r,o){return l(t,u(c(t,n,o))),i.register(Array.isArray(t)?t[0]:t,r),e},TypeSignature:{optional:function(e){return{pattern:"optional",innerType:e}},zeroOrMore:function(e){return{pattern:"zero or more",innerType:e}},either:function(){for(var e=arguments.length,t=Array(e),n=0;e>n;n++)t[n]=arguments[n];return{pattern:"either",innerType:t}},rest:function(e){return{pattern:"rest",innerType:e}},wrapped:function(e,t){return{pattern:"wrapped",innerType:e,message:t}},Any:{TwineScript_TypeName:"anything"}},run:function(e,t){return s.containsError(e)?e:b.has(e)?b.get(e)(t):s.create("macrocall","I can't run the macro '"+e+"' because it doesn't exist.","Did you mean to run a macro? If you have a word written like (this:), it is regarded as a macro name.")}},Object.freeze(b)}),define("datatypes/assignmentrequest",["utils"],function(e){var t=e.assertMustHave,n=Object.freeze({assignmentRequest:!0,TwineScript_TypeName:"a 'to' or 'into' expression",TwineScript_ObjectName:"a 'to' or 'into' expression",TwineScript_Unstorable:!0,create:function(e,n,r){return t(e,["varref"]),Object.assign(Object.create(this),{dest:e,src:n,operator:r})}});return n}),define("twinescript/operations",["state","datatypes/colour","datatypes/assignmentrequest","utils/operationutils","internaltypes/twineerror"],function(e,t,n,r,i){function o(e,t,n,r){return n=n||"do this to",function(o,a){1===t.length&&(a=o);var s=void 0;return(s=i.containsError(o,a))?s:("undefined"==typeof o?"undefined":_typeof(o))!==e||("undefined"==typeof a?"undefined":_typeof(a))!==e?i.create("operation","I can only "+n+" "+e+"s, not "+m(("undefined"==typeof o?"undefined":_typeof(o))!==e?o:a)+".",r):t(o,a)}}function a(e){return function(t,n){var r=void 0;return(r=i.containsError(t,n))?r:t&&t.varref?i.create("operation","I can't give an expression a new value."):("undefined"==typeof t?"undefined":_typeof(t))!==("undefined"==typeof n?"undefined":_typeof(n))||c(t)!==c(n)?l(e,t,n)||i.create("operation",m(t)+" isn't the same type of data as "+m(n)):e(t,n)}}function s(e){var t=function t(n,r){var o=void 0;if(o=i.containsError(n,r))return o;if(y=n,n.determiner){var a=function(){var e="all"===n.determiner;return{v:n.array.reduce(function(n,o){var a=void 0,s=t(o,r);return(a=i.containsError(n,s))?a:e?n&&s:n||s},e)}}();if("object"===("undefined"==typeof a?"undefined":_typeof(a)))return a.v}else if(r.determiner){var s=function(){var e="all"===r.determiner;return{v:r.array.reduce(function(r,o){var a=void 0,s=t(n,o);return(a=i.containsError(r,s))?a:e?r&&s:r||s},e)}}();if("object"===("undefined"==typeof s?"undefined":_typeof(s)))return s.v}return e(n,r)};return t}var u=r.isObject,c=r.collectionType,l=r.coerceToString,f=r.is,p=r.clone,d=r.unique,h=r.contains,m=(r.typeName,r.objectName),g=void 0,y=0,v="If one of these values is a number, you may want to write a check that it 'is not 0'. Also, if one is a string, you may want to write a check that it 'is not \"\" '.";return g={create:function(e){var t=Object.create(this);return t.Identifiers={TwineScript_Identifiers:!0,get it(){return y},get time(){return Date.now()-e.timestamp}},t},elidedComparisonOperator:function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];return r.reduce(function(n,r){return"boolean"==typeof r?r:g[e](n,g[t](y,r))},"and"===e)},and:o("boolean",a(function(e,t){return e&&t}),"use 'and' to join",v),or:o("boolean",a(function(e,t){return e||t}),"use 'or' to join",v),not:o("boolean",function(e){return!e},"use 'not' to invert",v),"+":a(function(e,t){if(Array.isArray(e))return[].concat(_toConsumableArray(e),_toConsumableArray(t));var n=void 0;return e instanceof Map?(n=new Map(e),t.forEach(function(e,t){return n.set(t,e)}),n):e instanceof Set?new Set([].concat(_toConsumableArray(e),_toConsumableArray(t)).filter(d).map(p)):"function"==typeof e["TwineScript_+"]?e["TwineScript_+"](t):"string|number|boolean".includes("undefined"==typeof e?"undefined":_typeof(e))?e+t:i.create("operation","I can't use + on "+m(e)+".")}),"-":a(function(e,t){if(Array.isArray(e))return e.filter(function(e){return!t.some(function(t){return f(e,t)})});if(e instanceof Set){var n=function(){var n=[].concat(_toConsumableArray(t));return{v:new Set([].concat(_toConsumableArray(e)).filter(function(e){return!n.some(function(t){return f(e,t)})}))}}();if("object"===("undefined"==typeof n?"undefined":_typeof(n)))return n.v}return"string"==typeof e?e.split(t).join(""):"number"==typeof e?e-t:i.create("operation","I can't use - on "+m(e)+".")}),"*":o("number",a(function(e,t){return e*t}),"multiply"),"/":o("number",a(function(e,t){return 0===t?i.create("operation","I can't divide "+m(e)+" by zero."):e/t}),"divide"),"%":o("number",a(function(e,t){return 0===t?i.create("operation","I can't modulo "+m(e)+" by zero."):e%t}),"modulus"),"<":s(o("number",a(function(e,t){return t>e}),"do < to")),">":s(o("number",a(function(e,t){return e>t}),"do > to")),"<=":s(o("number",a(function(e,t){return t>=e}),"do <= to")),">=":s(o("number",a(function(e,t){return e>=t}),"do >= to")),is:s(f),isNot:s(function(e,t){return!g.is(e,t)}),contains:s(h),isIn:s(function(e,t){return h(t,e)}),where:function(e,t,n){var r=void 0;return(r=i.containsError(e))?r:"boolean"!=typeof e?i.create("operation","This lambda's 'where' clause must evaluate to true or false, not "+m(e)+"."):e?t:n},makeSpreader:function(e){return{value:e,spreader:!0}},makeAssignmentRequest:function(e,t,r){var o=i.containsError(e,t);return o?o:u(e)&&"varref"in e?n.create(e,t,r):i.create("operation","I can't store a new value inside "+m(e)+".")},setIt:function(e){return i.containsError(e)?e:e.varref?(y=e.get(),e):i.create("operation","I can't put a new value into "+m(e)+".")},initialiseIt:function(e){y=e}},Object.freeze(g)}),define("twinescript/environ",["macros","state","utils","datatypes/colour","datatypes/hookset","datatypes/lambda","internaltypes/varref","internaltypes/twineerror","twinescript/operations"],function(Macros,State,Utils,Colour,HookSet,Lambda,VarRef,TwineError,OperationsProto){return function(section){"object"===("undefined"==typeof section?"undefined":_typeof(section))&&section||Utils.impossible("TwineScript.environ","no Section argument was given!");var Operations=OperationsProto.create(section);return section.eval=function(){try{for(var _len5=arguments.length,args=Array(_len5),_key5=0;_len5>_key5;_key5++)args[_key5]=arguments[_key5];return eval(args.join(""))}catch(e){return e}},section}}),define("internaltypes/twinenotifier",["jquery","utils"],function(e,t){var n=t.impossible,r={create:function(e){return e||n("TwineNotifier.create","called with only 1 string."),Object.assign(Object.create(r),{message:e})},render:function(){return e("<tw-notifier>").attr("message",this.message)}};return r}),define("section",["jquery","utils","utils/selectors","renderer","twinescript/environ","twinescript/operations","state","utils/operationutils","datatypes/changercommand","datatypes/hookset","datatypes/colour","internaltypes/changedescriptor","internaltypes/varscope","internaltypes/twineerror","internaltypes/twinenotifier"],function(e,t,n,r,i,o,a,s,u,c,l,f,p,d,h){function m(e,n,r){if(n&&"object"===("undefined"==typeof n?"undefined":_typeof(n))&&n.changer){var i=this.renderInto(r.popAttr("source"),r,n);if(!i){var o=t.insensitiveName(e.attr("name"));return void(["if","elseif","unless","else"].includes(o)&&(e.addClass("false"),"elseif"!==o&&(this.stack[0].lastHookShown=!1)))}}else if(n&&"object"===("undefined"==typeof n?"undefined":_typeof(n))&&n.live)x.call(this,r,n.delay,n.event);else{if(n===!1)return r.attr("source")&&r.data("hiddenSource",r.popAttr("source")),e.addClass("false"),void(this.stack[0].lastHookShown=!1);n!==!0&&e.replaceWith(d.create("datatype",S(n)+" cannot be attached to this hook.","Only Booleans, changer commands, and the (live:) macro can be attached to hooks.").render(e.attr("title")))}this.stack[0].lastHookShown=!0}function g(t){var n=t instanceof e?t[0]:t,r=n.nextSibling;if(r&&(r instanceof Text&&!r.textContent.trim()||"br"===(r.tagName||"").toLowerCase())){var i=g(r),o=i.whitespace,a=i.nextElem;return{whitespace:e(r).add(o),nextElem:a}}return{whitespace:e(),nextElem:e(r)}}function y(r){var i=this.eval(r.popAttr("js")||""),a=void 0,s=void 0,c=e();for(s=r;u.isPrototypeOf(i);){var f=g(s);if(a=f.whitespace,s=f.nextElem,s[0]instanceof Text&&"+"===s[0].textContent.trim()){var p=void 0,y=s,v=g(y);if(p=v.whitespace,s=v.nextElem,s.is(n.expression)){var b=this.eval(s.popAttr("js"));if(d.containsError(b)){i=b;break}var w=o["+"](i,b);e(a).add(y).add(p).remove(),i=d.containsError(w)?d.create("operation","I can't combine "+S(i)+" with "+S(b)+"."):w;continue}}if(s.is(n.hook)){a.remove(),c=s;break}r.replaceWith(d.create("syntax","The ("+i.macroName+":) command should be assigned to a variable or attached to a hook.","Macros like this should appear to the left of a hook: "+r.attr("title")+"[Some text]").render(r.attr("title")));break}c=c.length?c:g(r).nextElem.filter(n.hook);var x=void 0;if(x=d.containsError(i))x instanceof Error&&(x=d.fromError(x)),r.replaceWith(x.render(r.attr("title"),r));else if(h.isPrototypeOf(i))r.append(i.render());else if(!c.length&&("string"==typeof i||"number"==typeof i||i instanceof Map||i instanceof Set||Array.isArray(i)||l.isPrototypeOf(i))||i&&i.TwineScript_Print&&!i.changer){if(i=T(i),i.earlyExit)return"earlyexit";i instanceof e?r.append(i):d.containsError(i)?(i instanceof Error&&(i=d.fromError(i)),r.replaceWith(i.render(r.attr("title"),r))):this.renderInto(i,r)}else c.length?m.call(this,r,i,c):i.changer||"boolean"==typeof i||t.impossible("Section.runExpression","The expression evaluated to an unknown value: "+i.toSource())}function v(e){var t=e.first()[0],n=e.parent();if(!n.length)return null;var r=n.textNodes().filter(function(e){var n=e.compareDocumentPosition(t);return 4&n&&!(8&n)});return r=r[r.length-1],r?r:v(n)}function b(e){var t=e.last()[0],n=e.parent();if(!n.length)return null;var r=n.textNodes().filter(function(e){var n=e.compareDocumentPosition(t);return 2&n&&!(8&n)})[0];return r?r:b(n)}function w(t){function n(t){return 0===e(this||t).parentsUntil("tw-collapsed").filter("tw-verbatim, tw-expression, [collapsing=false]").length}var r=v(t);e(r).parents("tw-collapsed").length||(r=null);
-
-var i=b(t);e(i).parents("tw-collapsed").length||(i=null),t.findAndFilter("br:not([data-raw])").filter(n).replaceWith(document.createTextNode(" "));var o=t.textNodes(),a=0;o.reduce(function(e,t){return n(t)?(t.textContent=t.textContent.replace(/\s+/g," ")," "!==t.textContent[0]||e&&e.textContent&&!(e.textContent.search(/\s$/)>-1)||(t.textContent=t.textContent.slice(1)),t):document.createTextNode("A")},r),[].concat(_toConsumableArray(o)).reverse().every(function(e){return n(e)?e.textContent.match(/^\s*$/)?(a+=e.textContent.length,e.textContent="",!0):(e.textContent=e.textContent.replace(/\s+$/,function(e){return a+=e.length,""}),!1):!1}),a>0&&i&&(o[o.length-1].textContent+=" "),t[0]&&j()&&t[0].normalize()}function x(e,t){var r=this,i=e.popAttr("source")||"";t=void 0===t?20:t;var o=function o(){r.inDOM()&&(r.renderInto(i,e,{append:"replace"}),e.find(n.expression+"[name='stop']").length||r.inDOM()&&setTimeout(o,t))};setTimeout(o,t)}var T=s.printBuiltinValue,S=s.objectName,O=void 0,j=function(){var t=void 0;return function(){if(void 0!==t)return t;var n=e("<p>");return n[0].normalize?(n.append(document.createTextNode("0-"),document.createTextNode("2"),document.createTextNode(""))[0].normalize(),t=1===n.contents().length):t=!1}}();return O={create:function(n){n instanceof e&&1===n.length||t.impossible("Section.create","called with no DOM element");var r=Object.assign(Object.create(this),{timestamp:Date.now(),dom:n||t.storyElement,stack:[],enchantments:[]});return r=i(r)},inDOM:function(){return e(t.storyElement).find(this.dom).length>0},evaluateTwineMarkup:function(t){var n=e("<p>");this.renderInto(t,n);var r=void 0;return(r=n.find("tw-error")).length>0?r:n.text()},renderInto:function(t,r){for(var i=this,o=f.create({target:r,source:t,section:this}),a=arguments.length,s=Array(a>2?a-2:0),u=2;a>u;u++)s[u-2]=arguments[u];s.forEach(function(e){e.changer?e.run(o):Object.assign(o,e)}),r=o.target,this.stack.length>=50&&d.create("infinite","Printing this expression may have trapped me in an infinite loop.").render(r.attr("title")).replaceAll(r);var c=function(t,o){var a=t.render();i.stack.unshift(o);var s=i;a.findAndFilter(n.hook+","+n.expression).each(function(){var t=e(this);switch(t.tag()){case n.hook:if(t.attr("hidden")&&(t.removeAttr("hidden"),t.data("hiddenSource",t.popAttr("source"))),t.attr("source")&&s.renderInto(t.popAttr("source"),t),t.find("[earlyexit]").length)return!1;break;case n.expression:if(t.attr("js")){var r=y.call(s,t);return"earlyexit"===r?(a.attr("earlyexit",!0),!1):r}}}),a.length&&r instanceof e&&r.is(n.hook)&&r.parents("tw-collapsed").length>0&&w(a),a.findAndFilter(n.collapsed).each(function(){w(e(this))}),i.stack.shift()},l=Object.create(this.stack.length?this.stack[0].tempVariables:p),h=r&&r.tag();return l.TwineScript_VariableStoreName=h===n.hook?r.attr("name")?"?"+r.attr("name"):"an unnamed hook":h===n.expression?"a "+r.attr("type")+" expression":h===n.passage?"this passage":"an unknown scope",Object.keys(o.loopVars).length?!function(){for(var e=Object.assign({},o.loopVars),t=Math.min.apply(Math,_toConsumableArray(Object.keys(e).map(function(t){return e[t].length})));t>0;t-=1)c(o,{tempVariables:Object.keys(e).reduce(function(t,n){return t[n]=e[n].shift(),t},Object.create(l))})}():c(o,{tempVariables:l}),0===this.stack.length&&this.updateEnchantments(),o.enabled},updateEnchantments:function(){this.enchantments.forEach(function(e){e.disenchant(),e.enchantScope()})}},Object.preventExtensions(O)}),define("engine",["jquery","utils","utils/selectors","state","section","passages"],function(e,t,n,r,i,o){function a(){var t=e("<tw-passage><tw-sidebar>"),i=t.children(n.sidebar);h.permalink&&r.save&&i.append('<tw-icon tabindex=0 class="permalink" title="Permanent link to this passage"><a href="#'+r.save()+'">&sect;');var o=e('<tw-icon tabindex=0 class="undo" title="Undo">&#8630;</tw-icon>').click(d.goBack),a=e('<tw-icon tabindex=0 class="redo" title="Redo">&#8631;</tw-icon>').click(d.goForward);return r.pastLength<=0&&o.css("visibility","hidden"),r.futureLength<=0&&a.css("visibility","hidden"),i.append(o).append(a),t}function s(e,t){return"<tw-include type="+e+" title='"+c(t.get("name"))+"'>"+t.get("source")+"</tw-include>"}function u(u){var c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t.assertOnlyHas(c,["stretch","transitionIn","transitionOut"]);var d=o.get(u),m=t.storyElement,g=m.parent(),y=c.stretch,v=c.transitionOut,b=c.transitionIn;if(v=v||"instant",g.is(n.enchantment)){var w=g.data("enchantedProperties");w&&m.css(w.reduce(function(e,t){return e[t]="",e},{})),g=m.unwrap().parent()}d&&d instanceof Map&&d.has("source")||l("Engine.showPassage","There's no passage with the name \""+u+'"!'),m.detach();var x=t.$(m.children(f));!y&&v&&(p(x,v),x.css("position","absolute"));var T=(d.get("tags")||[]).join(" "),S=a().appendTo(m).attr({tags:T});m.attr({tags:T});var O=i.create(S),j=d.get("source");j=o.getTagged("header").map(s.bind(0,"header")).join("")+(h.debug?o.getTagged("debug-header").map(s.bind(0,"debug-header")).join(""):"")+j+o.getTagged("footer").map(s.bind(0,"footer")).join("")+(h.debug?o.getTagged("debug-footer").map(s.bind(0,"debug-footer")).join(""):""),r.pastLength<=0&&(h.debug&&(j=o.getTagged("debug-startup").map(s.bind(0,"debug-startup")).join("")+j),j=o.getTagged("startup").map(s.bind(0,"startup")).join("")+j),O.renderInto(j,S,{transition:b||"dissolve"}),g.append(m.parents().length?m.parents().last():m),scroll(0,y?S.offset().top-.05*e(window).height():m.offset().top)}var c=t.escape,l=t.impossible,f=t.passageSelector,p=t.transitionOut,d=void 0,h=Object.create(null);return d={goBack:function(){r.rewind()&&u(r.passage)},goForward:function(){r.fastForward()&&u(r.passage)},goToPassage:function(e,t){r.play(e),u(e,{stretch:t})},showPassage:u,options:h},Object.freeze(d)}),define("debugmode",["jquery","utils","state","internaltypes/varref","utils/operationutils","engine"],function(e,t,n,r,i,o){{var a=i.objectName;i.typeName}return function(){function t(t,n,r){var i=l.children('[data-name="'+t+'"]'),o=a(n);i.length||(i=e('<div class="variable-row" data-name="'+t+'" data-value="'+o+'"></div>').appendTo(l)),i.empty().append("<span class='variable-name "+(r?"temporary":"")+"'>"+t+(r?"<span class='temporary-variable-scope'>"+r+"</span>":"")+"</span><span class='variable-value'>"+a(n)+"</span>");var s=l.children();c.text(s.length+" Variable"+(1!==s.length?"s":""))}function i(){var r=[];l.children().each(function(i,o){o=e(o);var s=o.attr("data-name"),u=o.attr("data-value");s.startsWith("TwineScript")||(s in n.variables?(r.push(s),a(n.variables[s])!==u&&t(s,n.variables[s])):o.remove())});for(var i in n.variables)i.startsWith("TwineScript")||r.includes(i)||t(i,n.variables[i])}var s=e("<tw-debugger><div class='variables'></div>Turns: <select disabled></select><button class='show-invisibles'>Debug View</button><button class='show-variables enabled'>0 Variables</button></tw-debugger>"),u=s.find(".show-invisibles");u.click(function(){e(document.documentElement).toggleClass("debug-mode"),u.toggleClass("enabled")});var c=s.find(".show-variables"),l=s.find(".variables");c.click(function(){l[c.is(".enabled")?"attr":"removeAttr"]("hidden",""),c.toggleClass("enabled")});var f=s.find("select");f.change(function(e){var t=e.target.value,r=t-n.pastLength;0!==r&&(n[0>r?"rewind":"fastForward"](Math.abs(r)),o.showPassage(n.passage))}),n.on("forward",function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:!1,i=n.pastLength;i>1&&f.removeAttr("disabled"),r||(f.children().each(function(t,n){t>=i&&e(n).remove()}),f.append("<option value="+i+">"+(i+1)+": "+t+"</option>").val(i))}).on("back",function(){n.pastLength<=1&&f.attr("disabled"),f.find("[selected]").removeAttr("selected"),f.val(n.pastLength)}).on("load",function(e){f.empty(),f[e.length<=1?"attr":"removeAttr"]("disabled"),e.forEach(function(e,t){return f.append("<option value="+t+">"+(t+1)+": "+e.passage+"</option>")})}),n.on("forward",i).on("back",i),r.on("set",function(e,r,i){(e===n.variables||e.TwineScript_VariableStore)&&t(r,i,e===n.variables?"":e.TwineScript_VariableStoreName)}).on("delete",function(e,t){e===n.variables&&l.find('[data-name="'+t+'"]:not(.temporary)').remove()}),e(document.body).append(s)}}),define("macrolib/values",["macros","utils","utils/operationutils","datatypes/colour","internaltypes/twineerror"],function(e,t,n,r,i){function o(e){return function(){var t=e.apply(void 0,arguments);return"number"!=typeof t||isNaN(t)?i.create("macrocall","This mathematical expression doesn't compute!"):t}}var a=t.realWhitespace,s=t.anyRealLetter,u=n.subset,c=n.objectName,l=e.TypeSignature,f=l.rest,p=l.zeroOrMore,d=l.Any;e.add(["text","string"],function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];return t.join("")},[p(e.TypeSignature.either(String,Number,Boolean,Array))])("substring",function(e,t,n,r){return u(t,n,r)},[String,parseInt,parseInt])("lowercase",function(e,t){return t.toLowerCase()},[String])("uppercase",function(e,t){return t.toUpperCase()},[String])("lowerfirst",function(e,t){return t.replace(new RegExp(s+"+"),function(e){return e=Array.from(e),e[0].toLowerCase()+e.slice(1).join("").toLowerCase()})},[String])("upperfirst",function(e,t){return t.replace(new RegExp(s+"+"),function(e){return e=Array.from(e),e[0].toUpperCase()+e.slice(1).join("").toLowerCase()})},[String])("words",function(e,t){return t.split(new RegExp(a+"+")).filter(Boolean)},[String])(["num","number"],function(e,t){return Number.isNaN(+t)?i.create("macrocall","I couldn't convert "+c(t)+" to a number."):+t},[String])("rgb",function(){for(var e,t=0;t<(arguments.length<=1?0:arguments.length-1);t+=1)if(e=arguments.length<=t+1?void 0:arguments[t+1],0>e||e>255)return i.create("macrocall","RGB values must be whole numbers between 0 and 255, not "+c(e)+".");return r.create({r:arguments.length<=1?void 0:arguments[1],g:arguments.length<=2?void 0:arguments[2],b:arguments.length<=3?void 0:arguments[3]})},[parseInt,parseInt,parseInt])("rgba",function(){for(var e,t=0;3>t;t+=1)if(e=arguments.length<=t+1?void 0:arguments[t+1],0>e||e>255)return i.create("macrocall","RGB values must be whole numbers between 0 and 255, not "+c(e)+".");return(arguments.length<=4?void 0:arguments[4])<0||(arguments.length<=4?void 0:arguments[4])>1?i.create("macrocall","Alpha values must be numbers between 0 and 1 inclusive, not "+c(arguments.length<=4?void 0:arguments[4])+"."):r.create({r:arguments.length<=1?void 0:arguments[1],g:arguments.length<=2?void 0:arguments[2],b:arguments.length<=3?void 0:arguments[3],a:arguments.length<=4?void 0:arguments[4]})},[parseInt,parseInt,parseInt,Number])("hsl",function(e,t,n,o){var a=" values must be numbers between 0 and 1 inclusive, not ";return 0>n||n>1?i.create("macrocall","Saturation"+a+c(n)+"."):0>o||o>1?i.create("macrocall","Lightness"+a+c(o)+"."):(t=Math.round(t)%360,0>t&&(t+=360),r.create({h:t,s:n,l:o}))},[Number,Number,Number])("hsla",function(e,t,n,o,a){var s=" values must be numbers between 0 and 1 inclusive, not ";return 0>n||n>1?i.create("macrocall","Saturation"+s+c(n)+"."):0>o||o>1?i.create("macrocall","Lightness"+s+c(o)+"."):0>a||a>1?i.create("macrocall","Alpha"+s+c(o)+"."):(t=Math.round(t)%360,0>t&&(t+=360),r.create({h:t,s:n,l:o,a:a}))},[Number,Number,Number,Number]),{weekday:[function(){return["Sun","Mon","Tues","Wednes","Thurs","Fri","Satur"][(new Date).getDay()]+"day"},null],monthday:[function(){return(new Date).getDate()},null],currenttime:[function(){var e=new Date,t=e.getHours()<12,n=e.getHours()%12||12,r=(e.getMinutes()<10?"0":"")+e.getMinutes();return n+":"+r+" "+(t?"A":"P")+"M"},null],currentdate:[function(){return(new Date).toDateString()},null],min:[Math.min,f(Number)],max:[Math.max,f(Number)],abs:[Math.abs,Number],sign:[Math.sign,Number],sin:[Math.sin,Number],cos:[Math.cos,Number],tan:[Math.tan,Number],floor:[Math.floor,Number],round:[Math.round,Number],ceil:[Math.ceil,Number],pow:[o(Math.pow),[Number,Number]],exp:[Math.exp,Number],sqrt:[o(Math.sqrt),Number],log:[o(Math.log),Number],log10:[o(Math.log10),Number],log2:[o(Math.log2),Number],random:[function(e,t){var n=void 0,r=void 0;return t?(n=Math.min(e,t),r=Math.max(e,t)):(n=0,r=e),r+=1,~~(Math.random()*(r-n))+n},[parseInt,e.TypeSignature.optional(parseInt)]],either:[function(){var e;return e=~~(Math.random()*arguments.length),arguments.length<=e?void 0:arguments[e]},f(d)],"":function(){var t=this;Object.keys(this).forEach(function(n){n&&!function(){var r=t[n][0],i=t[n][1];e.add(n,function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];return r.apply(void 0,t)},i)}()})}}[""]()}),function(e){!function(){if(!e.requestAnimationFrame){if(e.webkitRequestAnimationFrame)return e.requestAnimationFrame=e.webkitRequestAnimationFrame,void(e.cancelAnimationFrame=e.webkitCancelAnimationFrame||e.webkitCancelRequestAnimationFrame);var t=0;e.requestAnimationFrame=function(n){var r=(new Date).getTime(),i=Math.max(0,16-(r-t)),o=e.setTimeout(function(){n(r+i)},i);return t=r+i,o},e.cancelAnimationFrame=function(e){clearTimeout(e)}}}(),"function"==typeof define&&define("requestAnimationFrame",[],function(){return e.requestAnimationFrame})}(window),define("macrolib/commands",["requestAnimationFrame","macros","utils","state","passages","engine","internaltypes/twineerror","datatypes/hookset","utils/operationutils"],function(e,t,n,r,i,o,a,s,u){function c(e){return"("+e+" "+o.options.ifid+") "}var l=n.toJSLiteral,f=n.unescape,p=u.printBuiltinValue,d=t.TypeSignature,h=d.Any,m=d.rest,g=d.optional,y=!!localStorage&&function(){try{return localStorage.setItem("test","1"),localStorage.removeItem("test"),!0}catch(e){return!1}}();t.add("display",function(e,t){return{TwineScript_ObjectName:"a (display: "+l(t)+") command",TwineScript_TypeName:"a (display:) command",TwineScript_Print:function(){return i.has(t)?f(i.get(t).get("source")):a.create("macrocall","I can't (display:) the passage '"+t+"' because it doesn't exist.")}}},[String])("print",function(e,t){return{TwineScript_ObjectName:"a (print:) command",TwineScript_TypeName:"a (print:) command",TwineScript_Print:function(){return p(t)}}},[h])("show",function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;t>r;r++)n[r-1]=arguments[r];return{TwineScript_ObjectName:"a (show:) command",TwineScript_TypeName:"a (show:) command",TwineScript_Print:function(){return n.forEach(function(t){return t.forEach(e,function(t){var n=t.data("hiddenSource");return void 0===n?a.create("operation","I can't reveal a hook which is already visible."):void e.renderInto(n,t)})}),""}}},[m(s)])("goto",function(t,n){return{TwineScript_ObjectName:"a (go-to: "+l(n)+") command",TwineScript_TypeName:"a (go-to:) command",TwineScript_Print:function(){return i.has(n)?(e(function(){return o.goToPassage(n)}),{earlyExit:1}):a.create("macrocall","I can't (go-to:) the passage '"+n+"' because it doesn't exist.")}}},[String])("goto-transition",function(t,n,r){return{TwineScript_ObjectName:"a (goto-transition: "+l(n)+","+l(r)+") command",TwineScript_TypeName:"a (goto-transition:) command",TwineScript_Print:function(){return i.has(n)?(e(function(){return o.goToPassage(n,{transitionIn:r,transitionOut:r})}),{earlyExit:1}):a.create("macrocall","I can't (goto-transition:) the passage '"+r+"' because it doesn't exist.")}}},[String,String])("undo",function(){return{TwineScript_ObjectName:"a (undo:) command",TwineScript_TypeName:"a (undo:) command",TwineScript_Print:function(){return r.pastLength<1?a.create("macrocall","I can't (undo:) on the first turn."):(e(function(){return o.goBack()}),{earlyExit:1})}}},[])("live",function(e,t){return{TwineScript_ObjectName:"a (live: "+t+") command",TwineScript_TypeName:"a (live:) command",live:!0,delay:t}},[g(Number)])("stop",function(){return{TwineScript_ObjectName:"a (stop:) command",TwineScript_TypeName:"a (stop:) command",TwineScript_Print:function(){return""}}},[])("savegame",function(e,t,n){if(n=n||"",!y)return!1;var i=r.serialise();if(a.containsError(i))return i;try{return localStorage.setItem(c("Saved Game")+t,i),localStorage.setItem(c("Saved Game Filename")+t,n),!0}catch(e){return!1}},[String,g(String)])("loadgame",function(t,n){return{TwineScript_ObjectName:"a (load-game:) command",TwineScript_TypeName:"a (load-game:) command",TwineScript_Print:function(){var t=localStorage.getItem(c("Saved Game")+n);return t?(r.deserialise(t),e(o.showPassage.bind(o,r.passage,!1)),{earlyExit:1}):a.create("saving","I can't find a save slot named '"+n+"'!")}}},[String])("alert",function(e,t){return{TwineScript_ObjectName:"an (alert:) command",TwineScript_TypeName:"an (alert:) command",TwineScript_Print:function(){return window.alert(t),""}}},[String])("prompt",function(e,t,n){return window.prompt(t,n)||""},[String,String])("confirm",function(e,t){return window.confirm(t)},[String])("openURL",function(e,t){return{TwineScript_ObjectName:"an (open-url:) command",TwineScript_TypeName:"an (open-url:) command",TwineScript_Print:function(){return window.open(t,""),""}}},[String])("reload",function(){return{TwineScript_ObjectName:"a (reload:) command",TwineScript_TypeName:"a (reload:) command",TwineScript_Print:function(){return r.pastLength<1?a.create("infinite","I mustn't (reload:) the page in the starting passage."):(window.location.reload(),{earlyExit:1})}}},[])("gotoURL",function(e,t){return{TwineScript_ObjectName:"a (goto-url:) command",TwineScript_TypeName:"a (goto-url:) command",TwineScript_Print:function(){return window.location.assign(t),{earlyExit:1}}}},[String])("pageURL",function(){return window.location.href},[])}),define("macrolib/datastructures",["jquery","utils/naturalsort","macros","utils/operationutils","state","engine","passages","datatypes/lambda","datatypes/assignmentrequest","internaltypes/twineerror","internaltypes/twinenotifier"],function(e,t,n,r,i,o,a,s,u,c,l){var f=r.objectName,p=(r.typeName,r.subset),d=r.collectionType,h=r.isValidDatamapName,m=r.is,g=r.unique,y=r.clone,v=n.TypeSignature,b=v.optional,w=v.rest,x=v.either,T=v.zeroOrMore,S=v.Any;n.add("set",function(){for(var e="",t=0;t<(arguments.length<=1?0:arguments.length-1);t+=1){var n=arguments.length<=t+1?void 0:arguments[t+1];if("into"===n.operator)return c.create("macrocall","Please say 'to' when using the (set:) macro.");var r=void 0;if(n.src&&n.src.varref){var i=n.src.get(),a=void 0;if(a=c.containsError(i))return a;r=n.dest.set(i)}else r=n.dest.set(n.src);if(c.isPrototypeOf(r))return r;o.options.debug&&(e+=(e?"; ":"")+f(n.dest)+" is now "+f(n.src))}return{TwineScript_TypeName:"a (set:) operation",TwineScript_ObjectName:"a (set:) operation",TwineScript_Unstorable:!0,TwineScript_Print:function(){return e&&l.create(e).render()}}},[w(u)])("put",function(){for(var e="",t=0;t<(arguments.length<=1?0:arguments.length-1);t+=1){var n=arguments.length<=t+1?void 0:arguments[t+1];if("into"!==n.operator)return c.create("macrocall","Please say 'into' when using the (put:) macro.");var r=n.dest.set(n.src);if(c.isPrototypeOf(r))return r;o.options.debug&&(e+=(e?"; ":"")+f(n.dest)+" is now "+f(n.src))}return{TwineScript_TypeName:"a (put:) operation",TwineScript_ObjectName:"a (put:) operation",TwineScript_Unstorable:!0,TwineScript_Print:function(){return e&&l.create(e).render()}}},[w(u)])("move",function(){for(var e="",t=0;t<(arguments.length<=1?0:arguments.length-1);t+=1){var n=arguments.length<=t+1?void 0:arguments[t+1];if("into"!==n.operator)return c.create("macrocall","Please say 'into' when using the (move:) macro.");var r=void 0,i=void 0;if(n.src&&n.src.varref){var a=n.src.get();if(i=c.containsError(a))return i;if(r=n.dest.set(a),i=c.containsError(r))return i;n.src.delete()}else if(r=n.dest.set(n.src),i=c.containsError(r))return i;o.options.debug&&(e+=(e?"; ":"")+f(n.dest)+" is now "+f(n.src))}return{TwineScript_TypeName:"a (move:) operation",TwineScript_ObjectName:"a (move:) operation",TwineScript_Unstorable:!0,TwineScript_Print:function(){return e&&l.create(e).render()}}},[w(u)])(["a","array"],function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];return t},T(S))("range",function e(t,n,r){if(n>r)return e(t,r,n);var i=[n];for(r-=n;r-->0;)i.push(++n);return i},[parseInt,parseInt])("subarray",function(e,t,n,r){return p(t,n,r)},[Array,parseInt,parseInt])("shuffled",function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];return t.reduce(function(e,t,n){var r=Math.random()*(n+1)|0;return r===n?e.push(t):(e.push(e[r]),e[r]=t),e},[]).map(y)},[S,w(S)])("sorted",function(){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;e>r;r++)n[r-1]=arguments[r];return n.sort(t("en"))},[x(Number,String),w(x(Number,String))])("rotated",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];return t*=-1,0===t?c.create("macrocall","I can't rotate these values by 0 positions."):Math.abs(t)>=r.length?c.create("macrocall","I can't rotate these "+r.length+" values by "+t+" positions."):r.slice(t).concat(r.slice(0,t)).map(y)},[parseInt,S,w(S)])("repeated",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];if(0>=t)return c.create("macrocall","I can't repeat these values "+t+" times.");for(var o=[];t-->0;)o.push.apply(o,r);return o.map(y)},[parseInt,w(S)])("interlaced",function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];for(var r=Math.min.apply(Math,_toConsumableArray(t.map(function(e){return e.length}))),i=[],o=0;r>o;o+=1)for(var a=0;a<t.length;a+=1)i.push(y(t[a][o]));return i},[Array,w(Array)]),n.add("altered",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];return r.map(function(n){return t.apply(e,{loop:n})})},[s.TypeSignature("via"),w(S)])("find",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];return t.filter(e,r)},[s.TypeSignature("where"),w(S)])("all-pass",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];var o=t.filter(e,r);return c.containsError(o)||o.length===r.length},[s.TypeSignature("where"),w(S)])("some-pass",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];var o=t.filter(e,r);return c.containsError(o)||o.length>0},[s.TypeSignature("where"),w(S)])("none-pass",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];var o=t.filter(e,r);return c.containsError(o)||0===o.length},[s.TypeSignature("where"),w(S)])("folded",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];return"where"in t&&(r=t.filter(e,r)),c.containsError(r)||r.reduce(function(n,r){return t.apply(e,{making:n,loop:r})})},[x(s.TypeSignature("where via making"),s.TypeSignature("via making")),w(S)]),n.add("datanames",function(e,n){return Array.from(n.keys()).sort(t("en"))},[Map])("datavalues",function(e,n){return Array.from(n.entries()).sort(function(e,n){return[e[0],n[0]].sort(t("en"))[0]===e[0]?-1:1}).map(function(e){return y(e[1])})},[Map])("dataentries",function(e,n){return Array.from(n.entries()).sort(function(e,n){return[e[0],n[0]].sort(t("en"))[0]===e[0]?-1:1}).map(function(e){return new Map([["name",e[0]],["value",y(e[1])]])})},[Map])("history",function(){return i.pastPassageNames()},[])("passage",function(e,t){return y(a.get(t||i.passage))||c.create("macrocall","There's no passage named '"+t+"' in this story.")},[b(String)])("savedgames",function(){function e(e){return"("+e+" "+o.options.ifid+") "}var t=0,n=void 0,r=new Map;do{n=localStorage.key(t),t+=1;var i=e("Saved Game");n&&n.startsWith(i)&&(n=n.slice(i.length),r.set(n,localStorage.getItem(e("Saved Game Filename")+n)))}while(n);return r},[])(["datamap","dm"],function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];var r=void 0,i=new Map,o=t.reduce(function(e,t){var n=void 0;if(c.containsError(e))return e;if(void 0===r)r=t;else{if(n=c.containsError(h(i,r)))return n;if(i.has(r))return c.create("macrocall","You used the same data name ("+f(r)+") twice in the same (datamap:) call.");i.set(r,y(t)),r=void 0}return e},!0);return c.containsError(o)?o:void 0!==r?c.create("macrocall","This datamap has a data name without a value."):i},T(S))(["dataset","ds"],function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];return new Set(t.filter(g).map(y))},T(S))("count",function e(t,n){for(var r=arguments.length,i=Array(r>2?r-2:0),o=2;r>o;o++)i[o-2]=arguments[o];if(i.length>1){var a=void 0,s=i.map(function(r){return e(t,n,r)});return(a=c.containsError(s))?a:s.reduce(function(e,t){return e+t},0)}var u=i[0];switch(d(n)){case"dataset":case"datamap":return c.create("macrocall","(count:) shouldn't be given a datamap or dataset.","You should use the 'contains' operator instead. For instance, write: $variable contains 'value'.");case"string":return"string"!=typeof u?c.create("macrocall",f(n)+" can't contain  "+f(u)+" because it isn't a string."):u?n.split(u).length-1:0;case"array":return n.reduce(function(e,t){return e+m(t,u)},0);default:return c.create("macrocall",f(n)+" can't contain values, let alone "+f(u)+".")}},[S,w(S)])}),define("macrolib/stylechangers",["jquery","macros","utils","utils/selectors","datatypes/colour","datatypes/changercommand","datatypes/lambda","internaltypes/changedescriptor","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,u){var c=t.TypeSignature,l=c.either,f=c.wrapped,p=c.rest,d=c.Any,h=[f(Boolean,'If you gave a number, you may instead want to check that the number is not 0. If you gave a string, you may instead want to check that the string is not "".')];e(function(){return e(n.storyElement).on("mouseenter.hover-macro","[hover=false]",function(){var t=e(this),n=t.data("hoverChanger");t.data({mouseoutStyle:t.attr("style")||""}),s.create({target:t},n).update(),t.attr("hover",!0)}).on("mouseleave.hover-macro","[hover=true]",function(){var t=e(this),n=t.data("mouseoutStyle");t.attr("style",n).removeData("mouseoutStyle").attr("hover",!1)})});var m=["dissolve","shudder","pulse"];t.addChanger("if",function(e,t){return o.create("if",[t])},function(e,t){return e.enabled=e.enabled&&t},h)("unless",function(e,t){return o.create("unless",[!t])},function(e,t){return e.enabled=e.enabled&&t},h)("elseif",function(e,t){return"lastHookShown"in e.stack[0]?o.create("elseif",[e.stack[0].lastHookShown===!1&&!!t]):u.create("macrocall","There's no (if:) or something else before this to do (else-if:) with.")},function(e,t){return e.enabled=e.enabled&&t},h)("else",function(e){return"lastHookShown"in e.stack[0]?o.create("else",[e.stack[0].lastHookShown===!1]):u.create("macrocall","There's nothing before this to do (else:) with.")},function(e,t){return e.enabled=e.enabled&&t},null)("hidden",function(){return o.create("hidden")},function(e){return e.enabled=!1},null)("hook",function(e,t){return o.create("hook",[t])},function(e,t){return e.attr.push({name:t})},[String])(["for","loop"],function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];return t.loop?o.create("for",[t,r]):u.create("macrocall","The lambda provided to (for:) must refer to a temp variable, not just 'it'.")},function(e,t,n){return e.loopVars[t.loop]=t.filter(e.section,n)},[a.TypeSignature("where"),p(d)])(["transition","t8n"],function(e,t){return t=n.insensitiveName(t),-1===m.indexOf(t)?u.create("macrocall","'"+t+"' is not a valid (transition:)","Only the following names are recognised (capitalisation and hyphens ignored): "+m.join(", ")):o.create("transition",[t])},function(e,t){return e.transition=t,e},[String])(["transition-time","t8n-time"],function(e,t){return 0>=t?u.create("macrocall","(transition-time:) should be a positive number of (milli)seconds, not "+t):o.create("transition-time",[t])},function(e,t){return e.transitionTime=t,e},[Number])("font",function(e,t){return o.create("font",[t])},function(e,t){return e.styles.push({"font-family":t}),e},[String])("align",function(e,t){var n=void 0,r=t.indexOf("><");if(!/^(==+>|<=+|=+><=+|<==+>)$/.test(t))return u.create("macrocall",'The (align:) macro requires an alignment arrow ("==>", "<==", "==><=" etc.) be provided, not "'+t+'"');if(~r){var i=Math.round(r/(t.length-2)*50);n=Object.assign({"text-align":"center","max-width":"50%"},25===i?{"margin-left":"auto","margin-right":"auto"}:{"margin-left":i+"%"})}else n="<"===t[0]&&">"===t.slice(-1)?{"text-align":"justify","max-width":"50%"}:t.includes(">")?{"text-align":"right"}:{"text-align":"left"};return n.display="block",o.create("align",[n])},function(e,t){e.styles.push(t)},[String])(["text-colour","text-color","color","colour"],function(e,t){return i.isPrototypeOf(t)&&(t=t.toRGBAString(t)),o.create("text-colour",[t])},function(e,t){return e.styles.push({color:t}),e},[l(String,i)])("text-rotate",function(e,t){return o.create("text-rotate",[t])},function(t,n){return t.styles.push({display:"inline-block",transform:function(){var t=e(this).css("transform")||"";return"none"===t&&(t=""),t+" rotate("+n+"deg)"}}),t},[Number])("background",function(e,t){return i.isPrototypeOf(t)&&(t=t.toRGBAString(t)),o.create("background",[t])},function(t,r){var o=void 0;return o=i.isHexString(r)||i.isCSS3Function(r)?{"background-color":r}:{"background-size":"cover","background-image":"url("+r+")"},t.styles.push(o,{display:function(){return n.childrenProbablyInline(e(this))?"initial":"block"}}),t},[l(String,i)]).apply(void 0,_toConsumableArray(function(){var t={color:"transparent"},r=Object.assign(Object.create(null),{none:{},bold:{"font-weight":"bold"},italic:{"font-style":"italic"},underline:{"text-decoration":"underline"},strike:{"text-decoration":"line-through"},superscript:{"vertical-align":"super","font-size":".83em"},subscript:{"vertical-align":"sub","font-size":".83em"},blink:{animation:"fade-in-out 1s steps(1,end) infinite alternate"},shudder:{animation:"shudder linear 0.1s 0s infinite",display:"inline-block"},mark:{"background-color":"hsla(60, 100%, 50%, 0.6)"},condense:{"letter-spacing":"-0.08em"},expand:{"letter-spacing":"0.1em"},outline:[{"text-shadow":function(){var t=e(this).css("color");return"-1px -1px 0 "+t+", 1px -1px 0 "+t+",-1px  1px 0 "+t+", 1px  1px 0 "+t}},{color:function(){for(var t=e(this);t.length&&t[0]!==document;t=t.parent()){var n=t.css("background-color");if("transparent"!==n&&!n.match(/^\w+a\(.+?,\s*0\s*\)$/))return n}return"#fff"}}],shadow:{"text-shadow":function(){return"0.08em 0.08em 0.08em "+e(this).css("color")}},emboss:{"text-shadow":function(){return"0.08em 0.08em 0em "+e(this).css("color")}},smear:[{"text-shadow":function(){var t=e(this).css("color");return"0em   0em 0.02em "+t+",-0.2em 0em  0.5em "+t+", 0.2em 0em  0.5em "+t}},t],blur:[{"text-shadow":function(){return"0em 0em 0.08em "+e(this).css("color")}},t],blurrier:[{"text-shadow":function(){return"0em 0em 0.2em "+e(this).css("color")},"user-select":"none"},t],mirror:{display:"inline-block",transform:"scaleX(-1)"},upsidedown:{display:"inline-block",transform:"scaleY(-1)"},fadeinout:{animation:"fade-in-out 2s ease-in-out infinite alternate"},rumble:{animation:"rumble linear 0.1s 0s infinite",display:"inline-block"}});return["text-style",function(e,t){return t=n.insensitiveName(t),t in r?o.create("text-style",[t]):u.create("macrocall","'"+t+"' is not a valid (text-style:)","Only the following names are recognised (capitalisation and hyphens ignored): "+Object.keys(r).join(", "))},function(e,t){return n.assertMustHave(r,[t]),e.styles="none"===t?[]:e.styles.concat(r[t]),e}]}()).concat([[String]]))("hover-style",function(e,t){var n=s.create(),r=(t.run(n),n.summary());return r+""=="styles"||r.every(function(e){return"styles"===e||"attr"===e})&&n.attr.every(function(e){return Object.keys(e)+""=="style"})?o.create("hover-style",[t]):u.create("macrocall","The changer given to (hover-style:) must only change the hook's style.")},function(e,t){return e.data.hoverChanger=t,e.attr.push({hover:!1}),e},[o])("css",function(e,t){return t.trim().endsWith(";")||(t+=";"),o.create("css",[t])},function(t,n){return t.attr.push({
-style:function(){return(e(this).attr("style")||"")+n}}),t},[String])}),define("internaltypes/enchantment",["jquery","utils","internaltypes/changedescriptor"],function(e,t,n){var r={create:function(n){return t.assertOnlyHas(n,["scope","section","attr","data","changer","functions"]),Object.assign(Object.create(this),{enchantments:e()},n)},enchantScope:function(){var r=this,i=this.attr,o=this.data,a=this.functions,s=this.section,u=this.changer,c=this.scope;c instanceof e&&(c=Array.prototype.map.call(c,function(t){return e(t)})),this.enchantments=e(),c.forEach(s,function(e){var c=e.wrapAll("<tw-enchantment>").parent();if(i&&c.attr(i),o&&c.data(o),a&&a.forEach(function(e){return e(c)}),u){var l=n.create({section:s,target:c});if(u.run(l),l.update(),e.is(t.storyElement)){var f=Object.keys(Object.assign.apply(Object,[{}].concat(_toConsumableArray(l.styles))));e.css(f.reduce(function(e,t){return e[t]="inherit",e},{})),c.data({enchantedProperties:f})}}e.is(t.storyElement)&&c.css({width:"100%",height:"100%"}),r.enchantments=r.enchantments.add(c)})},disenchant:function(){this.enchantments.each(function(){var n=e(this).contents();n.unwrap();var r=e(this).data("enchantedProperties");r&&n.has(t.storyElement)&&t.storyElement.css(r.reduce(function(e,t){return e[t]="",e},{}))})}};return Object.freeze(r)}),define("macrolib/enchantments",["jquery","utils","utils/selectors","utils/operationutils","macros","datatypes/hookset","datatypes/changercommand","internaltypes/enchantment","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,u){function c(n,r){return e(function(){t.storyElement.on(n.event+".enchantment","."+n.classList.replace(/ /g,"."),function(){var t=e(this),n=t.data("enchantmentEvent");n&&n(t)})}),[function(){for(var e=arguments.length,t=Array(e>1?e-1:0),n=1;e>n;n++)t[n-1]=arguments[n];return t.every(Boolean)?a.create(r,t.map(o.from)):u.create("datatype","A string given to this ("+r+":) macro was empty.")},function(e,t){e.enabled=!1,n.rerender&&(e.newTargets=(e.newTargets||[]).concat({target:t,append:n.rerender}));var r=s.create({functions:[function(e){e.attr("class",e.children().is("tw-story, tw-sidebar, tw-passage")?n.blockClassList:n.classList)}],attr:(n.classList+"").match(/\b(?:link|enchantment-clickblock)\b/)?{tabIndex:"0"}:{},data:{enchantmentEvent:function(){if(n.once){var t=e.section.enchantments.indexOf(r);e.section.enchantments.splice(t,1),r.disenchant()}e.section.renderInto(e.source,null,Object.assign({},e,{enabled:!0}))}},scope:t,section:e.section});return e.section.enchantments.push(r),r.enchantScope(),e},p(o,String)]}var l=r.is,f=i.TypeSignature,p=f.either,d=f.rest;i.add("enchant",function(e,t,n){return{TwineScript_ObjectName:"an (enchant:) command",TwineScript_TypeName:"an (enchant:) command",TwineScript_Print:function(){var r=n.summary();if(r.includes("newTargets")||r.includes("target"))return u.create("macrocall","The changer given to (enchant:) can't include a revision command like (replace:) or (append:).");var i=s.create({scope:o.from(t),changer:n,section:e});return e.enchantments.push(i),i.enchantScope(),""}}},[p(o,String),a]);var h=["replace","append","prepend"];h.forEach(function(t){i.addChanger(t,function(){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;e>r;r++)n[r-1]=arguments[r];return n.every(Boolean)?a.create(t,n.map(o.from)):u.create("datatype","A string given to this ("+t+":) macro was empty.")},function(n){for(var r,i=arguments.length,o=Array(i>1?i-1:0),a=1;i>a;a++)o[a-1]=arguments[a];var s=e(n.target).parents().filter("tw-collapsed").length>0;return s||(n.attr=[].concat(_toConsumableArray(n.attr),[{collapsing:!1}])),n.newTargets=n.newTargets||[],(r=n.newTargets).push.apply(r,_toConsumableArray(o.filter(function(e){return!n.newTargets.some(function(n){var r=n.target,i=n.append;return l(e,r)&&t===i})}).map(function(e){return{target:e,append:t}}))),n},d(p(o,String)))}),e(function(){t.storyElement.on("click.enchantment",function(){Array.from(e(this).parents(".enchantment-clickblock")).sort(function(e,t){return 8&e.compareDocumentPosition(t)?1:-1}).forEach(function(t){var n=e(t).data("enchantmentEvent");n&&n()})})});var m=[{name:"click",enchantDesc:{event:"click",once:!0,rerender:"",classList:"link enchantment-link",blockClassList:"enchantment-clickblock"}},{name:"mouseover",enchantDesc:{event:"mouseenter",once:!0,rerender:"",classList:"enchantment-mouseover"}},{name:"mouseout",enchantDesc:{event:"mouseleave",once:!0,rerender:"",classList:"enchantment-mouseout"}}];m.forEach(function(e){return i.addChanger.apply(i,[e.name].concat(_toConsumableArray(c(e.enchantDesc,e.name))))}),h.forEach(function(e){m.forEach(function(t){var n=Object.assign({},t.enchantDesc,{rerender:e}),r=t.name+"-"+e;i.addChanger.apply(i,[r].concat(_toConsumableArray(c(n,r))))})})}),define("macrolib/links",["jquery","macros","utils","utils/selectors","state","passages","engine","datatypes/changercommand","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,u){var c=t.TypeSignature.optional,l="Links can't have empty strings for their displayed text.";e(function(){return e(n.storyElement).on("click.passage-link",r.internalLink,function(){var t=e(this),n=t.parent().data("clickEvent");if(n)return void n(t);var r=t.attr("passage-name");return r?void a.goToPassage(r,!1):t.is("[undo]")?void a.goBack():void 0})}),[["link","link-replace"],["link-reveal"],["link-repeat"]].forEach(function(e){return t.addChanger(e,function(t,n){return n?s.create(e[0],[n]):u.create("macrocall",l)},function(t,n){t.innerSource||(t.innerSource=t.source),t.source="<tw-link tabindex=0>"+n+"</tw-link>",t.append="link"===e[0]?"replace":"append",t.data.clickEvent=function(n){t.source=t.innerSource,t.section.renderInto(t.innerSource+"",null,t),"link-reveal"===e[0]&&n.contents().unwrap()}},[String])}),t.add(["link-goto"],function(t,r,a){return r?{TwineScript_TypeName:"a (link-goto: "+n.toJSLiteral(r)+", "+n.toJSLiteral(a)+") command",TwineScript_ObjectName:"a (link-goto:) command",TwineScript_Print:function(){var s=t.evaluateTwineMarkup(n.unescape(a||r));if(s instanceof e)return s;if(!o.has(s))return'<tw-broken-link passage-name="'+n.escape(s)+'">'+(r||a)+"</tw-broken-link>";var u=i.passageNameVisited(s);return"<tw-link tabindex=0 "+(u>0?'class="visited" ':"")+'passage-name="'+n.escape(s)+'">'+(r||a)+"</tw-link>"}}:u.create("macrocall",l)},[String,c(String)])("link-undo",function(e,t){return t?{TwineScript_ObjectName:"a (link-undo:"+n.toJSLiteral(t)+") command",TwineScript_TypeName:"a (link-undo:) command",TwineScript_Print:function(){return i.pastLength<1?u.create("macrocall","I can't use (link-undo:) on the first turn."):"<tw-link tabindex=0 undo>"+t+"</tw-link>"}}:u.create("macrocall",l)},[String])}),define("repl",["utils","markup","twinescript/compiler","twinescript/environ"],function(e,t,n,r){window.REPL=function(e){var i=n(t.lex("(print:"+e+")"));console.log(i);var o=r({}).eval(i);return o.TwineScript_Print?o.TwineScript_Print():o},window.LEX=function(e){var n=t.lex(e);return 1===n.length?n[0]:n}}),require.config({paths:{jquery:"../node_modules/jquery/dist/jquery",almond:"../node_modules/almond/almond","es6-shim":"../node_modules/es6-shim/es6-shim",requestAnimationFrame:"../node_modules/requestanimationframe/app/requestAnimationFrame",jqueryplugins:"utils/jqueryplugins",markup:"./markup/markup",lexer:"./markup/lexer",patterns:"./markup/patterns"},deps:["jquery","es6-shim","jqueryplugins"]}),require(["jquery","debugmode","renderer","state","engine","passages","utils/selectors","macros","macrolib/values","macrolib/commands","macrolib/datastructures","macrolib/stylechangers","macrolib/enchantments","macrolib/links","repl"],function($,DebugMode,Renderer,State,Engine,Passages,Selectors){function _eval(text){return eval(text+"")}var _installHandlers=function(){var e=$(document.documentElement);e.on("keydown",function(e){13===e.which&&"0"===e.target.getAttribute("tabindex")&&$(e.target).trigger("click")}),Engine.options.debug&&DebugMode(),_installHandlers=null};!function(e){window.onerror=function(t,n,r,i,o){var a=o&&o.stack&&"\n"+o.stack.replace(/\([^\)]+\)/g,"")+"\n"||"("+t+")\n";alert("Sorry to interrupt, but this page's code has got itself in a mess. "+a+"(This is probably due to a bug in the Harlowe game engine.)"),window.onerror=e,"function"==typeof e&&e.apply(void 0,arguments)}}(window.onerror),$(function(){var e=$(Selectors.storyData);if(0!==e.length){var t=e.attr("options");t&&t.split(/\s/).forEach(function(e){Renderer.options[e]=Engine.options[e]=!0});var n=e.attr("startnode");return Renderer.options.ifid=Engine.options.ifid=e.attr("ifid"),n||(n=[].reduce.call($(Selectors.passageData),function(e,t){var n=t.getAttribute("pid");return e>n?n:e},1/0)),n=$(Selectors.passageData+"[pid="+n+"]").attr("name"),_installHandlers(),$(Selectors.script).each(function(e){try{_eval($(this).html())}catch(t){alert("There is a problem with this story's script (#"+(e+1)+"):\n\n"+t.message)}}),$(Selectors.stylesheet).each(function(e){$(document.head).append('<style data-title="Story stylesheet '+(e+1)+'">'+$(this).html())}),window.location.hash&&!window.location.hash.includes("stories")&&State.load(window.location.hash)?void Engine.showPassage(State.passage):void Engine.goToPassage(n)}})}),define("harlowe",function(){}),require(["harlowe"])}();</script>
+function(e,t){"function"==typeof define&&define.amd?define("es6-shim",t):"object"===("undefined"==typeof exports?"undefined":_typeof(exports))?module.exports=t():e.returnExports=t()}(this,function(){var e,t=Function.call.bind(Function.apply),n=Function.call.bind(Function.call),r=Array.isArray,i=Object.keys,o=function(e){try{return e(),!1}catch(e){return!0}},a=function(e){try{return e()}catch(e){return!1}},s=function(e){return function(){return!t(e,this,arguments)}}(o),c=!!Object.defineProperty&&function(){return!o(function(){Object.defineProperty({},"x",{get:function(){}})})}(),u="foo"===function(){}.name,l=Function.call.bind(Array.prototype.forEach),f=Function.call.bind(Array.prototype.reduce),p=Function.call.bind(Array.prototype.filter),d=Function.call.bind(Array.prototype.some),h=function(e,t,n,r){!r&&t in e||(c?Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:!0,value:n}):e[t]=n)},y=function(e,t,n){l(i(t),function(r){var i=t[r];h(e,r,i,!!n)})},g=Function.call.bind(Object.prototype.toString),m="function"==typeof/abc/?function(e){return"function"==typeof e&&"[object Function]"===g(e)}:function(e){return"function"==typeof e},v={getter:function(e,t,n){if(!c)throw new TypeError("getters require true ES5 support");Object.defineProperty(e,t,{configurable:!0,enumerable:!1,get:n})},proxy:function(e,t,n){if(!c)throw new TypeError("getters require true ES5 support");var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,{configurable:r.configurable,enumerable:r.enumerable,get:function(){return e[t]},set:function(n){e[t]=n}})},redefine:function(e,t,n){if(c){var r=Object.getOwnPropertyDescriptor(e,t);r.value=n,Object.defineProperty(e,t,r)}else e[t]=n},defineByDescriptor:function(e,t,n){c?Object.defineProperty(e,t,n):"value"in n&&(e[t]=n.value)},preserveToString:function(e,t){t&&m(t.toString)&&h(e,"toString",t.toString.bind(t),!0)}},b=Object.create||function(e,t){var n=function(){};n.prototype=e;var r=new n;return void 0!==t&&i(t).forEach(function(e){v.defineByDescriptor(r,e,t[e])}),r},w=function(e,t){return!!Object.setPrototypeOf&&a(function(){var n=function t(n){var r=new e(n);return Object.setPrototypeOf(r,t.prototype),r};return Object.setPrototypeOf(n,e),n.prototype=b(e.prototype,{constructor:{value:n}}),t(n)})},x=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if("undefined"!=typeof global)return global;throw new Error("unable to locate global object")}(),T=x.isFinite,S=Function.call.bind(String.prototype.indexOf),O=Function.apply.bind(Array.prototype.indexOf),j=Function.call.bind(Array.prototype.concat),k=Function.call.bind(String.prototype.slice),A=Function.call.bind(Array.prototype.push),C=Function.apply.bind(Array.prototype.push),E=Function.call.bind(Array.prototype.shift),N=Math.max,_=Math.min,I=Math.floor,P=Math.abs,M=Math.exp,D=Math.log,L=Math.sqrt,q=Function.call.bind(Object.prototype.hasOwnProperty),R=function(){},F=x.Map,H=F&&F.prototype.delete,V=F&&F.prototype.get,$=F&&F.prototype.has,B=F&&F.prototype.set,z=x.Symbol||{},W=z.species||"@@species",U=Number.isNaN||function(e){return e!==e},G=Number.isFinite||function(e){return"number"==typeof e&&T(e)},X=m(Math.sign)?Math.sign:function(e){var t=Number(e);return 0===t?t:U(t)?t:t<0?-1:1},Y=function(e){return"[object Arguments]"===g(e)},J=function(e){return null!==e&&"object"===(void 0===e?"undefined":_typeof(e))&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==g(e)&&"[object Function]"===g(e.callee)},Z=Y(arguments)?Y:J,Q={primitive:function(e){return null===e||"function"!=typeof e&&"object"!==(void 0===e?"undefined":_typeof(e))},string:function(e){return"[object String]"===g(e)},regex:function(e){return"[object RegExp]"===g(e)},symbol:function(e){return"function"==typeof x.Symbol&&"symbol"===(void 0===e?"undefined":_typeof(e))}},K=function(e,t,n){var r=e[t];h(e,t,n,!0),v.preserveToString(e[t],r)},ee="function"==typeof z&&"function"==typeof z.for&&Q.symbol(z()),te=Q.symbol(z.iterator)?z.iterator:"_es6-shim iterator_";x.Set&&"function"==typeof(new x.Set)["@@iterator"]&&(te="@@iterator"),x.Reflect||h(x,"Reflect",{},!0);var ne=x.Reflect,re=String,ie="undefined"!=typeof document&&document?document.all:null,oe=null==ie?function(e){return null==e}:function(e){return null==e&&e!==ie},ae={Call:function(e,n){var r=arguments.length>2?arguments[2]:[];if(!ae.IsCallable(e))throw new TypeError(e+" is not a function");return t(e,n,r)},RequireObjectCoercible:function(e,t){if(oe(e))throw new TypeError(t||"Cannot call method on "+e);return e},TypeIsObject:function(e){return void 0!==e&&null!==e&&!0!==e&&!1!==e&&("function"==typeof e||"object"===(void 0===e?"undefined":_typeof(e))||e===ie)},ToObject:function(e,t){return Object(ae.RequireObjectCoercible(e,t))},IsCallable:m,IsConstructor:function(e){return ae.IsCallable(e)},ToInt32:function(e){return ae.ToNumber(e)>>0},ToUint32:function(e){return ae.ToNumber(e)>>>0},ToNumber:function(e){if("[object Symbol]"===g(e))throw new TypeError("Cannot convert a Symbol value to a number");return+e},ToInteger:function(e){var t=ae.ToNumber(e);return U(t)?0:0!==t&&G(t)?(t>0?1:-1)*I(P(t)):t},ToLength:function(e){var t=ae.ToInteger(e);return t<=0?0:t>Number.MAX_SAFE_INTEGER?Number.MAX_SAFE_INTEGER:t},SameValue:function(e,t){return e===t?0!==e||1/e==1/t:U(e)&&U(t)},SameValueZero:function(e,t){return e===t||U(e)&&U(t)},IsIterable:function(e){return ae.TypeIsObject(e)&&(void 0!==e[te]||Z(e))},GetIterator:function(t){if(Z(t))return new e(t,"value");var n=ae.GetMethod(t,te);if(!ae.IsCallable(n))throw new TypeError("value is not an iterable");var r=ae.Call(n,t);if(!ae.TypeIsObject(r))throw new TypeError("bad iterator");return r},GetMethod:function(e,t){var n=ae.ToObject(e)[t];if(!oe(n)){if(!ae.IsCallable(n))throw new TypeError("Method not callable: "+t);return n}},IteratorComplete:function(e){return!!e.done},IteratorClose:function(e,t){var n=ae.GetMethod(e,"return");if(void 0!==n){var r,i;try{r=ae.Call(n,e)}catch(e){i=e}if(!t){if(i)throw i;if(!ae.TypeIsObject(r))throw new TypeError("Iterator's return method returned a non-object.")}}},IteratorNext:function(e){var t=arguments.length>1?e.next(arguments[1]):e.next();if(!ae.TypeIsObject(t))throw new TypeError("bad iterator");return t},IteratorStep:function(e){var t=ae.IteratorNext(e);return!ae.IteratorComplete(t)&&t},Construct:function(e,t,n,r){var i=void 0===n?e:n;if(!r&&ne.construct)return ne.construct(e,t,i);var o=i.prototype;ae.TypeIsObject(o)||(o=Object.prototype);var a=b(o),s=ae.Call(e,a,t);return ae.TypeIsObject(s)?s:a},SpeciesConstructor:function(e,t){var n=e.constructor;if(void 0===n)return t;if(!ae.TypeIsObject(n))throw new TypeError("Bad constructor");var r=n[W];if(oe(r))return t;if(!ae.IsConstructor(r))throw new TypeError("Bad @@species");return r},CreateHTML:function(e,t,n,r){var i=ae.ToString(e),o="<"+t;if(""!==n){o+=" "+n+'="'+ae.ToString(r).replace(/"/g,"&quot;")+'"'}return o+">"+i+"</"+t+">"},IsRegExp:function(e){if(!ae.TypeIsObject(e))return!1;var t=e[z.match];return void 0!==t?!!t:Q.regex(e)},ToString:function(e){return re(e)}};if(c&&ee){var se=function(e){if(Q.symbol(z[e]))return z[e];var t=z.for("Symbol."+e);return Object.defineProperty(z,e,{configurable:!1,enumerable:!1,writable:!1,value:t}),t};if(!Q.symbol(z.search)){var ce=se("search"),ue=String.prototype.search;h(RegExp.prototype,ce,function(e){return ae.Call(ue,e,[this])});var le=function(e){var t=ae.RequireObjectCoercible(this);if(!oe(e)){var n=ae.GetMethod(e,ce);if(void 0!==n)return ae.Call(n,e,[t])}return ae.Call(ue,t,[ae.ToString(e)])};K(String.prototype,"search",le)}if(!Q.symbol(z.replace)){var fe=se("replace"),pe=String.prototype.replace;h(RegExp.prototype,fe,function(e,t){return ae.Call(pe,e,[this,t])});var de=function(e,t){var n=ae.RequireObjectCoercible(this);if(!oe(e)){var r=ae.GetMethod(e,fe);if(void 0!==r)return ae.Call(r,e,[n,t])}return ae.Call(pe,n,[ae.ToString(e),t])};K(String.prototype,"replace",de)}if(!Q.symbol(z.split)){var he=se("split"),ye=String.prototype.split;h(RegExp.prototype,he,function(e,t){return ae.Call(ye,e,[this,t])});var ge=function(e,t){var n=ae.RequireObjectCoercible(this);if(!oe(e)){var r=ae.GetMethod(e,he);if(void 0!==r)return ae.Call(r,e,[n,t])}return ae.Call(ye,n,[ae.ToString(e),t])};K(String.prototype,"split",ge)}var me=Q.symbol(z.match),ve=me&&function(){var e={};return e[z.match]=function(){return 42},42!=="a".match(e)}();if(!me||ve){var be=se("match"),we=String.prototype.match;h(RegExp.prototype,be,function(e){return ae.Call(we,e,[this])});var xe=function(e){var t=ae.RequireObjectCoercible(this);if(!oe(e)){var n=ae.GetMethod(e,be);if(void 0!==n)return ae.Call(n,e,[t])}return ae.Call(we,t,[ae.ToString(e)])};K(String.prototype,"match",xe)}}var Te=function(e,t,n){v.preserveToString(t,e),Object.setPrototypeOf&&Object.setPrototypeOf(e,t),c?l(Object.getOwnPropertyNames(e),function(r){r in R||n[r]||v.proxy(e,r,t)}):l(Object.keys(e),function(r){r in R||n[r]||(t[r]=e[r])}),t.prototype=e.prototype,v.redefine(e.prototype,"constructor",t)},Se=function(){return this},Oe=function(e){c&&!q(e,W)&&v.getter(e,W,Se)},je=function(e,t){var n=t||function(){return this};h(e,te,n),!e[te]&&Q.symbol(te)&&(e[te]=n)},ke=function(e,t,n){c?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n},Ae=function(e,t,n){if(ke(e,t,n),!ae.SameValue(e[t],n))throw new TypeError("property is nonconfigurable")},Ce=function(e,t,n,r){if(!ae.TypeIsObject(e))throw new TypeError("Constructor requires `new`: "+t.name);var i=t.prototype;ae.TypeIsObject(i)||(i=n);var o=b(i);for(var a in r)if(q(r,a)){var s=r[a];h(o,a,s,!0)}return o};if(String.fromCodePoint&&1!==String.fromCodePoint.length){var Ee=String.fromCodePoint;K(String,"fromCodePoint",function(e){return ae.Call(Ee,this,arguments)})}var Ne={fromCodePoint:function(e){for(var t,n=[],r=0,i=arguments.length;r<i;r++){if(t=Number(arguments[r]),!ae.SameValue(t,ae.ToInteger(t))||t<0||t>1114111)throw new RangeError("Invalid code point "+t);t<65536?A(n,String.fromCharCode(t)):(t-=65536,A(n,String.fromCharCode(55296+(t>>10))),A(n,String.fromCharCode(t%1024+56320)))}return n.join("")},raw:function(e){var t=ae.ToObject(e,"bad callSite"),n=ae.ToObject(t.raw,"bad raw value"),r=n.length,i=ae.ToLength(r);if(i<=0)return"";for(var o,a,s,c,u=[],l=0;l<i&&(o=ae.ToString(l),s=ae.ToString(n[o]),A(u,s),!(l+1>=i));)a=l+1<arguments.length?arguments[l+1]:"",c=ae.ToString(a),A(u,c),l+=1;return u.join("")}};String.raw&&"xy"!==String.raw({raw:{0:"x",1:"y",length:2}})&&K(String,"raw",Ne.raw),y(String,Ne);var _e=function e(t,n){if(n<1)return"";if(n%2)return e(t,n-1)+t;var r=e(t,n/2);return r+r},Ie={repeat:function(e){var t=ae.ToString(ae.RequireObjectCoercible(this)),n=ae.ToInteger(e);if(n<0||n>=1/0)throw new RangeError("repeat count must be less than infinity and not overflow maximum string size");return _e(t,n)},startsWith:function(e){var t=ae.ToString(ae.RequireObjectCoercible(this));if(ae.IsRegExp(e))throw new TypeError('Cannot call method "startsWith" with a regex');var n,r=ae.ToString(e);arguments.length>1&&(n=arguments[1]);var i=N(ae.ToInteger(n),0);return k(t,i,i+r.length)===r},endsWith:function(e){var t=ae.ToString(ae.RequireObjectCoercible(this));if(ae.IsRegExp(e))throw new TypeError('Cannot call method "endsWith" with a regex');var n,r=ae.ToString(e),i=t.length;arguments.length>1&&(n=arguments[1]);var o=void 0===n?i:ae.ToInteger(n),a=_(N(o,0),i);return k(t,a-r.length,a)===r},includes:function(e){if(ae.IsRegExp(e))throw new TypeError('"includes" does not accept a RegExp');var t,n=ae.ToString(e);return arguments.length>1&&(t=arguments[1]),-1!==S(this,n,t)},codePointAt:function(e){var t=ae.ToString(ae.RequireObjectCoercible(this)),n=ae.ToInteger(e),r=t.length;if(n>=0&&n<r){var i=t.charCodeAt(n),o=n+1===r;if(i<55296||i>56319||o)return i;var a=t.charCodeAt(n+1);return a<56320||a>57343?i:1024*(i-55296)+(a-56320)+65536}}};if(String.prototype.includes&&!1!=="a".includes("a",1/0)&&K(String.prototype,"includes",Ie.includes),String.prototype.startsWith&&String.prototype.endsWith){var Pe=o(function(){"/a/".startsWith(/a/)}),Me=a(function(){return!1==="abc".startsWith("a",1/0)});Pe&&Me||(K(String.prototype,"startsWith",Ie.startsWith),K(String.prototype,"endsWith",Ie.endsWith))}if(ee){a(function(){var e=/a/;return e[z.match]=!1,"/a/".startsWith(e)})||K(String.prototype,"startsWith",Ie.startsWith);a(function(){var e=/a/;return e[z.match]=!1,"/a/".endsWith(e)})||K(String.prototype,"endsWith",Ie.endsWith);a(function(){var e=/a/;return e[z.match]=!1,"/a/".includes(e)})||K(String.prototype,"includes",Ie.includes)}y(String.prototype,Ie);var De=["\t\n\v\f\r \xa0\u1680\u180e\u2000\u2001\u2002\u2003","\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028","\u2029\ufeff"].join(""),Le=new RegExp("(^["+De+"]+)|(["+De+"]+$)","g"),qe=function(){return ae.ToString(ae.RequireObjectCoercible(this)).replace(Le,"")},Re=["\x85","\u200b","\ufffe"].join(""),Fe=new RegExp("["+Re+"]","g"),He=/^[-+]0x[0-9a-f]+$/i,Ve=Re.trim().length!==Re.length;h(String.prototype,"trim",qe,Ve);var $e=function(e){return{value:e,done:0===arguments.length}},Be=function(e){ae.RequireObjectCoercible(e),this._s=ae.ToString(e),this._i=0};Be.prototype.next=function(){var e=this._s,t=this._i;if(void 0===e||t>=e.length)return this._s=void 0,$e();var n,r,i=e.charCodeAt(t);return i<55296||i>56319||t+1===e.length?r=1:(n=e.charCodeAt(t+1),r=n<56320||n>57343?1:2),this._i=t+r,$e(e.substr(t,r))},je(Be.prototype),je(String.prototype,function(){return new Be(this)});var ze={from:function(e){var t,r=this;arguments.length>1&&(t=arguments[1]);var i,o;if(void 0===t)i=!1;else{if(!ae.IsCallable(t))throw new TypeError("Array.from: when provided, the second argument must be a function");arguments.length>2&&(o=arguments[2]),i=!0}var a,s,c,u=void 0!==(Z(e)||ae.GetMethod(e,te));if(u){s=ae.IsConstructor(r)?Object(new r):[];var l,f,p=ae.GetIterator(e);for(c=0;;){if(!1===(l=ae.IteratorStep(p)))break;f=l.value;try{i&&(f=void 0===o?t(f,c):n(t,o,f,c)),s[c]=f}catch(e){throw ae.IteratorClose(p,!0),e}c+=1}a=c}else{var d=ae.ToObject(e);a=ae.ToLength(d.length),s=ae.IsConstructor(r)?Object(new r(a)):new Array(a);var h;for(c=0;c<a;++c)h=d[c],i&&(h=void 0===o?t(h,c):n(t,o,h,c)),Ae(s,c,h)}return s.length=a,s},of:function(){for(var e=arguments.length,t=this,n=r(t)||!ae.IsCallable(t)?new Array(e):ae.Construct(t,[e]),i=0;i<e;++i)Ae(n,i,arguments[i]);return n.length=e,n}};y(Array,ze),Oe(Array),e=function(e,t){this.i=0,this.array=e,this.kind=t},y(e.prototype,{next:function(){var t=this.i,n=this.array;if(!(this instanceof e))throw new TypeError("Not an ArrayIterator");if(void 0!==n)for(var r=ae.ToLength(n.length);t<r;t++){var i,o=this.kind;return"key"===o?i=t:"value"===o?i=n[t]:"entry"===o&&(i=[t,n[t]]),this.i=t+1,$e(i)}return this.array=void 0,$e()}}),je(e.prototype),Array.of===ze.of||function(){var e=function(e){this.length=e};e.prototype=[];var t=Array.of.apply(e,[1,2]);return t instanceof e&&2===t.length}()||K(Array,"of",ze.of);var We={copyWithin:function(e,t){var n,r=ae.ToObject(this),i=ae.ToLength(r.length),o=ae.ToInteger(e),a=ae.ToInteger(t),s=o<0?N(i+o,0):_(o,i),c=a<0?N(i+a,0):_(a,i);arguments.length>2&&(n=arguments[2]);var u=void 0===n?i:ae.ToInteger(n),l=u<0?N(i+u,0):_(u,i),f=_(l-c,i-s),p=1;for(c<s&&s<c+f&&(p=-1,c+=f-1,s+=f-1);f>0;)c in r?r[s]=r[c]:delete r[s],c+=p,s+=p,f-=1;return r},fill:function(e){var t;arguments.length>1&&(t=arguments[1]);var n;arguments.length>2&&(n=arguments[2]);var r=ae.ToObject(this),i=ae.ToLength(r.length);t=ae.ToInteger(void 0===t?0:t),n=ae.ToInteger(void 0===n?i:n);for(var o=t<0?N(i+t,0):_(t,i),a=n<0?i+n:n,s=o;s<i&&s<a;++s)r[s]=e;return r},find:function(e){var t=ae.ToObject(this),r=ae.ToLength(t.length);if(!ae.IsCallable(e))throw new TypeError("Array#find: predicate must be a function");for(var i,o=arguments.length>1?arguments[1]:null,a=0;a<r;a++)if(i=t[a],o){if(n(e,o,i,a,t))return i}else if(e(i,a,t))return i},findIndex:function(e){var t=ae.ToObject(this),r=ae.ToLength(t.length);if(!ae.IsCallable(e))throw new TypeError("Array#findIndex: predicate must be a function");for(var i=arguments.length>1?arguments[1]:null,o=0;o<r;o++)if(i){if(n(e,i,t[o],o,t))return o}else if(e(t[o],o,t))return o;return-1},keys:function(){return new e(this,"key")},values:function(){return new e(this,"value")},entries:function(){return new e(this,"entry")}};if(Array.prototype.keys&&!ae.IsCallable([1].keys().next)&&delete Array.prototype.keys,Array.prototype.entries&&!ae.IsCallable([1].entries().next)&&delete Array.prototype.entries,Array.prototype.keys&&Array.prototype.entries&&!Array.prototype.values&&Array.prototype[te]&&(y(Array.prototype,{values:Array.prototype[te]}),Q.symbol(z.unscopables)&&(Array.prototype[z.unscopables].values=!0)),u&&Array.prototype.values&&"values"!==Array.prototype.values.name){var Ue=Array.prototype.values;K(Array.prototype,"values",function(){return ae.Call(Ue,this,arguments)}),h(Array.prototype,te,Array.prototype.values,!0)}y(Array.prototype,We),1/[!0].indexOf(!0,-0)<0&&h(Array.prototype,"indexOf",function(e){var t=O(this,arguments);return 0===t&&1/t<0?0:t},!0),je(Array.prototype,function(){return this.values()}),Object.getPrototypeOf&&je(Object.getPrototypeOf([].values()));var Ge=function(){return a(function(){return 0===Array.from({length:-1}).length})}(),Xe=function(){var e=Array.from([0].entries());return 1===e.length&&r(e[0])&&0===e[0][0]&&0===e[0][1]}();if(Ge&&Xe||K(Array,"from",ze.from),!function(){return a(function(){return Array.from([0],void 0)})}()){var Ye=Array.from;K(Array,"from",function(e){return arguments.length>1&&void 0!==arguments[1]?ae.Call(Ye,this,arguments):n(Ye,this,e)})}var Je=-(Math.pow(2,32)-1),Ze=function(e,t){var r={length:Je};return r[t?(r.length>>>0)-1:0]=!0,a(function(){return n(e,r,function(){throw new RangeError("should not reach here")},[]),!0})};if(!Ze(Array.prototype.forEach)){var Qe=Array.prototype.forEach;K(Array.prototype,"forEach",function(e){return ae.Call(Qe,this.length>=0?this:[],arguments)})}if(!Ze(Array.prototype.map)){var Ke=Array.prototype.map;K(Array.prototype,"map",function(e){return ae.Call(Ke,this.length>=0?this:[],arguments)})}if(!Ze(Array.prototype.filter)){var et=Array.prototype.filter;K(Array.prototype,"filter",function(e){return ae.Call(et,this.length>=0?this:[],arguments)})}if(!Ze(Array.prototype.some)){var tt=Array.prototype.some;K(Array.prototype,"some",function(e){return ae.Call(tt,this.length>=0?this:[],arguments)})}if(!Ze(Array.prototype.every)){var nt=Array.prototype.every;K(Array.prototype,"every",function(e){return ae.Call(nt,this.length>=0?this:[],arguments)})}if(!Ze(Array.prototype.reduce)){var rt=Array.prototype.reduce;K(Array.prototype,"reduce",function(e){return ae.Call(rt,this.length>=0?this:[],arguments)})}if(!Ze(Array.prototype.reduceRight,!0)){var it=Array.prototype.reduceRight;K(Array.prototype,"reduceRight",function(e){return ae.Call(it,this.length>=0?this:[],arguments)})}var ot=8!==Number("0o10"),at=2!==Number("0b10"),st=d(Re,function(e){return 0===Number(e+0+e)});if(ot||at||st){var ct=Number,ut=/^0b[01]+$/i,lt=/^0o[0-7]+$/i,ft=ut.test.bind(ut),pt=lt.test.bind(lt),dt=function(e){var t;if("function"==typeof e.valueOf&&(t=e.valueOf(),Q.primitive(t)))return t;if("function"==typeof e.toString&&(t=e.toString(),Q.primitive(t)))return t;throw new TypeError("No default value")},ht=Fe.test.bind(Fe),yt=He.test.bind(He),gt=function(){var e=function(t){var n;"string"==typeof(n=arguments.length>0?Q.primitive(t)?t:dt(t):0)&&(n=ae.Call(qe,n),ft(n)?n=parseInt(k(n,2),2):pt(n)?n=parseInt(k(n,2),8):(ht(n)||yt(n))&&(n=NaN));var r=this,i=a(function(){return ct.prototype.valueOf.call(r),!0});return r instanceof e&&!i?new ct(n):ct(n)};return e}();Te(ct,gt,{}),y(gt,{NaN:ct.NaN,MAX_VALUE:ct.MAX_VALUE,MIN_VALUE:ct.MIN_VALUE,NEGATIVE_INFINITY:ct.NEGATIVE_INFINITY,POSITIVE_INFINITY:ct.POSITIVE_INFINITY}),Number=gt,v.redefine(x,"Number",gt)}var mt=Math.pow(2,53)-1;y(Number,{MAX_SAFE_INTEGER:mt,MIN_SAFE_INTEGER:-mt,EPSILON:2.220446049250313e-16,parseInt:x.parseInt,parseFloat:x.parseFloat,isFinite:G,isInteger:function(e){return G(e)&&ae.ToInteger(e)===e},isSafeInteger:function(e){return Number.isInteger(e)&&P(e)<=Number.MAX_SAFE_INTEGER},isNaN:U}),h(Number,"parseInt",x.parseInt,Number.parseInt!==x.parseInt),1===[,1].find(function(){return!0})&&K(Array.prototype,"find",We.find),0!==[,1].findIndex(function(){return!0})&&K(Array.prototype,"findIndex",We.findIndex);var vt=Function.bind.call(Function.bind,Object.prototype.propertyIsEnumerable),bt=function(e,t){c&&vt(e,t)&&Object.defineProperty(e,t,{enumerable:!1})},wt=function(){for(var e=Number(this),t=arguments.length,n=t-e,r=new Array(n<0?0:n),i=e;i<t;++i)r[i-e]=arguments[i];return r},xt=function(e){return function(t,n){return t[n]=e[n],t}},Tt=function(e,t){var n,r=i(Object(t));return ae.IsCallable(Object.getOwnPropertySymbols)&&(n=p(Object.getOwnPropertySymbols(Object(t)),vt(t))),f(j(r,n||[]),xt(t),e)},St={assign:function(e,t){var n=ae.ToObject(e,"Cannot convert undefined or null to object");return f(ae.Call(wt,1,arguments),Tt,n)},is:function(e,t){return ae.SameValue(e,t)}};if(Object.assign&&Object.preventExtensions&&function(){var e=Object.preventExtensions({1:2});try{Object.assign(e,"xy")}catch(t){return"y"===e[1]}}()&&K(Object,"assign",St.assign),y(Object,St),c){var Ot={setPrototypeOf:function(e,t){var r,i=function(e,t){if(!ae.TypeIsObject(e))throw new TypeError("cannot set prototype on a non-object");if(null!==t&&!ae.TypeIsObject(t))throw new TypeError("can only set prototype to an object or null"+t)},o=function(e,t){return i(e,t),n(r,e,t),e};try{r=e.getOwnPropertyDescriptor(e.prototype,"__proto__").set,n(r,{},null)}catch(t){if(e.prototype!=={}.__proto__)return;r=function(e){this.__proto__=e},o.polyfill=o(o({},null),e.prototype)instanceof e}return o}(Object)};y(Object,Ot)}if(Object.setPrototypeOf&&Object.getPrototypeOf&&null!==Object.getPrototypeOf(Object.setPrototypeOf({},null))&&null===Object.getPrototypeOf(Object.create(null))&&function(){var e=Object.create(null),t=Object.getPrototypeOf,n=Object.setPrototypeOf;Object.getPrototypeOf=function(n){var r=t(n);return r===e?null:r},Object.setPrototypeOf=function(t,r){return n(t,null===r?e:r)},Object.setPrototypeOf.polyfill=!1}(),!!o(function(){Object.keys("foo")})){var jt=Object.keys;K(Object,"keys",function(e){return jt(ae.ToObject(e))}),i=Object.keys}if(o(function(){Object.keys(/a/g)})){var kt=Object.keys;K(Object,"keys",function(e){if(Q.regex(e)){var t=[];for(var n in e)q(e,n)&&A(t,n);return t}return kt(e)}),i=Object.keys}if(Object.getOwnPropertyNames){if(!!o(function(){Object.getOwnPropertyNames("foo")})){var At="object"===("undefined"==typeof window?"undefined":_typeof(window))?Object.getOwnPropertyNames(window):[],Ct=Object.getOwnPropertyNames;K(Object,"getOwnPropertyNames",function(e){var t=ae.ToObject(e);if("[object Window]"===g(t))try{return Ct(t)}catch(e){return j([],At)}return Ct(t)})}}if(Object.getOwnPropertyDescriptor){if(!!o(function(){Object.getOwnPropertyDescriptor("foo","bar")})){var Et=Object.getOwnPropertyDescriptor;K(Object,"getOwnPropertyDescriptor",function(e,t){return Et(ae.ToObject(e),t)})}}if(Object.seal){if(!!o(function(){Object.seal("foo")})){var Nt=Object.seal;K(Object,"seal",function(e){return ae.TypeIsObject(e)?Nt(e):e})}}if(Object.isSealed){if(!!o(function(){Object.isSealed("foo")})){var _t=Object.isSealed;K(Object,"isSealed",function(e){return!ae.TypeIsObject(e)||_t(e)})}}if(Object.freeze){if(!!o(function(){Object.freeze("foo")})){var It=Object.freeze;K(Object,"freeze",function(e){return ae.TypeIsObject(e)?It(e):e})}}if(Object.isFrozen){if(!!o(function(){Object.isFrozen("foo")})){var Pt=Object.isFrozen;K(Object,"isFrozen",function(e){return!ae.TypeIsObject(e)||Pt(e)})}}if(Object.preventExtensions){if(!!o(function(){Object.preventExtensions("foo")})){var Mt=Object.preventExtensions;K(Object,"preventExtensions",function(e){return ae.TypeIsObject(e)?Mt(e):e})}}if(Object.isExtensible){if(!!o(function(){Object.isExtensible("foo")})){var Dt=Object.isExtensible;K(Object,"isExtensible",function(e){return!!ae.TypeIsObject(e)&&Dt(e)})}}if(Object.getPrototypeOf){if(!!o(function(){Object.getPrototypeOf("foo")})){var Lt=Object.getPrototypeOf;K(Object,"getPrototypeOf",function(e){return Lt(ae.ToObject(e))})}}var qt=c&&function(){var e=Object.getOwnPropertyDescriptor(RegExp.prototype,"flags");return e&&ae.IsCallable(e.get)}();if(c&&!qt){var Rt=function(){if(!ae.TypeIsObject(this))throw new TypeError("Method called on incompatible type: must be an object.");var e="";return this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.unicode&&(e+="u"),this.sticky&&(e+="y"),e};v.getter(RegExp.prototype,"flags",Rt)}var Ft=c&&a(function(){return"/a/i"===String(new RegExp(/a/g,"i"))}),Ht=ee&&c&&function(){var e=/./;return e[z.match]=!1,RegExp(e)===e}(),Vt=a(function(){return"/abc/"===RegExp.prototype.toString.call({source:"abc"})}),$t=Vt&&a(function(){return"/a/b"===RegExp.prototype.toString.call({source:"a",flags:"b"})});if(!Vt||!$t){var Bt=RegExp.prototype.toString;h(RegExp.prototype,"toString",function(){var e=ae.RequireObjectCoercible(this);return Q.regex(e)?n(Bt,e):"/"+re(e.source)+"/"+re(e.flags)},!0),v.preserveToString(RegExp.prototype.toString,Bt)}if(c&&(!Ft||Ht)){var zt=Object.getOwnPropertyDescriptor(RegExp.prototype,"flags").get,Wt=Object.getOwnPropertyDescriptor(RegExp.prototype,"source")||{},Ut=function(){return this.source},Gt=ae.IsCallable(Wt.get)?Wt.get:Ut,Xt=RegExp,Yt=function(){return function e(t,n){var r=ae.IsRegExp(t);if(!(this instanceof e)&&r&&void 0===n&&t.constructor===e)return t;var i=t,o=n;return Q.regex(t)?(i=ae.Call(Gt,t),o=void 0===n?ae.Call(zt,t):n,new e(i,o)):(r&&(i=t.source,o=void 0===n?t.flags:n),new Xt(t,n))}}();Te(Xt,Yt,{$input:!0}),RegExp=Yt,v.redefine(x,"RegExp",Yt)}if(c){var Jt={input:"$_",lastMatch:"$&",lastParen:"$+",leftContext:"$`",rightContext:"$'"};l(i(Jt),function(e){e in RegExp&&!(Jt[e]in RegExp)&&v.getter(RegExp,Jt[e],function(){return RegExp[e]})})}Oe(RegExp);var Zt=1/Number.EPSILON,Qt=function(e){return e+Zt-Zt},Kt=Math.pow(2,-23),en=Math.pow(2,127)*(2-Kt),tn=Math.pow(2,-126),nn=Math.E,rn=Math.LOG2E,on=Math.LOG10E,an=Number.prototype.clz;delete Number.prototype.clz;var sn={acosh:function(e){var t=Number(e);return U(t)||e<1?NaN:1===t?0:t===1/0?t:D(t/nn+L(t+1)*L(t-1)/nn)+1},asinh:function e(t){var n=Number(t);return 0!==n&&T(n)?n<0?-e(-n):D(n+L(n*n+1)):n},atanh:function(e){var t=Number(e);return U(t)||t<-1||t>1?NaN:-1===t?-1/0:1===t?1/0:0===t?t:.5*D((1+t)/(1-t))},cbrt:function(e){var t=Number(e);if(0===t)return t;var n,r=t<0;return r&&(t=-t),t===1/0?n=1/0:(n=M(D(t)/3),n=(t/(n*n)+2*n)/3),r?-n:n},clz32:function(e){var t=Number(e),n=ae.ToUint32(t);return 0===n?32:an?ae.Call(an,n):31-I(D(n+.5)*rn)},cosh:function(e){var t=Number(e);return 0===t?1:U(t)?NaN:T(t)?(t<0&&(t=-t),t>21?M(t)/2:(M(t)+M(-t))/2):1/0},expm1:function(e){var t=Number(e);if(t===-1/0)return-1;if(!T(t)||0===t)return t;if(P(t)>.5)return M(t)-1;for(var n=t,r=0,i=1;r+n!==r;)r+=n,i+=1,n*=t/i;return r},hypot:function(e,t){for(var n=0,r=0,i=0;i<arguments.length;++i){var o=P(Number(arguments[i]));r<o?(n*=r/o*(r/o),n+=1,r=o):n+=o>0?o/r*(o/r):o}return r===1/0?1/0:r*L(n)},log2:function(e){return D(e)*rn},log10:function(e){return D(e)*on},log1p:function(e){var t=Number(e);return t<-1||U(t)?NaN:0===t||t===1/0?t:-1===t?-1/0:1+t-1==0?t:t*(D(1+t)/(1+t-1))},sign:X,sinh:function(e){var t=Number(e);return T(t)&&0!==t?P(t)<1?(Math.expm1(t)-Math.expm1(-t))/2:(M(t-1)-M(-t-1))*nn/2:t},tanh:function(e){var t=Number(e);return U(t)||0===t?t:t>=20?1:t<=-20?-1:(Math.expm1(t)-Math.expm1(-t))/(M(t)+M(-t))},trunc:function(e){var t=Number(e);return t<0?-I(-t):I(t)},imul:function(e,t){var n=ae.ToUint32(e),r=ae.ToUint32(t),i=n>>>16&65535,o=65535&n,a=r>>>16&65535,s=65535&r;return o*s+(i*s+o*a<<16>>>0)|0},fround:function(e){var t=Number(e);if(0===t||t===1/0||t===-1/0||U(t))return t;var n=X(t),r=P(t);if(r<tn)return n*Qt(r/tn/Kt)*tn*Kt;var i=(1+Kt/Number.EPSILON)*r,o=i-(i-r);return o>en||U(o)?n*(1/0):n*o}};y(Math,sn),h(Math,"log1p",sn.log1p,-1e-17!==Math.log1p(-1e-17)),h(Math,"asinh",sn.asinh,Math.asinh(-1e7)!==-Math.asinh(1e7)),h(Math,"tanh",sn.tanh,-2e-17!==Math.tanh(-2e-17)),h(Math,"acosh",sn.acosh,Math.acosh(Number.MAX_VALUE)===1/0),h(Math,"cbrt",sn.cbrt,Math.abs(1-Math.cbrt(1e-300)/1e-100)/Number.EPSILON>8),h(Math,"sinh",sn.sinh,-2e-17!==Math.sinh(-2e-17));var cn=Math.expm1(10);h(Math,"expm1",sn.expm1,cn>22025.465794806718||cn<22025.465794806718);var un=Math.round,ln=0===Math.round(.5-Number.EPSILON/4)&&1===Math.round(Number.EPSILON/3.99-.5),fn=Zt+1,pn=2*Zt-1,dn=[fn,pn].every(function(e){return Math.round(e)===e});h(Math,"round",function(e){var t=I(e),n=-1===t?-0:t+1;return e-t<.5?t:n},!ln||!dn),v.preserveToString(Math.round,un);var hn=Math.imul;-5!==Math.imul(4294967295,5)&&(Math.imul=sn.imul,v.preserveToString(Math.imul,hn)),2!==Math.imul.length&&K(Math,"imul",function(e,t){return ae.Call(hn,Math,arguments)});var yn=function(){var e=x.setTimeout;if("function"==typeof e||"object"===(void 0===e?"undefined":_typeof(e))){ae.IsPromise=function(e){return!!ae.TypeIsObject(e)&&void 0!==e._promise};var t,r=function(e){if(!ae.IsConstructor(e))throw new TypeError("Bad promise constructor");var t=this,n=function(e,n){if(void 0!==t.resolve||void 0!==t.reject)throw new TypeError("Bad Promise implementation!");t.resolve=e,t.reject=n};if(t.resolve=void 0,t.reject=void 0,t.promise=new e(n),!ae.IsCallable(t.resolve)||!ae.IsCallable(t.reject))throw new TypeError("Bad promise constructor")};"undefined"!=typeof window&&ae.IsCallable(window.postMessage)&&(t=function(){var e=[],t=function(t){A(e,t),window.postMessage("zero-timeout-message","*")},n=function(t){if(t.source===window&&"zero-timeout-message"===t.data){if(t.stopPropagation(),0===e.length)return;E(e)()}};return window.addEventListener("message",n,!0),t});var i,o,a=ae.IsCallable(x.setImmediate)?x.setImmediate:"object"===("undefined"==typeof process?"undefined":_typeof(process))&&process.nextTick?process.nextTick:function(){var e=x.Promise,t=e&&e.resolve&&e.resolve();return t&&function(e){return t.then(e)}}()||(ae.IsCallable(t)?t():function(t){e(t,0)}),s=function(e){return e},c=function(e){throw e},u={},l=function(e,t,n){a(function(){f(e,t,n)})},f=function(e,t,n){var r,i;if(t===u)return e(n);try{r=e(n),i=t.resolve}catch(e){r=e,i=t.reject}i(r)},p=function(e,t){var n=e._promise,r=n.reactionLength;if(r>0&&(l(n.fulfillReactionHandler0,n.reactionCapability0,t),n.fulfillReactionHandler0=void 0,n.rejectReactions0=void 0,n.reactionCapability0=void 0,r>1))for(var i=1,o=0;i<r;i++,o+=3)l(n[o+0],n[o+2],t),e[o+0]=void 0,e[o+1]=void 0,e[o+2]=void 0;n.result=t,n.state=1,n.reactionLength=0},d=function(e,t){var n=e._promise,r=n.reactionLength;if(r>0&&(l(n.rejectReactionHandler0,n.reactionCapability0,t),n.fulfillReactionHandler0=void 0,n.rejectReactions0=void 0,n.reactionCapability0=void 0,r>1))for(var i=1,o=0;i<r;i++,o+=3)l(n[o+1],n[o+2],t),e[o+0]=void 0,e[o+1]=void 0,e[o+2]=void 0;n.result=t,n.state=2,n.reactionLength=0},h=function(e){var t=!1;return{resolve:function(n){var r;if(!t){if(t=!0,n===e)return d(e,new TypeError("Self resolution"));if(!ae.TypeIsObject(n))return p(e,n);try{r=n.then}catch(t){return d(e,t)}if(!ae.IsCallable(r))return p(e,n);a(function(){m(e,n,r)})}},reject:function(n){if(!t)return t=!0,d(e,n)}}},g=function(e,t,r,i){e===o?n(e,t,r,i,u):n(e,t,r,i)},m=function(e,t,n){var r=h(e),i=r.resolve,o=r.reject;try{g(n,t,i,o)}catch(e){o(e)}},v=function(){var e=function(t){if(!(this instanceof e))throw new TypeError('Constructor Promise requires "new"');if(this&&this._promise)throw new TypeError("Bad construction");if(!ae.IsCallable(t))throw new TypeError("not a valid resolver");var n=Ce(this,e,i,{_promise:{result:void 0,state:0,reactionLength:0,fulfillReactionHandler0:void 0,rejectReactionHandler0:void 0,reactionCapability0:void 0}}),r=h(n),o=r.reject;try{t(r.resolve,o)}catch(e){o(e)}return n};return e}();i=v.prototype;var b=function(e,t,n,r){var i=!1;return function(o){if(!i&&(i=!0,t[e]=o,0==--r.count)){(0,n.resolve)(t)}}
+},w=function(e,t,n){for(var r,i,o=e.iterator,a=[],s={count:1},c=0;;){try{if(!1===(r=ae.IteratorStep(o))){e.done=!0;break}i=r.value}catch(t){throw e.done=!0,t}a[c]=void 0;var u=t.resolve(i),l=b(c,a,n,s);s.count+=1,g(u.then,u,l,n.reject),c+=1}if(0==--s.count){(0,n.resolve)(a)}return n.promise},T=function(e,t,n){for(var r,i,o,a=e.iterator;;){try{if(!1===(r=ae.IteratorStep(a))){e.done=!0;break}i=r.value}catch(t){throw e.done=!0,t}o=t.resolve(i),g(o.then,o,n.resolve,n.reject)}return n.promise};return y(v,{all:function(e){var t=this;if(!ae.TypeIsObject(t))throw new TypeError("Promise is not object");var n,i,o=new r(t);try{return n=ae.GetIterator(e),i={iterator:n,done:!1},w(i,t,o)}catch(e){var a=e;if(i&&!i.done)try{ae.IteratorClose(n,!0)}catch(e){a=e}var s=o.reject;return s(a),o.promise}},race:function(e){var t=this;if(!ae.TypeIsObject(t))throw new TypeError("Promise is not object");var n,i,o=new r(t);try{return n=ae.GetIterator(e),i={iterator:n,done:!1},T(i,t,o)}catch(e){var a=e;if(i&&!i.done)try{ae.IteratorClose(n,!0)}catch(e){a=e}var s=o.reject;return s(a),o.promise}},reject:function(e){var t=this;if(!ae.TypeIsObject(t))throw new TypeError("Bad promise constructor");var n=new r(t);return(0,n.reject)(e),n.promise},resolve:function(e){var t=this;if(!ae.TypeIsObject(t))throw new TypeError("Bad promise constructor");if(ae.IsPromise(e)){var n=e.constructor;if(n===t)return e}var i=new r(t);return(0,i.resolve)(e),i.promise}}),y(i,{catch:function(e){return this.then(null,e)},then:function(e,t){var n=this;if(!ae.IsPromise(n))throw new TypeError("not a promise");var i,o=ae.SpeciesConstructor(n,v);i=arguments.length>2&&arguments[2]===u&&o===v?u:new r(o);var a,f=ae.IsCallable(e)?e:s,p=ae.IsCallable(t)?t:c,d=n._promise;if(0===d.state){if(0===d.reactionLength)d.fulfillReactionHandler0=f,d.rejectReactionHandler0=p,d.reactionCapability0=i;else{var h=3*(d.reactionLength-1);d[h+0]=f,d[h+1]=p,d[h+2]=i}d.reactionLength+=1}else if(1===d.state)a=d.result,l(f,i,a);else{if(2!==d.state)throw new TypeError("unexpected Promise state");a=d.result,l(p,i,a)}return i.promise}}),u=new r(v),o=i.then,v}}();if(x.Promise&&(delete x.Promise.accept,delete x.Promise.defer,delete x.Promise.prototype.chain),"function"==typeof yn){y(x,{Promise:yn});var gn=w(x.Promise,function(e){return e.resolve(42).then(function(){})instanceof e}),mn=!o(function(){x.Promise.reject(42).then(null,5).then(null,R)}),vn=o(function(){x.Promise.call(3,R)}),bn=function(e){var t=e.resolve(5);t.constructor={};var n=e.resolve(t);try{n.then(null,R).then(null,R)}catch(e){return!0}return t===n}(x.Promise),wn=c&&function(){var e=0,t=Object.defineProperty({},"then",{get:function(){e+=1}});return Promise.resolve(t),1===e}(),xn=function e(t){var n=new Promise(t);t(3,function(){}),this.then=n.then,this.constructor=e};xn.prototype=Promise.prototype,xn.all=Promise.all;var Tn=a(function(){return!!xn.all([1,2])});if(gn&&mn&&vn&&!bn&&wn&&!Tn||(Promise=yn,K(x,"Promise",yn)),1!==Promise.all.length){var Sn=Promise.all;K(Promise,"all",function(e){return ae.Call(Sn,this,arguments)})}if(1!==Promise.race.length){var On=Promise.race;K(Promise,"race",function(e){return ae.Call(On,this,arguments)})}if(1!==Promise.resolve.length){var jn=Promise.resolve;K(Promise,"resolve",function(e){return ae.Call(jn,this,arguments)})}if(1!==Promise.reject.length){var kn=Promise.reject;K(Promise,"reject",function(e){return ae.Call(kn,this,arguments)})}bt(Promise,"all"),bt(Promise,"race"),bt(Promise,"resolve"),bt(Promise,"reject"),Oe(Promise)}var An=function(e){var t=i(f(e,function(e,t){return e[t]=!0,e},{}));return e.join(":")===t.join(":")},Cn=An(["z","a","bb"]),En=An(["z",1,"a","3",2]);if(c){var Nn=function(e,t){return t||Cn?oe(e)?"^"+ae.ToString(e):"string"==typeof e?"$"+e:"number"==typeof e?En?e:"n"+e:"boolean"==typeof e?"b"+e:null:null},_n=function(){return Object.create?Object.create(null):{}},In=function(e,t,i){if(r(i)||Q.string(i))l(i,function(e){if(!ae.TypeIsObject(e))throw new TypeError("Iterator value "+e+" is not an entry object");t.set(e[0],e[1])});else if(i instanceof e)n(e.prototype.forEach,i,function(e,n){t.set(n,e)});else{var o,a;if(!oe(i)){if(a=t.set,!ae.IsCallable(a))throw new TypeError("bad map");o=ae.GetIterator(i)}if(void 0!==o)for(;;){var s=ae.IteratorStep(o);if(!1===s)break;var c=s.value;try{if(!ae.TypeIsObject(c))throw new TypeError("Iterator value "+c+" is not an entry object");n(a,t,c[0],c[1])}catch(e){throw ae.IteratorClose(o,!0),e}}}},Pn=function(e,t,i){if(r(i)||Q.string(i))l(i,function(e){t.add(e)});else if(i instanceof e)n(e.prototype.forEach,i,function(e){t.add(e)});else{var o,a;if(!oe(i)){if(a=t.add,!ae.IsCallable(a))throw new TypeError("bad set");o=ae.GetIterator(i)}if(void 0!==o)for(;;){var s=ae.IteratorStep(o);if(!1===s)break;var c=s.value;try{n(a,t,c)}catch(e){throw ae.IteratorClose(o,!0),e}}}},Mn={Map:function(){var e={},t=function(e,t){this.key=e,this.value=t,this.next=null,this.prev=null};t.prototype.isRemoved=function(){return this.key===e};var r=function(e){return!!e._es6map},i=function(e,t){if(!ae.TypeIsObject(e)||!r(e))throw new TypeError("Method Map.prototype."+t+" called on incompatible receiver "+ae.ToString(e))},o=function(e,t){i(e,"[[MapIterator]]"),this.head=e._head,this.i=this.head,this.kind=t};o.prototype={next:function(){var e=this.i,t=this.kind,n=this.head;if(void 0===this.i)return $e();for(;e.isRemoved()&&e!==n;)e=e.prev;for(var r;e.next!==n;)if(e=e.next,!e.isRemoved())return r="key"===t?e.key:"value"===t?e.value:[e.key,e.value],this.i=e,$e(r);return this.i=void 0,$e()}},je(o.prototype);var a,s=function e(){if(!(this instanceof e))throw new TypeError('Constructor Map requires "new"');if(this&&this._es6map)throw new TypeError("Bad construction");var n=Ce(this,e,a,{_es6map:!0,_head:null,_map:F?new F:null,_size:0,_storage:_n()}),r=new t(null,null);return r.next=r.prev=r,n._head=r,arguments.length>0&&In(e,n,arguments[0]),n};return a=s.prototype,v.getter(a,"size",function(){if(void 0===this._size)throw new TypeError("size method called on incompatible Map");return this._size}),y(a,{get:function(e){i(this,"get");var t,n=Nn(e,!0);if(null!==n)return t=this._storage[n],t?t.value:void 0;if(this._map)return t=V.call(this._map,e),t?t.value:void 0;for(var r=this._head,o=r;(o=o.next)!==r;)if(ae.SameValueZero(o.key,e))return o.value},has:function(e){i(this,"has");var t=Nn(e,!0);if(null!==t)return void 0!==this._storage[t];if(this._map)return $.call(this._map,e);for(var n=this._head,r=n;(r=r.next)!==n;)if(ae.SameValueZero(r.key,e))return!0;return!1},set:function(e,n){i(this,"set");var r,o=this._head,a=o,s=Nn(e,!0);if(null!==s){if(void 0!==this._storage[s])return this._storage[s].value=n,this;r=this._storage[s]=new t(e,n),a=o.prev}else this._map&&($.call(this._map,e)?V.call(this._map,e).value=n:(r=new t(e,n),B.call(this._map,e,r),a=o.prev));for(;(a=a.next)!==o;)if(ae.SameValueZero(a.key,e))return a.value=n,this;return r=r||new t(e,n),ae.SameValue(-0,e)&&(r.key=0),r.next=this._head,r.prev=this._head.prev,r.prev.next=r,r.next.prev=r,this._size+=1,this},delete:function(t){i(this,"delete");var n=this._head,r=n,o=Nn(t,!0);if(null!==o){if(void 0===this._storage[o])return!1;r=this._storage[o].prev,delete this._storage[o]}else if(this._map){if(!$.call(this._map,t))return!1;r=V.call(this._map,t).prev,H.call(this._map,t)}for(;(r=r.next)!==n;)if(ae.SameValueZero(r.key,t))return r.key=e,r.value=e,r.prev.next=r.next,r.next.prev=r.prev,this._size-=1,!0;return!1},clear:function(){i(this,"clear"),this._map=F?new F:null,this._size=0,this._storage=_n();for(var t=this._head,n=t,r=n.next;(n=r)!==t;)n.key=e,n.value=e,r=n.next,n.next=n.prev=t;t.next=t.prev=t},keys:function(){return i(this,"keys"),new o(this,"key")},values:function(){return i(this,"values"),new o(this,"value")},entries:function(){return i(this,"entries"),new o(this,"key+value")},forEach:function(e){i(this,"forEach");for(var t=arguments.length>1?arguments[1]:null,r=this.entries(),o=r.next();!o.done;o=r.next())t?n(e,t,o.value[1],o.value[0],this):e(o.value[1],o.value[0],this)}}),je(a,a.entries),s}(),Set:function(){var e,t=function(e){return e._es6set&&void 0!==e._storage},r=function(e,n){if(!ae.TypeIsObject(e)||!t(e))throw new TypeError("Set.prototype."+n+" called on incompatible receiver "+ae.ToString(e))},o=function t(){if(!(this instanceof t))throw new TypeError('Constructor Set requires "new"');if(this&&this._es6set)throw new TypeError("Bad construction");var n=Ce(this,t,e,{_es6set:!0,"[[SetData]]":null,_storage:_n()});if(!n._es6set)throw new TypeError("bad set");return arguments.length>0&&Pn(t,n,arguments[0]),n};e=o.prototype;var a=function(e){var t=e;if("^null"===t)return null;if("^undefined"!==t){var n=t.charAt(0);return"$"===n?k(t,1):"n"===n?+k(t,1):"b"===n?"btrue"===t:+t}},s=function(e){if(!e["[[SetData]]"]){var t=new Mn.Map;e["[[SetData]]"]=t,l(i(e._storage),function(e){var n=a(e);t.set(n,n)}),e["[[SetData]]"]=t}e._storage=null};return v.getter(o.prototype,"size",function(){return r(this,"size"),this._storage?i(this._storage).length:(s(this),this["[[SetData]]"].size)}),y(o.prototype,{has:function(e){r(this,"has");var t;return this._storage&&null!==(t=Nn(e))?!!this._storage[t]:(s(this),this["[[SetData]]"].has(e))},add:function(e){r(this,"add");var t;return this._storage&&null!==(t=Nn(e))?(this._storage[t]=!0,this):(s(this),this["[[SetData]]"].set(e,e),this)},delete:function(e){r(this,"delete");var t;if(this._storage&&null!==(t=Nn(e))){var n=q(this._storage,t);return delete this._storage[t]&&n}return s(this),this["[[SetData]]"].delete(e)},clear:function(){r(this,"clear"),this._storage&&(this._storage=_n()),this["[[SetData]]"]&&this["[[SetData]]"].clear()},values:function(){return r(this,"values"),s(this),this["[[SetData]]"].values()},entries:function(){return r(this,"entries"),s(this),this["[[SetData]]"].entries()},forEach:function(e){r(this,"forEach");var t=arguments.length>1?arguments[1]:null,i=this;s(i),this["[[SetData]]"].forEach(function(r,o){t?n(e,t,o,o,i):e(o,o,i)})}}),h(o.prototype,"keys",o.prototype.values,!0),je(o.prototype,o.prototype.values),o}()};if(x.Map||x.Set){a(function(){return 2===new Map([[1,2]]).get(1)})||(x.Map=function e(){if(!(this instanceof e))throw new TypeError('Constructor Map requires "new"');var t=new F;return arguments.length>0&&In(e,t,arguments[0]),delete t.constructor,Object.setPrototypeOf(t,x.Map.prototype),t},x.Map.prototype=b(F.prototype),h(x.Map.prototype,"constructor",x.Map,!0),v.preserveToString(x.Map,F));var Dn=new Map,Ln=function(){var e=new Map([[1,0],[2,0],[3,0],[4,0]]);return e.set(-0,e),e.get(0)===e&&e.get(-0)===e&&e.has(0)&&e.has(-0)}(),qn=Dn.set(1,2)===Dn;Ln&&qn||K(Map.prototype,"set",function(e,t){return n(B,this,0===e?0:e,t),this}),Ln||(y(Map.prototype,{get:function(e){return n(V,this,0===e?0:e)},has:function(e){return n($,this,0===e?0:e)}},!0),v.preserveToString(Map.prototype.get,V),v.preserveToString(Map.prototype.has,$));var Rn=new Set,Fn=function(e){return e.delete(0),e.add(-0),!e.has(0)}(Rn),Hn=Rn.add(1)===Rn;if(!Fn||!Hn){var Vn=Set.prototype.add;Set.prototype.add=function(e){return n(Vn,this,0===e?0:e),this},v.preserveToString(Set.prototype.add,Vn)}if(!Fn){var $n=Set.prototype.has;Set.prototype.has=function(e){return n($n,this,0===e?0:e)},v.preserveToString(Set.prototype.has,$n);var Bn=Set.prototype.delete;Set.prototype.delete=function(e){return n(Bn,this,0===e?0:e)},v.preserveToString(Set.prototype.delete,Bn)}var zn=w(x.Map,function(e){var t=new e([]);return t.set(42,42),t instanceof e}),Wn=Object.setPrototypeOf&&!zn,Un=function(){try{return!(x.Map()instanceof x.Map)}catch(e){return e instanceof TypeError}}();0===x.Map.length&&!Wn&&Un||(x.Map=function e(){if(!(this instanceof e))throw new TypeError('Constructor Map requires "new"');var t=new F;return arguments.length>0&&In(e,t,arguments[0]),delete t.constructor,Object.setPrototypeOf(t,e.prototype),t},x.Map.prototype=F.prototype,h(x.Map.prototype,"constructor",x.Map,!0),v.preserveToString(x.Map,F));var Gn=w(x.Set,function(e){var t=new e([]);return t.add(42,42),t instanceof e}),Xn=Object.setPrototypeOf&&!Gn,Yn=function(){try{return!(x.Set()instanceof x.Set)}catch(e){return e instanceof TypeError}}();if(0!==x.Set.length||Xn||!Yn){var Jn=x.Set;x.Set=function e(){if(!(this instanceof e))throw new TypeError('Constructor Set requires "new"');var t=new Jn;return arguments.length>0&&Pn(e,t,arguments[0]),delete t.constructor,Object.setPrototypeOf(t,e.prototype),t},x.Set.prototype=Jn.prototype,h(x.Set.prototype,"constructor",x.Set,!0),v.preserveToString(x.Set,Jn)}var Zn=new x.Map,Qn=!a(function(){return Zn.keys().next().done});if(("function"!=typeof x.Map.prototype.clear||0!==(new x.Set).size||0!==Zn.size||"function"!=typeof x.Map.prototype.keys||"function"!=typeof x.Set.prototype.keys||"function"!=typeof x.Map.prototype.forEach||"function"!=typeof x.Set.prototype.forEach||s(x.Map)||s(x.Set)||"function"!=typeof Zn.keys().next||Qn||!zn)&&y(x,{Map:Mn.Map,Set:Mn.Set},!0),x.Set.prototype.keys!==x.Set.prototype.values&&h(x.Set.prototype,"keys",x.Set.prototype.values,!0),je(Object.getPrototypeOf((new x.Map).keys())),je(Object.getPrototypeOf((new x.Set).keys())),u&&"has"!==x.Set.prototype.has.name){var Kn=x.Set.prototype.has;K(x.Set.prototype,"has",function(e){return n(Kn,this,e)})}}y(x,Mn),Oe(x.Map),Oe(x.Set)}var er=function(e){if(!ae.TypeIsObject(e))throw new TypeError("target must be an object")},tr={apply:function(){return ae.Call(ae.Call,null,arguments)},construct:function(e,t){if(!ae.IsConstructor(e))throw new TypeError("First argument must be a constructor.");var n=arguments.length>2?arguments[2]:e;if(!ae.IsConstructor(n))throw new TypeError("new.target must be a constructor.");return ae.Construct(e,t,n,"internal")},deleteProperty:function(e,t){if(er(e),c){var n=Object.getOwnPropertyDescriptor(e,t);if(n&&!n.configurable)return!1}return delete e[t]},has:function(e,t){return er(e),t in e}};Object.getOwnPropertyNames&&Object.assign(tr,{ownKeys:function(e){er(e);var t=Object.getOwnPropertyNames(e);return ae.IsCallable(Object.getOwnPropertySymbols)&&C(t,Object.getOwnPropertySymbols(e)),t}});var nr=function(e){return!o(e)};if(Object.preventExtensions&&Object.assign(tr,{isExtensible:function(e){return er(e),Object.isExtensible(e)},preventExtensions:function(e){return er(e),nr(function(){Object.preventExtensions(e)})}}),c){var rr=function(e,t,n){var r=Object.getOwnPropertyDescriptor(e,t);if(!r){var i=Object.getPrototypeOf(e);if(null===i)return;return rr(i,t,n)}return"value"in r?r.value:r.get?ae.Call(r.get,n):void 0},ir=function(e,t,r,i){var o=Object.getOwnPropertyDescriptor(e,t);if(!o){var a=Object.getPrototypeOf(e);if(null!==a)return ir(a,t,r,i);o={value:void 0,writable:!0,enumerable:!0,configurable:!0}}if("value"in o){if(!o.writable)return!1;if(!ae.TypeIsObject(i))return!1;return Object.getOwnPropertyDescriptor(i,t)?ne.defineProperty(i,t,{value:r}):ne.defineProperty(i,t,{value:r,writable:!0,enumerable:!0,configurable:!0})}return!!o.set&&(n(o.set,i,r),!0)};Object.assign(tr,{defineProperty:function(e,t,n){return er(e),nr(function(){Object.defineProperty(e,t,n)})},getOwnPropertyDescriptor:function(e,t){return er(e),Object.getOwnPropertyDescriptor(e,t)},get:function(e,t){er(e);var n=arguments.length>2?arguments[2]:e;return rr(e,t,n)},set:function(e,t,n){er(e);var r=arguments.length>3?arguments[3]:e;return ir(e,t,n,r)}})}if(Object.getPrototypeOf){var or=Object.getPrototypeOf;tr.getPrototypeOf=function(e){return er(e),or(e)}}if(Object.setPrototypeOf&&tr.getPrototypeOf){var ar=function(e,t){for(var n=t;n;){if(e===n)return!0;n=tr.getPrototypeOf(n)}return!1};Object.assign(tr,{setPrototypeOf:function(e,t){if(er(e),null!==t&&!ae.TypeIsObject(t))throw new TypeError("proto must be an object or null");return t===ne.getPrototypeOf(e)||!(ne.isExtensible&&!ne.isExtensible(e))&&(!ar(e,t)&&(Object.setPrototypeOf(e,t),!0))}})}var sr=function(e,t){if(ae.IsCallable(x.Reflect[e])){a(function(){return x.Reflect[e](1),x.Reflect[e](NaN),x.Reflect[e](!0),!0})&&K(x.Reflect,e,t)}else h(x.Reflect,e,t)};Object.keys(tr).forEach(function(e){sr(e,tr[e])});var cr=x.Reflect.getPrototypeOf;if(u&&cr&&"getPrototypeOf"!==cr.name&&K(x.Reflect,"getPrototypeOf",function(e){return n(cr,x.Reflect,e)}),x.Reflect.setPrototypeOf&&a(function(){return x.Reflect.setPrototypeOf(1,{}),!0})&&K(x.Reflect,"setPrototypeOf",tr.setPrototypeOf),x.Reflect.defineProperty&&(a(function(){var e=!x.Reflect.defineProperty(1,"test",{value:1}),t="function"!=typeof Object.preventExtensions||!x.Reflect.defineProperty(Object.preventExtensions({}),"test",{});return e&&t})||K(x.Reflect,"defineProperty",tr.defineProperty)),x.Reflect.construct&&(a(function(){var e=function(){};return x.Reflect.construct(function(){},[],e)instanceof e})||K(x.Reflect,"construct",tr.construct)),"Invalid Date"!==String(new Date(NaN))){var ur=Date.prototype.toString,lr=function(){var e=+this;return e!==e?"Invalid Date":ae.Call(ur,this)};K(Date.prototype,"toString",lr)}var fr={anchor:function(e){return ae.CreateHTML(this,"a","name",e)},big:function(){return ae.CreateHTML(this,"big","","")},blink:function(){return ae.CreateHTML(this,"blink","","")},bold:function(){return ae.CreateHTML(this,"b","","")},fixed:function(){return ae.CreateHTML(this,"tt","","")},fontcolor:function(e){return ae.CreateHTML(this,"font","color",e)},fontsize:function(e){return ae.CreateHTML(this,"font","size",e)},italics:function(){return ae.CreateHTML(this,"i","","")},link:function(e){return ae.CreateHTML(this,"a","href",e)},small:function(){return ae.CreateHTML(this,"small","","")},strike:function(){return ae.CreateHTML(this,"strike","","")},sub:function(){return ae.CreateHTML(this,"sub","","")},sup:function(){return ae.CreateHTML(this,"sup","","")}};l(Object.keys(fr),function(e){var t=String.prototype[e],r=!1;if(ae.IsCallable(t)){var i=n(t,"",' " '),o=j([],i.match(/"/g)).length;r=i!==i.toLowerCase()||o>2}else r=!0;r&&K(String.prototype,e,fr[e])});var pr=function(){if(!ee)return!1;var e="object"===("undefined"==typeof JSON?"undefined":_typeof(JSON))&&"function"==typeof JSON.stringify?JSON.stringify:null;if(!e)return!1;if(void 0!==e(z()))return!0;if("[null]"!==e([z()]))return!0;var t={a:z()};return t[z()]=!0,"{}"!==e(t)}(),dr=a(function(){return!ee||"{}"===JSON.stringify(Object(z()))&&"[{}]"===JSON.stringify([Object(z())])});if(pr||!dr){var hr=JSON.stringify;K(JSON,"stringify",function(e){if("symbol"!==(void 0===e?"undefined":_typeof(e))){var t;arguments.length>1&&(t=arguments[1]);var i=[e];if(r(t))i.push(t);else{var o=ae.IsCallable(t)?t:null,a=function(e,t){var r=o?n(o,this,e,t):t;if("symbol"!==(void 0===r?"undefined":_typeof(r)))return Q.symbol(r)?xt({})(r):r};i.push(a)}return arguments.length>2&&i.push(arguments[2]),hr.apply(this,i)}})}return x}),define("jqueryplugins",["jquery"],function(e){e.prototype.extend({popAttr:function(e){var t=this.attr(e);return this.removeAttr(e),t},popData:function(e){var t=this.data(e);return this.removeData(e),t},tag:function(){return this[0]&&this[0].tagName&&this[0].tagName.toLowerCase()},textNodes:function(){return 1===this.length&&this[0]instanceof Text?[this[0]]:Array.from(this.add(this.contents().add(this.find("*").contents())).filter(function(){return this instanceof Text})).sort(function(e,t){return 2&e.compareDocumentPosition(t)?1:-1})},findAndFilter:function(e){return this.filter(e).add(this.find(e))}})}),function(){function e(){for(var e=0;e<arguments.length;e++)for(var t in arguments[e])this[t]=arguments[e][t]}function t(e,t){e.childAt=e.childAt||{};for(var n=t.start;n<t.end;n+=1)e.childAt[n]=t}function n(e,t,n,r){return!(e.canFollow&&!(e.canFollow.indexOf(n&&n.type)>-1)||e.cannotFollow&&(-1!==e.cannotFollow.indexOf(n&&n.type)||e.cannotFollow.indexOf("text")>-1&&r)||e.peek&&e.peek.toLowerCase()!==t.slice(0,e.peek.length).toLowerCase())}function r(e){for(var t=e.innerText,r=[],o=0,s=o,c=t.length,u=null;o<c;){for(var l=t.slice(o),f=(r.length?r[0]:e).innerMode,p=0,d=f.length;p<d;p+=1){var h=a[f[p]];if(n(h,l,u,s<o)&&h.pattern.test(l)){var y=h.pattern.exec(l),g=h.fn(y),m=!1,v=0;if(g.matches){for(;v<r.length;v+=1){var b=r[v].type;if(b in g.matches){m=!0;break}0===b.indexOf("verbatim")&&(b="verbatimOpener"),g.cannotCross&&g.cannotCross.indexOf(b)>-1&&(v=r.length-1)}if(v>=r.length&&!g.isFront)continue}s<o&&e.addChild({type:"text",text:t.slice(s,o),innerMode:f}),u=e.addChild(g),o+=u.text.length,s=o,m&&(i(e,u,r[v]),r=r.slice(v+1)),u.isFrontToken()&&r.unshift(u);break}}p===d&&(o+=1,null===u&&(u={type:"text"}))}for(s<o&&e.addChild({type:"text",text:t.slice(s,o),innerMode:(r.length?r[0]:e).innerMode});r.length>0;)r.shift().demote();return e}function i(e,n,r){var i=e.children.indexOf(n),o=e.children.indexOf(r);n.children=e.children.splice(o+1,i-(o+1)),n.children.forEach(function(e){t(n,e)}),n.type=n.matches[r.type],n.innerText="";for(var a=0,s=n.children.length;a<s;a++)n.innerText+=n.children[a].text;n.start=r.start,n.text=r.text+n.innerText+n.text,Object.keys(r).forEach(function(e){Object.hasOwnProperty.call(n,e)||(n[e]=r[e])}),n.isFront&&(n.isFront=!1),e.children.splice(o,1),t(e,n)}var o=void 0,a={};e.prototype={constructor:e,addChild:function(n){var i=this.lastChildEnd(),o=new e({start:i,end:n.text&&i+n.text.length,children:[]},n);return o.innerText&&r(o),this.children.push(o),t(this,o),o},lastChild:function(){return this.children?this.children[this.children.length-1]||null:null},lastChildEnd:function(){var e=this.lastChild();return e?e.end:this.start+Math.max(0,this.text.indexOf(this.innerText))},tokenAt:function(e){if(e<this.start||e>=this.end)return null;if(this.childAt)return this.childAt[e]&&this.childAt[e].tokenAt(e)||this;if(this.children.length)for(var t=0;t<this.children.length;t+=1){var n=this.children[t].tokenAt(e);if(n)return n}return this},pathAt:function(e){if(e<this.start||e>=this.end)return[];if(this.childAt)return(this.childAt[e]&&this.childAt[e].pathAt(e)||[]).concat(this);var t=[];if(this.children.length)for(var n=0;n<this.children.length;n+=1){var r=this.children[n].pathAt(e);if(r.length){t.concat(r);break}}return t.concat(this)},nearestTokenAt:function(e){return e<this.start||e>=this.end?null:this.children?this.children.reduce(function(t,n){return t||(e>=n.start&&e<n.end?n:null)},null):this},everyLeaf:function(e){return this.children&&0!==this.children.length?this.children.reduce(function(t,n){return n.everyLeaf(e)&&t},!0):!!e(this)},isWhitespace:function(){return this.everyLeaf(function(e){return"whitespace"===e.type||!e.text.trim()})},isFrontToken:function(){return this.isFront},isBackToken:function(){return"matches"in this},demote:function(){this.type="text"},error:function(e){this.type="error",this.message=e},toString:function(){var e=this.type+"("+this.start+"\u2192"+this.end+")";return this.children&&this.children.length>0&&(e+="["+this.children+"]"),e}},o={lex:function(t,n){return r(new e({type:"root",start:n||0,end:t.length,text:t,innerText:t,children:[],childAt:{},innerMode:o.modes.start}))},rules:a,modes:{}},"object"===("undefined"==typeof module?"undefined":_typeof(module))?module.exports=o:"function"==typeof define&&define.amd?define("lexer",[],function(){return o}):this&&this.loaded?(this.modules||(this.modules={}),this.modules.Lexer=o):this.TwineLexer=o}.call(eval("this")||("undefined"!=typeof global?global:window)),function(){function e(t){return t&&"object"===(void 0===t?"undefined":_typeof(t))?(Object.keys(t).forEach(function(n){t[n]=e(t[n])}),t):(t+"").replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function t(e){return function(){return"("+e+Array.apply(0,arguments).join("|")+")"}}var n=void 0,r=t("?:"),i=t("?!"),o=t("?="),a="[ \\f\\t\\v\\u00a0\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000]*",s=a.replace("*","+"),c="\\b",u="[\\w\\-\\u00c0-\\u00de\\u00df-\\u00ff\\u0150\\u0170\\u0151\\u0171\\uD800-\\uDFFF]",l=u.replace("\\-",""),f=r("\\n","$"),p="("+r("\\\\\\n\\\\?|\\n\\\\","[^\\n]")+"+)",d=a+"(\\*+)"+s+p+f,h=a+"((?:0\\.)+)"+s+p+f,y=a+"-{3,}"+a+f,g=a+"(#{1,6})"+a+p+f,m=a+"(==+>|<=+|=+><=+|<==+>)"+a+f,v=a+"(=+\\|+|\\|+=+|=+\\|+=+|\\|=+\\|)"+a+f,b={opener:"\\[\\[(?!\\[)",text:"("+function(){return"[^"+Array.apply(0,arguments).map(e).join("")+"]*"}("]")+")",rightSeparator:r("\\->","\\|"),leftSeparator:"<\\-",closer:"\\]\\]",legacySeparator:"\\|",legacyText:"("+r("[^\\|\\]]","\\]"+i("\\]"))+"+)"},w=l+"*"+l.replace("\\w","a-zA-Z")+l+"*",x="\\$("+w+")",T="'s"+s+"("+w+")",S="("+w+")"+s+"of"+c+i("it\\b"),O="'s"+s,j=r("it","time")+c,k="its"+s+"("+w+")",A="its"+s,C="("+w+")"+s+"of"+s+"it"+c,E="of\\b"+s+"it"+c,N={opener:"\\(",name:"("+r(u+"+",x)+"):"+i("\\/"),closer:"\\)"},_=r("=<","=>","[gl]te?\\b","n?eq\\b","isnot\\b","are\\b","x\\b","isa\\b","or"+s+"a"+c),I={name:"[a-zA-Z][\\w\\-]*",attrs:"(?:\"[^\"]*\"|'[^']*'|[^'\">])*?"},P="\\|("+u+"+)(>|\\))",M="(<|\\()("+u+"+)\\|",D="_("+w+")"+c,L="\\b(\\d+(?:\\.\\d+)?(?:[eE][+\\-]?\\d+)?)"+i("m?s")+c;b.main=b.opener+r(b.text+b.rightSeparator,b.text.replace("*","*?")+b.leftSeparator)+b.text,n={upperLetter:"[A-Z\\u00c0-\\u00de\\u0150\\u0170]",lowerLetter:"[a-z0-9_\\-\\u00df-\\u00ff\\u0151\\u0171]",anyLetter:u,anyLetterStrict:l,whitespace:s,escapedLine:"\\\\\\n\\\\?|\\n\\\\",br:"\\n(?!\\\\)",commentFront:"\x3c!--",commentBack:"--\x3e",tag:"<\\/?"+I.name+I.attrs+">",tagPeek:"<",scriptStyleTag:"<("+r("script","style")+")"+I.attrs+">[^]*?<\\/\\1>",scriptStyleTagOpener:"<",url:"("+r("https?","mailto","javascript","ftp","data")+":\\/\\/[^\\s<]+[^<.,:;\"')\\]\\s])",bullet:"\\*",hr:y,heading:g,align:m,column:v,bulleted:d,numbered:h,strikeOpener:e("~~"),italicOpener:e("//"),boldOpener:e("''"),supOpener:e("^^"),strongFront:e("**"),strongBack:e("**"),emFront:e("*"),emBack:e("*"),verbatimOpener:"`+",collapsedFront:"{",collapsedBack:"}",hookAppendedFront:"\\[",hookPrependedFront:P+"\\[",hookFront:"\\[",hookBack:"\\]"+i(M),hookAppendedBack:"\\]"+M,passageLink:b.main+b.closer,passageLinkPeek:"[[",legacyLink:b.opener+b.legacyText+b.legacySeparator+b.legacyText+b.closer,legacyLinkPeek:"[[",simpleLink:b.opener+b.legacyText+b.closer,simpleLinkPeek:"[[",macroFront:N.opener+o(N.name),macroFrontPeek:"(",macroName:N.name,groupingFront:"\\("+i(N.name),groupingFrontPeek:"(",groupingBack:"\\)",twine1Macro:"<<[^>\\s]+\\s*(?:\\\\.|'(?:[^'\\\\]*\\\\.)*[^'\\\\]*'|\"(?:[^\"\\\\]*\\\\.)*[^\"\\\\]*\"|[^'\"\\\\>]|>(?!>))*>>",twine1MacroPeek:"<<",property:T,propertyPeek:"'s",belongingProperty:S,possessiveOperator:O,belongingOperator:"of\\b",belongingOperatorPeek:"of",itsOperator:A,itsOperatorPeek:"its",belongingItOperator:E,belongingItOperatorPeek:"of",variable:x,variablePeek:"$",tempVariable:D,tempVariablePeek:"_",hookRef:"\\?("+u+"+)\\b",hookRefPeek:"?",cssTime:"(\\d+\\.?\\d*|\\d*\\.?\\d+)(m?s)\\b",colour:r(r("Red","Orange","Yellow","Lime","Green","Cyan","Aqua","Blue","Navy","Purple","Fuchsia","Magenta","White","Gray","Grey","Black"),"#[\\dA-Fa-f]{3}(?:[\\dA-Fa-f]{3})?"),datatype:r("array","boolean","changer","colour","color","command","dm","datamap","ds","dataset","number","num","string","str"),number:L,boolean:r("true","false")+c,identifier:j,itsProperty:k,itsPropertyPeek:"its",belongingItProperty:C,escapedStringChar:"\\\\[^\\n]",singleStringOpener:"'",doubleStringOpener:'"',is:"is"+i(s+"not"+c,s+"an?"+c,s+"in"+c,s+"<",s+">")+c,isNot:"is"+s+"not"+i(s+"a"+c)+c,isA:"is"+s+"an?"+c,isNotA:"is"+s+"not"+s+"an?"+c,matches:"matches"+s,and:"and\\b",or:"or\\b",not:"not\\b",inequality:"((?:is(?:"+s+"not)?"+a+")*)("+r("<(?!=)","<=",">(?!=)",">=")+")",isIn:"is"+s+"in"+c,contains:"contains\\b",addition:e("+")+i("="),subtraction:e("-")+i("="),multiplication:e("*")+i("="),division:r("/","%")+i("="),comma:",",spread:"\\.\\.\\."+i("\\."),to:r("to\\b","="),into:"into\\b",making:"making\\b",where:"where\\b",when:"when\\b",via:"via\\b",with:"with\\b",each:"each\\b",augmentedAssign:r("\\+","\\-","\\*","\\/","%")+"=",bind:"bind\\b",incorrectOperator:_},"object"===("undefined"==typeof module?"undefined":_typeof(module))?module.exports=n:"function"==typeof define&&define.amd?define("patterns",[],function(){return n}):this&&this.loaded?(this.modules||(this.modules={}),this.modules.Patterns=n):this.Patterns=n}.call(eval("this")||("undefined"!=typeof global?global:window)),function(){function e(e){function t(e){return e=e||"innerText",function(t){var n=t.reduceRight(function(e,t,n){return e||(n?t:"")},""),r={};return r[e]=n,r}}function r(e,t){var n={};return n[e]=t,function(){return{isFront:!0,matches:n,cannotCross:["verbatimOpener"]}}}function i(e,t){return Object.keys(t).forEach(function(n){var r=t[n].fn;t[n].fn=function(t){var i=r(t);return i.text||(i.text=t[0]),i.type||(i.type=n),i.innerMode||(i.innerMode=e),i}}),t}var o=Object.bind(0,null),a=[],s=[],c=i(a,{hr:{fn:o},bulleted:{fn:function(e){return{depth:e[1].length,innerText:e[2]}}},numbered:{fn:function(e){return{depth:e[1].length/2,innerText:e[2]}}},heading:{fn:function(e){return{depth:e[1].length,innerText:e[2]}}},align:{fn:function(e){var t=void 0,n=e[1],r=n.indexOf("><");return~r?25===(t=Math.round(r/(n.length-2)*50))&&(t="center"):"<"===n[0]&&">"===n.slice(-1)?t="justify":n.indexOf(">")>-1?t="right":n.indexOf("<")>-1&&(t="left"),{align:t}}},column:{fn:function(e){var t=void 0,n=e[1],r=n.indexOf("|");return r&&r<n.length-1?t="center":"|"===n[0]&&"|"===n.slice(-1)?t="none":r===n.length-1?t="right":r||(t="left"),{column:t,width:/\|+/.exec(n)[0].length,marginLeft:/^=*/.exec(n)[0].length,marginRight:/=*$/.exec(n)[0].length}}}});Object.keys(c).forEach(function(e){c[e].canFollow=[null,"br","hr","bulleted","numbered","heading","align"],c[e].cannotFollow=["text"]});var u=i(a,{twine1Macro:{fn:function(){return{type:"error",message:"Harlowe macros use a different syntax to Twine 1 and SugarCube macros."}}},emBack:{fn:function(){return{matches:{emFront:"em"},cannotCross:["verbatimOpener"]}}},strongBack:{fn:function(){return{matches:{strongFront:"strong"},cannotCross:["verbatimOpener"]}}},strongFront:{fn:function(){return{isFront:!0}}},emFront:{fn:function(){return{isFront:!0}}},boldOpener:{fn:r("boldOpener","bold")},italicOpener:{fn:r("italicOpener","italic")},strikeOpener:{fn:r("strikeOpener","strike")},supOpener:{fn:r("supOpener","sup")},commentFront:{fn:function(){return{isFront:!0}}},commentBack:{fn:function(){return{matches:{commentFront:"comment"}}}},scriptStyleTag:{fn:o},tag:{fn:o},url:{fn:o},hookPrependedFront:{fn:function(e){return{name:e[1],hidden:")"===e[2],isFront:!0,tagPosition:"prepended"}}},hookFront:{fn:function(){return{isFront:!0}}},hookBack:{fn:function(){return{matches:{hookPrependedFront:"hook",hookFront:"hook"},cannotCross:["verbatimOpener"]}}},hookAppendedBack:{fn:function(e){return{name:e[2],hidden:"("===e[1],tagPosition:"appended",matches:{hookFront:"hook"},cannotCross:["verbatimOpener"]}}},verbatimOpener:{fn:function(e){var t=e[0].length,n={};return n["verbatim"+t]="verbatim",{type:"verbatim"+t,isFront:!0,matches:n}}},collapsedFront:{fn:function(){return{isFront:!0}}},collapsedBack:{fn:function(){return{matches:{collapsedFront:"collapsed"},cannotCross:["verbatimOpener"]}}},escapedLine:{fn:o},legacyLink:{fn:function(e){return{type:"twineLink",innerText:e[1],passage:e[2]}}},br:{fn:o}}),l=i(s,{macroFront:{fn:function(e){return{isFront:!0,name:e[1]}}},groupingBack:{fn:function(){return{matches:{groupingFront:"grouping",macroFront:"macro"},cannotCross:["singleStringOpener","doubleStringOpener"]}}},passageLink:{fn:function(e){var t=e[1]||"",n=e[2]||"",r=e[3]||"";return{type:"twineLink",innerText:n?r:t,passage:t?r:n}}},simpleLink:{fn:function(e){return{type:"twineLink",innerText:e[1]||"",passage:e[1]||""}}},variable:{fn:t("name")},tempVariable:{fn:t("name")}}),f=i(s,Object.assign({macroName:{canFollow:["macroFront"],fn:function(e){return e[2]?{isMethodCall:!0,innerText:e[2]}:{isMethodCall:!1}}},groupingFront:{fn:function(){return{isFront:!0}}},property:{fn:t("name"),canFollow:["variable","hookRef","property","tempVariable","colour","itsProperty","belongingItProperty","macro","grouping","string","boolean","number"]},possessiveOperator:{fn:o},itsProperty:{cannotFollow:["text"],fn:t("name")},itsOperator:{cannotFollow:["text"],fn:o},belongingItProperty:{cannotFollow:["text"],fn:t("name")},belongingItOperator:{
+cannotFollow:["text"],fn:o},belongingProperty:{cannotFollow:["text"],fn:t("name")},belongingOperator:{cannotFollow:["text"],fn:o},escapedStringChar:{fn:function(){return{type:"text"}}},singleStringOpener:{fn:function(){return{isFront:!0,matches:{singleStringOpener:"string"}}}},doubleStringOpener:{fn:function(){return{isFront:!0,matches:{doubleStringOpener:"string"}}}},hookRef:{fn:t("name")},cssTime:{fn:function(e){return{value:+e[1]*("s"===e[2].toLowerCase()?1e3:1)}}},datatype:{cannotFollow:["text"],fn:function(e){return{name:e[0].toLowerCase()}}},colour:{cannotFollow:["text"],fn:function(e){var t,n=e[0].toLowerCase(),r={red:"e61919",orange:"e68019",yellow:"e5e619",lime:"80e619",green:"19e619",cyan:"19e5e6",aqua:"19e5e6",blue:"197fe6",navy:"1919e6",purple:"7f19e6",fuchsia:"e619e5",magenta:"e619e5",white:"fff",black:"000",gray:"888",grey:"888"};return t=Object.hasOwnProperty.call(r,n)?"#"+r[n]:n,{colour:t}}},number:{fn:function(e){return{value:parseFloat(e[0])}}},inequality:{fn:function(e){return{operator:e[2],negate:e[1].indexOf("not")>-1}}},augmentedAssign:{fn:function(e){return{operator:e[0][0]}}},identifier:{fn:t("name"),cannotFollow:["text"]},whitespace:{fn:o,cannotFollow:"text"},incorrectOperator:{fn:function(e){var t={"=>":">=","=<":"<=",gte:">=",lte:"<=",gt:">",lt:"<",eq:"is",isnot:"is not",neq:"is not",isa:"is a",are:"is",x:"*","or a":"or"}[e[0].toLowerCase().replace(/\s+/g," ")];return{type:"error",message:"Please say "+(t?"'"+t+"'":"something else")+" instead of '"+e[0]+"'.",explanation:"In the interests of readability, I want certain operators to be in a specific form."}},cannotFollow:"text"}},["boolean","is","to","into","where","when","via","with","making","each","and","or","not","isNot","contains","isIn","isA","isNotA","matches","bind"].reduce(function(e,t){return e[t]={fn:o,cannotFollow:["text"]},e},{}),["comma","spread","addition","subtraction","multiplication","division"].reduce(function(e,t){return e[t]={fn:o},e},{})));a.push.apply(a,_toConsumableArray(Object.keys(c)).concat(_toConsumableArray(Object.keys(l)),_toConsumableArray(Object.keys(u)))),s.push.apply(s,_toConsumableArray(Object.keys(l)).concat(_toConsumableArray(Object.keys(f))));var p=Object.assign({},c,u,l,f);return Object.keys(p).forEach(function(e){var t=n[e];p[e].pattern="string"!=typeof t?t:new RegExp("^(?:"+t+")","i"),n[e+"Peek"]&&(p[e].peek=n[e+"Peek"])}),Object.assign(e.rules,p),e.modes.start=e.modes.markup=a,e.modes.macro=s,e}function t(t){return Object.freeze({lex:e(t).lex,Patterns:n})}var n=void 0;Object.assign=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},"object"===("undefined"==typeof module?"undefined":_typeof(module))?(n=require("./patterns"),module.exports=t(require("./lexer"))):"function"==typeof define&&define.amd?define("markup",["lexer","patterns"],function(e,r){return n=r,t(e)}):this&&this.loaded&&this.modules?(n=this.modules.Patterns,this.modules.Markup=t(this.modules.Lexer)):(n=this.Patterns,this.TwineMarkup=t(this.TwineLexer))}.call(eval("this")||("undefined"!=typeof global?global:window)),define("utils/selectors",[],function(){return Object.freeze({passage:"tw-passage",story:"tw-story",sidebar:"tw-sidebar",internalLink:"tw-link",brokenLink:"tw-broken-link",hook:"tw-hook",enchantment:"tw-enchantment",expression:"tw-expression",script:"[role=script]",stylesheet:"[role=stylesheet]",storyData:"tw-storydata",passageData:"tw-passagedata",collapsed:"tw-collapsed"})}),define("utils/polyfills",[],function(){var e=Array.prototype;"function"!=typeof e.includes&&(e.includes=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(!Number.isNaN(t)&&Number.isFinite(n)&&void 0!==t)return e.indexOf.call(this,t,n)>-1;var r=Object(this),i=parseInt(r.length);if(i<=0)return!1;for(var o=n>=0?n:Math.max(0,i+n);o<i;){if(Object.is(t,r[o]))return!0;o+=1}return!1})}),define("utils",["jquery","markup","utils/selectors","utils/polyfills"],function(e,t,n){function r(t,n){var r=o[n];if(!r[t]){var i=e("<p>").appendTo(document.body).attr("data-t8n",t).addClass(n);r[t]=u.cssTimeUnit(i.css("animation-duration"))+u.cssTimeUnit(i.css("animation-delay")),i.remove()}return r[t]}var i={configurable:0,writable:0},o={"transition-in":Object.create(null),"transition-out":Object.create(null)},a="audio,blockquote,canvas,div,h1,h2,h3,h4,h5,hr,ol,p,pre,table,ul,video,tw-align,tw-story,tw-passage".split(","),s="a,b,i,em,strong,sup,sub,abbr,acronym,s,strike,del,big,small,script,img,button,input,tw-link,tw-broken-link,tw-verbatim,tw-collapsed,tw-error".split(","),c=["audio"],u=void 0,l=void 0,f=[];return u={lockProperty:function(e,t,n){var r=Object.create(i);return n&&(r.value=n),Object.defineProperty(e,t,r),e},permutations:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];for(var r=t.length,i=[[].concat(t)],o=Array(r).fill(0),a=1,s=void 0,c=void 0;a<r;)o[a]<a?(s=a%2&&o[a],c=t[a],t[a]=t[s],t[s]=c,++o[a],a=1,i.push([].concat(t))):(o[a]=0,++a);return i},toJSLiteral:function(e){return e instanceof Map?"(new Map("+u.toJSLiteral([].concat(_toConsumableArray(e.entries())))+"))":e instanceof Set?"(new Set("+u.toJSLiteral([].concat(_toConsumableArray(e.values())))+"))":JSON.stringify(e)},cssTimeUnit:function(e){return e=e.toLowerCase(),"ms"===e.slice(-2)?+e.slice(0,-2)||0:"s"===e.slice(-1)?1e3*+e.slice(0,-1)||0:0},nth:function(e){var t=(+e+"").slice(-1);return e+("1"===t?"st":"2"===t?"nd":"3"===t?"rd":"th")},plural:function(e,t){return e+" "+t+(e>1?"s":"")},andList:function(e){return 1===e.length?e[0]:e.slice(0,-1).join(", ")+" and "+e[e.length-1]},realWhitespace:"[ \\n\\r\\f\\t\\v\\u00a0\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000]",anyRealLetter:"[\\dA-Za-z\\u00c0-\\u00de\\u00df-\\u00ff\\u0150\\u0170\\u0151\\u0171\\uD800-\\uDFFF]",unescape:function(e){return e.replace(/&(?:amp|lt|gt|quot|nbsp|zwnj|#39|#96);/g,function(e){return{"&amp;":"&","&gt;":">","&lt;":"<","&quot;":'"',"&#39;":"'","&nbsp;":String.fromCharCode(160),"&zwnj;":String.fromCharCode(8204)}[e]})},escape:function(e){return e.replace(/[&><"']/g,function(e){return{"&":"&amp;",">":"&gt;","<":"&lt;",'"':"&quot;","'":"&#39;"}[e]})},insensitiveName:function(e){return(e+"").toLowerCase().replace(/-|_/g,"")},childrenProbablyInline:function(e){var t=[];return Array.prototype.every.call(e.find("*"),function(e){return!(!e.hidden&&!/none|inline/.test(e.style.display))||!a.includes(e.tagName.toLowerCase())&&!/none|inline/.test(e.style.display)&&(!!s.includes(e.tagName.toLowerCase())||(t.push(e),!0))})&&t.every(function(e){return/none|inline/.test(e.style.display)})},transitionReplace:function(t,r,i){var o=t.closest(n.hook);o.length>0&&(t=o);var a=e("<tw-transition-container>").css("position","relative");a.insertBefore(t.first());var s=void 0;r&&(s=e("<tw-transition-container>").appendTo(a),r.appendTo(s));var c=e("<tw-transition-container>").css("position","absolute").prependTo(a);t.detach().appendTo(c),u.transitionOut(c,i),r&&u.transitionIn(s,i,function(){s.unwrap().children().first().unwrap()})},transitionOut:function(e,t,n){function i(){e.remove()}var o=u.childrenProbablyInline(e);(e.length>1||!o||!["tw-hook","tw-passage"].includes(e.tag()))&&(e=e.wrapAll("<tw-transition-container>").parent()),e.attr("data-t8n",t).addClass("transition-out"),u.childrenProbablyInline(e)&&e.css("display","inline-block"),"number"==typeof n&&e.css("animation-duration",n+"ms");var a=n||r(t,"transition-out");a?window.setTimeout(i,a):i()},transitionIn:function(e,t,n){function i(){var t=0===e.findAndFilter(c.join(",")).length;a&&t?e.contents().unwrap():e.removeClass("transition-in").removeAttr("data-t8n")}var o=u.childrenProbablyInline(e),a=e.length>1||!o||!["tw-hook","tw-passage"].includes(e.tag());a&&(e=e.wrapAll("<tw-transition-container>").parent()),e.attr("data-t8n",t).addClass("transition-in"),"number"==typeof n&&e.css("animation-duration",n+"ms"),u.childrenProbablyInline(e)&&e.css("display","inline-block");var s=n||r(t,"transition-in");s?window.setTimeout(i,s):i()},$:function(t,n){return e(t,n||u.storyElement).not(".transition-out, .transition-out *")},impossible:function(e,t){window.console&&console.error(e+"(): "+t)},assertMustHave:function(e,t){if(window.console)for(var n=0;n<t.length;n+=1)t[n]in e||console.error("Assertion failed: object lacks property "+t[n])},assertOnlyHas:function(e,t){if(window.console)for(var n in e)t.includes(n)||console.error("Assertion failed: object had unexpected property '"+n+"'!")},onStartup:function(e){f?f.push(e):e()},get storyElement(){return l}},e(function(){l=e(n.story),f.forEach(function(e){return e()}),f=null}),Object.freeze(u)}),define("passages",["jquery","utils","utils/selectors"],function(e,t,n){function r(e){return Object.assign(new Map([["source",i(e.html())],["tags",(e.attr("tags")||"").split(/\s/)||[]],["name",e.attr("name")]]),{TwineScript_TypeName:"a passage datamap",TwineScript_ObjectName:"a passage datamap"})}var i=t.unescape,o=t.onStartup,a=Object.assign(new Map,{TwineScript_ObjectName:"the Passages datamap",getTagged:function(e){var t=[];return this.forEach(function(n){var r=n instanceof Map&&n.get("tags");Array.isArray(r)&&r.includes(e)&&t.push(n)}),t.sort(function(e,t){return e.get("name")>t.get("name")})},hasValid:function(e){var t=this.get(e);return t&&t instanceof Map&&t.has("source")},create:r});return o(function(){Array.from(e(n.storyData+" > "+n.passageData)).forEach(function(t){t=e(t),a.set(t.attr("name"),new r(t))})}),a}),define("datatypes/hookset",["jquery","utils","utils/selectors","markup"],function(e,t,n,r){function i(e,t,n){var r=e.textContent.length;if(!(t>=r)){var i=void 0,o=[i=0===t?e:e.splitText(t)];return n&&(n<=0&&(n=r-n),n<r&&o.push(i.splitText(n-t))),o}}function o(e,t){var n=[],r="",a=[];if(!e.length||!t)return a;for(;e.length>0;){n.push(e[0]),r+=e[0].textContent,e.shift();var s=r.indexOf(t);if(s>-1){for(var c,u=r.length-(s+t.length);s>=n[0].textContent.length;)s-=n[0].textContent.length,n.shift();if(1===n.length){var l=i(n[0],s,s+t.length);a.push(l[0]),l[1]&&e.unshift(l[1]);break}a.push(i(n[0],s,n[0].length)[0]),(c=a).push.apply(c,_toConsumableArray(n.slice(1,-1)));var f=i(n[n.length-1],0,n[n.length-1].textContent.length-u);a.push(f[0]),f[1]&&e.unshift(f[1]),a=a.filter(Boolean);break}}return[a].concat(_toConsumableArray(o(e,t)))}function a(t,n,r){var i=o(n.textNodes(),t),a=e();return i.forEach(function(t){a=a.add(e(t).wrapAll(r))}),a.parent()}function s(e){e=t.insensitiveName(e).replace(/\?/g,"").replace(/"/g,"&quot;");var r=n.hook+'[name="'+e+'"]';return r+={page:", tw-story",passage:", tw-passage",sidebar:", tw-sidebar",link:", tw-link, .enchantment-link"}[e]||""}function c(n){var r=n.dom,i=e();this.prev&&(i=i.add(c.call(this.prev,{dom:r})));var o=function(t,n){return Array.isArray(n)?n.reduce(function(e,n){return e.add(t.get(n))},e()):e(t.get(n))};if(this.selector){var u=void 0;u=this.selector.match("^"+f.hookRef+"$")?r.add(r.parentsUntil(t.storyElement.parent())).findAndFilter(s(this.selector)):a(this.selector,r,"<tw-pseudo-hook>"),i=this.properties.length?i.add(this.properties.reduce(o,u)):i.add(u)}return this.base&&(i=i.add(this.properties.reduce(o,c.call(this.base,{dom:r})))),i}function u(e){var n=e.dom;t.$("tw-pseudo-hook",n).contents().unwrap().parent().each(function(){this.normalize()})}function l(e){if(!e)return[];var n=e.selector,r=e.base,i=e.properties,o=e.prev;return[JSON.stringify([t.insensitiveName(n)||"",l(r),[].concat(_toConsumableArray(i)).sort()])].concat(_toConsumableArray(l(o))).sort()}var f=r.Patterns,p=Object.freeze({forEach:function(t,n){var r=c.call(this,t).each(function(t){n(e(this),t)});return u.call(this,t),r},get TwineScript_ObjectName(){return this.properties.length>0||this.prev?"a complex hook name":this.selector+" (a hook name)"},TwineScript_TypeName:"a hook name (like ?this)",TwineScript_Unstorable:!0,"TwineScript_+":function(e){var t=e.TwineScript_Clone();return t.prev=this,t},TwineScript_is:function(e){return l(this)+""==l(e)+""},TwineScript_GetElement:function(e){return p.create(void 0,this,[e],void 0)},TwineScript_Clone:function(){return p.create(this.selector,this.base,this.properties,this.prev)},create:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:void 0;return Object.assign(Object.create(this||p),{selector:e,base:t,properties:n,prev:r})},from:function(e){return p.isPrototypeOf(e)?e:p.create(e)}});return p}),define("internaltypes/twineerror",["jquery","utils"],function(e,t){var n=t.impossible,r=t.escape,i={syntax:"The markup seems to contain a mistake.",saving:"I tried to save or load the game, but I couldn't do it.",operation:"I tried to perform an operation on some data, but the data's type was incorrect.",macrocall:"I tried to use a macro, but its call wasn't written correctly.",datatype:"I tried to use a macro, but was given the wrong type of data to it.",infinite:"I almost ended up doing the same thing over and over, forever.",property:"I tried to access a value in a string/array/datamap, but I couldn't find it.",unimplemented:"I currently don't have this particular feature. I'm sorry.",javascript:"This error message was reported by your browser's Javascript engine. I don't understand it either, but it usually means that an expression was badly written."},o={create:function(e,t,r){return t||n("TwineError.create","called with only 1 string."),r||e in i||n("TwineError.create","no error explanation given"),Object.assign(Object.create(this),{type:e,message:t,explanation:r})},fromError:function(e){return o.create("javascript","\u2615 "+e.message)},containsError:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce(function(e,t){return e||(t instanceof Error?t:o.isPrototypeOf(t)?t:!!Array.isArray(t)&&o.containsError.apply(o,_toConsumableArray(t)))},!1)},createWarning:function(e,t){return Object.assign(this.create(e,t),{warning:!0})},render:function(t){t=t||"";var n=e("<tw-error class='"+("javascript"===this.type?"javascript ":"")+(this.warning?"warning":"error")+"' title='"+r(t)+"'>"+r(this.message)+"</tw-error>"),o=e("<tw-error-explanation>").text(this.explanation||i[this.type]).hide(),a=e("<tw-error-explanation-button tabindex=0>").html("<span class='folddown-arrowhead'>&#9658;</span>");return a.on("click",function(){o.toggle(),a.children(".folddown-arrowhead").css("transform","rotate("+(o.is(":visible")?"90deg":"0deg")+")")}),n.append(a).append(o),n.data("TwineError",this),n}};return o}),define("utils/operationutils",["jquery","utils","datatypes/hookset","internaltypes/twineerror"],function(e,t,n,r){function i(e){return!!e&&("object"===(void 0===e?"undefined":_typeof(e))||"function"==typeof e)}function o(e){return Array.isArray(e)?"array":e instanceof Map?"datamap":e instanceof Set?"dataset":"string"==typeof e?"string":e&&"object"===(void 0===e?"undefined":_typeof(e))?"object":""}function a(e,t){if(e instanceof Map||v("isValidDatamapName","called with non-Map"),"string"!=typeof t&&"number"!=typeof t)return r.create("property","Only strings and numbers can be used as data names for "+l(e)+", not "+l(t)+".");var n="string"==typeof t?+t:""+t;return!(!Number.isNaN(n)&&e.has(n))||r.create("property","You mustn't use both "+l(t)+" and "+l(n)+" as data names in the same datamap.")}function s(e,t){if(null===t)return void 0===e;if(t.innerType){if("optional"===t.pattern||"zero or more"===t.pattern)return void 0===e||s(e,t.innerType);if("either"===t.pattern)return t.innerType.some(function(t){return s(e,t)});if("lambda"===t.pattern&&s(e,t.innerType))return"string"!=typeof t.clauses&&v("singleTypeCheck","lambda signature had non-string clauses"),t.clauses.includes("where")==="where"in e&&t.clauses.includes("making")==="making"in e&&t.clauses.includes("via")==="via"in e&&t.clauses.includes("with")==="with"in e;if("wrapped"===t.pattern)return s(e,t.innerType)}return(void 0===t||void 0!==e)&&("anything"===t.TwineScript_TypeName&&void 0!==e&&!e.TwineScript_Unstorable||(t===String?"string"==typeof e:t===Boolean?"boolean"==typeof e:t===parseInt?"number"==typeof e&&!Number.isNaN(e)&&!(e+"").includes("."):t===Number?"number"==typeof e&&!Number.isNaN(e):t===Array?Array.isArray(e):t===Map||t===Set?e instanceof t:Object.isPrototypeOf.call(t,e)))}function c(e){return"string"==typeof e||Array.isArray(e)||n.isPrototypeOf(e)}function u(e){if(!i(e))return e;if("function"==typeof e.TwineScript_Clone)return e.TwineScript_Clone();if(Array.isArray(e))return[].concat(_toConsumableArray(e));if(e instanceof Map)return new Map(e);if(e instanceof Set)return new Set(e);if("function"==typeof e)return Object.assign(e.bind(),e);switch(Object.getPrototypeOf(e)){case Object.prototype:return Object.assign({},e);case null:return Object.assign(Object.create(null),e)}return v("OperationUtils.clone","The value "+(e.toSource?e.toSource():e)+" cannot be cloned!"),e}function l(e){return i(e)&&"TwineScript_ObjectName"in e?e.TwineScript_ObjectName:Array.isArray(e)?"an array":e instanceof Map?"a datamap":e instanceof Set?"a dataset":"boolean"==typeof e?"the boolean value '"+e+"'":"string"==typeof e||"number"==typeof e?"the "+(void 0===e?"undefined":_typeof(e))+" "+w(e):void 0===e?"an empty variable":"...whatever this is"}function f(e){return Object.getPrototypeOf(e)===Object.prototype&&e.innerType?e.typeName?e.typeName:"either"===e.pattern?(Array.isArray(e.innerType)||v("typeName",'"either" pattern had non-array inner type'),e.innerType.map(f).join(" or ")):"optional"===e.pattern?"(an optional) "+f(e.innerType):f(e.innerType):e===String||e===Number||e===Boolean?"a "+_typeof(e()):e===parseInt?"a whole number":e===Map?"a datamap":e===Set?"a dataset":e===Array?"an array":i(e)&&"TwineScript_TypeName"in e?e.TwineScript_TypeName:l(e)}function p(e,t){return"object"!==(void 0===e?"undefined":_typeof(e))&&"object"!==(void 0===t?"undefined":_typeof(t))?e===t:Array.isArray(e)&&Array.isArray(t)?e.length===t.length&&e.every(function(e,n){return p(t[n],e)}):e instanceof Map&&t instanceof Map?p(Array.from(e.entries()).sort(),Array.from(t.entries()).sort()):e instanceof Set&&t instanceof Set?p([].concat(_toConsumableArray(e)),[].concat(_toConsumableArray(t))):e&&"function"==typeof e.TwineScript_is?e.TwineScript_is(t):e&&"object"===(void 0===e?"undefined":_typeof(e))&&t&&"object"===(void 0===t?"undefined":_typeof(t))&&Object.getPrototypeOf(e)===Object.prototype&&Object.getPrototypeOf(t)===Object.prototype?p(Object.getOwnPropertyNames(e).map(function(t){return[t,e[t]]}),Object.getOwnPropertyNames(t).map(function(e){return[e,t[e]]})):Object.is(e,t)}function d(e,t){if(e||""===e){if("string"==typeof e)return e.includes(t);if(Array.isArray(e))return e.some(function(e){return p(e,t)});if(e instanceof Set||e instanceof Map)return Array.from(e.keys()).some(function(e){return p(e,t)})}return r.create("operation",l(e)+" cannot contain any values, let alone "+l(t))}function h(e,t){return"function"==typeof t.TwineScript_IsTypeOf?t.TwineScript_IsTypeOf(e):r.create("operation",'"is a" should only be used to compare type names, not '+l(t)+".")}function y(e,t){return e&&"function"==typeof e.TwineScript_IsTypeOf?e.TwineScript_IsTypeOf(t):t&&"function"==typeof t.TwineScript_IsTypeOf?t.TwineScript_IsTypeOf(e):Array.isArray(e)&&Array.isArray(t)?e.length===t.length&&e.every(function(e,n){return y(e,t[n])}):e instanceof Map&&t instanceof Map?y(Array.from(e.entries()).sort(),Array.from(t.entries()).sort()):e instanceof Set&&t instanceof Set?(e=[].concat(_toConsumableArray(e)),b.apply(void 0,_toConsumableArray(t)).some(function(t){return y(e,t)})):p(e,t)}function g(e,t,n){if(!t||!n)return r.create("macrocall","The sub"+o(e)+" index values must not be 0 or NaN.");if(t<0&&(t=e.length+t+1),n<0&&(n=e.length+n+1),t>n)return g(e,n,t);var i="string"==typeof e;i&&(e=Array.from(e));var a=e.slice(t>0?t-1:t,n).map(u);return i?a.join(""):a}function m(t){return r.containsError(t)?t:t&&"function"==typeof t.TwineScript_Print?t.TwineScript_Print():t instanceof Map?(t=Array.from(t.entries()),r.containsError(t)?t:t.reduce(function(e,t){var n=_slicedToArray(t,2),r=n[0],i=n[1];return e+"<tr><td>`"+m(r)+"`</td><td>`"+m(i)+"`</td></tr>"},"<table class=datamap>")+"</table>"):t instanceof Set?Array.from(t.values()).map(m)+"":Array.isArray(t)?t.map(m)+"":t instanceof e?t:i(t)?r.create("unimplemented","I don't know how to print this value yet."):t+""}var v=t.impossible,b=t.permutations,w=t.toJSLiteral;return Object.freeze({isObject:i,singleTypeCheck:s,isValidDatamapName:a,collectionType:o,isSequential:c,clone:u,objectName:l,typeName:f,is:p,contains:d,isA:h,matches:y,subset:g,printBuiltinValue:m,numericIndex:/^(?:[1-9]\d*|0)$/,unique:function(e,t,n){return!n.slice(t+1).some(function(t){return p(e,t)})}})}),define("twinescript/compiler",["utils"],function(e){function t(e,t){for(var n=0;n<e.length;n+=1)if(t.includes(e[n].type))return n;return NaN}function n(e,n){return e.length-1-t.apply(void 0,[[].concat(_toConsumableArray(e)).reverse(),n])}function r(e,r){var i=[];return e.length?([["error"],["comma"],{rightAssociative:["spread","bind"]},["to"],["into"],["where","when","via"],["with","making","each"],["augmentedAssign"],["and","or"],["is","isNot"],["contains","isIn"],["isA","isNotA"],["matches"],["inequality"],["addition","subtraction"],["multiplication","division"],{rightAssociative:["not","positive","negative"]},{rightAssociative:["belongingProperty"]},{rightAssociative:["belongingOperator","belongingItOperator"]},["property"],["itsProperty"],{rightAssociative:["belongingItProperty"]},["possessiveOperator","itsOperator"],["twineLink"],["macro"],["grouping"]]["most"===r?"reverse":"valueOf"]().some(function(r){var o=void 0;if(o=r.rightAssociative?t(e,r.rightAssociative):n(e,r),!Number.isNaN(o)&&o>-1)return i=[e[o],o],!0}),i):i}function i(e){if("inequality"===e.type){var t=e.operator;return e.negate?{">":"<=","<":">=",">=":"<","<=":">"}[t]:t}return e.type}function o(e){var t=i(e);return{">":"<","<":">",">=":"<=","<=":">=",contains:"isIn",isIn:"contains",isA:"typifies",typifies:"isA",isNotA:"untypifies",untypifies:"isNotA"}[t]||t}function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.isVarRef,u=t.whitespaceError,l=t.elidedComparison,f=t.testNeedsRight;if(e=[].concat(e),!e.length)return n&&u?"TwineError.create('operation',"+s(u)+")":"";var p=e[0];if(1===e.length){if("identifier"===p.type)return n?"VarRef.create(Operations.Identifiers,"+s(p.text)+")":" Operations.Identifiers."+p.text.toLowerCase()+" ";if("variable"===p.type)return"VarRef.create(State.variables,"+s(p.name)+")"+(n?"":".get()");if("tempVariable"===p.type)return"VarRef.create(section.stack[0].tempVariables,"+s(p.name)+")"+(n?"":".get()");if("hookRef"===p.type)return" HookSet.create('?"+p.name+"') ";if("string"===p.type)return p.text.replace(/\n/g,"\\n");if("colour"===p.type)return"Colour.create("+s(p.colour)+")";if("datatype"===p.type)return"Datatype.create("+s(p.name)+")";if("root"===p.type)return a(p.children);if("whitespace"===p.type&&n&&u)return"TwineError.create('operation',"+s(u)+")"}var d=void 0,h=r(e,"least"),y=_slicedToArray(h,2);p=y[0],d=y[1];var g=(p||{}).type,m=function(e){return{isVarRef:!0,whitespaceError:"I need usable data to be on the "+e+' of "'+p.text+'".'}},v=void 0,b=void 0,w=void 0,x=void 0,T=void 0,S=void 0,O=!0,j=!0,k=!1;if(g){if("error"===g)return"TwineError.create('syntax',"+s(p.message)+")";if("comma"===g)w=",",j=!1;else if("spread"===g)w="Operations.makeSpreader(",b=a(e.slice(d+1))+")",O=!1;else if("bind"===g)w="VarBind.create(",b=a(e.slice(d+1),m("right"))+")",O=!1;else if("to"===g)T="to",b=a(e.slice(d+1),m("right")),v="Operations.setIt("+a(e.slice(0,d),m("left"))+")";else if("into"===g)T="into",b=a(e.slice(0,d),m("left")),v="Operations.setIt("+a(e.slice(d+1),m("right"))+")";else if("where"===g||"when"===g||"via"===g)v="Lambda.create("+(a(e.slice(0,d),{isVarRef:!0,whitespaceError:null}).trim()||"undefined")+",",w=s(p.type)+",",b=s(a(e.slice(d+1)))+")";else if("with"===g||"making"===g||"each"===g){var A=e.slice(d+1);![2,3].includes(A.length)||"whitespace"!==A[0].type||"tempVariable"!==A[1].type||A[2]&&"whitespace"!==A[2].type?(v="TwineError.create('operation','I need a temporary variable to the right of \\'",w=p.type,b="\\'.')"):"each"===g?(v="Lambda.create(",w=a(A,m("right")).trim(),b=",'where','true')"):(v="Lambda.create("+(a(e.slice(0,d),{isVarRef:!0,whitespaceError:null}).trim()||"undefined")+",",w=s(p.type)+",",b=s(A[1].name)+")")}else if("augmentedAssign"===g)T=p.operator,v=a(e.slice(0,d),m("left")),b="Operations['"+T+"']("+a(e.slice(0,d))+","+a(e.slice(d+1))+")";else if("and"===g||"or"===g){var C=function e(t){var n=r(t,"least"),i=_slicedToArray(n,2),o=i[0],a=i[1];if(o)return["inequality","is","isNot","isIn","contains","isA","typifies","isNotA","untypifies","matches"].includes(o.type)?o:["and","or"].includes(o.type)?e(t.slice(0,a))||e(t.slice(a+1)):void 0},E=C(e.slice(0,d)),N=C(e.slice(d+1)),_="TwineError.create('operation', 'This use of \"is not\" and \""+g+"\" is grammatically ambiguous','Maybe try rewriting this as \"__ is not __ "+g+" __ is not __\"') ";if(x=p.type,l===p.type)x="",v=a(e.slice(0,d),{isVarRef:n,elidedComparison:l}).trim(),w=",",b=a(e.slice(d+1),{elidedComparison:l}).trim();else if(E&&!N){var I=E,P=s(i(I));if("isNot"===I.type||"isNotA"===I.type||"untypifies"===I.type)return _;b="Operations.elidedComparisonOperator("+s(p.type)+","+P+","+a(e.slice(d+1),{elidedComparison:g})+")"}else if(!E&&N){var M=N,D=e.indexOf(M),L=s(o(M));if("isNot"===M.type||"isNotA"===M.type||"untypifies"===M.type)return _;b="Operations.elidedComparisonOperator("+s(p.type)+","+L+","+a(e.slice(0,d),{elidedComparison:g})+")",v=a([].concat(_toConsumableArray(e.slice(D+1)),[Object.assign(Object.create(M),_defineProperty({},"inequality"===M.type?"operator":"type",o(M)))],_toConsumableArray(e.slice(d+1,D))))}}else if("is"===g||"isNot"===g||"contains"===g||"isIn"===g||"inequality"===g||"isA"===g||"typifies"===g||"isNotA"===g||"untypifies"===g||"matches"===g)k=!0,x=i(p);else if("addition"===g||"subtraction"===g){var q=a(e.slice(0,d),{testNeedsRight:!0}).trim();if(!q)return p.type={addition:"positive",subtraction:"negative"}[g],a(e,{isVarRef:n,whitespaceError:u,elidedComparison:l,testNeedsRight:f});x=p.text}else if("multiplication"===g||"division"===g)x=p.text;else if("positive"===g||"negative"===g)x="*",v="negative"===g?"-1":"1";else if("not"===g)w=" ",b="Operations.not("+a(e.slice(d+1))+")",O=!1;else if("belongingProperty"===g)b="VarRef.create("+a(e.slice(d+1),m("right"))+","+s(p.name)+")"+(n?"":".get()"),w=" ",O=j=!1;else if("belongingOperator"===g||"belongingItOperator"===g)p.type.includes("It")?(b="Operations.Identifiers.it",j=!1):b=a(e.slice(d+1),m("right")),S="belonging";else if("property"===g)v="VarRef.create("+a(e.slice(0,d),m("left"))+","+s(p.name)+")"+(n?"":".get()"),w=" ",O=j=!1;else if("itsProperty"===g||"belongingItProperty"===g)v="VarRef.create(Operations.Identifiers.it,"+s(p.name)+").get()",w=" ",O=j=!1;else if("possessiveOperator"===g||"itsOperator"===g)p.type.includes("it")&&(v="Operations.Identifiers.it",O=!1),S="possessive";else if("twineLink"===g)w='Macros.run("link-goto", [section,'+s(p.innerText)+","+s(p.passage)+"])",O=j=!1;else if("macro"===g){var R=p.children[0];"macroName"!==R.type&&c("Compiler.compile","macro token had no macroName child token"),w="Macros.run("+(R.isMethodCall?a(R.children):'"'+p.name+'"')+", [section,"+a(p.children.slice(1))+"])",O=j=!1}else"grouping"===g&&(w="("+a(p.children,{isVarRef:n})+")",O=j=!1)}else;return d>-1?(x&&(n=!1),v=v||a(e.slice(0,d),{isVarRef:n}).trim(),b=b||a(e.slice(d+1)).trim(),k&&!v&&(v=" Operations.Identifiers.it "),O&&!v||j&&!b?f&&j&&!b?"":"TwineError.create('operation','I need some code to be "+(O?"left ":"")+(O&&j?"and ":"")+(j?"right ":"")+'of "'+p.text+"\"')":w?v+w+b:T?"Operations.makeAssignmentRequest("+[v,b,s(T)]+")":S?"VarRef.create("+("belonging"===S?b:v)+",{computed:true,value:"+("belonging"===S?v:b)+"})"+(n?"":".get()"):x?" Operations["+s(x)+"]("+v+","+b+") ":""):1===e.length?(("value"in e[0]?e[0].value:e[0].text)+"").trim()||" ":e.reduce(function(e,t){return e+a(t,{isVarRef:n})},"")}var s=e.toJSLiteral,c=e.impossible;return a}),define("renderer",["utils","markup","twinescript/compiler","internaltypes/twineerror"],function(e,t,n,r){function i(e,t){return"<"+t+">"+e+"</"+t+">"}function o(e,t){var n=l.render(e.children);return n&&i(n,t)}var a=e.escape,s=e.impossible,c=e.toJSLiteral,u=e.insensitiveName,l=void 0,f="text-align: center; max-width:50%; ";return l={options:{},exec:function(){var e=void 0,n=void 0;return function(r){return"string"!=typeof r?(s("Renderer.exec","source was not a string, but "+(void 0===r?"undefined":_typeof(r))),""):r===e?n:(e=r,n=l.render(t.lex(r).children))}}(),render:function e(s){var p="",d=[];if(!s)return p;for(var h=s.length,y=0;y<h;y+=1){var g=s[y];switch(g.type){case"error":p+=r.create("syntax",g.message).render(a(g.text))[0].outerHTML;break;case"numbered":case"bulleted":var m="numbered"===g.type?"ol":"ul";p+="<"+m+">";for(var v=1;y<h&&s[y]&&s[y].type===g.type;)p+=("<"+m+">").repeat(Math.max(0,s[y].depth-v)),p+=("</"+m+">").repeat(Math.max(0,v-s[y].depth)),v=s[y].depth,p+=o(s[y],"li"),y+=1;y-=1,p+=("</"+m+">").repeat(v+1);break;case"align":for(;g&&"align"===g.type;){var b=g,w=b.align,x=y+=1;if("left"===w){y-=1;break}for(;y<h&&s[y]&&"align"!==s[y].type;)y+=1;var T=e(s.slice(x,y)),S="";switch(w){case"center":S+=f+"margin-left: auto; margin-right: auto;";break;case"justify":case"right":S+="text-align: "+w+";";break;default:+w&&(S+=f+"margin-left: "+w+"%;")}p+="<tw-align "+(S?'style="'+S+'"':"")+(l.options.debug?' title="'+g.text+'"':"")+">"+T+"</tw-align>\n",g=s[y]}break;case"column":for(var O=[];g&&"column"===g.type;){var j=g,k=j.column,A=y+=1;if("none"===k){y-=1;break}for(;y<h&&s[y]&&"column"!==s[y].type;)y+=1;O.push({text:g.text,type:k,body:e(s.slice(A,y)),width:g.width,marginLeft:g.marginLeft,marginRight:g.marginRight}),g=s[y]}O.length&&function(){var e=O.reduce(function(e,t){return e+t.width},0);p+="<tw-columns>"+O.map(function(t){return"<tw-column type="+t.type+'  style="width:'+t.width/e*100+"%; margin-left: "+t.marginLeft+"em; margin-right: "+t.marginRight+'em;" '+(l.options.debug?' title="'+t.text+'"':"")+">"+t.body+"</tw-column>\n"}).join("")+"</tw-columns>"}();break;case"heading":p+=o(g,"h"+g.depth);break;case"br":d.length&&!/td|th/.test(d[0])||(p+="<br>");break;case"hr":p+="<hr>";break;case"escapedLine":case"comment":break;case"inlineUrl":p+='<a class="link" href="'+a(g.text)+'">'+g.text+"</a>";break;case"scriptStyleTag":case"tag":var C=g.text.toLowerCase();/^<\/?(?:table|thead|tbody|tr|tfoot|td|th)\b/.test(C)&&d[g.text.startsWith("</")?"shift":"unshift"](C),p+=g.text.startsWith("</")?g.text:g.text.replace(/>$/," data-raw>");break;case"sub":case"sup":case"strong":case"em":p+=o(g,g.type);break;case"strike":p+=o(g,"s");break;case"bold":p+=o(g,"b");break;case"italic":p+=o(g,"i");break;case"twineLink":var E=_slicedToArray(t.lex("(link-goto:"+c(g.innerText)+","+c(g.passage)+")").children,1),N=E[0];p+='<tw-expression type="macro" name="link-goto"'+(l.options.debug?' title="'+a(g.text)+'"':"")+' js="'+a(n(N))+'"></tw-expression>';break;case"hook":p+="<tw-hook "+(g.hidden?"hidden ":"")+(g.name?'name="'+u(g.name)+'"':"")+(l.options.debug&&g.name?' title="Hook: ?'+g.name+'"':"")+' source="'+a(g.innerText)+'"></tw-hook>';break;case"verbatim":p+=i(a(g.innerText).replace(/\n/g,"<br>"),"tw-verbatim");break;case"collapsed":p+=o(g,"tw-collapsed");break;case"variable":case"tempVariable":case"macro":p+='<tw-expression type="'+g.type+'" name="'+a(g.name||g.text)+'"'+(l.options.debug?' title="'+a(g.text)+'"':"")+' js="'+a(n(g))+'"></tw-expression>';break;default:p+=g.children&&g.children.length?e(g.children):g.text}}return p}},Object.freeze(l)}),define("internaltypes/changedescriptor",["jquery","utils","renderer","datatypes/hookset"],function(e,t,n,r){
+var i=t.assertOnlyHas,o=t.impossible,a=t.transitionIn,s=n.exec,c=void 0,u={source:"",innerSource:"",enabled:!0,target:null,append:"append",newTargets:null,transition:"instant",transitionTime:null,transitionDeferred:!1,loopVars:null,styles:null,attr:null,data:null,section:null,earlyExit:!1,summary:function(){var e=this;return["source","innerSource","enabled","target","append","newTargets","transition","transitionTime"].filter(function(t){return e.hasOwnProperty(t)}).concat([this.attr.length&&"attr",this.styles.length&&"styles",Object.keys(this.loopVars).length&&"loopVars",Object.keys(this.data).length&&"data"].filter(Boolean))},create:function(e,t){var n=Object.assign(Object.create(this),{attr:[].concat(this.attr||[]),styles:[].concat(this.styles||[]),loopVars:this.loopVars||{},data:this.data||{}},e);return t&&t.run(n),n},update:function(){var e=this,t=this.section,n=this.newTargets,i=this.target,o=function(t){Array.isArray(e.styles)&&e.styles.length>0&&setTimeout(function(){return t.css(Object.assign.apply(Object,_toConsumableArray([{}].concat(e.styles))))}),e.attr&&e.attr.forEach(function(e){return t.attr(e)}),e.data&&t.data(e.data)};Array.isArray(n)&&n.length&&(i=n.map(function(e){return e.target})),[].concat(i).forEach(function(e){r.isPrototypeOf(e)?e.forEach(t,o):o(e)})},render:function(){var t=this,n=this.source,l=this.transition,f=this.transitionTime,p=this.transitionDeferred,d=this.enabled,h=this.data,y=this.section,g=this.newTargets,m=this.target,v=this.target,b=this.append;if(i(this,c),!d||void 0!==m.popAttr("hidden"))return u.create({target:m,data:Object.assign({},h,{hiddenSource:n})}).update(),e();if(Array.isArray(g)&&g.length&&(m=g),!m)return o("ChangeDescriptor.render","ChangeDescriptor has source but not a target!"),e();var w=e(),x=function(e,n){return function(r){n&&1&r[0].compareDocumentPosition(document)&&2&r[0].compareDocumentPosition(v[0])||(w=w.add(t.create({target:r,append:e,newTargets:null}).render()))}};if([].concat(m).forEach(function t(n,i,o){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:b,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0;r.isPrototypeOf(n)?n.forEach(y,x(a,s)):n.jquery&&n.length>1?Array.from(n).map(e).forEach(x(a)):n.target&&n.append&&t(n.target,i,o,n.append,n.before)}),w.length||Array.isArray(m)||r.isPrototypeOf(m))return w;if(!(b in m)){if("replace"!==b)return o("Section.render","The target doesn't have a '"+b+"' method."),e();m.empty(),b="append"}return w=e(n&&e.parseHTML(s(n),document,!0)),m[b](w.length?w:void 0),this.update(),l&&!p&&a("replace"===b?m:w,l,f),w}};return c=Object.keys(u),Object.seal(u)}),define("datatypes/changercommand",["utils","utils/operationutils","internaltypes/changedescriptor","internaltypes/twineerror"],function(e,t,n,r){var i=e.impossible,o=t.is,a={},s={changer:!0,TwineScript_TypeName:"a changer command",TwineScript_Print:function(){return"`[A ('"+this.macroName+"':) command]`"},summary:function(){var e=n.create();return this.run(e),e.summary()},create:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return Array.isArray(t)||i("ChangerCommand.create","params was not an array"),Object.assign(Object.create(this),{macroName:e,params:t,next:n,TwineScript_ObjectName:"a ("+e+":) command"})},"TwineScript_+":function(e){for(var t=this.TwineScript_Clone(),n=t;n.next;)n=n.next;return n.next=e,t},TwineScript_is:function(e){if(s.isPrototypeOf(e))return this.macroName===e.macroName&&o(this.params,e.params)&&o(this.next,e.next)},TwineScript_Clone:function(){return this.create(this.macroName,this.params,this.next)},run:function(e){var t=a[this.macroName].apply(a,[e].concat(_toConsumableArray(this.params)));if(r.containsError(t))return t;this.next&&this.next.run(e)},register:function(e,t){a[e]=t}};return Object.freeze(s)}),define("state",["utils","passages","datatypes/changercommand","internaltypes/twineerror","utils/operationutils"],function(e,t,n,r,i){function o(){if(m.hasSessionStorage){var e=m.serialise();if("string"==typeof e)try{sessionStorage.setItem("Saved Session",e)}catch(e){return}}}function a(e){h=(p[d]||f).create(e),o()}var s=e.impossible,c=i.objectName,u=["localStorage","sessionStorage"].map(function(e){try{return!!window[e]&&function(){return window[e].setItem("test","1"),window[e].removeItem("test"),!0}()}catch(e){return!1}}),l={TwineScript_ObjectName:"this story's variables",TwineScript_VariableStore:!0},f={passage:"",variables:l,create:function(e,t){var n=Object.create(f);return n.passage=e||"",n.variables=Object.assign(Object.create(this.variables),t),n}},p=[],d=-1,h=f.create(),y=void 0,g={forward:[],back:[],load:[]},m=void 0;return m=Object.assign({get passage(){return h.passage},get variables(){return h.variables},get pastLength(){return d},get futureLength(){return p.length-1-d},passageNameVisited:function(e){var n=0;if(!t.get(e))return 0;for(var r=0;r<=d;r++)n+=+(e===p[r].passage);return n},passageNameLastVisited:function(e){if(!t.get(e))return 1/0;if(e===h.passage)return 0;for(var n=d;n>0;n--)if(p[n].passage===e)return d-n+1;return 1/0},pastPassageNames:function(){for(var e=[],t=d-1;t>=0;t--)e.unshift(p[t].passage);return e},play:function(e){h||s("State.play","present is undefined!"),h.passage=e,p=p.slice(0,d+1).concat(h),d+=1,a(e),g.forward.forEach(function(t){return t(e)})},rewind:function(e){var t=1,n=!1;if(e)if("string"==typeof e){if((t=this.passageNameLastVisited(e))===1/0)return}else"number"==typeof e&&(t=e);for(;t>0&&d>0;t--)n=!0,d-=1;return n&&(a(p[d].passage),g.back.forEach(function(e){return e()})),n},fastForward:function(e){var t=1,n=!1;for("number"==typeof e&&(t=e);t>0&&p.length>0;t--)n=!0,d+=1;return n&&(a(p[d].passage),g.forward.forEach(function(e){return e(p[d].passage,"fastForward")})),n},on:function(e,t){return e in g?("function"!=typeof t||g[e].includes(t)||g[e].push(t),m):void s("State.on","invalid event name")},reset:function(){window.jasmine&&(p=[],d=-1,h=f.create(),y=void 0,g.load.forEach(function(e){return e(p)}))},hasStorage:u[0],hasSessionStorage:u[1]},function(){function e(t){return"number"==typeof t||"boolean"==typeof t||"string"==typeof t||null===t||Array.isArray(t)&&t.every(e)||t instanceof Set&&Array.from(t).every(e)||t instanceof Map&&Array.from(t.values()).every(e)||n.isPrototypeOf(t)}function i(e,t){return t instanceof Set?{"(dataset:)":Array.from(t)}:t instanceof Map?{"(datamap:)":Array.from(t)}:n.isPrototypeOf(t)?{changer:{name:t.macroName,params:t.params,next:t.next}}:t}function o(e,t){if(t&&"object"===(void 0===t?"undefined":_typeof(t))){if(Array.isArray(t["(dataset:)"]))return new Set(t["(dataset:)"]);if(Array.isArray(t["(datamap:)"]))return new Map(t["(datamap:)"]);if(t.changer&&"object"===_typeof(t.changer)){var r=t.changer,i=r.name,o=r.params,a=r.next;return n.create(i,o,a)}}return t}function s(){var t=p.slice(0,d+1),n=t.map(function(t){return Object.keys(t.variables).filter(function(n){return t.variables[n]&&!e(t.variables[n])}).map(function(e){return[e,t.variables[e]]})});if(y||(y=n.reduce(function(e,t,n){var r=_slicedToArray(t,2),i=r[0],o=r[1];return e||i&&[i,o,n+1]},void 0)),y){var o=y,a=_slicedToArray(o,3),s=a[0],u=a[1],l=a[2];return r.create("saving","The variable $"+s+" holds "+c(u)+" (which is, or contains, a complex data value) on turn "+l+"; the game can no longer be saved.")}try{return JSON.stringify(t,i)}catch(e){return!1}}function u(e){var n=void 0,r=l,i="The save data is unintelligible.";try{n=JSON.parse(e,o)}catch(e){return Error(i)}if(!Array.isArray(n))return Error(i);var s=void 0;return(s=(n=n.map(function(e){return"object"===(void 0===e?"undefined":_typeof(e))&&e.hasOwnProperty("passage")&&e.hasOwnProperty("variables")?t.hasValid(e.passage)?(e.variables=Object.assign(Object.create(r),e.variables),r=e.variables,Object.assign(Object.create(f),e)):Error("The data refers to a passage named '"+e.passage+"', but it isn't in this story."):Error(i)})).find(function(e){return e instanceof Error}))?s:(p=n,g.load.forEach(function(e){return e(p)}),d=p.length-1,a(p[d].passage),!0)}return{serialise:s,deserialise:u}}()),Object.seal(f),Object.freeze(m)}),define("datatypes/colour",["jquery"],function(e){function t(t){if(t in s)return s[t];var n=e("<p>").css("background-color",t).css("background-color");return n=n.startsWith("rgb")?n.match(/\d+/g).reduce(function(e,t,n){return e["rgb"[n]]=+t,e},{}):{r:192,g:192,b:192},s[t]=n,n}function n(e){return"string"!=typeof e?e:(e=e.replace("#",""),e=e.replace(o,"$1$1$2$2$3$3"),{r:parseInt(e.slice(0,2),16),g:parseInt(e.slice(2,4),16),b:parseInt(e.slice(4,6),16)})}function r(e){var t=e.r,n=e.g,r=e.b,i=e.a;t/=255,n/=255,r/=255;var o=Math.max(t,n,r),a=Math.min(t,n,r),s=(o+a)/2,c=o-a;if(o===a)return{h:0,s:0,l:s};var u=void 0;switch(o){case t:u=(n-r)/c+(n<r?6:0);break;case n:u=(r-t)/c+2;break;case r:u=(t-n)/c+4}return u=Math.round(60*u),{h:u,s:s>.5?c/(2-o-a):c/(o+a),l:s,a:i}}function i(e){function t(e){return e<0&&(e+=1),e>1&&(e-=1),e<1/6?c+6*(s-c)*e:e<.5?s:e<2/3?c+(s-c)*(2/3-e)*6:c}var n=e.h,r=e.s,i=e.l,o=e.a;if(0===r){var a=Math.floor(255*i);return{r:a,g:a,b:a}}n/=360;var s=i<.5?i*(1+r):i+r-i*r,c=2*i-s;return{r:Math.floor(255*t(n+1/3)),g:Math.floor(255*t(n)),b:Math.floor(255*t(n-1/3)),a:o}}var o=/^([\da-fA-F])([\da-fA-F])([\da-fA-F])$/,a=/^([\da-fA-F])([\da-fA-F])([\da-fA-F])([\da-fA-F])([\da-fA-F])([\da-fA-F])$/,s=Object.create(null),c=Object.freeze({TwineScript_TypeName:"a colour",TwineScript_ObjectName:"a colour","TwineScript_+":function(e){var t=this,n=e;return c.create({r:Math.min(Math.round(.6*(t.r+n.r)),255),g:Math.min(Math.round(.6*(t.g+n.g)),255),b:Math.min(Math.round(.6*(t.b+n.b)),255),a:(t.a+n.a)/2})},TwineScript_Print:function(){return"<tw-colour style='background-color:rgba("+[this.r,this.g,this.b,this.a].join(",")+");'></span>"},TwineScript_is:function(e){return c.isPrototypeOf(e)&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a},TwineScript_Clone:function(){return c.create(this)},toRGBAString:function(){return"rgba("+this.r+", "+this.g+", "+this.b+", "+this.a+")"},get h(){return r(this).h},get s(){return r(this).s},get l(){return r(this).l},create:function(e){return"string"==typeof e?c.isHexString(e)?this.create(n(e)):this.create(t(e)):!("h"in e&&"s"in e&&"l"in e)||"r"in e||"g"in e||"b"in e?("a"in e&&"number"==typeof e.a||(e.a=1),Object.assign(Object.create(this),e)):this.create(i(e))},isHexString:function(e){return"string"==typeof e&&"#"===e[0]&&(e.slice(1).match(o)||e.slice(1).match(a))},isCSS3Function:function(e){return"string"==typeof e&&/^(?:rgb|hsl)a?\(\s*\d+\s*,\s*\d+%?\s*,\s*\d+%?(?:,\s*\d+(?:\.\d+)?\s*)?\)$/.test(e)}});return c}),define("internaltypes/varref",["state","internaltypes/twineerror","utils","utils/operationutils","datatypes/hookset","datatypes/colour"],function(e,t,n,r,i,o){function a(e,n){var r=void 0;if(e instanceof Map&&(r=t.containsError(j(e,n))))return r;if(w(e)){var o=void 0;if("number"==typeof n){if(0===n)return t.create("property","You can't access elements at position 0 of "+x(e)+".","Only positive and negative position values exist.");n>0&&(n-=1)}else if("string"==typeof n&&(o=/(\d+)(?:st|[nr]d|th)last/i.exec(n)))n=-o[1];else if("string"==typeof n&&(o=/(\d+)(?:st|[nr]d|th)/i.exec(n)))n=o[1]-1;else if("last"===n)n=-1;else if(!["length","any","all"].includes(n)||i.isPrototypeOf(e))return t.create("property","You can only access position strings/numbers ('4th', 'last', '2ndlast', (2), etc.)"+(i.isPrototypeOf(e)?"":", 'length', 'any' and 'all'")+" of "+x(e)+", not "+x(n)+".")}else if(e instanceof Set){if(!["length","any","all"].includes(n))return t.create("property","You can only get the 'length', 'any' and 'all' of a "+x(e)+".","To check contained values, use the 'contains' operator.");"length"===n&&(n="size")}else if("number"==typeof e||"boolean"==typeof e)return t.create("property","You can't get data values from "+x(e)+".");return n}function s(e,n){return{compiledPropertyChain:n.reduce(function(r,i,o){i.computed&&(i=i.value),k.isPrototypeOf(i)&&(i=i.get()),i=Array.isArray(i)?i.map(function(t){return a(e,t)}):a(e,i);var s=void 0;return(s=t.containsError(r,i))?s:(o<n.length-1&&(e=g(e,i)),r.push(i),r)},[]),deepestObject:e}}function c(e,t){return t-0<0&&Math.abs(t)<=e.length?e.length+(t-0):t}function u(e,t){var n={any:"'any' value of ",all:"'all' values of "}[t];return{determiner:t,array:[].concat(_toConsumableArray(e)),TwineScript_ObjectName:n+x(e),TwineScript_TypeName:n+"a data structure",TwineScript_Unstorable:!0,TwineScript_Print:function(){return"`["+this.TwineScript_TypeName+"]`"}}}function l(e,t){if(void 0===e)return e;if(e instanceof Map)return e.get(t);if(w(e)&&(t=c(e,t)),"any"===t||"all"===t)return u(e,t);if(e.TwineScript_GetElement&&Number.isFinite(+t))return e.TwineScript_GetElement(t);var n=e[t];return"function"!=typeof n?n:void 0}function f(e){return e.computed?"string"==typeof e.value?"('"+e.value+"')":"("+e.value+")":"'"+e+"'"}function p(e,n){if(Array.isArray(n))return n.map(function(t){return p(e,t)});if(i.isPrototypeOf(e))return t.create("operation","I can't modify "+x(e),"You should alter hooks indirectly using macros like (replace:) or (enchant:).");if(e instanceof Set)return t.create("operation","I can't modify "+x(e),"You should use an (array:) if you need to modify the data inside this dataset.");if(o.isPrototypeOf(e))return t.create("operation","I can't modify the components of "+x(e)+".");if(e instanceof Map)return"string"==typeof n||t.create("operation",x(e)+" can only have string data names, not "+x(n)+".");if(w(e)){if(["length","any","all"].includes(n))return t.create("operation","I can't forcibly alter the '"+n+"' of "+x(e)+".");if(+n!=(0|n))return t.create("property",x(e)+" can only have position keys ('3rd', '1st', (5), etc.), not "+f(n)+".")}return e.TwineScript_Identifiers&&n in e?t.create("keyword","I can't alter the value of the '"+n+"' identifier.","You can only alter data in variables and hooks, not fixed identifiers."):"number"!=typeof e&&"boolean"!=typeof e||t.create("operation","You can't alter the data values of "+x(e)+".")}function d(e,t,n){var r=t;e instanceof Map?e.set(t,n):(w(e)&&(t=c(e,t)),e.TwineScript_Set?e.TwineScript_Set(t):e[t]=n),C.set.forEach(function(t){return t(e,r,n)})}function h(e,t){var n=t;w(e)&&(t=c(e,t)),Array.isArray(e)&&O.exec(t)?e.splice(t,1):e instanceof Map||e instanceof Set?e.delete(t):delete e[t],C.delete.forEach(function(t){return t(e,n)})}function y(e){function t(){return e}return{get:t,set:t,delete:t,varref:!0}}function g(n,r,o){if(Array.isArray(r))return i.isPrototypeOf(n)?n.TwineScript_GetElement(r):r.map(function(e){return g(n,e,e)})["string"==typeof n?"join":"valueOf"]("");"string"==typeof n&&(n=[].concat(_toConsumableArray(n)));var a=l(n,r);return void 0===a?n===e.variables?A:n.TwineScript_VariableStore?t.create("property","There isn't a temp variable named _"+o+" in this place.","Temp variables only exist inside the same passage and hook in which they're (set:)."):t.create("property","I can't find a "+f(o)+" data name in "+x(n)):a}function m(e,n){var r=this,i=this.compiledPropertyChain.reduce(function(e,t){var n=void 0;return n=0===e.length?r.object:g.apply(void 0,_toConsumableArray(e[e.length-1])),e.push([n,t])&&e},[]).reduceRight(e,n);return t.containsError(i)?i:void 0}var v=n.impossible,b=r.isObject,w=r.isSequential,x=r.objectName,T=r.typeName,S=r.clone,O=r.numericIndex,j=r.isValidDatamapName,k=void 0,A=0,C={set:[],delete:[]};return k=Object.freeze({varref:!0,get:function(){return g(this.deepestObject,this.compiledPropertyChain.slice(-1)[0],this.propertyChain.slice(-1)[0])},set:function(e){return!this.object||this.object.TwineScript_VariableStore||this.object.TwineScript_Identifiers?m.call(this,function(e,n,r){var i=_slicedToArray(n,2),o=i[0],a=i[1],s=void 0;if(s=t.containsError(e,o,a)||t.containsError(p(o,a)))return s;if(e&&e.TwineScript_Unstorable)return t.create("operation",T(e)+" can't be stored.");if(r>0&&(o=S(o)),"string"==typeof o){if("string"!=typeof e||e.length!==(Array.isArray(a)?a.length:1))return t.create("datatype","I can't put this non-string value, "+x(e)+", in a string.");o=[].concat(_toConsumableArray(o));var c=[].concat(_toConsumableArray(e));[].concat(a).forEach(function(e){0+e<0&&(e=o.length+(0+e)),o=[].concat(_toConsumableArray(o.slice(0,e)),[c.shift()],_toConsumableArray(o.slice(e+1)))}),o=o.join("")}else b(o)&&(Array.isArray(a)&&w(e)?("string"==typeof e&&(e=[].concat(_toConsumableArray(e))),a.map(function(t,n){return[t,e[n]]}).forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=t[1];return d(o,n,r)})):d(o,a,e));return o},e):t.create("macrocall","I can't (set:) "+x(this)+", if the "+(x(this.object).match(/ (.+$)/)||["","value"])[1]+" isn't stored in a variable.","Modifying data structures that aren't in variables won't change the game state at all.")},delete:function(){return m.call(this,function(e,n,r){var i=_slicedToArray(n,2),o=i[0],a=i[1],s=void 0;if(s=t.containsError(e,o,a)||t.containsError(p(o,a)))return s;if(r>0&&(o=S(o)),null===e){var u="string"==typeof o;u&&(o=[].concat(_toConsumableArray(o))),Array.isArray(a)?(w(o)&&(a=[].concat(_toConsumableArray(new Set(a))),a.sort(function(e,t){return c(o,t)-c(o,e)})),a.forEach(function(e){return h(o,e)})):h(o,a),u&&(o=o.join(""))}else d(o,a,e);return o},null)},create:function(e,n){var r=void 0;if(r=t.containsError(e))return y(r);n=[].concat(n),k.isPrototypeOf(e)&&(n=e.propertyChain.concat(n),e=e.object);var i=s(e,n),o=i.compiledPropertyChain,a=i.deepestObject;return(r=t.containsError(o,a))?y(r):Object.assign(Object.create(k),{object:e,propertyChain:n,compiledPropertyChain:o,deepestObject:a})},get TwineScript_ObjectName(){var t=this,n=function(n,r){return r||t.object!==e.variables&&!t.object.TwineScript_VariableStore?f(n):n};return(this.object===e.variables?"$":this.object.TwineScript_VariableStore?"_":x(this.object)+"'s ")+(1===this.propertyChain.length?n(this.propertyChain[0]):this.propertyChain.reduce(function(e,t,r){return e+"'s "+n(t,r)}))+(this.object.TwineScript_VariableStoreName?" in "+this.object.TwineScript_VariableStoreName:"")},on:function(e,t){return e in C?("function"!=typeof t||C[e].includes(t)||C[e].push(t),k):void v("VarRef.on","invalid event name")}})}),define("utils/naturalsort",[],function(){return function(e){return function t(n,r){var i,o,a,s,c=/(^-?[0-9]+(\.?[0-9]*)[df]?e?[0-9]?$|^0x[0-9a-f]+$|[0-9]+)/gi,u=/(^[ ]*|[ ]*$)/g,l=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,f=/^0x[0-9a-f]+$/i,p=/^0/,d=function(e){return t.insensitive&&(""+e).toLowerCase()||""+e},h=d(n).replace(u,"")||"",y=d(r).replace(u,"")||"",g=h.replace(c,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),m=y.replace(c,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),v=parseInt(h.match(f))||1!==g.length&&h.match(l)&&Date.parse(h),b=parseInt(y.match(f))||v&&y.match(l)&&Date.parse(y)||null;if(e&&window.Intl&&window.Intl.Collator&&(a=window.Intl.Collator(e)),b){if(v<b)return-1;if(v>b)return 1}for(var w=0,x=Math.max(g.length,m.length);w<x;w++){if(i=!(g[w]||"").match(p)&&parseFloat(g[w])||g[w]||0,o=!(m[w]||"").match(p)&&parseFloat(m[w])||m[w]||0,isNaN(i)!==isNaN(o))return isNaN(i)?1:-1;if((void 0===i?"undefined":_typeof(i))!==(void 0===o?"undefined":_typeof(o)))i+="",o+="";else if("string"==typeof i&&a&&0!==(s=a.compare(i,o)))return s;if(i<o)return-1;if(i>o)return 1}return 0}}}),define("internaltypes/varscope",[],function(){return{TwineScript_ObjectName:"the temporary variables",TwineScript_VariableStore:!0}}),define("datatypes/lambda",["utils","utils/operationutils","internaltypes/varscope","internaltypes/twineerror"],function(e,t,n,r){var i=e.toJSLiteral,o=e.insensitiveName,a=(e.plural,t.typeName,t.objectName,t.singleTypeCheck,Object.freeze({lambda:!0,TwineScript_TypeName:"a lambda",TwineScript_ObjectName:function(){return'a "'+("making"in this?"making ... ":"")+("with"in this?"with ... ":"")+("where"in this?"where ... ":"")+("when"in this?"when ... ":"")+("via"in this?"via ... ":"")+'" lambda'},TwineScript_Print:function(){return"`[A lambda]`"},TwineScript_is:function(e){return e===this},TypeSignature:function(e){return{pattern:"lambda",innerType:a,clauses:e,typeName:'a "'+e.split().concat("").join(" ...")+'" lambda'}},create:function(e,t,i){var s=void 0;if(r.containsError(e))return e;if(a.isPrototypeOf(e)){if("when"===t||"when"in e)return r.create("syntax","A 'when' lambda cannot have any other clauses, such as '"+t+"'.");if(t in e&&("where"!==t||"true"!==e[t]))return r.create("syntax","This lambda has two '"+t+"' clauses.");s=e}else{if("when"===t&&void 0!==e)return r.create("syntax","A 'when' lambda shouldn't begin with a temporary variable (just use 'when' followed by the condition).");if(void 0!==e&&(!e||!e.varref||!n.isPrototypeOf(e.object)||e.propertyChain.length>1))return r.create("syntax","This lambda needs to start with a single temporary variable.");s=Object.create(this),s.loop=e?e.propertyChain[0]:""}s[t]=i;var c=[s.making,s.with,s.loop].filter(function(e,t,n){return e&&n.indexOf(o(e))!==t});return c.length?r.create("syntax","This lambda has two variables named '"+c[0]+"'.","Lambdas should have all-unique parameter names."):s},apply:function(e,t){var o=t.loop,a=t.with,s=t.making,c=t.fail,u=t.pass,l=t.ignoreVia,f=t.tempVariables;f=f||Object.create(e.stack[0]||n),[[this.loop,o],[this.with,a],[this.making,s]].forEach(function(e){var t=_slicedToArray(e,2),n=t[0],r=t[1];return n&&(f[n]=r)}),e.stack.unshift(Object.assign(Object.create(null),{tempVariables:f})),!o||this.with||this.making||this.when?e.eval("Operations").initialiseIt(r.create("operation","I can't use 'it', or an implied 'it', in "+this.TwineScript_ObjectName())):e.eval("Operations").initialiseIt(o);var p=!l&&this.via,d=e.eval("where"in this||"when"in this?"Operations.where("+(this.where||this.when)+","+(p||i(u))+","+i(c)+")":p||i(u));return e.stack.shift(),d},filter:function(e,t){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=void 0,a=t.reduce(function(t,a){if(o=r.containsError(t))return o;var s=n.apply(e,{loop:a,pass:!0,fail:!1,ignoreVia:!0,tempVariables:i});return(o=r.containsError(s))?o:t.concat(s?[a]:[])},[]);return(o=r.containsError(a))?o:a}}));return a}),define("macros",["jquery","utils/naturalsort","utils","utils/operationutils","datatypes/changercommand","datatypes/lambda","datatypes/hookset","internaltypes/changedescriptor","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,c){function u(e){return function(n){n=n.reduce(function(e,n){if(n&&!0===n.spreader){var r=n.value;if(Array.isArray(r)||"string"==typeof r)for(var i=0;i<r.length;i++)e.push(r[i]);else r instanceof Set?e.push.apply(e,_toConsumableArray(Array.from(r).sort(t("en")))):e.push(c.create("operation","I can't spread out "+m(r)+", because it is not a string, dataset, or array."))}else e.push(n);return e},[]);var r=c.containsError(n);return r||e.apply(void 0,_toConsumableArray(n))}}function l(e,t,n){n=[].concat(n||[]),e="("+(Array.isArray(e)&&e.length>1?e[0]:e)+":)";var r=void 0;return r=n.length>0?"The "+e+" macro must only be given "+n.map(v).reduce(function(e,t,n,r){return e+(0===n?"":n<r.length-1?", ":", and ")+t},"")+(n.length>1?", in that order":"."):"The macro must not be given any data - just write "+e+".",function(i){for(var a=arguments.length,s=Array(a>1?a-1:0),u=1;u<a;u++)s[u-1]=arguments[u];for(var l=void 0,f=0,p=Math.max(s.length,n.length);f<p;f+=1){var g=function(t,i){var a=n[t],u=s[t];return t>=n.length&&!l?{v:c.create("datatype",s.length-n.length+" too many values were given to this "+e+" macro.",r)}:(a||(a=l),!a.innerType||"rest"!==a.pattern&&"zero or more"!==a.pattern||(l=a.innerType,"rest"===a.pattern&&(a=a.innerType)),b(u,a)?void 0:void 0===u?{v:c.create("datatype","The "+e+" macro needs "+h(n.length-t,"more value")+".",r)}:u&&u.TwineScript_Unstorable&&(a===w.TypeSignature.Any||a.innerType&&a.innerType===w.TypeSignature.Any)?{v:c.create("datatype",e+"'s "+d(t+1)+" value, "+m(u)+", is not valid data for this macro.",r)}:u&&o.isPrototypeOf(u)&&"lambda"===a.pattern?{v:c.create("datatype",e+"'s "+d(t+1)+" value (a lambda) should have "+y(["where","making","via","with"].filter(function(e){return a.clauses.includes(e)}).map(function(e){return"a '"+e+"' clause"}))+", not "+y(["where","making","via","with"].filter(function(e){return e in u}).map(function(e){return"a '"+e+"' clause"}))+".")}:{v:c.create("datatype",e+"'s "+d(t+1)+" value is "+m(u)+", but should be "+v(a)+".",a.message||r)})}(f);if("object"===(void 0===g?"undefined":_typeof(g)))return g.v}return t.apply(void 0,[i].concat(s))}}function f(e,t){Array.isArray(e)?e.forEach(function(e){return g(x,p(e),t)}):g(x,p(e),t)}var p=n.insensitiveName,d=n.nth,h=n.plural,y=n.andList,g=n.lockProperty,m=r.objectName,v=r.typeName,b=r.singleTypeCheck,w=void 0,x={},T=function(e,t,n,r){return function(){for(var i=arguments.length,o=Array(i),a=0;a<i;a++)o[a]=arguments[a];var c=t.apply(void 0,_toConsumableArray(o.slice(1)));if(c)return c;var u=void 0;r&&(u=s.create());var l=Object.assign({TwineScript_ObjectName:"a ("+e+":) command",TwineScript_TypeName:"a ("+e+":) command",TwineScript_Print:function(){return"`[A ("+e+":) command]`"}},r?{TwineScript_Attach:function(e){return e.run(u),l},TwineScript_Run:function(){return n.apply(void 0,[u].concat(o))}}:{TwineScript_Run:function(){return n.apply(void 0,o)}});return l}};return w={has:function(e){return e=p(e),x.hasOwnProperty(e)},get:function(e){return e=p(e),x.hasOwnProperty(e)&&x[e]},add:function e(t,n,r){return f(t,u(l(t,n,r))),e},addChanger:function e(t,n,r,o){return f(t,u(l(t,n,o))),i.register(Array.isArray(t)?t[0]:t,r),e},addCommand:function e(t,n,r,i){var o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=[].concat(t)[0];return f(t,u(l(t,T(a,n,r,o),i))),e},TypeSignature:{optional:function(e){return{pattern:"optional",innerType:e}},zeroOrMore:function(e){return{pattern:"zero or more",innerType:e}},either:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return{pattern:"either",innerType:t}},rest:function(e){return{pattern:"rest",innerType:e}},wrapped:function(e,t){return{pattern:"wrapped",innerType:e,message:t}},Any:{TwineScript_TypeName:"anything"}},run:function(e,t){return c.containsError(e)?e:w.has(e)?w.get(e)(t):c.create("macrocall","I can't run the macro '"+e+"' because it doesn't exist.","Did you mean to run a macro? If you have a word written like (this:), it is regarded as a macro name.")}},Object.freeze(w)}),define("datatypes/datatype",["datatypes/changercommand","datatypes/colour"],function(e,t){var n=Object.freeze({datatype:!0,TwineScript_TypeName:"a datatype",TwineScript_Print:function(){return"`["+this.TwineScript_ObjectName+"]`"},TwineScript_is:function(e){return n.isPrototypeOf(e)&&e.name===this.name},TwineScript_Clone:function(){return n.create(this.name)},TwineScript_IsTypeOf:function(e){return this.name===(Array.isArray(e)?"array":e instanceof Map?"datamap":e instanceof Set?"dataset":t.isPrototypeOf(e)?"colour":"string"==typeof e?"string":"number"==typeof e?"number":"boolean"==typeof e?"boolean":"unknown")},create:function(e){return e="dm"===e?"datamap":"ds"===e?"dataset":"num"===e?"number":"str"===e?"string":"color"===e?"colour":e,Object.assign(Object.create(this),{name:e,TwineScript_ObjectName:"the "+e+" datatype"})}});return n}),define("datatypes/varbind",["utils","utils/operationutils","internaltypes/varref","internaltypes/twineerror"],function(e,t,n,r){var i=t.objectName;return Object.freeze({TwineScript_TypeName:"a bound variable",TwineScript_ObjectName:"a bound variable",TwineScript_Unstorable:!0,set:function(e){var t=this.varRef.set(e),n=void 0;if(n=r.containsError(t))return n},create:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"one way";return n.isPrototypeOf(e)||e.varref?Object.assign(Object.create(this),{varRef:e,bind:t}):r.create("operation","I can only 'bind' a variable, not "+i(e)+".")}})}),define("datatypes/assignmentrequest",["utils"],function(e){var t=e.assertMustHave;return Object.freeze({assignmentRequest:!0,TwineScript_TypeName:"a 'to' or 'into' expression",TwineScript_ObjectName:"a 'to' or 'into' expression",TwineScript_Unstorable:!0,create:function(e,n,r){return t(e,["varref"]),Object.assign(Object.create(this),{dest:e,src:n,operator:r})}})}),define("twinescript/operations",["state","datatypes/assignmentrequest","utils/operationutils","internaltypes/twineerror"],function(e,t,n,r){function i(e,t,n,i){return n=n||"do this to",function(o,a){1===t.length&&(a=o);var s=void 0;return(s=r.containsError(o,a))?s:(void 0===o?"undefined":_typeof(o))!==e||(void 0===a?"undefined":_typeof(a))!==e?r.create("operation","I can only "+n+" "+e+"s, not "+y((void 0===o?"undefined":_typeof(o))!==e?o:a)+".",i):t(o,a)}}function o(e){return function(t,n){var i=void 0;return(i=r.containsError(t,n))?i:t&&t.varref?r.create("operation","I can't give an expression a new value."):(void 0===t?"undefined":_typeof(t))!==(void 0===n?"undefined":_typeof(n))||s(t)&&"TwineScript_TypeName"in t&&s(n)&&"TwineScript_TypeName"in n&&t.TwineScript_TypeName!==n.TwineScript_TypeName||c(t)!==c(n)?r.create("operation",y(t)+" isn't the same type of data as "+y(n)):e(t,n)}}function a(e){return function t(n,i){var o=void 0;if(o=r.containsError(n,i))return o;if(m=n,n.determiner){var a="all"===n.determiner;return n.array.reduce(function(e,n){var o=void 0,s=t(n,i);return(o=r.containsError(e,s))?o:a?e&&s:e||s},a)}if(i.determiner){var s="all"===i.determiner;return i.array.reduce(function(e,i){var o=void 0,a=t(n,i);return(o=r.containsError(e,a))?o:s?e&&a:e||a},s)}return e(n,i)}}var s=n.isObject,c=n.collectionType,u=n.is,l=n.isA,f=n.clone,p=n.unique,d=n.contains,h=n.matches,y=(n.typeName,n.objectName),g=void 0,m=0,v="If one of these values is a number, you may want to write a check that it 'is not 0'. Also, if one is a string, you may want to write a check that it 'is not \"\" '.";return g={create:function(e){var t=Object.create(this);return t.Identifiers={TwineScript_Identifiers:!0,get it(){return m},get time(){return Date.now()-e.timestamp}},t},elidedComparisonOperator:function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return r.reduce(function(n,r){return"boolean"==typeof r?r:g[e](n,g[t](m,r))},"and"===e)},and:i("boolean",o(function(e,t){return e&&t}),"use 'and' to join",v),or:i("boolean",o(function(e,t){return e||t}),"use 'or' to join",v),not:i("boolean",function(e){return!e},"use 'not' to invert",v),"+":o(function(e,t){if(Array.isArray(e))return[].concat(_toConsumableArray(e),_toConsumableArray(t));var n=void 0;return e instanceof Map?(n=new Map(e),t.forEach(function(e,t){return n.set(t,e)}),n):e instanceof Set?new Set([].concat(_toConsumableArray(e),_toConsumableArray(t)).filter(p).map(f)):"function"==typeof e["TwineScript_+"]?e["TwineScript_+"](t):"string|number|boolean".includes(void 0===e?"undefined":_typeof(e))?e+t:r.create("operation","I can't use + on "+y(e)+".")}),"-":o(function(e,t){if(Array.isArray(e))return e.filter(function(e){return!t.some(function(t){return u(e,t)})});if(e instanceof Set){var n=[].concat(_toConsumableArray(t));return new Set([].concat(_toConsumableArray(e)).filter(function(e){return!n.some(function(t){return u(e,t)})}))}return"string"==typeof e?e.split(t).join(""):"number"==typeof e?e-t:r.create("operation","I can't use - on "+y(e)+".")}),"*":i("number",o(function(e,t){return e*t}),"multiply"),"/":i("number",o(function(e,t){return 0===t?r.create("operation","I can't divide "+y(e)+" by zero."):e/t}),"divide"),"%":i("number",o(function(e,t){return 0===t?r.create("operation","I can't modulo "+y(e)+" by zero."):e%t}),"modulus"),"<":a(i("number",o(function(e,t){return e<t}),"do < to")),">":a(i("number",o(function(e,t){return e>t}),"do > to")),"<=":a(i("number",o(function(e,t){return e<=t}),"do <= to")),">=":a(i("number",o(function(e,t){return e>=t}),"do >= to")),is:a(u),isNot:a(function(e,t){return!g.is(e,t)}),contains:a(d),isIn:a(function(e,t){
+return d(t,e)}),isA:a(l),isNotA:a(function(e,t){return!l(e,t)}),typifies:a(function(e,t){return l(t,e)}),untypifies:a(function(e,t){return!l(t,e)}),matches:a(h),where:function(e,t,n){var i=void 0;return(i=r.containsError(e))?i:"boolean"!=typeof e?r.create("operation","This lambda's 'where' clause must evaluate to true or false, not "+y(e)+"."):e?t:n},makeSpreader:function(e){return{value:e,spreader:!0}},makeAssignmentRequest:function(e,n,i){var o=r.containsError(e,n);return o||(s(e)&&"varref"in e?t.create(e,n,i):r.create("operation","I can't store a new value inside "+y(e)+"."))},setIt:function(e){return r.containsError(e)?e:e.varref?(m=e.get(),e):r.create("operation","I can't put a new value into "+y(e)+".")},initialiseIt:function(e){m=e}},Object.freeze(g)}),define("twinescript/environ",["macros","state","utils","datatypes/colour","datatypes/hookset","datatypes/lambda","datatypes/datatype","datatypes/varbind","internaltypes/varref","internaltypes/twineerror","twinescript/operations"],function(Macros,State,Utils,Colour,HookSet,Lambda,Datatype,VarBind,VarRef,TwineError,OperationsProto){return function(section){"object"===(void 0===section?"undefined":_typeof(section))&&section||Utils.impossible("TwineScript.environ","no Section argument was given!");var Operations=OperationsProto.create(section);return section.eval=function(){try{for(var _len7=arguments.length,args=Array(_len7),_key7=0;_key7<_len7;_key7++)args[_key7]=arguments[_key7];return eval(args.join(""))}catch(e){return e}},section}}),define("internaltypes/twinenotifier",["jquery","utils"],function(e,t){var n=t.impossible,r={create:function(e){return e||n("TwineNotifier.create","called with only 1 string."),Object.assign(Object.create(r),{message:e})},render:function(){return e("<tw-notifier>").attr("message",this.message)}};return r}),define("section",["jquery","utils","utils/selectors","renderer","twinescript/environ","twinescript/operations","state","utils/operationutils","datatypes/changercommand","datatypes/hookset","datatypes/colour","internaltypes/changedescriptor","internaltypes/varscope","internaltypes/twineerror","internaltypes/twinenotifier"],function(e,t,n,r,i,o,a,s,c,u,l,f,p,d,h){function y(e,n,r){if(n&&"object"===(void 0===n?"undefined":_typeof(n))&&c.isPrototypeOf(n)){if(!this.renderInto(r.popAttr("source"),r,n)){var i=t.insensitiveName(e.attr("name"));if(["if","elseif","unless","else"].includes(i)&&(e.addClass("false"),"elseif"!==i&&(this.stack[0].lastHookShown=!1)),r.data("live")){var o=r.data("live"),a=o.delay,s=o.event;x.call(this,e,r,a,s)}return}}else{if(!1===n)return r.attr("source")&&r.data("hiddenSource",r.popAttr("source")),e.addClass("false"),void(this.stack[0].lastHookShown=!1);!0!==n&&e.replaceWith(d.create("datatype",S(n)+" cannot be attached to this hook.","Only Booleans, changer commands, and the (live:) macro can be attached to hooks.").render(e.attr("title")))}this.stack[0].lastHookShown=!0}function g(t){var n=t instanceof e?t[0]:t,r=n.nextSibling;if(r&&(r instanceof Text&&!r.textContent.trim()||"br"===(r.tagName||"").toLowerCase())){var i=g(r),o=i.whitespace,a=i.nextElem;return{whitespace:e(r).add(o),nextElem:a}}return{whitespace:e(),nextElem:e(r)}}function m(r){var i=this.eval(r.popAttr("js")||""),a=void 0,s=void 0,u=e();for(s=r;c.isPrototypeOf(i);){var p=g(s);if(a=p.whitespace,s=p.nextElem,s[0]instanceof Text&&"+"===s[0].textContent.trim()){var m=void 0,v=s,b=g(v);if(m=b.whitespace,s=b.nextElem,s.is(n.expression)){var w=this.eval(s.popAttr("js"));if(d.containsError(w)){i=w;break}var x=o["+"](i,w);e(a).add(v).add(m).remove(),i=d.containsError(x)?d.create("operation","I can't combine "+S(i)+" with "+S(w)+".","function"==typeof w.TwineScript_Run?"If you want to attach this changer to "+S(w)+", remove the + between them.":"Changers can only be added to other changers."):x;continue}}if(s.is(n.expression)){var O=this.eval(s.popAttr("js"));if(d.containsError(O)){i=O;break}if(O&&"object"===(void 0===O?"undefined":_typeof(O))&&"function"==typeof O.TwineScript_Attach){i=O.TwineScript_Attach(i);break}return c.isPrototypeOf(O)?void r.replaceWith(d.create("operation","Changers like ("+i.macroName+":) need to be combined using + between them.","Place the + between the changer macros, or the variables holding them. The + is absent only between a changer and its attached hook or command.").render(r.attr("title"))):void r.replaceWith(d.create("operation",S(O)+" can't have changers like ("+i.macroName+":) attached.","Changers placed just before hooks, links and commands will attempt to attach, but in this case it didn't work.").render(r.attr("title")))}if(s.is(n.hook)){a.remove(),u=s;break}i.macroName||t.impossible("Section.runExpression","changer has no macroName");var j=r.attr("title")||"("+i.macroName+": ...)";return void r.replaceWith(d.create("syntax","The ("+i.macroName+":) changer should be stored in a variable or attached to a hook.","Macros like this should appear to the left of a hook: "+j+"[Some text]").render(r.attr("title")))}u=u.length?u:g(r).nextElem.filter(n.hook);var k=void 0;if(k=d.containsError(i))k instanceof Error&&(k=d.fromError(k)),r.replaceWith(k.render(r.attr("title"),r));else if(h.isPrototypeOf(i))r.append(i.render());else if(i&&"function"==typeof i.TwineScript_Run)if(i=i.TwineScript_Run(),d.containsError(i))r.replaceWith(i.render(r.attr("title")));else if(f.isPrototypeOf(i)){if(i.data&&i.data.live)return void r.replaceWith(d.create("unimplemented","I currently can't attach (live:) or (event:) macros to commands - only hooks.").render(r.attr("title")));if(i.section=this,i.target=s,this.renderInto("",s,i),i.earlyExit)return"earlyexit"}else i&&t.impossible("Section.runExpression","TwineScript_Run() returned a non-ChangeDescriptor "+(void 0===i?"undefined":_typeof(i))+': "'+i+'"');else!u.length&&("string"==typeof i||"number"==typeof i||i instanceof Map||i instanceof Set||Array.isArray(i)||l.isPrototypeOf(i))||i&&"function"==typeof i.TwineScript_Print&&!c.isPrototypeOf(i)?(i=T(i),"string"!=typeof i&&t.impossible("printBuiltinValue() produced a non-string "+(void 0===i?"undefined":_typeof(i))),d.containsError(i)?(i instanceof Error&&(i=d.fromError(i)),r.replaceWith(i.render(r.attr("title")))):this.renderInto(i,r)):u.length?y.call(this,r,i,u):c.isPrototypeOf(i)||"boolean"==typeof i||t.impossible("Section.runExpression","The expression evaluated to an unknown value: "+i.toSource())}function v(e){var t=e.first()[0],n=e.parent();if(!n.length)return null;var r=n.textNodes().filter(function(e){var n=e.compareDocumentPosition(t);return 4&n&&!(8&n)});return(r=r[r.length-1])||v(n)}function b(e){var t=e.last()[0],n=e.parent();if(!n.length)return null;var r=n.textNodes().filter(function(e){var n=e.compareDocumentPosition(t);return 2&n&&!(8&n)})[0];return r||b(n)}function w(t){function n(t){return 0===e(this||t).parentsUntil("tw-collapsed").filter("tw-verbatim, tw-expression, [collapsing=false]").length}var r=v(t);e(r).parents("tw-collapsed").length||(r=null);var i=b(t);e(i).parents("tw-collapsed").length||(i=null),t.findAndFilter("br:not([data-raw])").filter(n).replaceWith(document.createTextNode(" "));var o=t.textNodes(),a=0;o.reduce(function(e,t){return n(t)?(t.textContent=t.textContent.replace(/\s+/g," ")," "!==t.textContent[0]||e&&e.textContent&&!(e.textContent.search(/\s$/)>-1)||(t.textContent=t.textContent.slice(1)),t):document.createTextNode("A")},r),[].concat(_toConsumableArray(o)).reverse().every(function(e){return!!n(e)&&(e.textContent.match(/^\s*$/)?(a+=e.textContent.length,e.textContent="",!0):(e.textContent=e.textContent.replace(/\s+$/,function(e){return a+=e.length,""}),!1))}),a>0&&i&&(o[o.length-1].textContent+=" "),t[0]&&j()&&t[0].normalize()}function x(e,r){var i=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:20,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:void 0;a&&t.assertMustHave(a,["when"]);var s=r.data("hiddenSource")||"",c=_slicedToArray(this.stack,1),u=c[0].tempVariables,l=function t(){if(i.inDOM()){var c=a&&a.filter(i,[!0],u);if(d.containsError(c))return void c.render(e.attr("title")).replaceAll(e);if(a&&!c[0])return void setTimeout(t,o);i.renderInto(s,r,{append:"replace"}),c||r.find(n.expression+"[name='stop']").length||i.inDOM()&&setTimeout(t,o)}};setTimeout(l,o)}var T=s.printBuiltinValue,S=s.objectName,O=void 0,j=function(){var t=void 0;return function(){if(void 0!==t)return t;var n=e("<p>");return n[0].normalize?(n.append(document.createTextNode("0-"),document.createTextNode("2"),document.createTextNode(""))[0].normalize(),t=1===n.contents().length):t=!1}}();return O={create:function(n){n instanceof e&&1===n.length||t.impossible("Section.create","called with no DOM element");var r=Object.assign(Object.create(this),{timestamp:Date.now(),dom:n||t.storyElement,stack:[],enchantments:[]});return r=i(r)},inDOM:function(){return e(t.storyElement).find(this.dom).length>0},evaluateTwineMarkup:function(t){var n=e("<p>");this.renderInto(t,n);var r=void 0;return(r=n.find("tw-error")).length>0?r:n.text()},renderInto:function(t,r,i){var o=this,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=f.create({target:r,source:t,section:this});if(i)if(c.isPrototypeOf(i)){var u=i.run(s);if(d.containsError(u))return u.render(r.attr("title")).replaceAll(r),!1}else Object.assign(s,i);if(r=s.target,this.stack.length>=50)return d.create("infinite","Printing this expression may have trapped me in an infinite loop.").render(r.attr("title")).replaceAll(r),!1;var l=function(t,i){var a=t.render();o.stack.unshift(i);var s=o;a.findAndFilter(n.hook+","+n.expression).each(function(){var t=e(this);switch(t.tag()){case n.hook:if(t.attr("hidden")&&(t.removeAttr("hidden"),t.data("hiddenSource",t.popAttr("source"))),t.attr("source")&&s.renderInto(t.popAttr("source"),t),t.find("[earlyexit]").length)return!1;break;case n.expression:if(t.attr("js")){if("earlyexit"===m.call(s,t))return a.attr("earlyexit",!0),!1;return}}}),a.length&&r instanceof e&&r.is(n.hook)&&r.parents("tw-collapsed").length>0&&w(a),a.findAndFilter(n.collapsed).each(function(){w(e(this))}),o.stack.shift()};if(!a){a=Object.create(this.stack.length?this.stack[0].tempVariables:p);var h=r&&r.tag();a.TwineScript_VariableStoreName=h===n.hook?r.attr("name")?"?"+r.attr("name"):"an unnamed hook":h===n.expression?"a "+r.attr("type")+" expression":h===n.passage?"this passage":"an unknown scope"}return Object.keys(s.loopVars).length?function(){for(var e=Object.assign({},s.loopVars),t=Math.min.apply(Math,_toConsumableArray(Object.keys(e).map(function(t){return e[t].length})));t>0;t-=1)l(s,{tempVariables:Object.keys(e).reduce(function(t,n){return t[n]=e[n].shift(),t},Object.create(a))})}():l(s,{tempVariables:a}),0===this.stack.length&&this.updateEnchantments(),s.enabled},updateEnchantments:function(){this.enchantments.forEach(function(e){e.disenchant(),e.enchantScope()})}},Object.preventExtensions(O)}),define("engine",["jquery","utils","utils/selectors","state","section","passages"],function(e,t,n,r,i,o){function a(){var t=e("<tw-passage><tw-sidebar>"),i=t.children(n.sidebar);h.permalink&&r.save&&i.append('<tw-icon tabindex=0 class="permalink" title="Permanent link to this passage"><a href="#'+r.save()+'">&sect;');var o=e('<tw-icon tabindex=0 class="undo" title="Undo">&#8630;</tw-icon>').click(function(){return d.goBack()}),a=e('<tw-icon tabindex=0 class="redo" title="Redo">&#8631;</tw-icon>').click(function(){return d.goForward()});return r.pastLength<=0&&o.css("visibility","hidden"),r.futureLength<=0&&a.css("visibility","hidden"),i.append(o).append(a),t}function s(e,t){return"<tw-include type="+e+" title='"+u(t.get("name"))+"'>"+t.get("source")+"</tw-include>"}function c(c){var u=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t.assertOnlyHas(u,["stretch","transitionIn","transitionOut","transitionTime"]);var d=o.get(c),y=t.storyElement,g=y.parent(),m=u.stretch,v=u.transitionOut,b=u.transitionIn,w=u.transitionTime;if(v=v||"instant",b=b||"dissolve",g.is(n.enchantment)){var x=g.data("enchantedProperties");x&&y.css(x.reduce(function(e,t){return e[t]="",e},{})),g=y.unwrap().parent()}o.hasValid(c)||l("Engine.showPassage","There's no passage with the name \""+c+'"!'),y.detach();var T=t.$(y.children(f));!m&&v&&(p(T,v,w),T.css("position","absolute"));var S=(d.get("tags")||[]).join(" "),O=a().appendTo(y).attr({tags:S});y.attr({tags:S});var j=i.create(O),k=d.get("source");k=o.getTagged("header").map(s.bind(0,"header")).join("")+(h.debug?o.getTagged("debug-header").map(s.bind(0,"debug-header")).join(""):"")+k+o.getTagged("footer").map(s.bind(0,"footer")).join("")+(h.debug?o.getTagged("debug-footer").map(s.bind(0,"debug-footer")).join(""):""),r.pastLength<=0&&(h.debug&&(k=o.getTagged("debug-startup").map(s.bind(0,"debug-startup")).join("")+k),k=o.getTagged("startup").map(s.bind(0,"startup")).join("")+k),j.renderInto(k,O,{transition:b,transitionTime:w}),g.append(y.parents().length?y.parents().last():y),scroll(0,m?O.offset().top-.05*e(window).height():y.offset().top)}var u=t.escape,l=t.impossible,f=t.passageSelector,p=t.transitionOut,d=void 0,h=Object.create(null);return d={goBack:function(e){r.rewind()&&c(r.passage,e)},goForward:function(e){r.fastForward()&&c(r.passage,e)},goToPassage:function(e,t){r.play(e),c(e,t)},showPassage:c,options:h},Object.freeze(d)}),define("debugmode",["jquery","utils","state","internaltypes/varref","utils/operationutils","engine"],function(e,t,n,r,i,o){var a=i.objectName;i.typeName;return function(){function t(t,n,r){var i=l.children('[data-name="'+t+'"]'),o=a(n);i.length||(i=e('<div class="variable-row" data-name="'+t+'" data-value="'+o+'"></div>').appendTo(l)),i.empty().append("<span class='variable-name "+(r?"temporary":"")+"'>"+t+(r?"<span class='temporary-variable-scope'>"+r+"</span>":"")+"</span><span class='variable-value'>"+a(n)+"</span>");var s=l.children();u.text(s.length+" Variable"+(1!==s.length?"s":""))}function i(){var r=[];l.children().each(function(i,o){o=e(o);var s=o.attr("data-name"),c=o.attr("data-value");s.startsWith("TwineScript")||(s in n.variables?(r.push(s),a(n.variables[s])!==c&&t(s,n.variables[s])):o.remove())});for(var i in n.variables)i.startsWith("TwineScript")||r.includes(i)||t(i,n.variables[i])}var s=e("<tw-debugger><div class='variables'></div>Turns: <select disabled></select><button class='show-invisibles'>Debug View</button><button class='show-variables enabled'>0 Variables</button></tw-debugger>"),c=s.find(".show-invisibles");c.click(function(){e(document.documentElement).toggleClass("debug-mode"),c.toggleClass("enabled")});var u=s.find(".show-variables"),l=s.find(".variables");u.click(function(){l[u.is(".enabled")?"attr":"removeAttr"]("hidden",""),u.toggleClass("enabled")});var f=s.find("select");f.change(function(e){var t=e.target.value,r=t-n.pastLength;0!==r&&(n[r<0?"rewind":"fastForward"](Math.abs(r)),o.showPassage(n.passage))}),n.on("forward",function(t){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=n.pastLength;i>1&&f.removeAttr("disabled"),r||(f.children().each(function(t,n){t>=i&&e(n).remove()}),f.append("<option value="+i+">"+(i+1)+": "+t+"</option>").val(i))}).on("back",function(){n.pastLength<=1&&f.attr("disabled"),f.find("[selected]").removeAttr("selected"),f.val(n.pastLength)}).on("load",function(e){f.empty(),f[e.length<=1?"attr":"removeAttr"]("disabled"),e.forEach(function(e,t){return f.append("<option value="+t+">"+(t+1)+": "+e.passage+"</option>")})}),n.on("forward",i).on("back",i),r.on("set",function(e,r,i){(e===n.variables||e.TwineScript_VariableStore)&&t(r,i,e===n.variables?"":e.TwineScript_VariableStoreName)}).on("delete",function(e,t){e===n.variables&&l.find('[data-name="'+t+'"]:not(.temporary)').remove()}),e(document.body).append(s)}}),define("macrolib/values",["macros","utils","utils/operationutils","datatypes/colour","internaltypes/twineerror"],function(e,t,n,r,i){function o(e){return function(){var t=e.apply(void 0,arguments);return"number"!=typeof t||isNaN(t)?i.create("macrocall","This mathematical expression doesn't compute!"):t}}var a=t.realWhitespace,s=t.anyRealLetter,c=n.subset,u=n.objectName,l=e.TypeSignature,f=l.rest,p=l.zeroOrMore,d=l.Any;e.add(["text","string","str"],function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return n.join("")},[p(e.TypeSignature.either(String,Number,Boolean,Array))])("substring",function(e,t,n,r){return c(t,n,r)},[String,parseInt,parseInt])("lowercase",function(e,t){return t.toLowerCase()},[String])("uppercase",function(e,t){return t.toUpperCase()},[String])("lowerfirst",function(e,t){return t.replace(new RegExp(s+"+"),function(e){return e=Array.from(e),e[0].toLowerCase()+e.slice(1).join("").toLowerCase()})},[String])("upperfirst",function(e,t){return t.replace(new RegExp(s+"+"),function(e){return e=Array.from(e),e[0].toUpperCase()+e.slice(1).join("").toLowerCase()})},[String])("words",function(e,t){return t.split(new RegExp(a+"+")).filter(Boolean)},[String])(["str-repeated","string-repeated"],function(e,t,n){return t<=0?i.create("macrocall","I can't repeat this string "+t+" times."):0===n.length?i.create("macrocall","I can't repeat an empty string."):n.repeat(t)},[parseInt,String])(["str-reversed","string-reversed"],function(e,t){return[].concat(_toConsumableArray(t)).reverse().join("")},[String])(["num","number"],function(e,t){return Number.isNaN(+t)?i.create("macrocall","I couldn't convert "+u(t)+" to a number."):+t},[String])("rgb",function(e){for(var t,n=0;n<(arguments.length<=1?0:arguments.length-1);n+=1)if((t=arguments.length<=n+1?void 0:arguments[n+1])<0||t>255)return i.create("macrocall","RGB values must be whole numbers between 0 and 255, not "+u(t)+".");return r.create({r:arguments.length<=1?void 0:arguments[1],g:arguments.length<=2?void 0:arguments[2],b:arguments.length<=3?void 0:arguments[3]})},[parseInt,parseInt,parseInt])("rgba",function(e){for(var t,n=0;n<3;n+=1)if((t=arguments.length<=n+1?void 0:arguments[n+1])<0||t>255)return i.create("macrocall","RGB values must be whole numbers between 0 and 255, not "+u(t)+".");return(arguments.length<=4?void 0:arguments[4])<0||(arguments.length<=4?void 0:arguments[4])>1?i.create("macrocall","Alpha values must be numbers between 0 and 1 inclusive, not "+u(arguments.length<=4?void 0:arguments[4])+"."):r.create({r:arguments.length<=1?void 0:arguments[1],g:arguments.length<=2?void 0:arguments[2],b:arguments.length<=3?void 0:arguments[3],a:arguments.length<=4?void 0:arguments[4]})},[parseInt,parseInt,parseInt,Number])("hsl",function(e,t,n,o){var a=" values must be numbers between 0 and 1 inclusive, not ";return n<0||n>1?i.create("macrocall","Saturation"+a+u(n)+"."):o<0||o>1?i.create("macrocall","Lightness"+a+u(o)+"."):(t=Math.round(t)%360,t<0&&(t+=360),r.create({h:t,s:n,l:o}))},[Number,Number,Number])("hsla",function(e,t,n,o,a){var s=" values must be numbers between 0 and 1 inclusive, not ";return n<0||n>1?i.create("macrocall","Saturation"+s+u(n)+"."):o<0||o>1?i.create("macrocall","Lightness"+s+u(o)+"."):a<0||a>1?i.create("macrocall","Alpha"+s+u(o)+"."):(t=Math.round(t)%360,t<0&&(t+=360),r.create({h:t,s:n,l:o,a:a}))},[Number,Number,Number,Number]),{weekday:[function(){return["Sun","Mon","Tues","Wednes","Thurs","Fri","Satur"][(new Date).getDay()]+"day"},null],monthday:[function(){return(new Date).getDate()},null],currenttime:[function(){var e=new Date,t=e.getHours()<12;return(e.getHours()%12||12)+":"+(e.getMinutes()<10?"0":"")+e.getMinutes()+" "+(t?"A":"P")+"M"},null],currentdate:[function(){return(new Date).toDateString()},null],min:[Math.min,f(Number)],max:[Math.max,f(Number)],abs:[Math.abs,Number],sign:[Math.sign,Number],sin:[Math.sin,Number],cos:[Math.cos,Number],tan:[Math.tan,Number],floor:[Math.floor,Number],round:[Math.round,Number],ceil:[Math.ceil,Number],pow:[o(Math.pow),[Number,Number]],exp:[Math.exp,Number],sqrt:[o(Math.sqrt),Number],log:[o(Math.log),Number],log10:[o(Math.log10),Number],log2:[o(Math.log2),Number],random:[function(e,t){var n=void 0,r=void 0;return t?(n=Math.min(e,t),r=Math.max(e,t)):(n=0,r=e),r+=1,~~(Math.random()*(r-n))+n},[parseInt,e.TypeSignature.optional(parseInt)]],either:[function(){var e;return e=~~(Math.random()*arguments.length),arguments.length<=e?void 0:arguments[e]},f(d)],"":function(){var t=this;Object.keys(this).forEach(function(n){if(n){var r=t[n][0],i=t[n][1];e.add(n,function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return r.apply(void 0,n)},i)}})}}[""]()}),function(e){!function(){if(!e.requestAnimationFrame){if(e.webkitRequestAnimationFrame)return e.requestAnimationFrame=e.webkitRequestAnimationFrame,void(e.cancelAnimationFrame=e.webkitCancelAnimationFrame||e.webkitCancelRequestAnimationFrame);var t=0;e.requestAnimationFrame=function(n){var r=(new Date).getTime(),i=Math.max(0,16-(r-t)),o=e.setTimeout(function(){n(r+i)},i);return t=r+i,o},e.cancelAnimationFrame=function(e){clearTimeout(e)}}}(),"function"==typeof define&&define("requestAnimationFrame",[],function(){return e.requestAnimationFrame})}(window),define("macrolib/commands",["jquery","requestAnimationFrame","macros","utils","utils/selectors","state","passages","engine","internaltypes/twineerror","datatypes/hookset","datatypes/varbind","utils/operationutils"],function(e,t,n,r,i,o,a,s,c,u,l,f){function p(e){return"("+e+" "+s.options.ifid+") "}var d=f.printBuiltinValue,h=n.TypeSignature,y=h.Any,g=h.rest,m=h.either,v=h.optional,b=Object.assign;n.addCommand("display",function(e){if(!a.hasValid(e))return c.create("macrocall","I can't (display:) the passage '"+e+"' because it doesn't exist.")},function(e,t,n){return b(e,{source:r.unescape(a.get(n).get("source"))})},[String])("print",function(){},function(e,t,n){return b(e,{source:d(n)})},[y])("go-to",function(e){if(!a.hasValid(e))return c.create("macrocall","I can't (go-to:) the passage '"+e+"' because it doesn't exist.")},function(e,n,r){return t(function(){return s.goToPassage(r,{transitionOut:e.data.t8nDepart,transitionIn:e.data.t8nArrive})}),b(e,{earlyExit:!0})},[String])("undo",function(){},function(e){return o.pastLength<1?c.create("macrocall","I can't (undo:) on the first turn."):(t(function(){return s.goBack({transitionOut:e.data.t8nDepart,transitionIn:e.data.t8nArrive})}),b(e,{earlyExit:!0}))},[])("cycling-link",function(){if(""===(arguments.length<=0?void 0:arguments[0]))return c.create("macrocall","The first string in a (cycling-link:) can't be empty.");if(arguments.length<=(l.isPrototypeOf(arguments.length<=0?void 0:arguments[0])?2:1)){var e;return c.create("macrocall","I need two or more strings to cycle through, not just '"+(e=arguments.length-1,arguments.length<=e?void 0:arguments[e])+"'.")}},function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var o=void 0;l.isPrototypeOf(r[0])&&(o=r.shift());var a=0,s=_slicedToArray(t.stack,1),u=s[0].tempVariables;e.data.clickEvent=function(t){a=(a+1)%r.length;var n=""===r[a]?"":"<tw-link>"+r[a]+"</tw-link>";if(o){var i=o.set(r[a]);if(c.containsError(i))return void t.replaceWith(i.render(r[a]))}var s=b({},e,{source:n,transitionDeferred:!1});e.section.renderInto("",null,s,u)};var f="<tw-link>"+r[0]+"</tw-link>";if(o){var p=o.set(r[a]);if(c.containsError(p))return p}return b(e,{source:f,append:"replace",transitionDeferred:!0})},[m(l,String),g(String)]),r.onStartup(function(){return e(r.storyElement).on("change.dropdown-macro","select",function(){var t=e(this),n=t.closest("tw-expression, tw-hook").data("dropdownEvent");n&&n(t)})}),n.addCommand("dropdown",function(e){var t;return""===(arguments.length<=1?void 0:arguments[1])||""===(t=(arguments.length<=1?0:arguments.length-1)-1+1,arguments.length<=t?void 0:arguments[t])?c.create("macrocall","The first or last strings in a (dropdown:) can't be empty.","Because empty strings create separators within (dropdown:)s, having them at the start or end doesn't make sense."):(arguments.length<=1?0:arguments.length-1)<=1?c.create("macrocall","I need two or more strings to create a (dropdown:) menu, not just "+(arguments.length<=1?0:arguments.length-1)+"."):void 0},function(e,t,n){for(var r=arguments.length,i=Array(r>3?r-3:0),o=3;o<r;o++)i[o-3]=arguments[o];var a=Math.max.apply(Math,_toConsumableArray(i.map(function(e){return[].concat(_toConsumableArray(e)).length}))),s="<select>"+i.map(function(e,t){return"<option"+(0===t?" selected":"")+(""===e?" disabled":"")+">"+(e||"\u2500".repeat(a))+"</option>"}).join("\n")+"</select>";e.data.dropdownEvent=function(e){var t=e.val(),r=n.set(t);if(c.containsError(r))return void e.replaceWith(r.render(t))};var u=n.set(i[0]);return c.containsError(u)?u:b(e,{source:s,append:"replace"})},[l,String,g(String)])("show",function(){},function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return r.forEach(function(n){return n.forEach(t,function(n){var r=n.data("hiddenSource");void 0!==r&&t.renderInto("",null,b({},e,{source:r,target:n}))})}),e},[g(u)])("stop",function(){},function(){},[],!1)("load-game",function(){},function(e,n){var r=localStorage.getItem(p("Saved Game")+n);if(!r)return c.create("saving","I can't find a save slot named '"+n+"'!");var i=o.deserialise(r);if(i instanceof Error)return void("delete"===(window.prompt("Sorry to interrupt... The story tried to load saved data, but there was a problem.\n"+i.message+"\n\nThat data might have been saved from a different version of this story. Should I delete it?\n(Type 'delete' and choose OK to delete it.)\n\nEither way, the story will now continue without loading the data.","")||"").trim().toLowerCase()&&localStorage.removeItem(p("Saved Game")+n));t(s.showPassage.bind(s,o.passage,!1))},[String],!1)("alert",function(){if("function"!=typeof window.alert)return c.create("unimplemented","The (alert:) macro doesn't seem to work in this browser. Sorry.")},function(e,t){window.alert(t)},[String],!1)("open-url",function(){},function(e,t){window.open(t,"")},[String],!1)("reload",function(){},function(){if(o.pastLength<1)return c.create("infinite","I mustn't (reload:) the page in the starting passage.");o.hasSessionStorage&&sessionStorage.removeItem("Saved Session"),window.location.reload()},[],!1)("goto-url",function(){},function(e,t){window.location.assign(t)},[String],!1),n.add("save-game",function(e,t,n){if(n=n||"",!o.hasStorage)return!1;var r=o.serialise();if(c.containsError(r))return r;if(!1===r)return!1;try{return localStorage.setItem(p("Saved Game")+t,r),localStorage.setItem(p("Saved Game Filename")+t,n),!0}catch(e){return!1}},[String,v(String)])("prompt",function(e,t,n){return"function"!=typeof window.prompt?c.create("unimplemented","The (prompt:) macro doesn't seem to work in this browser. Sorry."):window.prompt(t,n)||""},[String,String])("confirm",function(e,t){return"function"!=typeof window.confirm?c.create("unimplemented","The (confirm:) macro doesn't seem to work in this browser. Sorry."):window.confirm(t)},[String])("page-url",function(){return window.location.href},[])}),define("macrolib/datastructures",["jquery","utils/naturalsort","macros","utils/operationutils","state","engine","passages","datatypes/lambda","datatypes/assignmentrequest","internaltypes/twineerror","internaltypes/twinenotifier"],function(e,t,n,r,i,o,a,s,c,u,l){var f=r.objectName,p=(r.typeName,r.subset),d=r.collectionType,h=r.isValidDatamapName,y=r.is,g=r.unique,m=r.clone,v=n.TypeSignature,b=v.optional,w=v.rest,x=v.either,T=v.zeroOrMore,S=v.Any;n.add("set",function(e){for(var t="",n=0;n<(arguments.length<=1?0:arguments.length-1);n+=1){var r=arguments.length<=n+1?void 0:arguments[n+1];if("into"===r.operator)return u.create("macrocall","Please say 'to' when using the (set:) macro.");var i=void 0;if(r.src&&r.src.varref){var a=r.src.get(),s=void 0;if(s=u.containsError(a))return s;i=r.dest.set(a)}else i=r.dest.set(r.src);if(u.isPrototypeOf(i))return i;o.options.debug&&(t+=(t?"; ":"")+f(r.dest)+" is now "+f(r.src))}return{TwineScript_TypeName:"a (set:) operation",TwineScript_ObjectName:"a (set:) operation",TwineScript_Unstorable:!0,TwineScript_Print:function(){return t&&l.create(t).render().html()}}},[w(c)])("put",function(e){for(var t="",n=0;n<(arguments.length<=1?0:arguments.length-1);n+=1){var r=arguments.length<=n+1?void 0:arguments[n+1];if("into"!==r.operator)return u.create("macrocall","Please say 'into' when using the (put:) macro.");var i=r.dest.set(r.src);if(u.isPrototypeOf(i))return i;o.options.debug&&(t+=(t?"; ":"")+f(r.dest)+" is now "+f(r.src))}return{TwineScript_TypeName:"a (put:) operation",TwineScript_ObjectName:"a (put:) operation",TwineScript_Unstorable:!0,TwineScript_Print:function(){return t&&l.create(t).render().html()}}},[w(c)])("move",function(e){for(var t="",n=0;n<(arguments.length<=1?0:arguments.length-1);n+=1){var r=arguments.length<=n+1?void 0:arguments[n+1];if("into"!==r.operator)return u.create("macrocall","Please say 'into' when using the (move:) macro.");var i=void 0,a=void 0;if(r.src&&r.src.varref){var s=r.src.get();if(a=u.containsError(s))return a;if(i=r.dest.set(s),a=u.containsError(i))return a;r.src.delete()}else if(i=r.dest.set(r.src),a=u.containsError(i))return a;o.options.debug&&(t+=(t?"; ":"")+f(r.dest)+" is now "+f(r.src))}return{TwineScript_TypeName:"a (move:) operation",TwineScript_ObjectName:"a (move:) operation",TwineScript_Unstorable:!0,TwineScript_Print:function(){return t&&l.create(t).render().html()}}},[w(c)])(["a","array"],function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return n},T(S))("range",function e(t,n,r){if(n>r)return e(t,r,n);var i=[n];for(r-=n;r-- >0;)i.push(++n);return i},[parseInt,parseInt])("subarray",function(e,t,n,r){return p(t,n,r)},[Array,parseInt,parseInt])("reversed",function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return n.reverse().map(m)},T(S))("shuffled",function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return n.reduce(function(e,t,n){var r=Math.random()*(n+1)|0;return r===n?e.push(t):(e.push(e[r]),e[r]=t),e},[]).map(m)},[S,w(S)])("sorted",function(e){for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return r.sort(t("en"))},[x(Number,String),w(x(Number,String))])("rotated",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return t*=-1,0===t?u.create("macrocall","I can't rotate these values by 0 positions."):Math.abs(t)>=r.length?u.create("macrocall","I can't rotate these "+r.length+" values by "+t+" positions."):r.slice(t).concat(r.slice(0,t)).map(m)},[parseInt,S,w(S)])("repeated",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];if(t<=0)return u.create("macrocall","I can't repeat these values "+t+" times.");for(var o=[];t-- >0;)o.push.apply(o,r);return o.map(m)},[parseInt,w(S)])("interlaced",function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];for(var i=Math.min.apply(Math,_toConsumableArray(n.map(function(e){return e.length}))),o=[],a=0;a<i;a+=1)for(var s=0;s<n.length;s+=1)o.push(m(n[s][a]));return o},[Array,w(Array)]),n.add("altered",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return r.map(function(n){return t.apply(e,{loop:n})})},[s.TypeSignature("via"),T(S)])("find",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return t.filter(e,r)},[s.TypeSignature("where"),T(S)])("all-pass",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var o=t.filter(e,r);return u.containsError(o)||o.length===r.length},[s.TypeSignature("where"),T(S)])("some-pass",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var o=t.filter(e,r);return u.containsError(o)||o.length>0},[s.TypeSignature("where"),T(S)])("none-pass",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var o=t.filter(e,r);return u.containsError(o)||0===o.length
+},[s.TypeSignature("where"),T(S)])("folded",function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return"where"in t&&(r=t.filter(e,r)),u.containsError(r)||r.reduce(function(n,r){return t.apply(e,{making:n,loop:r})})},[x(s.TypeSignature("where via making"),s.TypeSignature("via making")),w(S)]),n.add("datanames",function(e,n){return Array.from(n.keys()).sort(t("en"))},[Map])("datavalues",function(e,n){return Array.from(n.entries()).sort(function(e,n){return[e[0],n[0]].sort(t("en"))[0]===e[0]?-1:1}).map(function(e){return m(e[1])})},[Map])("dataentries",function(e,n){return Array.from(n.entries()).sort(function(e,n){return[e[0],n[0]].sort(t("en"))[0]===e[0]?-1:1}).map(function(e){return new Map([["name",e[0]],["value",m(e[1])]])})},[Map])("history",function(){return i.pastPassageNames()},[])("passage",function(e,t){return m(a.get(t||i.passage))||u.create("macrocall","There's no passage named '"+t+"' in this story.")},[b(String)])("savedgames",function(){function e(e){return"("+e+" "+o.options.ifid+") "}var t=0,n=void 0,r=new Map;do{if(!i.hasStorage)break;n=localStorage.key(t),t+=1;var a=e("Saved Game");n&&n.startsWith(a)&&(n=n.slice(a.length),r.set(n,localStorage.getItem(e("Saved Game Filename")+n)))}while(n);return r},[])(["datamap","dm"],function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=void 0,o=new Map,a=n.reduce(function(e,t){var n=void 0;if(u.containsError(e))return e;if(void 0===i)i=t;else{if(n=u.containsError(h(o,i)))return n;if(o.has(i))return u.create("macrocall","You used the same data name ("+f(i)+") twice in the same (datamap:) call.");o.set(i,m(t)),i=void 0}return e},!0);return u.containsError(a)?a:void 0!==i?u.create("macrocall","This datamap has a data name without a value."):o},T(S))(["dataset","ds"],function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new Set(n.filter(g).map(m))},T(S))("count",function e(t,n){for(var r=arguments.length,i=Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];if(i.length>1){var a=void 0,s=i.map(function(r){return e(t,n,r)});return(a=u.containsError(s))?a:s.reduce(function(e,t){return e+t},0)}var c=i[0];switch(d(n)){case"dataset":case"datamap":return u.create("macrocall","(count:) shouldn't be given a datamap or dataset.","You should use the 'contains' operator instead. For instance, write: $variable contains 'value'.");case"string":return"string"!=typeof c?u.create("macrocall",f(n)+" can't contain  "+f(c)+" because it isn't a string."):c?n.split(c).length-1:0;case"array":return n.reduce(function(e,t){return e+y(t,c)},0);default:return u.create("macrocall",f(n)+" can't contain values, let alone "+f(c)+".")}},[S,w(S)])}),define("macrolib/stylechangers",["jquery","macros","utils","utils/selectors","datatypes/colour","datatypes/changercommand","datatypes/lambda","internaltypes/changedescriptor","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,c){var u=t.TypeSignature,l=u.either,f=u.wrapped,p=u.optional,d=u.Any,h=u.zeroOrMore,y=[f(Boolean,'If you gave a number, you may instead want to check that the number is not 0. If you gave a string, you may instead want to check that the string is not "".')];n.onStartup(function(){return e(n.storyElement).on("mouseenter.hover-macro","[hover=false]",function(){var t=e(this),n=t.data("hoverChanger");t.data({mouseoutStyle:t.attr("style")||""}),s.create({target:t},n).update(),t.attr("hover",!0)}).on("mouseleave.hover-macro","[hover=true]",function(){var t=e(this),n=t.data("mouseoutStyle");t.attr("style",n).removeData("mouseoutStyle").attr("hover",!1)})});var g=["instant","dissolve","rumble","shudder","pulse","flicker","slideleft","slideright","slideup","slidedown"],m="Only the following names are recognised (capitalisation and hyphens ignored): "+g.join(", ");t.addChanger("if",function(e,t){return o.create("if",[t])},function(e,t){return e.enabled=e.enabled&&t},y)("unless",function(e,t){return o.create("unless",[!t])},function(e,t){return e.enabled=e.enabled&&t},y)("elseif",function(e,t){return"lastHookShown"in e.stack[0]?o.create("elseif",[!1===e.stack[0].lastHookShown&&!!t]):c.create("macrocall","There's no (if:) or something else before this to do (else-if:) with.")},function(e,t){return e.enabled=e.enabled&&t},y)("else",function(e){return"lastHookShown"in e.stack[0]?o.create("else",[!1===e.stack[0].lastHookShown]):c.create("macrocall","There's nothing before this to do (else:) with.")},function(e,t){return e.enabled=e.enabled&&t},null)("hidden",function(){return o.create("hidden")},function(e){return e.enabled=!1},null)("live",function(e,t){return o.create("live",[t])},function(e,t){e.enabled=!1,e.data.live={delay:t}},p(Number))("event",function(e,t){return o.create("event",[t])},function(e,t){e.enabled=!1,e.data.live={event:t}},a.TypeSignature("when"))("hook",function(e,t){return o.create("hook",[t])},function(e,t){return e.attr.push({name:t})},[String])(["for","loop"],function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return t.loop?o.create("for",[t,r]):c.create("macrocall","The lambda provided to (for:) must refer to a temp variable, not just 'it'.")},function(e,t,n){var r=t.filter(e.section,n),i=void 0;if(i=c.containsError(r))return i;e.loopVars[t.loop]=r||[]},[a.TypeSignature("where"),h(d)])(["transition","t8n"],function(e,t){return t=n.insensitiveName(t),-1===g.indexOf(t)?c.create("macrocall","'"+t+"' is not a valid (transition:)",m):o.create("transition",[t])},function(e,t){return e.transition=t,e},[String])(["transition-time","t8n-time"],function(e,t){return t<=0?c.create("macrocall","(transition-time:) should be a positive number of (milli)seconds, not "+t):o.create("transition-time",[t])},function(e,t){return e.transitionTime=t,e.data.t8nTime=t,e},[Number])(["transition-depart","t8n-depart"],function(e,t){return t=n.insensitiveName(t),-1===g.indexOf(t)?c.create("macrocall","'"+t+"' is not a valid transition",m):o.create("transition-depart",[t])},function(e,t){return e.data.t8nDepart=t,e},[String])(["transition-arrive","t8n-arrive"],function(e,t){return t=n.insensitiveName(t),-1===g.indexOf(t)?c.create("macrocall","'"+t+"' is not a valid transition",m):o.create("transition-arrive",[t])},function(e,t){return e.data.t8nArrive=t,e},[String])("font",function(e,t){return o.create("font",[t])},function(e,t){return e.styles.push({"font-family":t}),e},[String])("align",function(e,t){var n=void 0,r=t.indexOf("><");if(!/^(==+>|<=+|=+><=+|<==+>)$/.test(t))return c.create("macrocall",'The (align:) macro requires an alignment arrow ("==>", "<==", "==><=" etc.) be provided, not "'+t+'"');if(~r){var i=Math.round(r/(t.length-2)*50);n=Object.assign({"text-align":"center","max-width":"50%"},25===i?{"margin-left":"auto","margin-right":"auto"}:{"margin-left":i+"%"})}else n="<"===t[0]&&">"===t.slice(-1)?{"text-align":"justify","max-width":"50%"}:t.includes(">")?{"text-align":"right"}:{"text-align":"left"};return n.display="block",o.create("align",[n])},function(e,t){e.styles.push(t)},[String])(["text-colour","text-color","color","colour"],function(e,t){return i.isPrototypeOf(t)&&(t=t.toRGBAString(t)),o.create("text-colour",[t])},function(e,t){return e.styles.push({color:t}),e},[l(String,i)])("text-rotate",function(e,t){return o.create("text-rotate",[t])},function(t,n){return t.styles.push({display:"inline-block",transform:function(){var t=e(this).css("transform")||"";return"none"===t&&(t=""),t+" rotate("+n+"deg)"}}),t},[Number])("background",function(e,t){return i.isPrototypeOf(t)&&(t=t.toRGBAString(t)),o.create("background",[t])},function(t,r){var o=void 0;return o=i.isHexString(r)||i.isCSS3Function(r)?{"background-color":r}:{"background-size":"cover","background-image":"url("+r+")"},t.styles.push(o,{display:function(){return n.childrenProbablyInline(e(this))?"initial":"block"}}),t},[l(String,i)]).apply(void 0,_toConsumableArray(function(){var t={color:"transparent"},r=Object.assign(Object.create(null),{none:{},bold:{"font-weight":"bold"},italic:{"font-style":"italic"},underline:{"text-decoration":"underline"},strike:{"text-decoration":"line-through"},superscript:{"vertical-align":"super","font-size":".83em"},subscript:{"vertical-align":"sub","font-size":".83em"},blink:{animation:"fade-in-out 1s steps(1,end) infinite alternate"},shudder:{animation:"shudder linear 0.1s 0s infinite",display:"inline-block"},mark:{"background-color":"hsla(60, 100%, 50%, 0.6)"},condense:{"letter-spacing":"-0.08em"},expand:{"letter-spacing":"0.1em"},outline:[{"text-shadow":function(){var t=e(this).css("color");return"-1px -1px 0 "+t+", 1px -1px 0 "+t+",-1px  1px 0 "+t+", 1px  1px 0 "+t}},{color:function(){for(var t=e(this);t.length&&t[0]!==document;t=t.parent()){var n=t.css("background-color");if("transparent"!==n&&!n.match(/^\w+a\(.+?,\s*0\s*\)$/))return n}return"#fff"}}],shadow:{"text-shadow":function(){return"0.08em 0.08em 0.08em "+e(this).css("color")}},emboss:{"text-shadow":function(){return"0.08em 0.08em 0em "+e(this).css("color")}},smear:[{"text-shadow":function(){var t=e(this).css("color");return"0em   0em 0.02em "+t+",-0.2em 0em  0.5em "+t+", 0.2em 0em  0.5em "+t}},t],blur:[{"text-shadow":function(){return"0em 0em 0.08em "+e(this).css("color")}},t],blurrier:[{"text-shadow":function(){return"0em 0em 0.2em "+e(this).css("color")},"user-select":"none"},t],mirror:{display:"inline-block",transform:"scaleX(-1)"},upsidedown:{display:"inline-block",transform:"scaleY(-1)"},fadeinout:{animation:"fade-in-out 2s ease-in-out infinite alternate"},rumble:{animation:"rumble linear 0.1s 0s infinite",display:"inline-block"}});return["text-style",function(e,t){return t=n.insensitiveName(t),t in r?o.create("text-style",[t]):c.create("macrocall","'"+t+"' is not a valid (text-style:)","Only the following names are recognised (capitalisation and hyphens ignored): "+Object.keys(r).join(", "))},function(e,t){return n.assertMustHave(r,[t]),e.styles="none"===t?[]:e.styles.concat(r[t]),e}]}()).concat([[String]]))("hover-style",function(e,t){var n=s.create(),r=(t.run(n),n.summary());return r+""=="styles"||r.every(function(e){return"styles"===e||"attr"===e})&&n.attr.every(function(e){return Object.keys(e)+""=="style"})?o.create("hover-style",[t]):c.create("macrocall","The changer given to (hover-style:) must only change the hook's style.")},function(e,t){return e.data.hoverChanger=t,e.attr.push({hover:!1}),e},[o])("css",function(e,t){return t.trim().endsWith(";")||(t+=";"),o.create("css",[t])},function(t,n){return t.attr.push({style:function(){return(e(this).attr("style")||"")+n}}),t},[String])}),define("internaltypes/enchantment",["jquery","utils","internaltypes/changedescriptor"],function(e,t,n){var r={create:function(n){return t.assertOnlyHas(n,["scope","section","attr","data","changer","functions"]),Object.assign(Object.create(this),{enchantments:e()},n)},enchantScope:function(){var r=this,i=this.attr,o=this.data,a=this.functions,s=this.section,c=this.changer,u=this.scope;u instanceof e&&(u=Array.prototype.map.call(u,function(t){return e(t)})),this.enchantments=e(),u.forEach(s,function(e){var u=e.wrapAll("<tw-enchantment>").parent();if(i&&u.attr(i),o&&u.data(o),a&&a.forEach(function(e){return e(u)}),c){var l=n.create({section:s,target:u});if(c.run(l),l.update(),e.is(t.storyElement)){var f=Object.keys(Object.assign.apply(Object,[{}].concat(_toConsumableArray(l.styles))));e.css(f.reduce(function(e,t){return e[t]="inherit",e},{})),u.data({enchantedProperties:f})}}e.is(t.storyElement)&&u.css({width:"100%",height:"100%"}),r.enchantments=r.enchantments.add(u)})},disenchant:function(){this.enchantments.each(function(){var n=e(this).contents();n.unwrap();var r=e(this).data("enchantedProperties");r&&n.has(t.storyElement)&&t.storyElement.css(r.reduce(function(e,t){return e[t]="",e},{}))})}};return Object.freeze(r)}),define("macrolib/enchantments",["jquery","utils","utils/selectors","utils/operationutils","engine","passages","macros","datatypes/hookset","datatypes/changercommand","internaltypes/enchantment","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,c,u,l){function f(n,r){return t.onStartup(function(){t.storyElement.on(n.event+".enchantment","."+n.classList.replace(/ /g,"."),function(){var t=e(this),n=t.data("enchantmentEvent");n&&n(t)})}),[function(e,t){return t?c.create(r,[s.from(t)]):l.create("datatype","A string given to this ("+r+":) macro was empty.")},function(e,t){e.enabled=!1,e.transitionDeferred=!0,n.rerender&&(e.newTargets=(e.newTargets||[]).concat({target:t,append:n.rerender}));var r=_slicedToArray(e.section.stack,1),o=r[0].tempVariables,a=u.create({functions:[function(e){e.attr("class",e.children().is("tw-story, tw-sidebar, tw-passage")?n.blockClassList:n.classList)}],attr:(n.classList+"").match(/\b(?:link|enchantment-clickblock)\b/)?{tabIndex:"0"}:{},data:{enchantmentEvent:function(){if(n.once){var t=e.section.enchantments.indexOf(a);e.section.enchantments.splice(t,1),a.disenchant()}if(n.goto)return void i.goToPassage(n.goto,{transitionOut:n.transitionOut,transitionIn:n.transitionIn});e.section.renderInto(e.source,null,Object.assign({},e,{enabled:!0,transitionDeferred:!1}),o)}},scope:t,section:e.section});return e.section.enchantments.push(a),a.enchantScope(),e},h(s,String)]}var p=r.is,d=a.TypeSignature,h=d.either,y=d.rest;a.addCommand("enchant",function(e,t){var n=t.summary();if(n.includes("newTargets")||n.includes("target"))return l.create("macrocall","The changer given to (enchant:) can't include a revision command like (replace:) or (append:).")},function(e,t,n){var r=u.create({scope:s.from(t),changer:n,section:e});return e.enchantments.push(r),r.enchantScope(),""},[h(s,String),c],!1);var g=["replace","append","prepend"];g.forEach(function(t){a.addChanger(t,function(e){for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return r.every(Boolean)?c.create(t,r.map(s.from)):l.create("datatype","A string given to this ("+t+":) macro was empty.")},function(n){for(var r,i=arguments.length,o=Array(i>1?i-1:0),a=1;a<i;a++)o[a-1]=arguments[a];return e(n.target).parents().filter("tw-collapsed").length>0||(n.attr=[].concat(_toConsumableArray(n.attr),[{collapsing:!1}])),n.newTargets=n.newTargets||[],(r=n.newTargets).push.apply(r,_toConsumableArray(o.filter(function(e){return!n.newTargets.some(function(n){var r=n.target,i=n.append;return p(e,r)&&t===i})}).map(function(e){return{target:e,append:t,before:!0}}))),n},y(h(s,String)))}),t.onStartup(function(){t.storyElement.on("click.enchantment",function(){Array.from(e(this).parents(".enchantment-clickblock")).sort(function(e,t){return 8&e.compareDocumentPosition(t)?1:-1}).forEach(function(t){var n=e(t).data("enchantmentEvent");n&&n()})})});var m=[{name:"click",enchantDesc:{event:"click",once:!0,rerender:"",classList:"link enchantment-link",blockClassList:"enchantment-clickblock"}},{name:"mouseover",enchantDesc:{event:"mouseenter",once:!0,rerender:"",classList:"enchantment-mouseover"}},{name:"mouseout",enchantDesc:{event:"mouseleave",once:!0,rerender:"",classList:"enchantment-mouseout"}}];m.forEach(function(e){return a.addChanger.apply(a,[e.name].concat(_toConsumableArray(f(e.enchantDesc,e.name))))}),g.forEach(function(e){m.forEach(function(t){var n=Object.assign({},t.enchantDesc,{rerender:e}),r=t.name+"-"+e;a.addChanger.apply(a,[r].concat(_toConsumableArray(f(n,r))))})}),m.forEach(function(e){var t=e.name+"-goto";a.addCommand(t,function(e,n){return e&&n?o.hasValid(n)?void 0:l.create("macrocall","I can't ("+t+":) the passage '"+n+"' because it doesn't exist."):l.create("datatype","A string given to this ("+t+":) macro was empty.")},function(n,r,i,o){var a=f(Object.assign({},e.enchantDesc,{goto:o,transitionOut:n.data.t8nDepart,transitionIn:n.data.t8nArrive}),t);return(0,_slicedToArray(a,2)[1])({section:r},s.from(i)),Object.assign(n,{source:""})},[h(s,String),String])})}),define("macrolib/links",["jquery","macros","utils","utils/selectors","state","passages","engine","datatypes/changercommand","datatypes/hookset","internaltypes/twineerror"],function(e,t,n,r,i,o,a,s,c,u){var l=t.TypeSignature,f=l.optional,p=l.rest,d=["Links can't have empty strings for their displayed text.","In the link syntax, a link's displayed text is inside the [[ and ]], and on the non-pointy side of the -> or <- arrow if it's there."],h=Object.assign;n.onStartup(function(){return e(n.storyElement).on("click.passage-link",r.internalLink,function(){var t=e(this),n=t.closest("tw-expression"),r=t.closest("tw-expression, tw-hook").data("clickEvent");if(r){if(t.find("tw-error").length>0)return;return void r(t)}var i=n.data("linkPassageName"),o=n.data("t8nDepart"),s=n.data("t8nArrive"),c=n.data("t8nTime");return n.find("tw-enchantment").each(function(t,n){o=e(n).data("t8nDepart")||o,s=e(n).data("t8nArrive")||s,c=void 0!==e(n).data("t8nTime")?e(n).data("t8nTime"):c}),i?void a.goToPassage(i,{transitionOut:o,transitionIn:s,transitionTime:c}):t.is("[undo]")?void a.goBack({transitionOut:o,transitionIn:s,transitionTime:c}):void 0})}),[["link","link-replace"],["link-reveal"],["link-repeat"]].forEach(function(e){return t.addChanger(e,function(t,n){return n?s.create(e[0],[n]):u.create("macrocall",d[0])},function(t,n){t.innerSource||(t.innerSource=t.source),t.source="<tw-link tabindex=0>"+n+"</tw-link>",t.append="link"===e[0]?"replace":"append",t.transitionDeferred=!0;var r=_slicedToArray(t.section.stack,1),i=r[0].tempVariables;t.data.clickEvent=function(n){"link-reveal"===e[0]&&n.contents().unwrap(),t.source=t.innerSource+"",t.transitionDeferred=!1,t.section.renderInto("",null,t,i)}},[String])}),t.addCommand(["link-goto"],function(e,t){if(!e)return u.create.apply(u,["macrocall"].concat(d));t||(t=e)},function(t,r,a,s){var c=r.evaluateTwineMarkup(n.unescape(s||a)),u=void 0;c instanceof e&&(u=c),o.hasValid(c)||(u='<tw-broken-link passage-name="'+n.escape(c)+'">'+a+"</tw-broken-link>");var l=i.passageNameVisited(c);return u=u||"<tw-link tabindex=0 "+(l>0?'class="visited" ':"")+'">'+a+"</tw-link>",t.data.linkPassageName=c,h(t,{source:u,transitionDeferred:!0})},[String,f(String)])("link-undo",function(e){if(!e)return u.create("macrocall",d[0])},function(e,t,n){return i.pastLength<1?u.create("macrocall","I can't use (link-undo:) on the first turn."):h(e,{source:"<tw-link tabindex=0 undo>"+n+"</tw-link>",transitionDeferred:!0})},[String])("link-show",function(e){if(!e)return u.create("macrocall",d[0])},function(e,t,n){for(var r=arguments.length,i=Array(r>3?r-3:0),o=3;o<r;o++)i[o-3]=arguments[o];var a=_slicedToArray(t.stack,1),s=a[0].tempVariables;return e.data.clickEvent=function(n){n.contents().unwrap(),i.forEach(function(n){return n.forEach(t,function(n){var r=n.data("hiddenSource");void 0!==r&&t.renderInto("",null,h({},e,{source:r,target:n,transitionDeferred:!1}),s)})})},h(e,{source:"<tw-link tabindex=0>"+n+"</tw-link>",transitionDeferred:!0})},[String,p(c)]),t.addChanger(["link-reveal-goto"],function(t,r,i){if(!r)return u.create.apply(u,["macrocall"].concat(d));i||(i=r);var o=t.evaluateTwineMarkup(n.unescape(i||r));return o instanceof e?o.data("TwineError"):s.create("link-reveal-goto",[r||i,o])},function(e,t,r){if(!o.hasValid(r))return void(e.source='<tw-broken-link passage-name="'+n.escape(r)+'">'+t+"</tw-broken-link>");e.innerSource||(e.innerSource=e.source);var s=i.passageNameVisited(r);e.source="<tw-link tabindex=0 "+(s>0?'class="visited" ':"")+">"+t+"</tw-link>",e.append="append",e.transitionDeferred=!0;var c=_slicedToArray(e.section.stack,1),u=c[0].tempVariables;e.data.clickEvent=function(t){e.source=e.innerSource,t.contents().unwrap(),e.transitionDeferred=!1,e.section.renderInto(e.innerSource+"",null,e,u),e.target.find("[earlyexit]").length||a.goToPassage(r,{transitionOut:e.data.t8nDepart,transitionIn:e.data.t8nArrive})}},[String,f(String)])}),define("repl",["utils","markup","twinescript/compiler","twinescript/environ"],function(e,t,n,r){window.REPL=function(e){var i=n(t.lex("(print:"+e+")"));console.log(i);var o=r({}).eval(i);return o.TwineScript_Print?o.TwineScript_Print():o},window.LEX=function(e){var n=t.lex(e);return 1===n.length?n[0]:n}}),require.config({paths:{jquery:"../node_modules/jquery/dist/jquery",almond:"../node_modules/almond/almond","es6-shim":"../node_modules/es6-shim/es6-shim",requestAnimationFrame:"../node_modules/requestanimationframe/app/requestAnimationFrame",jqueryplugins:"utils/jqueryplugins",markup:"./markup/markup",lexer:"./markup/lexer",patterns:"./markup/patterns"},deps:["jquery","es6-shim","jqueryplugins"]}),require(["jquery","debugmode","renderer","state","engine","passages","utils","utils/selectors","macros","macrolib/values","macrolib/commands","macrolib/datastructures","macrolib/stylechangers","macrolib/enchantments","macrolib/links","repl"],function($,DebugMode,Renderer,State,Engine,Passages,Utils,Selectors){function _eval(text){return eval(text+"")}var _installHandlers=function(){$(document.documentElement).on("keydown",function(e){13===e.which&&"0"===e.target.getAttribute("tabindex")&&$(e.target).trigger("click")}),Engine.options.debug&&DebugMode(),_installHandlers=null};!function(e){window.onerror=function(t,n,r,i,o){var a=o&&o.stack&&"\n"+o.stack.replace(/\([^\)]+\)/g,"")+"\n"||"("+t+")\n";alert("Sorry to interrupt, but this page's code has got itself in a mess. "+a+"(This is probably due to a bug in the Harlowe game engine.)"),window.onerror=e,"function"==typeof e&&e.apply(void 0,arguments)}}(window.onerror),Utils.onStartup(function(){var e=$(Selectors.storyData);if(0!==e.length){var t=e.attr("options");t&&t.split(/\s/).forEach(function(e){Renderer.options[e]=Engine.options[e]=!0});var n=e.attr("startnode");Renderer.options.ifid=Engine.options.ifid=e.attr("ifid"),n||(n=[].reduce.call($(Selectors.passageData),function(e,t){var n=t.getAttribute("pid");return n<e?n:e},1/0)),n=$(Selectors.passageData+"[pid="+n+"]").attr("name"),_installHandlers(),$(Selectors.script).each(function(e){try{_eval($(this).html())}catch(t){alert("There is a problem with this story's script (#"+(e+1)+"):\n\n"+t.message)}}),$(Selectors.stylesheet).each(function(e){$(document.head).append('<style data-title="Story stylesheet '+(e+1)+'">'+$(this).html())});var r=!Engine.options.debug&&State.hasSessionStorage&&sessionStorage.getItem("Saved Session");if(r&&!0===State.deserialise(r))return void Engine.showPassage(State.passage,!1);Engine.goToPassage(n)}})}),define("harlowe",function(){}),require(["harlowe"])}();
+</script>
 
 
 </body>
diff --git a/docs/demo/twee/start.twee b/docs/demo/twee/start.twee
index 42ad3fd..d4a6744 100644
--- a/docs/demo/twee/start.twee
+++ b/docs/demo/twee/start.twee
@@ -8,23 +8,22 @@
     A.createGroup('tests', 'beep', 'nope');
     A.createGroup('bgm', 'cibelle', 'que-pena');
     A.createPlaylist('bgm', 'cibelle', 'que-pena');
+    A.createPlaylist('test', 'beep', 'nope');
 
     A.preload();
 </script>
 
-:: story-menu [startup]
-<script>
-    A.menu.links.add('Navigate', 'other passage');
-    A.menu.links.add('Alert', function () {
-        alert('This is an alert.');
-    });
-    A.menu.links.add('Both', 'other passage', function () {
-        alert('This is an alert.');
-    });
-    A.menu.links.add('Removes self.', function () {
-        A.menu.links.remove('Removes self.');
-    });
-</script>
+:: story-menu [script]
+A.menu.links.add('Navigate', 'other passage');
+A.menu.links.add('Alert', function () {
+    alert('This is an alert.');
+});
+A.menu.links.add('Both', 'other passage', function () {
+    alert('This is an alert.');
+});
+A.menu.links.add('Removes self.', function () {
+    A.menu.links.remove('Removes self.');
+});
 
 :: Start
 <script>A.playlist('bgm').random().loop(true).playWhenPossible();</script>\
@@ -93,8 +92,31 @@ Tests:
     </script>
 ]
 }
+<!--
+[[stop test]]
+[[playlist test]]
+-->
 
 :: other passage
 This is another passage!
 
-[[Go back.|Start]]
\ No newline at end of file
+[[Go back.|Start]]
+
+:: stop test
+<span id='counter-test'>0</span>
+(link-repeat: 'test')[
+    <script>
+        A.track('beep').play();
+        A.track('beep').one(':stop', function () {
+            var x = Number($('#counter-test').text())
+            $('#counter-test').empty().append(++x);
+        });
+    </script>
+]
+
+:: playlist test
+(link-repeat: 'test')[
+    <script>
+        A.playlist('test').loop(true).play();
+    </script>
+]
diff --git a/gulpfile.js b/gulpfile.js
index ed833a6..a59dea5 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -43,11 +43,30 @@ function rimraf () {
 
 // build functions
 function buildScripts () {
-    return processScripts('./src/*.js', './src/wrap', 'min.js');
+    var jsFiles = [
+        'get.js',
+        'audio.js',
+        'controlpanel.js',
+        'detect.js',
+        'preload.js',
+        'state.js',
+        'setup.js',
+        'userland.js',
+        'fixes.js'
+    ].map( function (file) {
+        return './src/js/' + file;
+    });
+    return processScripts(jsFiles, './src/wrap', 'min.js');
 }
 
 function buildStyles () {
-    return processStyles('./src/*.css', './dist', 'harlowe-audio.min.css');
+    var cssFiles = [
+        'overlay.css',
+        'panel.css'
+    ].map( function (file) {
+        return './src/css/' + file;
+    });
+    return processStyles(cssFiles, './dist', 'harlowe-audio.min.css');
 }
 
 // add js wrapper
diff --git a/package-lock.json b/package-lock.json
index 8b8cdb6..8ada861 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,21 +1,9 @@
 {
   "name": "harlowe-audio",
-  "version": "0.1.0",
+  "version": "1.3.0",
   "lockfileVersion": 1,
   "requires": true,
   "dependencies": {
-    "ajv": {
-      "version": "5.5.2",
-      "resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz",
-      "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=",
-      "optional": true,
-      "requires": {
-        "co": "^4.6.0",
-        "fast-deep-equal": "^1.0.0",
-        "fast-json-stable-stringify": "^2.0.0",
-        "json-schema-traverse": "^0.3.0"
-      }
-    },
     "ansi-colors": {
       "version": "1.1.0",
       "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-1.1.0.tgz",
@@ -187,53 +175,26 @@
       "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz",
       "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg="
     },
-    "asn1": {
-      "version": "0.2.4",
-      "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz",
-      "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==",
-      "optional": true,
-      "requires": {
-        "safer-buffer": "~2.1.0"
-      }
-    },
-    "assert-plus": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz",
-      "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU="
-    },
     "assign-symbols": {
       "version": "1.0.0",
       "resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz",
       "integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c="
     },
-    "async": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/async/-/async-1.0.0.tgz",
-      "integrity": "sha1-+PwEyjoTeErenhZBr5hXjPvWR6k=",
-      "optional": true
-    },
     "async-done": {
-      "version": "1.3.1",
-      "resolved": "https://registry.npmjs.org/async-done/-/async-done-1.3.1.tgz",
-      "integrity": "sha512-R1BaUeJ4PMoLNJuk+0tLJgjmEqVsdN118+Z8O+alhnQDQgy0kmD5Mqi0DNEmMx2LM0Ed5yekKu+ZXYvIHceicg==",
+      "version": "1.3.2",
+      "resolved": "https://registry.npmjs.org/async-done/-/async-done-1.3.2.tgz",
+      "integrity": "sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw==",
       "requires": {
         "end-of-stream": "^1.1.0",
         "once": "^1.3.2",
-        "process-nextick-args": "^1.0.7",
+        "process-nextick-args": "^2.0.0",
         "stream-exhaust": "^1.0.1"
-      },
-      "dependencies": {
-        "process-nextick-args": {
-          "version": "1.0.7",
-          "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz",
-          "integrity": "sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M="
-        }
       }
     },
     "async-each": {
-      "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.1.tgz",
-      "integrity": "sha1-GdOGodntxufByF04iu28xW0zYC0="
+      "version": "1.0.3",
+      "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.3.tgz",
+      "integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ=="
     },
     "async-settle": {
       "version": "1.0.0",
@@ -243,16 +204,10 @@
         "async-done": "^1.2.2"
       }
     },
-    "asynckit": {
-      "version": "0.4.0",
-      "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
-      "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=",
-      "optional": true
-    },
     "atob": {
-      "version": "2.1.1",
-      "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.1.tgz",
-      "integrity": "sha1-ri1acpR38onWDdf5amMUoi3Wwio="
+      "version": "2.1.2",
+      "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
+      "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg=="
     },
     "autoprefixer": {
       "version": "8.6.5",
@@ -267,18 +222,6 @@
         "postcss-value-parser": "^3.2.3"
       }
     },
-    "aws-sign2": {
-      "version": "0.7.0",
-      "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz",
-      "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=",
-      "optional": true
-    },
-    "aws4": {
-      "version": "1.8.0",
-      "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz",
-      "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==",
-      "optional": true
-    },
     "bach": {
       "version": "1.2.0",
       "resolved": "https://registry.npmjs.org/bach/-/bach-1.2.0.tgz",
@@ -350,19 +293,10 @@
         }
       }
     },
-    "bcrypt-pbkdf": {
-      "version": "1.0.2",
-      "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz",
-      "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=",
-      "optional": true,
-      "requires": {
-        "tweetnacl": "^0.14.3"
-      }
-    },
     "binary-extensions": {
-      "version": "1.11.0",
-      "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.11.0.tgz",
-      "integrity": "sha1-RqoXUftqL5PuXmibsQh9SxTGwgU="
+      "version": "1.13.1",
+      "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.13.1.tgz",
+      "integrity": "sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw=="
     },
     "binaryextensions": {
       "version": "2.1.1",
@@ -424,11 +358,6 @@
       "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz",
       "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A=="
     },
-    "builtin-modules": {
-      "version": "1.1.1",
-      "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-1.1.1.tgz",
-      "integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8="
-    },
     "cache-base": {
       "version": "1.0.1",
       "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz",
@@ -455,30 +384,30 @@
       "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000876.tgz",
       "integrity": "sha512-v+Q2afhJJ1oydQnEB4iHhxDz5x9lWPbRnQBQlM3FgtZxqLO8KDSdu4txUrFwC1Ws9I2kQi/QImkvj17NbVpNAg=="
     },
-    "caseless": {
-      "version": "0.12.0",
-      "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz",
-      "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=",
-      "optional": true
-    },
     "chokidar": {
-      "version": "2.0.4",
-      "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-2.0.4.tgz",
-      "integrity": "sha512-z9n7yt9rOvIJrMhvDtDictKrkFHeihkNl6uWMmZlmL6tJtX9Cs+87oK+teBx+JIgzvbX3yZHT3eF8vpbDxHJXQ==",
+      "version": "2.1.6",
+      "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-2.1.6.tgz",
+      "integrity": "sha512-V2jUo67OKkc6ySiRpJrjlpJKl9kDuG+Xb8VgsGzb+aEouhgS1D0weyPU4lEzdAcsCAvrih2J2BqyXqHWvVLw5g==",
       "requires": {
         "anymatch": "^2.0.0",
-        "async-each": "^1.0.0",
-        "braces": "^2.3.0",
-        "fsevents": "^1.2.2",
+        "async-each": "^1.0.1",
+        "braces": "^2.3.2",
+        "fsevents": "^1.2.7",
         "glob-parent": "^3.1.0",
-        "inherits": "^2.0.1",
+        "inherits": "^2.0.3",
         "is-binary-path": "^1.0.0",
         "is-glob": "^4.0.0",
-        "lodash.debounce": "^4.0.8",
-        "normalize-path": "^2.1.1",
+        "normalize-path": "^3.0.0",
         "path-is-absolute": "^1.0.0",
-        "readdirp": "^2.0.0",
-        "upath": "^1.0.5"
+        "readdirp": "^2.2.1",
+        "upath": "^1.1.1"
+      },
+      "dependencies": {
+        "normalize-path": {
+          "version": "3.0.0",
+          "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz",
+          "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA=="
+        }
       }
     },
     "class-utils": {
@@ -524,29 +453,6 @@
       "requires": {
         "exit": "0.1.2",
         "glob": "^7.1.1"
-      },
-      "dependencies": {
-        "glob": {
-          "version": "7.1.2",
-          "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz",
-          "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
-          "requires": {
-            "fs.realpath": "^1.0.0",
-            "inflight": "^1.0.4",
-            "inherits": "2",
-            "minimatch": "^3.0.4",
-            "once": "^1.3.0",
-            "path-is-absolute": "^1.0.0"
-          }
-        },
-        "minimatch": {
-          "version": "3.0.4",
-          "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
-          "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
-          "requires": {
-            "brace-expansion": "^1.1.7"
-          }
-        }
       }
     },
     "cliui": {
@@ -613,12 +519,6 @@
         }
       }
     },
-    "co": {
-      "version": "4.6.0",
-      "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz",
-      "integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ=",
-      "optional": true
-    },
     "code-point-at": {
       "version": "1.1.0",
       "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz",
@@ -661,29 +561,15 @@
       "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz",
       "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg=="
     },
-    "colors": {
-      "version": "1.0.3",
-      "resolved": "https://registry.npmjs.org/colors/-/colors-1.0.3.tgz",
-      "integrity": "sha1-BDP0TYCWgP3rYO0mDxsMJi6CpAs=",
-      "optional": true
-    },
-    "combined-stream": {
-      "version": "1.0.6",
-      "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.6.tgz",
-      "integrity": "sha1-cj599ugBrFYTETp+RFqbactjKBg=",
-      "requires": {
-        "delayed-stream": "~1.0.0"
-      }
-    },
     "commander": {
-      "version": "2.16.0",
-      "resolved": "https://registry.npmjs.org/commander/-/commander-2.16.0.tgz",
-      "integrity": "sha512-sVXqklSaotK9at437sFlFpyOcJonxe0yST/AG9DkQKUdIE6IqGIMv4SfAQSKaJbSdVEJYItASCrBiVQHq1HQew=="
+      "version": "2.20.0",
+      "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.0.tgz",
+      "integrity": "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ=="
     },
     "component-emitter": {
-      "version": "1.2.1",
-      "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz",
-      "integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY="
+      "version": "1.3.0",
+      "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz",
+      "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg=="
     },
     "concat-map": {
       "version": "0.0.1",
@@ -699,35 +585,6 @@
         "inherits": "^2.0.3",
         "readable-stream": "^2.2.2",
         "typedarray": "^0.0.6"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
       }
     },
     "concat-with-sourcemaps": {
@@ -754,9 +611,12 @@
       }
     },
     "convert-source-map": {
-      "version": "1.5.1",
-      "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.5.1.tgz",
-      "integrity": "sha1-uCeAl7m8IpNl3lxiz1/K7YtVmeU="
+      "version": "1.6.0",
+      "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.6.0.tgz",
+      "integrity": "sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A==",
+      "requires": {
+        "safe-buffer": "~5.1.1"
+      }
     },
     "copy-descriptor": {
       "version": "0.1.1",
@@ -777,27 +637,13 @@
       "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
       "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
     },
-    "cycle": {
-      "version": "1.0.3",
-      "resolved": "https://registry.npmjs.org/cycle/-/cycle-1.0.3.tgz",
-      "integrity": "sha1-IegLK+hYD5i0aPN5QwZisEbDStI=",
-      "optional": true
-    },
     "d": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/d/-/d-1.0.0.tgz",
-      "integrity": "sha1-dUu1v+VUUdpppYuU1F9MWwRi1Y8=",
-      "requires": {
-        "es5-ext": "^0.10.9"
-      }
-    },
-    "dashdash": {
-      "version": "1.14.1",
-      "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz",
-      "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=",
-      "optional": true,
+      "version": "1.0.1",
+      "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz",
+      "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==",
       "requires": {
-        "assert-plus": "^1.0.0"
+        "es5-ext": "^0.10.50",
+        "type": "^1.0.1"
       }
     },
     "date-now": {
@@ -844,12 +690,11 @@
       "integrity": "sha1-vLgrqnKtebQmp2cy8aga1t8m1oQ="
     },
     "define-properties": {
-      "version": "1.1.2",
-      "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.2.tgz",
-      "integrity": "sha1-g6c/L+pWmJj7c3GTyPhzyvbUXJQ=",
+      "version": "1.1.3",
+      "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz",
+      "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==",
       "requires": {
-        "foreach": "^2.0.5",
-        "object-keys": "^1.0.8"
+        "object-keys": "^1.0.12"
       }
     },
     "define-property": {
@@ -902,41 +747,31 @@
         "rimraf": "^2.2.8"
       }
     },
-    "delayed-stream": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
-      "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
-    },
     "detect-file": {
       "version": "1.0.0",
       "resolved": "https://registry.npmjs.org/detect-file/-/detect-file-1.0.0.tgz",
       "integrity": "sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc="
     },
     "dom-serializer": {
-      "version": "0.1.0",
-      "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.0.tgz",
-      "integrity": "sha1-BzxpdUbOB4DOI75KKOKT5AvDDII=",
+      "version": "0.1.1",
+      "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.1.tgz",
+      "integrity": "sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA==",
       "requires": {
-        "domelementtype": "~1.1.1",
-        "entities": "~1.1.1"
+        "domelementtype": "^1.3.0",
+        "entities": "^1.1.1"
       },
       "dependencies": {
-        "domelementtype": {
-          "version": "1.1.3",
-          "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.1.3.tgz",
-          "integrity": "sha1-vSh3PiZCiBrsUVRJJCmcXNgiGFs="
-        },
         "entities": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.1.tgz",
-          "integrity": "sha1-blwtClYhtdra7O+AuQ7ftc13cvA="
+          "version": "1.1.2",
+          "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz",
+          "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w=="
         }
       }
     },
     "domelementtype": {
-      "version": "1.3.0",
-      "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.0.tgz",
-      "integrity": "sha1-sXrtguirWeUt2cGbF1bg/BhyBMI="
+      "version": "1.3.1",
+      "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz",
+      "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w=="
     },
     "domhandler": {
       "version": "2.3.0",
@@ -956,43 +791,14 @@
       }
     },
     "duplexify": {
-      "version": "3.6.0",
-      "resolved": "https://registry.npmjs.org/duplexify/-/duplexify-3.6.0.tgz",
-      "integrity": "sha512-fO3Di4tBKJpYTFHAxTU00BcfWMY9w24r/x21a6rZRbsD/ToUgGxsMbiGRmB7uVAXeGKXD9MwiLZa5E97EVgIRQ==",
+      "version": "3.7.1",
+      "resolved": "https://registry.npmjs.org/duplexify/-/duplexify-3.7.1.tgz",
+      "integrity": "sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g==",
       "requires": {
         "end-of-stream": "^1.0.0",
         "inherits": "^2.0.1",
         "readable-stream": "^2.0.0",
         "stream-shift": "^1.0.0"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
       }
     },
     "each-props": {
@@ -1004,16 +810,6 @@
         "object.defaults": "^1.1.0"
       }
     },
-    "ecc-jsbn": {
-      "version": "0.1.2",
-      "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz",
-      "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=",
-      "optional": true,
-      "requires": {
-        "jsbn": "~0.1.0",
-        "safer-buffer": "^2.1.0"
-      }
-    },
     "editions": {
       "version": "1.3.4",
       "resolved": "https://registry.npmjs.org/editions/-/editions-1.3.4.tgz",
@@ -1056,13 +852,13 @@
       }
     },
     "es5-ext": {
-      "version": "0.10.46",
-      "resolved": "https://registry.npmjs.org/es5-ext/-/es5-ext-0.10.46.tgz",
-      "integrity": "sha512-24XxRvJXNFwEMpJb3nOkiRJKRoupmjYmOPVlI65Qy2SrtxwOTB+g6ODjBKOtwEHbYrhWRty9xxOWLNdClT2djw==",
+      "version": "0.10.50",
+      "resolved": "https://registry.npmjs.org/es5-ext/-/es5-ext-0.10.50.tgz",
+      "integrity": "sha512-KMzZTPBkeQV/JcSQhI5/z6d9VWJ3EnQ194USTUwIYZ2ZbpN8+SGXQKt1h68EX44+qt+Fzr8DO17vnxrw7c3agw==",
       "requires": {
         "es6-iterator": "~2.0.3",
         "es6-symbol": "~3.1.1",
-        "next-tick": "1"
+        "next-tick": "^1.0.0"
       }
     },
     "es6-iterator": {
@@ -1075,12 +871,6 @@
         "es6-symbol": "^3.1.1"
       }
     },
-    "es6-promise": {
-      "version": "4.2.4",
-      "resolved": "https://registry.npmjs.org/es6-promise/-/es6-promise-4.2.4.tgz",
-      "integrity": "sha512-/NdNZVJg+uZgtm9eS3O6lrOLYmQag2DjdEXuPaHlZ6RuVqgqaVZfgYCepEIKsLqwdQArOPtC3XzRLqGGfT8KQQ==",
-      "optional": true
-    },
     "es6-symbol": {
       "version": "3.1.1",
       "resolved": "https://registry.npmjs.org/es6-symbol/-/es6-symbol-3.1.1.tgz",
@@ -1091,13 +881,13 @@
       }
     },
     "es6-weak-map": {
-      "version": "2.0.2",
-      "resolved": "https://registry.npmjs.org/es6-weak-map/-/es6-weak-map-2.0.2.tgz",
-      "integrity": "sha1-XjqzIlH/0VOKH45f+hNXdy+S2W8=",
+      "version": "2.0.3",
+      "resolved": "https://registry.npmjs.org/es6-weak-map/-/es6-weak-map-2.0.3.tgz",
+      "integrity": "sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA==",
       "requires": {
         "d": "1",
-        "es5-ext": "^0.10.14",
-        "es6-iterator": "^2.0.1",
+        "es5-ext": "^0.10.46",
+        "es6-iterator": "^2.0.3",
         "es6-symbol": "^3.1.1"
       }
     },
@@ -1234,29 +1024,6 @@
         }
       }
     },
-    "extract-zip": {
-      "version": "1.6.7",
-      "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-1.6.7.tgz",
-      "integrity": "sha1-qEC0uK9kAyZMjbV/Txp0Mz74H+k=",
-      "optional": true,
-      "requires": {
-        "concat-stream": "1.6.2",
-        "debug": "2.6.9",
-        "mkdirp": "0.5.1",
-        "yauzl": "2.4.1"
-      }
-    },
-    "extsprintf": {
-      "version": "1.3.0",
-      "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz",
-      "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU="
-    },
-    "eyes": {
-      "version": "0.1.8",
-      "resolved": "https://registry.npmjs.org/eyes/-/eyes-0.1.8.tgz",
-      "integrity": "sha1-Ys8SAjTGg3hdkCNIqADvPgzCC8A=",
-      "optional": true
-    },
     "fancy-log": {
       "version": "1.3.2",
       "resolved": "https://registry.npmjs.org/fancy-log/-/fancy-log-1.3.2.tgz",
@@ -1267,27 +1034,6 @@
         "time-stamp": "^1.0.0"
       }
     },
-    "fast-deep-equal": {
-      "version": "1.1.0",
-      "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz",
-      "integrity": "sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ=",
-      "optional": true
-    },
-    "fast-json-stable-stringify": {
-      "version": "2.0.0",
-      "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz",
-      "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=",
-      "optional": true
-    },
-    "fd-slicer": {
-      "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.0.1.tgz",
-      "integrity": "sha1-i1vL2ewyfFBBv5qwI/1nUPEXfmU=",
-      "optional": true,
-      "requires": {
-        "pend": "~1.2.0"
-      }
-    },
     "fill-range": {
       "version": "4.0.0",
       "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz",
@@ -1319,30 +1065,20 @@
       }
     },
     "findup-sync": {
-      "version": "2.0.0",
-      "resolved": "https://registry.npmjs.org/findup-sync/-/findup-sync-2.0.0.tgz",
-      "integrity": "sha1-kyaxSIwi0aYIhlCoaQGy2akKLLw=",
+      "version": "3.0.0",
+      "resolved": "https://registry.npmjs.org/findup-sync/-/findup-sync-3.0.0.tgz",
+      "integrity": "sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg==",
       "requires": {
         "detect-file": "^1.0.0",
-        "is-glob": "^3.1.0",
+        "is-glob": "^4.0.0",
         "micromatch": "^3.0.4",
         "resolve-dir": "^1.0.1"
-      },
-      "dependencies": {
-        "is-glob": {
-          "version": "3.1.0",
-          "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz",
-          "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=",
-          "requires": {
-            "is-extglob": "^2.1.0"
-          }
-        }
       }
     },
     "fined": {
-      "version": "1.1.0",
-      "resolved": "https://registry.npmjs.org/fined/-/fined-1.1.0.tgz",
-      "integrity": "sha1-s33IRLdqL15wgeiE98CuNE8VNHY=",
+      "version": "1.2.0",
+      "resolved": "https://registry.npmjs.org/fined/-/fined-1.2.0.tgz",
+      "integrity": "sha512-ZYDqPLGxDkDhDZBjZBb+oD1+j0rA4E0pXY50eplAAOPg2N/gUBSSk5IM1/QhPfyVo19lJ+CvXpqfvk+b2p/8Ng==",
       "requires": {
         "expand-tilde": "^2.0.2",
         "is-plain-object": "^2.0.3",
@@ -1352,46 +1088,17 @@
       }
     },
     "flagged-respawn": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/flagged-respawn/-/flagged-respawn-1.0.0.tgz",
-      "integrity": "sha1-Tnmumy6zi/hrO7Vr8+ClaqX8q9c="
+      "version": "1.0.1",
+      "resolved": "https://registry.npmjs.org/flagged-respawn/-/flagged-respawn-1.0.1.tgz",
+      "integrity": "sha512-lNaHNVymajmk0OJMBn8fVUAU1BtDeKIqKoVhk4xAALB57aALg6b4W0MfJ/cUE0g9YBXy5XhSlPIpYIJ7HaY/3Q=="
     },
     "flush-write-stream": {
-      "version": "1.0.3",
-      "resolved": "https://registry.npmjs.org/flush-write-stream/-/flush-write-stream-1.0.3.tgz",
-      "integrity": "sha512-calZMC10u0FMUqoiunI2AiGIIUtUIvifNwkHhNupZH4cbNnW1Itkoh/Nf5HFYmDrwWPjrUxpkZT0KhuCq0jmGw==",
+      "version": "1.1.1",
+      "resolved": "https://registry.npmjs.org/flush-write-stream/-/flush-write-stream-1.1.1.tgz",
+      "integrity": "sha512-3Z4XhFZ3992uIq0XOqb9AreonueSYphE6oYbpt5+3u06JWklbsPkNv3ZKkP9Bz/r+1MWCaMoSQ28P85+1Yc77w==",
       "requires": {
-        "inherits": "^2.0.1",
-        "readable-stream": "^2.0.4"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
+        "inherits": "^2.0.3",
+        "readable-stream": "^2.3.6"
       }
     },
     "for-in": {
@@ -1407,28 +1114,6 @@
         "for-in": "^1.0.1"
       }
     },
-    "foreach": {
-      "version": "2.0.5",
-      "resolved": "https://registry.npmjs.org/foreach/-/foreach-2.0.5.tgz",
-      "integrity": "sha1-C+4AUBiusmDQo6865ljdATbsG5k="
-    },
-    "forever-agent": {
-      "version": "0.6.1",
-      "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz",
-      "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=",
-      "optional": true
-    },
-    "form-data": {
-      "version": "2.3.2",
-      "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.2.tgz",
-      "integrity": "sha1-SXBJi+YEwgwAXU9cI67NIda0kJk=",
-      "optional": true,
-      "requires": {
-        "asynckit": "^0.4.0",
-        "combined-stream": "1.0.6",
-        "mime-types": "^2.1.12"
-      }
-    },
     "fragment-cache": {
       "version": "0.2.1",
       "resolved": "https://registry.npmjs.org/fragment-cache/-/fragment-cache-0.2.1.tgz",
@@ -1437,25 +1122,6 @@
         "map-cache": "^0.2.2"
       }
     },
-    "fs-extra": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-1.0.0.tgz",
-      "integrity": "sha1-zTzl9+fLYUWIP8rjGR6Yd/hYeVA=",
-      "optional": true,
-      "requires": {
-        "graceful-fs": "^4.1.2",
-        "jsonfile": "^2.1.0",
-        "klaw": "^1.0.0"
-      },
-      "dependencies": {
-        "graceful-fs": {
-          "version": "4.1.11",
-          "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz",
-          "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=",
-          "optional": true
-        }
-      }
-    },
     "fs-mkdirp-stream": {
       "version": "1.0.0",
       "resolved": "https://registry.npmjs.org/fs-mkdirp-stream/-/fs-mkdirp-stream-1.0.0.tgz",
@@ -1471,13 +1137,13 @@
       "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8="
     },
     "fsevents": {
-      "version": "1.2.4",
-      "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.4.tgz",
-      "integrity": "sha512-z8H8/diyk76B7q5wg+Ud0+CqzcAF3mBBI/bA5ne5zrRUUIvNkJY//D3BqyH571KuAC4Nr7Rw7CjWX4r0y9DvNg==",
+      "version": "1.2.9",
+      "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.9.tgz",
+      "integrity": "sha512-oeyj2H3EjjonWcFjD5NvZNE9Rqe4UW+nQBU2HNeKw0koVLEFIhtyETyAakeAM3de7Z/SW5kcA+fZUait9EApnw==",
       "optional": true,
       "requires": {
-        "nan": "^2.9.2",
-        "node-pre-gyp": "^0.10.0"
+        "nan": "^2.12.1",
+        "node-pre-gyp": "^0.12.0"
       },
       "dependencies": {
         "abbrev": {
@@ -1495,7 +1161,7 @@
           "optional": true
         },
         "are-we-there-yet": {
-          "version": "1.1.4",
+          "version": "1.1.5",
           "bundled": true,
           "optional": true,
           "requires": {
@@ -1516,7 +1182,7 @@
           }
         },
         "chownr": {
-          "version": "1.0.1",
+          "version": "1.1.1",
           "bundled": true,
           "optional": true
         },
@@ -1538,15 +1204,15 @@
           "optional": true
         },
         "debug": {
-          "version": "2.6.9",
+          "version": "4.1.1",
           "bundled": true,
           "optional": true,
           "requires": {
-            "ms": "2.0.0"
+            "ms": "^2.1.1"
           }
         },
         "deep-extend": {
-          "version": "0.5.1",
+          "version": "0.6.0",
           "bundled": true,
           "optional": true
         },
@@ -1589,7 +1255,7 @@
           }
         },
         "glob": {
-          "version": "7.1.2",
+          "version": "7.1.3",
           "bundled": true,
           "optional": true,
           "requires": {
@@ -1607,11 +1273,11 @@
           "optional": true
         },
         "iconv-lite": {
-          "version": "0.4.21",
+          "version": "0.4.24",
           "bundled": true,
           "optional": true,
           "requires": {
-            "safer-buffer": "^2.1.0"
+            "safer-buffer": ">= 2.1.2 < 3"
           }
         },
         "ignore-walk": {
@@ -1664,15 +1330,15 @@
           "bundled": true
         },
         "minipass": {
-          "version": "2.2.4",
+          "version": "2.3.5",
           "bundled": true,
           "requires": {
-            "safe-buffer": "^5.1.1",
+            "safe-buffer": "^5.1.2",
             "yallist": "^3.0.0"
           }
         },
         "minizlib": {
-          "version": "1.1.0",
+          "version": "1.2.1",
           "bundled": true,
           "optional": true,
           "requires": {
@@ -1687,32 +1353,32 @@
           }
         },
         "ms": {
-          "version": "2.0.0",
+          "version": "2.1.1",
           "bundled": true,
           "optional": true
         },
         "needle": {
-          "version": "2.2.0",
+          "version": "2.3.0",
           "bundled": true,
           "optional": true,
           "requires": {
-            "debug": "^2.1.2",
+            "debug": "^4.1.0",
             "iconv-lite": "^0.4.4",
             "sax": "^1.2.4"
           }
         },
         "node-pre-gyp": {
-          "version": "0.10.0",
+          "version": "0.12.0",
           "bundled": true,
           "optional": true,
           "requires": {
             "detect-libc": "^1.0.2",
             "mkdirp": "^0.5.1",
-            "needle": "^2.2.0",
+            "needle": "^2.2.1",
             "nopt": "^4.0.1",
             "npm-packlist": "^1.1.6",
             "npmlog": "^4.0.2",
-            "rc": "^1.1.7",
+            "rc": "^1.2.7",
             "rimraf": "^2.6.1",
             "semver": "^5.3.0",
             "tar": "^4"
@@ -1728,12 +1394,12 @@
           }
         },
         "npm-bundled": {
-          "version": "1.0.3",
+          "version": "1.0.6",
           "bundled": true,
           "optional": true
         },
         "npm-packlist": {
-          "version": "1.1.10",
+          "version": "1.4.1",
           "bundled": true,
           "optional": true,
           "requires": {
@@ -1798,11 +1464,11 @@
           "optional": true
         },
         "rc": {
-          "version": "1.2.7",
+          "version": "1.2.8",
           "bundled": true,
           "optional": true,
           "requires": {
-            "deep-extend": "^0.5.1",
+            "deep-extend": "^0.6.0",
             "ini": "~1.3.0",
             "minimist": "^1.2.0",
             "strip-json-comments": "~2.0.1"
@@ -1830,15 +1496,15 @@
           }
         },
         "rimraf": {
-          "version": "2.6.2",
+          "version": "2.6.3",
           "bundled": true,
           "optional": true,
           "requires": {
-            "glob": "^7.0.5"
+            "glob": "^7.1.3"
           }
         },
         "safe-buffer": {
-          "version": "5.1.1",
+          "version": "5.1.2",
           "bundled": true
         },
         "safer-buffer": {
@@ -1852,7 +1518,7 @@
           "optional": true
         },
         "semver": {
-          "version": "5.5.0",
+          "version": "5.7.0",
           "bundled": true,
           "optional": true
         },
@@ -1896,16 +1562,16 @@
           "optional": true
         },
         "tar": {
-          "version": "4.4.1",
+          "version": "4.4.8",
           "bundled": true,
           "optional": true,
           "requires": {
-            "chownr": "^1.0.1",
+            "chownr": "^1.1.1",
             "fs-minipass": "^1.2.5",
-            "minipass": "^2.2.4",
-            "minizlib": "^1.1.0",
+            "minipass": "^2.3.4",
+            "minizlib": "^1.1.1",
             "mkdirp": "^0.5.0",
-            "safe-buffer": "^5.1.1",
+            "safe-buffer": "^5.1.2",
             "yallist": "^3.0.2"
           }
         },
@@ -1915,11 +1581,11 @@
           "optional": true
         },
         "wide-align": {
-          "version": "1.1.2",
+          "version": "1.1.3",
           "bundled": true,
           "optional": true,
           "requires": {
-            "string-width": "^1.0.2"
+            "string-width": "^1.0.2 || 2"
           }
         },
         "wrappy": {
@@ -1927,7 +1593,7 @@
           "bundled": true
         },
         "yallist": {
-          "version": "3.0.2",
+          "version": "3.0.3",
           "bundled": true
         }
       }
@@ -1947,15 +1613,6 @@
       "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz",
       "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg="
     },
-    "getpass": {
-      "version": "0.1.7",
-      "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz",
-      "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=",
-      "optional": true,
-      "requires": {
-        "assert-plus": "^1.0.0"
-      }
-    },
     "glob": {
       "version": "7.1.2",
       "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz",
@@ -2003,44 +1660,17 @@
         "remove-trailing-separator": "^1.0.1",
         "to-absolute-glob": "^2.0.0",
         "unique-stream": "^2.0.2"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
       }
     },
     "glob-watcher": {
-      "version": "5.0.1",
-      "resolved": "https://registry.npmjs.org/glob-watcher/-/glob-watcher-5.0.1.tgz",
-      "integrity": "sha512-fK92r2COMC199WCyGUblrZKhjra3cyVMDiypDdqg1vsSDmexnbYivK1kNR4QItiNXLKmGlqan469ks67RtNa2g==",
+      "version": "5.0.3",
+      "resolved": "https://registry.npmjs.org/glob-watcher/-/glob-watcher-5.0.3.tgz",
+      "integrity": "sha512-8tWsULNEPHKQ2MR4zXuzSmqbdyV5PtwwCaWSGQ1WwHsJ07ilNeN1JB8ntxhckbnpSHaf9dXFUHzIWvm1I13dsg==",
       "requires": {
+        "anymatch": "^2.0.0",
         "async-done": "^1.2.0",
         "chokidar": "^2.0.0",
+        "is-negated-glob": "^1.0.0",
         "just-debounce": "^1.0.0",
         "object.defaults": "^1.1.0"
       }
@@ -2087,33 +1717,33 @@
       }
     },
     "glogg": {
-      "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/glogg/-/glogg-1.0.1.tgz",
-      "integrity": "sha512-ynYqXLoluBKf9XGR1gA59yEJisIL7YHEH4xr3ZziHB5/yl4qWfaK8Js9jGe6gBGCSCKVqiyO30WnRZADvemUNw==",
+      "version": "1.0.2",
+      "resolved": "https://registry.npmjs.org/glogg/-/glogg-1.0.2.tgz",
+      "integrity": "sha512-5mwUoSuBk44Y4EshyiqcH95ZntbDdTQqA3QYSrxmzj28Ai0vXBGMH1ApSANH14j2sIRtqCEyg6PfsuP7ElOEDA==",
       "requires": {
         "sparkles": "^1.0.0"
       }
     },
     "graceful-fs": {
-      "version": "4.1.11",
-      "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz",
-      "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg="
+      "version": "4.1.15",
+      "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.15.tgz",
+      "integrity": "sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA=="
     },
     "gulp": {
-      "version": "4.0.0",
-      "resolved": "https://registry.npmjs.org/gulp/-/gulp-4.0.0.tgz",
-      "integrity": "sha1-lXZsYB2t5Kd+0+eyttwDiBtZY2Y=",
+      "version": "4.0.2",
+      "resolved": "https://registry.npmjs.org/gulp/-/gulp-4.0.2.tgz",
+      "integrity": "sha512-dvEs27SCZt2ibF29xYgmnwwCYZxdxhQ/+LFWlbAW8y7jt68L/65402Lz3+CKy0Ov4rOs+NERmDq7YlZaDqUIfA==",
       "requires": {
-        "glob-watcher": "^5.0.0",
-        "gulp-cli": "^2.0.0",
-        "undertaker": "^1.0.0",
+        "glob-watcher": "^5.0.3",
+        "gulp-cli": "^2.2.0",
+        "undertaker": "^1.2.1",
         "vinyl-fs": "^3.0.0"
       },
       "dependencies": {
         "gulp-cli": {
-          "version": "2.0.1",
-          "resolved": "https://registry.npmjs.org/gulp-cli/-/gulp-cli-2.0.1.tgz",
-          "integrity": "sha512-RxujJJdN8/O6IW2nPugl7YazhmrIEjmiVfPKrWt68r71UCaLKS71Hp0gpKT+F6qOUFtr7KqtifDKaAJPRVvMYQ==",
+          "version": "2.2.0",
+          "resolved": "https://registry.npmjs.org/gulp-cli/-/gulp-cli-2.2.0.tgz",
+          "integrity": "sha512-rGs3bVYHdyJpLqR0TUBnlcZ1O5O++Zs4bA0ajm+zr3WFCfiSLjGwoCBqFs18wzN+ZxahT9DkOK5nDf26iDsWjA==",
           "requires": {
             "ansi-colors": "^1.0.1",
             "archy": "^1.0.0",
@@ -2125,7 +1755,7 @@
             "gulplog": "^1.0.0",
             "interpret": "^1.1.0",
             "isobject": "^3.0.1",
-            "liftoff": "^2.5.0",
+            "liftoff": "^3.1.0",
             "matchdep": "^2.0.0",
             "mute-stdout": "^1.0.0",
             "pretty-hrtime": "^1.0.0",
@@ -2317,25 +1947,20 @@
       }
     },
     "gulp-uglify": {
-      "version": "3.0.1",
-      "resolved": "https://registry.npmjs.org/gulp-uglify/-/gulp-uglify-3.0.1.tgz",
-      "integrity": "sha512-KVffbGY9d4Wv90bW/B1KZJyunLMyfHTBbilpDvmcrj5Go0/a1G3uVpt+1gRBWSw/11dqR3coJ1oWNTt1AiXuWQ==",
+      "version": "3.0.2",
+      "resolved": "https://registry.npmjs.org/gulp-uglify/-/gulp-uglify-3.0.2.tgz",
+      "integrity": "sha512-gk1dhB74AkV2kzqPMQBLA3jPoIAPd/nlNzP2XMDSG8XZrqnlCiDGAqC+rZOumzFvB5zOphlFh6yr3lgcAb/OOg==",
       "requires": {
+        "array-each": "^1.0.1",
+        "extend-shallow": "^3.0.2",
         "gulplog": "^1.0.0",
         "has-gulplog": "^0.1.0",
-        "lodash": "^4.13.1",
+        "isobject": "^3.0.1",
         "make-error-cause": "^1.1.1",
         "safe-buffer": "^5.1.2",
         "through2": "^2.0.0",
         "uglify-js": "^3.0.5",
         "vinyl-sourcemaps-apply": "^0.2.0"
-      },
-      "dependencies": {
-        "lodash": {
-          "version": "4.17.10",
-          "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz",
-          "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg=="
-        }
       }
     },
     "gulplog": {
@@ -2346,22 +1971,6 @@
         "glogg": "^1.0.0"
       }
     },
-    "har-schema": {
-      "version": "2.0.0",
-      "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz",
-      "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=",
-      "optional": true
-    },
-    "har-validator": {
-      "version": "5.1.0",
-      "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.0.tgz",
-      "integrity": "sha512-+qnmNjI4OfH2ipQ9VQOw23bBd/ibtfbVdK2fYbY4acTDqKTW/YDp9McimZdDbG8iV9fZizUqQMD5xvriB146TA==",
-      "optional": true,
-      "requires": {
-        "ajv": "^5.3.0",
-        "har-schema": "^2.0.0"
-      }
-    },
     "has-flag": {
       "version": "3.0.0",
       "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
@@ -2409,20 +2018,10 @@
         }
       }
     },
-    "hasha": {
-      "version": "2.2.0",
-      "resolved": "https://registry.npmjs.org/hasha/-/hasha-2.2.0.tgz",
-      "integrity": "sha1-eNfL/B5tZjA/55g3NlmEUXsvbuE=",
-      "optional": true,
-      "requires": {
-        "is-stream": "^1.0.1",
-        "pinkie-promise": "^2.0.0"
-      }
-    },
     "homedir-polyfill": {
-      "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/homedir-polyfill/-/homedir-polyfill-1.0.1.tgz",
-      "integrity": "sha1-TCu8inWJmP7r9e1oWA921GdotLw=",
+      "version": "1.0.3",
+      "resolved": "https://registry.npmjs.org/homedir-polyfill/-/homedir-polyfill-1.0.3.tgz",
+      "integrity": "sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA==",
       "requires": {
         "parse-passwd": "^1.0.0"
       }
@@ -2442,17 +2041,29 @@
         "domutils": "1.5",
         "entities": "1.0",
         "readable-stream": "1.1"
-      }
-    },
-    "http-signature": {
-      "version": "1.2.0",
-      "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz",
-      "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=",
-      "optional": true,
-      "requires": {
-        "assert-plus": "^1.0.0",
-        "jsprim": "^1.2.2",
-        "sshpk": "^1.7.0"
+      },
+      "dependencies": {
+        "isarray": {
+          "version": "0.0.1",
+          "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
+          "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8="
+        },
+        "readable-stream": {
+          "version": "1.1.14",
+          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz",
+          "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=",
+          "requires": {
+            "core-util-is": "~1.0.0",
+            "inherits": "~2.0.1",
+            "isarray": "0.0.1",
+            "string_decoder": "~0.10.x"
+          }
+        },
+        "string_decoder": {
+          "version": "0.10.31",
+          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz",
+          "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ="
+        }
       }
     },
     "inflight": {
@@ -2475,9 +2086,9 @@
       "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw=="
     },
     "interpret": {
-      "version": "1.1.0",
-      "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.1.0.tgz",
-      "integrity": "sha1-ftGxQQxqDg94z5XTuEQMY/eLhhQ="
+      "version": "1.2.0",
+      "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.2.0.tgz",
+      "integrity": "sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw=="
     },
     "invert-kv": {
       "version": "1.0.0",
@@ -2529,14 +2140,6 @@
       "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz",
       "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w=="
     },
-    "is-builtin-module": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz",
-      "integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=",
-      "requires": {
-        "builtin-modules": "^1.0.0"
-      }
-    },
     "is-data-descriptor": {
       "version": "0.1.4",
       "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz",
@@ -2591,9 +2194,9 @@
       }
     },
     "is-glob": {
-      "version": "4.0.0",
-      "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.0.tgz",
-      "integrity": "sha1-lSHHaEXMJhCoUgPd8ICpWML/q8A=",
+      "version": "4.0.1",
+      "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz",
+      "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==",
       "requires": {
         "is-extglob": "^2.1.1"
       }
@@ -2658,18 +2261,6 @@
         "is-unc-path": "^1.0.0"
       }
     },
-    "is-stream": {
-      "version": "1.1.0",
-      "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz",
-      "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=",
-      "optional": true
-    },
-    "is-typedarray": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz",
-      "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=",
-      "optional": true
-    },
     "is-unc-path": {
       "version": "1.0.0",
       "resolved": "https://registry.npmjs.org/is-unc-path/-/is-unc-path-1.0.0.tgz",
@@ -2694,9 +2285,9 @@
       "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA=="
     },
     "isarray": {
-      "version": "0.0.1",
-      "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
-      "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8="
+      "version": "1.0.0",
+      "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
+      "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
     },
     "isexe": {
       "version": "2.0.0",
@@ -2708,11 +2299,6 @@
       "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz",
       "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8="
     },
-    "isstream": {
-      "version": "0.1.2",
-      "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz",
-      "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo="
-    },
     "istextorbinary": {
       "version": "2.2.1",
       "resolved": "https://registry.npmjs.org/istextorbinary/-/istextorbinary-2.2.1.tgz",
@@ -2723,182 +2309,51 @@
         "textextensions": "2"
       }
     },
-    "jsbn": {
-      "version": "0.1.1",
-      "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz",
-      "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=",
-      "optional": true
-    },
     "jshint": {
-      "version": "2.9.6",
-      "resolved": "https://registry.npmjs.org/jshint/-/jshint-2.9.6.tgz",
-      "integrity": "sha512-KO9SIAKTlJQOM4lE64GQUtGBRpTOuvbrRrSZw3AhUxMNG266nX9hK2cKA4SBhXOj0irJGyNyGSLT62HGOVDEOA==",
+      "version": "2.10.2",
+      "resolved": "https://registry.npmjs.org/jshint/-/jshint-2.10.2.tgz",
+      "integrity": "sha512-e7KZgCSXMJxznE/4WULzybCMNXNAd/bf5TSrvVEq78Q/K8ZwFpmBqQeDtNiHc3l49nV4E/+YeHU/JZjSUIrLAA==",
       "requires": {
         "cli": "~1.0.0",
         "console-browserify": "1.1.x",
         "exit": "0.1.x",
         "htmlparser2": "3.8.x",
-        "lodash": "~4.17.10",
+        "lodash": "~4.17.11",
         "minimatch": "~3.0.2",
-        "phantom": "~4.0.1",
-        "phantomjs-prebuilt": "~2.1.7",
         "shelljs": "0.3.x",
-        "strip-json-comments": "1.0.x",
-        "unicode-5.2.0": "^0.7.5"
-      },
-      "dependencies": {
-        "lodash": {
-          "version": "4.17.10",
-          "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz",
-          "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg=="
-        },
-        "minimatch": {
-          "version": "3.0.4",
-          "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
-          "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
-          "requires": {
-            "brace-expansion": "^1.1.7"
-          }
-        }
+        "strip-json-comments": "1.0.x"
       }
     },
-    "json-schema": {
-      "version": "0.2.3",
-      "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz",
-      "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=",
-      "optional": true
-    },
-    "json-schema-traverse": {
-      "version": "0.3.1",
-      "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz",
-      "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=",
-      "optional": true
-    },
-    "json-stable-stringify": {
+    "json-stable-stringify-without-jsonify": {
       "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz",
-      "integrity": "sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8=",
-      "requires": {
-        "jsonify": "~0.0.0"
-      }
-    },
-    "json-stringify-safe": {
-      "version": "5.0.1",
-      "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz",
-      "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=",
-      "optional": true
-    },
-    "jsonfile": {
-      "version": "2.4.0",
-      "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
-      "integrity": "sha1-NzaitCi4e72gzIO1P6PWM6NcKug=",
-      "optional": true,
-      "requires": {
-        "graceful-fs": "^4.1.6"
-      },
-      "dependencies": {
-        "graceful-fs": {
-          "version": "4.1.11",
-          "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz",
-          "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=",
-          "optional": true
-        }
-      }
-    },
-    "jsonify": {
-      "version": "0.0.0",
-      "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.0.tgz",
-      "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM="
-    },
-    "jsprim": {
-      "version": "1.4.1",
-      "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz",
-      "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=",
-      "optional": true,
-      "requires": {
-        "assert-plus": "1.0.0",
-        "extsprintf": "1.3.0",
-        "json-schema": "0.2.3",
-        "verror": "1.10.0"
-      }
+      "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz",
+      "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE="
     },
     "just-debounce": {
       "version": "1.0.0",
       "resolved": "https://registry.npmjs.org/just-debounce/-/just-debounce-1.0.0.tgz",
       "integrity": "sha1-h/zPrv/AtozRnVX2cilD+SnqNeo="
     },
-    "kew": {
-      "version": "0.7.0",
-      "resolved": "https://registry.npmjs.org/kew/-/kew-0.7.0.tgz",
-      "integrity": "sha1-edk9LTM2PW/dKXCzNdkUGtWR15s=",
-      "optional": true
-    },
-    "kind-of": {
-      "version": "6.0.2",
-      "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz",
-      "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA=="
-    },
-    "klaw": {
-      "version": "1.3.1",
-      "resolved": "https://registry.npmjs.org/klaw/-/klaw-1.3.1.tgz",
-      "integrity": "sha1-QIhDO0azsbolnXh4XY6W9zugJDk=",
-      "optional": true,
-      "requires": {
-        "graceful-fs": "^4.1.9"
-      },
-      "dependencies": {
-        "graceful-fs": {
-          "version": "4.1.11",
-          "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz",
-          "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=",
-          "optional": true
-        }
-      }
-    },
-    "last-run": {
-      "version": "1.1.1",
-      "resolved": "https://registry.npmjs.org/last-run/-/last-run-1.1.1.tgz",
-      "integrity": "sha1-RblpQsF7HHnHchmCWbqUO+v4yls=",
-      "requires": {
-        "default-resolution": "^2.0.0",
-        "es6-weak-map": "^2.0.1"
-      }
-    },
-    "lazystream": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/lazystream/-/lazystream-1.0.0.tgz",
-      "integrity": "sha1-9plf4PggOS9hOWvolGJAe7dxaOQ=",
-      "requires": {
-        "readable-stream": "^2.0.5"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
+    "kind-of": {
+      "version": "6.0.2",
+      "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz",
+      "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA=="
+    },
+    "last-run": {
+      "version": "1.1.1",
+      "resolved": "https://registry.npmjs.org/last-run/-/last-run-1.1.1.tgz",
+      "integrity": "sha1-RblpQsF7HHnHchmCWbqUO+v4yls=",
+      "requires": {
+        "default-resolution": "^2.0.0",
+        "es6-weak-map": "^2.0.1"
+      }
+    },
+    "lazystream": {
+      "version": "1.0.0",
+      "resolved": "https://registry.npmjs.org/lazystream/-/lazystream-1.0.0.tgz",
+      "integrity": "sha1-9plf4PggOS9hOWvolGJAe7dxaOQ=",
+      "requires": {
+        "readable-stream": "^2.0.5"
       }
     },
     "lcid": {
@@ -2918,12 +2373,12 @@
       }
     },
     "liftoff": {
-      "version": "2.5.0",
-      "resolved": "https://registry.npmjs.org/liftoff/-/liftoff-2.5.0.tgz",
-      "integrity": "sha1-IAkpG7Mc6oYbvxCnwVooyvdcMew=",
+      "version": "3.1.0",
+      "resolved": "https://registry.npmjs.org/liftoff/-/liftoff-3.1.0.tgz",
+      "integrity": "sha512-DlIPlJUkCV0Ips2zf2pJP0unEoT1kwYhiiPUGF3s/jtxTCjziNLoiVVh+jqWOWeFi6mmwQ5fNxvAUyPad4Dfog==",
       "requires": {
         "extend": "^3.0.0",
-        "findup-sync": "^2.0.0",
+        "findup-sync": "^3.0.0",
         "fined": "^1.0.1",
         "flagged-respawn": "^1.0.0",
         "is-plain-object": "^2.0.4",
@@ -2951,6 +2406,11 @@
         }
       }
     },
+    "lodash": {
+      "version": "4.17.11",
+      "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz",
+      "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg=="
+    },
     "lodash.assign": {
       "version": "4.2.0",
       "resolved": "https://registry.npmjs.org/lodash.assign/-/lodash.assign-4.2.0.tgz",
@@ -2961,11 +2421,6 @@
       "resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz",
       "integrity": "sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8="
     },
-    "lodash.debounce": {
-      "version": "4.0.8",
-      "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz",
-      "integrity": "sha1-gteb/zCmfEAF/9XiUVMArZyk168="
-    },
     "lodash.isobject": {
       "version": "3.0.2",
       "resolved": "https://registry.npmjs.org/lodash.isobject/-/lodash.isobject-3.0.2.tgz",
@@ -2977,9 +2432,9 @@
       "integrity": "sha512-AOYza4+Hf5z1/0Hztxpm2/xiPZgi/cjMqdnKTUWTBSKchJlxXXuUSxCCl8rJlf4g6yww/j6mA8nC8Hw/EZWxKQ=="
     },
     "make-error": {
-      "version": "1.3.4",
-      "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.4.tgz",
-      "integrity": "sha512-0Dab5btKVPhibSalc9QGXb559ED7G7iLjFXBaj9Wq8O3vorueR5K5jaE3hkG6ZQINyhA/JgG6Qk4qdFQjsYV6g=="
+      "version": "1.3.5",
+      "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.5.tgz",
+      "integrity": "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g=="
     },
     "make-error-cause": {
       "version": "1.2.2",
@@ -3019,6 +2474,27 @@
         "micromatch": "^3.0.4",
         "resolve": "^1.4.0",
         "stack-trace": "0.0.10"
+      },
+      "dependencies": {
+        "findup-sync": {
+          "version": "2.0.0",
+          "resolved": "https://registry.npmjs.org/findup-sync/-/findup-sync-2.0.0.tgz",
+          "integrity": "sha1-kyaxSIwi0aYIhlCoaQGy2akKLLw=",
+          "requires": {
+            "detect-file": "^1.0.0",
+            "is-glob": "^3.1.0",
+            "micromatch": "^3.0.4",
+            "resolve-dir": "^1.0.1"
+          }
+        },
+        "is-glob": {
+          "version": "3.1.0",
+          "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz",
+          "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=",
+          "requires": {
+            "is-extglob": "^2.1.0"
+          }
+        }
       }
     },
     "micromatch": {
@@ -3041,19 +2517,6 @@
         "to-regex": "^3.0.2"
       }
     },
-    "mime-db": {
-      "version": "1.35.0",
-      "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.35.0.tgz",
-      "integrity": "sha512-JWT/IcCTsB0Io3AhWUMjRqucrHSPsSf2xKLaRldJVULioggvkJvggZ3VXNNSRkCddE6D+BUI4HEIZIA2OjwIvg=="
-    },
-    "mime-types": {
-      "version": "2.1.19",
-      "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.19.tgz",
-      "integrity": "sha512-P1tKYHVSZ6uFo26mtnve4HQFE3koh1UWVkp8YUC+ESBHe945xWSoXuHHiGarDqcEZ+whpCDnlNw5LON0kLo+sw==",
-      "requires": {
-        "mime-db": "~1.35.0"
-      }
-    },
     "minimatch": {
       "version": "3.0.4",
       "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
@@ -3081,37 +2544,20 @@
         }
       }
     },
-    "mkdirp": {
-      "version": "0.5.1",
-      "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
-      "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
-      "optional": true,
-      "requires": {
-        "minimist": "0.0.8"
-      },
-      "dependencies": {
-        "minimist": {
-          "version": "0.0.8",
-          "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
-          "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
-          "optional": true
-        }
-      }
-    },
     "ms": {
       "version": "2.0.0",
       "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
       "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
     },
     "mute-stdout": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/mute-stdout/-/mute-stdout-1.0.0.tgz",
-      "integrity": "sha1-WzLqB+tDyd7WEwQ0z5JvRrKn/U0="
+      "version": "1.0.1",
+      "resolved": "https://registry.npmjs.org/mute-stdout/-/mute-stdout-1.0.1.tgz",
+      "integrity": "sha512-kDcwXR4PS7caBpuRYYBUz9iVixUk3anO3f5OYFiIPwK/20vCzKCHyKoulbiDY1S53zD2bxUpxN/IJ+TnXjfvxg=="
     },
     "nan": {
-      "version": "2.10.0",
-      "resolved": "https://registry.npmjs.org/nan/-/nan-2.10.0.tgz",
-      "integrity": "sha512-bAdJv7fBLhWC+/Bls0Oza+mvTaNQtP+1RyhhhvD95pgUJz6XM5IzgmxOkItJ9tkoCiplvAnXI1tNmmUD/eScyA==",
+      "version": "2.14.0",
+      "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz",
+      "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==",
       "optional": true
     },
     "nanomatch": {
@@ -3138,12 +2584,12 @@
       "integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw="
     },
     "normalize-package-data": {
-      "version": "2.4.0",
-      "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.4.0.tgz",
-      "integrity": "sha512-9jjUFbTPfEy3R/ad/2oNbKtW9Hgovl5O1FvFWKkKblNXoN/Oou6+9+KKohPK13Yc3/TyunyWhJp6gvRNR/PPAw==",
+      "version": "2.5.0",
+      "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz",
+      "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==",
       "requires": {
         "hosted-git-info": "^2.1.4",
-        "is-builtin-module": "^1.0.0",
+        "resolve": "^1.10.0",
         "semver": "2 || 3 || 4 || 5",
         "validate-npm-package-license": "^3.0.1"
       }
@@ -3162,9 +2608,9 @@
       "integrity": "sha1-LRDAa9/TEuqXd2laTShDlFa3WUI="
     },
     "now-and-later": {
-      "version": "2.0.0",
-      "resolved": "https://registry.npmjs.org/now-and-later/-/now-and-later-2.0.0.tgz",
-      "integrity": "sha1-vGHLtFbXnLMiB85HygUTb/Ln1u4=",
+      "version": "2.0.1",
+      "resolved": "https://registry.npmjs.org/now-and-later/-/now-and-later-2.0.1.tgz",
+      "integrity": "sha512-KGvQ0cB70AQfg107Xvs/Fbu+dGmZoTRJp2TaPwcwQm3/7PteUyN2BCgk8KBMPGBUXZdVwyWS8fDCGFygBm19UQ==",
       "requires": {
         "once": "^1.3.2"
       }
@@ -3179,12 +2625,6 @@
       "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz",
       "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0="
     },
-    "oauth-sign": {
-      "version": "0.9.0",
-      "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz",
-      "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==",
-      "optional": true
-    },
     "object-assign": {
       "version": "4.1.1",
       "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
@@ -3219,9 +2659,9 @@
       }
     },
     "object-keys": {
-      "version": "1.0.12",
-      "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.0.12.tgz",
-      "integrity": "sha512-FTMyFUm2wBcGHnH2eXmz7tC6IwlqQZ6mVZ+6dm6vZ4IQIHjs6FdNsQBuKGPuUUUY6NfJw2PshC08Tn6LzLDOag=="
+      "version": "1.1.1",
+      "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz",
+      "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA=="
     },
     "object-visit": {
       "version": "1.0.1",
@@ -3293,35 +2733,6 @@
       "integrity": "sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4=",
       "requires": {
         "readable-stream": "^2.0.1"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
       }
     },
     "os-locale": {
@@ -3423,46 +2834,6 @@
         }
       }
     },
-    "pend": {
-      "version": "1.2.0",
-      "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz",
-      "integrity": "sha1-elfrVQpng/kRUzH89GY9XI4AelA=",
-      "optional": true
-    },
-    "performance-now": {
-      "version": "2.1.0",
-      "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz",
-      "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=",
-      "optional": true
-    },
-    "phantom": {
-      "version": "4.0.12",
-      "resolved": "https://registry.npmjs.org/phantom/-/phantom-4.0.12.tgz",
-      "integrity": "sha512-Tz82XhtPmwCk1FFPmecy7yRGZG2btpzY2KI9fcoPT7zT9det0CcMyfBFPp1S8DqzsnQnm8ZYEfdy528mwVtksA==",
-      "optional": true,
-      "requires": {
-        "phantomjs-prebuilt": "^2.1.16",
-        "split": "^1.0.1",
-        "winston": "^2.4.0"
-      }
-    },
-    "phantomjs-prebuilt": {
-      "version": "2.1.16",
-      "resolved": "https://registry.npmjs.org/phantomjs-prebuilt/-/phantomjs-prebuilt-2.1.16.tgz",
-      "integrity": "sha1-79ISpKOWbTZHaE6ouniFSb4q7+8=",
-      "optional": true,
-      "requires": {
-        "es6-promise": "^4.0.3",
-        "extract-zip": "^1.6.5",
-        "fs-extra": "^1.0.0",
-        "hasha": "^2.2.0",
-        "kew": "^0.7.0",
-        "progress": "^1.1.8",
-        "request": "^2.81.0",
-        "request-progress": "^2.0.1",
-        "which": "^1.2.10"
-      }
-    },
     "pify": {
       "version": "3.0.0",
       "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz",
@@ -3555,18 +2926,6 @@
       "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz",
       "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw=="
     },
-    "progress": {
-      "version": "1.1.8",
-      "resolved": "https://registry.npmjs.org/progress/-/progress-1.1.8.tgz",
-      "integrity": "sha1-4mDHj2Fhzdmw5WzD4Khd4Xx6V74=",
-      "optional": true
-    },
-    "psl": {
-      "version": "1.1.29",
-      "resolved": "https://registry.npmjs.org/psl/-/psl-1.1.29.tgz",
-      "integrity": "sha512-AeUmQ0oLN02flVHXWh9sSJF7mcdFq0ppid/JkErufc3hGIV/AMa8Fo9VgDo/cT2jFdOWoFvHp90qqBH54W+gjQ==",
-      "optional": true
-    },
     "pump": {
       "version": "2.0.1",
       "resolved": "https://registry.npmjs.org/pump/-/pump-2.0.1.tgz",
@@ -3586,18 +2945,6 @@
         "pump": "^2.0.0"
       }
     },
-    "punycode": {
-      "version": "1.4.1",
-      "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz",
-      "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=",
-      "optional": true
-    },
-    "qs": {
-      "version": "6.5.2",
-      "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz",
-      "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==",
-      "optional": true
-    },
     "rcfinder": {
       "version": "0.1.9",
       "resolved": "https://registry.npmjs.org/rcfinder/-/rcfinder-0.1.9.tgz",
@@ -3637,54 +2984,27 @@
       }
     },
     "readable-stream": {
-      "version": "1.1.14",
-      "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz",
-      "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=",
+      "version": "2.3.6",
+      "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
+      "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
       "requires": {
         "core-util-is": "~1.0.0",
-        "inherits": "~2.0.1",
-        "isarray": "0.0.1",
-        "string_decoder": "~0.10.x"
+        "inherits": "~2.0.3",
+        "isarray": "~1.0.0",
+        "process-nextick-args": "~2.0.0",
+        "safe-buffer": "~5.1.1",
+        "string_decoder": "~1.1.1",
+        "util-deprecate": "~1.0.1"
       }
     },
     "readdirp": {
-      "version": "2.1.0",
-      "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.1.0.tgz",
-      "integrity": "sha1-TtCtBg3zBzMAxIRANz9y0cxkLXg=",
+      "version": "2.2.1",
+      "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.2.1.tgz",
+      "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==",
       "requires": {
-        "graceful-fs": "^4.1.2",
-        "minimatch": "^3.0.2",
-        "readable-stream": "^2.0.2",
-        "set-immediate-shim": "^1.0.1"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
+        "graceful-fs": "^4.1.11",
+        "micromatch": "^3.1.10",
+        "readable-stream": "^2.0.2"
       }
     },
     "rechoir": {
@@ -3729,9 +3049,9 @@
       "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8="
     },
     "repeat-element": {
-      "version": "1.1.2",
-      "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.2.tgz",
-      "integrity": "sha1-7wiaF40Ug7quTZPrmLT55OEdmQo="
+      "version": "1.1.3",
+      "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.3.tgz",
+      "integrity": "sha512-ahGq0ZnV5m5XtZLMb+vP76kcAM5nkLqk0lpqAuojSKGgQtn4eRi4ZZGm2olo2zKFH+sMsWaqOCW1dqAnOru72g=="
     },
     "repeat-string": {
       "version": "1.6.1",
@@ -3797,43 +3117,6 @@
         }
       }
     },
-    "request": {
-      "version": "2.88.0",
-      "resolved": "https://registry.npmjs.org/request/-/request-2.88.0.tgz",
-      "integrity": "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==",
-      "optional": true,
-      "requires": {
-        "aws-sign2": "~0.7.0",
-        "aws4": "^1.8.0",
-        "caseless": "~0.12.0",
-        "combined-stream": "~1.0.6",
-        "extend": "~3.0.2",
-        "forever-agent": "~0.6.1",
-        "form-data": "~2.3.2",
-        "har-validator": "~5.1.0",
-        "http-signature": "~1.2.0",
-        "is-typedarray": "~1.0.0",
-        "isstream": "~0.1.2",
-        "json-stringify-safe": "~5.0.1",
-        "mime-types": "~2.1.19",
-        "oauth-sign": "~0.9.0",
-        "performance-now": "^2.1.0",
-        "qs": "~6.5.2",
-        "safe-buffer": "^5.1.2",
-        "tough-cookie": "~2.4.3",
-        "tunnel-agent": "^0.6.0",
-        "uuid": "^3.3.2"
-      }
-    },
-    "request-progress": {
-      "version": "2.0.1",
-      "resolved": "https://registry.npmjs.org/request-progress/-/request-progress-2.0.1.tgz",
-      "integrity": "sha1-XTa7V5YcZzqlt4jbyBQf3yO0Tgg=",
-      "optional": true,
-      "requires": {
-        "throttleit": "^1.0.0"
-      }
-    },
     "require-directory": {
       "version": "2.1.1",
       "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
@@ -3845,11 +3128,11 @@
       "integrity": "sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE="
     },
     "resolve": {
-      "version": "1.8.1",
-      "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.8.1.tgz",
-      "integrity": "sha512-AicPrAC7Qu1JxPCZ9ZgCZlY35QgFnNqc+0LtbRNxnVw4TXvjQ72wnuL9JQcEBgXkI9JM8MsT9kaQoHcpCRJOYA==",
+      "version": "1.11.1",
+      "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.11.1.tgz",
+      "integrity": "sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw==",
       "requires": {
-        "path-parse": "^1.0.5"
+        "path-parse": "^1.0.6"
       }
     },
     "resolve-dir": {
@@ -3923,15 +3206,10 @@
         "ret": "~0.1.10"
       }
     },
-    "safer-buffer": {
-      "version": "2.1.2",
-      "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
-      "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
-    },
     "semver": {
-      "version": "5.5.0",
-      "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz",
-      "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA=="
+      "version": "5.7.0",
+      "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz",
+      "integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA=="
     },
     "semver-greatest-satisfied-range": {
       "version": "1.1.0",
@@ -3946,11 +3224,6 @@
       "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz",
       "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc="
     },
-    "set-immediate-shim": {
-      "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz",
-      "integrity": "sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E="
-    },
     "set-value": {
       "version": "2.0.0",
       "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.0.tgz",
@@ -4102,18 +3375,18 @@
       "integrity": "sha512-dSO0DDYUahUt/0/pD/Is3VIm5TGJjludZ0HVymmhYF6eNA53PVLhnUk0znSYbH8IYBuJdCE+1luR22jNLMaQdw=="
     },
     "spdx-correct": {
-      "version": "3.0.0",
-      "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.0.0.tgz",
-      "integrity": "sha512-N19o9z5cEyc8yQQPukRCZ9EUmb4HUpnrmaL/fxS2pBo2jbfcFRVuFZ/oFC+vZz0MNNk0h80iMn5/S6qGZOL5+g==",
+      "version": "3.1.0",
+      "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz",
+      "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==",
       "requires": {
         "spdx-expression-parse": "^3.0.0",
         "spdx-license-ids": "^3.0.0"
       }
     },
     "spdx-exceptions": {
-      "version": "2.1.0",
-      "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.1.0.tgz",
-      "integrity": "sha512-4K1NsmrlCU1JJgUrtgEeTVyfx8VaYea9J9LvARxhbHtVtohPs/gFGG5yy49beySjlIMhhXZ4QqujIZEfS4l6Cg=="
+      "version": "2.2.0",
+      "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz",
+      "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA=="
     },
     "spdx-expression-parse": {
       "version": "3.0.0",
@@ -4125,18 +3398,9 @@
       }
     },
     "spdx-license-ids": {
-      "version": "3.0.0",
-      "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz",
-      "integrity": "sha512-2+EPwgbnmOIl8HjGBXXMd9NAu02vLjOO1nWw4kmeRDFyHn+M/ETfHxQUK0oXg8ctgVnl9t3rosNVsZ1jG61nDA=="
-    },
-    "split": {
-      "version": "1.0.1",
-      "resolved": "https://registry.npmjs.org/split/-/split-1.0.1.tgz",
-      "integrity": "sha512-mTyOoPbrivtXnwnIxZRFYRrPNtEFKlpB2fvjSnCQUiAA6qAZzqwna5envK4uk6OIeP17CsdF3rSBGYVBsU0Tkg==",
-      "optional": true,
-      "requires": {
-        "through": "2"
-      }
+      "version": "3.0.4",
+      "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz",
+      "integrity": "sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA=="
     },
     "split-string": {
       "version": "3.1.0",
@@ -4146,23 +3410,6 @@
         "extend-shallow": "^3.0.0"
       }
     },
-    "sshpk": {
-      "version": "1.14.2",
-      "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.14.2.tgz",
-      "integrity": "sha1-xvxhZIo9nE52T9P8306hBeSSupg=",
-      "optional": true,
-      "requires": {
-        "asn1": "~0.2.3",
-        "assert-plus": "^1.0.0",
-        "bcrypt-pbkdf": "^1.0.0",
-        "dashdash": "^1.12.0",
-        "ecc-jsbn": "~0.1.1",
-        "getpass": "^0.1.1",
-        "jsbn": "~0.1.0",
-        "safer-buffer": "^2.0.2",
-        "tweetnacl": "~0.14.0"
-      }
-    },
     "stack-trace": {
       "version": "0.0.10",
       "resolved": "https://registry.npmjs.org/stack-trace/-/stack-trace-0.0.10.tgz",
@@ -4208,9 +3455,12 @@
       }
     },
     "string_decoder": {
-      "version": "0.10.31",
-      "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz",
-      "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ="
+      "version": "1.1.1",
+      "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
+      "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
+      "requires": {
+        "safe-buffer": "~5.1.0"
+      }
     },
     "strip-ansi": {
       "version": "3.0.1",
@@ -4247,18 +3497,6 @@
       "resolved": "https://registry.npmjs.org/textextensions/-/textextensions-2.2.0.tgz",
       "integrity": "sha512-j5EMxnryTvKxwH2Cq+Pb43tsf6sdEgw6Pdwxk83mPaq0ToeFJt6WE4J3s5BqY7vmjlLgkgXvhtXUxo80FyBhCA=="
     },
-    "throttleit": {
-      "version": "1.0.0",
-      "resolved": "https://registry.npmjs.org/throttleit/-/throttleit-1.0.0.tgz",
-      "integrity": "sha1-nnhYNtr0Z0MUWlmEtiaNgoUorGw=",
-      "optional": true
-    },
-    "through": {
-      "version": "2.3.8",
-      "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
-      "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=",
-      "optional": true
-    },
     "through2": {
       "version": "2.0.3",
       "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz",
@@ -4298,9 +3536,9 @@
       }
     },
     "through2-filter": {
-      "version": "2.0.0",
-      "resolved": "https://registry.npmjs.org/through2-filter/-/through2-filter-2.0.0.tgz",
-      "integrity": "sha1-YLxVoNrLdghdsfna6Zq0P4PWIuw=",
+      "version": "3.0.0",
+      "resolved": "https://registry.npmjs.org/through2-filter/-/through2-filter-3.0.0.tgz",
+      "integrity": "sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA==",
       "requires": {
         "through2": "~2.0.0",
         "xtend": "~4.0.0"
@@ -4366,30 +3604,10 @@
         "through2": "^2.0.3"
       }
     },
-    "tough-cookie": {
-      "version": "2.4.3",
-      "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz",
-      "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==",
-      "optional": true,
-      "requires": {
-        "psl": "^1.1.24",
-        "punycode": "^1.4.1"
-      }
-    },
-    "tunnel-agent": {
-      "version": "0.6.0",
-      "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz",
-      "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=",
-      "optional": true,
-      "requires": {
-        "safe-buffer": "^5.0.1"
-      }
-    },
-    "tweetnacl": {
-      "version": "0.14.5",
-      "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz",
-      "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=",
-      "optional": true
+    "type": {
+      "version": "1.0.1",
+      "resolved": "https://registry.npmjs.org/type/-/type-1.0.1.tgz",
+      "integrity": "sha512-MAM5dBMJCJNKs9E7JXo4CXRAansRfG0nlJxW7Wf6GZzSOvH31zClSaHdIMWLehe/EGMBkqeC55rrkaOr5Oo7Nw=="
     },
     "typedarray": {
       "version": "0.0.6",
@@ -4397,11 +3615,11 @@
       "integrity": "sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c="
     },
     "uglify-js": {
-      "version": "3.4.7",
-      "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.4.7.tgz",
-      "integrity": "sha512-J0M2i1mQA+ze3EdN9SBi751DNdAXmeFLfJrd/MDIkRc3G3Gbb9OPVSx7GIQvVwfWxQARcYV2DTxIkMyDAk3o9Q==",
+      "version": "3.6.0",
+      "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.6.0.tgz",
+      "integrity": "sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg==",
       "requires": {
-        "commander": "~2.16.0",
+        "commander": "~2.20.0",
         "source-map": "~0.6.1"
       },
       "dependencies": {
@@ -4418,9 +3636,9 @@
       "integrity": "sha1-5z3T17DXxe2G+6xrCufYxqadUPo="
     },
     "undertaker": {
-      "version": "1.2.0",
-      "resolved": "https://registry.npmjs.org/undertaker/-/undertaker-1.2.0.tgz",
-      "integrity": "sha1-M52kZGJS0ILcN45wgGcpl1DhG0k=",
+      "version": "1.2.1",
+      "resolved": "https://registry.npmjs.org/undertaker/-/undertaker-1.2.1.tgz",
+      "integrity": "sha512-71WxIzDkgYk9ZS+spIB8iZXchFhAdEo2YU8xYqBYJ39DIUIqziK78ftm26eecoIY49X0J2MLhG4hr18Yp6/CMA==",
       "requires": {
         "arr-flatten": "^1.0.1",
         "arr-map": "^2.0.0",
@@ -4438,11 +3656,6 @@
       "resolved": "https://registry.npmjs.org/undertaker-registry/-/undertaker-registry-1.0.1.tgz",
       "integrity": "sha1-XkvaMI5KiirlhPm5pDWaSZglzFA="
     },
-    "unicode-5.2.0": {
-      "version": "0.7.5",
-      "resolved": "https://registry.npmjs.org/unicode-5.2.0/-/unicode-5.2.0-0.7.5.tgz",
-      "integrity": "sha512-KVGLW1Bri30x00yv4HNM8kBxoqFXr0Sbo55735nvrlsx4PYBZol3UtoWgO492fSwmsetzPEZzy73rbU8OGXJcA=="
-    },
     "union-value": {
       "version": "1.0.0",
       "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.0.tgz",
@@ -4476,12 +3689,12 @@
       }
     },
     "unique-stream": {
-      "version": "2.2.1",
-      "resolved": "https://registry.npmjs.org/unique-stream/-/unique-stream-2.2.1.tgz",
-      "integrity": "sha1-WqADz76Uxf+GbE59ZouxxNuts2k=",
+      "version": "2.3.1",
+      "resolved": "https://registry.npmjs.org/unique-stream/-/unique-stream-2.3.1.tgz",
+      "integrity": "sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A==",
       "requires": {
-        "json-stable-stringify": "^1.0.0",
-        "through2-filter": "^2.0.0"
+        "json-stable-stringify-without-jsonify": "^1.0.1",
+        "through2-filter": "^3.0.0"
       }
     },
     "unset-value": {
@@ -4517,18 +3730,13 @@
           "version": "0.1.4",
           "resolved": "https://registry.npmjs.org/has-values/-/has-values-0.1.4.tgz",
           "integrity": "sha1-bWHeldkd/Km5oCCJrThL/49it3E="
-        },
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
         }
       }
     },
     "upath": {
-      "version": "1.1.0",
-      "resolved": "https://registry.npmjs.org/upath/-/upath-1.1.0.tgz",
-      "integrity": "sha512-bzpH/oBhoS/QI/YtbkqCg6VEiPYjSZtrHQM6/QnJS6OL9pKUFLqb3aFh4Scvwm45+7iAgiMkLhSbaZxUqmrprw=="
+      "version": "1.1.2",
+      "resolved": "https://registry.npmjs.org/upath/-/upath-1.1.2.tgz",
+      "integrity": "sha512-kXpym8nmDmlCBr7nKdIx8P2jNBa+pBpIUFRnKJ4dr8htyYGJFokkr2ZvERRtUN+9SY+JqXouNgUPtv6JQva/2Q=="
     },
     "urix": {
       "version": "0.1.0",
@@ -4545,16 +3753,10 @@
       "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
       "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
     },
-    "uuid": {
-      "version": "3.3.2",
-      "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz",
-      "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==",
-      "optional": true
-    },
     "v8flags": {
-      "version": "3.1.1",
-      "resolved": "https://registry.npmjs.org/v8flags/-/v8flags-3.1.1.tgz",
-      "integrity": "sha512-iw/1ViSEaff8NJ3HLyEjawk/8hjJib3E7pvG4pddVXfUg1983s3VGsiClDjhK64MQVDGqc1Q8r18S4VKQZS9EQ==",
+      "version": "3.1.3",
+      "resolved": "https://registry.npmjs.org/v8flags/-/v8flags-3.1.3.tgz",
+      "integrity": "sha512-amh9CCg3ZxkzQ48Mhcb8iX7xpAfYJgePHxWMQCBWECpOSqJUXgY26ncA61UTV0BkPqfhcy6mzwCIoP4ygxpW8w==",
       "requires": {
         "homedir-polyfill": "^1.0.1"
       }
@@ -4573,17 +3775,6 @@
       "resolved": "https://registry.npmjs.org/value-or-function/-/value-or-function-3.0.0.tgz",
       "integrity": "sha1-HCQ6ULWVwb5Up1S/7OhWO5/42BM="
     },
-    "verror": {
-      "version": "1.10.0",
-      "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz",
-      "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=",
-      "optional": true,
-      "requires": {
-        "assert-plus": "^1.0.0",
-        "core-util-is": "1.0.2",
-        "extsprintf": "^1.2.0"
-      }
-    },
     "vinyl": {
       "version": "2.2.0",
       "resolved": "https://registry.npmjs.org/vinyl/-/vinyl-2.2.0.tgz",
@@ -4619,35 +3810,6 @@
         "value-or-function": "^3.0.0",
         "vinyl": "^2.0.0",
         "vinyl-sourcemap": "^1.1.0"
-      },
-      "dependencies": {
-        "isarray": {
-          "version": "1.0.0",
-          "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
-          "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
-        },
-        "readable-stream": {
-          "version": "2.3.6",
-          "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
-          "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
-          "requires": {
-            "core-util-is": "~1.0.0",
-            "inherits": "~2.0.3",
-            "isarray": "~1.0.0",
-            "process-nextick-args": "~2.0.0",
-            "safe-buffer": "~5.1.1",
-            "string_decoder": "~1.1.1",
-            "util-deprecate": "~1.0.1"
-          }
-        },
-        "string_decoder": {
-          "version": "1.1.1",
-          "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
-          "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-          "requires": {
-            "safe-buffer": "~5.1.0"
-          }
-        }
       }
     },
     "vinyl-sourcemap": {
@@ -4685,20 +3847,6 @@
       "resolved": "https://registry.npmjs.org/which-module/-/which-module-1.0.0.tgz",
       "integrity": "sha1-u6Y8qGGUiZT/MHc2CJ47lgJsKk8="
     },
-    "winston": {
-      "version": "2.4.3",
-      "resolved": "https://registry.npmjs.org/winston/-/winston-2.4.3.tgz",
-      "integrity": "sha512-GYKuysPz2pxYAVJD2NPsDLP5Z79SDEzPm9/j4tCjkF/n89iBNGBMJcR+dMUqxgPNgoSs6fVygPi+Vl2oxIpBuw==",
-      "optional": true,
-      "requires": {
-        "async": "~1.0.0",
-        "colors": "1.0.x",
-        "cycle": "1.0.x",
-        "eyes": "0.1.x",
-        "isstream": "0.1.x",
-        "stack-trace": "0.0.x"
-      }
-    },
     "wrap-ansi": {
       "version": "2.1.0",
       "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
@@ -4750,15 +3898,6 @@
       "requires": {
         "camelcase": "^3.0.0"
       }
-    },
-    "yauzl": {
-      "version": "2.4.1",
-      "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.4.1.tgz",
-      "integrity": "sha1-lSj0QtqxsihOWLQ3m7GU4i4MQAU=",
-      "optional": true,
-      "requires": {
-        "fd-slicer": "~1.0.1"
-      }
     }
   }
 }
diff --git a/package.json b/package.json
index da37871..f3a288d 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "harlowe-audio",
-  "version": "1.0.0",
+  "version": "1.3.0",
   "description": "Audio library for Twine2/Harlowe2.",
   "main": "gulpfile.js",
   "directories": {
@@ -9,19 +9,19 @@
   },
   "dependencies": {
     "del": "^3.0.0",
-    "gulp": "^4.0.0",
+    "gulp": "^4.0.2",
     "gulp-autoprefixer": "^5.0.0",
     "gulp-clean-css": "^3.10.0",
     "gulp-concat": "^2.6.1",
     "gulp-jshint": "^2.1.0",
     "gulp-rename": "^1.4.0",
     "gulp-replace": "^1.0.0",
-    "gulp-uglify": "^3.0.1",
-    "jshint": "^2.9.6"
+    "gulp-uglify": "^3.0.2",
+    "jshint": "^2.10.2"
   },
   "devDependencies": {},
   "scripts": {
-    "test": "tweego -f harlowe-2 --head=test/head.html -o test/index.html dist test/twee && start test/index.html",
+    "test": "tweego -f harlowe-3 --head=test/head.html -o test/index.html dist test/twee && start test/index.html",
     "gulp": "gulp",
     "clean": "gulp clean",
     "build": "gulp build",
diff --git a/src/overlay.css b/src/css/overlay.css
similarity index 100%
rename from src/overlay.css
rename to src/css/overlay.css
diff --git a/src/panel.css b/src/css/panel.css
similarity index 100%
rename from src/panel.css
rename to src/css/panel.css
diff --git a/src/audio.js b/src/js/audio.js
similarity index 99%
rename from src/audio.js
rename to src/js/audio.js
index d533fc8..ec73d18 100644
--- a/src/audio.js
+++ b/src/js/audio.js
@@ -557,7 +557,7 @@
             }
             this.$el.on(type, cb);
         },
-        one : function () {
+        one : function (type, cb) {
             if (!cb || typeof cb !== 'function') {
                 console.error('<track>.one() -> invalid callback');
                 return this;
diff --git a/src/controlpanel.js b/src/js/controlpanel.js
similarity index 100%
rename from src/controlpanel.js
rename to src/js/controlpanel.js
diff --git a/src/detect.js b/src/js/detect.js
similarity index 100%
rename from src/detect.js
rename to src/js/detect.js
diff --git a/src/js/fixes.js b/src/js/fixes.js
new file mode 100644
index 0000000..0fbcd79
--- /dev/null
+++ b/src/js/fixes.js
@@ -0,0 +1,24 @@
+(function () {
+    'use strict';
+
+    // fix prompt injection
+
+    function isHTML(str) {
+        var doc = new DOMParser().parseFromString(str, "text/html");
+        return Array.from(doc.body.childNodes).some( function (node) { return node.nodeType === 1; });
+    }
+
+    if (options.includeFixes) {
+        var cached = window.prompt;
+
+        window.prompt = function () {
+            var result = cached.apply(null, [].slice.call(arguments));
+            if (isHTML(result)) {
+                return (result.replace(/[<>]/g, ''));
+            } else {
+                return result;
+            }
+        };
+    }
+
+}());
\ No newline at end of file
diff --git a/src/js/get.js b/src/js/get.js
new file mode 100644
index 0000000..a0f2bd1
--- /dev/null
+++ b/src/js/get.js
@@ -0,0 +1,43 @@
+(function () {
+    'use strict';
+
+    // pull data from the data chunk for use elsewhere
+
+    var $dataChunk = $('tw-storydata');
+
+    function getHarloweVersion () {
+        var semVer = $dataChunk.attr('format-version');
+        var major = semVer.split('.')[0];
+        major = Number(major);
+        if (Number.isNaN(major)) {
+            major = 3;
+        }
+        if (major < 1) {
+            major = 3;
+        }
+        return major;
+    }
+
+    function version3OrLater () {
+        return getHarloweVersion() >= 3;
+    }
+
+    function getStoryTitle () {
+        return $dataChunk.attr('name');
+    }
+
+    function getStoryIFID () {
+        return $dataChunk.attr('ifid');
+    }
+
+    window.Chapel = window.Chapel || {};
+
+    window.Chapel.Get = {
+        isHarlowe3OrLater : version3OrLater(),
+        storyTitle : getStoryTitle(),
+        IFID : getStoryIFID()
+    };
+
+    // set storage key for this story with IFID + Story Title
+    options.storagekey = options.storagekey + '-' + Chapel.Get.IFID + '-{' + Chapel.Get.storyTitle + '}';
+}());
\ No newline at end of file
diff --git a/src/preload.js b/src/js/preload.js
similarity index 100%
rename from src/preload.js
rename to src/js/preload.js
diff --git a/src/js/setup.js b/src/js/setup.js
new file mode 100644
index 0000000..b8a6c6a
--- /dev/null
+++ b/src/js/setup.js
@@ -0,0 +1,31 @@
+(function () {
+    'use strict';
+
+    if (options.globalA && window.A === undefined) {
+        window.A = window.Chapel.Audio;
+    }
+
+    $(document).on('unload', function () {
+        window.Chapel.Audio.savePrefs();
+    });
+
+    Chapel.Audio.classes.Track.renew();
+    if (Chapel.Audio.controls) {
+        Chapel.Audio.controls.updateVolume();
+    }
+
+    if (Chapel.Get.isHarlowe3OrLater) {
+        $(window).on('unload', function () {
+            // save tracks to session storage
+            Chapel.Audio.state.saveTracks();
+            Chapel.Audio.state.savePlaylists();
+            Chapel.Audio.state.saveGroups();
+        });
+
+        // reload any tracks in session storage on start-up
+        Chapel.Audio.state.loadTracks();
+        Chapel.Audio.state.loadPlaylists();
+        Chapel.Audio.state.loadGroups();
+    }
+
+}());
\ No newline at end of file
diff --git a/src/js/state.js b/src/js/state.js
new file mode 100644
index 0000000..04df2bc
--- /dev/null
+++ b/src/js/state.js
@@ -0,0 +1,159 @@
+(function () {
+    'use strict';
+
+    // save the state to reload it on restarts...
+    // load script just before setup.js
+
+    var _key = options.storagekey + '_hal_restart_';
+    var _store = (function () {
+        var save, load;
+        if (window.sessionStorage) {
+            save = function (key, data) {
+                window.sessionStorage.setItem(_key + key, data);
+            };
+            load = function (key) {
+                return window.sessionStorage.getItem(_key + key);
+            };
+        } else {
+            save = function () { /* no op */ };
+            load = function () { /* no op */ };
+            console.warn('Session storage is unavailable...');
+        }
+        return {
+            save : save,
+            load : load
+        };
+    }());
+
+    // tracks
+
+    function saveTracks () {
+        var data;
+        try {
+            data = Chapel.Audio.classes.Track.list.map( function (track) {
+                return {
+                    id : track.id,
+                    sources : track.sources
+                };
+            });
+            data = JSON.stringify(data);
+            _store.save('tracks', data);
+        } catch (err) {
+            console.error(err.message);
+        }
+    }
+
+    function loadTracks () {
+        // reprocess all track data
+        var data;
+        try {
+            data = _store.load('tracks');
+            if (data) {
+                data = JSON.parse(data);
+            }
+            if (Array.isArray(data) && data.length) {
+                data.forEach( function (def) {
+                    if (def.id && def.sources && !Chapel.Audio.classes.Track.has(def.id)) {
+                        Chapel.Audio.newTrack.apply(null, [def.id].concat(def.sources));
+                    } else {
+                        console.warn('Track reload failed...');
+                    }
+                });
+            }
+        } catch (err) {
+            console.error(err.message);
+        }
+    }
+
+    // playlists
+
+    function savePlaylists () {
+        var data;
+        try {
+            var plList = Chapel.Audio.classes.Playlist.list;
+            data = Object.keys(plList).map( function (pl) {
+                var obj = {};
+                obj.tracks = plList[pl].tracks.map( function (tr) {
+                    return tr.id;
+                });
+                obj.id = plList[pl].id;
+                return obj;
+            });
+            data = JSON.stringify(data);
+            _store.save('playlists', data);
+        } catch (err) {
+            console.error(err.message);
+        }
+    }
+
+    function loadPlaylists () {
+        var data;
+        try {
+            data = _store.load('playlists');
+            if (data) {
+                data = JSON.parse(data);
+            }
+            if (data && Array.isArray(data) && data.length) {
+                data.forEach( function (def) {
+                    if (def.id && def.tracks) {
+                        Chapel.Audio.createPlaylist(def.id, def.tracks);
+                    }
+                });
+            }
+        } catch (err) {
+            console.error(err.message);
+        }
+    }
+
+    // custom groups
+
+    function saveGroups () {
+        var data;
+        try {
+            data = {};
+            Object.keys(Chapel.Audio.groups.custom).forEach( function (gr) {
+                data[gr] = Chapel.Audio.groups.custom[gr].map( function (tr) {
+                    if (typeof tr === 'string') {
+                        return tr;
+                    }
+                    return tr.id;
+                });
+            });
+            data = JSON.stringify(data);
+            _store.save('groups', data);
+        } catch (err) {
+            console.error(err.message);
+        }
+    }
+
+    function loadGroups () {
+        var data;
+        try {
+            data = _store.load('groups');
+            if (data) {
+                data = JSON.parse(data);
+            }
+            if (data && typeof data === 'object') {
+                Object.keys(data).forEach( function (gr) {
+                    data[gr].map( function (tr) {
+                        return Chapel.Audio.classes.Track.get(tr);
+                    });
+                });
+                Chapel.Audio.groups.custom = data;
+            }
+        } catch (err) {
+            console.error(err.message);
+        }
+    }
+
+    window.Chapel.Audio.state = {
+        _store : _store,
+        saveTracks : saveTracks,
+        loadTracks : loadTracks,
+        savePlaylists : savePlaylists,
+        loadPlaylists : loadPlaylists,
+        saveGroups : saveGroups,
+        loadGroups : loadGroups
+    };
+
+}());
\ No newline at end of file
diff --git a/src/userland.js b/src/js/userland.js
similarity index 100%
rename from src/userland.js
rename to src/js/userland.js
diff --git a/src/setup.js b/src/setup.js
deleted file mode 100644
index faf9a1a..0000000
--- a/src/setup.js
+++ /dev/null
@@ -1,17 +0,0 @@
-(function () {
-    'use strict';
-
-    if (options.globalA && window.A === undefined) {
-        window.A = window.Chapel.Audio;
-    }
-
-    $(document).on('unload', function () {
-        window.Chapel.Audio.savePrefs();
-    });
-
-    Chapel.Audio.classes.Track.renew();
-    if (Chapel.Audio.controls) {
-        Chapel.Audio.controls.updateVolume();
-    }
-
-}());
\ No newline at end of file
diff --git a/src/wrap/min.js b/src/wrap/min.js
deleted file mode 100644
index 81722bd..0000000
--- a/src/wrap/min.js
+++ /dev/null
@@ -1 +0,0 @@
-!function(){"use strict";var e=$(document.createElement("div")).attr("id","audio-container").css("display","none").appendTo(document.body),t=function(t,e){if(window.localStorage)try{t=""+t,"string"!=typeof e&&(e=JSON.stringify(e)),window.localStorage.setItem(t,e)}catch(t){console.error(t)}},o=function(t){if(window.localStorage)try{return t=""+t,window.localStorage.getItem(t)}catch(t){console.error(t)}},n=function(t){if(window.localStorage)try{t=""+t,window.localStorage.removeItem(t)}catch(t){console.error(t)}};function i(e,o){if("object"!=typeof e||"object"!=typeof o)throw new Error("Invalid extension.");Object.keys(o).forEach(function(t){if(void 0!==e[t])throw new Error('Invalid extension: cannot clobber existing property "'+t+'"');e[t]=o[t]})}var a={loaded:[],classes:{},master:{volume:options.startingVol,mute:!1},groups:{playing:[],looping:[],custom:{}},mute:function(t){a.master.mute=!!t,$(document).trigger({type:":master-mute",mute:!!t})},isMuted:function(){return!!a.master.mute},volume:function(t){t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),a.master.volume=t),$(document).trigger({type:":master-volume",volume:t})},getVolume:function(){return a.master.volume},stopAll:function(){c.list.forEach(function(t){t.stop()})},audioPlaying:function(){return!!a.groups.playing.length},savePrefs:function(){t(options.storagekey,a.master)},loadPrefs:function(){var t=o(options.storagekey);t&&"object"==typeof t&&t.hasOwnProperty("volume")&&"number"==typeof t.volume&&t.hasOwnProperty("mute")&&"boolean"==typeof t.volume&&(delete a.master,a.master=t)},clearPrefs:function(){n(options.storagekey)}},r={track:[":available",":loaded",":play",":stop",":mute",":volume"],master:[":master-mute",":master-volume"]},u={aac:"audio/aac",caf:"audio/x-caf","x-caf":"audio/x-caf",mp3:'audio/mpeg; codecs="mp3"',mpeg:'audio/mpeg; codecs="mp3"',m4a:"audio/mp4",mp4:"audio/mp4","x-m4a":"audio/mp4","x-mp4":"audio/mp4",oga:"audio/ogg",ogg:"audio/ogg",opus:'audio/ogg; codecs="opus"',wav:"audio/wav",wave:"audio/wav",weba:"audio/webm",webm:"audio/webm"};function s(t){throw new Error(t)}function c(t,e,o){this instanceof c||s("Track: called without `new` operator"),t||s("Track: no id specified"),"string"!=typeof t&&s("Track: track id is not a string"),(!e||Array.isArray(e)&&!e.length)&&s("Track: no sources specified"),o&&(e=[].slice.call(arguments).slice(1));var i=$(document.createElement("audio"));e.forEach(function(t){var e,o,n;$(document.createElement("source")).attr({src:t,type:(e=t,o=e.split("."),n=o[o.length-1],n.includes("?")&&(n=n.split("?")[0]),n=n.toLowerCase().trim(),Object.keys(u).includes(n)||s('Track: unsupported file type "'+n+'"'),u[n])}).appendTo(i)}),i.attr({"data-track":"id","data-volume":1,"data-mute":!1}).one("canplay",function(){a.loaded.push(t)}),options.preload&&i.attr("preload","auto"),i[0].volume=1*a.master.volume,this.id=t,this.$el=i,this.unwrap=i[0],this.sources=e}c.list=[],c.is=function(t){return t instanceof c},c.has=function(e){return c.list.some(function(t){return t.id===e})},c.emit=function(t,e){$(document).trigger({type:t,track:e}),e.emit(t)},c.add=function(t){var e=new c(t,[].slice.call(arguments).slice(1));return c.list.push(e),e.$el.on("canplay",function(){c.emit(":available",e)}),e.$el.on("canplaythrough",function(){c.emit(":loaded",e)}),e.attach(),e},c.renew=function(){c.list.forEach(function(t){t.mute(t.isMuted()),t.volume(t.getVolume())})},c.getIdx=function(e){return c.list.findIndex(function(t){return t.id===e})},c.get=function(e){return c.list.find(function(t){return t.id===e})},c.extend=function(t){i(c,t)},c.extendPrototype=function(t){i(c.prototype,t)},c.removeFromDOM=function(t){"string"==typeof t&&(t=c.get(t)),t&&c.is(t)?t.unattach():e.remove()},c.prototype={constructor:c,emit:function(t){this.$el.trigger({type:t,track:this})},clone:function(){return new c(this.id,this.sources)},isAttached:function(){return $.contains(e[0],this.unwrap)},attach:function(){return this.isAttached()||this.$el.appendTo(e),this},unattach:function(){return this.isAttached()&&this.$el.remove(),this},isPlaying:function(){return!this.unwrap.paused},play:function(){var t=this;return this.unwrap.play(),c.emit(":play",this),this.$el.on("ended",function(){t.unwrap.loop||(t.unwrap.currentTime=0,c.emit(":stop",t))}),this},playWhenPossible:function(){var e=this;return this.unwrap.play().then(function(){c.emit(":play",e),e.$el.on("ended",function(){e.unwrap.loop||(e.unwrap.currentTime=0,c.emit(":stop",e))})},function(t){$(document).one("click mousedown keydown touchstart",function(){e.play()})}).catch(function(t){console.error(t)}),this},forcePlay:function(){var t=this,e=$(document.createElement("a")).css("display","none").appendTo(document.body).on("click",function(){t.play()});setTimeout(function(){e.trigger("click")},100)},pause:function(){return this.unwrap.pause(),c.emit(":pause",this),this},stop:function(){return this.unwrap.pause(),this.unwrap.currentTime=0,c.emit(":stop",this),this},mute:function(t){return t=!!t,this.$el.attr("data-mute",t),a.master.mute?this.unwrap.muted=!0:this.unwrap.muted=t,c.emit(":mute",this),this},isMuted:function(){var t=this.$el.attr("data-mute");return"boolean"==typeof t?t:"false"!==t},toggleMute:function(){return this.mute(!this.isMuted()),this},volume:function(t){return t=Number(t),Number.isNaN(t)||(1<t?t=1:t<0&&(t=0),this.$el.attr("data-volume",t),this.unwrap.volume=t*a.master.volume),c.emit(":volume",this),this},getVolume:function(){return Number(this.$el.attr("data-volume"))},addToGroup:function(t,e){var o=this,n=e?a.groups.custom[t]:a.groups[t];return n.some(function(t){return o.id===t.id})||n.push(this),this},removeFromGroup:function(t,e){var o=this,n=e?a.groups.custom[t]:a.groups[t],i=n.findIndex(function(t){return t.id&&t.id===o.id});return n.splice(i,1),this},loop:function(t){return this.unwrap.loop=!!t,this.unwrap.loop?this.addToGroup("looping"):this.removeFromGroup("looping"),this},isLooping:function(){return!!this.unwrap.loop},toggleLoop:function(){return this.loop(!this.isLooping()),this},seek:function(t){return t<0?t=this.unwrap.duration-t:t>this.unwrap.duration&&(t=this.unwrap.duration),this.unwrap.currentTime=t,this},fadeIn:function(t){var e=this;t=t||1;var o=this.getVolume();return this.volume(0),this.play(),this.$el.animate({volume:o*a.master.volume},1e3*t,function(){e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeOut:function(t){t=t||1;var e=this,o=this.getVolume();return this.$el.animate({volume:0},1e3*t,function(){e.stop(),e.volume(o),c.emit(":volume",e),c.emit(":fade",e)}),this},fadeTo:function(t,e){var o=this;if(t=t||1,e=Number(e),!Number.isNaN(e))return 1<e?e=1:e<0&&(e=0),this.$el.animate({volume:e*a.master.volume},1e3*t,function(){o.volume(e),c.emit(":volume",o),c.emit(":fade",o)}),this;alert("ivalid volume level")},delay:function(t,e){var o=this;"function"==typeof e&&(t=Number(t),(Number.isNaN(t)||t<0)&&(t=0),setTimeout(function(){e.call(o,o,t)},t))},on:function(t,e){return e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),r.track.includes(t)?void this.$el.on(t,e):(console.error("<track>.on() -> invalid event type"),this)):(console.error("<track>.on() -> invalid callback"),this)},one:function(){return cb&&"function"==typeof cb?(type=type.trim().toLowerCase(),":"!==type[0]&&(type=":"+type),r.track.includes(type)?void this.$el.one(type,cb):(console.error("<track>.one() -> invalid event type"),this)):(console.error("<track>.one() -> invalid callback"),this)}};var l=r.track.concat(r.master);function p(t,e){if(!(this instanceof p))return new p(t,e);this.id=t,this.tracks=e.map(function(t){return c.get(t)}),this.looping=!1,this.current="",this.playing=!1}a.on=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).on(t,e):console.error("Chapel.Audio.on() -> invalid event type")):console.error("Chapel.Audio.on() -> invalid callback")},a.one=function(t,e){e&&"function"==typeof e?(":"!==(t=t.trim().toLowerCase())[0]&&(t=":"+t),l.includes(t)?$(document).one(t,e):console.error("Chapel.Audio.one() -> invalid event type")):console.error("Chapel.Audio.one() -> invalid callback")},a.on(":master-mute",c.renew),a.on(":master-volume",c.renew),options.persistPrefs&&(a.on(":master-mute",a.savePrefs),a.on(":master-volume",a.savePrefs)),a.on(":play",function(t){t.track.addToGroup("playing")}),a.on(":stop",function(t){t.track.removeFromGroup("playing")}),options.muteOnBlur&&$(window).on("blur",function(){a.isMuted()||(a.mute(!0),$(window).one("focus",function(){a.mute(!1)}))}),a.classes.Track=c,a.newTrack=c.add,a.track=c.get,a.createGroup=function(t,e,o){var n,i,r;n=o?[].slice.call(arguments).slice(1):e,i=t,(r=n)&&Array.isArray(r)||(r=[]),a.groups.custom[i]=r.map(function(t){return c.get(t)})},a.group=function(t){if(!(this instanceof a.group))return new a.group(t);Object.keys(a.groups.custom).includes(t)?this.members=a.groups.custom[t]:this.members=a.groups[t],Array.isArray(this.members)||(this.members=[],console.error('Could not find members for track group "'+t+'"!'))},a.group.is=function(t){return this instanceof a.group},a.group.runOnAll=function(t,e,o){t.members.forEach(function(t){t[e].apply(t,o&&Array.isArray(o)?o:[])})},a.group.extend=function(t){i(a.group,t)},a.group.extendPrototype=function(t){i(a.group.prototype,t)},a.group.prototype={constructor:a.group,run:function(t,e,o){null!=o&&(e=[].slice.call(arguments).slice(1)),c.prototype.hasOwnProperty(t)&&a.group.runOnAll(this,t,e)},play:function(){return this.run("play"),this},pause:function(){return this.run("pause"),this},stop:function(){return this.run("stop"),this},mute:function(t){return this.run("mute",[t]),this},volume:function(t){return this.run("volume",[t]),this},loop:function(t){return this.run("loop",[t]),this}},p.list={},p.is=function(t){return t instanceof p},p.add=function(t,e,o){return o&&(e=[].slice.call(arguments).slice(1)),p.list[t]=new p(t,e),p.list[t]},p.extend=function(t){i(p,t)},p.extendPrototype=function(t){i(p.prototype,t)},p.prototype={constructor:p,clone:function(){return new p(this.id,this.tracks.map(function(t){return t.id}))},shuffle:function(){var t,e,o,n=this.tracks;for(o=n.length-1;0<o;o--)t=Math.floor(Math.random()*(o+1)),e=n[o],n[o]=n[t],n[t]=e;return this.tracks=n,this},random:function(){return this.tracks[Math.floor(Math.random()*this.tracks.length)]},isPlaying:function(){return this.playing},play:function(t){var e=this;if((t=t||(e.current?e.tracks.findIndex(function(t){return t.id===e.current}):0))>=e.tracks.length&&e.looping)t=0;else if(t>=e.tracks.length)return e.current="",void(e.playing=!1);var o=e.tracks[t],n=o.isLooping();return o.loop(!1),o.play(),e.playing=!0,setTimeout(function(){o.isPlaying()||(e.playing=!1)},20),e.current=o.id,o.$el.one("ended.playlist",function(){t++,o.loop(n),e.play(t)}),e},loop:function(t){return this.looping=!!t,this},stop:function(){var t=c.get(this.current);return t.stop(),t.$el.off(".playlist"),this.current="",this.playing=!1,this},pause:function(){return c.get(this.current).pause(),this.playing=!1,this}},a.classes.Playlist=p,a.createPlaylist=p.add,a.playlist=function(t){return p.list[t]||null},a.extend=function(t){i(a,t)},a.extendTrack=c.extend,a.extendTrackProto=c.extendPrototype,a.extendGroup=a.group.extend,a.extendGroupProto=a.group.extendPrototype,a.extendPlaylist=p.extend,a.extendPlaylistProto=p.extendPrototype,window.Chapel=window.Chapel||{},window.Chapel.Audio=a,options.persistPrefs&&a.loadPrefs()}(),function(){"use strict";if(options.controls.show){var t=$(document.createElement("div")).attr("id","story-menu").css("display","none"),e=$(document.createElement("span")).attr("id","vol-title").append("Volume");options.controls.volumeDisplay||e.css("display","none");var o=$(document.createElement("input")).attr({id:"audio-volume",type:"range",min:1,max:99,step:1,title:"Volume"}),n=Math.trunc(100*window.Chapel.Audio.master.volume);n<0?n=0:100<n&&(n=100),o.attr("value",n);var i=function(t){void 0===t&&(t=o.val()),e.empty().append("Volume "+t)};o.on("input",function(){window.Chapel.Audio.volume($(this).val()/100),i($(this).val())});var r=$(document.createElement("tw-link")).attr({id:"audio-mute",title:"Mute"}).append("Mute <span></span>").on("click",function(t){t.preventDefault(),$(this).toggleClass("muted"),Chapel.Audio.mute(!Chapel.Audio.isMuted())});Chapel.Audio.isMuted()&&r.addClass("muted");var a=$(document.createElement("tw-link")).attr("id","audio-panel-toggle").on("click",function(t){t.preventDefault(),u.toggleClass("closed")}),u=$(document.createElement("div")).attr("id","audio-controls").append(t,e,o,r,a).appendTo(document.body);options.controls.startClosed&&u.addClass("closed"),window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.controls={$panel:u,$volume:o,$mute:r,$user:t,close:function(){u.addClass("closed")},open:function(){u.removeClass("closed")},toggle:function(){u.toggleClass("closed")},hide:function(){u.css("display","none")},show:function(){u.css("display","block")},updateVolume:i}}}(),function(t){(jQuery.browser=jQuery.browser||{}).mobile=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4))}(navigator.userAgent||navigator.vendor||window.opera),function(){"use strict";var e=State,t=$(document.createElement("div")).attr("id","audio-overlay").css("display","none").appendTo(document.body);function o(){t.css("display","block").append('<div class="lds-ring"><div></div><div></div><div></div><div></div></div>')}function u(){t.fadeOut(function(){t.empty()})}window.Chapel=window.Chapel||{},window.Chapel.Audio=window.Chapel.Audio||{},window.Chapel.Audio.loadScreen={show:o,dismiss:u,kill:function(){$("#audio-overlay").remove()}},window.Chapel.Audio.$overlay=t,window.Chapel.Audio.preload=function(){if(!(e.pastLength||e.futureLength||$.browser.mobile)){$(document).ready(function(){o()});var i=100+options.loadDelay,t=Chapel.Audio.classes.Track.list,r=Chapel.Audio.loaded;if(t.length){var a=t.map(function(t){return t.id});options.forceDismiss&&setTimeout(function(){u()},options.loadLimit.total),function t(){if(a.length){var e=a.shift();if(r.includes(e))t();else{var o=Chapel.Audio.classes.Track.get(e);if(o.unwrap.readyState<2){var n=!1;o.$el.one("canplay",function(){t(),n=!0}),setTimeout(function(){n||(o.$el.off("canplay"),t())},options.loadLimit.track)}else r.includes(e)||r.push(e),t()}}else setTimeout(u,i)}()}else setTimeout(u,i)}}}(),function(){"use strict";options.globalA&&void 0===window.A&&(window.A=window.Chapel.Audio),$(document).on("unload",function(){window.Chapel.Audio.savePrefs()}),Chapel.Audio.classes.Track.renew(),Chapel.Audio.controls&&Chapel.Audio.controls.updateVolume()}(),function(){"use strict";if(options.controls.show){var u=Engine,s=Chapel.Audio.controls.$user,t=function(){return"none"!==s.css("display")},c=function(){return t()||s.css("display","block"),s},e=function(){return t()&&s.css("display","none"),s};Chapel.Audio.menu={hide:e,show:c,isShown:t,links:{add:function(t,e,o){var n,i;if(!t||"string"!=typeof t){var r="undefined";return alert(r),void console.error(r)}o||"function"!=typeof e?(e&&"string"==typeof e&&(n=e),o&&"function"==typeof o&&(i=o)):(i=e,n=null);var a=$(document.createElement("tw-link")).append(t).attr({tabindex:"0",name:t.toLowerCase().trim()}).on("click",function(){n&&u.goToPassage(n),i&&i()}).addClass("story-menu").appendTo(s);return c(),a},clear:function(){return s.empty(),e()},hide:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').addClass("hide")},show:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').removeClass("hide")},toggle:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').toggleClass("hide")},remove:function(t){t=t.toLowerCase().trim(),$('tw-link.story-menu[name="'+t+'"]').remove()}}}}}(),function(){"use strict";var n=window.prompt;window.prompt=function(){var t,e,o=n.apply(null,[].slice.call(arguments));return t=o,e=(new DOMParser).parseFromString(t,"text/html"),Array.from(e.body.childNodes).some(function(t){return 1===t.nodeType})?o.replace(/[<>]/g,""):o}}();
\ No newline at end of file
diff --git a/src/wrap/wrapper.js b/src/wrap/wrapper.js
index 5743197..89503b4 100644
--- a/src/wrap/wrapper.js
+++ b/src/wrap/wrapper.js
@@ -1,6 +1,6 @@
 ;(function () {
     /**
-     * Harlowe Audio Library, by Chapel, v1.1.2
+     * Harlowe Audio Library, by Chapel, v1.3.0
      *
      * Released under the Unlicense, and dedicated to the public domain.
     **/
diff --git a/src/z-fixes.js b/src/z-fixes.js
deleted file mode 100644
index 5c827a2..0000000
--- a/src/z-fixes.js
+++ /dev/null
@@ -1,22 +0,0 @@
-(function () {
-    'use strict';
-
-    // fix prompt injection
-
-    function isHTML(str) {
-        var doc = new DOMParser().parseFromString(str, "text/html");
-        return Array.from(doc.body.childNodes).some( function (node) { return node.nodeType === 1; });
-    }
-
-    var cached = window.prompt;
-
-    window.prompt = function () {
-        var result = cached.apply(null, [].slice.call(arguments));
-        if (isHTML(result)) {
-            return (result.replace(/[<>]/g, ''));
-        } else {
-            return result;
-        }
-    };
-
-}());
\ No newline at end of file