From 137af3a6516e132459f22348e56cddf16839ea5b Mon Sep 17 00:00:00 2001
From: ezsh <ezsh.junk@gmail.com>
Date: Sun, 7 Jul 2019 23:01:46 +0200
Subject: [PATCH] Update SugarCube to 2.29.0

---
 .../sugarcube stuff/2.29.0-debug-format.js    |  1 +
 devNotes/sugarcube stuff/2.29.0-format.js     |  1 +
 .../sugarcube-fc-changes-2.28.0.patch         | 73 +++++++++++++++
 .../sugarcube-fc-changes.patch                | 90 +++++++++----------
 .../tweeGo/storyFormats/sugarcube-2/format.js |  2 +-
 5 files changed, 121 insertions(+), 46 deletions(-)
 create mode 100644 devNotes/sugarcube stuff/2.29.0-debug-format.js
 create mode 100644 devNotes/sugarcube stuff/2.29.0-format.js
 create mode 100644 devNotes/sugarcube stuff/sugarcube-fc-changes-2.28.0.patch
 mode change 100644 => 120000 devTools/tweeGo/storyFormats/sugarcube-2/format.js

diff --git a/devNotes/sugarcube stuff/2.29.0-debug-format.js b/devNotes/sugarcube stuff/2.29.0-debug-format.js
new file mode 100644
index 00000000000..b8a742c3356
--- /dev/null
+++ b/devNotes/sugarcube stuff/2.29.0-debug-format.js	
@@ -0,0 +1 @@
+window.storyFormat({"name":"SugarCube","version":"2.29.0","description":"A full featured, highly customizable story format.  See its <a href=\"http://www.motoslave.net/sugarcube/2/#documentation\" target=\"_blank\">documentation</a>.","author":"Thomas Michael Edwards","image":"icon.svg","url":"http://www.motoslave.net/sugarcube/","license":"BSD-2-Clause","proofing":false,"source":"<!DOCTYPE html>\n<html data-init=\"no-js\">\n<head>\n<meta charset=\"UTF-8\" />\n<title>{{STORY_NAME}}</title>\n<meta name=\"viewport\" content=\"width=device-width,initial-scale=1\" />\n<!--\n\nSugarCube (v2.29.0): A free (gratis and libre) story format.\n\nCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>.\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this\n   list of conditions and the following disclaimer.\n2. Redistributions in binary form must reproduce the above copyright notice,\n   this list of conditions and the following disclaimer in the documentation\n   and/or other materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\nANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\nWARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR\nANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\nLOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\nON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS\nSOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n\n-->\n<script id=\"script-libraries\" type=\"text/javascript\">\nif(document.head&&document.addEventListener&&document.querySelector&&Object.create&&Object.freeze&&JSON){document.documentElement.setAttribute(\"data-init\", \"loading\");\n/*! @source http://purl.eligrey.com/github/classList.js/blob/master/classList.js */\nif(\"document\" in self){if(!(\"classList\" in document.createElement(\"_\"))){(function(j){\"use strict\";if(!(\"Element\" in j)){return}var a=\"classList\",f=\"prototype\",m=j.Element[f],b=Object,k=String[f].trim||function(){return this.replace(/^\\s+|\\s+$/g,\"\")},c=Array[f].indexOf||function(q){var p=0,o=this.length;for(;p<o;p++){if(p in this&&this[p]===q){return p}}return -1},n=function(o,p){this.name=o;this.code=DOMException[o];this.message=p},g=function(p,o){if(o===\"\"){throw new n(\"SYNTAX_ERR\",\"An invalid or illegal string was specified\")}if(/\\s/.test(o)){throw new n(\"INVALID_CHARACTER_ERR\",\"String contains an invalid character\")}return c.call(p,o)},d=function(s){var r=k.call(s.getAttribute(\"class\")||\"\"),q=r?r.split(/\\s+/):[],p=0,o=q.length;for(;p<o;p++){this.push(q[p])}this._updateClassName=function(){s.setAttribute(\"class\",this.toString())}},e=d[f]=[],i=function(){return new d(this)};n[f]=Error[f];e.item=function(o){return this[o]||null};e.contains=function(o){o+=\"\";return g(this,o)!==-1};e.add=function(){var s=arguments,r=0,p=s.length,q,o=false;do{q=s[r]+\"\";if(g(this,q)===-1){this.push(q);o=true}}while(++r<p);if(o){this._updateClassName()}};e.remove=function(){var t=arguments,s=0,p=t.length,r,o=false,q;do{r=t[s]+\"\";q=g(this,r);while(q!==-1){this.splice(q,1);o=true;q=g(this,r)}}while(++s<p);if(o){this._updateClassName()}};e.toggle=function(p,q){p+=\"\";var o=this.contains(p),r=o?q!==true&&\"remove\":q!==false&&\"add\";if(r){this[r](p)}if(q===true||q===false){return q}else{return !o}};e.toString=function(){return this.join(\" \")};if(b.defineProperty){var l={get:i,enumerable:true,configurable:true};try{b.defineProperty(m,a,l)}catch(h){if(h.number===-2146823252){l.enumerable=false;b.defineProperty(m,a,l)}}}else{if(b[f].__defineGetter__){m.__defineGetter__(a,i)}}}(self))}else{(function(){var b=document.createElement(\"_\");b.classList.add(\"c1\",\"c2\");if(!b.classList.contains(\"c2\")){var c=function(e){var d=DOMTokenList.prototype[e];DOMTokenList.prototype[e]=function(h){var g,f=arguments.length;for(g=0;g<f;g++){h=arguments[g];d.call(this,h)}}};c(\"add\");c(\"remove\")}b.classList.toggle(\"c3\",false);if(b.classList.contains(\"c3\")){var a=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(d,e){if(1 in arguments&&!this.contains(d)===!e){return e}else{return a.call(this,d)}}}b=null}())}};\n/*!\n * https://github.com/es-shims/es5-shim\n * @license es5-shim Copyright 2009-2015 by contributors, MIT License\n * see https://github.com/es-shims/es5-shim/blob/v4.5.13/LICENSE\n */\n(function(t,r){\"use strict\";if(typeof define===\"function\"&&define.amd){define(r)}else if(typeof exports===\"object\"){module.exports=r()}else{t.returnExports=r()}})(this,function(){var t=Array;var r=t.prototype;var e=Object;var n=e.prototype;var i=Function;var a=i.prototype;var o=String;var f=o.prototype;var u=Number;var l=u.prototype;var s=r.slice;var c=r.splice;var v=r.push;var h=r.unshift;var p=r.concat;var y=r.join;var d=a.call;var g=a.apply;var w=Math.max;var b=Math.min;var T=n.toString;var m=typeof Symbol===\"function\"&&typeof Symbol.toStringTag===\"symbol\";var D;var S=Function.prototype.toString,x=/^\\s*class /,O=function isES6ClassFn(t){try{var r=S.call(t);var e=r.replace(/\\/\\/.*\\n/g,\"\");var n=e.replace(/\\/\\*[.\\s\\S]*\\*\\//g,\"\");var i=n.replace(/\\n/gm,\" \").replace(/ {2}/g,\" \");return x.test(i)}catch(a){return false}},E=function tryFunctionObject(t){try{if(O(t)){return false}S.call(t);return true}catch(r){return false}},j=\"[object Function]\",I=\"[object GeneratorFunction]\",D=function isCallable(t){if(!t){return false}if(typeof t!==\"function\"&&typeof t!==\"object\"){return false}if(m){return E(t)}if(O(t)){return false}var r=T.call(t);return r===j||r===I};var M;var U=RegExp.prototype.exec,$=function tryRegexExec(t){try{U.call(t);return true}catch(r){return false}},F=\"[object RegExp]\";M=function isRegex(t){if(typeof t!==\"object\"){return false}return m?$(t):T.call(t)===F};var N;var C=String.prototype.valueOf,k=function tryStringObject(t){try{C.call(t);return true}catch(r){return false}},A=\"[object String]\";N=function isString(t){if(typeof t===\"string\"){return true}if(typeof t!==\"object\"){return false}return m?k(t):T.call(t)===A};var R=e.defineProperty&&function(){try{var t={};e.defineProperty(t,\"x\",{enumerable:false,value:t});for(var r in t){return false}return t.x===t}catch(n){return false}}();var P=function(t){var r;if(R){r=function(t,r,n,i){if(!i&&r in t){return}e.defineProperty(t,r,{configurable:true,enumerable:false,writable:true,value:n})}}else{r=function(t,r,e,n){if(!n&&r in t){return}t[r]=e}}return function defineProperties(e,n,i){for(var a in n){if(t.call(n,a)){r(e,a,n[a],i)}}}}(n.hasOwnProperty);var J=function isPrimitive(t){var r=typeof t;return t===null||r!==\"object\"&&r!==\"function\"};var Y=u.isNaN||function isActualNaN(t){return t!==t};var z={ToInteger:function ToInteger(t){var r=+t;if(Y(r)){r=0}else if(r!==0&&r!==1/0&&r!==-(1/0)){r=(r>0||-1)*Math.floor(Math.abs(r))}return r},ToPrimitive:function ToPrimitive(t){var r,e,n;if(J(t)){return t}e=t.valueOf;if(D(e)){r=e.call(t);if(J(r)){return r}}n=t.toString;if(D(n)){r=n.call(t);if(J(r)){return r}}throw new TypeError},ToObject:function(t){if(t==null){throw new TypeError(\"can't convert \"+t+\" to object\")}return e(t)},ToUint32:function ToUint32(t){return t>>>0}};var Z=function Empty(){};P(a,{bind:function bind(t){var r=this;if(!D(r)){throw new TypeError(\"Function.prototype.bind called on incompatible \"+r)}var n=s.call(arguments,1);var a;var o=function(){if(this instanceof a){var i=g.call(r,this,p.call(n,s.call(arguments)));if(e(i)===i){return i}return this}else{return g.call(r,t,p.call(n,s.call(arguments)))}};var f=w(0,r.length-n.length);var u=[];for(var l=0;l<f;l++){v.call(u,\"$\"+l)}a=i(\"binder\",\"return function (\"+y.call(u,\",\")+\"){ return binder.apply(this, arguments); }\")(o);if(r.prototype){Z.prototype=r.prototype;a.prototype=new Z;Z.prototype=null}return a}});var G=d.bind(n.hasOwnProperty);var H=d.bind(n.toString);var W=d.bind(s);var B=g.bind(s);if(typeof document===\"object\"&&document&&document.documentElement){try{W(document.documentElement.childNodes)}catch(X){var L=W;var q=B;W=function arraySliceIE(t){var r=[];var e=t.length;while(e-- >0){r[e]=t[e]}return q(r,L(arguments,1))};B=function arraySliceApplyIE(t,r){return q(W(t),r)}}}var K=d.bind(f.slice);var Q=d.bind(f.split);var V=d.bind(f.indexOf);var _=d.bind(v);var tt=d.bind(n.propertyIsEnumerable);var rt=d.bind(r.sort);var et=t.isArray||function isArray(t){return H(t)===\"[object Array]\"};var nt=[].unshift(0)!==1;P(r,{unshift:function(){h.apply(this,arguments);return this.length}},nt);P(t,{isArray:et});var it=e(\"a\");var at=it[0]!==\"a\"||!(0 in it);var ot=function properlyBoxed(t){var r=true;var e=true;var n=false;if(t){try{t.call(\"foo\",function(t,e,n){if(typeof n!==\"object\"){r=false}});t.call([1],function(){\"use strict\";e=typeof this===\"string\"},\"x\")}catch(i){n=true}}return!!t&&!n&&r&&e};P(r,{forEach:function forEach(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=-1;var i=z.ToUint32(e.length);var a;if(arguments.length>1){a=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.forEach callback must be a function\")}while(++n<i){if(n in e){if(typeof a===\"undefined\"){t(e[n],n,r)}else{t.call(a,e[n],n,r)}}}}},!ot(r.forEach));P(r,{map:function map(r){var e=z.ToObject(this);var n=at&&N(this)?Q(this,\"\"):e;var i=z.ToUint32(n.length);var a=t(i);var o;if(arguments.length>1){o=arguments[1]}if(!D(r)){throw new TypeError(\"Array.prototype.map callback must be a function\")}for(var f=0;f<i;f++){if(f in n){if(typeof o===\"undefined\"){a[f]=r(n[f],f,e)}else{a[f]=r.call(o,n[f],f,e)}}}return a}},!ot(r.map));P(r,{filter:function filter(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);var i=[];var a;var o;if(arguments.length>1){o=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.filter callback must be a function\")}for(var f=0;f<n;f++){if(f in e){a=e[f];if(typeof o===\"undefined\"?t(a,f,r):t.call(o,a,f,r)){_(i,a)}}}return i}},!ot(r.filter));P(r,{every:function every(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);var i;if(arguments.length>1){i=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.every callback must be a function\")}for(var a=0;a<n;a++){if(a in e&&!(typeof i===\"undefined\"?t(e[a],a,r):t.call(i,e[a],a,r))){return false}}return true}},!ot(r.every));P(r,{some:function some(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);var i;if(arguments.length>1){i=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.some callback must be a function\")}for(var a=0;a<n;a++){if(a in e&&(typeof i===\"undefined\"?t(e[a],a,r):t.call(i,e[a],a,r))){return true}}return false}},!ot(r.some));var ft=false;if(r.reduce){ft=typeof r.reduce.call(\"es5\",function(t,r,e,n){return n})===\"object\"}P(r,{reduce:function reduce(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);if(!D(t)){throw new TypeError(\"Array.prototype.reduce callback must be a function\")}if(n===0&&arguments.length===1){throw new TypeError(\"reduce of empty array with no initial value\")}var i=0;var a;if(arguments.length>=2){a=arguments[1]}else{do{if(i in e){a=e[i++];break}if(++i>=n){throw new TypeError(\"reduce of empty array with no initial value\")}}while(true)}for(;i<n;i++){if(i in e){a=t(a,e[i],i,r)}}return a}},!ft);var ut=false;if(r.reduceRight){ut=typeof r.reduceRight.call(\"es5\",function(t,r,e,n){return n})===\"object\"}P(r,{reduceRight:function reduceRight(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);if(!D(t)){throw new TypeError(\"Array.prototype.reduceRight callback must be a function\")}if(n===0&&arguments.length===1){throw new TypeError(\"reduceRight of empty array with no initial value\")}var i;var a=n-1;if(arguments.length>=2){i=arguments[1]}else{do{if(a in e){i=e[a--];break}if(--a<0){throw new TypeError(\"reduceRight of empty array with no initial value\")}}while(true)}if(a<0){return i}do{if(a in e){i=t(i,e[a],a,r)}}while(a--);return i}},!ut);var lt=r.indexOf&&[0,1].indexOf(1,2)!==-1;P(r,{indexOf:function indexOf(t){var r=at&&N(this)?Q(this,\"\"):z.ToObject(this);var e=z.ToUint32(r.length);if(e===0){return-1}var n=0;if(arguments.length>1){n=z.ToInteger(arguments[1])}n=n>=0?n:w(0,e+n);for(;n<e;n++){if(n in r&&r[n]===t){return n}}return-1}},lt);var st=r.lastIndexOf&&[0,1].lastIndexOf(0,-3)!==-1;P(r,{lastIndexOf:function lastIndexOf(t){var r=at&&N(this)?Q(this,\"\"):z.ToObject(this);var e=z.ToUint32(r.length);if(e===0){return-1}var n=e-1;if(arguments.length>1){n=b(n,z.ToInteger(arguments[1]))}n=n>=0?n:e-Math.abs(n);for(;n>=0;n--){if(n in r&&t===r[n]){return n}}return-1}},st);var ct=function(){var t=[1,2];var r=t.splice();return t.length===2&&et(r)&&r.length===0}();P(r,{splice:function splice(t,r){if(arguments.length===0){return[]}else{return c.apply(this,arguments)}}},!ct);var vt=function(){var t={};r.splice.call(t,0,0,1);return t.length===1}();P(r,{splice:function splice(t,r){if(arguments.length===0){return[]}var e=arguments;this.length=w(z.ToInteger(this.length),0);if(arguments.length>0&&typeof r!==\"number\"){e=W(arguments);if(e.length<2){_(e,this.length-t)}else{e[1]=z.ToInteger(r)}}return c.apply(this,e)}},!vt);var ht=function(){var r=new t(1e5);r[8]=\"x\";r.splice(1,1);return r.indexOf(\"x\")===7}();var pt=function(){var t=256;var r=[];r[t]=\"a\";r.splice(t+1,0,\"b\");return r[t]===\"a\"}();P(r,{splice:function splice(t,r){var e=z.ToObject(this);var n=[];var i=z.ToUint32(e.length);var a=z.ToInteger(t);var f=a<0?w(i+a,0):b(a,i);var u=b(w(z.ToInteger(r),0),i-f);var l=0;var s;while(l<u){s=o(f+l);if(G(e,s)){n[l]=e[s]}l+=1}var c=W(arguments,2);var v=c.length;var h;if(v<u){l=f;var p=i-u;while(l<p){s=o(l+u);h=o(l+v);if(G(e,s)){e[h]=e[s]}else{delete e[h]}l+=1}l=i;var y=i-u+v;while(l>y){delete e[l-1];l-=1}}else if(v>u){l=i-u;while(l>f){s=o(l+u-1);h=o(l+v-1);if(G(e,s)){e[h]=e[s]}else{delete e[h]}l-=1}}l=f;for(var d=0;d<c.length;++d){e[l]=c[d];l+=1}e.length=i-u+v;return n}},!ht||!pt);var yt=r.join;var dt;try{dt=Array.prototype.join.call(\"123\",\",\")!==\"1,2,3\"}catch(X){dt=true}if(dt){P(r,{join:function join(t){var r=typeof t===\"undefined\"?\",\":t;return yt.call(N(this)?Q(this,\"\"):this,r)}},dt)}var gt=[1,2].join(undefined)!==\"1,2\";if(gt){P(r,{join:function join(t){var r=typeof t===\"undefined\"?\",\":t;return yt.call(this,r)}},gt)}var wt=function push(t){var r=z.ToObject(this);var e=z.ToUint32(r.length);var n=0;while(n<arguments.length){r[e+n]=arguments[n];n+=1}r.length=e+n;return e+n};var bt=function(){var t={};var r=Array.prototype.push.call(t,undefined);return r!==1||t.length!==1||typeof t[0]!==\"undefined\"||!G(t,0)}();P(r,{push:function push(t){if(et(this)){return v.apply(this,arguments)}return wt.apply(this,arguments)}},bt);var Tt=function(){var t=[];var r=t.push(undefined);return r!==1||t.length!==1||typeof t[0]!==\"undefined\"||!G(t,0)}();P(r,{push:wt},Tt);P(r,{slice:function(t,r){var e=N(this)?Q(this,\"\"):this;return B(e,arguments)}},at);var mt=function(){try{[1,2].sort(null)}catch(t){try{[1,2].sort({})}catch(r){return false}}return true}();var Dt=function(){try{[1,2].sort(/a/);return false}catch(t){}return true}();var St=function(){try{[1,2].sort(undefined);return true}catch(t){}return false}();P(r,{sort:function sort(t){if(typeof t===\"undefined\"){return rt(this)}if(!D(t)){throw new TypeError(\"Array.prototype.sort callback must be a function\")}return rt(this,t)}},mt||!St||!Dt);var xt=!tt({toString:null},\"toString\");var Ot=tt(function(){},\"prototype\");var Et=!G(\"x\",\"0\");var jt=function(t){var r=t.constructor;return r&&r.prototype===t};var It={$applicationCache:true,$console:true,$external:true,$frame:true,$frameElement:true,$frames:true,$innerHeight:true,$innerWidth:true,$onmozfullscreenchange:true,$onmozfullscreenerror:true,$outerHeight:true,$outerWidth:true,$pageXOffset:true,$pageYOffset:true,$parent:true,$scrollLeft:true,$scrollTop:true,$scrollX:true,$scrollY:true,$self:true,$webkitIndexedDB:true,$webkitStorageInfo:true,$window:true,$width:true,$height:true,$top:true,$localStorage:true};var Mt=function(){if(typeof window===\"undefined\"){return false}for(var t in window){try{if(!It[\"$\"+t]&&G(window,t)&&window[t]!==null&&typeof window[t]===\"object\"){jt(window[t])}}catch(r){return true}}return false}();var Ut=function(t){if(typeof window===\"undefined\"||!Mt){return jt(t)}try{return jt(t)}catch(r){return false}};var $t=[\"toString\",\"toLocaleString\",\"valueOf\",\"hasOwnProperty\",\"isPrototypeOf\",\"propertyIsEnumerable\",\"constructor\"];var Ft=$t.length;var Nt=function isArguments(t){return H(t)===\"[object Arguments]\"};var Ct=function isArguments(t){return t!==null&&typeof t===\"object\"&&typeof t.length===\"number\"&&t.length>=0&&!et(t)&&D(t.callee)};var kt=Nt(arguments)?Nt:Ct;P(e,{keys:function keys(t){var r=D(t);var e=kt(t);var n=t!==null&&typeof t===\"object\";var i=n&&N(t);if(!n&&!r&&!e){throw new TypeError(\"Object.keys called on a non-object\")}var a=[];var f=Ot&&r;if(i&&Et||e){for(var u=0;u<t.length;++u){_(a,o(u))}}if(!e){for(var l in t){if(!(f&&l===\"prototype\")&&G(t,l)){_(a,o(l))}}}if(xt){var s=Ut(t);for(var c=0;c<Ft;c++){var v=$t[c];if(!(s&&v===\"constructor\")&&G(t,v)){_(a,v)}}}return a}});var At=e.keys&&function(){return e.keys(arguments).length===2}(1,2);var Rt=e.keys&&function(){var t=e.keys(arguments);return arguments.length!==1||t.length!==1||t[0]!==1}(1);var Pt=e.keys;P(e,{keys:function keys(t){if(kt(t)){return Pt(W(t))}else{return Pt(t)}}},!At||Rt);var Jt=new Date(-0xc782b5b342b24).getUTCMonth()!==0;var Yt=new Date(-0x55d318d56a724);var zt=new Date(14496624e5);var Zt=Yt.toUTCString()!==\"Mon, 01 Jan -45875 11:59:59 GMT\";var Gt;var Ht;var Wt=Yt.getTimezoneOffset();if(Wt<-720){Gt=Yt.toDateString()!==\"Tue Jan 02 -45875\";Ht=!/^Thu Dec 10 2015 \\d\\d:\\d\\d:\\d\\d GMT[-+]\\d\\d\\d\\d(?: |$)/.test(String(zt))}else{Gt=Yt.toDateString()!==\"Mon Jan 01 -45875\";Ht=!/^Wed Dec 09 2015 \\d\\d:\\d\\d:\\d\\d GMT[-+]\\d\\d\\d\\d(?: |$)/.test(String(zt))}var Bt=d.bind(Date.prototype.getFullYear);var Xt=d.bind(Date.prototype.getMonth);var Lt=d.bind(Date.prototype.getDate);var qt=d.bind(Date.prototype.getUTCFullYear);var Kt=d.bind(Date.prototype.getUTCMonth);var Qt=d.bind(Date.prototype.getUTCDate);var Vt=d.bind(Date.prototype.getUTCDay);var _t=d.bind(Date.prototype.getUTCHours);var tr=d.bind(Date.prototype.getUTCMinutes);var rr=d.bind(Date.prototype.getUTCSeconds);var er=d.bind(Date.prototype.getUTCMilliseconds);var nr=[\"Sun\",\"Mon\",\"Tue\",\"Wed\",\"Thu\",\"Fri\",\"Sat\"];var ir=[\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sep\",\"Oct\",\"Nov\",\"Dec\"];var ar=function daysInMonth(t,r){return Lt(new Date(r,t,0))};P(Date.prototype,{getFullYear:function getFullYear(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);if(t<0&&Xt(this)>11){return t+1}return t},getMonth:function getMonth(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);var r=Xt(this);if(t<0&&r>11){return 0}return r},getDate:function getDate(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);var r=Xt(this);var e=Lt(this);if(t<0&&r>11){if(r===12){return e}var n=ar(0,t+1);return n-e+1}return e},getUTCFullYear:function getUTCFullYear(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);if(t<0&&Kt(this)>11){return t+1}return t},getUTCMonth:function getUTCMonth(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);var r=Kt(this);if(t<0&&r>11){return 0}return r},getUTCDate:function getUTCDate(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);var r=Kt(this);var e=Qt(this);if(t<0&&r>11){if(r===12){return e}var n=ar(0,t+1);return n-e+1}return e}},Jt);P(Date.prototype,{toUTCString:function toUTCString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Vt(this);var r=Qt(this);var e=Kt(this);var n=qt(this);var i=_t(this);var a=tr(this);var o=rr(this);return nr[t]+\", \"+(r<10?\"0\"+r:r)+\" \"+ir[e]+\" \"+n+\" \"+(i<10?\"0\"+i:i)+\":\"+(a<10?\"0\"+a:a)+\":\"+(o<10?\"0\"+o:o)+\" GMT\"}},Jt||Zt);P(Date.prototype,{toDateString:function toDateString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=this.getDay();var r=this.getDate();var e=this.getMonth();var n=this.getFullYear();return nr[t]+\" \"+ir[e]+\" \"+(r<10?\"0\"+r:r)+\" \"+n}},Jt||Gt);if(Jt||Ht){Date.prototype.toString=function toString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=this.getDay();var r=this.getDate();var e=this.getMonth();var n=this.getFullYear();var i=this.getHours();var a=this.getMinutes();var o=this.getSeconds();var f=this.getTimezoneOffset();var u=Math.floor(Math.abs(f)/60);var l=Math.floor(Math.abs(f)%60);return nr[t]+\" \"+ir[e]+\" \"+(r<10?\"0\"+r:r)+\" \"+n+\" \"+(i<10?\"0\"+i:i)+\":\"+(a<10?\"0\"+a:a)+\":\"+(o<10?\"0\"+o:o)+\" GMT\"+(f>0?\"-\":\"+\")+(u<10?\"0\"+u:u)+(l<10?\"0\"+l:l)};if(R){e.defineProperty(Date.prototype,\"toString\",{configurable:true,enumerable:false,writable:true})}}var or=-621987552e5;var fr=\"-000001\";var ur=Date.prototype.toISOString&&new Date(or).toISOString().indexOf(fr)===-1;var lr=Date.prototype.toISOString&&new Date(-1).toISOString()!==\"1969-12-31T23:59:59.999Z\";var sr=d.bind(Date.prototype.getTime);P(Date.prototype,{toISOString:function toISOString(){if(!isFinite(this)||!isFinite(sr(this))){throw new RangeError(\"Date.prototype.toISOString called on non-finite value.\")}var t=qt(this);var r=Kt(this);t+=Math.floor(r/12);r=(r%12+12)%12;var e=[r+1,Qt(this),_t(this),tr(this),rr(this)];t=(t<0?\"-\":t>9999?\"+\":\"\")+K(\"00000\"+Math.abs(t),0<=t&&t<=9999?-4:-6);for(var n=0;n<e.length;++n){e[n]=K(\"00\"+e[n],-2)}return t+\"-\"+W(e,0,2).join(\"-\")+\"T\"+W(e,2).join(\":\")+\".\"+K(\"000\"+er(this),-3)+\"Z\"}},ur||lr);var cr=function(){try{return Date.prototype.toJSON&&new Date(NaN).toJSON()===null&&new Date(or).toJSON().indexOf(fr)!==-1&&Date.prototype.toJSON.call({toISOString:function(){return true}})}catch(t){return false}}();if(!cr){Date.prototype.toJSON=function toJSON(t){var r=e(this);var n=z.ToPrimitive(r);if(typeof n===\"number\"&&!isFinite(n)){return null}var i=r.toISOString;if(!D(i)){throw new TypeError(\"toISOString property is not callable\")}return i.call(r)}}var vr=Date.parse(\"+033658-09-27T01:46:40.000Z\")===1e15;var hr=!isNaN(Date.parse(\"2012-04-04T24:00:00.500Z\"))||!isNaN(Date.parse(\"2012-11-31T23:59:59.000Z\"))||!isNaN(Date.parse(\"2012-12-31T23:59:60.000Z\"));var pr=isNaN(Date.parse(\"2000-01-01T00:00:00.000Z\"));if(pr||hr||!vr){var yr=Math.pow(2,31)-1;var dr=Y(new Date(1970,0,1,0,0,0,yr+1).getTime());Date=function(t){var r=function Date(e,n,i,a,f,u,l){var s=arguments.length;var c;if(this instanceof t){var v=u;var h=l;if(dr&&s>=7&&l>yr){var p=Math.floor(l/yr)*yr;var y=Math.floor(p/1e3);v+=y;h-=y*1e3}c=s===1&&o(e)===e?new t(r.parse(e)):s>=7?new t(e,n,i,a,f,v,h):s>=6?new t(e,n,i,a,f,v):s>=5?new t(e,n,i,a,f):s>=4?new t(e,n,i,a):s>=3?new t(e,n,i):s>=2?new t(e,n):s>=1?new t(e instanceof t?+e:e):new t}else{c=t.apply(this,arguments)}if(!J(c)){P(c,{constructor:r},true)}return c};var e=new RegExp(\"^\"+\"(\\\\d{4}|[+-]\\\\d{6})\"+\"(?:-(\\\\d{2})\"+\"(?:-(\\\\d{2})\"+\"(?:\"+\"T(\\\\d{2})\"+\":(\\\\d{2})\"+\"(?:\"+\":(\\\\d{2})\"+\"(?:(\\\\.\\\\d{1,}))?\"+\")?\"+\"(\"+\"Z|\"+\"(?:\"+\"([-+])\"+\"(\\\\d{2})\"+\":(\\\\d{2})\"+\")\"+\")?)?)?)?\"+\"$\");var n=[0,31,59,90,120,151,181,212,243,273,304,334,365];var i=function dayFromMonth(t,r){var e=r>1?1:0;return n[r]+Math.floor((t-1969+e)/4)-Math.floor((t-1901+e)/100)+Math.floor((t-1601+e)/400)+365*(t-1970)};var a=function toUTC(r){var e=0;var n=r;if(dr&&n>yr){var i=Math.floor(n/yr)*yr;var a=Math.floor(i/1e3);e+=a;n-=a*1e3}return u(new t(1970,0,1,0,0,e,n))};for(var f in t){if(G(t,f)){r[f]=t[f]}}P(r,{now:t.now,UTC:t.UTC},true);r.prototype=t.prototype;P(r.prototype,{constructor:r},true);var l=function parse(r){var n=e.exec(r);if(n){var o=u(n[1]),f=u(n[2]||1)-1,l=u(n[3]||1)-1,s=u(n[4]||0),c=u(n[5]||0),v=u(n[6]||0),h=Math.floor(u(n[7]||0)*1e3),p=Boolean(n[4]&&!n[8]),y=n[9]===\"-\"?1:-1,d=u(n[10]||0),g=u(n[11]||0),w;var b=c>0||v>0||h>0;if(s<(b?24:25)&&c<60&&v<60&&h<1e3&&f>-1&&f<12&&d<24&&g<60&&l>-1&&l<i(o,f+1)-i(o,f)){w=((i(o,f)+l)*24+s+d*y)*60;w=((w+c+g*y)*60+v)*1e3+h;if(p){w=a(w)}if(-864e13<=w&&w<=864e13){return w}}return NaN}return t.parse.apply(this,arguments)};P(r,{parse:l});return r}(Date)}if(!Date.now){Date.now=function now(){return(new Date).getTime()}}var gr=l.toFixed&&(8e-5.toFixed(3)!==\"0.000\"||.9.toFixed(0)!==\"1\"||1.255.toFixed(2)!==\"1.25\"||(1000000000000000128).toFixed(0)!==\"1000000000000000128\");var wr={base:1e7,size:6,data:[0,0,0,0,0,0],multiply:function multiply(t,r){var e=-1;var n=r;while(++e<wr.size){n+=t*wr.data[e];wr.data[e]=n%wr.base;n=Math.floor(n/wr.base)}},divide:function divide(t){var r=wr.size;var e=0;while(--r>=0){e+=wr.data[r];wr.data[r]=Math.floor(e/t);e=e%t*wr.base}},numToString:function numToString(){var t=wr.size;var r=\"\";while(--t>=0){if(r!==\"\"||t===0||wr.data[t]!==0){var e=o(wr.data[t]);if(r===\"\"){r=e}else{r+=K(\"0000000\",0,7-e.length)+e}}}return r},pow:function pow(t,r,e){return r===0?e:r%2===1?pow(t,r-1,e*t):pow(t*t,r/2,e)},log:function log(t){var r=0;var e=t;while(e>=4096){r+=12;e/=4096}while(e>=2){r+=1;e/=2}return r}};var br=function toFixed(t){var r,e,n,i,a,f,l,s;r=u(t);r=Y(r)?0:Math.floor(r);if(r<0||r>20){throw new RangeError(\"Number.toFixed called with invalid number of decimals\")}e=u(this);if(Y(e)){return\"NaN\"}if(e<=-1e21||e>=1e21){return o(e)}n=\"\";if(e<0){n=\"-\";e=-e}i=\"0\";if(e>1e-21){a=wr.log(e*wr.pow(2,69,1))-69;f=a<0?e*wr.pow(2,-a,1):e/wr.pow(2,a,1);f*=4503599627370496;a=52-a;if(a>0){wr.multiply(0,f);l=r;while(l>=7){wr.multiply(1e7,0);l-=7}wr.multiply(wr.pow(10,l,1),0);l=a-1;while(l>=23){wr.divide(1<<23);l-=23}wr.divide(1<<l);wr.multiply(1,1);wr.divide(2);i=wr.numToString()}else{wr.multiply(0,f);wr.multiply(1<<-a,0);i=wr.numToString()+K(\"0.00000000000000000000\",2,2+r)}}if(r>0){s=i.length;if(s<=r){i=n+K(\"0.0000000000000000000\",0,r-s+2)+i}else{i=n+K(i,0,s-r)+\".\"+K(i,s-r)}}else{i=n+i}return i};P(l,{toFixed:br},gr);var Tr=function(){try{return 1..toPrecision(undefined)===\"1\"}catch(t){return true}}();var mr=l.toPrecision;P(l,{toPrecision:function toPrecision(t){return typeof t===\"undefined\"?mr.call(this):mr.call(this,t)}},Tr);if(\"ab\".split(/(?:ab)*/).length!==2||\".\".split(/(.?)(.?)/).length!==4||\"tesst\".split(/(s)*/)[1]===\"t\"||\"test\".split(/(?:)/,-1).length!==4||\"\".split(/.?/).length||\".\".split(/()()/).length>1){(function(){var t=typeof/()??/.exec(\"\")[1]===\"undefined\";var r=Math.pow(2,32)-1;f.split=function(e,n){var i=String(this);if(typeof e===\"undefined\"&&n===0){return[]}if(!M(e)){return Q(this,e,n)}var a=[];var o=(e.ignoreCase?\"i\":\"\")+(e.multiline?\"m\":\"\")+(e.unicode?\"u\":\"\")+(e.sticky?\"y\":\"\"),f=0,u,l,s,c;var h=new RegExp(e.source,o+\"g\");if(!t){u=new RegExp(\"^\"+h.source+\"$(?!\\\\s)\",o)}var p=typeof n===\"undefined\"?r:z.ToUint32(n);l=h.exec(i);while(l){s=l.index+l[0].length;if(s>f){_(a,K(i,f,l.index));if(!t&&l.length>1){l[0].replace(u,function(){for(var t=1;t<arguments.length-2;t++){if(typeof arguments[t]===\"undefined\"){l[t]=void 0}}})}if(l.length>1&&l.index<i.length){v.apply(a,W(l,1))}c=l[0].length;f=s;if(a.length>=p){break}}if(h.lastIndex===l.index){h.lastIndex++}l=h.exec(i)}if(f===i.length){if(c||!h.test(\"\")){_(a,\"\")}}else{_(a,K(i,f))}return a.length>p?W(a,0,p):a}})()}else if(\"0\".split(void 0,0).length){f.split=function split(t,r){if(typeof t===\"undefined\"&&r===0){return[]}return Q(this,t,r)}}var Dr=f.replace;var Sr=function(){var t=[];\"x\".replace(/x(.)?/g,function(r,e){_(t,e)});return t.length===1&&typeof t[0]===\"undefined\"}();if(!Sr){f.replace=function replace(t,r){var e=D(r);var n=M(t)&&/\\)[*?]/.test(t.source);if(!e||!n){return Dr.call(this,t,r)}else{var i=function(e){var n=arguments.length;var i=t.lastIndex;t.lastIndex=0;var a=t.exec(e)||[];t.lastIndex=i;_(a,arguments[n-2],arguments[n-1]);return r.apply(this,a)};return Dr.call(this,t,i)}}}var xr=f.substr;var Or=\"\".substr&&\"0b\".substr(-1)!==\"b\";P(f,{substr:function substr(t,r){var e=t;if(t<0){e=w(this.length+t,0)}return xr.call(this,e,r)}},Or);var Er=\"\\t\\n\\x0B\\f\\r \\xa0\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\"+\"\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\u2028\"+\"\\u2029\\ufeff\";var jr=\"\\u200b\";var Ir=\"[\"+Er+\"]\";var Mr=new RegExp(\"^\"+Ir+Ir+\"*\");var Ur=new RegExp(Ir+Ir+\"*$\");var $r=f.trim&&(Er.trim()||!jr.trim());P(f,{trim:function trim(){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}return o(this).replace(Mr,\"\").replace(Ur,\"\")}},$r);var Fr=d.bind(String.prototype.trim);var Nr=f.lastIndexOf&&\"abc\\u3042\\u3044\".lastIndexOf(\"\\u3042\\u3044\",2)!==-1;P(f,{lastIndexOf:function lastIndexOf(t){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}var r=o(this);var e=o(t);var n=arguments.length>1?u(arguments[1]):NaN;var i=Y(n)?Infinity:z.ToInteger(n);var a=b(w(i,0),r.length);var f=e.length;var l=a+f;while(l>0){l=w(0,l-f);var s=V(K(r,l,a+f),e);if(s!==-1){return l+s}}return-1}},Nr);var Cr=f.lastIndexOf;P(f,{lastIndexOf:function lastIndexOf(t){return Cr.apply(this,arguments)}},f.lastIndexOf.length!==1);if(parseInt(Er+\"08\")!==8||parseInt(Er+\"0x16\")!==22){parseInt=function(t){var r=/^[-+]?0[xX]/;return function parseInt(e,n){if(typeof e===\"symbol\"){\"\"+e}var i=Fr(String(e));var a=u(n)||(r.test(i)?16:10);return t(i,a)}}(parseInt)}if(1/parseFloat(\"-0\")!==-Infinity){parseFloat=function(t){return function parseFloat(r){var e=Fr(String(r));var n=t(e);return n===0&&K(e,0,1)===\"-\"?-0:n}}(parseFloat)}if(String(new RangeError(\"test\"))!==\"RangeError: test\"){var kr=function toString(){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}var t=this.name;if(typeof t===\"undefined\"){t=\"Error\"}else if(typeof t!==\"string\"){t=o(t)}var r=this.message;if(typeof r===\"undefined\"){r=\"\"}else if(typeof r!==\"string\"){r=o(r)}if(!t){return r}if(!r){return t}return t+\": \"+r};Error.prototype.toString=kr}if(R){var Ar=function(t,r){if(tt(t,r)){var e=Object.getOwnPropertyDescriptor(t,r);if(e.configurable){e.enumerable=false;Object.defineProperty(t,r,e)}}};Ar(Error.prototype,\"message\");if(Error.prototype.message!==\"\"){Error.prototype.message=\"\"}Ar(Error.prototype,\"name\")}if(String(/a/gim)!==\"/a/gim\"){var Rr=function toString(){var t=\"/\"+this.source+\"/\";if(this.global){t+=\"g\"}if(this.ignoreCase){t+=\"i\"}if(this.multiline){t+=\"m\"}return t};RegExp.prototype.toString=Rr}});\n//# sourceMappingURL=es5-shim.map\n/*!\n * https://github.com/paulmillr/es6-shim\n * @license es6-shim Copyright 2013-2016 by Paul Miller (http://paulmillr.com)\n *   and contributors,  MIT License\n * es6-shim: v0.35.4\n * see https://github.com/paulmillr/es6-shim/blob/0.35.4/LICENSE\n * Details and documentation:\n * https://github.com/paulmillr/es6-shim/\n */\n(function(e,t){if(typeof define===\"function\"&&define.amd){define(t)}else if(typeof exports===\"object\"){module.exports=t()}else{e.returnExports=t()}})(this,function(){\"use strict\";var e=Function.call.bind(Function.apply);var t=Function.call.bind(Function.call);var r=Array.isArray;var n=Object.keys;var o=function notThunker(t){return function notThunk(){return!e(t,this,arguments)}};var i=function(e){try{e();return false}catch(t){return true}};var a=function valueOrFalseIfThrows(e){try{return e()}catch(t){return false}};var u=o(i);var f=function(){return!i(function(){return Object.defineProperty({},\"x\",{get:function(){}})})};var s=!!Object.defineProperty&&f();var c=function foo(){}.name===\"foo\";var l=Function.call.bind(Array.prototype.forEach);var p=Function.call.bind(Array.prototype.reduce);var v=Function.call.bind(Array.prototype.filter);var y=Function.call.bind(Array.prototype.some);var h=function(e,t,r,n){if(!n&&t in e){return}if(s){Object.defineProperty(e,t,{configurable:true,enumerable:false,writable:true,value:r})}else{e[t]=r}};var b=function(e,t,r){l(n(t),function(n){var o=t[n];h(e,n,o,!!r)})};var g=Function.call.bind(Object.prototype.toString);var d=typeof/abc/===\"function\"?function IsCallableSlow(e){return typeof e===\"function\"&&g(e)===\"[object Function]\"}:function IsCallableFast(e){return typeof e===\"function\"};var m={getter:function(e,t,r){if(!s){throw new TypeError(\"getters require true ES5 support\")}Object.defineProperty(e,t,{configurable:true,enumerable:false,get:r})},proxy:function(e,t,r){if(!s){throw new TypeError(\"getters require true ES5 support\")}var n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,{configurable:n.configurable,enumerable:n.enumerable,get:function getKey(){return e[t]},set:function setKey(r){e[t]=r}})},redefine:function(e,t,r){if(s){var n=Object.getOwnPropertyDescriptor(e,t);n.value=r;Object.defineProperty(e,t,n)}else{e[t]=r}},defineByDescriptor:function(e,t,r){if(s){Object.defineProperty(e,t,r)}else if(\"value\"in r){e[t]=r.value}},preserveToString:function(e,t){if(t&&d(t.toString)){h(e,\"toString\",t.toString.bind(t),true)}}};var O=Object.create||function(e,t){var r=function Prototype(){};r.prototype=e;var o=new r;if(typeof t!==\"undefined\"){n(t).forEach(function(e){m.defineByDescriptor(o,e,t[e])})}return o};var w=function(e,t){if(!Object.setPrototypeOf){return false}return a(function(){var r=function Subclass(t){var r=new e(t);Object.setPrototypeOf(r,Subclass.prototype);return r};Object.setPrototypeOf(r,e);r.prototype=O(e.prototype,{constructor:{value:r}});return t(r)})};var j=function(){if(typeof self!==\"undefined\"){return self}if(typeof window!==\"undefined\"){return window}if(typeof global!==\"undefined\"){return global}throw new Error(\"unable to locate global object\")};var S=j();var T=S.isFinite;var I=Function.call.bind(String.prototype.indexOf);var E=Function.apply.bind(Array.prototype.indexOf);var P=Function.call.bind(Array.prototype.concat);var C=Function.call.bind(String.prototype.slice);var M=Function.call.bind(Array.prototype.push);var x=Function.apply.bind(Array.prototype.push);var N=Function.call.bind(Array.prototype.shift);var A=Math.max;var R=Math.min;var _=Math.floor;var k=Math.abs;var L=Math.exp;var F=Math.log;var D=Math.sqrt;var z=Function.call.bind(Object.prototype.hasOwnProperty);var q;var W=function(){};var G=S.Map;var H=G&&G.prototype[\"delete\"];var V=G&&G.prototype.get;var B=G&&G.prototype.has;var U=G&&G.prototype.set;var $=S.Symbol||{};var J=$.species||\"@@species\";var X=Number.isNaN||function isNaN(e){return e!==e};var K=Number.isFinite||function isFinite(e){return typeof e===\"number\"&&T(e)};var Z=d(Math.sign)?Math.sign:function sign(e){var t=Number(e);if(t===0){return t}if(X(t)){return t}return t<0?-1:1};var Y=function log1p(e){var t=Number(e);if(t<-1||X(t)){return NaN}if(t===0||t===Infinity){return t}if(t===-1){return-Infinity}return 1+t-1===0?t:t*(F(1+t)/(1+t-1))};var Q=function isArguments(e){return g(e)===\"[object Arguments]\"};var ee=function isArguments(e){return e!==null&&typeof e===\"object\"&&typeof e.length===\"number\"&&e.length>=0&&g(e)!==\"[object Array]\"&&g(e.callee)===\"[object Function]\"};var te=Q(arguments)?Q:ee;var re={primitive:function(e){return e===null||typeof e!==\"function\"&&typeof e!==\"object\"},string:function(e){return g(e)===\"[object String]\"},regex:function(e){return g(e)===\"[object RegExp]\"},symbol:function(e){return typeof S.Symbol===\"function\"&&typeof e===\"symbol\"}};var ne=function overrideNative(e,t,r){var n=e[t];h(e,t,r,true);m.preserveToString(e[t],n)};var oe=typeof $===\"function\"&&typeof $[\"for\"]===\"function\"&&re.symbol($());var ie=re.symbol($.iterator)?$.iterator:\"_es6-shim iterator_\";if(S.Set&&typeof(new S.Set)[\"@@iterator\"]===\"function\"){ie=\"@@iterator\"}if(!S.Reflect){h(S,\"Reflect\",{},true)}var ae=S.Reflect;var ue=String;var fe=typeof document===\"undefined\"||!document?null:document.all;var se=fe==null?function isNullOrUndefined(e){return e==null}:function isNullOrUndefinedAndNotDocumentAll(e){return e==null&&e!==fe};var ce={Call:function Call(t,r){var n=arguments.length>2?arguments[2]:[];if(!ce.IsCallable(t)){throw new TypeError(t+\" is not a function\")}return e(t,r,n)},RequireObjectCoercible:function(e,t){if(se(e)){throw new TypeError(t||\"Cannot call method on \"+e)}return e},TypeIsObject:function(e){if(e===void 0||e===null||e===true||e===false){return false}return typeof e===\"function\"||typeof e===\"object\"||e===fe},ToObject:function(e,t){return Object(ce.RequireObjectCoercible(e,t))},IsCallable:d,IsConstructor:function(e){return ce.IsCallable(e)},ToInt32:function(e){return ce.ToNumber(e)>>0},ToUint32:function(e){return ce.ToNumber(e)>>>0},ToNumber:function(e){if(g(e)===\"[object Symbol]\"){throw new TypeError(\"Cannot convert a Symbol value to a number\")}return+e},ToInteger:function(e){var t=ce.ToNumber(e);if(X(t)){return 0}if(t===0||!K(t)){return t}return(t>0?1:-1)*_(k(t))},ToLength:function(e){var t=ce.ToInteger(e);if(t<=0){return 0}if(t>Number.MAX_SAFE_INTEGER){return Number.MAX_SAFE_INTEGER}return t},SameValue:function(e,t){if(e===t){if(e===0){return 1/e===1/t}return true}return X(e)&&X(t)},SameValueZero:function(e,t){return e===t||X(e)&&X(t)},IsIterable:function(e){return ce.TypeIsObject(e)&&(typeof e[ie]!==\"undefined\"||te(e))},GetIterator:function(e){if(te(e)){return new q(e,\"value\")}var t=ce.GetMethod(e,ie);if(!ce.IsCallable(t)){throw new TypeError(\"value is not an iterable\")}var r=ce.Call(t,e);if(!ce.TypeIsObject(r)){throw new TypeError(\"bad iterator\")}return r},GetMethod:function(e,t){var r=ce.ToObject(e)[t];if(se(r)){return void 0}if(!ce.IsCallable(r)){throw new TypeError(\"Method not callable: \"+t)}return r},IteratorComplete:function(e){return!!e.done},IteratorClose:function(e,t){var r=ce.GetMethod(e,\"return\");if(r===void 0){return}var n,o;try{n=ce.Call(r,e)}catch(i){o=i}if(t){return}if(o){throw o}if(!ce.TypeIsObject(n)){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(!ce.TypeIsObject(t)){throw new TypeError(\"bad iterator\")}return t},IteratorStep:function(e){var t=ce.IteratorNext(e);var r=ce.IteratorComplete(t);return r?false:t},Construct:function(e,t,r,n){var o=typeof r===\"undefined\"?e:r;if(!n&&ae.construct){return ae.construct(e,t,o)}var i=o.prototype;if(!ce.TypeIsObject(i)){i=Object.prototype}var a=O(i);var u=ce.Call(e,a,t);return ce.TypeIsObject(u)?u:a},SpeciesConstructor:function(e,t){var r=e.constructor;if(r===void 0){return t}if(!ce.TypeIsObject(r)){throw new TypeError(\"Bad constructor\")}var n=r[J];if(se(n)){return t}if(!ce.IsConstructor(n)){throw new TypeError(\"Bad @@species\")}return n},CreateHTML:function(e,t,r,n){var o=ce.ToString(e);var i=\"<\"+t;if(r!==\"\"){var a=ce.ToString(n);var u=a.replace(/\"/g,\"&quot;\");i+=\" \"+r+'=\"'+u+'\"'}var f=i+\">\";var s=f+o;return s+\"</\"+t+\">\"},IsRegExp:function IsRegExp(e){if(!ce.TypeIsObject(e)){return false}var t=e[$.match];if(typeof t!==\"undefined\"){return!!t}return re.regex(e)},ToString:function ToString(e){return ue(e)}};if(s&&oe){var le=function defineWellKnownSymbol(e){if(re.symbol($[e])){return $[e]}var t=$[\"for\"](\"Symbol.\"+e);Object.defineProperty($,e,{configurable:false,enumerable:false,writable:false,value:t});return t};if(!re.symbol($.search)){var pe=le(\"search\");var ve=String.prototype.search;h(RegExp.prototype,pe,function search(e){return ce.Call(ve,e,[this])});var ye=function search(e){var t=ce.RequireObjectCoercible(this);if(!se(e)){var r=ce.GetMethod(e,pe);if(typeof r!==\"undefined\"){return ce.Call(r,e,[t])}}return ce.Call(ve,t,[ce.ToString(e)])};ne(String.prototype,\"search\",ye)}if(!re.symbol($.replace)){var he=le(\"replace\");var be=String.prototype.replace;h(RegExp.prototype,he,function replace(e,t){return ce.Call(be,e,[this,t])});var ge=function replace(e,t){var r=ce.RequireObjectCoercible(this);if(!se(e)){var n=ce.GetMethod(e,he);if(typeof n!==\"undefined\"){return ce.Call(n,e,[r,t])}}return ce.Call(be,r,[ce.ToString(e),t])};ne(String.prototype,\"replace\",ge)}if(!re.symbol($.split)){var de=le(\"split\");var me=String.prototype.split;h(RegExp.prototype,de,function split(e,t){return ce.Call(me,e,[this,t])});var Oe=function split(e,t){var r=ce.RequireObjectCoercible(this);if(!se(e)){var n=ce.GetMethod(e,de);if(typeof n!==\"undefined\"){return ce.Call(n,e,[r,t])}}return ce.Call(me,r,[ce.ToString(e),t])};ne(String.prototype,\"split\",Oe)}var we=re.symbol($.match);var je=we&&function(){var e={};e[$.match]=function(){return 42};return\"a\".match(e)!==42}();if(!we||je){var Se=le(\"match\");var Te=String.prototype.match;h(RegExp.prototype,Se,function match(e){return ce.Call(Te,e,[this])});var Ie=function match(e){var t=ce.RequireObjectCoercible(this);if(!se(e)){var r=ce.GetMethod(e,Se);if(typeof r!==\"undefined\"){return ce.Call(r,e,[t])}}return ce.Call(Te,t,[ce.ToString(e)])};ne(String.prototype,\"match\",Ie)}}var Ee=function wrapConstructor(e,t,r){m.preserveToString(t,e);if(Object.setPrototypeOf){Object.setPrototypeOf(e,t)}if(s){l(Object.getOwnPropertyNames(e),function(n){if(n in W||r[n]){return}m.proxy(e,n,t)})}else{l(Object.keys(e),function(n){if(n in W||r[n]){return}t[n]=e[n]})}t.prototype=e.prototype;m.redefine(e.prototype,\"constructor\",t)};var Pe=function(){return this};var Ce=function(e){if(s&&!z(e,J)){m.getter(e,J,Pe)}};var Me=function(e,t){var r=t||function iterator(){return this};h(e,ie,r);if(!e[ie]&&re.symbol(ie)){e[ie]=r}};var xe=function createDataProperty(e,t,r){if(s){Object.defineProperty(e,t,{configurable:true,enumerable:true,writable:true,value:r})}else{e[t]=r}};var Ne=function createDataPropertyOrThrow(e,t,r){xe(e,t,r);if(!ce.SameValue(e[t],r)){throw new TypeError(\"property is nonconfigurable\")}};var Ae=function(e,t,r,n){if(!ce.TypeIsObject(e)){throw new TypeError(\"Constructor requires `new`: \"+t.name)}var o=t.prototype;if(!ce.TypeIsObject(o)){o=r}var i=O(o);for(var a in n){if(z(n,a)){var u=n[a];h(i,a,u,true)}}return i};if(String.fromCodePoint&&String.fromCodePoint.length!==1){var Re=String.fromCodePoint;ne(String,\"fromCodePoint\",function fromCodePoint(e){return ce.Call(Re,this,arguments)})}var _e={fromCodePoint:function fromCodePoint(e){var t=[];var r;for(var n=0,o=arguments.length;n<o;n++){r=Number(arguments[n]);if(!ce.SameValue(r,ce.ToInteger(r))||r<0||r>1114111){throw new RangeError(\"Invalid code point \"+r)}if(r<65536){M(t,String.fromCharCode(r))}else{r-=65536;M(t,String.fromCharCode((r>>10)+55296));M(t,String.fromCharCode(r%1024+56320))}}return t.join(\"\")},raw:function raw(e){var t=ce.ToObject(e,\"bad callSite\");var r=ce.ToObject(t.raw,\"bad raw value\");var n=r.length;var o=ce.ToLength(n);if(o<=0){return\"\"}var i=[];var a=0;var u,f,s,c;while(a<o){u=ce.ToString(a);s=ce.ToString(r[u]);M(i,s);if(a+1>=o){break}f=a+1<arguments.length?arguments[a+1]:\"\";c=ce.ToString(f);M(i,c);a+=1}return i.join(\"\")}};if(String.raw&&String.raw({raw:{0:\"x\",1:\"y\",length:2}})!==\"xy\"){ne(String,\"raw\",_e.raw)}b(String,_e);var ke=function repeat(e,t){if(t<1){return\"\"}if(t%2){return repeat(e,t-1)+e}var r=repeat(e,t/2);return r+r};var Le=Infinity;var Fe={repeat:function repeat(e){var t=ce.ToString(ce.RequireObjectCoercible(this));var r=ce.ToInteger(e);if(r<0||r>=Le){throw new RangeError(\"repeat count must be less than infinity and not overflow maximum string size\")}return ke(t,r)},startsWith:function startsWith(e){var t=ce.ToString(ce.RequireObjectCoercible(this));if(ce.IsRegExp(e)){throw new TypeError('Cannot call method \"startsWith\" with a regex')}var r=ce.ToString(e);var n;if(arguments.length>1){n=arguments[1]}var o=A(ce.ToInteger(n),0);return C(t,o,o+r.length)===r},endsWith:function endsWith(e){var t=ce.ToString(ce.RequireObjectCoercible(this));if(ce.IsRegExp(e)){throw new TypeError('Cannot call method \"endsWith\" with a regex')}var r=ce.ToString(e);var n=t.length;var o;if(arguments.length>1){o=arguments[1]}var i=typeof o===\"undefined\"?n:ce.ToInteger(o);var a=R(A(i,0),n);return C(t,a-r.length,a)===r},includes:function includes(e){if(ce.IsRegExp(e)){throw new TypeError('\"includes\" does not accept a RegExp')}var t=ce.ToString(e);var r;if(arguments.length>1){r=arguments[1]}return I(this,t,r)!==-1},codePointAt:function codePointAt(e){var t=ce.ToString(ce.RequireObjectCoercible(this));var r=ce.ToInteger(e);var n=t.length;if(r>=0&&r<n){var o=t.charCodeAt(r);var i=r+1===n;if(o<55296||o>56319||i){return o}var a=t.charCodeAt(r+1);if(a<56320||a>57343){return o}return(o-55296)*1024+(a-56320)+65536}}};if(String.prototype.includes&&\"a\".includes(\"a\",Infinity)!==false){ne(String.prototype,\"includes\",Fe.includes)}if(String.prototype.startsWith&&String.prototype.endsWith){var De=i(function(){return\"/a/\".startsWith(/a/)});var ze=a(function(){return\"abc\".startsWith(\"a\",Infinity)===false});if(!De||!ze){ne(String.prototype,\"startsWith\",Fe.startsWith);ne(String.prototype,\"endsWith\",Fe.endsWith)}}if(oe){var qe=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".startsWith(e)});if(!qe){ne(String.prototype,\"startsWith\",Fe.startsWith)}var We=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".endsWith(e)});if(!We){ne(String.prototype,\"endsWith\",Fe.endsWith)}var Ge=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".includes(e)});if(!Ge){ne(String.prototype,\"includes\",Fe.includes)}}b(String.prototype,Fe);var He=[\"\\t\\n\\x0B\\f\\r \\xa0\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\",\"\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\u2028\",\"\\u2029\\ufeff\"].join(\"\");var Ve=new RegExp(\"(^[\"+He+\"]+)|([\"+He+\"]+$)\",\"g\");var Be=function trim(){return ce.ToString(ce.RequireObjectCoercible(this)).replace(Ve,\"\")};var Ue=[\"\\x85\",\"\\u200b\",\"\\ufffe\"].join(\"\");var $e=new RegExp(\"[\"+Ue+\"]\",\"g\");var Je=/^[-+]0x[0-9a-f]+$/i;var Xe=Ue.trim().length!==Ue.length;h(String.prototype,\"trim\",Be,Xe);var Ke=function(e){return{value:e,done:arguments.length===0}};var Ze=function(e){ce.RequireObjectCoercible(e);this._s=ce.ToString(e);this._i=0};Ze.prototype.next=function(){var e=this._s;var t=this._i;if(typeof e===\"undefined\"||t>=e.length){this._s=void 0;return Ke()}var r=e.charCodeAt(t);var n,o;if(r<55296||r>56319||t+1===e.length){o=1}else{n=e.charCodeAt(t+1);o=n<56320||n>57343?1:2}this._i=t+o;return Ke(e.substr(t,o))};Me(Ze.prototype);Me(String.prototype,function(){return new Ze(this)});var Ye={from:function from(e){var r=this;var n;if(arguments.length>1){n=arguments[1]}var o,i;if(typeof n===\"undefined\"){o=false}else{if(!ce.IsCallable(n)){throw new TypeError(\"Array.from: when provided, the second argument must be a function\")}if(arguments.length>2){i=arguments[2]}o=true}var a=typeof(te(e)||ce.GetMethod(e,ie))!==\"undefined\";var u,f,s;if(a){f=ce.IsConstructor(r)?Object(new r):[];var c=ce.GetIterator(e);var l,p;s=0;while(true){l=ce.IteratorStep(c);if(l===false){break}p=l.value;try{if(o){p=typeof i===\"undefined\"?n(p,s):t(n,i,p,s)}f[s]=p}catch(v){ce.IteratorClose(c,true);throw v}s+=1}u=s}else{var y=ce.ToObject(e);u=ce.ToLength(y.length);f=ce.IsConstructor(r)?Object(new r(u)):new Array(u);var h;for(s=0;s<u;++s){h=y[s];if(o){h=typeof i===\"undefined\"?n(h,s):t(n,i,h,s)}Ne(f,s,h)}}f.length=u;return f},of:function of(){var e=arguments.length;var t=this;var n=r(t)||!ce.IsCallable(t)?new Array(e):ce.Construct(t,[e]);for(var o=0;o<e;++o){Ne(n,o,arguments[o])}n.length=e;return n}};b(Array,Ye);Ce(Array);q=function(e,t){this.i=0;this.array=e;this.kind=t};b(q.prototype,{next:function(){var e=this.i;var t=this.array;if(!(this instanceof q)){throw new TypeError(\"Not an ArrayIterator\")}if(typeof t!==\"undefined\"){var r=ce.ToLength(t.length);for(;e<r;e++){var n=this.kind;var o;if(n===\"key\"){o=e}else if(n===\"value\"){o=t[e]}else if(n===\"entry\"){o=[e,t[e]]}this.i=e+1;return Ke(o)}}this.array=void 0;return Ke()}});Me(q.prototype);var Qe=Array.of===Ye.of||function(){var e=function Foo(e){this.length=e};e.prototype=[];var t=Array.of.apply(e,[1,2]);return t instanceof e&&t.length===2}();if(!Qe){ne(Array,\"of\",Ye.of)}var et={copyWithin:function copyWithin(e,t){var r=ce.ToObject(this);var n=ce.ToLength(r.length);var o=ce.ToInteger(e);var i=ce.ToInteger(t);var a=o<0?A(n+o,0):R(o,n);var u=i<0?A(n+i,0):R(i,n);var f;if(arguments.length>2){f=arguments[2]}var s=typeof f===\"undefined\"?n:ce.ToInteger(f);var c=s<0?A(n+s,0):R(s,n);var l=R(c-u,n-a);var p=1;if(u<a&&a<u+l){p=-1;u+=l-1;a+=l-1}while(l>0){if(u in r){r[a]=r[u]}else{delete r[a]}u+=p;a+=p;l-=1}return r},fill:function fill(e){var t;if(arguments.length>1){t=arguments[1]}var r;if(arguments.length>2){r=arguments[2]}var n=ce.ToObject(this);var o=ce.ToLength(n.length);t=ce.ToInteger(typeof t===\"undefined\"?0:t);r=ce.ToInteger(typeof r===\"undefined\"?o:r);var i=t<0?A(o+t,0):R(t,o);var a=r<0?o+r:r;for(var u=i;u<o&&u<a;++u){n[u]=e}return n},find:function find(e){var r=ce.ToObject(this);var n=ce.ToLength(r.length);if(!ce.IsCallable(e)){throw new TypeError(\"Array#find: predicate must be a function\")}var o=arguments.length>1?arguments[1]:null;for(var i=0,a;i<n;i++){a=r[i];if(o){if(t(e,o,a,i,r)){return a}}else if(e(a,i,r)){return a}}},findIndex:function findIndex(e){var r=ce.ToObject(this);var n=ce.ToLength(r.length);if(!ce.IsCallable(e)){throw new TypeError(\"Array#findIndex: predicate must be a function\")}var o=arguments.length>1?arguments[1]:null;for(var i=0;i<n;i++){if(o){if(t(e,o,r[i],i,r)){return i}}else if(e(r[i],i,r)){return i}}return-1},keys:function keys(){return new q(this,\"key\")},values:function values(){return new q(this,\"value\")},entries:function entries(){return new q(this,\"entry\")}};if(Array.prototype.keys&&!ce.IsCallable([1].keys().next)){delete Array.prototype.keys}if(Array.prototype.entries&&!ce.IsCallable([1].entries().next)){delete Array.prototype.entries}if(Array.prototype.keys&&Array.prototype.entries&&!Array.prototype.values&&Array.prototype[ie]){b(Array.prototype,{values:Array.prototype[ie]});if(re.symbol($.unscopables)){Array.prototype[$.unscopables].values=true}}if(c&&Array.prototype.values&&Array.prototype.values.name!==\"values\"){var tt=Array.prototype.values;ne(Array.prototype,\"values\",function values(){return ce.Call(tt,this,arguments)});h(Array.prototype,ie,Array.prototype.values,true)}b(Array.prototype,et);if(1/[true].indexOf(true,-0)<0){h(Array.prototype,\"indexOf\",function indexOf(e){var t=E(this,arguments);if(t===0&&1/t<0){return 0}return t},true)}Me(Array.prototype,function(){return this.values()});if(Object.getPrototypeOf){Me(Object.getPrototypeOf([].values()))}var rt=function(){return a(function(){return Array.from({length:-1}).length===0})}();var nt=function(){var e=Array.from([0].entries());return e.length===1&&r(e[0])&&e[0][0]===0&&e[0][1]===0}();if(!rt||!nt){ne(Array,\"from\",Ye.from)}var ot=function(){return a(function(){return Array.from([0],void 0)})}();if(!ot){var it=Array.from;ne(Array,\"from\",function from(e){if(arguments.length>1&&typeof arguments[1]!==\"undefined\"){return ce.Call(it,this,arguments)}else{return t(it,this,e)}})}var at=-(Math.pow(2,32)-1);var ut=function(e,r){var n={length:at};n[r?(n.length>>>0)-1:0]=true;return a(function(){t(e,n,function(){throw new RangeError(\"should not reach here\")},[]);return true})};if(!ut(Array.prototype.forEach)){var ft=Array.prototype.forEach;ne(Array.prototype,\"forEach\",function forEach(e){return ce.Call(ft,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.map)){var st=Array.prototype.map;ne(Array.prototype,\"map\",function map(e){return ce.Call(st,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.filter)){var ct=Array.prototype.filter;ne(Array.prototype,\"filter\",function filter(e){return ce.Call(ct,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.some)){var lt=Array.prototype.some;ne(Array.prototype,\"some\",function some(e){return ce.Call(lt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.every)){var pt=Array.prototype.every;ne(Array.prototype,\"every\",function every(e){return ce.Call(pt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.reduce)){var vt=Array.prototype.reduce;ne(Array.prototype,\"reduce\",function reduce(e){return ce.Call(vt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.reduceRight,true)){var yt=Array.prototype.reduceRight;ne(Array.prototype,\"reduceRight\",function reduceRight(e){return ce.Call(yt,this.length>=0?this:[],arguments)},true)}var ht=Number(\"0o10\")!==8;var bt=Number(\"0b10\")!==2;var gt=y(Ue,function(e){return Number(e+0+e)===0});if(ht||bt||gt){var dt=Number;var mt=/^0b[01]+$/i;var Ot=/^0o[0-7]+$/i;var wt=mt.test.bind(mt);var jt=Ot.test.bind(Ot);var St=function(e){var t;if(typeof e.valueOf===\"function\"){t=e.valueOf();if(re.primitive(t)){return t}}if(typeof e.toString===\"function\"){t=e.toString();if(re.primitive(t)){return t}}throw new TypeError(\"No default value\")};var Tt=$e.test.bind($e);var It=Je.test.bind(Je);var Et=function(){var e=function Number(t){var r;if(arguments.length>0){r=re.primitive(t)?t:St(t,\"number\")}else{r=0}if(typeof r===\"string\"){r=ce.Call(Be,r);if(wt(r)){r=parseInt(C(r,2),2)}else if(jt(r)){r=parseInt(C(r,2),8)}else if(Tt(r)||It(r)){r=NaN}}var n=this;var o=a(function(){dt.prototype.valueOf.call(n);return true});if(n instanceof e&&!o){return new dt(r)}return dt(r)};return e}();Ee(dt,Et,{});b(Et,{NaN:dt.NaN,MAX_VALUE:dt.MAX_VALUE,MIN_VALUE:dt.MIN_VALUE,NEGATIVE_INFINITY:dt.NEGATIVE_INFINITY,POSITIVE_INFINITY:dt.POSITIVE_INFINITY});Number=Et;m.redefine(S,\"Number\",Et)}var Pt=Math.pow(2,53)-1;b(Number,{MAX_SAFE_INTEGER:Pt,MIN_SAFE_INTEGER:-Pt,EPSILON:2.220446049250313e-16,parseInt:S.parseInt,parseFloat:S.parseFloat,isFinite:K,isInteger:function isInteger(e){return K(e)&&ce.ToInteger(e)===e},isSafeInteger:function isSafeInteger(e){return Number.isInteger(e)&&k(e)<=Number.MAX_SAFE_INTEGER},isNaN:X});h(Number,\"parseInt\",S.parseInt,Number.parseInt!==S.parseInt);if([,1].find(function(){return true})===1){ne(Array.prototype,\"find\",et.find)}if([,1].findIndex(function(){return true})!==0){ne(Array.prototype,\"findIndex\",et.findIndex)}var Ct=Function.bind.call(Function.bind,Object.prototype.propertyIsEnumerable);var Mt=function ensureEnumerable(e,t){if(s&&Ct(e,t)){Object.defineProperty(e,t,{enumerable:false})}};var xt=function sliceArgs(){var e=Number(this);var t=arguments.length;var r=t-e;var n=new Array(r<0?0:r);for(var o=e;o<t;++o){n[o-e]=arguments[o]}return n};var Nt=function assignTo(e){return function assignToSource(t,r){t[r]=e[r];return t}};var At=function(e,t){var r=n(Object(t));var o;if(ce.IsCallable(Object.getOwnPropertySymbols)){o=v(Object.getOwnPropertySymbols(Object(t)),Ct(t))}return p(P(r,o||[]),Nt(t),e)};var Rt={assign:function(e,t){var r=ce.ToObject(e,\"Cannot convert undefined or null to object\");return p(ce.Call(xt,1,arguments),At,r)},is:function is(e,t){return ce.SameValue(e,t)}};var _t=Object.assign&&Object.preventExtensions&&function(){var e=Object.preventExtensions({1:2});try{Object.assign(e,\"xy\")}catch(t){return e[1]===\"y\"}}();if(_t){ne(Object,\"assign\",Rt.assign)}b(Object,Rt);if(s){var kt={setPrototypeOf:function(e,r){var n;var o=function(e,t){if(!ce.TypeIsObject(e)){throw new TypeError(\"cannot set prototype on a non-object\")}if(!(t===null||ce.TypeIsObject(t))){throw new TypeError(\"can only set prototype to an object or null\"+t)}};var i=function(e,r){o(e,r);t(n,e,r);return e};try{n=e.getOwnPropertyDescriptor(e.prototype,r).set;t(n,{},null)}catch(a){if(e.prototype!=={}[r]){return}n=function(e){this[r]=e};i.polyfill=i(i({},null),e.prototype)instanceof e}return i}(Object,\"__proto__\")};b(Object,kt)}if(Object.setPrototypeOf&&Object.getPrototypeOf&&Object.getPrototypeOf(Object.setPrototypeOf({},null))!==null&&Object.getPrototypeOf(Object.create(null))===null){(function(){var e=Object.create(null);var t=Object.getPrototypeOf;var r=Object.setPrototypeOf;Object.getPrototypeOf=function(r){var n=t(r);return n===e?null:n};Object.setPrototypeOf=function(t,n){var o=n===null?e:n;return r(t,o)};Object.setPrototypeOf.polyfill=false})()}var Lt=!i(function(){return Object.keys(\"foo\")});if(!Lt){var Ft=Object.keys;ne(Object,\"keys\",function keys(e){return Ft(ce.ToObject(e))});n=Object.keys}var Dt=i(function(){return Object.keys(/a/g)});if(Dt){var zt=Object.keys;ne(Object,\"keys\",function keys(e){if(re.regex(e)){var t=[];for(var r in e){if(z(e,r)){M(t,r)}}return t}return zt(e)});n=Object.keys}if(Object.getOwnPropertyNames){var qt=!i(function(){return Object.getOwnPropertyNames(\"foo\")});if(!qt){var Wt=typeof window===\"object\"?Object.getOwnPropertyNames(window):[];var Gt=Object.getOwnPropertyNames;ne(Object,\"getOwnPropertyNames\",function getOwnPropertyNames(e){var t=ce.ToObject(e);if(g(t)===\"[object Window]\"){try{return Gt(t)}catch(r){return P([],Wt)}}return Gt(t)})}}if(Object.getOwnPropertyDescriptor){var Ht=!i(function(){return Object.getOwnPropertyDescriptor(\"foo\",\"bar\")});if(!Ht){var Vt=Object.getOwnPropertyDescriptor;ne(Object,\"getOwnPropertyDescriptor\",function getOwnPropertyDescriptor(e,t){return Vt(ce.ToObject(e),t)})}}if(Object.seal){var Bt=!i(function(){return Object.seal(\"foo\")});if(!Bt){var Ut=Object.seal;ne(Object,\"seal\",function seal(e){if(!ce.TypeIsObject(e)){return e}return Ut(e)})}}if(Object.isSealed){var $t=!i(function(){return Object.isSealed(\"foo\")});if(!$t){var Jt=Object.isSealed;ne(Object,\"isSealed\",function isSealed(e){if(!ce.TypeIsObject(e)){return true}return Jt(e)})}}if(Object.freeze){var Xt=!i(function(){return Object.freeze(\"foo\")});if(!Xt){var Kt=Object.freeze;ne(Object,\"freeze\",function freeze(e){if(!ce.TypeIsObject(e)){return e}return Kt(e)})}}if(Object.isFrozen){var Zt=!i(function(){return Object.isFrozen(\"foo\")});if(!Zt){var Yt=Object.isFrozen;ne(Object,\"isFrozen\",function isFrozen(e){if(!ce.TypeIsObject(e)){return true}return Yt(e)})}}if(Object.preventExtensions){var Qt=!i(function(){return Object.preventExtensions(\"foo\")});if(!Qt){var er=Object.preventExtensions;ne(Object,\"preventExtensions\",function preventExtensions(e){if(!ce.TypeIsObject(e)){return e}return er(e)})}}if(Object.isExtensible){var tr=!i(function(){return Object.isExtensible(\"foo\")});if(!tr){var rr=Object.isExtensible;ne(Object,\"isExtensible\",function isExtensible(e){if(!ce.TypeIsObject(e)){return false}return rr(e)})}}if(Object.getPrototypeOf){var nr=!i(function(){return Object.getPrototypeOf(\"foo\")});if(!nr){var or=Object.getPrototypeOf;ne(Object,\"getPrototypeOf\",function getPrototypeOf(e){return or(ce.ToObject(e))})}}var ir=s&&function(){var e=Object.getOwnPropertyDescriptor(RegExp.prototype,\"flags\");return e&&ce.IsCallable(e.get)}();if(s&&!ir){var ar=function flags(){if(!ce.TypeIsObject(this)){throw new TypeError(\"Method called on incompatible type: must be an object.\")}var e=\"\";if(this.global){e+=\"g\"}if(this.ignoreCase){e+=\"i\"}if(this.multiline){e+=\"m\"}if(this.unicode){e+=\"u\"}if(this.sticky){e+=\"y\"}return e};m.getter(RegExp.prototype,\"flags\",ar)}var ur=s&&a(function(){return String(new RegExp(/a/g,\"i\"))===\"/a/i\"});var fr=oe&&s&&function(){var e=/./;e[$.match]=false;return RegExp(e)===e}();var sr=a(function(){return RegExp.prototype.toString.call({source:\"abc\"})===\"/abc/\"});var cr=sr&&a(function(){return RegExp.prototype.toString.call({source:\"a\",flags:\"b\"})===\"/a/b\"});if(!sr||!cr){var lr=RegExp.prototype.toString;h(RegExp.prototype,\"toString\",function toString(){var e=ce.RequireObjectCoercible(this);if(re.regex(e)){return t(lr,e)}var r=ue(e.source);var n=ue(e.flags);return\"/\"+r+\"/\"+n},true);m.preserveToString(RegExp.prototype.toString,lr)}if(s&&(!ur||fr)){var pr=Object.getOwnPropertyDescriptor(RegExp.prototype,\"flags\").get;var vr=Object.getOwnPropertyDescriptor(RegExp.prototype,\"source\")||{};var yr=function(){return this.source};var hr=ce.IsCallable(vr.get)?vr.get:yr;var br=RegExp;var gr=function(){return function RegExp(e,t){var r=ce.IsRegExp(e);var n=this instanceof RegExp;if(!n&&r&&typeof t===\"undefined\"&&e.constructor===RegExp){return e}var o=e;var i=t;if(re.regex(e)){o=ce.Call(hr,e);i=typeof t===\"undefined\"?ce.Call(pr,e):t;return new RegExp(o,i)}else if(r){o=e.source;i=typeof t===\"undefined\"?e.flags:t}return new br(e,t)}}();Ee(br,gr,{$input:true});RegExp=gr;m.redefine(S,\"RegExp\",gr)}if(s){var dr={input:\"$_\",lastMatch:\"$&\",lastParen:\"$+\",leftContext:\"$`\",rightContext:\"$'\"};l(n(dr),function(e){if(e in RegExp&&!(dr[e]in RegExp)){m.getter(RegExp,dr[e],function get(){return RegExp[e]})}})}Ce(RegExp);var mr=1/Number.EPSILON;var Or=function roundTiesToEven(e){return e+mr-mr};var wr=Math.pow(2,-23);var jr=Math.pow(2,127)*(2-wr);var Sr=Math.pow(2,-126);var Tr=Math.E;var Ir=Math.LOG2E;var Er=Math.LOG10E;var Pr=Number.prototype.clz;delete Number.prototype.clz;var Cr={acosh:function acosh(e){var t=Number(e);if(X(t)||e<1){return NaN}if(t===1){return 0}if(t===Infinity){return t}var r=1/(t*t);if(t<2){return Y(t-1+D(1-r)*t)}var n=t/2;return Y(n+D(1-r)*n-1)+1/Ir},asinh:function asinh(e){var t=Number(e);if(t===0||!T(t)){return t}var r=k(t);var n=r*r;var o=Z(t);if(r<1){return o*Y(r+n/(D(n+1)+1))}return o*(Y(r/2+D(1+1/n)*r/2-1)+1/Ir)},atanh:function atanh(e){var t=Number(e);if(t===0){return t}if(t===-1){return-Infinity}if(t===1){return Infinity}if(X(t)||t<-1||t>1){return NaN}var r=k(t);return Z(t)*Y(2*r/(1-r))/2},cbrt:function cbrt(e){var t=Number(e);if(t===0){return t}var r=t<0;var n;if(r){t=-t}if(t===Infinity){n=Infinity}else{n=L(F(t)/3);n=(t/(n*n)+2*n)/3}return r?-n:n},clz32:function clz32(e){var t=Number(e);var r=ce.ToUint32(t);if(r===0){return 32}return Pr?ce.Call(Pr,r):31-_(F(r+.5)*Ir)},cosh:function cosh(e){var t=Number(e);if(t===0){return 1}if(X(t)){return NaN}if(!T(t)){return Infinity}var r=L(k(t)-1);return(r+1/(r*Tr*Tr))*(Tr/2)},expm1:function expm1(e){var t=Number(e);if(t===-Infinity){return-1}if(!T(t)||t===0){return t}if(k(t)>.5){return L(t)-1}var r=t;var n=0;var o=1;while(n+r!==n){n+=r;o+=1;r*=t/o}return n},hypot:function hypot(e,t){var r=0;var n=0;for(var o=0;o<arguments.length;++o){var i=k(Number(arguments[o]));if(n<i){r*=n/i*(n/i);r+=1;n=i}else{r+=i>0?i/n*(i/n):i}}return n===Infinity?Infinity:n*D(r)},log2:function log2(e){return F(e)*Ir},log10:function log10(e){return F(e)*Er},log1p:Y,sign:Z,sinh:function sinh(e){var t=Number(e);if(!T(t)||t===0){return t}var r=k(t);if(r<1){var n=Math.expm1(r);return Z(t)*n*(1+1/(n+1))/2}var o=L(r-1);return Z(t)*(o-1/(o*Tr*Tr))*(Tr/2)},tanh:function tanh(e){var t=Number(e);if(X(t)||t===0){return t}if(t>=20){return 1}if(t<=-20){return-1}return(Math.expm1(t)-Math.expm1(-t))/(L(t)+L(-t))},trunc:function trunc(e){var t=Number(e);return t<0?-_(-t):_(t)},imul:function imul(e,t){var r=ce.ToUint32(e);var n=ce.ToUint32(t);var o=r>>>16&65535;var i=r&65535;var a=n>>>16&65535;var u=n&65535;return i*u+(o*u+i*a<<16>>>0)|0},fround:function fround(e){var t=Number(e);if(t===0||t===Infinity||t===-Infinity||X(t)){return t}var r=Z(t);var n=k(t);if(n<Sr){return r*Or(n/Sr/wr)*Sr*wr}var o=(1+wr/Number.EPSILON)*n;var i=o-(o-n);if(i>jr||X(i)){return r*Infinity}return r*i}};var Mr=function withinULPDistance(e,t,r){return k(1-e/t)/Number.EPSILON<(r||8)};b(Math,Cr);h(Math,\"sinh\",Cr.sinh,Math.sinh(710)===Infinity);h(Math,\"cosh\",Cr.cosh,Math.cosh(710)===Infinity);h(Math,\"log1p\",Cr.log1p,Math.log1p(-1e-17)!==-1e-17);h(Math,\"asinh\",Cr.asinh,Math.asinh(-1e7)!==-Math.asinh(1e7));h(Math,\"asinh\",Cr.asinh,Math.asinh(1e300)===Infinity);h(Math,\"atanh\",Cr.atanh,Math.atanh(1e-300)===0);h(Math,\"tanh\",Cr.tanh,Math.tanh(-2e-17)!==-2e-17);\nh(Math,\"acosh\",Cr.acosh,Math.acosh(Number.MAX_VALUE)===Infinity);h(Math,\"acosh\",Cr.acosh,!Mr(Math.acosh(1+Number.EPSILON),Math.sqrt(2*Number.EPSILON)));h(Math,\"cbrt\",Cr.cbrt,!Mr(Math.cbrt(1e-300),1e-100));h(Math,\"sinh\",Cr.sinh,Math.sinh(-2e-17)!==-2e-17);var xr=Math.expm1(10);h(Math,\"expm1\",Cr.expm1,xr>22025.465794806718||xr<22025.465794806718);var Nr=Math.round;var Ar=Math.round(.5-Number.EPSILON/4)===0&&Math.round(-.5+Number.EPSILON/3.99)===1;var Rr=mr+1;var _r=2*mr-1;var kr=[Rr,_r].every(function(e){return Math.round(e)===e});h(Math,\"round\",function round(e){var t=_(e);var r=t===-1?-0:t+1;return e-t<.5?t:r},!Ar||!kr);m.preserveToString(Math.round,Nr);var Lr=Math.imul;if(Math.imul(4294967295,5)!==-5){Math.imul=Cr.imul;m.preserveToString(Math.imul,Lr)}if(Math.imul.length!==2){ne(Math,\"imul\",function imul(e,t){return ce.Call(Lr,Math,arguments)})}var Fr=function(){var e=S.setTimeout;if(typeof e!==\"function\"&&typeof e!==\"object\"){return}ce.IsPromise=function(e){if(!ce.TypeIsObject(e)){return false}if(typeof e._promise===\"undefined\"){return false}return true};var r=function(e){if(!ce.IsConstructor(e)){throw new TypeError(\"Bad promise constructor\")}var t=this;var r=function(e,r){if(t.resolve!==void 0||t.reject!==void 0){throw new TypeError(\"Bad Promise implementation!\")}t.resolve=e;t.reject=r};t.resolve=void 0;t.reject=void 0;t.promise=new e(r);if(!(ce.IsCallable(t.resolve)&&ce.IsCallable(t.reject))){throw new TypeError(\"Bad promise constructor\")}};var n;if(typeof window!==\"undefined\"&&ce.IsCallable(window.postMessage)){n=function(){var e=[];var t=\"zero-timeout-message\";var r=function(r){M(e,r);window.postMessage(t,\"*\")};var n=function(r){if(r.source===window&&r.data===t){r.stopPropagation();if(e.length===0){return}var n=N(e);n()}};window.addEventListener(\"message\",n,true);return r}}var o=function(){var e=S.Promise;var t=e&&e.resolve&&e.resolve();return t&&function(e){return t.then(e)}};var i=ce.IsCallable(S.setImmediate)?S.setImmediate:typeof process===\"object\"&&process.nextTick?process.nextTick:o()||(ce.IsCallable(n)?n():function(t){e(t,0)});var a=function(e){return e};var u=function(e){throw e};var f=0;var s=1;var c=2;var l=0;var p=1;var v=2;var y={};var h=function(e,t,r){i(function(){g(e,t,r)})};var g=function(e,t,r){var n,o;if(t===y){return e(r)}try{n=e(r);o=t.resolve}catch(i){n=i;o=t.reject}o(n)};var d=function(e,t){var r=e._promise;var n=r.reactionLength;if(n>0){h(r.fulfillReactionHandler0,r.reactionCapability0,t);r.fulfillReactionHandler0=void 0;r.rejectReactions0=void 0;r.reactionCapability0=void 0;if(n>1){for(var o=1,i=0;o<n;o++,i+=3){h(r[i+l],r[i+v],t);e[i+l]=void 0;e[i+p]=void 0;e[i+v]=void 0}}}r.result=t;r.state=s;r.reactionLength=0};var m=function(e,t){var r=e._promise;var n=r.reactionLength;if(n>0){h(r.rejectReactionHandler0,r.reactionCapability0,t);r.fulfillReactionHandler0=void 0;r.rejectReactions0=void 0;r.reactionCapability0=void 0;if(n>1){for(var o=1,i=0;o<n;o++,i+=3){h(r[i+p],r[i+v],t);e[i+l]=void 0;e[i+p]=void 0;e[i+v]=void 0}}}r.result=t;r.state=c;r.reactionLength=0};var O=function(e){var t=false;var r=function(r){var n;if(t){return}t=true;if(r===e){return m(e,new TypeError(\"Self resolution\"))}if(!ce.TypeIsObject(r)){return d(e,r)}try{n=r.then}catch(o){return m(e,o)}if(!ce.IsCallable(n)){return d(e,r)}i(function(){j(e,r,n)})};var n=function(r){if(t){return}t=true;return m(e,r)};return{resolve:r,reject:n}};var w=function(e,r,n,o){if(e===I){t(e,r,n,o,y)}else{t(e,r,n,o)}};var j=function(e,t,r){var n=O(e);var o=n.resolve;var i=n.reject;try{w(r,t,o,i)}catch(a){i(a)}};var T,I;var E=function(){var e=function Promise(t){if(!(this instanceof e)){throw new TypeError('Constructor Promise requires \"new\"')}if(this&&this._promise){throw new TypeError(\"Bad construction\")}if(!ce.IsCallable(t)){throw new TypeError(\"not a valid resolver\")}var r=Ae(this,e,T,{_promise:{result:void 0,state:f,reactionLength:0,fulfillReactionHandler0:void 0,rejectReactionHandler0:void 0,reactionCapability0:void 0}});var n=O(r);var o=n.reject;try{t(n.resolve,o)}catch(i){o(i)}return r};return e}();T=E.prototype;var P=function(e,t,r,n){var o=false;return function(i){if(o){return}o=true;t[e]=i;if(--n.count===0){var a=r.resolve;a(t)}}};var C=function(e,t,r){var n=e.iterator;var o=[];var i={count:1};var a,u;var f=0;while(true){try{a=ce.IteratorStep(n);if(a===false){e.done=true;break}u=a.value}catch(s){e.done=true;throw s}o[f]=void 0;var c=t.resolve(u);var l=P(f,o,r,i);i.count+=1;w(c.then,c,l,r.reject);f+=1}if(--i.count===0){var p=r.resolve;p(o)}return r.promise};var x=function(e,t,r){var n=e.iterator;var o,i,a;while(true){try{o=ce.IteratorStep(n);if(o===false){e.done=true;break}i=o.value}catch(u){e.done=true;throw u}a=t.resolve(i);w(a.then,a,r.resolve,r.reject)}return r.promise};b(E,{all:function all(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Promise is not object\")}var n=new r(t);var o,i;try{o=ce.GetIterator(e);i={iterator:o,done:false};return C(i,t,n)}catch(a){var u=a;if(i&&!i.done){try{ce.IteratorClose(o,true)}catch(f){u=f}}var s=n.reject;s(u);return n.promise}},race:function race(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Promise is not object\")}var n=new r(t);var o,i;try{o=ce.GetIterator(e);i={iterator:o,done:false};return x(i,t,n)}catch(a){var u=a;if(i&&!i.done){try{ce.IteratorClose(o,true)}catch(f){u=f}}var s=n.reject;s(u);return n.promise}},reject:function reject(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Bad promise constructor\")}var n=new r(t);var o=n.reject;o(e);return n.promise},resolve:function resolve(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Bad promise constructor\")}if(ce.IsPromise(e)){var n=e.constructor;if(n===t){return e}}var o=new r(t);var i=o.resolve;i(e);return o.promise}});b(T,{\"catch\":function(e){return this.then(null,e)},then:function then(e,t){var n=this;if(!ce.IsPromise(n)){throw new TypeError(\"not a promise\")}var o=ce.SpeciesConstructor(n,E);var i;var b=arguments.length>2&&arguments[2]===y;if(b&&o===E){i=y}else{i=new r(o)}var g=ce.IsCallable(e)?e:a;var d=ce.IsCallable(t)?t:u;var m=n._promise;var O;if(m.state===f){if(m.reactionLength===0){m.fulfillReactionHandler0=g;m.rejectReactionHandler0=d;m.reactionCapability0=i}else{var w=3*(m.reactionLength-1);m[w+l]=g;m[w+p]=d;m[w+v]=i}m.reactionLength+=1}else if(m.state===s){O=m.result;h(g,i,O)}else if(m.state===c){O=m.result;h(d,i,O)}else{throw new TypeError(\"unexpected Promise state\")}return i.promise}});y=new r(E);I=T.then;return E}();if(S.Promise){delete S.Promise.accept;delete S.Promise.defer;delete S.Promise.prototype.chain}if(typeof Fr===\"function\"){b(S,{Promise:Fr});var Dr=w(S.Promise,function(e){return e.resolve(42).then(function(){})instanceof e});var zr=!i(function(){return S.Promise.reject(42).then(null,5).then(null,W)});var qr=i(function(){return S.Promise.call(3,W)});var Wr=function(e){var t=e.resolve(5);t.constructor={};var r=e.resolve(t);try{r.then(null,W).then(null,W)}catch(n){return true}return t===r}(S.Promise);var Gr=s&&function(){var e=0;var t=Object.defineProperty({},\"then\",{get:function(){e+=1}});Promise.resolve(t);return e===1}();var Hr=function BadResolverPromise(e){var t=new Promise(e);e(3,function(){});this.then=t.then;this.constructor=BadResolverPromise};Hr.prototype=Promise.prototype;Hr.all=Promise.all;var Vr=a(function(){return!!Hr.all([1,2])});if(!Dr||!zr||!qr||Wr||!Gr||Vr){Promise=Fr;ne(S,\"Promise\",Fr)}if(Promise.all.length!==1){var Br=Promise.all;ne(Promise,\"all\",function all(e){return ce.Call(Br,this,arguments)})}if(Promise.race.length!==1){var Ur=Promise.race;ne(Promise,\"race\",function race(e){return ce.Call(Ur,this,arguments)})}if(Promise.resolve.length!==1){var $r=Promise.resolve;ne(Promise,\"resolve\",function resolve(e){return ce.Call($r,this,arguments)})}if(Promise.reject.length!==1){var Jr=Promise.reject;ne(Promise,\"reject\",function reject(e){return ce.Call(Jr,this,arguments)})}Mt(Promise,\"all\");Mt(Promise,\"race\");Mt(Promise,\"resolve\");Mt(Promise,\"reject\");Ce(Promise)}var Xr=function(e){var t=n(p(e,function(e,t){e[t]=true;return e},{}));return e.join(\":\")===t.join(\":\")};var Kr=Xr([\"z\",\"a\",\"bb\"]);var Zr=Xr([\"z\",1,\"a\",\"3\",2]);if(s){var Yr=function fastkey(e,t){if(!t&&!Kr){return null}if(se(e)){return\"^\"+ce.ToString(e)}else if(typeof e===\"string\"){return\"$\"+e}else if(typeof e===\"number\"){if(!Zr){return\"n\"+e}return e}else if(typeof e===\"boolean\"){return\"b\"+e}return null};var Qr=function emptyObject(){return Object.create?Object.create(null):{}};var en=function addIterableToMap(e,n,o){if(r(o)||re.string(o)){l(o,function(e){if(!ce.TypeIsObject(e)){throw new TypeError(\"Iterator value \"+e+\" is not an entry object\")}n.set(e[0],e[1])})}else if(o instanceof e){t(e.prototype.forEach,o,function(e,t){n.set(t,e)})}else{var i,a;if(!se(o)){a=n.set;if(!ce.IsCallable(a)){throw new TypeError(\"bad map\")}i=ce.GetIterator(o)}if(typeof i!==\"undefined\"){while(true){var u=ce.IteratorStep(i);if(u===false){break}var f=u.value;try{if(!ce.TypeIsObject(f)){throw new TypeError(\"Iterator value \"+f+\" is not an entry object\")}t(a,n,f[0],f[1])}catch(s){ce.IteratorClose(i,true);throw s}}}}};var tn=function addIterableToSet(e,n,o){if(r(o)||re.string(o)){l(o,function(e){n.add(e)})}else if(o instanceof e){t(e.prototype.forEach,o,function(e){n.add(e)})}else{var i,a;if(!se(o)){a=n.add;if(!ce.IsCallable(a)){throw new TypeError(\"bad set\")}i=ce.GetIterator(o)}if(typeof i!==\"undefined\"){while(true){var u=ce.IteratorStep(i);if(u===false){break}var f=u.value;try{t(a,n,f)}catch(s){ce.IteratorClose(i,true);throw s}}}}};var rn={Map:function(){var e={};var r=function MapEntry(e,t){this.key=e;this.value=t;this.next=null;this.prev=null};r.prototype.isRemoved=function isRemoved(){return this.key===e};var n=function isMap(e){return!!e._es6map};var o=function requireMapSlot(e,t){if(!ce.TypeIsObject(e)||!n(e)){throw new TypeError(\"Method Map.prototype.\"+t+\" called on incompatible receiver \"+ce.ToString(e))}};var i=function MapIterator(e,t){o(e,\"[[MapIterator]]\");this.head=e._head;this.i=this.head;this.kind=t};i.prototype={isMapIterator:true,next:function next(){if(!this.isMapIterator){throw new TypeError(\"Not a MapIterator\")}var e=this.i;var t=this.kind;var r=this.head;if(typeof this.i===\"undefined\"){return Ke()}while(e.isRemoved()&&e!==r){e=e.prev}var n;while(e.next!==r){e=e.next;if(!e.isRemoved()){if(t===\"key\"){n=e.key}else if(t===\"value\"){n=e.value}else{n=[e.key,e.value]}this.i=e;return Ke(n)}}this.i=void 0;return Ke()}};Me(i.prototype);var a;var u=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}if(this&&this._es6map){throw new TypeError(\"Bad construction\")}var e=Ae(this,Map,a,{_es6map:true,_head:null,_map:G?new G:null,_size:0,_storage:Qr()});var t=new r(null,null);t.next=t.prev=t;e._head=t;if(arguments.length>0){en(Map,e,arguments[0])}return e};a=u.prototype;m.getter(a,\"size\",function(){if(typeof this._size===\"undefined\"){throw new TypeError(\"size method called on incompatible Map\")}return this._size});b(a,{get:function get(e){o(this,\"get\");var t;var r=Yr(e,true);if(r!==null){t=this._storage[r];if(t){return t.value}else{return}}if(this._map){t=V.call(this._map,e);if(t){return t.value}else{return}}var n=this._head;var i=n;while((i=i.next)!==n){if(ce.SameValueZero(i.key,e)){return i.value}}},has:function has(e){o(this,\"has\");var t=Yr(e,true);if(t!==null){return typeof this._storage[t]!==\"undefined\"}if(this._map){return B.call(this._map,e)}var r=this._head;var n=r;while((n=n.next)!==r){if(ce.SameValueZero(n.key,e)){return true}}return false},set:function set(e,t){o(this,\"set\");var n=this._head;var i=n;var a;var u=Yr(e,true);if(u!==null){if(typeof this._storage[u]!==\"undefined\"){this._storage[u].value=t;return this}else{a=this._storage[u]=new r(e,t);i=n.prev}}else if(this._map){if(B.call(this._map,e)){V.call(this._map,e).value=t}else{a=new r(e,t);U.call(this._map,e,a);i=n.prev}}while((i=i.next)!==n){if(ce.SameValueZero(i.key,e)){i.value=t;return this}}a=a||new r(e,t);if(ce.SameValue(-0,e)){a.key=+0}a.next=this._head;a.prev=this._head.prev;a.prev.next=a;a.next.prev=a;this._size+=1;return this},\"delete\":function(t){o(this,\"delete\");var r=this._head;var n=r;var i=Yr(t,true);if(i!==null){if(typeof this._storage[i]===\"undefined\"){return false}n=this._storage[i].prev;delete this._storage[i]}else if(this._map){if(!B.call(this._map,t)){return false}n=V.call(this._map,t).prev;H.call(this._map,t)}while((n=n.next)!==r){if(ce.SameValueZero(n.key,t)){n.key=e;n.value=e;n.prev.next=n.next;n.next.prev=n.prev;this._size-=1;return true}}return false},clear:function clear(){o(this,\"clear\");this._map=G?new G:null;this._size=0;this._storage=Qr();var t=this._head;var r=t;var n=r.next;while((r=n)!==t){r.key=e;r.value=e;n=r.next;r.next=r.prev=t}t.next=t.prev=t},keys:function keys(){o(this,\"keys\");return new i(this,\"key\")},values:function values(){o(this,\"values\");return new i(this,\"value\")},entries:function entries(){o(this,\"entries\");return new i(this,\"key+value\")},forEach:function forEach(e){o(this,\"forEach\");var r=arguments.length>1?arguments[1]:null;var n=this.entries();for(var i=n.next();!i.done;i=n.next()){if(r){t(e,r,i.value[1],i.value[0],this)}else{e(i.value[1],i.value[0],this)}}}});Me(a,a.entries);return u}(),Set:function(){var e=function isSet(e){return e._es6set&&typeof e._storage!==\"undefined\"};var r=function requireSetSlot(t,r){if(!ce.TypeIsObject(t)||!e(t)){throw new TypeError(\"Set.prototype.\"+r+\" called on incompatible receiver \"+ce.ToString(t))}};var o;var i=function Set(){if(!(this instanceof Set)){throw new TypeError('Constructor Set requires \"new\"')}if(this&&this._es6set){throw new TypeError(\"Bad construction\")}var e=Ae(this,Set,o,{_es6set:true,\"[[SetData]]\":null,_storage:Qr()});if(!e._es6set){throw new TypeError(\"bad set\")}if(arguments.length>0){tn(Set,e,arguments[0])}return e};o=i.prototype;var a=function(e){var t=e;if(t===\"^null\"){return null}else if(t===\"^undefined\"){return void 0}else{var r=t.charAt(0);if(r===\"$\"){return C(t,1)}else if(r===\"n\"){return+C(t,1)}else if(r===\"b\"){return t===\"btrue\"}}return+t};var u=function ensureMap(e){if(!e[\"[[SetData]]\"]){var t=new rn.Map;e[\"[[SetData]]\"]=t;l(n(e._storage),function(e){var r=a(e);t.set(r,r)});e[\"[[SetData]]\"]=t}e._storage=null};m.getter(i.prototype,\"size\",function(){r(this,\"size\");if(this._storage){return n(this._storage).length}u(this);return this[\"[[SetData]]\"].size});b(i.prototype,{has:function has(e){r(this,\"has\");var t;if(this._storage&&(t=Yr(e))!==null){return!!this._storage[t]}u(this);return this[\"[[SetData]]\"].has(e)},add:function add(e){r(this,\"add\");var t;if(this._storage&&(t=Yr(e))!==null){this._storage[t]=true;return this}u(this);this[\"[[SetData]]\"].set(e,e);return this},\"delete\":function(e){r(this,\"delete\");var t;if(this._storage&&(t=Yr(e))!==null){var n=z(this._storage,t);return delete this._storage[t]&&n}u(this);return this[\"[[SetData]]\"][\"delete\"](e)},clear:function clear(){r(this,\"clear\");if(this._storage){this._storage=Qr()}if(this[\"[[SetData]]\"]){this[\"[[SetData]]\"].clear()}},values:function values(){r(this,\"values\");u(this);return new f(this[\"[[SetData]]\"].values())},entries:function entries(){r(this,\"entries\");u(this);return new f(this[\"[[SetData]]\"].entries())},forEach:function forEach(e){r(this,\"forEach\");var n=arguments.length>1?arguments[1]:null;var o=this;u(o);this[\"[[SetData]]\"].forEach(function(r,i){if(n){t(e,n,i,i,o)}else{e(i,i,o)}})}});h(i.prototype,\"keys\",i.prototype.values,true);Me(i.prototype,i.prototype.values);var f=function SetIterator(e){this.it=e};f.prototype={isSetIterator:true,next:function next(){if(!this.isSetIterator){throw new TypeError(\"Not a SetIterator\")}return this.it.next()}};Me(f.prototype);return i}()};var nn=S.Set&&!Set.prototype[\"delete\"]&&Set.prototype.remove&&Set.prototype.items&&Set.prototype.map&&Array.isArray((new Set).keys);if(nn){S.Set=rn.Set}if(S.Map||S.Set){var on=a(function(){return new Map([[1,2]]).get(1)===2});if(!on){S.Map=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}var e=new G;if(arguments.length>0){en(Map,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,S.Map.prototype);return e};S.Map.prototype=O(G.prototype);h(S.Map.prototype,\"constructor\",S.Map,true);m.preserveToString(S.Map,G)}var an=new Map;var un=function(){var e=new Map([[1,0],[2,0],[3,0],[4,0]]);e.set(-0,e);return e.get(0)===e&&e.get(-0)===e&&e.has(0)&&e.has(-0)}();var fn=an.set(1,2)===an;if(!un||!fn){ne(Map.prototype,\"set\",function set(e,r){t(U,this,e===0?0:e,r);return this})}if(!un){b(Map.prototype,{get:function get(e){return t(V,this,e===0?0:e)},has:function has(e){return t(B,this,e===0?0:e)}},true);m.preserveToString(Map.prototype.get,V);m.preserveToString(Map.prototype.has,B)}var sn=new Set;var cn=Set.prototype[\"delete\"]&&Set.prototype.add&&Set.prototype.has&&function(e){e[\"delete\"](0);e.add(-0);return!e.has(0)}(sn);var ln=sn.add(1)===sn;if(!cn||!ln){var pn=Set.prototype.add;Set.prototype.add=function add(e){t(pn,this,e===0?0:e);return this};m.preserveToString(Set.prototype.add,pn)}if(!cn){var vn=Set.prototype.has;Set.prototype.has=function has(e){return t(vn,this,e===0?0:e)};m.preserveToString(Set.prototype.has,vn);var yn=Set.prototype[\"delete\"];Set.prototype[\"delete\"]=function SetDelete(e){return t(yn,this,e===0?0:e)};m.preserveToString(Set.prototype[\"delete\"],yn)}var hn=w(S.Map,function(e){var t=new e([]);t.set(42,42);return t instanceof e});var bn=Object.setPrototypeOf&&!hn;var gn=function(){try{return!(S.Map()instanceof S.Map)}catch(e){return e instanceof TypeError}}();if(S.Map.length!==0||bn||!gn){S.Map=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}var e=new G;if(arguments.length>0){en(Map,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,Map.prototype);return e};S.Map.prototype=G.prototype;h(S.Map.prototype,\"constructor\",S.Map,true);m.preserveToString(S.Map,G)}var dn=w(S.Set,function(e){var t=new e([]);t.add(42,42);return t instanceof e});var mn=Object.setPrototypeOf&&!dn;var On=function(){try{return!(S.Set()instanceof S.Set)}catch(e){return e instanceof TypeError}}();if(S.Set.length!==0||mn||!On){var wn=S.Set;S.Set=function Set(){if(!(this instanceof Set)){throw new TypeError('Constructor Set requires \"new\"')}var e=new wn;if(arguments.length>0){tn(Set,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,Set.prototype);return e};S.Set.prototype=wn.prototype;h(S.Set.prototype,\"constructor\",S.Set,true);m.preserveToString(S.Set,wn)}var jn=new S.Map;var Sn=!a(function(){return jn.keys().next().done});if(typeof S.Map.prototype.clear!==\"function\"||(new S.Set).size!==0||jn.size!==0||typeof S.Map.prototype.keys!==\"function\"||typeof S.Set.prototype.keys!==\"function\"||typeof S.Map.prototype.forEach!==\"function\"||typeof S.Set.prototype.forEach!==\"function\"||u(S.Map)||u(S.Set)||typeof jn.keys().next!==\"function\"||Sn||!hn){b(S,{Map:rn.Map,Set:rn.Set},true)}if(S.Set.prototype.keys!==S.Set.prototype.values){h(S.Set.prototype,\"keys\",S.Set.prototype.values,true)}Me(Object.getPrototypeOf((new S.Map).keys()));Me(Object.getPrototypeOf((new S.Set).keys()));if(c&&S.Set.prototype.has.name!==\"has\"){var Tn=S.Set.prototype.has;ne(S.Set.prototype,\"has\",function has(e){return t(Tn,this,e)})}}b(S,rn);Ce(S.Map);Ce(S.Set)}var In=function throwUnlessTargetIsObject(e){if(!ce.TypeIsObject(e)){throw new TypeError(\"target must be an object\")}};var En={apply:function apply(){return ce.Call(ce.Call,null,arguments)},construct:function construct(e,t){if(!ce.IsConstructor(e)){throw new TypeError(\"First argument must be a constructor.\")}var r=arguments.length>2?arguments[2]:e;if(!ce.IsConstructor(r)){throw new TypeError(\"new.target must be a constructor.\")}return ce.Construct(e,t,r,\"internal\")},deleteProperty:function deleteProperty(e,t){In(e);if(s){var r=Object.getOwnPropertyDescriptor(e,t);if(r&&!r.configurable){return false}}return delete e[t]},has:function has(e,t){In(e);return t in e}};if(Object.getOwnPropertyNames){Object.assign(En,{ownKeys:function ownKeys(e){In(e);var t=Object.getOwnPropertyNames(e);if(ce.IsCallable(Object.getOwnPropertySymbols)){x(t,Object.getOwnPropertySymbols(e))}return t}})}var Pn=function ConvertExceptionToBoolean(e){return!i(e)};if(Object.preventExtensions){Object.assign(En,{isExtensible:function isExtensible(e){In(e);return Object.isExtensible(e)},preventExtensions:function preventExtensions(e){In(e);return Pn(function(){return Object.preventExtensions(e)})}})}if(s){var Cn=function get(e,t,r){var n=Object.getOwnPropertyDescriptor(e,t);if(!n){var o=Object.getPrototypeOf(e);if(o===null){return void 0}return Cn(o,t,r)}if(\"value\"in n){return n.value}if(n.get){return ce.Call(n.get,r)}return void 0};var Mn=function set(e,r,n,o){var i=Object.getOwnPropertyDescriptor(e,r);if(!i){var a=Object.getPrototypeOf(e);if(a!==null){return Mn(a,r,n,o)}i={value:void 0,writable:true,enumerable:true,configurable:true}}if(\"value\"in i){if(!i.writable){return false}if(!ce.TypeIsObject(o)){return false}var u=Object.getOwnPropertyDescriptor(o,r);if(u){return ae.defineProperty(o,r,{value:n})}else{return ae.defineProperty(o,r,{value:n,writable:true,enumerable:true,configurable:true})}}if(i.set){t(i.set,o,n);return true}return false};Object.assign(En,{defineProperty:function defineProperty(e,t,r){In(e);return Pn(function(){return Object.defineProperty(e,t,r)})},getOwnPropertyDescriptor:function getOwnPropertyDescriptor(e,t){In(e);return Object.getOwnPropertyDescriptor(e,t)},get:function get(e,t){In(e);var r=arguments.length>2?arguments[2]:e;return Cn(e,t,r)},set:function set(e,t,r){In(e);var n=arguments.length>3?arguments[3]:e;return Mn(e,t,r,n)}})}if(Object.getPrototypeOf){var xn=Object.getPrototypeOf;En.getPrototypeOf=function getPrototypeOf(e){In(e);return xn(e)}}if(Object.setPrototypeOf&&En.getPrototypeOf){var Nn=function(e,t){var r=t;while(r){if(e===r){return true}r=En.getPrototypeOf(r)}return false};Object.assign(En,{setPrototypeOf:function setPrototypeOf(e,t){In(e);if(t!==null&&!ce.TypeIsObject(t)){throw new TypeError(\"proto must be an object or null\")}if(t===ae.getPrototypeOf(e)){return true}if(ae.isExtensible&&!ae.isExtensible(e)){return false}if(Nn(e,t)){return false}Object.setPrototypeOf(e,t);return true}})}var An=function(e,t){if(!ce.IsCallable(S.Reflect[e])){h(S.Reflect,e,t)}else{var r=a(function(){S.Reflect[e](1);S.Reflect[e](NaN);S.Reflect[e](true);return true});if(r){ne(S.Reflect,e,t)}}};Object.keys(En).forEach(function(e){An(e,En[e])});var Rn=S.Reflect.getPrototypeOf;if(c&&Rn&&Rn.name!==\"getPrototypeOf\"){ne(S.Reflect,\"getPrototypeOf\",function getPrototypeOf(e){return t(Rn,S.Reflect,e)})}if(S.Reflect.setPrototypeOf){if(a(function(){S.Reflect.setPrototypeOf(1,{});return true})){ne(S.Reflect,\"setPrototypeOf\",En.setPrototypeOf)}}if(S.Reflect.defineProperty){if(!a(function(){var e=!S.Reflect.defineProperty(1,\"test\",{value:1});var t=typeof Object.preventExtensions!==\"function\"||!S.Reflect.defineProperty(Object.preventExtensions({}),\"test\",{});return e&&t})){ne(S.Reflect,\"defineProperty\",En.defineProperty)}}if(S.Reflect.construct){if(!a(function(){var e=function F(){};return S.Reflect.construct(function(){},[],e)instanceof e})){ne(S.Reflect,\"construct\",En.construct)}}if(String(new Date(NaN))!==\"Invalid Date\"){var _n=Date.prototype.toString;var kn=function toString(){var e=+this;if(e!==e){return\"Invalid Date\"}return ce.Call(_n,this)};ne(Date.prototype,\"toString\",kn)}var Ln={anchor:function anchor(e){return ce.CreateHTML(this,\"a\",\"name\",e)},big:function big(){return ce.CreateHTML(this,\"big\",\"\",\"\")},blink:function blink(){return ce.CreateHTML(this,\"blink\",\"\",\"\")},bold:function bold(){return ce.CreateHTML(this,\"b\",\"\",\"\")},fixed:function fixed(){return ce.CreateHTML(this,\"tt\",\"\",\"\")},fontcolor:function fontcolor(e){return ce.CreateHTML(this,\"font\",\"color\",e)},fontsize:function fontsize(e){return ce.CreateHTML(this,\"font\",\"size\",e)},italics:function italics(){return ce.CreateHTML(this,\"i\",\"\",\"\")},link:function link(e){return ce.CreateHTML(this,\"a\",\"href\",e)},small:function small(){return ce.CreateHTML(this,\"small\",\"\",\"\")},strike:function strike(){return ce.CreateHTML(this,\"strike\",\"\",\"\")},sub:function sub(){return ce.CreateHTML(this,\"sub\",\"\",\"\")},sup:function sub(){return ce.CreateHTML(this,\"sup\",\"\",\"\")}};l(Object.keys(Ln),function(e){var r=String.prototype[e];var n=false;if(ce.IsCallable(r)){var o=t(r,\"\",' \" ');var i=P([],o.match(/\"/g)).length;n=o!==o.toLowerCase()||i>2}else{n=true}if(n){ne(String.prototype,e,Ln[e])}});var Fn=function(){if(!oe){return false}var e=typeof JSON===\"object\"&&typeof JSON.stringify===\"function\"?JSON.stringify:null;if(!e){return false}if(typeof e($())!==\"undefined\"){return true}if(e([$()])!==\"[null]\"){return true}var t={a:$()};t[$()]=true;if(e(t)!==\"{}\"){return true}return false}();var Dn=a(function(){if(!oe){return true}return JSON.stringify(Object($()))===\"{}\"&&JSON.stringify([Object($())])===\"[{}]\"});if(Fn||!Dn){var zn=JSON.stringify;ne(JSON,\"stringify\",function stringify(e){if(typeof e===\"symbol\"){return}var n;if(arguments.length>1){n=arguments[1]}var o=[e];if(!r(n)){var i=ce.IsCallable(n)?n:null;var a=function(e,r){var n=i?t(i,this,e,r):r;if(typeof n!==\"symbol\"){if(re.symbol(n)){return Nt({})(n)}else{return n}}};o.push(a)}else{o.push(n)}if(arguments.length>2){o.push(arguments[2])}return zn.apply(this,o)})}return S});\n//# sourceMappingURL=es6-shim.map\n/*! jQuery v3.4.1 | (c) JS Foundation and other contributors | jquery.org/license */\n!function(e,t){\"use strict\";\"object\"==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(C,e){\"use strict\";var t=[],E=C.document,r=Object.getPrototypeOf,s=t.slice,g=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return\"function\"==typeof e&&\"number\"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement(\"script\");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+\"\":\"object\"==typeof e||\"function\"==typeof e?n[o.call(e)]||\"object\":typeof e}var f=\"3.4.1\",k=function(e,t){return new k.fn.init(e,t)},p=/^[\\s\\uFEFF\\xA0]+|[\\s\\uFEFF\\xA0]+$/g;function d(e){var t=!!e&&\"length\"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&(\"array\"===n||0===t||\"number\"==typeof t&&0<t&&t-1 in e)}k.fn=k.prototype={jquery:f,constructor:k,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=k.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return k.each(this,e)},map:function(n){return this.pushStack(k.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.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(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},k.extend=k.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for(\"boolean\"==typeof a&&(l=a,a=arguments[s]||{},s++),\"object\"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],\"__proto__\"!==t&&a!==r&&(l&&r&&(k.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||k.isPlainObject(n)?n:{},i=!1,a[t]=k.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},k.extend({expando:\"jQuery\"+(f+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]\"!==o.call(e))&&(!(t=r(e))||\"function\"==typeof(n=v.call(t,\"constructor\")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t){b(e,{nonce:t&&t.nonce})},each:function(e,t){var n,r=0;if(d(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}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(p,\"\")},makeArray:function(e,t){var n=t||[];return null!=e&&(d(Object(e))?k.merge(n,\"string\"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.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,i,o=0,a=[];if(d(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g.apply([],a)},guid:1,support:y}),\"function\"==typeof Symbol&&(k.fn[Symbol.iterator]=t[Symbol.iterator]),k.each(\"Boolean Number String Function Array Date RegExp Object Error Symbol\".split(\" \"),function(e,t){n[\"[object \"+t+\"]\"]=t.toLowerCase()});var h=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,k=\"sizzle\"+1*new Date,m=n.document,S=0,r=0,p=ue(),x=ue(),N=ue(),A=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R=\"checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped\",M=\"[\\\\x20\\\\t\\\\r\\\\n\\\\f]\",I=\"(?:\\\\\\\\.|[\\\\w-]|[^\\0-\\\\xa0])+\",W=\"\\\\[\"+M+\"*(\"+I+\")(?:\"+M+\"*([*^$|!~]?=)\"+M+\"*(?:'((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\"|(\"+I+\"))|)\"+M+\"*\\\\]\",$=\":(\"+I+\")(?:\\\\((('((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\")|((?:\\\\\\\\.|[^\\\\\\\\()[\\\\]]|\"+W+\")*)|.*)\\\\)|)\",F=new RegExp(M+\"+\",\"g\"),B=new RegExp(\"^\"+M+\"+|((?:^|[^\\\\\\\\])(?:\\\\\\\\.)*)\"+M+\"+$\",\"g\"),_=new RegExp(\"^\"+M+\"*,\"+M+\"*\"),z=new RegExp(\"^\"+M+\"*([>+~]|\"+M+\")\"+M+\"*\"),U=new RegExp(M+\"|>\"),X=new RegExp($),V=new RegExp(\"^\"+I+\"$\"),G={ID:new RegExp(\"^#(\"+I+\")\"),CLASS:new RegExp(\"^\\\\.(\"+I+\")\"),TAG:new RegExp(\"^(\"+I+\"|[*])\"),ATTR:new RegExp(\"^\"+W),PSEUDO:new RegExp(\"^\"+$),CHILD:new RegExp(\"^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\\\(\"+M+\"*(even|odd|(([+-]|)(\\\\d*)n|)\"+M+\"*(?:([+-]|)\"+M+\"*(\\\\d+)|))\"+M+\"*\\\\)|)\",\"i\"),bool:new RegExp(\"^(?:\"+R+\")$\",\"i\"),needsContext:new RegExp(\"^\"+M+\"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\\\(\"+M+\"*((?:-\\\\d)?\\\\d*)\"+M+\"*\\\\)|)(?=[^-]|$)\",\"i\")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\\d$/i,K=/^[^{]+\\{\\s*\\[native \\w/,Z=/^(?:#([\\w-]+)|(\\w+)|\\.([\\w-]+))$/,ee=/[+~]/,te=new RegExp(\"\\\\\\\\([\\\\da-f]{1,6}\"+M+\"?|(\"+M+\")|.)\",\"ig\"),ne=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)},re=/([\\0-\\x1f\\x7f]|^-?\\d)|^-$|[^\\0-\\x1f\\x7f-\\uFFFF\\w-]/g,ie=function(e,t){return t?\"\\0\"===e?\"\\ufffd\":e.slice(0,-1)+\"\\\\\"+e.charCodeAt(e.length-1).toString(16)+\" \":\"\\\\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&\"fieldset\"===e.nodeName.toLowerCase()},{dir:\"parentNode\",next:\"legend\"});try{H.apply(t=O.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],\"string\"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&((e?e.ownerDocument||e:m)!==C&&T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!A[t+\" \"]&&(!v||!v.test(t))&&(1!==p||\"object\"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&U.test(t)){(s=e.getAttribute(\"id\"))?s=s.replace(re,ie):e.setAttribute(\"id\",s=k),o=(l=h(t)).length;while(o--)l[o]=\"#\"+s+\" \"+xe(l[o]);c=l.join(\",\"),f=ee.test(t)&&ye(e.parentNode)||e}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){A(t,!0)}finally{s===k&&e.removeAttribute(\"id\")}}}return g(t.replace(B,\"$1\"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+\" \")>b.cacheLength&&delete e[r.shift()],e[t+\" \"]=n}}function le(e){return e[k]=!0,e}function ce(e){var t=C.createElement(\"fieldset\");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split(\"|\"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return\"input\"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return(\"input\"===t||\"button\"===t)&&e.type===n}}function ge(t){return function(e){return\"form\"in e?e.parentNode&&!1===e.disabled?\"label\"in e?\"label\"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:\"label\"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&\"undefined\"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||\"HTML\")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),m!==C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener(\"unload\",oe,!1):n.attachEvent&&n.attachEvent(\"onunload\",oe)),d.attributes=ce(function(e){return e.className=\"i\",!e.getAttribute(\"className\")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment(\"\")),!e.getElementsByTagName(\"*\").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=k,!C.getElementsByName||!C.getElementsByName(k).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute(\"id\")===t}},b.find.ID=function(e,t){if(\"undefined\"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t=\"undefined\"!=typeof e.getAttributeNode&&e.getAttributeNode(\"id\");return t&&t.value===n}},b.find.ID=function(e,t){if(\"undefined\"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return\"undefined\"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if(\"*\"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if(\"undefined\"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML=\"<a id='\"+k+\"'></a><select id='\"+k+\"-\\r\\\\' msallowcapture=''><option selected=''></option></select>\",e.querySelectorAll(\"[msallowcapture^='']\").length&&v.push(\"[*^$]=\"+M+\"*(?:''|\\\"\\\")\"),e.querySelectorAll(\"[selected]\").length||v.push(\"\\\\[\"+M+\"*(?:value|\"+R+\")\"),e.querySelectorAll(\"[id~=\"+k+\"-]\").length||v.push(\"~=\"),e.querySelectorAll(\":checked\").length||v.push(\":checked\"),e.querySelectorAll(\"a#\"+k+\"+*\").length||v.push(\".#.+[+~]\")}),ce(function(e){e.innerHTML=\"<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>\";var t=C.createElement(\"input\");t.setAttribute(\"type\",\"hidden\"),e.appendChild(t).setAttribute(\"name\",\"D\"),e.querySelectorAll(\"[name=d]\").length&&v.push(\"name\"+M+\"*[*^$|!~]?=\"),2!==e.querySelectorAll(\":enabled\").length&&v.push(\":enabled\",\":disabled\"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(\":disabled\").length&&v.push(\":enabled\",\":disabled\"),e.querySelectorAll(\"*,:x\"),v.push(\",.*:\")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,\"*\"),c.call(e,\"[s!='']:x\"),s.push(\"!=\",$)}),v=v.length&&new RegExp(v.join(\"|\")),s=s.length&&new RegExp(s.join(\"|\")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.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)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e===C||e.ownerDocument===m&&y(m,e)?-1:t===C||t.ownerDocument===m&&y(m,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===C?-1:t===C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==C&&T(e),d.matchesSelector&&E&&!A[t+\" \"]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){A(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!==C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!==C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+\"\").replace(re,ie)},se.error=function(e){throw new Error(\"Syntax error, unrecognized expression: \"+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.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 while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,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(te,ne),e[3]=(e[3]||e[4]||e[5]||\"\").replace(te,ne),\"~=\"===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]||se.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]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||\"\":n&&X.test(n)&&(t=h(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(te,ne).toLowerCase();return\"*\"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+\" \"];return t||(t=new RegExp(\"(^|\"+M+\")\"+e+\"(\"+M+\"|$)\"))&&p(e,function(e){return t.test(\"string\"==typeof e.className&&e.className||\"undefined\"!=typeof e.getAttribute&&e.getAttribute(\"class\")||\"\")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?\"!=\"===r:!r||(t+=\"\",\"=\"===r?t===i:\"!=\"===r?t!==i:\"^=\"===r?i&&0===t.indexOf(i):\"*=\"===r?i&&-1<t.indexOf(i):\"$=\"===r?i&&t.slice(-i.length)===i:\"~=\"===r?-1<(\" \"+t.replace(F,\" \")+\" \").indexOf(i):\"|=\"===r&&(t===i||t.slice(0,i.length+1)===i+\"-\"))}},CHILD:function(h,e,t,g,v){var y=\"nth\"!==h.slice(0,3),m=\"last\"!==h.slice(-4),x=\"of-type\"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?\"nextSibling\":\"previousSibling\",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l=\"only\"===h&&!u&&\"nextSibling\"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[k]||(a[k]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===S&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[S,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[k]||(a[k]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===S&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[k]||(a[k]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[S,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error(\"unsupported pseudo: \"+e);return a[k]?a(o):1<a.length?(t=[e,e,\"\",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace(B,\"$1\"));return s[k]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||\"\")||se.error(\"unsupported lang: \"+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute(\"xml:lang\")||e.getAttribute(\"lang\"))return(t=t.toLowerCase())===n||0===t.indexOf(n+\"-\")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!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!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.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:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r=\"\";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&\"parentNode\"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[S,p];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[k]||(e[k]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===S&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Ce(d,h,g,v,y,e){return v&&!v[k]&&(v=Ce(v)),y&&!y[k]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||\"*\",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[\" \"],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[k]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:\" \"===e[s-2].type?\"*\":\"\"})).replace(B,\"$1\"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+\" \"];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace(B,\" \")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=N[e+\" \"];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[k]?i.push(a):o.push(a);(a=N(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l=\"0\",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG(\"*\",i),h=S+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t===C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument===C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(S=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(S=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l=\"function\"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&\"ID\"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=k.split(\"\").sort(D).join(\"\")===k,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement(\"fieldset\"))}),ce(function(e){return e.innerHTML=\"<a href='#'></a>\",\"#\"===e.firstChild.getAttribute(\"href\")})||fe(\"type|href|height|width\",function(e,t,n){if(!n)return e.getAttribute(t,\"type\"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML=\"<input/>\",e.firstChild.setAttribute(\"value\",\"\"),\"\"===e.firstChild.getAttribute(\"value\")})||fe(\"value\",function(e,t,n){if(!n&&\"input\"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute(\"disabled\")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);k.find=h,k.expr=h.selectors,k.expr[\":\"]=k.expr.pseudos,k.uniqueSort=k.unique=h.uniqueSort,k.text=h.getText,k.isXMLDoc=h.isXML,k.contains=h.contains,k.escapeSelector=h.escape;var T=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&k(e).is(n))break;r.push(e)}return r},S=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},N=k.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var D=/^<([a-z][^\\/\\0>:\\x20\\t\\r\\n\\f]*)[\\x20\\t\\r\\n\\f]*\\/?>(?:<\\/\\1>|)$/i;function j(e,n,r){return m(n)?k.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?k.grep(e,function(e){return e===n!==r}):\"string\"!=typeof n?k.grep(e,function(e){return-1<i.call(n,e)!==r}):k.filter(n,e,r)}k.filter=function(e,t,n){var r=t[0];return n&&(e=\":not(\"+e+\")\"),1===t.length&&1===r.nodeType?k.find.matchesSelector(r,e)?[r]:[]:k.find.matches(e,k.grep(t,function(e){return 1===e.nodeType}))},k.fn.extend({find:function(e){var t,n,r=this.length,i=this;if(\"string\"!=typeof e)return this.pushStack(k(e).filter(function(){for(t=0;t<r;t++)if(k.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)k.find(e,i[t],n);return 1<r?k.uniqueSort(n):n},filter:function(e){return this.pushStack(j(this,e||[],!1))},not:function(e){return this.pushStack(j(this,e||[],!0))},is:function(e){return!!j(this,\"string\"==typeof e&&N.test(e)?k(e):e||[],!1).length}});var q,L=/^(?:\\s*(<[\\w\\W]+>)[^>]*|#([\\w-]+))$/;(k.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||q,\"string\"==typeof e){if(!(r=\"<\"===e[0]&&\">\"===e[e.length-1]&&3<=e.length?[null,e,null]:L.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 k?t[0]:t,k.merge(this,k.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),D.test(r[1])&&k.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(k):k.makeArray(e,this)}).prototype=k.fn,q=k(E);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}k.fn.extend({has:function(e){var t=k(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(k.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a=\"string\"!=typeof e&&k(e);if(!N.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&k.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?k.uniqueSort(o):o)},index:function(e){return e?\"string\"==typeof e?i.call(k(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(k.uniqueSort(k.merge(this.get(),k(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),k.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return T(e,\"parentNode\")},parentsUntil:function(e,t,n){return T(e,\"parentNode\",n)},next:function(e){return P(e,\"nextSibling\")},prev:function(e){return P(e,\"previousSibling\")},nextAll:function(e){return T(e,\"nextSibling\")},prevAll:function(e){return T(e,\"previousSibling\")},nextUntil:function(e,t,n){return T(e,\"nextSibling\",n)},prevUntil:function(e,t,n){return T(e,\"previousSibling\",n)},siblings:function(e){return S((e.parentNode||{}).firstChild,e)},children:function(e){return S(e.firstChild)},contents:function(e){return\"undefined\"!=typeof e.contentDocument?e.contentDocument:(A(e,\"template\")&&(e=e.content||e),k.merge([],e.childNodes))}},function(r,i){k.fn[r]=function(e,t){var n=k.map(this,i,e);return\"Until\"!==r.slice(-5)&&(t=e),t&&\"string\"==typeof t&&(n=k.filter(t,n)),1<this.length&&(O[r]||k.uniqueSort(n),H.test(r)&&n.reverse()),this.pushStack(n)}});var R=/[^\\x20\\t\\r\\n\\f]+/g;function M(e){return e}function I(e){throw e}function W(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}k.Callbacks=function(r){var e,n;r=\"string\"==typeof r?(e=r,n={},k.each(e.match(R)||[],function(e,t){n[t]=!0}),n):k.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:\"\")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){k.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&\"string\"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return k.each(arguments,function(e,t){var n;while(-1<(n=k.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<k.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t=\"\",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=\"\"),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},k.extend({Deferred:function(e){var o=[[\"notify\",\"progress\",k.Callbacks(\"memory\"),k.Callbacks(\"memory\"),2],[\"resolve\",\"done\",k.Callbacks(\"once memory\"),k.Callbacks(\"once memory\"),0,\"resolved\"],[\"reject\",\"fail\",k.Callbacks(\"once memory\"),k.Callbacks(\"once memory\"),1,\"rejected\"]],i=\"pending\",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},\"catch\":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return k.Deferred(function(r){k.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+\"With\"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError(\"Thenable self-resolution\");t=e&&(\"object\"==typeof e||\"function\"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,M,s),l(u,o,I,s)):(u++,t.call(e,l(u,o,M,s),l(u,o,I,s),l(u,o,M,o.notifyWith))):(a!==M&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){k.Deferred.exceptionHook&&k.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==I&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(k.Deferred.getStackHook&&(t.stackTrace=k.Deferred.getStackHook()),C.setTimeout(t))}}return k.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:M,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:M)),o[2][3].add(l(0,e,m(n)?n:I))}).promise()},promise:function(e){return null!=e?k.extend(e,a):a}},s={};return k.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+\"With\"](this===s?void 0:this,arguments),this},s[t[0]+\"With\"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=k.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(W(e,o.done(a(t)).resolve,o.reject,!n),\"pending\"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)W(i[t],a(t),o.reject);return o.promise()}});var $=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;k.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&$.test(e.name)&&C.console.warn(\"jQuery.Deferred exception: \"+e.message,e.stack,t)},k.readyException=function(e){C.setTimeout(function(){throw e})};var F=k.Deferred();function B(){E.removeEventListener(\"DOMContentLoaded\",B),C.removeEventListener(\"load\",B),k.ready()}k.fn.ready=function(e){return F.then(e)[\"catch\"](function(e){k.readyException(e)}),this},k.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--k.readyWait:k.isReady)||(k.isReady=!0)!==e&&0<--k.readyWait||F.resolveWith(E,[k])}}),k.ready.then=F.then,\"complete\"===E.readyState||\"loading\"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(k.ready):(E.addEventListener(\"DOMContentLoaded\",B),C.addEventListener(\"load\",B));var _=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if(\"object\"===w(n))for(s in i=!0,n)_(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(k(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},z=/^-ms-/,U=/-([a-z])/g;function X(e,t){return t.toUpperCase()}function V(e){return e.replace(z,\"ms-\").replace(U,X)}var G=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function Y(){this.expando=k.expando+Y.uid++}Y.uid=1,Y.prototype={cache:function(e){var t=e[this.expando];return t||(t={},G(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[V(t)]=n;else for(r in t)i[V(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][V(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){n=(t=Array.isArray(t)?t.map(V):(t=V(t))in r?[t]:t.match(R)||[]).length;while(n--)delete r[t[n]]}(void 0===t||k.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&&!k.isEmptyObject(t)}};var Q=new Y,J=new Y,K=/^(?:\\{[\\w\\W]*\\}|\\[[\\w\\W]*\\])$/,Z=/[A-Z]/g;function ee(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r=\"data-\"+t.replace(Z,\"-$&\").toLowerCase(),\"string\"==typeof(n=e.getAttribute(r))){try{n=\"true\"===(i=n)||\"false\"!==i&&(\"null\"===i?null:i===+i+\"\"?+i:K.test(i)?JSON.parse(i):i)}catch(e){}J.set(e,t,n)}else n=void 0;return n}k.extend({hasData:function(e){return J.hasData(e)||Q.hasData(e)},data:function(e,t,n){return J.access(e,t,n)},removeData:function(e,t){J.remove(e,t)},_data:function(e,t,n){return Q.access(e,t,n)},_removeData:function(e,t){Q.remove(e,t)}}),k.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=J.get(o),1===o.nodeType&&!Q.get(o,\"hasDataAttrs\"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf(\"data-\")&&(r=V(r.slice(5)),ee(o,r,i[r]));Q.set(o,\"hasDataAttrs\",!0)}return i}return\"object\"==typeof n?this.each(function(){J.set(this,n)}):_(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=J.get(o,n))?t:void 0!==(t=ee(o,n))?t:void 0;this.each(function(){J.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){J.remove(this,e)})}}),k.extend({queue:function(e,t,n){var r;if(e)return t=(t||\"fx\")+\"queue\",r=Q.get(e,t),n&&(!r||Array.isArray(n)?r=Q.access(e,t,k.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||\"fx\";var n=k.queue(e,t),r=n.length,i=n.shift(),o=k._queueHooks(e,t);\"inprogress\"===i&&(i=n.shift(),r--),i&&(\"fx\"===t&&n.unshift(\"inprogress\"),delete o.stop,i.call(e,function(){k.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+\"queueHooks\";return Q.get(e,n)||Q.access(e,n,{empty:k.Callbacks(\"once memory\").add(function(){Q.remove(e,[t+\"queue\",n])})})}}),k.fn.extend({queue:function(t,n){var e=2;return\"string\"!=typeof t&&(n=t,t=\"fx\",e--),arguments.length<e?k.queue(this[0],t):void 0===n?this:this.each(function(){var e=k.queue(this,t,n);k._queueHooks(this,t),\"fx\"===t&&\"inprogress\"!==e[0]&&k.dequeue(this,t)})},dequeue:function(e){return this.each(function(){k.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||\"fx\",[])},promise:function(e,t){var n,r=1,i=k.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};\"string\"!=typeof e&&(t=e,e=void 0),e=e||\"fx\";while(a--)(n=Q.get(o[a],e+\"queueHooks\"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var te=/[+-]?(?:\\d*\\.|)\\d+(?:[eE][+-]?\\d+|)/.source,ne=new RegExp(\"^(?:([+-])=|)(\"+te+\")([a-z%]*)$\",\"i\"),re=[\"Top\",\"Right\",\"Bottom\",\"Left\"],ie=E.documentElement,oe=function(e){return k.contains(e.ownerDocument,e)},ae={composed:!0};ie.getRootNode&&(oe=function(e){return k.contains(e.ownerDocument,e)||e.getRootNode(ae)===e.ownerDocument});var se=function(e,t){return\"none\"===(e=t||e).style.display||\"\"===e.style.display&&oe(e)&&\"none\"===k.css(e,\"display\")},ue=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];for(o in i=n.apply(e,r||[]),t)e.style[o]=a[o];return i};function le(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return k.css(e,t,\"\")},u=s(),l=n&&n[3]||(k.cssNumber[t]?\"\":\"px\"),c=e.nodeType&&(k.cssNumber[t]||\"px\"!==l&&+u)&&ne.exec(k.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)k.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,k.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var ce={};function fe(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?(\"none\"===n&&(l[c]=Q.get(r,\"display\")||null,l[c]||(r.style.display=\"\")),\"\"===r.style.display&&se(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ce[s])||(o=a.body.appendChild(a.createElement(s)),u=k.css(o,\"display\"),o.parentNode.removeChild(o),\"none\"===u&&(u=\"block\"),ce[s]=u)))):\"none\"!==n&&(l[c]=\"none\",Q.set(r,\"display\",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}k.fn.extend({show:function(){return fe(this,!0)},hide:function(){return fe(this)},toggle:function(e){return\"boolean\"==typeof e?e?this.show():this.hide():this.each(function(){se(this)?k(this).show():k(this).hide()})}});var pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)/i,he=/^$|^module$|\\/(?:java|ecma)script/i,ge={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,\"\",\"\"]};function ve(e,t){var n;return n=\"undefined\"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||\"*\"):\"undefined\"!=typeof e.querySelectorAll?e.querySelectorAll(t||\"*\"):[],void 0===t||t&&A(e,t)?k.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Q.set(e[n],\"globalEval\",!t||Q.get(t[n],\"globalEval\"))}ge.optgroup=ge.option,ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td;var me,xe,be=/<|&#?\\w+;/;function we(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if(\"object\"===w(o))k.merge(p,o.nodeType?[o]:o);else if(be.test(o)){a=a||f.appendChild(t.createElement(\"div\")),s=(de.exec(o)||[\"\",\"\"])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+k.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;k.merge(p,a.childNodes),(a=f.firstChild).textContent=\"\"}else p.push(t.createTextNode(o));f.textContent=\"\",d=0;while(o=p[d++])if(r&&-1<k.inArray(o,r))i&&i.push(o);else if(l=oe(o),a=ve(f.appendChild(o),\"script\"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||\"\")&&n.push(o)}return f}me=E.createDocumentFragment().appendChild(E.createElement(\"div\")),(xe=E.createElement(\"input\")).setAttribute(\"type\",\"radio\"),xe.setAttribute(\"checked\",\"checked\"),xe.setAttribute(\"name\",\"t\"),me.appendChild(xe),y.checkClone=me.cloneNode(!0).cloneNode(!0).lastChild.checked,me.innerHTML=\"<textarea>x</textarea>\",y.noCloneChecked=!!me.cloneNode(!0).lastChild.defaultValue;var Te=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ee=/^([^.]*)(?:\\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ne(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==(\"focus\"===t)}function Ae(e,t,n,r,i,o){var a,s;if(\"object\"==typeof t){for(s in\"string\"!=typeof n&&(r=r||n,n=void 0),t)Ae(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=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return k().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=k.guid++)),e.each(function(){k.event.add(this,t,i,r,n)})}function De(e,i,o){o?(Q.set(e,i,!1),k.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Q.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(k.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Q.set(this,i,r),t=o(this,i),this[i](),r!==(n=Q.get(this,i))||t?Q.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Q.set(this,i,{value:k.event.trigger(k.extend(r[0],k.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Q.get(e,i)&&k.event.add(e,i,ke)}k.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&k.find.matchesSelector(ie,i),n.guid||(n.guid=k.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return\"undefined\"!=typeof k&&k.event.triggered!==e.type?k.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||\"\").match(R)||[\"\"]).length;while(l--)d=g=(s=Ee.exec(e[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d&&(f=k.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=k.event.special[d]||{},c=k.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&k.expr.match.needsContext.test(i),namespace:h.join(\".\")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),k.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.hasData(e)&&Q.get(e);if(v&&(u=v.events)){l=(t=(t||\"\").match(R)||[\"\"]).length;while(l--)if(d=g=(s=Ee.exec(t[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d){f=k.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp(\"(^|\\\\.)\"+h.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&(\"**\"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||k.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)k.event.remove(e,d+t[l],n,r,!0);k.isEmptyObject(u)&&Q.remove(e,\"handle events\")}},dispatch:function(e){var t,n,r,i,o,a,s=k.event.fix(e),u=new Array(arguments.length),l=(Q.get(this,\"events\")||{})[s.type]||[],c=k.event.special[s.type]||{};for(u[0]=s,t=1;t<arguments.length;t++)u[t]=arguments[t];if(s.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,s)){a=k.event.handlers.call(this,s,l),t=0;while((i=a[t++])&&!s.isPropagationStopped()){s.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!s.isImmediatePropagationStopped())s.rnamespace&&!1!==o.namespace&&!s.rnamespace.test(o.namespace)||(s.handleObj=o,s.data=o.data,void 0!==(r=((k.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,u))&&!1===(s.result=r)&&(s.preventDefault(),s.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,s),s.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!(\"click\"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&(\"click\"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+\" \"]&&(a[i]=r.needsContext?-1<k(i,this).index(l):k.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(k.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[k.expando]?e:new k.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,\"input\")&&De(t,\"click\",ke),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,\"input\")&&De(t,\"click\"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,\"input\")&&Q.get(t,\"click\")||A(t,\"a\")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},k.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},k.Event=function(e,t){if(!(this instanceof k.Event))return new k.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?ke:Se,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&&k.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[k.expando]=!0},k.Event.prototype={constructor:k.Event,isDefaultPrevented:Se,isPropagationStopped:Se,isImmediatePropagationStopped:Se,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=ke,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=ke,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=ke,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},k.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,code:!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&&Te.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Ce.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},k.event.addProp),k.each({focus:\"focusin\",blur:\"focusout\"},function(e,t){k.event.special[e]={setup:function(){return De(this,e,Ne),!1},trigger:function(){return De(this,e),!0},delegateType:t}}),k.each({mouseenter:\"mouseover\",mouseleave:\"mouseout\",pointerenter:\"pointerover\",pointerleave:\"pointerout\"},function(e,i){k.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||k.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),k.fn.extend({on:function(e,t,n,r){return Ae(this,e,t,n,r)},one:function(e,t,n,r){return Ae(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,k(e.delegateTarget).off(r.namespace?r.origType+\".\"+r.namespace:r.origType,r.selector,r.handler),this;if(\"object\"==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=Se),this.each(function(){k.event.remove(this,e,n,t)})}});var je=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)[^>]*)\\/>/gi,qe=/<script|<style|<link/i,Le=/checked\\s*(?:[^=]|=\\s*.checked.)/i,He=/^\\s*<!(?:\\[CDATA\\[|--)|(?:\\]\\]|--)>\\s*$/g;function Oe(e,t){return A(e,\"table\")&&A(11!==t.nodeType?t:t.firstChild,\"tr\")&&k(e).children(\"tbody\")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute(\"type\"))+\"/\"+e.type,e}function Re(e){return\"true/\"===(e.type||\"\").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute(\"type\"),e}function Me(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(Q.hasData(e)&&(o=Q.access(e),a=Q.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n<r;n++)k.event.add(t,i,l[i][n]);J.hasData(e)&&(s=J.access(e),u=k.extend({},s),J.set(t,u))}}function Ie(n,r,i,o){r=g.apply([],r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&\"string\"==typeof d&&!y.checkClone&&Le.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Ie(t,r,i,o)});if(f&&(t=(e=we(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=k.map(ve(e,\"script\"),Pe)).length;c<f;c++)u=e,c!==p&&(u=k.clone(u,!0,!0),s&&k.merge(a,ve(u,\"script\"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,k.map(a,Re),c=0;c<s;c++)u=a[c],he.test(u.type||\"\")&&!Q.access(u,\"globalEval\")&&k.contains(l,u)&&(u.src&&\"module\"!==(u.type||\"\").toLowerCase()?k._evalUrl&&!u.noModule&&k._evalUrl(u.src,{nonce:u.nonce||u.getAttribute(\"nonce\")}):b(u.textContent.replace(He,\"\"),u,l))}return n}function We(e,t,n){for(var r,i=t?k.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||k.cleanData(ve(r)),r.parentNode&&(n&&oe(r)&&ye(ve(r,\"script\")),r.parentNode.removeChild(r));return e}k.extend({htmlPrefilter:function(e){return e.replace(je,\"<$1></$2>\")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||k.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,\"input\"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:\"input\"!==l&&\"textarea\"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Me(o[r],a[r]);else Me(e,c);return 0<(a=ve(c,\"script\")).length&&ye(a,!f&&ve(e,\"script\")),c},cleanData:function(e){for(var t,n,r,i=k.event.special,o=0;void 0!==(n=e[o]);o++)if(G(n)){if(t=n[Q.expando]){if(t.events)for(r in t.events)i[r]?k.event.remove(n,r):k.removeEvent(n,r,t.handle);n[Q.expando]=void 0}n[J.expando]&&(n[J.expando]=void 0)}}}),k.fn.extend({detach:function(e){return We(this,e,!0)},remove:function(e){return We(this,e)},text:function(e){return _(this,function(e){return void 0===e?k.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 Ie(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Oe(this,e).appendChild(e)})},prepend:function(){return Ie(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Oe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Ie(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Ie(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&&(k.cleanData(ve(e,!1)),e.textContent=\"\");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return k.clone(this,e,t)})},html:function(e){return _(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&&!qe.test(e)&&!ge[(de.exec(e)||[\"\",\"\"])[1].toLowerCase()]){e=k.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(k.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Ie(this,arguments,function(e){var t=this.parentNode;k.inArray(this,n)<0&&(k.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),k.each({appendTo:\"append\",prependTo:\"prepend\",insertBefore:\"before\",insertAfter:\"after\",replaceAll:\"replaceWith\"},function(e,a){k.fn[e]=function(e){for(var t,n=[],r=k(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),k(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var $e=new RegExp(\"^(\"+te+\")(?!px)[a-z%]+$\",\"i\"),Fe=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},Be=new RegExp(re.join(\"|\"),\"i\");function _e(e,t,n){var r,i,o,a,s=e.style;return(n=n||Fe(e))&&(\"\"!==(a=n.getPropertyValue(t)||n[t])||oe(e)||(a=k.style(e,t)),!y.pixelBoxStyles()&&$e.test(a)&&Be.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 ze(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(u){s.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%\",ie.appendChild(s).appendChild(u);var e=C.getComputedStyle(u);n=\"1%\"!==e.top,a=12===t(e.marginLeft),u.style.right=\"60%\",o=36===t(e.right),r=36===t(e.width),u.style.position=\"absolute\",i=12===t(u.offsetWidth/3),ie.removeChild(s),u=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s=E.createElement(\"div\"),u=E.createElement(\"div\");u.style&&(u.style.backgroundClip=\"content-box\",u.cloneNode(!0).style.backgroundClip=\"\",y.clearCloneStyle=\"content-box\"===u.style.backgroundClip,k.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),a},scrollboxSize:function(){return e(),i}}))}();var Ue=[\"Webkit\",\"Moz\",\"ms\"],Xe=E.createElement(\"div\").style,Ve={};function Ge(e){var t=k.cssProps[e]||Ve[e];return t||(e in Xe?e:Ve[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=Ue.length;while(n--)if((e=Ue[n]+t)in Xe)return e}(e)||e)}var Ye=/^(none|table(?!-c[ea]).+)/,Qe=/^--/,Je={position:\"absolute\",visibility:\"hidden\",display:\"block\"},Ke={letterSpacing:\"0\",fontWeight:\"400\"};function Ze(e,t,n){var r=ne.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||\"px\"):t}function et(e,t,n,r,i,o){var a=\"width\"===t?1:0,s=0,u=0;if(n===(r?\"border\":\"content\"))return 0;for(;a<4;a+=2)\"margin\"===n&&(u+=k.css(e,n+re[a],!0,i)),r?(\"content\"===n&&(u-=k.css(e,\"padding\"+re[a],!0,i)),\"margin\"!==n&&(u-=k.css(e,\"border\"+re[a]+\"Width\",!0,i))):(u+=k.css(e,\"padding\"+re[a],!0,i),\"padding\"!==n?u+=k.css(e,\"border\"+re[a]+\"Width\",!0,i):s+=k.css(e,\"border\"+re[a]+\"Width\",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e[\"offset\"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function tt(e,t,n){var r=Fe(e),i=(!y.boxSizingReliable()||n)&&\"border-box\"===k.css(e,\"boxSizing\",!1,r),o=i,a=_e(e,t,r),s=\"offset\"+t[0].toUpperCase()+t.slice(1);if($e.test(a)){if(!n)return a;a=\"auto\"}return(!y.boxSizingReliable()&&i||\"auto\"===a||!parseFloat(a)&&\"inline\"===k.css(e,\"display\",!1,r))&&e.getClientRects().length&&(i=\"border-box\"===k.css(e,\"boxSizing\",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+et(e,t,n||(i?\"border\":\"content\"),o,r,a)+\"px\"}function nt(e,t,n,r,i){return new nt.prototype.init(e,t,n,r,i)}k.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=_e(e,\"opacity\");return\"\"===n?\"1\":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!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=V(t),u=Qe.test(t),l=e.style;if(u||(t=Ge(s)),a=k.cssHooks[t]||k.cssHooks[s],void 0===n)return a&&\"get\"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];\"string\"===(o=typeof n)&&(i=ne.exec(n))&&i[1]&&(n=le(e,t,i),o=\"number\"),null!=n&&n==n&&(\"number\"!==o||u||(n+=i&&i[3]||(k.cssNumber[s]?\"\":\"px\")),y.clearCloneStyle||\"\"!==n||0!==t.indexOf(\"background\")||(l[t]=\"inherit\"),a&&\"set\"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=V(t);return Qe.test(t)||(t=Ge(s)),(a=k.cssHooks[t]||k.cssHooks[s])&&\"get\"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=_e(e,t,r)),\"normal\"===i&&t in Ke&&(i=Ke[t]),\"\"===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),k.each([\"height\",\"width\"],function(e,u){k.cssHooks[u]={get:function(e,t,n){if(t)return!Ye.test(k.css(e,\"display\"))||e.getClientRects().length&&e.getBoundingClientRect().width?tt(e,u,n):ue(e,Je,function(){return tt(e,u,n)})},set:function(e,t,n){var r,i=Fe(e),o=!y.scrollboxSize()&&\"absolute\"===i.position,a=(o||n)&&\"border-box\"===k.css(e,\"boxSizing\",!1,i),s=n?et(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e[\"offset\"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-et(e,u,\"border\",!1,i)-.5)),s&&(r=ne.exec(t))&&\"px\"!==(r[3]||\"px\")&&(e.style[u]=t,t=k.css(e,u)),Ze(0,t,s)}}}),k.cssHooks.marginLeft=ze(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(_e(e,\"marginLeft\"))||e.getBoundingClientRect().left-ue(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+\"px\"}),k.each({margin:\"\",padding:\"\",border:\"Width\"},function(i,o){k.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r=\"string\"==typeof e?e.split(\" \"):[e];t<4;t++)n[i+re[t]+o]=r[t]||r[t-2]||r[0];return n}},\"margin\"!==i&&(k.cssHooks[i+o].set=Ze)}),k.fn.extend({css:function(e,t){return _(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Fe(e),i=t.length;a<i;a++)o[t[a]]=k.css(e,t[a],!1,r);return o}return void 0!==n?k.style(e,t,n):k.css(e,t)},e,t,1<arguments.length)}}),((k.Tween=nt).prototype={constructor:nt,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||k.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(k.cssNumber[n]?\"\":\"px\")},cur:function(){var e=nt.propHooks[this.prop];return e&&e.get?e.get(this):nt.propHooks._default.get(this)},run:function(e){var t,n=nt.propHooks[this.prop];return this.options.duration?this.pos=t=k.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):nt.propHooks._default.set(this),this}}).init.prototype=nt.prototype,(nt.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=k.css(e.elem,e.prop,\"\"))&&\"auto\"!==t?t:0},set:function(e){k.fx.step[e.prop]?k.fx.step[e.prop](e):1!==e.elem.nodeType||!k.cssHooks[e.prop]&&null==e.elem.style[Ge(e.prop)]?e.elem[e.prop]=e.now:k.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=nt.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},k.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:\"swing\"},k.fx=nt.prototype.init,k.fx.step={};var rt,it,ot,at,st=/^(?:toggle|show|hide)$/,ut=/queueHooks$/;function lt(){it&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(lt):C.setTimeout(lt,k.fx.interval),k.fx.tick())}function ct(){return C.setTimeout(function(){rt=void 0}),rt=Date.now()}function ft(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i[\"margin\"+(n=re[r])]=i[\"padding\"+n]=e;return t&&(i.opacity=i.width=e),i}function pt(e,t,n){for(var r,i=(dt.tweeners[t]||[]).concat(dt.tweeners[\"*\"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function dt(o,e,t){var n,a,r=0,i=dt.prefilters.length,s=k.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=rt||ct(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:k.extend({},e),opts:k.extend(!0,{specialEasing:{},easing:k.easing._default},t),originalProperties:e,originalOptions:t,startTime:rt||ct(),duration:t.duration,tweens:[],createTween:function(e,t){var n=k.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=V(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=k.cssHooks[r])&&\"expand\"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=dt.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(k._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return k.map(c,pt,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),k.fx.timer(k.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}k.Animation=k.extend(dt,{tweeners:{\"*\":[function(e,t){var n=this.createTween(e,t);return le(n.elem,e,ne.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=[\"*\"]):e=e.match(R);for(var n,r=0,i=e.length;r<i;r++)n=e[r],dt.tweeners[n]=dt.tweeners[n]||[],dt.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c,f=\"width\"in t||\"height\"in t,p=this,d={},h=e.style,g=e.nodeType&&se(e),v=Q.get(e,\"fxshow\");for(r in n.queue||(null==(a=k._queueHooks(e,\"fx\")).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--,k.queue(e,\"fx\").length||a.empty.fire()})})),t)if(i=t[r],st.test(i)){if(delete t[r],o=o||\"toggle\"===i,i===(g?\"hide\":\"show\")){if(\"show\"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||k.style(e,r)}if((u=!k.isEmptyObject(t))||!k.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Q.get(e,\"display\")),\"none\"===(c=k.css(e,\"display\"))&&(l?c=l:(fe([e],!0),l=e.style.display||l,c=k.css(e,\"display\"),fe([e]))),(\"inline\"===c||\"inline-block\"===c&&null!=l)&&\"none\"===k.css(e,\"float\")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l=\"none\"===c?\"\":c)),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,d)u||(v?\"hidden\"in v&&(g=v.hidden):v=Q.access(e,\"fxshow\",{display:l}),o&&(v.hidden=!g),g&&fe([e],!0),p.done(function(){for(r in g||fe([e]),Q.remove(e,\"fxshow\"),d)k.style(e,r,d[r])})),u=pt(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?dt.prefilters.unshift(e):dt.prefilters.push(e)}}),k.speed=function(e,t,n){var r=e&&\"object\"==typeof e?k.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return k.fx.off?r.duration=0:\"number\"!=typeof r.duration&&(r.duration in k.fx.speeds?r.duration=k.fx.speeds[r.duration]:r.duration=k.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue=\"fx\"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&k.dequeue(this,r.queue)},r},k.fn.extend({fadeTo:function(e,t,n,r){return this.filter(se).css(\"opacity\",0).show().end().animate({opacity:t},e,n,r)},animate:function(t,e,n,r){var i=k.isEmptyObject(t),o=k.speed(e,n,r),a=function(){var e=dt(this,k.extend({},t),o);(i||Q.get(this,\"finish\"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return\"string\"!=typeof i&&(o=e,e=i,i=void 0),e&&!1!==i&&this.queue(i||\"fx\",[]),this.each(function(){var e=!0,t=null!=i&&i+\"queueHooks\",n=k.timers,r=Q.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&ut.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||k.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||\"fx\"),this.each(function(){var e,t=Q.get(this),n=t[a+\"queue\"],r=t[a+\"queueHooks\"],i=k.timers,o=n?n.length:0;for(t.finish=!0,k.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),k.each([\"toggle\",\"show\",\"hide\"],function(e,r){var i=k.fn[r];k.fn[r]=function(e,t,n){return null==e||\"boolean\"==typeof e?i.apply(this,arguments):this.animate(ft(r,!0),e,t,n)}}),k.each({slideDown:ft(\"show\"),slideUp:ft(\"hide\"),slideToggle:ft(\"toggle\"),fadeIn:{opacity:\"show\"},fadeOut:{opacity:\"hide\"},fadeToggle:{opacity:\"toggle\"}},function(e,r){k.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),k.timers=[],k.fx.tick=function(){var e,t=0,n=k.timers;for(rt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||k.fx.stop(),rt=void 0},k.fx.timer=function(e){k.timers.push(e),k.fx.start()},k.fx.interval=13,k.fx.start=function(){it||(it=!0,lt())},k.fx.stop=function(){it=null},k.fx.speeds={slow:600,fast:200,_default:400},k.fn.delay=function(r,e){return r=k.fx&&k.fx.speeds[r]||r,e=e||\"fx\",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},ot=E.createElement(\"input\"),at=E.createElement(\"select\").appendChild(E.createElement(\"option\")),ot.type=\"checkbox\",y.checkOn=\"\"!==ot.value,y.optSelected=at.selected,(ot=E.createElement(\"input\")).value=\"t\",ot.type=\"radio\",y.radioValue=\"t\"===ot.value;var ht,gt=k.expr.attrHandle;k.fn.extend({attr:function(e,t){return _(this,k.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){k.removeAttr(this,e)})}}),k.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return\"undefined\"==typeof e.getAttribute?k.prop(e,t,n):(1===o&&k.isXMLDoc(e)||(i=k.attrHooks[t.toLowerCase()]||(k.expr.match.bool.test(t)?ht:void 0)),void 0!==n?null===n?void k.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:null==(r=k.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&\"radio\"===t&&A(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(R);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),ht={set:function(e,t,n){return!1===t?k.removeAttr(e,n):e.setAttribute(n,n),n}},k.each(k.expr.match.bool.source.match(/\\w+/g),function(e,t){var a=gt[t]||k.find.attr;gt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=gt[o],gt[o]=r,r=null!=a(e,t,n)?o:null,gt[o]=i),r}});var vt=/^(?:input|select|textarea|button)$/i,yt=/^(?:a|area)$/i;function mt(e){return(e.match(R)||[]).join(\" \")}function xt(e){return e.getAttribute&&e.getAttribute(\"class\")||\"\"}function bt(e){return Array.isArray(e)?e:\"string\"==typeof e&&e.match(R)||[]}k.fn.extend({prop:function(e,t){return _(this,k.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[k.propFix[e]||e]})}}),k.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&k.isXMLDoc(e)||(t=k.propFix[t]||t,i=k.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=k.find.attr(e,\"tabindex\");return t?parseInt(t,10):vt.test(e.nodeName)||yt.test(e.nodeName)&&e.href?0:-1}}},propFix:{\"for\":\"htmlFor\",\"class\":\"className\"}}),y.optSelected||(k.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)}}),k.each([\"tabIndex\",\"readOnly\",\"maxLength\",\"cellSpacing\",\"cellPadding\",\"rowSpan\",\"colSpan\",\"useMap\",\"frameBorder\",\"contentEditable\"],function(){k.propFix[this.toLowerCase()]=this}),k.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){k(this).addClass(t.call(this,e,xt(this)))});if((e=bt(t)).length)while(n=this[u++])if(i=xt(n),r=1===n.nodeType&&\" \"+mt(i)+\" \"){a=0;while(o=e[a++])r.indexOf(\" \"+o+\" \")<0&&(r+=o+\" \");i!==(s=mt(r))&&n.setAttribute(\"class\",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){k(this).removeClass(t.call(this,e,xt(this)))});if(!arguments.length)return this.attr(\"class\",\"\");if((e=bt(t)).length)while(n=this[u++])if(i=xt(n),r=1===n.nodeType&&\" \"+mt(i)+\" \"){a=0;while(o=e[a++])while(-1<r.indexOf(\" \"+o+\" \"))r=r.replace(\" \"+o+\" \",\" \");i!==(s=mt(r))&&n.setAttribute(\"class\",s)}return this},toggleClass:function(i,t){var o=typeof i,a=\"string\"===o||Array.isArray(i);return\"boolean\"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){k(this).toggleClass(i.call(this,e,xt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=k(this),r=bt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&\"boolean\"!==o||((e=xt(this))&&Q.set(this,\"__className__\",e),this.setAttribute&&this.setAttribute(\"class\",e||!1===i?\"\":Q.get(this,\"__className__\")||\"\"))})},hasClass:function(e){var t,n,r=0;t=\" \"+e+\" \";while(n=this[r++])if(1===n.nodeType&&-1<(\" \"+mt(xt(n))+\" \").indexOf(t))return!0;return!1}});var wt=/\\r/g;k.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,k(this).val()):n)?t=\"\":\"number\"==typeof t?t+=\"\":Array.isArray(t)&&(t=k.map(t,function(e){return null==e?\"\":e+\"\"})),(r=k.valHooks[this.type]||k.valHooks[this.nodeName.toLowerCase()])&&\"set\"in r&&void 0!==r.set(this,t,\"value\")||(this.value=t))})):t?(r=k.valHooks[t.type]||k.valHooks[t.nodeName.toLowerCase()])&&\"get\"in r&&void 0!==(e=r.get(t,\"value\"))?e:\"string\"==typeof(e=t.value)?e.replace(wt,\"\"):null==e?\"\":e:void 0}}),k.extend({valHooks:{option:{get:function(e){var t=k.find.attr(e,\"value\");return null!=t?t:mt(k.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=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!A(n.parentNode,\"optgroup\"))){if(t=k(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=k.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<k.inArray(k.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),k.each([\"radio\",\"checkbox\"],function(){k.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<k.inArray(k(e).val(),t)}},y.checkOn||(k.valHooks[this].get=function(e){return null===e.getAttribute(\"value\")?\"on\":e.value})}),y.focusin=\"onfocusin\"in C;var Tt=/^(?:focusinfocus|focusoutblur)$/,Ct=function(e){e.stopPropagation()};k.extend(k.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,\"type\")?e.type:e,h=v.call(e,\"namespace\")?e.namespace.split(\".\"):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!Tt.test(d+k.event.triggered)&&(-1<d.indexOf(\".\")&&(d=(h=d.split(\".\")).shift(),h.sort()),u=d.indexOf(\":\")<0&&\"on\"+d,(e=e[k.expando]?e:new k.Event(d,\"object\"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join(\".\"),e.rnamespace=e.namespace?new RegExp(\"(^|\\\\.)\"+h.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:k.makeArray(t,[e]),c=k.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,Tt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Q.get(o,\"events\")||{})[e.type]&&Q.get(o,\"handle\"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&G(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!G(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),k.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,Ct),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,Ct),k.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=k.extend(new k.Event,n,{type:e,isSimulated:!0});k.event.trigger(r,null,t)}}),k.fn.extend({trigger:function(e,t){return this.each(function(){k.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return k.event.trigger(e,t,n,!0)}}),y.focusin||k.each({focus:\"focusin\",blur:\"focusout\"},function(n,r){var i=function(e){k.event.simulate(r,e.target,k.event.fix(e))};k.event.special[r]={setup:function(){var e=this.ownerDocument||this,t=Q.access(e,r);t||e.addEventListener(n,i,!0),Q.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this,t=Q.access(e,r)-1;t?Q.access(e,r,t):(e.removeEventListener(n,i,!0),Q.remove(e,r))}}});var Et=C.location,kt=Date.now(),St=/\\?/;k.parseXML=function(e){var t;if(!e||\"string\"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,\"text/xml\")}catch(e){t=void 0}return t&&!t.getElementsByTagName(\"parsererror\").length||k.error(\"Invalid XML: \"+e),t};var Nt=/\\[\\]$/,At=/\\r?\\n/g,Dt=/^(?:submit|button|image|reset|file)$/i,jt=/^(?:input|select|textarea|keygen)/i;function qt(n,e,r,i){var t;if(Array.isArray(e))k.each(e,function(e,t){r||Nt.test(n)?i(n,t):qt(n+\"[\"+(\"object\"==typeof t&&null!=t?e:\"\")+\"]\",t,r,i)});else if(r||\"object\"!==w(e))i(n,e);else for(t in e)qt(n+\"[\"+t+\"]\",e[t],r,i)}k.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+\"=\"+encodeURIComponent(null==n?\"\":n)};if(null==e)return\"\";if(Array.isArray(e)||e.jquery&&!k.isPlainObject(e))k.each(e,function(){i(this.name,this.value)});else for(n in e)qt(n,e[n],t,i);return r.join(\"&\")},k.fn.extend({serialize:function(){return k.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=k.prop(this,\"elements\");return e?k.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!k(this).is(\":disabled\")&&jt.test(this.nodeName)&&!Dt.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=k(this).val();return null==n?null:Array.isArray(n)?k.map(n,function(e){return{name:t.name,value:e.replace(At,\"\\r\\n\")}}):{name:t.name,value:n.replace(At,\"\\r\\n\")}}).get()}});var Lt=/%20/g,Ht=/#.*$/,Ot=/([?&])_=[^&]*/,Pt=/^(.*?):[ \\t]*([^\\r\\n]*)$/gm,Rt=/^(?:GET|HEAD)$/,Mt=/^\\/\\//,It={},Wt={},$t=\"*/\".concat(\"*\"),Ft=E.createElement(\"a\");function Bt(o){return function(e,t){\"string\"!=typeof e&&(t=e,e=\"*\");var n,r=0,i=e.toLowerCase().match(R)||[];if(m(t))while(n=i[r++])\"+\"===n[0]?(n=n.slice(1)||\"*\",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function _t(t,i,o,a){var s={},u=t===Wt;function l(e){var r;return s[e]=!0,k.each(t[e]||[],function(e,t){var n=t(i,o,a);return\"string\"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s[\"*\"]&&l(\"*\")}function zt(e,t){var n,r,i=k.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&k.extend(!0,e,r),e}Ft.href=Et.href,k.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Et.href,type:\"GET\",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Et.protocol),global:!0,processData:!0,async:!0,contentType:\"application/x-www-form-urlencoded; charset=UTF-8\",accepts:{\"*\":$t,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\":k.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?zt(zt(e,k.ajaxSettings),t):zt(k.ajaxSettings,e)},ajaxPrefilter:Bt(It),ajaxTransport:Bt(Wt),ajax:function(e,t){\"object\"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=k.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?k(y):k.event,x=k.Deferred(),b=k.Callbacks(\"once memory\"),w=v.statusCode||{},a={},s={},u=\"canceled\",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Pt.exec(p))n[t[1].toLowerCase()+\" \"]=(n[t[1].toLowerCase()+\" \"]||[]).concat(t[2])}t=n[e.toLowerCase()+\" \"]}return null==t?null:t.join(\", \")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Et.href)+\"\").replace(Mt,Et.protocol+\"//\"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||\"*\").toLowerCase().match(R)||[\"\"],null==v.crossDomain){r=E.createElement(\"a\");try{r.href=v.url,r.href=r.href,v.crossDomain=Ft.protocol+\"//\"+Ft.host!=r.protocol+\"//\"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&\"string\"!=typeof v.data&&(v.data=k.param(v.data,v.traditional)),_t(It,v,t,T),h)return T;for(i in(g=k.event&&v.global)&&0==k.active++&&k.event.trigger(\"ajaxStart\"),v.type=v.type.toUpperCase(),v.hasContent=!Rt.test(v.type),f=v.url.replace(Ht,\"\"),v.hasContent?v.data&&v.processData&&0===(v.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&(v.data=v.data.replace(Lt,\"+\")):(o=v.url.slice(f.length),v.data&&(v.processData||\"string\"==typeof v.data)&&(f+=(St.test(f)?\"&\":\"?\")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Ot,\"$1\"),o=(St.test(f)?\"&\":\"?\")+\"_=\"+kt+++o),v.url=f+o),v.ifModified&&(k.lastModified[f]&&T.setRequestHeader(\"If-Modified-Since\",k.lastModified[f]),k.etag[f]&&T.setRequestHeader(\"If-None-Match\",k.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader(\"Content-Type\",v.contentType),T.setRequestHeader(\"Accept\",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+(\"*\"!==v.dataTypes[0]?\", \"+$t+\"; q=0.01\":\"\"):v.accepts[\"*\"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u=\"abort\",b.add(v.complete),T.done(v.success),T.fail(v.error),c=_t(Wt,v,t,T)){if(T.readyState=1,g&&m.trigger(\"ajaxSend\",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort(\"timeout\")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,\"No Transport\");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||\"\",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while(\"*\"===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}if(o)return o!==u[0]&&u.unshift(o),n[o]}(v,T,n)),s=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if(\"*\"===o)o=u;else if(\"*\"!==u&&u!==o){if(!(a=l[u+\" \"+o]||l[\"* \"+o]))for(i in l)if((s=i.split(\" \"))[1]===o&&(a=l[u+\" \"+s[0]]||l[\"* \"+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.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 \"+u+\" to \"+o}}}return{state:\"success\",data:t}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader(\"Last-Modified\"))&&(k.lastModified[f]=u),(u=T.getResponseHeader(\"etag\"))&&(k.etag[f]=u)),204===e||\"HEAD\"===v.type?l=\"nocontent\":304===e?l=\"notmodified\":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l=\"error\",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+\"\",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?\"ajaxSuccess\":\"ajaxError\",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger(\"ajaxComplete\",[T,v]),--k.active||k.event.trigger(\"ajaxStop\")))}return T},getJSON:function(e,t,n){return k.get(e,t,n,\"json\")},getScript:function(e,t){return k.get(e,void 0,t,\"script\")}}),k.each([\"get\",\"post\"],function(e,i){k[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),k.ajax(k.extend({url:e,type:i,dataType:r,data:t,success:n},k.isPlainObject(e)&&e))}}),k._evalUrl=function(e,t){return k.ajax({url:e,type:\"GET\",dataType:\"script\",cache:!0,async:!1,global:!1,converters:{\"text script\":function(){}},dataFilter:function(e){k.globalEval(e,t)}})},k.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=k(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return m(n)?this.each(function(e){k(this).wrapInner(n.call(this,e))}):this.each(function(){var e=k(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){k(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not(\"body\").each(function(){k(this).replaceWith(this.childNodes)}),this}}),k.expr.pseudos.hidden=function(e){return!k.expr.pseudos.visible(e)},k.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},k.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var Ut={0:200,1223:204},Xt=k.ajaxSettings.xhr();y.cors=!!Xt&&\"withCredentials\"in Xt,y.ajax=Xt=!!Xt,k.ajaxTransport(function(i){var o,a;if(y.cors||Xt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e[\"X-Requested-With\"]||(e[\"X-Requested-With\"]=\"XMLHttpRequest\"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,\"abort\"===e?r.abort():\"error\"===e?\"number\"!=typeof r.status?t(0,\"error\"):t(r.status,r.statusText):t(Ut[r.status]||r.status,r.statusText,\"text\"!==(r.responseType||\"text\")||\"string\"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o(\"error\"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o(\"abort\");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),k.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),k.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 k.globalEval(e),e}}}),k.ajaxPrefilter(\"script\",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type=\"GET\")}),k.ajaxTransport(\"script\",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=k(\"<script>\").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on(\"load error\",i=function(e){r.remove(),i=null,e&&t(\"error\"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Vt,Gt=[],Yt=/(=)\\?(?=&|$)|\\?\\?/;k.ajaxSetup({jsonp:\"callback\",jsonpCallback:function(){var e=Gt.pop()||k.expando+\"_\"+kt++;return this[e]=!0,e}}),k.ajaxPrefilter(\"json jsonp\",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Yt.test(e.url)?\"url\":\"string\"==typeof e.data&&0===(e.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&Yt.test(e.data)&&\"data\");if(a||\"jsonp\"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Yt,\"$1\"+r):!1!==e.jsonp&&(e.url+=(St.test(e.url)?\"&\":\"?\")+e.jsonp+\"=\"+r),e.converters[\"script json\"]=function(){return o||k.error(r+\" was not called\"),o[0]},e.dataTypes[0]=\"json\",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?k(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Gt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),\"script\"}),y.createHTMLDocument=((Vt=E.implementation.createHTMLDocument(\"\").body).innerHTML=\"<form></form><form></form>\",2===Vt.childNodes.length),k.parseHTML=function(e,t,n){return\"string\"!=typeof e?[]:(\"boolean\"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument(\"\")).createElement(\"base\")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=we([e],t,o),o&&o.length&&k(o).remove(),k.merge([],i.childNodes)));var r,i,o},k.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(\" \");return-1<s&&(r=mt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&\"object\"==typeof t&&(i=\"POST\"),0<a.length&&k.ajax({url:e,type:i||\"GET\",dataType:\"html\",data:t}).done(function(e){o=arguments,a.html(r?k(\"<div>\").append(k.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},k.each([\"ajaxStart\",\"ajaxStop\",\"ajaxComplete\",\"ajaxError\",\"ajaxSuccess\",\"ajaxSend\"],function(e,t){k.fn[t]=function(e){return this.on(t,e)}}),k.expr.pseudos.animated=function(t){return k.grep(k.timers,function(e){return t===e.elem}).length},k.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=k.css(e,\"position\"),c=k(e),f={};\"static\"===l&&(e.style.position=\"relative\"),s=c.offset(),o=k.css(e,\"top\"),u=k.css(e,\"left\"),(\"absolute\"===l||\"fixed\"===l)&&-1<(o+u).indexOf(\"auto\")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,k.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),\"using\"in t?t.using.call(e,f):c.css(f)}},k.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){k.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if(\"fixed\"===k.css(r,\"position\"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&\"static\"===k.css(e,\"position\"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=k(e).offset()).top+=k.css(e,\"borderTopWidth\",!0),i.left+=k.css(e,\"borderLeftWidth\",!0))}return{top:t.top-i.top-k.css(r,\"marginTop\",!0),left:t.left-i.left-k.css(r,\"marginLeft\",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&\"static\"===k.css(e,\"position\"))e=e.offsetParent;return e||ie})}}),k.each({scrollLeft:\"pageXOffset\",scrollTop:\"pageYOffset\"},function(t,i){var o=\"pageYOffset\"===i;k.fn[t]=function(e){return _(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),k.each([\"top\",\"left\"],function(e,n){k.cssHooks[n]=ze(y.pixelPosition,function(e,t){if(t)return t=_e(e,n),$e.test(t)?k(e).position()[n]+\"px\":t})}),k.each({Height:\"height\",Width:\"width\"},function(a,s){k.each({padding:\"inner\"+a,content:s,\"\":\"outer\"+a},function(r,o){k.fn[o]=function(e,t){var n=arguments.length&&(r||\"boolean\"!=typeof e),i=r||(!0===e||!0===t?\"margin\":\"border\");return _(this,function(e,t,n){var r;return x(e)?0===o.indexOf(\"outer\")?e[\"inner\"+a]:e.document.documentElement[\"client\"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body[\"scroll\"+a],r[\"scroll\"+a],e.body[\"offset\"+a],r[\"offset\"+a],r[\"client\"+a])):void 0===n?k.css(e,t,i):k.style(e,t,n,i)},s,n?e:void 0,n)}})}),k.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,n){k.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}}),k.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),k.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)}}),k.proxy=function(e,t){var n,r,i;if(\"string\"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||k.guid++,i},k.holdReady=function(e){e?k.readyWait++:k.ready(!0)},k.isArray=Array.isArray,k.parseJSON=JSON.parse,k.nodeName=A,k.isFunction=m,k.isWindow=x,k.camelCase=V,k.type=w,k.now=Date.now,k.isNumeric=function(e){var t=k.type(e);return(\"number\"===t||\"string\"===t)&&!isNaN(e-parseFloat(e))},\"function\"==typeof define&&define.amd&&define(\"jquery\",[],function(){return k});var Qt=C.jQuery,Jt=C.$;return k.noConflict=function(e){return C.$===k&&(C.$=Jt),e&&C.jQuery===k&&(C.jQuery=Qt),k},e||(C.jQuery=C.$=k),k});\n/*\n * jQuery throttle / debounce - v1.1 - 3/7/2010\n * http://benalman.com/projects/jquery-throttle-debounce-plugin/\n * \n * Copyright (c) 2010 \"Cowboy\" Ben Alman\n * Dual licensed under the MIT and GPL licenses.\n * http://benalman.com/about/license/\n */\n(function(b,c){var $=b.jQuery||b.Cowboy||(b.Cowboy={}),a;$.throttle=a=function(e,f,j,i){var h,d=0;if(typeof f!==\"boolean\"){i=j;j=f;f=c}function g(){var o=this,m=+new Date()-d,n=arguments;function l(){d=+new Date();j.apply(o,n)}function k(){h=c}if(i&&!h){l()}h&&clearTimeout(h);if(i===c&&m>e){l()}else{if(f!==true){h=setTimeout(i?k:l,i===c?e-m:e)}}}if($.guid){g.guid=j.guid=j.guid||$.guid++}return g};$.debounce=function(d,e,f){return f===c?a(d,e,false):a(d,f,e!==false)}})(this);\n/*!\n * imagesLoaded PACKAGED v4.1.0\n * JavaScript is all like \"You images are done yet or what?\"\n * MIT License\n */\n!function(t,e){\"function\"==typeof define&&define.amd?define(\"ev-emitter/ev-emitter\",e):\"object\"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}(this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return-1==n.indexOf(e)&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||[];return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return-1!=n&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=0,o=i[n];e=e||[];for(var r=this._onceEvents&&this._onceEvents[t];o;){var s=r&&r[o];s&&(this.off(t,o),delete r[o]),o.apply(this,e),n+=s?0:1,o=i[n]}return this}},t}),function(t,e){\"use strict\";\"function\"==typeof define&&define.amd?define([\"ev-emitter/ev-emitter\"],function(i){return e(t,i)}):\"object\"==typeof module&&module.exports?module.exports=e(t,require(\"ev-emitter\")):t.imagesLoaded=e(t,t.EvEmitter)}(window,function(t,e){function i(t,e){for(var i in e)t[i]=e[i];return t}function n(t){var e=[];if(Array.isArray(t))e=t;else if(\"number\"==typeof t.length)for(var i=0;i<t.length;i++)e.push(t[i]);else e.push(t);return e}function o(t,e,r){return this instanceof o?(\"string\"==typeof t&&(t=document.querySelectorAll(t)),this.elements=n(t),this.options=i({},this.options),\"function\"==typeof e?r=e:i(this.options,e),r&&this.on(\"always\",r),this.getImages(),h&&(this.jqDeferred=new h.Deferred),void setTimeout(function(){this.check()}.bind(this))):new o(t,e,r)}function r(t){this.img=t}function s(t,e){this.url=t,this.element=e,this.img=new Image}var h=t.jQuery,a=t.console;o.prototype=Object.create(e.prototype),o.prototype.options={},o.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},o.prototype.addElementImages=function(t){\"IMG\"==t.nodeName&&this.addImage(t),this.options.background===!0&&this.addElementBackgroundImages(t);var e=t.nodeType;if(e&&d[e]){for(var i=t.querySelectorAll(\"img\"),n=0;n<i.length;n++){var o=i[n];this.addImage(o)}if(\"string\"==typeof this.options.background){var r=t.querySelectorAll(this.options.background);for(n=0;n<r.length;n++){var s=r[n];this.addElementBackgroundImages(s)}}}};var d={1:!0,9:!0,11:!0};return o.prototype.addElementBackgroundImages=function(t){var e=getComputedStyle(t);if(e)for(var i=/url\\((['\"])?(.*?)\\1\\)/gi,n=i.exec(e.backgroundImage);null!==n;){var o=n&&n[2];o&&this.addBackground(o,t),n=i.exec(e.backgroundImage)}},o.prototype.addImage=function(t){var e=new r(t);this.images.push(e)},o.prototype.addBackground=function(t,e){var i=new s(t,e);this.images.push(i)},o.prototype.check=function(){function t(t,i,n){setTimeout(function(){e.progress(t,i,n)})}var e=this;return this.progressedCount=0,this.hasAnyBroken=!1,this.images.length?void this.images.forEach(function(e){e.once(\"progress\",t),e.check()}):void this.complete()},o.prototype.progress=function(t,e,i){this.progressedCount++,this.hasAnyBroken=this.hasAnyBroken||!t.isLoaded,this.emitEvent(\"progress\",[this,t,e]),this.jqDeferred&&this.jqDeferred.notify&&this.jqDeferred.notify(this,t),this.progressedCount==this.images.length&&this.complete(),this.options.debug&&a&&a.log(\"progress: \"+i,t,e)},o.prototype.complete=function(){var t=this.hasAnyBroken?\"fail\":\"done\";if(this.isComplete=!0,this.emitEvent(t,[this]),this.emitEvent(\"always\",[this]),this.jqDeferred){var e=this.hasAnyBroken?\"reject\":\"resolve\";this.jqDeferred[e](this)}},r.prototype=Object.create(e.prototype),r.prototype.check=function(){var t=this.getIsImageComplete();return t?void this.confirm(0!==this.img.naturalWidth,\"naturalWidth\"):(this.proxyImage=new Image,this.proxyImage.addEventListener(\"load\",this),this.proxyImage.addEventListener(\"error\",this),this.img.addEventListener(\"load\",this),this.img.addEventListener(\"error\",this),void(this.proxyImage.src=this.img.src))},r.prototype.getIsImageComplete=function(){return this.img.complete&&void 0!==this.img.naturalWidth},r.prototype.confirm=function(t,e){this.isLoaded=t,this.emitEvent(\"progress\",[this,this.img,e])},r.prototype.handleEvent=function(t){var e=\"on\"+t.type;this[e]&&this[e](t)},r.prototype.onload=function(){this.confirm(!0,\"onload\"),this.unbindEvents()},r.prototype.onerror=function(){this.confirm(!1,\"onerror\"),this.unbindEvents()},r.prototype.unbindEvents=function(){this.proxyImage.removeEventListener(\"load\",this),this.proxyImage.removeEventListener(\"error\",this),this.img.removeEventListener(\"load\",this),this.img.removeEventListener(\"error\",this)},s.prototype=Object.create(r.prototype),s.prototype.check=function(){this.img.addEventListener(\"load\",this),this.img.addEventListener(\"error\",this),this.img.src=this.url;var t=this.getIsImageComplete();t&&(this.confirm(0!==this.img.naturalWidth,\"naturalWidth\"),this.unbindEvents())},s.prototype.unbindEvents=function(){this.img.removeEventListener(\"load\",this),this.img.removeEventListener(\"error\",this)},s.prototype.confirm=function(t,e){this.isLoaded=t,this.emitEvent(\"progress\",[this,this.element,e])},o.makeJQueryPlugin=function(e){e=e||t.jQuery,e&&(h=e,h.fn.imagesLoaded=function(t,e){var i=new o(this,t,e);return i.jqDeferred.promise(h(this))})},o.makeJQueryPlugin(),o});\n/*! lz-string-1.3.3-min.js | (c) 2013 Pieroxy | Licensed under a WTFPL license */\nvar LZString={_keyStr:\"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\",_f:String.fromCharCode,compressToBase64:function(e){if(e==null)return\"\";var t=\"\";var n,r,i,s,o,u,a;var f=0;e=LZString.compress(e);while(f<e.length*2){if(f%2==0){n=e.charCodeAt(f/2)>>8;r=e.charCodeAt(f/2)&255;if(f/2+1<e.length)i=e.charCodeAt(f/2+1)>>8;else i=NaN}else{n=e.charCodeAt((f-1)/2)&255;if((f+1)/2<e.length){r=e.charCodeAt((f+1)/2)>>8;i=e.charCodeAt((f+1)/2)&255}else r=i=NaN}f+=3;s=n>>2;o=(n&3)<<4|r>>4;u=(r&15)<<2|i>>6;a=i&63;if(isNaN(r)){u=a=64}else if(isNaN(i)){a=64}t=t+LZString._keyStr.charAt(s)+LZString._keyStr.charAt(o)+LZString._keyStr.charAt(u)+LZString._keyStr.charAt(a)}return t},decompressFromBase64:function(e){if(e==null)return\"\";var t=\"\",n=0,r,i,s,o,u,a,f,l,c=0,h=LZString._f;e=e.replace(/[^A-Za-z0-9\\+\\/\\=]/g,\"\");while(c<e.length){u=LZString._keyStr.indexOf(e.charAt(c++));a=LZString._keyStr.indexOf(e.charAt(c++));f=LZString._keyStr.indexOf(e.charAt(c++));l=LZString._keyStr.indexOf(e.charAt(c++));i=u<<2|a>>4;s=(a&15)<<4|f>>2;o=(f&3)<<6|l;if(n%2==0){r=i<<8;if(f!=64){t+=h(r|s)}if(l!=64){r=o<<8}}else{t=t+h(r|i);if(f!=64){r=s<<8}if(l!=64){t+=h(r|o)}}n+=3}return LZString.decompress(t)},compressToUTF16:function(e){if(e==null)return\"\";var t=\"\",n,r,i,s=0,o=LZString._f;e=LZString.compress(e);for(n=0;n<e.length;n++){r=e.charCodeAt(n);switch(s++){case 0:t+=o((r>>1)+32);i=(r&1)<<14;break;case 1:t+=o(i+(r>>2)+32);i=(r&3)<<13;break;case 2:t+=o(i+(r>>3)+32);i=(r&7)<<12;break;case 3:t+=o(i+(r>>4)+32);i=(r&15)<<11;break;case 4:t+=o(i+(r>>5)+32);i=(r&31)<<10;break;case 5:t+=o(i+(r>>6)+32);i=(r&63)<<9;break;case 6:t+=o(i+(r>>7)+32);i=(r&127)<<8;break;case 7:t+=o(i+(r>>8)+32);i=(r&255)<<7;break;case 8:t+=o(i+(r>>9)+32);i=(r&511)<<6;break;case 9:t+=o(i+(r>>10)+32);i=(r&1023)<<5;break;case 10:t+=o(i+(r>>11)+32);i=(r&2047)<<4;break;case 11:t+=o(i+(r>>12)+32);i=(r&4095)<<3;break;case 12:t+=o(i+(r>>13)+32);i=(r&8191)<<2;break;case 13:t+=o(i+(r>>14)+32);i=(r&16383)<<1;break;case 14:t+=o(i+(r>>15)+32,(r&32767)+32);s=0;break}}return t+o(i+32)},decompressFromUTF16:function(e){if(e==null)return\"\";var t=\"\",n,r,i=0,s=0,o=LZString._f;while(s<e.length){r=e.charCodeAt(s)-32;switch(i++){case 0:n=r<<1;break;case 1:t+=o(n|r>>14);n=(r&16383)<<2;break;case 2:t+=o(n|r>>13);n=(r&8191)<<3;break;case 3:t+=o(n|r>>12);n=(r&4095)<<4;break;case 4:t+=o(n|r>>11);n=(r&2047)<<5;break;case 5:t+=o(n|r>>10);n=(r&1023)<<6;break;case 6:t+=o(n|r>>9);n=(r&511)<<7;break;case 7:t+=o(n|r>>8);n=(r&255)<<8;break;case 8:t+=o(n|r>>7);n=(r&127)<<9;break;case 9:t+=o(n|r>>6);n=(r&63)<<10;break;case 10:t+=o(n|r>>5);n=(r&31)<<11;break;case 11:t+=o(n|r>>4);n=(r&15)<<12;break;case 12:t+=o(n|r>>3);n=(r&7)<<13;break;case 13:t+=o(n|r>>2);n=(r&3)<<14;break;case 14:t+=o(n|r>>1);n=(r&1)<<15;break;case 15:t+=o(n|r);i=0;break}s++}return LZString.decompress(t)},compress:function(e){if(e==null)return\"\";var t,n,r={},i={},s=\"\",o=\"\",u=\"\",a=2,f=3,l=2,c=\"\",h=0,p=0,d,v=LZString._f;for(d=0;d<e.length;d+=1){s=e.charAt(d);if(!Object.prototype.hasOwnProperty.call(r,s)){r[s]=f++;i[s]=true}o=u+s;if(Object.prototype.hasOwnProperty.call(r,o)){u=o}else{if(Object.prototype.hasOwnProperty.call(i,u)){if(u.charCodeAt(0)<256){for(t=0;t<l;t++){h=h<<1;if(p==15){p=0;c+=v(h);h=0}else{p++}}n=u.charCodeAt(0);for(t=0;t<8;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}else{n=1;for(t=0;t<l;t++){h=h<<1|n;if(p==15){p=0;c+=v(h);h=0}else{p++}n=0}n=u.charCodeAt(0);for(t=0;t<16;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}delete i[u]}else{n=r[u];for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}r[o]=f++;u=String(s)}}if(u!==\"\"){if(Object.prototype.hasOwnProperty.call(i,u)){if(u.charCodeAt(0)<256){for(t=0;t<l;t++){h=h<<1;if(p==15){p=0;c+=v(h);h=0}else{p++}}n=u.charCodeAt(0);for(t=0;t<8;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}else{n=1;for(t=0;t<l;t++){h=h<<1|n;if(p==15){p=0;c+=v(h);h=0}else{p++}n=0}n=u.charCodeAt(0);for(t=0;t<16;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}delete i[u]}else{n=r[u];for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}}n=2;for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}while(true){h=h<<1;if(p==15){c+=v(h);break}else p++}return c},decompress:function(e){if(e==null)return\"\";if(e==\"\")return null;var t=[],n,r=4,i=4,s=3,o=\"\",u=\"\",a,f,l,c,h,p,d,v=LZString._f,m={string:e,val:e.charCodeAt(0),position:32768,index:1};for(a=0;a<3;a+=1){t[a]=a}l=0;h=Math.pow(2,2);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}switch(n=l){case 0:l=0;h=Math.pow(2,8);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}d=v(l);break;case 1:l=0;h=Math.pow(2,16);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}d=v(l);break;case 2:return\"\"}t[3]=d;f=u=d;while(true){if(m.index>m.string.length){return\"\"}l=0;h=Math.pow(2,s);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}switch(d=l){case 0:l=0;h=Math.pow(2,8);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}t[i++]=v(l);d=i-1;r--;break;case 1:l=0;h=Math.pow(2,16);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}t[i++]=v(l);d=i-1;r--;break;case 2:return u}if(r==0){r=Math.pow(2,s);s++}if(t[d]){o=t[d]}else{if(d===i){o=f+f.charAt(0)}else{return null}}u+=o;t[i++]=f+o.charAt(0);r--;f=o;if(r==0){r=Math.pow(2,s);s++}}}};if(typeof module!==\"undefined\"&&module!=null){module.exports=LZString}\n/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */\nvar saveAs=saveAs||navigator.msSaveBlob&&navigator.msSaveBlob.bind(navigator)||function(e){\"use strict\";var t=e.document,n=function(){return e.URL||e.webkitURL||e},r=e.URL||e.webkitURL||e,i=t.createElementNS(\"http://www.w3.org/1999/xhtml\",\"a\"),s=\"download\"in i,o=function(n){var r=t.createEvent(\"MouseEvents\");r.initMouseEvent(\"click\",true,false,e,0,0,0,0,0,false,false,false,false,0,null);n.dispatchEvent(r)},u=e.webkitRequestFileSystem,a=e.requestFileSystem||u||e.mozRequestFileSystem,f=function(t){(e.setImmediate||e.setTimeout)(function(){throw t},0)},l=\"application/octet-stream\",c=0,h=[],p=function(){var e=h.length;while(e--){var t=h[e];if(typeof t===\"string\"){r.revokeObjectURL(t)}else{t.remove()}}h.length=0},d=function(e,t,n){t=[].concat(t);var r=t.length;while(r--){var i=e[\"on\"+t[r]];if(typeof i===\"function\"){try{i.call(e,n||e)}catch(s){f(s)}}}},v=function(t,r){var f=this,p=t.type,v=false,m,g,y=function(){var e=n().createObjectURL(t);h.push(e);return e},b=function(){d(f,\"writestart progress write writeend\".split(\" \"))},w=function(){if(v||!m){m=y(t)}if(g){g.location.href=m}else{window.open(m,\"_blank\")}f.readyState=f.DONE;b()},E=function(e){return function(){if(f.readyState!==f.DONE){return e.apply(this,arguments)}}},S={create:true,exclusive:false},x;f.readyState=f.INIT;if(!r){r=\"download\"}if(s){m=y(t);i.href=m;i.download=r;o(i);f.readyState=f.DONE;b();return}if(e.chrome&&p&&p!==l){x=t.slice||t.webkitSlice;t=x.call(t,0,t.size,l);v=true}if(u&&r!==\"download\"){r+=\".download\"}if(p===l||u){g=e}if(!a){w();return}c+=t.size;a(e.TEMPORARY,c,E(function(e){e.root.getDirectory(\"saved\",S,E(function(e){var n=function(){e.getFile(r,S,E(function(e){e.createWriter(E(function(n){n.onwriteend=function(t){g.location.href=e.toURL();h.push(e);f.readyState=f.DONE;d(f,\"writeend\",t)};n.onerror=function(){var e=n.error;if(e.code!==e.ABORT_ERR){w()}};\"writestart progress write abort\".split(\" \").forEach(function(e){n[\"on\"+e]=f[\"on\"+e]});n.write(t);f.abort=function(){n.abort();f.readyState=f.DONE};f.readyState=f.WRITING}),w)}),w)};e.getFile(r,{create:false},E(function(e){e.remove();n()}),E(function(e){if(e.code===e.NOT_FOUND_ERR){n()}else{w()}}))}),w)}),w)},m=v.prototype,g=function(e,t){return new v(e,t)};m.abort=function(){var e=this;e.readyState=e.DONE;d(e,\"abort\")};m.readyState=m.INIT=0;m.WRITING=1;m.DONE=2;m.error=m.onwritestart=m.onprogress=m.onwrite=m.onabort=m.onerror=m.onwriteend=null;e.addEventListener(\"unload\",p,false);return g}(self)\n/*! seedrandom.js v2.3.3 | (c) 2013 David Bau, all rights reserved. | Licensed under a BSD-style license */\n!function(a,b,c,d,e,f,g,h,i){function j(a){var b,c=a.length,e=this,f=0,g=e.i=e.j=0,h=e.S=[];for(c||(a=[c++]);d>f;)h[f]=f++;for(f=0;d>f;f++)h[f]=h[g=r&g+a[f%c]+(b=h[f])],h[g]=b;(e.g=function(a){for(var b,c=0,f=e.i,g=e.j,h=e.S;a--;)b=h[f=r&f+1],c=c*d+h[r&(h[f]=h[g=r&g+b])+(h[g]=b)];return e.i=f,e.j=g,c})(d)}function k(a,b){var c,d=[],e=typeof a;if(b&&\"object\"==e)for(c in a)try{d.push(k(a[c],b-1))}catch(f){}return d.length?d:\"string\"==e?a:a+\"\\0\"}function l(a,b){for(var c,d=a+\"\",e=0;e<d.length;)b[r&e]=r&(c^=19*b[r&e])+d.charCodeAt(e++);return n(b)}function m(c){try{return a.crypto.getRandomValues(c=new Uint8Array(d)),n(c)}catch(e){return[+new Date,a,(c=a.navigator)&&c.plugins,a.screen,n(b)]}}function n(a){return String.fromCharCode.apply(0,a)}var o=c.pow(d,e),p=c.pow(2,f),q=2*p,r=d-1,s=c[\"seed\"+i]=function(a,f,g){var h=[],r=l(k(f?[a,n(b)]:null==a?m():a,3),h),s=new j(h);return l(n(s.S),b),(g||function(a,b,d){return d?(c[i]=a,b):a})(function(){for(var a=s.g(e),b=o,c=0;p>a;)a=(a+c)*d,b*=d,c=s.g(1);for(;a>=q;)a/=2,b/=2,c>>>=1;return(a+c)/b},r,this==c)};l(c[i](),b),g&&g.exports?g.exports=s:h&&h.amd&&h(function(){return s})}(this,[],Math,256,6,52,\"object\"==typeof module&&module,\"function\"==typeof define&&define,\"random\");\n/*! console_hack.js | (c) 2015 Thomas Michael Edwards | Licensed under SugarCube's Simple BSD license */\n!function(){for(var methods=[\"assert\",\"clear\",\"count\",\"debug\",\"dir\",\"dirxml\",\"error\",\"exception\",\"group\",\"groupCollapsed\",\"groupEnd\",\"info\",\"log\",\"markTimeline\",\"profile\",\"profileEnd\",\"table\",\"time\",\"timeEnd\",\"timeline\",\"timelineEnd\",\"timeStamp\",\"trace\",\"warn\"],length=methods.length,noop=function(){},console=window.console=window.console||{};length--;){var method=methods[length];console[method]||(console[method]=noop)}}();\n}else{document.documentElement.setAttribute(\"data-init\", \"lacking\");}\n</script>\n<style id=\"style-normalize\" type=\"text/css\">/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */\n\n/**\n * 1. Set default font family to sans-serif.\n * 2. Prevent iOS and IE text size adjust after device orientation change,\n *    without disabling user zoom.\n */\n\nhtml {\n  font-family: sans-serif; /* 1 */\n  -ms-text-size-adjust: 100%; /* 2 */\n  -webkit-text-size-adjust: 100%; /* 2 */\n}\n\n/**\n * Remove default margin.\n */\n\nbody {\n  margin: 0;\n}\n\n/* HTML5 display definitions\n   ========================================================================== */\n\n/**\n * Correct `block` display not defined for any HTML5 element in IE 8/9.\n * Correct `block` display not defined for `details` or `summary` in IE 10/11\n * and Firefox.\n * Correct `block` display not defined for `main` in IE 11.\n */\n\narticle,\naside,\ndetails,\nfigcaption,\nfigure,\nfooter,\nheader,\nhgroup,\nmain,\nmenu,\nnav,\nsection,\nsummary {\n  display: block;\n}\n\n/**\n * 1. Correct `inline-block` display not defined in IE 8/9.\n * 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.\n */\n\naudio,\ncanvas,\nprogress,\nvideo {\n  display: inline-block; /* 1 */\n  vertical-align: baseline; /* 2 */\n}\n\n/**\n * Prevent modern browsers from displaying `audio` without controls.\n * Remove excess height in iOS 5 devices.\n */\n\naudio:not([controls]) {\n  display: none;\n  height: 0;\n}\n\n/**\n * Address `[hidden]` styling not present in IE 8/9/10.\n * Hide the `template` element in IE 8/9/10/11, Safari, and Firefox < 22.\n */\n\n[hidden],\ntemplate {\n  display: none;\n}\n\n/* Links\n   ========================================================================== */\n\n/**\n * Remove the gray background color from active links in IE 10.\n */\n\na {\n  background-color: transparent;\n}\n\n/**\n * Improve readability of focused elements when they are also in an\n * active/hover state.\n */\n\na:active,\na:hover {\n  outline: 0;\n}\n\n/* Text-level semantics\n   ========================================================================== */\n\n/**\n * Address styling not present in IE 8/9/10/11, Safari, and Chrome.\n */\n\nabbr[title] {\n  border-bottom: 1px dotted;\n}\n\n/**\n * Address style set to `bolder` in Firefox 4+, Safari, and Chrome.\n */\n\nb,\nstrong {\n  font-weight: bold;\n}\n\n/**\n * Address styling not present in Safari and Chrome.\n */\n\ndfn {\n  font-style: italic;\n}\n\n/**\n * Address variable `h1` font-size and margin within `section` and `article`\n * contexts in Firefox 4+, Safari, and Chrome.\n */\n\nh1 {\n  font-size: 2em;\n  margin: 0.67em 0;\n}\n\n/**\n * Address styling not present in IE 8/9.\n */\n\nmark {\n  background: #ff0;\n  color: #000;\n}\n\n/**\n * Address inconsistent and variable font size in all browsers.\n */\n\nsmall {\n  font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` affecting `line-height` in all browsers.\n */\n\nsub,\nsup {\n  font-size: 75%;\n  line-height: 0;\n  position: relative;\n  vertical-align: baseline;\n}\n\nsup {\n  top: -0.5em;\n}\n\nsub {\n  bottom: -0.25em;\n}\n\n/* Embedded content\n   ========================================================================== */\n\n/**\n * Remove border when inside `a` element in IE 8/9/10.\n */\n\nimg {\n  border: 0;\n}\n\n/**\n * Correct overflow not hidden in IE 9/10/11.\n */\n\nsvg:not(:root) {\n  overflow: hidden;\n}\n\n/* Grouping content\n   ========================================================================== */\n\n/**\n * Address margin not present in IE 8/9 and Safari.\n */\n\nfigure {\n  margin: 1em 40px;\n}\n\n/**\n * Address differences between Firefox and other browsers.\n */\n\nhr {\n  box-sizing: content-box;\n  height: 0;\n}\n\n/**\n * Contain overflow in all browsers.\n */\n\npre {\n  overflow: auto;\n}\n\n/**\n * Address odd `em`-unit font size rendering in all browsers.\n */\n\ncode,\nkbd,\npre,\nsamp {\n  font-family: monospace, monospace;\n  font-size: 1em;\n}\n\n/* Forms\n   ========================================================================== */\n\n/**\n * Known limitation: by default, Chrome and Safari on OS X allow very limited\n * styling of `select`, unless a `border` property is set.\n */\n\n/**\n * 1. Correct color not being inherited.\n *    Known issue: affects color of disabled elements.\n * 2. Correct font properties not being inherited.\n * 3. Address margins set differently in Firefox 4+, Safari, and Chrome.\n */\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n  color: inherit; /* 1 */\n  font: inherit; /* 2 */\n  margin: 0; /* 3 */\n}\n\n/**\n * Address `overflow` set to `hidden` in IE 8/9/10/11.\n */\n\nbutton {\n  overflow: visible;\n}\n\n/**\n * Address inconsistent `text-transform` inheritance for `button` and `select`.\n * All other form control elements do not inherit `text-transform` values.\n * Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.\n * Correct `select` style inheritance in Firefox.\n */\n\nbutton,\nselect {\n  text-transform: none;\n}\n\n/**\n * 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`\n *    and `video` controls.\n * 2. Correct inability to style clickable `input` types in iOS.\n * 3. Improve usability and consistency of cursor style between image-type\n *    `input` and others.\n */\n\nbutton,\nhtml input[type=\"button\"], /* 1 */\ninput[type=\"reset\"],\ninput[type=\"submit\"] {\n  -webkit-appearance: button; /* 2 */\n  cursor: pointer; /* 3 */\n}\n\n/**\n * Re-set default cursor for disabled elements.\n */\n\nbutton[disabled],\nhtml input[disabled] {\n  cursor: default;\n}\n\n/**\n * Remove inner padding and border in Firefox 4+.\n */\n\nbutton::-moz-focus-inner,\ninput::-moz-focus-inner {\n  border: 0;\n  padding: 0;\n}\n\n/**\n * Address Firefox 4+ setting `line-height` on `input` using `!important` in\n * the UA stylesheet.\n */\n\ninput {\n  line-height: normal;\n}\n\n/**\n * It's recommended that you don't attempt to style these elements.\n * Firefox's implementation doesn't respect box-sizing, padding, or width.\n *\n * 1. Address box sizing set to `content-box` in IE 8/9/10.\n * 2. Remove excess padding in IE 8/9/10.\n */\n\ninput[type=\"checkbox\"],\ninput[type=\"radio\"] {\n  box-sizing: border-box; /* 1 */\n  padding: 0; /* 2 */\n}\n\n/**\n * Fix the cursor style for Chrome's increment/decrement buttons. For certain\n * `font-size` values of the `input`, it causes the cursor style of the\n * decrement button to change from `default` to `text`.\n */\n\ninput[type=\"number\"]::-webkit-inner-spin-button,\ninput[type=\"number\"]::-webkit-outer-spin-button {\n  height: auto;\n}\n\n/**\n * 1. Address `appearance` set to `searchfield` in Safari and Chrome.\n * 2. Address `box-sizing` set to `border-box` in Safari and Chrome.\n */\n\ninput[type=\"search\"] {\n  -webkit-appearance: textfield; /* 1 */\n  box-sizing: content-box; /* 2 */\n}\n\n/**\n * Remove inner padding and search cancel button in Safari and Chrome on OS X.\n * Safari (but not Chrome) clips the cancel button when the search input has\n * padding (and `textfield` appearance).\n */\n\ninput[type=\"search\"]::-webkit-search-cancel-button,\ninput[type=\"search\"]::-webkit-search-decoration {\n  -webkit-appearance: none;\n}\n\n/**\n * Define consistent border, margin, and padding.\n */\n\nfieldset {\n  border: 1px solid #c0c0c0;\n  margin: 0 2px;\n  padding: 0.35em 0.625em 0.75em;\n}\n\n/**\n * 1. Correct `color` not being inherited in IE 8/9/10/11.\n * 2. Remove padding so people aren't caught out if they zero out fieldsets.\n */\n\nlegend {\n  border: 0; /* 1 */\n  padding: 0; /* 2 */\n}\n\n/**\n * Remove default vertical scrollbar in IE 8/9/10/11.\n */\n\ntextarea {\n  overflow: auto;\n}\n\n/**\n * Don't inherit the `font-weight` (applied by a rule above).\n * NOTE: the default cannot safely be changed in Chrome and Safari on OS X.\n */\n\noptgroup {\n  font-weight: bold;\n}\n\n/* Tables\n   ========================================================================== */\n\n/**\n * Remove most spacing between table cells.\n */\n\ntable {\n  border-collapse: collapse;\n  border-spacing: 0;\n}\n\ntd,\nth {\n  padding: 0;\n}\n</style>\n<style id=\"style-init-screen\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/init-screen.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n@-webkit-keyframes init-loading-spin {\n\t0%   { -webkit-transform: rotate(0deg); transform: rotate(0deg); }\n\t100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); }\n}\n\n@-o-keyframes init-loading-spin {\n\t0%   { -o-transform: rotate(0deg); transform: rotate(0deg); }\n\t100% { -o-transform: rotate(360deg); transform: rotate(360deg); }\n}\n\n@keyframes init-loading-spin {\n\t0%   { -webkit-transform: rotate(0deg); -o-transform: rotate(0deg); transform: rotate(0deg); }\n\t100% { -webkit-transform: rotate(360deg); -o-transform: rotate(360deg); transform: rotate(360deg); }\n}\n#init-screen {\n\tdisplay: none;\n\tz-index: 100000;\n\tposition: fixed;\n\ttop: 0px;\n\tleft: 0px;\n\theight: 100%;\n\twidth: 100%;\n\tfont: 28px/1 Helmet, Freesans, sans-serif;\n\tfont-weight: bold;\n\tcolor: #eee;\n\tbackground-color: #111;\n\ttext-align: center;\n}\n#init-screen > div {\n\tdisplay: none;\n\tposition: relative;\n\tmargin: 0 auto;\n\tmax-width: 1136px;\n\ttop: 25%;\n}\nhtml[data-init=\"no-js\"] #init-screen, html[data-init=\"lacking\"] #init-screen, html[data-init=\"loading\"] #init-screen {\n\tdisplay: block;\n}\nhtml[data-init=\"no-js\"] #init-no-js, html[data-init=\"lacking\"] #init-lacking {\n\tdisplay: block;\n\tpadding: 0 1em;\n}\nhtml[data-init=\"no-js\"] #init-no-js {\n\tcolor: red;\n}\nhtml[data-init=\"loading\"] #init-loading {\n\tdisplay: block;\n\tborder: 24px solid transparent;\n\tborder-radius: 50%;\n\tborder-top-color: #7f7f7f;\n\tborder-bottom-color: #7f7f7f;\n\twidth: 100px;\n\theight: 100px;\n\t-webkit-animation: init-loading-spin 2s linear infinite;\n\t     -o-animation: init-loading-spin 2s linear infinite;\n\t        animation: init-loading-spin 2s linear infinite;\n}\nhtml[data-init=\"loading\"] #init-loading > div {\n\ttext-indent: 9999em;\n\toverflow: hidden;\n\twhite-space: nowrap;\n}\nhtml[data-init=\"loading\"] #ui-bar, html[data-init=\"loading\"] #passages {\n\tdisplay: none;\n}\n</style>\n<style id=\"style-font\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/font.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n@font-face {\n\tfont-family: \"tme-fa-icons\";\n\tsrc: url('data:application/octet-stream;base64,d09GRgABAAAAACWoAA4AAAAAQhQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABPUy8yAAABRAAAAEQAAABWPihI/2NtYXAAAAGIAAAAOgAAAUrQXRm3Y3Z0IAAAAcQAAAAKAAAACgAAAABmcGdtAAAB0AAABZQAAAtwiJCQWWdhc3AAAAdkAAAACAAAAAgAAAAQZ2x5ZgAAB2wAABjCAAAq+uJ4WNtoZWFkAAAgMAAAADQAAAA2BZlJs2hoZWEAACBkAAAAIAAAACQIJwQZaG10eAAAIIQAAABuAAABOPTeAABsb2NhAAAg9AAAAJ4AAACeojKW6m1heHAAACGUAAAAIAAAACAA6gvwbmFtZQAAIbQAAAGPAAAC/eLsyKlwb3N0AAAjRAAAAfwAAAM0412SIHByZXAAACVAAAAAZQAAAHvdawOFeJxjYGRWYZzAwMrAwVTFtIeBgaEHQjM+YDBkZGJgYGJgZWbACgLSXFMYHF4wvPBhDvqfxRDFHMQwDSjMCJIDANLeC6V4nGNgYGBmgGAZBkYGEHAB8hjBfBYGDSDNBqQZGZgYGF74/P8PUvCCAURLMELVAwEjG8OIBwC4Ywb6AAAAAAAAAAAAAAAAAAB4nK1WaXMTRxCd1WHLNj6CDxI2gVnGcox2VpjLCBDG7EoW4BzylexCjl1Ldu6LT/wG/ZpekVSRb/y0vB4d2GAnVVQoSv2m9+1M9+ueXpPQksReWI+k3HwpprY2aWTnSUg3bFqO4kPZ2QspU0z+LoiCaLXUvu04JCISgap1hSWC2PfI0iTjQ48yWrYlvWpSbulJd9kaD+qt+vbT0FGO3QklNZuhQ+uRLanCqBJFMu2RkjYtw9VfSVrh5yvMfNUMJYLoJJLGm2EMj+Rn44xWGa3GdhxFkU2WG0WKRDM8iCKPslpin1wxQUD5oBlSXvk0onyEH5EVe5TTCnHJdprf9yU/6R3OvyTieouyJQf+QHZkB3unK/ki0toK46adbEehivB0fSfEI5uT6p/sUV7TaOB2RaYnzQiWyleQWPkJZfYPyWrhfMqXPBrVkoOcCFovc2Jf8g60HkdMiWsmyILujk6IoO6XnKHYY/q4+OO9XSwXIQTIOJb1jkq4EEYpYbOaJG0EOYiSskWV1HpHTJzyOi3iLWG/Tu3oS2e0Sag7MZ6th46tnKjkeDSp00ymTu2k5tGUBlFKOhM85tcBlB/RJK+2sZrEyqNpbDNjJJFQoIVzaSqIZSeWNAXRPJrRm7thmmvXokWaPFDPPXpPb26Fmzs9p+3AP2v8Z3UqpoO9MJ2eDshKfJp2uUnRun56hn8m8UPWAiqRLTbDlMVDtn4H5eVjS47CawNs957zK+h99kTIpIH4G/AeL9UpBUyFmFVQC9201rUsy9RqVotUZOq7IU0rX9ZpAk05Dn1jX8Y4/q+ZGUtMCd/vxOnZEZeeufYlyDSH3GZdj+Z1arFdgM5sz+k0y/Z9nebYfqDTPNvzOh1ha+t0lO2HOi2w/UinY2wvaEGT7jsEchGBXMAGEoGwdRAI20sIhK1CIGwXEQjbIgJhu4RA2H6MQNguIxC2l7Wsmn4qaRw7E8sARYgDoznuyGVuKldTyaUSrotGpzbkKXKrpKJ4Vv0rA/3ikTesgbVAukTW/IpJrnxUleOPrmh508S5Ao5Vf3tzXJ8TD2W/WPhT8L/amqqkV6x5ZHIVeSPQk+NE1yYVj67p8rmqR9f/i4oOa4F+A6UQC0VZlg2+mZDwUafTUA1c5RAzGzMP1/W6Zc3P4fybGCEL6H78NxQaC9yDTllJWe1gr9XXj2W5twflsCdYkmK+zOtb4YuMzEr7RWYpez7yecAVMCqVYasNXK3gzXsS85DpTfJMELcVZYOkjceZILGBYx4wb76TICRMXbWB2imcsIG8YMwp2O+EQ1RvlOVwe6F9Ho2Uf2tX7MgZFU0Q+G32Rtjrs1DyW6yBhCe/1NdAVSFNxbipgEsj5YZq8GFcrdtGMk6gr6jYDcuyig8fR9x3So5lIPlIEatHRz+tvUKd1Ln9yihu3zv9CIJBaWL+9r6Z4qCUd7WSZVZtA1O3GpVT15rDxasO3c2j7nvH2Sdy1jTddE/c9L6mVbeDg7lZEO3bHJSlTC6o68MOG6jLzaXQ6mVckt52DzAsMKDfoRUb/1f3cfg8V6oKo+NIvZ2oH6PPYgzyDzh/R/UF6OcxTLmGlOd7lxOfbtzD2TJdxV2sn+LfwKy15mbpGnBD0w2Yh6xaHbrKDXynBjo90tyO9BDwse4K8QBgE8Bi8InuWsbzKYDxfMYcH+Bz5jBoMofBFnMYbDNnDWCHOQx2mcNgjzkMvmDOOsCXzGEQModBxBwGT5gTADxlDoOvmMPga+Yw+IY59wG+ZQ6DmDkMEuYw2Nd0ayhzixd0F6htUBXowPQTFvewONRUGbK/44Vhf28Qs38wiKk/aro9pP7EC0P92SCm/mIQU3/VdGdI/Y0Xhvq7QUz9wyCmPtMvxnKZwV9GvkuFA8ouNp/z98T7B8IaQLYAAQAB//8AD3icrToNcBzVefe9/b3dvd29u909/dyd7ke6k86yLEunOyHJsrCxJWyJGmEcLMDYxBhHNsZQBzOAkjQmFDrGIq5gHEIcCILOAGZq3IQO04RkIGkgaUMKMbQznSlJW0wgJtOQHxRr1e+93TvJwq7JTD3y2/f//bzvfX/vAhAIzL3KPcYNBFIB8UR9EJYuAcuAqGNbOiwDSczkuorlaJ6WTeVSRwMIDveY8aN20GztjzMhW4P2H+kNUPM5NaVNQE0K3tWM77vv8rJqgnT33VJE4WWIfd/QbKHZjcXcZiFAqjCDgUJA/mZTWOIIwi0vAwNiUjkW9THIZs6DAbnj6ffGP/P+0y2vv+5SXGLKuXHJPJH92c+yT7x3883wnI9W/DxI4T9+bm7uOL+MUwNywAg0BJYFQgNKa2NDzFBEjqeM0SFXLHU4YKe7yjFoSmdEKWw5nemOUj5czMXCliilM7lyuFgqp3HaDf1j/fhH+s6cfm4MEpA8c0BSQBO5CUkD5fJi05kDjSUoNnETTUUSXtpPVm0aGHDdmV0nNkPiMUWeHZMVRSZPSlp0dqypCKVG8iT9IK5AEeamyZGAjecW5tm5SSBm8ojiSqBsYoXDTRtuymw13V8axjB+p2EPlsMGcRzTTRkGOLRpmk/AzSZ+A97ecx+QN8g9gUbc26F7N+GJiN5pLGMA8hUo7EQcHI455A0PwrS3I37N+bZhTE8bex1aeeIJ4+MTjTY6gcH+iIvgGWQRdh2TR9sS81kspCzytguLfBcyuBOLXuhwYnZnh8NFUs6plLPLScGpWBKwkYztwsop7Hie9r7rYK/9brWXTg9U+RiBX+GJiyc0rgIv7UNJe3vPjrFdyZOV/byNUkyW/0AuIi/h+h6U5a64SmW5ieGcya2AYimG+EUtnZN08ImgveV+KOYykiiJVMrbkI+dHUkC9+nyPUFdD94j639r1uTq7FiSNrR1hXS8uLbGapYUSbpaJvzmp5aODbU9iJNBU1gJa5LFTCqihNpDigmWWtc2GjUy7Y2m3hHk14qmPJXp2cTInZudO85dhzw2AuXAJQHl+Yt7l0RVjkO8u4q5JZARE2A5yNxStNgGWcQSj7izA1HucCgJOsRsb7xYWgn9XAwvRqaN4HAS4ENF3kXFFovJ/muW3zsYDK3jxaCQbOouOPXZPmBDNZG4krS0N2/9wakf7hHv+IcPX/jcaGWZAp9fvrFtv66UeSlXn4zYdZo5kLNwIJJRTbEu3jz62Zf37Xv5l7RAeugZfAQ7kJ5koA3PoJB1eP8MpHRVWqpygyITpiKz4DCoHMENlun+wrDA0bNZ9jmJZdZwhhx9UnewMKztg2yAlie9j6O7Lzrks7tYdRdOO4u/FJ9e5G93RyFTJ1f5G17IZDs7z25uEfuFBYwlvYpUUuTnKJO6umg5IymD88yGGxbycjN2JOkIVk6wUoEzm/0O5T/Owb92Jg8NyL/6qFrl30IZ5nSgMp3nch7DkvOMCaMeoQ1U4JZxQncenmAMmcAei/S7V9CvAccW8mczwtMCceSQ8nwhXWuKAeQPJbRCc9RnhoSyhvBL+WgxTzsk0Y567IFj+35wa4Xq7ykS5YIm7UIdq4iCfKcsiIoSvFFWONUnFovZoXHKhXE69R9hTOIEgZPcJ0VZRrx+i3j9hhtFPqQDnYjX8uaEpS2+F4twiVkOylSJAwfvBZO3XBnoTaEHtltSWAGKIEl3SJIQ1CRESIRnLFtJRc88GckEbQuOBTO5zBXziL0JIPKiyMtzggwiMc+czmbDEbDMbJaLhC3LPzPuFOKaD6zEM+tt15gNxTPLIg5dvglCfGmbmakYmqmKsEfRVOWWAXjqvEzVeamT6botq9321Vu2rIb7KOrufmZ24LWmoiI3yspJJ65e704JprBSFGH3pxXLhAQe9fBzbM1rq7YAm1dsctvZSiqu8G94rxwS/LQ7JYorRR0XXq/GmSh4dJADKAsSk70ajQ8gHdE0MhzVjOCbVDSvKINd1PhKVN+fgMTG2zYCvIaq+V2mmsNTP36IRLD6xO7ejWTDisfc7zCVD6tQW+/eMTW1Y3fSt20foe+hBZpQ3zfGfH3vyzmCZNvHFoJFVPrRjj7m6I26M3r7KHQxgD5c2H/4tQdIeJLJ+yQDvTsZOwv4jYfJQxVaxxmtKtNTTVaQnRmS6kkWvfBoNvCeIT55jt41PJZwpg3YYeJYGK+dppgK/sF+R/8ggZIOBlnyNoK/qpwokLZ6uCFRKCTKV8HeGaYksPg2Xj/3fyQZb6dhGWv2QLLQU4DW7lZwf77Hw+vb3AjzexKIVywkEXoGlB1JUqr4FW3A7BZlDzgzhZ5W0tyfI1da7mmn13JvsZOFxLuJIRsmLXJVskByA41iu/uvSds9bWOnPZQ4lSgANm+xqQ6gMPlGH2YR79rSDIXLXQBujHZSxkCpSIeynwCdNxEFJ2HVmSDaFPxQYoIN2BfCM8E6zTCu66VDSQ97KkPfIa8i7nGUITNAZagDhYFJjeg5rXh+bcBuYamT/JWmRVE8Iopeb/3ud1ZdSIs4TkQLcaogJ63Z5dGUxEfefz8qSKko+Qm2PB/ZgyEEMngmjkjovYB0GBog+n9COzD7MiQ73pfOA5S8NLseIst+QWbPC9y/J8dRv7QFliCNWcnzAYlI3fE8hdNVbBPY1WEeZxm8m5mKOdypQRG1qhiRgQBnZbr7N20qT1ipoPsLVYWEGq8hE3BoLPn2tV8PhWVe0WTB4nIN3WMD7cmIiDZEhaSSROulWMbk2+sX4LIs0Iq4NNdUfV3mDeqCbaEOligmbYSFCaU0VRVULrhTKoKlIMubNvV3ZyyOByWMilXkBpNjcIjihTjBrwzF/bmKF1iMJNsHxrobcnxElDVF0C3u69fevP5txIsEcUrVZyR96DPqiI/C+zGTp0uZGkXVP6PG1RncET7Ey/eKjnX885QeWw83krsCIVyvMp8TD9P3rEvMFUkFZxS6Rw25ytWQJ/52/tqLyQSDrc7Dpiq/H2XDgYsVBgjnK7BF95EwLKLNKLh0bg5x74VXPNwJO1fq7raB588j7pbhat78pDKjPE1td1Jl6Hhn8Q73LdISsCrrgwuijljQ28Tinnavx+Xu9ap6jYqn2QzNaly7RoVJ99MoBl/DvmtU1X0Lu3FCnO37XXKEW832Nai8BYnDKKvIF92W3F9dotK94ahCNyJPuW+5b2L1WrQ2X6fSc1TBejLg77uvsm8FX2b1ghWk6cbjuB1FUIVm9y0f6aMKfMbdhjshNGihFKgIgE7044ZvkbXz+zbh3chXN/f35Z6mOyF2b/m7H6V7HVV3XYOYtiDOig/J25bh+xPuAPMdxRPRc8V1YU8Z2mEv9OIO2O6DTg8Wtt2C3+lCcjBRmEaNVbDhi0nLnUK1ttvqdVpsexruQ93WGnf3T9s47N+te7nN5FeohRGeChUfIvZx5htAPYTNjQl/ea/tTlkW7LZ7nIK3dyNsGUwWpq0+a4k/ALvozB5nurkCqwthUdrq5mnzBD/tu5rpfPVYuC6L0VZwnMfd/YnGxgTc97jjFNjGFvRQ6iyrYPfZjyPVyQJM233YRF5YVb1xgLzjwVMX3NOwZ/K7wtJZx4W8pGRNNzf4ZOBeCKgPCxuKcUYmxQNycbjP5wGlEJGk8OZc369tR3gtaZ+X6CbmVkIONRVJcugpluk1TQL1Fqmfy1ELVi4hYy1zJhYNj4zu7RkfbuebN17fv+q2Fj4sDgtE7Hv2uk89uneIH7j9yNWjR1YMmUvJSzO6s9QcGWkbHt83PtzW0yWCMMLr4roNcMm+o88e3XdJ/0VDkWiFDxSv5YhXq8d3nVAryjjtoDXp7Ojn2gg6ijGHIUxDpQZ0Y2lQym2+5NZHN219to8XhsUw33Lb6p6dG9DVGN598/bmkXA0NoPeR2t4qO/h0U8d3bcKtmB5yeilos6PCCB29fgINjeNmEsdfaYmGhm6qB9RrPhEx7mrEbfGwCDauZXNJo09wLJ1oAhSe1NxWkUDKKJofMqeE+szt8S4K9JYmjbLXRRtylOU1vWN//mVy4/0DVGNqM9QJT7SvL287ot5MSZoGC/oyHTWO7p3vdd5s6RB439/5fKH6aIaEDh46AVkpMqWo1YdaWpe1690hzT4e79jxGuLvD+R0iUwuiJ+TLUM4+yrA8aAdsVAsX1JFgMsTkCF4ceBdtgLZ8oXaENnPpfPipLA6A57nn4+XI1hUbCoYmig1KP5pH44Kybnq4cUyatKivvTmXpeOC7y8J4il3yHncWVz+SDrc5zTqucPyYro3Af7XP30/I8ddJxsQAgXIFbz37QdsmqNhJl0K6145C0rkWzExAX8aM3sDpwYyA8oF83PNBXWu7xRPQMIT1E6syw7M4F2tFwOmyhVKQ7+uH/lz9DribLBF4jsuze94lYBc+7LzLOXMw4c+66u52EZz/QLEWxyA0XZFuA9+OVUfSTwyzWCw0o3a0Jx9BYTrKp2AZiEi9qGSs6OFhZkPboRDXesZKpbcd3UOjV8dMgNNQhr1pJh0Qy5petVIQ48Zq1KefMj7zIhluf3pQeBs5JfUuJMGcgHFRik16gP1mzHX2EmroaYhmVysETLOo54aSGU/gHzbEwdRvCMXuGhUczHj3HkZ42Rk9LYIDS07c8YRuqSBg91Pmnwo8VghFR2Y9oKTmxziSwi0HTN2I1cMvT3E7Fezk/Pae1UnYyUwqdRnqCNZPoXSJSk6hxGWmRBKqBSMqyTP97/wmaJcQCGpqbG5Iw6vhEtHpEVWihepULpFG3rqG0rOha2qTxJIC0YOSYFjrxEtP8nlSlIxvu7PLcRKmS76mk04Sq0HoTqJ04CcfcK+DDIU34mhCX/dByaAiDy58ibicVeRdNJrNyezI2G/ESlUKsZDxiOtLJk/ChXCc9Imp+1nO2xL6QZIkkWiizM7SHIF9q9K8ZpQDx8zOjgWaMzORvdrSGPJ2sEzRYZer9O2gmWD4zSTr6sSuH8Uc/IGjmyLIMOHUV0G48840967ixy2v6zIhcU+pr3bDj9u0bc1xfqUbO9sUuH3O/iqEbFPqaPbOBZuFTO57rx7mxvnDL7avRFLah/ei55LZCpKddjqz4OxhyH6YRLuzA0rcfY5yC8rQTcb08JdLYleZW8TZ0lGgSCyVfQoQtRDiPV6BqKLryzL7kqRmkuoGdE5UzlKWy39mJQlU1OChf1KrEHOYcsdMhvaO3j5JN+zZBXJZ2Kmq0WRSMDSFJGqmtC0q8eZesmfWxPxNNca3DC3KzYsg7MBBXhJ2yHmvy5sojNXVBmQvfhUdoxJ0NgiENWTzfqwd3SOjC927ceNvGjbfTUTNp13eIumhvAKEvJA/HTUW6Maj1CeJAUtBFrcOI1xugSWxubV1qqaRJ1gZvqiHLbKqwOo5TR9hELw7/iBsjL/t6WXl+SWN9VOO5RfnTtJcwreTFY35bWthGB+bMB+yOcGEDg4bztxbkUR0wh1h2kJWgV0awMR+Hjvn5mlrmu9BMCMpYsZynmQC8KR2xco4maZIg5jN5CU86ViJ/s27nzqlxgFc6167fuXP92s5XYOdDO8j4pYNYw16IjR8eH79U0ra3Y6V9uyat20l2P7AbsKpjJ81Tzs39nt9PXgqYeL9LNB+Yi9uMN1BEZ0knnvijDiZLEDg6dJ30NuA9oQEVh9U0uk/kgO8A+R94pvWy8YveWn0ZWbfmLepJXdqz5Z5B94qhu7d2k75r7l0Lx2gVtvTMr6FXgDY7p56d6qSNS+/e0ke6r//CQ1/YXiTdW++u+FK/529HfC3klvzNhK3Te4txIUFlkuQ8tIjguXrUG6WAPWgMsIcDF664d3v3DHXwhQ07YMul2I9QDvtQXz+bokoej3uUo5mt1Qi7f/m58pGoIAyavsnnFiUl8cbhKTpRmI+CKw9Y1oKc5GvZZJCT6kWJcCHNzzDS3KTQKEocr/6Fe1GoUf+1rq/QG/W/hs9goz8E649Xc5M6HxXjAnDV9OT9spBFuwOC26Prv2bzQ3RhCHfwaYpW8+LxqOzlYOZR7/Kf/RbmXMktCzAr3jWP/Kqt5KUqZDq4uTqyBbYGfL17HcuL19KcjykyePSoAP2bNgILH1qOXXFwA9l471P3bOIvOwRXL8j+k0OjB6cPjrLCfe2sXP/824QcsAMZlOmGWiMo0rwb4K1qo+mH/LkBVlXdA+cFXFFWvz0//AXvbZ6+ac3GoyzHHvXfzCqvNILfLi9qV7KBJ/03OPbql/A+XlcDa3g9C1/rnPPU/XzkR4E3q/4p6kHES6V3vVx1M7x3EG4RnpwfhuT9B8mTF4BG6w/vZp7SbtoL4oJBkCuYe2+LL3GT6CtdzGKjNas6FGaHETyqOIeljCSdy4azYTwkLxFIL08OHSKaM+7sonl9vERpGguhHaS5bUgz24xu3ETTPsVKqntkIZfpqR1MdBfQKd6hmiFHviU1QZ260MQ2FSOcbfDmVoyFeHkb9rq/db9KFWsP6uutqz6LgZW6R+JrIjp86Gp6jSXL+7RoUv38yjEracH0NiVpKdu2ISBl27QDRdTKAT9WHoc/IL/p7w4sptcdmtpFR6IcZRnNXDnaT909x7Ykjj6PwmlFdP9FMuWgQvb8nAiKpHB7iS4/r+pk678LRCWOGpq9QwfOlOGlbpDkEPwThngKL7puibAY5LvMl+ZQQ8Yx4mxF/wZjkGJ7a3NjKl5jyjiJ/hAhLzVVExN+9qMpZsAyWImhu/eF2NlfcmS6bxq6lNlO9CZvxpjon/G7R5k1SqVwuFwOv3HTTZn0TTelSQs2wtjpPkNH8D/RH++b3mkosx0KLkzSlfi92qSrzPKX2arMTe692ChjJ7T5I75t3I487EIe5jXKQ6pg6Q83qs/lEn3noSFynmb4aOrBF9sEoBuHhKFYcL11up41emofLCQGE60wVdeDClSvn5qqM41Go7t+iuWUHqzrNrOGWTsFst5TtwLXXPk0Syc9fSX2rsBFmzadY6C/Fge8d+e5uXHkfyiQRc6vwTu2Ylkhz95Fq2/8+YVv/CxSqb7xxyqhDjDBRxFBxcQnSYzeBfrYNqGJjej4TLDfWEywII42hqZ+/BB/6I2DkCn0WS9uv3PD4Z0DpG/3oemDe7u5NS/aMOWtol60t2qCusYTSi19uHn1iHiQOpz2i2v6xx/4xqE9PfyqHQ+N3Ln9RftsmoxADcYAyvMt9Y73lr7wdwTUmb8g/u53GOaw6pPizJC9MJrEj7noG9sG1CNhmWN2BcF2dpRzGBfz5XrojEWZRxuj6aCYY0tiLJOTMmK2uJJQjxj/8hjKEB1iGHCj4JTpxczQzEtehAevG+5pUO12twtCjfG4I979yJB4a7RlZbDdVGV1OMgDQPZQY+ERm1wqiVyYJwJHMrGaP+o9YKbUlE2ApL6YEiyylNT9ESff74qtvCgqNSZcBVOa+2Hr9q9E70rVikGTcxRJ4BSQa6ImzpQIEXk+OFbqhvQRQ4souDWotqAiL2Xqm+AZ/Yz0kXcCOnvfqg1779vzOXtqtvPMii9Ig5+dwj87Kf4bQ6EJfdRt4PyQZYFY0/NXERbE5vPzi+As2njhToFqfp7h6ufXYTFiZ6MCryyG/xQX5qIBFddLfr6b+SYsHc3P1ocikRD5rxCMuNslxeBKuiZjzQpUY6kFvwNgPtyioHRxkEr9fv+HE5AwHFc9q0neOXOa/kiAi9ByQX3et1fZb2+q7yCL914QN5y1GVt/DOVaR29JPCECXV9iGaI84A7sQ9W3Y4dLZe4vVR1Mxd3Hc7rq7lNVOKjqHM9xqmiceVWXNTgoiO6fswpN0R/EfnefyHtnMvcsdw1nzMOJiSzGpQ+SPmclxmVRqlVM0HG5wNFSQYAIRhjE3ZDTsobwJbifVegTxj7sx7mCRwvp5XSWh6/QYs/TwjyMahKsVCYZVaeECMTR56MplPyzCfrSPO/dL0m8RwvpQ1oS56aF7i/58Mpn0eOHaKxcTNGd84cLd4oCvXPu3B+4a8kPUA7rmSzJ7E3Zy7OzuJEm/Mt+7Eh/pyDPMx7xF7luuh/CY9hDe4WZYLqvW+YhFlJiWX1PO0aOB6L0t3AVOUK7V/XSqP8Dx/CavHCY8erwC3jhyKHZR2nu9wXvpz4vKN4dwOIA22sZ/S1RTbhyBxbvF/XeXzEQpfEUTa0hLTTE+RigN9vzQhBp0RzT5OUaKazwlhEU8u0fx8D9XmGdwVmmZmpavDGuichhJJUz1nn5pp9yj5H3GG7DgZtovmnn5YNFiiT/JyIZqw6Uvd+i0TRIFwumFw7SVEg/TYvQDM/8hE9O4uTWEVlECuyU2tLW1oKK3jIk+bItDxy6TZKw36mttdZgKDxo1fIRzrFMSbrt0J/Cl8KVh1OcozuqGUyO7RxLBk3UrA6XfmDTF97qwAErpOl655GnjnTqOidyIQsHO08G/hcLt/j/AAB4nGNgZGBgAOLaW41M8fw2Xxm4mV8ARRguss1QhNC5H/9//Z/FUsEcBORyMDCBRAFTFwxveJxjYGRgYA76n8UQxVLGwPD/FUsFA1AEBfgBAHyYBUh4nGN+wcDAvACCWfSBNIgviMBM1kA6koGBMRWVBqsDYqYmiF4wHQkxg+kUBMPVWEP0gTDYvBdoahZAzYxEY0ciuWUBFjkoZimDYLC8IKpehmsQccYvSGYgYZB7YBhFL5o8cxTQjDUI/wIArpclrwAAAAAAAAA6AIYA3AEKAUgBgAGgAfoCYgKqAwIDOgOGA9wEQAR4BLYFAgU8BZoFzAYMBlIGmga6BtgG+AcYB0QHcAecB8gIAAg2CG4IpgjyCUAJrAo0CtALOAueDAoMYA0ADVANjg3mDiQOjg7GDvgPOA+ED84QPBB2EN4RNhGgEfISchKoEsgS6BMGEz4TXhOSE8QT+BQsFGIUiBTWFX0AAAABAAAATgBuAAYAAAAAAAIAAAAQAHMAAAAiC3AAAAAAeJx1kctOGzEUhn9DoIKgLloJdcdZIRDK5CKhSqyoogJrhLJDwgyeSzpjRx4HlGfgLcoz8Dp9j+76Z2KhqFJmZM93Ph/bxx4AX/AHCqvnnG3FCgeMVryFT/gReZv+JnKHfBd5B108RN6l/xV5H2d4idzFV/zmCqqzx2iK98gK39RR5C18Vt8jb9P/jNwh30fewaGaR96lf428j4l6i9zFsfo7drOFL/MiyMn4VEaD4bk8LsRRlVZXouehcL6RS8mcDaaqXJK6OtSml+lemTrb3Jp8Xmm/rtZ5YnxTOivDZLCur401XgfztNytec5HIWSSeVfLVdxHZt5NTRqSIoTZRb+/vj/GcJhhAY8SOQoECE5oT/kdYYAhf4zgkRnCzFVWCQuNikZjzhlFO9IwvmTLGFlaw4yKnCBlX9PUdD2Oa/Zlay1n3dLmXKei9xuzNvkJ7XLvso2F9SaselP2Na1tZ+i2wqePszV4ZhUj2sBZy1P4tmrB1X/nEd7XcmxKk9In7a0F2gv0+W44/z/KQo7lAHicbZLnlpswEIW5Bgy4bLLpvfeE9N57z76DLARWEJKOEEucpw8CO/kTncOdT6PhnlHxRt4wJt7/x47nYQQfAUKMESFGggmmmGGOLezBXmxjH/bjAA7iEA7jCI7iGI7jBE7iFE7jDM7iHM7jAi7iEi7jCq7iGq7jBlLcxC3cxh3cxT3cxwM8xCM8xhM8xTM8xwu8xCu8xhu8xTu8xwd8xCd8xhd8xTd8xw/sBLUlZuIkZZW2q0hzahvDRqocUyIpE4EWTR1WXDZ1sGRCz5yklBsqWBZwmauZk01mTqxl0nIlUyLs9r/Zej35m4kFl2XKftlAKFomTlKlmfQ1l74lRdB9dbxQqqyIKbc2MPQZGqbFKsqVaYnJ4ky1Ms24iQXLrYPE8GLZ07jRfaIvcf5JX+NoMhQ5jLoqFwenBS8Gpw7WTh05py6MaOtT2ibEGNXWKW1Da0i9nPY6dNe7CEWy7pc+5EJpvfJVnvtUFUHFZBPWS2LYxKqiECztVpINypAuGS2nvQ6Gs+H0hsk0U3ZznDETguua1/MNpLvMWH/RFGEuuobCihScxqS2zPC6jH4rVaVcxn1UjQ1yJW1QK2MTJ6nrPOqp0d3Vk1WoSVOz7p0oHeWdTbpoh5i3sVWpezp23AGTWch+Mmonu0o0Vb+l6RqdabLmRnveH9ru7j54nGPw3sFwIihiIyNjX+QGxp0cDBwMyQUbGVidNjIwaEFoDhR6JwMDAycyi5nBZaMKY0dgxAaHjoiNzCkuG9VAvF0cDQyMLA4dySERICWRQLCRgUdrB+P/1g0svRuZGFwAB9MiuAAAAA==') format('woff');\n}\n</style>\n<style id=\"style-core\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/core.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tDefault structural styles.\n*/\nhtml {\n\t/*\n\t\tWe define the base font size and line height here as they affect the layout\n\t\tof the base page elements (i.e. `#ui-bar`, `#ui-dialog`, and `#story`).\n\t*/\n\tfont: 16px/1 Helmet, Freesans, sans-serif;\n}\n\n/* Story data styling. */\n#store-area, tw-storydata {\n\tdisplay: none !important;\n\tz-index: 0;\n}\n\n/* Special no transition styling. */\n.no-transition {\n\t-o-transition: none !important;\n\ttransition: none !important;\n}\n\n\n/*\n\tDefault appearance styles.\n*/\n*:focus {\n\toutline: thin dotted;\n}\n*:disabled {\n\tcursor: not-allowed !important;\n}\nbody {\n\tcolor: #eee;\n\tbackground-color: #111;\n}\na {\n\tcursor: pointer;\n\tcolor: #68d;\n\ttext-decoration: none;\n\t-o-transition-duration: 200ms;\n\t   transition-duration: 200ms;\n}\na:hover {\n\tcolor: #8af;\n\ttext-decoration: underline;\n}\na.link-broken {\n\tcolor: #c22;\n}\na.link-broken:hover {\n\tcolor: #e44;\n}\na[disabled], span.link-disabled {\n\tcolor: #aaa;\n\tcursor: not-allowed !important;\n\t/*\n\t\tNOTE: Do not use `pointer-events` here as it disables\n\t\tthe display of a cursor in some browsers.\n\n\t\tpointer-events: none;\n\t*/\n\ttext-decoration: none;\n}\narea {\n\tcursor: pointer;\n}\nbutton {\n\tcursor: pointer;\n\tcolor: #eee;\n\tbackground-color: #35a;\n\tborder: 1px solid #57c;\n\tline-height: normal;\n\tpadding: 0.4em;\n\t-o-transition-duration: 200ms;\n\t   transition-duration: 200ms;\n\t-webkit-user-select: none;\n\t   -moz-user-select: none;\n\t    -ms-user-select: none;\n\t        user-select: none;\n}\nbutton:hover {\n\tbackground-color: #57c;\n\tborder-color: #79e;\n}\nbutton:disabled {\n\tbackground-color: #444;\n\tborder: 1px solid #666;\n}\ninput, select, textarea {\n\tcolor: #eee;\n\tbackground-color: transparent;\n\tborder: 1px solid #444;\n\tpadding: 0.4em;\n}\nselect {\n\tpadding: 0.34em 0.4em;\n}\ninput[type=\"text\"] {\n\tmin-width: 18em;\n}\ntextarea {\n\tmin-width: 30em;\n\tresize: vertical;\n}\ninput[type=\"checkbox\"], input[type=\"file\"], input[type=\"radio\"], select {\n\tcursor: pointer;\n}\n/* BEGIN: input[type=\"range\"] */\ninput[type=\"range\"] {\n\t-webkit-appearance: none;\n\tmin-height: 1.2em;\n}\ninput[type=\"range\"]:focus {\n\toutline: none;\n}\ninput[type=\"range\"]::-webkit-slider-runnable-track {\n\tbackground: #222;\n\tborder: 1px solid #444;\n\tborder-radius: 0;\n\tcursor: pointer;\n\theight: 10px;\n\twidth: 100%;\n}\ninput[type=\"range\"]::-webkit-slider-thumb {\n\t-webkit-appearance: none;\n\tbackground: #35a;\n\tborder: 1px solid #57c;\n\tborder-radius: 0;\n\tcursor: pointer;\n\theight: 18px;\n\t/*\n\t\tNOTE: Ideally, `margin-top` should be `0` for Edge/Spartan (ca. v17), but\n\t\treal WebKit/Blink-based browsers need it.  Since there's more of them and\n\t\tEdge is co-opting the prefix anyway, we cater to them.  Edge will simply\n\t\thave to look ever so slightly off.\n\t*/\n\tmargin-top: -5px;\n\twidth: 33px;\n}\ninput[type=\"range\"]:focus::-webkit-slider-runnable-track {\n\tbackground: #222;\n}\ninput[type=\"range\"]::-moz-range-track {\n\tbackground: #222;\n\tborder: 1px solid #444;\n\tborder-radius: 0;\n\tcursor: pointer;\n\theight: 10px;\n\twidth: 100%;\n}\ninput[type=\"range\"]::-moz-range-thumb {\n\tbackground: #35a;\n\tborder: 1px solid #57c;\n\tborder-radius: 0;\n\tcursor: pointer;\n\theight: 18px;\n\twidth: 33px;\n}\ninput[type=\"range\"]::-ms-track {\n\tbackground: transparent;\n\tborder-color: transparent;\n\tcolor: transparent;\n\tcursor: pointer;\n\theight: 10px;\n\twidth: calc(100% - 1px);\n}\ninput[type=\"range\"]::-ms-fill-lower {\n\tbackground: #222;\n\tborder: 1px solid #444;\n\tborder-radius: 0;\n}\ninput[type=\"range\"]::-ms-fill-upper {\n\tbackground: #222;\n\tborder: 1px solid #444;\n\tborder-radius: 0;\n}\ninput[type=\"range\"]::-ms-thumb {\n\tbackground: #35a;\n\tborder: 1px solid #57c;\n\tborder-radius: 0;\n\tcursor: pointer;\n\theight: 16px;\n\twidth: 33px;\n}\n/* END: input[type=\"range\"] */\ninput:not(:disabled):focus, select:not(:disabled):focus, textarea:not(:disabled):focus,\ninput:not(:disabled):hover, select:not(:disabled):hover, textarea:not(:disabled):hover {\n\tbackground-color: #333;\n\tborder-color: #eee;\n}\nhr {\n\tdisplay: block;\n\theight: 1px;\n\tborder: none;\n\tborder-top: 1px solid #eee;\n\tmargin: 1em 0;\n\tpadding: 0;\n}\naudio, canvas, progress, video {\n\tmax-width: 100%;\n\tvertical-align: middle;\n}\n\n.error-view {\n\tbackground-color: #511;\n\tborder-left: 0.5em solid #c22;\n\tdisplay: inline-block;\n\tmargin: 0.1em;\n\tmax-width: 100%;\n\tpadding: 0 0.25em;\n\tposition: relative;\n}\n.error-view > .error-toggle {\n\tbackground-color: transparent;\n\tborder: none;\n\tline-height: inherit;\n\tleft: 0;\n\tpadding: 0;\n\tposition: absolute;\n\ttop: 0;\n\twidth: 1.75em;\n}\n.error-view > .error {\n\tdisplay: inline-block;\n\tmargin-left: 0.25em;\n}\n.error-view > .error-toggle + .error {\n\tmargin-left: 1.5em;\n}\n.error-view > .error-source[hidden] {\n\tdisplay: none;\n}\n.error-view > .error-source:not([hidden]) {\n\tbackground-color: rgba(0, 0, 0, 0.2);\n\tdisplay: block;\n\tmargin: 0 0 0.25em;\n\toverflow-x: auto;\n\tpadding: 0.25em;\n}\n\n.highlight, .marked {\n\tcolor: yellow;\n\tfont-weight: bold;\n\tfont-style: italic;\n}\n.nobr {\n\twhite-space: nowrap;\n}\n\n[data-icon]:before,\n[data-icon-before]:before,\n[data-icon-after]:after,\n.error-view > .error-toggle:before,\n.error-view > .error:before,\na.link-external:after {\n\tfont-family: \"tme-fa-icons\";\n\tfont-style: normal;\n\tfont-weight: normal;\n\tfont-variant: normal;\n\ttext-transform: none;\n\tline-height: 1;\n\tspeak: none;\n}\n[data-icon]:before {\n\tcontent: attr(data-icon);\n}\n[data-icon-before]:before {\n\tcontent: attr(data-icon-before) \"\\00a0\";\n}\n[data-icon-after]:after {\n\tcontent: \"\\00a0\" attr(data-icon-after);\n}\n.error-view > .error-toggle:before {\n\tcontent: \"\\e81a\";\n}\n.error-view > .error-toggle.enabled:before {\n\tcontent: \"\\e818\";\n}\n.error-view > .error:before {\n\tcontent: \"\\e80d\\00a0\\00a0\";\n}\na.link-external:after {\n\tcontent: \"\\00a0\\e80e\";\n}\n</style>\n<style id=\"style-core-display\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/core-display.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tDefault structural styles.\n*/\n#story {\n\tz-index: 10;\n\tmargin: 2.5em;\n}\n@media screen and (max-width: 1136px) {\n\t#story {\n\t\tmargin-right: 1.5em;\n\t}\n}\n#passages {\n\tmax-width: 54em;\n\tmargin: 0 auto;\n}\n</style>\n<style id=\"style-core-passage\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/core-passage.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tDefault appearance styles.\n*/\n.passage {\n\tline-height: 1.75;\n\ttext-align: left;\n\t-o-transition: opacity 400ms ease-in;\n\ttransition: opacity 400ms ease-in;\n}\n.passage-in {\n\topacity: 0;\n}\n.passage ul, .passage ol {\n\tmargin-left: 0.5em;\n\tpadding-left: 1.5em;\n}\n.passage table {\n\tmargin: 1em 0;\n\tborder-collapse: collapse;\n\tfont-size: 100%;\n}\n.passage tr, .passage th, .passage td, .passage caption {\n\tpadding: 3px;\n}\n</style>\n<style id=\"style-core-macro\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/core-macro.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tDefault appearance styles.\n*/\n.macro-linkappend-insert,\n.macro-linkprepend-insert,\n.macro-linkreplace-insert,\n.macro-append-insert,\n.macro-prepend-insert,\n.macro-replace-insert,\n.macro-repeat-insert,\n.macro-timed-insert {\n\t-o-transition: opacity 400ms ease-in;\n\ttransition: opacity 400ms ease-in;\n}\n.macro-linkappend-in,\n.macro-linkprepend-in,\n.macro-linkreplace-in,\n.macro-append-in,\n.macro-prepend-in,\n.macro-replace-in,\n.macro-repeat-in,\n.macro-timed-in {\n\topacity: 0;\n}\n</style>\n<style id=\"style-ui-dialog\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/ui-dialog.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tPatches to the core styles.\n*/\nhtml[data-dialog] body {\n\toverflow: hidden;\n}\n\n\n/*\n\tDefault structural styles.\n*/\n#ui-overlay.open {\n\tvisibility: visible;\n\t-o-transition: opacity 200ms ease-in;\n\ttransition: opacity 200ms ease-in;\n}\n#ui-overlay:not(.open) {\n\t-o-transition: visibility 200ms step-end, opacity 200ms ease-in;\n\ttransition: visibility 200ms step-end, opacity 200ms ease-in;\n}\n#ui-overlay {\n\tvisibility: hidden;\n\topacity: 0;\n\tz-index: 100000;\n\tposition: fixed;\n\t/*\n\ttop: -50vh;\n\tleft: -50vw;\n\theight: 200vh;\n\twidth: 200vw;\n\t*/\n\ttop: -50%;\n\tleft: -50%;\n\theight: 200%;\n\twidth: 200%;\n}\n#ui-dialog.open {\n\tdisplay: block;\n\t-o-transition: opacity 200ms ease-in;\n\ttransition: opacity 200ms ease-in;\n}\n/*\n\tWe do not animate `#ui-dialog:not(.open)` for various reasons.  Chief among\n\tthem, however, is so that the dialog isn't in the middle of its animation\n\twhen other page updates happen.\n\n\te.g. The restoration of `overflow` on `body` would cause the still animating\n\t     dialog to jump around a little if a scrollbar were to pop in.\n\n\t     Any dialog action which performs a task which has its own animations\n\t     (e.g. passage display) or causes the page to reload in addition to\n\t     closing the dialog could cause display shenanigans.\n*/\n#ui-dialog {\n\tdisplay: none;\n\topacity: 0;\n\tz-index: 100100;\n\tposition: fixed;\n\ttop: 50px;\n\tmargin: 0;\n\tpadding: 0;\n}\n#ui-dialog > * {\n\tbox-sizing: border-box;\n}\n#ui-dialog-titlebar {\n\tposition: relative;\n}\n#ui-dialog-close {\n\tdisplay: block;\n\tposition: absolute;\n\tright: 0;\n\ttop: 0;\n\twhite-space: nowrap;\n}\n#ui-dialog-body {\n\toverflow: auto;\n\tmin-width: 280px;\n\theight: 92%; /* fallback for browsers without support for calc() */\n\theight: calc(100% - 2.1em); /* parent - title(2.1em) */\n}\n\n\n/*\n\tDefault appearance styles.\n*/\n#ui-overlay {\n\tbackground-color: #000;\n}\n#ui-overlay.open {\n\topacity: 0.8;\n}\n#ui-dialog {\n\tmax-width: 66em;\n}\n#ui-dialog.open {\n\topacity: 1;\n}\n#ui-dialog-titlebar {\n\tbackground-color: #444;\n\tmin-height: 24px;\n}\n#ui-dialog-title {\n\tmargin: 0;\n\tpadding: 0.2em 3.5em 0.2em 0.5em;\n\tfont-size: 1.5em;\n\ttext-align: center;\n\ttext-transform: uppercase;\n}\n#ui-dialog-close {\n\tcursor: pointer;\n\tfont-size: 120%;\n\tmargin: 0;\n\tpadding: 0;\n\twidth: 3.6em;\n\theight: 92%;\n\tbackground-color: transparent;\n\tborder: 1px solid transparent;\n\t-o-transition-duration: 200ms;\n\t   transition-duration: 200ms;\n}\n#ui-dialog-close:hover {\n\tbackground-color: #b44;\n\tborder-color: #d66;\n}\n#ui-dialog-body {\n\tbackground-color: #111;\n\tborder: 1px solid #444;\n\ttext-align: left;\n\tline-height: 1.5;\n\tpadding: 1em;\n}\n#ui-dialog-body > *:first-child {\n\tmargin-top: 0;\n}\n#ui-dialog-body hr {\n\tbackground-color: #444;\n}\n\n/* Default dialog button bar styling. */\n#ui-dialog-body ul.buttons {\n\tmargin: 0;\n\tpadding: 0;\n\tlist-style: none;\n}\n#ui-dialog-body ul.buttons li {\n\tdisplay: inline-block;\n\tmargin: 0;\n\tpadding: 0.4em 0.4em 0 0;\n}\n#ui-dialog-body ul.buttons > li + li > button {\n\tmargin-left: 1em;\n}\n\n/* Stop text selection on certain UI elements. */\n#ui-dialog-close {\n\t-webkit-user-select: none;\n\t   -moz-user-select: none;\n\t    -ms-user-select: none;\n\t        user-select: none;\n}\n\n\n/*\n\tDefault font icon styles.\n*/\n#ui-dialog-close {\n\tfont-family: \"tme-fa-icons\";\n\tfont-style: normal;\n\tfont-weight: normal;\n\tfont-variant: normal;\n\ttext-transform: none;\n\tline-height: 1;\n\tspeak: none;\n}\n</style>\n<style id=\"style-ui\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/ui.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tDefault structural styles.\n*/\n/* Settings dialog styling. */\n#ui-dialog-body.settings [id|=\"setting-body\"] > div:first-child {\n\tdisplay: table;\n\twidth: 100%;\n}\n#ui-dialog-body.settings [id|=\"setting-label\"] {\n\tdisplay: table-cell;\n\tpadding: 0.4em 2em 0.4em 0;\n}\n#ui-dialog-body.settings [id|=\"setting-label\"] + div {\n\tdisplay: table-cell;\n\tmin-width: 8em;\n\ttext-align: right;\n\tvertical-align: middle;\n\twhite-space: nowrap;\n}\n\n\n/*\n\tBuilt-in dialog appearance styles.\n*/\n/* List-based dialog styling (primarily for the Jumpto & Share dialogs). */\n#ui-dialog-body.list {\n\tpadding: 0;\n}\n#ui-dialog-body.list ul {\n\tmargin: 0;\n\tpadding: 0;\n\tlist-style: none;\n\tborder: 1px solid transparent;\n}\n#ui-dialog-body.list li {\n\tmargin: 0;\n}\n#ui-dialog-body.list li:not(:first-child) {\n\tborder-top: 1px solid #444;\n}\n#ui-dialog-body.list li a {\n\tdisplay: block;\n\tpadding: 0.25em 0.75em;\n\tborder: 1px solid transparent;\n\tcolor: #eee;\n\ttext-decoration: none;\n}\n#ui-dialog-body.list li a:hover {\n\tbackground-color: #333;\n\tborder-color: #eee;\n}\n\n/* Saves dialog styling. */\n#ui-dialog-body.saves {\n\tpadding: 0 0 1px; /* Webkit/Blink need 1px bottom padding or they'll trigger the scroll bar */\n}\n#ui-dialog-body.saves > *:not(:first-child) {\n\tborder-top: 1px solid #444;\n}\n#ui-dialog-body.saves table {\n\tborder-spacing: 0;\n\twidth: 100%;\n}\n#ui-dialog-body.saves tr:not(:first-child) {\n\tborder-top: 1px solid #444;\n}\n#ui-dialog-body.saves td {\n\tpadding: 0.33em 0.33em;\n}\n#ui-dialog-body.saves td:first-child {\n\tmin-width: 1.5em;\n\ttext-align: center;\n}\n#ui-dialog-body.saves td:nth-child(3) {\n\tline-height: 1.2;\n}\n#ui-dialog-body.saves td:last-child {\n\ttext-align: right;\n}\n#ui-dialog-body.saves .empty {\n\tcolor: #999;\n\tspeak: none;\n\ttext-align: center;\n\t-webkit-user-select: none;\n\t   -moz-user-select: none;\n\t    -ms-user-select: none;\n\t        user-select: none;\n}\n#ui-dialog-body.saves .datestamp {\n\tfont-size: 75%;\n\tmargin-left: 1em;\n}\n#ui-dialog-body.saves ul.buttons li {\n\tpadding: 0.4em;\n}\n#ui-dialog-body.saves ul.buttons > li + li > button {\n\tmargin-left: 0.2em;\n}\n#ui-dialog-body.saves ul.buttons li:last-child {\n\t/*\n\t\tUsing `position:absolute;right:0;` here can produce poor results,\n\t\tso we use `float:right` instead.\n\t*/\n\tfloat: right;\n}\n\n/* Settings dialog styling. */\n#ui-dialog-body.settings div[id|=\"header-body\"] {\n\tmargin: 1em 0;\n}\n#ui-dialog-body.settings div[id|=\"header-body\"]:first-child {\n\tmargin-top: 0;\n}\n#ui-dialog-body.settings div[id|=\"header-body\"]:not(:first-child) {\n\tborder-top: 1px solid #444;\n\tpadding-top: 1em;\n}\n#ui-dialog-body.settings div[id|=\"header-body\"] > * {\n\tmargin: 0;\n}\n#ui-dialog-body.settings h2[id|=\"header-heading\"] {\n\tfont-size: 1.375em;\n}\n#ui-dialog-body.settings p[id|=\"header-desc\"],\n#ui-dialog-body.settings p[id|=\"setting-desc\"] {\n\tfont-size: 87.5%;\n\tmargin: 0 0 0 0.5em;\n}\n#ui-dialog-body.settings div[id|=\"setting-body\"] + div[id|=\"setting-body\"] {\n\tmargin: 1em 0;\n}\n#ui-dialog-body.settings [id|=\"setting-control\"] {\n\twhite-space: nowrap;\n}\n#ui-dialog-body.settings button[id|=\"setting-control\"] {\n\tcolor: #eee;\n\tbackground-color: transparent;\n\tborder: 1px solid #444;\n\tpadding: 0.4em;\n}\n#ui-dialog-body.settings button[id|=\"setting-control\"]:hover {\n\tbackground-color: #333;\n\tborder-color: #eee;\n}\n#ui-dialog-body.settings button[id|=\"setting-control\"].enabled {\n\tbackground-color: #282;\n\tborder-color: #4a4;\n}\n#ui-dialog-body.settings button[id|=\"setting-control\"].enabled:hover {\n\tbackground-color: #4a4;\n\tborder-color: #6c6;\n}\n#ui-dialog-body.settings input[type=\"range\"][id|=\"setting-control\"] {\n\tmax-width: 35vw;\n}\n\n/* Stop text selection on certain UI elements. */\n#ui-dialog-body.list a,\n#ui-dialog-body.settings span[id|=\"setting-input\"] {\n\t-webkit-user-select: none;\n\t   -moz-user-select: none;\n\t    -ms-user-select: none;\n\t        user-select: none;\n}\n\n\n/*\n\tDefault font icon styles.\n*/\n#ui-dialog-body.saves button[id=\"saves-export\"]:before,\n#ui-dialog-body.saves button[id=\"saves-import\"]:before,\n#ui-dialog-body.saves button[id=\"saves-clear\"]:before,\n#ui-dialog-body.settings button[id|=\"setting-control\"]:after,\n#ui-dialog-body.settings button[id|=\"setting-control\"].enabled:after {\n\tfont-family: \"tme-fa-icons\";\n\tfont-style: normal;\n\tfont-weight: normal;\n\tfont-variant: normal;\n\ttext-transform: none;\n\tline-height: 1;\n\tspeak: none;\n}\n#ui-dialog-body.saves button[id=\"saves-export\"]:before {\n\tcontent: \"\\e829\\00a0\";\n}\n#ui-dialog-body.saves button[id=\"saves-import\"]:before {\n\tcontent: \"\\e82a\\00a0\";\n}\n#ui-dialog-body.saves button[id=\"saves-clear\"]:before {\n\tcontent: \"\\e827\\00a0\";\n}\n#ui-dialog-body.settings button[id|=\"setting-control\"]:after {\n\tcontent: \"\\00a0\\00a0\\e830\";\n}\n#ui-dialog-body.settings button[id|=\"setting-control\"].enabled:after {\n\tcontent: \"\\00a0\\00a0\\e831\";\n}\n</style>\n<style id=\"style-ui-bar\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/ui-bar.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tPatches to the core styles.\n*/\n#story {\n\tmargin-left: 20em;\n\t-o-transition: margin-left 200ms ease-in;\n\ttransition: margin-left 200ms ease-in;\n}\n#ui-bar.stowed ~ #story {\n\tmargin-left: 4.5em;\n}\n@media screen and (max-width: 1136px) {\n\t#story {\n\t\tmargin-left: 19em;\n\t}\n\t#ui-bar.stowed ~ #story {\n\t\tmargin-left: 3.5em;\n\t}\n}\n/*\n\tAt very narrow viewport widths, set `#story{margin-left}` equal to the value\n\tof `#ui-bar.stowed~#story{margin-left}`, so that `#ui-bar` will side over top\n\tof `#story` when unstowed, rather than shoving it over.\n*/\n@media screen and (max-width: 768px) {\n\t#story {\n\t\tmargin-left: 3.5em;\n\t}\n}\n\n\n/*\n\tDefault structural styles.\n*/\n#ui-bar {\n\tposition: fixed;\n\tz-index: 50;\n\ttop: 0;\n\tleft: 0;\n\twidth: 17.5em;\n\theight: 100%;\n\tmargin: 0;\n\tpadding: 0;\n\t-o-transition: left 200ms ease-in;\n\ttransition: left 200ms ease-in;\n}\n#ui-bar.stowed {\n\tleft: -15.5em;\n}\n#ui-bar-body {\n\theight: 90%; /* fallback for browsers without support for calc() */\n\theight: calc(100% - 2.5em);\n\tmargin: 2.5em 0;\n\tpadding: 0 1.5em;\n}\n#ui-bar.stowed #ui-bar-history,\n#ui-bar.stowed #ui-bar-body {\n\tvisibility: hidden;\n\t-o-transition: visibility 200ms step-end;\n\ttransition: visibility 200ms step-end;\n}\n\n\n/*\n\tDefault appearance styles.\n*/\n#ui-bar {\n\tbackground-color: #222;\n\tborder-right: 1px solid #444;\n\ttext-align: center;\n}\n#ui-bar-tray {\n\tposition: absolute;\n\ttop: 0.2em;\n\tleft: 0;\n\tright: 0;\n}\n#ui-bar a {\n\ttext-decoration: none;\n}\n#ui-bar hr {\n\tborder-color: #444;\n}\n#ui-bar-toggle,\n#ui-bar-history [id|=\"history\"] {\n\tfont-size: 1.2em;\n\tline-height: inherit;\n\tcolor: #eee;\n\tbackground-color: transparent;\n\tborder: 1px solid #444;\n}\n#ui-bar-toggle {\n\tdisplay: block;\n\tposition: absolute;\n\ttop: 0;\n\tright: 0;\n\tborder-right: none;\n\tpadding: 0.3em 0.45em 0.25em;\n}\n#ui-bar.stowed #ui-bar-toggle {\n\tpadding: 0.3em 0.35em 0.25em 0.55em;\n}\n#ui-bar-toggle:hover {\n\tbackground-color: #444;\n\tborder-color: #eee;\n}\n#ui-bar-history {\n\tmargin: 0 auto;\n}\n#ui-bar-history [id|=\"history\"] {\n\tpadding: 0.2em 0.45em 0.35em;\n}\n#ui-bar-history #history-jumpto {\n\tpadding: 0.2em 0.665em 0.35em;\n}\n#ui-bar-history [id|=\"history\"]:not(:first-child) {\n\tmargin-left: 1.2em;\n}\n#ui-bar-history [id|=\"history\"]:hover {\n\tbackground-color: #444;\n\tborder-color: #eee;\n}\n#ui-bar-history [id|=\"history\"]:disabled {\n\tcolor: #444;\n\tbackground-color: transparent;\n\tborder-color: #444;\n}\n#ui-bar-body {\n\tline-height: 1.5;\n\toverflow: auto;\n}\n#ui-bar-body > :not(:first-child) {\n\tmargin-top: 2em;\n}\n#story-title {\n\tmargin: 0;\n\tfont-size: 162.5%;\n}\n#story-author {\n\tmargin-top: 2em;\n\tfont-weight: bold;\n}\n#menu ul {\n\tmargin: 1em 0 0;\n\tpadding: 0;\n\tlist-style: none;\n\tborder: 1px solid #444;\n}\n#menu ul:empty {\n\tdisplay: none;\n}\n#menu li {\n\tmargin: 0;\n}\n#menu li:not(:first-child) {\n\tborder-top: 1px solid #444;\n}\n#menu li a {\n\tdisplay: block;\n\tpadding: 0.25em 0.75em;\n\tborder: 1px solid transparent;\n\tcolor: #eee;\n\ttext-transform: uppercase;\n}\n#menu li a:hover {\n\tbackground-color: #444;\n\tborder-color: #eee;\n}\n\n/* Stop text selection on certain UI elements. */\n#ui-bar-history [id|=\"history\"],\n#ui-bar-toggle,\n#menu a {\n\t-webkit-user-select: none;\n\t   -moz-user-select: none;\n\t    -ms-user-select: none;\n\t        user-select: none;\n}\n\n\n/*\n\tDefault font icon styles.\n*/\n#ui-bar-toggle:before,\n#ui-bar-history [id|=\"history\"],\n#menu-core li[id|=\"menu-item\"] a:before {\n\tfont-family: \"tme-fa-icons\";\n\tfont-style: normal;\n\tfont-weight: normal;\n\tfont-variant: normal;\n\ttext-transform: none;\n\tline-height: 1;\n\tspeak: none;\n}\n#ui-bar-toggle:before {\n\tcontent: \"\\e81d\";\n}\n#ui-bar.stowed #ui-bar-toggle:before {\n\tcontent: \"\\e81e\";\n}\n#menu-item-saves a:before {\n\tcontent: \"\\e82b\\00a0\";\n}\n#menu-item-settings a:before {\n\tcontent: \"\\e82d\\00a0\";\n}\n#menu-item-restart a:before {\n\tcontent: \"\\e82c\\00a0\";\n}\n#menu-item-share a:before {\n\tcontent: \"\\e82f\\00a0\";\n}\n</style>\n<style id=\"style-ui-debug\" type=\"text/css\">/***********************************************************************************************************************\n\n\tcss/ui-debug.css\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tDefault debug bar styles.\n*/\n#debug-bar {\n\tbackground-color: #222;\n\tborder-left: 1px solid #444;\n\tborder-top: 1px solid #444;\n\tbottom: 0;\n\tmargin: 0;\n\tmax-height: 75%;\n\t/* max-width: 28em;\n\tmin-width: 22em; */\n\tpadding: 0.5em;\n\tposition: fixed;\n\tright: 0;\n\tz-index: 99900;\n}\n#debug-bar > div:not([id]) + div {\n\tmargin-top: 0.5em;\n}\n#debug-bar > div > label {\n\tmargin-right: 0.5em;\n}\n#debug-bar > div > input[type=\"text\"] {\n\tmin-width: 0;\n\twidth: 8em;\n}\n#debug-bar > div > select {\n\twidth: 15em;\n}\n\n#debug-bar-toggle {\n\tcolor: #eee;\n\tbackground-color: #222;\n\tborder: 1px solid #444;\n\theight: 101%; /* fallback for browsers without support for calc() */\n\theight: calc(100% + 1px);\n\tleft: -2em; /* fallback for browsers without support for calc() */\n\tleft: calc(-2em - 1px);\n\tposition: absolute;\n\ttop: -1px;\n\twidth: 2em;\n}\n#debug-bar-toggle:hover {\n\tbackground-color: #333;\n\tborder-color: #eee;\n}\n\n#debug-bar-hint {\n\tbottom: 0.175em;\n\tfont-size: 4.5em;\n\topacity: 0.33;\n\tpointer-events: none;\n\tposition: fixed;\n\tright: 0.6em;\n\t-webkit-user-select: none;\n\t   -moz-user-select: none;\n\t    -ms-user-select: none;\n\t        user-select: none;\n\twhite-space: nowrap;\n}\n\n#debug-bar-watch {\n\tbackground-color: #222;\n\tborder-left: 1px solid #444;\n\tborder-top: 1px solid #444;\n\tbottom: 102%; /* fallback for browsers without support for calc() */\n\tbottom: calc(100% + 1px);\n\tfont-size: 0.9em;\n\tleft: -1px;\n\tmax-height: 650%; /* fallback for browsers without support for vh units */\n\tmax-height: 65vh;\n\tposition: absolute;\n\toverflow-x: hidden;\n\toverflow-y: scroll;\n\tright: 0;\n\tz-index: 99800;\n}\n#debug-bar-watch[hidden] {\n\tdisplay: none;\n}\n#debug-bar-watch div {\n\tcolor: #999;\n\tfont-style: italic;\n\tmargin: 1em auto;\n\ttext-align: center;\n}\n#debug-bar-watch table {\n\twidth: 100%;\n}\n#debug-bar-watch tr:nth-child(2n) {\n\tbackground-color: rgba(127, 127, 127, 0.15);\n}\n#debug-bar-watch td {\n\tpadding: 0.2em 0;\n}\n#debug-bar-watch td:first-child + td {\n\tpadding: 0.2em 0.3em 0.2em 0.1em;\n}\n#debug-bar-watch .watch-delete {\n\tbackground-color: transparent;\n\tborder: none;\n\tcolor: #c00;\n}\n#debug-bar-watch-all,\n#debug-bar-watch-none {\n\tmargin-left: 0.5em;\n}\n#debug-bar-watch-toggle,\n#debug-bar-views-toggle {\n\tcolor: #eee;\n\tbackground-color: transparent;\n\tborder: 1px solid #444;\n\tmargin-right: 1em;\n\tpadding: 0.4em;\n}\n#debug-bar-watch-toggle:hover,\n#debug-bar-views-toggle:hover {\n\tbackground-color: #333;\n\tborder-color: #eee;\n}\n#debug-bar-watch:not([hidden]) ~ div #debug-bar-watch-toggle,\nhtml[data-debug-view] #debug-bar-views-toggle {\n\tbackground-color: #282;\n\tborder-color: #4a4;\n}\n#debug-bar-watch:not([hidden]) ~ div #debug-bar-watch-toggle:hover,\nhtml[data-debug-view] #debug-bar-views-toggle:hover {\n\tbackground-color: #4a4;\n\tborder-color: #6c6;\n}\n\n#debug-bar-toggle:before,\n#debug-bar-hint:after,\n#debug-bar-watch .watch-delete:before,\n#debug-bar-watch-add:before,\n#debug-bar-watch-all:before,\n#debug-bar-watch-none:before,\n#debug-bar-watch-toggle:after,\n#debug-bar-views-toggle:after {\n\tfont-family: \"tme-fa-icons\";\n\tfont-style: normal;\n\tfont-weight: normal;\n\tfont-variant: normal;\n\ttext-transform: none;\n\tline-height: 1;\n\tspeak: none;\n}\n#debug-bar-toggle:before {\n\tcontent: \"\\e838\";\n}\n#debug-bar-hint:after {\n\tcontent: \"\\e838\\202f\\e822\";\n}\n#debug-bar-watch .watch-delete:before {\n\tcontent: \"\\e804\";\n}\n#debug-bar-watch-add:before {\n\tcontent: \"\\e805\";\n}\n#debug-bar-watch-all:before {\n\tcontent: \"\\e83a\";\n}\n#debug-bar-watch-none:before {\n\tcontent: \"\\e827\";\n}\n#debug-bar-watch-toggle:after,\n#debug-bar-views-toggle:after {\n\tcontent: \"\\00a0\\00a0\\e830\";\n}\n#debug-bar-watch:not([hidden]) ~ div #debug-bar-watch-toggle:after,\nhtml[data-debug-view] #debug-bar-views-toggle:after {\n\tcontent: \"\\00a0\\00a0\\e831\";\n}\n\n\n/*\n\tDefault debug view styles.\n*/\nhtml[data-debug-view] .debug {\n\tpadding: 0.25em;\n\tbackground-color: #234; /* #541, #151 */\n}\nhtml[data-debug-view] .debug[title] {\n\tcursor: help;\n}\nhtml[data-debug-view] .debug.block {\n\tdisplay: inline-block;\n\tvertical-align: middle;\n}\nhtml[data-debug-view] .debug.invalid {\n\ttext-decoration: line-through;\n}\nhtml[data-debug-view] .debug.hidden,\nhtml[data-debug-view] .debug.hidden .debug {\n\tbackground-color: #555;\n}\nhtml:not([data-debug-view]) .debug.hidden {\n\tdisplay: none;\n}\n\nhtml[data-debug-view] .debug[data-name][data-type]:before,\nhtml[data-debug-view] .debug[data-name][data-type].nonvoid:after {\n\tbackground-color: rgba(0,0,0,0.25);\n\tfont-family: monospace, monospace;\n\twhite-space: pre;\n}\nhtml[data-debug-view] .debug[data-name][data-type]:before {\n\tcontent: attr(data-name);\n}\nhtml[data-debug-view] .debug[data-name][data-type|=\"macro\"]:before {\n\tcontent: \"<<\" attr(data-name) \">>\";\n}\nhtml[data-debug-view] .debug[data-name][data-type|=\"macro\"].nonvoid:after {\n\tcontent: \"<</\" attr(data-name) \">>\";\n}\nhtml[data-debug-view] .debug[data-name][data-type|=\"html\"]:before {\n\tcontent: \"<\" attr(data-name) \">\";\n}\nhtml[data-debug-view] .debug[data-name][data-type|=\"html\"].nonvoid:after {\n\tcontent: \"</\" attr(data-name) \">\";\n}\nhtml[data-debug-view] .debug[data-name][data-type]:not(:empty):before {\n\tmargin-right: 0.25em;\n}\nhtml[data-debug-view] .debug[data-name][data-type].nonvoid:not(:empty):after {\n\tmargin-left: 0.25em;\n}\nhtml[data-debug-view] .debug[data-name][data-type|=\"special\"],\nhtml[data-debug-view] .debug[data-name][data-type|=\"special\"]:before {\n\tdisplay: block;\n}\n</style>\n</head>\n<body>\n\t<div id=\"init-screen\">\n\t\t<div id=\"init-no-js\"><noscript>JavaScript is required. Please enable it to continue.</noscript></div>\n\t\t<div id=\"init-lacking\">Your browser lacks required capabilities. Please upgrade it or switch to another to continue.</div>\n\t\t<div id=\"init-loading\"><div>Loading&hellip;</div></div>\n\t</div>\n\t{{STORY_DATA}}\n\t<script id=\"script-sugarcube\" type=\"text/javascript\">\n\t/*! SugarCube JS */\n\tif(document.documentElement.getAttribute(\"data-init\")===\"loading\"){window.TWINE1=false;\nwindow.DEBUG=true;\n(function (window, document, jQuery, undefined) {\n\"use strict\";\n\n'use strict';\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nvar _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"]) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError(\"Invalid attempt to destructure non-iterable instance\"); } }; }();\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; };\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }\n\n/***********************************************************************************************************************\n\n\tlib/alert.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tTODO: This regular expression should be elsewhere.\n\n\tError prologs by engine/browser: (ca. 2018)\n\t\tChrome, Opera, & Vivaldi → `Uncaught \\w*Error: …`\n\t\tEdge & IE                → `…`\n\t\tFirefox                  → `Error: …`\n\t\tOpera (Presto)           → `Uncaught exception: \\w*(?:Error|Exception): …`\n\t\tSafari (ca. v5.1)        → `\\w*(?:Error|_ERR): …`\n*/\nvar errorPrologRegExp = /^(?:(?:uncaught\\s+(?:exception:\\s+)?)?\\w*(?:error|exception|_err):\\s+)+/i; // eslint-disable-line no-unused-vars, no-var\n\nvar Alert = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tError Functions.\n *******************************************************************************************************************/\n\n\tfunction _alertMesg(type, where, what, error) {\n\t\tvar isFatal = type === 'fatal';\n\t\tvar mesg = 'Apologies! ' + (isFatal ? 'A fatal' : 'An') + ' error has occurred.';\n\n\t\tif (isFatal) {\n\t\t\tmesg += ' Aborting.';\n\t\t} else {\n\t\t\tmesg += ' You may be able to continue, but some parts may not work properly.';\n\t\t}\n\n\t\tif (where != null || what != null) {\n\t\t\t// lazy equality for null\n\t\t\tmesg += '\\n\\nError';\n\n\t\t\tif (where != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tmesg += ' [' + where + ']';\n\t\t\t}\n\n\t\t\tif (what != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tmesg += ': ' + what.replace(errorPrologRegExp, '') + '.';\n\t\t\t} else {\n\t\t\t\tmesg += ': unknown error.';\n\t\t\t}\n\t\t}\n\n\t\tif ((typeof error === 'undefined' ? 'undefined' : _typeof(error)) === 'object' && error.stack) {\n\t\t\tmesg += '\\n\\nStack Trace:\\n' + error.stack;\n\t\t}\n\n\t\twindow.alert(mesg); // eslint-disable-line no-alert\n\t}\n\n\tfunction alertError(where, what, error) {\n\t\t_alertMesg(null, where, what, error);\n\t}\n\n\tfunction alertFatal(where, what, error) {\n\t\t_alertMesg('fatal', where, what, error);\n\t}\n\n\t/*******************************************************************************************************************\n \tError Event.\n *******************************************************************************************************************/\n\t/*\n \tSet up a global error handler for uncaught exceptions.\n */\n\t(function (origOnError) {\n\t\twindow.onerror = function (what, source, lineNum, colNum, error) {\n\t\t\t// Uncaught exceptions during play may be recoverable/ignorable.\n\t\t\tif (document.readyState === 'complete') {\n\t\t\t\talertError(null, what, error);\n\t\t\t}\n\n\t\t\t// Uncaught exceptions during startup should be fatal.\n\t\t\telse {\n\t\t\t\t\talertFatal(null, what, error);\n\t\t\t\t\twindow.onerror = origOnError;\n\n\t\t\t\t\tif (typeof window.onerror === 'function') {\n\t\t\t\t\t\twindow.onerror.apply(this, arguments);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t};\n\t})(window.onerror);\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\terror: { value: alertError },\n\t\tfatal: { value: alertFatal }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tlib/patterns.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tTODO: Move all markup patterns into here.\n*/\n\nvar Patterns = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tPatterns.\n *******************************************************************************************************************/\n\t/*\n \tWhitespace patterns.\n \t\tSpace class (equivalent to `\\s`):\n \t\t[\\u0020\\f\\n\\r\\t\\v\\u00a0\\u1680\\u180e\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000\\ufeff]\n \tSpace class, sans line terminators:\n \t\t[\\u0020\\f\\t\\v\\u00a0\\u1680\\u180e\\u2000-\\u200a\\u202f\\u205f\\u3000\\ufeff]\n \tLine Terminator class:\n \t\t[\\n\\r\\u2028\\u2029]\n */\n\n\tvar space = function () {\n\t\t/*\n  \tSome browsers still supported by SugarCube have faulty space classes (`\\s`).\n  \tWe check for that lossage here and, if necessary, build our own class from\n  \tthe component pieces.\n  */\n\t\tvar wsMap = new Map([[' ', '\\\\u0020'], ['\\f', '\\\\f'], ['\\n', '\\\\n'], ['\\r', '\\\\r'], ['\\t', '\\\\t'], ['\\v', '\\\\v'], ['\\xA0', '\\\\u00a0'], ['\\u1680', '\\\\u1680'], ['\\u180E', '\\\\u180e'], ['\\u2000', '\\\\u2000'], ['\\u2001', '\\\\u2001'], ['\\u2002', '\\\\u2002'], ['\\u2003', '\\\\u2003'], ['\\u2004', '\\\\u2004'], ['\\u2005', '\\\\u2005'], ['\\u2006', '\\\\u2006'], ['\\u2007', '\\\\u2007'], ['\\u2008', '\\\\u2008'], ['\\u2009', '\\\\u2009'], ['\\u200A', '\\\\u200a'], ['\\u2028', '\\\\u2028'], ['\\u2029', '\\\\u2029'], ['\\u202F', '\\\\u202f'], ['\\u205F', '\\\\u205f'], ['\\u3000', '\\\\u3000'], ['\\uFEFF', '\\\\ufeff']]);\n\t\tvar wsRe = /^\\s$/;\n\t\tvar missing = '';\n\n\t\twsMap.forEach(function (pat, char) {\n\t\t\tif (!wsRe.test(char)) {\n\t\t\t\tmissing += pat;\n\t\t\t}\n\t\t});\n\n\t\treturn missing ? '[\\\\s' + missing + ']' : '\\\\s';\n\t}();\n\tvar spaceNoTerminator = '[\\\\u0020\\\\f\\\\t\\\\v\\\\u00a0\\\\u1680\\\\u180e\\\\u2000-\\\\u200a\\\\u202f\\\\u205f\\\\u3000\\\\ufeff]';\n\tvar lineTerminator = '[\\\\n\\\\r\\\\u2028\\\\u2029]';\n\tvar notSpace = space === '\\\\s' ? '\\\\S' : space.replace(/^\\[/, '[^');\n\n\t/*\n \tCharacter patterns.\n */\n\tvar anyChar = '(?:.|' + lineTerminator + ')';\n\n\t/*\n \tLetter patterns.\n \t\tFIXME:\n \t\t1. The existing set, which is a TiddlyWiki holdover, should probably\n \t\t   encompass a significantly greater range of BMP code points.\n \t\t2. Should we include the surrogate pair code units (\\uD800-\\uDBFF &\n \t\t   \\uDC00-\\uDFFF) to handle non-BMP code points?  Further, should we\n \t\t   simply be checking for the code units themselves or checking for\n \t\t   properly mated pairs?\n */\n\tvar anyLetter = '[0-9A-Z_a-z\\\\-\\\\u00c0-\\\\u00d6\\\\u00d8-\\\\u00f6\\\\u00f8-\\\\u00ff\\\\u0150\\\\u0170\\\\u0151\\\\u0171]';\n\tvar anyLetterStrict = anyLetter.replace('\\\\-', ''); // anyLetter sans hyphen\n\n\t/*\n \tIdentifier patterns.\n \t\tNOTE: Since JavaScript's RegExp syntax does not support Unicode character\n \tclasses, the correct regular expression to match a valid identifier name\n \t(within the scope of our needs) would be on the order of 11–16 kB.  That\n \tbeing the case, for the moment we restrict valid TwineScript identifiers\n \tto US-ASCII.\n \t\tFIXME: Fix this to, at least, approximate the correct range.\n */\n\tvar identifierFirstChar = '[$A-Z_a-z]';\n\tvar identifierNextChar = '[$0-9A-Z_a-z]';\n\tvar identifier = '' + identifierFirstChar + identifierNextChar + '*';\n\n\t// Variable patterns.\n\tvar variableSigil = '[$_]';\n\tvar variable = variableSigil + identifier;\n\n\t// Macro name pattern.\n\tvar macroName = '[A-Za-z][\\\\w-]*|[=-]';\n\n\t// Template name pattern.\n\tvar templateName = '[A-Za-z][\\\\w-]*';\n\n\t// CSS image transclusion template pattern.\n\t//\n\t// NOTE: The alignment syntax isn't supported, but removing it might break uses\n\t// of the template in the wild, so we leave it alone for now.\n\tvar cssImage = '\\\\[[<>]?[Ii][Mm][Gg]\\\\[(?:\\\\s|\\\\S)*?\\\\]\\\\]+';\n\n\t// Inline CSS pattern.\n\tvar inlineCss = function () {\n\t\tvar twStyle = '(' + anyLetter + '+)\\\\(([^\\\\)\\\\|\\\\n]+)\\\\):'; // [1,2]=style(value):\n\t\tvar cssStyle = '(' + anyLetter + '+):([^;\\\\|\\\\n]+);'; // [3,4]=style:value;\n\t\tvar className = '((?:\\\\.' + anyLetter + '+)+);'; // [5]  =.className;\n\t\tvar idName = '((?:#' + anyLetter + '+)+);'; // [6]  =#id;\n\n\t\treturn twStyle + '|' + cssStyle + '|' + className + '|' + idName;\n\t}();\n\n\t// URL pattern.\n\tvar url = '(?:file|https?|mailto|ftp|javascript|irc|news|data):[^\\\\s\\'\"]+';\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze({\n\t\tspace: space,\n\t\tspaceNoTerminator: spaceNoTerminator,\n\t\tlineTerminator: lineTerminator,\n\t\tnotSpace: notSpace,\n\t\tanyChar: anyChar,\n\t\tanyLetter: anyLetter,\n\t\tanyLetterStrict: anyLetterStrict,\n\t\tidentifierFirstChar: identifierFirstChar,\n\t\tidentifierNextChar: identifierNextChar,\n\t\tidentifier: identifier,\n\t\tvariableSigil: variableSigil,\n\t\tvariable: variable,\n\t\tmacroName: macroName,\n\t\ttemplateName: templateName,\n\t\tcssImage: cssImage,\n\t\tinlineCss: inlineCss,\n\t\turl: url\n\t});\n}();\n\n/***********************************************************************************************************************\n\n\tlib/extensions.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Patterns */\n\n/*\n\tDOM API Polyfills.\n*/\n(function () {\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tPolyfills.\n *******************************************************************************************************************/\n\t/*\n \tReturns the target's first child `Element` or `null` if there are no child elements.\n */\n\n\t(function (domApi) {\n\t\tif (domApi && domApi.prototype && domApi.prototype.firstElementChild == null) {\n\t\t\t// lazy equality for null\n\t\t\tvar ELEMENT_NODE = Node.ELEMENT_NODE;\n\n\t\t\tObject.defineProperty(domApi.prototype, 'firstElementChild', {\n\t\t\t\tget: function get() {\n\t\t\t\t\tvar nodes = this.childNodes; // WARNING: This is a live collection.\n\n\t\t\t\t\tfor (var i = 0; i < nodes.length; ++i) {\n\t\t\t\t\t\tvar node = nodes[i];\n\n\t\t\t\t\t\tif (node.nodeType === ELEMENT_NODE) {\n\t\t\t\t\t\t\treturn node;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t})(window.Node || window.Element);\n})();\n\n/*\n\tJavaScript Polyfills.\n\n\tNOTE: The ES5 and ES6 polyfills come from the vendored `es5-shim.js` and `es6-shim.js` libraries.\n*/\n(function () {\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\t/*\n \tTrims whitespace from either the start or end of the given string.\n */\n\n\tvar _trimString = function () {\n\t\t// Whitespace regular expressions.\n\t\tvar startWSRe = new RegExp('^' + Patterns.space + Patterns.space + '*');\n\t\tvar endWSRe = new RegExp('' + Patterns.space + Patterns.space + '*$');\n\n\t\tfunction trimString(str, where) {\n\t\t\tvar val = String(str);\n\n\t\t\tif (!val) {\n\t\t\t\treturn val;\n\t\t\t}\n\n\t\t\tswitch (where) {\n\t\t\t\tcase 'start':\n\t\t\t\t\treturn startWSRe.test(val) ? val.replace(startWSRe, '') : val;\n\n\t\t\t\tcase 'end':\n\t\t\t\t\treturn endWSRe.test(val) ? val.replace(endWSRe, '') : val;\n\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error('_trimString called with incorrect where parameter value: \"' + where + '\"');\n\t\t\t}\n\t\t}\n\n\t\treturn trimString;\n\t}();\n\n\t/*\n \tGenerates a pad string based upon the given string and length.\n */\n\tfunction _createPadString(length, padding) {\n\t\tvar targetLength = Number.parseInt(length, 10) || 0;\n\n\t\tif (targetLength < 1) {\n\t\t\treturn '';\n\t\t}\n\n\t\tvar padString = typeof padding === 'undefined' ? '' : String(padding);\n\n\t\tif (padString === '') {\n\t\t\tpadString = ' ';\n\t\t}\n\n\t\twhile (padString.length < targetLength) {\n\t\t\tvar curPadLength = padString.length;\n\t\t\tvar remainingLength = targetLength - curPadLength;\n\n\t\t\tpadString += curPadLength > remainingLength ? padString.slice(0, remainingLength) : padString;\n\t\t}\n\n\t\tif (padString.length > targetLength) {\n\t\t\tpadString = padString.slice(0, targetLength);\n\t\t}\n\n\t\treturn padString;\n\t}\n\n\t/*******************************************************************************************************************\n \tPolyfills.\n *******************************************************************************************************************/\n\t/*\n \t[ES2019] Returns a new array consisting of the source array with all sub-array elements\n \tconcatenated into it recursively up to the given depth.\n */\n\tif (!Array.prototype.flat) {\n\t\tObject.defineProperty(Array.prototype, 'flat', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\t\t\tvalue: function () {\n\t\t\t\tfunction flat() /* depth */{\n\t\t\t\t\tif (this == null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tthrow new TypeError('Array.prototype.flat called on null or undefined');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar depth = arguments.length === 0 ? 1 : Number(arguments[0]) || 0;\n\n\t\t\t\t\tif (depth < 1) {\n\t\t\t\t\t\treturn Array.prototype.slice.call(this);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn Array.prototype.reduce.call(this, function (acc, cur) {\n\t\t\t\t\t\tif (cur instanceof Array) {\n\t\t\t\t\t\t\t// acc.push.apply(acc, flat.call(cur, depth - 1));\n\t\t\t\t\t\t\tacc.push.apply(acc, _toConsumableArray(flat.call(cur, depth - 1)));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tacc.push(cur);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\treturn acc;\n\t\t\t\t\t}, []);\n\t\t\t\t}\n\n\t\t\t\treturn flat;\n\t\t\t}()\n\t\t});\n\t}\n\n\t/*\n \t[ES2019] Returns a new array consisting of the result of calling the given mapping function\n \ton every element in the source array and then concatenating all sub-array elements into it\n \trecursively up to a depth of `1`.  Identical to calling `<Array>.map(fn).flat()`.\n */\n\tif (!Array.prototype.flatMap) {\n\t\tObject.defineProperty(Array.prototype, 'flatMap', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value() /* callback [, thisArg] */{\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Array.prototype.flatMap called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\treturn Array.prototype.map.apply(this, arguments).flat();\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2016] Returns whether the given element was found within the array.\n */\n\tif (!Array.prototype.includes) {\n\t\tObject.defineProperty(Array.prototype, 'includes', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value() /* needle [, fromIndex] */{\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Array.prototype.includes called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\tif (arguments.length === 0) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tvar length = this.length >>> 0;\n\n\t\t\t\tif (length === 0) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tvar needle = arguments[0];\n\t\t\t\tvar i = Number(arguments[1]) || 0;\n\n\t\t\t\tif (i < 0) {\n\t\t\t\t\ti = Math.max(0, length + i);\n\t\t\t\t}\n\n\t\t\t\tfor (; /* empty */i < length; ++i) {\n\t\t\t\t\tvar value = this[i];\n\n\t\t\t\t\tif (value === needle || value !== value && needle !== needle) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn false;\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2017] Returns a new array consisting of the given object's own enumerable property/value\n \tpairs as `[key, value]` arrays.\n */\n\tif (!Object.entries) {\n\t\tObject.defineProperty(Object, 'entries', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(obj) {\n\t\t\t\tif ((typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) !== 'object' || obj === null) {\n\t\t\t\t\tthrow new TypeError('Object.entries object parameter must be an object');\n\t\t\t\t}\n\n\t\t\t\treturn Object.keys(obj).map(function (key) {\n\t\t\t\t\treturn [key, obj[key]];\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2019] Returns a new generic object consisting of the given list's key/value pairs.\n */\n\tif (!Object.fromEntries) {\n\t\tObject.defineProperty(Object, 'fromEntries', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(iter) {\n\t\t\t\treturn Array.from(iter).reduce(function (acc, pair) {\n\t\t\t\t\tif (Object(pair) !== pair) {\n\t\t\t\t\t\tthrow new TypeError('Object.fromEntries iterable parameter must yield objects');\n\t\t\t\t\t}\n\n\t\t\t\t\tif (pair[0] in acc) {\n\t\t\t\t\t\tObject.defineProperty(acc, pair[0], {\n\t\t\t\t\t\t\tconfigurable: true,\n\t\t\t\t\t\t\tenumerable: true,\n\t\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\t\tvalue: pair[1]\n\t\t\t\t\t\t});\n\t\t\t\t\t} else {\n\t\t\t\t\t\tacc[pair[0]] = pair[1]; // eslint-disable-line no-param-reassign\n\t\t\t\t\t}\n\n\t\t\t\t\treturn acc;\n\t\t\t\t}, {});\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2017] Returns all own property descriptors of the given object.\n */\n\tif (!Object.getOwnPropertyDescriptors) {\n\t\tObject.defineProperty(Object, 'getOwnPropertyDescriptors', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(obj) {\n\t\t\t\tif (obj == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Object.getOwnPropertyDescriptors object parameter is null or undefined');\n\t\t\t\t}\n\n\t\t\t\tvar O = Object(obj);\n\n\t\t\t\treturn Reflect.ownKeys(O).reduce(function (acc, key) {\n\t\t\t\t\tvar desc = Object.getOwnPropertyDescriptor(O, key);\n\n\t\t\t\t\tif (typeof desc !== 'undefined') {\n\t\t\t\t\t\tif (key in acc) {\n\t\t\t\t\t\t\tObject.defineProperty(acc, key, {\n\t\t\t\t\t\t\t\tconfigurable: true,\n\t\t\t\t\t\t\t\tenumerable: true,\n\t\t\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\t\t\tvalue: desc\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tacc[key] = desc; // eslint-disable-line no-param-reassign\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\treturn acc;\n\t\t\t\t}, {});\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2017] Returns a new array consisting of the given object's own enumerable property values.\n */\n\tif (!Object.values) {\n\t\tObject.defineProperty(Object, 'values', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(obj) {\n\t\t\t\tif ((typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) !== 'object' || obj === null) {\n\t\t\t\t\tthrow new TypeError('Object.values object parameter must be an object');\n\t\t\t\t}\n\n\t\t\t\treturn Object.keys(obj).map(function (key) {\n\t\t\t\t\treturn obj[key];\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2017] Returns a string based on concatenating the given padding, repeated as necessary,\n \tto the start of the string so that the given length is reached.\n \t\tNOTE: This pads based upon Unicode code units, rather than code points.\n */\n\tif (!String.prototype.padStart) {\n\t\tObject.defineProperty(String.prototype, 'padStart', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(length, padding) {\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('String.prototype.padStart called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\tvar baseString = String(this);\n\t\t\t\tvar baseLength = baseString.length;\n\t\t\t\tvar targetLength = Number.parseInt(length, 10);\n\n\t\t\t\tif (targetLength <= baseLength) {\n\t\t\t\t\treturn baseString;\n\t\t\t\t}\n\n\t\t\t\treturn _createPadString(targetLength - baseLength, padding) + baseString;\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2017] Returns a string based on concatenating the given padding, repeated as necessary,\n \tto the end of the string so that the given length is reached.\n \t\tNOTE: This pads based upon Unicode code units, rather than code points.\n */\n\tif (!String.prototype.padEnd) {\n\t\tObject.defineProperty(String.prototype, 'padEnd', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(length, padding) {\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('String.prototype.padEnd called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\tvar baseString = String(this);\n\t\t\t\tvar baseLength = baseString.length;\n\t\t\t\tvar targetLength = Number.parseInt(length, 10);\n\n\t\t\t\tif (targetLength <= baseLength) {\n\t\t\t\t\treturn baseString;\n\t\t\t\t}\n\n\t\t\t\treturn baseString + _createPadString(targetLength - baseLength, padding);\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2019] Returns a string with all whitespace removed from the start of the string.\n */\n\tif (!String.prototype.trimStart) {\n\t\tObject.defineProperty(String.prototype, 'trimStart', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value() {\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('String.prototype.trimStart called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\treturn _trimString(this, 'start');\n\t\t\t}\n\t\t});\n\t}\n\n\tif (!String.prototype.trimLeft) {\n\t\tObject.defineProperty(String.prototype, 'trimLeft', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value() {\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('String.prototype.trimLeft called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\treturn _trimString(this, 'start');\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \t[ES2019] Returns a string with all whitespace removed from the end of the string.\n */\n\tif (!String.prototype.trimEnd) {\n\t\tObject.defineProperty(String.prototype, 'trimEnd', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value() {\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('String.prototype.trimEnd called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\treturn _trimString(this, 'end');\n\t\t\t}\n\t\t});\n\t}\n\n\tif (!String.prototype.trimRight) {\n\t\tObject.defineProperty(String.prototype, 'trimRight', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value() {\n\t\t\t\tif (this == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('String.prototype.trimRight called on null or undefined');\n\t\t\t\t}\n\n\t\t\t\treturn _trimString(this, 'end');\n\t\t\t}\n\t\t});\n\t}\n})();\n\n/*\n\tJavaScript Extensions.\n*/\n(function () {\n\t'use strict';\n\n\tvar _nativeMathRandom = Math.random;\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns a pseudo-random whole number (integer) within the given bounds.\n */\n\tfunction _random() /* [min ,] max */{\n\t\tvar min = void 0;\n\t\tvar max = void 0;\n\n\t\tswitch (arguments.length) {\n\t\t\tcase 0:\n\t\t\t\tthrow new Error('_random called with insufficient parameters');\n\t\t\tcase 1:\n\t\t\t\tmin = 0;\n\t\t\t\tmax = arguments[0];\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tmin = arguments[0];\n\t\t\t\tmax = arguments[1];\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif (min > max) {\n\t\t\tvar _ref = [max, min];\n\t\t\tmin = _ref[0];\n\t\t\tmax = _ref[1];\n\t\t}\n\n\t\treturn Math.floor(_nativeMathRandom() * (max - min + 1)) + min;\n\t}\n\n\t/*\n \tReturns a randomly selected index within the given length and bounds.\n \tBounds may be negative.\n */\n\tfunction _randomIndex(length, boundsArgs) {\n\t\tvar min = void 0;\n\t\tvar max = void 0;\n\n\t\tswitch (boundsArgs.length) {\n\t\t\tcase 1:\n\t\t\t\tmin = 0;\n\t\t\t\tmax = length - 1;\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tmin = 0;\n\t\t\t\tmax = Math.trunc(boundsArgs[1]);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tmin = Math.trunc(boundsArgs[1]);\n\t\t\t\tmax = Math.trunc(boundsArgs[2]);\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif (Number.isNaN(min)) {\n\t\t\tmin = 0;\n\t\t} else if (!Number.isFinite(min) || min >= length) {\n\t\t\tmin = length - 1;\n\t\t} else if (min < 0) {\n\t\t\tmin = length + min;\n\n\t\t\tif (min < 0) {\n\t\t\t\tmin = 0;\n\t\t\t}\n\t\t}\n\n\t\tif (Number.isNaN(max)) {\n\t\t\tmax = 0;\n\t\t} else if (!Number.isFinite(max) || max >= length) {\n\t\t\tmax = length - 1;\n\t\t} else if (max < 0) {\n\t\t\tmax = length + max;\n\n\t\t\tif (max < 0) {\n\t\t\t\tmax = length - 1;\n\t\t\t}\n\t\t}\n\n\t\treturn _random(min, max);\n\t}\n\n\t/*\n \tReturns an object (`{ char, start, end }`) containing the Unicode character at\n \tposition `pos`, its starting position, and its ending position—surrogate pairs\n \tare properly handled.  If `pos` is out-of-bounds, returns an object containing\n \tthe empty string and start/end positions of `-1`.\n \t\tThis function is necessary because JavaScript strings are sequences of UTF-16\n \tcode units, so surrogate pairs are exposed and thus must be handled.  While the\n \tES6/2015 standard does improve the situation somewhat, it does not alleviate\n \tthe need for this function.\n \t\tNOTE: Will throw exceptions on invalid surrogate pairs.\n \t\tIDEA: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/charAt\n */\n\tfunction _getCodePointStartAndEnd(str, pos) {\n\t\tvar code = str.charCodeAt(pos);\n\n\t\t// Given position was out-of-bounds.\n\t\tif (Number.isNaN(code)) {\n\t\t\treturn { char: '', start: -1, end: -1 };\n\t\t}\n\n\t\t// Code unit is not a UTF-16 surrogate.\n\t\tif (code < 0xD800 || code > 0xDFFF) {\n\t\t\treturn {\n\t\t\t\tchar: str.charAt(pos),\n\t\t\t\tstart: pos,\n\t\t\t\tend: pos\n\t\t\t};\n\t\t}\n\n\t\t// Code unit is a high surrogate (D800–DBFF).\n\t\tif (code >= 0xD800 && code <= 0xDBFF) {\n\t\t\tvar nextPos = pos + 1;\n\n\t\t\t// End of string.\n\t\t\tif (nextPos >= str.length) {\n\t\t\t\tthrow new Error('high surrogate without trailing low surrogate');\n\t\t\t}\n\n\t\t\tvar nextCode = str.charCodeAt(nextPos);\n\n\t\t\t// Next code unit is not a low surrogate (DC00–DFFF).\n\t\t\tif (nextCode < 0xDC00 || nextCode > 0xDFFF) {\n\t\t\t\tthrow new Error('high surrogate without trailing low surrogate');\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\tchar: str.charAt(pos) + str.charAt(nextPos),\n\t\t\t\tstart: pos,\n\t\t\t\tend: nextPos\n\t\t\t};\n\t\t}\n\n\t\t// Code unit is a low surrogate (DC00–DFFF) in the first position.\n\t\tif (pos === 0) {\n\t\t\tthrow new Error('low surrogate without leading high surrogate');\n\t\t}\n\n\t\tvar prevPos = pos - 1;\n\t\tvar prevCode = str.charCodeAt(prevPos);\n\n\t\t// Previous code unit is not a high surrogate (D800–DBFF).\n\t\tif (prevCode < 0xD800 || prevCode > 0xDBFF) {\n\t\t\tthrow new Error('low surrogate without leading high surrogate');\n\t\t}\n\n\t\treturn {\n\t\t\tchar: str.charAt(prevPos) + str.charAt(pos),\n\t\t\tstart: prevPos,\n\t\t\tend: pos\n\t\t};\n\t}\n\n\t/*******************************************************************************************************************\n \tExtensions, General.\n *******************************************************************************************************************/\n\t/*\n \tRandomly selects an element from the given array, or array-like object, and returns it.\n \t[DEPRECATED] Optionally, from within the given bounds.\n */\n\tObject.defineProperty(Array, 'random', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(array /* DEPRECATED: [, [min ,] max] */) {\n\t\t\tif ((typeof array === 'undefined' ? 'undefined' : _typeof(array)) !== 'object' || array === null || !Object.prototype.hasOwnProperty.call(array, 'length')) {\n\t\t\t\tthrow new TypeError('Array.random array parameter must be an array or array-lke object');\n\t\t\t}\n\n\t\t\tvar length = array.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar index = arguments.length === 0 ? _random(0, length - 1) : _randomIndex(length, Array.prototype.slice.call(arguments, 1));\n\n\t\t\treturn array[index];\n\t\t}\n\t});\n\n\t/*\n \tConcatenates one or more unique elements to the end of the base array\n \tand returns the result as a new array.  Elements which are arrays will\n \tbe merged—i.e. their elements will be concatenated, rather than the\n \tarray itself.\n */\n\tObject.defineProperty(Array.prototype, 'concatUnique', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* variadic */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.concatUnique called on null or undefined');\n\t\t\t}\n\n\t\t\tvar result = Array.from(this);\n\n\t\t\tif (arguments.length === 0) {\n\t\t\t\treturn result;\n\t\t\t}\n\n\t\t\tvar items = Array.prototype.reduce.call(arguments, function (prev, cur) {\n\t\t\t\treturn prev.concat(cur);\n\t\t\t}, []);\n\t\t\tvar addSize = items.length;\n\n\t\t\tif (addSize === 0) {\n\t\t\t\treturn result;\n\t\t\t}\n\n\t\t\tvar indexOf = Array.prototype.indexOf;\n\t\t\tvar push = Array.prototype.push;\n\n\t\t\tfor (var i = 0; i < addSize; ++i) {\n\t\t\t\tvar value = items[i];\n\n\t\t\t\tif (indexOf.call(result, value) === -1) {\n\t\t\t\t\tpush.call(result, value);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn result;\n\t\t}\n\t});\n\n\t/*\n \tReturns the number of times the given element was found within the array.\n */\n\tObject.defineProperty(Array.prototype, 'count', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needle [, fromIndex ] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.count called on null or undefined');\n\t\t\t}\n\n\t\t\tvar indexOf = Array.prototype.indexOf;\n\t\t\tvar needle = arguments[0];\n\t\t\tvar pos = Number(arguments[1]) || 0;\n\t\t\tvar count = 0;\n\n\t\t\twhile ((pos = indexOf.call(this, needle, pos)) !== -1) {\n\t\t\t\t++count;\n\t\t\t\t++pos;\n\t\t\t}\n\n\t\t\treturn count;\n\t\t}\n\t});\n\n\t/*\n \tRemoves and returns all of the given elements from the array.\n */\n\tObject.defineProperty(Array.prototype, 'delete', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needles */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.delete called on null or undefined');\n\t\t\t}\n\n\t\t\tif (arguments.length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar needles = Array.prototype.concat.apply([], arguments);\n\t\t\tvar needlesLength = needles.length;\n\t\t\tvar indices = [];\n\n\t\t\tfor (var i = 0; i < length; ++i) {\n\t\t\t\tvar value = this[i];\n\n\t\t\t\tfor (var j = 0; j < needlesLength; ++j) {\n\t\t\t\t\tvar needle = needles[j];\n\n\t\t\t\t\tif (value === needle || value !== value && needle !== needle) {\n\t\t\t\t\t\tindices.push(i);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tvar result = [];\n\n\t\t\t// Copy the elements (in original order).\n\t\t\tfor (var _i = 0, iend = indices.length; _i < iend; ++_i) {\n\t\t\t\tresult[_i] = this[indices[_i]];\n\t\t\t}\n\n\t\t\tvar splice = Array.prototype.splice;\n\n\t\t\t// Delete the elements (in reverse order).\n\t\t\tfor (var _i2 = indices.length - 1; _i2 >= 0; --_i2) {\n\t\t\t\tsplice.call(this, indices[_i2], 1);\n\t\t\t}\n\n\t\t\treturn result;\n\t\t}\n\t});\n\n\t/*\n \tRemoves and returns all of the elements at the given indices from the array.\n */\n\tObject.defineProperty(Array.prototype, 'deleteAt', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* indices */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.deleteAt called on null or undefined');\n\t\t\t}\n\n\t\t\tif (arguments.length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar splice = Array.prototype.splice;\n\t\t\tvar cpyIndices = [].concat(_toConsumableArray(new Set(Array.prototype.concat.apply([], arguments)\n\t\t\t// Map negative indices to their positive counterparts,\n\t\t\t// so the Set can properly filter out duplicates.\n\t\t\t.map(function (x) {\n\t\t\t\treturn x < 0 ? Math.max(0, length + x) : x;\n\t\t\t})).values()));\n\t\t\tvar delIndices = [].concat(_toConsumableArray(cpyIndices)).sort(function (a, b) {\n\t\t\t\treturn b - a;\n\t\t\t});\n\t\t\tvar result = [];\n\n\t\t\t// Copy the elements (in originally specified order).\n\t\t\tfor (var i = 0, iend = cpyIndices.length; i < iend; ++i) {\n\t\t\t\tresult[i] = this[cpyIndices[i]];\n\t\t\t}\n\n\t\t\t// Delete the elements (in descending numeric order).\n\t\t\tfor (var _i3 = 0, _iend = delIndices.length; _i3 < _iend; ++_i3) {\n\t\t\t\tsplice.call(this, delIndices[_i3], 1);\n\t\t\t}\n\n\t\t\treturn result;\n\t\t}\n\t});\n\n\t/*\n \tRemoves and returns all of the elements that pass the test implemented\n \tby the given predicate function from the array.\n */\n\tObject.defineProperty(Array.prototype, 'deleteWith', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(predicate, thisArg) {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.deleteWith called on null or undefined');\n\t\t\t}\n\t\t\tif (typeof predicate !== 'function') {\n\t\t\t\tthrow new Error('Array.prototype.deleteWith predicate parameter must be a function');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar splice = Array.prototype.splice;\n\t\t\tvar indices = [];\n\t\t\tvar result = [];\n\n\t\t\t// Copy the elements (in original order).\n\t\t\tfor (var i = 0; i < length; ++i) {\n\t\t\t\tif (predicate.call(thisArg, this[i], i, this)) {\n\t\t\t\t\tresult.push(this[i]);\n\t\t\t\t\tindices.push(i);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Delete the elements (in reverse order).\n\t\t\tfor (var _i4 = indices.length - 1; _i4 >= 0; --_i4) {\n\t\t\t\tsplice.call(this, indices[_i4], 1);\n\t\t\t}\n\n\t\t\treturn result;\n\t\t}\n\t});\n\n\t/*\n \tReturns the first element from the array.\n */\n\tObject.defineProperty(Array.prototype, 'first', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.first called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\treturn this[0];\n\t\t}\n\t});\n\n\t/*\n \tReturns whether all of the given elements were found within the array.\n */\n\tObject.defineProperty(Array.prototype, 'includesAll', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needles */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.includesAll called on null or undefined');\n\t\t\t}\n\n\t\t\tif (arguments.length === 1) {\n\t\t\t\tif (Array.isArray(arguments[0])) {\n\t\t\t\t\treturn Array.prototype.includesAll.apply(this, arguments[0]);\n\t\t\t\t}\n\n\t\t\t\treturn Array.prototype.includes.apply(this, arguments);\n\t\t\t}\n\n\t\t\tfor (var i = 0, iend = arguments.length; i < iend; ++i) {\n\t\t\t\tif (!Array.prototype.some.call(this, function (val) {\n\t\t\t\t\treturn val === this.val || val !== val && this.val !== this.val;\n\t\t\t\t}, { val: arguments[i] })) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn true;\n\t\t}\n\t});\n\n\t/*\n \tReturns whether any of the given elements were found within the array.\n */\n\tObject.defineProperty(Array.prototype, 'includesAny', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needles */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.includesAny called on null or undefined');\n\t\t\t}\n\n\t\t\tif (arguments.length === 1) {\n\t\t\t\tif (Array.isArray(arguments[0])) {\n\t\t\t\t\treturn Array.prototype.includesAny.apply(this, arguments[0]);\n\t\t\t\t}\n\n\t\t\t\treturn Array.prototype.includes.apply(this, arguments);\n\t\t\t}\n\n\t\t\tfor (var i = 0, iend = arguments.length; i < iend; ++i) {\n\t\t\t\tif (Array.prototype.some.call(this, function (val) {\n\t\t\t\t\treturn val === this.val || val !== val && this.val !== this.val;\n\t\t\t\t}, { val: arguments[i] })) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn false;\n\t\t}\n\t});\n\n\t/*\n \tReturns the last element from the array.\n */\n\tObject.defineProperty(Array.prototype, 'last', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.last called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\treturn this[length - 1];\n\t\t}\n\t});\n\n\t/*\n \tRandomly removes an element from the base array and returns it.\n \t[DEPRECATED] Optionally, from within the given bounds.\n */\n\tObject.defineProperty(Array.prototype, 'pluck', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* DEPRECATED: [min ,] max */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.pluck called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar index = arguments.length === 0 ? _random(0, length - 1) : _randomIndex(length, [].concat(Array.prototype.slice.call(arguments)));\n\n\t\t\treturn Array.prototype.splice.call(this, index, 1)[0];\n\t\t}\n\t});\n\n\t/*\n \tRandomly removes the given number of unique elements from the base array\n \tand returns the removed elements as a new array.\n */\n\tObject.defineProperty(Array.prototype, 'pluckMany', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(wantSize) {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.pluckMany called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar want = Math.trunc(wantSize);\n\n\t\t\tif (!Number.isInteger(want)) {\n\t\t\t\tthrow new Error('Array.prototype.pluckMany want parameter must be an integer');\n\t\t\t}\n\n\t\t\tif (want < 1) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tif (want > length) {\n\t\t\t\twant = length;\n\t\t\t}\n\n\t\t\tvar splice = Array.prototype.splice;\n\t\t\tvar result = [];\n\t\t\tvar max = length - 1;\n\n\t\t\tdo {\n\t\t\t\tresult.push(splice.call(this, _random(0, max--), 1)[0]);\n\t\t\t} while (result.length < want);\n\n\t\t\treturn result;\n\t\t}\n\t});\n\n\t/*\n \tAppends one or more unique elements to the end of the base array and\n \treturns its new length.\n */\n\tObject.defineProperty(Array.prototype, 'pushUnique', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* variadic */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.pushUnique called on null or undefined');\n\t\t\t}\n\n\t\t\tvar addSize = arguments.length;\n\n\t\t\tif (addSize === 0) {\n\t\t\t\treturn this.length >>> 0;\n\t\t\t}\n\n\t\t\tvar indexOf = Array.prototype.indexOf;\n\t\t\tvar push = Array.prototype.push;\n\n\t\t\tfor (var i = 0; i < addSize; ++i) {\n\t\t\t\tvar value = arguments[i];\n\n\t\t\t\tif (indexOf.call(this, value) === -1) {\n\t\t\t\t\tpush.call(this, value);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn this.length >>> 0;\n\t\t}\n\t});\n\n\t/*\n \tRandomly selects an element from the base array and returns it.\n \t[DEPRECATED] Optionally, from within the given bounds.\n */\n\tObject.defineProperty(Array.prototype, 'random', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* DEPRECATED: [min ,] max */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.random called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar index = arguments.length === 0 ? _random(0, length - 1) : _randomIndex(length, [].concat(Array.prototype.slice.call(arguments)));\n\n\t\t\treturn this[index];\n\t\t}\n\t});\n\n\t/*\n \tRandomly selects the given number of unique elements from the base array\n \tand returns the selected elements as a new array.\n */\n\tObject.defineProperty(Array.prototype, 'randomMany', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(wantSize) {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.randomMany called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tvar want = Math.trunc(wantSize);\n\n\t\t\tif (!Number.isInteger(want)) {\n\t\t\t\tthrow new Error('Array.prototype.randomMany want parameter must be an integer');\n\t\t\t}\n\n\t\t\tif (want < 1) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\tif (want > length) {\n\t\t\t\twant = length;\n\t\t\t}\n\n\t\t\tvar picked = new Map();\n\t\t\tvar result = [];\n\t\t\tvar max = length - 1;\n\n\t\t\tdo {\n\t\t\t\tvar i = void 0;\n\t\t\t\tdo {\n\t\t\t\t\ti = _random(0, max);\n\t\t\t\t} while (picked.has(i));\n\t\t\t\tpicked.set(i, true);\n\t\t\t\tresult.push(this[i]);\n\t\t\t} while (result.length < want);\n\n\t\t\treturn result;\n\t\t}\n\t});\n\n\t/*\n \tRandomly shuffles the array and returns it.\n */\n\tObject.defineProperty(Array.prototype, 'shuffle', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.shuffle called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn this;\n\t\t\t}\n\n\t\t\tfor (var i = length - 1; i > 0; --i) {\n\t\t\t\tvar j = Math.floor(_nativeMathRandom() * (i + 1));\n\n\t\t\t\tif (i === j) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t// [this[i], this[j]] = [this[j], this[i]];\n\t\t\t\tvar swap = this[i];\n\t\t\t\tthis[i] = this[j];\n\t\t\t\tthis[j] = swap;\n\t\t\t}\n\n\t\t\treturn this;\n\t\t}\n\t});\n\n\t/*\n \tPrepends one or more unique elements to the beginning of the base array\n \tand returns its new length.\n */\n\tObject.defineProperty(Array.prototype, 'unshiftUnique', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* variadic */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.unshiftUnique called on null or undefined');\n\t\t\t}\n\n\t\t\tvar addSize = arguments.length;\n\n\t\t\tif (addSize === 0) {\n\t\t\t\treturn this.length >>> 0;\n\t\t\t}\n\n\t\t\tvar indexOf = Array.prototype.indexOf;\n\t\t\tvar unshift = Array.prototype.unshift;\n\n\t\t\tfor (var i = 0; i < addSize; ++i) {\n\t\t\t\tvar value = arguments[i];\n\n\t\t\t\tif (indexOf.call(this, value) === -1) {\n\t\t\t\t\tunshift.call(this, value);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn this.length >>> 0;\n\t\t}\n\t});\n\n\t/*\n \tReturns a bound function that supplies the given arguments to the base function, followed\n \tby the arguments are supplied to the bound function, whenever it is called.\n */\n\tObject.defineProperty(Function.prototype, 'partial', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* variadic */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Function.prototype.partial called on null or undefined');\n\t\t\t}\n\n\t\t\tvar slice = Array.prototype.slice;\n\t\t\tvar fn = this;\n\t\t\tvar bound = slice.call(arguments, 0);\n\n\t\t\treturn function () {\n\t\t\t\tvar applied = [];\n\t\t\t\tvar argc = 0;\n\n\t\t\t\tfor (var i = 0; i < bound.length; ++i) {\n\t\t\t\t\tapplied.push(bound[i] === undefined ? arguments[argc++] : bound[i]);\n\t\t\t\t}\n\n\t\t\t\treturn fn.apply(this, applied.concat(slice.call(arguments, argc)));\n\t\t\t};\n\t\t}\n\t});\n\n\t/*\n \tReturns the given numerical clamped to the specified bounds.\n */\n\tObject.defineProperty(Math, 'clamp', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(num, min, max) {\n\t\t\tvar value = Number(num);\n\t\t\treturn Number.isNaN(value) ? NaN : value.clamp(min, max);\n\t\t}\n\t});\n\n\t/*\n \tReturns a decimal number eased from 0 to 1.\n \t\tNOTE: The magnitude of the returned value decreases if num < 0.5 or increases if num > 0.5.\n */\n\tObject.defineProperty(Math, 'easeInOut', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(num) {\n\t\t\treturn 1 - (Math.cos(Number(num) * Math.PI) + 1) / 2;\n\t\t}\n\t});\n\n\t/*\n \tReturns the number clamped to the specified bounds.\n */\n\tObject.defineProperty(Number.prototype, 'clamp', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* min, max */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Number.prototype.clamp called on null or undefined');\n\t\t\t}\n\n\t\t\tif (arguments.length !== 2) {\n\t\t\t\tthrow new Error('Number.prototype.clamp called with an incorrect number of parameters');\n\t\t\t}\n\n\t\t\tvar min = Number(arguments[0]);\n\t\t\tvar max = Number(arguments[1]);\n\n\t\t\tif (min > max) {\n\t\t\t\tvar _ref2 = [max, min];\n\t\t\t\tmin = _ref2[0];\n\t\t\t\tmax = _ref2[1];\n\t\t\t}\n\n\t\t\treturn Math.min(Math.max(this, min), max);\n\t\t}\n\t});\n\n\t/*\n \tReturns a copy of the given string with all RegExp metacharacters escaped.\n */\n\tif (!RegExp.escape) {\n\t\t(function () {\n\t\t\tvar _regExpMetaCharsRe = /[\\\\^$*+?.()|[\\]{}]/g;\n\t\t\tvar _hasRegExpMetaCharsRe = new RegExp(_regExpMetaCharsRe.source); // to drop the global flag\n\n\t\t\tObject.defineProperty(RegExp, 'escape', {\n\t\t\t\tconfigurable: true,\n\t\t\t\twritable: true,\n\n\t\t\t\tvalue: function value(str) {\n\t\t\t\t\tvar val = String(str);\n\t\t\t\t\treturn val && _hasRegExpMetaCharsRe.test(val) ? val.replace(_regExpMetaCharsRe, '\\\\$&') : val;\n\t\t\t\t}\n\t\t\t});\n\t\t})();\n\t}\n\n\t/*\n \tReturns a formatted string, after replacing each format item in the given format string\n \twith the text equivalent of the corresponding argument's value.\n */\n\t(function () {\n\t\tvar _formatRegExp = /{(\\d+)(?:,([+-]?\\d+))?}/g;\n\t\tvar _hasFormatRegExp = new RegExp(_formatRegExp.source); // to drop the global flag\n\n\t\tObject.defineProperty(String, 'format', {\n\t\t\tconfigurable: true,\n\t\t\twritable: true,\n\n\t\t\tvalue: function value(format) {\n\t\t\t\tfunction padString(str, align, pad) {\n\t\t\t\t\tif (!align) {\n\t\t\t\t\t\treturn str;\n\t\t\t\t\t}\n\n\t\t\t\t\tvar plen = Math.abs(align) - str.length;\n\n\t\t\t\t\tif (plen < 1) {\n\t\t\t\t\t\treturn str;\n\t\t\t\t\t}\n\n\t\t\t\t\t// const padding = Array(plen + 1).join(pad);\n\t\t\t\t\tvar padding = String(pad).repeat(plen);\n\t\t\t\t\treturn align < 0 ? str + padding : padding + str;\n\t\t\t\t}\n\n\t\t\t\tif (arguments.length < 2) {\n\t\t\t\t\treturn arguments.length === 0 ? '' : format;\n\t\t\t\t}\n\n\t\t\t\tvar args = arguments.length === 2 && Array.isArray(arguments[1]) ? [].concat(_toConsumableArray(arguments[1])) : Array.prototype.slice.call(arguments, 1);\n\n\t\t\t\tif (args.length === 0) {\n\t\t\t\t\treturn format;\n\t\t\t\t}\n\n\t\t\t\tif (!_hasFormatRegExp.test(format)) {\n\t\t\t\t\treturn format;\n\t\t\t\t}\n\n\t\t\t\t// Possibly required by some old buggy browsers.\n\t\t\t\t_formatRegExp.lastIndex = 0;\n\n\t\t\t\treturn format.replace(_formatRegExp, function (match, index, align) {\n\t\t\t\t\tvar retval = args[index];\n\n\t\t\t\t\tif (retval == null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\treturn '';\n\t\t\t\t\t}\n\n\t\t\t\t\twhile (typeof retval === 'function') {\n\t\t\t\t\t\tretval = retval();\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch (typeof retval === 'undefined' ? 'undefined' : _typeof(retval)) {\n\t\t\t\t\t\tcase 'string':\n\t\t\t\t\t\t\t/* no-op */break;\n\t\t\t\t\t\tcase 'object':\n\t\t\t\t\t\t\tretval = JSON.stringify(retval);break;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tretval = String(retval);break;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn padString(retval, !align ? 0 : Number.parseInt(align, 10), ' ');\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t})();\n\n\t/*\n \tReturns whether the given string was found within the string.\n */\n\tObject.defineProperty(String.prototype, 'contains', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needle [, fromIndex] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.contains called on null or undefined');\n\t\t\t}\n\n\t\t\treturn String.prototype.indexOf.apply(this, arguments) !== -1;\n\t\t}\n\t});\n\n\t/*\n \tReturns the number of times the given substring was found within the string.\n */\n\tObject.defineProperty(String.prototype, 'count', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needle [, fromIndex ] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.count called on null or undefined');\n\t\t\t}\n\n\t\t\tvar needle = String(arguments[0] || '');\n\n\t\t\tif (needle === '') {\n\t\t\t\treturn 0;\n\t\t\t}\n\n\t\t\tvar indexOf = String.prototype.indexOf;\n\t\t\tvar step = needle.length;\n\t\t\tvar pos = Number(arguments[1]) || 0;\n\t\t\tvar count = 0;\n\n\t\t\twhile ((pos = indexOf.call(this, needle, pos)) !== -1) {\n\t\t\t\t++count;\n\t\t\t\tpos += step;\n\t\t\t}\n\n\t\t\treturn count;\n\t\t}\n\t});\n\n\t/*\n \tReturns the first Unicode code point from the string.\n */\n\tObject.defineProperty(String.prototype, 'first', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.first called on null or undefined');\n\t\t\t}\n\n\t\t\t// Required as `this` could be a `String` object or come from a `call()` or `apply()`.\n\t\t\tvar str = String(this);\n\n\t\t\t// Get the first code point—may be one or two code units—and its end position.\n\n\t\t\tvar _getCodePointStartAnd = _getCodePointStartAndEnd(str, 0),\n\t\t\t    char = _getCodePointStartAnd.char;\n\n\t\t\treturn char;\n\t\t}\n\t});\n\n\t/*\n \tReturns the last Unicode code point from the string.\n */\n\tObject.defineProperty(String.prototype, 'last', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.last called on null or undefined');\n\t\t\t}\n\n\t\t\t// Required as `this` could be a `String` object or come from a `call()` or `apply()`.\n\t\t\tvar str = String(this);\n\n\t\t\t// Get the last code point—may be one or two code units—and its end position.\n\n\t\t\tvar _getCodePointStartAnd2 = _getCodePointStartAndEnd(str, str.length - 1),\n\t\t\t    char = _getCodePointStartAnd2.char;\n\n\t\t\treturn char;\n\t\t}\n\t});\n\n\t/*\n \tReturns a copy of the base string with `delCount` characters replaced with `replacement`, starting at `startAt`.\n */\n\tObject.defineProperty(String.prototype, 'splice', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(startAt, delCount, replacement) {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.splice called on null or undefined');\n\t\t\t}\n\n\t\t\tvar length = this.length >>> 0;\n\n\t\t\tif (length === 0) {\n\t\t\t\treturn '';\n\t\t\t}\n\n\t\t\tvar start = Number(startAt);\n\n\t\t\tif (!Number.isSafeInteger(start)) {\n\t\t\t\tstart = 0;\n\t\t\t} else if (start < 0) {\n\t\t\t\tstart += length;\n\n\t\t\t\tif (start < 0) {\n\t\t\t\t\tstart = 0;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (start > length) {\n\t\t\t\tstart = length;\n\t\t\t}\n\n\t\t\tvar count = Number(delCount);\n\n\t\t\tif (!Number.isSafeInteger(count) || count < 0) {\n\t\t\t\tcount = 0;\n\t\t\t}\n\n\t\t\tvar res = this.slice(0, start);\n\n\t\t\tif (typeof replacement !== 'undefined') {\n\t\t\t\tres += replacement;\n\t\t\t}\n\n\t\t\tif (start + count < length) {\n\t\t\t\tres += this.slice(start + count);\n\t\t\t}\n\n\t\t\treturn res;\n\t\t}\n\t});\n\n\t/*\n \tReturns an array of strings, split from the string, or an empty array if the string is empty.\n */\n\tObject.defineProperty(String.prototype, 'splitOrEmpty', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* [ separator [, limit ]] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.splitOrEmpty called on null or undefined');\n\t\t\t}\n\n\t\t\t// Required as `this` could be a `String` object or come from a `call()` or `apply()`.\n\t\t\tif (String(this) === '') {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\treturn String.prototype.split.apply(this, arguments);\n\t\t}\n\t});\n\n\t/*\n \tReturns a copy of the base string with the first Unicode code point uppercased,\n \taccording to any locale-specific rules.\n */\n\tObject.defineProperty(String.prototype, 'toLocaleUpperFirst', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.toLocaleUpperFirst called on null or undefined');\n\t\t\t}\n\n\t\t\t// Required as `this` could be a `String` object or come from a `call()` or `apply()`.\n\t\t\tvar str = String(this);\n\n\t\t\t// Get the first code point—may be one or two code units—and its end position.\n\n\t\t\tvar _getCodePointStartAnd3 = _getCodePointStartAndEnd(str, 0),\n\t\t\t    char = _getCodePointStartAnd3.char,\n\t\t\t    end = _getCodePointStartAnd3.end;\n\n\t\t\treturn end === -1 ? '' : char.toLocaleUpperCase() + str.slice(end + 1);\n\t\t}\n\t});\n\n\t/*\n \tReturns a copy of the base string with the first Unicode code point uppercased.\n */\n\tObject.defineProperty(String.prototype, 'toUpperFirst', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.toUpperFirst called on null or undefined');\n\t\t\t}\n\n\t\t\t// Required as `this` could be a `String` object or come from a `call()` or `apply()`.\n\t\t\tvar str = String(this);\n\n\t\t\t// Get the first code point—may be one or two code units—and its end position.\n\n\t\t\tvar _getCodePointStartAnd4 = _getCodePointStartAndEnd(str, 0),\n\t\t\t    char = _getCodePointStartAnd4.char,\n\t\t\t    end = _getCodePointStartAnd4.end;\n\n\t\t\treturn end === -1 ? '' : char.toUpperCase() + str.slice(end + 1);\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tExtensions, JSON.\n *******************************************************************************************************************/\n\t/*\n \tDefine `toJSON()` methods on each prototype we wish to support.\n */\n\tObject.defineProperty(Date.prototype, 'toJSON', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\treturn ['(revive:date)', this.toISOString()];\n\t\t}\n\t});\n\tObject.defineProperty(Function.prototype, 'toJSON', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\t/*\n   \tThe enclosing parenthesis here are necessary to force the function expression code\n   \tstring, returned by `this.toString()`, to be evaluated as an expression during\n   \trevival.  Without them, the function expression, which is likely nameless, will be\n   \tevaluated as a function definition—which will throw a syntax error exception, since\n   \tfunction definitions must have a name.\n   */\n\t\t\treturn ['(revive:eval)', '(' + this.toString() + ')'];\n\t\t}\n\t});\n\tObject.defineProperty(Map.prototype, 'toJSON', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\treturn ['(revive:map)', [].concat(_toConsumableArray(this))];\n\t\t}\n\t});\n\tObject.defineProperty(RegExp.prototype, 'toJSON', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\treturn ['(revive:eval)', this.toString()];\n\t\t}\n\t});\n\tObject.defineProperty(Set.prototype, 'toJSON', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\treturn ['(revive:set)', [].concat(_toConsumableArray(this))];\n\t\t}\n\t});\n\n\t/*\n \tUtility method to allow users to easily wrap their code in the revive wrapper.\n */\n\tObject.defineProperty(JSON, 'reviveWrapper', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(code, data) {\n\t\t\tif (typeof code !== 'string') {\n\t\t\t\tthrow new TypeError('JSON.reviveWrapper code parameter must be a string');\n\t\t\t}\n\n\t\t\treturn ['(revive:eval)', [code, data]];\n\t\t}\n\t});\n\n\t/*\n \tBackup the original `JSON.parse()` and replace it with a revive wrapper aware version.\n */\n\tObject.defineProperty(JSON, '_real_parse', {\n\t\tvalue: JSON.parse\n\t});\n\tObject.defineProperty(JSON, 'parse', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value(text, reviver) {\n\t\t\treturn JSON._real_parse(text, function (key, val) {\n\t\t\t\tvar value = val;\n\n\t\t\t\t/*\n    \tAttempt to revive wrapped values.\n    */\n\t\t\t\tif (Array.isArray(value) && value.length === 2) {\n\t\t\t\t\tswitch (value[0]) {\n\t\t\t\t\t\tcase '(revive:set)':\n\t\t\t\t\t\t\tvalue = new Set(value[1]);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase '(revive:map)':\n\t\t\t\t\t\t\tvalue = new Map(value[1]);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase '(revive:date)':\n\t\t\t\t\t\t\tvalue = new Date(value[1]);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase '(revive:eval)':\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t/* eslint-disable no-eval */\n\t\t\t\t\t\t\t\t// For post-v2.9.0 `JSON.reviveWrapper()`.\n\t\t\t\t\t\t\t\tif (Array.isArray(value[1])) {\n\t\t\t\t\t\t\t\t\tvar $ReviveData$ = value[1][1]; // eslint-disable-line no-unused-vars\n\t\t\t\t\t\t\t\t\tvalue = eval(value[1][0]);\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// For regular expressions, functions, and pre-v2.9.0 `JSON.reviveWrapper()`.\n\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\tvalue = eval(value[1]);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t/* eslint-enable no-eval */\n\t\t\t\t\t\t\t} catch (ex) {/* no-op; although, perhaps, it would be better to throw an error here */}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* legacy */\n\t\t\t\telse if (typeof value === 'string' && value.slice(0, 10) === '@@revive@@') {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tvalue = eval(value.slice(10)); // eslint-disable-line no-eval\n\t\t\t\t\t\t} catch (ex) {/* no-op; although, perhaps, it would be better to throw an error here */}\n\t\t\t\t\t}\n\t\t\t\t/* /legacy */\n\n\t\t\t\t/*\n    \tCall the custom reviver, if specified.\n    */\n\t\t\t\tif (typeof reviver === 'function') {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tvalue = reviver(key, value);\n\t\t\t\t\t} catch (ex) {/* no-op; although, perhaps, it would be better to throw an error here */}\n\t\t\t\t}\n\n\t\t\t\treturn value;\n\t\t\t});\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tExtensions, Deprecated.\n *******************************************************************************************************************/\n\t/*\n \t[DEPRECATED] Returns whether the given element was found within the array.\n */\n\tObject.defineProperty(Array.prototype, 'contains', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needle [, fromIndex] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.contains called on null or undefined');\n\t\t\t}\n\n\t\t\treturn Array.prototype.includes.apply(this, arguments);\n\t\t}\n\t});\n\n\t/*\n \t[DEPRECATED] Returns whether all of the given elements were found within the array.\n */\n\tObject.defineProperty(Array.prototype, 'containsAll', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needle [, fromIndex] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.containsAll called on null or undefined');\n\t\t\t}\n\n\t\t\treturn Array.prototype.includesAll.apply(this, arguments);\n\t\t}\n\t});\n\n\t/*\n \t[DEPRECATED] Returns whether any of the given elements were found within the array.\n */\n\tObject.defineProperty(Array.prototype, 'containsAny', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() /* needle [, fromIndex] */{\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.containsAny called on null or undefined');\n\t\t\t}\n\n\t\t\treturn Array.prototype.includesAny.apply(this, arguments);\n\t\t}\n\t});\n\n\t/*\n \t[DEPRECATED] Returns a new array consisting of the flattened source array.\n */\n\tObject.defineProperty(Array.prototype, 'flatten', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('Array.prototype.flatten called on null or undefined');\n\t\t\t}\n\n\t\t\treturn Array.prototype.flat.call(this, Infinity);\n\t\t}\n\t});\n\n\t/*\n \t[DEPRECATED] Returns an array of link titles, parsed from the string.\n \t\tNOTE: Unused in SugarCube, only included for compatibility.\n */\n\tObject.defineProperty(String.prototype, 'readBracketedList', {\n\t\tconfigurable: true,\n\t\twritable: true,\n\n\t\tvalue: function value() {\n\t\t\tif (this == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('String.prototype.readBracketedList called on null or undefined');\n\t\t\t}\n\n\t\t\t// RegExp groups: Double-square-bracket quoted | Unquoted.\n\t\t\tvar re = new RegExp('(?:\\\\[\\\\[((?:\\\\s|\\\\S)*?)\\\\]\\\\])|([^\"\\'\\\\s]\\\\S*)', 'gm');\n\t\t\tvar names = [];\n\t\t\tvar match = void 0;\n\n\t\t\twhile ((match = re.exec(this)) !== null) {\n\t\t\t\tif (match[1]) {\n\t\t\t\t\t// double-square-bracket quoted\n\t\t\t\t\tnames.push(match[1]);\n\t\t\t\t} else if (match[2]) {\n\t\t\t\t\t// unquoted\n\t\t\t\t\tnames.push(match[2]);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn names;\n\t\t}\n\t});\n})();\n\n/***********************************************************************************************************************\n\n\tlib/browser.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\nvar Browser = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/* eslint-disable max-len */\n\n\tvar userAgent = navigator.userAgent.toLowerCase();\n\n\tvar winPhone = userAgent.includes('windows phone');\n\tvar isMobile = Object.freeze({\n\t\tAndroid: !winPhone && userAgent.includes('android'),\n\t\tBlackBerry: /blackberry|bb10/.test(userAgent),\n\t\tiOS: !winPhone && /ip(?:hone|ad|od)/.test(userAgent),\n\t\tWindows: winPhone || userAgent.includes('iemobile'),\n\n\t\tany: function any() {\n\t\t\treturn isMobile.Android || isMobile.BlackBerry || isMobile.iOS || isMobile.Windows;\n\t\t}\n\t});\n\n\tvar isGecko = !isMobile.Windows && !/khtml|trident|edge/.test(userAgent) && userAgent.includes('gecko');\n\n\tvar isIE = !userAgent.includes('opera') && /msie|trident/.test(userAgent);\n\tvar ieVersion = isIE ? function () {\n\t\tvar ver = /(?:msie\\s+|rv:)(\\d+\\.\\d)/.exec(userAgent);\n\t\treturn ver ? Number(ver[1]) : 0;\n\t}() : null;\n\n\t// opera <= 12: \"opera/9.80 (windows nt 6.1; wow64) presto/2.12.388 version/12.16\"\n\t// opera >= 15: \"mozilla/5.0 (windows nt 6.1; wow64) applewebkit/537.36 (khtml, like gecko) chrome/28.0.1500.52 safari/537.36 opr/15.0.1147.130\"\n\tvar isOpera = userAgent.includes('opera') || userAgent.includes(' opr/');\n\tvar operaVersion = isOpera ? function () {\n\t\tvar re = new RegExp((/khtml|chrome/.test(userAgent) ? 'opr' : 'version') + '\\\\/(\\\\d+\\\\.\\\\d+)');\n\t\tvar ver = re.exec(userAgent);\n\t\treturn ver ? Number(ver[1]) : 0;\n\t}() : null;\n\n\tvar isVivaldi = userAgent.includes('vivaldi');\n\t/* eslint-enable max-len */\n\n\t// Module Exports.\n\treturn Object.freeze({\n\t\tuserAgent: userAgent,\n\t\tisMobile: isMobile,\n\t\tisGecko: isGecko,\n\t\tisIE: isIE,\n\t\tieVersion: ieVersion,\n\t\tisOpera: isOpera,\n\t\toperaVersion: operaVersion,\n\t\tisVivaldi: isVivaldi\n\t});\n}();\n\n/***********************************************************************************************************************\n\n\tlib/has.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Browser */\n\nvar Has = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*\n \tNOTE: The aggressive try/catch feature tests are necessitated by implementation\n \tbugs in various browsers.\n */\n\n\t// Is the `HTMLAudioElement` API available?\n\n\tvar hasAudioElement = function () {\n\t\ttry {\n\t\t\treturn typeof document.createElement('audio').canPlayType === 'function';\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Does the `<HTMLAudioElement>.play()` method return a `Promise`?\n\tvar hasAudioElementPromise = hasAudioElement && function () {\n\t\ttry {\n\t\t\t// We do the test this way to silence \"Uncaught (in promise)\" console errors.\n\t\t\tvar value = document.createElement('audio').play();\n\t\t\tvalue.catch(function () {/* no-op */});\n\t\t\treturn value instanceof Promise;\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Is the `File` API available?\n\tvar hasFile = function () {\n\t\ttry {\n\t\t\treturn 'Blob' in window && 'File' in window && 'FileList' in window && 'FileReader' in window && !Browser.isMobile.any() && (!Browser.isOpera || Browser.operaVersion >= 15);\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Is the `geolocation` API available?\n\tvar hasGeolocation = function () {\n\t\ttry {\n\t\t\treturn 'geolocation' in navigator && typeof navigator.geolocation.getCurrentPosition === 'function' && typeof navigator.geolocation.watchPosition === 'function';\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Is the `MutationObserver` API available?\n\tvar hasMutationObserver = function () {\n\t\ttry {\n\t\t\treturn 'MutationObserver' in window && typeof window.MutationObserver === 'function';\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Is the `performance` API available?\n\tvar hasPerformance = function () {\n\t\ttry {\n\t\t\treturn 'performance' in window && typeof window.performance.now === 'function';\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Is the transition end event available and by what name?\n\tvar hasTransitionEndEvent = function () {\n\t\ttry {\n\t\t\tvar teMap = new Map([['transition', 'transitionend'], ['MSTransition', 'msTransitionEnd'], ['WebkitTransition', 'webkitTransitionEnd'], ['MozTransition', 'transitionend']]);\n\t\t\tvar teKeys = [].concat(_toConsumableArray(teMap.keys()));\n\t\t\tvar el = document.createElement('div');\n\n\t\t\tfor (var i = 0; i < teKeys.length; ++i) {\n\t\t\t\tif (el.style[teKeys[i]] !== undefined) {\n\t\t\t\t\treturn teMap.get(teKeys[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn false;\n\t}();\n\n\t// Module Exports.\n\treturn Object.freeze({\n\t\taudio: hasAudioElement,\n\t\taudioPromise: hasAudioElementPromise,\n\t\tfileAPI: hasFile,\n\t\tgeolocation: hasGeolocation,\n\t\tmutationObserver: hasMutationObserver,\n\t\tperformance: hasPerformance,\n\t\ttransitionEndEvent: hasTransitionEndEvent\n\t});\n}();\n\n/***********************************************************************************************************************\n\n\tlib/visibility.js\n\n\tCopyright © 2018–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\nvar Visibility = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*\n \tThere are two versions of the Page Visibility API: First Edition and, the current,\n \tSecond Edition (i.e. \"Level 2\").  First Edition is mentioned here only because some\n \tolder browsers implement it, rather than the current specification.\n \t\tSEE:\n \t\tSecond Edition : https://www.w3.org/TR/page-visibility/\n \t\tFirst Edition  : https://www.w3.org/TR/2013/REC-page-visibility-20130514/\n \t\tNOTE: Generally, all supported browsers change the visibility state when either switching tabs\n \twithin the browser or minimizing the browser window.  Exceptions are noted below:\n \t\t* IE 9 doesn't support either version of the Page Visibility API.\n \t\t* Opera 12 (Presto) doesn't change the visibility state when the browser is minimized.\n */\n\n\tvar vendor = function () {\n\t\ttry {\n\t\t\treturn Object.freeze([\n\t\t\t// Specification.\n\t\t\t{\n\t\t\t\thiddenProperty: 'hidden', // boolean; historical in 2nd edition\n\t\t\t\tstateProperty: 'visibilityState', // string, values: 'hidden', 'visible'; 1st edition had more values\n\t\t\t\tchangeEvent: 'visibilitychange'\n\t\t\t},\n\n\t\t\t// `webkit` prefixed: old Blink & WebKit.\n\t\t\t{\n\t\t\t\thiddenProperty: 'webkitHidden',\n\t\t\t\tstateProperty: 'webkitVisibilityState',\n\t\t\t\tchangeEvent: 'webkitvisibilitychange'\n\t\t\t},\n\n\t\t\t// `moz` prefixed: old Gecko, maybe Seamonkey.\n\t\t\t{\n\t\t\t\thiddenProperty: 'mozHidden',\n\t\t\t\tstateProperty: 'mozVisibilityState',\n\t\t\t\tchangeEvent: 'mozvisibilitychange'\n\t\t\t},\n\n\t\t\t// `ms` prefixed: IE 10.\n\t\t\t{\n\t\t\t\thiddenProperty: 'msHidden',\n\t\t\t\tstateProperty: 'msVisibilityState',\n\t\t\t\tchangeEvent: 'msvisibilitychange'\n\t\t\t}].find(function (vnd) {\n\t\t\t\treturn vnd.hiddenProperty in document;\n\t\t\t}));\n\t\t} catch (ex) {/* no-op */}\n\n\t\treturn null;\n\t}();\n\n\t/*******************************************************************************************************************\n \tFunctions.\n *******************************************************************************************************************/\n\tfunction visibilityIsHidden() {\n\t\t// return Boolean(vendor && document[vendor.stateProperty] === 'hidden');\n\t\treturn Boolean(vendor && document[vendor.hiddenProperty]); // historical, but probably better for 1st edition\n\t}\n\n\tfunction visibilityState() {\n\t\treturn vendor && document[vendor.stateProperty] || 'visible';\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t// Functions.\n\t\tisHidden: { value: visibilityIsHidden },\n\t\tstate: { value: visibilityState },\n\n\t\t// Properties.\n\t\thiddenProperty: { value: vendor.hiddenProperty },\n\t\tstateProperty: { value: vendor.stateProperty },\n\t\tchangeEvent: { value: vendor.changeEvent }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tlib/helpers.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global L10n, Story, Wikifier */\n\nvar _ref3 = function () {\n\t'use strict';\n\n\t/*\n \tReturns a deep copy of the given object.\n \t\tNOTE:\n \t\t1. `clone()` does not clone functions, however, since function definitions\n \t\t   are immutable, the only issues are with expando properties and scope.\n \t\t   The former really should not be done.  The latter is problematic either\n \t\t   way—damned if you do, damned if you don't.\n \t\t2. `clone()` does not maintain referential relationships—e.g. multiple\n \t\t   references to the same object will, post-cloning, refer to different\n \t\t   equivalent objects; i.e. each reference will receive its own clone\n \t\t   of the original object.\n */\n\n\tfunction clone(orig) {\n\t\t/*\n  \tImmediately return the primitives and functions.\n  */\n\t\tif ((typeof orig === 'undefined' ? 'undefined' : _typeof(orig)) !== 'object' || orig === null) {\n\t\t\treturn orig;\n\t\t}\n\n\t\t/*\n  \tUnbox instances of the primitive exemplar objects.\n  */\n\t\tif (orig instanceof String) {\n\t\t\treturn String(orig);\n\t\t}\n\t\tif (orig instanceof Number) {\n\t\t\treturn Number(orig);\n\t\t}\n\t\tif (orig instanceof Boolean) {\n\t\t\treturn Boolean(orig);\n\t\t}\n\n\t\t/*\n  \tHonor native clone methods.\n  */\n\t\tif (typeof orig.clone === 'function') {\n\t\t\treturn orig.clone(true);\n\t\t}\n\t\tif (orig.nodeType && typeof orig.cloneNode === 'function') {\n\t\t\treturn orig.cloneNode(true);\n\t\t}\n\n\t\t/*\n  \tCreate a copy of the original object.\n  \t\tNOTE: Each non-generic object that we wish to support must be\n  \texplicitly handled below.\n  */\n\t\tvar copy = void 0;\n\n\t\t// Handle instances of the core supported object types.\n\t\tif (orig instanceof Array) {\n\t\t\tcopy = new Array(orig.length);\n\t\t} else if (orig instanceof Date) {\n\t\t\tcopy = new Date(orig.getTime());\n\t\t} else if (orig instanceof Map) {\n\t\t\tcopy = new Map();\n\t\t\torig.forEach(function (val, key) {\n\t\t\t\treturn copy.set(key, clone(val));\n\t\t\t});\n\t\t} else if (orig instanceof RegExp) {\n\t\t\tcopy = new RegExp(orig);\n\t\t} else if (orig instanceof Set) {\n\t\t\tcopy = new Set();\n\t\t\torig.forEach(function (val) {\n\t\t\t\treturn copy.add(clone(val));\n\t\t\t});\n\t\t}\n\n\t\t// Handle instances of unknown or generic objects.\n\t\telse {\n\t\t\t\t// We try to ensure that the returned copy has the same prototype as\n\t\t\t\t// the original, but this will probably produce less than satisfactory\n\t\t\t\t// results on non-generics.\n\t\t\t\tcopy = Object.create(Object.getPrototypeOf(orig));\n\t\t\t}\n\n\t\t/*\n  \tDuplicate the original object's own enumerable properties, which will\n  \tinclude expando properties on non-generic objects.\n  \t\tNOTE: This does not preserve ES5 property attributes.  Neither does\n  \tthe delta coding or serialization code, however, so it's not really\n  \tan issue at the moment.\n  */\n\t\tObject.keys(orig).forEach(function (name) {\n\t\t\treturn copy[name] = clone(orig[name]);\n\t\t});\n\n\t\treturn copy;\n\t}\n\n\t/*\n \tConverts <br> elements to <p> elements within the given node tree.\n */\n\tfunction convertBreaks(source) {\n\t\tvar output = document.createDocumentFragment();\n\t\tvar para = document.createElement('p');\n\t\tvar node = void 0;\n\n\t\twhile ((node = source.firstChild) !== null) {\n\t\t\tif (node.nodeType === Node.ELEMENT_NODE) {\n\t\t\t\tvar tagName = node.nodeName.toUpperCase();\n\n\t\t\t\tswitch (tagName) {\n\t\t\t\t\tcase 'BR':\n\t\t\t\t\t\tif (node.nextSibling !== null && node.nextSibling.nodeType === Node.ELEMENT_NODE && node.nextSibling.nodeName.toUpperCase() === 'BR') {\n\t\t\t\t\t\t\tsource.removeChild(node.nextSibling);\n\t\t\t\t\t\t\tsource.removeChild(node);\n\t\t\t\t\t\t\toutput.appendChild(para);\n\t\t\t\t\t\t\tpara = document.createElement('p');\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t} else if (!para.hasChildNodes()) {\n\t\t\t\t\t\t\tsource.removeChild(node);\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'ADDRESS':\n\t\t\t\t\tcase 'ARTICLE':\n\t\t\t\t\tcase 'ASIDE':\n\t\t\t\t\tcase 'BLOCKQUOTE':\n\t\t\t\t\tcase 'CENTER':\n\t\t\t\t\tcase 'DIV':\n\t\t\t\t\tcase 'DL':\n\t\t\t\t\tcase 'FIGURE':\n\t\t\t\t\tcase 'FOOTER':\n\t\t\t\t\tcase 'FORM':\n\t\t\t\t\tcase 'H1':\n\t\t\t\t\tcase 'H2':\n\t\t\t\t\tcase 'H3':\n\t\t\t\t\tcase 'H4':\n\t\t\t\t\tcase 'H5':\n\t\t\t\t\tcase 'H6':\n\t\t\t\t\tcase 'HEADER':\n\t\t\t\t\tcase 'HR':\n\t\t\t\t\tcase 'MAIN':\n\t\t\t\t\tcase 'NAV':\n\t\t\t\t\tcase 'OL':\n\t\t\t\t\tcase 'P':\n\t\t\t\t\tcase 'PRE':\n\t\t\t\t\tcase 'SECTION':\n\t\t\t\t\tcase 'TABLE':\n\t\t\t\t\tcase 'UL':\n\t\t\t\t\t\tif (para.hasChildNodes()) {\n\t\t\t\t\t\t\toutput.appendChild(para);\n\t\t\t\t\t\t\tpara = document.createElement('p');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\toutput.appendChild(node);\n\t\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tpara.appendChild(node);\n\t\t}\n\n\t\tif (para.hasChildNodes()) {\n\t\t\toutput.appendChild(para);\n\t\t}\n\n\t\tsource.appendChild(output);\n\t}\n\n\t/*\n \tReturns `document.activeElement` or `null`.\n */\n\tfunction safeActiveElement() {\n\t\t/*\n  \tIE9 contains a bug where trying to access the active element of an iframe's\n  \tparent document (i.e. `window.parent.document.activeElement`) will throw an\n  \texception, so we must allow for an exception to be thrown.\n  \t\tWe could simply return `undefined` here, but since the API's default behavior\n  \tshould be to return `document.body` or `null` when there is no selection, we\n  \tchoose to return `null` in all non-element cases (i.e. whether it returns\n  \t`null` or throws an exception).  Just a bit of normalization.\n  */\n\t\ttry {\n\t\t\treturn document.activeElement || null;\n\t\t} catch (ex) {\n\t\t\treturn null;\n\t\t}\n\t}\n\n\t/*\n \tWikifies a passage into a DOM element corresponding to the passed ID and returns the element.\n */\n\tfunction setPageElement(idOrElement, titles, defaultText) {\n\t\tvar el = (typeof idOrElement === 'undefined' ? 'undefined' : _typeof(idOrElement)) === 'object' ? idOrElement : document.getElementById(idOrElement);\n\n\t\tif (el == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn null;\n\t\t}\n\n\t\tvar ids = Array.isArray(titles) ? titles : [titles];\n\n\t\tjQuery(el).empty();\n\n\t\tfor (var i = 0, iend = ids.length; i < iend; ++i) {\n\t\t\tif (Story.has(ids[i])) {\n\t\t\t\tnew Wikifier(el, Story.get(ids[i]).processText().trim());\n\t\t\t\treturn el;\n\t\t\t}\n\t\t}\n\n\t\tif (defaultText != null) {\n\t\t\t// lazy equality for null\n\t\t\tvar text = String(defaultText).trim();\n\n\t\t\tif (text !== '') {\n\t\t\t\tnew Wikifier(el, text);\n\t\t\t}\n\t\t}\n\n\t\treturn el;\n\t}\n\n\t/*\n \tAppends an error view to the passed DOM element.\n */\n\tfunction throwError(place, message, source) {\n\t\tvar $wrapper = jQuery(document.createElement('div'));\n\t\tvar $toggle = jQuery(document.createElement('button'));\n\t\tvar $source = jQuery(document.createElement('pre'));\n\t\tvar mesg = L10n.get('errorTitle') + ': ' + (message || 'unknown error');\n\n\t\t$toggle.addClass('error-toggle').ariaClick({\n\t\t\tlabel: L10n.get('errorToggle')\n\t\t}, function () {\n\t\t\tif ($toggle.hasClass('enabled')) {\n\t\t\t\t$toggle.removeClass('enabled');\n\t\t\t\t$source.attr({\n\t\t\t\t\t'aria-hidden': true,\n\t\t\t\t\thidden: 'hidden'\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\t$toggle.addClass('enabled');\n\t\t\t\t$source.removeAttr('aria-hidden hidden');\n\t\t\t}\n\t\t}).appendTo($wrapper);\n\t\tjQuery(document.createElement('span')).addClass('error').text(mesg).appendTo($wrapper);\n\t\tjQuery(document.createElement('code')).text(source).appendTo($source);\n\t\t$source.addClass('error-source').attr({\n\t\t\t'aria-hidden': true,\n\t\t\thidden: 'hidden'\n\t\t}).appendTo($wrapper);\n\t\t$wrapper.addClass('error-view').appendTo(place);\n\n\t\tconsole.warn(mesg + '\\n\\t' + source.replace(/\\n/g, '\\n\\t'));\n\n\t\treturn false;\n\t}\n\n\t/*\n \tReturns the simple string representation of the passed value or, if there is none,\n \tthe passed default value.\n */\n\tfunction toStringOrDefault(value, defValue) {\n\t\tvar tSOD = toStringOrDefault;\n\n\t\tswitch (typeof value === 'undefined' ? 'undefined' : _typeof(value)) {\n\t\t\tcase 'number':\n\t\t\t\t// TODO: Perhaps NaN should be printed instead?\n\t\t\t\tif (Number.isNaN(value)) {\n\t\t\t\t\treturn defValue;\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase 'object':\n\t\t\t\tif (value === null) {\n\t\t\t\t\treturn defValue;\n\t\t\t\t} else if (Array.isArray(value)) {\n\t\t\t\t\treturn value.map(function (val) {\n\t\t\t\t\t\treturn tSOD(val, defValue);\n\t\t\t\t\t}).join(', ');\n\t\t\t\t} else if (value instanceof Set) {\n\t\t\t\t\treturn [].concat(_toConsumableArray(value)).map(function (val) {\n\t\t\t\t\t\treturn tSOD(val, defValue);\n\t\t\t\t\t}).join(', ');\n\t\t\t\t} else if (value instanceof Map) {\n\t\t\t\t\tvar result = [].concat(_toConsumableArray(value)).map(function (_ref4) {\n\t\t\t\t\t\tvar _ref5 = _slicedToArray(_ref4, 2),\n\t\t\t\t\t\t    key = _ref5[0],\n\t\t\t\t\t\t    val = _ref5[1];\n\n\t\t\t\t\t\treturn tSOD(key, defValue) + ' \\u2192 ' + tSOD(val, defValue);\n\t\t\t\t\t});\n\t\t\t\t\treturn '{\\u202F' + result.join(', ') + '\\u202F}';\n\t\t\t\t} else if (value instanceof Date) {\n\t\t\t\t\treturn value.toLocaleString();\n\t\t\t\t} else if (typeof value.toString === 'function') {\n\t\t\t\t\treturn value.toString();\n\t\t\t\t}\n\t\t\t\treturn Object.prototype.toString.call(value);\n\n\t\t\tcase 'function':\n\t\t\tcase 'undefined':\n\t\t\t\treturn defValue;\n\t\t}\n\n\t\treturn String(value);\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tclone: { value: clone },\n\t\tconvertBreaks: { value: convertBreaks },\n\t\tsafeActiveElement: { value: safeActiveElement },\n\t\tsetPageElement: { value: setPageElement },\n\t\tthrowError: { value: throwError },\n\t\ttoStringOrDefault: { value: toStringOrDefault }\n\t}));\n}(),\n    clone = _ref3.clone,\n    convertBreaks = _ref3.convertBreaks,\n    safeActiveElement = _ref3.safeActiveElement,\n    setPageElement = _ref3.setPageElement,\n    throwError = _ref3.throwError,\n    toStringOrDefault = _ref3.toStringOrDefault;\n\n/***********************************************************************************************************************\n\n\tlib/jquery-plugins.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Wikifier, errorPrologRegExp, safeActiveElement */\n\n/*\n\tWAI-ARIA methods plugin.\n\n\t`<jQuery>.ariaClick([options,] handler)`\n\t    Makes the target element(s) WAI-ARIA compatible clickables.\n\n\t`<jQuery>.ariaDisabled(state)`\n\t    Changes the disabled state of the target WAI-ARIA-compatible clickable element(s).\n\n\t`<jQuery>.ariaIsDisabled()`\n\t    Checks the disabled status of the target WAI-ARIA-compatible clickable element(s).\n*/\n\n\n(function () {\n\t'use strict';\n\n\t/*\n \tEvent handler & utility functions.\n \t\tNOTE: Do not replace the anonymous functions herein with arrow functions.\n */\n\n\tfunction onKeypressFn(ev) {\n\t\t// 13 is Enter/Return, 32 is Space.\n\t\tif (ev.which === 13 || ev.which === 32) {\n\t\t\tev.preventDefault();\n\n\t\t\t// To allow delegation, attempt to trigger the event on `document.activeElement`,\n\t\t\t// if possible, elsewise on `this`.\n\t\t\tjQuery(safeActiveElement() || this).trigger('click');\n\t\t}\n\t}\n\n\tfunction onClickFnWrapper(fn) {\n\t\treturn function () {\n\t\t\tvar $this = jQuery(this);\n\n\t\t\tvar dataPassage = $this.attr('data-passage');\n\t\t\tvar initialDataPassage = window && window.SugarCube && window.SugarCube.State && window.SugarCube.State.passage;\n\t\t\tvar savedYOffset = window.pageYOffset;\n\n\t\t\t// Toggle \"aria-pressed\" status, if the attribute exists.\n\t\t\tif ($this.is('[aria-pressed]')) {\n\t\t\t\t$this.attr('aria-pressed', $this.attr('aria-pressed') === 'true' ? 'false' : 'true');\n\t\t\t}\n\n\t\t\t// Call the true handler.\n\t\t\tfn.apply(this, arguments);\n\n\t\t\tvar doJump = function doJump() {\n\t\t\t\twindow.scrollTo(0, savedYOffset);\n\t\t\t};\n\t\t\tif (dataPassage && (window.lastDataPassageLink === dataPassage || initialDataPassage === dataPassage)) doJump();\n\t\t\twindow.lastDataPassageLink = dataPassage;\n\t\t};\n\t}\n\n\tfunction oneClickFnWrapper(fn) {\n\t\treturn onClickFnWrapper(function () {\n\t\t\t// Remove both event handlers (keypress & click) and the other components.\n\t\t\tjQuery(this).off('.aria-clickable').removeAttr('tabindex aria-controls aria-pressed').not('a,button').removeAttr('role').end().filter('button').prop('disabled', true);\n\n\t\t\t// Call the true handler.\n\t\t\tfn.apply(this, arguments);\n\t\t});\n\t}\n\n\tjQuery.fn.extend({\n\t\t/*\n  \tExtend jQuery's chainable methods with an `ariaClick()` method.\n  */\n\t\tariaClick: function ariaClick(options, handler) {\n\t\t\t// Bail out if there are no target element(s) or parameters.\n\t\t\tif (this.length === 0 || arguments.length === 0) {\n\t\t\t\treturn this;\n\t\t\t}\n\n\t\t\tvar opts = options;\n\t\t\tvar fn = handler;\n\n\t\t\tif (fn == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tfn = opts;\n\t\t\t\topts = undefined;\n\t\t\t}\n\n\t\t\topts = jQuery.extend({\n\t\t\t\tnamespace: undefined,\n\t\t\t\tone: false,\n\t\t\t\tselector: undefined,\n\t\t\t\tdata: undefined,\n\t\t\t\tcontrols: undefined,\n\t\t\t\tpressed: undefined,\n\t\t\t\tlabel: undefined\n\t\t\t}, opts);\n\n\t\t\tif (typeof opts.namespace !== 'string') {\n\t\t\t\topts.namespace = '';\n\t\t\t} else if (opts.namespace[0] !== '.') {\n\t\t\t\topts.namespace = '.' + opts.namespace;\n\t\t\t}\n\n\t\t\tif (typeof opts.pressed === 'boolean') {\n\t\t\t\topts.pressed = opts.pressed ? 'true' : 'false';\n\t\t\t}\n\n\t\t\t// Set `type` to `button` to suppress \"submit\" semantics, for <button> elements.\n\t\t\tthis.filter('button').prop('type', 'button');\n\n\t\t\t// Set `role` to `button`, for non-<a>/-<button> elements.\n\t\t\tthis.not('a,button').attr('role', 'button');\n\n\t\t\t// Set `tabindex` to `0` to make them focusable (unnecessary on <button> elements, but it doesn't hurt).\n\t\t\tthis.attr('tabindex', 0);\n\n\t\t\t// Set `aria-controls`.\n\t\t\tif (opts.controls != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthis.attr('aria-controls', opts.controls);\n\t\t\t}\n\n\t\t\t// Set `aria-pressed`.\n\t\t\tif (opts.pressed != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthis.attr('aria-pressed', opts.pressed);\n\t\t\t}\n\n\t\t\t// Set `aria-label` and `title`.\n\t\t\tif (opts.label != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthis.attr({\n\t\t\t\t\t'aria-label': opts.label,\n\t\t\t\t\ttitle: opts.label\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Set the keypress handlers, for non-<button> elements.\n\t\t\t// NOTE: For the single-use case, the click handler will also remove this handler.\n\t\t\tthis.not('button').on('keypress.aria-clickable' + opts.namespace, opts.selector, onKeypressFn);\n\n\t\t\t// Set the click handlers.\n\t\t\t// NOTE: To ensure both handlers are properly removed, `one()` must not be used here.\n\t\t\tthis.on('click.aria-clickable' + opts.namespace, opts.selector, opts.data, opts.one ? oneClickFnWrapper(fn) : onClickFnWrapper(fn));\n\n\t\t\t// Return `this` for further chaining.\n\t\t\treturn this;\n\t\t},\n\n\n\t\t/*\n  \tExtend jQuery's chainable methods with an `ariaDisabled()` method.\n  */\n\t\tariaDisabled: function ariaDisabled(disable) {\n\t\t\t// Bail out if there are no target element(s) or parameters.\n\t\t\tif (this.length === 0 || arguments.length === 0) {\n\t\t\t\treturn this;\n\t\t\t}\n\n\t\t\t/*\n   \tNOTE: We use `<jQuery>.each()` callbacks to invoke the `<Element>.setAttribute()`\n   \tmethods in the following because the `<jQuery>.attr()` method does not allow you\n   \tto set a content attribute without a value, which is recommended for boolean\n   \tcontent attributes by the HTML specification.\n   */\n\n\t\t\tvar $nonDisableable = this.not('button,fieldset,input,menuitem,optgroup,option,select,textarea');\n\t\t\tvar $disableable = this.filter('button,fieldset,input,menuitem,optgroup,option,select,textarea');\n\n\t\t\tif (disable) {\n\t\t\t\t// Add content attributes `disabled` and `aria-disabled`, for non-disableable elements.\n\t\t\t\t$nonDisableable.each(function () {\n\t\t\t\t\tthis.setAttribute('disabled', '');\n\t\t\t\t\tthis.setAttribute('aria-disabled', '');\n\t\t\t\t});\n\n\t\t\t\t// Set IDL attribute `disabled` to `true` and add content attribute `aria-disabled`,\n\t\t\t\t// for disableable elements.\n\t\t\t\t$disableable.each(function () {\n\t\t\t\t\tthis.disabled = true;\n\t\t\t\t\tthis.setAttribute('aria-disabled', '');\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\t// Remove content attributes `disabled` and `aria-disabled`, for non-disableable elements.\n\t\t\t\t$nonDisableable.each(function () {\n\t\t\t\t\tthis.removeAttribute('disabled');\n\t\t\t\t\tthis.removeAttribute('aria-disabled');\n\t\t\t\t});\n\n\t\t\t\t// Set IDL attribute `disabled` to `false` and remove content attribute `aria-disabled`,\n\t\t\t\t// for disableable elements.\n\t\t\t\t$disableable.each(function () {\n\t\t\t\t\tthis.disabled = false;\n\t\t\t\t\tthis.removeAttribute('aria-disabled');\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Return `this` for further chaining.\n\t\t\treturn this;\n\t\t},\n\n\n\t\t/*\n  \tExtend jQuery's chainable methods with an `ariaIsDisabled()` method.\n  */\n\t\tariaIsDisabled: function ariaIsDisabled() {\n\t\t\t// Check content attribute `disabled`.\n\t\t\t//\n\t\t\t// NOTE: We simply check the `disabled` content attribute for all elements\n\t\t\t// since we have to check it for non-disableable elements and it may also\n\t\t\t// be used for disableable elements since their `disabled` IDL attribute\n\t\t\t// is required to reflect the status of their `disabled` content attribute,\n\t\t\t// and vice versa, by the HTML specification.\n\t\t\t// return this.toArray().some(el => el.hasAttribute('disabled'));\n\t\t\treturn this.is('[disabled]');\n\t\t}\n\t});\n})();\n\n/*\n\tWikifier methods plugin.\n\n\t`jQuery.wikiWithOptions(options, sources…)`\n\t    Wikifies the given content source(s), as directed by the given options.\n\n\t`jQuery.wiki(sources…)`\n\t    Wikifies the given content source(s).\n\n\t`<jQuery>.wikiWithOptions(options, sources…)`\n\t    Wikifies the given content source(s) and appends the result to the target\n\t    element(s), as directed by the given options.\n\n\t`<jQuery>.wiki(sources…)`\n\t    Wikifies the given content source(s) and appends the result to the target\n\t    element(s).\n*/\n(function () {\n\t'use strict';\n\n\tjQuery.extend({\n\t\t/*\n  \tExtend jQuery's static methods with a `wikiWithOptions()` method.\n  */\n\t\twikiWithOptions: function wikiWithOptions(options) {\n\t\t\tfor (var _len = arguments.length, sources = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n\t\t\t\tsources[_key - 1] = arguments[_key];\n\t\t\t}\n\n\t\t\t// Bail out, if there are no content sources.\n\t\t\tif (sources.length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Wikify the content sources into a fragment.\n\t\t\tvar frag = document.createDocumentFragment();\n\t\t\tsources.forEach(function (content) {\n\t\t\t\treturn new Wikifier(frag, content, options);\n\t\t\t});\n\n\t\t\t// Gather the text of any error elements within the fragment…\n\t\t\tvar errors = [].concat(_toConsumableArray(frag.querySelectorAll('.error'))).map(function (errEl) {\n\t\t\t\treturn errEl.textContent.replace(errorPrologRegExp, '');\n\t\t\t});\n\n\t\t\t// …and throw an exception, if there were any errors.\n\t\t\tif (errors.length > 0) {\n\t\t\t\tthrow new Error(errors.join('; '));\n\t\t\t}\n\t\t},\n\n\n\t\t/*\n  \tExtend jQuery's static methods with a `wiki()` method.\n  */\n\t\twiki: function wiki() {\n\t\t\tfor (var _len2 = arguments.length, sources = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n\t\t\t\tsources[_key2] = arguments[_key2];\n\t\t\t}\n\n\t\t\tthis.wikiWithOptions.apply(this, [undefined].concat(sources));\n\t\t}\n\t});\n\n\tjQuery.fn.extend({\n\t\t/*\n  \tExtend jQuery's chainable methods with a `wikiWithOptions()` method.\n  */\n\t\twikiWithOptions: function wikiWithOptions(options) {\n\t\t\tfor (var _len3 = arguments.length, sources = Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {\n\t\t\t\tsources[_key3 - 1] = arguments[_key3];\n\t\t\t}\n\n\t\t\t// Bail out if there are no target element(s) or content sources.\n\t\t\tif (this.length === 0 || sources.length === 0) {\n\t\t\t\treturn this;\n\t\t\t}\n\n\t\t\t// Wikify the content sources into a fragment.\n\t\t\tvar frag = document.createDocumentFragment();\n\t\t\tsources.forEach(function (content) {\n\t\t\t\treturn new Wikifier(frag, content, options);\n\t\t\t});\n\n\t\t\t// Append the fragment to the target element(s).\n\t\t\tthis.append(frag);\n\n\t\t\t// Return `this` for further chaining.\n\t\t\treturn this;\n\t\t},\n\n\n\t\t/*\n  \tExtend jQuery's chainable methods with a `wiki()` method.\n  */\n\t\twiki: function wiki() {\n\t\t\tfor (var _len4 = arguments.length, sources = Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {\n\t\t\t\tsources[_key4] = arguments[_key4];\n\t\t\t}\n\n\t\t\treturn this.wikiWithOptions.apply(this, [undefined].concat(sources));\n\t\t}\n\t});\n})();\n\n/***********************************************************************************************************************\n\n\tlib/util.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Has, Scripting */\n\nvar Util = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tType Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns a pseudo-enumeration created from the given array or generic object.\n */\n\n\tfunction utilToEnum(obj) {\n\t\tif (obj instanceof Array) {\n\t\t\treturn Object.freeze(obj.reduce(function (pe, key, i) {\n\t\t\t\tpe[key] = i; // eslint-disable-line no-param-reassign\n\t\t\t\treturn pe;\n\t\t\t}, Object.create(null)));\n\t\t} else if (obj instanceof Object) {\n\t\t\treturn Object.freeze(Object.assign(Object.create(null), obj));\n\t\t}\n\n\t\tthrow new TypeError('Util.toEnum obj parameter must be an array or generic object');\n\t}\n\n\t/*\n \tReturns the value of the `@@toStringTag` property of the given object.\n \t\tNOTE: In ≤ES5, returns the value of the `[[Class]]` internal slot.\n */\n\tfunction utilToStringTag(obj) {\n\t\treturn Object.prototype.toString.call(obj).slice(8, -1);\n\t}\n\n\t/*\n \tReturns the value yielded by `typeof` (for primitives), the `@@toStringTag`\n \tinternal property (for objects), and `'null'` for `null`.\n \t\tNOTE: In ≤ES5, returns the value of the `[[Class]]` internal slot for objects.\n */\n\tfunction utilGetType(obj) {\n\t\tif (obj === null) {\n\t\t\treturn 'null';\n\t\t}\n\n\t\tvar baseType = typeof obj === 'undefined' ? 'undefined' : _typeof(obj);\n\t\treturn baseType === 'object' ? Object.prototype.toString.call(obj).slice(8, -1) : baseType;\n\t}\n\n\t/*\n \tReturns whether the passed value is a finite number or a numeric string which\n \tyields a finite number when parsed.\n */\n\tfunction utilIsNumeric(obj) {\n\t\tvar num = void 0;\n\n\t\tswitch (typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) {\n\t\t\tcase 'number':\n\t\t\t\tnum = obj;\n\t\t\t\tbreak;\n\n\t\t\tcase 'string':\n\t\t\t\tnum = Number(obj);\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\treturn false;\n\t\t}\n\n\t\treturn !Number.isNaN(num) && Number.isFinite(num);\n\t}\n\n\t/*\n \tReturns whether the passed value is a boolean or one of the strings \"true\"\n \tor \"false\".\n */\n\tfunction utilIsBoolean(obj) {\n\t\treturn typeof obj === 'boolean' || typeof obj === 'string' && (obj === 'true' || obj === 'false');\n\t}\n\n\t/*\n \tReturns whether the passed values pass a SameValueZero comparison.\n \t\tSEE: http://ecma-international.org/ecma-262/8.0/#sec-samevaluezero\n */\n\tfunction utilSameValueZero(valA, valB) {\n\t\t/*\n  \tNOTE: This comparison could also be implemented thus:\n  \t\t\t```\n  \t\tvalA === valB ||\n  \t\ttypeof valA === 'number' && typeof valB === 'number' &&\n  \t\tNumber.isNaN(valA) && Number.isNaN(valB)\n  \t\t```\n  \t\tThat's needlessly verbose, however, as `NaN` is the only value in\n  \tthe language which is not reflexive.\n  */\n\t\treturn valA === valB || valA !== valA && valB !== valB;\n\t}\n\n\t/*******************************************************************************************************************\n \tString Encoding Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns a lowercased and hyphen encoded version of the passed string.\n */\n\tfunction utilSlugify(str) {\n\t\treturn String(str).trim().replace(/[^\\w\\s\\u2013\\u2014-]+/g, '').replace(/[_\\s\\u2013\\u2014-]+/g, '-').toLocaleLowerCase();\n\t}\n\n\t/*\n \tReturns an entity encoded version of the passed string.\n \t\tNOTE: Only escapes the five primary special characters and the backquote.\n */\n\tvar _htmlCharsRe = /[&<>\"'`]/g;\n\tvar _hasHtmlCharsRe = new RegExp(_htmlCharsRe.source); // to drop the global flag\n\tvar _htmlCharsMap = Object.freeze({\n\t\t'&': '&amp;',\n\t\t'<': '&lt;',\n\t\t'>': '&gt;',\n\t\t'\"': '&quot;',\n\t\t\"'\": '&#39;',\n\t\t'`': '&#96;'\n\t});\n\n\tfunction utilEscape(str) {\n\t\tif (str == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn '';\n\t\t}\n\n\t\tvar val = String(str);\n\t\treturn val && _hasHtmlCharsRe.test(val) ? val.replace(_htmlCharsRe, function (ch) {\n\t\t\treturn _htmlCharsMap[ch];\n\t\t}) : val;\n\t}\n\n\t/*\n \tReturns a decoded version of the passed entity encoded string.\n \t\tNOTE: The extended replacement set here, in contrast to `utilEscape()`,\n \tis required due to observed stupidity from various sources.\n */\n\tvar _escapedHtmlRe = /&(?:amp|#38|#x26|lt|#60|#x3c|gt|#62|#x3e|quot|#34|#x22|apos|#39|#x27|#96|#x60);/gi;\n\tvar _hasEscapedHtmlRe = new RegExp(_escapedHtmlRe.source, 'i'); // to drop the global flag\n\tvar _escapedHtmlMap = Object.freeze({\n\t\t'&amp;': '&', // ampersand (HTML character entity, XML predefined entity)\n\t\t'&#38;': '&', // ampersand (decimal numeric character reference)\n\t\t'&#x26;': '&', // ampersand (hexadecimal numeric character reference)\n\t\t'&lt;': '<', // less-than (HTML character entity, XML predefined entity)\n\t\t'&#60;': '<', // less-than (decimal numeric character reference)\n\t\t'&#x3c;': '<', // less-than (hexadecimal numeric character reference)\n\t\t'&gt;': '>', // greater-than (HTML character entity, XML predefined entity)\n\t\t'&#62;': '>', // greater-than (decimal numeric character reference)\n\t\t'&#x3e;': '>', // greater-than (hexadecimal numeric character reference)\n\t\t'&quot;': '\"', // double quote (HTML character entity, XML predefined entity)\n\t\t'&#34;': '\"', // double quote (decimal numeric character reference)\n\t\t'&#x22;': '\"', // double quote (hexadecimal numeric character reference)\n\t\t'&apos;': \"'\", // apostrophe (XML predefined entity)\n\t\t'&#39;': \"'\", // apostrophe (decimal numeric character reference)\n\t\t'&#x27;': \"'\", // apostrophe (hexadecimal numeric character reference)\n\t\t'&#96;': '`', // backquote (decimal numeric character reference)\n\t\t'&#x60;': '`' // backquote (hexadecimal numeric character reference)\n\t});\n\n\tfunction utilUnescape(str) {\n\t\tif (str == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn '';\n\t\t}\n\n\t\tvar val = String(str);\n\t\treturn val && _hasEscapedHtmlRe.test(val) ? val.replace(_escapedHtmlRe, function (entity) {\n\t\t\treturn _escapedHtmlMap[entity.toLowerCase()];\n\t\t}) : val;\n\t}\n\n\t/*\n \tReturns an object (`{ char, start, end }`) containing the Unicode character at\n \tposition `pos`, its starting position, and its ending position—surrogate pairs\n \tare properly handled.  If `pos` is out-of-bounds, returns an object containing\n \tthe empty string and start/end positions of `-1`.\n \t\tThis function is necessary because JavaScript strings are sequences of UTF-16\n \tcode units, so surrogate pairs are exposed and thus must be handled.  While the\n \tES6/2015 standard does improve the situation somewhat, it does not alleviate\n \tthe need for this function.\n \t\tNOTE: Returns the individual code units of invalid surrogate pairs as-is.\n \t\tIDEA: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/charAt\n */\n\tfunction utilCharAndPosAt(text, position) {\n\t\tvar str = String(text);\n\t\tvar pos = Math.trunc(position);\n\t\tvar code = str.charCodeAt(pos);\n\n\t\t// Given position was out-of-bounds.\n\t\tif (Number.isNaN(code)) {\n\t\t\treturn { char: '', start: -1, end: -1 };\n\t\t}\n\n\t\tvar retval = {\n\t\t\tchar: str.charAt(pos),\n\t\t\tstart: pos,\n\t\t\tend: pos\n\t\t};\n\n\t\t// Code unit is not a UTF-16 surrogate.\n\t\tif (code < 0xD800 || code > 0xDFFF) {\n\t\t\treturn retval;\n\t\t}\n\n\t\t// Code unit is a high surrogate (D800–DBFF).\n\t\tif (code >= 0xD800 && code <= 0xDBFF) {\n\t\t\tvar nextPos = pos + 1;\n\n\t\t\t// End of string.\n\t\t\tif (nextPos >= str.length) {\n\t\t\t\treturn retval;\n\t\t\t}\n\n\t\t\tvar nextCode = str.charCodeAt(nextPos);\n\n\t\t\t// Next code unit is not a low surrogate (DC00–DFFF).\n\t\t\tif (nextCode < 0xDC00 || nextCode > 0xDFFF) {\n\t\t\t\treturn retval;\n\t\t\t}\n\n\t\t\tretval.char = retval.char + str.charAt(nextPos);\n\t\t\tretval.end = nextPos;\n\t\t\treturn retval;\n\t\t}\n\n\t\t// Code unit is a low surrogate (DC00–DFFF) in the first position.\n\t\tif (pos === 0) {\n\t\t\treturn retval;\n\t\t}\n\n\t\tvar prevPos = pos - 1;\n\t\tvar prevCode = str.charCodeAt(prevPos);\n\n\t\t// Previous code unit is not a high surrogate (D800–DBFF).\n\t\tif (prevCode < 0xD800 || prevCode > 0xDBFF) {\n\t\t\treturn retval;\n\t\t}\n\n\t\tretval.char = str.charAt(prevPos) + retval.char;\n\t\tretval.start = prevPos;\n\t\treturn retval;\n\t}\n\n\t/*******************************************************************************************************************\n \tTime Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns the number of milliseconds elapsed since a reference epoch.\n \t\tNOTE: Use the Performance API, if available, elsewise use Date as a\n \tfailover.  The Performance API is preferred for its monotonic clock—\n \tmeaning, it's not subject to the vagaries of timezone changes and leap\n \tperiods, as is Date.\n */\n\tvar _nowSource = Has.performance ? performance : Date;\n\n\tfunction utilNow() {\n\t\treturn _nowSource.now();\n\t}\n\n\t/*******************************************************************************************************************\n \tConversion Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns the number of miliseconds represented by the passed CSS time string.\n */\n\tvar _cssTimeRe = /^([+-]?(?:\\d*\\.)?\\d+)([Mm]?[Ss])$/;\n\n\tfunction utilFromCssTime(cssTime) {\n\t\tvar match = _cssTimeRe.exec(String(cssTime));\n\n\t\tif (match === null) {\n\t\t\tthrow new SyntaxError('invalid time value syntax: \"' + cssTime + '\"');\n\t\t}\n\n\t\tvar msec = Number(match[1]);\n\n\t\tif (match[2].length === 1) {\n\t\t\tmsec *= 1000;\n\t\t}\n\n\t\tif (Number.isNaN(msec) || !Number.isFinite(msec)) {\n\t\t\tthrow new RangeError('invalid time value: \"' + cssTime + '\"');\n\t\t}\n\n\t\treturn msec;\n\t}\n\n\t/*\n \tReturns the CSS time string represented by the passed number of milliseconds.\n */\n\tfunction utilToCssTime(msec) {\n\t\tif (typeof msec !== 'number' || Number.isNaN(msec) || !Number.isFinite(msec)) {\n\t\t\tvar what = void 0;\n\n\t\t\tswitch (typeof msec === 'undefined' ? 'undefined' : _typeof(msec)) {\n\t\t\t\tcase 'string':\n\t\t\t\t\twhat = '\"' + msec + '\"';\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'number':\n\t\t\t\t\twhat = String(msec);\n\t\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\twhat = utilToStringTag(msec);\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tthrow new Error('invalid milliseconds: ' + what);\n\t\t}\n\n\t\treturn msec + 'ms';\n\t}\n\n\t/*\n \tReturns the DOM property name represented by the passed CSS property name.\n */\n\tfunction utilFromCssProperty(cssName) {\n\t\tif (!cssName.includes('-')) {\n\t\t\tswitch (cssName) {\n\t\t\t\tcase 'bgcolor':\n\t\t\t\t\treturn 'backgroundColor';\n\t\t\t\tcase 'float':\n\t\t\t\t\treturn 'cssFloat';\n\t\t\t\tdefault:\n\t\t\t\t\treturn cssName;\n\t\t\t}\n\t\t}\n\n\t\t// Strip the leading hyphen from the `-ms-` vendor prefix, so it stays lowercased.\n\t\tvar normalized = cssName.slice(0, 4) === '-ms-' ? cssName.slice(1) : cssName;\n\n\t\treturn normalized.split('-').map(function (part, i) {\n\t\t\treturn i === 0 ? part : part.toUpperFirst();\n\t\t}).join('');\n\t}\n\n\t/*\n \tReturns an object containing the component properties parsed from the passed URL.\n */\n\tfunction utilParseUrl(url) {\n\t\tvar el = document.createElement('a');\n\t\tvar queryObj = Object.create(null);\n\n\t\t// Let the `<a>` element parse the URL.\n\t\tel.href = url;\n\n\t\t// Populate the `queryObj` object with the query string attributes.\n\t\tif (el.search) {\n\t\t\tel.search.replace(/^\\?/, '').splitOrEmpty(/(?:&(?:amp;)?|;)/).forEach(function (query) {\n\t\t\t\tvar _query$split = query.split('='),\n\t\t\t\t    _query$split2 = _slicedToArray(_query$split, 2),\n\t\t\t\t    key = _query$split2[0],\n\t\t\t\t    value = _query$split2[1];\n\n\t\t\t\tqueryObj[key] = value;\n\t\t\t});\n\t\t}\n\n\t\t/*\n  \tCaveats by browser:\n  \t\tEdge and Internet Explorer (≥8) do not support authentication\n  \t\tinformation within a URL at all and will throw a security exception\n  \t\ton *any* property access if it's included.\n  \t\t\tInternet Explorer does not include the leading forward slash on\n  \t\t`pathname` when required.\n  \t\t\tOpera (Presto) strips the authentication information from `href`\n  \t\tand does not supply `username` or `password`.\n  \t\t\tSafari (ca. v5.1.x) does not supply `username` or `password` and\n  \t\tpeforms URI decoding on `pathname`.\n  */\n\n\t\t// Patch for IE not including the leading slash on `pathname` when required.\n\t\tvar pathname = el.host && el.pathname[0] !== '/' ? '/' + el.pathname : el.pathname;\n\n\t\treturn {\n\t\t\t// The full URL that was originally parsed.\n\t\t\thref: el.href,\n\n\t\t\t// The request protocol, lowercased.\n\t\t\tprotocol: el.protocol,\n\n\t\t\t// // The full authentication information.\n\t\t\t// auth : el.username || el.password // eslint-disable-line no-nested-ternary\n\t\t\t// \t? `${el.username}:${el.password}`\n\t\t\t// \t: typeof el.username === 'string' ? '' : undefined,\n\t\t\t//\n\t\t\t// // The username portion of the auth info.\n\t\t\t// username : el.username,\n\t\t\t//\n\t\t\t// // The password portion of the auth info.\n\t\t\t// password : el.password,\n\n\t\t\t// The full host information, including port number, lowercased.\n\t\t\thost: el.host,\n\n\t\t\t// The hostname portion of the host info, lowercased.\n\t\t\thostname: el.hostname,\n\n\t\t\t// The port number portion of the host info.\n\t\t\tport: el.port,\n\n\t\t\t// The full path information, including query info.\n\t\t\tpath: '' + pathname + el.search,\n\n\t\t\t// The pathname portion of the path info.\n\t\t\tpathname: pathname,\n\n\t\t\t// The query string portion of the path info, including the leading question mark.\n\t\t\tquery: el.search,\n\t\t\tsearch: el.search,\n\n\t\t\t// The attributes portion of the query string, parsed into an object.\n\t\t\tqueries: queryObj,\n\t\t\tsearches: queryObj,\n\n\t\t\t// The fragment string, including the leading hash/pound sign.\n\t\t\thash: el.hash\n\t\t};\n\t}\n\n\t/*\n \tReturns a new exception based on the given exception.\n \t\tNOTE: Mostly useful for making a standard JavaScript exception type copy\n \tof a host exception type—e.g. `DOMException` → `Error`.\n */\n\tfunction utilNewExceptionFrom(original, exceptionType, override) {\n\t\tif ((typeof original === 'undefined' ? 'undefined' : _typeof(original)) !== 'object' || original === null) {\n\t\t\tthrow new Error('Util.newExceptionFrom original parameter must be an object');\n\t\t}\n\t\tif (typeof exceptionType !== 'function') {\n\t\t\tthrow new Error('Util.newExceptionFrom exceptionType parameter must be an error type constructor');\n\t\t}\n\n\t\tvar ex = new exceptionType(original.message); // eslint-disable-line new-cap\n\n\t\tif (typeof original.name !== 'undefined') {\n\t\t\tex.name = original.name;\n\t\t}\n\t\tif (typeof original.code !== 'undefined') {\n\t\t\tex.code = original.code;\n\t\t}\n\t\tif (typeof original.columnNumber !== 'undefined') {\n\t\t\tex.columnNumber = original.columnNumber;\n\t\t}\n\t\tif (typeof original.description !== 'undefined') {\n\t\t\tex.description = original.description;\n\t\t}\n\t\tif (typeof original.fileName !== 'undefined') {\n\t\t\tex.fileName = original.fileName;\n\t\t}\n\t\tif (typeof original.lineNumber !== 'undefined') {\n\t\t\tex.lineNumber = original.lineNumber;\n\t\t}\n\t\tif (typeof original.number !== 'undefined') {\n\t\t\tex.number = original.number;\n\t\t}\n\t\tif (typeof original.stack !== 'undefined') {\n\t\t\tex.stack = original.stack;\n\t\t}\n\n\t\tvar overrideType = typeof override === 'undefined' ? 'undefined' : _typeof(override);\n\n\t\tif (overrideType !== 'undefined') {\n\t\t\tif (overrideType === 'object' && override !== null) {\n\t\t\t\tObject.assign(ex, override);\n\t\t\t} else if (overrideType === 'string') {\n\t\t\t\tex.message = override;\n\t\t\t} else {\n\t\t\t\tthrow new Error('Util.newExceptionFrom override parameter must be an object or string');\n\t\t\t}\n\t\t}\n\n\t\treturn ex;\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tType Functions.\n  */\n\t\ttoEnum: { value: utilToEnum },\n\t\ttoStringTag: { value: utilToStringTag },\n\t\tgetType: { value: utilGetType },\n\t\tisNumeric: { value: utilIsNumeric },\n\t\tisBoolean: { value: utilIsBoolean },\n\t\tsameValueZero: { value: utilSameValueZero },\n\n\t\t/*\n  \tString Encoding Functions.\n  */\n\t\tslugify: { value: utilSlugify },\n\t\tescape: { value: utilEscape },\n\t\tunescape: { value: utilUnescape },\n\t\tcharAndPosAt: { value: utilCharAndPosAt },\n\n\t\t/*\n  \tConversion Functions.\n  */\n\t\tfromCssTime: { value: utilFromCssTime },\n\t\ttoCssTime: { value: utilToCssTime },\n\t\tfromCssProperty: { value: utilFromCssProperty },\n\t\tparseUrl: { value: utilParseUrl },\n\t\tnewExceptionFrom: { value: utilNewExceptionFrom },\n\n\t\t/*\n  \tTime Functions.\n  */\n\t\tnow: { value: utilNow },\n\n\t\t/*\n  \tLegacy Aliases.\n  */\n\t\trandom: { value: Math.random },\n\t\tentityEncode: { value: utilEscape },\n\t\tentityDecode: { value: utilUnescape },\n\t\tevalExpression: { value: function value() {\n\t\t\t\treturn Scripting.evalJavaScript.apply(Scripting, arguments);\n\t\t\t} }, // SEE: `markup/scripting.js`.\n\t\tevalStatements: { value: function value() {\n\t\t\t\treturn Scripting.evalJavaScript.apply(Scripting, arguments);\n\t\t\t} // SEE: `markup/scripting.js`.\n\t\t} }));\n}();\n\n/***********************************************************************************************************************\n\n\tlib/simplestore/simplestore.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\nvar SimpleStore = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// In-order list of database adapters.\n\n\tvar _adapters = [];\n\n\t// The initialized adapter.\n\tvar _initialized = null;\n\n\t/*******************************************************************************************************************\n \tSimpleStore Functions.\n *******************************************************************************************************************/\n\tfunction storeCreate(storageId, persistent) {\n\t\tif (_initialized) {\n\t\t\treturn _initialized.create(storageId, persistent);\n\t\t}\n\n\t\t// Return the first adapter which successfully initializes, elsewise throw an exception.\n\t\tfor (var i = 0; i < _adapters.length; ++i) {\n\t\t\tif (_adapters[i].init(storageId, persistent)) {\n\t\t\t\t_initialized = _adapters[i];\n\t\t\t\treturn _initialized.create(storageId, persistent);\n\t\t\t}\n\t\t}\n\n\t\tthrow new Error('no valid storage adapters found');\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tAdapters List.\n  \t\tTODO: This should probably have a getter, rather than being exported directly.\n  */\n\t\tadapters: { value: _adapters },\n\n\t\t/*\n  \tCore Functions.\n  */\n\t\tcreate: { value: storeCreate }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tlib/simplestore/adapters/webstorage.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global SimpleStore, Util */\n\nSimpleStore.adapters.push(function () {\n\t'use strict';\n\n\t// Adapter readiness state.\n\n\tvar _ok = false;\n\n\t/*******************************************************************************************************************\n \t_WebStorageAdapter Class.\n *******************************************************************************************************************/\n\n\tvar _WebStorageAdapter = function () {\n\t\tfunction _WebStorageAdapter(storageId, persistent) {\n\t\t\t_classCallCheck(this, _WebStorageAdapter);\n\n\t\t\tvar prefix = storageId + '.';\n\t\t\tvar engine = null;\n\t\t\tvar name = null;\n\n\t\t\tif (persistent) {\n\t\t\t\tengine = window.localStorage;\n\t\t\t\tname = 'localStorage';\n\t\t\t} else {\n\t\t\t\tengine = window.sessionStorage;\n\t\t\t\tname = 'sessionStorage';\n\t\t\t}\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\t_engine: {\n\t\t\t\t\tvalue: engine\n\t\t\t\t},\n\n\t\t\t\t_prefix: {\n\t\t\t\t\tvalue: prefix\n\t\t\t\t},\n\n\t\t\t\t_prefixRe: {\n\t\t\t\t\tvalue: new RegExp('^' + RegExp.escape(prefix))\n\t\t\t\t},\n\n\t\t\t\tname: {\n\t\t\t\t\tvalue: name\n\t\t\t\t},\n\n\t\t\t\tid: {\n\t\t\t\t\tvalue: storageId\n\t\t\t\t},\n\n\t\t\t\tpersistent: {\n\t\t\t\t\tvalue: !!persistent\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t/* legacy */\n\n\n\t\t_createClass(_WebStorageAdapter, [{\n\t\t\tkey: 'size',\n\n\t\t\t/* /legacy */\n\n\t\t\tvalue: function size() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.size() : Number]');\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tNOTE: DO NOT do something like `return this._engine.length;` here,\n    \tas that will return the length of the entire store, rather than\n    \tjust our prefixed keys.\n    */\n\t\t\t\treturn this.keys().length;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'keys',\n\t\t\tvalue: function keys() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.keys() : String Array]');\n\t\t\t\t}\n\n\t\t\t\tvar keys = [];\n\n\t\t\t\tfor (var i = 0; i < this._engine.length; ++i) {\n\t\t\t\t\tvar key = this._engine.key(i);\n\n\t\t\t\t\tif (this._prefixRe.test(key)) {\n\t\t\t\t\t\tkeys.push(key.replace(this._prefixRe, ''));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn keys;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'has',\n\t\t\tvalue: function has(key) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.has(key: \"' + key + '\") : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\t// // FIXME: This method should probably check for the key, rather than comparing its value.\n\t\t\t\t// return this._engine.getItem(this._prefix + key) != null; // lazy equality for null\n\n\t\t\t\treturn this._engine.hasOwnProperty(this._prefix + key);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'get',\n\t\t\tvalue: function get(key) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.get(key: \"' + key + '\") : Any]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tvar value = this._engine.getItem(this._prefix + key);\n\n\t\t\t\treturn value == null ? null : _WebStorageAdapter._deserialize(value); // lazy equality for null\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'set',\n\t\t\tvalue: function set(key, value) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.set(key: \"' + key + '\", value: \\u2026) : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tthis._engine.setItem(this._prefix + key, _WebStorageAdapter._serialize(value));\n\t\t\t\t} catch (ex) {\n\t\t\t\t\t/*\n     \tIf the exception is a quota exceeded error, massage it into something\n     \ta bit nicer for the player.\n     \t\tNOTE: Ideally, we could simply do something like checking `ex.code`, but\n     \tit's a non-standard property and not supported in all browsers.  Thus,\n     \twe have to resort to pattern matching the name and message—the latter being\n     \trequired by Opera (Presto).  I hate the parties responsible for this snafu\n     \tso much.\n     */\n\t\t\t\t\tif (/quota.?(?:exceeded|reached)/i.test(ex.name + ex.message)) {\n\t\t\t\t\t\tthrow Util.newExceptionFrom(ex, Error, this.name + ' quota exceeded');\n\t\t\t\t\t}\n\n\t\t\t\t\tthrow ex;\n\t\t\t\t}\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'delete',\n\t\t\tvalue: function _delete(key) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.delete(key: \"' + key + '\") : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tthis._engine.removeItem(this._prefix + key);\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'clear',\n\t\t\tvalue: function clear() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.clear() : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tvar keys = this.keys();\n\n\t\t\t\tfor (var i = 0, iend = keys.length; i < iend; ++i) {\n\t\t\t\t\tif (DEBUG) {\n\t\t\t\t\t\tconsole.log('\\tdeleting key:', keys[i]);\n\t\t\t\t\t}\n\n\t\t\t\t\tthis.delete(keys[i]);\n\t\t\t\t}\n\n\t\t\t\t// return this.keys().forEach(key => {\n\t\t\t\t// \tif (DEBUG) { console.log('\\tdeleting key:', key); }\n\t\t\t\t//\n\t\t\t\t// \tthis.delete(key);\n\t\t\t\t// });\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'length',\n\t\t\tget: function get() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.length : Number]');\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tNOTE: DO NOT do something like `return this._engine.length;` here,\n    \tas that will return the length of the entire store, rather than\n    \tjust our prefixed keys.\n    */\n\t\t\t\treturn this.keys().length;\n\t\t\t}\n\t\t}], [{\n\t\t\tkey: '_serialize',\n\t\t\tvalue: function _serialize(obj) {\n\t\t\t\treturn JSON.stringify(obj);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_deserialize',\n\t\t\tvalue: function _deserialize(str) {\n\t\t\t\treturn JSON.parse(!str || str[0] == \"{\" ? str : LZString.decompressFromUTF16(str));\n\t\t\t}\n\t\t}]);\n\n\t\treturn _WebStorageAdapter;\n\t}();\n\n\t/*******************************************************************************************************************\n \tAdapter Utility Functions.\n *******************************************************************************************************************/\n\n\n\tfunction adapterInit() {\n\t\t// Web Storage feature test.\n\t\tfunction hasWebStorage(storeId) {\n\t\t\ttry {\n\t\t\t\tvar store = window[storeId];\n\t\t\t\tvar tid = '_sc_' + String(Date.now());\n\t\t\t\tstore.setItem(tid, tid);\n\t\t\t\tvar result = store.getItem(tid) === tid;\n\t\t\t\tstore.removeItem(tid);\n\t\t\t\treturn result;\n\t\t\t} catch (ex) {/* no-op */}\n\n\t\t\treturn false;\n\t\t}\n\n\t\t/*\n  \tJust to be safe, we feature test for both `localStorage` and `sessionStorage`,\n  \tas you never know what browser implementation bugs you're going to run into.\n  */\n\t\t_ok = hasWebStorage('localStorage') && hasWebStorage('sessionStorage');\n\n\t\treturn _ok;\n\t}\n\n\tfunction adapterCreate(storageId, persistent) {\n\t\tif (!_ok) {\n\t\t\tthrow new Error('adapter not initialized');\n\t\t}\n\n\t\treturn new _WebStorageAdapter(storageId, persistent);\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tinit: { value: adapterInit },\n\t\tcreate: { value: adapterCreate }\n\t}));\n}());\n\n/***********************************************************************************************************************\n\n\tlib/simplestore/adapters/cookie.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global SimpleStore, Util */\n\nSimpleStore.adapters.push(function () {\n\t'use strict';\n\n\t// Expiry constants.\n\n\tvar _MAX_EXPIRY = 'Tue, 19 Jan 2038 03:14:07 GMT'; // (new Date((Math.pow(2, 31) - 1) * 1000)).toUTCString()\n\tvar _MIN_EXPIRY = 'Thu, 01 Jan 1970 00:00:00 GMT'; // (new Date(0)).toUTCString()\n\n\t// Adapter readiness state.\n\tvar _ok = false;\n\n\t/*******************************************************************************************************************\n \t_CookieAdapter Class.\n *******************************************************************************************************************/\n\n\tvar _CookieAdapter = function () {\n\t\tfunction _CookieAdapter(storageId, persistent) {\n\t\t\t_classCallCheck(this, _CookieAdapter);\n\n\t\t\tvar prefix = '' + storageId + (persistent ? '!' : '*') + '.';\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\t_prefix: {\n\t\t\t\t\tvalue: prefix\n\t\t\t\t},\n\n\t\t\t\t_prefixRe: {\n\t\t\t\t\tvalue: new RegExp('^' + RegExp.escape(prefix))\n\t\t\t\t},\n\n\t\t\t\tname: {\n\t\t\t\t\tvalue: 'cookie'\n\t\t\t\t},\n\n\t\t\t\tid: {\n\t\t\t\t\tvalue: storageId\n\t\t\t\t},\n\n\t\t\t\tpersistent: {\n\t\t\t\t\tvalue: !!persistent\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t/* legacy */\n\n\n\t\t_createClass(_CookieAdapter, [{\n\t\t\tkey: 'size',\n\n\t\t\t/* /legacy */\n\n\t\t\tvalue: function size() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.size() : Number]');\n\t\t\t\t}\n\n\t\t\t\treturn this.keys().length;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'keys',\n\t\t\tvalue: function keys() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.keys() : String Array]');\n\t\t\t\t}\n\n\t\t\t\tif (document.cookie === '') {\n\t\t\t\t\treturn [];\n\t\t\t\t}\n\n\t\t\t\tvar cookies = document.cookie.split(/;\\s*/);\n\t\t\t\tvar keys = [];\n\n\t\t\t\tfor (var i = 0; i < cookies.length; ++i) {\n\t\t\t\t\tvar kvPair = cookies[i].split('=');\n\t\t\t\t\tvar key = decodeURIComponent(kvPair[0]);\n\n\t\t\t\t\tif (this._prefixRe.test(key)) {\n\t\t\t\t\t\t/*\n      \tAll stored values are serialized and an empty string serializes to a non-empty\n      \tstring.  Therefore, receiving an empty string here signifies a deleted value,\n      \tnot a serialized empty string, so we should omit such pairs.\n      */\n\t\t\t\t\t\tvar value = decodeURIComponent(kvPair[1]);\n\n\t\t\t\t\t\tif (value !== '') {\n\t\t\t\t\t\t\tkeys.push(key.replace(this._prefixRe, ''));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn keys;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'has',\n\t\t\tvalue: function has(key) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.has(key: \"' + key + '\") : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\treturn _CookieAdapter._getCookie(this._prefix + key) !== null;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'get',\n\t\t\tvalue: function get(key) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.get(key: \"' + key + '\") : Any]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tvar value = _CookieAdapter._getCookie(this._prefix + key);\n\n\t\t\t\treturn value === null ? null : _CookieAdapter._deserialize(value);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'set',\n\t\t\tvalue: function set(key, value) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.set(key: \"' + key + '\", value: \\u2026) : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tif (typeof key !== 'string' || !key) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\t_CookieAdapter._setCookie(this._prefix + key, _CookieAdapter._serialize(value),\n\n\t\t\t\t\t// An undefined expiry denotes a session cookie.\n\t\t\t\t\tthis.persistent ? _MAX_EXPIRY : undefined);\n\n\t\t\t\t\tif (!this.has(key)) {\n\t\t\t\t\t\tthrow new Error('unknown validation error during set');\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\t// Massage the cookie exception into something a bit nicer for the player.\n\t\t\t\t\tthrow Util.newExceptionFrom(ex, Error, 'cookie error: ' + ex.message);\n\t\t\t\t}\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'delete',\n\t\t\tvalue: function _delete(key) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.delete(key: \"' + key + '\") : Boolean]');\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tAttempting to delete a cookie implies setting it, so we test for its existence\n    \tbeforehand, to avoid creating it in the event that it does not already exist.\n    */\n\t\t\t\tif (typeof key !== 'string' || !key || !this.has(key)) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\t_CookieAdapter._setCookie(this._prefix + key,\n\n\t\t\t\t\t// Use `undefined` as the value.\n\t\t\t\t\tundefined,\n\n\t\t\t\t\t// Use the epoch as the expiry.\n\t\t\t\t\t_MIN_EXPIRY);\n\n\t\t\t\t\tif (this.has(key)) {\n\t\t\t\t\t\tthrow new Error('unknown validation error during delete');\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\t// Massage the cookie exception into something a bit nicer for the player.\n\t\t\t\t\tthrow Util.newExceptionFrom(ex, Error, 'cookie error: ' + ex.message);\n\t\t\t\t}\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'clear',\n\t\t\tvalue: function clear() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.clear() : Boolean]');\n\t\t\t\t}\n\n\t\t\t\tvar keys = this.keys();\n\n\t\t\t\tfor (var i = 0, iend = keys.length; i < iend; ++i) {\n\t\t\t\t\tif (DEBUG) {\n\t\t\t\t\t\tconsole.log('\\tdeleting key:', keys[i]);\n\t\t\t\t\t}\n\n\t\t\t\t\tthis.delete(keys[i]);\n\t\t\t\t}\n\n\t\t\t\t// this.keys().forEach(key => {\n\t\t\t\t// \tif (DEBUG) { console.log('\\tdeleting key:', key); }\n\t\t\t\t//\n\t\t\t\t// \tthis.delete(key);\n\t\t\t\t// });\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'length',\n\t\t\tget: function get() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<SimpleStore:' + this.name + '>.length : Number]');\n\t\t\t\t}\n\n\t\t\t\treturn this.keys().length;\n\t\t\t}\n\t\t}], [{\n\t\t\tkey: '_getCookie',\n\t\t\tvalue: function _getCookie(prefixedKey) {\n\t\t\t\tif (!prefixedKey || document.cookie === '') {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tvar cookies = document.cookie.split(/;\\s*/);\n\n\t\t\t\tfor (var i = 0; i < cookies.length; ++i) {\n\t\t\t\t\tvar kvPair = cookies[i].split('=');\n\t\t\t\t\tvar key = decodeURIComponent(kvPair[0]);\n\n\t\t\t\t\tif (prefixedKey === key) {\n\t\t\t\t\t\tvar value = decodeURIComponent(kvPair[1]);\n\n\t\t\t\t\t\t/*\n      \tAll stored values are serialized and an empty string serializes to a non-empty\n      \tstring.  Therefore, receiving an empty string here signifies a deleted value,\n      \tnot a serialized empty string, so we should yield `null` for such pairs.\n      */\n\t\t\t\t\t\treturn value || null;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_setCookie',\n\t\t\tvalue: function _setCookie(prefixedKey, value, expiry) {\n\t\t\t\tif (!prefixedKey) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tvar payload = encodeURIComponent(prefixedKey) + '=';\n\n\t\t\t\tif (value != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tpayload += encodeURIComponent(value);\n\t\t\t\t}\n\n\t\t\t\tif (expiry != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tpayload += '; expires=' + expiry;\n\t\t\t\t}\n\n\t\t\t\tpayload += '; path=/';\n\t\t\t\tdocument.cookie = payload;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_serialize',\n\t\t\tvalue: function _serialize(obj) {\n\t\t\t\treturn LZString.compressToBase64(JSON.stringify(obj));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_deserialize',\n\t\t\tvalue: function _deserialize(str) {\n\t\t\t\treturn JSON.parse(LZString.decompressFromBase64(str));\n\t\t\t}\n\t\t}]);\n\n\t\treturn _CookieAdapter;\n\t}();\n\n\t/*******************************************************************************************************************\n \tAdapter Utility Functions.\n *******************************************************************************************************************/\n\n\n\tfunction adapterInit(\n\t// Only used for stores updates.\n\tstorageId) {\n\t\t// Cookie feature test.\n\t\ttry {\n\t\t\tvar tid = '_sc_' + String(Date.now());\n\n\t\t\t// We only test a session cookie as that should suffice.\n\t\t\t_CookieAdapter._setCookie(tid, _CookieAdapter._serialize(tid), undefined);\n\t\t\t_ok = _CookieAdapter._deserialize(_CookieAdapter._getCookie(tid)) === tid;\n\t\t\t_CookieAdapter._setCookie(tid, undefined, _MIN_EXPIRY);\n\t\t} catch (ex) {\n\t\t\t_ok = false;\n\t\t}\n\n\t\t/* legacy */\n\t\t// Attempt to update the cookie stores, if necessary.  This should happen only during initialization.\n\t\tif (_ok) {\n\t\t\t_updateCookieStores(storageId);\n\t\t}\n\t\t/* /legacy */\n\n\t\treturn _ok;\n\t}\n\n\tfunction adapterCreate(storageId, persistent) {\n\t\tif (!_ok) {\n\t\t\tthrow new Error('adapter not initialized');\n\t\t}\n\n\t\treturn new _CookieAdapter(storageId, persistent);\n\t}\n\n\t/* legacy */\n\t// Updates old non-segmented cookie stores into segmented stores.\n\tfunction _updateCookieStores(storageId) {\n\t\tif (document.cookie === '') {\n\t\t\treturn;\n\t\t}\n\n\t\tvar oldPrefix = storageId + '.';\n\t\tvar oldPrefixRe = new RegExp('^' + RegExp.escape(oldPrefix));\n\t\tvar persistPrefix = storageId + '!.';\n\t\tvar sessionPrefix = storageId + '*.';\n\t\tvar sessionTestRe = /\\.(?:state|rcWarn)$/;\n\t\tvar cookies = document.cookie.split(/;\\s*/);\n\n\t\tfor (var i = 0; i < cookies.length; ++i) {\n\t\t\tvar kvPair = cookies[i].split('=');\n\t\t\tvar key = decodeURIComponent(kvPair[0]);\n\n\t\t\tif (oldPrefixRe.test(key)) {\n\t\t\t\t/*\n    \tAll stored values are serialized and an empty string serializes to a non-empty\n    \tstring.  Therefore, receiving an empty string here signifies a deleted value,\n    \tnot a serialized empty string, so we should skip processing such pairs.\n    */\n\t\t\t\tvar value = decodeURIComponent(kvPair[1]);\n\n\t\t\t\tif (value !== '') {\n\t\t\t\t\t(function () {\n\t\t\t\t\t\tvar persist = !sessionTestRe.test(key);\n\n\t\t\t\t\t\t// Delete the old k/v pair.\n\t\t\t\t\t\t_CookieAdapter._setCookie(key, undefined, _MIN_EXPIRY);\n\n\t\t\t\t\t\t// Set the new k/v pair.\n\t\t\t\t\t\t_CookieAdapter._setCookie(key.replace(oldPrefixRe, function () {\n\t\t\t\t\t\t\treturn persist ? persistPrefix : sessionPrefix;\n\t\t\t\t\t\t}), value, persist ? _MAX_EXPIRY : undefined);\n\t\t\t\t\t})();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t/* /legacy */\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tinit: { value: adapterInit },\n\t\tcreate: { value: adapterCreate }\n\t}));\n}());\n\n/***********************************************************************************************************************\n\n\tlib/debugview.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\tTODO: Make this use jQuery throughout.\n*/\nvar DebugView = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tDebugView Class.\n *******************************************************************************************************************/\n\n\tvar DebugView = function () {\n\t\tfunction DebugView(parent, type, name, title) {\n\t\t\t_classCallCheck(this, DebugView);\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\tparent: {\n\t\t\t\t\tvalue: parent\n\t\t\t\t},\n\n\t\t\t\tview: {\n\t\t\t\t\tvalue: document.createElement('span')\n\t\t\t\t},\n\n\t\t\t\tbreak: {\n\t\t\t\t\tvalue: document.createElement('wbr')\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// Set up the wrapper (`<span>`) element.\n\t\t\tjQuery(this.view).attr({\n\t\t\t\ttitle: title,\n\t\t\t\t'aria-label': title,\n\t\t\t\t'data-type': type != null ? type : '', // lazy equality for null\n\t\t\t\t'data-name': name != null ? name : '' // lazy equality for null\n\t\t\t}).addClass('debug');\n\n\t\t\t// Set up the word break (`<wbr>`) element.\n\t\t\tjQuery(this.break).addClass('debug hidden');\n\n\t\t\t// Add the wrapper (`<span>`) and word break (`<wbr>`) elements to the `parent` element.\n\t\t\tthis.parent.appendChild(this.view);\n\t\t\tthis.parent.appendChild(this.break);\n\t\t}\n\n\t\t_createClass(DebugView, [{\n\t\t\tkey: 'append',\n\t\t\tvalue: function append(el) {\n\t\t\t\tjQuery(this.view).append(el);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'modes',\n\t\t\tvalue: function modes(options) {\n\t\t\t\tif (options == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar current = {};\n\n\t\t\t\t\tthis.view.className.splitOrEmpty(/\\s+/).forEach(function (name) {\n\t\t\t\t\t\tif (name !== 'debug') {\n\t\t\t\t\t\t\tcurrent[name] = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t\t\t\treturn current;\n\t\t\t\t} else if ((typeof options === 'undefined' ? 'undefined' : _typeof(options)) === 'object') {\n\t\t\t\t\tObject.keys(options).forEach(function (name) {\n\t\t\t\t\t\tthis[options[name] ? 'addClass' : 'removeClass'](name);\n\t\t\t\t\t}, jQuery(this.view));\n\n\t\t\t\t\treturn this;\n\t\t\t\t}\n\n\t\t\t\tthrow new Error('DebugView.prototype.modes options parameter must be an object or null/undefined');\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'remove',\n\t\t\tvalue: function remove() {\n\t\t\t\tvar $view = jQuery(this.view);\n\n\t\t\t\tif (this.view.hasChildNodes()) {\n\t\t\t\t\t$view.contents().appendTo(this.parent);\n\t\t\t\t}\n\n\t\t\t\t$view.remove();\n\t\t\t\tjQuery(this.break).remove();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'output',\n\t\t\tget: function get() {\n\t\t\t\treturn this.view;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'type',\n\t\t\tget: function get() {\n\t\t\t\treturn this.view.getAttribute('data-type');\n\t\t\t},\n\t\t\tset: function set(type) {\n\t\t\t\tthis.view.setAttribute('data-type', type != null ? type : ''); // lazy equality for null\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'name',\n\t\t\tget: function get() {\n\t\t\t\treturn this.view.getAttribute('data-name');\n\t\t\t},\n\t\t\tset: function set(name) {\n\t\t\t\tthis.view.setAttribute('data-name', name != null ? name : ''); // lazy equality for null\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'title',\n\t\t\tget: function get() {\n\t\t\t\treturn this.view.title;\n\t\t\t},\n\t\t\tset: function set(title) {\n\t\t\t\tthis.view.title = title;\n\t\t\t}\n\t\t}], [{\n\t\t\tkey: 'isEnabled',\n\t\t\tvalue: function isEnabled() {\n\t\t\t\treturn jQuery(document.documentElement).attr('data-debug-view') === 'enabled';\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'enable',\n\t\t\tvalue: function enable() {\n\t\t\t\tjQuery(document.documentElement).attr('data-debug-view', 'enabled');\n\t\t\t\tjQuery.event.trigger(':debugviewupdate');\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'disable',\n\t\t\tvalue: function disable() {\n\t\t\t\tjQuery(document.documentElement).removeAttr('data-debug-view');\n\t\t\t\tjQuery.event.trigger(':debugviewupdate');\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'toggle',\n\t\t\tvalue: function toggle() {\n\t\t\t\tjQuery(document.documentElement).attr('data-debug-view') === 'enabled' ? DebugView.disable() : DebugView.enable();\n\t\t\t}\n\t\t}]);\n\n\t\treturn DebugView;\n\t}();\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\n\n\treturn DebugView;\n}();\n\n/***********************************************************************************************************************\n\n\tlib/prngwrapper.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\nvar PRNGWrapper = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tPRNGWrapper Class.\n *******************************************************************************************************************/\n\n\tvar PRNGWrapper = function () {\n\t\tfunction PRNGWrapper(seed, useEntropy) {\n\t\t\t_classCallCheck(this, PRNGWrapper);\n\n\t\t\t/* eslint-disable new-cap */\n\t\t\tObject.defineProperties(this, new Math.seedrandom(seed, useEntropy, function (prng, seed) {\n\t\t\t\treturn {\n\t\t\t\t\t_prng: {\n\t\t\t\t\t\tvalue: prng\n\t\t\t\t\t},\n\n\t\t\t\t\tseed: {\n\t\t\t\t\t\t/*\n      \tTODO: Make this non-writable.\n      */\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: seed\n\t\t\t\t\t},\n\n\t\t\t\t\tpull: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: 0\n\t\t\t\t\t},\n\n\t\t\t\t\trandom: {\n\t\t\t\t\t\tvalue: function value() {\n\t\t\t\t\t\t\t++this.pull;\n\t\t\t\t\t\t\treturn this._prng();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t}));\n\t\t\t/* eslint-enable new-cap */\n\t\t}\n\n\t\t_createClass(PRNGWrapper, null, [{\n\t\t\tkey: 'marshal',\n\t\t\tvalue: function marshal(prng) {\n\t\t\t\tif (!prng || !prng.hasOwnProperty('seed') || !prng.hasOwnProperty('pull')) {\n\t\t\t\t\tthrow new Error('PRNG is missing required data');\n\t\t\t\t}\n\n\t\t\t\treturn {\n\t\t\t\t\tseed: prng.seed,\n\t\t\t\t\tpull: prng.pull\n\t\t\t\t};\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'unmarshal',\n\t\t\tvalue: function unmarshal(prngObj) {\n\t\t\t\tif (!prngObj || !prngObj.hasOwnProperty('seed') || !prngObj.hasOwnProperty('pull')) {\n\t\t\t\t\tthrow new Error('PRNG object is missing required data');\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tCreate a new PRNG using the original seed and pull values from it until it\n    \thas reached the original pull count.\n    */\n\t\t\t\tvar prng = new PRNGWrapper(prngObj.seed, false);\n\n\t\t\t\tfor (var i = prngObj.pull; i > 0; --i) {\n\t\t\t\t\tprng.random();\n\t\t\t\t}\n\n\t\t\t\treturn prng;\n\t\t\t}\n\t\t}]);\n\n\t\treturn PRNGWrapper;\n\t}();\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\n\n\treturn PRNGWrapper;\n}();\n\n/***********************************************************************************************************************\n\n\tlib/stylewrapper.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Patterns, Story, Wikifier */\n\nvar StyleWrapper = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\tvar _imageMarkupRe = new RegExp(Patterns.cssImage, 'g');\n\tvar _hasImageMarkupRe = new RegExp(Patterns.cssImage);\n\n\t/*******************************************************************************************************************\n \tStyleWrapper Class.\n *******************************************************************************************************************/\n\n\tvar StyleWrapper = function () {\n\t\tfunction StyleWrapper(style) {\n\t\t\t_classCallCheck(this, StyleWrapper);\n\n\t\t\tif (style == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new TypeError('StyleWrapper style parameter must be an HTMLStyleElement object');\n\t\t\t}\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\tstyle: {\n\t\t\t\t\tvalue: style\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t_createClass(StyleWrapper, [{\n\t\t\tkey: 'isEmpty',\n\t\t\tvalue: function isEmpty() {\n\t\t\t\t// This should work in all supported browsers.\n\t\t\t\treturn this.style.cssRules.length === 0;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'set',\n\t\t\tvalue: function set(rawCss) {\n\t\t\t\tthis.clear();\n\t\t\t\tthis.add(rawCss);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'add',\n\t\t\tvalue: function add(rawCss) {\n\t\t\t\tvar css = rawCss;\n\n\t\t\t\t// Check for wiki image transclusion.\n\t\t\t\tif (_hasImageMarkupRe.test(css)) {\n\t\t\t\t\t/*\n     \tThe JavaScript specifications, since at least ES3, say that `<String>.replace()`\n     \tshould reset a global-flagged regular expression's `lastIndex` property to `0`\n     \tupon invocation.  Buggy browser versions exist, however, which do not reset\n     \t`lastIndex`, so we should do so manually to support those browsers.\n     \t\tNOTE: I do not think this is actually necessary, since `_imageMarkupRe` is\n     \tscoped to this module—meaning users should not be able to access it.  That\n     \tbeing the case, and since we search to exhaustion which should also cause\n     \t`lastIndex` to be reset, there should never be an instance where we invoke\n     \t`css.replace()` and `_imageMarkupRe.lastIndex` is not already `0`.  Still,\n     \tconsidering the other bug, better safe than sorry.\n     */\n\t\t\t\t\t_imageMarkupRe.lastIndex = 0;\n\n\t\t\t\t\tcss = css.replace(_imageMarkupRe, function (wikiImage) {\n\t\t\t\t\t\tvar markup = Wikifier.helpers.parseSquareBracketedMarkup({\n\t\t\t\t\t\t\tsource: wikiImage,\n\t\t\t\t\t\t\tmatchStart: 0\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\tif (markup.hasOwnProperty('error') || markup.pos < wikiImage.length) {\n\t\t\t\t\t\t\treturn wikiImage;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tvar source = markup.source;\n\n\t\t\t\t\t\t// Handle image passage transclusion.\n\t\t\t\t\t\tif (source.slice(0, 5) !== 'data:' && Story.has(source)) {\n\t\t\t\t\t\t\tvar passage = Story.get(source);\n\n\t\t\t\t\t\t\tif (passage.tags.includes('Twine.image')) {\n\t\t\t\t\t\t\t\tsource = passage.text.trim();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/*\n      \tThe source may be URI- or Base64-encoded, so we cannot use `encodeURIComponent()`\n      \there.  Instead, we simply encode any double quotes, since the URI will be\n      \tdelimited by them.\n      */\n\t\t\t\t\t\treturn 'url(\"' + source.replace(/\"/g, '%22') + '\")';\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t// For IE ≤ 10.\n\t\t\t\tif (this.style.styleSheet) {\n\t\t\t\t\tthis.style.styleSheet.cssText += css;\n\t\t\t\t}\n\n\t\t\t\t// For all other browsers (incl. IE ≥ 11).\n\t\t\t\telse {\n\t\t\t\t\t\tthis.style.appendChild(document.createTextNode(css));\n\t\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'clear',\n\t\t\tvalue: function clear() {\n\t\t\t\t// For IE ≤10.\n\t\t\t\tif (this.style.styleSheet) {\n\t\t\t\t\tthis.style.styleSheet.cssText = '';\n\t\t\t\t}\n\n\t\t\t\t// For all other browsers (incl. IE ≥11).\n\t\t\t\telse {\n\t\t\t\t\t\tjQuery(this.style).empty();\n\t\t\t\t\t}\n\t\t\t}\n\t\t}]);\n\n\t\treturn StyleWrapper;\n\t}();\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\n\n\treturn StyleWrapper;\n}();\n\n/***********************************************************************************************************************\n\n\tlib/diff.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Util, clone */\n\nvar Diff = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tDiff Functions.\n *******************************************************************************************************************/\n\t/*\n \tDiff operations object (pseudo-enumeration).\n */\n\n\tvar Op = Util.toEnum({\n\t\tDelete: 0,\n\t\tSpliceArray: 1,\n\t\tCopy: 2,\n\t\tCopyDate: 3\n\t});\n\n\t/*\n \tReturns a difference object generated from comparing the the orig and dest objects.\n */\n\tfunction diff(orig, dest) /* diff object */{\n\t\tvar objToString = Object.prototype.toString;\n\t\tvar origIsArray = orig instanceof Array;\n\t\tvar keys = [].concat(Object.keys(orig), Object.keys(dest)).sort().filter(function (val, i, arr) {\n\t\t\treturn i === 0 || arr[i - 1] !== val;\n\t\t});\n\t\tvar diffed = {};\n\t\tvar aOpRef = void 0;\n\n\t\tvar keyIsAOpRef = function keyIsAOpRef(key) {\n\t\t\treturn key === aOpRef;\n\t\t};\n\n\t\t/* eslint-disable max-depth */\n\t\tfor (var i = 0, klen = keys.length; i < klen; ++i) {\n\t\t\tvar key = keys[i];\n\t\t\tvar origP = orig[key];\n\t\t\tvar destP = dest[key];\n\n\t\t\tif (orig.hasOwnProperty(key)) {\n\t\t\t\t// Key exists in both.\n\t\t\t\tif (dest.hasOwnProperty(key)) {\n\t\t\t\t\t// Values are exactly the same, so do nothing.\n\t\t\t\t\tif (origP === destP) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Values are of the same basic type.\n\t\t\t\t\tif ((typeof origP === 'undefined' ? 'undefined' : _typeof(origP)) === (typeof destP === 'undefined' ? 'undefined' : _typeof(destP))) {\n\t\t\t\t\t\t// eslint-disable-line valid-typeof\n\t\t\t\t\t\t// Values are functions.\n\t\t\t\t\t\tif (typeof origP === 'function') {\n\t\t\t\t\t\t\t/* diffed[key] = [Op.Copy, destP]; */\n\t\t\t\t\t\t\tif (origP.toString() !== destP.toString()) {\n\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, destP];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Values are primitives.\n\t\t\t\t\t\telse if ((typeof origP === 'undefined' ? 'undefined' : _typeof(origP)) !== 'object' || origP === null) {\n\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, destP];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// Values are objects.\n\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\tvar origPType = objToString.call(origP);\n\t\t\t\t\t\t\t\t\tvar destPType = objToString.call(destP);\n\n\t\t\t\t\t\t\t\t\t// Values are objects of the same reported type.\n\t\t\t\t\t\t\t\t\tif (origPType === destPType) {\n\t\t\t\t\t\t\t\t\t\t// Various special cases to handle supported non-generic objects.\n\t\t\t\t\t\t\t\t\t\tif (origP instanceof Date) {\n\t\t\t\t\t\t\t\t\t\t\tif (Number(origP) !== Number(destP)) {\n\t\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, clone(destP)];\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t} else if (origP instanceof Map) {\n\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, clone(destP)];\n\t\t\t\t\t\t\t\t\t\t} else if (origP instanceof RegExp) {\n\t\t\t\t\t\t\t\t\t\t\tif (origP.toString() !== destP.toString()) {\n\t\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, clone(destP)];\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t} else if (origP instanceof Set) {\n\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, clone(destP)];\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t// Unknown non-generic objects (custom or unsupported natives).\n\t\t\t\t\t\t\t\t\t\telse if (origPType !== '[object Object]') {\n\t\t\t\t\t\t\t\t\t\t\t\t// We cannot know how to process these objects,\n\t\t\t\t\t\t\t\t\t\t\t\t// so we simply accept them as-is.\n\t\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, clone(destP)];\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t// Generic objects.\n\t\t\t\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\t\t\t\tvar recurse = diff(origP, destP);\n\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (recurse !== null) {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = recurse;\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t// Values are objects of different reported types.\n\t\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, clone(destP)];\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t// Values are of different types.\n\t\t\t\t\telse {\n\t\t\t\t\t\t\tdiffed[key] = [Op.Copy, (typeof destP === 'undefined' ? 'undefined' : _typeof(destP)) !== 'object' || destP === null ? destP : clone(destP)];\n\t\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// Key only exists in orig.\n\t\t\t\telse {\n\t\t\t\t\t\tif (origIsArray && Util.isNumeric(key)) {\n\t\t\t\t\t\t\tvar nKey = Number(key);\n\n\t\t\t\t\t\t\tif (!aOpRef) {\n\t\t\t\t\t\t\t\taOpRef = '';\n\n\t\t\t\t\t\t\t\tdo {\n\t\t\t\t\t\t\t\t\taOpRef += '~';\n\t\t\t\t\t\t\t\t} while (keys.some(keyIsAOpRef));\n\n\t\t\t\t\t\t\t\tdiffed[aOpRef] = [Op.SpliceArray, nKey, nKey];\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (nKey < diffed[aOpRef][1]) {\n\t\t\t\t\t\t\t\tdiffed[aOpRef][1] = nKey;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (nKey > diffed[aOpRef][2]) {\n\t\t\t\t\t\t\t\tdiffed[aOpRef][2] = nKey;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tdiffed[key] = Op.Delete;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t// Key only exists in dest.\n\t\t\telse {\n\t\t\t\t\tdiffed[key] = [Op.Copy, (typeof destP === 'undefined' ? 'undefined' : _typeof(destP)) !== 'object' || destP === null ? destP : clone(destP)];\n\t\t\t\t}\n\t\t}\n\t\t/* eslint-enable max-depth */\n\n\t\treturn Object.keys(diffed).length > 0 ? diffed : null;\n\t}\n\n\t/*\n \tReturns the object resulting from updating the orig object with the diffed object.\n */\n\tfunction patch(orig, diffed) /* patched object */{\n\t\tvar keys = Object.keys(diffed || {});\n\t\tvar patched = clone(orig);\n\n\t\tfor (var i = 0, klen = keys.length; i < klen; ++i) {\n\t\t\tvar key = keys[i];\n\t\t\tvar diffedP = diffed[key];\n\n\t\t\tif (diffedP === Op.Delete) {\n\t\t\t\tdelete patched[key];\n\t\t\t} else if (diffedP instanceof Array) {\n\t\t\t\tswitch (diffedP[0]) {\n\t\t\t\t\tcase Op.SpliceArray:\n\t\t\t\t\t\tpatched.splice(diffedP[1], 1 + (diffedP[2] - diffedP[1]));\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase Op.Copy:\n\t\t\t\t\t\tpatched[key] = clone(diffedP[1]);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase Op.CopyDate:\n\t\t\t\t\t\tpatched[key] = new Date(diffedP[1]);\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tpatched[key] = patch(patched[key], diffedP);\n\t\t\t}\n\t\t}\n\n\t\treturn patched;\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tOp: { value: Op },\n\t\tdiff: { value: diff },\n\t\tpatch: { value: patch }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tl10n/l10n.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global l10nStrings, strings */\n\nvar L10n = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Replacement pattern regular expressions.\n\n\tvar _patternRe = /\\{\\w+\\}/g;\n\tvar _hasPatternRe = new RegExp(_patternRe.source); // to drop the global flag\n\n\n\t/*******************************************************************************************************************\n \tLocalization Functions.\n *******************************************************************************************************************/\n\tfunction l10nInit() {\n\t\t/* legacy */\n\t\t_mapStringsToL10nStrings();\n\t\t/* /legacy */\n\t}\n\n\t/*******************************************************************************************************************\n \tLocalized String Functions.\n *******************************************************************************************************************/\n\tfunction l10nGet(ids, overrides) {\n\t\tif (!ids) {\n\t\t\treturn '';\n\t\t}\n\n\t\tvar id = function (idList) {\n\t\t\tvar selectedId = void 0;\n\t\t\tidList.some(function (id) {\n\t\t\t\tif (l10nStrings.hasOwnProperty(id)) {\n\t\t\t\t\tselectedId = id;\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\treturn false;\n\t\t\t});\n\t\t\treturn selectedId;\n\t\t}(Array.isArray(ids) ? ids : [ids]);\n\n\t\tif (!id) {\n\t\t\treturn '';\n\t\t}\n\n\t\tvar maxIterations = 50;\n\t\tvar processed = l10nStrings[id];\n\t\tvar iteration = 0;\n\n\t\twhile (_hasPatternRe.test(processed)) {\n\t\t\tif (++iteration > maxIterations) {\n\t\t\t\tthrow new Error('L10n.get exceeded maximum replacement iterations, probable infinite loop');\n\t\t\t}\n\n\t\t\t// Possibly required by some old buggy browsers.\n\t\t\t_patternRe.lastIndex = 0;\n\n\t\t\tprocessed = processed.replace(_patternRe, function (pat) {\n\t\t\t\tvar subId = pat.slice(1, -1);\n\n\t\t\t\tif (overrides && overrides.hasOwnProperty(subId)) {\n\t\t\t\t\treturn overrides[subId];\n\t\t\t\t} else if (l10nStrings.hasOwnProperty(subId)) {\n\t\t\t\t\treturn l10nStrings[subId];\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\treturn processed;\n\t}\n\n\t/*******************************************************************************************************************\n \tLegacy Functions.\n *******************************************************************************************************************/\n\t/*\n \tAttempt to map legacy `strings` object properties to the `l10nStrings` object.\n */\n\tfunction _mapStringsToL10nStrings() {\n\t\tif (strings && Object.keys(strings).length > 0) {\n\t\t\tObject.keys(l10nStrings).forEach(function (id) {\n\t\t\t\ttry {\n\t\t\t\t\tvar value = void 0;\n\n\t\t\t\t\tswitch (id) {\n\t\t\t\t\t\t/*\n      \tGeneral.\n      */\n\t\t\t\t\t\tcase 'identity':\n\t\t\t\t\t\t\tvalue = strings.identity;break;\n\t\t\t\t\t\tcase 'aborting':\n\t\t\t\t\t\t\tvalue = strings.aborting;break;\n\t\t\t\t\t\tcase 'cancel':\n\t\t\t\t\t\t\tvalue = strings.cancel;break;\n\t\t\t\t\t\tcase 'close':\n\t\t\t\t\t\t\tvalue = strings.close;break;\n\t\t\t\t\t\tcase 'ok':\n\t\t\t\t\t\t\tvalue = strings.ok;break;\n\n\t\t\t\t\t\t/*\n      \tErrors.\n      */\n\t\t\t\t\t\tcase 'errorTitle':\n\t\t\t\t\t\t\tvalue = strings.errors.title;break;\n\t\t\t\t\t\tcase 'errorNonexistentPassage':\n\t\t\t\t\t\t\tvalue = strings.errors.nonexistentPassage;break;\n\t\t\t\t\t\tcase 'errorSaveMissingData':\n\t\t\t\t\t\t\tvalue = strings.errors.saveMissingData;break;\n\t\t\t\t\t\tcase 'errorSaveIdMismatch':\n\t\t\t\t\t\t\tvalue = strings.errors.saveIdMismatch;break;\n\n\t\t\t\t\t\t/*\n      \tWarnings.\n      */\n\t\t\t\t\t\tcase 'warningDegraded':\n\t\t\t\t\t\t\tvalue = strings.warnings.degraded;break;\n\n\t\t\t\t\t\t/*\n      \tDebug View.\n      */\n\t\t\t\t\t\tcase 'debugViewTitle':\n\t\t\t\t\t\t\tvalue = strings.debugView.title;break;\n\t\t\t\t\t\tcase 'debugViewToggle':\n\t\t\t\t\t\t\tvalue = strings.debugView.toggle;break;\n\n\t\t\t\t\t\t/*\n      \tUI bar.\n      */\n\t\t\t\t\t\tcase 'uiBarToggle':\n\t\t\t\t\t\t\tvalue = strings.uiBar.toggle;break;\n\t\t\t\t\t\tcase 'uiBarBackward':\n\t\t\t\t\t\t\tvalue = strings.uiBar.backward;break;\n\t\t\t\t\t\tcase 'uiBarForward':\n\t\t\t\t\t\t\tvalue = strings.uiBar.forward;break;\n\t\t\t\t\t\tcase 'uiBarJumpto':\n\t\t\t\t\t\t\tvalue = strings.uiBar.jumpto;break;\n\n\t\t\t\t\t\t/*\n      \tJump To.\n      */\n\t\t\t\t\t\tcase 'jumptoTitle':\n\t\t\t\t\t\t\tvalue = strings.jumpto.title;break;\n\t\t\t\t\t\tcase 'jumptoTurn':\n\t\t\t\t\t\t\tvalue = strings.jumpto.turn;break;\n\t\t\t\t\t\tcase 'jumptoUnavailable':\n\t\t\t\t\t\t\tvalue = strings.jumpto.unavailable;break;\n\n\t\t\t\t\t\t/*\n      \tSaves.\n      */\n\t\t\t\t\t\tcase 'savesTitle':\n\t\t\t\t\t\t\tvalue = strings.saves.title;break;\n\t\t\t\t\t\tcase 'savesDisallowed':\n\t\t\t\t\t\t\tvalue = strings.saves.disallowed;break;\n\t\t\t\t\t\tcase 'savesIncapable':\n\t\t\t\t\t\t\tvalue = strings.saves.incapable;break;\n\t\t\t\t\t\tcase 'savesLabelAuto':\n\t\t\t\t\t\t\tvalue = strings.saves.labelAuto;break;\n\t\t\t\t\t\tcase 'savesLabelDelete':\n\t\t\t\t\t\t\tvalue = strings.saves.labelDelete;break;\n\t\t\t\t\t\tcase 'savesLabelExport':\n\t\t\t\t\t\t\tvalue = strings.saves.labelExport;break;\n\t\t\t\t\t\tcase 'savesLabelImport':\n\t\t\t\t\t\t\tvalue = strings.saves.labelImport;break;\n\t\t\t\t\t\tcase 'savesLabelLoad':\n\t\t\t\t\t\t\tvalue = strings.saves.labelLoad;break;\n\t\t\t\t\t\tcase 'savesLabelClear':\n\t\t\t\t\t\t\tvalue = strings.saves.labelClear;break;\n\t\t\t\t\t\tcase 'savesLabelSave':\n\t\t\t\t\t\t\tvalue = strings.saves.labelSave;break;\n\t\t\t\t\t\tcase 'savesLabelSlot':\n\t\t\t\t\t\t\tvalue = strings.saves.labelSlot;break;\n\t\t\t\t\t\tcase 'savesUnavailable':\n\t\t\t\t\t\t\tvalue = strings.saves.unavailable;break;\n\t\t\t\t\t\tcase 'savesUnknownDate':\n\t\t\t\t\t\t\tvalue = strings.saves.unknownDate;break;\n\n\t\t\t\t\t\t/*\n      \tSettings.\n      */\n\t\t\t\t\t\tcase 'settingsTitle':\n\t\t\t\t\t\t\tvalue = strings.settings.title;break;\n\t\t\t\t\t\tcase 'settingsOff':\n\t\t\t\t\t\t\tvalue = strings.settings.off;break;\n\t\t\t\t\t\tcase 'settingsOn':\n\t\t\t\t\t\t\tvalue = strings.settings.on;break;\n\t\t\t\t\t\tcase 'settingsReset':\n\t\t\t\t\t\t\tvalue = strings.settings.reset;break;\n\n\t\t\t\t\t\t/*\n      \tRestart.\n      */\n\t\t\t\t\t\tcase 'restartTitle':\n\t\t\t\t\t\t\tvalue = strings.restart.title;break;\n\t\t\t\t\t\tcase 'restartPrompt':\n\t\t\t\t\t\t\tvalue = strings.restart.prompt;break;\n\n\t\t\t\t\t\t/*\n      \tShare.\n      */\n\t\t\t\t\t\tcase 'shareTitle':\n\t\t\t\t\t\t\tvalue = strings.share.title;break;\n\n\t\t\t\t\t\t/*\n      \tAlert.\n      */\n\t\t\t\t\t\t/* none */\n\n\t\t\t\t\t\t/*\n      \tAutoload.\n      */\n\t\t\t\t\t\tcase 'autoloadTitle':\n\t\t\t\t\t\t\tvalue = strings.autoload.title;break;\n\t\t\t\t\t\tcase 'autoloadCancel':\n\t\t\t\t\t\t\tvalue = strings.autoload.cancel;break;\n\t\t\t\t\t\tcase 'autoloadOk':\n\t\t\t\t\t\t\tvalue = strings.autoload.ok;break;\n\t\t\t\t\t\tcase 'autoloadPrompt':\n\t\t\t\t\t\t\tvalue = strings.autoload.prompt;break;\n\n\t\t\t\t\t\t/*\n      \tMacros.\n      */\n\t\t\t\t\t\tcase 'macroBackText':\n\t\t\t\t\t\t\tvalue = strings.macros.back.text;break;\n\t\t\t\t\t\tcase 'macroReturnText':\n\t\t\t\t\t\t\tvalue = strings.macros.return.text;break;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (value) {\n\t\t\t\t\t\tl10nStrings[id] = value.replace(/%\\w+%/g, function (pat) {\n\t\t\t\t\t\t\treturn '{' + pat.slice(1, -1) + '}';\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {/* no-op */}\n\t\t\t});\n\t\t}\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tLocalization Functions.\n  */\n\t\tinit: { value: l10nInit },\n\n\t\t/*\n  \tLocalized String Functions.\n  */\n\t\tget: { value: l10nGet }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tl10n/legacy.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\n/*\n\t[DEPRECATED] The `strings` object is deprecated and should no longer be used.\n\tAll new or updated translations should be based upon the `l10nStrings` object\n\t(see: `l10n/strings.js`).\n\n\tLegacy/existing uses of the `strings` object will be mapped to the `l10nStrings`\n\tobject after user script evaluation.\n*/\nvar strings = { // eslint-disable-line no-unused-vars, no-var\n\terrors: {},\n\twarnings: {},\n\tdebugView: {},\n\tuiBar: {},\n\tjumpto: {},\n\tsaves: {},\n\tsettings: {},\n\trestart: {},\n\tshare: {},\n\tautoload: {},\n\tmacros: {\n\t\tback: {},\n\t\treturn: {}\n\t}\n};\n\n/***********************************************************************************************************************\n\n\tl10n/strings.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* eslint-disable max-len, prefer-template */\n\n/*\n\tATTENTION TRANSLATORS\n\n\tThe capitalization and punctuation used within the default replacement strings is\n\tdeliberate, especially within the error and warning strings.  You would do well\n\tto keep your translations similar when possible.\n\n\tReplacement patterns have the format `{NAME}` (e.g. {identity}), where NAME is the\n\tname of a property within either the `l10nStrings` object or, in a few cases, an\n\tobject supplied locally where the string is used—these instances will be commented.\n\n\tBy convention, properties starting with an underscore (e.g. _warningIntroLacking)\n\tare used as templates, only being included within other localized strings.  Feel\n\tfree to add your own if that makes localization easier—e.g. for gender, plurals,\n\tand whatnot.  As an example, the default replacement strings make use of this to\n\thandle various warning intros and outros.\n\n\tIn use, replacement patterns are replaced recursively, so replacement strings may\n\tcontain patterns whose replacements contain other patterns.  Because replacement is\n\trecursive, care must be taken to ensure infinite loops are not created—the system\n\twill detect an infinite loop and throw an error.\n\n\tFOR MORE INFO, SEE: http://www.motoslave.net/sugarcube/2/docs/localization.html\n*/\nvar l10nStrings = { // eslint-disable-line no-unused-vars, no-var\n\t/*\n \tGeneral.\n */\n\tidentity: 'game',\n\taborting: 'Aborting',\n\tcancel: 'Cancel',\n\tclose: 'Close',\n\tok: 'OK',\n\n\t/*\n \tErrors.\n */\n\terrorTitle: 'Error',\n\terrorToggle: 'Toggle the error view',\n\terrorNonexistentPassage: 'the passage \"{passage}\" does not exist', // NOTE: `passage` is supplied locally\n\terrorSaveMissingData: 'save is missing required data. Either the loaded file is not a save or the save has become corrupted',\n\terrorSaveIdMismatch: 'save is from the wrong {identity}',\n\n\t/*\n \tWarnings.\n */\n\t_warningIntroLacking: 'Your browser either lacks or has disabled',\n\t_warningOutroDegraded: ', so this {identity} is running in a degraded mode. You may be able to continue, however, some parts may not work properly.',\n\twarningNoWebStorage: '{_warningIntroLacking} the Web Storage API{_warningOutroDegraded}',\n\twarningDegraded: '{_warningIntroLacking} some of the capabilities required by this {identity}{_warningOutroDegraded}',\n\n\t/*\n \tDebug bar.\n */\n\tdebugBarToggle: 'Toggle the debug bar',\n\tdebugBarNoWatches: '— no watches set —',\n\tdebugBarAddWatch: 'Add watch',\n\tdebugBarDeleteWatch: 'Delete watch',\n\tdebugBarWatchAll: 'Watch all',\n\tdebugBarWatchNone: 'Delete all',\n\tdebugBarLabelAdd: 'Add',\n\tdebugBarLabelWatch: 'Watch',\n\tdebugBarLabelTurn: 'Turn', // as-in: (noun) chance to act (in a game), moment, period\n\tdebugBarLabelViews: 'Views',\n\tdebugBarViewsToggle: 'Toggle the debug views',\n\tdebugBarWatchToggle: 'Toggle the watch panel',\n\n\t/*\n \tUI bar.\n */\n\tuiBarToggle: 'Toggle the UI bar',\n\tuiBarBackward: 'Go backward within the {identity} history',\n\tuiBarForward: 'Go forward within the {identity} history',\n\tuiBarJumpto: 'Jump to a specific point within the {identity} history',\n\n\t/*\n \tJump To.\n */\n\tjumptoTitle: 'Jump To',\n\tjumptoTurn: 'Turn', // as-in: (noun) chance to act (in a game), moment, period\n\tjumptoUnavailable: 'No jump points currently available\\u2026',\n\n\t/*\n \tSaves.\n */\n\tsavesTitle: 'Saves',\n\tsavesDisallowed: 'Saving has been disallowed on this passage.',\n\tsavesIncapable: '{_warningIntroLacking} the capabilities required to support saves, so saves have been disabled for this session.',\n\tsavesLabelAuto: 'Autosave',\n\tsavesLabelDelete: 'Delete',\n\tsavesLabelExport: 'Save to Disk\\u2026',\n\tsavesLabelImport: 'Load from Disk\\u2026',\n\tsavesLabelLoad: 'Load',\n\tsavesLabelClear: 'Delete All',\n\tsavesLabelSave: 'Save',\n\tsavesLabelSlot: 'Slot',\n\tsavesUnavailable: 'No save slots found\\u2026',\n\tsavesUnknownDate: 'unknown',\n\n\t/*\n \tSettings.\n */\n\tsettingsTitle: 'Settings',\n\tsettingsOff: 'Off',\n\tsettingsOn: 'On',\n\tsettingsReset: 'Reset to Defaults',\n\n\t/*\n \tRestart.\n */\n\trestartTitle: 'Restart',\n\trestartPrompt: 'Are you sure that you want to restart? Unsaved progress will be lost.',\n\n\t/*\n \tShare.\n */\n\tshareTitle: 'Share',\n\n\t/*\n \tAlert.\n */\n\t/* none */\n\n\t/*\n \tAutoload.\n */\n\tautoloadTitle: 'Autoload',\n\tautoloadCancel: 'Go to start',\n\tautoloadOk: 'Load autosave',\n\tautoloadPrompt: 'An autosave exists. Load it now or go to the start?',\n\n\t/*\n \tMacros.\n */\n\tmacroBackText: 'Back', // as-in: (verb) rewind, revert\n\tmacroReturnText: 'Return' // as-in: (verb) go/send back\n};\n\n/***********************************************************************************************************************\n\n\tconfig.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Util */\n\nvar Config = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// General settings.\n\n\tvar _debug = false;\n\tvar _addVisitedLinkClass = false;\n\tvar _cleanupWikifierOutput = false;\n\tvar _loadDelay = 0;\n\n\t// Audio settings.\n\tvar _audioPauseOnFadeToZero = true;\n\tvar _audioPreloadMetadata = true;\n\n\t// State history settings.\n\tvar _historyControls = true;\n\tvar _historyMaxStates = 100;\n\n\t// Macros settings.\n\tvar _macrosIfAssignmentError = true;\n\tvar _macrosMaxLoopIterations = 1000;\n\n\t// Navigation settings.\n\tvar _navigationOverride = void 0;\n\n\t// Passages settings.\n\tvar _passagesDescriptions = void 0;\n\tvar _passagesDisplayTitles = false;\n\tvar _passagesNobr = false;\n\tvar _passagesStart = void 0; // set by `Story.load()`\n\tvar _passagesTransitionOut = void 0;\n\n\t// Saves settings.\n\tvar _savesAutoload = void 0;\n\tvar _savesAutosave = void 0;\n\tvar _savesId = 'untitled-story';\n\tvar _savesIsAllowed = void 0;\n\tvar _savesOnLoad = void 0;\n\tvar _savesOnSave = void 0;\n\tvar _savesSlots = 8;\n\tvar _savesVersion = void 0;\n\n\t// UI settings.\n\tvar _uiStowBarInitially = 800;\n\tvar _uiUpdateStoryElements = true;\n\n\t/*******************************************************************************\n \tUtility Functions.\n *******************************************************************************/\n\n\tfunction _throwHistoryModeError() {\n\t\tthrow new Error('Config.history.mode has been deprecated and is no longer used by SugarCube, please remove it from your code');\n\t}\n\n\tfunction _throwHistoryTrackingError() {\n\t\tthrow new Error('Config.history.tracking has been deprecated, use Config.history.maxStates instead');\n\t}\n\n\t/*******************************************************************************\n \tObject Exports.\n *******************************************************************************/\n\n\treturn Object.freeze({\n\t\t/*\n  \tGeneral settings.\n  */\n\t\tget debug() {\n\t\t\treturn _debug;\n\t\t},\n\t\tset debug(value) {\n\t\t\t_debug = Boolean(value);\n\t\t},\n\n\t\tget addVisitedLinkClass() {\n\t\t\treturn _addVisitedLinkClass;\n\t\t},\n\t\tset addVisitedLinkClass(value) {\n\t\t\t_addVisitedLinkClass = Boolean(value);\n\t\t},\n\n\t\tget cleanupWikifierOutput() {\n\t\t\treturn _cleanupWikifierOutput;\n\t\t},\n\t\tset cleanupWikifierOutput(value) {\n\t\t\t_cleanupWikifierOutput = Boolean(value);\n\t\t},\n\n\t\tget loadDelay() {\n\t\t\treturn _loadDelay;\n\t\t},\n\t\tset loadDelay(value) {\n\t\t\tif (!Number.isSafeInteger(value) || value < 0) {\n\t\t\t\tthrow new RangeError('Config.loadDelay must be a non-negative integer');\n\t\t\t}\n\n\t\t\t_loadDelay = value;\n\t\t},\n\n\t\t/*\n  \tAudio settings.\n  */\n\t\taudio: Object.freeze({\n\t\t\tget pauseOnFadeToZero() {\n\t\t\t\treturn _audioPauseOnFadeToZero;\n\t\t\t},\n\t\t\tset pauseOnFadeToZero(value) {\n\t\t\t\t_audioPauseOnFadeToZero = Boolean(value);\n\t\t\t},\n\n\t\t\tget preloadMetadata() {\n\t\t\t\treturn _audioPreloadMetadata;\n\t\t\t},\n\t\t\tset preloadMetadata(value) {\n\t\t\t\t_audioPreloadMetadata = Boolean(value);\n\t\t\t}\n\t\t}),\n\n\t\t/*\n  \tState history settings.\n  */\n\t\thistory: Object.freeze({\n\t\t\tget controls() {\n\t\t\t\treturn _historyControls;\n\t\t\t},\n\t\t\tset controls(value) {\n\t\t\t\t_historyControls = Boolean(value);\n\n\t\t\t\t// Force `Config.history.controls` to `false`, when limited to `1` moment.\n\t\t\t\tif (_historyControls && _historyMaxStates === 1) {\n\t\t\t\t\t_historyControls = false;\n\t\t\t\t\tthrow new Error('Config.history.controls must be false when Config.history.maxStates is 1');\n\t\t\t\t\t// console.warn('Config.history.controls must be false when Config.history.maxStates is 1');\n\t\t\t\t}\n\t\t\t},\n\n\t\t\tget maxStates() {\n\t\t\t\treturn _historyMaxStates;\n\t\t\t},\n\t\t\tset maxStates(value) {\n\t\t\t\tif (!Number.isSafeInteger(value) || value < 0) {\n\t\t\t\t\tthrow new RangeError('Config.history.maxStates must be a non-negative integer');\n\t\t\t\t}\n\n\t\t\t\t_historyMaxStates = value;\n\n\t\t\t\t// Force `Config.history.controls` to `false`, when limited to `1` moment.\n\t\t\t\tif (_historyControls && value === 1) {\n\t\t\t\t\t_historyControls = false;\n\t\t\t\t}\n\t\t\t},\n\n\t\t\t// legacy\n\t\t\t// Die if deprecated state history settings are accessed.\n\t\t\tget mode() {\n\t\t\t\t_throwHistoryModeError();\n\t\t\t},\n\t\t\tset mode(_) {\n\t\t\t\t_throwHistoryModeError();\n\t\t\t},\n\t\t\tget tracking() {\n\t\t\t\t_throwHistoryTrackingError();\n\t\t\t},\n\t\t\tset tracking(_) {\n\t\t\t\t_throwHistoryTrackingError();\n\t\t\t}\n\t\t\t// /legacy\n\t\t}),\n\n\t\t/*\n  \tMacros settings.\n  */\n\t\tmacros: Object.freeze({\n\t\t\tget ifAssignmentError() {\n\t\t\t\treturn _macrosIfAssignmentError;\n\t\t\t},\n\t\t\tset ifAssignmentError(value) {\n\t\t\t\t_macrosIfAssignmentError = Boolean(value);\n\t\t\t},\n\n\t\t\tget maxLoopIterations() {\n\t\t\t\treturn _macrosMaxLoopIterations;\n\t\t\t},\n\t\t\tset maxLoopIterations(value) {\n\t\t\t\tif (!Number.isSafeInteger(value) || value < 0) {\n\t\t\t\t\tthrow new RangeError('Config.macros.maxLoopIterations must be a non-negative integer');\n\t\t\t\t}\n\n\t\t\t\t_macrosMaxLoopIterations = value;\n\t\t\t}\n\t\t}),\n\n\t\t/*\n  \tNavigation settings.\n  */\n\t\tnavigation: Object.freeze({\n\t\t\tget override() {\n\t\t\t\treturn _navigationOverride;\n\t\t\t},\n\t\t\tset override(value) {\n\t\t\t\tif (!(value == null || value instanceof Function)) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Config.navigation.override must be a function or null/undefined (received: ' + Util.getType(value) + ')');\n\t\t\t\t}\n\n\t\t\t\t_navigationOverride = value;\n\t\t\t}\n\t\t}),\n\n\t\t/*\n  \tPassages settings.\n  */\n\t\tpassages: Object.freeze({\n\t\t\tget descriptions() {\n\t\t\t\treturn _passagesDescriptions;\n\t\t\t},\n\t\t\tset descriptions(value) {\n\t\t\t\tif (value != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar valueType = Util.getType(value);\n\n\t\t\t\t\tif (valueType !== 'boolean' && valueType !== 'Object' && valueType !== 'function') {\n\t\t\t\t\t\tthrow new TypeError('Config.passages.descriptions must be a boolean, object, function, or null/undefined (received: ' + valueType + ')');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t_passagesDescriptions = value;\n\t\t\t},\n\n\t\t\tget displayTitles() {\n\t\t\t\treturn _passagesDisplayTitles;\n\t\t\t},\n\t\t\tset displayTitles(value) {\n\t\t\t\t_passagesDisplayTitles = Boolean(value);\n\t\t\t},\n\n\t\t\tget nobr() {\n\t\t\t\treturn _passagesNobr;\n\t\t\t},\n\t\t\tset nobr(value) {\n\t\t\t\t_passagesNobr = Boolean(value);\n\t\t\t},\n\n\t\t\tget start() {\n\t\t\t\treturn _passagesStart;\n\t\t\t},\n\t\t\tset start(value) {\n\t\t\t\tif (value != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar valueType = Util.getType(value);\n\n\t\t\t\t\tif (valueType !== 'string') {\n\t\t\t\t\t\tthrow new TypeError('Config.passages.start must be a string or null/undefined (received: ' + valueType + ')');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t_passagesStart = value;\n\t\t\t},\n\n\t\t\tget transitionOut() {\n\t\t\t\treturn _passagesTransitionOut;\n\t\t\t},\n\t\t\tset transitionOut(value) {\n\t\t\t\tif (value != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar valueType = Util.getType(value);\n\n\t\t\t\t\tif (valueType !== 'string' && (valueType !== 'number' || !Number.isSafeInteger(value) || value < 0)) {\n\t\t\t\t\t\tthrow new TypeError('Config.passages.transitionOut must be a string, non-negative integer, or null/undefined (received: ' + valueType + ')');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t_passagesTransitionOut = value;\n\t\t\t}\n\t\t}),\n\n\t\t/*\n  \tSaves settings.\n  */\n\t\tsaves: Object.freeze({\n\t\t\tget autoload() {\n\t\t\t\treturn _savesAutoload;\n\t\t\t},\n\t\t\tset autoload(value) {\n\t\t\t\tif (value != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar valueType = Util.getType(value);\n\n\t\t\t\t\tif (valueType !== 'boolean' && valueType !== 'string' && valueType !== 'function') {\n\t\t\t\t\t\tthrow new TypeError('Config.saves.autoload must be a boolean, string, function, or null/undefined (received: ' + valueType + ')');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t_savesAutoload = value;\n\t\t\t},\n\n\t\t\tget autosave() {\n\t\t\t\treturn _savesAutosave;\n\t\t\t},\n\t\t\tset autosave(value) {\n\t\t\t\tif (value != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar valueType = Util.getType(value);\n\n\t\t\t\t\tif (valueType !== 'boolean' && valueType !== 'string' && (valueType !== 'Array' || !value.every(function (item) {\n\t\t\t\t\t\treturn typeof item === 'string';\n\t\t\t\t\t}))) {\n\t\t\t\t\t\tthrow new TypeError('Config.saves.autosave must be a boolean, string, Array of strings, or null/undefined (received: ' + valueType + (valueType === 'Array' ? ' of mixed' : '') + ')');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t_savesAutosave = value;\n\t\t\t},\n\n\t\t\tget id() {\n\t\t\t\treturn _savesId;\n\t\t\t},\n\t\t\tset id(value) {\n\t\t\t\tif (typeof value !== 'string' || value === '') {\n\t\t\t\t\tthrow new TypeError('Config.saves.id must be a non-empty string (received: ' + Util.getType(value) + ')');\n\t\t\t\t}\n\n\t\t\t\t_savesId = value;\n\t\t\t},\n\n\t\t\tget isAllowed() {\n\t\t\t\treturn _savesIsAllowed;\n\t\t\t},\n\t\t\tset isAllowed(value) {\n\t\t\t\tif (!(value == null || value instanceof Function)) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Config.saves.isAllowed must be a function or null/undefined (received: ' + Util.getType(value) + ')');\n\t\t\t\t}\n\n\t\t\t\t_savesIsAllowed = value;\n\t\t\t},\n\n\t\t\tget onLoad() {\n\t\t\t\treturn _savesOnLoad;\n\t\t\t},\n\t\t\tset onLoad(value) {\n\t\t\t\tif (!(value == null || value instanceof Function)) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Config.saves.onLoad must be a function or null/undefined (received: ' + Util.getType(value) + ')');\n\t\t\t\t}\n\n\t\t\t\t_savesOnLoad = value;\n\t\t\t},\n\n\t\t\tget onSave() {\n\t\t\t\treturn _savesOnSave;\n\t\t\t},\n\t\t\tset onSave(value) {\n\t\t\t\tif (!(value == null || value instanceof Function)) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('Config.saves.onSave must be a function or null/undefined (received: ' + Util.getType(value) + ')');\n\t\t\t\t}\n\n\t\t\t\t_savesOnSave = value;\n\t\t\t},\n\n\t\t\tget slots() {\n\t\t\t\treturn _savesSlots;\n\t\t\t},\n\t\t\tset slots(value) {\n\t\t\t\tif (!Number.isSafeInteger(value) || value < 0) {\n\t\t\t\t\tthrow new RangeError('Config.saves.slots must be a non-negative integer');\n\t\t\t\t}\n\n\t\t\t\t_savesSlots = value;\n\t\t\t},\n\n\t\t\tget version() {\n\t\t\t\treturn _savesVersion;\n\t\t\t},\n\t\t\tset version(value) {\n\t\t\t\t_savesVersion = value;\n\t\t\t}\n\t\t}),\n\n\t\t/*\n  \tUI settings.\n  */\n\t\tui: Object.freeze({\n\t\t\tget stowBarInitially() {\n\t\t\t\treturn _uiStowBarInitially;\n\t\t\t},\n\t\t\tset stowBarInitially(value) {\n\t\t\t\tvar valueType = Util.getType(value);\n\n\t\t\t\tif (valueType !== 'boolean' && (valueType !== 'number' || !Number.isSafeInteger(value) || value < 0)) {\n\t\t\t\t\tthrow new TypeError('Config.passages.transitionOut must be a boolean or non-negative integer (received: ' + valueType + ')');\n\t\t\t\t}\n\n\t\t\t\t_uiStowBarInitially = value;\n\t\t\t},\n\n\t\t\tget updateStoryElements() {\n\t\t\t\treturn _uiUpdateStoryElements;\n\t\t\t},\n\t\t\tset updateStoryElements(value) {\n\t\t\t\t_uiUpdateStoryElements = Boolean(value);\n\t\t\t}\n\t\t})\n\t});\n}();\n\n/***********************************************************************************************************************\n\n\tsimpleaudio.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Browser, Config, Has, LoadScreen, Story, Util, Visibility, clone */\n\nvar SimpleAudio = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*\n \tEvents that count as user activation—i.e. \"user gestures\", \"activation behavior\".\n \t\tNOTE (ca. Dec, 2018): This not an exhaustive list and varies significantly by browser.\n \tProposals for a specification/standard are still very much in flux at this point.\n \t\tTODO (ca. Dec, 2018): Revisit this topic.\n \t\tSEE: (too many to list)\n \t\thttps://github.com/whatwg/html/issues/3849\n \t\thttps://github.com/whatwg/html/issues/1903\n \t\thttps://html.spec.whatwg.org/#activation\n \t\thttps://docs.google.com/spreadsheets/d/1DGXjhQ6D3yZXIePOMo0dsd2agz0t5W7rYH1NwJ-QGJo/edit#gid=0\n */\n\n\tvar _gestureEventNames = Object.freeze(['click', 'contextmenu', 'dblclick', 'keyup', 'mouseup', 'pointerup', 'touchend']);\n\n\t// Special group IDs.\n\tvar _specialIds = Object.freeze([':not', ':all', ':looped', ':muted', ':paused', ':playing']);\n\n\t// Format specifier regular expression.\n\tvar _formatSpecRe = /^([\\w-]+)\\s*\\|\\s*(\\S.*)$/; // e.g. 'mp3|https://audiohost.tld/id'\n\n\t// ID verification regular expressions.\n\tvar _badIdRe = /[:\\s]/;\n\n\t// Tracks collection.\n\tvar _tracks = new Map();\n\n\t// Groups collection.\n\tvar _groups = new Map();\n\n\t// Playlists collection.\n\tvar _lists = new Map();\n\n\t// Subscriber collection.\n\tvar _subscribers = new Map();\n\n\t// Master playback rate.\n\tvar _masterRate = 1;\n\n\t// Master playback volume.\n\tvar _masterVolume = 1;\n\n\t// Master mute state.\n\tvar _masterMute = false;\n\n\t// Master mute on tab/window visibility state.\n\tvar _masterMuteOnHidden = false;\n\n\t/*******************************************************************************************************************\n \tAudioTrack Class.\n *******************************************************************************************************************/\n\n\tvar AudioTrack = function () {\n\t\tfunction AudioTrack(obj) {\n\t\t\t_classCallCheck(this, AudioTrack);\n\n\t\t\t// Process the given array of sources or AudioTrack object.\n\t\t\tif (obj instanceof Array) {\n\t\t\t\tthis._create(obj);\n\t\t\t} else if (obj instanceof AudioTrack) {\n\t\t\t\tthis._copy(obj);\n\t\t\t} else {\n\t\t\t\tthrow new Error('sources parameter must be either an array, of URIs or source objects, or an AudioTrack instance');\n\t\t\t}\n\t\t}\n\n\t\t_createClass(AudioTrack, [{\n\t\t\tkey: '_create',\n\t\t\tvalue: function _create(sourceList) {\n\t\t\t\tvar dataUriRe = /^data:\\s*audio\\/([^;,]+)\\s*[;,]/i;\n\t\t\t\tvar extRe = /\\.([^./\\\\]+)$/;\n\t\t\t\tvar getType = AudioTrack.getType;\n\t\t\t\tvar usedSources = [];\n\t\t\t\t/*\n    \tHTMLAudioElement: DOM factory method vs. constructor\n    \t\tUse of the DOM factory method, `document.createElement('audio')`, should be\n    \tpreferred over use of the constructor, `new Audio()`.  The reason being that\n    \tobjects created by the latter are, erroneously, treated differently, often\n    \tunfavorably, by certain browser engines—e.g. within some versions of the iOS\n    \tbrowser core.\n    \t\tNotably, the only difference between the two, per the specification, is that\n    \tobjects created via the constructor should have their `preload` property\n    \tautomatically set to 'auto'.  Thus, there's no technical reason to prefer\n    \tusage of the constructor, even discounting buggy browser implementations.\n    */\n\t\t\t\tvar audio = document.createElement('audio');\n\n\t\t\t\t// Initially set the `preload` attribute to `'none'`.\n\t\t\t\taudio.preload = 'none';\n\n\t\t\t\t// Process the array of sources, adding any valid sources to the `usedSources`\n\t\t\t\t// array and to the audio element as source elements.\n\t\t\t\tsourceList.forEach(function (src) {\n\t\t\t\t\tvar srcObj = null;\n\n\t\t\t\t\tswitch (typeof src === 'undefined' ? 'undefined' : _typeof(src)) {\n\t\t\t\t\t\tcase 'string':\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvar match = void 0;\n\n\t\t\t\t\t\t\t\tif (src.slice(0, 5) === 'data:') {\n\t\t\t\t\t\t\t\t\tmatch = dataUriRe.exec(src);\n\n\t\t\t\t\t\t\t\t\tif (match === null) {\n\t\t\t\t\t\t\t\t\t\tthrow new Error('source data URI missing media type');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tmatch = extRe.exec(Util.parseUrl(src).pathname);\n\n\t\t\t\t\t\t\t\t\tif (match === null) {\n\t\t\t\t\t\t\t\t\t\tthrow new Error('source URL missing file extension');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tvar type = getType(match[1]);\n\n\t\t\t\t\t\t\t\tif (type !== null) {\n\t\t\t\t\t\t\t\t\tsrcObj = { src: src, type: type };\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'object':\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (src === null) {\n\t\t\t\t\t\t\t\t\tthrow new Error('source object cannot be null');\n\t\t\t\t\t\t\t\t} else if (!src.hasOwnProperty('src')) {\n\t\t\t\t\t\t\t\t\tthrow new Error('source object missing required \"src\" property');\n\t\t\t\t\t\t\t\t} else if (!src.hasOwnProperty('format')) {\n\t\t\t\t\t\t\t\t\tthrow new Error('source object missing required \"format\" property');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tvar _type = getType(src.format);\n\n\t\t\t\t\t\t\t\tif (_type !== null) {\n\t\t\t\t\t\t\t\t\tsrcObj = { src: src.src, type: _type };\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tthrow new Error('invalid source value (type: ' + (typeof src === 'undefined' ? 'undefined' : _typeof(src)) + ')');\n\t\t\t\t\t}\n\n\t\t\t\t\tif (srcObj !== null) {\n\t\t\t\t\t\t/*\n      \tOpera (Blink; ca. Jul 2017) fails to play audio from some sources\n      \twith MIME-types containing a `codecs` parameter, despite the fact\n      \tthat `canPlayType()` blessed the full MIME-type including `codecs`.\n      \t\tBizarrely, this only affects some MIME-types—e.g. MP3s are affected,\n      \twhile WAVEs are not.\n      \t\tFails: 'audio/mpeg; codecs=\"mp3\"'\n      \t\tPlays: 'audio/mpeg'\n      \t\tPlays: 'audio/wav; codecs=\"1\"'\n      \t\tTo workaround this we remove all parameters from the MIME-type in\n      \tOpera.\n      */\n\t\t\t\t\t\tif (Browser.isOpera) {\n\t\t\t\t\t\t\tsrcObj.type = srcObj.type.replace(/;.*$/, '');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tvar source = document.createElement('source');\n\t\t\t\t\t\tsource.src = srcObj.src;\n\t\t\t\t\t\tsource.type = srcObj.type;\n\t\t\t\t\t\taudio.appendChild(source);\n\t\t\t\t\t\tusedSources.push(srcObj);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tif (audio.hasChildNodes()) {\n\t\t\t\t\t// Set the `preload` attribute to `'metadata'`, unless preloading has been disabled.\n\t\t\t\t\tif (Config.audio.preloadMetadata) {\n\t\t\t\t\t\taudio.preload = 'metadata';\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tthis._finalize(audio, usedSources, clone(sourceList));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_copy',\n\t\t\tvalue: function _copy(obj) {\n\t\t\t\tthis._finalize(obj.audio.cloneNode(true), // deep clone of the audio element & its children\n\t\t\t\tclone(obj.sources), clone(obj.originals));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_finalize',\n\t\t\tvalue: function _finalize(audio, sources, originals) {\n\t\t\t\tvar _this\n\t\t\t\t// NOTE: Do not use an arrow function here.\n\t\t\t\t= this;\n\n\t\t\t\t// Set up our own properties.\n\t\t\t\tObject.defineProperties(this, {\n\t\t\t\t\taudio: {\n\t\t\t\t\t\tconfigurable: true,\n\t\t\t\t\t\tvalue: audio\n\t\t\t\t\t},\n\n\t\t\t\t\tsources: {\n\t\t\t\t\t\tvalue: Object.freeze(sources)\n\t\t\t\t\t},\n\n\t\t\t\t\toriginals: {\n\t\t\t\t\t\tvalue: Object.freeze(originals)\n\t\t\t\t\t},\n\n\t\t\t\t\t_error: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: false\n\t\t\t\t\t},\n\n\t\t\t\t\t_faderId: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: null\n\t\t\t\t\t},\n\n\t\t\t\t\t_mute: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: false\n\t\t\t\t\t},\n\n\t\t\t\t\t_rate: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: 1\n\t\t\t\t\t},\n\n\t\t\t\t\t_volume: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: 1\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\t// Set up event handlers on the audio and source elements.\n\t\t\t\tjQuery(this.audio)\n\t\t\t\t/*\n    \tUpon receiving a `loadstart` event on the audio element, set `_error` to\n    \t`false`.\n    */\n\t\t\t\t.on('loadstart.AudioTrack', function () {\n\t\t\t\t\treturn _this._error = false;\n\t\t\t\t})\n\t\t\t\t/*\n    \tUpon receiving an `error` event on the audio element, set `_error` to\n    \t`true`.\n    \t\tCaveats by browser:\n    \t\tEdge violates the specification by triggering `error` events from source\n    \t\telements on their parent media element, rather than the source element.\n    \t\tTo enable error handling in all browsers, we set the error handler on the\n    \t\taudio element and have the final source element forward its `error` event.\n    \t\t\tIE does not trigger, at least some, `error` events from source elements at\n    \t\tall, not on the source element or its parent media element.  AFAIK, nothing\n    \t\tcan be done about this lossage.\n    */\n\t\t\t\t.on('error.AudioTrack', function () {\n\t\t\t\t\treturn _this._error = true;\n\t\t\t\t})\n\t\t\t\t/*\n    \tUpon receiving an `error` event on the final source element (if any), trigger\n    \tan `error` event on the audio element—that being necessary because the source\n    \t`error` event does not bubble.\n    */\n\t\t\t\t.find('source:last-of-type').on('error.AudioTrack', function () {\n\t\t\t\t\treturn _this._trigger('error');\n\t\t\t\t});\n\n\t\t\t\t// Subscribe to command messages.\n\t\t\t\tsubscribe(this, function (mesg) {\n\t\t\t\t\tif (!_this.audio) {\n\t\t\t\t\t\tunsubscribe(_this);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch (mesg) {\n\t\t\t\t\t\tcase 'loadwithscreen':\n\t\t\t\t\t\t\tif (_this.hasSource()) {\n\t\t\t\t\t\t\t\tvar lockId = LoadScreen.lock();\n\t\t\t\t\t\t\t\t_this.one('canplaythrough.AudioTrack_loadwithscreen error.AudioTrack_loadwithscreen', function () {\n\t\t\t\t\t\t\t\t\tjQuery(this).off('.AudioTrack_loadwithscreen');\n\t\t\t\t\t\t\t\t\tLoadScreen.unlock(lockId);\n\t\t\t\t\t\t\t\t}).load();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\t\t_this.load();break;\n\t\t\t\t\t\tcase 'mute':\n\t\t\t\t\t\t\t_this._updateAudioMute();break;\n\t\t\t\t\t\tcase 'rate':\n\t\t\t\t\t\t\t_this._updateAudioRate();break;\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\t\t_this.stop();break;\n\t\t\t\t\t\tcase 'volume':\n\t\t\t\t\t\t\t_this._updateAudioVolume();break;\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\t_this.unload();break;\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\t// Synchronize with the current master audio settings.\n\t\t\t\tthis._updateAudioMute();\n\t\t\t\tthis._updateAudioRate();\n\t\t\t\tthis._updateAudioVolume();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_trigger',\n\t\t\tvalue: function _trigger(eventName) {\n\t\t\t\t// Do not use `trigger()` here as we do not want these events to bubble.\n\t\t\t\tjQuery(this.audio).triggerHandler(eventName);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_destroy',\n\t\t\tvalue: function _destroy() {\n\t\t\t\t/*\n    \tStrictly speaking, self-destruction is not necessary as this object will,\n    \teventually, be garbage collected.  That said, since the audio element contains\n    \tdata buffers for the selected audio source, which may be quite large, manually\n    \tpurging them as soon as we know that they're no longer needed is not a bad idea.\n    */\n\t\t\t\tunsubscribe(this);\n\n\t\t\t\tif (!this.audio) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tjQuery(this.audio).off();\n\t\t\t\tthis.unload();\n\t\t\t\tthis._error = true;\n\n\t\t\t\t// Delete the audio element property.\n\t\t\t\tdelete this.audio;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'clone',\n\t\t\tvalue: function clone() {\n\t\t\t\treturn new AudioTrack(this);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'load',\n\t\t\tvalue: function load() {\n\t\t\t\tvar _this2 = this;\n\n\t\t\t\tthis.fadeStop();\n\t\t\t\tthis.audio.pause();\n\n\t\t\t\tif (!this.audio.hasChildNodes()) {\n\t\t\t\t\tif (this.sources.length === 0) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tthis.sources.forEach(function (srcObj) {\n\t\t\t\t\t\tvar source = document.createElement('source');\n\t\t\t\t\t\tsource.src = srcObj.src;\n\t\t\t\t\t\tsource.type = srcObj.type;\n\t\t\t\t\t\t_this2.audio.appendChild(source);\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tif (this.audio.preload !== 'auto') {\n\t\t\t\t\tthis.audio.preload = 'auto';\n\t\t\t\t}\n\n\t\t\t\tif (!this.isLoading()) {\n\t\t\t\t\tthis.audio.load();\n\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'unload',\n\t\t\tvalue: function unload() {\n\t\t\t\tthis.fadeStop();\n\t\t\t\tthis.stop();\n\n\t\t\t\tvar audio = this.audio;\n\t\t\t\taudio.preload = 'none';\n\n\t\t\t\t// Remove all source elements.\n\t\t\t\twhile (audio.hasChildNodes()) {\n\t\t\t\t\taudio.removeChild(audio.firstChild);\n\t\t\t\t}\n\n\t\t\t\t// Force the audio element to drop any existing data buffers.\n\t\t\t\taudio.load();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'play',\n\t\t\tvalue: function play() {\n\t\t\t\tvar _this3 = this;\n\n\t\t\t\tif (!this.hasSource()) {\n\t\t\t\t\treturn Promise.reject(new Error('none of the candidate sources were acceptable'));\n\t\t\t\t}\n\n\t\t\t\tif (this.isUnloaded()) {\n\t\t\t\t\treturn Promise.reject(new Error('no sources are loaded'));\n\t\t\t\t}\n\n\t\t\t\tif (this.isFailed()) {\n\t\t\t\t\treturn Promise.reject(new Error('failed to load any of the sources'));\n\t\t\t\t}\n\n\t\t\t\tif (this.audio.preload !== 'auto') {\n\t\t\t\t\tthis.audio.preload = 'auto';\n\t\t\t\t}\n\n\t\t\t\tif (Has.audioPromise) {\n\t\t\t\t\treturn this.audio.play();\n\t\t\t\t}\n\n\t\t\t\treturn new Promise(function (resolve, reject) {\n\t\t\t\t\tjQuery(_this3.audio).off('.AudioTrack_play').one('error.AudioTrack_play playing.AudioTrack_play', function (ev) {\n\t\t\t\t\t\tjQuery(_this3).off('.AudioTrack_play');\n\n\t\t\t\t\t\tif (ev.type === 'error') {\n\t\t\t\t\t\t\treject(new Error('unknown error'));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tresolve();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t_this3.audio.play();\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'playWhenAllowed',\n\t\t\tvalue: function playWhenAllowed() {\n\t\t\t\tvar _this4 = this;\n\n\t\t\t\tthis.play().catch(function () {\n\t\t\t\t\tvar gestures = _gestureEventNames.map(function (name) {\n\t\t\t\t\t\treturn name + '.AudioTrack_playWhenAllowed';\n\t\t\t\t\t}).join(' ');\n\t\t\t\t\tjQuery(document).one(gestures, function () {\n\t\t\t\t\t\tjQuery(document).off('.AudioTrack_playWhenAllowed');\n\t\t\t\t\t\t_this4.audio.play();\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'pause',\n\t\t\tvalue: function pause() {\n\t\t\t\tthis.audio.pause();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'stop',\n\t\t\tvalue: function stop() {\n\t\t\t\tthis.audio.pause();\n\t\t\t\tthis.time(0);\n\t\t\t\tthis._trigger(':stopped');\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fade',\n\t\t\tvalue: function fade(duration, toVol, fromVol) {\n\t\t\t\tvar _this5 = this;\n\n\t\t\t\tif (typeof duration !== 'number') {\n\t\t\t\t\tthrow new TypeError('duration parameter must be a number');\n\t\t\t\t}\n\t\t\t\tif (typeof toVol !== 'number') {\n\t\t\t\t\tthrow new TypeError('toVolume parameter must be a number');\n\t\t\t\t}\n\t\t\t\tif (fromVol != null && typeof fromVol !== 'number') {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('fromVolume parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\tif (!this.hasSource()) {\n\t\t\t\t\treturn Promise.reject(new Error('none of the candidate sources were acceptable'));\n\t\t\t\t}\n\n\t\t\t\tif (this.isUnloaded()) {\n\t\t\t\t\treturn Promise.reject(new Error('no sources are loaded'));\n\t\t\t\t}\n\n\t\t\t\tif (this.isFailed()) {\n\t\t\t\t\treturn Promise.reject(new Error('failed to load any of the sources'));\n\t\t\t\t}\n\n\t\t\t\tthis.fadeStop();\n\n\t\t\t\tvar from = Math.clamp(fromVol == null ? this.volume() : fromVol, 0, 1); // lazy equality for null\n\t\t\t\tvar to = Math.clamp(toVol, 0, 1);\n\n\t\t\t\tif (from === to) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tthis.volume(from);\n\n\t\t\t\t/*\n    \tWe listen for the `timeupdate` event here, rather than `playing`, because\n    \tvarious browsers (notably, mobile browsers) are poor at firing media events\n    \tin a timely fashion, so we use `timeupdate` to ensure that we don't start\n    \tthe fade until the track is actually progressing.\n    */\n\t\t\t\tjQuery(this.audio).off('timeupdate.AudioTrack_fade').one('timeupdate.AudioTrack_fade', function () {\n\t\t\t\t\tvar min = void 0;\n\t\t\t\t\tvar max = void 0;\n\n\t\t\t\t\t// Fade in.\n\t\t\t\t\tif (from < to) {\n\t\t\t\t\t\tmin = from;\n\t\t\t\t\t\tmax = to;\n\t\t\t\t\t}\n\t\t\t\t\t// Fade out.\n\t\t\t\t\telse {\n\t\t\t\t\t\t\tmin = to;\n\t\t\t\t\t\t\tmax = from;\n\t\t\t\t\t\t}\n\n\t\t\t\t\tvar time = Math.max(duration, 1);\n\t\t\t\t\tvar interval = 25; // in milliseconds\n\t\t\t\t\tvar delta = (to - from) / (time / (interval / 1000));\n\n\t\t\t\t\t_this5._trigger(':fading');\n\t\t\t\t\t_this5._faderId = setInterval(function () {\n\t\t\t\t\t\tif (!_this5.isPlaying()) {\n\t\t\t\t\t\t\t/*\n       \tWhile it may seem like a good idea to also set the track volume\n       \tto the `to` value here, we should not do so.  We cannot know why\n       \tthe track is no longer playing, nor if the volume has been modified\n       \tin the interim, so doing so now may clobber an end-user set volume.\n       */\n\t\t\t\t\t\t\t_this5.fadeStop();\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t_this5.volume(Math.clamp(_this5.volume() + delta, min, max));\n\n\t\t\t\t\t\tif (Config.audio.pauseOnFadeToZero && _this5.volume() === 0) {\n\t\t\t\t\t\t\t_this5.pause();\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (_this5.volume() === to) {\n\t\t\t\t\t\t\t_this5.fadeStop();\n\t\t\t\t\t\t\t_this5._trigger(':faded');\n\t\t\t\t\t\t}\n\t\t\t\t\t}, interval);\n\t\t\t\t});\n\n\t\t\t\treturn this.play();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeIn',\n\t\t\tvalue: function fadeIn(duration, fromVol) {\n\t\t\t\treturn this.fade(duration, 1, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeOut',\n\t\t\tvalue: function fadeOut(duration, fromVol) {\n\t\t\t\treturn this.fade(duration, 0, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeStop',\n\t\t\tvalue: function fadeStop() {\n\t\t\t\tif (this._faderId !== null) {\n\t\t\t\t\tclearInterval(this._faderId);\n\t\t\t\t\tthis._faderId = null;\n\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'loop',\n\t\t\tvalue: function (_loop) {\n\t\t\t\tfunction loop(_x) {\n\t\t\t\t\treturn _loop.apply(this, arguments);\n\t\t\t\t}\n\n\t\t\t\tloop.toString = function () {\n\t\t\t\t\treturn _loop.toString();\n\t\t\t\t};\n\n\t\t\t\treturn loop;\n\t\t\t}(function (loop) {\n\t\t\t\tif (loop == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this.audio.loop;\n\t\t\t\t}\n\n\t\t\t\tthis.audio.loop = !!loop;\n\n\t\t\t\treturn this;\n\t\t\t})\n\t\t}, {\n\t\t\tkey: 'mute',\n\t\t\tvalue: function mute(_mute) {\n\t\t\t\tif (_mute == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._mute;\n\t\t\t\t}\n\n\t\t\t\tthis._mute = !!_mute;\n\t\t\t\tthis._updateAudioMute();\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_updateAudioMute',\n\t\t\tvalue: function _updateAudioMute() {\n\t\t\t\tthis.audio.muted = this._mute || _masterMute;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'rate',\n\t\t\tvalue: function rate(_rate) {\n\t\t\t\tif (_rate == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._rate;\n\t\t\t\t}\n\n\t\t\t\tif (typeof _rate !== 'number') {\n\t\t\t\t\tthrow new TypeError('rate parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tClamp the playback rate to sane values—some browsers also do this to varying degrees.\n    \t\tNOTE (ca. Aug 2016): The specification allows negative values for reverse playback,\n    \thowever, most browsers either completely ignore negative values or clamp them to\n    \tsome positive value.  In some (notably, IE & Edge), setting a negative playback\n    \trate breaks the associated controls, if displayed.\n    */\n\t\t\t\t/*\n    this._rate = rate < 0\n    \t? Math.clamp(rate, -0.2, -5) // clamp to 5× slower & faster, backward\n    \t: Math.clamp(rate, 0.2, 5);  // clamp to 5× slower & faster, forward\n    */\n\t\t\t\tthis._rate = Math.clamp(_rate, 0.2, 5); // clamp to 5× slower & faster\n\t\t\t\tthis._updateAudioRate();\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_updateAudioRate',\n\t\t\tvalue: function _updateAudioRate() {\n\t\t\t\t/*\n    const rate = this._rate * _masterRate;\n    this.audio.playbackRate = rate < 0\n    \t? Math.clamp(rate, -0.2, -5) // clamp to 5× slower & faster, backward\n    \t: Math.clamp(rate, 0.2, 5);  // clamp to 5× slower & faster, forward\n    */\n\t\t\t\tthis.audio.playbackRate = Math.clamp(this._rate * _masterRate, 0.2, 5); // clamp to 5× slower & faster\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'time',\n\t\t\tvalue: function time(_time) {\n\t\t\t\tvar _this6 = this;\n\n\t\t\t\tif (_time == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this.audio.currentTime;\n\t\t\t\t}\n\n\t\t\t\tif (typeof _time !== 'number') {\n\t\t\t\t\tthrow new TypeError('time parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tNOTE (historic): If we try to modify the audio clip's `.currentTime` property\n    \tbefore its metadata has been loaded, it will throw an `InvalidStateError`\n    \t(since it doesn't know its duration, allowing `.currentTime` to be set would\n    \tbe undefined behavior), so in case an exception is thrown we provide a fallback\n    \tusing the `loadedmetadata` event.\n    \t\tNOTE (ca. 2016): This workaround should no longer be necessary in most browsers.\n    \tThat said, it will still be required for some time to service legacy browsers.\n    \t\tNOTE (ca. Dec 09, 2018): Firefox will still log an `InvalidStateError` to the\n    \tconsole when attempting to modify the clip's `.currentTime` property before its\n    \tmetadata has been loaded, even though it handles the situation properly—by waiting\n    \tfor the metadata, as all browsers do now.  To prevent this spurious logging, we\n    \tmust now manually check for the existence of the metadata and always failover to\n    \tan event regardless of if the browser needs it or not—because I don't want to\n    \tintroduce a browser check here.  Stay classy, Firefox.\n    */\n\t\t\t\tif (this.hasMetadata()) {\n\t\t\t\t\tthis.audio.currentTime = _time;\n\t\t\t\t} else {\n\t\t\t\t\tjQuery(this.audio).off('loadedmetadata.AudioTrack_time').one('loadedmetadata.AudioTrack_time', function () {\n\t\t\t\t\t\treturn _this6.audio.currentTime = _time;\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'volume',\n\t\t\tvalue: function volume(_volume) {\n\t\t\t\tif (_volume == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._volume;\n\t\t\t\t}\n\n\t\t\t\tif (typeof _volume !== 'number') {\n\t\t\t\t\tthrow new TypeError('volume parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\tthis._volume = Math.clamp(_volume, 0, 1); // clamp to 0 (silent) & 1 (full loudness)\n\t\t\t\tthis._updateAudioVolume();\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_updateAudioVolume',\n\t\t\tvalue: function _updateAudioVolume() {\n\t\t\t\tthis.audio.volume = Math.clamp(this._volume * _masterVolume, 0, 1);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'duration',\n\t\t\tvalue: function duration() {\n\t\t\t\t// NOTE: May return a double (normally), Infinity (for streams), or NaN (without metadata).\n\t\t\t\treturn this.audio.duration;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'remaining',\n\t\t\tvalue: function remaining() {\n\t\t\t\t// NOTE: May return a double (normally), Infinity (for streams), or NaN (without metadata).\n\t\t\t\treturn this.audio.duration - this.audio.currentTime;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isFailed',\n\t\t\tvalue: function isFailed() {\n\t\t\t\treturn this._error;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isLoading',\n\t\t\tvalue: function isLoading() {\n\t\t\t\treturn this.audio.networkState === HTMLMediaElement.NETWORK_LOADING;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isUnloaded',\n\t\t\tvalue: function isUnloaded() {\n\t\t\t\treturn !this.audio.hasChildNodes();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isUnavailable',\n\t\t\tvalue: function isUnavailable() {\n\t\t\t\treturn !this.hasSource() || this.isUnloaded() || this.isFailed();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isPlaying',\n\t\t\tvalue: function isPlaying() {\n\t\t\t\t// NOTE: The `this.hasSomeData()` check is probably no longer necessary.\n\t\t\t\treturn !this.audio.paused && this.hasSomeData();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isPaused',\n\t\t\tvalue: function isPaused() {\n\t\t\t\t/*\n    \tIf the selected audio resource is a stream, `currentTime` may return a non-zero\n    \tvalue even at the earliest available position within the stream as the browser\n    \tmay have dropped the earliest chunks of buffered data or the stream may have a\n    \ttimeline which does not start at zero.\n    \t\tIn an attempt to guard against these possiblities, as best as we can, we test\n    \t`duration` against `Infinity` first, which should yield true for actual streams.\n    */\n\t\t\t\treturn this.audio.paused && (this.audio.duration === Infinity || this.audio.currentTime > 0) && !this.audio.ended;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isStopped',\n\t\t\tvalue: function isStopped() {\n\t\t\t\treturn this.audio.paused && this.audio.currentTime === 0;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isEnded',\n\t\t\tvalue: function isEnded() {\n\t\t\t\treturn this.audio.ended;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isFading',\n\t\t\tvalue: function isFading() {\n\t\t\t\treturn this._faderId !== null;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isSeeking',\n\t\t\tvalue: function isSeeking() {\n\t\t\t\treturn this.audio.seeking;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'hasSource',\n\t\t\tvalue: function hasSource() {\n\t\t\t\treturn this.sources.length > 0;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'hasNoData',\n\t\t\tvalue: function hasNoData() {\n\t\t\t\treturn this.audio.readyState === HTMLMediaElement.HAVE_NOTHING;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'hasMetadata',\n\t\t\tvalue: function hasMetadata() {\n\t\t\t\treturn this.audio.readyState >= HTMLMediaElement.HAVE_METADATA;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'hasSomeData',\n\t\t\tvalue: function hasSomeData() {\n\t\t\t\treturn this.audio.readyState >= HTMLMediaElement.HAVE_CURRENT_DATA;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'hasData',\n\t\t\tvalue: function hasData() {\n\t\t\t\treturn this.audio.readyState === HTMLMediaElement.HAVE_ENOUGH_DATA;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'on',\n\t\t\tvalue: function on() {\n\t\t\t\tfor (var _len5 = arguments.length, args = Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {\n\t\t\t\t\targs[_key5] = arguments[_key5];\n\t\t\t\t}\n\n\t\t\t\tjQuery.fn.on.apply(jQuery(this.audio), args);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'one',\n\t\t\tvalue: function one() {\n\t\t\t\tfor (var _len6 = arguments.length, args = Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {\n\t\t\t\t\targs[_key6] = arguments[_key6];\n\t\t\t\t}\n\n\t\t\t\tjQuery.fn.one.apply(jQuery(this.audio), args);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'off',\n\t\t\tvalue: function off() {\n\t\t\t\tfor (var _len7 = arguments.length, args = Array(_len7), _key7 = 0; _key7 < _len7; _key7++) {\n\t\t\t\t\targs[_key7] = arguments[_key7];\n\t\t\t\t}\n\n\t\t\t\tjQuery.fn.off.apply(jQuery(this.audio), args);\n\t\t\t\treturn this;\n\t\t\t}\n\n\t\t\t/*\n   \tVerifies that the browser supports the given MIME-type and then retuns either\n   \tthe MIME-type, if it is supported, or `null`, if it is not.\n   */\n\n\t\t}], [{\n\t\t\tkey: '_verifyType',\n\t\t\tvalue: function _verifyType(type) {\n\t\t\t\tif (!type || !Has.audio) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tvar cache = AudioTrack._types;\n\n\t\t\t\tif (!cache.hasOwnProperty(type)) {\n\t\t\t\t\tvar audio = document.createElement('audio');\n\n\t\t\t\t\t// Some early implementations return 'no' instead of the empty string.\n\t\t\t\t\tcache[type] = audio.canPlayType(type).replace(/^no$/i, '') !== '';\n\t\t\t\t}\n\n\t\t\t\treturn cache[type] ? type : null;\n\t\t\t}\n\n\t\t\t/*\n   \tRetuns the MIME-type associated with the given format-ID, if it is supported,\n   \telsewise `null`.\n   */\n\n\t\t}, {\n\t\t\tkey: 'getType',\n\t\t\tvalue: function getType(format) {\n\t\t\t\tif (!format || !Has.audio) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\n\t\t\t\tvar known = AudioTrack.formats;\n\t\t\t\tvar id = format.toLowerCase();\n\t\t\t\tvar type = known.hasOwnProperty(id) ? known[id] : 'audio/' + id;\n\n\t\t\t\treturn AudioTrack._verifyType(type);\n\t\t\t}\n\n\t\t\t/*\n   \tReturns whether the browser potentially supports a format.\n   */\n\n\t\t}, {\n\t\t\tkey: 'canPlayFormat',\n\t\t\tvalue: function canPlayFormat(format) {\n\t\t\t\treturn AudioTrack.getType(format) !== null;\n\t\t\t}\n\n\t\t\t/*\n   \tReturns whether the browser potentially supports a MIME-type.\n   */\n\n\t\t}, {\n\t\t\tkey: 'canPlayType',\n\t\t\tvalue: function canPlayType(type) {\n\t\t\t\treturn AudioTrack._verifyType(type) !== null;\n\t\t\t}\n\t\t}]);\n\n\t\treturn AudioTrack;\n\t}();\n\n\t// Attach the static data members.\n\n\n\tObject.defineProperties(AudioTrack, {\n\t\t/*\n  \tFormat-ID to MIME-type mappings for common audio types.\n  \t\tIn most cases, the codecs property should not be included with the MIME-type,\n  \tas we have no way of knowing which codec was used—and the browser will figure\n  \tit out.  Conversely, in cases where the relationship relationship between a\n  \tformat-ID and a specific codec is strong, we should include the codecs property.\n  \t\tNOTE: Caveats by browser/engine:\n  \t\tOpera ≤12 (Presto) will return a false-negative if the codecs value is quoted\n  \t\twith single quotes, requiring the use of either double quotes or no quotes.\n  \t\t\tBlink-based browsers (e.g. Chrome, Opera ≥15) will return a false-negative\n  \t\tfor WAVE audio if the preferred MIME-type of 'audio/wave' is specified,\n  \t\trequiring the use of 'audio/wav' instead.\n  */\n\t\tformats: {\n\t\t\tvalue: { // Leave this object extensible for users.\n\t\t\t\t// AAC — MPEG-2 AAC audio; specific profiles vary, but commonly \"AAC-LC\".\n\t\t\t\taac: 'audio/aac',\n\n\t\t\t\t// CAF — Codecs vary.\n\t\t\t\tcaf: 'audio/x-caf',\n\t\t\t\t'x-caf': 'audio/x-caf',\n\n\t\t\t\t// MP3 — MPEG-1/-2 Layer-III audio.\n\t\t\t\tmp3: 'audio/mpeg; codecs=\"mp3\"',\n\t\t\t\tmpeg: 'audio/mpeg; codecs=\"mp3\"',\n\n\t\t\t\t// MP4 — Codecs vary, but commonly \"mp4a.40.2\" (a.k.a. \"AAC-LC\").\n\t\t\t\tm4a: 'audio/mp4',\n\t\t\t\tmp4: 'audio/mp4',\n\t\t\t\t'x-m4a': 'audio/mp4',\n\t\t\t\t'x-mp4': 'audio/mp4',\n\n\t\t\t\t// OGG — Codecs vary, but commonly \"vorbis\" and, recently, \"opus\".\n\t\t\t\toga: 'audio/ogg',\n\t\t\t\togg: 'audio/ogg',\n\n\t\t\t\t// OPUS — Opus audio in an Ogg container.\n\t\t\t\topus: 'audio/ogg; codecs=\"opus\"',\n\n\t\t\t\t// WAVE — Codecs vary, but commonly \"1\" (1 is the FourCC for PCM/LPCM).\n\t\t\t\twav: 'audio/wav',\n\t\t\t\twave: 'audio/wav',\n\n\t\t\t\t// WEBM — Codecs vary, but commonly \"vorbis\" and, recently, \"opus\".\n\t\t\t\tweba: 'audio/webm',\n\t\t\t\twebm: 'audio/webm'\n\t\t\t}\n\t\t},\n\n\t\t/*\n  \tCache of supported MIME-types.\n  */\n\t\t_types: {\n\t\t\tvalue: {}\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tAudioList Class.\n *******************************************************************************************************************/\n\n\tvar AudioList = function () {\n\t\tfunction AudioList(obj) {\n\t\t\t_classCallCheck(this, AudioList);\n\n\t\t\t// Process the given array of track objects or AudioList object.\n\t\t\tif (obj instanceof Array) {\n\t\t\t\tthis._create(obj);\n\t\t\t} else if (obj instanceof AudioList) {\n\t\t\t\tthis._copy(obj);\n\t\t\t\t// this._create(obj.tracks);\n\t\t\t} else {\n\t\t\t\tthrow new Error('tracks parameter must be either an array, of track objects, or an AudioTrack instance');\n\t\t\t}\n\t\t}\n\n\t\t_createClass(AudioList, [{\n\t\t\tkey: '_create',\n\t\t\tvalue: function _create(trackList) {\n\t\t\t\tvar _this7 = this;\n\n\t\t\t\t// Map the array of tracks to playlist track objects.\n\t\t\t\tthis._finalize(trackList.map(function (trackObj) {\n\t\t\t\t\tif ((typeof trackObj === 'undefined' ? 'undefined' : _typeof(trackObj)) !== 'object') {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tthrow new Error('tracks parameter array members must be objects');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar own = void 0;\n\t\t\t\t\tvar rate = void 0;\n\t\t\t\t\tvar track = void 0;\n\t\t\t\t\tvar volume = void 0;\n\n\t\t\t\t\tif (trackObj instanceof AudioTrack) {\n\t\t\t\t\t\town = true;\n\t\t\t\t\t\trate = trackObj.rate();\n\t\t\t\t\t\ttrack = trackObj.clone();\n\t\t\t\t\t\tvolume = trackObj.volume();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (!trackObj.hasOwnProperty('track')) {\n\t\t\t\t\t\t\tthrow new Error('track object missing required \"track\" property');\n\t\t\t\t\t\t} else if (!(trackObj.track instanceof AudioTrack)) {\n\t\t\t\t\t\t\tthrow new Error('track object\\'s \"track\" property must be an AudioTrack object');\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// else if (!trackObj.hasOwnProperty('volume')) {\n\t\t\t\t\t\t// \tthrow new Error('track object missing required \"volume\" property');\n\t\t\t\t\t\t// }\n\n\t\t\t\t\t\town = trackObj.hasOwnProperty('own') && trackObj.own;\n\t\t\t\t\t\trate = trackObj.hasOwnProperty('rate') ? trackObj.rate : trackObj.track.rate();\n\t\t\t\t\t\ttrack = trackObj.track;\n\t\t\t\t\t\tvolume = trackObj.hasOwnProperty('volume') ? trackObj.volume : trackObj.track.volume();\n\t\t\t\t\t}\n\n\t\t\t\t\ttrack.stop();\n\t\t\t\t\ttrack.loop(false);\n\t\t\t\t\ttrack.mute(false);\n\t\t\t\t\ttrack.rate(rate);\n\t\t\t\t\ttrack.volume(volume);\n\t\t\t\t\ttrack.on('ended.AudioList', function () {\n\t\t\t\t\t\treturn _this7._onEnd();\n\t\t\t\t\t});\n\n\t\t\t\t\treturn { own: own, track: track, volume: volume, rate: rate };\n\t\t\t\t}));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_copy',\n\t\t\tvalue: function _copy(obj) {\n\t\t\t\tthis._finalize(clone(obj.tracks));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_finalize',\n\t\t\tvalue: function _finalize(tracks) {\n\t\t\t\t// Set up our own properties.\n\t\t\t\tObject.defineProperties(this, {\n\t\t\t\t\ttracks: {\n\t\t\t\t\t\tconfigurable: true,\n\t\t\t\t\t\tvalue: Object.freeze(tracks)\n\t\t\t\t\t},\n\n\t\t\t\t\tqueue: {\n\t\t\t\t\t\tconfigurable: true,\n\t\t\t\t\t\tvalue: []\n\t\t\t\t\t},\n\n\t\t\t\t\tcurrent: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: null\n\t\t\t\t\t},\n\n\t\t\t\t\t_rate: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: 1\n\t\t\t\t\t},\n\n\t\t\t\t\t_volume: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: 1\n\t\t\t\t\t},\n\n\t\t\t\t\t_mute: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: false\n\t\t\t\t\t},\n\n\t\t\t\t\t_loop: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: false\n\t\t\t\t\t},\n\n\t\t\t\t\t_shuffle: {\n\t\t\t\t\t\twritable: true,\n\t\t\t\t\t\tvalue: false\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_destroy',\n\t\t\tvalue: function _destroy() {\n\t\t\t\t/*\n    \tStrictly speaking, self-destruction is not necessary as this object will,\n    \teventually, be garbage collected.\n    */\n\t\t\t\t// Stop playback.\n\t\t\t\tthis.stop();\n\n\t\t\t\t// Destroy all owned tracks.\n\t\t\t\tthis.tracks.filter(function (trackObj) {\n\t\t\t\t\treturn trackObj.own;\n\t\t\t\t}).forEach(function (trackObj) {\n\t\t\t\t\treturn trackObj.track._destroy();\n\t\t\t\t});\n\n\t\t\t\t// Delete the reference-type properties.\n\t\t\t\tdelete this.tracks;\n\t\t\t\tdelete this.queue;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'load',\n\t\t\tvalue: function load() {\n\t\t\t\tthis.tracks.forEach(function (trackObj) {\n\t\t\t\t\treturn trackObj.track.load();\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'unload',\n\t\t\tvalue: function unload() {\n\t\t\t\tthis.stop();\n\t\t\t\tthis.tracks.forEach(function (trackObj) {\n\t\t\t\t\treturn trackObj.track.unload();\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'play',\n\t\t\tvalue: function play() {\n\t\t\t\tif (this.current === null || this.current.track.isUnavailable() || this.current.track.isEnded()) {\n\t\t\t\t\tif (this.queue.length === 0) {\n\t\t\t\t\t\tthis._fillQueue();\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!this._next()) {\n\t\t\t\t\t\treturn Promise.reject(new Error('no tracks were available'));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn this.current.track.play();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'playWhenAllowed',\n\t\t\tvalue: function playWhenAllowed() {\n\t\t\t\tvar _this8 = this;\n\n\t\t\t\tthis.play().catch(function () {\n\t\t\t\t\tvar gestures = _gestureEventNames.map(function (name) {\n\t\t\t\t\t\treturn name + '.AudioList_playWhenAllowed';\n\t\t\t\t\t}).join(' ');\n\t\t\t\t\tjQuery(document).one(gestures, function () {\n\t\t\t\t\t\tjQuery(document).off('.AudioList_playWhenAllowed');\n\t\t\t\t\t\t_this8.play();\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'pause',\n\t\t\tvalue: function pause() {\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.pause();\n\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'stop',\n\t\t\tvalue: function stop() {\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.stop();\n\t\t\t\t\tthis.current = null;\n\t\t\t\t}\n\n\t\t\t\tthis._drainQueue();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'skip',\n\t\t\tvalue: function skip() {\n\t\t\t\tif (this._next()) {\n\t\t\t\t\tthis.current.track.play();\n\t\t\t\t} else if (this._loop) {\n\t\t\t\t\tthis.play();\n\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fade',\n\t\t\tvalue: function fade(duration, toVol, fromVol) {\n\t\t\t\tif (typeof duration !== 'number') {\n\t\t\t\t\tthrow new TypeError('duration parameter must be a number');\n\t\t\t\t}\n\t\t\t\tif (typeof toVol !== 'number') {\n\t\t\t\t\tthrow new TypeError('toVolume parameter must be a number');\n\t\t\t\t}\n\t\t\t\tif (fromVol != null && typeof fromVol !== 'number') {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new TypeError('fromVolume parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\tif (this.queue.length === 0) {\n\t\t\t\t\tthis._fillQueue();\n\t\t\t\t}\n\n\t\t\t\tif (this.current === null || this.current.track.isUnavailable() || this.current.track.isEnded()) {\n\t\t\t\t\tif (!this._next()) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tvar adjToVol = Math.clamp(toVol, 0, 1) * this.current.volume;\n\t\t\t\tvar adjFromVol = void 0;\n\n\t\t\t\tif (fromVol != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tadjFromVol = Math.clamp(fromVol, 0, 1) * this.current.volume;\n\t\t\t\t}\n\n\t\t\t\tthis._volume = toVol; // NOTE: Kludgey, but necessary.\n\n\t\t\t\treturn this.current.track.fade(duration, adjToVol, adjFromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeIn',\n\t\t\tvalue: function fadeIn(duration, fromVol) {\n\t\t\t\treturn this.fade(duration, 1, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeOut',\n\t\t\tvalue: function fadeOut(duration, fromVol) {\n\t\t\t\treturn this.fade(duration, 0, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeStop',\n\t\t\tvalue: function fadeStop() {\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.fadeStop();\n\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'loop',\n\t\t\tvalue: function (_loop2) {\n\t\t\t\tfunction loop(_x2) {\n\t\t\t\t\treturn _loop2.apply(this, arguments);\n\t\t\t\t}\n\n\t\t\t\tloop.toString = function () {\n\t\t\t\t\treturn _loop2.toString();\n\t\t\t\t};\n\n\t\t\t\treturn loop;\n\t\t\t}(function (loop) {\n\t\t\t\tif (loop == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._loop;\n\t\t\t\t}\n\n\t\t\t\tthis._loop = !!loop;\n\n\t\t\t\treturn this;\n\t\t\t})\n\t\t}, {\n\t\t\tkey: 'mute',\n\t\t\tvalue: function mute(_mute2) {\n\t\t\t\tif (_mute2 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._mute;\n\t\t\t\t}\n\n\t\t\t\tthis._mute = !!_mute2;\n\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.mute(this._mute);\n\t\t\t\t}\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'rate',\n\t\t\tvalue: function rate(_rate2) {\n\t\t\t\tif (_rate2 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._rate;\n\t\t\t\t}\n\n\t\t\t\tif (typeof _rate2 !== 'number') {\n\t\t\t\t\tthrow new TypeError('rate parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\tthis._rate = Math.clamp(_rate2, 0.2, 5); // clamp to 5× slower & faster\n\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.rate(this._rate * this.current.rate);\n\t\t\t\t}\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'shuffle',\n\t\t\tvalue: function shuffle(_shuffle) {\n\t\t\t\tvar _this9 = this;\n\n\t\t\t\tif (_shuffle == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._shuffle;\n\t\t\t\t}\n\n\t\t\t\tthis._shuffle = !!_shuffle;\n\n\t\t\t\tif (this.queue.length > 0) {\n\t\t\t\t\tthis._fillQueue();\n\n\t\t\t\t\t// Try not to immediately replay the last track when not shuffling.\n\t\t\t\t\tif (!this._shuffle && this.current !== null && this.queue.length > 1) {\n\t\t\t\t\t\tvar firstIdx = this.queue.findIndex(function (trackObj) {\n\t\t\t\t\t\t\treturn trackObj === _this9.current;\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\tif (firstIdx !== -1) {\n\t\t\t\t\t\t\tvar _queue;\n\n\t\t\t\t\t\t\t(_queue = this.queue).push.apply(_queue, _toConsumableArray(this.queue.splice(0, firstIdx + 1)));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'volume',\n\t\t\tvalue: function volume(_volume2) {\n\t\t\t\tif (_volume2 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this._volume;\n\t\t\t\t}\n\n\t\t\t\tif (typeof _volume2 !== 'number') {\n\t\t\t\t\tthrow new TypeError('volume parameter must be a number');\n\t\t\t\t}\n\n\t\t\t\tthis._volume = Math.clamp(_volume2, 0, 1); // clamp to 0 (silent) & 1 (full loudness)\n\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.volume(this._volume * this.current.volume);\n\t\t\t\t}\n\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'duration',\n\t\t\tvalue: function duration() {\n\t\t\t\tif (arguments.length > 0) {\n\t\t\t\t\tthrow new Error('duration takes no parameters');\n\t\t\t\t}\n\n\t\t\t\t// NOTE: May return a double (normally), Infinity (for streams), or NaN (without metadata).\n\t\t\t\treturn this.tracks.map(function (trackObj) {\n\t\t\t\t\treturn trackObj.track.duration();\n\t\t\t\t}).reduce(function (prev, cur) {\n\t\t\t\t\treturn prev + cur;\n\t\t\t\t}, 0);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'remaining',\n\t\t\tvalue: function remaining() {\n\t\t\t\tif (arguments.length > 0) {\n\t\t\t\t\tthrow new Error('remaining takes no parameters');\n\t\t\t\t}\n\n\t\t\t\t// NOTE: May return a double (normally), Infinity (for streams), or NaN (without metadata).\n\t\t\t\tvar remainingTime = this.queue.map(function (trackObj) {\n\t\t\t\t\treturn trackObj.track.duration();\n\t\t\t\t}).reduce(function (prev, cur) {\n\t\t\t\t\treturn prev + cur;\n\t\t\t\t}, 0);\n\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tremainingTime += this.current.track.remaining();\n\t\t\t\t}\n\n\t\t\t\treturn remainingTime;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'time',\n\t\t\tvalue: function time() {\n\t\t\t\tif (arguments.length > 0) {\n\t\t\t\t\tthrow new Error('time takes no parameters');\n\t\t\t\t}\n\n\t\t\t\treturn this.duration() - this.remaining();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isPlaying',\n\t\t\tvalue: function isPlaying() {\n\t\t\t\treturn this.current !== null && this.current.track.isPlaying();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isPaused',\n\t\t\tvalue: function isPaused() {\n\t\t\t\treturn this.current === null || this.current.track.isPaused();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isStopped',\n\t\t\tvalue: function isStopped() {\n\t\t\t\treturn this.queue.length === 0 && this.current === null;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isEnded',\n\t\t\tvalue: function isEnded() {\n\t\t\t\treturn this.queue.length === 0 && (this.current === null || this.current.track.isEnded());\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'isFading',\n\t\t\tvalue: function isFading() {\n\t\t\t\treturn this.current !== null && this.current.track.isFading();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_next',\n\t\t\tvalue: function _next() {\n\t\t\t\tif (this.current !== null) {\n\t\t\t\t\tthis.current.track.stop();\n\t\t\t\t\tthis.current = null;\n\t\t\t\t}\n\n\t\t\t\tvar nextTrack = void 0;\n\n\t\t\t\twhile (nextTrack = this.queue.shift()) {\n\t\t\t\t\tif (!nextTrack.track.isUnavailable()) {\n\t\t\t\t\t\tthis.current = nextTrack;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (this.current === null) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tthis.current.track.mute(this._mute);\n\t\t\t\tthis.current.track.rate(this._rate * this.current.rate);\n\t\t\t\tthis.current.track.volume(this._volume * this.current.volume);\n\n\t\t\t\t// Attempt to protect against the `loop` state being reenabled\n\t\t\t\t// outside of the playlist.  Mostly for unowned tracks.\n\t\t\t\t//\n\t\t\t\t// TODO: Should we reapply the `ended` event handler too?\n\t\t\t\tthis.current.track.loop(false);\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_onEnd',\n\t\t\tvalue: function _onEnd() {\n\t\t\t\tif (this.queue.length === 0) {\n\t\t\t\t\tif (!this._loop) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tthis._fillQueue();\n\t\t\t\t}\n\n\t\t\t\tif (!this._next()) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tthis.current.track.play();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_drainQueue',\n\t\t\tvalue: function _drainQueue() {\n\t\t\t\tthis.queue.splice(0);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: '_fillQueue',\n\t\t\tvalue: function _fillQueue() {\n\t\t\t\tvar _queue2;\n\n\t\t\t\tthis._drainQueue();\n\t\t\t\t(_queue2 = this.queue).push.apply(_queue2, _toConsumableArray(this.tracks.filter(function (trackObj) {\n\t\t\t\t\treturn !trackObj.track.isUnavailable();\n\t\t\t\t})));\n\n\t\t\t\tif (this.queue.length === 0) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tif (this._shuffle) {\n\t\t\t\t\tthis.queue.shuffle();\n\n\t\t\t\t\t// Try not to immediately replay the last track when shuffling.\n\t\t\t\t\tif (this.queue.length > 1 && this.queue[0] === this.current) {\n\t\t\t\t\t\tthis.queue.push(this.queue.shift());\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}]);\n\n\t\treturn AudioList;\n\t}();\n\n\t/*******************************************************************************************************************\n \tAudioRunner Class.\n *******************************************************************************************************************/\n\n\n\tvar AudioRunner = function () {\n\t\tfunction AudioRunner(list) {\n\t\t\t_classCallCheck(this, AudioRunner);\n\n\t\t\tif (!(list instanceof Set || list instanceof AudioRunner)) {\n\t\t\t\tthrow new TypeError('list parameter must be a Set or a AudioRunner instance');\n\t\t\t}\n\n\t\t\t// Set up our own properties.\n\t\t\tObject.defineProperties(this, {\n\t\t\t\ttrackIds: {\n\t\t\t\t\tvalue: new Set(list instanceof AudioRunner ? list.trackIds : list)\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t_createClass(AudioRunner, [{\n\t\t\tkey: 'load',\n\t\t\tvalue: function load() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.load);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'unload',\n\t\t\tvalue: function unload() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.unload);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'play',\n\t\t\tvalue: function play() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.play);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'playWhenAllowed',\n\t\t\tvalue: function playWhenAllowed() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.playWhenAllowed);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'pause',\n\t\t\tvalue: function pause() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.pause);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'stop',\n\t\t\tvalue: function stop() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.stop);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fade',\n\t\t\tvalue: function fade(duration, toVol, fromVol) {\n\t\t\t\tif (duration == null || toVol == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('fade requires parameters');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.fade, duration, toVol, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeIn',\n\t\t\tvalue: function fadeIn(duration, fromVol) {\n\t\t\t\tif (duration == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('fadeIn requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.fadeIn, duration, 1, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeOut',\n\t\t\tvalue: function fadeOut(duration, fromVol) {\n\t\t\t\tif (duration == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('fadeOut requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.fadeOut, duration, 0, fromVol);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'fadeStop',\n\t\t\tvalue: function fadeStop() {\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.fadeStop);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'loop',\n\t\t\tvalue: function (_loop3) {\n\t\t\t\tfunction loop(_x3) {\n\t\t\t\t\treturn _loop3.apply(this, arguments);\n\t\t\t\t}\n\n\t\t\t\tloop.toString = function () {\n\t\t\t\t\treturn _loop3.toString();\n\t\t\t\t};\n\n\t\t\t\treturn loop;\n\t\t\t}(function (loop) {\n\t\t\t\tif (loop == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('loop requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.loop, loop);\n\t\t\t\treturn this;\n\t\t\t})\n\t\t}, {\n\t\t\tkey: 'mute',\n\t\t\tvalue: function mute(_mute3) {\n\t\t\t\tif (_mute3 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('mute requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.mute, _mute3);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'rate',\n\t\t\tvalue: function rate(_rate3) {\n\t\t\t\tif (_rate3 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('rate requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.rate, _rate3);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'time',\n\t\t\tvalue: function time(_time2) {\n\t\t\t\tif (_time2 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('time requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.time, _time2);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'volume',\n\t\t\tvalue: function volume(_volume3) {\n\t\t\t\tif (_volume3 == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tthrow new Error('volume requires a parameter');\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run(this.trackIds, AudioTrack.prototype.volume, _volume3);\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'on',\n\t\t\tvalue: function on() {\n\t\t\t\tfor (var _len8 = arguments.length, args = Array(_len8), _key8 = 0; _key8 < _len8; _key8++) {\n\t\t\t\t\targs[_key8] = arguments[_key8];\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run.apply(AudioRunner, [this.trackIds, AudioTrack.prototype.on].concat(args));\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'one',\n\t\t\tvalue: function one() {\n\t\t\t\tfor (var _len9 = arguments.length, args = Array(_len9), _key9 = 0; _key9 < _len9; _key9++) {\n\t\t\t\t\targs[_key9] = arguments[_key9];\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run.apply(AudioRunner, [this.trackIds, AudioTrack.prototype.one].concat(args));\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'off',\n\t\t\tvalue: function off() {\n\t\t\t\tfor (var _len10 = arguments.length, args = Array(_len10), _key10 = 0; _key10 < _len10; _key10++) {\n\t\t\t\t\targs[_key10] = arguments[_key10];\n\t\t\t\t}\n\n\t\t\t\tAudioRunner._run.apply(AudioRunner, [this.trackIds, AudioTrack.prototype.off].concat(args));\n\t\t\t\treturn this;\n\t\t\t}\n\t\t}], [{\n\t\t\tkey: '_run',\n\t\t\tvalue: function _run(ids, fn) {\n\t\t\t\tfor (var _len11 = arguments.length, args = Array(_len11 > 2 ? _len11 - 2 : 0), _key11 = 2; _key11 < _len11; _key11++) {\n\t\t\t\t\targs[_key11 - 2] = arguments[_key11];\n\t\t\t\t}\n\n\t\t\t\tids.forEach(function (id) {\n\t\t\t\t\tvar track = _tracks.get(id);\n\n\t\t\t\t\tif (track) {\n\t\t\t\t\t\tfn.apply(track, args);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t}]);\n\n\t\treturn AudioRunner;\n\t}();\n\n\t/*******************************************************************************************************************\n \tTrack Functions.\n *******************************************************************************************************************/\n\t/*\n \tSimpleAudio.tracks.add(trackId, sources…);\n \t\tE.g.\n \t\tSimpleAudio.tracks.add(\n \t\t\t'over_the_top',\n \t\t\t'https://audiohost.tld/id/over_the_top.mp3',\n \t\t\t'https://audiohost.tld/id/over_the_top.ogg'\n \t\t);\n */\n\n\n\tfunction trackAdd() /* trackId , sources… */{\n\t\tif (arguments.length < 2) {\n\t\t\tvar errors = [];\n\t\t\tif (arguments.length < 1) {\n\t\t\t\terrors.push('track ID');\n\t\t\t}\n\t\t\tif (arguments.length < 2) {\n\t\t\t\terrors.push('sources');\n\t\t\t}\n\t\t\tthrow new Error('no ' + errors.join(' or ') + ' specified');\n\t\t}\n\n\t\tvar id = String(arguments[0]).trim();\n\t\tvar what = 'track ID \"' + id + '\"';\n\n\t\tif (_badIdRe.test(id)) {\n\t\t\tthrow new Error('invalid ' + what + ': track IDs must not contain colons or whitespace');\n\t\t}\n\n\t\tvar sources = Array.isArray(arguments[1]) ? Array.from(arguments[1]) : Array.from(arguments).slice(1);\n\t\tvar track = void 0;\n\n\t\ttry {\n\t\t\ttrack = _newTrack(sources);\n\t\t} catch (ex) {\n\t\t\tthrow new Error(what + ': error during track initialization: ' + ex.message);\n\t\t}\n\n\t\t// If in Test Mode and no supported sources were specified, throw an error.\n\t\tif (Config.debug && !track.hasSource()) {\n\t\t\tthrow new Error(what + ': no supported audio sources found');\n\t\t}\n\n\t\t// If a track by the given ID already exists, destroy it.\n\t\tif (_tracks.has(id)) {\n\t\t\t_tracks.get(id)._destroy();\n\t\t}\n\n\t\t// Add the track to the cache.\n\t\t_tracks.set(id, track);\n\t}\n\n\tfunction trackDelete(id) {\n\t\tif (_tracks.has(id)) {\n\t\t\t_tracks.get(id)._destroy();\n\t\t}\n\n\t\t// TODO: Should this also remove references to the track from groups and playlists?\n\n\t\treturn _tracks.delete(id);\n\t}\n\n\tfunction trackClear() {\n\t\t_tracks.forEach(function (track) {\n\t\t\treturn track._destroy();\n\t\t});\n\t\t_tracks.clear();\n\t}\n\n\tfunction trackHas(id) {\n\t\treturn _tracks.has(id);\n\t}\n\n\tfunction trackGet(id) {\n\t\treturn _tracks.get(id) || null;\n\t}\n\n\t/*******************************************************************************************************************\n \tGroup Functions.\n *******************************************************************************************************************/\n\t/*\n \tSimpleAudio.groups.add(groupId, trackIds…);\n \t\tE.g.\n \t\tSimpleAudio.groups.add(':ui', 'beep', 'boop', 'boing');\n */\n\tfunction groupAdd() /* groupId , trackIds… */{\n\t\tif (arguments.length < 2) {\n\t\t\tvar errors = [];\n\t\t\tif (arguments.length < 1) {\n\t\t\t\terrors.push('group ID');\n\t\t\t}\n\t\t\tif (arguments.length < 2) {\n\t\t\t\terrors.push('track IDs');\n\t\t\t}\n\t\t\tthrow new Error('no ' + errors.join(' or ') + ' specified');\n\t\t}\n\n\t\tvar id = String(arguments[0]).trim();\n\t\tvar what = 'group ID \"' + id + '\"';\n\n\t\tif (id[0] !== ':' || _badIdRe.test(id.slice(1))) {\n\t\t\tthrow new Error('invalid ' + what + ': group IDs must start with a colon and must not contain colons or whitespace');\n\t\t}\n\n\t\tif (_specialIds.includes(id)) {\n\t\t\tthrow new Error('cannot clobber special ' + what);\n\t\t}\n\n\t\tvar trackIds = Array.isArray(arguments[1]) ? Array.from(arguments[1]) : Array.from(arguments).slice(1);\n\t\tvar group = void 0;\n\n\t\ttry {\n\t\t\tgroup = new Set(trackIds.map(function (trackId) {\n\t\t\t\tif (!_tracks.has(trackId)) {\n\t\t\t\t\tthrow new Error('track \"' + trackId + '\" does not exist');\n\t\t\t\t}\n\n\t\t\t\treturn trackId;\n\t\t\t}));\n\t\t} catch (ex) {\n\t\t\tthrow new Error(what + ': error during group initialization: ' + ex.message);\n\t\t}\n\n\t\t// Add the group to the cache.\n\t\t_groups.set(id, Object.freeze(Array.from(group)));\n\t}\n\n\tfunction groupDelete(id) {\n\t\treturn _groups.delete(id);\n\t}\n\n\tfunction groupClear() {\n\t\t_groups.clear();\n\t}\n\n\tfunction groupHas(id) {\n\t\treturn _groups.has(id);\n\t}\n\n\tfunction groupGet(id) {\n\t\treturn _groups.get(id) || null;\n\t}\n\n\t/*******************************************************************************************************************\n \tPlaylist Functions.\n *******************************************************************************************************************/\n\t/*\n \tSimpleAudio.lists.add(listId, sources…);\n \t\tWhere `sources` may be either a track ID or descriptor (object).\n \t\tTrack descriptors are either { id, [own], [rate], [volume] } or { sources, [rate], [volume] }.\n \t\tNOTE: Rate properties are currently unsupported due to poor browser support.\n \t\tE.g.\n \t\tSimpleAudio.lists.add(\n \t\t\t'bgm',\n \t\t\t'over_the_top',\n \t\t\t{\n \t\t\t\tid     : 'heavens_a_lie',\n \t\t\t\tvolume : 0.5,\n \t\t\t\town    : true\n \t\t\t},\n \t\t\t{\n \t\t\t\tsources : [\n \t\t\t\t\t'https://audiohost.tld/id/swamped.mp3',\n \t\t\t\t\t'https://audiohost.tld/id/swamped.ogg'\n \t\t\t\t],\n \t\t\t\tvolume  : 0.75\n \t\t\t}\n \t\t);\n */\n\tfunction listAdd() /* listId , sources… */{\n\t\tif (arguments.length < 2) {\n\t\t\tvar errors = [];\n\t\t\tif (arguments.length < 1) {\n\t\t\t\terrors.push('list ID');\n\t\t\t}\n\t\t\tif (arguments.length < 2) {\n\t\t\t\terrors.push('track IDs');\n\t\t\t}\n\t\t\tthrow new Error('no ' + errors.join(' or ') + ' specified');\n\t\t}\n\n\t\tvar id = String(arguments[0]).trim();\n\t\tvar what = 'list ID \"' + id + '\"';\n\n\t\tif (_badIdRe.test(id)) {\n\t\t\treturn this.error('invalid ' + what + ': list IDs must not contain colons or whitespace');\n\t\t}\n\n\t\tvar descriptors = Array.isArray(arguments[1]) ? Array.from(arguments[1]) : Array.from(arguments).slice(1);\n\t\tvar list = void 0;\n\n\t\ttry {\n\t\t\tlist = new AudioList(descriptors.map(function (desc) {\n\t\t\t\tif (desc === null) {\n\t\t\t\t\tthrow new Error('track descriptor must be a string or object (type: null)');\n\t\t\t\t}\n\n\t\t\t\tswitch (typeof desc === 'undefined' ? 'undefined' : _typeof(desc)) {\n\t\t\t\t\tcase 'string':\n\t\t\t\t\t\t// Simply a track ID, so convert it into an object.\n\t\t\t\t\t\tdesc = { id: desc }; // eslint-disable-line no-param-reassign\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'object':\n\t\t\t\t\t\tif (!desc.hasOwnProperty('id') && !desc.hasOwnProperty('sources')) {\n\t\t\t\t\t\t\tthrow new Error('track descriptor must contain one of either an \"id\" or a \"sources\" property');\n\t\t\t\t\t\t} else if (desc.hasOwnProperty('id') && desc.hasOwnProperty('sources')) {\n\t\t\t\t\t\t\tthrow new Error('track descriptor must contain either an \"id\" or a \"sources\" property, not both');\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tthrow new Error('track descriptor must be a string or object (type: ' + (typeof desc === 'undefined' ? 'undefined' : _typeof(desc)) + ')');\n\t\t\t\t}\n\n\t\t\t\tvar own = void 0;\n\t\t\t\t// let rate;\n\t\t\t\tvar track = void 0;\n\t\t\t\tvar volume = void 0;\n\n\t\t\t\tif (desc.hasOwnProperty('id')) {\n\t\t\t\t\tif (typeof desc.id !== 'string') {\n\t\t\t\t\t\tthrow new Error('\"id\" property must be a string');\n\t\t\t\t\t}\n\t\t\t\t\tif (!_tracks.has(desc.id)) {\n\t\t\t\t\t\tthrow new Error('track \"' + desc.id + '\" does not exist');\n\t\t\t\t\t}\n\n\t\t\t\t\ttrack = _tracks.get(desc.id);\n\t\t\t\t} else if (desc.hasOwnProperty('sources')) {\n\t\t\t\t\tif (!Array.isArray(desc.sources) || desc.sources.length === 0) {\n\t\t\t\t\t\tthrow new Error('\"sources\" property must be a non-empty array');\n\t\t\t\t\t}\n\t\t\t\t\tif (desc.hasOwnProperty('own')) {\n\t\t\t\t\t\tthrow new Error('\"own\" property is not allowed with the \"sources\" property');\n\t\t\t\t\t}\n\n\t\t\t\t\ttry {\n\t\t\t\t\t\ttrack = _newTrack(desc.sources);\n\t\t\t\t\t\town = true;\n\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\tthrow new Error('error during track initialization: ' + ex.message);\n\t\t\t\t\t}\n\n\t\t\t\t\t// If in Test Mode and no supported sources were specified, return an error.\n\t\t\t\t\tif (Config.debug && !track.hasSource()) {\n\t\t\t\t\t\tthrow new Error('no supported audio sources found');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (desc.hasOwnProperty('own')) {\n\t\t\t\t\tif (typeof desc.own !== 'boolean') {\n\t\t\t\t\t\tthrow new Error('\"own\" property must be a boolean');\n\t\t\t\t\t}\n\n\t\t\t\t\town = desc.own;\n\n\t\t\t\t\tif (own) {\n\t\t\t\t\t\ttrack = track.clone();\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// if (desc.hasOwnProperty('rate')) {\n\t\t\t\t// \tif (\n\t\t\t\t// \t\t   typeof desc.rate !== 'number'\n\t\t\t\t// \t\t|| Number.isNaN(desc.rate)\n\t\t\t\t// \t\t|| !Number.isFinite(desc.rate)\n\t\t\t\t// \t) {\n\t\t\t\t// \t\tthrow new Error('\"rate\" property must be a finite number');\n\t\t\t\t// \t}\n\t\t\t\t//\n\t\t\t\t// \trate = desc.rate;\n\t\t\t\t// }\n\n\t\t\t\tif (desc.hasOwnProperty('volume')) {\n\t\t\t\t\tif (typeof desc.volume !== 'number' || Number.isNaN(desc.volume) || !Number.isFinite(desc.volume) || desc.volume < 0) {\n\t\t\t\t\t\tthrow new Error('\"volume\" property must be a non-negative finite number');\n\t\t\t\t\t}\n\n\t\t\t\t\tvolume = desc.volume;\n\t\t\t\t}\n\n\t\t\t\treturn {\n\t\t\t\t\town: own != null ? own : false, // lazy equality for null,\n\t\t\t\t\t// rate   : rate != null ? rate : track.rate(), // lazy equality for null,\n\t\t\t\t\ttrack: track,\n\t\t\t\t\tvolume: volume != null ? volume : track.volume() // lazy equality for null\n\t\t\t\t};\n\t\t\t}));\n\t\t} catch (ex) {\n\t\t\tthrow new Error(what + ': error during playlist initialization: ' + ex.message);\n\t\t}\n\n\t\t// If a playlist by the given ID already exists, destroy it.\n\t\tif (_lists.has(id)) {\n\t\t\t_lists.get(id)._destroy();\n\t\t}\n\n\t\t// Add the playlist to the cache.\n\t\t_lists.set(id, list);\n\t}\n\n\tfunction listDelete(id) {\n\t\tif (_lists.has(id)) {\n\t\t\t_lists.get(id)._destroy();\n\t\t}\n\n\t\treturn _lists.delete(id);\n\t}\n\n\tfunction listClear() {\n\t\t_lists.forEach(function (list) {\n\t\t\treturn list._destroy();\n\t\t});\n\t\t_lists.clear();\n\t}\n\n\tfunction listHas(id) {\n\t\treturn _lists.has(id);\n\t}\n\n\tfunction listGet(id) {\n\t\treturn _lists.get(id) || null;\n\t}\n\n\t/*******************************************************************************************************************\n \tRunner Functions.\n *******************************************************************************************************************/\n\tvar _runnerParseSelector = function () {\n\t\tvar notWsRe = /\\S/g;\n\t\tvar parenRe = /[()]/g;\n\n\t\tfunction processNegation(str, startPos) {\n\t\t\tvar match = void 0;\n\n\t\t\tnotWsRe.lastIndex = startPos;\n\t\t\tmatch = notWsRe.exec(str);\n\n\t\t\tif (match === null || match[0] !== '(') {\n\t\t\t\tthrow new Error('invalid \":not()\" syntax: missing parentheticals');\n\t\t\t}\n\n\t\t\tparenRe.lastIndex = notWsRe.lastIndex;\n\t\t\tvar start = notWsRe.lastIndex;\n\t\t\tvar result = { str: '', nextMatch: -1 };\n\t\t\tvar depth = 1;\n\n\t\t\twhile ((match = parenRe.exec(str)) !== null) {\n\t\t\t\tif (match[0] === '(') {\n\t\t\t\t\t++depth;\n\t\t\t\t} else {\n\t\t\t\t\t--depth;\n\t\t\t\t}\n\n\t\t\t\tif (depth < 1) {\n\t\t\t\t\tresult.nextMatch = parenRe.lastIndex;\n\t\t\t\t\tresult.str = str.slice(start, result.nextMatch - 1);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn result;\n\t\t}\n\n\t\tfunction parseSelector(idArg) {\n\t\t\tvar ids = [];\n\t\t\tvar idRe = /:?[^\\s:()]+/g;\n\t\t\tvar match = void 0;\n\n\t\t\twhile ((match = idRe.exec(idArg)) !== null) {\n\t\t\t\tvar id = match[0];\n\n\t\t\t\t// Group negation.\n\t\t\t\tif (id === ':not') {\n\t\t\t\t\tif (ids.length === 0) {\n\t\t\t\t\t\tthrow new Error('invalid negation: no group ID preceded \":not()\"');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar parent = ids[ids.length - 1];\n\n\t\t\t\t\tif (parent.id[0] !== ':') {\n\t\t\t\t\t\tthrow new Error('invalid negation of track \"' + parent.id + '\": only groups may be negated with \":not()\"');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar negation = processNegation(idArg, idRe.lastIndex);\n\n\t\t\t\t\tif (negation.nextMatch === -1) {\n\t\t\t\t\t\tthrow new Error('unknown error parsing \":not()\"');\n\t\t\t\t\t}\n\n\t\t\t\t\tidRe.lastIndex = negation.nextMatch;\n\t\t\t\t\tparent.not = parseSelector(negation.str);\n\t\t\t\t}\n\n\t\t\t\t// Group or track ID.\n\t\t\t\telse {\n\t\t\t\t\t\tids.push({ id: id });\n\t\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn ids;\n\t\t}\n\n\t\treturn parseSelector;\n\t}();\n\n\t/*\n \tSimpleAudio.select(selector).…;\n \t\tE.g.\n \t\tSimpleAudio.select(':ui').…\n \t\tSimpleAudio.select(':ui:not(boop)').…\n \t\tSimpleAudio.select('boop beep').…\n \t\tSimpleAudio.select(':ui :sfx').…\n \t\tSimpleAudio.select(':ui:not(boop) :sfx overthetop').…\n */\n\tfunction runnerGet() /* selector */{\n\t\tif (arguments.length === 0) {\n\t\t\tthrow new Error('no track selector specified');\n\t\t}\n\n\t\tvar selector = String(arguments[0]).trim();\n\t\tvar trackIds = new Set();\n\n\t\ttry {\n\t\t\tvar renderIds = function renderIds(idObj) {\n\t\t\t\tvar id = idObj.id;\n\t\t\t\tvar ids = void 0;\n\n\t\t\t\tswitch (id) {\n\t\t\t\t\tcase ':all':\n\t\t\t\t\t\tids = allIds;break;\n\t\t\t\t\tcase ':looped':\n\t\t\t\t\t\tids = allIds.filter(function (id) {\n\t\t\t\t\t\t\treturn _tracks.get(id).loop();\n\t\t\t\t\t\t});break;\n\t\t\t\t\tcase ':muted':\n\t\t\t\t\t\tids = allIds.filter(function (id) {\n\t\t\t\t\t\t\treturn _tracks.get(id).mute();\n\t\t\t\t\t\t});break;\n\t\t\t\t\tcase ':paused':\n\t\t\t\t\t\tids = allIds.filter(function (id) {\n\t\t\t\t\t\t\treturn _tracks.get(id).isPaused();\n\t\t\t\t\t\t});break;\n\t\t\t\t\tcase ':playing':\n\t\t\t\t\t\tids = allIds.filter(function (id) {\n\t\t\t\t\t\t\treturn _tracks.get(id).isPlaying();\n\t\t\t\t\t\t});break;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tids = id[0] === ':' ? _groups.get(id) : [id];break;\n\t\t\t\t}\n\n\t\t\t\tif (idObj.hasOwnProperty('not')) {\n\t\t\t\t\tvar negated = idObj.not.map(function (idObj) {\n\t\t\t\t\t\treturn renderIds(idObj);\n\t\t\t\t\t}).flat(Infinity);\n\t\t\t\t\tids = ids.filter(function (id) {\n\t\t\t\t\t\treturn !negated.includes(id);\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\treturn ids;\n\t\t\t};\n\n\t\t\tvar allIds = Array.from(_tracks.keys());\n\n\t\t\t_runnerParseSelector(selector).forEach(function (idObj) {\n\t\t\t\treturn renderIds(idObj).forEach(function (id) {\n\t\t\t\t\tif (!_tracks.has(id)) {\n\t\t\t\t\t\tthrow new Error('track \"' + id + '\" does not exist');\n\t\t\t\t\t}\n\n\t\t\t\t\ttrackIds.add(id);\n\t\t\t\t});\n\t\t\t});\n\t\t} catch (ex) {\n\t\t\tthrow new Error('error during runner initialization: ' + ex.message);\n\t\t}\n\n\t\treturn new AudioRunner(trackIds);\n\t}\n\n\t/*******************************************************************************************************************\n \tMaster Audio Functions.\n *******************************************************************************************************************/\n\tfunction masterLoad() {\n\t\tpublish('load');\n\t}\n\n\tfunction masterLoadWithScreen() {\n\t\tpublish('loadwithscreen');\n\t}\n\n\tfunction masterMute(mute) {\n\t\tif (mute == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn _masterMute;\n\t\t}\n\n\t\t_masterMute = !!mute;\n\t\tpublish('mute', _masterMute);\n\t}\n\n\tfunction masterMuteOnHidden(mute) {\n\t\tif (mute == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn _masterMuteOnHidden;\n\t\t}\n\n\t\t_masterMuteOnHidden = !!mute;\n\n\t\tif (_masterMuteOnHidden) {\n\t\t\tvar visibilityChange = Visibility.changeEvent + '.SimpleAudio_masterMuteOnHidden';\n\t\t\tjQuery(document).off(visibilityChange).on(visibilityChange, function () {\n\t\t\t\treturn masterMute(Visibility.isHidden());\n\t\t\t});\n\n\t\t\t// Only change the mute state initially if hidden.\n\t\t\tif (Visibility.isHidden()) {\n\t\t\t\tmasterMute(true);\n\t\t\t}\n\t\t} else {\n\t\t\tjQuery(document).off('.SimpleAudio_masterMuteOnHidden');\n\t\t}\n\t}\n\n\tfunction masterRate(rate) {\n\t\tif (rate == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn _masterRate;\n\t\t}\n\n\t\tif (typeof rate !== 'number' || Number.isNaN(rate) || !Number.isFinite(rate)) {\n\t\t\tthrow new Error('rate must be a finite number');\n\t\t}\n\n\t\t_masterRate = Math.clamp(rate, 0.2, 5); // clamp to 5× slower & faster\n\t\tpublish('rate', _masterRate);\n\t}\n\n\tfunction masterStop() {\n\t\tpublish('stop');\n\t}\n\n\tfunction masterUnload() {\n\t\tpublish('unload');\n\t}\n\n\tfunction masterVolume(volume) {\n\t\tif (volume == null) {\n\t\t\t// lazy equality for null\n\t\t\treturn _masterVolume;\n\t\t}\n\n\t\tif (typeof volume !== 'number' || Number.isNaN(volume) || !Number.isFinite(volume)) {\n\t\t\tthrow new Error('volume must be a finite number');\n\t\t}\n\n\t\t_masterVolume = Math.clamp(volume, 0, 1); // clamp to 0 (silent) & 1 (full loudness)\n\t\tpublish('volume', _masterVolume);\n\t}\n\n\t/*******************************************************************************************************************\n \tSubscription Functions.\n *******************************************************************************************************************/\n\tfunction subscribe(id, callback) {\n\t\tif (typeof callback !== 'function') {\n\t\t\tthrow new Error('callback parameter must be a function');\n\t\t}\n\n\t\t_subscribers.set(id, callback);\n\t}\n\n\tfunction unsubscribe(id) {\n\t\t_subscribers.delete(id);\n\t}\n\n\tfunction publish(mesg, data) {\n\t\t_subscribers.forEach(function (fn) {\n\t\t\treturn fn(mesg, data);\n\t\t});\n\t}\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\tfunction _newTrack(sources) {\n\t\treturn new AudioTrack(sources.map(function (source) {\n\t\t\t// Handle audio passages.\n\t\t\tif (source.slice(0, 5) !== 'data:' && Story.has(source)) {\n\t\t\t\tvar passage = Story.get(source);\n\n\t\t\t\tif (passage.tags.includes('Twine.audio')) {\n\t\t\t\t\treturn passage.text.trim();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Handle URIs—possibly prefixed with a format specifier.\n\t\t\tvar match = _formatSpecRe.exec(source);\n\t\t\treturn match === null ? source : {\n\t\t\t\tformat: match[1],\n\t\t\t\tsrc: match[2]\n\t\t\t};\n\t\t}));\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t// Track Functions.\n\t\ttracks: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tadd: { value: trackAdd },\n\t\t\t\tdelete: { value: trackDelete },\n\t\t\t\tclear: { value: trackClear },\n\t\t\t\thas: { value: trackHas },\n\t\t\t\tget: { value: trackGet }\n\t\t\t}))\n\t\t},\n\n\t\t// Group Functions.\n\t\tgroups: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tadd: { value: groupAdd },\n\t\t\t\tdelete: { value: groupDelete },\n\t\t\t\tclear: { value: groupClear },\n\t\t\t\thas: { value: groupHas },\n\t\t\t\tget: { value: groupGet }\n\t\t\t}))\n\t\t},\n\n\t\t// Playlist Functions.\n\t\tlists: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tadd: { value: listAdd },\n\t\t\t\tdelete: { value: listDelete },\n\t\t\t\tclear: { value: listClear },\n\t\t\t\thas: { value: listHas },\n\t\t\t\tget: { value: listGet }\n\t\t\t}))\n\t\t},\n\n\t\t// Runner Functions.\n\t\tselect: { value: runnerGet },\n\n\t\t// Master Audio Functions.\n\t\tload: { value: masterLoad },\n\t\tloadWithScreen: { value: masterLoadWithScreen },\n\t\tmute: { value: masterMute },\n\t\tmuteOnHidden: { value: masterMuteOnHidden },\n\t\trate: { value: masterRate },\n\t\tstop: { value: masterStop },\n\t\tunload: { value: masterUnload },\n\t\tvolume: { value: masterVolume }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tstate.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Config, Diff, Engine, PRNGWrapper, Patterns, clone, session, storage */\n\nvar State = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// History moment stack.\n\n\tvar _history = [];\n\n\t// Currently active/played moment.\n\tvar _active = momentCreate();\n\n\t// Currently active/played moment index.\n\tvar _activeIndex = -1;\n\n\t// Titles of all moments which have expired (i.e. fallen off the bottom of the stack).\n\tvar _expired = [];\n\n\t// (optional) Seedable PRNG object.\n\tvar _prng = null;\n\n\t// Temporary variables object.\n\tvar _tempVariables = {};\n\n\t/*******************************************************************************************************************\n \tState Functions.\n *******************************************************************************************************************/\n\t/*\n \tResets the story state.\n */\n\tfunction stateReset() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/stateReset()]');\n\t\t}\n\n\t\t/*\n  \tDelete the active session.\n  */\n\t\tsession.delete('state');\n\n\t\t/*\n  \tReset the properties.\n  */\n\t\t_history = [];\n\t\t_active = momentCreate();\n\t\t_activeIndex = -1;\n\t\t_expired = [];\n\t\t_prng = _prng === null ? null : new PRNGWrapper(_prng.seed, false);\n\t}\n\n\t/*\n \tRestores the story state from the active session.\n */\n\tfunction stateRestore() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/stateRestore()]');\n\t\t}\n\n\t\t/*\n  \tAttempt to restore an active session.\n  */\n\t\tif (session.has('state')) {\n\t\t\t/*\n   \tRetrieve the session.\n   */\n\t\t\tvar stateObj = session.get('state');\n\n\t\t\tif (DEBUG) {\n\t\t\t\tconsole.log('\\tsession state:', stateObj);\n\t\t\t}\n\n\t\t\tif (stateObj == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\t/*\n   \tRestore the session.\n   */\n\t\t\tstateUnmarshal(stateObj);\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/*\n \tReturns the current story state marshaled into a serializable object.\n */\n\tfunction stateMarshal(noDelta) {\n\t\t/*\n  \tGather the properties.\n  */\n\t\tvar stateObj = {\n\t\t\tindex: _activeIndex\n\t\t};\n\n\t\tif (noDelta) {\n\t\t\tstateObj.history = clone(_history);\n\t\t} else {\n\t\t\tstateObj.delta = historyDeltaEncode(_history);\n\t\t}\n\n\t\tif (_expired.length > 0) {\n\t\t\tstateObj.expired = [];\n\t\t}\n\n\t\tif (_prng !== null) {\n\t\t\tstateObj.seed = _prng.seed;\n\t\t}\n\n\t\treturn stateObj;\n\t}\n\n\t/*\n \tRestores the story state from a marshaled story state serialization object.\n */\n\tfunction stateUnmarshal(stateObj, noDelta) {\n\t\tif (stateObj == null) {\n\t\t\t// lazy equality for null\n\t\t\tthrow new Error('state object is null or undefined');\n\t\t}\n\n\t\tif (!stateObj.hasOwnProperty(noDelta ? 'history' : 'delta') || stateObj[noDelta ? 'history' : 'delta'].length === 0) {\n\t\t\tthrow new Error('state object has no history or history is empty');\n\t\t}\n\n\t\tif (!stateObj.hasOwnProperty('index')) {\n\t\t\tthrow new Error('state object has no index');\n\t\t}\n\n\t\tif (_prng !== null && !stateObj.hasOwnProperty('seed')) {\n\t\t\tthrow new Error('state object has no seed, but PRNG is enabled');\n\t\t}\n\n\t\tif (_prng === null && stateObj.hasOwnProperty('seed')) {\n\t\t\tthrow new Error('state object has seed, but PRNG is disabled');\n\t\t}\n\n\t\t/*\n  \tRestore the properties.\n  */\n\t\t_history = noDelta ? clone(stateObj.history) : historyDeltaDecode(stateObj.delta);\n\t\t_activeIndex = stateObj.index;\n\t\t_expired = stateObj.hasOwnProperty('expired') ? [].concat(_toConsumableArray(stateObj.expired)) : [];\n\n\t\tif (stateObj.hasOwnProperty('seed')) {\n\t\t\t/*\n   \tWe only need to restore the PRNG's seed here as `momentActivate()` will handle\n   \tfully restoring the PRNG to its proper state.\n   */\n\t\t\t_prng.seed = stateObj.seed;\n\t\t}\n\n\t\t/*\n  \tActivate the current moment (do this only after all properties have been restored).\n  */\n\t\tmomentActivate(_activeIndex);\n\t}\n\n\t/*\n \tReturns the current story state marshaled into a save-compatible serializable object.\n */\n\tfunction stateMarshalForSave() {\n\t\treturn stateMarshal(true);\n\t}\n\n\t/*\n \tRestores the story state from a marshaled save-compatible story state serialization object.\n */\n\tfunction stateUnmarshalForSave(stateObj) {\n\t\treturn stateUnmarshal(stateObj, true);\n\t}\n\n\t/*\n \tReturns the titles of expired moments.\n */\n\tfunction stateExpired() {\n\t\treturn _expired;\n\t}\n\n\t/*\n \tReturns the total number of played moments (expired + in-play history moments).\n */\n\tfunction stateTurns() {\n\t\treturn _expired.length + historyLength();\n\t}\n\n\t/*\n \tReturns the passage titles of all played moments (expired + in-play history moments).\n */\n\tfunction stateTitles() {\n\t\treturn _expired.concat(_history.slice(0, historyLength()).map(function (moment) {\n\t\t\treturn moment.title;\n\t\t}));\n\t}\n\n\t/*\n \tReturns whether a passage with the given title has been played (expired + in-play history moments).\n */\n\tfunction stateHasPlayed(title) {\n\t\tif (title == null || title === '') {\n\t\t\t// lazy equality for null\n\t\t\treturn false;\n\t\t}\n\n\t\tif (_expired.includes(title)) {\n\t\t\treturn true;\n\t\t} else if (_history.slice(0, historyLength()).some(function (moment) {\n\t\t\treturn moment.title === title;\n\t\t})) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/*******************************************************************************************************************\n \tMoment Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns a new moment object created from the given passage title and variables object.\n */\n\tfunction momentCreate(title, variables) {\n\t\treturn {\n\t\t\ttitle: title == null ? '' : String(title), // lazy equality for null\n\t\t\tvariables: variables == null ? {} : clone(variables) // lazy equality for null\n\t\t};\n\t}\n\n\t/*\n \tReturns the active (present) moment.\n */\n\tfunction momentActive() {\n\t\treturn _active;\n\t}\n\n\t/*\n \tReturns the index within the history of the active (present) moment.\n */\n\tfunction momentActiveIndex() {\n\t\treturn _activeIndex;\n\t}\n\n\t/*\n \tReturns the title from the active (present) moment.\n */\n\tfunction momentActiveTitle() {\n\t\treturn _active.title;\n\t}\n\n\t/*\n \tReturns the variables from the active (present) moment.\n */\n\tfunction momentActiveVariables() {\n\t\treturn _active.variables;\n\t}\n\n\t/*\n \tReturns the active (present) moment after setting it to either the given moment object\n \tor the moment object at the given history index.  Additionally, updates the active session\n \tand triggers a history update event.\n */\n\tfunction momentActivate(moment) {\n\t\tif (moment == null) {\n\t\t\t// lazy equality for null\n\t\t\tthrow new Error('moment activation attempted with null or undefined');\n\t\t}\n\n\t\t/*\n  \tSet the active moment.\n  */\n\t\tswitch (typeof moment === 'undefined' ? 'undefined' : _typeof(moment)) {\n\t\t\tcase 'object':\n\t\t\t\t_active = clone(moment);\n\t\t\t\tbreak;\n\n\t\t\tcase 'number':\n\t\t\t\tif (historyIsEmpty()) {\n\t\t\t\t\tthrow new Error('moment activation attempted with index on empty history');\n\t\t\t\t}\n\n\t\t\t\tif (moment < 0 || moment >= historySize()) {\n\t\t\t\t\tthrow new RangeError('moment activation attempted with out-of-bounds index; need [0, ' + (historySize() - 1) + '], got ' + moment);\n\t\t\t\t}\n\n\t\t\t\t_active = clone(_history[moment]);\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tthrow new TypeError('moment activation attempted with a \"' + (typeof moment === 'undefined' ? 'undefined' : _typeof(moment)) + '\"; must be an object or valid history stack index');\n\t\t}\n\n\t\t/*\n  \tRestore the seedable PRNG.\n  \t\tNOTE: We cannot simply set `_prng.pull` to `_active.pull` as that would\n  \tnot properly mutate the PRNG's internal state.\n  */\n\t\tif (_prng !== null) {\n\t\t\t_prng = PRNGWrapper.unmarshal({\n\t\t\t\tseed: _prng.seed,\n\t\t\t\tpull: _active.pull\n\t\t\t});\n\t\t}\n\n\t\t/*\n  \tUpdate the active session.\n  */\n\t\tsession.set('state', stateMarshal());\n\n\t\t/*\n  \tTrigger a global `:historyupdate` event.\n  \t\tNOTE: We do this here because setting a new active moment is a core component\n  \tof, virtually, all history updates.\n  */\n\t\tjQuery.event.trigger(':historyupdate');\n\n\t\treturn _active;\n\t}\n\n\t/*******************************************************************************************************************\n \tHistory Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns the moment history.\n */\n\tfunction historyGet() {\n\t\treturn _history;\n\t}\n\n\t/*\n \tReturns the number of active history moments (past only).\n */\n\tfunction historyLength() {\n\t\treturn _activeIndex + 1;\n\t}\n\n\t/*\n \tReturns the total number of history moments (past + future).\n */\n\tfunction historySize() {\n\t\treturn _history.length;\n\t}\n\n\t/*\n \tReturns whether the history is empty.\n */\n\tfunction historyIsEmpty() {\n\t\treturn _history.length === 0;\n\t}\n\n\t/*\n \tReturns the current (pre-play version of the active) moment within the history.\n */\n\tfunction historyCurrent() {\n\t\treturn _history.length > 0 ? _history[_activeIndex] : null;\n\t}\n\n\t/*\n \tReturns the topmost (most recent) moment within the history.\n */\n\tfunction historyTop() {\n\t\treturn _history.length > 0 ? _history[_history.length - 1] : null;\n\t}\n\n\t/*\n \tReturns the bottommost (least recent) moment within the history.\n */\n\tfunction historyBottom() {\n\t\treturn _history.length > 0 ? _history[0] : null;\n\t}\n\n\t/*\n \tReturns the moment at the given index within the history.\n */\n\tfunction historyIndex(index) {\n\t\tif (historyIsEmpty() || index < 0 || index > _activeIndex) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn _history[index];\n\t}\n\n\t/*\n \tReturns the moment at the given offset from the active moment within the history.\n */\n\tfunction historyPeek(offset) {\n\t\tif (historyIsEmpty()) {\n\t\t\treturn null;\n\t\t}\n\n\t\tvar lengthOffset = 1 + (offset ? Math.abs(offset) : 0);\n\n\t\tif (lengthOffset > historyLength()) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn _history[historyLength() - lengthOffset];\n\t}\n\n\t/*\n \tReturns whether a moment with the given title exists within the history.\n */\n\tfunction historyHas(title) {\n\t\tif (historyIsEmpty() || title == null || title === '') {\n\t\t\t// lazy equality for null\n\t\t\treturn false;\n\t\t}\n\n\t\tfor (var i = _activeIndex; i >= 0; --i) {\n\t\t\tif (_history[i].title === title) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/*\n \tCreates a new moment and pushes it onto the history, discarding future moments if necessary.\n */\n\tfunction historyCreate(title) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/historyCreate(title: \"' + title + '\")]');\n\t\t}\n\n\t\t/*\n  \tTODO: It might be good to have some assertions about the passage title here.\n  */\n\n\t\t/*\n  \tIf we're not at the top of the stack, discard the future moments.\n  */\n\t\tif (historyLength() < historySize()) {\n\t\t\tif (DEBUG) {\n\t\t\t\tconsole.log('\\tnon-top push; discarding ' + (historySize() - historyLength()) + ' future moments');\n\t\t\t}\n\n\t\t\t_history.splice(historyLength(), historySize() - historyLength());\n\t\t}\n\n\t\t/*\n  \tPush the new moment onto the history stack.\n  */\n\t\t_history.push(momentCreate(title, _active.variables));\n\n\t\tif (_prng) {\n\t\t\thistoryTop().pull = _prng.pull;\n\t\t}\n\n\t\t/*\n  \tTruncate the history, if necessary, by discarding moments from the bottom.\n  */\n\t\tif (Config.history.maxStates > 0) {\n\t\t\twhile (historySize() > Config.history.maxStates) {\n\t\t\t\t_expired.push(_history.shift().title);\n\t\t\t}\n\t\t}\n\n\t\t/*\n  \tActivate the new top moment.\n  */\n\t\t_activeIndex = historySize() - 1;\n\t\tmomentActivate(_activeIndex);\n\n\t\treturn historyLength();\n\t}\n\n\t/*\n \tActivate the moment at the given index within the history.\n */\n\tfunction historyGoTo(index) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/historyGoTo(index: ' + index + ')]');\n\t\t}\n\n\t\tif (index == null /* lazy equality for null */\n\t\t|| index < 0 || index >= historySize() || index === _activeIndex) {\n\t\t\treturn false;\n\t\t}\n\n\t\t_activeIndex = index;\n\t\tmomentActivate(_activeIndex);\n\n\t\treturn true;\n\t}\n\n\t/*\n \tActivate the moment at the given offset from the active moment within the history.\n */\n\tfunction historyGo(offset) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/historyGo(offset: ' + offset + ')]');\n\t\t}\n\n\t\tif (offset == null || offset === 0) {\n\t\t\t// lazy equality for null\n\t\t\treturn false;\n\t\t}\n\n\t\treturn historyGoTo(_activeIndex + offset);\n\t}\n\n\t/*\n \tReturns the delta encoded form of the given history array.\n */\n\tfunction historyDeltaEncode(historyArr) {\n\t\tif (!Array.isArray(historyArr)) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif (historyArr.length === 0) {\n\t\t\treturn [];\n\t\t}\n\n\t\tvar delta = [clone(historyArr[0])];\n\n\t\tfor (var i = 1, iend = historyArr.length; i < iend; ++i) {\n\t\t\tdelta.push(Diff.diff(historyArr[i - 1], historyArr[i]));\n\t\t}\n\n\t\treturn delta;\n\t}\n\n\t/*\n \tReturns a history array from the given delta encoded history array.\n */\n\tfunction historyDeltaDecode(delta) {\n\t\tif (!Array.isArray(delta)) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif (delta.length === 0) {\n\t\t\treturn [];\n\t\t}\n\n\t\tvar historyArr = [clone(delta[0])];\n\n\t\tfor (var i = 1, iend = delta.length; i < iend; ++i) {\n\t\t\thistoryArr.push(Diff.patch(historyArr[i - 1], delta[i]));\n\t\t}\n\n\t\treturn historyArr;\n\t}\n\n\t/*******************************************************************************************************************\n \tPRNG Functions.\n *******************************************************************************************************************/\n\tfunction prngInit(seed, useEntropy) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/prngInit(seed: ' + seed + ', useEntropy: ' + useEntropy + ')]');\n\t\t}\n\n\t\tif (!historyIsEmpty()) {\n\t\t\tvar scriptSection = void 0;\n\n\t\t\tif (TWINE1) {\n\t\t\t\t// for Twine 1\n\t\t\t\tscriptSection = 'a script-tagged passage';\n\t\t\t} else {\n\t\t\t\t// for Twine 2\n\t\t\t\tscriptSection = 'the Story JavaScript';\n\t\t\t}\n\n\t\t\tthrow new Error('State.initPRNG must be called during initialization, within either ' + scriptSection + ' or the StoryInit special passage');\n\t\t}\n\n\t\t_prng = new PRNGWrapper(seed, useEntropy);\n\t\t_active.pull = _prng.pull;\n\t}\n\n\tfunction prngIsEnabled() {\n\t\treturn _prng !== null;\n\t}\n\n\tfunction prngPull() {\n\t\treturn _prng ? _prng.pull : NaN;\n\t}\n\n\tfunction prngSeed() {\n\t\treturn _prng ? _prng.seed : null;\n\t}\n\n\tfunction prngRandom() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/prngRandom()]');\n\t\t}\n\n\t\treturn _prng ? _prng.random() : Math.random();\n\t}\n\n\t/*******************************************************************************************************************\n \tTemporary Variables Functions.\n *******************************************************************************************************************/\n\t/*\n \tClear the temporary variables.\n */\n\tfunction tempVariablesClear() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[State/tempVariablesReset()]');\n\t\t}\n\n\t\t_tempVariables = {};\n\n\t\t/* legacy */\n\t\tTempVariables = _tempVariables; // eslint-disable-line no-undef\n\t\t/* /legacy */\n\t}\n\n\t/*\n \tReturns the current temporary variables.\n */\n\tfunction tempVariables() {\n\t\treturn _tempVariables;\n\t}\n\n\t/*******************************************************************************************************************\n \tVariable Chain Parsing Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns the value of the given story/temporary variable.\n */\n\tfunction variableGet(name) {\n\t\tvar varData = _parseVariableChain(name);\n\n\t\tif (varData === null) {\n\t\t\treturn;\n\t\t}\n\n\t\tvar pNames = varData.names;\n\t\tvar retVal = varData.store;\n\n\t\tfor (var i = 0, iend = pNames.length; i < iend; ++i) {\n\t\t\tif (typeof retVal[pNames[i]] === 'undefined') {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tretVal = retVal[pNames[i]];\n\t\t}\n\n\t\treturn retVal;\n\t}\n\n\t/*\n \tSets the value of the given story/temporary variable.\n */\n\tfunction variableSet(name, value) {\n\t\tvar varData = _parseVariableChain(name);\n\n\t\tif (varData === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar pNames = varData.names;\n\t\tvar varName = pNames.pop();\n\t\tvar baseObj = varData.store;\n\n\t\tfor (var i = 0, iend = pNames.length; i < iend; ++i) {\n\t\t\tif (typeof baseObj[pNames[i]] === 'undefined') {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tbaseObj = baseObj[pNames[i]];\n\t\t}\n\n\t\tbaseObj[varName] = value;\n\t\treturn true;\n\t}\n\n\t/*\n \tReturns the property name chain of the given story/temporary variable,\n \twhich may be of arbitrary complexity.\n */\n\tvar _parseVarRegExp = new RegExp('^(?:' + Patterns.variableSigil + '(' + Patterns.identifier + ')|\\\\.(' + Patterns.identifier + ')|\\\\[(?:(?:\"((?:\\\\\\\\.|[^\"\\\\\\\\])+)\")|(?:\\'((?:\\\\\\\\.|[^\\'\\\\\\\\])+)\\')|(' + Patterns.variableSigil + Patterns.identifierFirstChar + '.*)|(\\\\d+))\\\\])');\n\tfunction _parseVariableChain(varText) {\n\t\tvar retVal = {\n\t\t\tstore: varText[0] === '$' ? State.variables : State.temporary,\n\t\t\tnames: []\n\t\t};\n\t\tvar text = varText;\n\t\tvar match = void 0;\n\n\t\twhile ((match = _parseVarRegExp.exec(text)) !== null) {\n\t\t\t// Remove full match from text.\n\t\t\ttext = text.slice(match[0].length);\n\n\t\t\t// Base variable.\n\t\t\tif (match[1]) {\n\t\t\t\tretVal.names.push(match[1]);\n\t\t\t}\n\n\t\t\t// Dot property.\n\t\t\telse if (match[2]) {\n\t\t\t\t\tretVal.names.push(match[2]);\n\t\t\t\t}\n\n\t\t\t\t// Square-bracketed property (double quoted).\n\t\t\t\telse if (match[3]) {\n\t\t\t\t\t\tretVal.names.push(match[3]);\n\t\t\t\t\t}\n\n\t\t\t\t\t// Square-bracketed property (single quoted).\n\t\t\t\t\telse if (match[4]) {\n\t\t\t\t\t\t\tretVal.names.push(match[4]);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Square-bracketed property (embedded variable).\n\t\t\t\t\t\telse if (match[5]) {\n\t\t\t\t\t\t\t\tretVal.names.push(variableGet(match[5]));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Square-bracketed property (numeric index).\n\t\t\t\t\t\t\telse if (match[6]) {\n\t\t\t\t\t\t\t\t\tretVal.names.push(Number(match[6]));\n\t\t\t\t\t\t\t\t}\n\t\t}\n\n\t\treturn text === '' ? retVal : null;\n\t}\n\n\t/*******************************************************************************************************************\n \tStory Metadata Functions.\n *******************************************************************************************************************/\n\tvar _METADATA_STORE = 'metadata';\n\n\tfunction metadataClear() {\n\t\tstorage.delete(_METADATA_STORE);\n\t}\n\n\tfunction metadataDelete(key) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('State.metadata.delete key parameter must be a string (received: ' + (typeof key === 'undefined' ? 'undefined' : _typeof(key)) + ')');\n\t\t}\n\n\t\tvar store = storage.get(_METADATA_STORE);\n\n\t\tif (store && store.hasOwnProperty(key)) {\n\t\t\tif (Object.keys(store).length === 1) {\n\t\t\t\tstorage.delete(_METADATA_STORE);\n\t\t\t} else {\n\t\t\t\tdelete store[key];\n\t\t\t\tstorage.set(_METADATA_STORE, store);\n\t\t\t}\n\t\t}\n\t}\n\n\tfunction metadataGet(key) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('State.metadata.get key parameter must be a string (received: ' + (typeof key === 'undefined' ? 'undefined' : _typeof(key)) + ')');\n\t\t}\n\n\t\tvar store = storage.get(_METADATA_STORE);\n\t\treturn store && store.hasOwnProperty(key) ? store[key] : undefined;\n\t}\n\n\tfunction metadataHas(key) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('State.metadata.has key parameter must be a string (received: ' + (typeof key === 'undefined' ? 'undefined' : _typeof(key)) + ')');\n\t\t}\n\n\t\tvar store = storage.get(_METADATA_STORE);\n\t\treturn store && store.hasOwnProperty(key);\n\t}\n\n\tfunction metadataSet(key, value) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('State.metadata.set key parameter must be a string (received: ' + (typeof key === 'undefined' ? 'undefined' : _typeof(key)) + ')');\n\t\t}\n\n\t\tif (typeof value === 'undefined') {\n\t\t\tmetadataDelete(key);\n\t\t} else {\n\t\t\tvar store = storage.get(_METADATA_STORE) || {};\n\t\t\tstore[key] = value;\n\t\t\tstorage.set(_METADATA_STORE, store);\n\t\t}\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tState Functions.\n  */\n\t\treset: { value: stateReset },\n\t\trestore: { value: stateRestore },\n\t\tmarshalForSave: { value: stateMarshalForSave },\n\t\tunmarshalForSave: { value: stateUnmarshalForSave },\n\t\texpired: { get: stateExpired },\n\t\tturns: { get: stateTurns },\n\t\tpassages: { get: stateTitles },\n\t\thasPlayed: { value: stateHasPlayed },\n\n\t\t/*\n  \tMoment Functions.\n  */\n\t\tactive: { get: momentActive },\n\t\tactiveIndex: { get: momentActiveIndex },\n\t\tpassage: { get: momentActiveTitle }, // shortcut for `State.active.title`\n\t\tvariables: { get: momentActiveVariables }, // shortcut for `State.active.variables`\n\n\t\t/*\n  \tHistory Functions.\n  */\n\t\thistory: { get: historyGet },\n\t\tlength: { get: historyLength },\n\t\tsize: { get: historySize },\n\t\tisEmpty: { value: historyIsEmpty },\n\t\tcurrent: { get: historyCurrent },\n\t\ttop: { get: historyTop },\n\t\tbottom: { get: historyBottom },\n\t\tindex: { value: historyIndex },\n\t\tpeek: { value: historyPeek },\n\t\thas: { value: historyHas },\n\t\tcreate: { value: historyCreate },\n\t\tgoTo: { value: historyGoTo },\n\t\tgo: { value: historyGo },\n\t\tdeltaEncode: { value: historyDeltaEncode },\n\t\tdeltaDecode: { value: historyDeltaDecode },\n\n\t\t/*\n  \tPRNG Functions.\n  */\n\t\tprng: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tinit: { value: prngInit },\n\t\t\t\tisEnabled: { value: prngIsEnabled },\n\t\t\t\tpull: { get: prngPull },\n\t\t\t\tseed: { get: prngSeed }\n\t\t\t}))\n\t\t},\n\t\trandom: { value: prngRandom },\n\n\t\t/*\n  \tTemporary Variables Functions.\n  */\n\t\tclearTemporary: { value: tempVariablesClear },\n\t\ttemporary: { get: tempVariables },\n\n\t\t/*\n  \tVariable Chain Parsing Functions.\n  */\n\t\tgetVar: { value: variableGet },\n\t\tsetVar: { value: variableSet },\n\n\t\t/*\n  \tStory Metadata Functions.\n  */\n\t\tmetadata: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tclear: { value: metadataClear },\n\t\t\t\tdelete: { value: metadataDelete },\n\t\t\t\tget: { value: metadataGet },\n\t\t\t\thas: { value: metadataHas },\n\t\t\t\tset: { value: metadataSet }\n\t\t\t}))\n\t\t},\n\n\t\t/*\n  \tLegacy Aliases.\n  */\n\t\tinitPRNG: { value: prngInit },\n\t\trestart: { value: function value() {\n\t\t\t\treturn Engine.restart();\n\t\t\t} },\n\t\tbackward: { value: function value() {\n\t\t\t\treturn Engine.backward();\n\t\t\t} },\n\t\tforward: { value: function value() {\n\t\t\t\treturn Engine.forward();\n\t\t\t} },\n\t\tdisplay: { value: function value() {\n\t\t\t\treturn Engine.display.apply(Engine, arguments);\n\t\t\t} },\n\t\tshow: { value: function value() {\n\t\t\t\treturn Engine.show.apply(Engine, arguments);\n\t\t\t} },\n\t\tplay: { value: function value() {\n\t\t\t\treturn Engine.play.apply(Engine, arguments);\n\t\t\t} }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tmarkup/scripting.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Engine, Patterns, State, Story, Util */\n\nvar Scripting = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/* eslint-disable no-unused-vars */\n\n\t/*******************************************************************************************************************\n \tDeprecated Legacy Functions.\n *******************************************************************************************************************/\n\t/*\n \t[DEPRECATED] Returns the jQuery-wrapped target element(s) after making them accessible\n \tclickables (ARIA compatibility).\n \t\tNOTE: Unused, included only for compatibility.\n */\n\n\tfunction addAccessibleClickHandler(targets, selector, handler, one, namespace) {\n\t\tif (arguments.length < 2) {\n\t\t\tthrow new Error('addAccessibleClickHandler insufficient number of parameters');\n\t\t}\n\n\t\tvar fn = void 0;\n\t\tvar opts = void 0;\n\n\t\tif (typeof selector === 'function') {\n\t\t\tfn = selector;\n\t\t\topts = {\n\t\t\t\tnamespace: one,\n\t\t\t\tone: !!handler\n\t\t\t};\n\t\t} else {\n\t\t\tfn = handler;\n\t\t\topts = {\n\t\t\t\tnamespace: namespace,\n\t\t\t\tone: !!one,\n\t\t\t\tselector: selector\n\t\t\t};\n\t\t}\n\n\t\tif (typeof fn !== 'function') {\n\t\t\tthrow new TypeError('addAccessibleClickHandler handler parameter must be a function');\n\t\t}\n\n\t\treturn jQuery(targets).ariaClick(opts, fn);\n\t}\n\n\t/*\n \t[DEPRECATED] Returns a new DOM element, optionally appending it to the passed DOM element, if any.\n \t\tNOTE: Unused, included only for compatibility.\n */\n\tfunction insertElement(place, type, id, classNames, text, title) {\n\t\t// eslint-disable-line max-params\n\t\tvar $el = jQuery(document.createElement(type));\n\n\t\t// Add attributes/properties.\n\t\tif (id) {\n\t\t\t$el.attr('id', id);\n\t\t}\n\n\t\tif (classNames) {\n\t\t\t$el.addClass(classNames);\n\t\t}\n\n\t\tif (title) {\n\t\t\t$el.attr('title', title);\n\t\t}\n\n\t\t// Add text content.\n\t\tif (text) {\n\t\t\t$el.text(text);\n\t\t}\n\n\t\t// Append it to the given node.\n\t\tif (place) {\n\t\t\t$el.appendTo(place);\n\t\t}\n\n\t\treturn $el[0];\n\t}\n\n\t/*\n \t[DEPRECATED] Creates a new text node and appends it to the passed DOM element.\n \t\tNOTE: Unused, included only for compatibility.\n */\n\tfunction insertText(place, text) {\n\t\tjQuery(place).append(document.createTextNode(text));\n\t}\n\n\t/*\n \t[DEPRECATED] Removes all children from the passed DOM node.\n \t\tNOTE: Unused, included only for compatibility.\n */\n\tfunction removeChildren(node) {\n\t\tjQuery(node).empty();\n\t}\n\n\t/*\n \t[DEPRECATED] Removes the passed DOM node.\n \t\tNOTE: Unused, included only for compatibility.\n */\n\tfunction removeElement(node) {\n\t\tjQuery(node).remove();\n\t}\n\n\t/*\n \t[DEPRECATED] Fades a DOM element in or out.\n \t\tNOTE: Unused, included only for compatibility.\n */\n\tfunction fade(el, options) {\n\t\t/* eslint-disable no-param-reassign */\n\t\tvar direction = options.fade === 'in' ? 1 : -1;\n\t\tvar current = void 0;\n\t\tvar proxy = el.cloneNode(true);\n\t\tvar intervalId = void 0; // eslint-disable-line prefer-const\n\n\t\tfunction tick() {\n\t\t\tcurrent += 0.05 * direction;\n\t\t\tsetOpacity(proxy, Math.easeInOut(current));\n\n\t\t\tif (direction === 1 && current >= 1 || direction === -1 && current <= 0) {\n\t\t\t\tel.style.visibility = options.fade === 'in' ? 'visible' : 'hidden';\n\t\t\t\tproxy.parentNode.replaceChild(el, proxy);\n\t\t\t\tproxy = null;\n\t\t\t\twindow.clearInterval(intervalId);\n\n\t\t\t\tif (options.onComplete) {\n\t\t\t\t\toptions.onComplete();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfunction setOpacity(el, opacity) {\n\t\t\t// Old IE.\n\t\t\tel.style.zoom = 1;\n\t\t\tel.style.filter = 'alpha(opacity=' + Math.floor(opacity * 100) + ')';\n\n\t\t\t// CSS.\n\t\t\tel.style.opacity = opacity;\n\t\t}\n\n\t\tel.parentNode.replaceChild(proxy, el);\n\n\t\tif (options.fade === 'in') {\n\t\t\tcurrent = 0;\n\t\t\tproxy.style.visibility = 'visible';\n\t\t} else {\n\t\t\tcurrent = 1;\n\t\t}\n\n\t\tsetOpacity(proxy, current);\n\t\tintervalId = window.setInterval(tick, 25);\n\t\t/* eslint-enable no-param-reassign */\n\t}\n\n\t/*\n \t[DEPRECATED] Scrolls the browser window to ensure that a DOM element is in view.\n \t\tNOTE: Unused, included only for compatibility.\n */\n\tfunction scrollWindowTo(el, incrementBy) {\n\t\t/* eslint-disable no-param-reassign */\n\t\tvar increment = incrementBy != null ? Number(incrementBy) : 0.1; // lazy equality for null\n\n\t\tif (Number.isNaN(increment) || !Number.isFinite(increment) || increment < 0) {\n\t\t\tincrement = 0.1;\n\t\t} else if (increment > 1) {\n\t\t\tincrement = 1;\n\t\t}\n\n\t\tvar start = window.scrollY ? window.scrollY : document.body.scrollTop;\n\t\tvar end = ensureVisible(el);\n\t\tvar distance = Math.abs(start - end);\n\t\tvar direction = start > end ? -1 : 1;\n\t\tvar progress = 0;\n\t\tvar intervalId = void 0; // eslint-disable-line prefer-const\n\n\t\tfunction tick() {\n\t\t\tprogress += increment;\n\t\t\twindow.scroll(0, start + direction * (distance * Math.easeInOut(progress)));\n\n\t\t\tif (progress >= 1) {\n\t\t\t\twindow.clearInterval(intervalId);\n\t\t\t}\n\t\t}\n\n\t\tfunction findPosY(el) {\n\t\t\t// eslint-disable-line no-shadow\n\t\t\tvar curtop = 0;\n\n\t\t\twhile (el.offsetParent) {\n\t\t\t\tcurtop += el.offsetTop;\n\t\t\t\tel = el.offsetParent;\n\t\t\t}\n\n\t\t\treturn curtop;\n\t\t}\n\n\t\tfunction ensureVisible(el) {\n\t\t\t// eslint-disable-line no-shadow\n\t\t\tvar posTop = findPosY(el);\n\t\t\tvar posBottom = posTop + el.offsetHeight;\n\t\t\tvar winTop = window.scrollY ? window.scrollY : document.body.scrollTop;\n\t\t\tvar winHeight = window.innerHeight ? window.innerHeight : document.body.clientHeight;\n\t\t\tvar winBottom = winTop + winHeight;\n\n\t\t\treturn posTop >= winTop && posBottom > winBottom && el.offsetHeight < winHeight ? posTop - (winHeight - el.offsetHeight) + 20 : posTop;\n\t\t}\n\n\t\tintervalId = window.setInterval(tick, 25);\n\t\t/* eslint-enable no-param-reassign */\n\t}\n\n\t/*******************************************************************************************************************\n \tUser Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns a random value from its given arguments.\n */\n\tfunction either() /* variadic */{\n\t\tif (arguments.length === 0) {\n\t\t\treturn;\n\t\t}\n\n\t\treturn Array.prototype.concat.apply([], arguments).random();\n\t}\n\n\t/*\n \tRemoves the given key, and its value, from the story metadata store.\n */\n\tfunction forget(key) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('forget key parameter must be a string (received: ' + Util.getType(key) + ')');\n\t\t}\n\n\t\tState.metadata.delete(key);\n\t}\n\n\t/*\n \tReturns whether a passage with the given title exists within the story\n \thistory.  If multiple passage titles are given, returns the logical-AND\n \taggregate of the set.\n */\n\tfunction hasVisited() /* variadic */{\n\t\tif (arguments.length === 0) {\n\t\t\tthrow new Error('hasVisited called with insufficient parameters');\n\t\t}\n\n\t\tif (State.isEmpty()) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar needles = Array.prototype.concat.apply([], arguments);\n\t\tvar played = State.passages;\n\n\t\tfor (var i = 0, iend = needles.length; i < iend; ++i) {\n\t\t\tif (!played.includes(needles[i])) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\n\t\treturn true;\n\t}\n\n\t/*\n \tReturns the number of turns that have passed since the last instance of the given passage\n \toccurred within the story history or `-1` if it does not exist.  If multiple passages are\n \tgiven, returns the lowest count (which can be `-1`).\n */\n\tfunction lastVisited() /* variadic */{\n\t\tif (arguments.length === 0) {\n\t\t\tthrow new Error('lastVisited called with insufficient parameters');\n\t\t}\n\n\t\tif (State.isEmpty()) {\n\t\t\treturn -1;\n\t\t}\n\n\t\tvar needles = Array.prototype.concat.apply([], arguments);\n\t\tvar played = State.passages;\n\t\tvar uBound = played.length - 1;\n\t\tvar turns = State.turns;\n\n\t\tfor (var i = 0, iend = needles.length; i < iend && turns > -1; ++i) {\n\t\t\tvar lastIndex = played.lastIndexOf(needles[i]);\n\t\t\tturns = Math.min(turns, lastIndex === -1 ? -1 : uBound - lastIndex);\n\t\t}\n\n\t\treturn turns;\n\t}\n\n\t/*\n \tSets the given key/value pair within the story metadata store.\n */\n\tfunction memorize(key, value) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('memorize key parameter must be a string (received: ' + Util.getType(key) + ')');\n\t\t}\n\n\t\tState.metadata.set(key, value);\n\t}\n\n\t/*\n \tReturns the title of the current passage.\n */\n\tfunction passage() {\n\t\treturn State.passage;\n\t}\n\n\t/*\n \tReturns the title of a previous passage, either the most recent one whose title does not\n \tmatch that of the active passage or the one at the optional offset, or an empty string,\n \tif there is no such passage.\n */\n\tfunction previous() /* legacy: offset */{\n\t\tvar passages = State.passages;\n\n\t\t/* legacy: behavior with an offset */\n\t\tif (arguments.length > 0) {\n\t\t\tvar offset = Number(arguments[0]);\n\n\t\t\tif (!Number.isSafeInteger(offset) || offset < 1) {\n\t\t\t\tthrow new RangeError('previous offset parameter must be a positive integer greater than zero');\n\t\t\t}\n\n\t\t\treturn passages.length > offset ? passages[passages.length - 1 - offset] : '';\n\t\t}\n\t\t/* /legacy */\n\n\t\tfor (var i = passages.length - 2; i >= 0; --i) {\n\t\t\tif (passages[i] !== State.passage) {\n\t\t\t\treturn passages[i];\n\t\t\t}\n\t\t}\n\n\t\treturn '';\n\t}\n\n\t/*\n \tReturns a pseudo-random whole number (integer) within the range of the given bounds.\n */\n\tfunction random() /* [min ,] max */{\n\t\tvar min = void 0;\n\t\tvar max = void 0;\n\n\t\tswitch (arguments.length) {\n\t\t\tcase 0:\n\t\t\t\tthrow new Error('random called with insufficient parameters');\n\t\t\tcase 1:\n\t\t\t\tmin = 0;\n\t\t\t\tmax = Math.trunc(arguments[0]);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tmin = Math.trunc(arguments[0]);\n\t\t\t\tmax = Math.trunc(arguments[1]);\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif (!Number.isInteger(min)) {\n\t\t\tthrow new Error('random min parameter must be an integer');\n\t\t}\n\t\tif (!Number.isInteger(max)) {\n\t\t\tthrow new Error('random max parameter must be an integer');\n\t\t}\n\n\t\tif (min > max) {\n\t\t\tvar _ref6 = [max, min];\n\t\t\tmin = _ref6[0];\n\t\t\tmax = _ref6[1];\n\t\t}\n\n\t\treturn Math.floor(State.random() * (max - min + 1)) + min;\n\t}\n\n\t/*\n \tReturns a pseudo-random real number (floating-point) within the range of the given bounds.\n \t\tNOTE: Unlike with its sibling function `random()`, the `max` parameter\n \tis exclusive, not inclusive—i.e. the range goes to, but does not include,\n \tthe given value.\n */\n\tfunction randomFloat() /* [min ,] max */{\n\t\tvar min = void 0;\n\t\tvar max = void 0;\n\n\t\tswitch (arguments.length) {\n\t\t\tcase 0:\n\t\t\t\tthrow new Error('randomFloat called with insufficient parameters');\n\t\t\tcase 1:\n\t\t\t\tmin = 0.0;\n\t\t\t\tmax = Number(arguments[0]);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tmin = Number(arguments[0]);\n\t\t\t\tmax = Number(arguments[1]);\n\t\t\t\tbreak;\n\t\t}\n\n\t\tif (Number.isNaN(min) || !Number.isFinite(min)) {\n\t\t\tthrow new Error('randomFloat min parameter must be a number');\n\t\t}\n\t\tif (Number.isNaN(max) || !Number.isFinite(max)) {\n\t\t\tthrow new Error('randomFloat max parameter must be a number');\n\t\t}\n\n\t\tif (min > max) {\n\t\t\tvar _ref7 = [max, min];\n\t\t\tmin = _ref7[0];\n\t\t\tmax = _ref7[1];\n\t\t}\n\n\t\treturn State.random() * (max - min) + min;\n\t}\n\n\t/*\n \tReturns the value of the given key from the story metadata store\n \tor the given default value if the key does not exist.\n */\n\tfunction recall(key, defaultValue) {\n\t\tif (typeof key !== 'string') {\n\t\t\tthrow new TypeError('recall key parameter must be a string (received: ' + Util.getType(key) + ')');\n\t\t}\n\n\t\treturn State.metadata.has(key) ? State.metadata.get(key) : defaultValue;\n\t}\n\n\t/*\n \tReturns a new array consisting of all of the tags of the given passages.\n */\n\tfunction tags() /* variadic */{\n\t\tif (arguments.length === 0) {\n\t\t\treturn Story.get(State.passage).tags.slice(0);\n\t\t}\n\n\t\tvar passages = Array.prototype.concat.apply([], arguments);\n\t\tvar tags = [];\n\n\t\tfor (var i = 0, iend = passages.length; i < iend; ++i) {\n\t\t\ttags = tags.concat(Story.get(passages[i]).tags);\n\t\t}\n\n\t\treturn tags;\n\t}\n\n\t/*\n \tReturns a reference to the current temporary _variables store.\n */\n\tfunction temporary() {\n\t\treturn State.temporary;\n\t}\n\n\t/*\n \tReturns the number of milliseconds which have passed since the current passage was rendered.\n */\n\tfunction time() {\n\t\treturn Engine.lastPlay === null ? 0 : Util.now() - Engine.lastPlay;\n\t}\n\n\t/*\n \tReturns the number of passages that the player has visited.\n \t\tNOTE: Passages which were visited but have been undone—e.g. via the backward\n \tbutton or the `<<back>>` macro—are no longer part of the in-play story\n \thistory and thus are not tallied.  Passages which were visited but have\n \texpired from the story history, on the other hand, are tallied.\n */\n\tfunction turns() {\n\t\treturn State.turns;\n\t}\n\n\t/*\n \tReturns a reference to the current story $variables store.\n */\n\tfunction variables() {\n\t\treturn State.variables;\n\t}\n\n\t/*\n \tReturns the number of times that the passage with the given title exists within the story\n \thistory.  If multiple passage titles are given, returns the lowest count.\n */\n\tfunction visited() /* variadic */{\n\t\tif (State.isEmpty()) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tvar needles = Array.prototype.concat.apply([], arguments.length === 0 ? [State.passage] : arguments);\n\t\tvar played = State.passages;\n\t\tvar count = State.turns;\n\n\t\tfor (var i = 0, iend = needles.length; i < iend && count > 0; ++i) {\n\t\t\tcount = Math.min(count, played.count(needles[i]));\n\t\t}\n\n\t\treturn count;\n\t}\n\n\t/*\n \tReturns the number of passages within the story history which are tagged with all of the given tags.\n */\n\tfunction visitedTags() /* variadic */{\n\t\tif (arguments.length === 0) {\n\t\t\tthrow new Error('visitedTags called with insufficient parameters');\n\t\t}\n\n\t\tif (State.isEmpty()) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tvar needles = Array.prototype.concat.apply([], arguments);\n\t\tvar nLength = needles.length;\n\t\tvar played = State.passages;\n\t\tvar seen = new Map();\n\t\tvar count = 0;\n\n\t\tfor (var i = 0, iend = played.length; i < iend; ++i) {\n\t\t\tvar title = played[i];\n\n\t\t\tif (seen.has(title)) {\n\t\t\t\tif (seen.get(title)) {\n\t\t\t\t\t++count;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tvar _tags2 = Story.get(title).tags;\n\n\t\t\t\tif (_tags2.length > 0) {\n\t\t\t\t\tvar found = 0;\n\n\t\t\t\t\tfor (var j = 0; j < nLength; ++j) {\n\t\t\t\t\t\tif (_tags2.includes(needles[j])) {\n\t\t\t\t\t\t\t++found;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (found === nLength) {\n\t\t\t\t\t\t++count;\n\t\t\t\t\t\tseen.set(title, true);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tseen.set(title, false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn count;\n\t}\n\n\t/* eslint-enable no-unused-vars */\n\n\t/*******************************************************************************************************************\n \tImport Functions.\n *******************************************************************************************************************/\n\n\tvar _ref8 = function () {\n\t\t// Slugify the given URL.\n\t\tfunction slugifyUrl(url) {\n\t\t\treturn Util.parseUrl(url).path.replace(/^[^\\w]+|[^\\w]+$/g, '').replace(/[^\\w]+/g, '-').toLocaleLowerCase();\n\t\t}\n\n\t\t// Add a <script> element which will load the script from the given URL.\n\t\tfunction addScript(url) {\n\t\t\treturn new Promise(function (resolve, reject) {\n\t\t\t\t/*\n    \tWARNING: The ordering of the code within this function is important,\n    \tas some browsers don't play well with different arrangements, so\n    \tbe careful when mucking around with it.\n    \t\tThe best supported ordering seems be: events → DOM append → attributes.\n    */\n\t\t\t\tjQuery(document.createElement('script')).one('load abort error', function (ev) {\n\t\t\t\t\tjQuery(ev.target).off();\n\n\t\t\t\t\tif (ev.type === 'load') {\n\t\t\t\t\t\tresolve(ev.target);\n\t\t\t\t\t} else {\n\t\t\t\t\t\treject(new Error('importScripts failed to load the script \"' + url + '\".'));\n\t\t\t\t\t}\n\t\t\t\t}).appendTo(document.head).attr({\n\t\t\t\t\tid: 'script-imported-' + slugifyUrl(url),\n\t\t\t\t\ttype: 'text/javascript',\n\t\t\t\t\tsrc: url\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\n\t\t// Add a <link> element which will load the stylesheet from the given URL.\n\t\tfunction addStyle(url) {\n\t\t\treturn new Promise(function (resolve, reject) {\n\t\t\t\t/*\n    \tWARNING: The ordering of the code within this function is important,\n    \tas some browsers don't play well with different arrangements, so\n    \tbe careful when mucking around with it.\n    \t\tThe best supported ordering seems be: events → DOM append → attributes.\n    */\n\t\t\t\tjQuery(document.createElement('link')).one('load abort error', function (ev) {\n\t\t\t\t\tjQuery(ev.target).off();\n\n\t\t\t\t\tif (ev.type === 'load') {\n\t\t\t\t\t\tresolve(ev.target);\n\t\t\t\t\t} else {\n\t\t\t\t\t\treject(new Error('importStyles failed to load the stylesheet \"' + url + '\".'));\n\t\t\t\t\t}\n\t\t\t\t}).appendTo(document.head).attr({\n\t\t\t\t\tid: 'style-imported-' + slugifyUrl(url),\n\t\t\t\t\trel: 'stylesheet',\n\t\t\t\t\thref: url\n\t\t\t\t});\n\t\t\t});\n\t\t}\n\n\t\t// Turn a list of callbacks into a sequential chain of `Promise` objects.\n\t\tfunction sequence(callbacks) {\n\t\t\treturn callbacks.reduce(function (seq, fn) {\n\t\t\t\treturn seq = seq.then(fn);\n\t\t\t}, Promise.resolve()); // eslint-disable-line no-param-reassign\n\t\t}\n\n\t\t/*\n  \tImport scripts from a URL.\n  */\n\t\tfunction importScripts() {\n\t\t\tfor (var _len12 = arguments.length, urls = Array(_len12), _key12 = 0; _key12 < _len12; _key12++) {\n\t\t\t\turls[_key12] = arguments[_key12];\n\t\t\t}\n\n\t\t\treturn Promise.all(urls.map(function (oneOrSeries) {\n\t\t\t\t// Array of URLs to be imported in sequence.\n\t\t\t\tif (Array.isArray(oneOrSeries)) {\n\t\t\t\t\treturn sequence(oneOrSeries.map(function (url) {\n\t\t\t\t\t\treturn function () {\n\t\t\t\t\t\t\treturn addScript(url);\n\t\t\t\t\t\t};\n\t\t\t\t\t}));\n\t\t\t\t}\n\n\t\t\t\t// Single URL to be imported.\n\t\t\t\treturn addScript(oneOrSeries);\n\t\t\t}));\n\t\t}\n\n\t\t/*\n  \tImport stylesheets from a URL.\n  */\n\t\tfunction importStyles() {\n\t\t\tfor (var _len13 = arguments.length, urls = Array(_len13), _key13 = 0; _key13 < _len13; _key13++) {\n\t\t\t\turls[_key13] = arguments[_key13];\n\t\t\t}\n\n\t\t\treturn Promise.all(urls.map(function (oneOrSeries) {\n\t\t\t\t// Array of URLs to be imported in sequence.\n\t\t\t\tif (Array.isArray(oneOrSeries)) {\n\t\t\t\t\treturn sequence(oneOrSeries.map(function (url) {\n\t\t\t\t\t\treturn function () {\n\t\t\t\t\t\t\treturn addStyle(url);\n\t\t\t\t\t\t};\n\t\t\t\t\t}));\n\t\t\t\t}\n\n\t\t\t\t// Single URL to be imported.\n\t\t\t\treturn addStyle(oneOrSeries);\n\t\t\t}));\n\t\t}\n\n\t\t// Exports.\n\t\treturn {\n\t\t\timportScripts: importScripts,\n\t\t\timportStyles: importStyles\n\t\t};\n\t}(),\n\t    importScripts = _ref8.importScripts,\n\t    importStyles = _ref8.importStyles;\n\n\t/*******************************************************************************************************************\n \tParsing Functions.\n *******************************************************************************************************************/\n\t/*\n \tReturns the given string after converting all TwineScript syntactical sugars to\n \ttheir native JavaScript counterparts.\n */\n\n\n\tvar parse = function () {\n\t\tvar parseMap = Object.freeze({\n\t\t\t/* eslint-disable quote-props */\n\t\t\t// Story $variable sigil-prefix.\n\t\t\t'$': 'State.variables.',\n\t\t\t// Temporary _variable sigil-prefix.\n\t\t\t'_': 'State.temporary.',\n\t\t\t// Assignment operators.\n\t\t\t'to': '=',\n\t\t\t// Equality operators.\n\t\t\t'eq': '==',\n\t\t\t'neq': '!=',\n\t\t\t'is': '===',\n\t\t\t'isnot': '!==',\n\t\t\t// Relational operators.\n\t\t\t'gt': '>',\n\t\t\t'gte': '>=',\n\t\t\t'lt': '<',\n\t\t\t'lte': '<=',\n\t\t\t// Logical operators.\n\t\t\t'and': '&&',\n\t\t\t'or': '||',\n\t\t\t// Unary operators.\n\t\t\t'not': '!',\n\t\t\t'def': '\"undefined\" !== typeof',\n\t\t\t'ndef': '\"undefined\" === typeof'\n\t\t\t/* eslint-enable quote-props */\n\t\t});\n\t\tvar parseRe = new RegExp(['(\"\"|\\'\\')', // 1=Empty quotes\n\t\t'(\"(?:\\\\\\\\.|[^\"\\\\\\\\])+\")', // 2=Double quoted, non-empty\n\t\t\"('(?:\\\\\\\\.|[^'\\\\\\\\])+')\", // 3=Single quoted, non-empty\n\t\t'([=+\\\\-*\\\\/%<>&\\\\|\\\\^~!?:,;\\\\(\\\\)\\\\[\\\\]{}]+)', // 4=Operator delimiters\n\t\t'([^\"\\'=+\\\\-*\\\\/%<>&\\\\|\\\\^~!?:,;\\\\(\\\\)\\\\[\\\\]{}\\\\s]+)' // 5=Barewords\n\t\t].join('|'), 'g');\n\t\tvar varTest = new RegExp('^' + Patterns.variable);\n\n\t\tfunction parse(rawCodeString) {\n\t\t\tif (parseRe.lastIndex !== 0) {\n\t\t\t\tthrow new RangeError('Scripting.parse last index is non-zero at start');\n\t\t\t}\n\n\t\t\tvar code = rawCodeString;\n\t\t\tvar match = void 0;\n\n\t\t\twhile ((match = parseRe.exec(code)) !== null) {\n\t\t\t\t// no-op: Empty quotes | Double quoted | Single quoted | Operator delimiters\n\n\t\t\t\t/*\n    \tBarewords.\n    */\n\t\t\t\tif (match[5]) {\n\t\t\t\t\tvar token = match[5];\n\n\t\t\t\t\t/*\n     \tIf the token is simply a dollar-sign or underscore, then it's either\n     \tjust the raw character or, probably, a function alias, so skip it.\n     */\n\t\t\t\t\tif (token === '$' || token === '_') {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t/*\n     \tIf the token is a story $variable or temporary _variable, reset it\n     \tto just its sigil—for later mapping.\n     */\n\t\t\t\t\telse if (varTest.test(token)) {\n\t\t\t\t\t\t\ttoken = token[0];\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/*\n      \tIf the token is `is`, check to see if it's followed by `not`, if so,\n      \tconvert them into the `isnot` operator.\n      \t\tNOTE: This is a safety feature, since `$a is not $b` probably sounds\n      \treasonable to most users.\n      */\n\t\t\t\t\t\telse if (token === 'is') {\n\t\t\t\t\t\t\t\tvar start = parseRe.lastIndex;\n\t\t\t\t\t\t\t\tvar part = code.slice(start);\n\n\t\t\t\t\t\t\t\tif (/^\\s+not\\b/.test(part)) {\n\t\t\t\t\t\t\t\t\tcode = code.splice(start, part.search(/\\S/));\n\t\t\t\t\t\t\t\t\ttoken = 'isnot';\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t/*\n     \tIf the finalized token has a mapping, replace it within the code string\n     \twith its counterpart.\n     \t\tNOTE: We must use `parseMap.hasOwnProperty(token)` here, rather than\n     \tsimply using something like `parseMap[token]`, otherwise tokens which\n     \tmatch properties from the prototype chain will cause shenanigans.\n     */\n\t\t\t\t\tif (parseMap.hasOwnProperty(token)) {\n\t\t\t\t\t\tcode = code.splice(match.index, // starting index\n\t\t\t\t\t\ttoken.length, // replace how many\n\t\t\t\t\t\tparseMap[token] // replacement string\n\t\t\t\t\t\t);\n\t\t\t\t\t\tparseRe.lastIndex += parseMap[token].length - token.length;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn code;\n\t\t}\n\n\t\treturn parse;\n\t}();\n\n\t/*******************************************************************************************************************\n \tEval Functions.\n *******************************************************************************************************************/\n\t/* eslint-disable no-eval, no-extra-parens, no-unused-vars */\n\t/*\n \tEvaluates the given JavaScript code and returns the result, throwing if there were errors.\n */\n\tfunction evalJavaScript(code, output) {\n\t\treturn function (code, output) {\n\t\t\treturn eval(code);\n\t\t}.call(output ? { output: output } : null, String(code), output);\n\t}\n\n\t/*\n \tEvaluates the given TwineScript code and returns the result, throwing if there were errors.\n */\n\tfunction evalTwineScript(code, output) {\n\t\treturn function (code, output) {\n\t\t\treturn eval(code);\n\t\t}.call(output ? { output: output } : null, parse(String(code)), output);\n\t}\n\t/* eslint-enable no-eval, no-extra-parens, no-unused-vars */\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tparse: { value: parse },\n\t\tevalJavaScript: { value: evalJavaScript },\n\t\tevalTwineScript: { value: evalTwineScript }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tmarkup/lexer.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n\nvar _ref9 = function () {\n\t'use strict';\n\n\t// End of file (string, actually).\n\n\tvar EOF = -1;\n\n\t/*******************************************************************************************************************\n \tLexer Class.\n *******************************************************************************************************************/\n\n\tvar Lexer = function () {\n\t\tfunction Lexer(source, initialState) {\n\t\t\t_classCallCheck(this, Lexer);\n\n\t\t\tif (arguments.length < 2) {\n\t\t\t\tthrow new Error('Lexer constructor called with too few parameters (source:string , initialState:function)');\n\t\t\t}\n\n\t\t\t/*\n   \tthis.source  → the string to be scanned\n   \tthis.initial → initial state\n   \tthis.state   → current state\n   \tthis.start   → start position of an item\n   \tthis.pos     → current position in the source string\n   \tthis.depth   → current brace/bracket/parenthesis nesting depth\n   \tthis.items   → scanned item queue\n   \tthis.data    → lexing data\n   */\n\t\t\tObject.defineProperties(this, {\n\t\t\t\tsource: {\n\t\t\t\t\tvalue: source\n\t\t\t\t},\n\n\t\t\t\tinitial: {\n\t\t\t\t\tvalue: initialState\n\t\t\t\t},\n\n\t\t\t\tstate: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: initialState\n\t\t\t\t},\n\n\t\t\t\tstart: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: 0\n\t\t\t\t},\n\n\t\t\t\tpos: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: 0\n\t\t\t\t},\n\n\t\t\t\tdepth: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: 0\n\t\t\t\t},\n\n\t\t\t\titems: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: []\n\t\t\t\t},\n\n\t\t\t\tdata: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: {}\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t_createClass(Lexer, [{\n\t\t\tkey: 'reset',\n\t\t\tvalue: function reset() {\n\t\t\t\tthis.state = this.initial;\n\t\t\t\tthis.start = 0;\n\t\t\t\tthis.pos = 0;\n\t\t\t\tthis.depth = 0;\n\t\t\t\tthis.items = [];\n\t\t\t\tthis.data = {};\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'run',\n\t\t\tvalue: function run() {\n\t\t\t\t// scan the source string until no states remain\n\t\t\t\twhile (this.state !== null) {\n\t\t\t\t\tthis.state = this.state(this);\n\t\t\t\t}\n\n\t\t\t\t// return the array of items\n\t\t\t\treturn this.items;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'nextItem',\n\t\t\tvalue: function nextItem() {\n\t\t\t\t// scan the source string until we have an item or no states remain\n\t\t\t\twhile (this.items.length === 0 && this.state !== null) {\n\t\t\t\t\tthis.state = this.state(this);\n\t\t\t\t}\n\n\t\t\t\t// return the current item\n\t\t\t\treturn this.items.shift();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'next',\n\t\t\tvalue: function next() {\n\t\t\t\tif (this.pos >= this.source.length) {\n\t\t\t\t\treturn EOF;\n\t\t\t\t}\n\n\t\t\t\treturn this.source[this.pos++];\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'peek',\n\t\t\tvalue: function peek() {\n\t\t\t\tif (this.pos >= this.source.length) {\n\t\t\t\t\treturn EOF;\n\t\t\t\t}\n\n\t\t\t\treturn this.source[this.pos];\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'backup',\n\t\t\tvalue: function backup(num) {\n\t\t\t\t// if (num) {\n\t\t\t\t// \tthis.pos -= num;\n\t\t\t\t// }\n\t\t\t\t// else {\n\t\t\t\t// \t--this.pos;\n\t\t\t\t// }\n\t\t\t\tthis.pos -= num || 1;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'forward',\n\t\t\tvalue: function forward(num) {\n\t\t\t\t// if (num) {\n\t\t\t\t// \tthis.pos += num;\n\t\t\t\t// }\n\t\t\t\t// else {\n\t\t\t\t// \t++this.pos;\n\t\t\t\t// }\n\t\t\t\tthis.pos += num || 1;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'ignore',\n\t\t\tvalue: function ignore() {\n\t\t\t\tthis.start = this.pos;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'accept',\n\t\t\tvalue: function accept(valid) {\n\t\t\t\tvar ch = this.next();\n\n\t\t\t\tif (ch === EOF) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tif (valid.includes(ch)) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\tthis.backup();\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'acceptRe',\n\t\t\tvalue: function acceptRe(validRe) {\n\t\t\t\tvar ch = this.next();\n\n\t\t\t\tif (ch === EOF) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tif (validRe.test(ch)) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\tthis.backup();\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'acceptRun',\n\t\t\tvalue: function acceptRun(valid) {\n\t\t\t\tfor (;;) {\n\t\t\t\t\tvar ch = this.next();\n\n\t\t\t\t\tif (ch === EOF) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!valid.includes(ch)) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tthis.backup();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'acceptRunRe',\n\t\t\tvalue: function acceptRunRe(validRe) {\n\t\t\t\tfor (;;) {\n\t\t\t\t\tvar ch = this.next();\n\n\t\t\t\t\tif (ch === EOF) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!validRe.test(ch)) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tthis.backup();\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'emit',\n\t\t\tvalue: function emit(type) {\n\t\t\t\tthis.items.push({\n\t\t\t\t\ttype: type,\n\t\t\t\t\ttext: this.source.slice(this.start, this.pos),\n\t\t\t\t\tstart: this.start,\n\t\t\t\t\tpos: this.pos\n\t\t\t\t});\n\t\t\t\tthis.start = this.pos;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'error',\n\t\t\tvalue: function error(type, message) {\n\t\t\t\tif (arguments.length < 2) {\n\t\t\t\t\tthrow new Error('Lexer.prototype.error called with too few parameters (type:number , message:string)');\n\t\t\t\t}\n\n\t\t\t\tthis.items.push({\n\t\t\t\t\ttype: type,\n\t\t\t\t\tmessage: message,\n\t\t\t\t\ttext: this.source.slice(this.start, this.pos),\n\t\t\t\t\tstart: this.start,\n\t\t\t\t\tpos: this.pos\n\t\t\t\t});\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}], [{\n\t\t\tkey: 'enumFromNames',\n\t\t\tvalue: function enumFromNames(names) {\n\t\t\t\tvar obj = names.reduce(function (obj, name, i) {\n\t\t\t\t\tobj[name] = i; // eslint-disable-line no-param-reassign\n\t\t\t\t\treturn obj;\n\t\t\t\t}, {});\n\t\t\t\treturn Object.freeze(Object.assign(Object.create(null), obj));\n\t\t\t}\n\t\t}]);\n\n\t\treturn Lexer;\n\t}();\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\n\n\treturn {\n\t\tEOF: EOF,\n\t\tLexer: Lexer\n\t};\n}(),\n    EOF = _ref9.EOF,\n    Lexer = _ref9.Lexer;\n\n/***********************************************************************************************************************\n\n\tmarkup/wikifier.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Config, EOF, Engine, Lexer, Patterns, Scripting, State, Story, TempState, Util, convertBreaks,\n\t       errorPrologRegExp\n*/\n\n/*\n\tTODO: The Wikifier, and associated code, could stand to receive a serious refactoring.\n*/\n/* eslint-disable max-len */\n\n\nvar Wikifier = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Wikifier call depth.\n\n\tvar _callDepth = 0;\n\n\t/*******************************************************************************************************************\n \tWikifier Class.\n *******************************************************************************************************************/\n\n\tvar Wikifier = function () {\n\t\tfunction Wikifier(destination, source, options) {\n\t\t\t_classCallCheck(this, Wikifier);\n\n\t\t\tif (Wikifier.Parser.Profile.isEmpty()) {\n\t\t\t\tWikifier.Parser.Profile.compile();\n\t\t\t}\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\t// General Wikifier properties.\n\t\t\t\tsource: {\n\t\t\t\t\tvalue: String(source)\n\t\t\t\t},\n\n\t\t\t\toptions: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: Object.assign({\n\t\t\t\t\t\tprofile: 'all'\n\t\t\t\t\t}, options)\n\t\t\t\t},\n\n\t\t\t\tnextMatch: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: 0\n\t\t\t\t},\n\n\t\t\t\toutput: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: null\n\t\t\t\t},\n\n\t\t\t\t// Macro parser ('macro') related properties.\n\t\t\t\t_rawArgs: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: ''\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// No destination specified.  Create a fragment to act as the output buffer.\n\t\t\tif (destination == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthis.output = document.createDocumentFragment();\n\t\t\t}\n\n\t\t\t// jQuery-wrapped destination.  Grab the first element.\n\t\t\telse if (destination.jquery) {\n\t\t\t\t\t// cannot use `hasOwnProperty()` here as `jquery` is from jQuery's prototype\n\t\t\t\t\tthis.output = destination[0];\n\t\t\t\t}\n\n\t\t\t\t// Normal destination.\n\t\t\t\telse {\n\t\t\t\t\t\tthis.output = destination;\n\t\t\t\t\t}\n\n\t\t\t/*\n   \tWikify the source into the output buffer element, possibly converting line\n   \tbreaks into paragraphs.\n   \t\tNOTE: There's no catch clause here because this try/finally exists solely\n   \tto ensure that the call depth is properly restored in the event that an\n   \tuncaught exception is thrown during the call to `subWikify()`.\n   */\n\t\t\ttry {\n\t\t\t\t++_callDepth;\n\n\t\t\t\tthis.subWikify(this.output);\n\n\t\t\t\t// Limit line break conversion to non-recursive calls.\n\t\t\t\tif (_callDepth === 1 && Config.cleanupWikifierOutput) {\n\t\t\t\t\tconvertBreaks(this.output);\n\t\t\t\t}\n\t\t\t} finally {\n\t\t\t\t--_callDepth;\n\t\t\t}\n\t\t}\n\n\t\t_createClass(Wikifier, [{\n\t\t\tkey: 'subWikify',\n\t\t\tvalue: function subWikify(output, terminator, options) {\n\t\t\t\t// Cache and temporarily replace the current output buffer and options.\n\t\t\t\tvar oldOutput = this.output;\n\t\t\t\tvar oldOptions = void 0;\n\n\t\t\t\tthis.output = output;\n\n\t\t\t\tif (options != null && (typeof options === 'undefined' ? 'undefined' : _typeof(options)) === 'object') {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\toldOptions = this.options;\n\t\t\t\t\tthis.options = Object.assign({}, this.options, options);\n\t\t\t\t}\n\n\t\t\t\tvar parsersProfile = Wikifier.Parser.Profile.get(this.options.profile);\n\t\t\t\tvar terminatorRegExp = terminator ? new RegExp('(?:' + terminator + ')', this.options.ignoreTerminatorCase ? 'gim' : 'gm') : null;\n\t\t\t\tvar terminatorMatch = void 0;\n\t\t\t\tvar parserMatch = void 0;\n\n\t\t\t\tdo {\n\t\t\t\t\t// Prepare the RegExp match positions.\n\t\t\t\t\tparsersProfile.parserRegExp.lastIndex = this.nextMatch;\n\n\t\t\t\t\tif (terminatorRegExp) {\n\t\t\t\t\t\tterminatorRegExp.lastIndex = this.nextMatch;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Get the first matches.\n\t\t\t\t\tparserMatch = parsersProfile.parserRegExp.exec(this.source);\n\t\t\t\t\tterminatorMatch = terminatorRegExp ? terminatorRegExp.exec(this.source) : null;\n\n\t\t\t\t\t// Try for a terminator match, unless there's a closer parser match.\n\t\t\t\t\tif (terminatorMatch && (!parserMatch || terminatorMatch.index <= parserMatch.index)) {\n\t\t\t\t\t\t// Output any text before the match.\n\t\t\t\t\t\tif (terminatorMatch.index > this.nextMatch) {\n\t\t\t\t\t\t\tthis.outputText(this.output, this.nextMatch, terminatorMatch.index);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Set the match parameters.\n\t\t\t\t\t\tthis.matchStart = terminatorMatch.index;\n\t\t\t\t\t\tthis.matchLength = terminatorMatch[0].length;\n\t\t\t\t\t\tthis.matchText = terminatorMatch[0];\n\t\t\t\t\t\tthis.nextMatch = terminatorRegExp.lastIndex;\n\n\t\t\t\t\t\t// Restore the original output buffer and options.\n\t\t\t\t\t\tthis.output = oldOutput;\n\n\t\t\t\t\t\tif (oldOptions) {\n\t\t\t\t\t\t\tthis.options = oldOptions;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Exit.\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Try for a parser match.\n\t\t\t\t\telse if (parserMatch) {\n\t\t\t\t\t\t\t// Output any text before the match.\n\t\t\t\t\t\t\tif (parserMatch.index > this.nextMatch) {\n\t\t\t\t\t\t\t\tthis.outputText(this.output, this.nextMatch, parserMatch.index);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Set the match parameters.\n\t\t\t\t\t\t\tthis.matchStart = parserMatch.index;\n\t\t\t\t\t\t\tthis.matchLength = parserMatch[0].length;\n\t\t\t\t\t\t\tthis.matchText = parserMatch[0];\n\t\t\t\t\t\t\tthis.nextMatch = parsersProfile.parserRegExp.lastIndex;\n\n\t\t\t\t\t\t\t// Figure out which parser matched.\n\t\t\t\t\t\t\tvar matchingParser = void 0;\n\n\t\t\t\t\t\t\tfor (var i = 1, iend = parserMatch.length; i < iend; ++i) {\n\t\t\t\t\t\t\t\tif (parserMatch[i]) {\n\t\t\t\t\t\t\t\t\tmatchingParser = i - 1;\n\t\t\t\t\t\t\t\t\tbreak; // stop once we've found the matching parser\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Call the parser.\n\t\t\t\t\t\t\tparsersProfile.parsers[matchingParser].handler(this);\n\n\t\t\t\t\t\t\tif (TempState.break != null) {\n\t\t\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t} while (terminatorMatch || parserMatch);\n\n\t\t\t\t// Output any text after the last match.\n\t\t\t\tif (TempState.break == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tif (this.nextMatch < this.source.length) {\n\t\t\t\t\t\tthis.outputText(this.output, this.nextMatch, this.source.length);\n\t\t\t\t\t\tthis.nextMatch = this.source.length;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// In case of <<break>>/<<continue>>, remove the last <br>.\n\t\t\t\telse if (this.output.lastChild && this.output.lastChild.nodeType === Node.ELEMENT_NODE && this.output.lastChild.nodeName.toUpperCase() === 'BR') {\n\t\t\t\t\t\tjQuery(this.output.lastChild).remove();\n\t\t\t\t\t}\n\n\t\t\t\t// Restore the original output buffer and options.\n\t\t\t\tthis.output = oldOutput;\n\n\t\t\t\tif (oldOptions) {\n\t\t\t\t\tthis.options = oldOptions;\n\t\t\t\t}\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'outputText',\n\t\t\tvalue: function outputText(destination, startPos, endPos) {\n\t\t\t\tjQuery(destination).append(document.createTextNode(this.source.substring(startPos, endPos)));\n\t\t\t}\n\n\t\t\t/*\n   \t[DEPRECATED] Meant to be called by legacy macros, this returns the raw, unprocessed\n   \ttext given to the currently executing macro.\n   */\n\n\t\t}, {\n\t\t\tkey: 'rawArgs',\n\t\t\tvalue: function rawArgs() {\n\t\t\t\treturn this._rawArgs;\n\t\t\t}\n\n\t\t\t/*\n   \t[DEPRECATED] Meant to be called by legacy macros, this returns the text given to\n   \tthe currently executing macro after doing TwineScript-to-JavaScript transformations.\n   */\n\n\t\t}, {\n\t\t\tkey: 'fullArgs',\n\t\t\tvalue: function fullArgs() {\n\t\t\t\treturn Scripting.parse(this._rawArgs);\n\t\t\t}\n\n\t\t\t/*\n   \tReturns the output generated by wikifying the given text, throwing if there were errors.\n   */\n\n\t\t}], [{\n\t\t\tkey: 'wikifyEval',\n\t\t\tvalue: function wikifyEval(text) {\n\t\t\t\tvar output = document.createDocumentFragment();\n\n\t\t\t\tnew Wikifier(output, text);\n\n\t\t\t\tvar errors = output.querySelector('.error');\n\n\t\t\t\tif (errors !== null) {\n\t\t\t\t\tthrow new Error(errors.textContent.replace(errorPrologRegExp, ''));\n\t\t\t\t}\n\n\t\t\t\treturn output;\n\t\t\t}\n\n\t\t\t/*\n   \tCreate and return an internal link.\n   */\n\n\t\t}, {\n\t\t\tkey: 'createInternalLink',\n\t\t\tvalue: function createInternalLink(destination, passage, text, callback) {\n\t\t\t\tvar $link = jQuery(document.createElement('a'));\n\n\t\t\t\tif (passage != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t$link.attr('data-passage', passage);\n\n\t\t\t\t\tif (Story.has(passage)) {\n\t\t\t\t\t\t$link.addClass('link-internal');\n\n\t\t\t\t\t\tif (Config.addVisitedLinkClass && State.hasPlayed(passage)) {\n\t\t\t\t\t\t\t$link.addClass('link-visited');\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$link.addClass('link-broken');\n\t\t\t\t\t}\n\n\t\t\t\t\t$link.ariaClick({ one: true }, function () {\n\t\t\t\t\t\tif (typeof callback === 'function') {\n\t\t\t\t\t\t\tcallback();\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tEngine.play(passage);\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tif (text) {\n\t\t\t\t\t$link.append(document.createTextNode(text));\n\t\t\t\t}\n\n\t\t\t\tif (destination) {\n\t\t\t\t\t$link.appendTo(destination);\n\t\t\t\t}\n\n\t\t\t\t// For legacy-compatibility we must return the DOM node.\n\t\t\t\treturn $link[0];\n\t\t\t}\n\n\t\t\t/*\n   \tCreate and return an external link.\n   */\n\n\t\t}, {\n\t\t\tkey: 'createExternalLink',\n\t\t\tvalue: function createExternalLink(destination, url, text) {\n\t\t\t\tvar $link = jQuery(document.createElement('a')).attr('target', '_blank').addClass('link-external').text(text).appendTo(destination);\n\n\t\t\t\tif (url != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t$link.attr({\n\t\t\t\t\t\thref: url,\n\t\t\t\t\t\ttabindex: 0 // for accessiblity\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t// For legacy-compatibility we must return the DOM node.\n\t\t\t\treturn $link[0];\n\t\t\t}\n\n\t\t\t/*\n   \tReturns whether the given link source is external (probably).\n   */\n\n\t\t}, {\n\t\t\tkey: 'isExternalLink',\n\t\t\tvalue: function isExternalLink(link) {\n\t\t\t\tif (Story.has(link)) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tvar urlRegExp = new RegExp('^' + Patterns.url, 'gim');\n\t\t\t\treturn urlRegExp.test(link) || /[/.?#]/.test(link);\n\t\t\t}\n\t\t}]);\n\n\t\treturn Wikifier;\n\t}();\n\n\t/*******************************************************************************************************************\n \tParser Static Object.\n *******************************************************************************************************************/\n\n\n\tObject.defineProperty(Wikifier, 'Parser', {\n\t\tvalue: function () {\n\t\t\t// Parser definition array.  Ordering matters, so this must be an ordered list.\n\t\t\tvar _parsers = [];\n\n\t\t\t// Parser profiles object.\n\t\t\tvar _profiles = void 0;\n\n\t\t\t/*\n   \tParser Functions.\n   */\n\t\t\tfunction parsersGetter() {\n\t\t\t\treturn _parsers;\n\t\t\t}\n\n\t\t\tfunction parsersAdd(parser) {\n\t\t\t\t// Parser object sanity checks.\n\t\t\t\tif ((typeof parser === 'undefined' ? 'undefined' : _typeof(parser)) !== 'object') {\n\t\t\t\t\tthrow new Error('Wikifier.Parser.add parser parameter must be an object');\n\t\t\t\t}\n\n\t\t\t\tif (!parser.hasOwnProperty('name')) {\n\t\t\t\t\tthrow new Error('parser object missing required \"name\" property');\n\t\t\t\t} else if (typeof parser.name !== 'string') {\n\t\t\t\t\tthrow new Error('parser object \"name\" property must be a string');\n\t\t\t\t}\n\n\t\t\t\tif (!parser.hasOwnProperty('match')) {\n\t\t\t\t\tthrow new Error('parser object missing required \"match\" property');\n\t\t\t\t} else if (typeof parser.match !== 'string') {\n\t\t\t\t\tthrow new Error('parser object \"match\" property must be a string');\n\t\t\t\t}\n\n\t\t\t\tif (!parser.hasOwnProperty('handler')) {\n\t\t\t\t\tthrow new Error('parser object missing required \"handler\" property');\n\t\t\t\t} else if (typeof parser.handler !== 'function') {\n\t\t\t\t\tthrow new Error('parser object \"handler\" property must be a function');\n\t\t\t\t}\n\n\t\t\t\tif (parser.hasOwnProperty('profiles') && !Array.isArray(parser.profiles)) {\n\t\t\t\t\tthrow new Error('parser object \"profiles\" property must be an array');\n\t\t\t\t}\n\n\t\t\t\t// Check for an existing parser with the same name.\n\t\t\t\tif (parsersHas(parser.name)) {\n\t\t\t\t\tthrow new Error('cannot clobber existing parser \"' + parser.name + '\"');\n\t\t\t\t}\n\n\t\t\t\t// Add the parser to the end of the array.\n\t\t\t\t_parsers.push(parser);\n\t\t\t}\n\n\t\t\tfunction parsersDelete(name) {\n\t\t\t\tvar parser = _parsers.find(function (parser) {\n\t\t\t\t\treturn parser.name === name;\n\t\t\t\t});\n\n\t\t\t\tif (parser) {\n\t\t\t\t\t_parsers.delete(parser);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfunction parsersIsEmpty() {\n\t\t\t\treturn _parsers.length === 0;\n\t\t\t}\n\n\t\t\tfunction parsersHas(name) {\n\t\t\t\treturn !!_parsers.find(function (parser) {\n\t\t\t\t\treturn parser.name === name;\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tfunction parsersGet(name) {\n\t\t\t\treturn _parsers.find(function (parser) {\n\t\t\t\t\treturn parser.name === name;\n\t\t\t\t}) || null;\n\t\t\t}\n\n\t\t\t/*\n   \tParser Profile Functions.\n   */\n\t\t\tfunction profilesGetter() {\n\t\t\t\treturn _profiles;\n\t\t\t}\n\n\t\t\tfunction profilesCompile() {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[Wikifier.Parser/profilesCompile()]');\n\t\t\t\t}\n\n\t\t\t\tvar all = _parsers;\n\t\t\t\tvar core = all.filter(function (parser) {\n\t\t\t\t\treturn !Array.isArray(parser.profiles) || parser.profiles.includes('core');\n\t\t\t\t});\n\n\t\t\t\t_profiles = Object.freeze({\n\t\t\t\t\tall: {\n\t\t\t\t\t\tparsers: all,\n\t\t\t\t\t\tparserRegExp: new RegExp(all.map(function (parser) {\n\t\t\t\t\t\t\treturn '(' + parser.match + ')';\n\t\t\t\t\t\t}).join('|'), 'gm')\n\t\t\t\t\t},\n\t\t\t\t\tcore: {\n\t\t\t\t\t\tparsers: core,\n\t\t\t\t\t\tparserRegExp: new RegExp(core.map(function (parser) {\n\t\t\t\t\t\t\treturn '(' + parser.match + ')';\n\t\t\t\t\t\t}).join('|'), 'gm')\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\treturn _profiles;\n\t\t\t}\n\n\t\t\tfunction profilesIsEmpty() {\n\t\t\t\treturn (typeof _profiles === 'undefined' ? 'undefined' : _typeof(_profiles)) !== 'object' || Object.keys(_profiles).length === 0;\n\t\t\t}\n\n\t\t\tfunction profilesGet(profile) {\n\t\t\t\tif ((typeof _profiles === 'undefined' ? 'undefined' : _typeof(_profiles)) !== 'object' || !_profiles.hasOwnProperty(profile)) {\n\t\t\t\t\tthrow new Error('nonexistent parser profile \"' + profile + '\"');\n\t\t\t\t}\n\n\t\t\t\treturn _profiles[profile];\n\t\t\t}\n\n\t\t\tfunction profilesHas(profile) {\n\t\t\t\treturn (typeof _profiles === 'undefined' ? 'undefined' : _typeof(_profiles)) === 'object' && _profiles.hasOwnProperty(profile);\n\t\t\t}\n\n\t\t\t/*\n   \tExports.\n   */\n\t\t\treturn Object.freeze(Object.defineProperties({}, {\n\t\t\t\t/*\n    \tParser Containers.\n    */\n\t\t\t\tparsers: { get: parsersGetter },\n\n\t\t\t\t/*\n    \tParser Functions.\n    */\n\t\t\t\tadd: { value: parsersAdd },\n\t\t\t\tdelete: { value: parsersDelete },\n\t\t\t\tisEmpty: { value: parsersIsEmpty },\n\t\t\t\thas: { value: parsersHas },\n\t\t\t\tget: { value: parsersGet },\n\n\t\t\t\t/*\n    \tParser Profile.\n    */\n\t\t\t\tProfile: {\n\t\t\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\t\t\t/*\n      \tProfiles Containers.\n      */\n\t\t\t\t\t\tprofiles: { get: profilesGetter },\n\n\t\t\t\t\t\t/*\n      \tProfiles Functions.\n      */\n\t\t\t\t\t\tcompile: { value: profilesCompile },\n\t\t\t\t\t\tisEmpty: { value: profilesIsEmpty },\n\t\t\t\t\t\thas: { value: profilesHas },\n\t\t\t\t\t\tget: { value: profilesGet }\n\t\t\t\t\t}))\n\t\t\t\t}\n\t\t\t}));\n\t\t}()\n\t});\n\n\t/*******************************************************************************************************************\n \tAdditional Static Properties.\n *******************************************************************************************************************/\n\tObject.defineProperties(Wikifier, {\n\t\thelpers: { value: {} },\n\n\t\t/*\n  \tLegacy Aliases.\n  */\n\t\tgetValue: { value: State.getVar }, // SEE: `state.js`.\n\t\tsetValue: { value: State.setVar }, // SEE: `state.js`.\n\t\tparse: { value: Scripting.parse }, // SEE: `markup/scripting.js`.\n\t\tevalExpression: { value: Scripting.evalTwineScript }, // SEE: `markup/scripting.js`.\n\t\tevalStatements: { value: Scripting.evalTwineScript }, // SEE: `markup/scripting.js`.\n\t\ttextPrimitives: { value: Patterns // SEE: `lib/patterns.js`.\n\t\t} });\n\n\t/*******************************************************************************************************************\n \tHelper Static Methods.\n *******************************************************************************************************************/\n\tObject.defineProperties(Wikifier.helpers, {\n\t\tinlineCss: {\n\t\t\tvalue: function () {\n\t\t\t\tvar lookahead = new RegExp(Patterns.inlineCss, 'gm');\n\n\t\t\t\tfunction helperInlineCss(w) {\n\t\t\t\t\tvar css = { classes: [], id: '', styles: {} };\n\t\t\t\t\tvar matched = void 0;\n\n\t\t\t\t\tdo {\n\t\t\t\t\t\tlookahead.lastIndex = w.nextMatch;\n\n\t\t\t\t\t\tvar match = lookahead.exec(w.source);\n\n\t\t\t\t\t\tmatched = match && match.index === w.nextMatch;\n\n\t\t\t\t\t\tif (matched) {\n\t\t\t\t\t\t\tif (match[1]) {\n\t\t\t\t\t\t\t\tcss.styles[Util.fromCssProperty(match[1])] = match[2].trim();\n\t\t\t\t\t\t\t} else if (match[3]) {\n\t\t\t\t\t\t\t\tcss.styles[Util.fromCssProperty(match[3])] = match[4].trim();\n\t\t\t\t\t\t\t} else if (match[5]) {\n\t\t\t\t\t\t\t\tcss.classes = css.classes.concat(match[5].slice(1).split(/\\./));\n\t\t\t\t\t\t\t} else if (match[6]) {\n\t\t\t\t\t\t\t\tcss.id = match[6].slice(1).split(/#/).pop();\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tw.nextMatch = lookahead.lastIndex; // eslint-disable-line no-param-reassign\n\t\t\t\t\t\t}\n\t\t\t\t\t} while (matched);\n\n\t\t\t\t\treturn css;\n\t\t\t\t}\n\n\t\t\t\treturn helperInlineCss;\n\t\t\t}()\n\t\t},\n\n\t\tevalText: {\n\t\t\tvalue: function value(text) {\n\t\t\t\tvar result = void 0;\n\n\t\t\t\ttry {\n\t\t\t\t\tresult = Scripting.evalTwineScript(text);\n\n\t\t\t\t\t/*\n     \tAttempt to prevent the leakage of auto-globals by enforcing that\n     \tthe resultant value be either a string or a number.\n     \t\tNOTE: This is not a foolproof solution to the problem of auto-global\n     \tleakage.  Various auto-globals, which return strings or numbers, can\n     \tstill leak through—e.g. `window.status` → string.\n     */\n\t\t\t\t\tswitch (typeof result === 'undefined' ? 'undefined' : _typeof(result)) {\n\t\t\t\t\t\tcase 'string':\n\t\t\t\t\t\t\tif (result.trim() === '') {\n\t\t\t\t\t\t\t\tresult = text;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'number':\n\t\t\t\t\t\t\tresult = String(result);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tresult = text;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\tresult = text;\n\t\t\t\t}\n\n\t\t\t\treturn result;\n\t\t\t}\n\t\t},\n\n\t\tevalPassageId: {\n\t\t\tvalue: function value(passage) {\n\t\t\t\tif (passage == null || Story.has(passage)) {\n\t\t\t\t\t// lazy equality for null; `0` is a valid name, so we cannot simply evaluate `passage`\n\t\t\t\t\treturn passage;\n\t\t\t\t}\n\n\t\t\t\treturn Wikifier.helpers.evalText(passage);\n\t\t\t}\n\t\t},\n\n\t\thasBlockContext: {\n\t\t\tvalue: function value(nodes) {\n\t\t\t\tvar hasGCS = typeof window.getComputedStyle === 'function';\n\n\t\t\t\tfor (var i = nodes.length - 1; i >= 0; --i) {\n\t\t\t\t\tvar node = nodes[i];\n\n\t\t\t\t\tswitch (node.nodeType) {\n\t\t\t\t\t\tcase Node.ELEMENT_NODE:\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvar tagName = node.nodeName.toUpperCase();\n\n\t\t\t\t\t\t\t\tif (tagName === 'BR') {\n\t\t\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tvar styles = hasGCS ? window.getComputedStyle(node, null) : node.currentStyle;\n\n\t\t\t\t\t\t\t\tif (styles && styles.display) {\n\t\t\t\t\t\t\t\t\tif (styles.display === 'none') {\n\t\t\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\treturn styles.display === 'block';\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t/*\n        \tWebKit/Blink-based browsers do not attach any computed style\n        \tinformation to elements until they're inserted into the DOM\n        \t(and probably visible), not even the default browser styles\n        \tand any user styles.  So, we make an assumption based on the\n        \telement.\n        */\n\t\t\t\t\t\t\t\tswitch (tagName) {\n\t\t\t\t\t\t\t\t\tcase 'ADDRESS':\n\t\t\t\t\t\t\t\t\tcase 'ARTICLE':\n\t\t\t\t\t\t\t\t\tcase 'ASIDE':\n\t\t\t\t\t\t\t\t\tcase 'BLOCKQUOTE':\n\t\t\t\t\t\t\t\t\tcase 'CENTER':\n\t\t\t\t\t\t\t\t\tcase 'DIV':\n\t\t\t\t\t\t\t\t\tcase 'DL':\n\t\t\t\t\t\t\t\t\tcase 'FIGURE':\n\t\t\t\t\t\t\t\t\tcase 'FOOTER':\n\t\t\t\t\t\t\t\t\tcase 'FORM':\n\t\t\t\t\t\t\t\t\tcase 'H1':\n\t\t\t\t\t\t\t\t\tcase 'H2':\n\t\t\t\t\t\t\t\t\tcase 'H3':\n\t\t\t\t\t\t\t\t\tcase 'H4':\n\t\t\t\t\t\t\t\t\tcase 'H5':\n\t\t\t\t\t\t\t\t\tcase 'H6':\n\t\t\t\t\t\t\t\t\tcase 'HEADER':\n\t\t\t\t\t\t\t\t\tcase 'HR':\n\t\t\t\t\t\t\t\t\tcase 'MAIN':\n\t\t\t\t\t\t\t\t\tcase 'NAV':\n\t\t\t\t\t\t\t\t\tcase 'OL':\n\t\t\t\t\t\t\t\t\tcase 'P':\n\t\t\t\t\t\t\t\t\tcase 'PRE':\n\t\t\t\t\t\t\t\t\tcase 'SECTION':\n\t\t\t\t\t\t\t\t\tcase 'TABLE':\n\t\t\t\t\t\t\t\t\tcase 'UL':\n\t\t\t\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\treturn false;\n\n\t\t\t\t\t\tcase Node.COMMENT_NODE:\n\t\t\t\t\t\t\tcontinue;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t},\n\n\t\tcreateShadowSetterCallback: {\n\t\t\tvalue: function () {\n\t\t\t\tvar macroParser = null;\n\n\t\t\t\tfunction cacheMacroParser() {\n\t\t\t\t\tif (!macroParser) {\n\t\t\t\t\t\tmacroParser = Wikifier.Parser.get('macro');\n\n\t\t\t\t\t\tif (!macroParser) {\n\t\t\t\t\t\t\tthrow new Error('cannot find \"macro\" parser');\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\treturn macroParser;\n\t\t\t\t}\n\n\t\t\t\tfunction getMacroContextShadowView() {\n\t\t\t\t\tvar macro = macroParser || cacheMacroParser();\n\t\t\t\t\tvar view = new Set();\n\n\t\t\t\t\tfor (var context = macro.context; context !== null; context = context.parent) {\n\t\t\t\t\t\tif (context._shadows) {\n\t\t\t\t\t\t\tcontext._shadows.forEach(function (name) {\n\t\t\t\t\t\t\t\treturn view.add(name);\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\treturn [].concat(_toConsumableArray(view));\n\t\t\t\t}\n\n\t\t\t\tfunction helperCreateShadowSetterCallback(code) {\n\t\t\t\t\tvar shadowStore = {};\n\n\t\t\t\t\tgetMacroContextShadowView().forEach(function (varName) {\n\t\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\t\t\t\t\t\tshadowStore[varName] = store[varKey];\n\t\t\t\t\t});\n\n\t\t\t\t\treturn function () {\n\t\t\t\t\t\tvar shadowNames = Object.keys(shadowStore);\n\t\t\t\t\t\tvar valueCache = shadowNames.length > 0 ? {} : null;\n\n\t\t\t\t\t\t/*\n      \tThere's no catch clause because this try/finally is here simply to ensure that\n      \tproper cleanup is done in the event that an exception is thrown during the\n      \tevaluation.\n      */\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t/*\n       \tCache the existing values of the variables to be shadowed and assign the\n       \tshadow values.\n       */\n\t\t\t\t\t\t\tshadowNames.forEach(function (varName) {\n\t\t\t\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\n\t\t\t\t\t\t\t\tif (store.hasOwnProperty(varKey)) {\n\t\t\t\t\t\t\t\t\tvalueCache[varKey] = store[varKey];\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tstore[varKey] = shadowStore[varName];\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t// Evaluate the JavaScript.\n\t\t\t\t\t\t\treturn Scripting.evalJavaScript(code);\n\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t// Revert the variable shadowing.\n\t\t\t\t\t\t\tshadowNames.forEach(function (varName) {\n\t\t\t\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\n\t\t\t\t\t\t\t\t/*\n        \tUpdate the shadow store with the variable's current value, in case it\n        \twas modified during the callback.\n        */\n\t\t\t\t\t\t\t\tshadowStore[varName] = store[varKey];\n\n\t\t\t\t\t\t\t\tif (valueCache.hasOwnProperty(varKey)) {\n\t\t\t\t\t\t\t\t\tstore[varKey] = valueCache[varKey];\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tdelete store[varKey];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t}\n\n\t\t\t\treturn helperCreateShadowSetterCallback;\n\t\t\t}()\n\t\t},\n\n\t\tparseSquareBracketedMarkup: {\n\t\t\tvalue: function () {\n\t\t\t\t/* eslint-disable no-param-reassign */\n\t\t\t\tvar Item = Lexer.enumFromNames([// lex item types object (pseudo-enumeration)\n\t\t\t\t'Error', // error\n\t\t\t\t'DelimLTR', // '|' or '->'\n\t\t\t\t'DelimRTL', // '<-'\n\t\t\t\t'InnerMeta', // ']['\n\t\t\t\t'ImageMeta', // '[img[', '[<img[', or '[>img['\n\t\t\t\t'LinkMeta', // '[['\n\t\t\t\t'Link', // link destination\n\t\t\t\t'RightMeta', // ']]'\n\t\t\t\t'Setter', // setter expression\n\t\t\t\t'Source', // image source\n\t\t\t\t'Text' // link text or image alt text\n\t\t\t\t]);\n\t\t\t\tvar Delim = Lexer.enumFromNames([// delimiter state object (pseudo-enumeration)\n\t\t\t\t'None', // no delimiter encountered\n\t\t\t\t'LTR', // '|' or '->'\n\t\t\t\t'RTL' // '<-'\n\t\t\t\t]);\n\n\t\t\t\t// Lexing functions.\n\t\t\t\tfunction slurpQuote(lexer, endQuote) {\n\t\t\t\t\tloop: for (;;) {\n\t\t\t\t\t\t/* eslint-disable indent */\n\t\t\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\t\t\tcase '\\\\':\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tvar ch = lexer.next();\n\n\t\t\t\t\t\t\t\t\tif (ch !== EOF && ch !== '\\n') {\n\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t/* falls through */\n\t\t\t\t\t\t\tcase EOF:\n\t\t\t\t\t\t\tcase '\\n':\n\t\t\t\t\t\t\t\treturn EOF;\n\n\t\t\t\t\t\t\tcase endQuote:\n\t\t\t\t\t\t\t\tbreak loop;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t/* eslint-enable indent */\n\t\t\t\t\t}\n\n\t\t\t\t\treturn lexer.pos;\n\t\t\t\t}\n\n\t\t\t\tfunction lexLeftMeta(lexer) {\n\t\t\t\t\tif (!lexer.accept('[')) {\n\t\t\t\t\t\treturn lexer.error(Item.Error, 'malformed square-bracketed markup');\n\t\t\t\t\t}\n\n\t\t\t\t\t// Is link markup.\n\t\t\t\t\tif (lexer.accept('[')) {\n\t\t\t\t\t\tlexer.data.isLink = true;\n\t\t\t\t\t\tlexer.emit(Item.LinkMeta);\n\t\t\t\t\t}\n\n\t\t\t\t\t// May be image markup.\n\t\t\t\t\telse {\n\t\t\t\t\t\t\tlexer.accept('<>'); // aligner syntax\n\n\t\t\t\t\t\t\tif (!lexer.accept('Ii') || !lexer.accept('Mm') || !lexer.accept('Gg') || !lexer.accept('[')) {\n\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'malformed square-bracketed markup');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tlexer.data.isLink = false;\n\t\t\t\t\t\t\tlexer.emit(Item.ImageMeta);\n\t\t\t\t\t\t}\n\n\t\t\t\t\tlexer.depth = 2; // account for both initial left square brackets\n\t\t\t\t\treturn lexCoreComponents;\n\t\t\t\t}\n\n\t\t\t\tfunction lexCoreComponents(lexer) {\n\t\t\t\t\tvar what = lexer.data.isLink ? 'link' : 'image';\n\t\t\t\t\tvar delim = Delim.None;\n\n\t\t\t\t\tfor (;;) {\n\t\t\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\t\t\tcase EOF:\n\t\t\t\t\t\t\tcase '\\n':\n\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated ' + what + ' markup');\n\n\t\t\t\t\t\t\tcase '\"':\n\t\t\t\t\t\t\t\t/*\n        \tThis is not entirely reliable within sections that allow raw strings, since\n        \tit's possible, however unlikely, for a raw string to contain unpaired double\n        \tquotes.  The likelihood is low enough, however, that I'm deeming the risk as\n        \tacceptable—for now, at least.\n        */\n\t\t\t\t\t\t\t\tif (slurpQuote(lexer, '\"') === EOF) {\n\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated double quoted string in ' + what + ' markup');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase '|':\n\t\t\t\t\t\t\t\t// possible pipe ('|') delimiter\n\t\t\t\t\t\t\t\tif (delim === Delim.None) {\n\t\t\t\t\t\t\t\t\tdelim = Delim.LTR;\n\t\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.Text);\n\t\t\t\t\t\t\t\t\tlexer.forward();\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.DelimLTR);\n\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase '-':\n\t\t\t\t\t\t\t\t// possible right arrow ('->') delimiter\n\t\t\t\t\t\t\t\tif (delim === Delim.None && lexer.peek() === '>') {\n\t\t\t\t\t\t\t\t\tdelim = Delim.LTR;\n\t\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.Text);\n\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.DelimLTR);\n\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase '<':\n\t\t\t\t\t\t\t\t// possible left arrow ('<-') delimiter\n\t\t\t\t\t\t\t\tif (delim === Delim.None && lexer.peek() === '-') {\n\t\t\t\t\t\t\t\t\tdelim = Delim.RTL;\n\t\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t\t\tlexer.emit(lexer.data.isLink ? Item.Link : Item.Source);\n\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.DelimRTL);\n\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase '[':\n\t\t\t\t\t\t\t\t++lexer.depth;\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase ']':\n\t\t\t\t\t\t\t\t--lexer.depth;\n\n\t\t\t\t\t\t\t\tif (lexer.depth === 1) {\n\t\t\t\t\t\t\t\t\tswitch (lexer.peek()) {\n\t\t\t\t\t\t\t\t\t\tcase '[':\n\t\t\t\t\t\t\t\t\t\t\t++lexer.depth;\n\t\t\t\t\t\t\t\t\t\t\tlexer.backup();\n\n\t\t\t\t\t\t\t\t\t\t\tif (delim === Delim.RTL) {\n\t\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.Text);\n\t\t\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t\t\tlexer.emit(lexer.data.isLink ? Item.Link : Item.Source);\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.InnerMeta);\n\t\t\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t\t\t\treturn lexer.data.isLink ? lexSetter : lexImageLink;\n\n\t\t\t\t\t\t\t\t\t\tcase ']':\n\t\t\t\t\t\t\t\t\t\t\t--lexer.depth;\n\t\t\t\t\t\t\t\t\t\t\tlexer.backup();\n\n\t\t\t\t\t\t\t\t\t\t\tif (delim === Delim.RTL) {\n\t\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.Text);\n\t\t\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t\t\tlexer.emit(lexer.data.isLink ? Item.Link : Item.Source);\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.RightMeta);\n\t\t\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t\t\t\treturn null;\n\n\t\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'malformed ' + what + ' markup');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tfunction lexImageLink(lexer) {\n\t\t\t\t\tvar what = lexer.data.isLink ? 'link' : 'image';\n\n\t\t\t\t\tfor (;;) {\n\t\t\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\t\t\tcase EOF:\n\t\t\t\t\t\t\tcase '\\n':\n\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated ' + what + ' markup');\n\n\t\t\t\t\t\t\tcase '\"':\n\t\t\t\t\t\t\t\t/*\n        \tThis is not entirely reliable within sections that allow raw strings, since\n        \tit's possible, however unlikely, for a raw string to contain unpaired double\n        \tquotes.  The likelihood is low enough, however, that I'm deeming the risk as\n        \tacceptable—for now, at least.\n        */\n\t\t\t\t\t\t\t\tif (slurpQuote(lexer, '\"') === EOF) {\n\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated double quoted string in ' + what + ' markup link component');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase '[':\n\t\t\t\t\t\t\t\t++lexer.depth;\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase ']':\n\t\t\t\t\t\t\t\t--lexer.depth;\n\n\t\t\t\t\t\t\t\tif (lexer.depth === 1) {\n\t\t\t\t\t\t\t\t\tswitch (lexer.peek()) {\n\t\t\t\t\t\t\t\t\t\tcase '[':\n\t\t\t\t\t\t\t\t\t\t\t++lexer.depth;\n\t\t\t\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.Link);\n\t\t\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.InnerMeta);\n\t\t\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t\t\t\treturn lexSetter;\n\n\t\t\t\t\t\t\t\t\t\tcase ']':\n\t\t\t\t\t\t\t\t\t\t\t--lexer.depth;\n\t\t\t\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.Link);\n\t\t\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\t\t\tlexer.emit(Item.RightMeta);\n\t\t\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t\t\t\treturn null;\n\n\t\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'malformed ' + what + ' markup');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tfunction lexSetter(lexer) {\n\t\t\t\t\tvar what = lexer.data.isLink ? 'link' : 'image';\n\n\t\t\t\t\tfor (;;) {\n\t\t\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\t\t\tcase EOF:\n\t\t\t\t\t\t\tcase '\\n':\n\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated ' + what + ' markup');\n\n\t\t\t\t\t\t\tcase '\"':\n\t\t\t\t\t\t\t\tif (slurpQuote(lexer, '\"') === EOF) {\n\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated double quoted string in ' + what + ' markup setter component');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase \"'\":\n\t\t\t\t\t\t\t\tif (slurpQuote(lexer, \"'\") === EOF) {\n\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated single quoted string in ' + what + ' markup setter component');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase '[':\n\t\t\t\t\t\t\t\t++lexer.depth;\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase ']':\n\t\t\t\t\t\t\t\t--lexer.depth;\n\n\t\t\t\t\t\t\t\tif (lexer.depth === 1) {\n\t\t\t\t\t\t\t\t\tif (lexer.peek() !== ']') {\n\t\t\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'malformed ' + what + ' markup');\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t--lexer.depth;\n\t\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.Setter);\n\t\t\t\t\t\t\t\t\tlexer.forward(2);\n\t\t\t\t\t\t\t\t\tlexer.emit(Item.RightMeta);\n\t\t\t\t\t\t\t\t\t// lexer.ignore();\n\t\t\t\t\t\t\t\t\treturn null;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Parse function.\n\t\t\t\tfunction parseSquareBracketedMarkup(w) {\n\t\t\t\t\t// Initialize the lexer.\n\t\t\t\t\tvar lexer = new Lexer(w.source, lexLeftMeta);\n\n\t\t\t\t\t// Set the initial positions within the source string.\n\t\t\t\t\tlexer.start = lexer.pos = w.matchStart;\n\n\t\t\t\t\t// Lex the raw argument string.\n\t\t\t\t\tvar markup = {};\n\t\t\t\t\tvar items = lexer.run();\n\t\t\t\t\tvar last = items.last();\n\n\t\t\t\t\tif (last && last.type === Item.Error) {\n\t\t\t\t\t\tmarkup.error = last.message;\n\t\t\t\t\t} else {\n\t\t\t\t\t\titems.forEach(function (item) {\n\t\t\t\t\t\t\tvar text = item.text.trim();\n\n\t\t\t\t\t\t\tswitch (item.type) {\n\t\t\t\t\t\t\t\tcase Item.ImageMeta:\n\t\t\t\t\t\t\t\t\tmarkup.isImage = true;\n\n\t\t\t\t\t\t\t\t\tif (text[1] === '<') {\n\t\t\t\t\t\t\t\t\t\tmarkup.align = 'left';\n\t\t\t\t\t\t\t\t\t} else if (text[1] === '>') {\n\t\t\t\t\t\t\t\t\t\tmarkup.align = 'right';\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\tcase Item.LinkMeta:\n\t\t\t\t\t\t\t\t\tmarkup.isLink = true;\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\tcase Item.Link:\n\t\t\t\t\t\t\t\t\tif (text[0] === '~') {\n\t\t\t\t\t\t\t\t\t\tmarkup.forceInternal = true;\n\t\t\t\t\t\t\t\t\t\tmarkup.link = text.slice(1);\n\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\tmarkup.link = text;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\tcase Item.Setter:\n\t\t\t\t\t\t\t\t\tmarkup.setter = text;\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\tcase Item.Source:\n\t\t\t\t\t\t\t\t\tmarkup.source = text;\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\tcase Item.Text:\n\t\t\t\t\t\t\t\t\tmarkup.text = text;\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\n\t\t\t\t\tmarkup.pos = lexer.pos;\n\t\t\t\t\treturn markup;\n\t\t\t\t}\n\n\t\t\t\treturn parseSquareBracketedMarkup;\n\t\t\t\t/* eslint-enable no-param-reassign */\n\t\t\t}()\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Wikifier;\n}();\n/* eslint-enable max-len */\n\n/***********************************************************************************************************************\n\n\tmarkup/parserlib.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Config, DebugView, EOF, Engine, Lexer, Macro, MacroContext, Patterns, Scripting, State, Story, Template,\n\t       Wikifier, toStringOrDefault, throwError\n*/\n/* eslint \"no-param-reassign\": [ 2, { \"props\" : false } ] */\n\n(function () {\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\n\tfunction _verbatimTagHandler(w) {\n\t\tthis.lookahead.lastIndex = w.matchStart;\n\n\t\tvar match = this.lookahead.exec(w.source);\n\n\t\tif (match && match.index === w.matchStart) {\n\t\t\tw.nextMatch = this.lookahead.lastIndex;\n\n\t\t\tjQuery(document.createDocumentFragment()).append(match[1]).appendTo(w.output);\n\t\t}\n\t}\n\n\t/*******************************************************************************************************************\n \tParsers.\n *******************************************************************************************************************/\n\tWikifier.Parser.add({\n\t\tname: 'quoteByBlock',\n\t\tprofiles: ['block'],\n\t\tmatch: '^<<<\\\\n',\n\t\tterminator: '^<<<\\\\n',\n\n\t\thandler: function handler(w) {\n\t\t\tif (!Wikifier.helpers.hasBlockContext(w.output.childNodes)) {\n\t\t\t\tjQuery(w.output).append(document.createTextNode(w.matchText));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tw.subWikify(jQuery(document.createElement('blockquote')).appendTo(w.output).get(0), this.terminator);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'quoteByLine',\n\t\tprofiles: ['block'],\n\t\tmatch: '^>+',\n\t\tlookahead: /^>+/gm,\n\t\tterminator: '\\\\n',\n\n\t\thandler: function handler(w) {\n\t\t\tif (!Wikifier.helpers.hasBlockContext(w.output.childNodes)) {\n\t\t\t\tjQuery(w.output).append(document.createTextNode(w.matchText));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar destStack = [w.output];\n\t\t\tvar curLevel = 0;\n\t\t\tvar newLevel = w.matchLength;\n\t\t\tvar matched = void 0;\n\t\t\tvar i = void 0;\n\n\t\t\tdo {\n\t\t\t\tif (newLevel > curLevel) {\n\t\t\t\t\tfor (i = curLevel; i < newLevel; ++i) {\n\t\t\t\t\t\tdestStack.push(jQuery(document.createElement('blockquote')).appendTo(destStack[destStack.length - 1]).get(0));\n\t\t\t\t\t}\n\t\t\t\t} else if (newLevel < curLevel) {\n\t\t\t\t\tfor (i = curLevel; i > newLevel; --i) {\n\t\t\t\t\t\tdestStack.pop();\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tcurLevel = newLevel;\n\t\t\t\tw.subWikify(destStack[destStack.length - 1], this.terminator);\n\t\t\t\tjQuery(document.createElement('br')).appendTo(destStack[destStack.length - 1]);\n\n\t\t\t\tthis.lookahead.lastIndex = w.nextMatch;\n\n\t\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\t\tmatched = match && match.index === w.nextMatch;\n\n\t\t\t\tif (matched) {\n\t\t\t\t\tnewLevel = match[0].length;\n\t\t\t\t\tw.nextMatch += match[0].length;\n\t\t\t\t}\n\t\t\t} while (matched);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'macro',\n\t\tprofiles: ['core'],\n\t\tmatch: '<<',\n\t\tlookahead: new RegExp('<<(/?' + Patterns.macroName + ')(?:\\\\s*)((?:(?:`(?:\\\\\\\\.|[^`\\\\\\\\])*`)|(?:\"(?:\\\\\\\\.|[^\"\\\\\\\\])*\")|(?:\\'(?:\\\\\\\\.|[^\\'\\\\\\\\])*\\')|(?:\\\\[(?:[<>]?[Ii][Mm][Gg])?\\\\[[^\\\\r\\\\n]*?\\\\]\\\\]+)|[^>]|(?:>(?!>)))*)>>', 'gm'),\n\t\tworking: { source: '', name: '', arguments: '', index: 0 }, // the working parse object\n\t\tcontext: null, // last execution context object (top-level macros, hierarchically, have a null context)\n\n\t\thandler: function handler(w) {\n\t\t\tvar matchStart = this.lookahead.lastIndex = w.matchStart;\n\n\t\t\tif (this.parseTag(w)) {\n\t\t\t\t/*\n    \tIf `parseBody()` is called below, it will modify the current working\n    \tvalues, so we must cache them now.\n    */\n\t\t\t\tvar nextMatch = w.nextMatch;\n\t\t\t\tvar name = this.working.name;\n\t\t\t\tvar rawArgs = this.working.arguments;\n\t\t\t\tvar macro = void 0;\n\n\t\t\t\ttry {\n\t\t\t\t\tmacro = Macro.get(name);\n\n\t\t\t\t\tif (macro) {\n\t\t\t\t\t\tvar payload = null;\n\n\t\t\t\t\t\tif (macro.hasOwnProperty('tags')) {\n\t\t\t\t\t\t\tpayload = this.parseBody(w, macro);\n\n\t\t\t\t\t\t\tif (!payload) {\n\t\t\t\t\t\t\t\tw.nextMatch = nextMatch; // we must reset `w.nextMatch` here, as `parseBody()` modifies it\n\t\t\t\t\t\t\t\treturn throwError(w.output, 'cannot find a closing tag for macro <<' + name + '>>', w.source.slice(matchStart, w.nextMatch) + '\\u2026');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (typeof macro.handler === 'function') {\n\t\t\t\t\t\t\tvar args = !payload ? this.createArgs(rawArgs, this.skipArgs(macro, macro.name)) : payload[0].args;\n\n\t\t\t\t\t\t\t/*\n       \tNew-style macros.\n       */\n\t\t\t\t\t\t\tif (macro.hasOwnProperty('_MACRO_API')) {\n\t\t\t\t\t\t\t\t/*\n        \tAdd the macro's execution context to the context chain.\n        */\n\t\t\t\t\t\t\t\tthis.context = new MacroContext({\n\t\t\t\t\t\t\t\t\tmacro: macro,\n\t\t\t\t\t\t\t\t\tname: name,\n\t\t\t\t\t\t\t\t\targs: args,\n\t\t\t\t\t\t\t\t\tpayload: payload,\n\t\t\t\t\t\t\t\t\tsource: w.source.slice(matchStart, w.nextMatch),\n\t\t\t\t\t\t\t\t\tparent: this.context,\n\t\t\t\t\t\t\t\t\tparser: w\n\t\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t\t/*\n        \tCall the handler.\n        \t\tNOTE: There's no catch clause here because this try/finally exists solely\n        \tto ensure that the execution context is properly restored in the event\n        \tthat an uncaught exception is thrown during the handler call.\n        */\n\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\tmacro.handler.call(this.context);\n\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\tthis.context = this.context.parent;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t/*\n       \tOld-style macros.\n       */\n\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t/*\n         \tSet up the raw arguments string.\n         */\n\t\t\t\t\t\t\t\t\tvar prevRawArgs = w._rawArgs;\n\t\t\t\t\t\t\t\t\tw._rawArgs = rawArgs;\n\n\t\t\t\t\t\t\t\t\t/*\n         \tCall the handler.\n         \t\tNOTE: There's no catch clause here because this try/finally exists solely\n         \tto ensure that the previous raw arguments string is properly restored in\n         \tthe event that an uncaught exception is thrown during the handler call.\n         */\n\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\tmacro.handler(w.output, name, args, w, payload);\n\t\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\t\tw._rawArgs = prevRawArgs;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\treturn throwError(w.output, 'macro <<' + name + '>> handler function ' + (macro.hasOwnProperty('handler') ? 'is not a function' : 'does not exist'), w.source.slice(matchStart, w.nextMatch));\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (Macro.tags.has(name)) {\n\t\t\t\t\t\tvar tags = Macro.tags.get(name);\n\t\t\t\t\t\treturn throwError(w.output, 'child tag <<' + name + '>> was found outside of a call to its parent macro' + (tags.length === 1 ? '' : 's') + ' <<' + tags.join('>>, <<') + '>>', w.source.slice(matchStart, w.nextMatch));\n\t\t\t\t\t} else {\n\t\t\t\t\t\treturn throwError(w.output, 'macro <<' + name + '>> does not exist', w.source.slice(matchStart, w.nextMatch));\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn throwError(w.output, 'cannot execute ' + (macro && macro.isWidget ? 'widget' : 'macro') + ' <<' + name + '>>: ' + ex.message, w.source.slice(matchStart, w.nextMatch));\n\t\t\t\t} finally {\n\t\t\t\t\tthis.working.source = '';\n\t\t\t\t\tthis.working.name = '';\n\t\t\t\t\tthis.working.arguments = '';\n\t\t\t\t\tthis.working.index = 0;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tw.outputText(w.output, w.matchStart, w.nextMatch);\n\t\t\t}\n\t\t},\n\t\tparseTag: function parseTag(w) {\n\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\tif (match && match.index === w.matchStart && match[1]) {\n\t\t\t\tw.nextMatch = this.lookahead.lastIndex;\n\n\t\t\t\tthis.working.source = w.source.slice(match.index, this.lookahead.lastIndex);\n\t\t\t\tthis.working.name = match[1];\n\t\t\t\tthis.working.arguments = match[2];\n\t\t\t\tthis.working.index = match.index;\n\n\t\t\t\treturn true;\n\t\t\t}\n\n\t\t\treturn false;\n\t\t},\n\t\tparseBody: function parseBody(w, macro) {\n\t\t\tvar openTag = this.working.name;\n\t\t\tvar closeTag = '/' + openTag;\n\t\t\tvar closeAlt = 'end' + openTag;\n\t\t\tvar bodyTags = Array.isArray(macro.tags) ? macro.tags : false;\n\t\t\tvar payload = [];\n\t\t\tvar end = -1;\n\t\t\tvar opened = 1;\n\t\t\tvar curSource = this.working.source;\n\t\t\tvar curTag = this.working.name;\n\t\t\tvar curArgument = this.working.arguments;\n\t\t\tvar contentStart = w.nextMatch;\n\n\t\t\twhile ((w.matchStart = w.source.indexOf(this.match, w.nextMatch)) !== -1) {\n\t\t\t\tif (!this.parseTag(w)) {\n\t\t\t\t\tthis.lookahead.lastIndex = w.nextMatch = w.matchStart + this.match.length;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tvar tagSource = this.working.source;\n\t\t\t\tvar tagName = this.working.name;\n\t\t\t\tvar tagArgs = this.working.arguments;\n\t\t\t\tvar tagBegin = this.working.index;\n\t\t\t\tvar tagEnd = w.nextMatch;\n\n\t\t\t\tswitch (tagName) {\n\t\t\t\t\tcase openTag:\n\t\t\t\t\t\t++opened;\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase closeAlt:\n\t\t\t\t\tcase closeTag:\n\t\t\t\t\t\t--opened;\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tif (opened === 1 && bodyTags) {\n\t\t\t\t\t\t\tfor (var i = 0, iend = bodyTags.length; i < iend; ++i) {\n\t\t\t\t\t\t\t\tif (tagName === bodyTags[i]) {\n\t\t\t\t\t\t\t\t\tpayload.push({\n\t\t\t\t\t\t\t\t\t\tsource: curSource,\n\t\t\t\t\t\t\t\t\t\tname: curTag,\n\t\t\t\t\t\t\t\t\t\targuments: curArgument,\n\t\t\t\t\t\t\t\t\t\targs: this.createArgs(curArgument, this.skipArgs(macro, curTag)),\n\t\t\t\t\t\t\t\t\t\tcontents: w.source.slice(contentStart, tagBegin)\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\tcurSource = tagSource;\n\t\t\t\t\t\t\t\t\tcurTag = tagName;\n\t\t\t\t\t\t\t\t\tcurArgument = tagArgs;\n\t\t\t\t\t\t\t\t\tcontentStart = tagEnd;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tif (opened === 0) {\n\t\t\t\t\tpayload.push({\n\t\t\t\t\t\tsource: curSource,\n\t\t\t\t\t\tname: curTag,\n\t\t\t\t\t\targuments: curArgument,\n\t\t\t\t\t\targs: this.createArgs(curArgument, this.skipArgs(macro, curTag)),\n\t\t\t\t\t\tcontents: w.source.slice(contentStart, tagBegin)\n\t\t\t\t\t});\n\t\t\t\t\tend = tagEnd;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (end !== -1) {\n\t\t\t\tw.nextMatch = end;\n\t\t\t\treturn payload;\n\t\t\t}\n\n\t\t\treturn null;\n\t\t},\n\t\tcreateArgs: function createArgs(rawArgsString, skipArgs) {\n\t\t\tvar args = skipArgs ? [] : this.parseArgs(rawArgsString);\n\n\t\t\t// Extend the args array with the raw and full argument strings.\n\t\t\tObject.defineProperties(args, {\n\t\t\t\traw: {\n\t\t\t\t\tvalue: rawArgsString\n\t\t\t\t},\n\t\t\t\tfull: {\n\t\t\t\t\tvalue: Scripting.parse(rawArgsString)\n\t\t\t\t}\n\t\t\t});\n\n\t\t\treturn args;\n\t\t},\n\t\tskipArgs: function skipArgs(macro, tagName) {\n\t\t\tif (macro.hasOwnProperty('skipArgs')) {\n\t\t\t\tvar sa = macro.skipArgs;\n\n\t\t\t\treturn typeof sa === 'boolean' && sa || Array.isArray(sa) && sa.includes(tagName);\n\t\t\t}\n\t\t\t/* legacy */\n\t\t\telse if (macro.hasOwnProperty('skipArg0')) {\n\t\t\t\t\treturn macro.skipArg0 && macro.name === tagName;\n\t\t\t\t}\n\t\t\t/* /legacy */\n\n\t\t\treturn false;\n\t\t},\n\n\n\t\tparseArgs: function () {\n\t\t\tvar Item = Lexer.enumFromNames([// lex item types object (pseudo-enumeration)\n\t\t\t'Error', // error\n\t\t\t'Bareword', // bare identifier\n\t\t\t'Expression', // expression (backquoted)\n\t\t\t'String', // quoted string (single or double)\n\t\t\t'SquareBracket' // [[…]] or [img[…]]\n\t\t\t]);\n\t\t\tvar spaceRe = new RegExp(Patterns.space);\n\t\t\tvar notSpaceRe = new RegExp(Patterns.notSpace);\n\t\t\tvar varTest = new RegExp('^' + Patterns.variable);\n\n\t\t\t// Lexing functions.\n\t\t\tfunction slurpQuote(lexer, endQuote) {\n\t\t\t\tloop: for (;;) {\n\t\t\t\t\t/* eslint-disable indent */\n\t\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\t\tcase '\\\\':\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvar ch = lexer.next();\n\n\t\t\t\t\t\t\t\tif (ch !== EOF && ch !== '\\n') {\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/* falls through */\n\t\t\t\t\t\tcase EOF:\n\t\t\t\t\t\tcase '\\n':\n\t\t\t\t\t\t\treturn EOF;\n\n\t\t\t\t\t\tcase endQuote:\n\t\t\t\t\t\t\tbreak loop;\n\t\t\t\t\t}\n\t\t\t\t\t/* eslint-enable indent */\n\t\t\t\t}\n\n\t\t\t\treturn lexer.pos;\n\t\t\t}\n\n\t\t\tfunction lexSpace(lexer) {\n\t\t\t\tvar offset = lexer.source.slice(lexer.pos).search(notSpaceRe);\n\n\t\t\t\tif (offset === EOF) {\n\t\t\t\t\t// no non-whitespace characters, so bail\n\t\t\t\t\treturn null;\n\t\t\t\t} else if (offset !== 0) {\n\t\t\t\t\tlexer.pos += offset;\n\t\t\t\t\tlexer.ignore();\n\t\t\t\t}\n\n\t\t\t\t// determine what the next state is\n\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\tcase '`':\n\t\t\t\t\t\treturn lexExpression;\n\t\t\t\t\tcase '\"':\n\t\t\t\t\t\treturn lexDoubleQuote;\n\t\t\t\t\tcase \"'\":\n\t\t\t\t\t\treturn lexSingleQuote;\n\t\t\t\t\tcase '[':\n\t\t\t\t\t\treturn lexSquareBracket;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\treturn lexBareword;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfunction lexExpression(lexer) {\n\t\t\t\tif (slurpQuote(lexer, '`') === EOF) {\n\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated backquote expression');\n\t\t\t\t}\n\n\t\t\t\tlexer.emit(Item.Expression);\n\t\t\t\treturn lexSpace;\n\t\t\t}\n\n\t\t\tfunction lexDoubleQuote(lexer) {\n\t\t\t\tif (slurpQuote(lexer, '\"') === EOF) {\n\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated double quoted string');\n\t\t\t\t}\n\n\t\t\t\tlexer.emit(Item.String);\n\t\t\t\treturn lexSpace;\n\t\t\t}\n\n\t\t\tfunction lexSingleQuote(lexer) {\n\t\t\t\tif (slurpQuote(lexer, \"'\") === EOF) {\n\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated single quoted string');\n\t\t\t\t}\n\n\t\t\t\tlexer.emit(Item.String);\n\t\t\t\treturn lexSpace;\n\t\t\t}\n\n\t\t\tfunction lexSquareBracket(lexer) {\n\t\t\t\tvar imgMeta = '<>IiMmGg';\n\t\t\t\tvar what = void 0;\n\n\t\t\t\tif (lexer.accept(imgMeta)) {\n\t\t\t\t\twhat = 'image';\n\t\t\t\t\tlexer.acceptRun(imgMeta);\n\t\t\t\t} else {\n\t\t\t\t\twhat = 'link';\n\t\t\t\t}\n\n\t\t\t\tif (!lexer.accept('[')) {\n\t\t\t\t\treturn lexer.error(Item.Error, 'malformed ' + what + ' markup');\n\t\t\t\t}\n\n\t\t\t\tlexer.depth = 2; // account for both initial left square brackets\n\n\t\t\t\tloop: for (;;) {\n\t\t\t\t\t/* eslint-disable indent */\n\t\t\t\t\tswitch (lexer.next()) {\n\t\t\t\t\t\tcase '\\\\':\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvar ch = lexer.next();\n\n\t\t\t\t\t\t\t\tif (ch !== EOF && ch !== '\\n') {\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/* falls through */\n\t\t\t\t\t\tcase EOF:\n\t\t\t\t\t\tcase '\\n':\n\t\t\t\t\t\t\treturn lexer.error(Item.Error, 'unterminated ' + what + ' markup');\n\n\t\t\t\t\t\tcase '[':\n\t\t\t\t\t\t\t++lexer.depth;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase ']':\n\t\t\t\t\t\t\t--lexer.depth;\n\n\t\t\t\t\t\t\tif (lexer.depth < 0) {\n\t\t\t\t\t\t\t\treturn lexer.error(Item.Error, \"unexpected right square bracket ']'\");\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (lexer.depth === 1) {\n\t\t\t\t\t\t\t\tif (lexer.next() === ']') {\n\t\t\t\t\t\t\t\t\t--lexer.depth;\n\t\t\t\t\t\t\t\t\tbreak loop;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tlexer.backup();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t/* eslint-enable indent */\n\t\t\t\t}\n\n\t\t\t\tlexer.emit(Item.SquareBracket);\n\t\t\t\treturn lexSpace;\n\t\t\t}\n\n\t\t\tfunction lexBareword(lexer) {\n\t\t\t\tvar offset = lexer.source.slice(lexer.pos).search(spaceRe);\n\t\t\t\tlexer.pos = offset === EOF ? lexer.source.length : lexer.pos + offset;\n\t\t\t\tlexer.emit(Item.Bareword);\n\t\t\t\treturn offset === EOF ? null : lexSpace;\n\t\t\t}\n\n\t\t\t// Parse function.\n\t\t\tfunction parseMacroArgs(rawArgsString) {\n\t\t\t\t// Initialize the lexer.\n\t\t\t\tvar lexer = new Lexer(rawArgsString, lexSpace);\n\t\t\t\tvar args = [];\n\n\t\t\t\t// Lex the raw argument string.\n\t\t\t\tlexer.run().forEach(function (item) {\n\t\t\t\t\tvar arg = item.text;\n\n\t\t\t\t\tswitch (item.type) {\n\t\t\t\t\t\tcase Item.Error:\n\t\t\t\t\t\t\tthrow new Error('unable to parse macro argument \"' + arg + '\": ' + item.message);\n\n\t\t\t\t\t\tcase Item.Bareword:\n\t\t\t\t\t\t\t// A variable, so substitute its value.\n\t\t\t\t\t\t\tif (varTest.test(arg)) {\n\t\t\t\t\t\t\t\targ = State.getVar(arg);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Property access on the settings or setup objects, so try to evaluate it.\n\t\t\t\t\t\t\telse if (/^(?:settings|setup)[.[]/.test(arg)) {\n\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\targ = Scripting.evalTwineScript(arg);\n\t\t\t\t\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\t\t\t\t\tthrow new Error('unable to parse macro argument \"' + arg + '\": ' + ex.message);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Null literal, so convert it into null.\n\t\t\t\t\t\t\t\telse if (arg === 'null') {\n\t\t\t\t\t\t\t\t\t\targ = null;\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t// Undefined literal, so convert it into undefined.\n\t\t\t\t\t\t\t\t\telse if (arg === 'undefined') {\n\t\t\t\t\t\t\t\t\t\t\targ = undefined;\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t// Boolean true literal, so convert it into true.\n\t\t\t\t\t\t\t\t\t\telse if (arg === 'true') {\n\t\t\t\t\t\t\t\t\t\t\t\targ = true;\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t// Boolean false literal, so convert it into false.\n\t\t\t\t\t\t\t\t\t\t\telse if (arg === 'false') {\n\t\t\t\t\t\t\t\t\t\t\t\t\targ = false;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t// NaN literal, so convert it into NaN.\n\t\t\t\t\t\t\t\t\t\t\t\telse if (arg === 'NaN') {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\targ = NaN;\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t// Attempt to convert it into a number, in case it's a numeric literal.\n\t\t\t\t\t\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tvar argAsNum = Number(arg);\n\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif (!Number.isNaN(argAsNum)) {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\targ = argAsNum;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase Item.Expression:\n\t\t\t\t\t\t\targ = arg.slice(1, -1).trim(); // remove the backquotes and trim the expression\n\n\t\t\t\t\t\t\t// Empty backquotes.\n\t\t\t\t\t\t\tif (arg === '') {\n\t\t\t\t\t\t\t\targ = undefined;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Evaluate the expression.\n\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t/*\n          \tThe enclosing parenthesis here are necessary to force a code string\n          \tconsisting solely of an object literal to be evaluated as such, rather\n          \tthan as a code block.\n          */\n\t\t\t\t\t\t\t\t\t\targ = Scripting.evalTwineScript('(' + arg + ')');\n\t\t\t\t\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\t\t\t\t\tthrow new Error('unable to parse macro argument expression \"' + arg + '\": ' + ex.message);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase Item.String:\n\t\t\t\t\t\t\t// Evaluate the string to handle escaped characters.\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\targ = Scripting.evalJavaScript(arg);\n\t\t\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\t\t\tthrow new Error('unable to parse macro argument string \"' + arg + '\": ' + ex.message);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase Item.SquareBracket:\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvar markup = Wikifier.helpers.parseSquareBracketedMarkup({\n\t\t\t\t\t\t\t\t\tsource: arg,\n\t\t\t\t\t\t\t\t\tmatchStart: 0\n\t\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t\tif (markup.hasOwnProperty('error')) {\n\t\t\t\t\t\t\t\t\tthrow new Error('unable to parse macro argument \"' + arg + '\": ' + markup.error);\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tif (markup.pos < arg.length) {\n\t\t\t\t\t\t\t\t\tthrow new Error('unable to parse macro argument \"' + arg + '\": unexpected character(s) \"' + arg.slice(markup.pos) + '\" (pos: ' + markup.pos + ')');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Convert to a link or image object.\n\t\t\t\t\t\t\t\tif (markup.isLink) {\n\t\t\t\t\t\t\t\t\t// .isLink, [.text], [.forceInternal], .link, [.setter]\n\t\t\t\t\t\t\t\t\targ = { isLink: true };\n\t\t\t\t\t\t\t\t\targ.count = markup.hasOwnProperty('text') ? 2 : 1;\n\t\t\t\t\t\t\t\t\targ.link = Wikifier.helpers.evalPassageId(markup.link);\n\t\t\t\t\t\t\t\t\targ.text = markup.hasOwnProperty('text') ? Wikifier.helpers.evalText(markup.text) : arg.link;\n\t\t\t\t\t\t\t\t\targ.external = !markup.forceInternal && Wikifier.isExternalLink(arg.link);\n\t\t\t\t\t\t\t\t\targ.setFn = markup.hasOwnProperty('setter') ? Wikifier.helpers.createShadowSetterCallback(Scripting.parse(markup.setter)) : null;\n\t\t\t\t\t\t\t\t} else if (markup.isImage) {\n\t\t\t\t\t\t\t\t\t// .isImage, [.align], [.title], .source, [.forceInternal], [.link], [.setter]\n\t\t\t\t\t\t\t\t\targ = function (source) {\n\t\t\t\t\t\t\t\t\t\tvar imgObj = {\n\t\t\t\t\t\t\t\t\t\t\tsource: source,\n\t\t\t\t\t\t\t\t\t\t\tisImage: true\n\t\t\t\t\t\t\t\t\t\t};\n\n\t\t\t\t\t\t\t\t\t\t// Check for Twine 1.4 Base64 image passage transclusion.\n\t\t\t\t\t\t\t\t\t\tif (source.slice(0, 5) !== 'data:' && Story.has(source)) {\n\t\t\t\t\t\t\t\t\t\t\tvar passage = Story.get(source);\n\n\t\t\t\t\t\t\t\t\t\t\tif (passage.tags.includes('Twine.image')) {\n\t\t\t\t\t\t\t\t\t\t\t\timgObj.source = passage.text;\n\t\t\t\t\t\t\t\t\t\t\t\timgObj.passage = passage.title;\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\treturn imgObj;\n\t\t\t\t\t\t\t\t\t}(Wikifier.helpers.evalPassageId(markup.source));\n\n\t\t\t\t\t\t\t\t\tif (markup.hasOwnProperty('align')) {\n\t\t\t\t\t\t\t\t\t\targ.align = markup.align;\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tif (markup.hasOwnProperty('text')) {\n\t\t\t\t\t\t\t\t\t\targ.title = Wikifier.helpers.evalText(markup.text);\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tif (markup.hasOwnProperty('link')) {\n\t\t\t\t\t\t\t\t\t\targ.link = Wikifier.helpers.evalPassageId(markup.link);\n\t\t\t\t\t\t\t\t\t\targ.external = !markup.forceInternal && Wikifier.isExternalLink(arg.link);\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\targ.setFn = markup.hasOwnProperty('setter') ? Wikifier.helpers.createShadowSetterCallback(Scripting.parse(markup.setter)) : null;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\targs.push(arg);\n\t\t\t\t});\n\n\t\t\t\treturn args;\n\t\t\t}\n\n\t\t\treturn parseMacroArgs;\n\t\t}()\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'link',\n\t\tprofiles: ['core'],\n\t\tmatch: '\\\\[\\\\[[^[]',\n\n\t\thandler: function handler(w) {\n\t\t\tvar markup = Wikifier.helpers.parseSquareBracketedMarkup(w);\n\n\t\t\tif (markup.hasOwnProperty('error')) {\n\t\t\t\tw.outputText(w.output, w.matchStart, w.nextMatch);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tw.nextMatch = markup.pos;\n\n\t\t\t// text=(text), forceInternal=(~), link=link, setter=(setter)\n\t\t\tvar link = Wikifier.helpers.evalPassageId(markup.link);\n\t\t\tvar text = markup.hasOwnProperty('text') ? Wikifier.helpers.evalText(markup.text) : link;\n\t\t\tvar setFn = markup.hasOwnProperty('setter') ? Wikifier.helpers.createShadowSetterCallback(Scripting.parse(markup.setter)) : null;\n\n\t\t\t// Debug view setup.\n\t\t\tvar output = (Config.debug ? new DebugView(w.output, 'link-markup', '[[link]]', w.source.slice(w.matchStart, w.nextMatch)) : w).output;\n\n\t\t\tif (markup.forceInternal || !Wikifier.isExternalLink(link)) {\n\t\t\t\tWikifier.createInternalLink(output, link, text, setFn);\n\t\t\t} else {\n\t\t\t\tWikifier.createExternalLink(output, link, text);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'urlLink',\n\t\tprofiles: ['core'],\n\t\tmatch: Patterns.url,\n\n\t\thandler: function handler(w) {\n\t\t\tw.outputText(Wikifier.createExternalLink(w.output, w.matchText), w.matchStart, w.nextMatch);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'image',\n\t\tprofiles: ['core'],\n\t\tmatch: '\\\\[[<>]?[Ii][Mm][Gg]\\\\[',\n\n\t\thandler: function handler(w) {\n\t\t\tvar markup = Wikifier.helpers.parseSquareBracketedMarkup(w);\n\n\t\t\tif (markup.hasOwnProperty('error')) {\n\t\t\t\tw.outputText(w.output, w.matchStart, w.nextMatch);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tw.nextMatch = markup.pos;\n\n\t\t\t// Debug view setup.\n\t\t\tvar debugView = void 0;\n\n\t\t\tif (Config.debug) {\n\t\t\t\tdebugView = new DebugView(w.output, 'image-markup', markup.hasOwnProperty('link') ? '[img[][link]]' : '[img[]]', w.source.slice(w.matchStart, w.nextMatch));\n\t\t\t\tdebugView.modes({ block: true });\n\t\t\t}\n\n\t\t\t// align=(left|right), title=(title), source=source, forceInternal=(~), link=(link), setter=(setter)\n\t\t\tvar setFn = markup.hasOwnProperty('setter') ? Wikifier.helpers.createShadowSetterCallback(Scripting.parse(markup.setter)) : null;\n\t\t\tvar el = (Config.debug ? debugView : w).output;\n\t\t\tvar source = void 0;\n\n\t\t\tif (markup.hasOwnProperty('link')) {\n\t\t\t\tvar link = Wikifier.helpers.evalPassageId(markup.link);\n\n\t\t\t\tif (markup.forceInternal || !Wikifier.isExternalLink(link)) {\n\t\t\t\t\tel = Wikifier.createInternalLink(el, link, null, setFn);\n\t\t\t\t} else {\n\t\t\t\t\tel = Wikifier.createExternalLink(el, link);\n\t\t\t\t}\n\n\t\t\t\tel.classList.add('link-image');\n\t\t\t}\n\n\t\t\tel = jQuery(document.createElement('img')).appendTo(el).get(0);\n\t\t\tsource = Wikifier.helpers.evalPassageId(markup.source);\n\n\t\t\t// Check for image passage transclusion.\n\t\t\tif (source.slice(0, 5) !== 'data:' && Story.has(source)) {\n\t\t\t\tvar passage = Story.get(source);\n\n\t\t\t\tif (passage.tags.includes('Twine.image')) {\n\t\t\t\t\tel.setAttribute('data-passage', passage.title);\n\t\t\t\t\tsource = passage.text.trim();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tel.src = source;\n\n\t\t\tif (markup.hasOwnProperty('text')) {\n\t\t\t\tel.title = Wikifier.helpers.evalText(markup.text);\n\t\t\t}\n\n\t\t\tif (markup.hasOwnProperty('align')) {\n\t\t\t\tel.align = markup.align;\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'monospacedByBlock',\n\t\tprofiles: ['block'],\n\t\tmatch: '^\\\\{\\\\{\\\\{\\\\n',\n\t\tlookahead: /^\\{\\{\\{\\n((?:^[^\\n]*\\n)+?)(^\\}\\}\\}$\\n?)/gm,\n\n\t\thandler: function handler(w) {\n\t\t\tthis.lookahead.lastIndex = w.matchStart;\n\n\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\tif (match && match.index === w.matchStart) {\n\t\t\t\tvar pre = jQuery(document.createElement('pre'));\n\t\t\t\tjQuery(document.createElement('code')).text(match[1]).appendTo(pre);\n\t\t\t\tpre.appendTo(w.output);\n\t\t\t\tw.nextMatch = this.lookahead.lastIndex;\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'formatByChar',\n\t\tprofiles: ['core'],\n\t\tmatch: \"''|//|__|\\\\^\\\\^|~~|==|\\\\{\\\\{\\\\{\",\n\n\t\thandler: function handler(w) {\n\t\t\tswitch (w.matchText) {\n\t\t\t\tcase \"''\":\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('strong')).appendTo(w.output).get(0), \"''\");\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase '//':\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('em')).appendTo(w.output).get(0), '//');\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase '__':\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('u')).appendTo(w.output).get(0), '__');\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase '^^':\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('sup')).appendTo(w.output).get(0), '\\\\^\\\\^');\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase '~~':\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('sub')).appendTo(w.output).get(0), '~~');\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase '==':\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('s')).appendTo(w.output).get(0), '==');\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase '{{{':\n\t\t\t\t\t{\n\t\t\t\t\t\tvar lookahead = /\\{\\{\\{((?:.|\\n)*?)\\}\\}\\}/gm;\n\n\t\t\t\t\t\tlookahead.lastIndex = w.matchStart;\n\n\t\t\t\t\t\tvar match = lookahead.exec(w.source);\n\n\t\t\t\t\t\tif (match && match.index === w.matchStart) {\n\t\t\t\t\t\t\tjQuery(document.createElement('code')).text(match[1]).appendTo(w.output);\n\t\t\t\t\t\t\tw.nextMatch = lookahead.lastIndex;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'customStyle',\n\t\tprofiles: ['core'],\n\t\tmatch: '@@',\n\t\tterminator: '@@',\n\t\tblockRe: /\\s*\\n/gm,\n\n\t\thandler: function handler(w) {\n\t\t\tvar css = Wikifier.helpers.inlineCss(w);\n\n\t\t\tthis.blockRe.lastIndex = w.nextMatch; // must follow the call to `inlineCss()`\n\n\t\t\tvar blockMatch = this.blockRe.exec(w.source);\n\t\t\tvar blockLevel = blockMatch && blockMatch.index === w.nextMatch;\n\t\t\tvar $el = jQuery(document.createElement(blockLevel ? 'div' : 'span')).appendTo(w.output);\n\n\t\t\tif (css.classes.length === 0 && css.id === '' && Object.keys(css.styles).length === 0) {\n\t\t\t\t$el.addClass('marked');\n\t\t\t} else {\n\t\t\t\tcss.classes.forEach(function (className) {\n\t\t\t\t\treturn $el.addClass(className);\n\t\t\t\t});\n\n\t\t\t\tif (css.id !== '') {\n\t\t\t\t\t$el.attr('id', css.id);\n\t\t\t\t}\n\n\t\t\t\t$el.css(css.styles);\n\t\t\t}\n\n\t\t\tif (blockLevel) {\n\t\t\t\t// Skip the leading and, if it exists, trailing newlines.\n\t\t\t\tw.nextMatch += blockMatch[0].length;\n\t\t\t\tw.subWikify($el[0], '\\\\n?' + this.terminator);\n\t\t\t} else {\n\t\t\t\tw.subWikify($el[0], this.terminator);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'verbatimText',\n\t\tprofiles: ['core'],\n\t\tmatch: '\"{3}|<[Nn][Oo][Ww][Ii][Kk][Ii]>',\n\t\tlookahead: /(?:\"{3}((?:.|\\n)*?)\"{3})|(?:<[Nn][Oo][Ww][Ii][Kk][Ii]>((?:.|\\n)*?)<\\/[Nn][Oo][Ww][Ii][Kk][Ii]>)/gm,\n\n\t\thandler: function handler(w) {\n\t\t\tthis.lookahead.lastIndex = w.matchStart;\n\n\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\tif (match && match.index === w.matchStart) {\n\t\t\t\tw.nextMatch = this.lookahead.lastIndex;\n\n\t\t\t\tjQuery(document.createElement('span')).addClass('verbatim').text(match[1] || match[2]).appendTo(w.output);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'horizontalRule',\n\t\tprofiles: ['core'],\n\t\tmatch: '^----+$\\\\n?|<[Hh][Rr]\\\\s*/?>\\\\n?',\n\n\t\thandler: function handler(w) {\n\t\t\tjQuery(document.createElement('hr')).appendTo(w.output);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'emdash',\n\t\tprofiles: ['core'],\n\t\tmatch: '--',\n\n\t\thandler: function handler(w) {\n\t\t\tjQuery(document.createTextNode('\\u2014')).appendTo(w.output);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'doubleDollarSign',\n\t\tprofiles: ['core'],\n\t\tmatch: '\\\\${2}', // eslint-disable-line no-template-curly-in-string\n\n\t\thandler: function handler(w) {\n\t\t\tjQuery(document.createTextNode('$')).appendTo(w.output);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\t/*\n  \tSupported syntax:\n  \t\t$variable\n  \t\t$variable.property\n  \t\t$variable[numericIndex]\n  \t\t$variable[\"property\"]\n  \t\t$variable['property']\n  \t\t$variable[$indexOrPropertyVariable]\n  */\n\t\tname: 'nakedVariable',\n\t\tprofiles: ['core'],\n\t\tmatch: Patterns.variable + '(?:(?:\\\\.' + Patterns.identifier + ')|(?:\\\\[\\\\d+\\\\])|(?:\\\\[\"(?:\\\\\\\\.|[^\"\\\\\\\\])+\"\\\\])|(?:\\\\[\\'(?:\\\\\\\\.|[^\\'\\\\\\\\])+\\'\\\\])|(?:\\\\[' + Patterns.variable + '\\\\]))*',\n\n\t\thandler: function handler(w) {\n\t\t\tvar result = toStringOrDefault(State.getVar(w.matchText), null);\n\n\t\t\tif (result === null) {\n\t\t\t\tjQuery(document.createTextNode(w.matchText)).appendTo(w.output);\n\t\t\t} else {\n\t\t\t\tnew Wikifier((Config.debug ? new DebugView(w.output, 'variable', w.matchText, w.matchText) // Debug view setup.\n\t\t\t\t: w).output, result);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'template',\n\t\tprofiles: ['core'],\n\t\tmatch: '\\\\?' + Patterns.templateName,\n\n\t\thandler: function handler(w) {\n\t\t\tvar name = w.matchText.slice(1);\n\t\t\tvar template = Template.get(name);\n\t\t\tvar result = null;\n\n\t\t\t// If we have an array of templates, randomly choose one.\n\t\t\tif (template instanceof Array) {\n\t\t\t\ttemplate = template.random();\n\t\t\t}\n\n\t\t\tswitch (typeof template === 'undefined' ? 'undefined' : _typeof(template)) {\n\t\t\t\tcase 'function':\n\t\t\t\t\ttry {\n\t\t\t\t\t\tresult = toStringOrDefault(template.call({ name: name }), null);\n\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\treturn throwError(w.output, 'cannot execute function template ?' + name + ': ' + ex.message, w.source.slice(w.matchStart, w.nextMatch));\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'string':\n\t\t\t\t\tresult = template;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tif (result === null) {\n\t\t\t\tjQuery(document.createTextNode(w.matchText)).appendTo(w.output);\n\t\t\t} else {\n\t\t\t\tnew Wikifier((Config.debug ? new DebugView(w.output, 'template', w.matchText, w.matchText) // Debug view setup.\n\t\t\t\t: w).output, result);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'heading',\n\t\tprofiles: ['block'],\n\t\tmatch: '^!{1,6}',\n\t\tterminator: '\\\\n',\n\n\t\thandler: function handler(w) {\n\t\t\tif (!Wikifier.helpers.hasBlockContext(w.output.childNodes)) {\n\t\t\t\tjQuery(w.output).append(document.createTextNode(w.matchText));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tw.subWikify(jQuery(document.createElement('h' + w.matchLength)).appendTo(w.output).get(0), this.terminator);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'table',\n\t\tprofiles: ['block'],\n\t\tmatch: '^\\\\|(?:[^\\\\n]*)\\\\|(?:[fhck]?)$',\n\t\tlookahead: /^\\|([^\\n]*)\\|([fhck]?)$/gm,\n\t\trowTerminator: '\\\\|(?:[cfhk]?)$\\\\n?',\n\t\tcellPattern: '(?:\\\\|([^\\\\n\\\\|]*)\\\\|)|(\\\\|[cfhk]?$\\\\n?)',\n\t\tcellTerminator: '(?:\\\\u0020*)\\\\|',\n\t\trowTypes: { c: 'caption', f: 'tfoot', h: 'thead', '': 'tbody' }, // eslint-disable-line id-length\n\n\t\thandler: function handler(w) {\n\t\t\tif (!Wikifier.helpers.hasBlockContext(w.output.childNodes)) {\n\t\t\t\tjQuery(w.output).append(document.createTextNode(w.matchText));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar table = jQuery(document.createElement('table')).appendTo(w.output).get(0);\n\t\t\tvar prevColumns = [];\n\t\t\tvar curRowType = null;\n\t\t\tvar $rowContainer = null;\n\t\t\tvar rowCount = 0;\n\t\t\tvar matched = void 0;\n\n\t\t\tw.nextMatch = w.matchStart;\n\n\t\t\tdo {\n\t\t\t\tthis.lookahead.lastIndex = w.nextMatch;\n\n\t\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\t\tmatched = match && match.index === w.nextMatch;\n\n\t\t\t\tif (matched) {\n\t\t\t\t\tvar nextRowType = match[2];\n\n\t\t\t\t\tif (nextRowType === 'k') {\n\t\t\t\t\t\ttable.className = match[1];\n\t\t\t\t\t\tw.nextMatch += match[0].length + 1;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (nextRowType !== curRowType) {\n\t\t\t\t\t\t\tcurRowType = nextRowType;\n\t\t\t\t\t\t\t$rowContainer = jQuery(document.createElement(this.rowTypes[nextRowType])).appendTo(table);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (curRowType === 'c') {\n\t\t\t\t\t\t\t$rowContainer.css('caption-side', rowCount === 0 ? 'top' : 'bottom');\n\t\t\t\t\t\t\tw.nextMatch += 1;\n\t\t\t\t\t\t\tw.subWikify($rowContainer[0], this.rowTerminator);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tthis.rowHandler(w, jQuery(document.createElement('tr')).appendTo($rowContainer).get(0), prevColumns);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t++rowCount;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} while (matched);\n\t\t},\n\t\trowHandler: function rowHandler(w, rowEl, prevColumns) {\n\t\t\tvar _this10 = this;\n\n\t\t\tvar cellRe = new RegExp(this.cellPattern, 'gm');\n\t\t\tvar col = 0;\n\t\t\tvar curColCount = 1;\n\t\t\tvar matched = void 0;\n\n\t\t\tdo {\n\t\t\t\tcellRe.lastIndex = w.nextMatch;\n\n\t\t\t\tvar cellMatch = cellRe.exec(w.source);\n\n\t\t\t\tmatched = cellMatch && cellMatch.index === w.nextMatch;\n\n\t\t\t\tif (matched) {\n\t\t\t\t\tif (cellMatch[1] === '~') {\n\t\t\t\t\t\tvar last = prevColumns[col];\n\n\t\t\t\t\t\tif (last) {\n\t\t\t\t\t\t\t++last.rowCount;\n\t\t\t\t\t\t\tlast.$element.attr('rowspan', last.rowCount).css('vertical-align', 'middle');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tw.nextMatch = cellMatch.index + cellMatch[0].length - 1;\n\t\t\t\t\t} else if (cellMatch[1] === '>') {\n\t\t\t\t\t\t++curColCount;\n\t\t\t\t\t\tw.nextMatch = cellMatch.index + cellMatch[0].length - 1;\n\t\t\t\t\t} else if (cellMatch[2]) {\n\t\t\t\t\t\tw.nextMatch = cellMatch.index + cellMatch[0].length;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t(function () {\n\t\t\t\t\t\t\t++w.nextMatch;\n\n\t\t\t\t\t\t\tvar css = Wikifier.helpers.inlineCss(w);\n\t\t\t\t\t\t\tvar spaceLeft = false;\n\t\t\t\t\t\t\tvar spaceRight = false;\n\t\t\t\t\t\t\tvar $cell = void 0;\n\n\t\t\t\t\t\t\twhile (w.source.substr(w.nextMatch, 1) === ' ') {\n\t\t\t\t\t\t\t\tspaceLeft = true;\n\t\t\t\t\t\t\t\t++w.nextMatch;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (w.source.substr(w.nextMatch, 1) === '!') {\n\t\t\t\t\t\t\t\t$cell = jQuery(document.createElement('th')).appendTo(rowEl);\n\t\t\t\t\t\t\t\t++w.nextMatch;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$cell = jQuery(document.createElement('td')).appendTo(rowEl);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tprevColumns[col] = {\n\t\t\t\t\t\t\t\trowCount: 1,\n\t\t\t\t\t\t\t\t$element: $cell\n\t\t\t\t\t\t\t};\n\n\t\t\t\t\t\t\tif (curColCount > 1) {\n\t\t\t\t\t\t\t\t$cell.attr('colspan', curColCount);\n\t\t\t\t\t\t\t\tcurColCount = 1;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tw.subWikify($cell[0], _this10.cellTerminator);\n\n\t\t\t\t\t\t\tif (w.matchText.substr(w.matchText.length - 2, 1) === ' ') {\n\t\t\t\t\t\t\t\tspaceRight = true;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tcss.classes.forEach(function (className) {\n\t\t\t\t\t\t\t\treturn $cell.addClass(className);\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\tif (css.id !== '') {\n\t\t\t\t\t\t\t\t$cell.attr('id', css.id);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (spaceLeft && spaceRight) {\n\t\t\t\t\t\t\t\tcss.styles['text-align'] = 'center';\n\t\t\t\t\t\t\t} else if (spaceLeft) {\n\t\t\t\t\t\t\t\tcss.styles['text-align'] = 'right';\n\t\t\t\t\t\t\t} else if (spaceRight) {\n\t\t\t\t\t\t\t\tcss.styles['text-align'] = 'left';\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$cell.css(css.styles);\n\n\t\t\t\t\t\t\tw.nextMatch = w.nextMatch - 1;\n\t\t\t\t\t\t})();\n\t\t\t\t\t}\n\n\t\t\t\t\t++col;\n\t\t\t\t}\n\t\t\t} while (matched);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'list',\n\t\tprofiles: ['block'],\n\t\tmatch: '^(?:(?:\\\\*+)|(?:#+))',\n\t\tlookahead: /^(?:(\\*+)|(#+))/gm,\n\t\tterminator: '\\\\n',\n\n\t\thandler: function handler(w) {\n\t\t\tif (!Wikifier.helpers.hasBlockContext(w.output.childNodes)) {\n\t\t\t\tjQuery(w.output).append(document.createTextNode(w.matchText));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tw.nextMatch = w.matchStart;\n\n\t\t\tvar destStack = [w.output];\n\t\t\tvar curType = null;\n\t\t\tvar curLevel = 0;\n\t\t\tvar matched = void 0;\n\t\t\tvar i = void 0;\n\n\t\t\tdo {\n\t\t\t\tthis.lookahead.lastIndex = w.nextMatch;\n\n\t\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\t\tmatched = match && match.index === w.nextMatch;\n\n\t\t\t\tif (matched) {\n\t\t\t\t\tvar newType = match[2] ? 'ol' : 'ul';\n\t\t\t\t\tvar newLevel = match[0].length;\n\n\t\t\t\t\tw.nextMatch += match[0].length;\n\n\t\t\t\t\tif (newLevel > curLevel) {\n\t\t\t\t\t\tfor (i = curLevel; i < newLevel; ++i) {\n\t\t\t\t\t\t\tdestStack.push(jQuery(document.createElement(newType)).appendTo(destStack[destStack.length - 1]).get(0));\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (newLevel < curLevel) {\n\t\t\t\t\t\tfor (i = curLevel; i > newLevel; --i) {\n\t\t\t\t\t\t\tdestStack.pop();\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (newLevel === curLevel && newType !== curType) {\n\t\t\t\t\t\tdestStack.pop();\n\t\t\t\t\t\tdestStack.push(jQuery(document.createElement(newType)).appendTo(destStack[destStack.length - 1]).get(0));\n\t\t\t\t\t}\n\n\t\t\t\t\tcurLevel = newLevel;\n\t\t\t\t\tcurType = newType;\n\t\t\t\t\tw.subWikify(jQuery(document.createElement('li')).appendTo(destStack[destStack.length - 1]).get(0), this.terminator);\n\t\t\t\t}\n\t\t\t} while (matched);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'commentByBlock',\n\t\tprofiles: ['core'],\n\t\tmatch: '(?:/(?:%|\\\\*))|(?:<!--)',\n\t\tlookahead: /(?:\\/(%|\\*)(?:(?:.|\\n)*?)\\1\\/)|(?:<!--(?:(?:.|\\n)*?)-->)/gm,\n\n\t\thandler: function handler(w) {\n\t\t\tthis.lookahead.lastIndex = w.matchStart;\n\n\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\tif (match && match.index === w.matchStart) {\n\t\t\t\tw.nextMatch = this.lookahead.lastIndex;\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'lineContinuation',\n\t\tprofiles: ['core'],\n\n\t\t// WARNING: The ordering here is important: end-of-line, start-of-line, end-of-string, start-of-string.\n\t\tmatch: '\\\\\\\\' + Patterns.spaceNoTerminator + '*\\\\n|\\\\n' + Patterns.spaceNoTerminator + '*\\\\\\\\|\\\\n?\\\\\\\\' + Patterns.spaceNoTerminator + '*$|^' + Patterns.spaceNoTerminator + '*\\\\\\\\\\\\n?',\n\n\t\thandler: function handler(w) {\n\t\t\tw.nextMatch = w.matchStart + w.matchLength;\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'lineBreak',\n\t\tprofiles: ['core'],\n\t\tmatch: '\\\\n|<[Bb][Rr]\\\\s*/?>',\n\n\t\thandler: function handler(w) {\n\t\t\tif (!w.options.nobr) {\n\t\t\t\tjQuery(document.createElement('br')).appendTo(w.output);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'htmlCharacterReference',\n\t\tprofiles: ['core'],\n\t\tmatch: '(?:(?:&#?[0-9A-Za-z]{2,8};|.)(?:&#?(?:x0*(?:3[0-6][0-9A-Fa-f]|1D[C-Fc-f][0-9A-Fa-f]|20[D-Fd-f][0-9A-Fa-f]|FE2[0-9A-Fa-f])|0*(?:76[89]|7[7-9][0-9]|8[0-7][0-9]|761[6-9]|76[2-7][0-9]|84[0-3][0-9]|844[0-7]|6505[6-9]|6506[0-9]|6507[0-1]));)+|&#?[0-9A-Za-z]{2,8};)',\n\n\t\thandler: function handler(w) {\n\t\t\tjQuery(document.createDocumentFragment()).append(w.matchText).appendTo(w.output);\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'xmlProlog',\n\t\tprofiles: ['core'],\n\t\tmatch: '<\\\\?[Xx][Mm][Ll][^>]*\\\\?>',\n\n\t\thandler: function handler(w) {\n\t\t\tw.nextMatch = w.matchStart + w.matchLength;\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'verbatimHtml',\n\t\tprofiles: ['core'],\n\t\tmatch: '<[Hh][Tt][Mm][Ll]>',\n\t\tlookahead: /<[Hh][Tt][Mm][Ll]>((?:.|\\n)*?)<\\/[Hh][Tt][Mm][Ll]>/gm,\n\t\thandler: _verbatimTagHandler\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'verbatimSvgTag',\n\t\tprofiles: ['core'],\n\t\tmatch: '<[Ss][Vv][Gg][^>]*>',\n\t\tlookahead: /(<[Ss][Vv][Gg][^>]*>(?:.|\\n)*?<\\/[Ss][Vv][Gg]>)/gm,\n\t\thandler: _verbatimTagHandler\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'verbatimScriptTag',\n\t\tprofiles: ['core'],\n\t\tmatch: '<[Ss][Cc][Rr][Ii][Pp][Tt][^>]*>',\n\t\tlookahead: /(<[Ss][Cc][Rr][Ii][Pp][Tt]*>(?:.|\\n)*?<\\/[Ss][Cc][Rr][Ii][Pp][Tt]>)/gm,\n\t\thandler: _verbatimTagHandler\n\t});\n\n\tWikifier.Parser.add({\n\t\tname: 'styleTag',\n\t\tprofiles: ['core'],\n\t\tmatch: '<[Ss][Tt][Yy][Ll][Ee][^>]*>',\n\t\tlookahead: /(<[Ss][Tt][Yy][Ll][Ee]*>)((?:.|\\n)*?)(<\\/[Ss][Tt][Yy][Ll][Ee]>)/gm,\n\t\timageMarkup: new RegExp(Patterns.cssImage, 'g'),\n\t\thasImageMarkup: new RegExp(Patterns.cssImage),\n\n\t\thandler: function handler(w) {\n\t\t\tthis.lookahead.lastIndex = w.matchStart;\n\n\t\t\tvar match = this.lookahead.exec(w.source);\n\n\t\t\tif (match && match.index === w.matchStart) {\n\t\t\t\tw.nextMatch = this.lookahead.lastIndex;\n\n\t\t\t\tvar css = match[2];\n\n\t\t\t\t// Check for wiki image transclusion.\n\t\t\t\tif (this.hasImageMarkup.test(css)) {\n\t\t\t\t\tthis.imageMarkup.lastIndex = 0;\n\n\t\t\t\t\tcss = css.replace(this.imageMarkup, function (wikiImage) {\n\t\t\t\t\t\tvar markup = Wikifier.helpers.parseSquareBracketedMarkup({\n\t\t\t\t\t\t\tsource: wikiImage,\n\t\t\t\t\t\t\tmatchStart: 0\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\tif (markup.hasOwnProperty('error') || markup.pos < wikiImage.length) {\n\t\t\t\t\t\t\treturn wikiImage;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tvar source = markup.source;\n\n\t\t\t\t\t\t// Handle image passage transclusion.\n\t\t\t\t\t\tif (source.slice(0, 5) !== 'data:' && Story.has(source)) {\n\t\t\t\t\t\t\tvar passage = Story.get(source);\n\n\t\t\t\t\t\t\tif (passage.tags.includes('Twine.image')) {\n\t\t\t\t\t\t\t\tsource = passage.text;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/*\n      \tThe source may be URI- or Base64-encoded, so we cannot use `encodeURIComponent()`\n      \there.  Instead, we simply encode any double quotes, since the URI will be\n      \tdelimited by them.\n      */\n\t\t\t\t\t\treturn 'url(\"' + source.replace(/\"/g, '%22') + '\")';\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tjQuery(document.createDocumentFragment()).append(match[1] + css + match[3]).appendTo(w.output);\n\t\t\t}\n\t\t}\n\t});\n\n\tWikifier.Parser.add({\n\t\t/*\n  \tNOTE: This parser MUST come after any parser which handles HTML tag-\n  \tlike constructs—e.g. 'verbatimText', 'horizontalRule', 'lineBreak',\n  \t'xmlProlog', 'verbatimHtml', 'verbatimSvgTag', 'verbatimScriptTag',\n  \tand 'styleTag'.\n  */\n\t\tname: 'htmlTag',\n\t\tprofiles: ['core'],\n\t\tmatch: '<\\\\w+(?:\\\\s+[^\\\\u0000-\\\\u001F\\\\u007F-\\\\u009F\\\\s\"\\'>\\\\/=]+(?:\\\\s*=\\\\s*(?:\"[^\"]*?\"|\\'[^\\']*?\\'|[^\\\\s\"\\'=<>`]+))?)*\\\\s*\\\\/?>',\n\t\ttagRe: /^<(\\w+)/,\n\t\tmediaElements: ['audio', 'img', 'source', 'track', 'video'], // NOTE: The `<picture>` element should not be in this list.\n\t\tnobrElements: ['audio', 'colgroup', 'datalist', 'dl', 'figure', 'ol', 'optgroup', 'picture', 'select', 'table', 'tbody', 'tfoot', 'thead', 'tr', 'ul', 'video'],\n\t\tvoidElements: ['area', 'base', 'br', 'col', 'embed', 'hr', 'img', 'input', 'keygen', 'link', 'menuitem', 'meta', 'param', 'source', 'track', 'wbr'],\n\n\t\thandler: function handler(w) {\n\t\t\tvar tagMatch = this.tagRe.exec(w.matchText);\n\t\t\tvar tag = tagMatch && tagMatch[1];\n\t\t\tvar tagName = tag && tag.toLowerCase();\n\n\t\t\tif (tagName) {\n\t\t\t\tvar isVoid = this.voidElements.includes(tagName) || w.matchText.endsWith('/>');\n\t\t\t\tvar isNobr = this.nobrElements.includes(tagName);\n\t\t\t\tvar terminator = void 0;\n\t\t\t\tvar terminatorMatch = void 0;\n\n\t\t\t\tif (!isVoid) {\n\t\t\t\t\tterminator = '<\\\\/' + tagName + '\\\\s*>';\n\n\t\t\t\t\tvar terminatorRe = new RegExp(terminator, 'gim'); // ignore case during match\n\n\t\t\t\t\tterminatorRe.lastIndex = w.matchStart;\n\t\t\t\t\tterminatorMatch = terminatorRe.exec(w.source);\n\t\t\t\t}\n\n\t\t\t\tif (isVoid || terminatorMatch) {\n\t\t\t\t\tvar output = w.output;\n\t\t\t\t\tvar el = document.createElement(w.output.tagName);\n\t\t\t\t\tvar debugView = void 0;\n\n\t\t\t\t\tel.innerHTML = w.matchText;\n\n\t\t\t\t\t/*\n     \tNOTE: The use of a `while` statement here is curious, however,\n     \tI'm hesitant to change it for fear of breaking some edge case.\n     */\n\t\t\t\t\twhile (el.firstChild) {\n\t\t\t\t\t\tel = el.firstChild;\n\t\t\t\t\t}\n\n\t\t\t\t\ttry {\n\t\t\t\t\t\tthis.processAttributeDirectives(el);\n\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\treturn throwError(w.output, '<' + tagName + '>: ' + ex.message, w.matchText + '\\u2026');\n\t\t\t\t\t}\n\n\t\t\t\t\tif (el.hasAttribute('data-passage')) {\n\t\t\t\t\t\tthis.processDataAttributes(el, tagName);\n\n\t\t\t\t\t\t// Debug view setup.\n\t\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\t\tdebugView = new DebugView(w.output, 'html-' + tagName, tagName, w.matchText);\n\t\t\t\t\t\t\tdebugView.modes({\n\t\t\t\t\t\t\t\tblock: tagName === 'img',\n\t\t\t\t\t\t\t\tnonvoid: terminatorMatch\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\toutput = debugView.output;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (terminatorMatch) {\n\t\t\t\t\t\tw.subWikify(el, terminator, {\n\t\t\t\t\t\t\tignoreTerminatorCase: true,\n\t\t\t\t\t\t\tnobr: isNobr\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\t/*\n      \tDebug view modification.  If the current element has any debug\n      \tview descendants who have \"block\" mode set, then set its debug\n      \tview to the same.  It just makes things look a bit nicer.\n      */\n\t\t\t\t\t\tif (debugView && jQuery(el).find('.debug.block').length > 0) {\n\t\t\t\t\t\t\tdebugView.modes({ block: true });\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t/*\n     \tNOTE: The use of `cloneNode(true)` here for `<track>` elements\n     \tis necessary to workaround a poorly understood rehoming issue.\n     */\n\t\t\t\t\toutput.appendChild(tagName === 'track' ? el.cloneNode(true) : el);\n\t\t\t\t} else {\n\t\t\t\t\treturn throwError(w.output, 'cannot find a closing tag for HTML <' + tag + '>', w.matchText + '\\u2026');\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\tprocessAttributeDirectives: function processAttributeDirectives(el) {\n\t\t\t// NOTE: The `.attributes` property yields a live collection, so we\n\t\t\t// must make a non-live copy of it as we will be adding and removing\n\t\t\t// members of said collection if any directives are found.\n\t\t\t[].concat(_toConsumableArray(el.attributes)).forEach(function (_ref10) {\n\t\t\t\tvar name = _ref10.name,\n\t\t\t\t    value = _ref10.value;\n\n\t\t\t\tvar evalShorthand = name[0] === '@';\n\n\t\t\t\tif (evalShorthand || name.startsWith('sc-eval:')) {\n\t\t\t\t\tvar newName = name.slice(evalShorthand ? 1 : 8); // Remove eval directive prefix.\n\t\t\t\t\tvar result = void 0;\n\n\t\t\t\t\t// Evaluate the value as TwineScript.\n\t\t\t\t\ttry {\n\t\t\t\t\t\tresult = Scripting.evalTwineScript(value);\n\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\tthrow new Error('bad evaluation from attribute directive \"' + name + '\": ' + ex.message);\n\t\t\t\t\t}\n\n\t\t\t\t\t// Assign the result to the new attribute and remove the old one.\n\t\t\t\t\ttry {\n\t\t\t\t\t\t/*\n      \tNOTE: Most browsers (ca. Nov 2017) have broken `setAttribute()`\n      \tmethod implementations that throw on attribute names that start\n      \twith, or contain, various symbols that are completely valid per\n      \tthe specification.  Thus this code could fail if the user chooses\n      \tattribute names that, after removing the directive prefix, are\n      \tunpalatable to `setAttribute()`.\n      */\n\t\t\t\t\t\tel.setAttribute(newName, result);\n\t\t\t\t\t\tel.removeAttribute(name);\n\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\tthrow new Error('cannot transform attribute directive \"' + name + '\" into attribute \"' + newName + '\"');\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t},\n\t\tprocessDataAttributes: function processDataAttributes(el, tagName) {\n\t\t\tvar passage = el.getAttribute('data-passage');\n\n\t\t\tif (passage == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar evaluated = Wikifier.helpers.evalPassageId(passage);\n\n\t\t\tif (evaluated !== passage) {\n\t\t\t\tpassage = evaluated;\n\t\t\t\tel.setAttribute('data-passage', evaluated);\n\t\t\t}\n\n\t\t\tif (passage !== '') {\n\t\t\t\t// Media element, so attempt media passage transclusion.\n\t\t\t\tif (this.mediaElements.includes(tagName)) {\n\t\t\t\t\tif (passage.slice(0, 5) !== 'data:' && Story.has(passage)) {\n\t\t\t\t\t\tpassage = Story.get(passage);\n\n\t\t\t\t\t\tvar parentName = void 0;\n\t\t\t\t\t\tvar twineTag = void 0;\n\n\t\t\t\t\t\tswitch (tagName) {\n\t\t\t\t\t\t\tcase 'audio':\n\t\t\t\t\t\t\tcase 'video':\n\t\t\t\t\t\t\t\ttwineTag = 'Twine.' + tagName;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'img':\n\t\t\t\t\t\t\t\ttwineTag = 'Twine.image';\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'track':\n\t\t\t\t\t\t\t\ttwineTag = 'Twine.vtt';\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'source':\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tvar $parent = $(el).closest('audio,picture,video');\n\n\t\t\t\t\t\t\t\t\tif ($parent.length) {\n\t\t\t\t\t\t\t\t\t\tparentName = $parent.get(0).tagName.toLowerCase();\n\t\t\t\t\t\t\t\t\t\ttwineTag = 'Twine.' + (parentName === 'picture' ? 'image' : parentName);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (passage.tags.includes(twineTag)) {\n\t\t\t\t\t\t\tel[parentName === 'picture' ? 'srcset' : 'src'] = passage.text.trim();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Elsewise, assume a link element of some type—e.g. '<a>', '<area>', '<button>', etc.\n\t\t\t\telse {\n\t\t\t\t\t\tvar setter = el.getAttribute('data-setter');\n\t\t\t\t\t\tvar setFn = void 0;\n\n\t\t\t\t\t\tif (setter != null) {\n\t\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\t\tsetter = String(setter).trim();\n\n\t\t\t\t\t\t\tif (setter !== '') {\n\t\t\t\t\t\t\t\tsetFn = Wikifier.helpers.createShadowSetterCallback(Scripting.parse(setter));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (Story.has(passage)) {\n\t\t\t\t\t\t\tel.classList.add('link-internal');\n\n\t\t\t\t\t\t\tif (Config.addVisitedLinkClass && State.hasPlayed(passage)) {\n\t\t\t\t\t\t\t\tel.classList.add('link-visited');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tel.classList.add('link-broken');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tjQuery(el).ariaClick({ one: true }, function () {\n\t\t\t\t\t\t\tif (typeof setFn === 'function') {\n\t\t\t\t\t\t\t\tsetFn.call(this);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tEngine.play(passage);\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t}\n\t\t}\n\t});\n})();\n\n/***********************************************************************************************************************\n\n\tmarkup/template.js\n\n\tCopyright © 2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Patterns */\n\nvar Template = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Template definitions.\n\n\tvar _templates = new Map();\n\n\t// Valid template name regular expression.\n\tvar _validNameRe = new RegExp('^(?:' + Patterns.templateName + ')$');\n\n\t// Valid template type predicate.\n\tvar _validType = function _validType(template) {\n\t\tvar templateType = typeof template === 'undefined' ? 'undefined' : _typeof(template);\n\t\treturn templateType === 'function' || templateType === 'string';\n\t};\n\n\t/*******************************************************************************\n \tTemplate Functions.\n *******************************************************************************/\n\n\tfunction templateAdd(name, template) {\n\t\tif (!_validType(template) && !(template instanceof Array && template.length > 0 && template.every(_validType))) {\n\t\t\tthrow new Error('invalid template type (' + name + '); templates must be: functions, strings, or an array of either');\n\t\t}\n\n\t\t(name instanceof Array ? name : [name]).forEach(function (name) {\n\t\t\tif (_templates.has(name)) {\n\t\t\t\tthrow new Error('cannot clobber existing template ?' + name);\n\t\t\t}\n\t\t\tif (!_validNameRe.test(name)) {\n\t\t\t\tthrow new Error('invalid template name \"' + name + '\"');\n\t\t\t}\n\n\t\t\t_templates.set(name, template);\n\t\t});\n\t}\n\n\tfunction templateDelete(name) {\n\t\t(name instanceof Array ? name : [name]).forEach(function (name) {\n\t\t\treturn _templates.delete(name);\n\t\t});\n\t}\n\n\tfunction templateGet(name) {\n\t\treturn _templates.has(name) ? _templates.get(name) : null;\n\t}\n\n\tfunction templateHas(name) {\n\t\treturn _templates.has(name);\n\t}\n\n\tfunction templateSize() {\n\t\treturn _templates.size;\n\t}\n\n\t/*******************************************************************************\n \tObject Exports.\n *******************************************************************************/\n\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tadd: { value: templateAdd },\n\t\tdelete: { value: templateDelete },\n\t\tget: { value: templateGet },\n\t\thas: { value: templateHas },\n\t\tsize: { get: templateSize }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tmacros/macro.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Patterns, Scripting, clone, macros */\n\nvar Macro = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Macro definitions.\n\n\tvar _macros = {};\n\n\t// Map of all macro tags and their parents (key: 'tag name' => value: ['list of parent names']).\n\tvar _tags = {};\n\n\t// Valid macro name regular expression.\n\tvar _validNameRe = new RegExp('^(?:' + Patterns.macroName + ')$');\n\n\t/*******************************************************************************************************************\n \tMacros Functions.\n *******************************************************************************************************************/\n\tfunction macrosAdd(name, def, deep) {\n\t\tif (Array.isArray(name)) {\n\t\t\tname.forEach(function (name) {\n\t\t\t\treturn macrosAdd(name, def, deep);\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\tif (!_validNameRe.test(name)) {\n\t\t\tthrow new Error('invalid macro name \"' + name + '\"');\n\t\t}\n\n\t\tif (macrosHas(name)) {\n\t\t\tthrow new Error('cannot clobber existing macro <<' + name + '>>');\n\t\t} else if (tagsHas(name)) {\n\t\t\tthrow new Error('cannot clobber child tag <<' + name + '>> of parent macro' + (_tags[name].length === 1 ? '' : 's') + ' <<' + _tags[name].join('>>, <<') + '>>');\n\t\t}\n\n\t\ttry {\n\t\t\tif ((typeof def === 'undefined' ? 'undefined' : _typeof(def)) === 'object') {\n\t\t\t\t// Add the macro definition.\n\t\t\t\t_macros[name] = deep ? clone(def) : def;\n\t\t\t} else {\n\t\t\t\t// Add the macro alias.\n\t\t\t\tif (macrosHas(def)) {\n\t\t\t\t\t_macros[name] = deep ? clone(_macros[def]) : _macros[def];\n\t\t\t\t} else {\n\t\t\t\t\tthrow new Error('cannot create alias of nonexistent macro <<' + def + '>>');\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tObject.defineProperty(_macros, name, { writable: false });\n\n\t\t\t/* legacy */\n\t\t\t/*\n   \tSince `macrosGet()` may return legacy macros, we have to add a flag to (modern)\n   \tAPI macros, so that the macro formatter will know how to call the macro.\n   */\n\t\t\t_macros[name]._MACRO_API = true;\n\t\t\t/* /legacy */\n\t\t} catch (ex) {\n\t\t\tif (ex.name === 'TypeError') {\n\t\t\t\tthrow new Error('cannot clobber protected macro <<' + name + '>>');\n\t\t\t} else {\n\t\t\t\tthrow new Error('unknown error when attempting to add macro <<' + name + '>>: [' + ex.name + '] ' + ex.message);\n\t\t\t}\n\t\t}\n\n\t\t// Tags post-processing.\n\t\tif (_macros[name].hasOwnProperty('tags')) {\n\t\t\tif (_macros[name].tags == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\ttagsRegister(name);\n\t\t\t} else if (Array.isArray(_macros[name].tags)) {\n\t\t\t\ttagsRegister(name, _macros[name].tags);\n\t\t\t} else {\n\t\t\t\tthrow new Error('bad value for \"tags\" property of macro <<' + name + '>>');\n\t\t\t}\n\t\t}\n\t}\n\n\tfunction macrosDelete(name) {\n\t\tif (Array.isArray(name)) {\n\t\t\tname.forEach(function (name) {\n\t\t\t\treturn macrosDelete(name);\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\tif (macrosHas(name)) {\n\t\t\t// Tags pre-processing.\n\t\t\tif (_macros[name].hasOwnProperty('tags')) {\n\t\t\t\ttagsUnregister(name);\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\t// Remove the macro definition.\n\t\t\t\tObject.defineProperty(_macros, name, { writable: true });\n\t\t\t\tdelete _macros[name];\n\t\t\t} catch (ex) {\n\t\t\t\tthrow new Error('unknown error removing macro <<' + name + '>>: ' + ex.message);\n\t\t\t}\n\t\t} else if (tagsHas(name)) {\n\t\t\tthrow new Error('cannot remove child tag <<' + name + '>> of parent macro <<' + _tags[name] + '>>');\n\t\t}\n\t}\n\n\tfunction macrosIsEmpty() {\n\t\treturn Object.keys(_macros).length === 0;\n\t}\n\n\tfunction macrosHas(name) {\n\t\treturn _macros.hasOwnProperty(name);\n\t}\n\n\tfunction macrosGet(name) {\n\t\tvar macro = null;\n\n\t\tif (macrosHas(name) && typeof _macros[name].handler === 'function') {\n\t\t\tmacro = _macros[name];\n\t\t}\n\t\t/* legacy macro support */\n\t\telse if (macros.hasOwnProperty(name) && typeof macros[name].handler === 'function') {\n\t\t\t\tmacro = macros[name];\n\t\t\t}\n\t\t/* /legacy macro support */\n\n\t\treturn macro;\n\t}\n\n\tfunction macrosInit() {\n\t\tvar handler = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'init';\n\t\t// eslint-disable-line no-unused-vars\n\t\tObject.keys(_macros).forEach(function (name) {\n\t\t\tif (typeof _macros[name][handler] === 'function') {\n\t\t\t\t_macros[name][handler](name);\n\t\t\t}\n\t\t});\n\n\t\t/* legacy macro support */\n\t\tObject.keys(macros).forEach(function (name) {\n\t\t\tif (typeof macros[name][handler] === 'function') {\n\t\t\t\tmacros[name][handler](name);\n\t\t\t}\n\t\t});\n\t\t/* /legacy macro support */\n\t}\n\n\t/*******************************************************************************************************************\n \tTags Functions.\n *******************************************************************************************************************/\n\tfunction tagsRegister(parent, bodyTags) {\n\t\tif (!parent) {\n\t\t\tthrow new Error('no parent specified');\n\t\t}\n\n\t\tvar endTags = ['/' + parent, 'end' + parent]; // automatically create the closing tags\n\t\tvar allTags = [].concat(endTags, Array.isArray(bodyTags) ? bodyTags : []);\n\n\t\tfor (var i = 0; i < allTags.length; ++i) {\n\t\t\tvar tag = allTags[i];\n\n\t\t\tif (macrosHas(tag)) {\n\t\t\t\tthrow new Error('cannot register tag for an existing macro');\n\t\t\t}\n\n\t\t\tif (tagsHas(tag)) {\n\t\t\t\tif (!_tags[tag].includes(parent)) {\n\t\t\t\t\t_tags[tag].push(parent);\n\t\t\t\t\t_tags[tag].sort();\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t_tags[tag] = [parent];\n\t\t\t}\n\t\t}\n\t}\n\n\tfunction tagsUnregister(parent) {\n\t\tif (!parent) {\n\t\t\tthrow new Error('no parent specified');\n\t\t}\n\n\t\tObject.keys(_tags).forEach(function (tag) {\n\t\t\tvar i = _tags[tag].indexOf(parent);\n\n\t\t\tif (i !== -1) {\n\t\t\t\tif (_tags[tag].length === 1) {\n\t\t\t\t\tdelete _tags[tag];\n\t\t\t\t} else {\n\t\t\t\t\t_tags[tag].splice(i, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}\n\n\tfunction tagsHas(name) {\n\t\treturn _tags.hasOwnProperty(name);\n\t}\n\n\tfunction tagsGet(name) {\n\t\treturn tagsHas(name) ? _tags[name] : null;\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tMacro Functions.\n  */\n\t\tadd: { value: macrosAdd },\n\t\tdelete: { value: macrosDelete },\n\t\tisEmpty: { value: macrosIsEmpty },\n\t\thas: { value: macrosHas },\n\t\tget: { value: macrosGet },\n\t\tinit: { value: macrosInit },\n\n\t\t/*\n  \tTags Functions.\n  */\n\t\ttags: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tregister: { value: tagsRegister },\n\t\t\t\tunregister: { value: tagsUnregister },\n\t\t\t\thas: { value: tagsHas },\n\t\t\t\tget: { value: tagsGet }\n\t\t\t}))\n\t\t},\n\n\t\t/*\n  \tLegacy Aliases.\n  */\n\t\tevalStatements: { value: function value() {\n\t\t\t\treturn Scripting.evalJavaScript.apply(Scripting, arguments);\n\t\t\t} // SEE: `markup/scripting.js`.\n\t\t} }));\n}();\n\n/***********************************************************************************************************************\n\n\tmacros/macrocontext.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Config, DebugView, Patterns, State, Wikifier, throwError */\n\nvar MacroContext = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tMacroContext Class.\n *******************************************************************************************************************/\n\n\tvar MacroContext = function () {\n\t\tfunction MacroContext(contextData) {\n\t\t\t_classCallCheck(this, MacroContext);\n\n\t\t\tvar context = Object.assign({\n\t\t\t\tparent: null,\n\t\t\t\tmacro: null,\n\t\t\t\tname: '',\n\t\t\t\targs: null,\n\t\t\t\tpayload: null,\n\t\t\t\tparser: null,\n\t\t\t\tsource: ''\n\t\t\t}, contextData);\n\n\t\t\tif (context.macro === null || context.name === '' || context.parser === null) {\n\t\t\t\tthrow new TypeError('context object missing required properties');\n\t\t\t}\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\tself: {\n\t\t\t\t\tvalue: context.macro\n\t\t\t\t},\n\n\t\t\t\tname: {\n\t\t\t\t\tvalue: context.name\n\t\t\t\t},\n\n\t\t\t\targs: {\n\t\t\t\t\tvalue: context.args\n\t\t\t\t},\n\n\t\t\t\tpayload: {\n\t\t\t\t\tvalue: context.payload\n\t\t\t\t},\n\n\t\t\t\tsource: {\n\t\t\t\t\tvalue: context.source\n\t\t\t\t},\n\n\t\t\t\tparent: {\n\t\t\t\t\tvalue: context.parent\n\t\t\t\t},\n\n\t\t\t\tparser: {\n\t\t\t\t\tvalue: context.parser\n\t\t\t\t},\n\n\t\t\t\t_output: {\n\t\t\t\t\tvalue: context.parser.output\n\t\t\t\t},\n\n\t\t\t\t_shadows: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: null\n\t\t\t\t},\n\n\t\t\t\t_debugView: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: null\n\t\t\t\t},\n\n\t\t\t\t_debugViewEnabled: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: Config.debug\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t_createClass(MacroContext, [{\n\t\t\tkey: 'contextHas',\n\t\t\tvalue: function contextHas(filter) {\n\t\t\t\tvar context = this;\n\n\t\t\t\twhile ((context = context.parent) !== null) {\n\t\t\t\t\tif (filter(context)) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'contextSelect',\n\t\t\tvalue: function contextSelect(filter) {\n\t\t\t\tvar context = this;\n\n\t\t\t\twhile ((context = context.parent) !== null) {\n\t\t\t\t\tif (filter(context)) {\n\t\t\t\t\t\treturn context;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'contextSelectAll',\n\t\t\tvalue: function contextSelectAll(filter) {\n\t\t\t\tvar result = [];\n\t\t\t\tvar context = this;\n\n\t\t\t\twhile ((context = context.parent) !== null) {\n\t\t\t\t\tif (filter(context)) {\n\t\t\t\t\t\tresult.push(context);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn result;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'addShadow',\n\t\t\tvalue: function addShadow() {\n\t\t\t\tvar _this11 = this;\n\n\t\t\t\tif (!this._shadows) {\n\t\t\t\t\tthis._shadows = new Set();\n\t\t\t\t}\n\n\t\t\t\tvar varRe = new RegExp('^' + Patterns.variable + '$');\n\n\t\t\t\tfor (var _len14 = arguments.length, names = Array(_len14), _key14 = 0; _key14 < _len14; _key14++) {\n\t\t\t\t\tnames[_key14] = arguments[_key14];\n\t\t\t\t}\n\n\t\t\t\tnames.flat(Infinity).forEach(function (name) {\n\t\t\t\t\tif (typeof name !== 'string') {\n\t\t\t\t\t\tthrow new TypeError('variable name must be a string; type: ' + (typeof name === 'undefined' ? 'undefined' : _typeof(name)));\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!varRe.test(name)) {\n\t\t\t\t\t\tthrow new Error('invalid variable name \"' + name + '\"');\n\t\t\t\t\t}\n\n\t\t\t\t\t_this11._shadows.add(name);\n\t\t\t\t});\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'createShadowWrapper',\n\t\t\tvalue: function createShadowWrapper(callback, doneCallback, startCallback) {\n\t\t\t\tvar shadowContext = this;\n\t\t\t\tvar shadowStore = void 0;\n\n\t\t\t\tif (typeof callback === 'function') {\n\t\t\t\t\tshadowStore = {};\n\t\t\t\t\tthis.shadowView.forEach(function (varName) {\n\t\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\t\t\t\t\t\tshadowStore[varName] = store[varKey];\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\treturn function () {\n\t\t\t\t\tfor (var _len15 = arguments.length, args = Array(_len15), _key15 = 0; _key15 < _len15; _key15++) {\n\t\t\t\t\t\targs[_key15] = arguments[_key15];\n\t\t\t\t\t}\n\n\t\t\t\t\tif (typeof startCallback === 'function') {\n\t\t\t\t\t\tstartCallback.apply(this, args);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (typeof callback === 'function') {\n\t\t\t\t\t\tvar shadowNames = Object.keys(shadowStore);\n\t\t\t\t\t\tvar valueCache = shadowNames.length > 0 ? {} : null;\n\t\t\t\t\t\tvar macroParser = Wikifier.Parser.get('macro');\n\t\t\t\t\t\tvar contextCache = void 0;\n\n\t\t\t\t\t\t/*\n      \tThere's no catch clause because this try/finally is here simply to ensure that\n      \tproper cleanup is done in the event that an exception is thrown during the\n      \tcallback.\n      */\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t/*\n       \tCache the existing values of the variables to be shadowed and assign the\n       \tshadow values.\n       */\n\t\t\t\t\t\t\tshadowNames.forEach(function (varName) {\n\t\t\t\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\n\t\t\t\t\t\t\t\tif (store.hasOwnProperty(varKey)) {\n\t\t\t\t\t\t\t\t\tvalueCache[varKey] = store[varKey];\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tstore[varKey] = shadowStore[varName];\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t// Cache the existing macro execution context and assign the shadow context.\n\t\t\t\t\t\t\tcontextCache = macroParser.context;\n\t\t\t\t\t\t\tmacroParser.context = shadowContext;\n\n\t\t\t\t\t\t\t// Call the callback function.\n\t\t\t\t\t\t\tcallback.apply(this, args);\n\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t// Revert the macro execution context shadowing.\n\t\t\t\t\t\t\tif (contextCache !== undefined) {\n\t\t\t\t\t\t\t\tmacroParser.context = contextCache;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Revert the variable shadowing.\n\t\t\t\t\t\t\tshadowNames.forEach(function (varName) {\n\t\t\t\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\n\t\t\t\t\t\t\t\t/*\n        \tUpdate the shadow store with the variable's current value, in case it\n        \twas modified during the callback.\n        */\n\t\t\t\t\t\t\t\tshadowStore[varName] = store[varKey];\n\n\t\t\t\t\t\t\t\tif (valueCache.hasOwnProperty(varKey)) {\n\t\t\t\t\t\t\t\t\tstore[varKey] = valueCache[varKey];\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tdelete store[varKey];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (typeof doneCallback === 'function') {\n\t\t\t\t\t\tdoneCallback.apply(this, args);\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'createDebugView',\n\t\t\tvalue: function createDebugView(name, title) {\n\t\t\t\tthis._debugView = new DebugView(this._output, 'macro', name ? name : this.name, title ? title : this.source);\n\n\t\t\t\tif (this.payload !== null && this.payload.length > 0) {\n\t\t\t\t\tthis._debugView.modes({ nonvoid: true });\n\t\t\t\t}\n\n\t\t\t\tthis._debugViewEnabled = true;\n\t\t\t\treturn this._debugView;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'removeDebugView',\n\t\t\tvalue: function removeDebugView() {\n\t\t\t\tif (this._debugView !== null) {\n\t\t\t\t\tthis._debugView.remove();\n\t\t\t\t\tthis._debugView = null;\n\t\t\t\t}\n\n\t\t\t\tthis._debugViewEnabled = false;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'error',\n\t\t\tvalue: function error(message, source) {\n\t\t\t\treturn throwError(this._output, '<<' + this.name + '>>: ' + message, source ? source : this.source);\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'output',\n\t\t\tget: function get() {\n\t\t\t\treturn this._debugViewEnabled ? this.debugView.output : this._output;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'shadows',\n\t\t\tget: function get() {\n\t\t\t\treturn [].concat(_toConsumableArray(this._shadows));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'shadowView',\n\t\t\tget: function get() {\n\t\t\t\tvar view = new Set();\n\t\t\t\tthis.contextSelectAll(function (ctx) {\n\t\t\t\t\treturn ctx._shadows;\n\t\t\t\t}).forEach(function (ctx) {\n\t\t\t\t\treturn ctx._shadows.forEach(function (name) {\n\t\t\t\t\t\treturn view.add(name);\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t\treturn [].concat(_toConsumableArray(view));\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'debugView',\n\t\t\tget: function get() {\n\t\t\t\tif (this._debugViewEnabled) {\n\t\t\t\t\treturn this._debugView !== null ? this._debugView : this.createDebugView();\n\t\t\t\t}\n\n\t\t\t\treturn null;\n\t\t\t}\n\t\t}]);\n\n\t\treturn MacroContext;\n\t}();\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\n\n\treturn MacroContext;\n}();\n\n/***********************************************************************************************************************\n\n\tmacros/macrolib.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Config, DebugView, Engine, Has, L10n, Macro, Patterns, Scripting, SimpleAudio, State, Story,\n\t       TempState, Util, Wikifier, postdisplay, prehistory, storage, toStringOrDefault\n*/\n\n(function () {\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tVariables Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<capture>>\n */\n\n\tMacro.add('capture', {\n\t\tskipArgs: true,\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.raw.length === 0) {\n\t\t\t\treturn this.error('no story/temporary variable list specified');\n\t\t\t}\n\n\t\t\tvar valueCache = {};\n\n\t\t\t/*\n   \tThere's no catch clause because this try/finally is here simply to ensure that\n   \tproper cleanup is done in the event that an exception is thrown during the\n   \t`Wikifier` call.\n   */\n\t\t\ttry {\n\t\t\t\tvar varRe = new RegExp('(' + Patterns.variable + ')', 'g');\n\t\t\t\tvar match = void 0;\n\n\t\t\t\t/*\n    \tCache the existing values of the variables and add a shadow.\n    */\n\t\t\t\twhile ((match = varRe.exec(this.args.raw)) !== null) {\n\t\t\t\t\tvar varName = match[1];\n\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\n\t\t\t\t\tif (store.hasOwnProperty(varKey)) {\n\t\t\t\t\t\tvalueCache[varKey] = store[varKey];\n\t\t\t\t\t}\n\n\t\t\t\t\tthis.addShadow(varName);\n\t\t\t\t}\n\n\t\t\t\tnew Wikifier(this.output, this.payload[0].contents);\n\t\t\t} finally {\n\t\t\t\t// Revert the variable shadowing.\n\t\t\t\tthis.shadows.forEach(function (varName) {\n\t\t\t\t\tvar varKey = varName.slice(1);\n\t\t\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\n\t\t\t\t\tif (valueCache.hasOwnProperty(varKey)) {\n\t\t\t\t\t\tstore[varKey] = valueCache[varKey];\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdelete store[varKey];\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<set>>\n */\n\tMacro.add('set', {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.full.length === 0) {\n\t\t\t\treturn this.error('no expression specified');\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tScripting.evalJavaScript(this.args.full);\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad evaluation: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<unset>>\n */\n\tMacro.add('unset', {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.full.length === 0) {\n\t\t\t\treturn this.error('no story/temporary variable list specified');\n\t\t\t}\n\n\t\t\tvar re = new RegExp('State\\\\.(variables|temporary)\\\\.(' + Patterns.identifier + ')', 'g');\n\t\t\tvar match = void 0;\n\n\t\t\twhile ((match = re.exec(this.args.full)) !== null) {\n\t\t\t\tvar store = State[match[1]];\n\t\t\t\tvar name = match[2];\n\n\t\t\t\tif (store.hasOwnProperty(name)) {\n\t\t\t\t\tdelete store[name];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<remember>>\n */\n\tMacro.add('remember', {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.full.length === 0) {\n\t\t\t\treturn this.error('no expression specified');\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tScripting.evalJavaScript(this.args.full);\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad evaluation: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t}\n\n\t\t\tvar remember = storage.get('remember') || {};\n\t\t\tvar re = new RegExp('State\\\\.variables\\\\.(' + Patterns.identifier + ')', 'g');\n\t\t\tvar match = void 0;\n\n\t\t\twhile ((match = re.exec(this.args.full)) !== null) {\n\t\t\t\tvar name = match[1];\n\t\t\t\tremember[name] = State.variables[name];\n\t\t\t}\n\n\t\t\tif (!storage.set('remember', remember)) {\n\t\t\t\treturn this.error('unknown error, cannot remember: ' + this.args.raw);\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t},\n\t\tinit: function init() {\n\t\t\tvar remember = storage.get('remember');\n\n\t\t\tif (remember) {\n\t\t\t\tObject.keys(remember).forEach(function (name) {\n\t\t\t\t\treturn State.variables[name] = remember[name];\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<forget>>\n */\n\tMacro.add('forget', {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.full.length === 0) {\n\t\t\t\treturn this.error('no story variable list specified');\n\t\t\t}\n\n\t\t\tvar remember = storage.get('remember');\n\t\t\tvar re = new RegExp('State\\\\.variables\\\\.(' + Patterns.identifier + ')', 'g');\n\t\t\tvar match = void 0;\n\t\t\tvar needStore = false;\n\n\t\t\twhile ((match = re.exec(this.args.full)) !== null) {\n\t\t\t\tvar name = match[1];\n\n\t\t\t\tif (State.variables.hasOwnProperty(name)) {\n\t\t\t\t\tdelete State.variables[name];\n\t\t\t\t}\n\n\t\t\t\tif (remember && remember.hasOwnProperty(name)) {\n\t\t\t\t\tneedStore = true;\n\t\t\t\t\tdelete remember[name];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (needStore) {\n\t\t\t\tif (Object.keys(remember).length === 0) {\n\t\t\t\t\tif (!storage.delete('remember')) {\n\t\t\t\t\t\treturn this.error('unknown error, cannot update remember store');\n\t\t\t\t\t}\n\t\t\t\t} else if (!storage.set('remember', remember)) {\n\t\t\t\t\treturn this.error('unknown error, cannot update remember store');\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tScripting Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<run>>\n */\n\tMacro.add('run', 'set'); // add <<run>> as an alias of <<set>>\n\n\t/*\n \t<<script>>\n */\n\tMacro.add('script', {\n\t\tskipArgs: true,\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tvar output = document.createDocumentFragment();\n\n\t\t\ttry {\n\t\t\t\tScripting.evalJavaScript(this.payload[0].contents, output);\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad evaluation: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex), this.source + this.payload[0].contents + '<</' + this.name + '>>');\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.createDebugView();\n\t\t\t}\n\n\t\t\tif (output.hasChildNodes()) {\n\t\t\t\tthis.output.appendChild(output);\n\t\t\t}\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tDisplay Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<include>>\n */\n\tMacro.add('include', {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no passage specified');\n\t\t\t}\n\n\t\t\tvar passage = void 0;\n\n\t\t\tif (_typeof(this.args[0]) === 'object') {\n\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\tpassage = this.args[0].link;\n\t\t\t} else {\n\t\t\t\t// Argument was simply the passage name.\n\t\t\t\tpassage = this.args[0];\n\t\t\t}\n\n\t\t\tif (!Story.has(passage)) {\n\t\t\t\treturn this.error('passage \"' + passage + '\" does not exist');\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\tpassage = Story.get(passage);\n\t\t\tvar $el = void 0;\n\n\t\t\tif (this.args[1]) {\n\t\t\t\t$el = jQuery(document.createElement(this.args[1])).addClass(passage.domId + ' macro-' + this.name).attr('data-passage', passage.title).appendTo(this.output);\n\t\t\t} else {\n\t\t\t\t$el = jQuery(this.output);\n\t\t\t}\n\n\t\t\t$el.wiki(passage.processText());\n\t\t}\n\t});\n\n\t/*\n \t<<nobr>>\n */\n\tMacro.add('nobr', {\n\t\tskipArgs: true,\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\t/*\n   \tWikify the contents, after removing all leading & trailing newlines and compacting\n   \tall internal sequences of newlines into single spaces.\n   */\n\t\t\tnew Wikifier(this.output, this.payload[0].contents.replace(/^\\n+|\\n+$/g, '').replace(/\\n+/g, ' '));\n\t\t}\n\t});\n\n\t/*\n \t<<print>>, <<=>>, & <<->>\n */\n\tMacro.add(['print', '=', '-'], {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.full.length === 0) {\n\t\t\t\treturn this.error('no expression specified');\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tvar result = toStringOrDefault(Scripting.evalJavaScript(this.args.full), null);\n\n\t\t\t\tif (result !== null) {\n\t\t\t\t\tnew Wikifier(this.output, this.name === '-' ? Util.escape(result) : result);\n\t\t\t\t}\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad evaluation: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<silently>>\n */\n\tMacro.add('silently', {\n\t\tskipArgs: true,\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tvar frag = document.createDocumentFragment();\n\t\t\tnew Wikifier(frag, this.payload[0].contents.trim());\n\n\t\t\tif (Config.debug) {\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\tthis.output.appendChild(frag);\n\t\t\t} else {\n\t\t\t\t// Discard the output, unless there were errors.\n\t\t\t\tvar errList = [].concat(_toConsumableArray(frag.querySelectorAll('.error'))).map(function (errEl) {\n\t\t\t\t\treturn errEl.textContent;\n\t\t\t\t});\n\n\t\t\t\tif (errList.length > 0) {\n\t\t\t\t\treturn this.error('error' + (errList.length === 1 ? '' : 's') + ' within contents (' + errList.join('; ') + ')', this.source + this.payload[0].contents + '<</' + this.name + '>>');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t[DEPRECATED] <<display>>\n */\n\tMacro.add('display', 'include'); // add <<display>> as an alias of <<include>>\n\n\n\t/*******************************************************************************************************************\n \tControl Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<if>>, <<elseif>>, & <<else>>\n */\n\tMacro.add('if', {\n\t\tskipArgs: true,\n\t\ttags: ['elseif', 'else'],\n\n\t\thandler: function handler() {\n\t\t\tvar i = void 0;\n\n\t\t\ttry {\n\t\t\t\tvar len = this.payload.length;\n\n\t\t\t\t// Sanity checks.\n\t\t\t\tfor ( /* declared previously */i = 0; i < len; ++i) {\n\t\t\t\t\t/* eslint-disable prefer-template */\n\t\t\t\t\tswitch (this.payload[i].name) {\n\t\t\t\t\t\tcase 'else':\n\t\t\t\t\t\t\tif (this.payload[i].args.raw.length > 0) {\n\t\t\t\t\t\t\t\tif (/^\\s*if\\b/i.test(this.payload[i].args.raw)) {\n\t\t\t\t\t\t\t\t\treturn this.error('whitespace is not allowed between the \"else\" and \"if\" in <<elseif>> clause' + (i > 0 ? ' (#' + i + ')' : ''));\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\treturn this.error('<<else>> does not accept a conditional expression (perhaps you meant to use <<elseif>>), invalid: ' + this.payload[i].args.raw);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (i + 1 !== len) {\n\t\t\t\t\t\t\t\treturn this.error('<<else>> must be the final clause');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tif (this.payload[i].args.full.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('no conditional expression specified for <<' + this.payload[i].name + '>> clause' + (i > 0 ? ' (#' + i + ')' : ''));\n\t\t\t\t\t\t\t} else if (Config.macros.ifAssignmentError && /[^!=&^|<>*/%+-]=[^=]/.test(this.payload[i].args.full)) {\n\t\t\t\t\t\t\t\treturn this.error('assignment operator found within <<' + this.payload[i].name + '>> clause' + (i > 0 ? ' (#' + i + ')' : '') + ' (perhaps you meant to use an equality operator: ==, ===, eq, is), invalid: ' + this.payload[i].args.raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t/* eslint-enable prefer-template */\n\t\t\t\t}\n\n\t\t\t\tvar evalJavaScript = Scripting.evalJavaScript;\n\t\t\t\tvar success = false;\n\n\t\t\t\t// Evaluate the clauses.\n\t\t\t\tfor ( /* declared previously */i = 0; i < len; ++i) {\n\t\t\t\t\t// Custom debug view setup for the current clause.\n\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\tthis.createDebugView(this.payload[i].name, this.payload[i].source).modes({ nonvoid: false });\n\t\t\t\t\t}\n\n\t\t\t\t\t// Conditional test.\n\t\t\t\t\tif (this.payload[i].name === 'else' || !!evalJavaScript(this.payload[i].args.full)) {\n\t\t\t\t\t\tsuccess = true;\n\t\t\t\t\t\tnew Wikifier(this.output, this.payload[i].contents);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t} else if (Config.debug) {\n\t\t\t\t\t\t// Custom debug view setup for a failed conditional.\n\t\t\t\t\t\tthis.debugView.modes({\n\t\t\t\t\t\t\thidden: true,\n\t\t\t\t\t\t\tinvalid: true\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Custom debug view setup for the remaining clauses.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tfor (++i; i < len; ++i) {\n\t\t\t\t\t\tthis.createDebugView(this.payload[i].name, this.payload[i].source).modes({\n\t\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\t\thidden: true,\n\t\t\t\t\t\t\tinvalid: true\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\n\t\t\t\t\t/*\n     \tFake a debug view for `<</if>>`.  We do this to aid the checking of nesting\n     \tand as a quick indicator of if any of the clauses matched.\n     */\n\t\t\t\t\tthis.createDebugView('/' + this.name, '<</' + this.name + '>>').modes({\n\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\thidden: !success,\n\t\t\t\t\t\tinvalid: !success\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad conditional expression in <<' + (i === 0 ? 'if' : 'elseif') + '>> clause' + (i > 0 ? ' (#' + i + ')' : '') + ': ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex)); // eslint-disable-line prefer-template\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<switch>>, <<case>>, & <<default>>\n */\n\tMacro.add('switch', {\n\t\tskipArgs: ['switch'],\n\t\ttags: ['case', 'default'],\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.full.length === 0) {\n\t\t\t\treturn this.error('no expression specified');\n\t\t\t}\n\n\t\t\tvar len = this.payload.length;\n\n\t\t\t// if (len === 1 || !this.payload.some(p => p.name === 'case')) {\n\t\t\tif (len === 1) {\n\t\t\t\treturn this.error('no cases specified');\n\t\t\t}\n\n\t\t\tvar i = void 0;\n\n\t\t\t// Sanity checks.\n\t\t\tfor ( /* declared previously */i = 1; i < len; ++i) {\n\t\t\t\tswitch (this.payload[i].name) {\n\t\t\t\t\tcase 'default':\n\t\t\t\t\t\tif (this.payload[i].args.length > 0) {\n\t\t\t\t\t\t\treturn this.error('<<default>> does not accept values, invalid: ' + this.payload[i].args.raw);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (i + 1 !== len) {\n\t\t\t\t\t\t\treturn this.error('<<default>> must be the final case');\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tif (this.payload[i].args.length === 0) {\n\t\t\t\t\t\t\treturn this.error('no value(s) specified for <<' + this.payload[i].name + '>> (#' + i + ')');\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tvar result = void 0;\n\n\t\t\ttry {\n\t\t\t\tresult = Scripting.evalJavaScript(this.args.full);\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad evaluation: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t}\n\n\t\t\tvar debugView = this.debugView; // cache it now, to be modified later\n\t\t\tvar success = false;\n\n\t\t\t// Initial debug view setup for `<<switch>>`.\n\t\t\tif (Config.debug) {\n\t\t\t\tdebugView.modes({\n\t\t\t\t\tnonvoid: false,\n\t\t\t\t\thidden: true\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Evaluate the clauses.\n\t\t\tfor ( /* declared previously */i = 1; i < len; ++i) {\n\t\t\t\t// Custom debug view setup for the current case.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.createDebugView(this.payload[i].name, this.payload[i].source).modes({ nonvoid: false });\n\t\t\t\t}\n\n\t\t\t\t// Case test(s).\n\t\t\t\tif (this.payload[i].name === 'default' || this.payload[i].args.some(function (val) {\n\t\t\t\t\treturn val === result;\n\t\t\t\t})) {\n\t\t\t\t\tsuccess = true;\n\t\t\t\t\tnew Wikifier(this.output, this.payload[i].contents);\n\t\t\t\t\tbreak;\n\t\t\t\t} else if (Config.debug) {\n\t\t\t\t\t// Custom debug view setup for a failed case.\n\t\t\t\t\tthis.debugView.modes({\n\t\t\t\t\t\thidden: true,\n\t\t\t\t\t\tinvalid: true\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Custom debug view setup for the remaining cases.\n\t\t\tif (Config.debug) {\n\t\t\t\tfor (++i; i < len; ++i) {\n\t\t\t\t\tthis.createDebugView(this.payload[i].name, this.payload[i].source).modes({\n\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\thidden: true,\n\t\t\t\t\t\tinvalid: true\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t/*\n    \tFinalize the debug view for `<<switch>>` and fake a debug view for `<</switch>>`.\n    \tWe do both as a quick indicator of if any of the cases matched and the latter\n    \tto aid the checking of nesting.\n    */\n\t\t\t\tdebugView.modes({\n\t\t\t\t\tnonvoid: false,\n\t\t\t\t\thidden: true, // !success,\n\t\t\t\t\tinvalid: !success\n\t\t\t\t});\n\t\t\t\tthis.createDebugView('/' + this.name, '<</' + this.name + '>>').modes({\n\t\t\t\t\tnonvoid: false,\n\t\t\t\t\thidden: true, // !success,\n\t\t\t\t\tinvalid: !success\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<for>>, <<break>>, & <<continue>>\n */\n\tMacro.add('for', {\n\t\t/* eslint-disable max-len */\n\t\tskipArgs: true,\n\t\ttags: null,\n\t\t_hasRangeRe: new RegExp('^\\\\S' + Patterns.anyChar + '*?\\\\s+range\\\\s+\\\\S' + Patterns.anyChar + '*?$'),\n\t\t_rangeRe: new RegExp('^(?:State\\\\.(variables|temporary)\\\\.(' + Patterns.identifier + ')\\\\s*,\\\\s*)?State\\\\.(variables|temporary)\\\\.(' + Patterns.identifier + ')\\\\s+range\\\\s+(\\\\S' + Patterns.anyChar + '*?)$'),\n\t\t_3PartRe: /^([^;]*?)\\s*;\\s*([^;]*?)\\s*;\\s*([^;]*?)$/,\n\t\t/* eslint-enable max-len */\n\n\t\thandler: function handler() {\n\t\t\tvar argsStr = this.args.full.trim();\n\t\t\tvar payload = this.payload[0].contents.replace(/\\n$/, '');\n\n\t\t\t// Empty form.\n\t\t\tif (argsStr.length === 0) {\n\t\t\t\tthis.self._handleFor.call(this, payload, null, true, null);\n\t\t\t}\n\n\t\t\t// Range form.\n\t\t\telse if (this.self._hasRangeRe.test(argsStr)) {\n\t\t\t\t\tvar parts = argsStr.match(this.self._rangeRe);\n\n\t\t\t\t\tif (parts === null) {\n\t\t\t\t\t\treturn this.error('invalid range form syntax, format: [index ,] value range collection');\n\t\t\t\t\t}\n\n\t\t\t\t\tthis.self._handleForRange.call(this, payload, { type: parts[1], name: parts[2] }, { type: parts[3], name: parts[4] }, parts[5]);\n\t\t\t\t}\n\n\t\t\t\t// Conditional forms.\n\t\t\t\telse {\n\t\t\t\t\t\tvar init = void 0;\n\t\t\t\t\t\tvar condition = void 0;\n\t\t\t\t\t\tvar post = void 0;\n\n\t\t\t\t\t\t// Conditional-only form.\n\t\t\t\t\t\tif (argsStr.indexOf(';') === -1) {\n\t\t\t\t\t\t\t// Sanity checks.\n\t\t\t\t\t\t\tif (/^\\S+\\s+in\\s+\\S+/i.test(argsStr)) {\n\t\t\t\t\t\t\t\treturn this.error('invalid syntax, for…in is not supported; see: for…range');\n\t\t\t\t\t\t\t} else if (/^\\S+\\s+of\\s+\\S+/i.test(argsStr)) {\n\t\t\t\t\t\t\t\treturn this.error('invalid syntax, for…of is not supported; see: for…range');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tcondition = argsStr;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// 3-part conditional form.\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\tvar _parts = argsStr.match(this.self._3PartRe);\n\n\t\t\t\t\t\t\t\tif (_parts === null) {\n\t\t\t\t\t\t\t\t\treturn this.error('invalid 3-part conditional form syntax, format: [init] ; [condition] ; [post]');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tinit = _parts[1];\n\t\t\t\t\t\t\t\tcondition = _parts[2].trim();\n\t\t\t\t\t\t\t\tpost = _parts[3];\n\n\t\t\t\t\t\t\t\tif (condition.length === 0) {\n\t\t\t\t\t\t\t\t\tcondition = true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\tthis.self._handleFor.call(this, payload, init, condition, post);\n\t\t\t\t\t}\n\t\t},\n\t\t_handleFor: function _handleFor(payload, init, condition, post) {\n\t\t\tvar evalJavaScript = Scripting.evalJavaScript;\n\t\t\tvar first = true;\n\t\t\tvar safety = Config.macros.maxLoopIterations;\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tTempState.break = null;\n\n\t\t\t\tif (init) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tevalJavaScript(init);\n\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\treturn this.error('bad init expression: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\twhile (evalJavaScript(condition)) {\n\t\t\t\t\tif (--safety < 0) {\n\t\t\t\t\t\treturn this.error('exceeded configured maximum loop iterations (' + Config.macros.maxLoopIterations + ')');\n\t\t\t\t\t}\n\n\t\t\t\t\tnew Wikifier(this.output, first ? payload.replace(/^\\n/, '') : payload);\n\n\t\t\t\t\tif (first) {\n\t\t\t\t\t\tfirst = false;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (TempState.break != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tif (TempState.break === 1) {\n\t\t\t\t\t\t\tTempState.break = null;\n\t\t\t\t\t\t} else if (TempState.break === 2) {\n\t\t\t\t\t\t\tTempState.break = null;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (post) {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tevalJavaScript(post);\n\t\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\t\treturn this.error('bad post expression: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('bad conditional expression: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex));\n\t\t\t} finally {\n\t\t\t\tTempState.break = null;\n\t\t\t}\n\t\t},\n\t\t_handleForRange: function _handleForRange(payload, indexVar, valueVar, rangeExp) {\n\t\t\tvar first = true;\n\t\t\tvar rangeList = void 0;\n\n\t\t\ttry {\n\t\t\t\trangeList = this.self._toRangeList(rangeExp);\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error(ex.message);\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tTempState.break = null;\n\n\t\t\t\tfor (var i = 0; i < rangeList.length; ++i) {\n\t\t\t\t\tif (indexVar.name) {\n\t\t\t\t\t\tState[indexVar.type][indexVar.name] = rangeList[i][0];\n\t\t\t\t\t}\n\n\t\t\t\t\tState[valueVar.type][valueVar.name] = rangeList[i][1];\n\n\t\t\t\t\tnew Wikifier(this.output, first ? payload.replace(/^\\n/, '') : payload);\n\n\t\t\t\t\tif (first) {\n\t\t\t\t\t\tfirst = false;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (TempState.break != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tif (TempState.break === 1) {\n\t\t\t\t\t\t\tTempState.break = null;\n\t\t\t\t\t\t} else if (TempState.break === 2) {\n\t\t\t\t\t\t\tTempState.break = null;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex);\n\t\t\t} finally {\n\t\t\t\tTempState.break = null;\n\t\t\t}\n\t\t},\n\t\t_toRangeList: function _toRangeList(rangeExp) {\n\t\t\tvar evalJavaScript = Scripting.evalJavaScript;\n\t\t\tvar value = void 0;\n\n\t\t\ttry {\n\t\t\t\t/*\n    \tNOTE: If the first character is the left curly brace, then we\n    \tassume that it's part of an object literal and wrap it within\n    \tparenthesis to ensure that it is not mistaken for a block\n    \tduring evaluation—which would cause an error.\n    */\n\t\t\t\tvalue = evalJavaScript(rangeExp[0] === '{' ? '(' + rangeExp + ')' : rangeExp);\n\t\t\t} catch (ex) {\n\t\t\t\tif ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) !== 'object') {\n\t\t\t\t\tthrow new Error('bad range expression: ' + ex);\n\t\t\t\t}\n\n\t\t\t\tex.message = 'bad range expression: ' + ex.message;\n\t\t\t\tthrow ex;\n\t\t\t}\n\n\t\t\tvar list = void 0;\n\n\t\t\tswitch (typeof value === 'undefined' ? 'undefined' : _typeof(value)) {\n\t\t\t\tcase 'string':\n\t\t\t\t\tlist = [];\n\t\t\t\t\tfor (var i = 0; i < value.length;) /* empty */{\n\t\t\t\t\t\tvar obj = Util.charAndPosAt(value, i);\n\t\t\t\t\t\tlist.push([i, obj.char]);\n\t\t\t\t\t\ti = 1 + obj.end;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'object':\n\t\t\t\t\tif (Array.isArray(value)) {\n\t\t\t\t\t\tlist = value.map(function (val, i) {\n\t\t\t\t\t\t\treturn [i, val];\n\t\t\t\t\t\t});\n\t\t\t\t\t} else if (value instanceof Set) {\n\t\t\t\t\t\tlist = [].concat(_toConsumableArray(value)).map(function (val, i) {\n\t\t\t\t\t\t\treturn [i, val];\n\t\t\t\t\t\t});\n\t\t\t\t\t} else if (value instanceof Map) {\n\t\t\t\t\t\tlist = [].concat(_toConsumableArray(value.entries()));\n\t\t\t\t\t} else if (Util.toStringTag(value) === 'Object') {\n\t\t\t\t\t\tlist = Object.keys(value).map(function (key) {\n\t\t\t\t\t\t\treturn [key, value[key]];\n\t\t\t\t\t\t});\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthrow new Error('unsupported range expression type: ' + Util.toStringTag(value));\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error('unsupported range expression type: ' + (typeof value === 'undefined' ? 'undefined' : _typeof(value)));\n\t\t\t}\n\n\t\t\treturn list;\n\t\t}\n\t});\n\tMacro.add(['break', 'continue'], {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.contextHas(function (ctx) {\n\t\t\t\treturn ctx.name === 'for';\n\t\t\t})) {\n\t\t\t\tTempState.break = this.name === 'continue' ? 1 : 2;\n\t\t\t} else {\n\t\t\t\treturn this.error('must only be used in conjunction with its parent macro <<for>>');\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tInteractive Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<button>> & <<link>>\n */\n\tMacro.add(['button', 'link'], {\n\t\tisAsync: true,\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tvar _this12 = this;\n\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no ' + (this.name === 'button' ? 'button' : 'link') + ' text specified');\n\t\t\t}\n\n\t\t\tvar $link = jQuery(document.createElement(this.name === 'button' ? 'button' : 'a'));\n\t\t\tvar passage = void 0;\n\n\t\t\tif (_typeof(this.args[0]) === 'object') {\n\t\t\t\tif (this.args[0].isImage) {\n\t\t\t\t\t// Argument was in wiki image syntax.\n\t\t\t\t\tvar $image = jQuery(document.createElement('img')).attr('src', this.args[0].source).appendTo($link);\n\n\t\t\t\t\tif (this.args[0].hasOwnProperty('passage')) {\n\t\t\t\t\t\t$image.attr('data-passage', this.args[0].passage);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (this.args[0].hasOwnProperty('title')) {\n\t\t\t\t\t\t$image.attr('title', this.args[0].title);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (this.args[0].hasOwnProperty('align')) {\n\t\t\t\t\t\t$image.attr('align', this.args[0].align);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (this.args[0].hasOwnProperty('link')) {\n\t\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t\t}\n\n\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t} else {\n\t\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\t\t$link.append(document.createTextNode(this.args[0].text));\n\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// Argument was simply the link text.\n\t\t\t\t$link.wikiWithOptions({ profile: 'core' }, this.args[0]);\n\t\t\t\tpassage = this.args.length > 1 ? this.args[1] : undefined;\n\t\t\t}\n\n\t\t\tif (passage != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\t$link.attr('data-passage', passage);\n\n\t\t\t\tif (Story.has(passage)) {\n\t\t\t\t\t$link.addClass('link-internal');\n\n\t\t\t\t\tif (Config.addVisitedLinkClass && State.hasPlayed(passage)) {\n\t\t\t\t\t\t$link.addClass('link-visited');\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t$link.addClass('link-broken');\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$link.addClass('link-internal');\n\t\t\t}\n\n\t\t\t$link.addClass('macro-' + this.name).ariaClick({\n\t\t\t\tnamespace: '.macros',\n\t\t\t\tone: passage != null // lazy equality for null\n\t\t\t}, this.createShadowWrapper(this.payload[0].contents !== '' ? function () {\n\t\t\t\treturn Wikifier.wikifyEval(_this12.payload[0].contents.trim());\n\t\t\t} : null, passage != null // lazy equality for null\n\t\t\t? function () {\n\t\t\t\treturn Engine.play(passage);\n\t\t\t} : null)).appendTo(this.output);\n\t\t}\n\t});\n\n\t/*\n \t<<checkbox>>\n */\n\tMacro.add('checkbox', {\n\t\tisAsync: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.length < 3) {\n\t\t\t\tvar errors = [];\n\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\terrors.push('variable name');\n\t\t\t\t}\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\terrors.push('unchecked value');\n\t\t\t\t}\n\t\t\t\tif (this.args.length < 3) {\n\t\t\t\t\terrors.push('checked value');\n\t\t\t\t}\n\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t}\n\n\t\t\t// Ensure that the variable name argument is a string.\n\t\t\tif (typeof this.args[0] !== 'string') {\n\t\t\t\treturn this.error('variable name argument is not a string');\n\t\t\t}\n\n\t\t\tvar varName = this.args[0].trim();\n\n\t\t\t// Try to ensure that we receive the variable's name (incl. sigil), not its value.\n\t\t\tif (varName[0] !== '$' && varName[0] !== '_') {\n\t\t\t\treturn this.error('variable name \"' + this.args[0] + '\" is missing its sigil ($ or _)');\n\t\t\t}\n\n\t\t\tvar varId = Util.slugify(varName);\n\t\t\tvar uncheckValue = this.args[1];\n\t\t\tvar checkValue = this.args[2];\n\t\t\tvar el = document.createElement('input');\n\n\t\t\t/*\n   \tSet up and append the input element to the output buffer.\n   */\n\t\t\tjQuery(el).attr({\n\t\t\t\tid: this.name + '-' + varId,\n\t\t\t\tname: this.name + '-' + varId,\n\t\t\t\ttype: 'checkbox',\n\t\t\t\ttabindex: 0 // for accessiblity\n\t\t\t}).addClass('macro-' + this.name).on('change.macros', this.createShadowWrapper(function () {\n\t\t\t\tState.setVar(varName, this.checked ? checkValue : uncheckValue);\n\t\t\t})).appendTo(this.output);\n\n\t\t\t/*\n   \tSet the variable and input element to the appropriate value and state, as requested.\n   */\n\t\t\tif (this.args.length > 3 && this.args[3] === 'checked') {\n\t\t\t\tel.checked = true;\n\t\t\t\tState.setVar(varName, checkValue);\n\t\t\t} else {\n\t\t\t\tState.setVar(varName, uncheckValue);\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<cycle>>, <<listbox>>, <<option>>, & <<optionsfrom>>\n */\n\tMacro.add(['cycle', 'listbox'], {\n\t\tisAsync: true,\n\t\tskipArgs: ['optionsfrom'],\n\t\ttags: ['option', 'optionsfrom'],\n\n\t\thandler: function handler() {\n\t\t\tvar _this13 = this;\n\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no variable name specified');\n\t\t\t}\n\n\t\t\t// Ensure that the variable name argument is a string.\n\t\t\tif (typeof this.args[0] !== 'string') {\n\t\t\t\treturn this.error('variable name argument is not a string');\n\t\t\t}\n\n\t\t\tvar varName = this.args[0].trim();\n\n\t\t\t// Try to ensure that we receive the variable's name (incl. sigil), not its value.\n\t\t\tif (varName[0] !== '$' && varName[0] !== '_') {\n\t\t\t\treturn this.error('variable name \"' + this.args[0] + '\" is missing its sigil ($ or _)');\n\t\t\t}\n\n\t\t\tvar varId = Util.slugify(varName);\n\t\t\tvar len = this.payload.length;\n\n\t\t\tif (len === 1) {\n\t\t\t\treturn this.error('no options specified');\n\t\t\t}\n\n\t\t\tvar autoselect = this.args.length > 1 && this.args[1] === 'autoselect';\n\t\t\tvar options = [];\n\t\t\tvar tagCount = { option: 0, optionsfrom: 0 };\n\t\t\tvar selectedIdx = -1;\n\n\t\t\t// Get the options and selected index, if any.\n\t\t\tfor (var i = 1; i < len; ++i) {\n\t\t\t\tvar payload = this.payload[i];\n\n\t\t\t\t// <<option label value [selected]>>\n\t\t\t\tif (payload.name === 'option') {\n\t\t\t\t\t++tagCount.option;\n\n\t\t\t\t\tif (payload.args.length === 0) {\n\t\t\t\t\t\treturn this.error('no arguments specified for <<' + payload.name + '>> (#' + tagCount.option + ')');\n\t\t\t\t\t}\n\n\t\t\t\t\toptions.push({\n\t\t\t\t\t\tlabel: String(payload.args[0]),\n\t\t\t\t\t\tvalue: payload.args.length === 1 ? payload.args[0] : payload.args[1]\n\t\t\t\t\t});\n\n\t\t\t\t\tif (payload.args.length > 2 && payload.args[2] === 'selected') {\n\t\t\t\t\t\tif (autoselect) {\n\t\t\t\t\t\t\treturn this.error('cannot specify both the autoselect and selected keywords');\n\t\t\t\t\t\t} else if (selectedIdx !== -1) {\n\t\t\t\t\t\t\treturn this.error('multiple selected keywords specified for <<' + payload.name + '>> (#' + (selectedIdx + 1) + ' & #' + tagCount.option + ')');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tselectedIdx = options.length - 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// <<optionsfrom expression>>\n\t\t\t\telse {\n\t\t\t\t\t\tvar _ret3 = function () {\n\t\t\t\t\t\t\t++tagCount.optionsfrom;\n\n\t\t\t\t\t\t\tif (payload.args.full.length === 0) {\n\t\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\t\tv: _this13.error('no expression specified for <<' + payload.name + '>> (#' + tagCount.optionsfrom + ')')\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tvar result = void 0;\n\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t/*\n        \tNOTE: If the first character is the left curly brace, then we\n        \tassume that it's part of an object literal and wrap it within\n        \tparenthesis to ensure that it is not mistaken for a block\n        \tduring evaluation—which would cause an error.\n        */\n\t\t\t\t\t\t\t\tvar exp = payload.args.full;\n\t\t\t\t\t\t\t\tresult = Scripting.evalJavaScript(exp[0] === '{' ? '(' + exp + ')' : exp);\n\t\t\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\t\tv: _this13.error('bad evaluation: ' + ((typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex))\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif ((typeof result === 'undefined' ? 'undefined' : _typeof(result)) !== 'object' || result === null) {\n\t\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\t\tv: _this13.error('expression must yield a supported collection or generic object (type: ' + (result === null ? 'null' : typeof result === 'undefined' ? 'undefined' : _typeof(result)) + ')')\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (result instanceof Array || result instanceof Set) {\n\t\t\t\t\t\t\t\tresult.forEach(function (val) {\n\t\t\t\t\t\t\t\t\treturn options.push({ label: String(val), value: val });\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} else if (result instanceof Map) {\n\t\t\t\t\t\t\t\tresult.forEach(function (val, key) {\n\t\t\t\t\t\t\t\t\treturn options.push({ label: String(key), value: val });\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tvar oType = Util.toStringTag(result);\n\n\t\t\t\t\t\t\t\tif (oType !== 'Object') {\n\t\t\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\t\t\tv: _this13.error('expression must yield a supported collection or generic object (object type: ' + oType + ')')\n\t\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tObject.keys(result).forEach(function (key) {\n\t\t\t\t\t\t\t\t\treturn options.push({ label: key, value: result[key] });\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}();\n\n\t\t\t\t\t\tif ((typeof _ret3 === 'undefined' ? 'undefined' : _typeof(_ret3)) === \"object\") return _ret3.v;\n\t\t\t\t\t}\n\t\t\t}\n\n\t\t\t// No options were selected by the user, so we must select one.\n\t\t\tif (selectedIdx === -1) {\n\t\t\t\t// Attempt to automatically select an option by matching the variable's current value.\n\t\t\t\tif (autoselect) {\n\t\t\t\t\t// NOTE: This will usually fail for objects due to a variety of reasons.\n\t\t\t\t\tvar sameValueZero = Util.sameValueZero;\n\t\t\t\t\tvar curValue = State.getVar(varName);\n\t\t\t\t\tvar curValueIdx = options.findIndex(function (opt) {\n\t\t\t\t\t\treturn sameValueZero(opt.value, curValue);\n\t\t\t\t\t});\n\t\t\t\t\tselectedIdx = curValueIdx === -1 ? 0 : curValueIdx;\n\t\t\t\t}\n\n\t\t\t\t// Simply select the first option.\n\t\t\t\telse {\n\t\t\t\t\t\tselectedIdx = 0;\n\t\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Set up and append the appropriate element to the output buffer.\n\t\t\tif (this.name === 'cycle') {\n\t\t\t\tvar cycleIdx = selectedIdx;\n\t\t\t\tjQuery(document.createElement('a')).wikiWithOptions({ profile: 'core' }, options[selectedIdx].label).addClass('macro-' + this.name).ariaClick({ namespace: '.macros' }, this.createShadowWrapper(function () {\n\t\t\t\t\tcycleIdx = (cycleIdx + 1) % options.length;\n\t\t\t\t\t$(this).empty().wikiWithOptions({ profile: 'core' }, options[cycleIdx].label);\n\t\t\t\t\tState.setVar(varName, options[cycleIdx].value);\n\t\t\t\t})).appendTo(this.output);\n\t\t\t} else {\n\t\t\t\t// this.name === 'listbox'\n\t\t\t\tvar $select = jQuery(document.createElement('select'));\n\n\t\t\t\toptions.forEach(function (opt, i) {\n\t\t\t\t\tjQuery(document.createElement('option')).val(i).text(opt.label).appendTo($select);\n\t\t\t\t});\n\n\t\t\t\t$select.attr({\n\t\t\t\t\tid: this.name + '-' + varId,\n\t\t\t\t\tname: this.name + '-' + varId,\n\t\t\t\t\ttabindex: 0 // for accessiblity\n\t\t\t\t}).addClass('macro-' + this.name).val(selectedIdx).on('change.macros', this.createShadowWrapper(function () {\n\t\t\t\t\tState.setVar(varName, options[Number(this.value)].value);\n\t\t\t\t})).appendTo(this.output);\n\t\t\t}\n\n\t\t\t// Set the variable to the appropriate value, as requested.\n\t\t\tState.setVar(varName, options[selectedIdx].value);\n\t\t}\n\t});\n\n\t/*\n \t<<linkappend>>, <<linkprepend>>, & <<linkreplace>>\n */\n\tMacro.add(['linkappend', 'linkprepend', 'linkreplace'], {\n\t\tisAsync: true,\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tvar _this14 = this;\n\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no link text specified');\n\t\t\t}\n\n\t\t\tvar $link = jQuery(document.createElement('a'));\n\t\t\tvar $insert = jQuery(document.createElement('span'));\n\t\t\tvar transition = this.args.length > 1 && /^(?:transition|t8n)$/.test(this.args[1]);\n\n\t\t\t$link.wikiWithOptions({ profile: 'core' }, this.args[0]).addClass('link-internal macro-' + this.name).ariaClick({\n\t\t\t\tnamespace: '.macros',\n\t\t\t\tone: true\n\t\t\t}, this.createShadowWrapper(function () {\n\t\t\t\tif (_this14.name === 'linkreplace') {\n\t\t\t\t\t$link.remove();\n\t\t\t\t} else {\n\t\t\t\t\t$link.wrap('<span class=\"macro-' + _this14.name + '\"></span>').replaceWith(function () {\n\t\t\t\t\t\treturn $link.html();\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tif (_this14.payload[0].contents !== '') {\n\t\t\t\t\tvar frag = document.createDocumentFragment();\n\t\t\t\t\tnew Wikifier(frag, _this14.payload[0].contents);\n\t\t\t\t\t$insert.append(frag);\n\t\t\t\t}\n\n\t\t\t\tif (transition) {\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\treturn $insert.removeClass('macro-' + _this14.name + '-in');\n\t\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t\t}\n\t\t\t})).appendTo(this.output);\n\n\t\t\t$insert.addClass('macro-' + this.name + '-insert');\n\n\t\t\tif (transition) {\n\t\t\t\t$insert.addClass('macro-' + this.name + '-in');\n\t\t\t}\n\n\t\t\tif (this.name === 'linkprepend') {\n\t\t\t\t$insert.insertBefore($link);\n\t\t\t} else {\n\t\t\t\t$insert.insertAfter($link);\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<radiobutton>>\n */\n\tMacro.add('radiobutton', {\n\t\tisAsync: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.length < 2) {\n\t\t\t\tvar errors = [];\n\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\terrors.push('variable name');\n\t\t\t\t}\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\terrors.push('checked value');\n\t\t\t\t}\n\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t}\n\n\t\t\t// Ensure that the variable name argument is a string.\n\t\t\tif (typeof this.args[0] !== 'string') {\n\t\t\t\treturn this.error('variable name argument is not a string');\n\t\t\t}\n\n\t\t\tvar varName = this.args[0].trim();\n\n\t\t\t// Try to ensure that we receive the variable's name (incl. sigil), not its value.\n\t\t\tif (varName[0] !== '$' && varName[0] !== '_') {\n\t\t\t\treturn this.error('variable name \"' + this.args[0] + '\" is missing its sigil ($ or _)');\n\t\t\t}\n\n\t\t\tvar varId = Util.slugify(varName);\n\t\t\tvar checkValue = this.args[1];\n\t\t\tvar el = document.createElement('input');\n\n\t\t\t/*\n   \tSet up and initialize the group counter.\n   */\n\t\t\tif (!TempState.hasOwnProperty(this.name)) {\n\t\t\t\tTempState[this.name] = {};\n\t\t\t}\n\n\t\t\tif (!TempState[this.name].hasOwnProperty(varId)) {\n\t\t\t\tTempState[this.name][varId] = 0;\n\t\t\t}\n\n\t\t\t/*\n   \tSet up and append the input element to the output buffer.\n   */\n\t\t\tjQuery(el).attr({\n\t\t\t\tid: this.name + '-' + varId + '-' + TempState[this.name][varId]++,\n\t\t\t\tname: this.name + '-' + varId,\n\t\t\t\ttype: 'radio',\n\t\t\t\ttabindex: 0 // for accessiblity\n\t\t\t}).addClass('macro-' + this.name).on('change.macros', this.createShadowWrapper(function () {\n\t\t\t\tif (this.checked) {\n\t\t\t\t\tState.setVar(varName, checkValue);\n\t\t\t\t}\n\t\t\t})).appendTo(this.output);\n\n\t\t\t/*\n   \tSet the variable to the checked value and the input element to checked, if requested.\n   */\n\t\t\tif (this.args.length > 2 && this.args[2] === 'checked') {\n\t\t\t\tel.checked = true;\n\t\t\t\tState.setVar(varName, checkValue);\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<textarea>>\n */\n\tMacro.add('textarea', {\n\t\tisAsync: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.length < 2) {\n\t\t\t\tvar errors = [];\n\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\terrors.push('variable name');\n\t\t\t\t}\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\terrors.push('default value');\n\t\t\t\t}\n\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t}\n\n\t\t\t// Ensure that the variable name argument is a string.\n\t\t\tif (typeof this.args[0] !== 'string') {\n\t\t\t\treturn this.error('variable name argument is not a string');\n\t\t\t}\n\n\t\t\tvar varName = this.args[0].trim();\n\n\t\t\t// Try to ensure that we receive the variable's name (incl. sigil), not its value.\n\t\t\tif (varName[0] !== '$' && varName[0] !== '_') {\n\t\t\t\treturn this.error('variable name \"' + this.args[0] + '\" is missing its sigil ($ or _)');\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\tvar varId = Util.slugify(varName);\n\t\t\tvar defaultValue = this.args[1];\n\t\t\tvar autofocus = this.args[2] === 'autofocus';\n\t\t\tvar el = document.createElement('textarea');\n\n\t\t\t/*\n   \tSet up and append the textarea element to the output buffer.\n   */\n\t\t\tjQuery(el).attr({\n\t\t\t\tid: this.name + '-' + varId,\n\t\t\t\tname: this.name + '-' + varId,\n\t\t\t\trows: 4,\n\t\t\t\t// cols     : 68, // instead of setting \"cols\" we set the `min-width` in CSS\n\t\t\t\ttabindex: 0 // for accessiblity\n\t\t\t}).addClass('macro-' + this.name).on('change.macros', this.createShadowWrapper(function () {\n\t\t\t\tState.setVar(varName, this.value);\n\t\t\t})).appendTo(this.output);\n\n\t\t\t/*\n   \tSet the variable and textarea element to the default value.\n   */\n\t\t\tState.setVar(varName, defaultValue);\n\t\t\t// Ideally, we should be setting `.defaultValue` here, but IE doesn't support it,\n\t\t\t// so we have to use `.textContent`, which is equivalent.\n\t\t\tel.textContent = defaultValue;\n\n\t\t\t/*\n   \tAutofocus the textarea element, if requested.\n   */\n\t\t\tif (autofocus) {\n\t\t\t\t// Set the element's \"autofocus\" attribute.\n\t\t\t\tel.setAttribute('autofocus', 'autofocus');\n\n\t\t\t\t// Set up a single-use post-display task to autofocus the element.\n\t\t\t\tpostdisplay['#autofocus:' + el.id] = function (task) {\n\t\t\t\t\tdelete postdisplay[task]; // single-use task\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\treturn el.focus();\n\t\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<textbox>>\n */\n\tMacro.add('textbox', {\n\t\tisAsync: true,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.length < 2) {\n\t\t\t\tvar errors = [];\n\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\terrors.push('variable name');\n\t\t\t\t}\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\terrors.push('default value');\n\t\t\t\t}\n\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t}\n\n\t\t\t// Ensure that the variable name argument is a string.\n\t\t\tif (typeof this.args[0] !== 'string') {\n\t\t\t\treturn this.error('variable name argument is not a string');\n\t\t\t}\n\n\t\t\tvar varName = this.args[0].trim();\n\n\t\t\t// Try to ensure that we receive the variable's name (incl. sigil), not its value.\n\t\t\tif (varName[0] !== '$' && varName[0] !== '_') {\n\t\t\t\treturn this.error('variable name \"' + this.args[0] + '\" is missing its sigil ($ or _)');\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\tvar varId = Util.slugify(varName);\n\t\t\tvar defaultValue = this.args[1];\n\t\t\tvar el = document.createElement('input');\n\t\t\tvar autofocus = false;\n\t\t\tvar passage = void 0;\n\n\t\t\tif (this.args.length > 3) {\n\t\t\t\tpassage = this.args[2];\n\t\t\t\tautofocus = this.args[3] === 'autofocus';\n\t\t\t} else if (this.args.length > 2) {\n\t\t\t\tif (this.args[2] === 'autofocus') {\n\t\t\t\t\tautofocus = true;\n\t\t\t\t} else {\n\t\t\t\t\tpassage = this.args[2];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ((typeof passage === 'undefined' ? 'undefined' : _typeof(passage)) === 'object') {\n\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\tpassage = passage.link;\n\t\t\t}\n\n\t\t\t/*\n   \tSet up and append the input element to the output buffer.\n   */\n\t\t\tjQuery(el).attr({\n\t\t\t\tid: this.name + '-' + varId,\n\t\t\t\tname: this.name + '-' + varId,\n\t\t\t\ttype: 'text',\n\t\t\t\ttabindex: 0 // for accessiblity\n\t\t\t}).addClass('macro-' + this.name).on('change.macros', this.createShadowWrapper(function () {\n\t\t\t\tState.setVar(varName, this.value);\n\t\t\t})).on('keypress.macros', this.createShadowWrapper(function (ev) {\n\t\t\t\t// If Return/Enter is pressed, set the variable and, optionally, forward to another passage.\n\t\t\t\tif (ev.which === 13) {\n\t\t\t\t\t// 13 is Return/Enter\n\t\t\t\t\tev.preventDefault();\n\t\t\t\t\tState.setVar(varName, this.value);\n\n\t\t\t\t\tif (passage != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tEngine.play(passage);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})).appendTo(this.output);\n\n\t\t\t/*\n   \tSet the variable and input element to the default value.\n   */\n\t\t\tState.setVar(varName, defaultValue);\n\t\t\tel.value = defaultValue;\n\n\t\t\t/*\n   \tAutofocus the input element, if requested.\n   */\n\t\t\tif (autofocus) {\n\t\t\t\t// Set the element's \"autofocus\" attribute.\n\t\t\t\tel.setAttribute('autofocus', 'autofocus');\n\n\t\t\t\t// Set up a single-use post-display task to autofocus the element.\n\t\t\t\tpostdisplay['#autofocus:' + el.id] = function (task) {\n\t\t\t\t\tdelete postdisplay[task]; // single-use task\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\treturn el.focus();\n\t\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t[DEPRECATED] <<click>>\n */\n\tMacro.add('click', 'link'); // add <<click>> as an alias of <<link>>\n\n\n\t/*******************************************************************************************************************\n \tLinks Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<actions>>\n */\n\tMacro.add('actions', {\n\t\thandler: function handler() {\n\t\t\tvar $list = jQuery(document.createElement('ul')).addClass(this.name).appendTo(this.output);\n\n\t\t\tfor (var i = 0; i < this.args.length; ++i) {\n\t\t\t\tvar passage = void 0;\n\t\t\t\tvar text = void 0;\n\t\t\t\tvar $image = void 0;\n\t\t\t\tvar setFn = void 0;\n\n\t\t\t\tif (_typeof(this.args[i]) === 'object') {\n\t\t\t\t\tif (this.args[i].isImage) {\n\t\t\t\t\t\t// Argument was in wiki image syntax.\n\t\t\t\t\t\t$image = jQuery(document.createElement('img')).attr('src', this.args[i].source);\n\n\t\t\t\t\t\tif (this.args[i].hasOwnProperty('passage')) {\n\t\t\t\t\t\t\t$image.attr('data-passage', this.args[i].passage);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[i].hasOwnProperty('title')) {\n\t\t\t\t\t\t\t$image.attr('title', this.args[i].title);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[i].hasOwnProperty('align')) {\n\t\t\t\t\t\t\t$image.attr('align', this.args[i].align);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tpassage = this.args[i].link;\n\t\t\t\t\t\tsetFn = this.args[i].setFn;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\t\t\ttext = this.args[i].text;\n\t\t\t\t\t\tpassage = this.args[i].link;\n\t\t\t\t\t\tsetFn = this.args[i].setFn;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t// Argument was simply the passage name.\n\t\t\t\t\ttext = passage = this.args[i];\n\t\t\t\t}\n\n\t\t\t\tif (State.variables.hasOwnProperty('#actions') && State.variables['#actions'].hasOwnProperty(passage) && State.variables['#actions'][passage]) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tjQuery(Wikifier.createInternalLink(jQuery(document.createElement('li')).appendTo($list), passage, null, function (passage, fn) {\n\t\t\t\t\treturn function () {\n\t\t\t\t\t\tif (!State.variables.hasOwnProperty('#actions')) {\n\t\t\t\t\t\t\tState.variables['#actions'] = {};\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tState.variables['#actions'][passage] = true;\n\n\t\t\t\t\t\tif (typeof fn === 'function') {\n\t\t\t\t\t\t\tfn();\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t}(passage, setFn))).addClass('macro-' + this.name).append($image || document.createTextNode(text));\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<back>> & <<return>>\n */\n\tMacro.add(['back', 'return'], {\n\t\thandler: function handler() {\n\t\t\t/* legacy */\n\t\t\tif (this.args.length > 1) {\n\t\t\t\treturn this.error('too many arguments specified, check the documentation for details');\n\t\t\t}\n\t\t\t/* /legacy */\n\n\t\t\tvar momentIndex = -1;\n\t\t\tvar passage = void 0;\n\t\t\tvar text = void 0;\n\t\t\tvar $image = void 0;\n\n\t\t\tif (this.args.length === 1) {\n\t\t\t\tif (_typeof(this.args[0]) === 'object') {\n\t\t\t\t\tif (this.args[0].isImage) {\n\t\t\t\t\t\t// Argument was in wiki image syntax.\n\t\t\t\t\t\t$image = jQuery(document.createElement('img')).attr('src', this.args[0].source);\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('passage')) {\n\t\t\t\t\t\t\t$image.attr('data-passage', this.args[0].passage);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('title')) {\n\t\t\t\t\t\t\t$image.attr('title', this.args[0].title);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('align')) {\n\t\t\t\t\t\t\t$image.attr('align', this.args[0].align);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('link')) {\n\t\t\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\t\t\tif (this.args[0].count === 1) {\n\t\t\t\t\t\t\t// Simple link syntax: `[[...]]`.\n\t\t\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// Pretty link syntax: `[[...|...]]`.\n\t\t\t\t\t\t\ttext = this.args[0].text;\n\t\t\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else if (this.args.length === 1) {\n\t\t\t\t\t// Argument was simply the link text.\n\t\t\t\t\ttext = this.args[0];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (passage == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\t/*\n    \tFind the index and title of the most recent moment whose title does not match\n    \tthat of the active (present) moment's.\n    */\n\t\t\t\tfor (var i = State.length - 2; i >= 0; --i) {\n\t\t\t\t\tif (State.history[i].title !== State.passage) {\n\t\t\t\t\t\tmomentIndex = i;\n\t\t\t\t\t\tpassage = State.history[i].title;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// If we failed to find a passage and we're `<<return>>`, fallback to `State.expired`.\n\t\t\t\tif (passage == null && this.name === 'return') {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tfor (var _i5 = State.expired.length - 1; _i5 >= 0; --_i5) {\n\t\t\t\t\t\tif (State.expired[_i5] !== State.passage) {\n\t\t\t\t\t\t\tpassage = State.expired[_i5];\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif (!Story.has(passage)) {\n\t\t\t\t\treturn this.error('passage \"' + passage + '\" does not exist');\n\t\t\t\t}\n\n\t\t\t\tif (this.name === 'back') {\n\t\t\t\t\t/*\n     \tFind the index of the most recent moment whose title matches that of the\n     \tspecified passage.\n     */\n\t\t\t\t\tfor (var _i6 = State.length - 2; _i6 >= 0; --_i6) {\n\t\t\t\t\t\tif (State.history[_i6].title === passage) {\n\t\t\t\t\t\t\tmomentIndex = _i6;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (momentIndex === -1) {\n\t\t\t\t\t\treturn this.error('cannot find passage \"' + passage + '\" in the current story history');\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (passage == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\treturn this.error('cannot find passage');\n\t\t\t}\n\n\t\t\t// if (this.name === \"back\" && momentIndex === -1) {\n\t\t\t// \t// no-op; we're already at the first passage in the current story history\n\t\t\t// \treturn;\n\t\t\t// }\n\n\t\t\tvar $el = void 0;\n\n\t\t\tif (this.name !== 'back' || momentIndex !== -1) {\n\t\t\t\t$el = jQuery(document.createElement('a')).addClass('link-internal').ariaClick({ one: true }, this.name === 'return' ? function () {\n\t\t\t\t\treturn Engine.play(passage);\n\t\t\t\t} : function () {\n\t\t\t\t\treturn Engine.goTo(momentIndex);\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\t$el = jQuery(document.createElement('span')).addClass('link-disabled');\n\t\t\t}\n\n\t\t\t$el.addClass('macro-' + this.name).append($image || document.createTextNode(text || L10n.get('macro' + this.name.toUpperFirst() + 'Text'))).appendTo(this.output);\n\t\t}\n\t});\n\n\t/*\n \t<<choice>>\n */\n\tMacro.add('choice', {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no passage specified');\n\t\t\t}\n\n\t\t\tvar choiceId = State.passage;\n\t\t\tvar passage = void 0;\n\t\t\tvar text = void 0;\n\t\t\tvar $image = void 0;\n\t\t\tvar setFn = void 0;\n\n\t\t\tif (this.args.length === 1) {\n\t\t\t\tif (_typeof(this.args[0]) === 'object') {\n\t\t\t\t\tif (this.args[0].isImage) {\n\t\t\t\t\t\t// Argument was in wiki image syntax.\n\t\t\t\t\t\t$image = jQuery(document.createElement('img')).attr('src', this.args[0].source);\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('passage')) {\n\t\t\t\t\t\t\t$image.attr('data-passage', this.args[0].passage);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('title')) {\n\t\t\t\t\t\t\t$image.attr('title', this.args[0].title);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.args[0].hasOwnProperty('align')) {\n\t\t\t\t\t\t\t$image.attr('align', this.args[0].align);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t\t\tsetFn = this.args[0].setFn;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\t\t\ttext = this.args[0].text;\n\t\t\t\t\t\tpassage = this.args[0].link;\n\t\t\t\t\t\tsetFn = this.args[0].setFn;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t// Argument was simply the passage name.\n\t\t\t\t\ttext = passage = this.args[0];\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// NOTE: The arguments here are backwards.\n\t\t\t\tpassage = this.args[0];\n\t\t\t\ttext = this.args[1];\n\t\t\t}\n\n\t\t\tif (State.variables.hasOwnProperty('#choice') && State.variables['#choice'].hasOwnProperty(choiceId) && State.variables['#choice'][choiceId]) {\n\t\t\t\tjQuery(document.createElement('span')).addClass('link-disabled macro-' + this.name).attr('tabindex', -1).append($image || document.createTextNode(text)).appendTo(this.output);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tjQuery(Wikifier.createInternalLink(this.output, passage, null, function () {\n\t\t\t\tif (!State.variables.hasOwnProperty('#choice')) {\n\t\t\t\t\tState.variables['#choice'] = {};\n\t\t\t\t}\n\n\t\t\t\tState.variables['#choice'][choiceId] = true;\n\n\t\t\t\tif (typeof setFn === 'function') {\n\t\t\t\t\tsetFn();\n\t\t\t\t}\n\t\t\t})).addClass('macro-' + this.name).append($image || document.createTextNode(text));\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tDOM Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<addclass>> & <<toggleclass>>\n */\n\tMacro.add(['addclass', 'toggleclass'], {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length < 2) {\n\t\t\t\tvar errors = [];\n\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\terrors.push('selector');\n\t\t\t\t}\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\terrors.push('class names');\n\t\t\t\t}\n\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t}\n\n\t\t\tvar $targets = jQuery(this.args[0]);\n\n\t\t\tif ($targets.length === 0) {\n\t\t\t\treturn this.error('no elements matched the selector \"' + this.args[0] + '\"');\n\t\t\t}\n\n\t\t\tswitch (this.name) {\n\t\t\t\tcase 'addclass':\n\t\t\t\t\t$targets.addClass(this.args[1].trim());\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'toggleclass':\n\t\t\t\t\t$targets.toggleClass(this.args[1].trim());\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<removeclass>>\n */\n\tMacro.add('removeclass', {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no selector specified');\n\t\t\t}\n\n\t\t\tvar $targets = jQuery(this.args[0]);\n\n\t\t\tif ($targets.length === 0) {\n\t\t\t\treturn this.error('no elements matched the selector \"' + this.args[0] + '\"');\n\t\t\t}\n\n\t\t\tif (this.args.length > 1) {\n\t\t\t\t$targets.removeClass(this.args[1].trim());\n\t\t\t} else {\n\t\t\t\t$targets.removeClass();\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<copy>>\n */\n\tMacro.add('copy', {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no selector specified');\n\t\t\t}\n\n\t\t\tvar $targets = jQuery(this.args[0]);\n\n\t\t\tif ($targets.length === 0) {\n\t\t\t\treturn this.error('no elements matched the selector \"' + this.args[0] + '\"');\n\t\t\t}\n\n\t\t\tjQuery(this.output).append($targets.html());\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<append>>, <<prepend>>, & <<replace>>\n */\n\tMacro.add(['append', 'prepend', 'replace'], {\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tvar _this15 = this;\n\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no selector specified');\n\t\t\t}\n\n\t\t\tvar $targets = jQuery(this.args[0]);\n\n\t\t\tif ($targets.length === 0) {\n\t\t\t\treturn this.error('no elements matched the selector \"' + this.args[0] + '\"');\n\t\t\t}\n\n\t\t\tif (this.payload[0].contents !== '') {\n\t\t\t\tvar transition = this.args.length > 1 && /^(?:transition|t8n)$/.test(this.args[1]);\n\t\t\t\tvar $insert = void 0;\n\n\t\t\t\tif (transition) {\n\t\t\t\t\t$insert = jQuery(document.createElement('span'));\n\t\t\t\t\t$insert.addClass('macro-' + this.name + '-insert macro-' + this.name + '-in');\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\treturn $insert.removeClass('macro-' + _this15.name + '-in');\n\t\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t\t} else {\n\t\t\t\t\t$insert = jQuery(document.createDocumentFragment());\n\t\t\t\t}\n\n\t\t\t\t$insert.wiki(this.payload[0].contents);\n\n\t\t\t\tswitch (this.name) {\n\t\t\t\t\tcase 'replace':\n\t\t\t\t\t\t$targets.empty();\n\t\t\t\t\t/* falls through */\n\n\t\t\t\t\tcase 'append':\n\t\t\t\t\t\t$targets.append($insert);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'prepend':\n\t\t\t\t\t\t$targets.prepend($insert);\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t} else if (this.name === 'replace') {\n\t\t\t\t$targets.empty();\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<remove>>\n */\n\tMacro.add('remove', {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no selector specified');\n\t\t\t}\n\n\t\t\tvar $targets = jQuery(this.args[0]);\n\n\t\t\tif ($targets.length === 0) {\n\t\t\t\treturn this.error('no elements matched the selector \"' + this.args[0] + '\"');\n\t\t\t}\n\n\t\t\t$targets.remove();\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*******************************************************************************************************************\n \tAudio Macros.\n *******************************************************************************************************************/\n\tif (Has.audio) {\n\t\tvar errorOnePlaybackAction = function errorOnePlaybackAction(cur, prev) {\n\t\t\treturn 'only one playback action allowed per invocation, \"' + cur + '\" cannot be combined with \"' + prev + '\"';\n\t\t};\n\n\t\t/*\n  \t<<audio>>\n  */\n\t\tMacro.add('audio', {\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\tvar errors = [];\n\t\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\t\terrors.push('track and/or group IDs');\n\t\t\t\t\t}\n\t\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\t\terrors.push('actions');\n\t\t\t\t\t}\n\t\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t\t}\n\n\t\t\t\tvar selected = void 0;\n\n\t\t\t\t// Process the track and/or group IDs.\n\t\t\t\ttry {\n\t\t\t\t\tselected = SimpleAudio.select(this.args[0]);\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error(ex.message);\n\t\t\t\t}\n\n\t\t\t\tvar args = this.args.slice(1);\n\t\t\t\tvar action = void 0;\n\t\t\t\tvar fadeOver = 5;\n\t\t\t\tvar fadeTo = void 0;\n\t\t\t\tvar loop = void 0;\n\t\t\t\tvar mute = void 0;\n\t\t\t\tvar passage = void 0;\n\t\t\t\tvar time = void 0;\n\t\t\t\tvar volume = void 0;\n\n\t\t\t\t// Process arguments.\n\t\t\t\twhile (args.length > 0) {\n\t\t\t\t\tvar arg = args.shift();\n\t\t\t\t\tvar raw = void 0;\n\n\t\t\t\t\tswitch (arg) {\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\tcase 'pause':\n\t\t\t\t\t\tcase 'play':\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = arg;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadein':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\tfadeTo = 1;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadeout':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\tfadeTo = 0;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadeto':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('fadeto missing required level value');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tfadeTo = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(fadeTo) || !Number.isFinite(fadeTo)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse fadeto: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadeoverto':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (args.length < 2) {\n\t\t\t\t\t\t\t\tvar _errors = [];\n\t\t\t\t\t\t\t\tif (args.length < 1) {\n\t\t\t\t\t\t\t\t\t_errors.push('seconds');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (args.length < 2) {\n\t\t\t\t\t\t\t\t\t_errors.push('level');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\treturn this.error('fadeoverto missing required ' + _errors.join(' and ') + ' value' + (_errors.length > 1 ? 's' : ''));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tfadeOver = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(fadeOver) || !Number.isFinite(fadeOver)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse fadeoverto: ' + raw);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tfadeTo = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(fadeTo) || !Number.isFinite(fadeTo)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse fadeoverto: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'volume':\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('volume missing required level value');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tvolume = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(volume) || !Number.isFinite(volume)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse volume: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'mute':\n\t\t\t\t\t\tcase 'unmute':\n\t\t\t\t\t\t\tmute = arg === 'mute';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'time':\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('time missing required seconds value');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\ttime = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(time) || !Number.isFinite(time)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse time: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'loop':\n\t\t\t\t\t\tcase 'unloop':\n\t\t\t\t\t\t\tloop = arg === 'loop';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'goto':\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('goto missing required passage title');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\n\t\t\t\t\t\t\tif ((typeof raw === 'undefined' ? 'undefined' : _typeof(raw)) === 'object') {\n\t\t\t\t\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\t\t\t\t\tpassage = raw.link;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t// Argument was simply the passage name.\n\t\t\t\t\t\t\t\tpassage = raw;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (!Story.has(passage)) {\n\t\t\t\t\t\t\t\treturn this.error('passage \"' + passage + '\" does not exist');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\treturn this.error('unknown action: ' + arg);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tif (volume != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tselected.volume(volume);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (time != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tselected.time(time);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (mute != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tselected.mute(mute);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (loop != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tselected.loop(loop);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (passage != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tvar nsEnded = 'ended.macros.macro-' + this.name + '_goto';\n\t\t\t\t\t\tselected.off(nsEnded).one(nsEnded, function () {\n\t\t\t\t\t\t\tselected.off(nsEnded);\n\t\t\t\t\t\t\tEngine.play(passage);\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch (action) {\n\t\t\t\t\t\tcase 'fade':\n\t\t\t\t\t\t\tselected.fade(fadeOver, fadeTo);\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\t\tselected.load();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'pause':\n\t\t\t\t\t\t\tselected.pause();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'play':\n\t\t\t\t\t\t\tselected.play();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\t\tselected.stop();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\tselected.unload();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Custom debug view setup.\n\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error('error executing action: ' + ex.message);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<cacheaudio track_id source_list>>\n  */\n\t\tMacro.add('cacheaudio', {\n\t\t\thandler: function handler() {\n\t\t\t\tvar _this16 = this;\n\n\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\tvar errors = [];\n\t\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\t\terrors.push('track ID');\n\t\t\t\t\t}\n\t\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\t\terrors.push('sources');\n\t\t\t\t\t}\n\t\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t\t}\n\n\t\t\t\tvar id = String(this.args[0]).trim();\n\t\t\t\tvar oldFmtRe = /^format:\\s*([\\w-]+)\\s*;\\s*/i;\n\n\t\t\t\ttry {\n\t\t\t\t\tSimpleAudio.tracks.add(id, this.args.slice(1).map(function (source) {\n\t\t\t\t\t\t/* legacy */\n\t\t\t\t\t\t// Transform an old format specifier into the new style.\n\t\t\t\t\t\tif (oldFmtRe.test(source)) {\n\t\t\t\t\t\t\t// If in Test Mode, return an error.\n\t\t\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\t\t\treturn _this16.error('track ID \"' + id + '\": format specifier migration required, \"format:formatId;\" \\u2192 \"formatId|\"');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tsource = source.replace(oldFmtRe, '$1|'); // eslint-disable-line no-param-reassign\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\treturn source;\n\t\t\t\t\t\t/* /legacy */\n\t\t\t\t\t}));\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error(ex.message);\n\t\t\t\t}\n\n\t\t\t\t// If in Test Mode and no supported sources were specified, return an error.\n\t\t\t\tif (Config.debug && !SimpleAudio.tracks.get(id).hasSource()) {\n\t\t\t\t\treturn this.error('track ID \"' + id + '\": no supported audio sources found');\n\t\t\t\t}\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<createaudiogroup group_id>>\n  \t\t<<track track_id>>\n  \t\t…\n  \t<</createaudiogroup>>\n  */\n\t\tMacro.add('createaudiogroup', {\n\t\t\ttags: ['track'],\n\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\treturn this.error('no group ID specified');\n\t\t\t\t}\n\n\t\t\t\tif (this.payload.length === 1) {\n\t\t\t\t\treturn this.error('no tracks defined via <<track>>');\n\t\t\t\t}\n\n\t\t\t\t// Initial debug view setup for `<<createaudiogroup>>`.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({\n\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\thidden: true\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tvar groupId = String(this.args[0]).trim();\n\t\t\t\tvar trackIds = [];\n\n\t\t\t\tfor (var i = 1, len = this.payload.length; i < len; ++i) {\n\t\t\t\t\tif (this.payload[i].args.length < 1) {\n\t\t\t\t\t\treturn this.error('no track ID specified');\n\t\t\t\t\t}\n\n\t\t\t\t\ttrackIds.push(String(this.payload[i].args[0]).trim());\n\n\t\t\t\t\t// Custom debug view setup for the current `<<track>>`.\n\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\tthis.createDebugView(this.payload[i].name, this.payload[i].source).modes({\n\t\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\t\thidden: true\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tSimpleAudio.groups.add(groupId, trackIds);\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error(ex.message);\n\t\t\t\t}\n\n\t\t\t\t// Custom fake debug view setup for `<</createaudiogroup>>`.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.createDebugView('/' + this.name, '<</' + this.name + '>>').modes({\n\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\thidden: true\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<createplaylist list_id>>\n  \t\t<<track track_id action_list>>\n  \t\t…\n  \t<</createplaylist>>\n  */\n\t\tMacro.add('createplaylist', {\n\t\t\ttags: ['track'],\n\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\treturn this.error('no list ID specified');\n\t\t\t\t}\n\n\t\t\t\tif (this.payload.length === 1) {\n\t\t\t\t\treturn this.error('no tracks defined via <<track>>');\n\t\t\t\t}\n\n\t\t\t\tvar playlist = Macro.get('playlist');\n\n\t\t\t\tif (playlist.from !== null && playlist.from !== 'createplaylist') {\n\t\t\t\t\treturn this.error('a playlist has already been defined with <<setplaylist>>');\n\t\t\t\t}\n\n\t\t\t\t// Initial debug view setup for `<<createplaylist>>`.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({\n\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\thidden: true\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tvar listId = String(this.args[0]).trim();\n\t\t\t\tvar trackObjs = [];\n\n\t\t\t\tfor (var i = 1, len = this.payload.length; i < len; ++i) {\n\t\t\t\t\tif (this.payload[i].args.length === 0) {\n\t\t\t\t\t\treturn this.error('no track ID specified');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar trackObj = { id: String(this.payload[i].args[0]).trim() };\n\t\t\t\t\tvar args = this.payload[i].args.slice(1);\n\n\t\t\t\t\t// Process arguments.\n\t\t\t\t\twhile (args.length > 0) {\n\t\t\t\t\t\tvar arg = args.shift();\n\t\t\t\t\t\tvar raw = void 0;\n\t\t\t\t\t\tvar parsed = void 0;\n\n\t\t\t\t\t\tswitch (arg) {\n\t\t\t\t\t\t\tcase 'copy': // [DEPRECATED]\n\t\t\t\t\t\t\tcase 'own':\n\t\t\t\t\t\t\t\ttrackObj.own = true;\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase 'rate':\n\t\t\t\t\t\t\t\t// if (args.length === 0) {\n\t\t\t\t\t\t\t\t// \treturn this.error('rate missing required speed value');\n\t\t\t\t\t\t\t\t// }\n\t\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\t\t// raw = args.shift();\n\t\t\t\t\t\t\t\t// parsed = Number.parseFloat(raw);\n\t\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\t\t// if (Number.isNaN(parsed) || !Number.isFinite(parsed)) {\n\t\t\t\t\t\t\t\t// \treturn this.error(`cannot parse rate: ${raw}`);\n\t\t\t\t\t\t\t\t// }\n\t\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\t\t// trackObj.rate = parsed;\n\t\t\t\t\t\t\t\tif (args.length > 0) {\n\t\t\t\t\t\t\t\t\targs.shift();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tcase 'volume':\n\t\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\t\treturn this.error('volume missing required level value');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\t\tparsed = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\t\tif (Number.isNaN(parsed) || !Number.isFinite(parsed)) {\n\t\t\t\t\t\t\t\t\treturn this.error('cannot parse volume: ' + raw);\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\ttrackObj.volume = parsed;\n\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\treturn this.error('unknown action: ' + arg);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\ttrackObjs.push(trackObj);\n\n\t\t\t\t\t// Custom debug view setup for the current `<<track>>`.\n\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\tthis.createDebugView(this.payload[i].name, this.payload[i].source).modes({\n\t\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\t\thidden: true\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tSimpleAudio.lists.add(listId, trackObjs);\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error(ex.message);\n\t\t\t\t}\n\n\t\t\t\t// Lock `<<playlist>>` into our syntax.\n\t\t\t\tif (playlist.from === null) {\n\t\t\t\t\tplaylist.from = 'createplaylist';\n\t\t\t\t}\n\n\t\t\t\t// Custom fake debug view setup for `<</createplaylist>>`.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.createDebugView('/' + this.name, '<</' + this.name + '>>').modes({\n\t\t\t\t\t\tnonvoid: false,\n\t\t\t\t\t\thidden: true\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<masteraudio action_list>>\n  */\n\t\tMacro.add('masteraudio', {\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\treturn this.error('no actions specified');\n\t\t\t\t}\n\n\t\t\t\tvar args = this.args.slice(0);\n\t\t\t\tvar action = void 0;\n\t\t\t\tvar mute = void 0;\n\t\t\t\tvar muteOnHide = void 0;\n\t\t\t\tvar volume = void 0;\n\n\t\t\t\t// Process arguments.\n\t\t\t\twhile (args.length > 0) {\n\t\t\t\t\tvar arg = args.shift();\n\t\t\t\t\tvar raw = void 0;\n\n\t\t\t\t\tswitch (arg) {\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = arg;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'mute':\n\t\t\t\t\t\tcase 'unmute':\n\t\t\t\t\t\t\tmute = arg === 'mute';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'muteonhide':\n\t\t\t\t\t\tcase 'nomuteonhide':\n\t\t\t\t\t\t\tmuteOnHide = arg === 'muteonhide';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'volume':\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('volume missing required level value');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tvolume = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(volume) || !Number.isFinite(volume)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse volume: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\treturn this.error('unknown action: ' + arg);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tif (mute != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tSimpleAudio.mute(mute);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (muteOnHide != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tSimpleAudio.muteOnHidden(muteOnHide);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (volume != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tSimpleAudio.volume(volume);\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch (action) {\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\t\tSimpleAudio.load();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\t\tSimpleAudio.stop();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\tSimpleAudio.unload();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Custom debug view setup.\n\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error('error executing action: ' + ex.message);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<playlist list_id action_list>>  ← <<createplaylist>> syntax\n  \t<<playlist action_list>>          ← <<setplaylist>> syntax\n  */\n\t\tMacro.add('playlist', {\n\t\t\tfrom: null,\n\n\t\t\thandler: function handler() {\n\t\t\t\tvar from = this.self.from;\n\n\t\t\t\tif (from === null) {\n\t\t\t\t\treturn this.error('no playlists have been created');\n\t\t\t\t}\n\n\t\t\t\tvar list = void 0;\n\t\t\t\tvar args = void 0;\n\n\t\t\t\tif (from === 'createplaylist') {\n\t\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\t\tvar errors = [];\n\t\t\t\t\t\tif (this.args.length < 1) {\n\t\t\t\t\t\t\terrors.push('list ID');\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (this.args.length < 2) {\n\t\t\t\t\t\t\terrors.push('actions');\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn this.error('no ' + errors.join(' or ') + ' specified');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar id = String(this.args[0]).trim();\n\n\t\t\t\t\tif (!SimpleAudio.lists.has(id)) {\n\t\t\t\t\t\treturn this.error('playlist \"' + id + '\" does not exist');\n\t\t\t\t\t}\n\n\t\t\t\t\tlist = SimpleAudio.lists.get(id);\n\t\t\t\t\targs = this.args.slice(1);\n\t\t\t\t} else {\n\t\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\t\treturn this.error('no actions specified');\n\t\t\t\t\t}\n\n\t\t\t\t\tlist = SimpleAudio.lists.get('setplaylist');\n\t\t\t\t\targs = this.args.slice(0);\n\t\t\t\t}\n\n\t\t\t\tvar action = void 0;\n\t\t\t\tvar fadeOver = 5;\n\t\t\t\tvar fadeTo = void 0;\n\t\t\t\tvar loop = void 0;\n\t\t\t\tvar mute = void 0;\n\t\t\t\tvar shuffle = void 0;\n\t\t\t\tvar volume = void 0;\n\n\t\t\t\t// Process arguments.\n\t\t\t\twhile (args.length > 0) {\n\t\t\t\t\tvar arg = args.shift();\n\t\t\t\t\tvar raw = void 0;\n\n\t\t\t\t\tswitch (arg) {\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\tcase 'pause':\n\t\t\t\t\t\tcase 'play':\n\t\t\t\t\t\tcase 'skip':\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = arg;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadein':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\tfadeTo = 1;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadeout':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\tfadeTo = 0;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadeto':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('fadeto missing required level value');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tfadeTo = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(fadeTo) || !Number.isFinite(fadeTo)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse fadeto: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'fadeoverto':\n\t\t\t\t\t\t\tif (action) {\n\t\t\t\t\t\t\t\treturn this.error(errorOnePlaybackAction(arg, action));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (args.length < 2) {\n\t\t\t\t\t\t\t\tvar _errors2 = [];\n\t\t\t\t\t\t\t\tif (args.length < 1) {\n\t\t\t\t\t\t\t\t\t_errors2.push('seconds');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (args.length < 2) {\n\t\t\t\t\t\t\t\t\t_errors2.push('level');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\treturn this.error('fadeoverto missing required ' + _errors2.join(' and ') + ' value' + (_errors2.length > 1 ? 's' : ''));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\taction = 'fade';\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tfadeOver = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(fadeOver) || !Number.isFinite(fadeOver)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse fadeoverto: ' + raw);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tfadeTo = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(fadeTo) || !Number.isFinite(fadeTo)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse fadeoverto: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'volume':\n\t\t\t\t\t\t\tif (args.length === 0) {\n\t\t\t\t\t\t\t\treturn this.error('volume missing required level value');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\traw = args.shift();\n\t\t\t\t\t\t\tvolume = Number.parseFloat(raw);\n\n\t\t\t\t\t\t\tif (Number.isNaN(volume) || !Number.isFinite(volume)) {\n\t\t\t\t\t\t\t\treturn this.error('cannot parse volume: ' + raw);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'mute':\n\t\t\t\t\t\tcase 'unmute':\n\t\t\t\t\t\t\tmute = arg === 'mute';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'loop':\n\t\t\t\t\t\tcase 'unloop':\n\t\t\t\t\t\t\tloop = arg === 'loop';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'shuffle':\n\t\t\t\t\t\tcase 'unshuffle':\n\t\t\t\t\t\t\tshuffle = arg === 'shuffle';\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\treturn this.error('unknown action: ' + arg);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tif (volume != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tlist.volume(volume);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (mute != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tlist.mute(mute);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (loop != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tlist.loop(loop);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (shuffle != null) {\n\t\t\t\t\t\t// lazy equality for null\n\t\t\t\t\t\tlist.shuffle(shuffle);\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch (action) {\n\t\t\t\t\t\tcase 'fade':\n\t\t\t\t\t\t\tlist.fade(fadeOver, fadeTo);\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'load':\n\t\t\t\t\t\t\tlist.load();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'pause':\n\t\t\t\t\t\t\tlist.pause();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'play':\n\t\t\t\t\t\t\tlist.play();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'skip':\n\t\t\t\t\t\t\tlist.skip();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'stop':\n\t\t\t\t\t\t\tlist.stop();\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'unload':\n\t\t\t\t\t\t\tlist.unload();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Custom debug view setup.\n\t\t\t\t\tif (Config.debug) {\n\t\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error('error executing action: ' + ex.message);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<removeaudiogroup group_id>>\n  */\n\t\tMacro.add('removeaudiogroup', {\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\treturn this.error('no group ID specified');\n\t\t\t\t}\n\n\t\t\t\tvar id = String(this.args[0]).trim();\n\n\t\t\t\tif (!SimpleAudio.groups.has(id)) {\n\t\t\t\t\treturn this.error('group \"' + id + '\" does not exist');\n\t\t\t\t}\n\n\t\t\t\tSimpleAudio.groups.delete(id);\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<removeplaylist list_id>>\n  */\n\t\tMacro.add('removeplaylist', {\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\treturn this.error('no list ID specified');\n\t\t\t\t}\n\n\t\t\t\tvar id = String(this.args[0]).trim();\n\n\t\t\t\tif (!SimpleAudio.lists.has(id)) {\n\t\t\t\t\treturn this.error('playlist \"' + id + '\" does not exist');\n\t\t\t\t}\n\n\t\t\t\tSimpleAudio.lists.delete(id);\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t<<waitforaudio>>\n  */\n\t\tMacro.add('waitforaudio', {\n\t\t\tskipArgs: true,\n\n\t\t\thandler: function handler() {\n\t\t\t\tSimpleAudio.loadWithScreen();\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t[DEPRECATED] <<setplaylist track_id_list>>\n  */\n\t\tMacro.add('setplaylist', {\n\t\t\thandler: function handler() {\n\t\t\t\tif (this.args.length === 0) {\n\t\t\t\t\treturn this.error('no track ID(s) specified');\n\t\t\t\t}\n\n\t\t\t\tvar playlist = Macro.get('playlist');\n\n\t\t\t\tif (playlist.from !== null && playlist.from !== 'setplaylist') {\n\t\t\t\t\treturn this.error('playlists have already been defined with <<createplaylist>>');\n\t\t\t\t}\n\n\t\t\t\t// Create the new playlist.\n\t\t\t\ttry {\n\t\t\t\t\tSimpleAudio.lists.add('setplaylist', this.args.slice(0));\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error(ex.message);\n\t\t\t\t}\n\n\t\t\t\t// Lock `<<playlist>>` into our syntax.\n\t\t\t\tif (playlist.from === null) {\n\t\t\t\t\tplaylist.from = 'setplaylist';\n\t\t\t\t}\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t/*\n  \t[DEPRECATED] <<stopallaudio>>\n  */\n\t\tMacro.add('stopallaudio', {\n\t\t\tskipArgs: true,\n\n\t\t\thandler: function handler() {\n\t\t\t\tSimpleAudio.select(':all').stop();\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t} else {\n\t\t/* The HTML5 <audio> API appears to be missing or disabled, set up no-op macros. */\n\t\tMacro.add(['audio', 'cacheaudio', 'createaudiogroup', 'createplaylist', 'masteraudio', 'playlist', 'removeaudiogroup', 'removeplaylist', 'waitforaudio',\n\n\t\t// Deprecated.\n\t\t'setplaylist', 'stopallaudio'], {\n\t\t\tskipArgs: true,\n\n\t\t\thandler: function handler() {\n\t\t\t\t/* no-op */\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}\n\n\t/*******************************************************************************************************************\n \tMiscellaneous Macros.\n *******************************************************************************************************************/\n\t/*\n \t<<goto>>\n */\n\tMacro.add('goto', {\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no passage specified');\n\t\t\t}\n\n\t\t\tvar passage = void 0;\n\n\t\t\tif (_typeof(this.args[0]) === 'object') {\n\t\t\t\t// Argument was in wiki link syntax.\n\t\t\t\tpassage = this.args[0].link;\n\t\t\t} else {\n\t\t\t\t// Argument was simply the passage name.\n\t\t\t\tpassage = this.args[0];\n\t\t\t}\n\n\t\t\tif (!Story.has(passage)) {\n\t\t\t\treturn this.error('passage \"' + passage + '\" does not exist');\n\t\t\t}\n\n\t\t\t/*\n   \tCall `Engine.play()` asynchronously.\n   \t\tNOTE: This does not terminate the current Wikifier call chain,\n   \tthough, ideally, it should.  Doing so would not be trivial, however,\n   \tand there's also the question of whether that behavior would be\n   \tunwanted by users, who are used to the current behavior from\n   \tsimilar macros and constructs.\n   */\n\t\t\tsetTimeout(function () {\n\t\t\t\treturn Engine.play(passage);\n\t\t\t}, Engine.minDomActionDelay);\n\t\t}\n\t});\n\n\t/*\n \t<<repeat>> & <<stop>>\n */\n\tMacro.add('repeat', {\n\t\tisAsync: true,\n\t\ttags: null,\n\t\ttimers: new Set(),\n\n\t\thandler: function handler() {\n\t\t\tvar _this17 = this;\n\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no time value specified');\n\t\t\t}\n\n\t\t\tvar delay = void 0;\n\n\t\t\ttry {\n\t\t\t\tdelay = Math.max(Engine.minDomActionDelay, Util.fromCssTime(this.args[0]));\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error(ex.message);\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\tvar transition = this.args.length > 1 && /^(?:transition|t8n)$/.test(this.args[1]);\n\t\t\tvar $wrapper = jQuery(document.createElement('span')).addClass('macro-' + this.name).appendTo(this.output);\n\n\t\t\t// Register the timer.\n\t\t\tthis.self.registerInterval(this.createShadowWrapper(function () {\n\t\t\t\tvar frag = document.createDocumentFragment();\n\t\t\t\tnew Wikifier(frag, _this17.payload[0].contents);\n\n\t\t\t\tvar $output = $wrapper;\n\n\t\t\t\tif (transition) {\n\t\t\t\t\t$output = jQuery(document.createElement('span')).addClass('macro-repeat-insert macro-repeat-in').appendTo($output);\n\t\t\t\t}\n\n\t\t\t\t$output.append(frag);\n\n\t\t\t\tif (transition) {\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\treturn $output.removeClass('macro-repeat-in');\n\t\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t\t}\n\t\t\t}), delay);\n\t\t},\n\t\tregisterInterval: function registerInterval(callback, delay) {\n\t\t\tvar _this18 = this;\n\n\t\t\tif (typeof callback !== 'function') {\n\t\t\t\tthrow new TypeError('callback parameter must be a function');\n\t\t\t}\n\n\t\t\tvar turnId = State.turns;\n\t\t\tvar timers = this.timers;\n\t\t\tvar timerId = null;\n\n\t\t\t// Set up the interval.\n\t\t\ttimerId = setInterval(function () {\n\t\t\t\t// Terminate the timer if the turn IDs do not match.\n\t\t\t\tif (turnId !== State.turns) {\n\t\t\t\t\tclearInterval(timerId);\n\t\t\t\t\ttimers.delete(timerId);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tvar timerIdCache = void 0;\n\t\t\t\t/*\n    \tThere's no catch clause because this try/finally is here simply to ensure that\n    \tproper cleanup is done in the event that an exception is thrown during the\n    \t`Wikifier` call.\n    */\n\t\t\t\ttry {\n\t\t\t\t\tTempState.break = null;\n\n\t\t\t\t\t// Set up the `repeatTimerId` value, caching the existing value, if necessary.\n\t\t\t\t\tif (TempState.hasOwnProperty('repeatTimerId')) {\n\t\t\t\t\t\ttimerIdCache = TempState.repeatTimerId;\n\t\t\t\t\t}\n\n\t\t\t\t\tTempState.repeatTimerId = timerId;\n\n\t\t\t\t\t// Execute the callback.\n\t\t\t\t\tcallback.call(_this18);\n\t\t\t\t} finally {\n\t\t\t\t\t// Teardown the `repeatTimerId` property, restoring the cached value, if necessary.\n\t\t\t\t\tif (typeof timerIdCache !== 'undefined') {\n\t\t\t\t\t\tTempState.repeatTimerId = timerIdCache;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdelete TempState.repeatTimerId;\n\t\t\t\t\t}\n\n\t\t\t\t\tTempState.break = null;\n\t\t\t\t}\n\t\t\t}, delay);\n\t\t\ttimers.add(timerId);\n\n\t\t\t// Set up a single-use `prehistory` task to remove pending timers.\n\t\t\tif (!prehistory.hasOwnProperty('#repeat-timers-cleanup')) {\n\t\t\t\tprehistory['#repeat-timers-cleanup'] = function (task) {\n\t\t\t\t\tdelete prehistory[task]; // single-use task\n\t\t\t\t\ttimers.forEach(function (timerId) {\n\t\t\t\t\t\treturn clearInterval(timerId);\n\t\t\t\t\t});\n\t\t\t\t\ttimers.clear();\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t});\n\tMacro.add('stop', {\n\t\tskipArgs: true,\n\n\t\thandler: function handler() {\n\t\t\tif (!TempState.hasOwnProperty('repeatTimerId')) {\n\t\t\t\treturn this.error('must only be used in conjunction with its parent macro <<repeat>>');\n\t\t\t}\n\n\t\t\tvar timers = Macro.get('repeat').timers;\n\t\t\tvar timerId = TempState.repeatTimerId;\n\t\t\tclearInterval(timerId);\n\t\t\ttimers.delete(timerId);\n\t\t\tTempState.break = 2;\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<timed>> & <<next>>\n */\n\tMacro.add('timed', {\n\t\tisAsync: true,\n\t\ttags: ['next'],\n\t\ttimers: new Set(),\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no time value specified in <<timed>>');\n\t\t\t}\n\n\t\t\tvar items = [];\n\n\t\t\ttry {\n\t\t\t\titems.push({\n\t\t\t\t\tname: this.name,\n\t\t\t\t\tsource: this.source,\n\t\t\t\t\tdelay: Math.max(Engine.minDomActionDelay, Util.fromCssTime(this.args[0])),\n\t\t\t\t\tcontent: this.payload[0].contents\n\t\t\t\t});\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error(ex.message + ' in <<timed>>');\n\t\t\t}\n\n\t\t\tif (this.payload.length > 1) {\n\t\t\t\tvar i = void 0;\n\n\t\t\t\ttry {\n\t\t\t\t\tvar len = void 0;\n\n\t\t\t\t\tfor (i = 1, len = this.payload.length; i < len; ++i) {\n\t\t\t\t\t\titems.push({\n\t\t\t\t\t\t\tname: this.payload[i].name,\n\t\t\t\t\t\t\tsource: this.payload[i].source,\n\t\t\t\t\t\t\tdelay: this.payload[i].args.length === 0 ? items[items.length - 1].delay : Math.max(Engine.minDomActionDelay, Util.fromCssTime(this.payload[i].args[0])),\n\t\t\t\t\t\t\tcontent: this.payload[i].contents\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t} catch (ex) {\n\t\t\t\t\treturn this.error(ex.message + ' in <<next>> (#' + i + ')');\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Custom debug view setup.\n\t\t\tif (Config.debug) {\n\t\t\t\tthis.debugView.modes({ block: true });\n\t\t\t}\n\n\t\t\tvar transition = this.args.length > 1 && /^(?:transition|t8n)$/.test(this.args[1]);\n\t\t\tvar $wrapper = jQuery(document.createElement('span')).addClass('macro-' + this.name).appendTo(this.output);\n\n\t\t\t// Register the timer.\n\t\t\tthis.self.registerTimeout(this.createShadowWrapper(function (item) {\n\t\t\t\tvar frag = document.createDocumentFragment();\n\t\t\t\tnew Wikifier(frag, item.content);\n\n\t\t\t\t// Output.\n\t\t\t\tvar $output = $wrapper;\n\n\t\t\t\t// Custom debug view setup for `<<next>>`.\n\t\t\t\tif (Config.debug && item.name === 'next') {\n\t\t\t\t\t$output = jQuery(new DebugView( // eslint-disable-line no-param-reassign\n\t\t\t\t\t$output[0], 'macro', item.name, item.source).output);\n\t\t\t\t}\n\n\t\t\t\tif (transition) {\n\t\t\t\t\t$output = jQuery(document.createElement('span')).addClass('macro-timed-insert macro-timed-in').appendTo($output);\n\t\t\t\t}\n\n\t\t\t\t$output.append(frag);\n\n\t\t\t\tif (transition) {\n\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\treturn $output.removeClass('macro-timed-in');\n\t\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t\t}\n\t\t\t}), items);\n\t\t},\n\t\tregisterTimeout: function registerTimeout(callback, items) {\n\t\t\tif (typeof callback !== 'function') {\n\t\t\t\tthrow new TypeError('callback parameter must be a function');\n\t\t\t}\n\n\t\t\tvar turnId = State.turns;\n\t\t\tvar timers = this.timers;\n\t\t\tvar timerId = null;\n\t\t\tvar nextItem = items.shift();\n\n\t\t\tvar worker = function worker() {\n\t\t\t\t// Bookkeeping.\n\t\t\t\ttimers.delete(timerId);\n\n\t\t\t\tif (turnId !== State.turns) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// Set the current item and set up the next worker, if any.\n\t\t\t\tvar curItem = nextItem;\n\n\t\t\t\tif ((nextItem = items.shift()) != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\ttimerId = setTimeout(worker, nextItem.delay);\n\t\t\t\t\ttimers.add(timerId);\n\t\t\t\t}\n\n\t\t\t\t// Execute the callback.\n\t\t\t\tcallback.call(this, curItem);\n\t\t\t};\n\n\t\t\t// Setup the timeout.\n\t\t\ttimerId = setTimeout(worker, nextItem.delay);\n\t\t\ttimers.add(timerId);\n\n\t\t\t// Set up a single-use `prehistory` task to remove pending timers.\n\t\t\tif (!prehistory.hasOwnProperty('#timed-timers-cleanup')) {\n\t\t\t\tprehistory['#timed-timers-cleanup'] = function (task) {\n\t\t\t\t\tdelete prehistory[task]; // single-use task\n\t\t\t\t\ttimers.forEach(function (timerId) {\n\t\t\t\t\t\treturn clearTimeout(timerId);\n\t\t\t\t\t}); // eslint-disable-line no-shadow\n\t\t\t\t\ttimers.clear();\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t});\n\n\t/*\n \t<<widget>>\n */\n\tMacro.add('widget', {\n\t\ttags: null,\n\n\t\thandler: function handler() {\n\t\t\tif (this.args.length === 0) {\n\t\t\t\treturn this.error('no widget name specified');\n\t\t\t}\n\n\t\t\tvar widgetName = this.args[0];\n\n\t\t\tif (Macro.has(widgetName)) {\n\t\t\t\tif (!Macro.get(widgetName).isWidget) {\n\t\t\t\t\treturn this.error('cannot clobber existing macro \"' + widgetName + '\"');\n\t\t\t\t}\n\n\t\t\t\t// Delete the existing widget.\n\t\t\t\tMacro.delete(widgetName);\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tMacro.add(widgetName, {\n\t\t\t\t\tisWidget: true,\n\t\t\t\t\thandler: function (contents) {\n\t\t\t\t\t\treturn function () {\n\t\t\t\t\t\t\tvar argsCache = void 0;\n\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t// Cache the existing value of the `$args` variable, if necessary.\n\t\t\t\t\t\t\t\tif (State.variables.hasOwnProperty('args')) {\n\t\t\t\t\t\t\t\t\targsCache = State.variables.args;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Set up the widget `$args` variable and add a shadow.\n\t\t\t\t\t\t\t\tState.variables.args = [].concat(_toConsumableArray(this.args));\n\t\t\t\t\t\t\t\tState.variables.args.raw = this.args.raw;\n\t\t\t\t\t\t\t\tState.variables.args.full = this.args.full;\n\t\t\t\t\t\t\t\tthis.addShadow('$args');\n\n\t\t\t\t\t\t\t\t// Set up the error trapping variables.\n\t\t\t\t\t\t\t\tvar resFrag = document.createDocumentFragment();\n\t\t\t\t\t\t\t\tvar errList = [];\n\n\t\t\t\t\t\t\t\t// Wikify the widget contents.\n\t\t\t\t\t\t\t\tnew Wikifier(resFrag, contents);\n\n\t\t\t\t\t\t\t\t// Carry over the output, unless there were errors.\n\t\t\t\t\t\t\t\tArray.from(resFrag.querySelectorAll('.error')).forEach(function (errEl) {\n\t\t\t\t\t\t\t\t\terrList.push(errEl.textContent);\n\t\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t\tif (errList.length === 0) {\n\t\t\t\t\t\t\t\t\tthis.output.appendChild(resFrag);\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\treturn this.error('error' + (errList.length > 1 ? 's' : '') + ' within widget contents (' + errList.join('; ') + ')');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} catch (ex) {\n\t\t\t\t\t\t\t\treturn this.error('cannot execute widget: ' + ex.message);\n\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t// Revert the `$args` variable shadowing.\n\t\t\t\t\t\t\t\tif (typeof argsCache !== 'undefined') {\n\t\t\t\t\t\t\t\t\tState.variables.args = argsCache;\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tdelete State.variables.args;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t};\n\t\t\t\t\t}(this.payload[0].contents)\n\t\t\t\t});\n\n\t\t\t\t// Custom debug view setup.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tthis.debugView.modes({ hidden: true });\n\t\t\t\t}\n\t\t\t} catch (ex) {\n\t\t\t\treturn this.error('cannot create widget macro \"' + widgetName + '\": ' + ex.message);\n\t\t\t}\n\t\t}\n\t});\n})();\n\n/***********************************************************************************************************************\n\n\tdialog.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Has, L10n, safeActiveElement */\n\nvar Dialog = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Dialog element caches.\n\n\tvar _$overlay = null;\n\tvar _$dialog = null;\n\tvar _$dialogTitle = null;\n\tvar _$dialogBody = null;\n\n\t// The last active/focused non-dialog element.\n\tvar _lastActive = null;\n\n\t// The width of the browser's scrollbars.\n\tvar _scrollbarWidth = 0;\n\n\t// Dialog mutation resize handler.\n\tvar _dialogObserver = null;\n\n\t/*******************************************************************************\n \tDialog Functions.\n *******************************************************************************/\n\n\t/*\n \t[DEPRECATED] Adds a click hander to the target element(s) which opens the dialog modal.\n */\n\tfunction dialogAddClickHandler(targets, options, startFn, doneFn, closeFn) {\n\t\treturn jQuery(targets).ariaClick(function (ev) {\n\t\t\tev.preventDefault();\n\n\t\t\t// Call the start function.\n\t\t\tif (typeof startFn === 'function') {\n\t\t\t\tstartFn(ev);\n\t\t\t}\n\n\t\t\t// Open the dialog.\n\t\t\tdialogOpen(options, closeFn);\n\n\t\t\t// Call the done function.\n\t\t\tif (typeof doneFn === 'function') {\n\t\t\t\tdoneFn(ev);\n\t\t\t}\n\t\t});\n\t}\n\n\tfunction dialogBodyAppend() {\n\t\tvar _$dialogBody2;\n\n\t\t(_$dialogBody2 = _$dialogBody).append.apply(_$dialogBody2, arguments);\n\t\treturn Dialog;\n\t}\n\n\tfunction dialogBody() {\n\t\treturn _$dialogBody.get(0);\n\t}\n\n\tfunction dialogClose(ev) {\n\t\t// Trigger a `:dialogclosing` event on the dialog body.\n\t\t_$dialogBody.trigger(':dialogclosing');\n\n\t\t// Largely reverse the actions taken in `dialogOpen()`.\n\t\tjQuery(document).off('.dialog-close');\n\t\tif (_dialogObserver) {\n\t\t\t_dialogObserver.disconnect();\n\t\t\t_dialogObserver = null;\n\t\t} else {\n\t\t\t_$dialogBody.off('.dialog-resize');\n\t\t}\n\t\tjQuery(window).off('.dialog-resize');\n\t\t_$dialog.removeClass('open').css({ left: '', right: '', top: '', bottom: '' });\n\n\t\tjQuery('#ui-bar,#story').find('[tabindex=-2]').removeAttr('aria-hidden').attr('tabindex', 0);\n\t\tjQuery('body>[tabindex=-3]').removeAttr('aria-hidden').removeAttr('tabindex');\n\n\t\t_$overlay.removeClass('open');\n\t\tjQuery(document.documentElement).removeAttr('data-dialog');\n\n\t\t// Clear the dialog's content.\n\t\t_$dialogTitle.empty();\n\t\t_$dialogBody.empty().removeClass();\n\n\t\t// Attempt to restore focus to whichever element had it prior to opening the dialog.\n\t\tif (_lastActive !== null) {\n\t\t\tjQuery(_lastActive).focus();\n\t\t\t_lastActive = null;\n\t\t}\n\n\t\t// Call the given \"on close\" callback function, if any.\n\t\tif (ev && ev.data && typeof ev.data.closeFn === 'function') {\n\t\t\tev.data.closeFn(ev);\n\t\t}\n\n\t\t// Trigger a `:dialogclosed` event on the dialog body.\n\t\t/* legacy */\n\t\t_$dialogBody.trigger(':dialogclose');\n\t\t/* /legacy */\n\t\t_$dialogBody.trigger(':dialogclosed');\n\n\t\treturn Dialog;\n\t}\n\n\tfunction dialogInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Dialog/dialogInit()]');\n\t\t}\n\n\t\tif (document.getElementById('ui-dialog')) {\n\t\t\treturn;\n\t\t}\n\n\t\t/*\n  \tCalculate and cache the width of scrollbars.\n  */\n\t\t_scrollbarWidth = function () {\n\t\t\tvar scrollbarWidth = void 0;\n\n\t\t\ttry {\n\t\t\t\tvar inner = document.createElement('p');\n\t\t\t\tvar outer = document.createElement('div');\n\n\t\t\t\tinner.style.width = '100%';\n\t\t\t\tinner.style.height = '200px';\n\t\t\t\touter.style.position = 'absolute';\n\t\t\t\touter.style.left = '0px';\n\t\t\t\touter.style.top = '0px';\n\t\t\t\touter.style.width = '100px';\n\t\t\t\touter.style.height = '100px';\n\t\t\t\touter.style.visibility = 'hidden';\n\t\t\t\touter.style.overflow = 'hidden';\n\n\t\t\t\touter.appendChild(inner);\n\t\t\t\tdocument.body.appendChild(outer);\n\n\t\t\t\tvar w1 = inner.offsetWidth;\n\t\t\t\t/*\n    \tThe `overflow: scroll` style property value does not work consistently\n    \twith scrollbars which are styled with `::-webkit-scrollbar`, so we use\n    \t`overflow: auto` with dimensions guaranteed to force a scrollbar.\n    */\n\t\t\t\touter.style.overflow = 'auto';\n\t\t\t\tvar w2 = inner.offsetWidth;\n\n\t\t\t\tif (w1 === w2) {\n\t\t\t\t\tw2 = outer.clientWidth;\n\t\t\t\t}\n\n\t\t\t\tdocument.body.removeChild(outer);\n\n\t\t\t\tscrollbarWidth = w1 - w2;\n\t\t\t} catch (ex) {/* no-op */}\n\n\t\t\treturn scrollbarWidth || 17; // 17px is a reasonable failover\n\t\t}();\n\n\t\t/*\n  \tGenerate the dialog elements.\n  */\n\t\tvar $elems = jQuery(document.createDocumentFragment()).append(\n\t\t/* eslint-disable max-len */\n\t\t'<div id=\"ui-overlay\" class=\"ui-close\"></div>' + '<div id=\"ui-dialog\" tabindex=\"0\" role=\"dialog\" aria-labelledby=\"ui-dialog-title\">' + '<div id=\"ui-dialog-titlebar\">' + '<h1 id=\"ui-dialog-title\"></h1>' + ('<button id=\"ui-dialog-close\" class=\"ui-close\" tabindex=\"0\" aria-label=\"' + L10n.get('close') + '\">\\uE804</button>') + '</div>' + '<div id=\"ui-dialog-body\"></div>' + '</div>'\n\t\t/* eslint-enable max-len */\n\t\t);\n\n\t\t/*\n  \tCache the dialog elements, since they're going to be used often.\n  \t\tNOTE: We rewrap the elements themselves, rather than simply using\n  \tthe results of `find()`, so that we cache uncluttered jQuery-wrappers\n  \t(i.e. `context` refers to the elements and there is no `prevObject`).\n  */\n\t\t_$overlay = jQuery($elems.find('#ui-overlay').get(0));\n\t\t_$dialog = jQuery($elems.find('#ui-dialog').get(0));\n\t\t_$dialogTitle = jQuery($elems.find('#ui-dialog-title').get(0));\n\t\t_$dialogBody = jQuery($elems.find('#ui-dialog-body').get(0));\n\n\t\t/*\n  \tInsert the dialog elements into the page before the main script.\n  */\n\t\t$elems.insertBefore('body>script#script-sugarcube');\n\t}\n\n\tfunction dialogIsOpen(classNames) {\n\t\treturn _$dialog.hasClass('open') && (classNames ? classNames.splitOrEmpty(/\\s+/).every(function (cn) {\n\t\t\treturn _$dialogBody.hasClass(cn);\n\t\t}) : true);\n\t}\n\n\tfunction dialogOpen(options, closeFn) {\n\t\t// Trigger a `:dialogopening` event on the dialog body.\n\t\t_$dialogBody.trigger(':dialogopening');\n\n\t\t// Grab the options we care about.\n\n\t\tvar _jQuery$extend = jQuery.extend({ top: 50 }, options),\n\t\t    top = _jQuery$extend.top;\n\n\t\t// Record the last active/focused non-dialog element.\n\n\n\t\tif (!dialogIsOpen()) {\n\t\t\t_lastActive = safeActiveElement();\n\t\t}\n\n\t\t// Add the `data-dialog` attribute to <html> (mostly used to style <body>).\n\t\tjQuery(document.documentElement).attr('data-dialog', 'open');\n\n\t\t// Display the overlay.\n\t\t_$overlay.addClass('open');\n\n\t\t/*\n  \tAdd the imagesLoaded handler to the dialog body, if necessary.\n  \t\tNOTE: We use `querySelector()` here as jQuery has no simple way to\n  \tcheck if, and only if, at least one element of the specified type\n  \texists.  The best that jQuery offers is analogous to `querySelectorAll()`,\n  \twhich enumerates all elements of the specified type.\n  */\n\t\tif (_$dialogBody[0].querySelector('img') !== null) {\n\t\t\t_$dialogBody.imagesLoaded().always(function () {\n\t\t\t\treturn _resizeHandler({ data: { top: top } });\n\t\t\t});\n\t\t}\n\n\t\t// Add `aria-hidden=true` to all direct non-dialog-children of <body> to\n\t\t// hide the underlying page from screen readers while the dialog is open.\n\t\tjQuery('body>:not(script,#store-area,tw-storydata,#ui-bar,#ui-overlay,#ui-dialog)').attr('tabindex', -3).attr('aria-hidden', true);\n\t\tjQuery('#ui-bar,#story').find('[tabindex]:not([tabindex^=-])').attr('tabindex', -2).attr('aria-hidden', true);\n\n\t\t// Display the dialog.\n\t\t_$dialog.css(_calcPosition(top)).addClass('open').focus();\n\n\t\t// Add the UI resize handler.\n\t\tjQuery(window).on('resize.dialog-resize', null, { top: top }, jQuery.throttle(40, _resizeHandler));\n\n\t\t// Add the dialog mutation resize handler.\n\t\tif (Has.mutationObserver) {\n\t\t\t_dialogObserver = new MutationObserver(function (mutations) {\n\t\t\t\tfor (var i = 0; i < mutations.length; ++i) {\n\t\t\t\t\tif (mutations[i].type === 'childList') {\n\t\t\t\t\t\t_resizeHandler({ data: { top: top } });\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t\t_dialogObserver.observe(_$dialogBody[0], {\n\t\t\t\tchildList: true,\n\t\t\t\tsubtree: true\n\t\t\t});\n\t\t} else {\n\t\t\t_$dialogBody.on('DOMNodeInserted.dialog-resize DOMNodeRemoved.dialog-resize', null, { top: top }, jQuery.throttle(40, _resizeHandler));\n\t\t}\n\n\t\t// Set up the delegated UI close handler.\n\t\tjQuery(document).on('click.dialog-close', '.ui-close', { closeFn: closeFn }, dialogClose).on('keypress.dialog-close', '.ui-close', function (ev) {\n\t\t\t// 13 is Enter/Return, 32 is Space.\n\t\t\tif (ev.which === 13 || ev.which === 32) {\n\t\t\t\tjQuery(this).trigger('click');\n\t\t\t}\n\t\t});\n\n\t\t// Trigger a `:dialogopened` event on the dialog body.\n\t\t/* legacy */\n\t\t_$dialogBody.trigger(':dialogopen');\n\t\t/* /legacy */\n\t\t_$dialogBody.trigger(':dialogopened');\n\n\t\treturn Dialog;\n\t}\n\n\tfunction dialogResize(data) {\n\t\treturn _resizeHandler((typeof data === 'undefined' ? 'undefined' : _typeof(data)) === 'object' ? { data: data } : undefined);\n\t}\n\n\tfunction dialogSetup(title, classNames) {\n\t\t_$dialogBody.empty().removeClass();\n\n\t\tif (classNames != null) {\n\t\t\t// lazy equality for null\n\t\t\t_$dialogBody.addClass(classNames);\n\t\t}\n\n\t\t_$dialogTitle.empty().append((title != null ? String(title) : '') || '\\xA0'); // lazy equality for null\n\n\t\t// TODO: In v3 this should return `Dialog` for chaining.\n\t\treturn _$dialogBody.get(0);\n\t}\n\n\tfunction dialogBodyWiki() {\n\t\tvar _$dialogBody3;\n\n\t\t(_$dialogBody3 = _$dialogBody).wiki.apply(_$dialogBody3, arguments);\n\t\treturn Dialog;\n\t}\n\n\t/*******************************************************************************\n \tUtility Functions.\n *******************************************************************************/\n\n\tfunction _calcPosition(topPos) {\n\t\tvar top = topPos != null ? topPos : 50; // lazy equality for null\n\t\tvar $parent = jQuery(window);\n\t\tvar dialogPos = { left: '', right: '', top: '', bottom: '' };\n\n\t\t// Unset the dialog's positional properties before checking its dimensions.\n\t\t_$dialog.css(dialogPos);\n\n\t\tvar horzSpace = $parent.width() - _$dialog.outerWidth(true) - 1; // -1 to address a Firefox issue\n\t\tvar vertSpace = $parent.height() - _$dialog.outerHeight(true) - 1; // -1 to address a Firefox issue\n\n\t\tif (horzSpace <= 32 + _scrollbarWidth) {\n\t\t\tvertSpace -= _scrollbarWidth;\n\t\t}\n\n\t\tif (vertSpace <= 32 + _scrollbarWidth) {\n\t\t\thorzSpace -= _scrollbarWidth;\n\t\t}\n\n\t\tif (horzSpace <= 32) {\n\t\t\tdialogPos.left = dialogPos.right = 16;\n\t\t} else {\n\t\t\tdialogPos.left = dialogPos.right = horzSpace / 2 >> 0;\n\t\t}\n\n\t\tif (vertSpace <= 32) {\n\t\t\tdialogPos.top = dialogPos.bottom = 16;\n\t\t} else {\n\t\t\tif (vertSpace / 2 > top) {\n\t\t\t\tdialogPos.top = top;\n\t\t\t} else {\n\t\t\t\tdialogPos.top = dialogPos.bottom = vertSpace / 2 >> 0;\n\t\t\t}\n\t\t}\n\n\t\tObject.keys(dialogPos).forEach(function (key) {\n\t\t\tif (dialogPos[key] !== '') {\n\t\t\t\tdialogPos[key] += 'px';\n\t\t\t}\n\t\t});\n\n\t\treturn dialogPos;\n\t}\n\n\tfunction _resizeHandler(ev) {\n\t\tvar top = ev && ev.data && typeof ev.data.top !== 'undefined' ? ev.data.top : 50;\n\n\t\tif (_$dialog.css('display') === 'block') {\n\t\t\t// Stow the dialog.\n\t\t\t_$dialog.css({ display: 'none' });\n\n\t\t\t// Restore the dialog with its new positional properties.\n\t\t\t_$dialog.css(jQuery.extend({ display: '' }, _calcPosition(top)));\n\t\t}\n\t}\n\n\t/*******************************************************************************\n \tObject Exports.\n *******************************************************************************/\n\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tappend: { value: dialogBodyAppend },\n\t\tbody: { value: dialogBody },\n\t\tclose: { value: dialogClose },\n\t\tinit: { value: dialogInit },\n\t\tisOpen: { value: dialogIsOpen },\n\t\topen: { value: dialogOpen },\n\t\tresize: { value: dialogResize },\n\t\tsetup: { value: dialogSetup },\n\t\twiki: { value: dialogBodyWiki },\n\n\t\t// Legacy Functions.\n\t\taddClickHandler: { value: dialogAddClickHandler }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tengine.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Alert, Config, DebugView, Dialog, Has, LoadScreen, Save, State, Story, StyleWrapper, UI, UIBar, Util,\n\t       Wikifier, postdisplay, predisplay, prehistory\n*/\n\nvar Engine = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Engine state types object (pseudo-enumeration).\n\n\tvar States = Util.toEnum({\n\t\tIdle: 'idle',\n\t\tPlaying: 'playing',\n\t\tRendering: 'rendering'\n\t});\n\n\t// Minimum delay for DOM actions (in milliseconds).\n\tvar minDomActionDelay = 40;\n\n\t// Current state of the engine (default: `Engine.States.Idle`).\n\tvar _state = States.Idle;\n\n\t// Last time `enginePlay()` was called (in milliseconds).\n\tvar _lastPlay = null;\n\n\t// Cache of the debug view for the StoryInit special passage.\n\tvar _storyInitDebugView = null;\n\n\t// Cache of the outline patching <style> element (`StyleWrapper`-wrapped).\n\tvar _outlinePatch = null;\n\n\t// List of objects describing `StoryInterface` elements to update via passages during navigation.\n\tvar _updating = null;\n\n\t/*******************************************************************************************************************\n \tEngine Functions.\n *******************************************************************************************************************/\n\t/*\n \tInitialize the core story elements and perform some bookkeeping.\n */\n\tfunction engineInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Engine/engineInit()]');\n\t\t}\n\n\t\t/*\n  \tRemove #init-no-js & #init-lacking from #init-screen.\n  */\n\t\tjQuery('#init-no-js,#init-lacking').remove();\n\n\t\t/*\n  \tGenerate the core story elements and insert them into the page before the store area.\n  */\n\t\t(function () {\n\t\t\tvar $elems = jQuery(document.createDocumentFragment());\n\t\t\tvar markup = Story.has('StoryInterface') && Story.get('StoryInterface').text.trim();\n\n\t\t\tif (markup) {\n\t\t\t\t// Remove the UI bar, its styles, and events.\n\t\t\t\tUIBar.destroy();\n\n\t\t\t\t// Remove the core display area styles.\n\t\t\t\tjQuery(document.head).find('#style-core-display').remove();\n\n\t\t\t\t$elems.append(markup);\n\n\t\t\t\tif ($elems.find('#passages').length === 0) {\n\t\t\t\t\tthrow new Error('no element with ID \"passages\" found within \"StoryInterface\" special passage');\n\t\t\t\t}\n\n\t\t\t\tvar updating = [];\n\n\t\t\t\t$elems.find('[data-passage]').each(function (i, el) {\n\t\t\t\t\tif (el.id === 'passages') {\n\t\t\t\t\t\tthrow new Error('\"StoryInterface\" element <' + el.nodeName.toLowerCase() + ' id=\"passages\"> must not contain a \"data-passage\" content attribute');\n\t\t\t\t\t}\n\n\t\t\t\t\tvar passage = el.getAttribute('data-passage').trim();\n\n\t\t\t\t\tif (el.firstElementChild !== null) {\n\t\t\t\t\t\tthrow new Error('\"StoryInterface\" element <' + el.nodeName.toLowerCase() + ' data-passage=\"' + passage + '\"> contains child elements');\n\t\t\t\t\t}\n\n\t\t\t\t\tif (Story.has(passage)) {\n\t\t\t\t\t\tupdating.push({\n\t\t\t\t\t\t\tpassage: passage,\n\t\t\t\t\t\t\telement: el\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tif (updating.length > 0) {\n\t\t\t\t\t_updating = updating;\n\t\t\t\t}\n\n\t\t\t\tConfig.ui.updateStoryElements = false;\n\t\t\t} else {\n\t\t\t\t$elems.append('<div id=\"story\" role=\"main\"><div id=\"passages\"></div></div>');\n\t\t\t}\n\n\t\t\t// Insert the core UI elements into the page before the main script.\n\t\t\t$elems.insertBefore('body>script#script-sugarcube');\n\t\t})();\n\n\t\t/*\n  \tGenerate and cache the ARIA outlines <style> element (`StyleWrapper`-wrapped)\n  \tand set up the handler to manipulate the outlines.\n  \t\tIDEA: http://www.paciellogroup.com/blog/2012/04/how-to-remove-css-outlines-in-an-accessible-manner/\n  */\n\t\t_outlinePatch = new StyleWrapper(function () {\n\t\t\treturn jQuery(document.createElement('style')).attr({\n\t\t\t\tid: 'style-aria-outlines',\n\t\t\t\ttype: 'text/css'\n\t\t\t}).appendTo(document.head).get(0);\n\t\t} // return the <style> element itself\n\t\t());\n\t\tjQuery(document).on('mousedown.aria-outlines keydown.aria-outlines', function (ev) {\n\t\t\treturn ev.type === 'keydown' ? _showOutlines() : _hideOutlines();\n\t\t});\n\t}\n\n\t/*\n \tStarts the story.\n */\n\tfunction engineStart() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Engine/engineStart()]');\n\t\t}\n\n\t\t/*\n  \tExecute the StoryInit special passage.\n  */\n\t\tif (Story.has('StoryInit')) {\n\t\t\ttry {\n\t\t\t\tvar debugBuffer = Wikifier.wikifyEval(Story.get('StoryInit').text);\n\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tvar debugView = new DebugView(document.createDocumentFragment(), 'special', 'StoryInit', 'StoryInit');\n\t\t\t\t\tdebugView.modes({ hidden: true });\n\t\t\t\t\tdebugView.append(debugBuffer);\n\t\t\t\t\t_storyInitDebugView = debugView.output;\n\t\t\t\t}\n\t\t\t} catch (ex) {\n\t\t\t\tconsole.error(ex);\n\t\t\t\tAlert.error('StoryInit', ex.message);\n\t\t\t}\n\t\t}\n\n\t\t// Sanity checks.\n\t\tif (Config.passages.start == null) {\n\t\t\t// lazy equality for null\n\t\t\tthrow new Error('starting passage not selected');\n\t\t}\n\t\tif (!Story.has(Config.passages.start)) {\n\t\t\tthrow new Error('starting passage (\"' + Config.passages.start + '\") not found');\n\t\t}\n\n\t\t// Focus the document element initially.\n\t\tjQuery(document.documentElement).focus();\n\n\t\t/*\n  \tAttempt to restore an active session.  Failing that, attempt to autoload the autosave,\n  \tif requested.  Failing that, display the starting passage.\n  */\n\t\tif (State.restore()) {\n\t\t\tengineShow();\n\t\t} else {\n\t\t\tvar loadStart = true;\n\n\t\t\tswitch (_typeof(Config.saves.autoload)) {\n\t\t\t\tcase 'boolean':\n\t\t\t\t\tif (Config.saves.autoload && Save.autosave.ok() && Save.autosave.has()) {\n\t\t\t\t\t\tif (DEBUG) {\n\t\t\t\t\t\t\tconsole.log('\\tattempting autoload: \"' + Save.autosave.get().title + '\"');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tloadStart = !Save.autosave.load();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'string':\n\t\t\t\t\tif (Config.saves.autoload === 'prompt' && Save.autosave.ok() && Save.autosave.has()) {\n\t\t\t\t\t\tloadStart = false;\n\t\t\t\t\t\tUI.buildAutoload();\n\t\t\t\t\t\tDialog.open();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'function':\n\t\t\t\t\tif (Save.autosave.ok() && Save.autosave.has() && !!Config.saves.autoload()) {\n\t\t\t\t\t\tif (DEBUG) {\n\t\t\t\t\t\t\tconsole.log('\\tattempting autoload: \"' + Save.autosave.get().title + '\"');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tloadStart = !Save.autosave.load();\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tif (loadStart) {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('\\tstarting passage: \"' + Config.passages.start + '\"');\n\t\t\t\t}\n\n\t\t\t\tenginePlay(Config.passages.start);\n\t\t\t}\n\t\t}\n\t}\n\n\t/*\n \tRestarts the story.\n */\n\tfunction engineRestart() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Engine/engineRestart()]');\n\t\t}\n\n\t\t/*\n  \tShow the loading screen to hide any unsightly rendering shenanigans during the\n  \tpage reload.\n  */\n\t\tLoadScreen.show();\n\n\t\t/*\n  \tScroll the window to the top.\n  \t\tThis is required by most browsers for the starting passage or it will remain at\n  \twhatever its current scroll position is after the page reload.  We do it generally,\n  \trather than only for the currently set starting passage, since the starting passage\n  \tmay be dynamically manipulated.\n  */\n\t\twindow.scroll(0, 0);\n\n\t\t/*\n  \tDelete the active session.\n  */\n\t\tState.reset();\n\n\t\t/*\n  \tTrigger an ':enginerestart' event.\n  */\n\t\tjQuery.event.trigger(':enginerestart');\n\n\t\t/*\n  \tReload the page.\n  */\n\t\twindow.location.reload();\n\t}\n\n\t/*\n \tReturns the current state of the engine.\n */\n\tfunction engineState() {\n\t\treturn _state;\n\t}\n\n\t/*\n \tReturns whether the engine is idle.\n */\n\tfunction engineIsIdle() {\n\t\treturn _state === States.Idle;\n\t}\n\n\t/*\n \tReturns whether the engine is playing.\n */\n\tfunction engineIsPlaying() {\n\t\treturn _state !== States.Idle;\n\t}\n\n\t/*\n \tReturns whether the engine is rendering.\n */\n\tfunction engineIsRendering() {\n\t\treturn _state === States.Rendering;\n\t}\n\n\t/*\n \tReturns a timestamp representing the last time `Engine.play()` was called.\n */\n\tfunction engineLastPlay() {\n\t\treturn _lastPlay;\n\t}\n\n\t/*\n \tActivate the moment at the given index within the state history and show it.\n */\n\tfunction engineGoTo(idx) {\n\t\tvar succeded = State.goTo(idx);\n\n\t\tif (succeded) {\n\t\t\tengineShow();\n\t\t}\n\n\t\treturn succeded;\n\t}\n\n\t/*\n \tActivate the moment at the given offset from the active moment within the state history\n \tand show it.\n */\n\tfunction engineGo(offset) {\n\t\tvar succeded = State.go(offset);\n\n\t\tif (succeded) {\n\t\t\tengineShow();\n\t\t}\n\n\t\treturn succeded;\n\t}\n\n\t/*\n \tGo to the moment which directly precedes the active moment and show it.\n */\n\tfunction engineBackward() {\n\t\treturn engineGo(-1);\n\t}\n\n\t/*\n \tGo to the moment which directly follows the active moment and show it.\n */\n\tfunction engineForward() {\n\t\treturn engineGo(1);\n\t}\n\n\t/*\n \tRenders and displays the active (present) moment's associated passage without adding\n \ta new moment to the history.\n */\n\tfunction engineShow() {\n\t\treturn enginePlay(State.passage, true);\n\t}\n\n\t/*\n \tRenders and displays the passage referenced by the given title, optionally without\n \tadding a new moment to the history.\n */\n\tfunction enginePlay(title, noHistory) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Engine/enginePlay(title: \"' + title + '\", noHistory: ' + noHistory + ')]');\n\t\t}\n\n\t\tvar passageTitle = title;\n\n\t\t/*\n  \tUpdate the engine state.\n  */\n\t\t_state = States.Playing;\n\n\t\t/*\n  \tReset the temporary state and variables objects.\n  */\n\t\tTempState = {}; // eslint-disable-line no-undef\n\t\tState.clearTemporary();\n\n\t\t/*\n  \tDebug view setup.\n  */\n\t\tvar passageReadyOutput = void 0;\n\t\tvar passageDoneOutput = void 0;\n\n\t\t/*\n  \tExecute the navigation override callback.\n  */\n\t\tif (typeof Config.navigation.override === 'function') {\n\t\t\ttry {\n\t\t\t\tvar overrideTitle = Config.navigation.override(passageTitle);\n\n\t\t\t\tif (overrideTitle) {\n\t\t\t\t\tpassageTitle = overrideTitle;\n\t\t\t\t}\n\t\t\t} catch (ex) {/* no-op */}\n\t\t}\n\n\t\t/*\n  \tRetrieve the passage by the given title.\n  \t\tNOTE: The values of the `title` parameter and `passageTitle` variable\n  \tmay be empty, strings, or numbers (though using a number as reference\n  \tto a numeric title should be discouraged), so after loading the passage,\n  \talways refer to `passage.title` and never to the others.\n  */\n\t\tvar passage = Story.get(passageTitle);\n\n\t\t/*\n  \tExecute the pre-history events and tasks.\n  */\n\t\tjQuery.event.trigger({\n\t\t\ttype: ':passageinit',\n\t\t\tpassage: passage\n\t\t});\n\t\tObject.keys(prehistory).forEach(function (task) {\n\t\t\tif (typeof prehistory[task] === 'function') {\n\t\t\t\tprehistory[task].call(this, task);\n\t\t\t}\n\t\t}, passage);\n\n\t\t/*\n  \tCreate a new entry in the history.\n  */\n\t\tif (!noHistory) {\n\t\t\tState.create(passage.title);\n\t\t}\n\n\t\t/*\n  \tUpdate the last play time.\n  \t\tNOTE: This is mostly for event, task, and special passage code,\n  \tthough the likelihood of it being needed this early is low.  This\n  \twill be updated again later at the end.\n  */\n\t\t_lastPlay = Util.now();\n\n\t\t/*\n  \tClear `<body>` classes.\n  */\n\t\tif (document.body.className) {\n\t\t\tdocument.body.className = '';\n\t\t}\n\n\t\t/*\n  \tExecute pre-display tasks and the `PassageReady` special passage.\n  */\n\t\tObject.keys(predisplay).forEach(function (task) {\n\t\t\tif (typeof predisplay[task] === 'function') {\n\t\t\t\tpredisplay[task].call(this, task);\n\t\t\t}\n\t\t}, passage);\n\n\t\tif (Story.has('PassageReady')) {\n\t\t\ttry {\n\t\t\t\tpassageReadyOutput = Wikifier.wikifyEval(Story.get('PassageReady').text);\n\t\t\t} catch (ex) {\n\t\t\t\tconsole.error(ex);\n\t\t\t\tAlert.error('PassageReady', ex.message);\n\t\t\t}\n\t\t}\n\n\t\t/*\n  \tUpdate the engine state.\n  */\n\t\t_state = States.Rendering;\n\n\t\t/*\n  \tRender the incoming passage and add it to the page.\n  */\n\t\tvar $incoming = jQuery(passage.render());\n\t\tvar passages = document.getElementById('passages');\n\n\t\tif (passages.hasChildNodes()) {\n\t\t\tif (typeof Config.passages.transitionOut === 'number' || typeof Config.passages.transitionOut === 'string' && Config.passages.transitionOut !== '' && Has.transitionEndEvent) {\n\t\t\t\t[].concat(_toConsumableArray(passages.childNodes)).forEach(function (outgoing) {\n\t\t\t\t\tvar $outgoing = jQuery(outgoing);\n\n\t\t\t\t\tif (outgoing.nodeType === Node.ELEMENT_NODE && $outgoing.hasClass('passage')) {\n\t\t\t\t\t\tif ($outgoing.hasClass('passage-out')) {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$outgoing.attr('id', 'out-' + $outgoing.attr('id')).addClass('passage-out');\n\n\t\t\t\t\t\tif (typeof Config.passages.transitionOut === 'string') {\n\t\t\t\t\t\t\t$outgoing.on(Has.transitionEndEvent, function (ev) {\n\t\t\t\t\t\t\t\tif (ev.originalEvent.propertyName === Config.passages.transitionOut) {\n\t\t\t\t\t\t\t\t\t$outgoing.remove();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\t\t\treturn $outgoing.remove();\n\t\t\t\t\t\t\t}, Math.max(minDomActionDelay, Config.passages.transitionOut));\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$outgoing.remove();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tjQuery(passages).empty();\n\t\t\t}\n\t\t}\n\n\t\t$incoming.addClass('passage-in').appendTo(passages);\n\t\tsetTimeout(function () {\n\t\t\treturn $incoming.removeClass('passage-in');\n\t\t}, minDomActionDelay);\n\n\t\t/*\n  \tSet the document title, if necessary.\n  */\n\t\tif (Config.passages.displayTitles && passage.title !== Config.passages.start) {\n\t\t\tdocument.title = passage.title + ' | ' + Story.title;\n\t\t}\n\n\t\t/*\n  \tScroll the window to the top.\n  */\n\t\twindow.scroll(0, 0);\n\n\t\t/*\n  \tUpdate the engine state.\n  */\n\t\t_state = States.Playing;\n\n\t\t/*\n  \tExecute post-display events, tasks, and the `PassageDone` special passage.\n  */\n\t\tif (Story.has('PassageDone')) {\n\t\t\ttry {\n\t\t\t\tpassageDoneOutput = Wikifier.wikifyEval(Story.get('PassageDone').text);\n\t\t\t} catch (ex) {\n\t\t\t\tconsole.error(ex);\n\t\t\t\tAlert.error('PassageDone', ex.message);\n\t\t\t}\n\t\t}\n\n\t\tjQuery.event.trigger({\n\t\t\ttype: ':passagedisplay',\n\t\t\tpassage: passage\n\t\t});\n\t\tObject.keys(postdisplay).forEach(function (task) {\n\t\t\tif (typeof postdisplay[task] === 'function') {\n\t\t\t\tpostdisplay[task].call(this, task);\n\t\t\t}\n\t\t}, passage);\n\n\t\t/*\n  \tUpdate the other interface elements, if necessary.\n  */\n\t\tif (_updating !== null) {\n\t\t\t_updating.forEach(function (pair) {\n\t\t\t\tjQuery(pair.element).empty();\n\t\t\t\tnew Wikifier(pair.element, Story.get(pair.passage).processText().trim());\n\t\t\t});\n\t\t} else if (Config.ui.updateStoryElements) {\n\t\t\tUIBar.update();\n\t\t}\n\n\t\t/*\n  \tAdd the completed debug views for `StoryInit`, `PassageReady`, and `PassageDone`\n  \tto the incoming passage element.\n  */\n\t\tif (Config.debug) {\n\t\t\tvar debugView = void 0;\n\n\t\t\t// Prepend the `PassageReady` debug view.\n\t\t\tif (passageReadyOutput != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tdebugView = new DebugView(document.createDocumentFragment(), 'special', 'PassageReady', 'PassageReady');\n\t\t\t\tdebugView.modes({ hidden: true });\n\t\t\t\tdebugView.append(passageReadyOutput);\n\t\t\t\t$incoming.prepend(debugView.output);\n\t\t\t}\n\n\t\t\t// Append the `PassageDone` debug view.\n\t\t\tif (passageDoneOutput != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tdebugView = new DebugView(document.createDocumentFragment(), 'special', 'PassageDone', 'PassageDone');\n\t\t\t\tdebugView.modes({ hidden: true });\n\t\t\t\tdebugView.append(passageDoneOutput);\n\t\t\t\t$incoming.append(debugView.output);\n\t\t\t}\n\n\t\t\t// Prepend the cached `StoryInit` debug view, if we're showing the first moment/turn.\n\t\t\tif (State.turns === 1 && _storyInitDebugView != null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\t$incoming.prepend(_storyInitDebugView);\n\t\t\t}\n\t\t}\n\n\t\t/*\n  \tLast second post-processing for accessibility and other things.\n  */\n\t\t_hideOutlines(); // initially hide outlines\n\t\tjQuery('#story')\n\t\t// Add `link-external` to all `href` bearing `<a>` elements which don't have it.\n\t\t.find('a[href]:not(.link-external)').addClass('link-external').end()\n\t\t// Add `tabindex=0` to all interactive elements which don't have it.\n\t\t.find('a,link,button,input,select,textarea').not('[tabindex]').attr('tabindex', 0);\n\n\t\t/*\n  \tHandle autosaves.\n  */\n\t\tswitch (_typeof(Config.saves.autosave)) {\n\t\t\tcase 'boolean':\n\t\t\t\tif (Config.saves.autosave) {\n\t\t\t\t\tSave.autosave.save();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'string':\n\t\t\t\tif (passage.tags.includes(Config.saves.autosave)) {\n\t\t\t\t\tSave.autosave.save();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'object':\n\t\t\t\tif (Array.isArray(Config.saves.autosave) && passage.tags.some(function (tag) {\n\t\t\t\t\treturn Config.saves.autosave.includes(tag);\n\t\t\t\t})) {\n\t\t\t\t\tSave.autosave.save();\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\n\t\t/*\n  \tExecute post-play events.\n  */\n\t\tjQuery.event.trigger({\n\t\t\ttype: ':passageend',\n\t\t\tpassage: passage\n\t\t});\n\n\t\t/*\n  \tReset the engine state.\n  */\n\t\t_state = States.Idle;\n\n\t\t/*\n  \tUpdate the last play time.\n  */\n\t\t_lastPlay = Util.now();\n\n\t\t// TODO: Let this return the jQuery wrapped element, rather than just the element.\n\t\treturn $incoming[0];\n\t}\n\n\t/*******************************************************************************************************************\n \tLegacy Functions.\n *******************************************************************************************************************/\n\t/*\n \t[DEPRECATED] Play the given passage, optionally without altering the history.\n */\n\tfunction engineDisplay(title, link, option) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Engine/engineDisplay()]');\n\t\t}\n\n\t\tvar noHistory = false;\n\n\t\t// Process the option parameter.\n\t\tswitch (option) {\n\t\t\tcase undefined:\n\t\t\t\t/* no-op */\n\t\t\t\tbreak;\n\n\t\t\tcase 'replace':\n\t\t\tcase 'back':\n\t\t\t\tnoHistory = true;\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tthrow new Error('Engine.display option parameter called with obsolete value \"' + option + '\"; please notify the developer');\n\t\t}\n\n\t\tenginePlay(title, noHistory);\n\t}\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\tfunction _hideOutlines() {\n\t\t_outlinePatch.set('*:focus{outline:none}');\n\t}\n\n\tfunction _showOutlines() {\n\t\t_outlinePatch.clear();\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tConstants.\n  */\n\t\tStates: { value: States },\n\t\tminDomActionDelay: { value: minDomActionDelay },\n\n\t\t/*\n  \tCore Functions.\n  */\n\t\tinit: { value: engineInit },\n\t\tstart: { value: engineStart },\n\t\trestart: { value: engineRestart },\n\t\tstate: { get: engineState },\n\t\tisIdle: { value: engineIsIdle },\n\t\tisPlaying: { value: engineIsPlaying },\n\t\tisRendering: { value: engineIsRendering },\n\t\tlastPlay: { get: engineLastPlay },\n\t\tgoTo: { value: engineGoTo },\n\t\tgo: { value: engineGo },\n\t\tbackward: { value: engineBackward },\n\t\tforward: { value: engineForward },\n\t\tshow: { value: engineShow },\n\t\tplay: { value: enginePlay },\n\n\t\t/*\n  \tLegacy Functions.\n  */\n\t\tdisplay: { value: engineDisplay }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tpassage.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Config, L10n, Story, Util, Wikifier, postrender, prerender */\n\nvar Passage = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\tvar _tagsToSkip = void 0;\n\tvar _twine1Unescape = void 0;\n\n\t/*\n \tTags which should not be transformed into classes:\n \t\tdebug      → special tag\n \t\tnobr       → special tag\n \t\tpassage    → the default class\n \t\tscript     → special tag (only in Twine 1)\n \t\tstylesheet → special tag (only in Twine 1)\n \t\ttwine.*    → special tag\n \t\twidget     → special tag\n */\n\t// For Twine 1\n\tif (TWINE1) {\n\t\t_tagsToSkip = /^(?:debug|nobr|passage|script|stylesheet|widget|twine\\..*)$/i;\n\t}\n\t// For Twine 2\n\telse {\n\t\t\t_tagsToSkip = /^(?:debug|nobr|passage|widget|twine\\..*)$/i;\n\t\t}\n\n\t// For Twine 1\n\tif (TWINE1) {\n\t\t/*\n  \tReturns a decoded version of the passed Twine 1 passage store encoded string.\n  */\n\t\tvar _twine1EscapesRe = /(?:\\\\n|\\\\t|\\\\s|\\\\|\\r)/g;\n\t\tvar _hasTwine1EscapesRe = new RegExp(_twine1EscapesRe.source); // to drop the global flag\n\t\tvar _twine1EscapesMap = Object.freeze({\n\t\t\t'\\\\n': '\\n',\n\t\t\t'\\\\t': '\\t',\n\t\t\t'\\\\s': '\\\\',\n\t\t\t'\\\\': '\\\\',\n\t\t\t'\\r': ''\n\t\t});\n\n\t\t_twine1Unescape = function _twine1Unescape(str) {\n\t\t\tif (str == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\treturn '';\n\t\t\t}\n\n\t\t\tvar val = String(str);\n\t\t\treturn val && _hasTwine1EscapesRe.test(val) ? val.replace(_twine1EscapesRe, function (esc) {\n\t\t\t\treturn _twine1EscapesMap[esc];\n\t\t\t}) : val;\n\t\t};\n\t}\n\n\t/*******************************************************************************************************************\n \tPassage Class.\n *******************************************************************************************************************/\n\n\tvar Passage = function () {\n\t\tfunction Passage(title, el) {\n\t\t\tvar _this19 = this;\n\n\t\t\t_classCallCheck(this, Passage);\n\n\t\t\tObject.defineProperties(this, {\n\t\t\t\t// Passage title/ID.\n\t\t\t\ttitle: {\n\t\t\t\t\tvalue: Util.unescape(title)\n\t\t\t\t},\n\n\t\t\t\t// Passage data element (within the story data element; i.e. T1: '[tiddler]', T2: 'tw-passagedata').\n\t\t\t\telement: {\n\t\t\t\t\tvalue: el || null\n\t\t\t\t},\n\n\t\t\t\t// Passage tags array (sorted and unique).\n\t\t\t\ttags: {\n\t\t\t\t\tvalue: Object.freeze(el && el.hasAttribute('tags') ? el.getAttribute('tags').trim().splitOrEmpty(/\\s+/).sort().filter(function (tag, i, aref) {\n\t\t\t\t\t\treturn i === 0 || aref[i - 1] !== tag;\n\t\t\t\t\t}) : [])\n\t\t\t\t},\n\n\t\t\t\t// Passage excerpt.  Used by the `description()` method.\n\t\t\t\t_excerpt: {\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: null\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// Properties dependant upon the above set.\n\t\t\tObject.defineProperties(this, {\n\t\t\t\t// Passage DOM-compatible ID.\n\t\t\t\tdomId: {\n\t\t\t\t\tvalue: 'passage-' + Util.slugify(this.title)\n\t\t\t\t},\n\n\t\t\t\t// Passage classes array (sorted and unique).\n\t\t\t\tclasses: {\n\t\t\t\t\tvalue: Object.freeze(this.tags.length === 0 ? [] : function () {\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t/*\n       \tReturn the sorted list of unique classes.\n       \t\tNOTE: The `this.tags` array is already sorted and unique,\n       \tso we only need to filter and map here.\n       */\n\t\t\t\t\t\t\t_this19.tags.filter(function (tag) {\n\t\t\t\t\t\t\t\treturn !_tagsToSkip.test(tag);\n\t\t\t\t\t\t\t}).map(function (tag) {\n\t\t\t\t\t\t\t\treturn Util.slugify(tag);\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t);\n\t\t\t\t\t}())\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t// Getters.\n\n\n\t\t_createClass(Passage, [{\n\t\t\tkey: 'description',\n\t\t\tvalue: function description() {\n\t\t\t\tvar descriptions = Config.passages.descriptions;\n\n\t\t\t\tif (descriptions != null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tswitch (typeof descriptions === 'undefined' ? 'undefined' : _typeof(descriptions)) {\n\t\t\t\t\t\tcase 'boolean':\n\t\t\t\t\t\t\tif (descriptions) {\n\t\t\t\t\t\t\t\treturn this.title;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'object':\n\t\t\t\t\t\t\tif (descriptions instanceof Map && descriptions.has(this.title)) {\n\t\t\t\t\t\t\t\treturn descriptions.get(this.title);\n\t\t\t\t\t\t\t} else if (descriptions.hasOwnProperty(this.title)) {\n\t\t\t\t\t\t\t\treturn descriptions[this.title];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tcase 'function':\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tvar result = descriptions.call(this);\n\n\t\t\t\t\t\t\t\tif (result) {\n\t\t\t\t\t\t\t\t\treturn result;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tthrow new TypeError('Config.passages.descriptions must be a boolean, object, or function');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Initialize the excerpt cache from the raw passage text, if necessary.\n\t\t\t\tif (this._excerpt === null) {\n\t\t\t\t\tthis._excerpt = Passage.getExcerptFromText(this.text);\n\t\t\t\t}\n\n\t\t\t\treturn this._excerpt;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'processText',\n\t\t\tvalue: function processText() {\n\t\t\t\tif (this.element == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\treturn this.text;\n\t\t\t\t}\n\n\t\t\t\tvar processed = this.text;\n\n\t\t\t\t// Handle image passage transclusion.\n\t\t\t\tif (this.tags.includes('Twine.image')) {\n\t\t\t\t\tprocessed = '[img[' + processed + ']]';\n\t\t\t\t}\n\n\t\t\t\t// Handle `Config.passages.nobr` and the `nobr` tag.\n\t\t\t\telse if (Config.passages.nobr || this.tags.includes('nobr')) {\n\t\t\t\t\t\t// Remove all leading & trailing newlines and compact all internal sequences\n\t\t\t\t\t\t// of newlines into single spaces.\n\t\t\t\t\t\tprocessed = processed.replace(/^\\n+|\\n+$/g, '').replace(/\\n+/g, ' ');\n\t\t\t\t\t}\n\n\t\t\t\treturn processed;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'render',\n\t\t\tvalue: function render() {\n\t\t\t\tvar _this20 = this;\n\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('[<Passage: \"' + this.title + '\">.render()]');\n\t\t\t\t}\n\n\t\t\t\tvar dataTags = this.tags.length > 0 ? this.tags.join(' ') : null;\n\n\t\t\t\t// Create and set up the new passage element.\n\t\t\t\tvar passageEl = document.createElement('div');\n\t\t\t\tjQuery(passageEl).attr({\n\t\t\t\t\tid: this.domId,\n\t\t\t\t\t'data-passage': this.title,\n\t\t\t\t\t'data-tags': dataTags\n\t\t\t\t}).addClass('passage ' + this.className);\n\n\t\t\t\t// Add the passage's classes and tags to <body>.\n\t\t\t\tjQuery(document.body).attr('data-tags', dataTags).addClass(this.className);\n\n\t\t\t\t// Add the passage's tags to <html>.\n\t\t\t\tjQuery(document.documentElement).attr('data-tags', dataTags);\n\n\t\t\t\t// Execute pre-render events and tasks.\n\t\t\t\tjQuery.event.trigger({\n\t\t\t\t\ttype: ':passagestart',\n\t\t\t\t\tcontent: passageEl,\n\t\t\t\t\tpassage: this\n\t\t\t\t});\n\t\t\t\tObject.keys(prerender).forEach(function (task) {\n\t\t\t\t\tif (typeof prerender[task] === 'function') {\n\t\t\t\t\t\tprerender[task].call(_this20, passageEl, task);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\t// Wikify the PassageHeader passage, if it exists, into the passage element.\n\t\t\t\tif (Story.has('PassageHeader')) {\n\t\t\t\t\tnew Wikifier(passageEl, Story.get('PassageHeader').processText());\n\t\t\t\t}\n\n\t\t\t\t// Wikify the passage into its element.\n\t\t\t\tnew Wikifier(passageEl, this.processText());\n\n\t\t\t\t// Wikify the PassageFooter passage, if it exists, into the passage element.\n\t\t\t\tif (Story.has('PassageFooter')) {\n\t\t\t\t\tnew Wikifier(passageEl, Story.get('PassageFooter').processText());\n\t\t\t\t}\n\n\t\t\t\t// Execute post-render events and tasks.\n\t\t\t\tjQuery.event.trigger({\n\t\t\t\t\ttype: ':passagerender',\n\t\t\t\t\tcontent: passageEl,\n\t\t\t\t\tpassage: this\n\t\t\t\t});\n\t\t\t\tObject.keys(postrender).forEach(function (task) {\n\t\t\t\t\tif (typeof postrender[task] === 'function') {\n\t\t\t\t\t\tpostrender[task].call(_this20, passageEl, task);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\t// Update the excerpt cache to reflect the rendered text.\n\t\t\t\tthis._excerpt = Passage.getExcerptFromNode(passageEl);\n\n\t\t\t\treturn passageEl;\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'className',\n\t\t\tget: function get() {\n\t\t\t\treturn this.classes.join(' ');\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'text',\n\t\t\tget: function get() {\n\t\t\t\tif (this.element == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tvar passage = Util.escape(this.title);\n\t\t\t\t\tvar mesg = L10n.get('errorTitle') + ': ' + L10n.get('errorNonexistentPassage', { passage: passage });\n\t\t\t\t\treturn '<div class=\"error-view\"><span class=\"error\">' + mesg + '</span></div>';\n\t\t\t\t}\n\n\t\t\t\t// For Twine 1\n\t\t\t\tif (TWINE1) {\n\t\t\t\t\treturn _twine1Unescape(this.element.textContent);\n\t\t\t\t}\n\t\t\t\t// For Twine 2\n\t\t\t\telse {\n\t\t\t\t\t\t// eslint-disable-line no-else-return\n\t\t\t\t\t\treturn this.element.textContent.replace(/\\r/g, '');\n\t\t\t\t\t}\n\t\t\t}\n\t\t}], [{\n\t\t\tkey: 'getExcerptFromNode',\n\t\t\tvalue: function getExcerptFromNode(node, count) {\n\t\t\t\tif (!node.hasChildNodes()) {\n\t\t\t\t\treturn '';\n\t\t\t\t}\n\n\t\t\t\tvar excerpt = node.textContent.trim();\n\n\t\t\t\tif (excerpt !== '') {\n\t\t\t\t\tvar excerptRe = new RegExp('(\\\\S+(?:\\\\s+\\\\S+){0,' + (count > 0 ? count - 1 : 7) + '})');\n\t\t\t\t\texcerpt = excerpt\n\t\t\t\t\t// Compact whitespace.\n\t\t\t\t\t.replace(/\\s+/g, ' ')\n\t\t\t\t\t// Attempt to match the excerpt regexp.\n\t\t\t\t\t.match(excerptRe);\n\t\t\t\t}\n\n\t\t\t\treturn excerpt ? excerpt[1] + '\\u2026' : '\\u2026'; // horizontal ellipsis\n\t\t\t}\n\t\t}, {\n\t\t\tkey: 'getExcerptFromText',\n\t\t\tvalue: function getExcerptFromText(text, count) {\n\t\t\t\tif (text === '') {\n\t\t\t\t\treturn '';\n\t\t\t\t}\n\n\t\t\t\tvar excerptRe = new RegExp('(\\\\S+(?:\\\\s+\\\\S+){0,' + (count > 0 ? count - 1 : 7) + '})');\n\t\t\t\tvar excerpt = text\n\t\t\t\t// Strip macro tags (replace with a space).\n\t\t\t\t.replace(/<<.*?>>/g, ' ')\n\t\t\t\t// Strip html tags (replace with a space).\n\t\t\t\t.replace(/<.*?>/g, ' ')\n\t\t\t\t// The above might have left problematic whitespace, so trim.\n\t\t\t\t.trim()\n\t\t\t\t// Strip table markup.\n\t\t\t\t.replace(/^\\s*\\|.*\\|.*?$/gm, '')\n\t\t\t\t// Strip image markup.\n\t\t\t\t.replace(/\\[[<>]?img\\[[^\\]]*\\]\\]/g, '')\n\t\t\t\t// Clean link markup (remove all but the link text).\n\t\t\t\t.replace(/\\[\\[([^|\\]]*?)(?:(?:\\||->|<-)[^\\]]*)?\\]\\]/g, '$1')\n\t\t\t\t// Clean heading markup.\n\t\t\t\t.replace(/^\\s*!+(.*?)$/gm, '$1')\n\t\t\t\t// Clean bold/italic/underline/highlight styles.\n\t\t\t\t.replace(/'{2}|\\/{2}|_{2}|@{2}/g, '')\n\t\t\t\t// A final trim.\n\t\t\t\t.trim()\n\t\t\t\t// Compact whitespace.\n\t\t\t\t.replace(/\\s+/g, ' ')\n\t\t\t\t// Attempt to match the excerpt regexp.\n\t\t\t\t.match(excerptRe);\n\t\t\t\treturn excerpt ? excerpt[1] + '\\u2026' : '\\u2026'; // horizontal ellipsis\n\t\t\t}\n\t\t}]);\n\n\t\treturn Passage;\n\t}();\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\n\n\treturn Passage;\n}();\n\n/***********************************************************************************************************************\n\n\tsave.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Config, Dialog, Engine, L10n, State, Story, UI, Util, storage */\n\nvar Save = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// The upper bound of the saves slots.\n\n\tvar _slotsUBound = -1;\n\n\t/*******************************************************************************************************************\n \tSaves Functions.\n *******************************************************************************************************************/\n\tfunction savesInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Save/savesInit()]');\n\t\t}\n\n\t\t// Disable save slots and the autosave when Web Storage is unavailable.\n\t\tif (storage.name === 'cookie') {\n\t\t\tsavesObjClear();\n\t\t\tConfig.saves.autoload = undefined;\n\t\t\tConfig.saves.autosave = undefined;\n\t\t\tConfig.saves.isAllowed = undefined;\n\t\t\tConfig.saves.onLoad = undefined;\n\t\t\tConfig.saves.onSave = undefined;\n\t\t\tConfig.saves.slots = 0;\n\t\t\treturn false;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\t\tvar updated = false;\n\n\t\t/* legacy */\n\t\t// Convert an ancient saves array into a new saves object.\n\t\tif (Array.isArray(saves)) {\n\t\t\tsaves = {\n\t\t\t\tautosave: null,\n\t\t\t\tslots: saves\n\t\t\t};\n\t\t\tupdated = true;\n\t\t}\n\t\t/* /legacy */\n\n\t\t// Handle the author changing the number of save slots.\n\t\tif (Config.saves.slots !== saves.slots.length) {\n\t\t\tif (Config.saves.slots < saves.slots.length) {\n\t\t\t\t// Attempt to decrease the number of slots; this will only compact\n\t\t\t\t// the slots array, by removing empty slots, no saves will be deleted.\n\t\t\t\tsaves.slots.reverse();\n\n\t\t\t\tsaves.slots = saves.slots.filter(function (val) {\n\t\t\t\t\tif (val === null && this.count > 0) {\n\t\t\t\t\t\t--this.count;\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn true;\n\t\t\t\t}, { count: saves.slots.length - Config.saves.slots });\n\n\t\t\t\tsaves.slots.reverse();\n\t\t\t} else if (Config.saves.slots > saves.slots.length) {\n\t\t\t\t// Attempt to increase the number of slots.\n\t\t\t\t_appendSlots(saves.slots, Config.saves.slots - saves.slots.length);\n\t\t\t}\n\n\t\t\tupdated = true;\n\t\t}\n\n\t\t/* legacy */\n\t\t// Update saves with old/obsolete properties.\n\t\tif (_savesObjUpdate(saves.autosave)) {\n\t\t\tupdated = true;\n\t\t}\n\n\t\tfor (var i = 0; i < saves.slots.length; ++i) {\n\t\t\tif (_savesObjUpdate(saves.slots[i])) {\n\t\t\t\tupdated = true;\n\t\t\t}\n\t\t}\n\n\t\t// Remove save stores which are empty.\n\t\tif (_savesObjIsEmpty(saves)) {\n\t\t\tstorage.delete('saves');\n\t\t\tupdated = false;\n\t\t}\n\t\t/* /legacy */\n\n\t\t// If the saves object was updated, then update the store.\n\t\tif (updated) {\n\t\t\t_savesObjSave(saves);\n\t\t}\n\n\t\t_slotsUBound = saves.slots.length - 1;\n\n\t\treturn true;\n\t}\n\n\tfunction savesObjCreate() {\n\t\treturn {\n\t\t\tautosave: null,\n\t\t\tslots: _appendSlots([], Config.saves.slots)\n\t\t};\n\t}\n\n\tfunction savesObjGet() {\n\t\tvar saves = storage.get('saves');\n\t\treturn saves === null ? savesObjCreate() : saves;\n\t}\n\n\tfunction savesObjClear() {\n\t\tstorage.delete('saves');\n\t\treturn true;\n\t}\n\n\tfunction savesOk() {\n\t\treturn autosaveOk() || slotsOk();\n\t}\n\n\t/*******************************************************************************************************************\n \tAutosave Functions.\n *******************************************************************************************************************/\n\tfunction autosaveOk() {\n\t\treturn storage.name !== 'cookie' && typeof Config.saves.autosave !== 'undefined';\n\t}\n\n\tfunction autosaveHas() {\n\t\tvar saves = savesObjGet();\n\n\t\tif (saves.autosave === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t}\n\n\tfunction autosaveGet() {\n\t\tvar saves = savesObjGet();\n\t\treturn saves.autosave;\n\t}\n\n\tfunction autosaveLoad() {\n\t\tvar saves = savesObjGet();\n\n\t\tif (saves.autosave === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn _unmarshal(saves.autosave);\n\t}\n\n\tfunction autosaveSave(title, metadata) {\n\t\tif (typeof Config.saves.isAllowed === 'function' && !Config.saves.isAllowed()) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\t\tvar supplemental = {\n\t\t\ttitle: title || Story.get(State.passage).description(),\n\t\t\tdate: Date.now()\n\t\t};\n\n\t\tif (metadata != null) {\n\t\t\t// lazy equality for null\n\t\t\tsupplemental.metadata = metadata;\n\t\t}\n\n\t\tsaves.autosave = _marshal(supplemental);\n\n\t\treturn _savesObjSave(saves);\n\t}\n\n\tfunction autosaveDelete() {\n\t\tvar saves = savesObjGet();\n\t\tsaves.autosave = null;\n\t\treturn _savesObjSave(saves);\n\t}\n\n\t/*******************************************************************************************************************\n \tSlots Functions.\n *******************************************************************************************************************/\n\tfunction slotsOk() {\n\t\treturn storage.name !== 'cookie' && _slotsUBound !== -1;\n\t}\n\n\tfunction slotsLength() {\n\t\treturn _slotsUBound + 1;\n\t}\n\n\tfunction slotsCount() {\n\t\tif (!slotsOk()) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\t\tvar count = 0;\n\n\t\tfor (var i = 0, iend = saves.slots.length; i < iend; ++i) {\n\t\t\tif (saves.slots[i] !== null) {\n\t\t\t\t++count;\n\t\t\t}\n\t\t}\n\t\treturn count;\n\t}\n\n\tfunction slotsIsEmpty() {\n\t\treturn slotsCount() === 0;\n\t}\n\n\tfunction slotsHas(slot) {\n\t\tif (slot < 0 || slot > _slotsUBound) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\n\t\tif (slot >= saves.slots.length || saves.slots[slot] === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t}\n\n\tfunction slotsGet(slot) {\n\t\tif (slot < 0 || slot > _slotsUBound) {\n\t\t\treturn null;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\n\t\tif (slot >= saves.slots.length) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn saves.slots[slot];\n\t}\n\n\tfunction slotsLoad(slot) {\n\t\tif (slot < 0 || slot > _slotsUBound) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\n\t\tif (slot >= saves.slots.length || saves.slots[slot] === null) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn _unmarshal(saves.slots[slot]);\n\t}\n\n\tfunction slotsSave(slot, title, metadata) {\n\t\tif (typeof Config.saves.isAllowed === 'function' && !Config.saves.isAllowed()) {\n\t\t\tif (Dialog.isOpen()) {\n\t\t\t\t$(document).one(':dialogclosed', function () {\n\t\t\t\t\treturn UI.alert(L10n.get('savesDisallowed'));\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tUI.alert(L10n.get('savesDisallowed'));\n\t\t\t}\n\n\t\t\treturn false;\n\t\t}\n\n\t\tif (slot < 0 || slot > _slotsUBound) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\n\t\tif (slot >= saves.slots.length) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar supplemental = {\n\t\t\ttitle: title || Story.get(State.passage).description(),\n\t\t\tdate: Date.now()\n\t\t};\n\n\t\tif (metadata != null) {\n\t\t\t// lazy equality for null\n\t\t\tsupplemental.metadata = metadata;\n\t\t}\n\n\t\tsaves.slots[slot] = _marshal(supplemental);\n\n\t\treturn _savesObjSave(saves);\n\t}\n\n\tfunction slotsDelete(slot) {\n\t\tif (slot < 0 || slot > _slotsUBound) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar saves = savesObjGet();\n\n\t\tif (slot >= saves.slots.length) {\n\t\t\treturn false;\n\t\t}\n\n\t\tsaves.slots[slot] = null;\n\t\treturn _savesObjSave(saves);\n\t}\n\n\t/*******************************************************************************************************************\n \tDisk Import/Export Functions.\n *******************************************************************************************************************/\n\tfunction exportToDisk(filename, metadata) {\n\t\tif (typeof Config.saves.isAllowed === 'function' && !Config.saves.isAllowed()) {\n\t\t\tif (Dialog.isOpen()) {\n\t\t\t\t$(document).one(':dialogclosed', function () {\n\t\t\t\t\treturn UI.alert(L10n.get('savesDisallowed'));\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tUI.alert(L10n.get('savesDisallowed'));\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tfunction datestamp() {\n\t\t\tvar now = new Date();\n\t\t\tvar MM = now.getMonth() + 1;\n\t\t\tvar DD = now.getDate();\n\t\t\tvar hh = now.getHours();\n\t\t\tvar mm = now.getMinutes();\n\t\t\tvar ss = now.getSeconds();\n\n\t\t\tif (MM < 10) {\n\t\t\t\tMM = '0' + MM;\n\t\t\t}\n\t\t\tif (DD < 10) {\n\t\t\t\tDD = '0' + DD;\n\t\t\t}\n\t\t\tif (hh < 10) {\n\t\t\t\thh = '0' + hh;\n\t\t\t}\n\t\t\tif (mm < 10) {\n\t\t\t\tmm = '0' + mm;\n\t\t\t}\n\t\t\tif (ss < 10) {\n\t\t\t\tss = '0' + ss;\n\t\t\t}\n\n\t\t\treturn '' + now.getFullYear() + MM + DD + '-' + hh + mm + ss;\n\t\t}\n\n\t\tvar baseName = filename == null ? Story.domId : Util.slugify(filename); // lazy equality for null\n\t\tvar saveName = baseName + '-' + datestamp() + '.save';\n\t\tvar supplemental = metadata == null ? {} : { metadata: metadata }; // lazy equality for null\n\t\tvar saveObj = LZString.compressToBase64(JSON.stringify(_marshal(supplemental)));\n\t\tsaveAs(new Blob([saveObj], { type: 'text/plain;charset=UTF-8' }), saveName);\n\t}\n\n\tfunction importFromDisk(event) {\n\t\tvar file = event.target.files[0];\n\t\tvar reader = new FileReader();\n\n\t\t// Add the handler that will capture the file information once the load is finished.\n\t\tjQuery(reader).on('load', function (ev) {\n\t\t\tvar target = ev.currentTarget;\n\n\t\t\tif (!target.result) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar saveObj = void 0;\n\n\t\t\ttry {\n\t\t\t\tsaveObj = JSON.parse(/\\.json$/i.test(file.name) || /^\\{/.test(target.result) ? target.result : LZString.decompressFromBase64(target.result));\n\t\t\t} catch (ex) {/* no-op; `_unmarshal()` will handle the error */}\n\n\t\t\t_unmarshal(saveObj);\n\t\t});\n\n\t\t// Initiate the file load.\n\t\treader.readAsText(file);\n\t}\n\n\t/*******************************************************************************************************************\n \tSerialization Functions.\n *******************************************************************************************************************/\n\tfunction serialize(metadata) {\n\t\tif (typeof Config.saves.isAllowed === 'function' && !Config.saves.isAllowed()) {\n\t\t\tif (Dialog.isOpen()) {\n\t\t\t\t$(document).one(':dialogclosed', function () {\n\t\t\t\t\treturn UI.alert(L10n.get('savesDisallowed'));\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tUI.alert(L10n.get('savesDisallowed'));\n\t\t\t}\n\n\t\t\treturn null;\n\t\t}\n\n\t\tvar supplemental = metadata == null ? {} : { metadata: metadata }; // lazy equality for null\n\t\treturn LZString.compressToBase64(JSON.stringify(_marshal(supplemental)));\n\t}\n\n\tfunction deserialize(base64Str) {\n\t\t/*\n  \tNOTE: We purposefully do not attempt to catch parameter shenanigans\n  \there, instead relying on `_unmarshal()` to do the heavy lifting.\n  */\n\n\t\tvar saveObj = void 0;\n\n\t\ttry {\n\t\t\tsaveObj = JSON.parse(LZString.decompressFromBase64(base64Str));\n\t\t} catch (ex) {/* no-op; `_unmarshal()` will handle the error */}\n\n\t\tif (!_unmarshal(saveObj)) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn saveObj.metadata;\n\t}\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\tfunction _appendSlots(array, num) {\n\t\tfor (var i = 0; i < num; ++i) {\n\t\t\tarray.push(null);\n\t\t}\n\n\t\treturn array;\n\t}\n\n\tfunction _savesObjIsEmpty(saves) {\n\t\tvar slots = saves.slots;\n\t\tvar isSlotsEmpty = true;\n\n\t\tfor (var i = 0, iend = slots.length; i < iend; ++i) {\n\t\t\tif (slots[i] !== null) {\n\t\t\t\tisSlotsEmpty = false;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\treturn saves.autosave === null && isSlotsEmpty;\n\t}\n\n\tfunction _savesObjSave(saves) {\n\t\tif (_savesObjIsEmpty(saves)) {\n\t\t\tstorage.delete('saves');\n\t\t\treturn true;\n\t\t}\n\n\t\treturn storage.set('saves', saves);\n\t}\n\n\tfunction _savesObjUpdate(saveObj) {\n\t\tif (saveObj == null || (typeof saveObj === 'undefined' ? 'undefined' : _typeof(saveObj)) !== 'object') {\n\t\t\t// lazy equality for null\n\t\t\treturn false;\n\t\t}\n\n\t\tvar updated = false;\n\n\t\t/* eslint-disable no-param-reassign */\n\t\tif (!saveObj.hasOwnProperty('state') || !saveObj.state.hasOwnProperty('delta') || !saveObj.state.hasOwnProperty('index')) {\n\t\t\tif (saveObj.hasOwnProperty('data')) {\n\t\t\t\tdelete saveObj.mode;\n\t\t\t\tsaveObj.state = {\n\t\t\t\t\tdelta: State.deltaEncode(saveObj.data)\n\t\t\t\t};\n\t\t\t\tdelete saveObj.data;\n\t\t\t} else if (!saveObj.state.hasOwnProperty('delta')) {\n\t\t\t\tdelete saveObj.state.mode;\n\t\t\t\tsaveObj.state.delta = State.deltaEncode(saveObj.state.history);\n\t\t\t\tdelete saveObj.state.history;\n\t\t\t} else if (!saveObj.state.hasOwnProperty('index')) {\n\t\t\t\tdelete saveObj.state.mode;\n\t\t\t}\n\n\t\t\tsaveObj.state.index = saveObj.state.delta.length - 1;\n\t\t\tupdated = true;\n\t\t}\n\n\t\tif (saveObj.state.hasOwnProperty('rseed')) {\n\t\t\tsaveObj.state.seed = saveObj.state.rseed;\n\t\t\tdelete saveObj.state.rseed;\n\n\t\t\tsaveObj.state.delta.forEach(function (_, i, delta) {\n\t\t\t\tif (delta[i].hasOwnProperty('rcount')) {\n\t\t\t\t\tdelta[i].pull = delta[i].rcount;\n\t\t\t\t\tdelete delta[i].rcount;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tupdated = true;\n\t\t}\n\n\t\tif (saveObj.state.hasOwnProperty('expired') && typeof saveObj.state.expired === 'number' || saveObj.state.hasOwnProperty('unique') || saveObj.state.hasOwnProperty('last')) {\n\t\t\tif (saveObj.state.hasOwnProperty('expired') && typeof saveObj.state.expired === 'number') {\n\t\t\t\tdelete saveObj.state.expired;\n\t\t\t}\n\n\t\t\tif (saveObj.state.hasOwnProperty('unique') || saveObj.state.hasOwnProperty('last')) {\n\t\t\t\tsaveObj.state.expired = [];\n\n\t\t\t\tif (saveObj.state.hasOwnProperty('unique')) {\n\t\t\t\t\tsaveObj.state.expired.push(saveObj.state.unique);\n\t\t\t\t\tdelete saveObj.state.unique;\n\t\t\t\t}\n\n\t\t\t\tif (saveObj.state.hasOwnProperty('last')) {\n\t\t\t\t\tsaveObj.state.expired.push(saveObj.state.last);\n\t\t\t\t\tdelete saveObj.state.last;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tupdated = true;\n\t\t}\n\t\t/* eslint-enable no-param-reassign */\n\n\t\treturn updated;\n\t}\n\n\tfunction _marshal(supplemental) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Save/_marshal()]');\n\t\t}\n\n\t\tif (supplemental != null && (typeof supplemental === 'undefined' ? 'undefined' : _typeof(supplemental)) !== 'object') {\n\t\t\t// lazy equality for null\n\t\t\tthrow new Error('supplemental parameter must be an object');\n\t\t}\n\n\t\tvar saveObj = Object.assign({}, supplemental, {\n\t\t\tid: Config.saves.id,\n\t\t\tstate: State.marshalForSave()\n\t\t});\n\n\t\tif (Config.saves.version) {\n\t\t\tsaveObj.version = Config.saves.version;\n\t\t}\n\n\t\tif (typeof Config.saves.onSave === 'function') {\n\t\t\tConfig.saves.onSave(saveObj);\n\t\t}\n\n\t\t// Delta encode the state history and delete the non-encoded property.\n\t\tsaveObj.state.delta = State.deltaEncode(saveObj.state.history);\n\t\tdelete saveObj.state.history;\n\n\t\treturn saveObj;\n\t}\n\n\tfunction _unmarshal(saveObj) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Save/_unmarshal()]');\n\t\t}\n\n\t\ttry {\n\t\t\t/* eslint-disable no-param-reassign */\n\t\t\t/* legacy */\n\t\t\t// Update saves with old/obsolete properties.\n\t\t\t_savesObjUpdate(saveObj);\n\t\t\t/* /legacy */\n\n\t\t\tif (!saveObj || !saveObj.hasOwnProperty('id') || !saveObj.hasOwnProperty('state')) {\n\t\t\t\tthrow new Error(L10n.get('errorSaveMissingData'));\n\t\t\t}\n\n\t\t\t// Delta decode the state history and delete the encoded property.\n\t\t\tsaveObj.state.history = State.deltaDecode(saveObj.state.delta);\n\t\t\tdelete saveObj.state.delta;\n\n\t\t\tif (typeof Config.saves.onLoad === 'function') {\n\t\t\t\tConfig.saves.onLoad(saveObj);\n\t\t\t}\n\n\t\t\tif (saveObj.id !== Config.saves.id) {\n\t\t\t\tthrow new Error(L10n.get('errorSaveIdMismatch'));\n\t\t\t}\n\n\t\t\t// Restore the state.\n\t\t\tState.unmarshalForSave(saveObj.state); // may also throw exceptions\n\n\t\t\t// Show the active moment.\n\t\t\tEngine.show();\n\t\t\t/* eslint-enable no-param-reassign */\n\t\t} catch (ex) {\n\t\t\tUI.alert(ex.message.toUpperFirst() + '.</p><p>' + L10n.get('aborting') + '.');\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tSave Functions.\n  */\n\t\tinit: { value: savesInit },\n\t\tget: { value: savesObjGet },\n\t\tclear: { value: savesObjClear },\n\t\tok: { value: savesOk },\n\n\t\t/*\n  \tAutosave Functions.\n  */\n\t\tautosave: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tok: { value: autosaveOk },\n\t\t\t\thas: { value: autosaveHas },\n\t\t\t\tget: { value: autosaveGet },\n\t\t\t\tload: { value: autosaveLoad },\n\t\t\t\tsave: { value: autosaveSave },\n\t\t\t\tdelete: { value: autosaveDelete }\n\t\t\t}))\n\t\t},\n\n\t\t/*\n  \tSlots Functions.\n  */\n\t\tslots: {\n\t\t\tvalue: Object.freeze(Object.defineProperties({}, {\n\t\t\t\tok: { value: slotsOk },\n\t\t\t\tlength: { get: slotsLength },\n\t\t\t\tisEmpty: { value: slotsIsEmpty },\n\t\t\t\tcount: { value: slotsCount },\n\t\t\t\thas: { value: slotsHas },\n\t\t\t\tget: { value: slotsGet },\n\t\t\t\tload: { value: slotsLoad },\n\t\t\t\tsave: { value: slotsSave },\n\t\t\t\tdelete: { value: slotsDelete }\n\t\t\t}))\n\t\t},\n\n\t\t/*\n  \tDisk Import/Export Functions.\n  */\n\t\texport: { value: exportToDisk },\n\t\timport: { value: importFromDisk },\n\n\t\t/*\n  \tSerialization Functions.\n  */\n\t\tserialize: { value: serialize },\n\t\tdeserialize: { value: deserialize }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tsetting.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Util, settings:true, storage */\n\nvar Setting = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Setting definition array.\n\n\tvar _definitions = [];\n\n\t// Setting control types object (pseudo-enumeration).\n\tvar Types = Util.toEnum({\n\t\tHeader: 0,\n\t\tToggle: 1,\n\t\tList: 2,\n\t\tRange: 3\n\t});\n\n\t/*******************************************************************************************************************\n \tSettings Functions.\n *******************************************************************************************************************/\n\tfunction settingsInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Setting/settingsInit()]');\n\t\t}\n\n\t\t/* legacy */\n\t\t// Attempt to migrate an existing `options` store to `settings`.\n\t\tif (storage.has('options')) {\n\t\t\tvar old = storage.get('options');\n\n\t\t\tif (old !== null) {\n\t\t\t\twindow.SugarCube.settings = settings = Object.assign(settingsCreate(), old);\n\t\t\t}\n\n\t\t\tsettingsSave();\n\t\t\tstorage.delete('options');\n\t\t}\n\t\t/* /legacy */\n\n\t\t// Load existing settings.\n\t\tsettingsLoad();\n\n\t\t// Execute `onInit` callbacks.\n\t\t_definitions.forEach(function (def) {\n\t\t\tif (def.hasOwnProperty('onInit')) {\n\t\t\t\tvar thisArg = {\n\t\t\t\t\tname: def.name,\n\t\t\t\t\tvalue: settings[def.name],\n\t\t\t\t\tdefault: def.default\n\t\t\t\t};\n\n\t\t\t\tif (def.hasOwnProperty('list')) {\n\t\t\t\t\tthisArg.list = def.list;\n\t\t\t\t}\n\n\t\t\t\tdef.onInit.call(thisArg);\n\t\t\t}\n\t\t});\n\t}\n\n\tfunction settingsCreate() {\n\t\treturn Object.create(null);\n\t}\n\n\tfunction settingsSave() {\n\t\tvar savedSettings = settingsCreate();\n\n\t\tif (Object.keys(settings).length > 0) {\n\t\t\t_definitions.filter(function (def) {\n\t\t\t\treturn def.type !== Types.Header && settings[def.name] !== def.default;\n\t\t\t}).forEach(function (def) {\n\t\t\t\treturn savedSettings[def.name] = settings[def.name];\n\t\t\t});\n\t\t}\n\n\t\tif (Object.keys(savedSettings).length === 0) {\n\t\t\tstorage.delete('settings');\n\t\t\treturn true;\n\t\t}\n\n\t\treturn storage.set('settings', savedSettings);\n\t}\n\n\tfunction settingsLoad() {\n\t\tvar defaultSettings = settingsCreate();\n\t\tvar loadedSettings = storage.get('settings') || settingsCreate();\n\n\t\t// Load the defaults.\n\t\t_definitions.filter(function (def) {\n\t\t\treturn def.type !== Types.Header;\n\t\t}).forEach(function (def) {\n\t\t\treturn defaultSettings[def.name] = def.default;\n\t\t});\n\n\t\t// Assign to the `settings` object while overwriting the defaults with the loaded settings.\n\t\twindow.SugarCube.settings = settings = Object.assign(defaultSettings, loadedSettings);\n\t}\n\n\tfunction settingsClear() {\n\t\twindow.SugarCube.settings = settings = settingsCreate();\n\t\tstorage.delete('settings');\n\t\treturn true;\n\t}\n\n\tfunction settingsReset(name) {\n\t\tif (arguments.length === 0) {\n\t\t\tsettingsClear();\n\t\t\tsettingsLoad();\n\t\t} else {\n\t\t\tif (name == null || !definitionsHas(name)) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tthrow new Error('nonexistent setting \"' + name + '\"');\n\t\t\t}\n\n\t\t\tvar def = definitionsGet(name);\n\n\t\t\tif (def.type !== Types.Header) {\n\t\t\t\tsettings[name] = def.default;\n\t\t\t}\n\t\t}\n\n\t\treturn settingsSave();\n\t}\n\n\t/*******************************************************************************************************************\n \tDefinitions Functions.\n *******************************************************************************************************************/\n\tfunction definitionsForEach(callback, thisArg) {\n\t\t_definitions.forEach(callback, thisArg);\n\t}\n\n\tfunction definitionsAdd(type, name, def) {\n\t\tif (arguments.length < 3) {\n\t\t\tvar errors = [];\n\t\t\tif (arguments.length < 1) {\n\t\t\t\terrors.push('type');\n\t\t\t}\n\t\t\tif (arguments.length < 2) {\n\t\t\t\terrors.push('name');\n\t\t\t}\n\t\t\tif (arguments.length < 3) {\n\t\t\t\terrors.push('definition');\n\t\t\t}\n\t\t\tthrow new Error('missing parameters, no ' + errors.join(' or ') + ' specified');\n\t\t}\n\n\t\tif ((typeof def === 'undefined' ? 'undefined' : _typeof(def)) !== 'object') {\n\t\t\tthrow new TypeError('definition parameter must be an object');\n\t\t}\n\n\t\tif (definitionsHas(name)) {\n\t\t\tthrow new Error('cannot clobber existing setting \"' + name + '\"');\n\t\t}\n\n\t\t/*\n  \tDefinition object properties and types:\n  \t\ttype      →  (all)   → Setting.Types\n  \t\tname      →  (all)   → string\n  \t\tlabel     →  (all)   → string\n  \t\tdesc      →  (all)   → string\n  \t\tdefault\n  \t\t\t(if defined)\n  \t\t\t\t\t  →  Toggle  → boolean\n  \t\t\t\t  →  List    → Array\n  \t\t\t\t  →  Range   → number\n  \t\t\t(if undefined)\n  \t\t\t\t  →  Toggle  → false\n  \t\t\t\t  →  List    → list[0]\n  \t\t\t\t  →  Range   → max\n  \t\tlist      →  List    → Array\n  \t\tmin       →  Range   → number\n  \t\tmax       →  Range   → number\n  \t\tstep      →  Range   → number\n  \t\tonInit    →  (all)   → function\n  \t\tonChange  →  (all)   → function\n  */\n\t\tvar definition = {\n\t\t\ttype: type,\n\t\t\tname: name,\n\t\t\tlabel: typeof def.label === 'string' ? def.label.trim() : ''\n\t\t};\n\n\t\tif (typeof def.desc === 'string') {\n\t\t\tvar desc = def.desc.trim();\n\n\t\t\tif (desc !== '') {\n\t\t\t\tdefinition.desc = desc;\n\t\t\t}\n\t\t}\n\n\t\tswitch (type) {\n\t\t\tcase Types.Header:\n\t\t\t\tbreak;\n\n\t\t\tcase Types.Toggle:\n\t\t\t\tdefinition.default = !!def.default;\n\t\t\t\tbreak;\n\n\t\t\tcase Types.List:\n\t\t\t\tif (!def.hasOwnProperty('list')) {\n\t\t\t\t\tthrow new Error('no list specified');\n\t\t\t\t} else if (!Array.isArray(def.list)) {\n\t\t\t\t\tthrow new TypeError('list must be an array');\n\t\t\t\t} else if (def.list.length === 0) {\n\t\t\t\t\tthrow new Error('list must not be empty');\n\t\t\t\t}\n\n\t\t\t\tdefinition.list = Object.freeze(def.list);\n\n\t\t\t\tif (def.default == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tdefinition.default = def.list[0];\n\t\t\t\t} else {\n\t\t\t\t\tvar defaultIndex = def.list.indexOf(def.default);\n\n\t\t\t\t\tif (defaultIndex === -1) {\n\t\t\t\t\t\tthrow new Error('list does not contain default');\n\t\t\t\t\t}\n\n\t\t\t\t\tdefinition.default = def.list[defaultIndex];\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase Types.Range:\n\t\t\t\tif (!def.hasOwnProperty('min')) {\n\t\t\t\t\tthrow new Error('no min specified');\n\t\t\t\t} else if (typeof def.min !== 'number' || Number.isNaN(def.min) || !Number.isFinite(def.min)) {\n\t\t\t\t\tthrow new TypeError('min must be a finite number');\n\t\t\t\t}\n\n\t\t\t\tif (!def.hasOwnProperty('max')) {\n\t\t\t\t\tthrow new Error('no max specified');\n\t\t\t\t} else if (typeof def.max !== 'number' || Number.isNaN(def.max) || !Number.isFinite(def.max)) {\n\t\t\t\t\tthrow new TypeError('max must be a finite number');\n\t\t\t\t}\n\n\t\t\t\tif (!def.hasOwnProperty('step')) {\n\t\t\t\t\tthrow new Error('no step specified');\n\t\t\t\t} else if (typeof def.step !== 'number' || Number.isNaN(def.step) || !Number.isFinite(def.step) || def.step <= 0) {\n\t\t\t\t\tthrow new TypeError('step must be a finite number greater than zero');\n\t\t\t\t} else {\n\n\t\t\t\t\t// Set up a function to validate a given value against the step value.\n\t\t\t\t\tvar stepValidate = function stepValidate(value) {\n\t\t\t\t\t\tif (fracDigits > 0) {\n\t\t\t\t\t\t\tvar ma = Number(def.min + 'e' + fracDigits);\n\t\t\t\t\t\t\tvar sa = Number(def.step + 'e' + fracDigits);\n\t\t\t\t\t\t\tvar _va = Number(value + 'e' + fracDigits) - ma;\n\t\t\t\t\t\t\treturn Number(_va - _va % sa + ma + 'e-' + fracDigits);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tvar va = value - def.min;\n\t\t\t\t\t\treturn va - va % def.step + def.min;\n\t\t\t\t\t};\n\n\t\t\t\t\t// Sanity check the max value against the step value.\n\n\n\t\t\t\t\t// Determine how many fractional digits we need to be concerned with based on the step value.\n\t\t\t\t\tvar fracDigits = function () {\n\t\t\t\t\t\tvar str = String(def.step);\n\t\t\t\t\t\tvar pos = str.lastIndexOf('.');\n\t\t\t\t\t\treturn pos === -1 ? 0 : str.length - pos - 1;\n\t\t\t\t\t}();if (stepValidate(def.max) !== def.max) {\n\t\t\t\t\t\tthrow new RangeError('max (' + def.max + ') is not a multiple of the step (' + def.step + ') plus the min (' + def.min + ')');\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tdefinition.max = def.max;\n\t\t\t\tdefinition.min = def.min;\n\t\t\t\tdefinition.step = def.step;\n\n\t\t\t\tif (def.default == null) {\n\t\t\t\t\t// lazy equality for null\n\t\t\t\t\tdefinition.default = def.max;\n\t\t\t\t} else {\n\t\t\t\t\tif (typeof def.default !== 'number' || Number.isNaN(def.default) || !Number.isFinite(def.default)) {\n\t\t\t\t\t\tthrow new TypeError('default must be a finite number');\n\t\t\t\t\t} else if (def.default < def.min) {\n\t\t\t\t\t\tthrow new RangeError('default (' + def.default + ') is less than min (' + def.min + ')');\n\t\t\t\t\t} else if (def.default > def.max) {\n\t\t\t\t\t\tthrow new RangeError('default (' + def.default + ') is greater than max (' + def.max + ')');\n\t\t\t\t\t}\n\n\t\t\t\t\tdefinition.default = def.default;\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tthrow new Error('unknown Setting type: ' + type);\n\t\t}\n\n\t\tif (typeof def.onInit === 'function') {\n\t\t\tdefinition.onInit = Object.freeze(def.onInit);\n\t\t}\n\n\t\tif (typeof def.onChange === 'function') {\n\t\t\tdefinition.onChange = Object.freeze(def.onChange);\n\t\t}\n\n\t\t_definitions.push(Object.freeze(definition));\n\t}\n\n\tfunction definitionsAddHeader(name, desc) {\n\t\tdefinitionsAdd(Types.Header, name, { desc: desc });\n\t}\n\n\tfunction definitionsAddToggle() {\n\t\tfor (var _len16 = arguments.length, args = Array(_len16), _key16 = 0; _key16 < _len16; _key16++) {\n\t\t\targs[_key16] = arguments[_key16];\n\t\t}\n\n\t\tdefinitionsAdd.apply(undefined, [Types.Toggle].concat(args));\n\t}\n\n\tfunction definitionsAddList() {\n\t\tfor (var _len17 = arguments.length, args = Array(_len17), _key17 = 0; _key17 < _len17; _key17++) {\n\t\t\targs[_key17] = arguments[_key17];\n\t\t}\n\n\t\tdefinitionsAdd.apply(undefined, [Types.List].concat(args));\n\t}\n\n\tfunction definitionsAddRange() {\n\t\tfor (var _len18 = arguments.length, args = Array(_len18), _key18 = 0; _key18 < _len18; _key18++) {\n\t\t\targs[_key18] = arguments[_key18];\n\t\t}\n\n\t\tdefinitionsAdd.apply(undefined, [Types.Range].concat(args));\n\t}\n\n\tfunction definitionsIsEmpty() {\n\t\treturn _definitions.length === 0;\n\t}\n\n\tfunction definitionsHas(name) {\n\t\treturn _definitions.some(function (definition) {\n\t\t\treturn definition.name === name;\n\t\t});\n\t}\n\n\tfunction definitionsGet(name) {\n\t\treturn _definitions.find(function (definition) {\n\t\t\treturn definition.name === name;\n\t\t});\n\t}\n\n\tfunction definitionsDelete(name) {\n\t\tif (definitionsHas(name)) {\n\t\t\tdelete settings[name];\n\t\t}\n\n\t\tfor (var i = 0; i < _definitions.length; ++i) {\n\t\t\tif (_definitions[i].name === name) {\n\t\t\t\t_definitions.splice(i, 1);\n\t\t\t\tdefinitionsDelete(name);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tEnumerations.\n  */\n\t\tTypes: { value: Types },\n\n\t\t/*\n  \tSettings Functions.\n  */\n\t\tinit: { value: settingsInit },\n\t\tcreate: { value: settingsCreate },\n\t\tsave: { value: settingsSave },\n\t\tload: { value: settingsLoad },\n\t\tclear: { value: settingsClear },\n\t\treset: { value: settingsReset },\n\n\t\t/*\n  \tDefinitions Functions.\n  */\n\t\tforEach: { value: definitionsForEach },\n\t\tadd: { value: definitionsAdd },\n\t\taddHeader: { value: definitionsAddHeader },\n\t\taddToggle: { value: definitionsAddToggle },\n\t\taddList: { value: definitionsAddList },\n\t\taddRange: { value: definitionsAddRange },\n\t\tisEmpty: { value: definitionsIsEmpty },\n\t\thas: { value: definitionsHas },\n\t\tget: { value: definitionsGet },\n\t\tdelete: { value: definitionsDelete }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tstory.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Alert, Config, Passage, Scripting, StyleWrapper, Util, Wikifier */\n\nvar Story = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Map of normal passages.\n\n\tvar _passages = {};\n\n\t// List of style passages.\n\tvar _styles = [];\n\n\t// List of script passages.\n\tvar _scripts = [];\n\n\t// List of widget passages.\n\tvar _widgets = [];\n\n\t// Story title.\n\tvar _title = '';\n\n\t// Story IFID.\n\tvar _ifId = '';\n\n\t// DOM-compatible ID.\n\tvar _domId = '';\n\n\t/*******************************************************************************************************************\n \tStory Functions.\n *******************************************************************************************************************/\n\tfunction storyLoad() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Story/storyLoad()]');\n\t\t}\n\n\t\tvar validationCodeTags = ['widget'];\n\t\tvar validationNoCodeTagPassages = ['PassageDone', 'PassageFooter', 'PassageHeader', 'PassageReady', 'StoryAuthor', 'StoryBanner', 'StoryCaption', 'StoryInit', 'StoryMenu', 'StoryShare', 'StorySubtitle'];\n\n\t\tfunction validateStartingPassage(passage) {\n\t\t\tif (passage.tags.includesAny(validationCodeTags)) {\n\t\t\t\tthrow new Error('starting passage \"' + passage.title + '\" contains illegal tags; invalid: \"' + passage.tags.filter(function (tag) {\n\t\t\t\t\treturn validationCodeTags.includes(tag);\n\t\t\t\t}).sort().join('\", \"') + '\"');\n\t\t\t}\n\t\t}\n\n\t\tfunction validateSpecialPassages(passage) {\n\t\t\tif (validationNoCodeTagPassages.includes(passage.title) && passage.tags.includesAny(validationCodeTags)) {\n\t\t\t\tthrow new Error('special passage \"' + passage.title + '\" contains illegal tags; invalid: \"' + passage.tags.filter(function (tag) {\n\t\t\t\t\treturn validationCodeTags.includes(tag);\n\t\t\t\t}).sort().join('\", \"') + '\"');\n\t\t\t}\n\t\t}\n\n\t\t// For Twine 1.\n\t\tif (TWINE1) {\n\t\t\tvar validateTwine1CodePassages = function validateTwine1CodePassages(passage) {\n\t\t\t\tvar codeTags = [].concat(validationCodeTags);\n\t\t\t\tvar foundTags = [];\n\n\t\t\t\tpassage.tags.forEach(function (tag) {\n\t\t\t\t\tif (codeTags.includes(tag)) {\n\t\t\t\t\t\tfoundTags.push.apply(foundTags, _toConsumableArray(codeTags.delete(tag)));\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tif (foundTags.length > 1) {\n\t\t\t\t\tthrow new Error('code passage \"' + passage.title + '\" contains multiple code tags; invalid: \"' + foundTags.sort().join('\", \"') + '\"');\n\t\t\t\t}\n\t\t\t};\n\n\t\t\t/*\n   \tSet the default starting passage.\n   */\n\n\n\t\t\t/*\n   \tAdditional Twine 1 validation setup.\n   */\n\t\t\tvalidationCodeTags.unshift('script', 'stylesheet');\n\t\t\tvalidationNoCodeTagPassages.push('StoryTitle');\n\n\t\t\tConfig.passages.start = function () {\n\t\t\t\t/*\n    \tHandle the Twine 1.4+ Test Play From Here feature.\n    \t\tWARNING: Do not remove the `String()` wrapper from or change the quote\n    \tstyle of the `\"START_AT\"` replacement target.  The former is there to\n    \tkeep UglifyJS from pruning the code into oblivion—i.e. minifying the\n    \tcode into something broken.  The latter is there because the Twine 1\n    \tpattern that matches it depends upon the double quotes.\n    \t*/\n\t\t\t\tvar testPlay = String(\"START_AT\"); // eslint-disable-line quotes\n\n\t\t\t\tif (testPlay !== '') {\n\t\t\t\t\tif (DEBUG) {\n\t\t\t\t\t\tconsole.log('\\tTest play; starting passage: \"' + testPlay + '\"');\n\t\t\t\t\t}\n\n\t\t\t\t\tConfig.debug = true;\n\t\t\t\t\treturn testPlay;\n\t\t\t\t}\n\n\t\t\t\t// In the absence of a `testPlay` value, return 'Start'.\n\t\t\t\treturn 'Start';\n\t\t\t}();\n\n\t\t\t/*\n   \tProcess the passages, excluding any tagged 'Twine.private' or 'annotation'.\n   */\n\t\t\tjQuery('#store-area').children(':not([tags~=\"Twine.private\"],[tags~=\"annotation\"])').each(function () {\n\t\t\t\tvar $this = jQuery(this);\n\t\t\t\tvar passage = new Passage($this.attr('tiddler'), this);\n\n\t\t\t\t// Special cases.\n\t\t\t\tif (passage.title === Config.passages.start) {\n\t\t\t\t\tvalidateStartingPassage(passage);\n\t\t\t\t\t_passages[passage.title] = passage;\n\t\t\t\t} else if (passage.tags.includes('stylesheet')) {\n\t\t\t\t\tvalidateTwine1CodePassages(passage);\n\t\t\t\t\t_styles.push(passage);\n\t\t\t\t} else if (passage.tags.includes('script')) {\n\t\t\t\t\tvalidateTwine1CodePassages(passage);\n\t\t\t\t\t_scripts.push(passage);\n\t\t\t\t} else if (passage.tags.includes('widget')) {\n\t\t\t\t\tvalidateTwine1CodePassages(passage);\n\t\t\t\t\t_widgets.push(passage);\n\t\t\t\t}\n\n\t\t\t\t// All other passages.\n\t\t\t\telse {\n\t\t\t\t\t\tvalidateSpecialPassages(passage);\n\t\t\t\t\t\t_passages[passage.title] = passage;\n\t\t\t\t\t}\n\t\t\t});\n\n\t\t\t/*\n   \tSet the story title or throw an exception.\n   */\n\t\t\tif (_passages.hasOwnProperty('StoryTitle')) {\n\t\t\t\tvar buf = document.createDocumentFragment();\n\t\t\t\tnew Wikifier(buf, _passages.StoryTitle.processText().trim());\n\t\t\t\t_storySetTitle(buf.textContent.trim());\n\t\t\t} else {\n\t\t\t\tthrow new Error('cannot find the \"StoryTitle\" special passage');\n\t\t\t}\n\n\t\t\t/*\n   \tSet the default saves ID (must be done after the call to `_storySetTitle()`).\n   */\n\t\t\tConfig.saves.id = Story.domId;\n\t\t}\n\n\t\t// For Twine 2.\n\t\telse {\n\t\t\t\tvar $storydata = jQuery('tw-storydata');\n\t\t\t\tvar startNode = $storydata.attr('startnode') || '';\n\n\t\t\t\t/*\n    \tSet the default starting passage.\n    */\n\t\t\t\tConfig.passages.start = null; // no default in Twine 2\n\n\t\t\t\t/*\n    \tProcess story options.\n    \t\tNOTE: Currently, the only option of interest is 'debug', so we\n    \tsimply use a regular expression to check for it.\n    */\n\t\t\t\tConfig.debug = /\\bdebug\\b/.test($storydata.attr('options'));\n\n\t\t\t\t/*\n    \tProcess stylesheet passages.\n    */\n\t\t\t\t$storydata.children('style') // alternatively: '[type=\"text/twine-css\"]' or '#twine-user-stylesheet'\n\t\t\t\t.each(function (i) {\n\t\t\t\t\t_styles.push(new Passage('tw-user-style-' + i, this));\n\t\t\t\t});\n\n\t\t\t\t/*\n    \tProcess script passages.\n    */\n\t\t\t\t$storydata.children('script') // alternatively: '[type=\"text/twine-javascript\"]' or '#twine-user-script'\n\t\t\t\t.each(function (i) {\n\t\t\t\t\t_scripts.push(new Passage('tw-user-script-' + i, this));\n\t\t\t\t});\n\n\t\t\t\t/*\n    \tProcess normal passages, excluding any tagged 'Twine.private' or 'annotation'.\n    */\n\t\t\t\t$storydata.children('tw-passagedata:not([tags~=\"Twine.private\"],[tags~=\"annotation\"])').each(function () {\n\t\t\t\t\tvar $this = jQuery(this);\n\t\t\t\t\tvar pid = $this.attr('pid') || '';\n\t\t\t\t\tvar passage = new Passage($this.attr('name'), this);\n\n\t\t\t\t\t// Special cases.\n\t\t\t\t\tif (pid === startNode && startNode !== '') {\n\t\t\t\t\t\tConfig.passages.start = passage.title;\n\t\t\t\t\t\tvalidateStartingPassage(passage);\n\t\t\t\t\t\t_passages[passage.title] = passage;\n\t\t\t\t\t} else if (passage.tags.includes('widget')) {\n\t\t\t\t\t\t_widgets.push(passage);\n\t\t\t\t\t}\n\n\t\t\t\t\t// All other passages.\n\t\t\t\t\telse {\n\t\t\t\t\t\t\tvalidateSpecialPassages(passage);\n\t\t\t\t\t\t\t_passages[passage.title] = passage;\n\t\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\t/*\n    \tGet the story IFID.\n    */\n\t\t\t\t_ifId = $storydata.attr('ifid');\n\n\t\t\t\t/*\n    \tSet the story title.\n    \t\tFIXME: Maybe `$storydata.attr('name')` should be used instead of `'{{STORY_NAME}}'`?\n    */\n\t\t\t\t// _storySetTitle($storydata.attr('name'));\n\t\t\t\t_storySetTitle(Util.unescape('{{STORY_NAME}}'));\n\n\t\t\t\t/*\n    \tSet the default saves ID (must be done after the call to `_storySetTitle()`).\n    */\n\t\t\t\tConfig.saves.id = Story.domId;\n\t\t\t}\n\t}\n\n\tfunction storyInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[Story/storyInit()]');\n\t\t}\n\n\t\t/*\n  \tAdd the story styles.\n  */\n\t\t(function () {\n\t\t\tvar storyStyle = document.createElement('style');\n\n\t\t\tnew StyleWrapper(storyStyle).add(_styles.map(function (style) {\n\t\t\t\treturn style.text.trim();\n\t\t\t}).join('\\n'));\n\n\t\t\tjQuery(storyStyle).appendTo(document.head).attr({\n\t\t\t\tid: 'style-story',\n\t\t\t\ttype: 'text/css'\n\t\t\t});\n\t\t})();\n\n\t\t/*\n  \tEvaluate the story scripts.\n  */\n\t\tfor (var i = 0; i < _scripts.length; ++i) {\n\t\t\ttry {\n\t\t\t\tScripting.evalJavaScript(_scripts[i].text);\n\t\t\t} catch (ex) {\n\t\t\t\tconsole.error(ex);\n\t\t\t\tAlert.error(_scripts[i].title, (typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex);\n\t\t\t}\n\t\t}\n\n\t\t/*\n  \tProcess the story widgets.\n  */\n\t\tfor (var _i7 = 0; _i7 < _widgets.length; ++_i7) {\n\t\t\ttry {\n\t\t\t\tWikifier.wikifyEval(_widgets[_i7].processText());\n\t\t\t} catch (ex) {\n\t\t\t\tconsole.error(ex);\n\t\t\t\tAlert.error(_widgets[_i7].title, (typeof ex === 'undefined' ? 'undefined' : _typeof(ex)) === 'object' ? ex.message : ex);\n\t\t\t}\n\t\t}\n\t}\n\n\tfunction _storySetTitle(title) {\n\t\tif (title == null || title === '') {\n\t\t\t// lazy equality for null\n\t\t\tthrow new Error('story title cannot be null or empty');\n\t\t}\n\n\t\tdocument.title = _title = Util.unescape(title);\n\t\t_domId = Util.slugify(_title);\n\n\t\tif (_title === '' || _domId === '') {\n\t\t\tthrow new Error('story title must include characters from the basic Latin alphabet');\n\t\t}\n\t}\n\n\tfunction storyTitle() {\n\t\treturn _title;\n\t}\n\n\tfunction storyDomId() {\n\t\treturn _domId;\n\t}\n\n\tfunction storyIfId() {\n\t\treturn _ifId;\n\t}\n\n\t/*******************************************************************************************************************\n \tPassage Functions.\n *******************************************************************************************************************/\n\tfunction passagesHas(title) {\n\t\tvar type = typeof title === 'undefined' ? 'undefined' : _typeof(title);\n\n\t\tswitch (type) {\n\t\t\t// Valid types.\n\t\t\tcase 'number':\n\t\t\tcase 'string':\n\t\t\t\treturn _passages.hasOwnProperty(String(title));\n\n\t\t\t// Invalid types.  We do the extra processing just to make a nicer error.\n\t\t\tcase 'boolean':\n\t\t\tcase 'function':\n\t\t\t\ttype = 'a ' + type;\n\t\t\t\tbreak;\n\n\t\t\tcase 'undefined':\n\t\t\t\t/* no-op */\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\t// 'object'\n\t\t\t\tif (title === null) {\n\t\t\t\t\ttype = 'null';\n\t\t\t\t} else {\n\t\t\t\t\ttype = 'an ' + type;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\n\t\tthrow new TypeError('Story.has title parameter cannot be ' + type);\n\t}\n\n\tfunction passagesGet(title) {\n\t\tvar type = typeof title === 'undefined' ? 'undefined' : _typeof(title);\n\n\t\tswitch (type) {\n\t\t\t// Valid types.\n\t\t\tcase 'number':\n\t\t\tcase 'string':\n\t\t\t\t/* eslint-disable indent */\n\t\t\t\t{\n\t\t\t\t\tvar id = String(title);\n\t\t\t\t\treturn _passages.hasOwnProperty(id) ? _passages[id] : new Passage(id || '(unknown)');\n\t\t\t\t}\n\t\t\t/* eslint-enable indent */\n\n\t\t\t// Invalid types.  We do the extra processing just to make a nicer error.\n\t\t\tcase 'boolean':\n\t\t\tcase 'function':\n\t\t\t\ttype = 'a ' + type;\n\t\t\t\tbreak;\n\n\t\t\tcase 'undefined':\n\t\t\t\t/* no-op */\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\t// 'object'\n\t\t\t\tif (title === null) {\n\t\t\t\t\ttype = 'null';\n\t\t\t\t} else {\n\t\t\t\t\ttype = 'an ' + type;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\n\t\tthrow new TypeError('Story.get title parameter cannot be ' + type);\n\t}\n\n\tfunction passagesLookup(key, value) {\n\t\tvar sortKey = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'title';\n\n\t\tvar pnames = Object.keys(_passages);\n\t\tvar results = [];\n\n\t\tfor (var i = 0; i < pnames.length; ++i) {\n\t\t\tvar passage = _passages[pnames[i]];\n\n\t\t\tif (passage.hasOwnProperty(key)) {\n\t\t\t\tswitch (_typeof(passage[key])) {\n\t\t\t\t\tcase 'undefined':\n\t\t\t\t\t\t/* no-op */\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase 'object':\n\t\t\t\t\t\t// Only arrays are supported at present, since the only non-method\n\t\t\t\t\t\t// `Passage` object properties yield either primitives or arrays.\n\t\t\t\t\t\t/* eslint-disable eqeqeq */\n\t\t\t\t\t\tif (passage[key] instanceof Array && passage[key].some(function (val) {\n\t\t\t\t\t\t\treturn val == value;\n\t\t\t\t\t\t}) // lazy equality, since null & undefined are both possible\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\tresults.push(passage);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/* eslint-enable eqeqeq */\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t/* eslint-disable eqeqeq */\n\t\t\t\t\t\tif (passage[key] == value) {\n\t\t\t\t\t\t\t// lazy equality, since null & undefined are both possible\n\t\t\t\t\t\t\tresults.push(passage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t/* eslint-enable eqeqeq */\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t/* eslint-disable eqeqeq, no-nested-ternary, max-len */\n\t\tresults.sort(function (a, b) {\n\t\t\treturn a[sortKey] == b[sortKey] ? 0 : a[sortKey] < b[sortKey] ? -1 : +1;\n\t\t}); // lazy equality for null\n\t\t/* eslint-enable eqeqeq, no-nested-ternary, max-len */\n\n\t\treturn results;\n\t}\n\n\tfunction passagesLookupWith(filter) {\n\t\tvar sortKey = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'title';\n\n\t\tif (typeof filter !== 'function') {\n\t\t\tthrow new Error('Story.lookupWith filter parameter must be a function');\n\t\t}\n\n\t\tvar pnames = Object.keys(_passages);\n\t\tvar results = [];\n\n\t\tfor (var i = 0; i < pnames.length; ++i) {\n\t\t\tvar passage = _passages[pnames[i]];\n\n\t\t\tif (filter(passage)) {\n\t\t\t\tresults.push(passage);\n\t\t\t}\n\t\t}\n\n\t\t/* eslint-disable eqeqeq, no-nested-ternary, max-len */\n\t\tresults.sort(function (a, b) {\n\t\t\treturn a[sortKey] == b[sortKey] ? 0 : a[sortKey] < b[sortKey] ? -1 : +1;\n\t\t}); // lazy equality for null\n\t\t/* eslint-enable eqeqeq, no-nested-ternary, max-len */\n\n\t\treturn results;\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tPassage Containers.\n  \t\tTODO: These should probably have getters, rather than being exported directly.\n  */\n\t\tpassages: { value: _passages },\n\t\tstyles: { value: _styles },\n\t\tscripts: { value: _scripts },\n\t\twidgets: { value: _widgets },\n\n\t\t/*\n  \tStory Functions.\n  */\n\t\tload: { value: storyLoad },\n\t\tinit: { value: storyInit },\n\t\ttitle: { get: storyTitle },\n\t\tdomId: { get: storyDomId },\n\t\tifId: { get: storyIfId },\n\n\t\t/*\n  \tPassage Functions.\n  */\n\t\thas: { value: passagesHas },\n\t\tget: { value: passagesGet },\n\t\tlookup: { value: passagesLookup },\n\t\tlookupWith: { value: passagesLookupWith }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tui.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Alert, Dialog, Engine, Has, L10n, Save, Setting, State, Story, Util, Wikifier, Config, errorPrologRegExp,\n\t       settings\n*/\n\nvar UI = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t/*******************************************************************************************************************\n \tUI Functions, Core.\n *******************************************************************************************************************/\n\n\tfunction uiAssembleLinkList(passage, listEl) {\n\t\tvar list = listEl;\n\n\t\t// Cache the values of `Config.debug` and `Config.cleanupWikifierOutput`,\n\t\t// then disable them during this method's run.\n\t\tvar debugState = Config.debug;\n\t\tvar cleanState = Config.cleanupWikifierOutput;\n\t\tConfig.debug = false;\n\t\tConfig.cleanupWikifierOutput = false;\n\n\t\ttry {\n\t\t\tif (list == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tlist = document.createElement('ul');\n\t\t\t}\n\n\t\t\t// Wikify the content of the given source passage into a fragment.\n\t\t\tvar frag = document.createDocumentFragment();\n\t\t\tnew Wikifier(frag, Story.get(passage).processText().trim());\n\n\t\t\t// Gather the text of any error elements within the fragment…\n\t\t\tvar errors = [].concat(_toConsumableArray(frag.querySelectorAll('.error'))).map(function (errEl) {\n\t\t\t\treturn errEl.textContent.replace(errorPrologRegExp, '');\n\t\t\t});\n\n\t\t\t// …and throw an exception, if there were any errors.\n\t\t\tif (errors.length > 0) {\n\t\t\t\tthrow new Error(errors.join('; '));\n\t\t\t}\n\n\t\t\twhile (frag.hasChildNodes()) {\n\t\t\t\tvar node = frag.firstChild;\n\n\t\t\t\t// Create list items for <a>-element nodes.\n\t\t\t\tif (node.nodeType === Node.ELEMENT_NODE && node.nodeName.toUpperCase() === 'A') {\n\t\t\t\t\tvar li = document.createElement('li');\n\t\t\t\t\tlist.appendChild(li);\n\t\t\t\t\tli.appendChild(node);\n\t\t\t\t}\n\n\t\t\t\t// Discard non-<a>-element nodes.\n\t\t\t\telse {\n\t\t\t\t\t\tfrag.removeChild(node);\n\t\t\t\t\t}\n\t\t\t}\n\t\t} finally {\n\t\t\t// Restore the `Config` settings to their original values.\n\t\t\tConfig.cleanupWikifierOutput = cleanState;\n\t\t\tConfig.debug = debugState;\n\t\t}\n\n\t\treturn list;\n\t}\n\n\t/*******************************************************************************************************************\n \tUI Functions, Built-ins.\n *******************************************************************************************************************/\n\tfunction uiOpenAlert(message) {\n\t\tjQuery(Dialog.setup('Alert', 'alert')).append('<p>' + message + '</p><ul class=\"buttons\">' + ('<li><button id=\"alert-ok\" class=\"ui-close\">' + L10n.get(['alertOk', 'ok']) + '</button></li>') + '</ul>');\n\n\t\tfor (var _len19 = arguments.length, args = Array(_len19 > 1 ? _len19 - 1 : 0), _key19 = 1; _key19 < _len19; _key19++) {\n\t\t\targs[_key19 - 1] = arguments[_key19];\n\t\t}\n\n\t\tDialog.open.apply(Dialog, args);\n\t}\n\n\tfunction uiOpenJumpto() {\n\t\tuiBuildJumpto();\n\t\tDialog.open.apply(Dialog, arguments);\n\t}\n\n\tfunction uiOpenRestart() {\n\t\tuiBuildRestart();\n\t\tDialog.open.apply(Dialog, arguments);\n\t}\n\n\tfunction uiOpenSaves() {\n\t\tuiBuildSaves();\n\t\tDialog.open.apply(Dialog, arguments);\n\t}\n\n\tfunction uiOpenSettings() {\n\t\tuiBuildSettings();\n\t\tDialog.open.apply(Dialog, arguments);\n\t}\n\n\tfunction uiOpenShare() {\n\t\tuiBuildShare();\n\t\tDialog.open.apply(Dialog, arguments);\n\t}\n\n\tfunction uiBuildAutoload() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UI/uiBuildAutoload()]');\n\t\t}\n\n\t\tjQuery(Dialog.setup(L10n.get('autoloadTitle'), 'autoload')).append(\n\t\t/* eslint-disable max-len */\n\t\t'<p>' + L10n.get('autoloadPrompt') + '</p><ul class=\"buttons\">' + ('<li><button id=\"autoload-ok\" class=\"ui-close\">' + L10n.get(['autoloadOk', 'ok']) + '</button></li>') + ('<li><button id=\"autoload-cancel\" class=\"ui-close\">' + L10n.get(['autoloadCancel', 'cancel']) + '</button></li>') + '</ul>'\n\t\t/* eslint-enable max-len */\n\t\t);\n\n\t\t// Add an additional delegated click handler for the `.ui-close` elements to handle autoloading.\n\t\tjQuery(document).one('click.autoload', '.ui-close', function (ev) {\n\t\t\tvar isAutoloadOk = ev.target.id === 'autoload-ok';\n\t\t\tjQuery(document).one(':dialogclosed', function () {\n\t\t\t\tif (DEBUG) {\n\t\t\t\t\tconsole.log('\\tattempting autoload: \"' + Save.autosave.get().title + '\"');\n\t\t\t\t}\n\n\t\t\t\tif (!isAutoloadOk || !Save.autosave.load()) {\n\t\t\t\t\tEngine.play(Config.passages.start);\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\n\t\treturn true;\n\t}\n\n\tfunction uiBuildJumpto() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UI/uiBuildJumpto()]');\n\t\t}\n\n\t\tvar list = document.createElement('ul');\n\n\t\tjQuery(Dialog.setup(L10n.get('jumptoTitle'), 'jumpto list')).append(list);\n\n\t\tvar expired = State.expired.length;\n\n\t\tfor (var i = State.size - 1; i >= 0; --i) {\n\t\t\tif (i === State.activeIndex) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tvar passage = Story.get(State.history[i].title);\n\n\t\t\tif (passage && passage.tags.includes('bookmark')) {\n\t\t\t\tjQuery(document.createElement('li')).append(jQuery(document.createElement('a')).ariaClick({ one: true }, function (idx) {\n\t\t\t\t\treturn function () {\n\t\t\t\t\t\treturn jQuery(document).one(':dialogclosed', function () {\n\t\t\t\t\t\t\treturn Engine.goTo(idx);\n\t\t\t\t\t\t});\n\t\t\t\t\t};\n\t\t\t\t}(i)).addClass('ui-close').text(L10n.get('jumptoTurn') + ' ' + (expired + i + 1) + ': ' + passage.description())).appendTo(list);\n\t\t\t}\n\t\t}\n\n\t\tif (!list.hasChildNodes()) {\n\t\t\tjQuery(list).append('<li><a><em>' + L10n.get('jumptoUnavailable') + '</em></a></li>');\n\t\t}\n\t}\n\n\tfunction uiBuildRestart() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UI/uiBuildRestart()]');\n\t\t}\n\n\t\tjQuery(Dialog.setup(L10n.get('restartTitle'), 'restart')).append(\n\t\t/* eslint-disable max-len */\n\t\t'<p>' + L10n.get('restartPrompt') + '</p><ul class=\"buttons\">' + ('<li><button id=\"restart-ok\">' + L10n.get(['restartOk', 'ok']) + '</button></li>') + ('<li><button id=\"restart-cancel\" class=\"ui-close\">' + L10n.get(['restartCancel', 'cancel']) + '</button></li>') + '</ul>'\n\t\t/* eslint-enable max-len */\n\t\t).find('#restart-ok')\n\t\t/*\n  \tInstead of adding '.ui-close' to '#restart-ok' (to receive the use of the default\n  \tdelegated dialog close handler), we set up a special case close handler here.  We\n  \tdo this to ensure that the invocation of `Engine.restart()` happens after the dialog\n  \thas fully closed.  If we did not, then a race condition could occur, causing display\n  \tshenanigans.\n  */\n\t\t.ariaClick({ one: true }, function () {\n\t\t\tjQuery(document).one(':dialogclosed', function () {\n\t\t\t\treturn Engine.restart();\n\t\t\t});\n\t\t\tDialog.close();\n\t\t});\n\n\t\treturn true;\n\t}\n\n\tfunction uiBuildSaves() {\n\t\tfunction createActionItem(bId, bClass, bText, bAction) {\n\t\t\tvar $btn = jQuery(document.createElement('button')).attr('id', 'saves-' + bId).html(bText);\n\n\t\t\tif (bClass) {\n\t\t\t\t$btn.addClass(bClass);\n\t\t\t}\n\n\t\t\tif (bAction) {\n\t\t\t\t$btn.ariaClick(bAction);\n\t\t\t} else {\n\t\t\t\t$btn.ariaDisabled(true);\n\t\t\t}\n\n\t\t\treturn jQuery(document.createElement('li')).append($btn);\n\t\t}\n\n\t\tfunction createSaveList() {\n\t\t\tfunction createButton(bId, bClass, bText, bSlot, bAction) {\n\t\t\t\tvar $btn = jQuery(document.createElement('button')).attr('id', 'saves-' + bId + '-' + bSlot).addClass(bId).html(bText);\n\n\t\t\t\tif (bClass) {\n\t\t\t\t\t$btn.addClass(bClass);\n\t\t\t\t}\n\n\t\t\t\tif (bAction) {\n\t\t\t\t\tif (bSlot === 'auto') {\n\t\t\t\t\t\t$btn.ariaClick({\n\t\t\t\t\t\t\tlabel: bText + ' ' + L10n.get('savesLabelAuto')\n\t\t\t\t\t\t}, function () {\n\t\t\t\t\t\t\treturn bAction();\n\t\t\t\t\t\t});\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$btn.ariaClick({\n\t\t\t\t\t\t\tlabel: bText + ' ' + L10n.get('savesLabelSlot') + ' ' + (bSlot + 1)\n\t\t\t\t\t\t}, function () {\n\t\t\t\t\t\t\treturn bAction(bSlot);\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t$btn.ariaDisabled(true);\n\t\t\t\t}\n\n\t\t\t\treturn $btn;\n\t\t\t}\n\n\t\t\tvar saves = Save.get();\n\t\t\tvar $tbody = jQuery(document.createElement('tbody'));\n\n\t\t\tif (Save.autosave.ok()) {\n\t\t\t\tvar $tdSlot = jQuery(document.createElement('td'));\n\t\t\t\tvar $tdLoad = jQuery(document.createElement('td'));\n\t\t\t\tvar $tdDesc = jQuery(document.createElement('td'));\n\t\t\t\tvar $tdDele = jQuery(document.createElement('td'));\n\n\t\t\t\t// Add the slot ID.\n\t\t\t\tjQuery(document.createElement('b')).attr({\n\t\t\t\t\ttitle: L10n.get('savesLabelAuto'),\n\t\t\t\t\t'aria-label': L10n.get('savesLabelAuto')\n\t\t\t\t}).text('A') // '\\u25C6' Black Diamond\n\t\t\t\t.appendTo($tdSlot);\n\n\t\t\t\tif (saves.autosave) {\n\t\t\t\t\t// Add the load button.\n\t\t\t\t\t$tdLoad.append(createButton('load', 'ui-close', L10n.get('savesLabelLoad'), 'auto', function () {\n\t\t\t\t\t\tjQuery(document).one(':dialogclosed', function () {\n\t\t\t\t\t\t\treturn Save.autosave.load();\n\t\t\t\t\t\t});\n\t\t\t\t\t}));\n\n\t\t\t\t\t// Add the description (title and datestamp).\n\t\t\t\t\tjQuery(document.createElement('div')).text(saves.autosave.title).appendTo($tdDesc);\n\t\t\t\t\tjQuery(document.createElement('div')).addClass('datestamp').html(saves.autosave.date ? '' + new Date(saves.autosave.date).toLocaleString() : '<em>' + L10n.get('savesUnknownDate') + '</em>').appendTo($tdDesc);\n\n\t\t\t\t\t// Add the delete button.\n\t\t\t\t\t$tdDele.append(createButton('delete', null, L10n.get('savesLabelDelete'), 'auto', function () {\n\t\t\t\t\t\tSave.autosave.delete();\n\t\t\t\t\t\tuiBuildSaves();\n\t\t\t\t\t}));\n\t\t\t\t} else {\n\t\t\t\t\t// Add the disabled load button.\n\t\t\t\t\t$tdLoad.append(createButton('load', null, L10n.get('savesLabelLoad'), 'auto'));\n\n\t\t\t\t\t// Add the description.\n\t\t\t\t\t$tdDesc.addClass('empty').text('\\u2022\\xA0\\xA0\\u2022\\xA0\\xA0\\u2022');\n\n\t\t\t\t\t// Add the disabled delete button.\n\t\t\t\t\t$tdDele.append(createButton('delete', null, L10n.get('savesLabelDelete'), 'auto'));\n\t\t\t\t}\n\n\t\t\t\tjQuery(document.createElement('tr')).append($tdSlot).append($tdLoad).append($tdDesc).append($tdDele).appendTo($tbody);\n\t\t\t}\n\n\t\t\tfor (var i = 0, iend = saves.slots.length; i < iend; ++i) {\n\t\t\t\tvar _$tdSlot = jQuery(document.createElement('td'));\n\t\t\t\tvar _$tdLoad = jQuery(document.createElement('td'));\n\t\t\t\tvar _$tdDesc = jQuery(document.createElement('td'));\n\t\t\t\tvar _$tdDele = jQuery(document.createElement('td'));\n\n\t\t\t\t// Add the slot ID.\n\t\t\t\t_$tdSlot.append(document.createTextNode(i + 1));\n\n\t\t\t\tif (saves.slots[i]) {\n\t\t\t\t\t// Add the load button.\n\t\t\t\t\t_$tdLoad.append(createButton('save', 'ui-close', L10n.get('savesLabelSave'), i, Save.slots.save), createButton('load', 'ui-close', L10n.get('savesLabelLoad'), i, function (slot) {\n\t\t\t\t\t\tjQuery(document).one(':dialogclosed', function () {\n\t\t\t\t\t\t\treturn Save.slots.load(slot);\n\t\t\t\t\t\t});\n\t\t\t\t\t}));\n\n\t\t\t\t\t// Add the description (title and datestamp).\n\t\t\t\t\tjQuery(document.createElement('div')).text(saves.slots[i].title).appendTo(_$tdDesc);\n\t\t\t\t\tjQuery(document.createElement('div')).addClass('datestamp').html(saves.slots[i].date ? '' + new Date(saves.slots[i].date).toLocaleString() : '<em>' + L10n.get('savesUnknownDate') + '</em>').appendTo(_$tdDesc);\n\n\t\t\t\t\t// Add the delete button.\n\t\t\t\t\t_$tdDele.append(createButton('delete', null, L10n.get('savesLabelDelete'), i, function (slot) {\n\t\t\t\t\t\tSave.slots.delete(slot);\n\t\t\t\t\t\tuiBuildSaves();\n\t\t\t\t\t}));\n\t\t\t\t} else {\n\t\t\t\t\t// Add the save button.\n\t\t\t\t\t_$tdLoad.append(createButton('save', 'ui-close', L10n.get('savesLabelSave'), i, Save.slots.save));\n\n\t\t\t\t\t// Add the description.\n\t\t\t\t\t_$tdDesc.addClass('empty').text('\\u2022\\xA0\\xA0\\u2022\\xA0\\xA0\\u2022');\n\n\t\t\t\t\t// Add the disabled delete button.\n\t\t\t\t\t_$tdDele.append(createButton('delete', null, L10n.get('savesLabelDelete'), i));\n\t\t\t\t}\n\n\t\t\t\tjQuery(document.createElement('tr')).append(_$tdSlot).append(_$tdLoad).append(_$tdDesc).append(_$tdDele).appendTo($tbody);\n\t\t\t}\n\n\t\t\treturn jQuery(document.createElement('table')).attr('id', 'saves-list').append($tbody);\n\t\t}\n\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UI/uiBuildSaves()]');\n\t\t}\n\n\t\tvar $dialogBody = jQuery(Dialog.setup(L10n.get('savesTitle'), 'saves'));\n\t\tvar savesOk = Save.ok();\n\n\t\t// Add saves list.\n\t\tif (savesOk) {\n\t\t\t$dialogBody.append(createSaveList());\n\t\t}\n\n\t\t// Add button bar items (export, import, and clear).\n\t\tif (savesOk || Has.fileAPI) {\n\t\t\tvar $btnBar = jQuery(document.createElement('ul')).addClass('buttons').appendTo($dialogBody);\n\n\t\t\tif (Has.fileAPI) {\n\t\t\t\t$btnBar.append(createActionItem('export', 'ui-close', L10n.get('savesLabelExport'), function () {\n\t\t\t\t\treturn Save.export();\n\t\t\t\t}));\n\t\t\t\t$btnBar.append(createActionItem('import', null, L10n.get('savesLabelImport'), function () {\n\t\t\t\t\treturn $dialogBody.find('#saves-import-file').trigger('click');\n\t\t\t\t}));\n\n\t\t\t\t// Add the hidden `input[type=file]` element which will be triggered by the `#saves-import` button.\n\t\t\t\tjQuery(document.createElement('input')).css({\n\t\t\t\t\tdisplay: 'block',\n\t\t\t\t\tvisibility: 'hidden',\n\t\t\t\t\tposition: 'fixed',\n\t\t\t\t\tleft: '-9999px',\n\t\t\t\t\ttop: '-9999px',\n\t\t\t\t\twidth: '1px',\n\t\t\t\t\theight: '1px'\n\t\t\t\t}).attr({\n\t\t\t\t\ttype: 'file',\n\t\t\t\t\tid: 'saves-import-file',\n\t\t\t\t\ttabindex: -1,\n\t\t\t\t\t'aria-hidden': true\n\t\t\t\t}).on('change', function (ev) {\n\t\t\t\t\tjQuery(document).one(':dialogclosed', function () {\n\t\t\t\t\t\treturn Save.import(ev);\n\t\t\t\t\t});\n\t\t\t\t\tDialog.close();\n\t\t\t\t}).appendTo($dialogBody);\n\t\t\t}\n\n\t\t\tif (savesOk) {\n\t\t\t\t$btnBar.append(createActionItem('clear', null, L10n.get('savesLabelClear'), Save.autosave.has() || !Save.slots.isEmpty() ? function () {\n\t\t\t\t\tSave.clear();\n\t\t\t\t\tuiBuildSaves();\n\t\t\t\t} : null));\n\t\t\t}\n\n\t\t\treturn true;\n\t\t}\n\n\t\tuiOpenAlert(L10n.get('savesIncapable'));\n\t\treturn false;\n\t}\n\n\tfunction uiBuildSettings() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UI/uiBuildSettings()]');\n\t\t}\n\n\t\tvar $dialogBody = jQuery(Dialog.setup(L10n.get('settingsTitle'), 'settings'));\n\n\t\tSetting.forEach(function (control) {\n\t\t\tif (control.type === Setting.Types.Header) {\n\t\t\t\tvar _name = control.name;\n\t\t\t\tvar _id = Util.slugify(_name);\n\t\t\t\tvar $header = jQuery(document.createElement('div'));\n\t\t\t\tvar $heading = jQuery(document.createElement('h2'));\n\n\t\t\t\t$header.attr('id', 'header-body-' + _id).append($heading).appendTo($dialogBody);\n\t\t\t\t$heading.attr('id', 'header-heading-' + _id).wiki(_name);\n\n\t\t\t\t// Set up the description, if any.\n\t\t\t\tif (control.desc) {\n\t\t\t\t\tjQuery(document.createElement('p')).attr('id', 'header-desc-' + _id).wiki(control.desc).appendTo($header);\n\t\t\t\t}\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar name = control.name;\n\t\t\tvar id = Util.slugify(name);\n\t\t\tvar $setting = jQuery(document.createElement('div'));\n\t\t\tvar $label = jQuery(document.createElement('label'));\n\t\t\tvar $controlBox = jQuery(document.createElement('div'));\n\t\t\tvar $control = void 0;\n\n\t\t\t// Set up the label+control wrapper.\n\t\t\tjQuery(document.createElement('div')).append($label).append($controlBox).appendTo($setting);\n\n\t\t\t// Set up the description, if any.\n\t\t\tif (control.desc) {\n\t\t\t\tjQuery(document.createElement('p')).attr('id', 'setting-desc-' + id).wiki(control.desc).appendTo($setting);\n\t\t\t}\n\n\t\t\t// Set up the label.\n\t\t\t$label.attr({\n\t\t\t\tid: 'setting-label-' + id,\n\t\t\t\tfor: 'setting-control-' + id // must be in sync with $control's ID (see below)\n\t\t\t}).wiki(control.label);\n\n\t\t\t// Set up the control.\n\t\t\tif (settings[name] == null) {\n\t\t\t\t// lazy equality for null\n\t\t\t\tsettings[name] = control.default;\n\t\t\t}\n\n\t\t\tswitch (control.type) {\n\t\t\t\tcase Setting.Types.Toggle:\n\t\t\t\t\t$control = jQuery(document.createElement('button'));\n\n\t\t\t\t\tif (settings[name]) {\n\t\t\t\t\t\t$control.addClass('enabled').text(L10n.get('settingsOn'));\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$control.text(L10n.get('settingsOff'));\n\t\t\t\t\t}\n\n\t\t\t\t\t$control.ariaClick(function () {\n\t\t\t\t\t\tif (settings[name]) {\n\t\t\t\t\t\t\tjQuery(this).removeClass('enabled').text(L10n.get('settingsOff'));\n\t\t\t\t\t\t\tsettings[name] = false;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tjQuery(this).addClass('enabled').text(L10n.get('settingsOn'));\n\t\t\t\t\t\t\tsettings[name] = true;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tSetting.save();\n\n\t\t\t\t\t\tif (control.hasOwnProperty('onChange')) {\n\t\t\t\t\t\t\tcontrol.onChange.call({\n\t\t\t\t\t\t\t\tname: name,\n\t\t\t\t\t\t\t\tvalue: settings[name],\n\t\t\t\t\t\t\t\tdefault: control.default\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase Setting.Types.List:\n\t\t\t\t\t$control = jQuery(document.createElement('select'));\n\n\t\t\t\t\tfor (var i = 0, iend = control.list.length; i < iend; ++i) {\n\t\t\t\t\t\tjQuery(document.createElement('option')).val(i).text(control.list[i]).appendTo($control);\n\t\t\t\t\t}\n\n\t\t\t\t\t$control.val(control.list.indexOf(settings[name])).attr('tabindex', 0).on('change', function () {\n\t\t\t\t\t\tsettings[name] = control.list[Number(this.value)];\n\t\t\t\t\t\tSetting.save();\n\n\t\t\t\t\t\tif (control.hasOwnProperty('onChange')) {\n\t\t\t\t\t\t\tcontrol.onChange.call({\n\t\t\t\t\t\t\t\tname: name,\n\t\t\t\t\t\t\t\tvalue: settings[name],\n\t\t\t\t\t\t\t\tdefault: control.default,\n\t\t\t\t\t\t\t\tlist: control.list\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase Setting.Types.Range:\n\t\t\t\t\t$control = jQuery(document.createElement('input'));\n\n\t\t\t\t\t// NOTE: Setting the value with `<jQuery>.val()` can cause odd behavior\n\t\t\t\t\t// in Edge if it's called before the type is set, so we use the `value`\n\t\t\t\t\t// content attribute here to dodge the entire issue.\n\t\t\t\t\t$control.attr({\n\t\t\t\t\t\ttype: 'range',\n\t\t\t\t\t\tmin: control.min,\n\t\t\t\t\t\tmax: control.max,\n\t\t\t\t\t\tstep: control.step,\n\t\t\t\t\t\tvalue: settings[name],\n\t\t\t\t\t\ttabindex: 0\n\t\t\t\t\t}).on('change input', function () {\n\t\t\t\t\t\tsettings[name] = Number(this.value);\n\t\t\t\t\t\tSetting.save();\n\n\t\t\t\t\t\tif (control.hasOwnProperty('onChange')) {\n\t\t\t\t\t\t\tcontrol.onChange.call({\n\t\t\t\t\t\t\t\tname: name,\n\t\t\t\t\t\t\t\tvalue: settings[name],\n\t\t\t\t\t\t\t\tdefault: control.default,\n\t\t\t\t\t\t\t\tmin: control.min,\n\t\t\t\t\t\t\t\tmax: control.max,\n\t\t\t\t\t\t\t\tstep: control.step\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t}).on('keypress', function (ev) {\n\t\t\t\t\t\tif (ev.which === 13) {\n\t\t\t\t\t\t\tev.preventDefault();\n\t\t\t\t\t\t\t$control.trigger('change');\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t$control.attr('id', 'setting-control-' + id).appendTo($controlBox);\n\n\t\t\t$setting.attr('id', 'setting-body-' + id).appendTo($dialogBody);\n\t\t});\n\n\t\t// Add the button bar.\n\t\t$dialogBody.append('<ul class=\"buttons\">' + ('<li><button id=\"settings-ok\" class=\"ui-close\">' + L10n.get(['settingsOk', 'ok']) + '</button></li>') + ('<li><button id=\"settings-reset\">' + L10n.get('settingsReset') + '</button></li>') + '</ul>').find('#settings-reset')\n\t\t/*\n  \tInstead of adding '.ui-close' to '#settings-reset' (to receive the use of the default\n  \tdelegated dialog close handler), we set up a special case close handler here.  We\n  \tdo this to ensure that the invocation of `window.location.reload()` happens after the\n  \tdialog has fully closed.  If we did not, then a race condition could occur, causing\n  \tdisplay shenanigans.\n  */\n\t\t.ariaClick({ one: true }, function () {\n\t\t\tjQuery(document).one(':dialogclosed', function () {\n\t\t\t\tSetting.reset();\n\t\t\t\twindow.location.reload();\n\t\t\t});\n\t\t\tDialog.close();\n\t\t});\n\n\t\treturn true;\n\t}\n\n\tfunction uiBuildShare() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UI/uiBuildShare()]');\n\t\t}\n\n\t\ttry {\n\t\t\tjQuery(Dialog.setup(L10n.get('shareTitle'), 'share list')).append(uiAssembleLinkList('StoryShare'));\n\t\t} catch (ex) {\n\t\t\tconsole.error(ex);\n\t\t\tAlert.error('StoryShare', ex.message);\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tUI Functions, Core.\n  */\n\t\tassembleLinkList: { value: uiAssembleLinkList },\n\n\t\t/*\n  \tUI Functions, Built-ins.\n  */\n\t\talert: { value: uiOpenAlert },\n\t\tjumpto: { value: uiOpenJumpto },\n\t\trestart: { value: uiOpenRestart },\n\t\tsaves: { value: uiOpenSaves },\n\t\tsettings: { value: uiOpenSettings },\n\t\tshare: { value: uiOpenShare },\n\t\tbuildAutoload: { value: uiBuildAutoload },\n\t\tbuildJumpto: { value: uiBuildJumpto },\n\t\tbuildRestart: { value: uiBuildRestart },\n\t\tbuildSaves: { value: uiBuildSaves },\n\t\tbuildSettings: { value: uiBuildSettings },\n\t\tbuildShare: { value: uiBuildShare },\n\n\t\t/*\n  \tLegacy Aliases.\n  */\n\t\t// `UIBar` methods.\n\t\t/* global UIBar */\n\t\tstow: { value: function value() {\n\t\t\t\treturn UIBar.stow();\n\t\t\t} },\n\t\tunstow: { value: function value() {\n\t\t\t\treturn UIBar.unstow();\n\t\t\t} },\n\t\tsetStoryElements: { value: function value() {\n\t\t\t\treturn UIBar.update();\n\t\t\t} },\n\t\t// `Dialog` methods.\n\t\tisOpen: { value: function value() {\n\t\t\t\treturn Dialog.isOpen.apply(Dialog, arguments);\n\t\t\t} },\n\t\tbody: { value: function value() {\n\t\t\t\treturn Dialog.body();\n\t\t\t} },\n\t\tsetup: { value: function value() {\n\t\t\t\treturn Dialog.setup.apply(Dialog, arguments);\n\t\t\t} },\n\t\taddClickHandler: { value: function value() {\n\t\t\t\treturn Dialog.addClickHandler.apply(Dialog, arguments);\n\t\t\t} },\n\t\topen: { value: function value() {\n\t\t\t\treturn Dialog.open.apply(Dialog, arguments);\n\t\t\t} },\n\t\tclose: { value: function value() {\n\t\t\t\treturn Dialog.close.apply(Dialog, arguments);\n\t\t\t} },\n\t\tresize: { value: function value() {\n\t\t\t\treturn Dialog.resize();\n\t\t\t} },\n\t\t// Deprecated method names.\n\t\tbuildDialogAutoload: { value: uiBuildAutoload },\n\t\tbuildDialogJumpto: { value: uiBuildJumpto },\n\t\tbuildDialogRestart: { value: uiBuildRestart },\n\t\tbuildDialogSaves: { value: uiBuildSaves },\n\t\tbuildDialogSettings: { value: uiBuildSettings },\n\t\tbuildDialogShare: { value: uiBuildShare },\n\t\tbuildLinkListFromPassage: { value: uiAssembleLinkList }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tuibar.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Alert, Dialog, Engine, L10n, Setting, State, Story, UI, Config, setPageElement\n*/\n\nvar UIBar = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// UI bar element cache.\n\n\tvar _$uiBar = null;\n\n\t/*******************************************************************************\n \tUI Bar Functions.\n *******************************************************************************/\n\n\tfunction uiBarDestroy() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UIBar/uiBarDestroy()]');\n\t\t}\n\n\t\tif (!_$uiBar) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Hide the UI bar.\n\t\t_$uiBar.hide();\n\n\t\t// Remove its namespaced events.\n\t\tjQuery(document).off('.ui-bar');\n\n\t\t// Remove its styles.\n\t\tjQuery(document.head).find('#style-ui-bar').remove();\n\n\t\t// Remove it from the DOM.\n\t\t_$uiBar.remove();\n\n\t\t// Drop the reference to the element.\n\t\t_$uiBar = null;\n\t}\n\n\tfunction uiBarHide() {\n\t\tif (_$uiBar) {\n\t\t\t_$uiBar.hide();\n\t\t}\n\n\t\treturn this;\n\t}\n\n\tfunction uiBarInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UIBar/uiBarInit()]');\n\t\t}\n\n\t\tif (document.getElementById('ui-bar')) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Generate the UI bar elements.\n\t\tvar $elems = function () {\n\t\t\tvar toggleLabel = L10n.get('uiBarToggle');\n\t\t\tvar backwardLabel = L10n.get('uiBarBackward');\n\t\t\tvar jumptoLabel = L10n.get('uiBarJumpto');\n\t\t\tvar forwardLabel = L10n.get('uiBarForward');\n\n\t\t\treturn jQuery(document.createDocumentFragment()).append(\n\t\t\t/* eslint-disable max-len */\n\t\t\t'<div id=\"ui-bar\">' + '<div id=\"ui-bar-tray\">' + ('<button id=\"ui-bar-toggle\" tabindex=\"0\" title=\"' + toggleLabel + '\" aria-label=\"' + toggleLabel + '\"></button>') + '<div id=\"ui-bar-history\">' + ('<button id=\"history-backward\" tabindex=\"0\" title=\"' + backwardLabel + '\" aria-label=\"' + backwardLabel + '\">\\uE821</button>') + ('<button id=\"history-jumpto\" tabindex=\"0\" title=\"' + jumptoLabel + '\" aria-label=\"' + jumptoLabel + '\">\\uE839</button>') + ('<button id=\"history-forward\" tabindex=\"0\" title=\"' + forwardLabel + '\" aria-label=\"' + forwardLabel + '\">\\uE822</button>') + '</div>' + '</div>' + '<div id=\"ui-bar-body\">' + '<header id=\"title\" role=\"banner\">' + '<div id=\"story-banner\"></div>' + '<h1 id=\"story-title\"></h1>' + '<div id=\"story-subtitle\"></div>' + '<div id=\"story-title-separator\"></div>' + '<p id=\"story-author\"></p>' + '</header>' + '<div id=\"story-caption\"></div>' + '<nav id=\"menu\" role=\"navigation\">' + '<ul id=\"menu-story\"></ul>' + '<ul id=\"menu-core\">' + ('<li id=\"menu-item-saves\"><a tabindex=\"0\">' + L10n.get('savesTitle') + '</a></li>') + ('<li id=\"menu-item-settings\"><a tabindex=\"0\">' + L10n.get('settingsTitle') + '</a></li>') + ('<li id=\"menu-item-restart\"><a tabindex=\"0\">' + L10n.get('restartTitle') + '</a></li>') + ('<li id=\"menu-item-share\"><a tabindex=\"0\">' + L10n.get('shareTitle') + '</a></li>') + '</ul>' + '</nav>' + '</div>' + '</div>'\n\t\t\t/* eslint-enable max-len */\n\t\t\t);\n\t\t}();\n\n\t\t/*\n  \tCache the UI bar element, since its going to be used often.\n  \t\tNOTE: We rewrap the element itself, rather than simply using the result\n  \tof `find()`, so that we cache an uncluttered jQuery-wrapper (i.e. `context`\n  \trefers to the element and there is no `prevObject`).\n  */\n\t\t_$uiBar = jQuery($elems.find('#ui-bar').get(0));\n\n\t\t// Insert the UI bar elements into the page before the main script.\n\t\t$elems.insertBefore('body>script#script-sugarcube');\n\n\t\t// Set up the UI bar's global event handlers.\n\t\tjQuery(document)\n\t\t// Set up a handler for the history-backward/-forward buttons.\n\t\t.on(':historyupdate.ui-bar', function ($backward, $forward) {\n\t\t\treturn function () {\n\t\t\t\t$backward.ariaDisabled(State.length < 2);\n\t\t\t\t$forward.ariaDisabled(State.length === State.size);\n\t\t\t};\n\t\t}(jQuery('#history-backward'), jQuery('#history-forward')));\n\t}\n\n\tfunction uiBarIsHidden() {\n\t\treturn _$uiBar && _$uiBar.css('display') === 'none';\n\t}\n\n\tfunction uiBarIsStowed() {\n\t\treturn _$uiBar && _$uiBar.hasClass('stowed');\n\t}\n\n\tfunction uiBarShow() {\n\t\tif (_$uiBar) {\n\t\t\t_$uiBar.show();\n\t\t}\n\n\t\treturn this;\n\t}\n\n\tfunction uiBarStart() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UIBar/uiBarStart()]');\n\t\t}\n\n\t\tif (!_$uiBar) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Set up the #ui-bar's initial state.\n\t\tif (typeof Config.ui.stowBarInitially === 'boolean' ? Config.ui.stowBarInitially : jQuery(window).width() <= Config.ui.stowBarInitially) {\n\t\t\t(function () {\n\t\t\t\tvar $uiBarStory = jQuery(_$uiBar).add('#story');\n\t\t\t\t$uiBarStory.addClass('no-transition');\n\t\t\t\t_$uiBar.addClass('stowed');\n\t\t\t\tsetTimeout(function () {\n\t\t\t\t\treturn $uiBarStory.removeClass('no-transition');\n\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t})();\n\t\t}\n\n\t\t// Set up the #ui-bar-toggle and #ui-bar-history widgets.\n\t\tjQuery('#ui-bar-toggle').ariaClick({\n\t\t\tlabel: L10n.get('uiBarToggle')\n\t\t}, function () {\n\t\t\treturn _$uiBar.toggleClass('stowed');\n\t\t});\n\n\t\tif (Config.history.controls) {\n\t\t\tjQuery('#history-backward').ariaDisabled(State.length < 2).ariaClick({\n\t\t\t\tlabel: L10n.get('uiBarBackward')\n\t\t\t}, function () {\n\t\t\t\treturn Engine.backward();\n\t\t\t});\n\n\t\t\tif (Story.lookup('tags', 'bookmark').length > 0) {\n\t\t\t\tjQuery('#history-jumpto').ariaClick({\n\t\t\t\t\tlabel: L10n.get('uiBarJumpto')\n\t\t\t\t}, function () {\n\t\t\t\t\treturn UI.jumpto();\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tjQuery('#history-jumpto').remove();\n\t\t\t}\n\n\t\t\tjQuery('#history-forward').ariaDisabled(State.length === State.size).ariaClick({\n\t\t\t\tlabel: L10n.get('uiBarForward')\n\t\t\t}, function () {\n\t\t\t\treturn Engine.forward();\n\t\t\t});\n\t\t} else {\n\t\t\tjQuery('#ui-bar-history').remove();\n\t\t}\n\n\t\t// Set up the title.\n\t\tif (TWINE1) {\n\t\t\t// for Twine 1\n\t\t\tsetPageElement('story-title', 'StoryTitle', Story.title);\n\t\t} else {\n\t\t\t// for Twine 2\n\t\t\tjQuery('#story-title').text(Story.title);\n\t\t}\n\n\t\t// Set up the dynamic page elements.\n\t\tif (!Story.has('StoryCaption')) {\n\t\t\tjQuery('#story-caption').remove();\n\t\t}\n\n\t\tif (!Story.has('StoryMenu')) {\n\t\t\tjQuery('#menu-story').remove();\n\t\t}\n\n\t\tif (!Config.ui.updateStoryElements) {\n\t\t\t// We only need to set the story elements here if `Config.ui.updateStoryElements`\n\t\t\t// is falsy, since otherwise they will be set by `Engine.play()`.\n\t\t\tuiBarUpdate();\n\t\t}\n\n\t\t// Set up the Saves menu item.\n\t\tjQuery('#menu-item-saves a').ariaClick(function (ev) {\n\t\t\tev.preventDefault();\n\t\t\tUI.buildSaves();\n\t\t\tDialog.open();\n\t\t}).text(L10n.get('savesTitle'));\n\n\t\t// Set up the Settings menu item.\n\t\tif (!Setting.isEmpty()) {\n\t\t\tjQuery('#menu-item-settings a').ariaClick(function (ev) {\n\t\t\t\tev.preventDefault();\n\t\t\t\tUI.buildSettings();\n\t\t\t\tDialog.open();\n\t\t\t}).text(L10n.get('settingsTitle'));\n\t\t} else {\n\t\t\tjQuery('#menu-item-settings').remove();\n\t\t}\n\n\t\t// Set up the Restart menu item.\n\t\tjQuery('#menu-item-restart a').ariaClick(function (ev) {\n\t\t\tev.preventDefault();\n\t\t\tUI.buildRestart();\n\t\t\tDialog.open();\n\t\t}).text(L10n.get('restartTitle'));\n\n\t\t// Set up the Share menu item.\n\t\tif (Story.has('StoryShare')) {\n\t\t\tjQuery('#menu-item-share a').ariaClick(function (ev) {\n\t\t\t\tev.preventDefault();\n\t\t\t\tUI.buildShare();\n\t\t\t\tDialog.open();\n\t\t\t}).text(L10n.get('shareTitle'));\n\t\t} else {\n\t\t\tjQuery('#menu-item-share').remove();\n\t\t}\n\t}\n\n\tfunction uiBarStow(noAnimation) {\n\t\tif (_$uiBar && !_$uiBar.hasClass('stowed')) {\n\t\t\tvar $story = void 0;\n\n\t\t\tif (noAnimation) {\n\t\t\t\t$story = jQuery('#story');\n\t\t\t\t$story.addClass('no-transition');\n\t\t\t\t_$uiBar.addClass('no-transition');\n\t\t\t}\n\n\t\t\t_$uiBar.addClass('stowed');\n\n\t\t\tif (noAnimation) {\n\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t$story.removeClass('no-transition');\n\t\t\t\t\t_$uiBar.removeClass('no-transition');\n\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t}\n\t\t}\n\n\t\treturn this;\n\t}\n\n\tfunction uiBarUnstow(noAnimation) {\n\t\tif (_$uiBar && _$uiBar.hasClass('stowed')) {\n\t\t\tvar $story = void 0;\n\n\t\t\tif (noAnimation) {\n\t\t\t\t$story = jQuery('#story');\n\t\t\t\t$story.addClass('no-transition');\n\t\t\t\t_$uiBar.addClass('no-transition');\n\t\t\t}\n\n\t\t\t_$uiBar.removeClass('stowed');\n\n\t\t\tif (noAnimation) {\n\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t$story.removeClass('no-transition');\n\t\t\t\t\t_$uiBar.removeClass('no-transition');\n\t\t\t\t}, Engine.minDomActionDelay);\n\t\t\t}\n\t\t}\n\n\t\treturn this;\n\t}\n\n\tfunction uiBarUpdate() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[UIBar/uiBarUpdate()]');\n\t\t}\n\n\t\tif (!_$uiBar) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Set up the (non-navigation) dynamic page elements.\n\t\tsetPageElement('story-banner', 'StoryBanner');\n\t\tsetPageElement('story-subtitle', 'StorySubtitle');\n\t\tsetPageElement('story-author', 'StoryAuthor');\n\t\tsetPageElement('story-caption', 'StoryCaption');\n\n\t\t// Set up the #menu-story items.\n\t\tvar menuStory = document.getElementById('menu-story');\n\n\t\tif (menuStory !== null) {\n\t\t\tjQuery(menuStory).empty();\n\n\t\t\tif (Story.has('StoryMenu')) {\n\t\t\t\ttry {\n\t\t\t\t\tUI.assembleLinkList('StoryMenu', menuStory);\n\t\t\t\t} catch (ex) {\n\t\t\t\t\tconsole.error(ex);\n\t\t\t\t\tAlert.error('StoryMenu', ex.message);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t/*******************************************************************************\n \tObject Exports.\n *******************************************************************************/\n\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tdestroy: { value: uiBarDestroy },\n\t\thide: { value: uiBarHide },\n\t\tinit: { value: uiBarInit },\n\t\tisHidden: { value: uiBarIsHidden },\n\t\tisStowed: { value: uiBarIsStowed },\n\t\tshow: { value: uiBarShow },\n\t\tstart: { value: uiBarStart },\n\t\tstow: { value: uiBarStow },\n\t\tunstow: { value: uiBarUnstow },\n\t\tupdate: { value: uiBarUpdate },\n\n\t\t// Legacy Functions.\n\t\tsetStoryElements: { value: uiBarUpdate }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tdebugbar.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal DebugView, Engine, L10n, Patterns, State, Util, session\n*/\n\nvar DebugBar = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\tvar _variableRe = new RegExp('^' + Patterns.variable + '$');\n\tvar _numericKeyRe = /^\\d+$/;\n\tvar _watchList = [];\n\tvar _$debugBar = null;\n\tvar _$watchBody = null;\n\tvar _$watchList = null;\n\tvar _$turnSelect = null;\n\tvar _stowed = true;\n\n\t/*******************************************************************************************************************\n \tDebug Bar Functions.\n *******************************************************************************************************************/\n\tfunction debugBarInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[DebugBar/debugBarInit()]');\n\t\t}\n\n\t\t/*\n  \tGenerate the debug bar elements and append them to the `<body>`.\n  */\n\t\tvar barToggleLabel = L10n.get('debugBarToggle');\n\t\tvar watchAddLabel = L10n.get('debugBarAddWatch');\n\t\tvar watchAllLabel = L10n.get('debugBarWatchAll');\n\t\tvar watchNoneLabel = L10n.get('debugBarWatchNone');\n\t\tvar watchToggleLabel = L10n.get('debugBarWatchToggle');\n\t\tvar viewsToggleLabel = L10n.get('debugBarViewsToggle');\n\n\t\tjQuery(document.createDocumentFragment()).append(\n\t\t/* eslint-disable max-len */\n\t\t'<div id=\"debug-bar\">' + '<div id=\"debug-bar-watch\" aria-hidden=\"true\" hidden=\"hidden\">' + ('<div>' + L10n.get('debugBarNoWatches') + '</div>>') + '</div>' + '<div>' + ('<button id=\"debug-bar-watch-toggle\" tabindex=\"0\" title=\"' + watchToggleLabel + '\" aria-label=\"' + watchToggleLabel + '\">' + L10n.get('debugBarLabelWatch') + '</button>') + ('<label id=\"debug-bar-watch-label\" for=\"debug-bar-watch-input\">' + L10n.get('debugBarLabelAdd') + '</label>') + '<input id=\"debug-bar-watch-input\" name=\"debug-bar-watch-input\" type=\"text\" list=\"debug-bar-watch-list\" tabindex=\"0\">' + '<datalist id=\"debug-bar-watch-list\" aria-hidden=\"true\" hidden=\"hidden\"></datalist>' + ('<button id=\"debug-bar-watch-add\" tabindex=\"0\" title=\"' + watchAddLabel + '\" aria-label=\"' + watchAddLabel + '\"></button>') + ('<button id=\"debug-bar-watch-all\" tabindex=\"0\" title=\"' + watchAllLabel + '\" aria-label=\"' + watchAllLabel + '\"></button>') + ('<button id=\"debug-bar-watch-none\" tabindex=\"0\" title=\"' + watchNoneLabel + '\" aria-label=\"' + watchNoneLabel + '\"></button>') + '</div>' + '<div>' + ('<button id=\"debug-bar-views-toggle\" tabindex=\"0\" title=\"' + viewsToggleLabel + '\" aria-label=\"' + viewsToggleLabel + '\">' + L10n.get('debugBarLabelViews') + '</button>') + ('<label id=\"debug-bar-turn-label\" for=\"debug-bar-turn-select\">' + L10n.get('debugBarLabelTurn') + '</label>') + '<select id=\"debug-bar-turn-select\" tabindex=\"0\"></select>' + '</div>' + ('<button id=\"debug-bar-toggle\" tabindex=\"0\" title=\"' + barToggleLabel + '\" aria-label=\"' + barToggleLabel + '\"></button>') + '</div>' + '<div id=\"debug-bar-hint\"></div>'\n\t\t/* eslint-enable max-len */\n\t\t).appendTo('body');\n\n\t\t/*\n  \tCache various oft used elements.\n  \t\tNOTE: We rewrap the elements themselves, rather than simply using\n  \tthe results of `find()`, so that we cache uncluttered jQuery-wrappers\n  \t(i.e. `context` refers to the elements and there is no `prevObject`).\n  */\n\t\t_$debugBar = jQuery('#debug-bar');\n\t\t_$watchBody = jQuery(_$debugBar.find('#debug-bar-watch').get(0));\n\t\t_$watchList = jQuery(_$debugBar.find('#debug-bar-watch-list').get(0));\n\t\t_$turnSelect = jQuery(_$debugBar.find('#debug-bar-turn-select').get(0));\n\n\t\tvar $barToggle = jQuery(_$debugBar.find('#debug-bar-toggle').get(0));\n\t\tvar $watchToggle = jQuery(_$debugBar.find('#debug-bar-watch-toggle').get(0));\n\t\tvar $watchInput = jQuery(_$debugBar.find('#debug-bar-watch-input').get(0));\n\t\tvar $watchAdd = jQuery(_$debugBar.find('#debug-bar-watch-add').get(0));\n\t\tvar $watchAll = jQuery(_$debugBar.find('#debug-bar-watch-all').get(0));\n\t\tvar $watchNone = jQuery(_$debugBar.find('#debug-bar-watch-none').get(0));\n\t\tvar $viewsToggle = jQuery(_$debugBar.find('#debug-bar-views-toggle').get(0));\n\n\t\t/*\n  \tSet up the debug bar's local event handlers.\n  */\n\t\t$barToggle.ariaClick(function () {\n\t\t\tif (_stowed) {\n\t\t\t\tdebugBarUnstow();\n\t\t\t} else {\n\t\t\t\tdebugBarStow();\n\t\t\t}\n\t\t\t_stowed = !_stowed;\n\t\t\t_updateSession();\n\t\t});\n\t\t$watchToggle.ariaClick(function () {\n\t\t\tif (_$watchBody.attr('hidden')) {\n\t\t\t\t_$watchBody.removeAttr('aria-hidden hidden');\n\t\t\t} else {\n\t\t\t\t_$watchBody.attr({\n\t\t\t\t\t'aria-hidden': true,\n\t\t\t\t\thidden: 'hidden'\n\t\t\t\t});\n\t\t\t}\n\t\t\t_updateSession();\n\t\t});\n\t\t$watchInput.on(':addwatch', function () {\n\t\t\tdebugBarWatchAdd(this.value.trim());\n\t\t\tthis.value = '';\n\t\t}).on('keypress', function (ev) {\n\t\t\tif (ev.which === 13) {\n\t\t\t\t// 13 is Return/Enter\n\t\t\t\tev.preventDefault();\n\t\t\t\t$watchInput.trigger(':addwatch');\n\t\t\t}\n\t\t});\n\t\t$watchAdd.ariaClick(function () {\n\t\t\treturn $watchInput.trigger(':addwatch');\n\t\t});\n\t\t$watchAll.ariaClick(debugBarWatchAddAll);\n\t\t$watchNone.ariaClick(debugBarWatchDeleteAll);\n\t\t_$turnSelect.on('change', function () {\n\t\t\tEngine.goTo(Number(this.value));\n\t\t});\n\t\t$viewsToggle.ariaClick(function () {\n\t\t\tDebugView.toggle();\n\t\t\t_updateSession();\n\t\t});\n\n\t\t/*\n  \tSet up the debug bar's global event handlers.\n  */\n\t\tjQuery(document)\n\t\t// Set up a handler for the history select.\n\t\t.on(':historyupdate.debug-bar', _updateTurnSelect)\n\t\t// Set up a handler for the variables watch.\n\t\t.on(':passageend.debug-bar', function () {\n\t\t\t_updateWatchBody();\n\t\t\t_updateWatchList();\n\t\t})\n\t\t// Set up a handler for engine resets.\n\t\t.on(':enginerestart.debug-bar', function () {\n\t\t\t// Delete the active debug session.\n\t\t\tsession.delete('debugState');\n\t\t});\n\t}\n\n\tfunction debugBarStart() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[DebugBar/debugBarStart()]');\n\t\t}\n\n\t\t// Attempt to restore an existing session.\n\t\t_restoreSession();\n\n\t\t// Update the UI.\n\t\t_updateBar();\n\t\t_updateTurnSelect();\n\t\t_updateWatchBody();\n\t\t_updateWatchList();\n\t}\n\n\tfunction debugBarStow() {\n\t\t_$debugBar.css('right', '-' + _$debugBar.outerWidth() + 'px');\n\t\t_updateSession();\n\t}\n\n\tfunction debugBarUnstow() {\n\t\t_$debugBar.css('right', 0);\n\t\t_updateSession();\n\t}\n\n\tfunction debugBarWatchAdd(varName) {\n\t\tif (!_variableRe.test(varName)) {\n\t\t\treturn;\n\t\t}\n\n\t\t_watchList.pushUnique(varName);\n\t\t_watchList.sort();\n\t\t_updateWatchBody();\n\t\t_updateWatchList();\n\t\t_updateSession();\n\t}\n\n\tfunction debugBarWatchAddAll() {\n\t\tObject.keys(State.variables).map(function (name) {\n\t\t\treturn _watchList.pushUnique('$' + name);\n\t\t});\n\t\tObject.keys(State.temporary).map(function (name) {\n\t\t\treturn _watchList.pushUnique('_' + name);\n\t\t});\n\n\t\t_watchList.sort();\n\t\t_updateWatchBody();\n\t\t_updateWatchList();\n\t\t_updateSession();\n\t}\n\n\tfunction debugBarWatchDelete(varName) {\n\t\t_watchList.delete(varName);\n\t\t_updateWatchBody();\n\t\t_updateWatchList();\n\t\t_updateSession();\n\t}\n\n\tfunction debugBarWatchDeleteAll() {\n\t\tfor (var i = _watchList.length - 1; i >= 0; --i) {\n\t\t\t_watchList.pop();\n\t\t}\n\n\t\t_updateWatchBody();\n\t\t_updateWatchList();\n\t\t_updateSession();\n\t}\n\n\t/*******************************************************************************************************************\n \tUtility Functions.\n *******************************************************************************************************************/\n\tfunction _restoreSession() {\n\t\tif (!session.has('debugState')) {\n\t\t\treturn;\n\t\t}\n\n\t\tvar debugState = session.get('debugState');\n\n\t\t_stowed = debugState.stowed;\n\n\t\t_watchList.push.apply(_watchList, _toConsumableArray(debugState.watchList));\n\n\t\tif (debugState.watchEnabled) {\n\t\t\t_$watchBody.removeAttr('aria-hidden hidden');\n\t\t} else {\n\t\t\t_$watchBody.attr({\n\t\t\t\t'aria-hidden': true,\n\t\t\t\thidden: 'hidden'\n\t\t\t});\n\t\t}\n\n\t\tif (debugState.viewsEnabled) {\n\t\t\tDebugView.enable();\n\t\t} else {\n\t\t\tDebugView.disable();\n\t\t}\n\t}\n\n\tfunction _updateSession() {\n\t\tsession.set('debugState', {\n\t\t\tstowed: _stowed,\n\t\t\twatchList: _watchList,\n\t\t\twatchEnabled: !_$watchBody.attr('hidden'),\n\t\t\tviewsEnabled: DebugView.isEnabled()\n\t\t});\n\t}\n\n\tfunction _updateBar() {\n\t\tif (_stowed) {\n\t\t\tdebugBarStow();\n\t\t} else {\n\t\t\tdebugBarUnstow();\n\t\t}\n\t}\n\n\tfunction _updateWatchBody() {\n\t\tif (_watchList.length === 0) {\n\t\t\t_$watchBody.empty().append('<div>' + L10n.get('debugBarNoWatches') + '</div>');\n\t\t\treturn;\n\t\t}\n\n\t\tvar delLabel = L10n.get('debugBarDeleteWatch');\n\t\tvar $table = jQuery(document.createElement('table'));\n\t\tvar $tbody = jQuery(document.createElement('tbody'));\n\n\t\tvar _loop4 = function _loop4(i, len) {\n\t\t\tvar varName = _watchList[i];\n\t\t\tvar varKey = varName.slice(1);\n\t\t\tvar store = varName[0] === '$' ? State.variables : State.temporary;\n\t\t\tvar $row = jQuery(document.createElement('tr'));\n\t\t\tvar $delBtn = jQuery(document.createElement('button'));\n\t\t\tvar $code = jQuery(document.createElement('code'));\n\n\t\t\t$delBtn.addClass('watch-delete').attr('data-name', varName).ariaClick({\n\t\t\t\tone: true,\n\t\t\t\tlabel: delLabel\n\t\t\t}, function () {\n\t\t\t\treturn debugBarWatchDelete(varName);\n\t\t\t});\n\t\t\t$code.text(_toWatchString(store[varKey]));\n\n\t\t\tjQuery(document.createElement('td')).append($delBtn).appendTo($row);\n\t\t\tjQuery(document.createElement('td')).text(varName).appendTo($row);\n\t\t\tjQuery(document.createElement('td')).append($code).appendTo($row);\n\t\t\t$row.appendTo($tbody);\n\t\t};\n\n\t\tfor (var i = 0, len = _watchList.length; i < len; ++i) {\n\t\t\t_loop4(i, len);\n\t\t}\n\n\t\t$table.append($tbody);\n\t\t_$watchBody.empty().append($table);\n\t}\n\n\tfunction _updateWatchList() {\n\t\tvar svn = Object.keys(State.variables);\n\t\tvar tvn = Object.keys(State.temporary);\n\n\t\tif (svn.length === 0 && tvn.length === 0) {\n\t\t\t_$watchList.empty();\n\t\t\treturn;\n\t\t}\n\n\t\tvar names = [].concat(_toConsumableArray(svn.map(function (name) {\n\t\t\treturn '$' + name;\n\t\t})), _toConsumableArray(tvn.map(function (name) {\n\t\t\treturn '_' + name;\n\t\t}))).sort();\n\t\tvar options = document.createDocumentFragment();\n\n\t\tnames.delete(_watchList);\n\n\t\tfor (var i = 0, len = names.length; i < len; ++i) {\n\t\t\tjQuery(document.createElement('option')).val(names[i]).appendTo(options);\n\t\t}\n\n\t\t_$watchList.empty().append(options);\n\t}\n\n\tfunction _updateTurnSelect() {\n\t\tvar histLen = State.size;\n\t\tvar expLen = State.expired.length;\n\t\tvar options = document.createDocumentFragment();\n\n\t\tfor (var i = 0; i < histLen; ++i) {\n\t\t\tjQuery(document.createElement('option')).val(i).text(expLen + i + 1 + '. ' + Util.escape(State.history[i].title)).appendTo(options);\n\t\t}\n\n\t\t_$turnSelect.empty().ariaDisabled(histLen < 2).append(options).val(State.activeIndex);\n\t}\n\n\tfunction _toWatchString(value) {\n\t\t/*\n  \tHandle the `null` primitive.\n  */\n\t\tif (value === null) {\n\t\t\treturn 'null';\n\t\t}\n\n\t\t/*\n  \tHandle the rest of the primitives and functions.\n  */\n\t\tswitch (typeof value === 'undefined' ? 'undefined' : _typeof(value)) {\n\t\t\tcase 'number':\n\t\t\t\tif (Number.isNaN(value)) {\n\t\t\t\t\treturn 'NaN';\n\t\t\t\t} else if (!Number.isFinite(value)) {\n\t\t\t\t\treturn 'Infinity';\n\t\t\t\t}\n\t\t\t/* falls through */\n\t\t\tcase 'boolean':\n\t\t\tcase 'symbol':\n\t\t\tcase 'undefined':\n\t\t\t\treturn String(value);\n\n\t\t\tcase 'string':\n\t\t\t\treturn JSON.stringify(value);\n\n\t\t\t// case 'symbol':\n\t\t\t// \treturn `Symbol\\u202F\"${String(value).slice(7, -1)}\"`;\n\n\t\t\tcase 'function':\n\t\t\t\t// return JSON.stringify(value.toString());\n\t\t\t\treturn 'Function';\n\t\t}\n\n\t\tvar objType = Util.toStringTag(value);\n\n\t\t// /*\n\t\t// \tHandle instances of the primitive exemplar objects (`Boolean`, `Number`, `String`).\n\t\t// */\n\t\t// if (objType === 'Boolean') {\n\t\t// \treturn `Boolean\\u202F{${String(value)}}`;\n\t\t// }\n\t\t// if (objType === 'Number') {\n\t\t// \treturn `Number\\u202F{${String(value)}}`;\n\t\t// }\n\t\t// if (objType === 'String') {\n\t\t// \treturn `String\\u202F{\"${String(value)}\"}`;\n\t\t// }\n\n\t\t/*\n  \tHandle `Date` objects.\n  */\n\t\tif (objType === 'Date') {\n\t\t\t// return `Date\\u202F${value.toISOString()}`;\n\t\t\treturn 'Date\\u202F{' + value.toLocaleString() + '}';\n\t\t}\n\n\t\t/*\n  \tHandle `RegExp` objects.\n  */\n\t\tif (objType === 'RegExp') {\n\t\t\treturn 'RegExp\\u202F' + value.toString();\n\t\t}\n\n\t\tvar result = [];\n\n\t\t/*\n  \tHandle `Array` & `Set` objects.\n  */\n\t\tif (value instanceof Array || value instanceof Set) {\n\t\t\tvar list = value instanceof Array ? value : Array.from(value);\n\n\t\t\t// own numeric properties\n\t\t\t// NOTE: Do not use `<Array>.forEach()` here as it skips undefined members.\n\t\t\tfor (var i = 0, len = list.length; i < len; ++i) {\n\t\t\t\tresult.push(list.hasOwnProperty(i) ? _toWatchString(list[i]) : '<empty>');\n\t\t\t}\n\n\t\t\t// own enumerable non-numeric expando properties\n\t\t\tObject.keys(list).filter(function (key) {\n\t\t\t\treturn !_numericKeyRe.test(key);\n\t\t\t}).forEach(function (key) {\n\t\t\t\treturn result.push(_toWatchString(key) + ': ' + _toWatchString(list[key]));\n\t\t\t});\n\n\t\t\treturn objType + '(' + list.length + ')\\u202F[' + result.join(', ') + ']';\n\t\t}\n\n\t\t/*\n  \tHandle `Map` objects.\n  */\n\t\tif (value instanceof Map) {\n\t\t\tvalue.forEach(function (val, key) {\n\t\t\t\treturn result.push(_toWatchString(key) + ' \\u2192 ' + _toWatchString(val));\n\t\t\t});\n\n\t\t\treturn objType + '(' + value.size + ')\\u202F{' + result.join(', ') + '}';\n\t\t}\n\n\t\t/*\n  \tGeneral object handling.\n  */\n\t\t// own enumerable properties\n\t\tObject.keys(value).forEach(function (key) {\n\t\t\treturn result.push(_toWatchString(key) + ': ' + _toWatchString(value[key]));\n\t\t});\n\n\t\treturn objType + '\\u202F{' + result.join(', ') + '}';\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\t/*\n  \tDebug Bar Functions.\n  */\n\t\tinit: { value: debugBarInit },\n\t\tstart: { value: debugBarStart },\n\t\tstow: { value: debugBarStow },\n\t\tunstow: { value: debugBarUnstow },\n\n\t\t/*\n  \tWatch Functions.\n  */\n\t\twatch: { value: debugBarWatchAdd },\n\t\twatchAll: { value: debugBarWatchAddAll },\n\t\tunwatch: { value: debugBarWatchDelete },\n\t\tunwatchAll: { value: debugBarWatchDeleteAll }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tloadscreen.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/* global Config, Engine */\n\nvar LoadScreen = function () {\n\t// eslint-disable-line no-unused-vars, no-var\n\t'use strict';\n\n\t// Locks collection.\n\n\tvar _locks = new Set();\n\n\t// Auto-incrementing lock ID.\n\tvar _autoId = 0;\n\n\t/*******************************************************************************************************************\n \tLoadScreen Functions.\n *******************************************************************************************************************/\n\t/*\n \tInitialize management of the loading screen.\n */\n\tfunction loadScreenInit() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[LoadScreen/loadScreenInit()]');\n\t\t}\n\n\t\t// Add a `readystatechange` listener for hiding/showing the loading screen.\n\t\tjQuery(document).on('readystatechange.SugarCube', function () {\n\t\t\tif (DEBUG) {\n\t\t\t\tconsole.log('[LoadScreen/<readystatechange>] document.readyState: \"' + document.readyState + '\"; locks(' + _locks.size + '):', _locks);\n\t\t\t}\n\n\t\t\tif (_locks.size > 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// The value of `document.readyState` may be: 'loading' -> 'interactive' -> 'complete'.\n\t\t\t// Though, to reach this point, it must already be in, at least, the 'interactive' state.\n\t\t\tif (document.readyState === 'complete') {\n\t\t\t\tif (jQuery(document.documentElement).attr('data-init') === 'loading') {\n\t\t\t\t\tif (Config.loadDelay > 0) {\n\t\t\t\t\t\tsetTimeout(function () {\n\t\t\t\t\t\t\tif (_locks.size === 0) {\n\t\t\t\t\t\t\t\tloadScreenHide();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}, Math.max(Engine.minDomActionDelay, Config.loadDelay));\n\t\t\t\t\t} else {\n\t\t\t\t\t\tloadScreenHide();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tloadScreenShow();\n\t\t\t}\n\t\t});\n\t}\n\n\t/*\n \tClear the loading screen.\n */\n\tfunction loadScreenClear() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[LoadScreen/loadScreenClear()]');\n\t\t}\n\n\t\t// Remove the event listener.\n\t\tjQuery(document).off('readystatechange.SugarCube');\n\n\t\t// Clear all locks.\n\t\t_locks.clear();\n\n\t\t// Hide the loading screen.\n\t\tloadScreenHide();\n\t}\n\n\t/*\n \tHide the loading screen.\n */\n\tfunction loadScreenHide() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[LoadScreen/loadScreenHide()]');\n\t\t}\n\n\t\tjQuery(document.documentElement).removeAttr('data-init');\n\t}\n\n\t/*\n \tShow the loading screen.\n */\n\tfunction loadScreenShow() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[LoadScreen/loadScreenShow()]');\n\t\t}\n\n\t\tjQuery(document.documentElement).attr('data-init', 'loading');\n\t}\n\n\t/*\n \tReturns a new lock ID after locking and showing the loading screen.\n */\n\tfunction loadScreenLock() {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[LoadScreen/loadScreenLock()]');\n\t\t}\n\n\t\t++_autoId;\n\t\t_locks.add(_autoId);\n\n\t\tif (DEBUG) {\n\t\t\tconsole.log('\\tacquired loading screen lock; id: ' + _autoId);\n\t\t}\n\n\t\tloadScreenShow();\n\t\treturn _autoId;\n\t}\n\n\t/*\n \tRemove the lock associated with the given lock ID and, if no locks remain,\n \ttrigger a `readystatechange` event.\n */\n\tfunction loadScreenUnlock(id) {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[LoadScreen/loadScreenUnlock(id: ' + id + ')]');\n\t\t}\n\n\t\tif (id == null) {\n\t\t\t// lazy equality for null\n\t\t\tthrow new Error('LoadScreen.unlock called with a null or undefined ID');\n\t\t}\n\n\t\tif (_locks.has(id)) {\n\t\t\t_locks.delete(id);\n\n\t\t\tif (DEBUG) {\n\t\t\t\tconsole.log('\\treleased loading screen lock; id: ' + id);\n\t\t\t}\n\t\t}\n\n\t\tif (_locks.size === 0) {\n\t\t\tjQuery(document).trigger('readystatechange');\n\t\t}\n\t}\n\n\t/*******************************************************************************************************************\n \tModule Exports.\n *******************************************************************************************************************/\n\treturn Object.freeze(Object.defineProperties({}, {\n\t\tinit: { value: loadScreenInit },\n\t\tclear: { value: loadScreenClear },\n\t\thide: { value: loadScreenHide },\n\t\tshow: { value: loadScreenShow },\n\t\tlock: { value: loadScreenLock },\n\t\tunlock: { value: loadScreenUnlock }\n\t}));\n}();\n\n/***********************************************************************************************************************\n\n\tsugarcube.js\n\n\tCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>. All rights reserved.\n\tUse of this source code is governed by a BSD 2-clause \"Simplified\" License, which may be found in the LICENSE file.\n\n***********************************************************************************************************************/\n/*\n\tglobal Alert, Browser, Config, Dialog, Engine, Has, LoadScreen, SimpleStore, L10n, Macro, Passage, Save,\n\t       Scripting, Setting, SimpleAudio, State, Story, UI, UIBar, DebugBar, Util, Visibility, Wikifier\n*/\n/* eslint-disable no-var */\n\n/*\n\tVersion object.\n*/\nvar version = Object.freeze({\n\ttitle: 'SugarCube',\n\tmajor: 2,\n\tminor: 29,\n\tpatch: 0,\n\tprerelease: null,\n\tbuild: 46,\n\tdate: new Date(\"2019-07-07T20:57:56.998Z\"),\n\t/* legacy */\n\textensions: {},\n\t/* /legacy */\n\n\ttoString: function toString() {\n\t\t'use strict';\n\n\t\tvar prerelease = this.prerelease ? '-' + this.prerelease : '';\n\t\treturn this.major + '.' + this.minor + '.' + this.patch + prerelease + '+' + this.build;\n\t},\n\tshort: function short() {\n\t\t'use strict';\n\n\t\tvar prerelease = this.prerelease ? '-' + this.prerelease : '';\n\t\treturn this.title + ' (v' + this.major + '.' + this.minor + '.' + this.patch + prerelease + ')';\n\t},\n\tlong: function long() {\n\t\t'use strict';\n\n\t\treturn this.title + ' v' + this.toString() + ' (' + this.date.toUTCString() + ')';\n\t}\n});\n\n/* eslint-disable no-unused-vars */\n/*\n\tInternal variables.\n*/\n// Temporary state object.\nvar TempState = {};\n\n// Legacy macros object.\nvar macros = {};\n\n// Post-display task callbacks object.\nvar postdisplay = {};\n\n// Post-render task callbacks object.\nvar postrender = {};\n\n// Pre-display task callbacks object.\nvar predisplay = {};\n\n// Pre-history task callbacks object.\nvar prehistory = {};\n\n// Pre-render task callbacks object.\nvar prerender = {};\n\n// Session storage manager object.\nvar session = null;\n\n// Settings object.\nvar settings = {};\n\n// Setup object.\nvar setup = {};\n\n// Persistant storage manager object.\nvar storage = null;\n\n/*\n\tLegacy aliases.\n*/\nvar browser = Browser;\nvar config = Config;\nvar has = Has;\nvar History = State;\nvar state = State;\nvar tale = Story;\nvar TempVariables = State.temporary;\n/* eslint-enable no-unused-vars */\n\n/*\n\tGlobal `SugarCube` object.  Allows scripts to detect if they're running in SugarCube by\n\ttesting for the object (e.g. `\"SugarCube\" in window`) and contains exported identifiers\n\tfor debugging purposes.\n*/\nwindow.SugarCube = {};\n\n/*\n\tMain function, entry point for the story.\n*/\njQuery(function () {\n\t'use strict';\n\n\ttry {\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[SugarCube/main()] Document loaded; beginning startup.');\n\t\t}\n\n\t\t/*\n  \tWARNING!\n  \t\tThe ordering of the code within this function is critically important,\n  \tso be careful when mucking around with it.\n  */\n\n\t\t// Acquire an initial lock for and initialize the loading screen.\n\t\tvar lockId = LoadScreen.lock();\n\t\tLoadScreen.init();\n\n\t\t// Normalize the document.\n\t\tif (document.normalize) {\n\t\t\tdocument.normalize();\n\t\t}\n\n\t\t// Load the story data (must be done before most anything else).\n\t\tStory.load();\n\n\t\t// Instantiate the storage and session objects.\n\t\t// NOTE: `SimpleStore.create(storageId, persistent)`\n\t\tstorage = SimpleStore.create(Story.domId, true);\n\t\tsession = SimpleStore.create(Story.domId, false);\n\n\t\t// Initialize the user interface (must be done before story initialization, specifically before scripts).\n\t\tDialog.init();\n\t\tUIBar.init();\n\t\tEngine.init();\n\n\t\t// Initialize the story (largely load the user styles, scripts, and widgets).\n\t\tStory.init();\n\n\t\t// Initialize the localization (must be done after story initialization).\n\t\tL10n.init();\n\n\t\t// Alert when the browser is degrading required capabilities (must be done after localization initialization).\n\t\tif (!session.has('rcWarn') && storage.name === 'cookie') {\n\t\t\t/* eslint-disable no-alert */\n\t\t\tsession.set('rcWarn', 1);\n\t\t\twindow.alert(L10n.get('warningNoWebStorage'));\n\t\t\t/* eslint-enable no-alert */\n\t\t}\n\n\t\t// Initialize the saves (must be done after story initialization, but before engine start).\n\t\tSave.init();\n\n\t\t// Initialize the settings.\n\t\tSetting.init();\n\n\t\t// Initialize the macros.\n\t\tMacro.init();\n\n\t\t// Start the engine (should be done as late as possible, but before interface startup).\n\t\tEngine.start();\n\n\t\t// Initialize the debug bar interface (should be done as late as possible, but before interface startup).\n\t\tif (Config.debug) {\n\t\t\tDebugBar.init();\n\t\t}\n\n\t\t// Set a timer to start the interfaces (necessary due to DOM readiness issues in some browsers).\n\t\tvar $window = $(window);\n\t\tvar vprCheckId = setInterval(function () {\n\t\t\tif (!$window.width()) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tclearInterval(vprCheckId);\n\t\t\tsetTimeout(function () {\n\t\t\t\t// Start the UI bar interface.\n\t\t\t\tUIBar.start();\n\n\t\t\t\t// Start the debug bar interface.\n\t\t\t\tif (Config.debug) {\n\t\t\t\t\tDebugBar.start();\n\t\t\t\t}\n\n\t\t\t\t// Release the loading screen lock.\n\t\t\t\tLoadScreen.unlock(lockId);\n\t\t\t}, Engine.minDomActionDelay);\n\t\t}, Engine.minDomActionDelay);\n\n\t\t// Finally, export identifiers for debugging purposes.\n\t\twindow.SugarCube = {\n\t\t\tBrowser: Browser,\n\t\t\tConfig: Config,\n\t\t\tDialog: Dialog,\n\t\t\tEngine: Engine,\n\t\t\tHas: Has,\n\t\t\tL10n: L10n,\n\t\t\tMacro: Macro,\n\t\t\tPassage: Passage,\n\t\t\tSave: Save,\n\t\t\tScripting: Scripting,\n\t\t\tSetting: Setting,\n\t\t\tSimpleAudio: SimpleAudio,\n\t\t\tState: State,\n\t\t\tStory: Story,\n\t\t\tUI: UI,\n\t\t\tUIBar: UIBar,\n\t\t\tDebugBar: DebugBar,\n\t\t\tUtil: Util,\n\t\t\tVisibility: Visibility,\n\t\t\tWikifier: Wikifier,\n\t\t\tsession: session,\n\t\t\tsettings: settings,\n\t\t\tsetup: setup,\n\t\t\tstorage: storage,\n\t\t\tversion: version\n\t\t};\n\n\t\tif (DEBUG) {\n\t\t\tconsole.log('[SugarCube/main()] Startup complete; story ready.');\n\t\t}\n\t} catch (ex) {\n\t\tconsole.error(ex);\n\t\tLoadScreen.clear();\n\t\treturn Alert.fatal(null, ex.message, ex);\n\t}\n});\n})(window, window.document, jQuery);\n}\n\t</script>\n</body>\n</html>\n"});
\ No newline at end of file
diff --git a/devNotes/sugarcube stuff/2.29.0-format.js b/devNotes/sugarcube stuff/2.29.0-format.js
new file mode 100644
index 00000000000..c59af8cd5e1
--- /dev/null
+++ b/devNotes/sugarcube stuff/2.29.0-format.js	
@@ -0,0 +1 @@
+window.storyFormat({"name":"SugarCube","version":"2.29.0","description":"A full featured, highly customizable story format.  See its <a href=\"http://www.motoslave.net/sugarcube/2/#documentation\" target=\"_blank\">documentation</a>.","author":"Thomas Michael Edwards","image":"icon.svg","url":"http://www.motoslave.net/sugarcube/","license":"BSD-2-Clause","proofing":false,"source":"<!DOCTYPE html>\n<html data-init=\"no-js\">\n<head>\n<meta charset=\"UTF-8\" />\n<title>{{STORY_NAME}}</title>\n<meta name=\"viewport\" content=\"width=device-width,initial-scale=1\" />\n<!--\n\nSugarCube (v2.29.0): A free (gratis and libre) story format.\n\nCopyright © 2013–2019 Thomas Michael Edwards <thomasmedwards@gmail.com>.\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this\n   list of conditions and the following disclaimer.\n2. Redistributions in binary form must reproduce the above copyright notice,\n   this list of conditions and the following disclaimer in the documentation\n   and/or other materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\nANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\nWARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR\nANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\nLOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\nON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS\nSOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n\n-->\n<script id=\"script-libraries\" type=\"text/javascript\">\nif(document.head&&document.addEventListener&&document.querySelector&&Object.create&&Object.freeze&&JSON){document.documentElement.setAttribute(\"data-init\", \"loading\");\n/*! @source http://purl.eligrey.com/github/classList.js/blob/master/classList.js */\nif(\"document\" in self){if(!(\"classList\" in document.createElement(\"_\"))){(function(j){\"use strict\";if(!(\"Element\" in j)){return}var a=\"classList\",f=\"prototype\",m=j.Element[f],b=Object,k=String[f].trim||function(){return this.replace(/^\\s+|\\s+$/g,\"\")},c=Array[f].indexOf||function(q){var p=0,o=this.length;for(;p<o;p++){if(p in this&&this[p]===q){return p}}return -1},n=function(o,p){this.name=o;this.code=DOMException[o];this.message=p},g=function(p,o){if(o===\"\"){throw new n(\"SYNTAX_ERR\",\"An invalid or illegal string was specified\")}if(/\\s/.test(o)){throw new n(\"INVALID_CHARACTER_ERR\",\"String contains an invalid character\")}return c.call(p,o)},d=function(s){var r=k.call(s.getAttribute(\"class\")||\"\"),q=r?r.split(/\\s+/):[],p=0,o=q.length;for(;p<o;p++){this.push(q[p])}this._updateClassName=function(){s.setAttribute(\"class\",this.toString())}},e=d[f]=[],i=function(){return new d(this)};n[f]=Error[f];e.item=function(o){return this[o]||null};e.contains=function(o){o+=\"\";return g(this,o)!==-1};e.add=function(){var s=arguments,r=0,p=s.length,q,o=false;do{q=s[r]+\"\";if(g(this,q)===-1){this.push(q);o=true}}while(++r<p);if(o){this._updateClassName()}};e.remove=function(){var t=arguments,s=0,p=t.length,r,o=false,q;do{r=t[s]+\"\";q=g(this,r);while(q!==-1){this.splice(q,1);o=true;q=g(this,r)}}while(++s<p);if(o){this._updateClassName()}};e.toggle=function(p,q){p+=\"\";var o=this.contains(p),r=o?q!==true&&\"remove\":q!==false&&\"add\";if(r){this[r](p)}if(q===true||q===false){return q}else{return !o}};e.toString=function(){return this.join(\" \")};if(b.defineProperty){var l={get:i,enumerable:true,configurable:true};try{b.defineProperty(m,a,l)}catch(h){if(h.number===-2146823252){l.enumerable=false;b.defineProperty(m,a,l)}}}else{if(b[f].__defineGetter__){m.__defineGetter__(a,i)}}}(self))}else{(function(){var b=document.createElement(\"_\");b.classList.add(\"c1\",\"c2\");if(!b.classList.contains(\"c2\")){var c=function(e){var d=DOMTokenList.prototype[e];DOMTokenList.prototype[e]=function(h){var g,f=arguments.length;for(g=0;g<f;g++){h=arguments[g];d.call(this,h)}}};c(\"add\");c(\"remove\")}b.classList.toggle(\"c3\",false);if(b.classList.contains(\"c3\")){var a=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(d,e){if(1 in arguments&&!this.contains(d)===!e){return e}else{return a.call(this,d)}}}b=null}())}};\n/*!\n * https://github.com/es-shims/es5-shim\n * @license es5-shim Copyright 2009-2015 by contributors, MIT License\n * see https://github.com/es-shims/es5-shim/blob/v4.5.13/LICENSE\n */\n(function(t,r){\"use strict\";if(typeof define===\"function\"&&define.amd){define(r)}else if(typeof exports===\"object\"){module.exports=r()}else{t.returnExports=r()}})(this,function(){var t=Array;var r=t.prototype;var e=Object;var n=e.prototype;var i=Function;var a=i.prototype;var o=String;var f=o.prototype;var u=Number;var l=u.prototype;var s=r.slice;var c=r.splice;var v=r.push;var h=r.unshift;var p=r.concat;var y=r.join;var d=a.call;var g=a.apply;var w=Math.max;var b=Math.min;var T=n.toString;var m=typeof Symbol===\"function\"&&typeof Symbol.toStringTag===\"symbol\";var D;var S=Function.prototype.toString,x=/^\\s*class /,O=function isES6ClassFn(t){try{var r=S.call(t);var e=r.replace(/\\/\\/.*\\n/g,\"\");var n=e.replace(/\\/\\*[.\\s\\S]*\\*\\//g,\"\");var i=n.replace(/\\n/gm,\" \").replace(/ {2}/g,\" \");return x.test(i)}catch(a){return false}},E=function tryFunctionObject(t){try{if(O(t)){return false}S.call(t);return true}catch(r){return false}},j=\"[object Function]\",I=\"[object GeneratorFunction]\",D=function isCallable(t){if(!t){return false}if(typeof t!==\"function\"&&typeof t!==\"object\"){return false}if(m){return E(t)}if(O(t)){return false}var r=T.call(t);return r===j||r===I};var M;var U=RegExp.prototype.exec,$=function tryRegexExec(t){try{U.call(t);return true}catch(r){return false}},F=\"[object RegExp]\";M=function isRegex(t){if(typeof t!==\"object\"){return false}return m?$(t):T.call(t)===F};var N;var C=String.prototype.valueOf,k=function tryStringObject(t){try{C.call(t);return true}catch(r){return false}},A=\"[object String]\";N=function isString(t){if(typeof t===\"string\"){return true}if(typeof t!==\"object\"){return false}return m?k(t):T.call(t)===A};var R=e.defineProperty&&function(){try{var t={};e.defineProperty(t,\"x\",{enumerable:false,value:t});for(var r in t){return false}return t.x===t}catch(n){return false}}();var P=function(t){var r;if(R){r=function(t,r,n,i){if(!i&&r in t){return}e.defineProperty(t,r,{configurable:true,enumerable:false,writable:true,value:n})}}else{r=function(t,r,e,n){if(!n&&r in t){return}t[r]=e}}return function defineProperties(e,n,i){for(var a in n){if(t.call(n,a)){r(e,a,n[a],i)}}}}(n.hasOwnProperty);var J=function isPrimitive(t){var r=typeof t;return t===null||r!==\"object\"&&r!==\"function\"};var Y=u.isNaN||function isActualNaN(t){return t!==t};var z={ToInteger:function ToInteger(t){var r=+t;if(Y(r)){r=0}else if(r!==0&&r!==1/0&&r!==-(1/0)){r=(r>0||-1)*Math.floor(Math.abs(r))}return r},ToPrimitive:function ToPrimitive(t){var r,e,n;if(J(t)){return t}e=t.valueOf;if(D(e)){r=e.call(t);if(J(r)){return r}}n=t.toString;if(D(n)){r=n.call(t);if(J(r)){return r}}throw new TypeError},ToObject:function(t){if(t==null){throw new TypeError(\"can't convert \"+t+\" to object\")}return e(t)},ToUint32:function ToUint32(t){return t>>>0}};var Z=function Empty(){};P(a,{bind:function bind(t){var r=this;if(!D(r)){throw new TypeError(\"Function.prototype.bind called on incompatible \"+r)}var n=s.call(arguments,1);var a;var o=function(){if(this instanceof a){var i=g.call(r,this,p.call(n,s.call(arguments)));if(e(i)===i){return i}return this}else{return g.call(r,t,p.call(n,s.call(arguments)))}};var f=w(0,r.length-n.length);var u=[];for(var l=0;l<f;l++){v.call(u,\"$\"+l)}a=i(\"binder\",\"return function (\"+y.call(u,\",\")+\"){ return binder.apply(this, arguments); }\")(o);if(r.prototype){Z.prototype=r.prototype;a.prototype=new Z;Z.prototype=null}return a}});var G=d.bind(n.hasOwnProperty);var H=d.bind(n.toString);var W=d.bind(s);var B=g.bind(s);if(typeof document===\"object\"&&document&&document.documentElement){try{W(document.documentElement.childNodes)}catch(X){var L=W;var q=B;W=function arraySliceIE(t){var r=[];var e=t.length;while(e-- >0){r[e]=t[e]}return q(r,L(arguments,1))};B=function arraySliceApplyIE(t,r){return q(W(t),r)}}}var K=d.bind(f.slice);var Q=d.bind(f.split);var V=d.bind(f.indexOf);var _=d.bind(v);var tt=d.bind(n.propertyIsEnumerable);var rt=d.bind(r.sort);var et=t.isArray||function isArray(t){return H(t)===\"[object Array]\"};var nt=[].unshift(0)!==1;P(r,{unshift:function(){h.apply(this,arguments);return this.length}},nt);P(t,{isArray:et});var it=e(\"a\");var at=it[0]!==\"a\"||!(0 in it);var ot=function properlyBoxed(t){var r=true;var e=true;var n=false;if(t){try{t.call(\"foo\",function(t,e,n){if(typeof n!==\"object\"){r=false}});t.call([1],function(){\"use strict\";e=typeof this===\"string\"},\"x\")}catch(i){n=true}}return!!t&&!n&&r&&e};P(r,{forEach:function forEach(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=-1;var i=z.ToUint32(e.length);var a;if(arguments.length>1){a=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.forEach callback must be a function\")}while(++n<i){if(n in e){if(typeof a===\"undefined\"){t(e[n],n,r)}else{t.call(a,e[n],n,r)}}}}},!ot(r.forEach));P(r,{map:function map(r){var e=z.ToObject(this);var n=at&&N(this)?Q(this,\"\"):e;var i=z.ToUint32(n.length);var a=t(i);var o;if(arguments.length>1){o=arguments[1]}if(!D(r)){throw new TypeError(\"Array.prototype.map callback must be a function\")}for(var f=0;f<i;f++){if(f in n){if(typeof o===\"undefined\"){a[f]=r(n[f],f,e)}else{a[f]=r.call(o,n[f],f,e)}}}return a}},!ot(r.map));P(r,{filter:function filter(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);var i=[];var a;var o;if(arguments.length>1){o=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.filter callback must be a function\")}for(var f=0;f<n;f++){if(f in e){a=e[f];if(typeof o===\"undefined\"?t(a,f,r):t.call(o,a,f,r)){_(i,a)}}}return i}},!ot(r.filter));P(r,{every:function every(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);var i;if(arguments.length>1){i=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.every callback must be a function\")}for(var a=0;a<n;a++){if(a in e&&!(typeof i===\"undefined\"?t(e[a],a,r):t.call(i,e[a],a,r))){return false}}return true}},!ot(r.every));P(r,{some:function some(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);var i;if(arguments.length>1){i=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.some callback must be a function\")}for(var a=0;a<n;a++){if(a in e&&(typeof i===\"undefined\"?t(e[a],a,r):t.call(i,e[a],a,r))){return true}}return false}},!ot(r.some));var ft=false;if(r.reduce){ft=typeof r.reduce.call(\"es5\",function(t,r,e,n){return n})===\"object\"}P(r,{reduce:function reduce(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);if(!D(t)){throw new TypeError(\"Array.prototype.reduce callback must be a function\")}if(n===0&&arguments.length===1){throw new TypeError(\"reduce of empty array with no initial value\")}var i=0;var a;if(arguments.length>=2){a=arguments[1]}else{do{if(i in e){a=e[i++];break}if(++i>=n){throw new TypeError(\"reduce of empty array with no initial value\")}}while(true)}for(;i<n;i++){if(i in e){a=t(a,e[i],i,r)}}return a}},!ft);var ut=false;if(r.reduceRight){ut=typeof r.reduceRight.call(\"es5\",function(t,r,e,n){return n})===\"object\"}P(r,{reduceRight:function reduceRight(t){var r=z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=z.ToUint32(e.length);if(!D(t)){throw new TypeError(\"Array.prototype.reduceRight callback must be a function\")}if(n===0&&arguments.length===1){throw new TypeError(\"reduceRight of empty array with no initial value\")}var i;var a=n-1;if(arguments.length>=2){i=arguments[1]}else{do{if(a in e){i=e[a--];break}if(--a<0){throw new TypeError(\"reduceRight of empty array with no initial value\")}}while(true)}if(a<0){return i}do{if(a in e){i=t(i,e[a],a,r)}}while(a--);return i}},!ut);var lt=r.indexOf&&[0,1].indexOf(1,2)!==-1;P(r,{indexOf:function indexOf(t){var r=at&&N(this)?Q(this,\"\"):z.ToObject(this);var e=z.ToUint32(r.length);if(e===0){return-1}var n=0;if(arguments.length>1){n=z.ToInteger(arguments[1])}n=n>=0?n:w(0,e+n);for(;n<e;n++){if(n in r&&r[n]===t){return n}}return-1}},lt);var st=r.lastIndexOf&&[0,1].lastIndexOf(0,-3)!==-1;P(r,{lastIndexOf:function lastIndexOf(t){var r=at&&N(this)?Q(this,\"\"):z.ToObject(this);var e=z.ToUint32(r.length);if(e===0){return-1}var n=e-1;if(arguments.length>1){n=b(n,z.ToInteger(arguments[1]))}n=n>=0?n:e-Math.abs(n);for(;n>=0;n--){if(n in r&&t===r[n]){return n}}return-1}},st);var ct=function(){var t=[1,2];var r=t.splice();return t.length===2&&et(r)&&r.length===0}();P(r,{splice:function splice(t,r){if(arguments.length===0){return[]}else{return c.apply(this,arguments)}}},!ct);var vt=function(){var t={};r.splice.call(t,0,0,1);return t.length===1}();P(r,{splice:function splice(t,r){if(arguments.length===0){return[]}var e=arguments;this.length=w(z.ToInteger(this.length),0);if(arguments.length>0&&typeof r!==\"number\"){e=W(arguments);if(e.length<2){_(e,this.length-t)}else{e[1]=z.ToInteger(r)}}return c.apply(this,e)}},!vt);var ht=function(){var r=new t(1e5);r[8]=\"x\";r.splice(1,1);return r.indexOf(\"x\")===7}();var pt=function(){var t=256;var r=[];r[t]=\"a\";r.splice(t+1,0,\"b\");return r[t]===\"a\"}();P(r,{splice:function splice(t,r){var e=z.ToObject(this);var n=[];var i=z.ToUint32(e.length);var a=z.ToInteger(t);var f=a<0?w(i+a,0):b(a,i);var u=b(w(z.ToInteger(r),0),i-f);var l=0;var s;while(l<u){s=o(f+l);if(G(e,s)){n[l]=e[s]}l+=1}var c=W(arguments,2);var v=c.length;var h;if(v<u){l=f;var p=i-u;while(l<p){s=o(l+u);h=o(l+v);if(G(e,s)){e[h]=e[s]}else{delete e[h]}l+=1}l=i;var y=i-u+v;while(l>y){delete e[l-1];l-=1}}else if(v>u){l=i-u;while(l>f){s=o(l+u-1);h=o(l+v-1);if(G(e,s)){e[h]=e[s]}else{delete e[h]}l-=1}}l=f;for(var d=0;d<c.length;++d){e[l]=c[d];l+=1}e.length=i-u+v;return n}},!ht||!pt);var yt=r.join;var dt;try{dt=Array.prototype.join.call(\"123\",\",\")!==\"1,2,3\"}catch(X){dt=true}if(dt){P(r,{join:function join(t){var r=typeof t===\"undefined\"?\",\":t;return yt.call(N(this)?Q(this,\"\"):this,r)}},dt)}var gt=[1,2].join(undefined)!==\"1,2\";if(gt){P(r,{join:function join(t){var r=typeof t===\"undefined\"?\",\":t;return yt.call(this,r)}},gt)}var wt=function push(t){var r=z.ToObject(this);var e=z.ToUint32(r.length);var n=0;while(n<arguments.length){r[e+n]=arguments[n];n+=1}r.length=e+n;return e+n};var bt=function(){var t={};var r=Array.prototype.push.call(t,undefined);return r!==1||t.length!==1||typeof t[0]!==\"undefined\"||!G(t,0)}();P(r,{push:function push(t){if(et(this)){return v.apply(this,arguments)}return wt.apply(this,arguments)}},bt);var Tt=function(){var t=[];var r=t.push(undefined);return r!==1||t.length!==1||typeof t[0]!==\"undefined\"||!G(t,0)}();P(r,{push:wt},Tt);P(r,{slice:function(t,r){var e=N(this)?Q(this,\"\"):this;return B(e,arguments)}},at);var mt=function(){try{[1,2].sort(null)}catch(t){try{[1,2].sort({})}catch(r){return false}}return true}();var Dt=function(){try{[1,2].sort(/a/);return false}catch(t){}return true}();var St=function(){try{[1,2].sort(undefined);return true}catch(t){}return false}();P(r,{sort:function sort(t){if(typeof t===\"undefined\"){return rt(this)}if(!D(t)){throw new TypeError(\"Array.prototype.sort callback must be a function\")}return rt(this,t)}},mt||!St||!Dt);var xt=!tt({toString:null},\"toString\");var Ot=tt(function(){},\"prototype\");var Et=!G(\"x\",\"0\");var jt=function(t){var r=t.constructor;return r&&r.prototype===t};var It={$applicationCache:true,$console:true,$external:true,$frame:true,$frameElement:true,$frames:true,$innerHeight:true,$innerWidth:true,$onmozfullscreenchange:true,$onmozfullscreenerror:true,$outerHeight:true,$outerWidth:true,$pageXOffset:true,$pageYOffset:true,$parent:true,$scrollLeft:true,$scrollTop:true,$scrollX:true,$scrollY:true,$self:true,$webkitIndexedDB:true,$webkitStorageInfo:true,$window:true,$width:true,$height:true,$top:true,$localStorage:true};var Mt=function(){if(typeof window===\"undefined\"){return false}for(var t in window){try{if(!It[\"$\"+t]&&G(window,t)&&window[t]!==null&&typeof window[t]===\"object\"){jt(window[t])}}catch(r){return true}}return false}();var Ut=function(t){if(typeof window===\"undefined\"||!Mt){return jt(t)}try{return jt(t)}catch(r){return false}};var $t=[\"toString\",\"toLocaleString\",\"valueOf\",\"hasOwnProperty\",\"isPrototypeOf\",\"propertyIsEnumerable\",\"constructor\"];var Ft=$t.length;var Nt=function isArguments(t){return H(t)===\"[object Arguments]\"};var Ct=function isArguments(t){return t!==null&&typeof t===\"object\"&&typeof t.length===\"number\"&&t.length>=0&&!et(t)&&D(t.callee)};var kt=Nt(arguments)?Nt:Ct;P(e,{keys:function keys(t){var r=D(t);var e=kt(t);var n=t!==null&&typeof t===\"object\";var i=n&&N(t);if(!n&&!r&&!e){throw new TypeError(\"Object.keys called on a non-object\")}var a=[];var f=Ot&&r;if(i&&Et||e){for(var u=0;u<t.length;++u){_(a,o(u))}}if(!e){for(var l in t){if(!(f&&l===\"prototype\")&&G(t,l)){_(a,o(l))}}}if(xt){var s=Ut(t);for(var c=0;c<Ft;c++){var v=$t[c];if(!(s&&v===\"constructor\")&&G(t,v)){_(a,v)}}}return a}});var At=e.keys&&function(){return e.keys(arguments).length===2}(1,2);var Rt=e.keys&&function(){var t=e.keys(arguments);return arguments.length!==1||t.length!==1||t[0]!==1}(1);var Pt=e.keys;P(e,{keys:function keys(t){if(kt(t)){return Pt(W(t))}else{return Pt(t)}}},!At||Rt);var Jt=new Date(-0xc782b5b342b24).getUTCMonth()!==0;var Yt=new Date(-0x55d318d56a724);var zt=new Date(14496624e5);var Zt=Yt.toUTCString()!==\"Mon, 01 Jan -45875 11:59:59 GMT\";var Gt;var Ht;var Wt=Yt.getTimezoneOffset();if(Wt<-720){Gt=Yt.toDateString()!==\"Tue Jan 02 -45875\";Ht=!/^Thu Dec 10 2015 \\d\\d:\\d\\d:\\d\\d GMT[-+]\\d\\d\\d\\d(?: |$)/.test(String(zt))}else{Gt=Yt.toDateString()!==\"Mon Jan 01 -45875\";Ht=!/^Wed Dec 09 2015 \\d\\d:\\d\\d:\\d\\d GMT[-+]\\d\\d\\d\\d(?: |$)/.test(String(zt))}var Bt=d.bind(Date.prototype.getFullYear);var Xt=d.bind(Date.prototype.getMonth);var Lt=d.bind(Date.prototype.getDate);var qt=d.bind(Date.prototype.getUTCFullYear);var Kt=d.bind(Date.prototype.getUTCMonth);var Qt=d.bind(Date.prototype.getUTCDate);var Vt=d.bind(Date.prototype.getUTCDay);var _t=d.bind(Date.prototype.getUTCHours);var tr=d.bind(Date.prototype.getUTCMinutes);var rr=d.bind(Date.prototype.getUTCSeconds);var er=d.bind(Date.prototype.getUTCMilliseconds);var nr=[\"Sun\",\"Mon\",\"Tue\",\"Wed\",\"Thu\",\"Fri\",\"Sat\"];var ir=[\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sep\",\"Oct\",\"Nov\",\"Dec\"];var ar=function daysInMonth(t,r){return Lt(new Date(r,t,0))};P(Date.prototype,{getFullYear:function getFullYear(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);if(t<0&&Xt(this)>11){return t+1}return t},getMonth:function getMonth(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);var r=Xt(this);if(t<0&&r>11){return 0}return r},getDate:function getDate(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);var r=Xt(this);var e=Lt(this);if(t<0&&r>11){if(r===12){return e}var n=ar(0,t+1);return n-e+1}return e},getUTCFullYear:function getUTCFullYear(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);if(t<0&&Kt(this)>11){return t+1}return t},getUTCMonth:function getUTCMonth(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);var r=Kt(this);if(t<0&&r>11){return 0}return r},getUTCDate:function getUTCDate(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);var r=Kt(this);var e=Qt(this);if(t<0&&r>11){if(r===12){return e}var n=ar(0,t+1);return n-e+1}return e}},Jt);P(Date.prototype,{toUTCString:function toUTCString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Vt(this);var r=Qt(this);var e=Kt(this);var n=qt(this);var i=_t(this);var a=tr(this);var o=rr(this);return nr[t]+\", \"+(r<10?\"0\"+r:r)+\" \"+ir[e]+\" \"+n+\" \"+(i<10?\"0\"+i:i)+\":\"+(a<10?\"0\"+a:a)+\":\"+(o<10?\"0\"+o:o)+\" GMT\"}},Jt||Zt);P(Date.prototype,{toDateString:function toDateString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=this.getDay();var r=this.getDate();var e=this.getMonth();var n=this.getFullYear();return nr[t]+\" \"+ir[e]+\" \"+(r<10?\"0\"+r:r)+\" \"+n}},Jt||Gt);if(Jt||Ht){Date.prototype.toString=function toString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=this.getDay();var r=this.getDate();var e=this.getMonth();var n=this.getFullYear();var i=this.getHours();var a=this.getMinutes();var o=this.getSeconds();var f=this.getTimezoneOffset();var u=Math.floor(Math.abs(f)/60);var l=Math.floor(Math.abs(f)%60);return nr[t]+\" \"+ir[e]+\" \"+(r<10?\"0\"+r:r)+\" \"+n+\" \"+(i<10?\"0\"+i:i)+\":\"+(a<10?\"0\"+a:a)+\":\"+(o<10?\"0\"+o:o)+\" GMT\"+(f>0?\"-\":\"+\")+(u<10?\"0\"+u:u)+(l<10?\"0\"+l:l)};if(R){e.defineProperty(Date.prototype,\"toString\",{configurable:true,enumerable:false,writable:true})}}var or=-621987552e5;var fr=\"-000001\";var ur=Date.prototype.toISOString&&new Date(or).toISOString().indexOf(fr)===-1;var lr=Date.prototype.toISOString&&new Date(-1).toISOString()!==\"1969-12-31T23:59:59.999Z\";var sr=d.bind(Date.prototype.getTime);P(Date.prototype,{toISOString:function toISOString(){if(!isFinite(this)||!isFinite(sr(this))){throw new RangeError(\"Date.prototype.toISOString called on non-finite value.\")}var t=qt(this);var r=Kt(this);t+=Math.floor(r/12);r=(r%12+12)%12;var e=[r+1,Qt(this),_t(this),tr(this),rr(this)];t=(t<0?\"-\":t>9999?\"+\":\"\")+K(\"00000\"+Math.abs(t),0<=t&&t<=9999?-4:-6);for(var n=0;n<e.length;++n){e[n]=K(\"00\"+e[n],-2)}return t+\"-\"+W(e,0,2).join(\"-\")+\"T\"+W(e,2).join(\":\")+\".\"+K(\"000\"+er(this),-3)+\"Z\"}},ur||lr);var cr=function(){try{return Date.prototype.toJSON&&new Date(NaN).toJSON()===null&&new Date(or).toJSON().indexOf(fr)!==-1&&Date.prototype.toJSON.call({toISOString:function(){return true}})}catch(t){return false}}();if(!cr){Date.prototype.toJSON=function toJSON(t){var r=e(this);var n=z.ToPrimitive(r);if(typeof n===\"number\"&&!isFinite(n)){return null}var i=r.toISOString;if(!D(i)){throw new TypeError(\"toISOString property is not callable\")}return i.call(r)}}var vr=Date.parse(\"+033658-09-27T01:46:40.000Z\")===1e15;var hr=!isNaN(Date.parse(\"2012-04-04T24:00:00.500Z\"))||!isNaN(Date.parse(\"2012-11-31T23:59:59.000Z\"))||!isNaN(Date.parse(\"2012-12-31T23:59:60.000Z\"));var pr=isNaN(Date.parse(\"2000-01-01T00:00:00.000Z\"));if(pr||hr||!vr){var yr=Math.pow(2,31)-1;var dr=Y(new Date(1970,0,1,0,0,0,yr+1).getTime());Date=function(t){var r=function Date(e,n,i,a,f,u,l){var s=arguments.length;var c;if(this instanceof t){var v=u;var h=l;if(dr&&s>=7&&l>yr){var p=Math.floor(l/yr)*yr;var y=Math.floor(p/1e3);v+=y;h-=y*1e3}c=s===1&&o(e)===e?new t(r.parse(e)):s>=7?new t(e,n,i,a,f,v,h):s>=6?new t(e,n,i,a,f,v):s>=5?new t(e,n,i,a,f):s>=4?new t(e,n,i,a):s>=3?new t(e,n,i):s>=2?new t(e,n):s>=1?new t(e instanceof t?+e:e):new t}else{c=t.apply(this,arguments)}if(!J(c)){P(c,{constructor:r},true)}return c};var e=new RegExp(\"^\"+\"(\\\\d{4}|[+-]\\\\d{6})\"+\"(?:-(\\\\d{2})\"+\"(?:-(\\\\d{2})\"+\"(?:\"+\"T(\\\\d{2})\"+\":(\\\\d{2})\"+\"(?:\"+\":(\\\\d{2})\"+\"(?:(\\\\.\\\\d{1,}))?\"+\")?\"+\"(\"+\"Z|\"+\"(?:\"+\"([-+])\"+\"(\\\\d{2})\"+\":(\\\\d{2})\"+\")\"+\")?)?)?)?\"+\"$\");var n=[0,31,59,90,120,151,181,212,243,273,304,334,365];var i=function dayFromMonth(t,r){var e=r>1?1:0;return n[r]+Math.floor((t-1969+e)/4)-Math.floor((t-1901+e)/100)+Math.floor((t-1601+e)/400)+365*(t-1970)};var a=function toUTC(r){var e=0;var n=r;if(dr&&n>yr){var i=Math.floor(n/yr)*yr;var a=Math.floor(i/1e3);e+=a;n-=a*1e3}return u(new t(1970,0,1,0,0,e,n))};for(var f in t){if(G(t,f)){r[f]=t[f]}}P(r,{now:t.now,UTC:t.UTC},true);r.prototype=t.prototype;P(r.prototype,{constructor:r},true);var l=function parse(r){var n=e.exec(r);if(n){var o=u(n[1]),f=u(n[2]||1)-1,l=u(n[3]||1)-1,s=u(n[4]||0),c=u(n[5]||0),v=u(n[6]||0),h=Math.floor(u(n[7]||0)*1e3),p=Boolean(n[4]&&!n[8]),y=n[9]===\"-\"?1:-1,d=u(n[10]||0),g=u(n[11]||0),w;var b=c>0||v>0||h>0;if(s<(b?24:25)&&c<60&&v<60&&h<1e3&&f>-1&&f<12&&d<24&&g<60&&l>-1&&l<i(o,f+1)-i(o,f)){w=((i(o,f)+l)*24+s+d*y)*60;w=((w+c+g*y)*60+v)*1e3+h;if(p){w=a(w)}if(-864e13<=w&&w<=864e13){return w}}return NaN}return t.parse.apply(this,arguments)};P(r,{parse:l});return r}(Date)}if(!Date.now){Date.now=function now(){return(new Date).getTime()}}var gr=l.toFixed&&(8e-5.toFixed(3)!==\"0.000\"||.9.toFixed(0)!==\"1\"||1.255.toFixed(2)!==\"1.25\"||(1000000000000000128).toFixed(0)!==\"1000000000000000128\");var wr={base:1e7,size:6,data:[0,0,0,0,0,0],multiply:function multiply(t,r){var e=-1;var n=r;while(++e<wr.size){n+=t*wr.data[e];wr.data[e]=n%wr.base;n=Math.floor(n/wr.base)}},divide:function divide(t){var r=wr.size;var e=0;while(--r>=0){e+=wr.data[r];wr.data[r]=Math.floor(e/t);e=e%t*wr.base}},numToString:function numToString(){var t=wr.size;var r=\"\";while(--t>=0){if(r!==\"\"||t===0||wr.data[t]!==0){var e=o(wr.data[t]);if(r===\"\"){r=e}else{r+=K(\"0000000\",0,7-e.length)+e}}}return r},pow:function pow(t,r,e){return r===0?e:r%2===1?pow(t,r-1,e*t):pow(t*t,r/2,e)},log:function log(t){var r=0;var e=t;while(e>=4096){r+=12;e/=4096}while(e>=2){r+=1;e/=2}return r}};var br=function toFixed(t){var r,e,n,i,a,f,l,s;r=u(t);r=Y(r)?0:Math.floor(r);if(r<0||r>20){throw new RangeError(\"Number.toFixed called with invalid number of decimals\")}e=u(this);if(Y(e)){return\"NaN\"}if(e<=-1e21||e>=1e21){return o(e)}n=\"\";if(e<0){n=\"-\";e=-e}i=\"0\";if(e>1e-21){a=wr.log(e*wr.pow(2,69,1))-69;f=a<0?e*wr.pow(2,-a,1):e/wr.pow(2,a,1);f*=4503599627370496;a=52-a;if(a>0){wr.multiply(0,f);l=r;while(l>=7){wr.multiply(1e7,0);l-=7}wr.multiply(wr.pow(10,l,1),0);l=a-1;while(l>=23){wr.divide(1<<23);l-=23}wr.divide(1<<l);wr.multiply(1,1);wr.divide(2);i=wr.numToString()}else{wr.multiply(0,f);wr.multiply(1<<-a,0);i=wr.numToString()+K(\"0.00000000000000000000\",2,2+r)}}if(r>0){s=i.length;if(s<=r){i=n+K(\"0.0000000000000000000\",0,r-s+2)+i}else{i=n+K(i,0,s-r)+\".\"+K(i,s-r)}}else{i=n+i}return i};P(l,{toFixed:br},gr);var Tr=function(){try{return 1..toPrecision(undefined)===\"1\"}catch(t){return true}}();var mr=l.toPrecision;P(l,{toPrecision:function toPrecision(t){return typeof t===\"undefined\"?mr.call(this):mr.call(this,t)}},Tr);if(\"ab\".split(/(?:ab)*/).length!==2||\".\".split(/(.?)(.?)/).length!==4||\"tesst\".split(/(s)*/)[1]===\"t\"||\"test\".split(/(?:)/,-1).length!==4||\"\".split(/.?/).length||\".\".split(/()()/).length>1){(function(){var t=typeof/()??/.exec(\"\")[1]===\"undefined\";var r=Math.pow(2,32)-1;f.split=function(e,n){var i=String(this);if(typeof e===\"undefined\"&&n===0){return[]}if(!M(e)){return Q(this,e,n)}var a=[];var o=(e.ignoreCase?\"i\":\"\")+(e.multiline?\"m\":\"\")+(e.unicode?\"u\":\"\")+(e.sticky?\"y\":\"\"),f=0,u,l,s,c;var h=new RegExp(e.source,o+\"g\");if(!t){u=new RegExp(\"^\"+h.source+\"$(?!\\\\s)\",o)}var p=typeof n===\"undefined\"?r:z.ToUint32(n);l=h.exec(i);while(l){s=l.index+l[0].length;if(s>f){_(a,K(i,f,l.index));if(!t&&l.length>1){l[0].replace(u,function(){for(var t=1;t<arguments.length-2;t++){if(typeof arguments[t]===\"undefined\"){l[t]=void 0}}})}if(l.length>1&&l.index<i.length){v.apply(a,W(l,1))}c=l[0].length;f=s;if(a.length>=p){break}}if(h.lastIndex===l.index){h.lastIndex++}l=h.exec(i)}if(f===i.length){if(c||!h.test(\"\")){_(a,\"\")}}else{_(a,K(i,f))}return a.length>p?W(a,0,p):a}})()}else if(\"0\".split(void 0,0).length){f.split=function split(t,r){if(typeof t===\"undefined\"&&r===0){return[]}return Q(this,t,r)}}var Dr=f.replace;var Sr=function(){var t=[];\"x\".replace(/x(.)?/g,function(r,e){_(t,e)});return t.length===1&&typeof t[0]===\"undefined\"}();if(!Sr){f.replace=function replace(t,r){var e=D(r);var n=M(t)&&/\\)[*?]/.test(t.source);if(!e||!n){return Dr.call(this,t,r)}else{var i=function(e){var n=arguments.length;var i=t.lastIndex;t.lastIndex=0;var a=t.exec(e)||[];t.lastIndex=i;_(a,arguments[n-2],arguments[n-1]);return r.apply(this,a)};return Dr.call(this,t,i)}}}var xr=f.substr;var Or=\"\".substr&&\"0b\".substr(-1)!==\"b\";P(f,{substr:function substr(t,r){var e=t;if(t<0){e=w(this.length+t,0)}return xr.call(this,e,r)}},Or);var Er=\"\\t\\n\\x0B\\f\\r \\xa0\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\"+\"\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\u2028\"+\"\\u2029\\ufeff\";var jr=\"\\u200b\";var Ir=\"[\"+Er+\"]\";var Mr=new RegExp(\"^\"+Ir+Ir+\"*\");var Ur=new RegExp(Ir+Ir+\"*$\");var $r=f.trim&&(Er.trim()||!jr.trim());P(f,{trim:function trim(){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}return o(this).replace(Mr,\"\").replace(Ur,\"\")}},$r);var Fr=d.bind(String.prototype.trim);var Nr=f.lastIndexOf&&\"abc\\u3042\\u3044\".lastIndexOf(\"\\u3042\\u3044\",2)!==-1;P(f,{lastIndexOf:function lastIndexOf(t){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}var r=o(this);var e=o(t);var n=arguments.length>1?u(arguments[1]):NaN;var i=Y(n)?Infinity:z.ToInteger(n);var a=b(w(i,0),r.length);var f=e.length;var l=a+f;while(l>0){l=w(0,l-f);var s=V(K(r,l,a+f),e);if(s!==-1){return l+s}}return-1}},Nr);var Cr=f.lastIndexOf;P(f,{lastIndexOf:function lastIndexOf(t){return Cr.apply(this,arguments)}},f.lastIndexOf.length!==1);if(parseInt(Er+\"08\")!==8||parseInt(Er+\"0x16\")!==22){parseInt=function(t){var r=/^[-+]?0[xX]/;return function parseInt(e,n){if(typeof e===\"symbol\"){\"\"+e}var i=Fr(String(e));var a=u(n)||(r.test(i)?16:10);return t(i,a)}}(parseInt)}if(1/parseFloat(\"-0\")!==-Infinity){parseFloat=function(t){return function parseFloat(r){var e=Fr(String(r));var n=t(e);return n===0&&K(e,0,1)===\"-\"?-0:n}}(parseFloat)}if(String(new RangeError(\"test\"))!==\"RangeError: test\"){var kr=function toString(){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}var t=this.name;if(typeof t===\"undefined\"){t=\"Error\"}else if(typeof t!==\"string\"){t=o(t)}var r=this.message;if(typeof r===\"undefined\"){r=\"\"}else if(typeof r!==\"string\"){r=o(r)}if(!t){return r}if(!r){return t}return t+\": \"+r};Error.prototype.toString=kr}if(R){var Ar=function(t,r){if(tt(t,r)){var e=Object.getOwnPropertyDescriptor(t,r);if(e.configurable){e.enumerable=false;Object.defineProperty(t,r,e)}}};Ar(Error.prototype,\"message\");if(Error.prototype.message!==\"\"){Error.prototype.message=\"\"}Ar(Error.prototype,\"name\")}if(String(/a/gim)!==\"/a/gim\"){var Rr=function toString(){var t=\"/\"+this.source+\"/\";if(this.global){t+=\"g\"}if(this.ignoreCase){t+=\"i\"}if(this.multiline){t+=\"m\"}return t};RegExp.prototype.toString=Rr}});\n//# sourceMappingURL=es5-shim.map\n/*!\n * https://github.com/paulmillr/es6-shim\n * @license es6-shim Copyright 2013-2016 by Paul Miller (http://paulmillr.com)\n *   and contributors,  MIT License\n * es6-shim: v0.35.4\n * see https://github.com/paulmillr/es6-shim/blob/0.35.4/LICENSE\n * Details and documentation:\n * https://github.com/paulmillr/es6-shim/\n */\n(function(e,t){if(typeof define===\"function\"&&define.amd){define(t)}else if(typeof exports===\"object\"){module.exports=t()}else{e.returnExports=t()}})(this,function(){\"use strict\";var e=Function.call.bind(Function.apply);var t=Function.call.bind(Function.call);var r=Array.isArray;var n=Object.keys;var o=function notThunker(t){return function notThunk(){return!e(t,this,arguments)}};var i=function(e){try{e();return false}catch(t){return true}};var a=function valueOrFalseIfThrows(e){try{return e()}catch(t){return false}};var u=o(i);var f=function(){return!i(function(){return Object.defineProperty({},\"x\",{get:function(){}})})};var s=!!Object.defineProperty&&f();var c=function foo(){}.name===\"foo\";var l=Function.call.bind(Array.prototype.forEach);var p=Function.call.bind(Array.prototype.reduce);var v=Function.call.bind(Array.prototype.filter);var y=Function.call.bind(Array.prototype.some);var h=function(e,t,r,n){if(!n&&t in e){return}if(s){Object.defineProperty(e,t,{configurable:true,enumerable:false,writable:true,value:r})}else{e[t]=r}};var b=function(e,t,r){l(n(t),function(n){var o=t[n];h(e,n,o,!!r)})};var g=Function.call.bind(Object.prototype.toString);var d=typeof/abc/===\"function\"?function IsCallableSlow(e){return typeof e===\"function\"&&g(e)===\"[object Function]\"}:function IsCallableFast(e){return typeof e===\"function\"};var m={getter:function(e,t,r){if(!s){throw new TypeError(\"getters require true ES5 support\")}Object.defineProperty(e,t,{configurable:true,enumerable:false,get:r})},proxy:function(e,t,r){if(!s){throw new TypeError(\"getters require true ES5 support\")}var n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,{configurable:n.configurable,enumerable:n.enumerable,get:function getKey(){return e[t]},set:function setKey(r){e[t]=r}})},redefine:function(e,t,r){if(s){var n=Object.getOwnPropertyDescriptor(e,t);n.value=r;Object.defineProperty(e,t,n)}else{e[t]=r}},defineByDescriptor:function(e,t,r){if(s){Object.defineProperty(e,t,r)}else if(\"value\"in r){e[t]=r.value}},preserveToString:function(e,t){if(t&&d(t.toString)){h(e,\"toString\",t.toString.bind(t),true)}}};var O=Object.create||function(e,t){var r=function Prototype(){};r.prototype=e;var o=new r;if(typeof t!==\"undefined\"){n(t).forEach(function(e){m.defineByDescriptor(o,e,t[e])})}return o};var w=function(e,t){if(!Object.setPrototypeOf){return false}return a(function(){var r=function Subclass(t){var r=new e(t);Object.setPrototypeOf(r,Subclass.prototype);return r};Object.setPrototypeOf(r,e);r.prototype=O(e.prototype,{constructor:{value:r}});return t(r)})};var j=function(){if(typeof self!==\"undefined\"){return self}if(typeof window!==\"undefined\"){return window}if(typeof global!==\"undefined\"){return global}throw new Error(\"unable to locate global object\")};var S=j();var T=S.isFinite;var I=Function.call.bind(String.prototype.indexOf);var E=Function.apply.bind(Array.prototype.indexOf);var P=Function.call.bind(Array.prototype.concat);var C=Function.call.bind(String.prototype.slice);var M=Function.call.bind(Array.prototype.push);var x=Function.apply.bind(Array.prototype.push);var N=Function.call.bind(Array.prototype.shift);var A=Math.max;var R=Math.min;var _=Math.floor;var k=Math.abs;var L=Math.exp;var F=Math.log;var D=Math.sqrt;var z=Function.call.bind(Object.prototype.hasOwnProperty);var q;var W=function(){};var G=S.Map;var H=G&&G.prototype[\"delete\"];var V=G&&G.prototype.get;var B=G&&G.prototype.has;var U=G&&G.prototype.set;var $=S.Symbol||{};var J=$.species||\"@@species\";var X=Number.isNaN||function isNaN(e){return e!==e};var K=Number.isFinite||function isFinite(e){return typeof e===\"number\"&&T(e)};var Z=d(Math.sign)?Math.sign:function sign(e){var t=Number(e);if(t===0){return t}if(X(t)){return t}return t<0?-1:1};var Y=function log1p(e){var t=Number(e);if(t<-1||X(t)){return NaN}if(t===0||t===Infinity){return t}if(t===-1){return-Infinity}return 1+t-1===0?t:t*(F(1+t)/(1+t-1))};var Q=function isArguments(e){return g(e)===\"[object Arguments]\"};var ee=function isArguments(e){return e!==null&&typeof e===\"object\"&&typeof e.length===\"number\"&&e.length>=0&&g(e)!==\"[object Array]\"&&g(e.callee)===\"[object Function]\"};var te=Q(arguments)?Q:ee;var re={primitive:function(e){return e===null||typeof e!==\"function\"&&typeof e!==\"object\"},string:function(e){return g(e)===\"[object String]\"},regex:function(e){return g(e)===\"[object RegExp]\"},symbol:function(e){return typeof S.Symbol===\"function\"&&typeof e===\"symbol\"}};var ne=function overrideNative(e,t,r){var n=e[t];h(e,t,r,true);m.preserveToString(e[t],n)};var oe=typeof $===\"function\"&&typeof $[\"for\"]===\"function\"&&re.symbol($());var ie=re.symbol($.iterator)?$.iterator:\"_es6-shim iterator_\";if(S.Set&&typeof(new S.Set)[\"@@iterator\"]===\"function\"){ie=\"@@iterator\"}if(!S.Reflect){h(S,\"Reflect\",{},true)}var ae=S.Reflect;var ue=String;var fe=typeof document===\"undefined\"||!document?null:document.all;var se=fe==null?function isNullOrUndefined(e){return e==null}:function isNullOrUndefinedAndNotDocumentAll(e){return e==null&&e!==fe};var ce={Call:function Call(t,r){var n=arguments.length>2?arguments[2]:[];if(!ce.IsCallable(t)){throw new TypeError(t+\" is not a function\")}return e(t,r,n)},RequireObjectCoercible:function(e,t){if(se(e)){throw new TypeError(t||\"Cannot call method on \"+e)}return e},TypeIsObject:function(e){if(e===void 0||e===null||e===true||e===false){return false}return typeof e===\"function\"||typeof e===\"object\"||e===fe},ToObject:function(e,t){return Object(ce.RequireObjectCoercible(e,t))},IsCallable:d,IsConstructor:function(e){return ce.IsCallable(e)},ToInt32:function(e){return ce.ToNumber(e)>>0},ToUint32:function(e){return ce.ToNumber(e)>>>0},ToNumber:function(e){if(g(e)===\"[object Symbol]\"){throw new TypeError(\"Cannot convert a Symbol value to a number\")}return+e},ToInteger:function(e){var t=ce.ToNumber(e);if(X(t)){return 0}if(t===0||!K(t)){return t}return(t>0?1:-1)*_(k(t))},ToLength:function(e){var t=ce.ToInteger(e);if(t<=0){return 0}if(t>Number.MAX_SAFE_INTEGER){return Number.MAX_SAFE_INTEGER}return t},SameValue:function(e,t){if(e===t){if(e===0){return 1/e===1/t}return true}return X(e)&&X(t)},SameValueZero:function(e,t){return e===t||X(e)&&X(t)},IsIterable:function(e){return ce.TypeIsObject(e)&&(typeof e[ie]!==\"undefined\"||te(e))},GetIterator:function(e){if(te(e)){return new q(e,\"value\")}var t=ce.GetMethod(e,ie);if(!ce.IsCallable(t)){throw new TypeError(\"value is not an iterable\")}var r=ce.Call(t,e);if(!ce.TypeIsObject(r)){throw new TypeError(\"bad iterator\")}return r},GetMethod:function(e,t){var r=ce.ToObject(e)[t];if(se(r)){return void 0}if(!ce.IsCallable(r)){throw new TypeError(\"Method not callable: \"+t)}return r},IteratorComplete:function(e){return!!e.done},IteratorClose:function(e,t){var r=ce.GetMethod(e,\"return\");if(r===void 0){return}var n,o;try{n=ce.Call(r,e)}catch(i){o=i}if(t){return}if(o){throw o}if(!ce.TypeIsObject(n)){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(!ce.TypeIsObject(t)){throw new TypeError(\"bad iterator\")}return t},IteratorStep:function(e){var t=ce.IteratorNext(e);var r=ce.IteratorComplete(t);return r?false:t},Construct:function(e,t,r,n){var o=typeof r===\"undefined\"?e:r;if(!n&&ae.construct){return ae.construct(e,t,o)}var i=o.prototype;if(!ce.TypeIsObject(i)){i=Object.prototype}var a=O(i);var u=ce.Call(e,a,t);return ce.TypeIsObject(u)?u:a},SpeciesConstructor:function(e,t){var r=e.constructor;if(r===void 0){return t}if(!ce.TypeIsObject(r)){throw new TypeError(\"Bad constructor\")}var n=r[J];if(se(n)){return t}if(!ce.IsConstructor(n)){throw new TypeError(\"Bad @@species\")}return n},CreateHTML:function(e,t,r,n){var o=ce.ToString(e);var i=\"<\"+t;if(r!==\"\"){var a=ce.ToString(n);var u=a.replace(/\"/g,\"&quot;\");i+=\" \"+r+'=\"'+u+'\"'}var f=i+\">\";var s=f+o;return s+\"</\"+t+\">\"},IsRegExp:function IsRegExp(e){if(!ce.TypeIsObject(e)){return false}var t=e[$.match];if(typeof t!==\"undefined\"){return!!t}return re.regex(e)},ToString:function ToString(e){return ue(e)}};if(s&&oe){var le=function defineWellKnownSymbol(e){if(re.symbol($[e])){return $[e]}var t=$[\"for\"](\"Symbol.\"+e);Object.defineProperty($,e,{configurable:false,enumerable:false,writable:false,value:t});return t};if(!re.symbol($.search)){var pe=le(\"search\");var ve=String.prototype.search;h(RegExp.prototype,pe,function search(e){return ce.Call(ve,e,[this])});var ye=function search(e){var t=ce.RequireObjectCoercible(this);if(!se(e)){var r=ce.GetMethod(e,pe);if(typeof r!==\"undefined\"){return ce.Call(r,e,[t])}}return ce.Call(ve,t,[ce.ToString(e)])};ne(String.prototype,\"search\",ye)}if(!re.symbol($.replace)){var he=le(\"replace\");var be=String.prototype.replace;h(RegExp.prototype,he,function replace(e,t){return ce.Call(be,e,[this,t])});var ge=function replace(e,t){var r=ce.RequireObjectCoercible(this);if(!se(e)){var n=ce.GetMethod(e,he);if(typeof n!==\"undefined\"){return ce.Call(n,e,[r,t])}}return ce.Call(be,r,[ce.ToString(e),t])};ne(String.prototype,\"replace\",ge)}if(!re.symbol($.split)){var de=le(\"split\");var me=String.prototype.split;h(RegExp.prototype,de,function split(e,t){return ce.Call(me,e,[this,t])});var Oe=function split(e,t){var r=ce.RequireObjectCoercible(this);if(!se(e)){var n=ce.GetMethod(e,de);if(typeof n!==\"undefined\"){return ce.Call(n,e,[r,t])}}return ce.Call(me,r,[ce.ToString(e),t])};ne(String.prototype,\"split\",Oe)}var we=re.symbol($.match);var je=we&&function(){var e={};e[$.match]=function(){return 42};return\"a\".match(e)!==42}();if(!we||je){var Se=le(\"match\");var Te=String.prototype.match;h(RegExp.prototype,Se,function match(e){return ce.Call(Te,e,[this])});var Ie=function match(e){var t=ce.RequireObjectCoercible(this);if(!se(e)){var r=ce.GetMethod(e,Se);if(typeof r!==\"undefined\"){return ce.Call(r,e,[t])}}return ce.Call(Te,t,[ce.ToString(e)])};ne(String.prototype,\"match\",Ie)}}var Ee=function wrapConstructor(e,t,r){m.preserveToString(t,e);if(Object.setPrototypeOf){Object.setPrototypeOf(e,t)}if(s){l(Object.getOwnPropertyNames(e),function(n){if(n in W||r[n]){return}m.proxy(e,n,t)})}else{l(Object.keys(e),function(n){if(n in W||r[n]){return}t[n]=e[n]})}t.prototype=e.prototype;m.redefine(e.prototype,\"constructor\",t)};var Pe=function(){return this};var Ce=function(e){if(s&&!z(e,J)){m.getter(e,J,Pe)}};var Me=function(e,t){var r=t||function iterator(){return this};h(e,ie,r);if(!e[ie]&&re.symbol(ie)){e[ie]=r}};var xe=function createDataProperty(e,t,r){if(s){Object.defineProperty(e,t,{configurable:true,enumerable:true,writable:true,value:r})}else{e[t]=r}};var Ne=function createDataPropertyOrThrow(e,t,r){xe(e,t,r);if(!ce.SameValue(e[t],r)){throw new TypeError(\"property is nonconfigurable\")}};var Ae=function(e,t,r,n){if(!ce.TypeIsObject(e)){throw new TypeError(\"Constructor requires `new`: \"+t.name)}var o=t.prototype;if(!ce.TypeIsObject(o)){o=r}var i=O(o);for(var a in n){if(z(n,a)){var u=n[a];h(i,a,u,true)}}return i};if(String.fromCodePoint&&String.fromCodePoint.length!==1){var Re=String.fromCodePoint;ne(String,\"fromCodePoint\",function fromCodePoint(e){return ce.Call(Re,this,arguments)})}var _e={fromCodePoint:function fromCodePoint(e){var t=[];var r;for(var n=0,o=arguments.length;n<o;n++){r=Number(arguments[n]);if(!ce.SameValue(r,ce.ToInteger(r))||r<0||r>1114111){throw new RangeError(\"Invalid code point \"+r)}if(r<65536){M(t,String.fromCharCode(r))}else{r-=65536;M(t,String.fromCharCode((r>>10)+55296));M(t,String.fromCharCode(r%1024+56320))}}return t.join(\"\")},raw:function raw(e){var t=ce.ToObject(e,\"bad callSite\");var r=ce.ToObject(t.raw,\"bad raw value\");var n=r.length;var o=ce.ToLength(n);if(o<=0){return\"\"}var i=[];var a=0;var u,f,s,c;while(a<o){u=ce.ToString(a);s=ce.ToString(r[u]);M(i,s);if(a+1>=o){break}f=a+1<arguments.length?arguments[a+1]:\"\";c=ce.ToString(f);M(i,c);a+=1}return i.join(\"\")}};if(String.raw&&String.raw({raw:{0:\"x\",1:\"y\",length:2}})!==\"xy\"){ne(String,\"raw\",_e.raw)}b(String,_e);var ke=function repeat(e,t){if(t<1){return\"\"}if(t%2){return repeat(e,t-1)+e}var r=repeat(e,t/2);return r+r};var Le=Infinity;var Fe={repeat:function repeat(e){var t=ce.ToString(ce.RequireObjectCoercible(this));var r=ce.ToInteger(e);if(r<0||r>=Le){throw new RangeError(\"repeat count must be less than infinity and not overflow maximum string size\")}return ke(t,r)},startsWith:function startsWith(e){var t=ce.ToString(ce.RequireObjectCoercible(this));if(ce.IsRegExp(e)){throw new TypeError('Cannot call method \"startsWith\" with a regex')}var r=ce.ToString(e);var n;if(arguments.length>1){n=arguments[1]}var o=A(ce.ToInteger(n),0);return C(t,o,o+r.length)===r},endsWith:function endsWith(e){var t=ce.ToString(ce.RequireObjectCoercible(this));if(ce.IsRegExp(e)){throw new TypeError('Cannot call method \"endsWith\" with a regex')}var r=ce.ToString(e);var n=t.length;var o;if(arguments.length>1){o=arguments[1]}var i=typeof o===\"undefined\"?n:ce.ToInteger(o);var a=R(A(i,0),n);return C(t,a-r.length,a)===r},includes:function includes(e){if(ce.IsRegExp(e)){throw new TypeError('\"includes\" does not accept a RegExp')}var t=ce.ToString(e);var r;if(arguments.length>1){r=arguments[1]}return I(this,t,r)!==-1},codePointAt:function codePointAt(e){var t=ce.ToString(ce.RequireObjectCoercible(this));var r=ce.ToInteger(e);var n=t.length;if(r>=0&&r<n){var o=t.charCodeAt(r);var i=r+1===n;if(o<55296||o>56319||i){return o}var a=t.charCodeAt(r+1);if(a<56320||a>57343){return o}return(o-55296)*1024+(a-56320)+65536}}};if(String.prototype.includes&&\"a\".includes(\"a\",Infinity)!==false){ne(String.prototype,\"includes\",Fe.includes)}if(String.prototype.startsWith&&String.prototype.endsWith){var De=i(function(){return\"/a/\".startsWith(/a/)});var ze=a(function(){return\"abc\".startsWith(\"a\",Infinity)===false});if(!De||!ze){ne(String.prototype,\"startsWith\",Fe.startsWith);ne(String.prototype,\"endsWith\",Fe.endsWith)}}if(oe){var qe=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".startsWith(e)});if(!qe){ne(String.prototype,\"startsWith\",Fe.startsWith)}var We=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".endsWith(e)});if(!We){ne(String.prototype,\"endsWith\",Fe.endsWith)}var Ge=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".includes(e)});if(!Ge){ne(String.prototype,\"includes\",Fe.includes)}}b(String.prototype,Fe);var He=[\"\\t\\n\\x0B\\f\\r \\xa0\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\",\"\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\u2028\",\"\\u2029\\ufeff\"].join(\"\");var Ve=new RegExp(\"(^[\"+He+\"]+)|([\"+He+\"]+$)\",\"g\");var Be=function trim(){return ce.ToString(ce.RequireObjectCoercible(this)).replace(Ve,\"\")};var Ue=[\"\\x85\",\"\\u200b\",\"\\ufffe\"].join(\"\");var $e=new RegExp(\"[\"+Ue+\"]\",\"g\");var Je=/^[-+]0x[0-9a-f]+$/i;var Xe=Ue.trim().length!==Ue.length;h(String.prototype,\"trim\",Be,Xe);var Ke=function(e){return{value:e,done:arguments.length===0}};var Ze=function(e){ce.RequireObjectCoercible(e);this._s=ce.ToString(e);this._i=0};Ze.prototype.next=function(){var e=this._s;var t=this._i;if(typeof e===\"undefined\"||t>=e.length){this._s=void 0;return Ke()}var r=e.charCodeAt(t);var n,o;if(r<55296||r>56319||t+1===e.length){o=1}else{n=e.charCodeAt(t+1);o=n<56320||n>57343?1:2}this._i=t+o;return Ke(e.substr(t,o))};Me(Ze.prototype);Me(String.prototype,function(){return new Ze(this)});var Ye={from:function from(e){var r=this;var n;if(arguments.length>1){n=arguments[1]}var o,i;if(typeof n===\"undefined\"){o=false}else{if(!ce.IsCallable(n)){throw new TypeError(\"Array.from: when provided, the second argument must be a function\")}if(arguments.length>2){i=arguments[2]}o=true}var a=typeof(te(e)||ce.GetMethod(e,ie))!==\"undefined\";var u,f,s;if(a){f=ce.IsConstructor(r)?Object(new r):[];var c=ce.GetIterator(e);var l,p;s=0;while(true){l=ce.IteratorStep(c);if(l===false){break}p=l.value;try{if(o){p=typeof i===\"undefined\"?n(p,s):t(n,i,p,s)}f[s]=p}catch(v){ce.IteratorClose(c,true);throw v}s+=1}u=s}else{var y=ce.ToObject(e);u=ce.ToLength(y.length);f=ce.IsConstructor(r)?Object(new r(u)):new Array(u);var h;for(s=0;s<u;++s){h=y[s];if(o){h=typeof i===\"undefined\"?n(h,s):t(n,i,h,s)}Ne(f,s,h)}}f.length=u;return f},of:function of(){var e=arguments.length;var t=this;var n=r(t)||!ce.IsCallable(t)?new Array(e):ce.Construct(t,[e]);for(var o=0;o<e;++o){Ne(n,o,arguments[o])}n.length=e;return n}};b(Array,Ye);Ce(Array);q=function(e,t){this.i=0;this.array=e;this.kind=t};b(q.prototype,{next:function(){var e=this.i;var t=this.array;if(!(this instanceof q)){throw new TypeError(\"Not an ArrayIterator\")}if(typeof t!==\"undefined\"){var r=ce.ToLength(t.length);for(;e<r;e++){var n=this.kind;var o;if(n===\"key\"){o=e}else if(n===\"value\"){o=t[e]}else if(n===\"entry\"){o=[e,t[e]]}this.i=e+1;return Ke(o)}}this.array=void 0;return Ke()}});Me(q.prototype);var Qe=Array.of===Ye.of||function(){var e=function Foo(e){this.length=e};e.prototype=[];var t=Array.of.apply(e,[1,2]);return t instanceof e&&t.length===2}();if(!Qe){ne(Array,\"of\",Ye.of)}var et={copyWithin:function copyWithin(e,t){var r=ce.ToObject(this);var n=ce.ToLength(r.length);var o=ce.ToInteger(e);var i=ce.ToInteger(t);var a=o<0?A(n+o,0):R(o,n);var u=i<0?A(n+i,0):R(i,n);var f;if(arguments.length>2){f=arguments[2]}var s=typeof f===\"undefined\"?n:ce.ToInteger(f);var c=s<0?A(n+s,0):R(s,n);var l=R(c-u,n-a);var p=1;if(u<a&&a<u+l){p=-1;u+=l-1;a+=l-1}while(l>0){if(u in r){r[a]=r[u]}else{delete r[a]}u+=p;a+=p;l-=1}return r},fill:function fill(e){var t;if(arguments.length>1){t=arguments[1]}var r;if(arguments.length>2){r=arguments[2]}var n=ce.ToObject(this);var o=ce.ToLength(n.length);t=ce.ToInteger(typeof t===\"undefined\"?0:t);r=ce.ToInteger(typeof r===\"undefined\"?o:r);var i=t<0?A(o+t,0):R(t,o);var a=r<0?o+r:r;for(var u=i;u<o&&u<a;++u){n[u]=e}return n},find:function find(e){var r=ce.ToObject(this);var n=ce.ToLength(r.length);if(!ce.IsCallable(e)){throw new TypeError(\"Array#find: predicate must be a function\")}var o=arguments.length>1?arguments[1]:null;for(var i=0,a;i<n;i++){a=r[i];if(o){if(t(e,o,a,i,r)){return a}}else if(e(a,i,r)){return a}}},findIndex:function findIndex(e){var r=ce.ToObject(this);var n=ce.ToLength(r.length);if(!ce.IsCallable(e)){throw new TypeError(\"Array#findIndex: predicate must be a function\")}var o=arguments.length>1?arguments[1]:null;for(var i=0;i<n;i++){if(o){if(t(e,o,r[i],i,r)){return i}}else if(e(r[i],i,r)){return i}}return-1},keys:function keys(){return new q(this,\"key\")},values:function values(){return new q(this,\"value\")},entries:function entries(){return new q(this,\"entry\")}};if(Array.prototype.keys&&!ce.IsCallable([1].keys().next)){delete Array.prototype.keys}if(Array.prototype.entries&&!ce.IsCallable([1].entries().next)){delete Array.prototype.entries}if(Array.prototype.keys&&Array.prototype.entries&&!Array.prototype.values&&Array.prototype[ie]){b(Array.prototype,{values:Array.prototype[ie]});if(re.symbol($.unscopables)){Array.prototype[$.unscopables].values=true}}if(c&&Array.prototype.values&&Array.prototype.values.name!==\"values\"){var tt=Array.prototype.values;ne(Array.prototype,\"values\",function values(){return ce.Call(tt,this,arguments)});h(Array.prototype,ie,Array.prototype.values,true)}b(Array.prototype,et);if(1/[true].indexOf(true,-0)<0){h(Array.prototype,\"indexOf\",function indexOf(e){var t=E(this,arguments);if(t===0&&1/t<0){return 0}return t},true)}Me(Array.prototype,function(){return this.values()});if(Object.getPrototypeOf){Me(Object.getPrototypeOf([].values()))}var rt=function(){return a(function(){return Array.from({length:-1}).length===0})}();var nt=function(){var e=Array.from([0].entries());return e.length===1&&r(e[0])&&e[0][0]===0&&e[0][1]===0}();if(!rt||!nt){ne(Array,\"from\",Ye.from)}var ot=function(){return a(function(){return Array.from([0],void 0)})}();if(!ot){var it=Array.from;ne(Array,\"from\",function from(e){if(arguments.length>1&&typeof arguments[1]!==\"undefined\"){return ce.Call(it,this,arguments)}else{return t(it,this,e)}})}var at=-(Math.pow(2,32)-1);var ut=function(e,r){var n={length:at};n[r?(n.length>>>0)-1:0]=true;return a(function(){t(e,n,function(){throw new RangeError(\"should not reach here\")},[]);return true})};if(!ut(Array.prototype.forEach)){var ft=Array.prototype.forEach;ne(Array.prototype,\"forEach\",function forEach(e){return ce.Call(ft,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.map)){var st=Array.prototype.map;ne(Array.prototype,\"map\",function map(e){return ce.Call(st,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.filter)){var ct=Array.prototype.filter;ne(Array.prototype,\"filter\",function filter(e){return ce.Call(ct,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.some)){var lt=Array.prototype.some;ne(Array.prototype,\"some\",function some(e){return ce.Call(lt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.every)){var pt=Array.prototype.every;ne(Array.prototype,\"every\",function every(e){return ce.Call(pt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.reduce)){var vt=Array.prototype.reduce;ne(Array.prototype,\"reduce\",function reduce(e){return ce.Call(vt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.reduceRight,true)){var yt=Array.prototype.reduceRight;ne(Array.prototype,\"reduceRight\",function reduceRight(e){return ce.Call(yt,this.length>=0?this:[],arguments)},true)}var ht=Number(\"0o10\")!==8;var bt=Number(\"0b10\")!==2;var gt=y(Ue,function(e){return Number(e+0+e)===0});if(ht||bt||gt){var dt=Number;var mt=/^0b[01]+$/i;var Ot=/^0o[0-7]+$/i;var wt=mt.test.bind(mt);var jt=Ot.test.bind(Ot);var St=function(e){var t;if(typeof e.valueOf===\"function\"){t=e.valueOf();if(re.primitive(t)){return t}}if(typeof e.toString===\"function\"){t=e.toString();if(re.primitive(t)){return t}}throw new TypeError(\"No default value\")};var Tt=$e.test.bind($e);var It=Je.test.bind(Je);var Et=function(){var e=function Number(t){var r;if(arguments.length>0){r=re.primitive(t)?t:St(t,\"number\")}else{r=0}if(typeof r===\"string\"){r=ce.Call(Be,r);if(wt(r)){r=parseInt(C(r,2),2)}else if(jt(r)){r=parseInt(C(r,2),8)}else if(Tt(r)||It(r)){r=NaN}}var n=this;var o=a(function(){dt.prototype.valueOf.call(n);return true});if(n instanceof e&&!o){return new dt(r)}return dt(r)};return e}();Ee(dt,Et,{});b(Et,{NaN:dt.NaN,MAX_VALUE:dt.MAX_VALUE,MIN_VALUE:dt.MIN_VALUE,NEGATIVE_INFINITY:dt.NEGATIVE_INFINITY,POSITIVE_INFINITY:dt.POSITIVE_INFINITY});Number=Et;m.redefine(S,\"Number\",Et)}var Pt=Math.pow(2,53)-1;b(Number,{MAX_SAFE_INTEGER:Pt,MIN_SAFE_INTEGER:-Pt,EPSILON:2.220446049250313e-16,parseInt:S.parseInt,parseFloat:S.parseFloat,isFinite:K,isInteger:function isInteger(e){return K(e)&&ce.ToInteger(e)===e},isSafeInteger:function isSafeInteger(e){return Number.isInteger(e)&&k(e)<=Number.MAX_SAFE_INTEGER},isNaN:X});h(Number,\"parseInt\",S.parseInt,Number.parseInt!==S.parseInt);if([,1].find(function(){return true})===1){ne(Array.prototype,\"find\",et.find)}if([,1].findIndex(function(){return true})!==0){ne(Array.prototype,\"findIndex\",et.findIndex)}var Ct=Function.bind.call(Function.bind,Object.prototype.propertyIsEnumerable);var Mt=function ensureEnumerable(e,t){if(s&&Ct(e,t)){Object.defineProperty(e,t,{enumerable:false})}};var xt=function sliceArgs(){var e=Number(this);var t=arguments.length;var r=t-e;var n=new Array(r<0?0:r);for(var o=e;o<t;++o){n[o-e]=arguments[o]}return n};var Nt=function assignTo(e){return function assignToSource(t,r){t[r]=e[r];return t}};var At=function(e,t){var r=n(Object(t));var o;if(ce.IsCallable(Object.getOwnPropertySymbols)){o=v(Object.getOwnPropertySymbols(Object(t)),Ct(t))}return p(P(r,o||[]),Nt(t),e)};var Rt={assign:function(e,t){var r=ce.ToObject(e,\"Cannot convert undefined or null to object\");return p(ce.Call(xt,1,arguments),At,r)},is:function is(e,t){return ce.SameValue(e,t)}};var _t=Object.assign&&Object.preventExtensions&&function(){var e=Object.preventExtensions({1:2});try{Object.assign(e,\"xy\")}catch(t){return e[1]===\"y\"}}();if(_t){ne(Object,\"assign\",Rt.assign)}b(Object,Rt);if(s){var kt={setPrototypeOf:function(e,r){var n;var o=function(e,t){if(!ce.TypeIsObject(e)){throw new TypeError(\"cannot set prototype on a non-object\")}if(!(t===null||ce.TypeIsObject(t))){throw new TypeError(\"can only set prototype to an object or null\"+t)}};var i=function(e,r){o(e,r);t(n,e,r);return e};try{n=e.getOwnPropertyDescriptor(e.prototype,r).set;t(n,{},null)}catch(a){if(e.prototype!=={}[r]){return}n=function(e){this[r]=e};i.polyfill=i(i({},null),e.prototype)instanceof e}return i}(Object,\"__proto__\")};b(Object,kt)}if(Object.setPrototypeOf&&Object.getPrototypeOf&&Object.getPrototypeOf(Object.setPrototypeOf({},null))!==null&&Object.getPrototypeOf(Object.create(null))===null){(function(){var e=Object.create(null);var t=Object.getPrototypeOf;var r=Object.setPrototypeOf;Object.getPrototypeOf=function(r){var n=t(r);return n===e?null:n};Object.setPrototypeOf=function(t,n){var o=n===null?e:n;return r(t,o)};Object.setPrototypeOf.polyfill=false})()}var Lt=!i(function(){return Object.keys(\"foo\")});if(!Lt){var Ft=Object.keys;ne(Object,\"keys\",function keys(e){return Ft(ce.ToObject(e))});n=Object.keys}var Dt=i(function(){return Object.keys(/a/g)});if(Dt){var zt=Object.keys;ne(Object,\"keys\",function keys(e){if(re.regex(e)){var t=[];for(var r in e){if(z(e,r)){M(t,r)}}return t}return zt(e)});n=Object.keys}if(Object.getOwnPropertyNames){var qt=!i(function(){return Object.getOwnPropertyNames(\"foo\")});if(!qt){var Wt=typeof window===\"object\"?Object.getOwnPropertyNames(window):[];var Gt=Object.getOwnPropertyNames;ne(Object,\"getOwnPropertyNames\",function getOwnPropertyNames(e){var t=ce.ToObject(e);if(g(t)===\"[object Window]\"){try{return Gt(t)}catch(r){return P([],Wt)}}return Gt(t)})}}if(Object.getOwnPropertyDescriptor){var Ht=!i(function(){return Object.getOwnPropertyDescriptor(\"foo\",\"bar\")});if(!Ht){var Vt=Object.getOwnPropertyDescriptor;ne(Object,\"getOwnPropertyDescriptor\",function getOwnPropertyDescriptor(e,t){return Vt(ce.ToObject(e),t)})}}if(Object.seal){var Bt=!i(function(){return Object.seal(\"foo\")});if(!Bt){var Ut=Object.seal;ne(Object,\"seal\",function seal(e){if(!ce.TypeIsObject(e)){return e}return Ut(e)})}}if(Object.isSealed){var $t=!i(function(){return Object.isSealed(\"foo\")});if(!$t){var Jt=Object.isSealed;ne(Object,\"isSealed\",function isSealed(e){if(!ce.TypeIsObject(e)){return true}return Jt(e)})}}if(Object.freeze){var Xt=!i(function(){return Object.freeze(\"foo\")});if(!Xt){var Kt=Object.freeze;ne(Object,\"freeze\",function freeze(e){if(!ce.TypeIsObject(e)){return e}return Kt(e)})}}if(Object.isFrozen){var Zt=!i(function(){return Object.isFrozen(\"foo\")});if(!Zt){var Yt=Object.isFrozen;ne(Object,\"isFrozen\",function isFrozen(e){if(!ce.TypeIsObject(e)){return true}return Yt(e)})}}if(Object.preventExtensions){var Qt=!i(function(){return Object.preventExtensions(\"foo\")});if(!Qt){var er=Object.preventExtensions;ne(Object,\"preventExtensions\",function preventExtensions(e){if(!ce.TypeIsObject(e)){return e}return er(e)})}}if(Object.isExtensible){var tr=!i(function(){return Object.isExtensible(\"foo\")});if(!tr){var rr=Object.isExtensible;ne(Object,\"isExtensible\",function isExtensible(e){if(!ce.TypeIsObject(e)){return false}return rr(e)})}}if(Object.getPrototypeOf){var nr=!i(function(){return Object.getPrototypeOf(\"foo\")});if(!nr){var or=Object.getPrototypeOf;ne(Object,\"getPrototypeOf\",function getPrototypeOf(e){return or(ce.ToObject(e))})}}var ir=s&&function(){var e=Object.getOwnPropertyDescriptor(RegExp.prototype,\"flags\");return e&&ce.IsCallable(e.get)}();if(s&&!ir){var ar=function flags(){if(!ce.TypeIsObject(this)){throw new TypeError(\"Method called on incompatible type: must be an object.\")}var e=\"\";if(this.global){e+=\"g\"}if(this.ignoreCase){e+=\"i\"}if(this.multiline){e+=\"m\"}if(this.unicode){e+=\"u\"}if(this.sticky){e+=\"y\"}return e};m.getter(RegExp.prototype,\"flags\",ar)}var ur=s&&a(function(){return String(new RegExp(/a/g,\"i\"))===\"/a/i\"});var fr=oe&&s&&function(){var e=/./;e[$.match]=false;return RegExp(e)===e}();var sr=a(function(){return RegExp.prototype.toString.call({source:\"abc\"})===\"/abc/\"});var cr=sr&&a(function(){return RegExp.prototype.toString.call({source:\"a\",flags:\"b\"})===\"/a/b\"});if(!sr||!cr){var lr=RegExp.prototype.toString;h(RegExp.prototype,\"toString\",function toString(){var e=ce.RequireObjectCoercible(this);if(re.regex(e)){return t(lr,e)}var r=ue(e.source);var n=ue(e.flags);return\"/\"+r+\"/\"+n},true);m.preserveToString(RegExp.prototype.toString,lr)}if(s&&(!ur||fr)){var pr=Object.getOwnPropertyDescriptor(RegExp.prototype,\"flags\").get;var vr=Object.getOwnPropertyDescriptor(RegExp.prototype,\"source\")||{};var yr=function(){return this.source};var hr=ce.IsCallable(vr.get)?vr.get:yr;var br=RegExp;var gr=function(){return function RegExp(e,t){var r=ce.IsRegExp(e);var n=this instanceof RegExp;if(!n&&r&&typeof t===\"undefined\"&&e.constructor===RegExp){return e}var o=e;var i=t;if(re.regex(e)){o=ce.Call(hr,e);i=typeof t===\"undefined\"?ce.Call(pr,e):t;return new RegExp(o,i)}else if(r){o=e.source;i=typeof t===\"undefined\"?e.flags:t}return new br(e,t)}}();Ee(br,gr,{$input:true});RegExp=gr;m.redefine(S,\"RegExp\",gr)}if(s){var dr={input:\"$_\",lastMatch:\"$&\",lastParen:\"$+\",leftContext:\"$`\",rightContext:\"$'\"};l(n(dr),function(e){if(e in RegExp&&!(dr[e]in RegExp)){m.getter(RegExp,dr[e],function get(){return RegExp[e]})}})}Ce(RegExp);var mr=1/Number.EPSILON;var Or=function roundTiesToEven(e){return e+mr-mr};var wr=Math.pow(2,-23);var jr=Math.pow(2,127)*(2-wr);var Sr=Math.pow(2,-126);var Tr=Math.E;var Ir=Math.LOG2E;var Er=Math.LOG10E;var Pr=Number.prototype.clz;delete Number.prototype.clz;var Cr={acosh:function acosh(e){var t=Number(e);if(X(t)||e<1){return NaN}if(t===1){return 0}if(t===Infinity){return t}var r=1/(t*t);if(t<2){return Y(t-1+D(1-r)*t)}var n=t/2;return Y(n+D(1-r)*n-1)+1/Ir},asinh:function asinh(e){var t=Number(e);if(t===0||!T(t)){return t}var r=k(t);var n=r*r;var o=Z(t);if(r<1){return o*Y(r+n/(D(n+1)+1))}return o*(Y(r/2+D(1+1/n)*r/2-1)+1/Ir)},atanh:function atanh(e){var t=Number(e);if(t===0){return t}if(t===-1){return-Infinity}if(t===1){return Infinity}if(X(t)||t<-1||t>1){return NaN}var r=k(t);return Z(t)*Y(2*r/(1-r))/2},cbrt:function cbrt(e){var t=Number(e);if(t===0){return t}var r=t<0;var n;if(r){t=-t}if(t===Infinity){n=Infinity}else{n=L(F(t)/3);n=(t/(n*n)+2*n)/3}return r?-n:n},clz32:function clz32(e){var t=Number(e);var r=ce.ToUint32(t);if(r===0){return 32}return Pr?ce.Call(Pr,r):31-_(F(r+.5)*Ir)},cosh:function cosh(e){var t=Number(e);if(t===0){return 1}if(X(t)){return NaN}if(!T(t)){return Infinity}var r=L(k(t)-1);return(r+1/(r*Tr*Tr))*(Tr/2)},expm1:function expm1(e){var t=Number(e);if(t===-Infinity){return-1}if(!T(t)||t===0){return t}if(k(t)>.5){return L(t)-1}var r=t;var n=0;var o=1;while(n+r!==n){n+=r;o+=1;r*=t/o}return n},hypot:function hypot(e,t){var r=0;var n=0;for(var o=0;o<arguments.length;++o){var i=k(Number(arguments[o]));if(n<i){r*=n/i*(n/i);r+=1;n=i}else{r+=i>0?i/n*(i/n):i}}return n===Infinity?Infinity:n*D(r)},log2:function log2(e){return F(e)*Ir},log10:function log10(e){return F(e)*Er},log1p:Y,sign:Z,sinh:function sinh(e){var t=Number(e);if(!T(t)||t===0){return t}var r=k(t);if(r<1){var n=Math.expm1(r);return Z(t)*n*(1+1/(n+1))/2}var o=L(r-1);return Z(t)*(o-1/(o*Tr*Tr))*(Tr/2)},tanh:function tanh(e){var t=Number(e);if(X(t)||t===0){return t}if(t>=20){return 1}if(t<=-20){return-1}return(Math.expm1(t)-Math.expm1(-t))/(L(t)+L(-t))},trunc:function trunc(e){var t=Number(e);return t<0?-_(-t):_(t)},imul:function imul(e,t){var r=ce.ToUint32(e);var n=ce.ToUint32(t);var o=r>>>16&65535;var i=r&65535;var a=n>>>16&65535;var u=n&65535;return i*u+(o*u+i*a<<16>>>0)|0},fround:function fround(e){var t=Number(e);if(t===0||t===Infinity||t===-Infinity||X(t)){return t}var r=Z(t);var n=k(t);if(n<Sr){return r*Or(n/Sr/wr)*Sr*wr}var o=(1+wr/Number.EPSILON)*n;var i=o-(o-n);if(i>jr||X(i)){return r*Infinity}return r*i}};var Mr=function withinULPDistance(e,t,r){return k(1-e/t)/Number.EPSILON<(r||8)};b(Math,Cr);h(Math,\"sinh\",Cr.sinh,Math.sinh(710)===Infinity);h(Math,\"cosh\",Cr.cosh,Math.cosh(710)===Infinity);h(Math,\"log1p\",Cr.log1p,Math.log1p(-1e-17)!==-1e-17);h(Math,\"asinh\",Cr.asinh,Math.asinh(-1e7)!==-Math.asinh(1e7));h(Math,\"asinh\",Cr.asinh,Math.asinh(1e300)===Infinity);h(Math,\"atanh\",Cr.atanh,Math.atanh(1e-300)===0);h(Math,\"tanh\",Cr.tanh,Math.tanh(-2e-17)!==-2e-17);\nh(Math,\"acosh\",Cr.acosh,Math.acosh(Number.MAX_VALUE)===Infinity);h(Math,\"acosh\",Cr.acosh,!Mr(Math.acosh(1+Number.EPSILON),Math.sqrt(2*Number.EPSILON)));h(Math,\"cbrt\",Cr.cbrt,!Mr(Math.cbrt(1e-300),1e-100));h(Math,\"sinh\",Cr.sinh,Math.sinh(-2e-17)!==-2e-17);var xr=Math.expm1(10);h(Math,\"expm1\",Cr.expm1,xr>22025.465794806718||xr<22025.465794806718);var Nr=Math.round;var Ar=Math.round(.5-Number.EPSILON/4)===0&&Math.round(-.5+Number.EPSILON/3.99)===1;var Rr=mr+1;var _r=2*mr-1;var kr=[Rr,_r].every(function(e){return Math.round(e)===e});h(Math,\"round\",function round(e){var t=_(e);var r=t===-1?-0:t+1;return e-t<.5?t:r},!Ar||!kr);m.preserveToString(Math.round,Nr);var Lr=Math.imul;if(Math.imul(4294967295,5)!==-5){Math.imul=Cr.imul;m.preserveToString(Math.imul,Lr)}if(Math.imul.length!==2){ne(Math,\"imul\",function imul(e,t){return ce.Call(Lr,Math,arguments)})}var Fr=function(){var e=S.setTimeout;if(typeof e!==\"function\"&&typeof e!==\"object\"){return}ce.IsPromise=function(e){if(!ce.TypeIsObject(e)){return false}if(typeof e._promise===\"undefined\"){return false}return true};var r=function(e){if(!ce.IsConstructor(e)){throw new TypeError(\"Bad promise constructor\")}var t=this;var r=function(e,r){if(t.resolve!==void 0||t.reject!==void 0){throw new TypeError(\"Bad Promise implementation!\")}t.resolve=e;t.reject=r};t.resolve=void 0;t.reject=void 0;t.promise=new e(r);if(!(ce.IsCallable(t.resolve)&&ce.IsCallable(t.reject))){throw new TypeError(\"Bad promise constructor\")}};var n;if(typeof window!==\"undefined\"&&ce.IsCallable(window.postMessage)){n=function(){var e=[];var t=\"zero-timeout-message\";var r=function(r){M(e,r);window.postMessage(t,\"*\")};var n=function(r){if(r.source===window&&r.data===t){r.stopPropagation();if(e.length===0){return}var n=N(e);n()}};window.addEventListener(\"message\",n,true);return r}}var o=function(){var e=S.Promise;var t=e&&e.resolve&&e.resolve();return t&&function(e){return t.then(e)}};var i=ce.IsCallable(S.setImmediate)?S.setImmediate:typeof process===\"object\"&&process.nextTick?process.nextTick:o()||(ce.IsCallable(n)?n():function(t){e(t,0)});var a=function(e){return e};var u=function(e){throw e};var f=0;var s=1;var c=2;var l=0;var p=1;var v=2;var y={};var h=function(e,t,r){i(function(){g(e,t,r)})};var g=function(e,t,r){var n,o;if(t===y){return e(r)}try{n=e(r);o=t.resolve}catch(i){n=i;o=t.reject}o(n)};var d=function(e,t){var r=e._promise;var n=r.reactionLength;if(n>0){h(r.fulfillReactionHandler0,r.reactionCapability0,t);r.fulfillReactionHandler0=void 0;r.rejectReactions0=void 0;r.reactionCapability0=void 0;if(n>1){for(var o=1,i=0;o<n;o++,i+=3){h(r[i+l],r[i+v],t);e[i+l]=void 0;e[i+p]=void 0;e[i+v]=void 0}}}r.result=t;r.state=s;r.reactionLength=0};var m=function(e,t){var r=e._promise;var n=r.reactionLength;if(n>0){h(r.rejectReactionHandler0,r.reactionCapability0,t);r.fulfillReactionHandler0=void 0;r.rejectReactions0=void 0;r.reactionCapability0=void 0;if(n>1){for(var o=1,i=0;o<n;o++,i+=3){h(r[i+p],r[i+v],t);e[i+l]=void 0;e[i+p]=void 0;e[i+v]=void 0}}}r.result=t;r.state=c;r.reactionLength=0};var O=function(e){var t=false;var r=function(r){var n;if(t){return}t=true;if(r===e){return m(e,new TypeError(\"Self resolution\"))}if(!ce.TypeIsObject(r)){return d(e,r)}try{n=r.then}catch(o){return m(e,o)}if(!ce.IsCallable(n)){return d(e,r)}i(function(){j(e,r,n)})};var n=function(r){if(t){return}t=true;return m(e,r)};return{resolve:r,reject:n}};var w=function(e,r,n,o){if(e===I){t(e,r,n,o,y)}else{t(e,r,n,o)}};var j=function(e,t,r){var n=O(e);var o=n.resolve;var i=n.reject;try{w(r,t,o,i)}catch(a){i(a)}};var T,I;var E=function(){var e=function Promise(t){if(!(this instanceof e)){throw new TypeError('Constructor Promise requires \"new\"')}if(this&&this._promise){throw new TypeError(\"Bad construction\")}if(!ce.IsCallable(t)){throw new TypeError(\"not a valid resolver\")}var r=Ae(this,e,T,{_promise:{result:void 0,state:f,reactionLength:0,fulfillReactionHandler0:void 0,rejectReactionHandler0:void 0,reactionCapability0:void 0}});var n=O(r);var o=n.reject;try{t(n.resolve,o)}catch(i){o(i)}return r};return e}();T=E.prototype;var P=function(e,t,r,n){var o=false;return function(i){if(o){return}o=true;t[e]=i;if(--n.count===0){var a=r.resolve;a(t)}}};var C=function(e,t,r){var n=e.iterator;var o=[];var i={count:1};var a,u;var f=0;while(true){try{a=ce.IteratorStep(n);if(a===false){e.done=true;break}u=a.value}catch(s){e.done=true;throw s}o[f]=void 0;var c=t.resolve(u);var l=P(f,o,r,i);i.count+=1;w(c.then,c,l,r.reject);f+=1}if(--i.count===0){var p=r.resolve;p(o)}return r.promise};var x=function(e,t,r){var n=e.iterator;var o,i,a;while(true){try{o=ce.IteratorStep(n);if(o===false){e.done=true;break}i=o.value}catch(u){e.done=true;throw u}a=t.resolve(i);w(a.then,a,r.resolve,r.reject)}return r.promise};b(E,{all:function all(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Promise is not object\")}var n=new r(t);var o,i;try{o=ce.GetIterator(e);i={iterator:o,done:false};return C(i,t,n)}catch(a){var u=a;if(i&&!i.done){try{ce.IteratorClose(o,true)}catch(f){u=f}}var s=n.reject;s(u);return n.promise}},race:function race(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Promise is not object\")}var n=new r(t);var o,i;try{o=ce.GetIterator(e);i={iterator:o,done:false};return x(i,t,n)}catch(a){var u=a;if(i&&!i.done){try{ce.IteratorClose(o,true)}catch(f){u=f}}var s=n.reject;s(u);return n.promise}},reject:function reject(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Bad promise constructor\")}var n=new r(t);var o=n.reject;o(e);return n.promise},resolve:function resolve(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Bad promise constructor\")}if(ce.IsPromise(e)){var n=e.constructor;if(n===t){return e}}var o=new r(t);var i=o.resolve;i(e);return o.promise}});b(T,{\"catch\":function(e){return this.then(null,e)},then:function then(e,t){var n=this;if(!ce.IsPromise(n)){throw new TypeError(\"not a promise\")}var o=ce.SpeciesConstructor(n,E);var i;var b=arguments.length>2&&arguments[2]===y;if(b&&o===E){i=y}else{i=new r(o)}var g=ce.IsCallable(e)?e:a;var d=ce.IsCallable(t)?t:u;var m=n._promise;var O;if(m.state===f){if(m.reactionLength===0){m.fulfillReactionHandler0=g;m.rejectReactionHandler0=d;m.reactionCapability0=i}else{var w=3*(m.reactionLength-1);m[w+l]=g;m[w+p]=d;m[w+v]=i}m.reactionLength+=1}else if(m.state===s){O=m.result;h(g,i,O)}else if(m.state===c){O=m.result;h(d,i,O)}else{throw new TypeError(\"unexpected Promise state\")}return i.promise}});y=new r(E);I=T.then;return E}();if(S.Promise){delete S.Promise.accept;delete S.Promise.defer;delete S.Promise.prototype.chain}if(typeof Fr===\"function\"){b(S,{Promise:Fr});var Dr=w(S.Promise,function(e){return e.resolve(42).then(function(){})instanceof e});var zr=!i(function(){return S.Promise.reject(42).then(null,5).then(null,W)});var qr=i(function(){return S.Promise.call(3,W)});var Wr=function(e){var t=e.resolve(5);t.constructor={};var r=e.resolve(t);try{r.then(null,W).then(null,W)}catch(n){return true}return t===r}(S.Promise);var Gr=s&&function(){var e=0;var t=Object.defineProperty({},\"then\",{get:function(){e+=1}});Promise.resolve(t);return e===1}();var Hr=function BadResolverPromise(e){var t=new Promise(e);e(3,function(){});this.then=t.then;this.constructor=BadResolverPromise};Hr.prototype=Promise.prototype;Hr.all=Promise.all;var Vr=a(function(){return!!Hr.all([1,2])});if(!Dr||!zr||!qr||Wr||!Gr||Vr){Promise=Fr;ne(S,\"Promise\",Fr)}if(Promise.all.length!==1){var Br=Promise.all;ne(Promise,\"all\",function all(e){return ce.Call(Br,this,arguments)})}if(Promise.race.length!==1){var Ur=Promise.race;ne(Promise,\"race\",function race(e){return ce.Call(Ur,this,arguments)})}if(Promise.resolve.length!==1){var $r=Promise.resolve;ne(Promise,\"resolve\",function resolve(e){return ce.Call($r,this,arguments)})}if(Promise.reject.length!==1){var Jr=Promise.reject;ne(Promise,\"reject\",function reject(e){return ce.Call(Jr,this,arguments)})}Mt(Promise,\"all\");Mt(Promise,\"race\");Mt(Promise,\"resolve\");Mt(Promise,\"reject\");Ce(Promise)}var Xr=function(e){var t=n(p(e,function(e,t){e[t]=true;return e},{}));return e.join(\":\")===t.join(\":\")};var Kr=Xr([\"z\",\"a\",\"bb\"]);var Zr=Xr([\"z\",1,\"a\",\"3\",2]);if(s){var Yr=function fastkey(e,t){if(!t&&!Kr){return null}if(se(e)){return\"^\"+ce.ToString(e)}else if(typeof e===\"string\"){return\"$\"+e}else if(typeof e===\"number\"){if(!Zr){return\"n\"+e}return e}else if(typeof e===\"boolean\"){return\"b\"+e}return null};var Qr=function emptyObject(){return Object.create?Object.create(null):{}};var en=function addIterableToMap(e,n,o){if(r(o)||re.string(o)){l(o,function(e){if(!ce.TypeIsObject(e)){throw new TypeError(\"Iterator value \"+e+\" is not an entry object\")}n.set(e[0],e[1])})}else if(o instanceof e){t(e.prototype.forEach,o,function(e,t){n.set(t,e)})}else{var i,a;if(!se(o)){a=n.set;if(!ce.IsCallable(a)){throw new TypeError(\"bad map\")}i=ce.GetIterator(o)}if(typeof i!==\"undefined\"){while(true){var u=ce.IteratorStep(i);if(u===false){break}var f=u.value;try{if(!ce.TypeIsObject(f)){throw new TypeError(\"Iterator value \"+f+\" is not an entry object\")}t(a,n,f[0],f[1])}catch(s){ce.IteratorClose(i,true);throw s}}}}};var tn=function addIterableToSet(e,n,o){if(r(o)||re.string(o)){l(o,function(e){n.add(e)})}else if(o instanceof e){t(e.prototype.forEach,o,function(e){n.add(e)})}else{var i,a;if(!se(o)){a=n.add;if(!ce.IsCallable(a)){throw new TypeError(\"bad set\")}i=ce.GetIterator(o)}if(typeof i!==\"undefined\"){while(true){var u=ce.IteratorStep(i);if(u===false){break}var f=u.value;try{t(a,n,f)}catch(s){ce.IteratorClose(i,true);throw s}}}}};var rn={Map:function(){var e={};var r=function MapEntry(e,t){this.key=e;this.value=t;this.next=null;this.prev=null};r.prototype.isRemoved=function isRemoved(){return this.key===e};var n=function isMap(e){return!!e._es6map};var o=function requireMapSlot(e,t){if(!ce.TypeIsObject(e)||!n(e)){throw new TypeError(\"Method Map.prototype.\"+t+\" called on incompatible receiver \"+ce.ToString(e))}};var i=function MapIterator(e,t){o(e,\"[[MapIterator]]\");this.head=e._head;this.i=this.head;this.kind=t};i.prototype={isMapIterator:true,next:function next(){if(!this.isMapIterator){throw new TypeError(\"Not a MapIterator\")}var e=this.i;var t=this.kind;var r=this.head;if(typeof this.i===\"undefined\"){return Ke()}while(e.isRemoved()&&e!==r){e=e.prev}var n;while(e.next!==r){e=e.next;if(!e.isRemoved()){if(t===\"key\"){n=e.key}else if(t===\"value\"){n=e.value}else{n=[e.key,e.value]}this.i=e;return Ke(n)}}this.i=void 0;return Ke()}};Me(i.prototype);var a;var u=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}if(this&&this._es6map){throw new TypeError(\"Bad construction\")}var e=Ae(this,Map,a,{_es6map:true,_head:null,_map:G?new G:null,_size:0,_storage:Qr()});var t=new r(null,null);t.next=t.prev=t;e._head=t;if(arguments.length>0){en(Map,e,arguments[0])}return e};a=u.prototype;m.getter(a,\"size\",function(){if(typeof this._size===\"undefined\"){throw new TypeError(\"size method called on incompatible Map\")}return this._size});b(a,{get:function get(e){o(this,\"get\");var t;var r=Yr(e,true);if(r!==null){t=this._storage[r];if(t){return t.value}else{return}}if(this._map){t=V.call(this._map,e);if(t){return t.value}else{return}}var n=this._head;var i=n;while((i=i.next)!==n){if(ce.SameValueZero(i.key,e)){return i.value}}},has:function has(e){o(this,\"has\");var t=Yr(e,true);if(t!==null){return typeof this._storage[t]!==\"undefined\"}if(this._map){return B.call(this._map,e)}var r=this._head;var n=r;while((n=n.next)!==r){if(ce.SameValueZero(n.key,e)){return true}}return false},set:function set(e,t){o(this,\"set\");var n=this._head;var i=n;var a;var u=Yr(e,true);if(u!==null){if(typeof this._storage[u]!==\"undefined\"){this._storage[u].value=t;return this}else{a=this._storage[u]=new r(e,t);i=n.prev}}else if(this._map){if(B.call(this._map,e)){V.call(this._map,e).value=t}else{a=new r(e,t);U.call(this._map,e,a);i=n.prev}}while((i=i.next)!==n){if(ce.SameValueZero(i.key,e)){i.value=t;return this}}a=a||new r(e,t);if(ce.SameValue(-0,e)){a.key=+0}a.next=this._head;a.prev=this._head.prev;a.prev.next=a;a.next.prev=a;this._size+=1;return this},\"delete\":function(t){o(this,\"delete\");var r=this._head;var n=r;var i=Yr(t,true);if(i!==null){if(typeof this._storage[i]===\"undefined\"){return false}n=this._storage[i].prev;delete this._storage[i]}else if(this._map){if(!B.call(this._map,t)){return false}n=V.call(this._map,t).prev;H.call(this._map,t)}while((n=n.next)!==r){if(ce.SameValueZero(n.key,t)){n.key=e;n.value=e;n.prev.next=n.next;n.next.prev=n.prev;this._size-=1;return true}}return false},clear:function clear(){o(this,\"clear\");this._map=G?new G:null;this._size=0;this._storage=Qr();var t=this._head;var r=t;var n=r.next;while((r=n)!==t){r.key=e;r.value=e;n=r.next;r.next=r.prev=t}t.next=t.prev=t},keys:function keys(){o(this,\"keys\");return new i(this,\"key\")},values:function values(){o(this,\"values\");return new i(this,\"value\")},entries:function entries(){o(this,\"entries\");return new i(this,\"key+value\")},forEach:function forEach(e){o(this,\"forEach\");var r=arguments.length>1?arguments[1]:null;var n=this.entries();for(var i=n.next();!i.done;i=n.next()){if(r){t(e,r,i.value[1],i.value[0],this)}else{e(i.value[1],i.value[0],this)}}}});Me(a,a.entries);return u}(),Set:function(){var e=function isSet(e){return e._es6set&&typeof e._storage!==\"undefined\"};var r=function requireSetSlot(t,r){if(!ce.TypeIsObject(t)||!e(t)){throw new TypeError(\"Set.prototype.\"+r+\" called on incompatible receiver \"+ce.ToString(t))}};var o;var i=function Set(){if(!(this instanceof Set)){throw new TypeError('Constructor Set requires \"new\"')}if(this&&this._es6set){throw new TypeError(\"Bad construction\")}var e=Ae(this,Set,o,{_es6set:true,\"[[SetData]]\":null,_storage:Qr()});if(!e._es6set){throw new TypeError(\"bad set\")}if(arguments.length>0){tn(Set,e,arguments[0])}return e};o=i.prototype;var a=function(e){var t=e;if(t===\"^null\"){return null}else if(t===\"^undefined\"){return void 0}else{var r=t.charAt(0);if(r===\"$\"){return C(t,1)}else if(r===\"n\"){return+C(t,1)}else if(r===\"b\"){return t===\"btrue\"}}return+t};var u=function ensureMap(e){if(!e[\"[[SetData]]\"]){var t=new rn.Map;e[\"[[SetData]]\"]=t;l(n(e._storage),function(e){var r=a(e);t.set(r,r)});e[\"[[SetData]]\"]=t}e._storage=null};m.getter(i.prototype,\"size\",function(){r(this,\"size\");if(this._storage){return n(this._storage).length}u(this);return this[\"[[SetData]]\"].size});b(i.prototype,{has:function has(e){r(this,\"has\");var t;if(this._storage&&(t=Yr(e))!==null){return!!this._storage[t]}u(this);return this[\"[[SetData]]\"].has(e)},add:function add(e){r(this,\"add\");var t;if(this._storage&&(t=Yr(e))!==null){this._storage[t]=true;return this}u(this);this[\"[[SetData]]\"].set(e,e);return this},\"delete\":function(e){r(this,\"delete\");var t;if(this._storage&&(t=Yr(e))!==null){var n=z(this._storage,t);return delete this._storage[t]&&n}u(this);return this[\"[[SetData]]\"][\"delete\"](e)},clear:function clear(){r(this,\"clear\");if(this._storage){this._storage=Qr()}if(this[\"[[SetData]]\"]){this[\"[[SetData]]\"].clear()}},values:function values(){r(this,\"values\");u(this);return new f(this[\"[[SetData]]\"].values())},entries:function entries(){r(this,\"entries\");u(this);return new f(this[\"[[SetData]]\"].entries())},forEach:function forEach(e){r(this,\"forEach\");var n=arguments.length>1?arguments[1]:null;var o=this;u(o);this[\"[[SetData]]\"].forEach(function(r,i){if(n){t(e,n,i,i,o)}else{e(i,i,o)}})}});h(i.prototype,\"keys\",i.prototype.values,true);Me(i.prototype,i.prototype.values);var f=function SetIterator(e){this.it=e};f.prototype={isSetIterator:true,next:function next(){if(!this.isSetIterator){throw new TypeError(\"Not a SetIterator\")}return this.it.next()}};Me(f.prototype);return i}()};var nn=S.Set&&!Set.prototype[\"delete\"]&&Set.prototype.remove&&Set.prototype.items&&Set.prototype.map&&Array.isArray((new Set).keys);if(nn){S.Set=rn.Set}if(S.Map||S.Set){var on=a(function(){return new Map([[1,2]]).get(1)===2});if(!on){S.Map=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}var e=new G;if(arguments.length>0){en(Map,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,S.Map.prototype);return e};S.Map.prototype=O(G.prototype);h(S.Map.prototype,\"constructor\",S.Map,true);m.preserveToString(S.Map,G)}var an=new Map;var un=function(){var e=new Map([[1,0],[2,0],[3,0],[4,0]]);e.set(-0,e);return e.get(0)===e&&e.get(-0)===e&&e.has(0)&&e.has(-0)}();var fn=an.set(1,2)===an;if(!un||!fn){ne(Map.prototype,\"set\",function set(e,r){t(U,this,e===0?0:e,r);return this})}if(!un){b(Map.prototype,{get:function get(e){return t(V,this,e===0?0:e)},has:function has(e){return t(B,this,e===0?0:e)}},true);m.preserveToString(Map.prototype.get,V);m.preserveToString(Map.prototype.has,B)}var sn=new Set;var cn=Set.prototype[\"delete\"]&&Set.prototype.add&&Set.prototype.has&&function(e){e[\"delete\"](0);e.add(-0);return!e.has(0)}(sn);var ln=sn.add(1)===sn;if(!cn||!ln){var pn=Set.prototype.add;Set.prototype.add=function add(e){t(pn,this,e===0?0:e);return this};m.preserveToString(Set.prototype.add,pn)}if(!cn){var vn=Set.prototype.has;Set.prototype.has=function has(e){return t(vn,this,e===0?0:e)};m.preserveToString(Set.prototype.has,vn);var yn=Set.prototype[\"delete\"];Set.prototype[\"delete\"]=function SetDelete(e){return t(yn,this,e===0?0:e)};m.preserveToString(Set.prototype[\"delete\"],yn)}var hn=w(S.Map,function(e){var t=new e([]);t.set(42,42);return t instanceof e});var bn=Object.setPrototypeOf&&!hn;var gn=function(){try{return!(S.Map()instanceof S.Map)}catch(e){return e instanceof TypeError}}();if(S.Map.length!==0||bn||!gn){S.Map=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}var e=new G;if(arguments.length>0){en(Map,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,Map.prototype);return e};S.Map.prototype=G.prototype;h(S.Map.prototype,\"constructor\",S.Map,true);m.preserveToString(S.Map,G)}var dn=w(S.Set,function(e){var t=new e([]);t.add(42,42);return t instanceof e});var mn=Object.setPrototypeOf&&!dn;var On=function(){try{return!(S.Set()instanceof S.Set)}catch(e){return e instanceof TypeError}}();if(S.Set.length!==0||mn||!On){var wn=S.Set;S.Set=function Set(){if(!(this instanceof Set)){throw new TypeError('Constructor Set requires \"new\"')}var e=new wn;if(arguments.length>0){tn(Set,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,Set.prototype);return e};S.Set.prototype=wn.prototype;h(S.Set.prototype,\"constructor\",S.Set,true);m.preserveToString(S.Set,wn)}var jn=new S.Map;var Sn=!a(function(){return jn.keys().next().done});if(typeof S.Map.prototype.clear!==\"function\"||(new S.Set).size!==0||jn.size!==0||typeof S.Map.prototype.keys!==\"function\"||typeof S.Set.prototype.keys!==\"function\"||typeof S.Map.prototype.forEach!==\"function\"||typeof S.Set.prototype.forEach!==\"function\"||u(S.Map)||u(S.Set)||typeof jn.keys().next!==\"function\"||Sn||!hn){b(S,{Map:rn.Map,Set:rn.Set},true)}if(S.Set.prototype.keys!==S.Set.prototype.values){h(S.Set.prototype,\"keys\",S.Set.prototype.values,true)}Me(Object.getPrototypeOf((new S.Map).keys()));Me(Object.getPrototypeOf((new S.Set).keys()));if(c&&S.Set.prototype.has.name!==\"has\"){var Tn=S.Set.prototype.has;ne(S.Set.prototype,\"has\",function has(e){return t(Tn,this,e)})}}b(S,rn);Ce(S.Map);Ce(S.Set)}var In=function throwUnlessTargetIsObject(e){if(!ce.TypeIsObject(e)){throw new TypeError(\"target must be an object\")}};var En={apply:function apply(){return ce.Call(ce.Call,null,arguments)},construct:function construct(e,t){if(!ce.IsConstructor(e)){throw new TypeError(\"First argument must be a constructor.\")}var r=arguments.length>2?arguments[2]:e;if(!ce.IsConstructor(r)){throw new TypeError(\"new.target must be a constructor.\")}return ce.Construct(e,t,r,\"internal\")},deleteProperty:function deleteProperty(e,t){In(e);if(s){var r=Object.getOwnPropertyDescriptor(e,t);if(r&&!r.configurable){return false}}return delete e[t]},has:function has(e,t){In(e);return t in e}};if(Object.getOwnPropertyNames){Object.assign(En,{ownKeys:function ownKeys(e){In(e);var t=Object.getOwnPropertyNames(e);if(ce.IsCallable(Object.getOwnPropertySymbols)){x(t,Object.getOwnPropertySymbols(e))}return t}})}var Pn=function ConvertExceptionToBoolean(e){return!i(e)};if(Object.preventExtensions){Object.assign(En,{isExtensible:function isExtensible(e){In(e);return Object.isExtensible(e)},preventExtensions:function preventExtensions(e){In(e);return Pn(function(){return Object.preventExtensions(e)})}})}if(s){var Cn=function get(e,t,r){var n=Object.getOwnPropertyDescriptor(e,t);if(!n){var o=Object.getPrototypeOf(e);if(o===null){return void 0}return Cn(o,t,r)}if(\"value\"in n){return n.value}if(n.get){return ce.Call(n.get,r)}return void 0};var Mn=function set(e,r,n,o){var i=Object.getOwnPropertyDescriptor(e,r);if(!i){var a=Object.getPrototypeOf(e);if(a!==null){return Mn(a,r,n,o)}i={value:void 0,writable:true,enumerable:true,configurable:true}}if(\"value\"in i){if(!i.writable){return false}if(!ce.TypeIsObject(o)){return false}var u=Object.getOwnPropertyDescriptor(o,r);if(u){return ae.defineProperty(o,r,{value:n})}else{return ae.defineProperty(o,r,{value:n,writable:true,enumerable:true,configurable:true})}}if(i.set){t(i.set,o,n);return true}return false};Object.assign(En,{defineProperty:function defineProperty(e,t,r){In(e);return Pn(function(){return Object.defineProperty(e,t,r)})},getOwnPropertyDescriptor:function getOwnPropertyDescriptor(e,t){In(e);return Object.getOwnPropertyDescriptor(e,t)},get:function get(e,t){In(e);var r=arguments.length>2?arguments[2]:e;return Cn(e,t,r)},set:function set(e,t,r){In(e);var n=arguments.length>3?arguments[3]:e;return Mn(e,t,r,n)}})}if(Object.getPrototypeOf){var xn=Object.getPrototypeOf;En.getPrototypeOf=function getPrototypeOf(e){In(e);return xn(e)}}if(Object.setPrototypeOf&&En.getPrototypeOf){var Nn=function(e,t){var r=t;while(r){if(e===r){return true}r=En.getPrototypeOf(r)}return false};Object.assign(En,{setPrototypeOf:function setPrototypeOf(e,t){In(e);if(t!==null&&!ce.TypeIsObject(t)){throw new TypeError(\"proto must be an object or null\")}if(t===ae.getPrototypeOf(e)){return true}if(ae.isExtensible&&!ae.isExtensible(e)){return false}if(Nn(e,t)){return false}Object.setPrototypeOf(e,t);return true}})}var An=function(e,t){if(!ce.IsCallable(S.Reflect[e])){h(S.Reflect,e,t)}else{var r=a(function(){S.Reflect[e](1);S.Reflect[e](NaN);S.Reflect[e](true);return true});if(r){ne(S.Reflect,e,t)}}};Object.keys(En).forEach(function(e){An(e,En[e])});var Rn=S.Reflect.getPrototypeOf;if(c&&Rn&&Rn.name!==\"getPrototypeOf\"){ne(S.Reflect,\"getPrototypeOf\",function getPrototypeOf(e){return t(Rn,S.Reflect,e)})}if(S.Reflect.setPrototypeOf){if(a(function(){S.Reflect.setPrototypeOf(1,{});return true})){ne(S.Reflect,\"setPrototypeOf\",En.setPrototypeOf)}}if(S.Reflect.defineProperty){if(!a(function(){var e=!S.Reflect.defineProperty(1,\"test\",{value:1});var t=typeof Object.preventExtensions!==\"function\"||!S.Reflect.defineProperty(Object.preventExtensions({}),\"test\",{});return e&&t})){ne(S.Reflect,\"defineProperty\",En.defineProperty)}}if(S.Reflect.construct){if(!a(function(){var e=function F(){};return S.Reflect.construct(function(){},[],e)instanceof e})){ne(S.Reflect,\"construct\",En.construct)}}if(String(new Date(NaN))!==\"Invalid Date\"){var _n=Date.prototype.toString;var kn=function toString(){var e=+this;if(e!==e){return\"Invalid Date\"}return ce.Call(_n,this)};ne(Date.prototype,\"toString\",kn)}var Ln={anchor:function anchor(e){return ce.CreateHTML(this,\"a\",\"name\",e)},big:function big(){return ce.CreateHTML(this,\"big\",\"\",\"\")},blink:function blink(){return ce.CreateHTML(this,\"blink\",\"\",\"\")},bold:function bold(){return ce.CreateHTML(this,\"b\",\"\",\"\")},fixed:function fixed(){return ce.CreateHTML(this,\"tt\",\"\",\"\")},fontcolor:function fontcolor(e){return ce.CreateHTML(this,\"font\",\"color\",e)},fontsize:function fontsize(e){return ce.CreateHTML(this,\"font\",\"size\",e)},italics:function italics(){return ce.CreateHTML(this,\"i\",\"\",\"\")},link:function link(e){return ce.CreateHTML(this,\"a\",\"href\",e)},small:function small(){return ce.CreateHTML(this,\"small\",\"\",\"\")},strike:function strike(){return ce.CreateHTML(this,\"strike\",\"\",\"\")},sub:function sub(){return ce.CreateHTML(this,\"sub\",\"\",\"\")},sup:function sub(){return ce.CreateHTML(this,\"sup\",\"\",\"\")}};l(Object.keys(Ln),function(e){var r=String.prototype[e];var n=false;if(ce.IsCallable(r)){var o=t(r,\"\",' \" ');var i=P([],o.match(/\"/g)).length;n=o!==o.toLowerCase()||i>2}else{n=true}if(n){ne(String.prototype,e,Ln[e])}});var Fn=function(){if(!oe){return false}var e=typeof JSON===\"object\"&&typeof JSON.stringify===\"function\"?JSON.stringify:null;if(!e){return false}if(typeof e($())!==\"undefined\"){return true}if(e([$()])!==\"[null]\"){return true}var t={a:$()};t[$()]=true;if(e(t)!==\"{}\"){return true}return false}();var Dn=a(function(){if(!oe){return true}return JSON.stringify(Object($()))===\"{}\"&&JSON.stringify([Object($())])===\"[{}]\"});if(Fn||!Dn){var zn=JSON.stringify;ne(JSON,\"stringify\",function stringify(e){if(typeof e===\"symbol\"){return}var n;if(arguments.length>1){n=arguments[1]}var o=[e];if(!r(n)){var i=ce.IsCallable(n)?n:null;var a=function(e,r){var n=i?t(i,this,e,r):r;if(typeof n!==\"symbol\"){if(re.symbol(n)){return Nt({})(n)}else{return n}}};o.push(a)}else{o.push(n)}if(arguments.length>2){o.push(arguments[2])}return zn.apply(this,o)})}return S});\n//# sourceMappingURL=es6-shim.map\n/*! jQuery v3.4.1 | (c) JS Foundation and other contributors | jquery.org/license */\n!function(e,t){\"use strict\";\"object\"==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(C,e){\"use strict\";var t=[],E=C.document,r=Object.getPrototypeOf,s=t.slice,g=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return\"function\"==typeof e&&\"number\"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement(\"script\");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+\"\":\"object\"==typeof e||\"function\"==typeof e?n[o.call(e)]||\"object\":typeof e}var f=\"3.4.1\",k=function(e,t){return new k.fn.init(e,t)},p=/^[\\s\\uFEFF\\xA0]+|[\\s\\uFEFF\\xA0]+$/g;function d(e){var t=!!e&&\"length\"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&(\"array\"===n||0===t||\"number\"==typeof t&&0<t&&t-1 in e)}k.fn=k.prototype={jquery:f,constructor:k,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=k.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return k.each(this,e)},map:function(n){return this.pushStack(k.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.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(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},k.extend=k.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for(\"boolean\"==typeof a&&(l=a,a=arguments[s]||{},s++),\"object\"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],\"__proto__\"!==t&&a!==r&&(l&&r&&(k.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||k.isPlainObject(n)?n:{},i=!1,a[t]=k.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},k.extend({expando:\"jQuery\"+(f+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]\"!==o.call(e))&&(!(t=r(e))||\"function\"==typeof(n=v.call(t,\"constructor\")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t){b(e,{nonce:t&&t.nonce})},each:function(e,t){var n,r=0;if(d(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}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(p,\"\")},makeArray:function(e,t){var n=t||[];return null!=e&&(d(Object(e))?k.merge(n,\"string\"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.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,i,o=0,a=[];if(d(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g.apply([],a)},guid:1,support:y}),\"function\"==typeof Symbol&&(k.fn[Symbol.iterator]=t[Symbol.iterator]),k.each(\"Boolean Number String Function Array Date RegExp Object Error Symbol\".split(\" \"),function(e,t){n[\"[object \"+t+\"]\"]=t.toLowerCase()});var h=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,k=\"sizzle\"+1*new Date,m=n.document,S=0,r=0,p=ue(),x=ue(),N=ue(),A=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R=\"checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped\",M=\"[\\\\x20\\\\t\\\\r\\\\n\\\\f]\",I=\"(?:\\\\\\\\.|[\\\\w-]|[^\\0-\\\\xa0])+\",W=\"\\\\[\"+M+\"*(\"+I+\")(?:\"+M+\"*([*^$|!~]?=)\"+M+\"*(?:'((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\"|(\"+I+\"))|)\"+M+\"*\\\\]\",$=\":(\"+I+\")(?:\\\\((('((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\")|((?:\\\\\\\\.|[^\\\\\\\\()[\\\\]]|\"+W+\")*)|.*)\\\\)|)\",F=new RegExp(M+\"+\",\"g\"),B=new RegExp(\"^\"+M+\"+|((?:^|[^\\\\\\\\])(?:\\\\\\\\.)*)\"+M+\"+$\",\"g\"),_=new RegExp(\"^\"+M+\"*,\"+M+\"*\"),z=new RegExp(\"^\"+M+\"*([>+~]|\"+M+\")\"+M+\"*\"),U=new RegExp(M+\"|>\"),X=new RegExp($),V=new RegExp(\"^\"+I+\"$\"),G={ID:new RegExp(\"^#(\"+I+\")\"),CLASS:new RegExp(\"^\\\\.(\"+I+\")\"),TAG:new RegExp(\"^(\"+I+\"|[*])\"),ATTR:new RegExp(\"^\"+W),PSEUDO:new RegExp(\"^\"+$),CHILD:new RegExp(\"^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\\\(\"+M+\"*(even|odd|(([+-]|)(\\\\d*)n|)\"+M+\"*(?:([+-]|)\"+M+\"*(\\\\d+)|))\"+M+\"*\\\\)|)\",\"i\"),bool:new RegExp(\"^(?:\"+R+\")$\",\"i\"),needsContext:new RegExp(\"^\"+M+\"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\\\(\"+M+\"*((?:-\\\\d)?\\\\d*)\"+M+\"*\\\\)|)(?=[^-]|$)\",\"i\")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\\d$/i,K=/^[^{]+\\{\\s*\\[native \\w/,Z=/^(?:#([\\w-]+)|(\\w+)|\\.([\\w-]+))$/,ee=/[+~]/,te=new RegExp(\"\\\\\\\\([\\\\da-f]{1,6}\"+M+\"?|(\"+M+\")|.)\",\"ig\"),ne=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)},re=/([\\0-\\x1f\\x7f]|^-?\\d)|^-$|[^\\0-\\x1f\\x7f-\\uFFFF\\w-]/g,ie=function(e,t){return t?\"\\0\"===e?\"\\ufffd\":e.slice(0,-1)+\"\\\\\"+e.charCodeAt(e.length-1).toString(16)+\" \":\"\\\\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&\"fieldset\"===e.nodeName.toLowerCase()},{dir:\"parentNode\",next:\"legend\"});try{H.apply(t=O.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],\"string\"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&((e?e.ownerDocument||e:m)!==C&&T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!A[t+\" \"]&&(!v||!v.test(t))&&(1!==p||\"object\"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&U.test(t)){(s=e.getAttribute(\"id\"))?s=s.replace(re,ie):e.setAttribute(\"id\",s=k),o=(l=h(t)).length;while(o--)l[o]=\"#\"+s+\" \"+xe(l[o]);c=l.join(\",\"),f=ee.test(t)&&ye(e.parentNode)||e}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){A(t,!0)}finally{s===k&&e.removeAttribute(\"id\")}}}return g(t.replace(B,\"$1\"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+\" \")>b.cacheLength&&delete e[r.shift()],e[t+\" \"]=n}}function le(e){return e[k]=!0,e}function ce(e){var t=C.createElement(\"fieldset\");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split(\"|\"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return\"input\"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return(\"input\"===t||\"button\"===t)&&e.type===n}}function ge(t){return function(e){return\"form\"in e?e.parentNode&&!1===e.disabled?\"label\"in e?\"label\"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:\"label\"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&\"undefined\"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||\"HTML\")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),m!==C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener(\"unload\",oe,!1):n.attachEvent&&n.attachEvent(\"onunload\",oe)),d.attributes=ce(function(e){return e.className=\"i\",!e.getAttribute(\"className\")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment(\"\")),!e.getElementsByTagName(\"*\").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=k,!C.getElementsByName||!C.getElementsByName(k).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute(\"id\")===t}},b.find.ID=function(e,t){if(\"undefined\"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t=\"undefined\"!=typeof e.getAttributeNode&&e.getAttributeNode(\"id\");return t&&t.value===n}},b.find.ID=function(e,t){if(\"undefined\"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return\"undefined\"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if(\"*\"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if(\"undefined\"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML=\"<a id='\"+k+\"'></a><select id='\"+k+\"-\\r\\\\' msallowcapture=''><option selected=''></option></select>\",e.querySelectorAll(\"[msallowcapture^='']\").length&&v.push(\"[*^$]=\"+M+\"*(?:''|\\\"\\\")\"),e.querySelectorAll(\"[selected]\").length||v.push(\"\\\\[\"+M+\"*(?:value|\"+R+\")\"),e.querySelectorAll(\"[id~=\"+k+\"-]\").length||v.push(\"~=\"),e.querySelectorAll(\":checked\").length||v.push(\":checked\"),e.querySelectorAll(\"a#\"+k+\"+*\").length||v.push(\".#.+[+~]\")}),ce(function(e){e.innerHTML=\"<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>\";var t=C.createElement(\"input\");t.setAttribute(\"type\",\"hidden\"),e.appendChild(t).setAttribute(\"name\",\"D\"),e.querySelectorAll(\"[name=d]\").length&&v.push(\"name\"+M+\"*[*^$|!~]?=\"),2!==e.querySelectorAll(\":enabled\").length&&v.push(\":enabled\",\":disabled\"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(\":disabled\").length&&v.push(\":enabled\",\":disabled\"),e.querySelectorAll(\"*,:x\"),v.push(\",.*:\")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,\"*\"),c.call(e,\"[s!='']:x\"),s.push(\"!=\",$)}),v=v.length&&new RegExp(v.join(\"|\")),s=s.length&&new RegExp(s.join(\"|\")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.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)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e===C||e.ownerDocument===m&&y(m,e)?-1:t===C||t.ownerDocument===m&&y(m,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===C?-1:t===C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==C&&T(e),d.matchesSelector&&E&&!A[t+\" \"]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){A(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!==C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!==C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+\"\").replace(re,ie)},se.error=function(e){throw new Error(\"Syntax error, unrecognized expression: \"+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.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 while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,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(te,ne),e[3]=(e[3]||e[4]||e[5]||\"\").replace(te,ne),\"~=\"===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]||se.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]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||\"\":n&&X.test(n)&&(t=h(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(te,ne).toLowerCase();return\"*\"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+\" \"];return t||(t=new RegExp(\"(^|\"+M+\")\"+e+\"(\"+M+\"|$)\"))&&p(e,function(e){return t.test(\"string\"==typeof e.className&&e.className||\"undefined\"!=typeof e.getAttribute&&e.getAttribute(\"class\")||\"\")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?\"!=\"===r:!r||(t+=\"\",\"=\"===r?t===i:\"!=\"===r?t!==i:\"^=\"===r?i&&0===t.indexOf(i):\"*=\"===r?i&&-1<t.indexOf(i):\"$=\"===r?i&&t.slice(-i.length)===i:\"~=\"===r?-1<(\" \"+t.replace(F,\" \")+\" \").indexOf(i):\"|=\"===r&&(t===i||t.slice(0,i.length+1)===i+\"-\"))}},CHILD:function(h,e,t,g,v){var y=\"nth\"!==h.slice(0,3),m=\"last\"!==h.slice(-4),x=\"of-type\"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?\"nextSibling\":\"previousSibling\",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l=\"only\"===h&&!u&&\"nextSibling\"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[k]||(a[k]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===S&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[S,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[k]||(a[k]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===S&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[k]||(a[k]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[S,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error(\"unsupported pseudo: \"+e);return a[k]?a(o):1<a.length?(t=[e,e,\"\",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace(B,\"$1\"));return s[k]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||\"\")||se.error(\"unsupported lang: \"+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute(\"xml:lang\")||e.getAttribute(\"lang\"))return(t=t.toLowerCase())===n||0===t.indexOf(n+\"-\")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!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!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.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:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r=\"\";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&\"parentNode\"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[S,p];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[k]||(e[k]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===S&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Ce(d,h,g,v,y,e){return v&&!v[k]&&(v=Ce(v)),y&&!y[k]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||\"*\",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[\" \"],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[k]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:\" \"===e[s-2].type?\"*\":\"\"})).replace(B,\"$1\"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+\" \"];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace(B,\" \")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=N[e+\" \"];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[k]?i.push(a):o.push(a);(a=N(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l=\"0\",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG(\"*\",i),h=S+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t===C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument===C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(S=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(S=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l=\"function\"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&\"ID\"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=k.split(\"\").sort(D).join(\"\")===k,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement(\"fieldset\"))}),ce(function(e){return e.innerHTML=\"<a href='#'></a>\",\"#\"===e.firstChild.getAttribute(\"href\")})||fe(\"type|href|height|width\",function(e,t,n){if(!n)return e.getAttribute(t,\"type\"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML=\"<input/>\",e.firstChild.setAttribute(\"value\",\"\"),\"\"===e.firstChild.getAttribute(\"value\")})||fe(\"value\",function(e,t,n){if(!n&&\"input\"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute(\"disabled\")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);k.find=h,k.expr=h.selectors,k.expr[\":\"]=k.expr.pseudos,k.uniqueSort=k.unique=h.uniqueSort,k.text=h.getText,k.isXMLDoc=h.isXML,k.contains=h.contains,k.escapeSelector=h.escape;var T=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&k(e).is(n))break;r.push(e)}return r},S=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},N=k.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var D=/^<([a-z][^\\/\\0>:\\x20\\t\\r\\n\\f]*)[\\x20\\t\\r\\n\\f]*\\/?>(?:<\\/\\1>|)$/i;function j(e,n,r){return m(n)?k.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?k.grep(e,function(e){return e===n!==r}):\"string\"!=typeof n?k.grep(e,function(e){return-1<i.call(n,e)!==r}):k.filter(n,e,r)}k.filter=function(e,t,n){var r=t[0];return n&&(e=\":not(\"+e+\")\"),1===t.length&&1===r.nodeType?k.find.matchesSelector(r,e)?[r]:[]:k.find.matches(e,k.grep(t,function(e){return 1===e.nodeType}))},k.fn.extend({find:function(e){var t,n,r=this.length,i=this;if(\"string\"!=typeof e)return this.pushStack(k(e).filter(function(){for(t=0;t<r;t++)if(k.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)k.find(e,i[t],n);return 1<r?k.uniqueSort(n):n},filter:function(e){return this.pushStack(j(this,e||[],!1))},not:function(e){return this.pushStack(j(this,e||[],!0))},is:function(e){return!!j(this,\"string\"==typeof e&&N.test(e)?k(e):e||[],!1).length}});var q,L=/^(?:\\s*(<[\\w\\W]+>)[^>]*|#([\\w-]+))$/;(k.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||q,\"string\"==typeof e){if(!(r=\"<\"===e[0]&&\">\"===e[e.length-1]&&3<=e.length?[null,e,null]:L.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 k?t[0]:t,k.merge(this,k.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),D.test(r[1])&&k.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(k):k.makeArray(e,this)}).prototype=k.fn,q=k(E);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}k.fn.extend({has:function(e){var t=k(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(k.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a=\"string\"!=typeof e&&k(e);if(!N.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&k.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?k.uniqueSort(o):o)},index:function(e){return e?\"string\"==typeof e?i.call(k(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(k.uniqueSort(k.merge(this.get(),k(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),k.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return T(e,\"parentNode\")},parentsUntil:function(e,t,n){return T(e,\"parentNode\",n)},next:function(e){return P(e,\"nextSibling\")},prev:function(e){return P(e,\"previousSibling\")},nextAll:function(e){return T(e,\"nextSibling\")},prevAll:function(e){return T(e,\"previousSibling\")},nextUntil:function(e,t,n){return T(e,\"nextSibling\",n)},prevUntil:function(e,t,n){return T(e,\"previousSibling\",n)},siblings:function(e){return S((e.parentNode||{}).firstChild,e)},children:function(e){return S(e.firstChild)},contents:function(e){return\"undefined\"!=typeof e.contentDocument?e.contentDocument:(A(e,\"template\")&&(e=e.content||e),k.merge([],e.childNodes))}},function(r,i){k.fn[r]=function(e,t){var n=k.map(this,i,e);return\"Until\"!==r.slice(-5)&&(t=e),t&&\"string\"==typeof t&&(n=k.filter(t,n)),1<this.length&&(O[r]||k.uniqueSort(n),H.test(r)&&n.reverse()),this.pushStack(n)}});var R=/[^\\x20\\t\\r\\n\\f]+/g;function M(e){return e}function I(e){throw e}function W(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}k.Callbacks=function(r){var e,n;r=\"string\"==typeof r?(e=r,n={},k.each(e.match(R)||[],function(e,t){n[t]=!0}),n):k.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:\"\")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){k.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&\"string\"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return k.each(arguments,function(e,t){var n;while(-1<(n=k.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<k.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t=\"\",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=\"\"),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},k.extend({Deferred:function(e){var o=[[\"notify\",\"progress\",k.Callbacks(\"memory\"),k.Callbacks(\"memory\"),2],[\"resolve\",\"done\",k.Callbacks(\"once memory\"),k.Callbacks(\"once memory\"),0,\"resolved\"],[\"reject\",\"fail\",k.Callbacks(\"once memory\"),k.Callbacks(\"once memory\"),1,\"rejected\"]],i=\"pending\",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},\"catch\":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return k.Deferred(function(r){k.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+\"With\"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError(\"Thenable self-resolution\");t=e&&(\"object\"==typeof e||\"function\"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,M,s),l(u,o,I,s)):(u++,t.call(e,l(u,o,M,s),l(u,o,I,s),l(u,o,M,o.notifyWith))):(a!==M&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){k.Deferred.exceptionHook&&k.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==I&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(k.Deferred.getStackHook&&(t.stackTrace=k.Deferred.getStackHook()),C.setTimeout(t))}}return k.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:M,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:M)),o[2][3].add(l(0,e,m(n)?n:I))}).promise()},promise:function(e){return null!=e?k.extend(e,a):a}},s={};return k.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+\"With\"](this===s?void 0:this,arguments),this},s[t[0]+\"With\"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=k.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(W(e,o.done(a(t)).resolve,o.reject,!n),\"pending\"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)W(i[t],a(t),o.reject);return o.promise()}});var $=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;k.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&$.test(e.name)&&C.console.warn(\"jQuery.Deferred exception: \"+e.message,e.stack,t)},k.readyException=function(e){C.setTimeout(function(){throw e})};var F=k.Deferred();function B(){E.removeEventListener(\"DOMContentLoaded\",B),C.removeEventListener(\"load\",B),k.ready()}k.fn.ready=function(e){return F.then(e)[\"catch\"](function(e){k.readyException(e)}),this},k.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--k.readyWait:k.isReady)||(k.isReady=!0)!==e&&0<--k.readyWait||F.resolveWith(E,[k])}}),k.ready.then=F.then,\"complete\"===E.readyState||\"loading\"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(k.ready):(E.addEventListener(\"DOMContentLoaded\",B),C.addEventListener(\"load\",B));var _=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if(\"object\"===w(n))for(s in i=!0,n)_(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(k(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},z=/^-ms-/,U=/-([a-z])/g;function X(e,t){return t.toUpperCase()}function V(e){return e.replace(z,\"ms-\").replace(U,X)}var G=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function Y(){this.expando=k.expando+Y.uid++}Y.uid=1,Y.prototype={cache:function(e){var t=e[this.expando];return t||(t={},G(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[V(t)]=n;else for(r in t)i[V(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][V(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){n=(t=Array.isArray(t)?t.map(V):(t=V(t))in r?[t]:t.match(R)||[]).length;while(n--)delete r[t[n]]}(void 0===t||k.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&&!k.isEmptyObject(t)}};var Q=new Y,J=new Y,K=/^(?:\\{[\\w\\W]*\\}|\\[[\\w\\W]*\\])$/,Z=/[A-Z]/g;function ee(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r=\"data-\"+t.replace(Z,\"-$&\").toLowerCase(),\"string\"==typeof(n=e.getAttribute(r))){try{n=\"true\"===(i=n)||\"false\"!==i&&(\"null\"===i?null:i===+i+\"\"?+i:K.test(i)?JSON.parse(i):i)}catch(e){}J.set(e,t,n)}else n=void 0;return n}k.extend({hasData:function(e){return J.hasData(e)||Q.hasData(e)},data:function(e,t,n){return J.access(e,t,n)},removeData:function(e,t){J.remove(e,t)},_data:function(e,t,n){return Q.access(e,t,n)},_removeData:function(e,t){Q.remove(e,t)}}),k.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=J.get(o),1===o.nodeType&&!Q.get(o,\"hasDataAttrs\"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf(\"data-\")&&(r=V(r.slice(5)),ee(o,r,i[r]));Q.set(o,\"hasDataAttrs\",!0)}return i}return\"object\"==typeof n?this.each(function(){J.set(this,n)}):_(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=J.get(o,n))?t:void 0!==(t=ee(o,n))?t:void 0;this.each(function(){J.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){J.remove(this,e)})}}),k.extend({queue:function(e,t,n){var r;if(e)return t=(t||\"fx\")+\"queue\",r=Q.get(e,t),n&&(!r||Array.isArray(n)?r=Q.access(e,t,k.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||\"fx\";var n=k.queue(e,t),r=n.length,i=n.shift(),o=k._queueHooks(e,t);\"inprogress\"===i&&(i=n.shift(),r--),i&&(\"fx\"===t&&n.unshift(\"inprogress\"),delete o.stop,i.call(e,function(){k.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+\"queueHooks\";return Q.get(e,n)||Q.access(e,n,{empty:k.Callbacks(\"once memory\").add(function(){Q.remove(e,[t+\"queue\",n])})})}}),k.fn.extend({queue:function(t,n){var e=2;return\"string\"!=typeof t&&(n=t,t=\"fx\",e--),arguments.length<e?k.queue(this[0],t):void 0===n?this:this.each(function(){var e=k.queue(this,t,n);k._queueHooks(this,t),\"fx\"===t&&\"inprogress\"!==e[0]&&k.dequeue(this,t)})},dequeue:function(e){return this.each(function(){k.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||\"fx\",[])},promise:function(e,t){var n,r=1,i=k.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};\"string\"!=typeof e&&(t=e,e=void 0),e=e||\"fx\";while(a--)(n=Q.get(o[a],e+\"queueHooks\"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var te=/[+-]?(?:\\d*\\.|)\\d+(?:[eE][+-]?\\d+|)/.source,ne=new RegExp(\"^(?:([+-])=|)(\"+te+\")([a-z%]*)$\",\"i\"),re=[\"Top\",\"Right\",\"Bottom\",\"Left\"],ie=E.documentElement,oe=function(e){return k.contains(e.ownerDocument,e)},ae={composed:!0};ie.getRootNode&&(oe=function(e){return k.contains(e.ownerDocument,e)||e.getRootNode(ae)===e.ownerDocument});var se=function(e,t){return\"none\"===(e=t||e).style.display||\"\"===e.style.display&&oe(e)&&\"none\"===k.css(e,\"display\")},ue=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];for(o in i=n.apply(e,r||[]),t)e.style[o]=a[o];return i};function le(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return k.css(e,t,\"\")},u=s(),l=n&&n[3]||(k.cssNumber[t]?\"\":\"px\"),c=e.nodeType&&(k.cssNumber[t]||\"px\"!==l&&+u)&&ne.exec(k.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)k.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,k.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var ce={};function fe(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?(\"none\"===n&&(l[c]=Q.get(r,\"display\")||null,l[c]||(r.style.display=\"\")),\"\"===r.style.display&&se(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ce[s])||(o=a.body.appendChild(a.createElement(s)),u=k.css(o,\"display\"),o.parentNode.removeChild(o),\"none\"===u&&(u=\"block\"),ce[s]=u)))):\"none\"!==n&&(l[c]=\"none\",Q.set(r,\"display\",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}k.fn.extend({show:function(){return fe(this,!0)},hide:function(){return fe(this)},toggle:function(e){return\"boolean\"==typeof e?e?this.show():this.hide():this.each(function(){se(this)?k(this).show():k(this).hide()})}});var pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)/i,he=/^$|^module$|\\/(?:java|ecma)script/i,ge={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,\"\",\"\"]};function ve(e,t){var n;return n=\"undefined\"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||\"*\"):\"undefined\"!=typeof e.querySelectorAll?e.querySelectorAll(t||\"*\"):[],void 0===t||t&&A(e,t)?k.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Q.set(e[n],\"globalEval\",!t||Q.get(t[n],\"globalEval\"))}ge.optgroup=ge.option,ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td;var me,xe,be=/<|&#?\\w+;/;function we(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if(\"object\"===w(o))k.merge(p,o.nodeType?[o]:o);else if(be.test(o)){a=a||f.appendChild(t.createElement(\"div\")),s=(de.exec(o)||[\"\",\"\"])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+k.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;k.merge(p,a.childNodes),(a=f.firstChild).textContent=\"\"}else p.push(t.createTextNode(o));f.textContent=\"\",d=0;while(o=p[d++])if(r&&-1<k.inArray(o,r))i&&i.push(o);else if(l=oe(o),a=ve(f.appendChild(o),\"script\"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||\"\")&&n.push(o)}return f}me=E.createDocumentFragment().appendChild(E.createElement(\"div\")),(xe=E.createElement(\"input\")).setAttribute(\"type\",\"radio\"),xe.setAttribute(\"checked\",\"checked\"),xe.setAttribute(\"name\",\"t\"),me.appendChild(xe),y.checkClone=me.cloneNode(!0).cloneNode(!0).lastChild.checked,me.innerHTML=\"<textarea>x</textarea>\",y.noCloneChecked=!!me.cloneNode(!0).lastChild.defaultValue;var Te=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ee=/^([^.]*)(?:\\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ne(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==(\"focus\"===t)}function Ae(e,t,n,r,i,o){var a,s;if(\"object\"==typeof t){for(s in\"string\"!=typeof n&&(r=r||n,n=void 0),t)Ae(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=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return k().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=k.guid++)),e.each(function(){k.event.add(this,t,i,r,n)})}function De(e,i,o){o?(Q.set(e,i,!1),k.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Q.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(k.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Q.set(this,i,r),t=o(this,i),this[i](),r!==(n=Q.get(this,i))||t?Q.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Q.set(this,i,{value:k.event.trigger(k.extend(r[0],k.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Q.get(e,i)&&k.event.add(e,i,ke)}k.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&k.find.matchesSelector(ie,i),n.guid||(n.guid=k.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return\"undefined\"!=typeof k&&k.event.triggered!==e.type?k.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||\"\").match(R)||[\"\"]).length;while(l--)d=g=(s=Ee.exec(e[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d&&(f=k.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=k.event.special[d]||{},c=k.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&k.expr.match.needsContext.test(i),namespace:h.join(\".\")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),k.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.hasData(e)&&Q.get(e);if(v&&(u=v.events)){l=(t=(t||\"\").match(R)||[\"\"]).length;while(l--)if(d=g=(s=Ee.exec(t[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d){f=k.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp(\"(^|\\\\.)\"+h.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&(\"**\"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||k.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)k.event.remove(e,d+t[l],n,r,!0);k.isEmptyObject(u)&&Q.remove(e,\"handle events\")}},dispatch:function(e){var t,n,r,i,o,a,s=k.event.fix(e),u=new Array(arguments.length),l=(Q.get(this,\"events\")||{})[s.type]||[],c=k.event.special[s.type]||{};for(u[0]=s,t=1;t<arguments.length;t++)u[t]=arguments[t];if(s.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,s)){a=k.event.handlers.call(this,s,l),t=0;while((i=a[t++])&&!s.isPropagationStopped()){s.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!s.isImmediatePropagationStopped())s.rnamespace&&!1!==o.namespace&&!s.rnamespace.test(o.namespace)||(s.handleObj=o,s.data=o.data,void 0!==(r=((k.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,u))&&!1===(s.result=r)&&(s.preventDefault(),s.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,s),s.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!(\"click\"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&(\"click\"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+\" \"]&&(a[i]=r.needsContext?-1<k(i,this).index(l):k.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(k.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[k.expando]?e:new k.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,\"input\")&&De(t,\"click\",ke),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,\"input\")&&De(t,\"click\"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,\"input\")&&Q.get(t,\"click\")||A(t,\"a\")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},k.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},k.Event=function(e,t){if(!(this instanceof k.Event))return new k.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?ke:Se,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&&k.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[k.expando]=!0},k.Event.prototype={constructor:k.Event,isDefaultPrevented:Se,isPropagationStopped:Se,isImmediatePropagationStopped:Se,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=ke,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=ke,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=ke,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},k.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,code:!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&&Te.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Ce.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},k.event.addProp),k.each({focus:\"focusin\",blur:\"focusout\"},function(e,t){k.event.special[e]={setup:function(){return De(this,e,Ne),!1},trigger:function(){return De(this,e),!0},delegateType:t}}),k.each({mouseenter:\"mouseover\",mouseleave:\"mouseout\",pointerenter:\"pointerover\",pointerleave:\"pointerout\"},function(e,i){k.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||k.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),k.fn.extend({on:function(e,t,n,r){return Ae(this,e,t,n,r)},one:function(e,t,n,r){return Ae(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,k(e.delegateTarget).off(r.namespace?r.origType+\".\"+r.namespace:r.origType,r.selector,r.handler),this;if(\"object\"==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=Se),this.each(function(){k.event.remove(this,e,n,t)})}});var je=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)[^>]*)\\/>/gi,qe=/<script|<style|<link/i,Le=/checked\\s*(?:[^=]|=\\s*.checked.)/i,He=/^\\s*<!(?:\\[CDATA\\[|--)|(?:\\]\\]|--)>\\s*$/g;function Oe(e,t){return A(e,\"table\")&&A(11!==t.nodeType?t:t.firstChild,\"tr\")&&k(e).children(\"tbody\")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute(\"type\"))+\"/\"+e.type,e}function Re(e){return\"true/\"===(e.type||\"\").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute(\"type\"),e}function Me(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(Q.hasData(e)&&(o=Q.access(e),a=Q.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n<r;n++)k.event.add(t,i,l[i][n]);J.hasData(e)&&(s=J.access(e),u=k.extend({},s),J.set(t,u))}}function Ie(n,r,i,o){r=g.apply([],r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&\"string\"==typeof d&&!y.checkClone&&Le.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Ie(t,r,i,o)});if(f&&(t=(e=we(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=k.map(ve(e,\"script\"),Pe)).length;c<f;c++)u=e,c!==p&&(u=k.clone(u,!0,!0),s&&k.merge(a,ve(u,\"script\"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,k.map(a,Re),c=0;c<s;c++)u=a[c],he.test(u.type||\"\")&&!Q.access(u,\"globalEval\")&&k.contains(l,u)&&(u.src&&\"module\"!==(u.type||\"\").toLowerCase()?k._evalUrl&&!u.noModule&&k._evalUrl(u.src,{nonce:u.nonce||u.getAttribute(\"nonce\")}):b(u.textContent.replace(He,\"\"),u,l))}return n}function We(e,t,n){for(var r,i=t?k.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||k.cleanData(ve(r)),r.parentNode&&(n&&oe(r)&&ye(ve(r,\"script\")),r.parentNode.removeChild(r));return e}k.extend({htmlPrefilter:function(e){return e.replace(je,\"<$1></$2>\")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||k.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,\"input\"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:\"input\"!==l&&\"textarea\"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Me(o[r],a[r]);else Me(e,c);return 0<(a=ve(c,\"script\")).length&&ye(a,!f&&ve(e,\"script\")),c},cleanData:function(e){for(var t,n,r,i=k.event.special,o=0;void 0!==(n=e[o]);o++)if(G(n)){if(t=n[Q.expando]){if(t.events)for(r in t.events)i[r]?k.event.remove(n,r):k.removeEvent(n,r,t.handle);n[Q.expando]=void 0}n[J.expando]&&(n[J.expando]=void 0)}}}),k.fn.extend({detach:function(e){return We(this,e,!0)},remove:function(e){return We(this,e)},text:function(e){return _(this,function(e){return void 0===e?k.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 Ie(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Oe(this,e).appendChild(e)})},prepend:function(){return Ie(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Oe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Ie(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Ie(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&&(k.cleanData(ve(e,!1)),e.textContent=\"\");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return k.clone(this,e,t)})},html:function(e){return _(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&&!qe.test(e)&&!ge[(de.exec(e)||[\"\",\"\"])[1].toLowerCase()]){e=k.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(k.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Ie(this,arguments,function(e){var t=this.parentNode;k.inArray(this,n)<0&&(k.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),k.each({appendTo:\"append\",prependTo:\"prepend\",insertBefore:\"before\",insertAfter:\"after\",replaceAll:\"replaceWith\"},function(e,a){k.fn[e]=function(e){for(var t,n=[],r=k(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),k(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var $e=new RegExp(\"^(\"+te+\")(?!px)[a-z%]+$\",\"i\"),Fe=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},Be=new RegExp(re.join(\"|\"),\"i\");function _e(e,t,n){var r,i,o,a,s=e.style;return(n=n||Fe(e))&&(\"\"!==(a=n.getPropertyValue(t)||n[t])||oe(e)||(a=k.style(e,t)),!y.pixelBoxStyles()&&$e.test(a)&&Be.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 ze(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(u){s.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%\",ie.appendChild(s).appendChild(u);var e=C.getComputedStyle(u);n=\"1%\"!==e.top,a=12===t(e.marginLeft),u.style.right=\"60%\",o=36===t(e.right),r=36===t(e.width),u.style.position=\"absolute\",i=12===t(u.offsetWidth/3),ie.removeChild(s),u=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s=E.createElement(\"div\"),u=E.createElement(\"div\");u.style&&(u.style.backgroundClip=\"content-box\",u.cloneNode(!0).style.backgroundClip=\"\",y.clearCloneStyle=\"content-box\"===u.style.backgroundClip,k.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),a},scrollboxSize:function(){return e(),i}}))}();var Ue=[\"Webkit\",\"Moz\",\"ms\"],Xe=E.createElement(\"div\").style,Ve={};function Ge(e){var t=k.cssProps[e]||Ve[e];return t||(e in Xe?e:Ve[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=Ue.length;while(n--)if((e=Ue[n]+t)in Xe)return e}(e)||e)}var Ye=/^(none|table(?!-c[ea]).+)/,Qe=/^--/,Je={position:\"absolute\",visibility:\"hidden\",display:\"block\"},Ke={letterSpacing:\"0\",fontWeight:\"400\"};function Ze(e,t,n){var r=ne.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||\"px\"):t}function et(e,t,n,r,i,o){var a=\"width\"===t?1:0,s=0,u=0;if(n===(r?\"border\":\"content\"))return 0;for(;a<4;a+=2)\"margin\"===n&&(u+=k.css(e,n+re[a],!0,i)),r?(\"content\"===n&&(u-=k.css(e,\"padding\"+re[a],!0,i)),\"margin\"!==n&&(u-=k.css(e,\"border\"+re[a]+\"Width\",!0,i))):(u+=k.css(e,\"padding\"+re[a],!0,i),\"padding\"!==n?u+=k.css(e,\"border\"+re[a]+\"Width\",!0,i):s+=k.css(e,\"border\"+re[a]+\"Width\",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e[\"offset\"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function tt(e,t,n){var r=Fe(e),i=(!y.boxSizingReliable()||n)&&\"border-box\"===k.css(e,\"boxSizing\",!1,r),o=i,a=_e(e,t,r),s=\"offset\"+t[0].toUpperCase()+t.slice(1);if($e.test(a)){if(!n)return a;a=\"auto\"}return(!y.boxSizingReliable()&&i||\"auto\"===a||!parseFloat(a)&&\"inline\"===k.css(e,\"display\",!1,r))&&e.getClientRects().length&&(i=\"border-box\"===k.css(e,\"boxSizing\",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+et(e,t,n||(i?\"border\":\"content\"),o,r,a)+\"px\"}function nt(e,t,n,r,i){return new nt.prototype.init(e,t,n,r,i)}k.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=_e(e,\"opacity\");return\"\"===n?\"1\":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!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=V(t),u=Qe.test(t),l=e.style;if(u||(t=Ge(s)),a=k.cssHooks[t]||k.cssHooks[s],void 0===n)return a&&\"get\"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];\"string\"===(o=typeof n)&&(i=ne.exec(n))&&i[1]&&(n=le(e,t,i),o=\"number\"),null!=n&&n==n&&(\"number\"!==o||u||(n+=i&&i[3]||(k.cssNumber[s]?\"\":\"px\")),y.clearCloneStyle||\"\"!==n||0!==t.indexOf(\"background\")||(l[t]=\"inherit\"),a&&\"set\"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=V(t);return Qe.test(t)||(t=Ge(s)),(a=k.cssHooks[t]||k.cssHooks[s])&&\"get\"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=_e(e,t,r)),\"normal\"===i&&t in Ke&&(i=Ke[t]),\"\"===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),k.each([\"height\",\"width\"],function(e,u){k.cssHooks[u]={get:function(e,t,n){if(t)return!Ye.test(k.css(e,\"display\"))||e.getClientRects().length&&e.getBoundingClientRect().width?tt(e,u,n):ue(e,Je,function(){return tt(e,u,n)})},set:function(e,t,n){var r,i=Fe(e),o=!y.scrollboxSize()&&\"absolute\"===i.position,a=(o||n)&&\"border-box\"===k.css(e,\"boxSizing\",!1,i),s=n?et(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e[\"offset\"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-et(e,u,\"border\",!1,i)-.5)),s&&(r=ne.exec(t))&&\"px\"!==(r[3]||\"px\")&&(e.style[u]=t,t=k.css(e,u)),Ze(0,t,s)}}}),k.cssHooks.marginLeft=ze(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(_e(e,\"marginLeft\"))||e.getBoundingClientRect().left-ue(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+\"px\"}),k.each({margin:\"\",padding:\"\",border:\"Width\"},function(i,o){k.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r=\"string\"==typeof e?e.split(\" \"):[e];t<4;t++)n[i+re[t]+o]=r[t]||r[t-2]||r[0];return n}},\"margin\"!==i&&(k.cssHooks[i+o].set=Ze)}),k.fn.extend({css:function(e,t){return _(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Fe(e),i=t.length;a<i;a++)o[t[a]]=k.css(e,t[a],!1,r);return o}return void 0!==n?k.style(e,t,n):k.css(e,t)},e,t,1<arguments.length)}}),((k.Tween=nt).prototype={constructor:nt,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||k.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(k.cssNumber[n]?\"\":\"px\")},cur:function(){var e=nt.propHooks[this.prop];return e&&e.get?e.get(this):nt.propHooks._default.get(this)},run:function(e){var t,n=nt.propHooks[this.prop];return this.options.duration?this.pos=t=k.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):nt.propHooks._default.set(this),this}}).init.prototype=nt.prototype,(nt.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=k.css(e.elem,e.prop,\"\"))&&\"auto\"!==t?t:0},set:function(e){k.fx.step[e.prop]?k.fx.step[e.prop](e):1!==e.elem.nodeType||!k.cssHooks[e.prop]&&null==e.elem.style[Ge(e.prop)]?e.elem[e.prop]=e.now:k.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=nt.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},k.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:\"swing\"},k.fx=nt.prototype.init,k.fx.step={};var rt,it,ot,at,st=/^(?:toggle|show|hide)$/,ut=/queueHooks$/;function lt(){it&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(lt):C.setTimeout(lt,k.fx.interval),k.fx.tick())}function ct(){return C.setTimeout(function(){rt=void 0}),rt=Date.now()}function ft(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i[\"margin\"+(n=re[r])]=i[\"padding\"+n]=e;return t&&(i.opacity=i.width=e),i}function pt(e,t,n){for(var r,i=(dt.tweeners[t]||[]).concat(dt.tweeners[\"*\"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function dt(o,e,t){var n,a,r=0,i=dt.prefilters.length,s=k.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=rt||ct(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:k.extend({},e),opts:k.extend(!0,{specialEasing:{},easing:k.easing._default},t),originalProperties:e,originalOptions:t,startTime:rt||ct(),duration:t.duration,tweens:[],createTween:function(e,t){var n=k.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=V(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=k.cssHooks[r])&&\"expand\"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=dt.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(k._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return k.map(c,pt,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),k.fx.timer(k.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}k.Animation=k.extend(dt,{tweeners:{\"*\":[function(e,t){var n=this.createTween(e,t);return le(n.elem,e,ne.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=[\"*\"]):e=e.match(R);for(var n,r=0,i=e.length;r<i;r++)n=e[r],dt.tweeners[n]=dt.tweeners[n]||[],dt.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c,f=\"width\"in t||\"height\"in t,p=this,d={},h=e.style,g=e.nodeType&&se(e),v=Q.get(e,\"fxshow\");for(r in n.queue||(null==(a=k._queueHooks(e,\"fx\")).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--,k.queue(e,\"fx\").length||a.empty.fire()})})),t)if(i=t[r],st.test(i)){if(delete t[r],o=o||\"toggle\"===i,i===(g?\"hide\":\"show\")){if(\"show\"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||k.style(e,r)}if((u=!k.isEmptyObject(t))||!k.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Q.get(e,\"display\")),\"none\"===(c=k.css(e,\"display\"))&&(l?c=l:(fe([e],!0),l=e.style.display||l,c=k.css(e,\"display\"),fe([e]))),(\"inline\"===c||\"inline-block\"===c&&null!=l)&&\"none\"===k.css(e,\"float\")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l=\"none\"===c?\"\":c)),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,d)u||(v?\"hidden\"in v&&(g=v.hidden):v=Q.access(e,\"fxshow\",{display:l}),o&&(v.hidden=!g),g&&fe([e],!0),p.done(function(){for(r in g||fe([e]),Q.remove(e,\"fxshow\"),d)k.style(e,r,d[r])})),u=pt(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?dt.prefilters.unshift(e):dt.prefilters.push(e)}}),k.speed=function(e,t,n){var r=e&&\"object\"==typeof e?k.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return k.fx.off?r.duration=0:\"number\"!=typeof r.duration&&(r.duration in k.fx.speeds?r.duration=k.fx.speeds[r.duration]:r.duration=k.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue=\"fx\"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&k.dequeue(this,r.queue)},r},k.fn.extend({fadeTo:function(e,t,n,r){return this.filter(se).css(\"opacity\",0).show().end().animate({opacity:t},e,n,r)},animate:function(t,e,n,r){var i=k.isEmptyObject(t),o=k.speed(e,n,r),a=function(){var e=dt(this,k.extend({},t),o);(i||Q.get(this,\"finish\"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return\"string\"!=typeof i&&(o=e,e=i,i=void 0),e&&!1!==i&&this.queue(i||\"fx\",[]),this.each(function(){var e=!0,t=null!=i&&i+\"queueHooks\",n=k.timers,r=Q.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&ut.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||k.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||\"fx\"),this.each(function(){var e,t=Q.get(this),n=t[a+\"queue\"],r=t[a+\"queueHooks\"],i=k.timers,o=n?n.length:0;for(t.finish=!0,k.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),k.each([\"toggle\",\"show\",\"hide\"],function(e,r){var i=k.fn[r];k.fn[r]=function(e,t,n){return null==e||\"boolean\"==typeof e?i.apply(this,arguments):this.animate(ft(r,!0),e,t,n)}}),k.each({slideDown:ft(\"show\"),slideUp:ft(\"hide\"),slideToggle:ft(\"toggle\"),fadeIn:{opacity:\"show\"},fadeOut:{opacity:\"hide\"},fadeToggle:{opacity:\"toggle\"}},function(e,r){k.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),k.timers=[],k.fx.tick=function(){var e,t=0,n=k.timers;for(rt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||k.fx.stop(),rt=void 0},k.fx.timer=function(e){k.timers.push(e),k.fx.start()},k.fx.interval=13,k.fx.start=function(){it||(it=!0,lt())},k.fx.stop=function(){it=null},k.fx.speeds={slow:600,fast:200,_default:400},k.fn.delay=function(r,e){return r=k.fx&&k.fx.speeds[r]||r,e=e||\"fx\",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},ot=E.createElement(\"input\"),at=E.createElement(\"select\").appendChild(E.createElement(\"option\")),ot.type=\"checkbox\",y.checkOn=\"\"!==ot.value,y.optSelected=at.selected,(ot=E.createElement(\"input\")).value=\"t\",ot.type=\"radio\",y.radioValue=\"t\"===ot.value;var ht,gt=k.expr.attrHandle;k.fn.extend({attr:function(e,t){return _(this,k.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){k.removeAttr(this,e)})}}),k.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return\"undefined\"==typeof e.getAttribute?k.prop(e,t,n):(1===o&&k.isXMLDoc(e)||(i=k.attrHooks[t.toLowerCase()]||(k.expr.match.bool.test(t)?ht:void 0)),void 0!==n?null===n?void k.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:null==(r=k.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&\"radio\"===t&&A(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(R);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),ht={set:function(e,t,n){return!1===t?k.removeAttr(e,n):e.setAttribute(n,n),n}},k.each(k.expr.match.bool.source.match(/\\w+/g),function(e,t){var a=gt[t]||k.find.attr;gt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=gt[o],gt[o]=r,r=null!=a(e,t,n)?o:null,gt[o]=i),r}});var vt=/^(?:input|select|textarea|button)$/i,yt=/^(?:a|area)$/i;function mt(e){return(e.match(R)||[]).join(\" \")}function xt(e){return e.getAttribute&&e.getAttribute(\"class\")||\"\"}function bt(e){return Array.isArray(e)?e:\"string\"==typeof e&&e.match(R)||[]}k.fn.extend({prop:function(e,t){return _(this,k.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[k.propFix[e]||e]})}}),k.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&k.isXMLDoc(e)||(t=k.propFix[t]||t,i=k.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=k.find.attr(e,\"tabindex\");return t?parseInt(t,10):vt.test(e.nodeName)||yt.test(e.nodeName)&&e.href?0:-1}}},propFix:{\"for\":\"htmlFor\",\"class\":\"className\"}}),y.optSelected||(k.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)}}),k.each([\"tabIndex\",\"readOnly\",\"maxLength\",\"cellSpacing\",\"cellPadding\",\"rowSpan\",\"colSpan\",\"useMap\",\"frameBorder\",\"contentEditable\"],function(){k.propFix[this.toLowerCase()]=this}),k.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){k(this).addClass(t.call(this,e,xt(this)))});if((e=bt(t)).length)while(n=this[u++])if(i=xt(n),r=1===n.nodeType&&\" \"+mt(i)+\" \"){a=0;while(o=e[a++])r.indexOf(\" \"+o+\" \")<0&&(r+=o+\" \");i!==(s=mt(r))&&n.setAttribute(\"class\",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){k(this).removeClass(t.call(this,e,xt(this)))});if(!arguments.length)return this.attr(\"class\",\"\");if((e=bt(t)).length)while(n=this[u++])if(i=xt(n),r=1===n.nodeType&&\" \"+mt(i)+\" \"){a=0;while(o=e[a++])while(-1<r.indexOf(\" \"+o+\" \"))r=r.replace(\" \"+o+\" \",\" \");i!==(s=mt(r))&&n.setAttribute(\"class\",s)}return this},toggleClass:function(i,t){var o=typeof i,a=\"string\"===o||Array.isArray(i);return\"boolean\"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){k(this).toggleClass(i.call(this,e,xt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=k(this),r=bt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&\"boolean\"!==o||((e=xt(this))&&Q.set(this,\"__className__\",e),this.setAttribute&&this.setAttribute(\"class\",e||!1===i?\"\":Q.get(this,\"__className__\")||\"\"))})},hasClass:function(e){var t,n,r=0;t=\" \"+e+\" \";while(n=this[r++])if(1===n.nodeType&&-1<(\" \"+mt(xt(n))+\" \").indexOf(t))return!0;return!1}});var wt=/\\r/g;k.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,k(this).val()):n)?t=\"\":\"number\"==typeof t?t+=\"\":Array.isArray(t)&&(t=k.map(t,function(e){return null==e?\"\":e+\"\"})),(r=k.valHooks[this.type]||k.valHooks[this.nodeName.toLowerCase()])&&\"set\"in r&&void 0!==r.set(this,t,\"value\")||(this.value=t))})):t?(r=k.valHooks[t.type]||k.valHooks[t.nodeName.toLowerCase()])&&\"get\"in r&&void 0!==(e=r.get(t,\"value\"))?e:\"string\"==typeof(e=t.value)?e.replace(wt,\"\"):null==e?\"\":e:void 0}}),k.extend({valHooks:{option:{get:function(e){var t=k.find.attr(e,\"value\");return null!=t?t:mt(k.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=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!A(n.parentNode,\"optgroup\"))){if(t=k(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=k.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<k.inArray(k.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),k.each([\"radio\",\"checkbox\"],function(){k.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<k.inArray(k(e).val(),t)}},y.checkOn||(k.valHooks[this].get=function(e){return null===e.getAttribute(\"value\")?\"on\":e.value})}),y.focusin=\"onfocusin\"in C;var Tt=/^(?:focusinfocus|focusoutblur)$/,Ct=function(e){e.stopPropagation()};k.extend(k.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,\"type\")?e.type:e,h=v.call(e,\"namespace\")?e.namespace.split(\".\"):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!Tt.test(d+k.event.triggered)&&(-1<d.indexOf(\".\")&&(d=(h=d.split(\".\")).shift(),h.sort()),u=d.indexOf(\":\")<0&&\"on\"+d,(e=e[k.expando]?e:new k.Event(d,\"object\"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join(\".\"),e.rnamespace=e.namespace?new RegExp(\"(^|\\\\.)\"+h.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:k.makeArray(t,[e]),c=k.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,Tt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Q.get(o,\"events\")||{})[e.type]&&Q.get(o,\"handle\"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&G(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!G(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),k.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,Ct),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,Ct),k.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=k.extend(new k.Event,n,{type:e,isSimulated:!0});k.event.trigger(r,null,t)}}),k.fn.extend({trigger:function(e,t){return this.each(function(){k.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return k.event.trigger(e,t,n,!0)}}),y.focusin||k.each({focus:\"focusin\",blur:\"focusout\"},function(n,r){var i=function(e){k.event.simulate(r,e.target,k.event.fix(e))};k.event.special[r]={setup:function(){var e=this.ownerDocument||this,t=Q.access(e,r);t||e.addEventListener(n,i,!0),Q.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this,t=Q.access(e,r)-1;t?Q.access(e,r,t):(e.removeEventListener(n,i,!0),Q.remove(e,r))}}});var Et=C.location,kt=Date.now(),St=/\\?/;k.parseXML=function(e){var t;if(!e||\"string\"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,\"text/xml\")}catch(e){t=void 0}return t&&!t.getElementsByTagName(\"parsererror\").length||k.error(\"Invalid XML: \"+e),t};var Nt=/\\[\\]$/,At=/\\r?\\n/g,Dt=/^(?:submit|button|image|reset|file)$/i,jt=/^(?:input|select|textarea|keygen)/i;function qt(n,e,r,i){var t;if(Array.isArray(e))k.each(e,function(e,t){r||Nt.test(n)?i(n,t):qt(n+\"[\"+(\"object\"==typeof t&&null!=t?e:\"\")+\"]\",t,r,i)});else if(r||\"object\"!==w(e))i(n,e);else for(t in e)qt(n+\"[\"+t+\"]\",e[t],r,i)}k.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+\"=\"+encodeURIComponent(null==n?\"\":n)};if(null==e)return\"\";if(Array.isArray(e)||e.jquery&&!k.isPlainObject(e))k.each(e,function(){i(this.name,this.value)});else for(n in e)qt(n,e[n],t,i);return r.join(\"&\")},k.fn.extend({serialize:function(){return k.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=k.prop(this,\"elements\");return e?k.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!k(this).is(\":disabled\")&&jt.test(this.nodeName)&&!Dt.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=k(this).val();return null==n?null:Array.isArray(n)?k.map(n,function(e){return{name:t.name,value:e.replace(At,\"\\r\\n\")}}):{name:t.name,value:n.replace(At,\"\\r\\n\")}}).get()}});var Lt=/%20/g,Ht=/#.*$/,Ot=/([?&])_=[^&]*/,Pt=/^(.*?):[ \\t]*([^\\r\\n]*)$/gm,Rt=/^(?:GET|HEAD)$/,Mt=/^\\/\\//,It={},Wt={},$t=\"*/\".concat(\"*\"),Ft=E.createElement(\"a\");function Bt(o){return function(e,t){\"string\"!=typeof e&&(t=e,e=\"*\");var n,r=0,i=e.toLowerCase().match(R)||[];if(m(t))while(n=i[r++])\"+\"===n[0]?(n=n.slice(1)||\"*\",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function _t(t,i,o,a){var s={},u=t===Wt;function l(e){var r;return s[e]=!0,k.each(t[e]||[],function(e,t){var n=t(i,o,a);return\"string\"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s[\"*\"]&&l(\"*\")}function zt(e,t){var n,r,i=k.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&k.extend(!0,e,r),e}Ft.href=Et.href,k.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Et.href,type:\"GET\",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Et.protocol),global:!0,processData:!0,async:!0,contentType:\"application/x-www-form-urlencoded; charset=UTF-8\",accepts:{\"*\":$t,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\":k.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?zt(zt(e,k.ajaxSettings),t):zt(k.ajaxSettings,e)},ajaxPrefilter:Bt(It),ajaxTransport:Bt(Wt),ajax:function(e,t){\"object\"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=k.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?k(y):k.event,x=k.Deferred(),b=k.Callbacks(\"once memory\"),w=v.statusCode||{},a={},s={},u=\"canceled\",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Pt.exec(p))n[t[1].toLowerCase()+\" \"]=(n[t[1].toLowerCase()+\" \"]||[]).concat(t[2])}t=n[e.toLowerCase()+\" \"]}return null==t?null:t.join(\", \")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Et.href)+\"\").replace(Mt,Et.protocol+\"//\"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||\"*\").toLowerCase().match(R)||[\"\"],null==v.crossDomain){r=E.createElement(\"a\");try{r.href=v.url,r.href=r.href,v.crossDomain=Ft.protocol+\"//\"+Ft.host!=r.protocol+\"//\"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&\"string\"!=typeof v.data&&(v.data=k.param(v.data,v.traditional)),_t(It,v,t,T),h)return T;for(i in(g=k.event&&v.global)&&0==k.active++&&k.event.trigger(\"ajaxStart\"),v.type=v.type.toUpperCase(),v.hasContent=!Rt.test(v.type),f=v.url.replace(Ht,\"\"),v.hasContent?v.data&&v.processData&&0===(v.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&(v.data=v.data.replace(Lt,\"+\")):(o=v.url.slice(f.length),v.data&&(v.processData||\"string\"==typeof v.data)&&(f+=(St.test(f)?\"&\":\"?\")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Ot,\"$1\"),o=(St.test(f)?\"&\":\"?\")+\"_=\"+kt+++o),v.url=f+o),v.ifModified&&(k.lastModified[f]&&T.setRequestHeader(\"If-Modified-Since\",k.lastModified[f]),k.etag[f]&&T.setRequestHeader(\"If-None-Match\",k.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader(\"Content-Type\",v.contentType),T.setRequestHeader(\"Accept\",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+(\"*\"!==v.dataTypes[0]?\", \"+$t+\"; q=0.01\":\"\"):v.accepts[\"*\"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u=\"abort\",b.add(v.complete),T.done(v.success),T.fail(v.error),c=_t(Wt,v,t,T)){if(T.readyState=1,g&&m.trigger(\"ajaxSend\",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort(\"timeout\")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,\"No Transport\");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||\"\",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while(\"*\"===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}if(o)return o!==u[0]&&u.unshift(o),n[o]}(v,T,n)),s=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if(\"*\"===o)o=u;else if(\"*\"!==u&&u!==o){if(!(a=l[u+\" \"+o]||l[\"* \"+o]))for(i in l)if((s=i.split(\" \"))[1]===o&&(a=l[u+\" \"+s[0]]||l[\"* \"+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.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 \"+u+\" to \"+o}}}return{state:\"success\",data:t}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader(\"Last-Modified\"))&&(k.lastModified[f]=u),(u=T.getResponseHeader(\"etag\"))&&(k.etag[f]=u)),204===e||\"HEAD\"===v.type?l=\"nocontent\":304===e?l=\"notmodified\":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l=\"error\",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+\"\",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?\"ajaxSuccess\":\"ajaxError\",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger(\"ajaxComplete\",[T,v]),--k.active||k.event.trigger(\"ajaxStop\")))}return T},getJSON:function(e,t,n){return k.get(e,t,n,\"json\")},getScript:function(e,t){return k.get(e,void 0,t,\"script\")}}),k.each([\"get\",\"post\"],function(e,i){k[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),k.ajax(k.extend({url:e,type:i,dataType:r,data:t,success:n},k.isPlainObject(e)&&e))}}),k._evalUrl=function(e,t){return k.ajax({url:e,type:\"GET\",dataType:\"script\",cache:!0,async:!1,global:!1,converters:{\"text script\":function(){}},dataFilter:function(e){k.globalEval(e,t)}})},k.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=k(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return m(n)?this.each(function(e){k(this).wrapInner(n.call(this,e))}):this.each(function(){var e=k(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){k(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not(\"body\").each(function(){k(this).replaceWith(this.childNodes)}),this}}),k.expr.pseudos.hidden=function(e){return!k.expr.pseudos.visible(e)},k.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},k.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var Ut={0:200,1223:204},Xt=k.ajaxSettings.xhr();y.cors=!!Xt&&\"withCredentials\"in Xt,y.ajax=Xt=!!Xt,k.ajaxTransport(function(i){var o,a;if(y.cors||Xt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e[\"X-Requested-With\"]||(e[\"X-Requested-With\"]=\"XMLHttpRequest\"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,\"abort\"===e?r.abort():\"error\"===e?\"number\"!=typeof r.status?t(0,\"error\"):t(r.status,r.statusText):t(Ut[r.status]||r.status,r.statusText,\"text\"!==(r.responseType||\"text\")||\"string\"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o(\"error\"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o(\"abort\");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),k.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),k.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 k.globalEval(e),e}}}),k.ajaxPrefilter(\"script\",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type=\"GET\")}),k.ajaxTransport(\"script\",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=k(\"<script>\").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on(\"load error\",i=function(e){r.remove(),i=null,e&&t(\"error\"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Vt,Gt=[],Yt=/(=)\\?(?=&|$)|\\?\\?/;k.ajaxSetup({jsonp:\"callback\",jsonpCallback:function(){var e=Gt.pop()||k.expando+\"_\"+kt++;return this[e]=!0,e}}),k.ajaxPrefilter(\"json jsonp\",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Yt.test(e.url)?\"url\":\"string\"==typeof e.data&&0===(e.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&Yt.test(e.data)&&\"data\");if(a||\"jsonp\"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Yt,\"$1\"+r):!1!==e.jsonp&&(e.url+=(St.test(e.url)?\"&\":\"?\")+e.jsonp+\"=\"+r),e.converters[\"script json\"]=function(){return o||k.error(r+\" was not called\"),o[0]},e.dataTypes[0]=\"json\",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?k(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Gt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),\"script\"}),y.createHTMLDocument=((Vt=E.implementation.createHTMLDocument(\"\").body).innerHTML=\"<form></form><form></form>\",2===Vt.childNodes.length),k.parseHTML=function(e,t,n){return\"string\"!=typeof e?[]:(\"boolean\"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument(\"\")).createElement(\"base\")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=we([e],t,o),o&&o.length&&k(o).remove(),k.merge([],i.childNodes)));var r,i,o},k.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(\" \");return-1<s&&(r=mt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&\"object\"==typeof t&&(i=\"POST\"),0<a.length&&k.ajax({url:e,type:i||\"GET\",dataType:\"html\",data:t}).done(function(e){o=arguments,a.html(r?k(\"<div>\").append(k.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},k.each([\"ajaxStart\",\"ajaxStop\",\"ajaxComplete\",\"ajaxError\",\"ajaxSuccess\",\"ajaxSend\"],function(e,t){k.fn[t]=function(e){return this.on(t,e)}}),k.expr.pseudos.animated=function(t){return k.grep(k.timers,function(e){return t===e.elem}).length},k.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=k.css(e,\"position\"),c=k(e),f={};\"static\"===l&&(e.style.position=\"relative\"),s=c.offset(),o=k.css(e,\"top\"),u=k.css(e,\"left\"),(\"absolute\"===l||\"fixed\"===l)&&-1<(o+u).indexOf(\"auto\")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,k.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),\"using\"in t?t.using.call(e,f):c.css(f)}},k.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){k.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if(\"fixed\"===k.css(r,\"position\"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&\"static\"===k.css(e,\"position\"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=k(e).offset()).top+=k.css(e,\"borderTopWidth\",!0),i.left+=k.css(e,\"borderLeftWidth\",!0))}return{top:t.top-i.top-k.css(r,\"marginTop\",!0),left:t.left-i.left-k.css(r,\"marginLeft\",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&\"static\"===k.css(e,\"position\"))e=e.offsetParent;return e||ie})}}),k.each({scrollLeft:\"pageXOffset\",scrollTop:\"pageYOffset\"},function(t,i){var o=\"pageYOffset\"===i;k.fn[t]=function(e){return _(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),k.each([\"top\",\"left\"],function(e,n){k.cssHooks[n]=ze(y.pixelPosition,function(e,t){if(t)return t=_e(e,n),$e.test(t)?k(e).position()[n]+\"px\":t})}),k.each({Height:\"height\",Width:\"width\"},function(a,s){k.each({padding:\"inner\"+a,content:s,\"\":\"outer\"+a},function(r,o){k.fn[o]=function(e,t){var n=arguments.length&&(r||\"boolean\"!=typeof e),i=r||(!0===e||!0===t?\"margin\":\"border\");return _(this,function(e,t,n){var r;return x(e)?0===o.indexOf(\"outer\")?e[\"inner\"+a]:e.document.documentElement[\"client\"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body[\"scroll\"+a],r[\"scroll\"+a],e.body[\"offset\"+a],r[\"offset\"+a],r[\"client\"+a])):void 0===n?k.css(e,t,i):k.style(e,t,n,i)},s,n?e:void 0,n)}})}),k.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,n){k.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}}),k.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),k.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)}}),k.proxy=function(e,t){var n,r,i;if(\"string\"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||k.guid++,i},k.holdReady=function(e){e?k.readyWait++:k.ready(!0)},k.isArray=Array.isArray,k.parseJSON=JSON.parse,k.nodeName=A,k.isFunction=m,k.isWindow=x,k.camelCase=V,k.type=w,k.now=Date.now,k.isNumeric=function(e){var t=k.type(e);return(\"number\"===t||\"string\"===t)&&!isNaN(e-parseFloat(e))},\"function\"==typeof define&&define.amd&&define(\"jquery\",[],function(){return k});var Qt=C.jQuery,Jt=C.$;return k.noConflict=function(e){return C.$===k&&(C.$=Jt),e&&C.jQuery===k&&(C.jQuery=Qt),k},e||(C.jQuery=C.$=k),k});\n/*\n * jQuery throttle / debounce - v1.1 - 3/7/2010\n * http://benalman.com/projects/jquery-throttle-debounce-plugin/\n * \n * Copyright (c) 2010 \"Cowboy\" Ben Alman\n * Dual licensed under the MIT and GPL licenses.\n * http://benalman.com/about/license/\n */\n(function(b,c){var $=b.jQuery||b.Cowboy||(b.Cowboy={}),a;$.throttle=a=function(e,f,j,i){var h,d=0;if(typeof f!==\"boolean\"){i=j;j=f;f=c}function g(){var o=this,m=+new Date()-d,n=arguments;function l(){d=+new Date();j.apply(o,n)}function k(){h=c}if(i&&!h){l()}h&&clearTimeout(h);if(i===c&&m>e){l()}else{if(f!==true){h=setTimeout(i?k:l,i===c?e-m:e)}}}if($.guid){g.guid=j.guid=j.guid||$.guid++}return g};$.debounce=function(d,e,f){return f===c?a(d,e,false):a(d,f,e!==false)}})(this);\n/*!\n * imagesLoaded PACKAGED v4.1.0\n * JavaScript is all like \"You images are done yet or what?\"\n * MIT License\n */\n!function(t,e){\"function\"==typeof define&&define.amd?define(\"ev-emitter/ev-emitter\",e):\"object\"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}(this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return-1==n.indexOf(e)&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||[];return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return-1!=n&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=0,o=i[n];e=e||[];for(var r=this._onceEvents&&this._onceEvents[t];o;){var s=r&&r[o];s&&(this.off(t,o),delete r[o]),o.apply(this,e),n+=s?0:1,o=i[n]}return this}},t}),function(t,e){\"use strict\";\"function\"==typeof define&&define.amd?define([\"ev-emitter/ev-emitter\"],function(i){return e(t,i)}):\"object\"==typeof module&&module.exports?module.exports=e(t,require(\"ev-emitter\")):t.imagesLoaded=e(t,t.EvEmitter)}(window,function(t,e){function i(t,e){for(var i in e)t[i]=e[i];return t}function n(t){var e=[];if(Array.isArray(t))e=t;else if(\"number\"==typeof t.length)for(var i=0;i<t.length;i++)e.push(t[i]);else e.push(t);return e}function o(t,e,r){return this instanceof o?(\"string\"==typeof t&&(t=document.querySelectorAll(t)),this.elements=n(t),this.options=i({},this.options),\"function\"==typeof e?r=e:i(this.options,e),r&&this.on(\"always\",r),this.getImages(),h&&(this.jqDeferred=new h.Deferred),void setTimeout(function(){this.check()}.bind(this))):new o(t,e,r)}function r(t){this.img=t}function s(t,e){this.url=t,this.element=e,this.img=new Image}var h=t.jQuery,a=t.console;o.prototype=Object.create(e.prototype),o.prototype.options={},o.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},o.prototype.addElementImages=function(t){\"IMG\"==t.nodeName&&this.addImage(t),this.options.background===!0&&this.addElementBackgroundImages(t);var e=t.nodeType;if(e&&d[e]){for(var i=t.querySelectorAll(\"img\"),n=0;n<i.length;n++){var o=i[n];this.addImage(o)}if(\"string\"==typeof this.options.background){var r=t.querySelectorAll(this.options.background);for(n=0;n<r.length;n++){var s=r[n];this.addElementBackgroundImages(s)}}}};var d={1:!0,9:!0,11:!0};return o.prototype.addElementBackgroundImages=function(t){var e=getComputedStyle(t);if(e)for(var i=/url\\((['\"])?(.*?)\\1\\)/gi,n=i.exec(e.backgroundImage);null!==n;){var o=n&&n[2];o&&this.addBackground(o,t),n=i.exec(e.backgroundImage)}},o.prototype.addImage=function(t){var e=new r(t);this.images.push(e)},o.prototype.addBackground=function(t,e){var i=new s(t,e);this.images.push(i)},o.prototype.check=function(){function t(t,i,n){setTimeout(function(){e.progress(t,i,n)})}var e=this;return this.progressedCount=0,this.hasAnyBroken=!1,this.images.length?void this.images.forEach(function(e){e.once(\"progress\",t),e.check()}):void this.complete()},o.prototype.progress=function(t,e,i){this.progressedCount++,this.hasAnyBroken=this.hasAnyBroken||!t.isLoaded,this.emitEvent(\"progress\",[this,t,e]),this.jqDeferred&&this.jqDeferred.notify&&this.jqDeferred.notify(this,t),this.progressedCount==this.images.length&&this.complete(),this.options.debug&&a&&a.log(\"progress: \"+i,t,e)},o.prototype.complete=function(){var t=this.hasAnyBroken?\"fail\":\"done\";if(this.isComplete=!0,this.emitEvent(t,[this]),this.emitEvent(\"always\",[this]),this.jqDeferred){var e=this.hasAnyBroken?\"reject\":\"resolve\";this.jqDeferred[e](this)}},r.prototype=Object.create(e.prototype),r.prototype.check=function(){var t=this.getIsImageComplete();return t?void this.confirm(0!==this.img.naturalWidth,\"naturalWidth\"):(this.proxyImage=new Image,this.proxyImage.addEventListener(\"load\",this),this.proxyImage.addEventListener(\"error\",this),this.img.addEventListener(\"load\",this),this.img.addEventListener(\"error\",this),void(this.proxyImage.src=this.img.src))},r.prototype.getIsImageComplete=function(){return this.img.complete&&void 0!==this.img.naturalWidth},r.prototype.confirm=function(t,e){this.isLoaded=t,this.emitEvent(\"progress\",[this,this.img,e])},r.prototype.handleEvent=function(t){var e=\"on\"+t.type;this[e]&&this[e](t)},r.prototype.onload=function(){this.confirm(!0,\"onload\"),this.unbindEvents()},r.prototype.onerror=function(){this.confirm(!1,\"onerror\"),this.unbindEvents()},r.prototype.unbindEvents=function(){this.proxyImage.removeEventListener(\"load\",this),this.proxyImage.removeEventListener(\"error\",this),this.img.removeEventListener(\"load\",this),this.img.removeEventListener(\"error\",this)},s.prototype=Object.create(r.prototype),s.prototype.check=function(){this.img.addEventListener(\"load\",this),this.img.addEventListener(\"error\",this),this.img.src=this.url;var t=this.getIsImageComplete();t&&(this.confirm(0!==this.img.naturalWidth,\"naturalWidth\"),this.unbindEvents())},s.prototype.unbindEvents=function(){this.img.removeEventListener(\"load\",this),this.img.removeEventListener(\"error\",this)},s.prototype.confirm=function(t,e){this.isLoaded=t,this.emitEvent(\"progress\",[this,this.element,e])},o.makeJQueryPlugin=function(e){e=e||t.jQuery,e&&(h=e,h.fn.imagesLoaded=function(t,e){var i=new o(this,t,e);return i.jqDeferred.promise(h(this))})},o.makeJQueryPlugin(),o});\n/*! lz-string-1.3.3-min.js | (c) 2013 Pieroxy | Licensed under a WTFPL license */\nvar LZString={_keyStr:\"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\",_f:String.fromCharCode,compressToBase64:function(e){if(e==null)return\"\";var t=\"\";var n,r,i,s,o,u,a;var f=0;e=LZString.compress(e);while(f<e.length*2){if(f%2==0){n=e.charCodeAt(f/2)>>8;r=e.charCodeAt(f/2)&255;if(f/2+1<e.length)i=e.charCodeAt(f/2+1)>>8;else i=NaN}else{n=e.charCodeAt((f-1)/2)&255;if((f+1)/2<e.length){r=e.charCodeAt((f+1)/2)>>8;i=e.charCodeAt((f+1)/2)&255}else r=i=NaN}f+=3;s=n>>2;o=(n&3)<<4|r>>4;u=(r&15)<<2|i>>6;a=i&63;if(isNaN(r)){u=a=64}else if(isNaN(i)){a=64}t=t+LZString._keyStr.charAt(s)+LZString._keyStr.charAt(o)+LZString._keyStr.charAt(u)+LZString._keyStr.charAt(a)}return t},decompressFromBase64:function(e){if(e==null)return\"\";var t=\"\",n=0,r,i,s,o,u,a,f,l,c=0,h=LZString._f;e=e.replace(/[^A-Za-z0-9\\+\\/\\=]/g,\"\");while(c<e.length){u=LZString._keyStr.indexOf(e.charAt(c++));a=LZString._keyStr.indexOf(e.charAt(c++));f=LZString._keyStr.indexOf(e.charAt(c++));l=LZString._keyStr.indexOf(e.charAt(c++));i=u<<2|a>>4;s=(a&15)<<4|f>>2;o=(f&3)<<6|l;if(n%2==0){r=i<<8;if(f!=64){t+=h(r|s)}if(l!=64){r=o<<8}}else{t=t+h(r|i);if(f!=64){r=s<<8}if(l!=64){t+=h(r|o)}}n+=3}return LZString.decompress(t)},compressToUTF16:function(e){if(e==null)return\"\";var t=\"\",n,r,i,s=0,o=LZString._f;e=LZString.compress(e);for(n=0;n<e.length;n++){r=e.charCodeAt(n);switch(s++){case 0:t+=o((r>>1)+32);i=(r&1)<<14;break;case 1:t+=o(i+(r>>2)+32);i=(r&3)<<13;break;case 2:t+=o(i+(r>>3)+32);i=(r&7)<<12;break;case 3:t+=o(i+(r>>4)+32);i=(r&15)<<11;break;case 4:t+=o(i+(r>>5)+32);i=(r&31)<<10;break;case 5:t+=o(i+(r>>6)+32);i=(r&63)<<9;break;case 6:t+=o(i+(r>>7)+32);i=(r&127)<<8;break;case 7:t+=o(i+(r>>8)+32);i=(r&255)<<7;break;case 8:t+=o(i+(r>>9)+32);i=(r&511)<<6;break;case 9:t+=o(i+(r>>10)+32);i=(r&1023)<<5;break;case 10:t+=o(i+(r>>11)+32);i=(r&2047)<<4;break;case 11:t+=o(i+(r>>12)+32);i=(r&4095)<<3;break;case 12:t+=o(i+(r>>13)+32);i=(r&8191)<<2;break;case 13:t+=o(i+(r>>14)+32);i=(r&16383)<<1;break;case 14:t+=o(i+(r>>15)+32,(r&32767)+32);s=0;break}}return t+o(i+32)},decompressFromUTF16:function(e){if(e==null)return\"\";var t=\"\",n,r,i=0,s=0,o=LZString._f;while(s<e.length){r=e.charCodeAt(s)-32;switch(i++){case 0:n=r<<1;break;case 1:t+=o(n|r>>14);n=(r&16383)<<2;break;case 2:t+=o(n|r>>13);n=(r&8191)<<3;break;case 3:t+=o(n|r>>12);n=(r&4095)<<4;break;case 4:t+=o(n|r>>11);n=(r&2047)<<5;break;case 5:t+=o(n|r>>10);n=(r&1023)<<6;break;case 6:t+=o(n|r>>9);n=(r&511)<<7;break;case 7:t+=o(n|r>>8);n=(r&255)<<8;break;case 8:t+=o(n|r>>7);n=(r&127)<<9;break;case 9:t+=o(n|r>>6);n=(r&63)<<10;break;case 10:t+=o(n|r>>5);n=(r&31)<<11;break;case 11:t+=o(n|r>>4);n=(r&15)<<12;break;case 12:t+=o(n|r>>3);n=(r&7)<<13;break;case 13:t+=o(n|r>>2);n=(r&3)<<14;break;case 14:t+=o(n|r>>1);n=(r&1)<<15;break;case 15:t+=o(n|r);i=0;break}s++}return LZString.decompress(t)},compress:function(e){if(e==null)return\"\";var t,n,r={},i={},s=\"\",o=\"\",u=\"\",a=2,f=3,l=2,c=\"\",h=0,p=0,d,v=LZString._f;for(d=0;d<e.length;d+=1){s=e.charAt(d);if(!Object.prototype.hasOwnProperty.call(r,s)){r[s]=f++;i[s]=true}o=u+s;if(Object.prototype.hasOwnProperty.call(r,o)){u=o}else{if(Object.prototype.hasOwnProperty.call(i,u)){if(u.charCodeAt(0)<256){for(t=0;t<l;t++){h=h<<1;if(p==15){p=0;c+=v(h);h=0}else{p++}}n=u.charCodeAt(0);for(t=0;t<8;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}else{n=1;for(t=0;t<l;t++){h=h<<1|n;if(p==15){p=0;c+=v(h);h=0}else{p++}n=0}n=u.charCodeAt(0);for(t=0;t<16;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}delete i[u]}else{n=r[u];for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}r[o]=f++;u=String(s)}}if(u!==\"\"){if(Object.prototype.hasOwnProperty.call(i,u)){if(u.charCodeAt(0)<256){for(t=0;t<l;t++){h=h<<1;if(p==15){p=0;c+=v(h);h=0}else{p++}}n=u.charCodeAt(0);for(t=0;t<8;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}else{n=1;for(t=0;t<l;t++){h=h<<1|n;if(p==15){p=0;c+=v(h);h=0}else{p++}n=0}n=u.charCodeAt(0);for(t=0;t<16;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}delete i[u]}else{n=r[u];for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}}n=2;for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}while(true){h=h<<1;if(p==15){c+=v(h);break}else p++}return c},decompress:function(e){if(e==null)return\"\";if(e==\"\")return null;var t=[],n,r=4,i=4,s=3,o=\"\",u=\"\",a,f,l,c,h,p,d,v=LZString._f,m={string:e,val:e.charCodeAt(0),position:32768,index:1};for(a=0;a<3;a+=1){t[a]=a}l=0;h=Math.pow(2,2);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}switch(n=l){case 0:l=0;h=Math.pow(2,8);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}d=v(l);break;case 1:l=0;h=Math.pow(2,16);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}d=v(l);break;case 2:return\"\"}t[3]=d;f=u=d;while(true){if(m.index>m.string.length){return\"\"}l=0;h=Math.pow(2,s);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}switch(d=l){case 0:l=0;h=Math.pow(2,8);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}t[i++]=v(l);d=i-1;r--;break;case 1:l=0;h=Math.pow(2,16);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}t[i++]=v(l);d=i-1;r--;break;case 2:return u}if(r==0){r=Math.pow(2,s);s++}if(t[d]){o=t[d]}else{if(d===i){o=f+f.charAt(0)}else{return null}}u+=o;t[i++]=f+o.charAt(0);r--;f=o;if(r==0){r=Math.pow(2,s);s++}}}};if(typeof module!==\"undefined\"&&module!=null){module.exports=LZString}\n/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */\nvar saveAs=saveAs||navigator.msSaveBlob&&navigator.msSaveBlob.bind(navigator)||function(e){\"use strict\";var t=e.document,n=function(){return e.URL||e.webkitURL||e},r=e.URL||e.webkitURL||e,i=t.createElementNS(\"http://www.w3.org/1999/xhtml\",\"a\"),s=\"download\"in i,o=function(n){var r=t.createEvent(\"MouseEvents\");r.initMouseEvent(\"click\",true,false,e,0,0,0,0,0,false,false,false,false,0,null);n.dispatchEvent(r)},u=e.webkitRequestFileSystem,a=e.requestFileSystem||u||e.mozRequestFileSystem,f=function(t){(e.setImmediate||e.setTimeout)(function(){throw t},0)},l=\"application/octet-stream\",c=0,h=[],p=function(){var e=h.length;while(e--){var t=h[e];if(typeof t===\"string\"){r.revokeObjectURL(t)}else{t.remove()}}h.length=0},d=function(e,t,n){t=[].concat(t);var r=t.length;while(r--){var i=e[\"on\"+t[r]];if(typeof i===\"function\"){try{i.call(e,n||e)}catch(s){f(s)}}}},v=function(t,r){var f=this,p=t.type,v=false,m,g,y=function(){var e=n().createObjectURL(t);h.push(e);return e},b=function(){d(f,\"writestart progress write writeend\".split(\" \"))},w=function(){if(v||!m){m=y(t)}if(g){g.location.href=m}else{window.open(m,\"_blank\")}f.readyState=f.DONE;b()},E=function(e){return function(){if(f.readyState!==f.DONE){return e.apply(this,arguments)}}},S={create:true,exclusive:false},x;f.readyState=f.INIT;if(!r){r=\"download\"}if(s){m=y(t);i.href=m;i.download=r;o(i);f.readyState=f.DONE;b();return}if(e.chrome&&p&&p!==l){x=t.slice||t.webkitSlice;t=x.call(t,0,t.size,l);v=true}if(u&&r!==\"download\"){r+=\".download\"}if(p===l||u){g=e}if(!a){w();return}c+=t.size;a(e.TEMPORARY,c,E(function(e){e.root.getDirectory(\"saved\",S,E(function(e){var n=function(){e.getFile(r,S,E(function(e){e.createWriter(E(function(n){n.onwriteend=function(t){g.location.href=e.toURL();h.push(e);f.readyState=f.DONE;d(f,\"writeend\",t)};n.onerror=function(){var e=n.error;if(e.code!==e.ABORT_ERR){w()}};\"writestart progress write abort\".split(\" \").forEach(function(e){n[\"on\"+e]=f[\"on\"+e]});n.write(t);f.abort=function(){n.abort();f.readyState=f.DONE};f.readyState=f.WRITING}),w)}),w)};e.getFile(r,{create:false},E(function(e){e.remove();n()}),E(function(e){if(e.code===e.NOT_FOUND_ERR){n()}else{w()}}))}),w)}),w)},m=v.prototype,g=function(e,t){return new v(e,t)};m.abort=function(){var e=this;e.readyState=e.DONE;d(e,\"abort\")};m.readyState=m.INIT=0;m.WRITING=1;m.DONE=2;m.error=m.onwritestart=m.onprogress=m.onwrite=m.onabort=m.onerror=m.onwriteend=null;e.addEventListener(\"unload\",p,false);return g}(self)\n/*! seedrandom.js v2.3.3 | (c) 2013 David Bau, all rights reserved. | Licensed under a BSD-style license */\n!function(a,b,c,d,e,f,g,h,i){function j(a){var b,c=a.length,e=this,f=0,g=e.i=e.j=0,h=e.S=[];for(c||(a=[c++]);d>f;)h[f]=f++;for(f=0;d>f;f++)h[f]=h[g=r&g+a[f%c]+(b=h[f])],h[g]=b;(e.g=function(a){for(var b,c=0,f=e.i,g=e.j,h=e.S;a--;)b=h[f=r&f+1],c=c*d+h[r&(h[f]=h[g=r&g+b])+(h[g]=b)];return e.i=f,e.j=g,c})(d)}function k(a,b){var c,d=[],e=typeof a;if(b&&\"object\"==e)for(c in a)try{d.push(k(a[c],b-1))}catch(f){}return d.length?d:\"string\"==e?a:a+\"\\0\"}function l(a,b){for(var c,d=a+\"\",e=0;e<d.length;)b[r&e]=r&(c^=19*b[r&e])+d.charCodeAt(e++);return n(b)}function m(c){try{return a.crypto.getRandomValues(c=new Uint8Array(d)),n(c)}catch(e){return[+new Date,a,(c=a.navigator)&&c.plugins,a.screen,n(b)]}}function n(a){return String.fromCharCode.apply(0,a)}var o=c.pow(d,e),p=c.pow(2,f),q=2*p,r=d-1,s=c[\"seed\"+i]=function(a,f,g){var h=[],r=l(k(f?[a,n(b)]:null==a?m():a,3),h),s=new j(h);return l(n(s.S),b),(g||function(a,b,d){return d?(c[i]=a,b):a})(function(){for(var a=s.g(e),b=o,c=0;p>a;)a=(a+c)*d,b*=d,c=s.g(1);for(;a>=q;)a/=2,b/=2,c>>>=1;return(a+c)/b},r,this==c)};l(c[i](),b),g&&g.exports?g.exports=s:h&&h.amd&&h(function(){return s})}(this,[],Math,256,6,52,\"object\"==typeof module&&module,\"function\"==typeof define&&define,\"random\");\n/*! console_hack.js | (c) 2015 Thomas Michael Edwards | Licensed under SugarCube's Simple BSD license */\n!function(){for(var methods=[\"assert\",\"clear\",\"count\",\"debug\",\"dir\",\"dirxml\",\"error\",\"exception\",\"group\",\"groupCollapsed\",\"groupEnd\",\"info\",\"log\",\"markTimeline\",\"profile\",\"profileEnd\",\"table\",\"time\",\"timeEnd\",\"timeline\",\"timelineEnd\",\"timeStamp\",\"trace\",\"warn\"],length=methods.length,noop=function(){},console=window.console=window.console||{};length--;){var method=methods[length];console[method]||(console[method]=noop)}}();\n}else{document.documentElement.setAttribute(\"data-init\", \"lacking\");}\n</script>\n<style id=\"style-normalize\" type=\"text/css\">/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}</style>\n<style id=\"style-init-screen\" type=\"text/css\">@-webkit-keyframes init-loading-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-o-keyframes init-loading-spin{0%{-o-transform:rotate(0);transform:rotate(0)}100%{-o-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes init-loading-spin{0%{-webkit-transform:rotate(0);-o-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);-o-transform:rotate(360deg);transform:rotate(360deg)}}#init-screen{display:none;z-index:100000;position:fixed;top:0;left:0;height:100%;width:100%;font:28px/1 Helmet,Freesans,sans-serif;font-weight:700;color:#eee;background-color:#111;text-align:center}#init-screen>div{display:none;position:relative;margin:0 auto;max-width:1136px;top:25%}html[data-init=lacking] #init-screen,html[data-init=loading] #init-screen,html[data-init=no-js] #init-screen{display:block}html[data-init=lacking] #init-lacking,html[data-init=no-js] #init-no-js{display:block;padding:0 1em}html[data-init=no-js] #init-no-js{color:red}html[data-init=loading] #init-loading{display:block;border:24px solid transparent;border-radius:50%;border-top-color:#7f7f7f;border-bottom-color:#7f7f7f;width:100px;height:100px;-webkit-animation:init-loading-spin 2s linear infinite;-o-animation:init-loading-spin 2s linear infinite;animation:init-loading-spin 2s linear infinite}html[data-init=loading] #init-loading>div{text-indent:9999em;overflow:hidden;white-space:nowrap}html[data-init=loading] #passages,html[data-init=loading] #ui-bar{display:none}</style>\n<style id=\"style-font\" type=\"text/css\">@font-face{font-family:tme-fa-icons;src:url(data:application/octet-stream;base64,d09GRgABAAAAACWoAA4AAAAAQhQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABPUy8yAAABRAAAAEQAAABWPihI/2NtYXAAAAGIAAAAOgAAAUrQXRm3Y3Z0IAAAAcQAAAAKAAAACgAAAABmcGdtAAAB0AAABZQAAAtwiJCQWWdhc3AAAAdkAAAACAAAAAgAAAAQZ2x5ZgAAB2wAABjCAAAq+uJ4WNtoZWFkAAAgMAAAADQAAAA2BZlJs2hoZWEAACBkAAAAIAAAACQIJwQZaG10eAAAIIQAAABuAAABOPTeAABsb2NhAAAg9AAAAJ4AAACeojKW6m1heHAAACGUAAAAIAAAACAA6gvwbmFtZQAAIbQAAAGPAAAC/eLsyKlwb3N0AAAjRAAAAfwAAAM0412SIHByZXAAACVAAAAAZQAAAHvdawOFeJxjYGRWYZzAwMrAwVTFtIeBgaEHQjM+YDBkZGJgYGJgZWbACgLSXFMYHF4wvPBhDvqfxRDFHMQwDSjMCJIDANLeC6V4nGNgYGBmgGAZBkYGEHAB8hjBfBYGDSDNBqQZGZgYGF74/P8PUvCCAURLMELVAwEjG8OIBwC4Ywb6AAAAAAAAAAAAAAAAAAB4nK1WaXMTRxCd1WHLNj6CDxI2gVnGcox2VpjLCBDG7EoW4BzylexCjl1Ldu6LT/wG/ZpekVSRb/y0vB4d2GAnVVQoSv2m9+1M9+ueXpPQksReWI+k3HwpprY2aWTnSUg3bFqO4kPZ2QspU0z+LoiCaLXUvu04JCISgap1hSWC2PfI0iTjQ48yWrYlvWpSbulJd9kaD+qt+vbT0FGO3QklNZuhQ+uRLanCqBJFMu2RkjYtw9VfSVrh5yvMfNUMJYLoJJLGm2EMj+Rn44xWGa3GdhxFkU2WG0WKRDM8iCKPslpin1wxQUD5oBlSXvk0onyEH5EVe5TTCnHJdprf9yU/6R3OvyTieouyJQf+QHZkB3unK/ki0toK46adbEehivB0fSfEI5uT6p/sUV7TaOB2RaYnzQiWyleQWPkJZfYPyWrhfMqXPBrVkoOcCFovc2Jf8g60HkdMiWsmyILujk6IoO6XnKHYY/q4+OO9XSwXIQTIOJb1jkq4EEYpYbOaJG0EOYiSskWV1HpHTJzyOi3iLWG/Tu3oS2e0Sag7MZ6th46tnKjkeDSp00ymTu2k5tGUBlFKOhM85tcBlB/RJK+2sZrEyqNpbDNjJJFQoIVzaSqIZSeWNAXRPJrRm7thmmvXokWaPFDPPXpPb26Fmzs9p+3AP2v8Z3UqpoO9MJ2eDshKfJp2uUnRun56hn8m8UPWAiqRLTbDlMVDtn4H5eVjS47CawNs957zK+h99kTIpIH4G/AeL9UpBUyFmFVQC9201rUsy9RqVotUZOq7IU0rX9ZpAk05Dn1jX8Y4/q+ZGUtMCd/vxOnZEZeeufYlyDSH3GZdj+Z1arFdgM5sz+k0y/Z9nebYfqDTPNvzOh1ha+t0lO2HOi2w/UinY2wvaEGT7jsEchGBXMAGEoGwdRAI20sIhK1CIGwXEQjbIgJhu4RA2H6MQNguIxC2l7Wsmn4qaRw7E8sARYgDoznuyGVuKldTyaUSrotGpzbkKXKrpKJ4Vv0rA/3ikTesgbVAukTW/IpJrnxUleOPrmh508S5Ao5Vf3tzXJ8TD2W/WPhT8L/amqqkV6x5ZHIVeSPQk+NE1yYVj67p8rmqR9f/i4oOa4F+A6UQC0VZlg2+mZDwUafTUA1c5RAzGzMP1/W6Zc3P4fybGCEL6H78NxQaC9yDTllJWe1gr9XXj2W5twflsCdYkmK+zOtb4YuMzEr7RWYpez7yecAVMCqVYasNXK3gzXsS85DpTfJMELcVZYOkjceZILGBYx4wb76TICRMXbWB2imcsIG8YMwp2O+EQ1RvlOVwe6F9Ho2Uf2tX7MgZFU0Q+G32Rtjrs1DyW6yBhCe/1NdAVSFNxbipgEsj5YZq8GFcrdtGMk6gr6jYDcuyig8fR9x3So5lIPlIEatHRz+tvUKd1Ln9yihu3zv9CIJBaWL+9r6Z4qCUd7WSZVZtA1O3GpVT15rDxasO3c2j7nvH2Sdy1jTddE/c9L6mVbeDg7lZEO3bHJSlTC6o68MOG6jLzaXQ6mVckt52DzAsMKDfoRUb/1f3cfg8V6oKo+NIvZ2oH6PPYgzyDzh/R/UF6OcxTLmGlOd7lxOfbtzD2TJdxV2sn+LfwKy15mbpGnBD0w2Yh6xaHbrKDXynBjo90tyO9BDwse4K8QBgE8Bi8InuWsbzKYDxfMYcH+Bz5jBoMofBFnMYbDNnDWCHOQx2mcNgjzkMvmDOOsCXzGEQModBxBwGT5gTADxlDoOvmMPga+Yw+IY59wG+ZQ6DmDkMEuYw2Nd0ayhzixd0F6htUBXowPQTFvewONRUGbK/44Vhf28Qs38wiKk/aro9pP7EC0P92SCm/mIQU3/VdGdI/Y0Xhvq7QUz9wyCmPtMvxnKZwV9GvkuFA8ouNp/z98T7B8IaQLYAAQAB//8AD3icrToNcBzVefe9/b3dvd29u909/dyd7ke6k86yLEunOyHJsrCxJWyJGmEcLMDYxBhHNsZQBzOAkjQmFDrGIq5gHEIcCILOAGZq3IQO04RkIGkgaUMKMbQznSlJW0wgJtOQHxRr1e+93TvJwq7JTD3y2/f//bzvfX/vAhAIzL3KPcYNBFIB8UR9EJYuAcuAqGNbOiwDSczkuorlaJ6WTeVSRwMIDveY8aN20GztjzMhW4P2H+kNUPM5NaVNQE0K3tWM77vv8rJqgnT33VJE4WWIfd/QbKHZjcXcZiFAqjCDgUJA/mZTWOIIwi0vAwNiUjkW9THIZs6DAbnj6ffGP/P+0y2vv+5SXGLKuXHJPJH92c+yT7x3883wnI9W/DxI4T9+bm7uOL+MUwNywAg0BJYFQgNKa2NDzFBEjqeM0SFXLHU4YKe7yjFoSmdEKWw5nemOUj5czMXCliilM7lyuFgqp3HaDf1j/fhH+s6cfm4MEpA8c0BSQBO5CUkD5fJi05kDjSUoNnETTUUSXtpPVm0aGHDdmV0nNkPiMUWeHZMVRSZPSlp0dqypCKVG8iT9IK5AEeamyZGAjecW5tm5SSBm8ojiSqBsYoXDTRtuymw13V8axjB+p2EPlsMGcRzTTRkGOLRpmk/AzSZ+A97ecx+QN8g9gUbc26F7N+GJiN5pLGMA8hUo7EQcHI455A0PwrS3I37N+bZhTE8bex1aeeIJ4+MTjTY6gcH+iIvgGWQRdh2TR9sS81kspCzytguLfBcyuBOLXuhwYnZnh8NFUs6plLPLScGpWBKwkYztwsop7Hie9r7rYK/9brWXTg9U+RiBX+GJiyc0rgIv7UNJe3vPjrFdyZOV/byNUkyW/0AuIi/h+h6U5a64SmW5ieGcya2AYimG+EUtnZN08ImgveV+KOYykiiJVMrbkI+dHUkC9+nyPUFdD94j639r1uTq7FiSNrR1hXS8uLbGapYUSbpaJvzmp5aODbU9iJNBU1gJa5LFTCqihNpDigmWWtc2GjUy7Y2m3hHk14qmPJXp2cTInZudO85dhzw2AuXAJQHl+Yt7l0RVjkO8u4q5JZARE2A5yNxStNgGWcQSj7izA1HucCgJOsRsb7xYWgn9XAwvRqaN4HAS4ENF3kXFFovJ/muW3zsYDK3jxaCQbOouOPXZPmBDNZG4krS0N2/9wakf7hHv+IcPX/jcaGWZAp9fvrFtv66UeSlXn4zYdZo5kLNwIJJRTbEu3jz62Zf37Xv5l7RAeugZfAQ7kJ5koA3PoJB1eP8MpHRVWqpygyITpiKz4DCoHMENlun+wrDA0bNZ9jmJZdZwhhx9UnewMKztg2yAlie9j6O7Lzrks7tYdRdOO4u/FJ9e5G93RyFTJ1f5G17IZDs7z25uEfuFBYwlvYpUUuTnKJO6umg5IymD88yGGxbycjN2JOkIVk6wUoEzm/0O5T/Owb92Jg8NyL/6qFrl30IZ5nSgMp3nch7DkvOMCaMeoQ1U4JZxQncenmAMmcAei/S7V9CvAccW8mczwtMCceSQ8nwhXWuKAeQPJbRCc9RnhoSyhvBL+WgxTzsk0Y567IFj+35wa4Xq7ykS5YIm7UIdq4iCfKcsiIoSvFFWONUnFovZoXHKhXE69R9hTOIEgZPcJ0VZRrx+i3j9hhtFPqQDnYjX8uaEpS2+F4twiVkOylSJAwfvBZO3XBnoTaEHtltSWAGKIEl3SJIQ1CRESIRnLFtJRc88GckEbQuOBTO5zBXziL0JIPKiyMtzggwiMc+czmbDEbDMbJaLhC3LPzPuFOKaD6zEM+tt15gNxTPLIg5dvglCfGmbmakYmqmKsEfRVOWWAXjqvEzVeamT6botq9321Vu2rIb7KOrufmZ24LWmoiI3yspJJ65e704JprBSFGH3pxXLhAQe9fBzbM1rq7YAm1dsctvZSiqu8G94rxwS/LQ7JYorRR0XXq/GmSh4dJADKAsSk70ajQ8gHdE0MhzVjOCbVDSvKINd1PhKVN+fgMTG2zYCvIaq+V2mmsNTP36IRLD6xO7ejWTDisfc7zCVD6tQW+/eMTW1Y3fSt20foe+hBZpQ3zfGfH3vyzmCZNvHFoJFVPrRjj7m6I26M3r7KHQxgD5c2H/4tQdIeJLJ+yQDvTsZOwv4jYfJQxVaxxmtKtNTTVaQnRmS6kkWvfBoNvCeIT55jt41PJZwpg3YYeJYGK+dppgK/sF+R/8ggZIOBlnyNoK/qpwokLZ6uCFRKCTKV8HeGaYksPg2Xj/3fyQZb6dhGWv2QLLQU4DW7lZwf77Hw+vb3AjzexKIVywkEXoGlB1JUqr4FW3A7BZlDzgzhZ5W0tyfI1da7mmn13JvsZOFxLuJIRsmLXJVskByA41iu/uvSds9bWOnPZQ4lSgANm+xqQ6gMPlGH2YR79rSDIXLXQBujHZSxkCpSIeynwCdNxEFJ2HVmSDaFPxQYoIN2BfCM8E6zTCu66VDSQ97KkPfIa8i7nGUITNAZagDhYFJjeg5rXh+bcBuYamT/JWmRVE8Iopeb/3ud1ZdSIs4TkQLcaogJ63Z5dGUxEfefz8qSKko+Qm2PB/ZgyEEMngmjkjovYB0GBog+n9COzD7MiQ73pfOA5S8NLseIst+QWbPC9y/J8dRv7QFliCNWcnzAYlI3fE8hdNVbBPY1WEeZxm8m5mKOdypQRG1qhiRgQBnZbr7N20qT1ipoPsLVYWEGq8hE3BoLPn2tV8PhWVe0WTB4nIN3WMD7cmIiDZEhaSSROulWMbk2+sX4LIs0Iq4NNdUfV3mDeqCbaEOligmbYSFCaU0VRVULrhTKoKlIMubNvV3ZyyOByWMilXkBpNjcIjihTjBrwzF/bmKF1iMJNsHxrobcnxElDVF0C3u69fevP5txIsEcUrVZyR96DPqiI/C+zGTp0uZGkXVP6PG1RncET7Ey/eKjnX885QeWw83krsCIVyvMp8TD9P3rEvMFUkFZxS6Rw25ytWQJ/52/tqLyQSDrc7Dpiq/H2XDgYsVBgjnK7BF95EwLKLNKLh0bg5x74VXPNwJO1fq7raB588j7pbhat78pDKjPE1td1Jl6Hhn8Q73LdISsCrrgwuijljQ28Tinnavx+Xu9ap6jYqn2QzNaly7RoVJ99MoBl/DvmtU1X0Lu3FCnO37XXKEW832Nai8BYnDKKvIF92W3F9dotK94ahCNyJPuW+5b2L1WrQ2X6fSc1TBejLg77uvsm8FX2b1ghWk6cbjuB1FUIVm9y0f6aMKfMbdhjshNGihFKgIgE7044ZvkbXz+zbh3chXN/f35Z6mOyF2b/m7H6V7HVV3XYOYtiDOig/J25bh+xPuAPMdxRPRc8V1YU8Z2mEv9OIO2O6DTg8Wtt2C3+lCcjBRmEaNVbDhi0nLnUK1ttvqdVpsexruQ93WGnf3T9s47N+te7nN5FeohRGeChUfIvZx5htAPYTNjQl/ea/tTlkW7LZ7nIK3dyNsGUwWpq0+a4k/ALvozB5nurkCqwthUdrq5mnzBD/tu5rpfPVYuC6L0VZwnMfd/YnGxgTc97jjFNjGFvRQ6iyrYPfZjyPVyQJM233YRF5YVb1xgLzjwVMX3NOwZ/K7wtJZx4W8pGRNNzf4ZOBeCKgPCxuKcUYmxQNycbjP5wGlEJGk8OZc369tR3gtaZ+X6CbmVkIONRVJcugpluk1TQL1Fqmfy1ELVi4hYy1zJhYNj4zu7RkfbuebN17fv+q2Fj4sDgtE7Hv2uk89uneIH7j9yNWjR1YMmUvJSzO6s9QcGWkbHt83PtzW0yWCMMLr4roNcMm+o88e3XdJ/0VDkWiFDxSv5YhXq8d3nVAryjjtoDXp7Ojn2gg6ijGHIUxDpQZ0Y2lQym2+5NZHN219to8XhsUw33Lb6p6dG9DVGN598/bmkXA0NoPeR2t4qO/h0U8d3bcKtmB5yeilos6PCCB29fgINjeNmEsdfaYmGhm6qB9RrPhEx7mrEbfGwCDauZXNJo09wLJ1oAhSe1NxWkUDKKJofMqeE+szt8S4K9JYmjbLXRRtylOU1vWN//mVy4/0DVGNqM9QJT7SvL287ot5MSZoGC/oyHTWO7p3vdd5s6RB439/5fKH6aIaEDh46AVkpMqWo1YdaWpe1690hzT4e79jxGuLvD+R0iUwuiJ+TLUM4+yrA8aAdsVAsX1JFgMsTkCF4ceBdtgLZ8oXaENnPpfPipLA6A57nn4+XI1hUbCoYmig1KP5pH44Kybnq4cUyatKivvTmXpeOC7y8J4il3yHncWVz+SDrc5zTqucPyYro3Af7XP30/I8ddJxsQAgXIFbz37QdsmqNhJl0K6145C0rkWzExAX8aM3sDpwYyA8oF83PNBXWu7xRPQMIT1E6syw7M4F2tFwOmyhVKQ7+uH/lz9DribLBF4jsuze94lYBc+7LzLOXMw4c+66u52EZz/QLEWxyA0XZFuA9+OVUfSTwyzWCw0o3a0Jx9BYTrKp2AZiEi9qGSs6OFhZkPboRDXesZKpbcd3UOjV8dMgNNQhr1pJh0Qy5petVIQ48Zq1KefMj7zIhluf3pQeBs5JfUuJMGcgHFRik16gP1mzHX2EmroaYhmVysETLOo54aSGU/gHzbEwdRvCMXuGhUczHj3HkZ42Rk9LYIDS07c8YRuqSBg91Pmnwo8VghFR2Y9oKTmxziSwi0HTN2I1cMvT3E7Fezk/Pae1UnYyUwqdRnqCNZPoXSJSk6hxGWmRBKqBSMqyTP97/wmaJcQCGpqbG5Iw6vhEtHpEVWihepULpFG3rqG0rOha2qTxJIC0YOSYFjrxEtP8nlSlIxvu7PLcRKmS76mk04Sq0HoTqJ04CcfcK+DDIU34mhCX/dByaAiDy58ibicVeRdNJrNyezI2G/ESlUKsZDxiOtLJk/ChXCc9Imp+1nO2xL6QZIkkWiizM7SHIF9q9K8ZpQDx8zOjgWaMzORvdrSGPJ2sEzRYZer9O2gmWD4zSTr6sSuH8Uc/IGjmyLIMOHUV0G48840967ixy2v6zIhcU+pr3bDj9u0bc1xfqUbO9sUuH3O/iqEbFPqaPbOBZuFTO57rx7mxvnDL7avRFLah/ei55LZCpKddjqz4OxhyH6YRLuzA0rcfY5yC8rQTcb08JdLYleZW8TZ0lGgSCyVfQoQtRDiPV6BqKLryzL7kqRmkuoGdE5UzlKWy39mJQlU1OChf1KrEHOYcsdMhvaO3j5JN+zZBXJZ2Kmq0WRSMDSFJGqmtC0q8eZesmfWxPxNNca3DC3KzYsg7MBBXhJ2yHmvy5sojNXVBmQvfhUdoxJ0NgiENWTzfqwd3SOjC927ceNvGjbfTUTNp13eIumhvAKEvJA/HTUW6Maj1CeJAUtBFrcOI1xugSWxubV1qqaRJ1gZvqiHLbKqwOo5TR9hELw7/iBsjL/t6WXl+SWN9VOO5RfnTtJcwreTFY35bWthGB+bMB+yOcGEDg4bztxbkUR0wh1h2kJWgV0awMR+Hjvn5mlrmu9BMCMpYsZynmQC8KR2xco4maZIg5jN5CU86ViJ/s27nzqlxgFc6167fuXP92s5XYOdDO8j4pYNYw16IjR8eH79U0ra3Y6V9uyat20l2P7AbsKpjJ81Tzs39nt9PXgqYeL9LNB+Yi9uMN1BEZ0knnvijDiZLEDg6dJ30NuA9oQEVh9U0uk/kgO8A+R94pvWy8YveWn0ZWbfmLepJXdqz5Z5B94qhu7d2k75r7l0Lx2gVtvTMr6FXgDY7p56d6qSNS+/e0ke6r//CQ1/YXiTdW++u+FK/529HfC3klvzNhK3Te4txIUFlkuQ8tIjguXrUG6WAPWgMsIcDF664d3v3DHXwhQ07YMul2I9QDvtQXz+bokoej3uUo5mt1Qi7f/m58pGoIAyavsnnFiUl8cbhKTpRmI+CKw9Y1oKc5GvZZJCT6kWJcCHNzzDS3KTQKEocr/6Fe1GoUf+1rq/QG/W/hs9goz8E649Xc5M6HxXjAnDV9OT9spBFuwOC26Prv2bzQ3RhCHfwaYpW8+LxqOzlYOZR7/Kf/RbmXMktCzAr3jWP/Kqt5KUqZDq4uTqyBbYGfL17HcuL19KcjykyePSoAP2bNgILH1qOXXFwA9l471P3bOIvOwRXL8j+k0OjB6cPjrLCfe2sXP/824QcsAMZlOmGWiMo0rwb4K1qo+mH/LkBVlXdA+cFXFFWvz0//AXvbZ6+ac3GoyzHHvXfzCqvNILfLi9qV7KBJ/03OPbql/A+XlcDa3g9C1/rnPPU/XzkR4E3q/4p6kHES6V3vVx1M7x3EG4RnpwfhuT9B8mTF4BG6w/vZp7SbtoL4oJBkCuYe2+LL3GT6CtdzGKjNas6FGaHETyqOIeljCSdy4azYTwkLxFIL08OHSKaM+7sonl9vERpGguhHaS5bUgz24xu3ETTPsVKqntkIZfpqR1MdBfQKd6hmiFHviU1QZ260MQ2FSOcbfDmVoyFeHkb9rq/db9KFWsP6uutqz6LgZW6R+JrIjp86Gp6jSXL+7RoUv38yjEracH0NiVpKdu2ISBl27QDRdTKAT9WHoc/IL/p7w4sptcdmtpFR6IcZRnNXDnaT909x7Ykjj6PwmlFdP9FMuWgQvb8nAiKpHB7iS4/r+pk678LRCWOGpq9QwfOlOGlbpDkEPwThngKL7puibAY5LvMl+ZQQ8Yx4mxF/wZjkGJ7a3NjKl5jyjiJ/hAhLzVVExN+9qMpZsAyWImhu/eF2NlfcmS6bxq6lNlO9CZvxpjon/G7R5k1SqVwuFwOv3HTTZn0TTelSQs2wtjpPkNH8D/RH++b3mkosx0KLkzSlfi92qSrzPKX2arMTe692ChjJ7T5I75t3I487EIe5jXKQ6pg6Q83qs/lEn3noSFynmb4aOrBF9sEoBuHhKFYcL11up41emofLCQGE60wVdeDClSvn5qqM41Go7t+iuWUHqzrNrOGWTsFst5TtwLXXPk0Syc9fSX2rsBFmzadY6C/Fge8d+e5uXHkfyiQRc6vwTu2Ylkhz95Fq2/8+YVv/CxSqb7xxyqhDjDBRxFBxcQnSYzeBfrYNqGJjej4TLDfWEywII42hqZ+/BB/6I2DkCn0WS9uv3PD4Z0DpG/3oemDe7u5NS/aMOWtol60t2qCusYTSi19uHn1iHiQOpz2i2v6xx/4xqE9PfyqHQ+N3Ln9RftsmoxADcYAyvMt9Y73lr7wdwTUmb8g/u53GOaw6pPizJC9MJrEj7noG9sG1CNhmWN2BcF2dpRzGBfz5XrojEWZRxuj6aCYY0tiLJOTMmK2uJJQjxj/8hjKEB1iGHCj4JTpxczQzEtehAevG+5pUO12twtCjfG4I979yJB4a7RlZbDdVGV1OMgDQPZQY+ERm1wqiVyYJwJHMrGaP+o9YKbUlE2ApL6YEiyylNT9ESff74qtvCgqNSZcBVOa+2Hr9q9E70rVikGTcxRJ4BSQa6ImzpQIEXk+OFbqhvQRQ4souDWotqAiL2Xqm+AZ/Yz0kXcCOnvfqg1779vzOXtqtvPMii9Ig5+dwj87Kf4bQ6EJfdRt4PyQZYFY0/NXERbE5vPzi+As2njhToFqfp7h6ufXYTFiZ6MCryyG/xQX5qIBFddLfr6b+SYsHc3P1ocikRD5rxCMuNslxeBKuiZjzQpUY6kFvwNgPtyioHRxkEr9fv+HE5AwHFc9q0neOXOa/kiAi9ByQX3et1fZb2+q7yCL914QN5y1GVt/DOVaR29JPCECXV9iGaI84A7sQ9W3Y4dLZe4vVR1Mxd3Hc7rq7lNVOKjqHM9xqmiceVWXNTgoiO6fswpN0R/EfnefyHtnMvcsdw1nzMOJiSzGpQ+SPmclxmVRqlVM0HG5wNFSQYAIRhjE3ZDTsobwJbifVegTxj7sx7mCRwvp5XSWh6/QYs/TwjyMahKsVCYZVaeECMTR56MplPyzCfrSPO/dL0m8RwvpQ1oS56aF7i/58Mpn0eOHaKxcTNGd84cLd4oCvXPu3B+4a8kPUA7rmSzJ7E3Zy7OzuJEm/Mt+7Eh/pyDPMx7xF7luuh/CY9hDe4WZYLqvW+YhFlJiWX1PO0aOB6L0t3AVOUK7V/XSqP8Dx/CavHCY8erwC3jhyKHZR2nu9wXvpz4vKN4dwOIA22sZ/S1RTbhyBxbvF/XeXzEQpfEUTa0hLTTE+RigN9vzQhBp0RzT5OUaKazwlhEU8u0fx8D9XmGdwVmmZmpavDGuichhJJUz1nn5pp9yj5H3GG7DgZtovmnn5YNFiiT/JyIZqw6Uvd+i0TRIFwumFw7SVEg/TYvQDM/8hE9O4uTWEVlECuyU2tLW1oKK3jIk+bItDxy6TZKw36mttdZgKDxo1fIRzrFMSbrt0J/Cl8KVh1OcozuqGUyO7RxLBk3UrA6XfmDTF97qwAErpOl655GnjnTqOidyIQsHO08G/hcLt/j/AAB4nGNgZGBgAOLaW41M8fw2Xxm4mV8ARRguss1QhNC5H/9//Z/FUsEcBORyMDCBRAFTFwxveJxjYGRgYA76n8UQxVLGwPD/FUsFA1AEBfgBAHyYBUh4nGN+wcDAvACCWfSBNIgviMBM1kA6koGBMRWVBqsDYqYmiF4wHQkxg+kUBMPVWEP0gTDYvBdoahZAzYxEY0ciuWUBFjkoZimDYLC8IKpehmsQccYvSGYgYZB7YBhFL5o8cxTQjDUI/wIArpclrwAAAAAAAAA6AIYA3AEKAUgBgAGgAfoCYgKqAwIDOgOGA9wEQAR4BLYFAgU8BZoFzAYMBlIGmga6BtgG+AcYB0QHcAecB8gIAAg2CG4IpgjyCUAJrAo0CtALOAueDAoMYA0ADVANjg3mDiQOjg7GDvgPOA+ED84QPBB2EN4RNhGgEfISchKoEsgS6BMGEz4TXhOSE8QT+BQsFGIUiBTWFX0AAAABAAAATgBuAAYAAAAAAAIAAAAQAHMAAAAiC3AAAAAAeJx1kctOGzEUhn9DoIKgLloJdcdZIRDK5CKhSqyoogJrhLJDwgyeSzpjRx4HlGfgLcoz8Dp9j+76Z2KhqFJmZM93Ph/bxx4AX/AHCqvnnG3FCgeMVryFT/gReZv+JnKHfBd5B108RN6l/xV5H2d4idzFV/zmCqqzx2iK98gK39RR5C18Vt8jb9P/jNwh30fewaGaR96lf428j4l6i9zFsfo7drOFL/MiyMn4VEaD4bk8LsRRlVZXouehcL6RS8mcDaaqXJK6OtSml+lemTrb3Jp8Xmm/rtZ5YnxTOivDZLCur401XgfztNytec5HIWSSeVfLVdxHZt5NTRqSIoTZRb+/vj/GcJhhAY8SOQoECE5oT/kdYYAhf4zgkRnCzFVWCQuNikZjzhlFO9IwvmTLGFlaw4yKnCBlX9PUdD2Oa/Zlay1n3dLmXKei9xuzNvkJ7XLvso2F9SaselP2Na1tZ+i2wqePszV4ZhUj2sBZy1P4tmrB1X/nEd7XcmxKk9In7a0F2gv0+W44/z/KQo7lAHicbZLnlpswEIW5Bgy4bLLpvfeE9N57z76DLARWEJKOEEucpw8CO/kTncOdT6PhnlHxRt4wJt7/x47nYQQfAUKMESFGggmmmGGOLezBXmxjH/bjAA7iEA7jCI7iGI7jBE7iFE7jDM7iHM7jAi7iEi7jCq7iGq7jBlLcxC3cxh3cxT3cxwM8xCM8xhM8xTM8xwu8xCu8xhu8xTu8xwd8xCd8xhd8xTd8xw/sBLUlZuIkZZW2q0hzahvDRqocUyIpE4EWTR1WXDZ1sGRCz5yklBsqWBZwmauZk01mTqxl0nIlUyLs9r/Zej35m4kFl2XKftlAKFomTlKlmfQ1l74lRdB9dbxQqqyIKbc2MPQZGqbFKsqVaYnJ4ky1Ms24iQXLrYPE8GLZ07jRfaIvcf5JX+NoMhQ5jLoqFwenBS8Gpw7WTh05py6MaOtT2ibEGNXWKW1Da0i9nPY6dNe7CEWy7pc+5EJpvfJVnvtUFUHFZBPWS2LYxKqiECztVpINypAuGS2nvQ6Gs+H0hsk0U3ZznDETguua1/MNpLvMWH/RFGEuuobCihScxqS2zPC6jH4rVaVcxn1UjQ1yJW1QK2MTJ6nrPOqp0d3Vk1WoSVOz7p0oHeWdTbpoh5i3sVWpezp23AGTWch+Mmonu0o0Vb+l6RqdabLmRnveH9ru7j54nGPw3sFwIihiIyNjX+QGxp0cDBwMyQUbGVidNjIwaEFoDhR6JwMDAycyi5nBZaMKY0dgxAaHjoiNzCkuG9VAvF0cDQyMLA4dySERICWRQLCRgUdrB+P/1g0svRuZGFwAB9MiuAAAAA==) format('woff')}</style>\n<style id=\"style-core\" type=\"text/css\">html{font:16px/1 Helmet,Freesans,sans-serif}#store-area,tw-storydata{display:none!important;z-index:0}.no-transition{-o-transition:none!important;transition:none!important}:focus{outline:thin dotted}:disabled{cursor:not-allowed!important}body{color:#eee;background-color:#111}a{cursor:pointer;color:#68d;text-decoration:none;-o-transition-duration:.2s;transition-duration:.2s}a:hover{color:#8af;text-decoration:underline}a.link-broken{color:#c22}a.link-broken:hover{color:#e44}a[disabled],span.link-disabled{color:#aaa;cursor:not-allowed!important;text-decoration:none}area{cursor:pointer}button{cursor:pointer;color:#eee;background-color:#35a;border:1px solid #57c;line-height:normal;padding:.4em;-o-transition-duration:.2s;transition-duration:.2s;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}button:hover{background-color:#57c;border-color:#79e}button:disabled{background-color:#444;border:1px solid #666}input,select,textarea{color:#eee;background-color:transparent;border:1px solid #444;padding:.4em}select{padding:.34em .4em}input[type=text]{min-width:18em}textarea{min-width:30em;resize:vertical}input[type=checkbox],input[type=file],input[type=radio],select{cursor:pointer}input[type=range]{-webkit-appearance:none;min-height:1.2em}input[type=range]:focus{outline:0}input[type=range]::-webkit-slider-runnable-track{background:#222;border:1px solid #444;border-radius:0;cursor:pointer;height:10px;width:100%}input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;background:#35a;border:1px solid #57c;border-radius:0;cursor:pointer;height:18px;margin-top:-5px;width:33px}input[type=range]:focus::-webkit-slider-runnable-track{background:#222}input[type=range]::-moz-range-track{background:#222;border:1px solid #444;border-radius:0;cursor:pointer;height:10px;width:100%}input[type=range]::-moz-range-thumb{background:#35a;border:1px solid #57c;border-radius:0;cursor:pointer;height:18px;width:33px}input[type=range]::-ms-track{background:0 0;border-color:transparent;color:transparent;cursor:pointer;height:10px;width:calc(100% - 1px)}input[type=range]::-ms-fill-lower{background:#222;border:1px solid #444;border-radius:0}input[type=range]::-ms-fill-upper{background:#222;border:1px solid #444;border-radius:0}input[type=range]::-ms-thumb{background:#35a;border:1px solid #57c;border-radius:0;cursor:pointer;height:16px;width:33px}input:not(:disabled):focus,input:not(:disabled):hover,select:not(:disabled):focus,select:not(:disabled):hover,textarea:not(:disabled):focus,textarea:not(:disabled):hover{background-color:#333;border-color:#eee}hr{display:block;height:1px;border:none;border-top:1px solid #eee;margin:1em 0;padding:0}audio,canvas,progress,video{max-width:100%;vertical-align:middle}.error-view{background-color:#511;border-left:.5em solid #c22;display:inline-block;margin:.1em;max-width:100%;padding:0 .25em;position:relative}.error-view>.error-toggle{background-color:transparent;border:none;line-height:inherit;left:0;padding:0;position:absolute;top:0;width:1.75em}.error-view>.error{display:inline-block;margin-left:.25em}.error-view>.error-toggle+.error{margin-left:1.5em}.error-view>.error-source[hidden]{display:none}.error-view>.error-source:not([hidden]){background-color:rgba(0,0,0,.2);display:block;margin:0 0 .25em;overflow-x:auto;padding:.25em}.highlight,.marked{color:#ff0;font-weight:700;font-style:italic}.nobr{white-space:nowrap}.error-view>.error-toggle:before,.error-view>.error:before,[data-icon-after]:after,[data-icon-before]:before,[data-icon]:before,a.link-external:after{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}[data-icon]:before{content:attr(data-icon)}[data-icon-before]:before{content:attr(data-icon-before) \"\\00a0\"}[data-icon-after]:after{content:\"\\00a0\" attr(data-icon-after)}.error-view>.error-toggle:before{content:\"\\e81a\"}.error-view>.error-toggle.enabled:before{content:\"\\e818\"}.error-view>.error:before{content:\"\\e80d\\00a0\\00a0\"}a.link-external:after{content:\"\\00a0\\e80e\"}</style>\n<style id=\"style-core-display\" type=\"text/css\">#story{z-index:10;margin:2.5em}@media screen and (max-width:1136px){#story{margin-right:1.5em}}#passages{max-width:54em;margin:0 auto}</style>\n<style id=\"style-core-passage\" type=\"text/css\">.passage{line-height:1.75;text-align:left;-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}.passage-in{opacity:0}.passage ol,.passage ul{margin-left:.5em;padding-left:1.5em}.passage table{margin:1em 0;border-collapse:collapse;font-size:100%}.passage caption,.passage td,.passage th,.passage tr{padding:3px}</style>\n<style id=\"style-core-macro\" type=\"text/css\">.macro-append-insert,.macro-linkappend-insert,.macro-linkprepend-insert,.macro-linkreplace-insert,.macro-prepend-insert,.macro-repeat-insert,.macro-replace-insert,.macro-timed-insert{-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}.macro-append-in,.macro-linkappend-in,.macro-linkprepend-in,.macro-linkreplace-in,.macro-prepend-in,.macro-repeat-in,.macro-replace-in,.macro-timed-in{opacity:0}</style>\n<style id=\"style-ui-dialog\" type=\"text/css\">html[data-dialog] body{overflow:hidden}#ui-overlay.open{visibility:visible;-o-transition:opacity .2s ease-in;transition:opacity .2s ease-in}#ui-overlay:not(.open){-o-transition:visibility .2s step-end,opacity .2s ease-in;transition:visibility .2s step-end,opacity .2s ease-in}#ui-overlay{visibility:hidden;opacity:0;z-index:100000;position:fixed;top:-50%;left:-50%;height:200%;width:200%}#ui-dialog.open{display:block;-o-transition:opacity .2s ease-in;transition:opacity .2s ease-in}#ui-dialog{display:none;opacity:0;z-index:100100;position:fixed;top:50px;margin:0;padding:0}#ui-dialog>*{box-sizing:border-box}#ui-dialog-titlebar{position:relative}#ui-dialog-close{display:block;position:absolute;right:0;top:0;white-space:nowrap}#ui-dialog-body{overflow:auto;min-width:280px;height:92%;height:calc(100% - 2.1em)}#ui-overlay{background-color:#000}#ui-overlay.open{opacity:.8}#ui-dialog{max-width:66em}#ui-dialog.open{opacity:1}#ui-dialog-titlebar{background-color:#444;min-height:24px}#ui-dialog-title{margin:0;padding:.2em 3.5em .2em .5em;font-size:1.5em;text-align:center;text-transform:uppercase}#ui-dialog-close{cursor:pointer;font-size:120%;margin:0;padding:0;width:3.6em;height:92%;background-color:transparent;border:1px solid transparent;-o-transition-duration:.2s;transition-duration:.2s}#ui-dialog-close:hover{background-color:#b44;border-color:#d66}#ui-dialog-body{background-color:#111;border:1px solid #444;text-align:left;line-height:1.5;padding:1em}#ui-dialog-body>:first-child{margin-top:0}#ui-dialog-body hr{background-color:#444}#ui-dialog-body ul.buttons{margin:0;padding:0;list-style:none}#ui-dialog-body ul.buttons li{display:inline-block;margin:0;padding:.4em .4em 0 0}#ui-dialog-body ul.buttons>li+li>button{margin-left:1em}#ui-dialog-close{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#ui-dialog-close{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}</style>\n<style id=\"style-ui\" type=\"text/css\">#ui-dialog-body.settings [id|=setting-body]>div:first-child{display:table;width:100%}#ui-dialog-body.settings [id|=setting-label]{display:table-cell;padding:.4em 2em .4em 0}#ui-dialog-body.settings [id|=setting-label]+div{display:table-cell;min-width:8em;text-align:right;vertical-align:middle;white-space:nowrap}#ui-dialog-body.list{padding:0}#ui-dialog-body.list ul{margin:0;padding:0;list-style:none;border:1px solid transparent}#ui-dialog-body.list li{margin:0}#ui-dialog-body.list li:not(:first-child){border-top:1px solid #444}#ui-dialog-body.list li a{display:block;padding:.25em .75em;border:1px solid transparent;color:#eee;text-decoration:none}#ui-dialog-body.list li a:hover{background-color:#333;border-color:#eee}#ui-dialog-body.saves{padding:0 0 1px}#ui-dialog-body.saves>:not(:first-child){border-top:1px solid #444}#ui-dialog-body.saves table{border-spacing:0;width:100%}#ui-dialog-body.saves tr:not(:first-child){border-top:1px solid #444}#ui-dialog-body.saves td{padding:.33em .33em}#ui-dialog-body.saves td:first-child{min-width:1.5em;text-align:center}#ui-dialog-body.saves td:nth-child(3){line-height:1.2}#ui-dialog-body.saves td:last-child{text-align:right}#ui-dialog-body.saves .empty{color:#999;speak:none;text-align:center;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#ui-dialog-body.saves .datestamp{font-size:75%;margin-left:1em}#ui-dialog-body.saves ul.buttons li{padding:.4em}#ui-dialog-body.saves ul.buttons>li+li>button{margin-left:.2em}#ui-dialog-body.saves ul.buttons li:last-child{float:right}#ui-dialog-body.settings div[id|=header-body]{margin:1em 0}#ui-dialog-body.settings div[id|=header-body]:first-child{margin-top:0}#ui-dialog-body.settings div[id|=header-body]:not(:first-child){border-top:1px solid #444;padding-top:1em}#ui-dialog-body.settings div[id|=header-body]>*{margin:0}#ui-dialog-body.settings h2[id|=header-heading]{font-size:1.375em}#ui-dialog-body.settings p[id|=header-desc],#ui-dialog-body.settings p[id|=setting-desc]{font-size:87.5%;margin:0 0 0 .5em}#ui-dialog-body.settings div[id|=setting-body]+div[id|=setting-body]{margin:1em 0}#ui-dialog-body.settings [id|=setting-control]{white-space:nowrap}#ui-dialog-body.settings button[id|=setting-control]{color:#eee;background-color:transparent;border:1px solid #444;padding:.4em}#ui-dialog-body.settings button[id|=setting-control]:hover{background-color:#333;border-color:#eee}#ui-dialog-body.settings button[id|=setting-control].enabled{background-color:#282;border-color:#4a4}#ui-dialog-body.settings button[id|=setting-control].enabled:hover{background-color:#4a4;border-color:#6c6}#ui-dialog-body.settings input[type=range][id|=setting-control]{max-width:35vw}#ui-dialog-body.list a,#ui-dialog-body.settings span[id|=setting-input]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#ui-dialog-body.saves button[id=saves-clear]:before,#ui-dialog-body.saves button[id=saves-export]:before,#ui-dialog-body.saves button[id=saves-import]:before,#ui-dialog-body.settings button[id|=setting-control].enabled:after,#ui-dialog-body.settings button[id|=setting-control]:after{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}#ui-dialog-body.saves button[id=saves-export]:before{content:\"\\e829\\00a0\"}#ui-dialog-body.saves button[id=saves-import]:before{content:\"\\e82a\\00a0\"}#ui-dialog-body.saves button[id=saves-clear]:before{content:\"\\e827\\00a0\"}#ui-dialog-body.settings button[id|=setting-control]:after{content:\"\\00a0\\00a0\\e830\"}#ui-dialog-body.settings button[id|=setting-control].enabled:after{content:\"\\00a0\\00a0\\e831\"}</style>\n<style id=\"style-ui-bar\" type=\"text/css\">#story{margin-left:20em;-o-transition:margin-left .2s ease-in;transition:margin-left .2s ease-in}#ui-bar.stowed~#story{margin-left:4.5em}@media screen and (max-width:1136px){#story{margin-left:19em}#ui-bar.stowed~#story{margin-left:3.5em}}@media screen and (max-width:768px){#story{margin-left:3.5em}}#ui-bar{position:fixed;z-index:50;top:0;left:0;width:17.5em;height:100%;margin:0;padding:0;-o-transition:left .2s ease-in;transition:left .2s ease-in}#ui-bar.stowed{left:-15.5em}#ui-bar-body{height:90%;height:calc(100% - 2.5em);margin:2.5em 0;padding:0 1.5em}#ui-bar.stowed #ui-bar-body,#ui-bar.stowed #ui-bar-history{visibility:hidden;-o-transition:visibility .2s step-end;transition:visibility .2s step-end}#ui-bar{background-color:#222;border-right:1px solid #444;text-align:center}#ui-bar-tray{position:absolute;top:.2em;left:0;right:0}#ui-bar a{text-decoration:none}#ui-bar hr{border-color:#444}#ui-bar-history [id|=history],#ui-bar-toggle{font-size:1.2em;line-height:inherit;color:#eee;background-color:transparent;border:1px solid #444}#ui-bar-toggle{display:block;position:absolute;top:0;right:0;border-right:none;padding:.3em .45em .25em}#ui-bar.stowed #ui-bar-toggle{padding:.3em .35em .25em .55em}#ui-bar-toggle:hover{background-color:#444;border-color:#eee}#ui-bar-history{margin:0 auto}#ui-bar-history [id|=history]{padding:.2em .45em .35em}#ui-bar-history #history-jumpto{padding:.2em .665em .35em}#ui-bar-history [id|=history]:not(:first-child){margin-left:1.2em}#ui-bar-history [id|=history]:hover{background-color:#444;border-color:#eee}#ui-bar-history [id|=history]:disabled{color:#444;background-color:transparent;border-color:#444}#ui-bar-body{line-height:1.5;overflow:auto}#ui-bar-body>:not(:first-child){margin-top:2em}#story-title{margin:0;font-size:162.5%}#story-author{margin-top:2em;font-weight:700}#menu ul{margin:1em 0 0;padding:0;list-style:none;border:1px solid #444}#menu ul:empty{display:none}#menu li{margin:0}#menu li:not(:first-child){border-top:1px solid #444}#menu li a{display:block;padding:.25em .75em;border:1px solid transparent;color:#eee;text-transform:uppercase}#menu li a:hover{background-color:#444;border-color:#eee}#menu a,#ui-bar-history [id|=history],#ui-bar-toggle{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#menu-core li[id|=menu-item] a:before,#ui-bar-history [id|=history],#ui-bar-toggle:before{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}#ui-bar-toggle:before{content:\"\\e81d\"}#ui-bar.stowed #ui-bar-toggle:before{content:\"\\e81e\"}#menu-item-saves a:before{content:\"\\e82b\\00a0\"}#menu-item-settings a:before{content:\"\\e82d\\00a0\"}#menu-item-restart a:before{content:\"\\e82c\\00a0\"}#menu-item-share a:before{content:\"\\e82f\\00a0\"}</style>\n<style id=\"style-ui-debug\" type=\"text/css\">#debug-bar{background-color:#222;border-left:1px solid #444;border-top:1px solid #444;bottom:0;margin:0;max-height:75%;padding:.5em;position:fixed;right:0;z-index:99900}#debug-bar>div:not([id])+div{margin-top:.5em}#debug-bar>div>label{margin-right:.5em}#debug-bar>div>input[type=text]{min-width:0;width:8em}#debug-bar>div>select{width:15em}#debug-bar-toggle{color:#eee;background-color:#222;border:1px solid #444;height:101%;height:calc(100% + 1px);left:-2em;left:calc(-2em - 1px);position:absolute;top:-1px;width:2em}#debug-bar-toggle:hover{background-color:#333;border-color:#eee}#debug-bar-hint{bottom:.175em;font-size:4.5em;opacity:.33;pointer-events:none;position:fixed;right:.6em;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;white-space:nowrap}#debug-bar-watch{background-color:#222;border-left:1px solid #444;border-top:1px solid #444;bottom:102%;bottom:calc(100% + 1px);font-size:.9em;left:-1px;max-height:650%;max-height:65vh;position:absolute;overflow-x:hidden;overflow-y:scroll;right:0;z-index:99800}#debug-bar-watch[hidden]{display:none}#debug-bar-watch div{color:#999;font-style:italic;margin:1em auto;text-align:center}#debug-bar-watch table{width:100%}#debug-bar-watch tr:nth-child(2n){background-color:rgba(127,127,127,.15)}#debug-bar-watch td{padding:.2em 0}#debug-bar-watch td:first-child+td{padding:.2em .3em .2em .1em}#debug-bar-watch .watch-delete{background-color:transparent;border:none;color:#c00}#debug-bar-watch-all,#debug-bar-watch-none{margin-left:.5em}#debug-bar-views-toggle,#debug-bar-watch-toggle{color:#eee;background-color:transparent;border:1px solid #444;margin-right:1em;padding:.4em}#debug-bar-views-toggle:hover,#debug-bar-watch-toggle:hover{background-color:#333;border-color:#eee}#debug-bar-watch:not([hidden])~div #debug-bar-watch-toggle,html[data-debug-view] #debug-bar-views-toggle{background-color:#282;border-color:#4a4}#debug-bar-watch:not([hidden])~div #debug-bar-watch-toggle:hover,html[data-debug-view] #debug-bar-views-toggle:hover{background-color:#4a4;border-color:#6c6}#debug-bar-hint:after,#debug-bar-toggle:before,#debug-bar-views-toggle:after,#debug-bar-watch .watch-delete:before,#debug-bar-watch-add:before,#debug-bar-watch-all:before,#debug-bar-watch-none:before,#debug-bar-watch-toggle:after{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}#debug-bar-toggle:before{content:\"\\e838\"}#debug-bar-hint:after{content:\"\\e838\\202f\\e822\"}#debug-bar-watch .watch-delete:before{content:\"\\e804\"}#debug-bar-watch-add:before{content:\"\\e805\"}#debug-bar-watch-all:before{content:\"\\e83a\"}#debug-bar-watch-none:before{content:\"\\e827\"}#debug-bar-views-toggle:after,#debug-bar-watch-toggle:after{content:\"\\00a0\\00a0\\e830\"}#debug-bar-watch:not([hidden])~div #debug-bar-watch-toggle:after,html[data-debug-view] #debug-bar-views-toggle:after{content:\"\\00a0\\00a0\\e831\"}html[data-debug-view] .debug{padding:.25em;background-color:#234}html[data-debug-view] .debug[title]{cursor:help}html[data-debug-view] .debug.block{display:inline-block;vertical-align:middle}html[data-debug-view] .debug.invalid{text-decoration:line-through}html[data-debug-view] .debug.hidden,html[data-debug-view] .debug.hidden .debug{background-color:#555}html:not([data-debug-view]) .debug.hidden{display:none}html[data-debug-view] .debug[data-name][data-type].nonvoid:after,html[data-debug-view] .debug[data-name][data-type]:before{background-color:rgba(0,0,0,.25);font-family:monospace,monospace;white-space:pre}html[data-debug-view] .debug[data-name][data-type]:before{content:attr(data-name)}html[data-debug-view] .debug[data-name][data-type|=macro]:before{content:\"<<\" attr(data-name) \">>\"}html[data-debug-view] .debug[data-name][data-type|=macro].nonvoid:after{content:\"<</\" attr(data-name) \">>\"}html[data-debug-view] .debug[data-name][data-type|=html]:before{content:\"<\" attr(data-name) \">\"}html[data-debug-view] .debug[data-name][data-type|=html].nonvoid:after{content:\"</\" attr(data-name) \">\"}html[data-debug-view] .debug[data-name][data-type]:not(:empty):before{margin-right:.25em}html[data-debug-view] .debug[data-name][data-type].nonvoid:not(:empty):after{margin-left:.25em}html[data-debug-view] .debug[data-name][data-type|=special],html[data-debug-view] .debug[data-name][data-type|=special]:before{display:block}</style>\n</head>\n<body>\n\t<div id=\"init-screen\">\n\t\t<div id=\"init-no-js\"><noscript>JavaScript is required. Please enable it to continue.</noscript></div>\n\t\t<div id=\"init-lacking\">Your browser lacks required capabilities. Please upgrade it or switch to another to continue.</div>\n\t\t<div id=\"init-loading\"><div>Loading&hellip;</div></div>\n\t</div>\n\t{{STORY_DATA}}\n\t<script id=\"script-sugarcube\" type=\"text/javascript\">\n\t/*! SugarCube JS */\n\tif(document.documentElement.getAttribute(\"data-init\")===\"loading\"){!function(window,document,jQuery,undefined){\"use strict\";function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError(\"Cannot call a class as a function\")}function _toConsumableArray(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t<e.length;t++)r[t]=e[t];return r}return Array.from(e)}var _createClass=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,\"value\"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),_slicedToArray=function(){function e(e,t){var r=[],n=!0,a=!1,i=undefined;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){a=!0,i=e}finally{try{!n&&s.return&&s.return()}finally{if(a)throw i}}return r}return function(t,r){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,r);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},errorPrologRegExp=/^(?:(?:uncaught\\s+(?:exception:\\s+)?)?\\w*(?:error|exception|_err):\\s+)+/i,Alert=function(){function e(e,t,r,n){var a=\"fatal\"===e,i=\"Apologies! \"+(a?\"A fatal\":\"An\")+\" error has occurred.\";i+=a?\" Aborting.\":\" You may be able to continue, but some parts may not work properly.\",null==t&&null==r||(i+=\"\\n\\nError\",null!=t&&(i+=\" [\"+t+\"]\"),i+=null!=r?\": \"+r.replace(errorPrologRegExp,\"\")+\".\":\": unknown error.\"),\"object\"===(void 0===n?\"undefined\":_typeof(n))&&n.stack&&(i+=\"\\n\\nStack Trace:\\n\"+n.stack),window.alert(i)}function t(t,r,n){e(null,t,r,n)}function r(t,r,n){e(\"fatal\",t,r,n)}return function(e){window.onerror=function(n,a,i,o,s){\"complete\"===document.readyState?t(null,n,s):(r(null,n,s),window.onerror=e,\"function\"==typeof window.onerror&&window.onerror.apply(this,arguments))}}(window.onerror),Object.freeze(Object.defineProperties({},{error:{value:t},fatal:{value:r}}))}(),Patterns=function(){var e=function(){var e=new Map([[\" \",\"\\\\u0020\"],[\"\\f\",\"\\\\f\"],[\"\\n\",\"\\\\n\"],[\"\\r\",\"\\\\r\"],[\"\\t\",\"\\\\t\"],[\"\\v\",\"\\\\v\"],[\" \",\"\\\\u00a0\"],[\" \",\"\\\\u1680\"],[\"᠎\",\"\\\\u180e\"],[\" \",\"\\\\u2000\"],[\" \",\"\\\\u2001\"],[\" \",\"\\\\u2002\"],[\" \",\"\\\\u2003\"],[\" \",\"\\\\u2004\"],[\" \",\"\\\\u2005\"],[\" \",\"\\\\u2006\"],[\" \",\"\\\\u2007\"],[\" \",\"\\\\u2008\"],[\" \",\"\\\\u2009\"],[\" \",\"\\\\u200a\"],[\"\\u2028\",\"\\\\u2028\"],[\"\\u2029\",\"\\\\u2029\"],[\" \",\"\\\\u202f\"],[\" \",\"\\\\u205f\"],[\" \",\"\\\\u3000\"],[\"\\ufeff\",\"\\\\ufeff\"]]),t=/^\\s$/,r=\"\";return e.forEach(function(e,n){t.test(n)||(r+=e)}),r?\"[\\\\s\"+r+\"]\":\"\\\\s\"}(),t=\"\\\\s\"===e?\"\\\\S\":e.replace(/^\\[/,\"[^\"),r=\"[0-9A-Z_a-z\\\\-\\\\u00c0-\\\\u00d6\\\\u00d8-\\\\u00f6\\\\u00f8-\\\\u00ff\\\\u0150\\\\u0170\\\\u0151\\\\u0171]\",n=r.replace(\"\\\\-\",\"\"),a=function(){return\"(\"+r+\"+)\\\\(([^\\\\)\\\\|\\\\n]+)\\\\):|(\"+r+\"+):([^;\\\\|\\\\n]+);|((?:\\\\.\"+r+\"+)+);|((?:#\"+r+\"+)+);\"}();return Object.freeze({space:e,spaceNoTerminator:\"[\\\\u0020\\\\f\\\\t\\\\v\\\\u00a0\\\\u1680\\\\u180e\\\\u2000-\\\\u200a\\\\u202f\\\\u205f\\\\u3000\\\\ufeff]\",lineTerminator:\"[\\\\n\\\\r\\\\u2028\\\\u2029]\",notSpace:t,anyChar:\"(?:.|[\\\\n\\\\r\\\\u2028\\\\u2029])\",anyLetter:r,anyLetterStrict:n,identifierFirstChar:\"[$A-Z_a-z]\",identifierNextChar:\"[$0-9A-Z_a-z]\",identifier:\"[$A-Z_a-z][$0-9A-Z_a-z]*\",variableSigil:\"[$_]\",variable:\"[$_][$A-Z_a-z][$0-9A-Z_a-z]*\",macroName:\"[A-Za-z][\\\\w-]*|[=-]\",templateName:\"[A-Za-z][\\\\w-]*\",cssImage:\"\\\\[[<>]?[Ii][Mm][Gg]\\\\[(?:\\\\s|\\\\S)*?\\\\]\\\\]+\",inlineCss:a,url:\"(?:file|https?|mailto|ftp|javascript|irc|news|data):[^\\\\s'\\\"]+\"})}();!function(){!function(e){if(e&&e.prototype&&null==e.prototype.firstElementChild){var t=Node.ELEMENT_NODE;Object.defineProperty(e.prototype,\"firstElementChild\",{get:function(){for(var e=this.childNodes,r=0;r<e.length;++r){var n=e[r];if(n.nodeType===t)return n}return null}})}}(window.Node||window.Element)}(),function(){function e(e,t){var r=Number.parseInt(e,10)||0;if(r<1)return\"\";var n=void 0===t?\"\":String(t);for(\"\"===n&&(n=\" \");n.length<r;){var a=n.length,i=r-a;n+=a>i?n.slice(0,i):n}return n.length>r&&(n=n.slice(0,r)),n}var t=function(){function e(e,n){var a=String(e);if(!a)return a;switch(n){case\"start\":return t.test(a)?a.replace(t,\"\"):a;case\"end\":return r.test(a)?a.replace(r,\"\"):a;default:throw new Error('_trimString called with incorrect where parameter value: \"'+n+'\"')}}var t=new RegExp(\"^\"+Patterns.space+Patterns.space+\"*\"),r=new RegExp(\"\"+Patterns.space+Patterns.space+\"*$\");return e}();Array.prototype.flat||Object.defineProperty(Array.prototype,\"flat\",{configurable:!0,writable:!0,value:function(){function e(){if(null==this)throw new TypeError(\"Array.prototype.flat called on null or undefined\");var t=0===arguments.length?1:Number(arguments[0])||0;return t<1?Array.prototype.slice.call(this):Array.prototype.reduce.call(this,function(r,n){return n instanceof Array?r.push.apply(r,_toConsumableArray(e.call(n,t-1))):r.push(n),r},[])}return e}()}),Array.prototype.flatMap||Object.defineProperty(Array.prototype,\"flatMap\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.flatMap called on null or undefined\");return Array.prototype.map.apply(this,arguments).flat()}}),Array.prototype.includes||Object.defineProperty(Array.prototype,\"includes\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.includes called on null or undefined\");if(0===arguments.length)return!1;var e=this.length>>>0;if(0===e)return!1;var t=arguments[0],r=Number(arguments[1])||0;for(r<0&&(r=Math.max(0,e+r));r<e;++r){var n=this[r];if(n===t||n!==n&&t!==t)return!0}return!1}}),Object.entries||Object.defineProperty(Object,\"entries\",{configurable:!0,writable:!0,value:function(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e))||null===e)throw new TypeError(\"Object.entries object parameter must be an object\");return Object.keys(e).map(function(t){return[t,e[t]]})}}),Object.fromEntries||Object.defineProperty(Object,\"fromEntries\",{configurable:!0,writable:!0,value:function(e){return Array.from(e).reduce(function(e,t){if(Object(t)!==t)throw new TypeError(\"Object.fromEntries iterable parameter must yield objects\");return t[0]in e?Object.defineProperty(e,t[0],{configurable:!0,enumerable:!0,writable:!0,value:t[1]}):e[t[0]]=t[1],e},{})}}),Object.getOwnPropertyDescriptors||Object.defineProperty(Object,\"getOwnPropertyDescriptors\",{configurable:!0,writable:!0,value:function(e){if(null==e)throw new TypeError(\"Object.getOwnPropertyDescriptors object parameter is null or undefined\");var t=Object(e);return Reflect.ownKeys(t).reduce(function(e,r){var n=Object.getOwnPropertyDescriptor(t,r);return void 0!==n&&(r in e?Object.defineProperty(e,r,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[r]=n),e},{})}}),Object.values||Object.defineProperty(Object,\"values\",{configurable:!0,writable:!0,value:function(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e))||null===e)throw new TypeError(\"Object.values object parameter must be an object\");return Object.keys(e).map(function(t){return e[t]})}}),String.prototype.padStart||Object.defineProperty(String.prototype,\"padStart\",{configurable:!0,writable:!0,value:function(t,r){if(null==this)throw new TypeError(\"String.prototype.padStart called on null or undefined\");var n=String(this),a=n.length,i=Number.parseInt(t,10);return i<=a?n:e(i-a,r)+n}}),String.prototype.padEnd||Object.defineProperty(String.prototype,\"padEnd\",{configurable:!0,writable:!0,value:function(t,r){if(null==this)throw new TypeError(\"String.prototype.padEnd called on null or undefined\");var n=String(this),a=n.length,i=Number.parseInt(t,10);return i<=a?n:n+e(i-a,r)}}),String.prototype.trimStart||Object.defineProperty(String.prototype,\"trimStart\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimStart called on null or undefined\");return t(this,\"start\")}}),String.prototype.trimLeft||Object.defineProperty(String.prototype,\"trimLeft\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimLeft called on null or undefined\");return t(this,\"start\")}}),String.prototype.trimEnd||Object.defineProperty(String.prototype,\"trimEnd\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimEnd called on null or undefined\");return t(this,\"end\")}}),String.prototype.trimRight||Object.defineProperty(String.prototype,\"trimRight\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimRight called on null or undefined\");return t(this,\"end\")}})}(),function(){function _random(){var e=void 0,t=void 0;switch(arguments.length){case 0:throw new Error(\"_random called with insufficient parameters\");case 1:e=0,t=arguments[0];break;default:e=arguments[0],t=arguments[1]}if(e>t){var r=[t,e];e=r[0],t=r[1]}return Math.floor(_nativeMathRandom()*(t-e+1))+e}function _randomIndex(e,t){var r=void 0,n=void 0;switch(t.length){case 1:r=0,n=e-1;break;case 2:r=0,n=Math.trunc(t[1]);break;default:r=Math.trunc(t[1]),n=Math.trunc(t[2])}return Number.isNaN(r)?r=0:!Number.isFinite(r)||r>=e?r=e-1:r<0&&(r=e+r)<0&&(r=0),Number.isNaN(n)?n=0:!Number.isFinite(n)||n>=e?n=e-1:n<0&&(n=e+n)<0&&(n=e-1),_random(r,n)}function _getCodePointStartAndEnd(e,t){var r=e.charCodeAt(t);if(Number.isNaN(r))return{char:\"\",start:-1,end:-1};if(r<55296||r>57343)return{char:e.charAt(t),start:t,end:t};if(r>=55296&&r<=56319){var n=t+1;if(n>=e.length)throw new Error(\"high surrogate without trailing low surrogate\");var a=e.charCodeAt(n);if(a<56320||a>57343)throw new Error(\"high surrogate without trailing low surrogate\");return{char:e.charAt(t)+e.charAt(n),start:t,end:n}}if(0===t)throw new Error(\"low surrogate without leading high surrogate\");var i=t-1,o=e.charCodeAt(i);if(o<55296||o>56319)throw new Error(\"low surrogate without leading high surrogate\");return{char:e.charAt(i)+e.charAt(t),start:i,end:t}}var _nativeMathRandom=Math.random;Object.defineProperty(Array,\"random\",{configurable:!0,writable:!0,value:function(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e))||null===e||!Object.prototype.hasOwnProperty.call(e,\"length\"))throw new TypeError(\"Array.random array parameter must be an array or array-lke object\");var t=e.length>>>0;if(0!==t){return e[0===arguments.length?_random(0,t-1):_randomIndex(t,Array.prototype.slice.call(arguments,1))]}}}),Object.defineProperty(Array.prototype,\"concatUnique\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.concatUnique called on null or undefined\");var e=Array.from(this);if(0===arguments.length)return e;var t=Array.prototype.reduce.call(arguments,function(e,t){return e.concat(t)},[]),r=t.length;if(0===r)return e;for(var n=Array.prototype.indexOf,a=Array.prototype.push,i=0;i<r;++i){var o=t[i];-1===n.call(e,o)&&a.call(e,o)}return e}}),Object.defineProperty(Array.prototype,\"count\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.count called on null or undefined\");for(var e=Array.prototype.indexOf,t=arguments[0],r=Number(arguments[1])||0,n=0;-1!==(r=e.call(this,t,r));)++n,++r;return n}}),Object.defineProperty(Array.prototype,\"delete\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.delete called on null or undefined\");if(0===arguments.length)return[];var e=this.length>>>0;if(0===e)return[];for(var t=Array.prototype.concat.apply([],arguments),r=t.length,n=[],a=0;a<e;++a)for(var i=this[a],o=0;o<r;++o){var s=t[o];if(i===s||i!==i&&s!==s){n.push(a);break}}for(var u=[],l=0,c=n.length;l<c;++l)u[l]=this[n[l]];for(var d=Array.prototype.splice,f=n.length-1;f>=0;--f)d.call(this,n[f],1);return u}}),Object.defineProperty(Array.prototype,\"deleteAt\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.deleteAt called on null or undefined\");if(0===arguments.length)return[];var e=this.length>>>0;if(0===e)return[];for(var t=Array.prototype.splice,r=[].concat(_toConsumableArray(new Set(Array.prototype.concat.apply([],arguments).map(function(t){return t<0?Math.max(0,e+t):t})).values())),n=[].concat(_toConsumableArray(r)).sort(function(e,t){return t-e}),a=[],i=0,o=r.length;i<o;++i)a[i]=this[r[i]];for(var s=0,u=n.length;s<u;++s)t.call(this,n[s],1);return a}}),Object.defineProperty(Array.prototype,\"deleteWith\",{configurable:!0,writable:!0,value:function(e,t){if(null==this)throw new TypeError(\"Array.prototype.deleteWith called on null or undefined\");if(\"function\"!=typeof e)throw new Error(\"Array.prototype.deleteWith predicate parameter must be a function\");var r=this.length>>>0;if(0===r)return[];for(var n=Array.prototype.splice,a=[],i=[],o=0;o<r;++o)e.call(t,this[o],o,this)&&(i.push(this[o]),a.push(o));for(var s=a.length-1;s>=0;--s)n.call(this,a[s],1);return i}}),Object.defineProperty(Array.prototype,\"first\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.first called on null or undefined\");if(0!=this.length>>>0)return this[0]}}),Object.defineProperty(Array.prototype,\"includesAll\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.includesAll called on null or undefined\");if(1===arguments.length)return Array.isArray(arguments[0])?Array.prototype.includesAll.apply(this,arguments[0]):Array.prototype.includes.apply(this,arguments);for(var e=0,t=arguments.length;e<t;++e)if(!Array.prototype.some.call(this,function(e){return e===this.val||e!==e&&this.val!==this.val},{val:arguments[e]}))return!1;return!0}}),Object.defineProperty(Array.prototype,\"includesAny\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.includesAny called on null or undefined\");if(1===arguments.length)return Array.isArray(arguments[0])?Array.prototype.includesAny.apply(this,arguments[0]):Array.prototype.includes.apply(this,arguments);for(var e=0,t=arguments.length;e<t;++e)if(Array.prototype.some.call(this,function(e){return e===this.val||e!==e&&this.val!==this.val},{val:arguments[e]}))return!0;return!1}}),Object.defineProperty(Array.prototype,\"last\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.last called on null or undefined\");var e=this.length>>>0;if(0!==e)return this[e-1]}}),Object.defineProperty(Array.prototype,\"pluck\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.pluck called on null or undefined\");var e=this.length>>>0;if(0!==e){var t=0===arguments.length?_random(0,e-1):_randomIndex(e,[].concat(Array.prototype.slice.call(arguments)));return Array.prototype.splice.call(this,t,1)[0]}}}),Object.defineProperty(Array.prototype,\"pluckMany\",{configurable:!0,writable:!0,value:function(e){if(null==this)throw new TypeError(\"Array.prototype.pluckMany called on null or undefined\");var t=this.length>>>0;if(0===t)return[];var r=Math.trunc(e);if(!Number.isInteger(r))throw new Error(\"Array.prototype.pluckMany want parameter must be an integer\");if(r<1)return[];r>t&&(r=t);var n=Array.prototype.splice,a=[],i=t-1;do{a.push(n.call(this,_random(0,i--),1)[0])}while(a.length<r);return a}}),Object.defineProperty(Array.prototype,\"pushUnique\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.pushUnique called on null or undefined\");var e=arguments.length;if(0===e)return this.length>>>0;for(var t=Array.prototype.indexOf,r=Array.prototype.push,n=0;n<e;++n){var a=arguments[n];-1===t.call(this,a)&&r.call(this,a)}return this.length>>>0}}),Object.defineProperty(Array.prototype,\"random\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.random called on null or undefined\");var e=this.length>>>0;if(0!==e){return this[0===arguments.length?_random(0,e-1):_randomIndex(e,[].concat(Array.prototype.slice.call(arguments)))]}}}),Object.defineProperty(Array.prototype,\"randomMany\",{configurable:!0,writable:!0,value:function(e){if(null==this)throw new TypeError(\"Array.prototype.randomMany called on null or undefined\");var t=this.length>>>0;if(0===t)return[];var r=Math.trunc(e);if(!Number.isInteger(r))throw new Error(\"Array.prototype.randomMany want parameter must be an integer\");if(r<1)return[];r>t&&(r=t);var n=new Map,a=[],i=t-1;do{var o=void 0;do{o=_random(0,i)}while(n.has(o));n.set(o,!0),a.push(this[o])}while(a.length<r);return a}}),Object.defineProperty(Array.prototype,\"shuffle\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.shuffle called on null or undefined\");var e=this.length>>>0;if(0===e)return this;for(var t=e-1;t>0;--t){var r=Math.floor(_nativeMathRandom()*(t+1));if(t!==r){var n=this[t];this[t]=this[r],this[r]=n}}return this}}),Object.defineProperty(Array.prototype,\"unshiftUnique\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.unshiftUnique called on null or undefined\");var e=arguments.length;if(0===e)return this.length>>>0;for(var t=Array.prototype.indexOf,r=Array.prototype.unshift,n=0;n<e;++n){var a=arguments[n];-1===t.call(this,a)&&r.call(this,a)}return this.length>>>0}}),Object.defineProperty(Function.prototype,\"partial\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Function.prototype.partial called on null or undefined\");var e=Array.prototype.slice,t=this,r=e.call(arguments,0);return function(){for(var n=[],a=0,i=0;i<r.length;++i)n.push(r[i]===undefined?arguments[a++]:r[i]);return t.apply(this,n.concat(e.call(arguments,a)))}}}),Object.defineProperty(Math,\"clamp\",{configurable:!0,writable:!0,value:function(e,t,r){var n=Number(e);return Number.isNaN(n)?NaN:n.clamp(t,r)}}),Object.defineProperty(Math,\"easeInOut\",{configurable:!0,writable:!0,value:function(e){return 1-(Math.cos(Number(e)*Math.PI)+1)/2}}),Object.defineProperty(Number.prototype,\"clamp\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Number.prototype.clamp called on null or undefined\");if(2!==arguments.length)throw new Error(\"Number.prototype.clamp called with an incorrect number of parameters\");var e=Number(arguments[0]),t=Number(arguments[1]);if(e>t){var r=[t,e];e=r[0],t=r[1]}return Math.min(Math.max(this,e),t)}}),RegExp.escape||function(){var e=/[\\\\^$*+?.()|[\\]{}]/g,t=new RegExp(e.source);Object.defineProperty(RegExp,\"escape\",{configurable:!0,writable:!0,value:function(r){var n=String(r);return n&&t.test(n)?n.replace(e,\"\\\\$&\"):n}})}(),function(){var e=/{(\\d+)(?:,([+-]?\\d+))?}/g,t=new RegExp(e.source);Object.defineProperty(String,\"format\",{configurable:!0,writable:!0,value:function(r){function n(e,t,r){if(!t)return e;var n=Math.abs(t)-e.length;if(n<1)return e;var a=String(r).repeat(n);return t<0?e+a:a+e}if(arguments.length<2)return 0===arguments.length?\"\":r;var a=2===arguments.length&&Array.isArray(arguments[1])?[].concat(_toConsumableArray(arguments[1])):Array.prototype.slice.call(arguments,1);return 0===a.length?r:t.test(r)?(e.lastIndex=0,r.replace(e,function(e,t,r){var i=a[t];if(null==i)return\"\";for(;\"function\"==typeof i;)i=i();switch(void 0===i?\"undefined\":_typeof(i)){case\"string\":break;case\"object\":i=JSON.stringify(i);break;default:i=String(i)}return n(i,r?Number.parseInt(r,10):0,\" \")})):r}})}(),Object.defineProperty(String.prototype,\"contains\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.contains called on null or undefined\");return-1!==String.prototype.indexOf.apply(this,arguments)}}),Object.defineProperty(String.prototype,\"count\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.count called on null or undefined\");var e=String(arguments[0]||\"\");if(\"\"===e)return 0;for(var t=String.prototype.indexOf,r=e.length,n=Number(arguments[1])||0,a=0;-1!==(n=t.call(this,e,n));)++a,n+=r;return a}}),Object.defineProperty(String.prototype,\"first\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.first called on null or undefined\");return _getCodePointStartAndEnd(String(this),0).char}}),Object.defineProperty(String.prototype,\"last\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.last called on null or undefined\");var e=String(this);return _getCodePointStartAndEnd(e,e.length-1).char}}),Object.defineProperty(String.prototype,\"splice\",{configurable:!0,writable:!0,value:function(e,t,r){if(null==this)throw new TypeError(\"String.prototype.splice called on null or undefined\");var n=this.length>>>0;if(0===n)return\"\";var a=Number(e);Number.isSafeInteger(a)?a<0&&(a+=n)<0&&(a=0):a=0,a>n&&(a=n);var i=Number(t);(!Number.isSafeInteger(i)||i<0)&&(i=0);var o=this.slice(0,a);return void 0!==r&&(o+=r),a+i<n&&(o+=this.slice(a+i)),o}}),Object.defineProperty(String.prototype,\"splitOrEmpty\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.splitOrEmpty called on null or undefined\");return\"\"===String(this)?[]:String.prototype.split.apply(this,arguments)}}),Object.defineProperty(String.prototype,\"toLocaleUpperFirst\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.toLocaleUpperFirst called on null or undefined\");var e=String(this),t=_getCodePointStartAndEnd(e,0),r=t.char,n=t.end;return-1===n?\"\":r.toLocaleUpperCase()+e.slice(n+1)}}),Object.defineProperty(String.prototype,\"toUpperFirst\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.toUpperFirst called on null or undefined\");var e=String(this),t=_getCodePointStartAndEnd(e,0),r=t.char,n=t.end;return-1===n?\"\":r.toUpperCase()+e.slice(n+1)}}),Object.defineProperty(Date.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:date)\",this.toISOString()]}}),Object.defineProperty(Function.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:eval)\",\"(\"+this.toString()+\")\"]}}),Object.defineProperty(Map.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:map)\",[].concat(_toConsumableArray(this))]}}),Object.defineProperty(RegExp.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:eval)\",this.toString()]}}),Object.defineProperty(Set.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:set)\",[].concat(_toConsumableArray(this))]}}),Object.defineProperty(JSON,\"reviveWrapper\",{configurable:!0,writable:!0,value:function(e,t){if(\"string\"!=typeof e)throw new TypeError(\"JSON.reviveWrapper code parameter must be a string\");return[\"(revive:eval)\",[e,t]]}}),Object.defineProperty(JSON,\"_real_parse\",{value:JSON.parse}),Object.defineProperty(JSON,\"parse\",{configurable:!0,writable:!0,value:function value(text,reviver){return JSON._real_parse(text,function(key,val){var value=val;if(Array.isArray(value)&&2===value.length)switch(value[0]){case\"(revive:set)\":value=new Set(value[1]);break;case\"(revive:map)\":value=new Map(value[1]);break;case\"(revive:date)\":value=new Date(value[1]);break;case\"(revive:eval)\":try{if(Array.isArray(value[1])){var $ReviveData$=value[1][1];value=eval(value[1][0])}else value=eval(value[1])}catch(e){}}else if(\"string\"==typeof value&&\"@@revive@@\"===value.slice(0,10))try{value=eval(value.slice(10))}catch(e){}if(\"function\"==typeof reviver)try{value=reviver(key,value)}catch(e){}return value})}}),Object.defineProperty(Array.prototype,\"contains\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.contains called on null or undefined\");return Array.prototype.includes.apply(this,arguments)}}),Object.defineProperty(Array.prototype,\"containsAll\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.containsAll called on null or undefined\");return Array.prototype.includesAll.apply(this,arguments)}}),Object.defineProperty(Array.prototype,\"containsAny\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.containsAny called on null or undefined\");return Array.prototype.includesAny.apply(this,arguments)}}),Object.defineProperty(Array.prototype,\"flatten\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.flatten called on null or undefined\");return Array.prototype.flat.call(this,1/0)}}),Object.defineProperty(String.prototype,\"readBracketedList\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.readBracketedList called on null or undefined\");for(var e=new RegExp(\"(?:\\\\[\\\\[((?:\\\\s|\\\\S)*?)\\\\]\\\\])|([^\\\"'\\\\s]\\\\S*)\",\"gm\"),t=[],r=void 0;null!==(r=e.exec(this));)r[1]?t.push(r[1]):r[2]&&t.push(r[2]);return t}})}();var Browser=function(){var e=navigator.userAgent.toLowerCase(),t=e.includes(\"windows phone\"),r=Object.freeze({Android:!t&&e.includes(\"android\"),BlackBerry:/blackberry|bb10/.test(e),iOS:!t&&/ip(?:hone|ad|od)/.test(e),Windows:t||e.includes(\"iemobile\"),any:function(){return r.Android||r.BlackBerry||r.iOS||r.Windows}}),n=!r.Windows&&!/khtml|trident|edge/.test(e)&&e.includes(\"gecko\"),a=!e.includes(\"opera\")&&/msie|trident/.test(e),i=a?function(){var t=/(?:msie\\s+|rv:)(\\d+\\.\\d)/.exec(e);return t?Number(t[1]):0}():null,o=e.includes(\"opera\")||e.includes(\" opr/\"),s=o?function(){var t=new RegExp((/khtml|chrome/.test(e)?\"opr\":\"version\")+\"\\\\/(\\\\d+\\\\.\\\\d+)\"),r=t.exec(e);return r?Number(r[1]):0}():null,u=e.includes(\"vivaldi\");return Object.freeze({userAgent:e,isMobile:r,isGecko:n,isIE:a,ieVersion:i,isOpera:o,operaVersion:s,isVivaldi:u})}(),Has=function(){var e=function(){try{return\"function\"==typeof document.createElement(\"audio\").canPlayType}catch(e){}return!1}(),t=e&&function(){try{var e=document.createElement(\"audio\").play();return e.catch(function(){}),e instanceof Promise}catch(e){}return!1}(),r=function(){try{return\"Blob\"in window&&\"File\"in window&&\"FileList\"in window&&\"FileReader\"in window&&!Browser.isMobile.any()&&(!Browser.isOpera||Browser.operaVersion>=15)}catch(e){}return!1}(),n=function(){try{return\"geolocation\"in navigator&&\"function\"==typeof navigator.geolocation.getCurrentPosition&&\"function\"==typeof navigator.geolocation.watchPosition}catch(e){}return!1}(),a=function(){try{return\"MutationObserver\"in window&&\"function\"==typeof window.MutationObserver}catch(e){}return!1}(),i=function(){try{return\"performance\"in window&&\"function\"==typeof window.performance.now}catch(e){}return!1}(),o=function(){try{for(var e=new Map([[\"transition\",\"transitionend\"],[\"MSTransition\",\"msTransitionEnd\"],[\"WebkitTransition\",\"webkitTransitionEnd\"],[\"MozTransition\",\"transitionend\"]]),t=[].concat(_toConsumableArray(e.keys())),r=document.createElement(\"div\"),n=0;n<t.length;++n)if(r.style[t[n]]!==undefined)return e.get(t[n])}catch(e){}return!1}();return Object.freeze({audio:e,audioPromise:t,fileAPI:r,geolocation:n,mutationObserver:a,performance:i,transitionEndEvent:o})}(),Visibility=function(){function e(){return Boolean(r&&document[r.hiddenProperty])}function t(){return r&&document[r.stateProperty]||\"visible\"}var r=function(){try{return Object.freeze([{hiddenProperty:\"hidden\",stateProperty:\"visibilityState\",changeEvent:\"visibilitychange\"},{hiddenProperty:\"webkitHidden\",stateProperty:\"webkitVisibilityState\",changeEvent:\"webkitvisibilitychange\"},{hiddenProperty:\"mozHidden\",stateProperty:\"mozVisibilityState\",changeEvent:\"mozvisibilitychange\"},{hiddenProperty:\"msHidden\",stateProperty:\"msVisibilityState\",changeEvent:\"msvisibilitychange\"}].find(function(e){return e.hiddenProperty in document}))}catch(e){}return null}();return Object.freeze(Object.defineProperties({},{isHidden:{value:e},state:{value:t},hiddenProperty:{value:r.hiddenProperty},stateProperty:{value:r.stateProperty},changeEvent:{value:r.changeEvent}}))}(),_ref3=function(){function e(t){if(\"object\"!==(void 0===t?\"undefined\":_typeof(t))||null===t)return t;if(t instanceof String)return String(t);if(t instanceof Number)return Number(t);if(t instanceof Boolean)return Boolean(t);if(\"function\"==typeof t.clone)return t.clone(!0);if(t.nodeType&&\"function\"==typeof t.cloneNode)return t.cloneNode(!0);var r=void 0;return t instanceof Array?r=new Array(t.length):t instanceof Date?r=new Date(t.getTime()):t instanceof Map?(r=new Map,t.forEach(function(t,n){return r.set(n,e(t))})):t instanceof RegExp?r=new RegExp(t):t instanceof Set?(r=new Set,t.forEach(function(t){return r.add(e(t))})):r=Object.create(Object.getPrototypeOf(t)),Object.keys(t).forEach(function(n){return r[n]=e(t[n])}),r}function t(e){for(var t=document.createDocumentFragment(),r=document.createElement(\"p\"),n=void 0;null!==(n=e.firstChild);){if(n.nodeType===Node.ELEMENT_NODE){switch(n.nodeName.toUpperCase()){case\"BR\":if(null!==n.nextSibling&&n.nextSibling.nodeType===Node.ELEMENT_NODE&&\"BR\"===n.nextSibling.nodeName.toUpperCase()){e.removeChild(n.nextSibling),e.removeChild(n),t.appendChild(r),r=document.createElement(\"p\");continue}if(!r.hasChildNodes()){e.removeChild(n);continue}break;case\"ADDRESS\":case\"ARTICLE\":case\"ASIDE\":case\"BLOCKQUOTE\":case\"CENTER\":case\"DIV\":case\"DL\":case\"FIGURE\":case\"FOOTER\":case\"FORM\":case\"H1\":case\"H2\":case\"H3\":case\"H4\":case\"H5\":case\"H6\":case\"HEADER\":case\"HR\":case\"MAIN\":case\"NAV\":case\"OL\":case\"P\":case\"PRE\":case\"SECTION\":case\"TABLE\":case\"UL\":r.hasChildNodes()&&(t.appendChild(r),r=document.createElement(\"p\")),t.appendChild(n);continue}}r.appendChild(n)}r.hasChildNodes()&&t.appendChild(r),e.appendChild(t)}function r(){try{return document.activeElement||null}catch(e){return null}}function n(e,t,r){var n=\"object\"===(void 0===e?\"undefined\":_typeof(e))?e:document.getElementById(e);if(null==n)return null;var a=Array.isArray(t)?t:[t];jQuery(n).empty();for(var i=0,o=a.length;i<o;++i)if(Story.has(a[i]))return new Wikifier(n,Story.get(a[i]).processText().trim()),n;if(null!=r){var s=String(r).trim();\"\"!==s&&new Wikifier(n,s)}return n}function a(e,t,r){var n=jQuery(document.createElement(\"div\")),a=jQuery(document.createElement(\"button\")),i=jQuery(document.createElement(\"pre\")),o=L10n.get(\"errorTitle\")+\": \"+(t||\"unknown error\");return a.addClass(\"error-toggle\").ariaClick({label:L10n.get(\"errorToggle\")},function(){a.hasClass(\"enabled\")?(a.removeClass(\"enabled\"),i.attr({\"aria-hidden\":!0,hidden:\"hidden\"})):(a.addClass(\"enabled\"),i.removeAttr(\"aria-hidden hidden\"))}).appendTo(n),jQuery(document.createElement(\"span\")).addClass(\"error\").text(o).appendTo(n),jQuery(document.createElement(\"code\")).text(r).appendTo(i),i.addClass(\"error-source\").attr({\"aria-hidden\":!0,hidden:\"hidden\"}).appendTo(n),n.addClass(\"error-view\").appendTo(e),console.warn(o+\"\\n\\t\"+r.replace(/\\n/g,\"\\n\\t\")),!1}function i(e,t){var r=i;switch(void 0===e?\"undefined\":_typeof(e)){case\"number\":if(Number.isNaN(e))return t;break;case\"object\":if(null===e)return t;if(Array.isArray(e))return e.map(function(e){return r(e,t)}).join(\", \");if(e instanceof Set)return[].concat(_toConsumableArray(e)).map(function(e){return r(e,t)}).join(\", \");if(e instanceof Map){return\"{ \"+[].concat(_toConsumableArray(e)).map(function(e){var n=_slicedToArray(e,2),a=n[0],i=n[1];return r(a,t)+\" → \"+r(i,t)}).join(\", \")+\" }\"}return e instanceof Date?e.toLocaleString():\"function\"==typeof e.toString?e.toString():Object.prototype.toString.call(e);case\"function\":case\"undefined\":return t}return String(e)}return Object.freeze(Object.defineProperties({},{clone:{value:e},convertBreaks:{value:t},safeActiveElement:{value:r},setPageElement:{value:n},throwError:{value:a},toStringOrDefault:{value:i}}))}(),clone=_ref3.clone,convertBreaks=_ref3.convertBreaks,safeActiveElement=_ref3.safeActiveElement,setPageElement=_ref3.setPageElement,throwError=_ref3.throwError,toStringOrDefault=_ref3.toStringOrDefault;!function(){function e(e){13!==e.which&&32!==e.which||(e.preventDefault(),jQuery(safeActiveElement()||this).trigger(\"click\"))}function t(e){return function(){\nvar t=jQuery(this),r=t.attr(\"data-passage\"),n=window&&window.SugarCube&&window.SugarCube.State&&window.SugarCube.State.passage,a=window.pageYOffset;t.is(\"[aria-pressed]\")&&t.attr(\"aria-pressed\",\"true\"===t.attr(\"aria-pressed\")?\"false\":\"true\"),e.apply(this,arguments);!r||window.lastDataPassageLink!==r&&n!==r||function(){window.scrollTo(0,a)}(),window.lastDataPassageLink=r}}function r(e){return t(function(){jQuery(this).off(\".aria-clickable\").removeAttr(\"tabindex aria-controls aria-pressed\").not(\"a,button\").removeAttr(\"role\").end().filter(\"button\").prop(\"disabled\",!0),e.apply(this,arguments)})}jQuery.fn.extend({ariaClick:function(n,a){if(0===this.length||0===arguments.length)return this;var i=n,o=a;return null==o&&(o=i,i=undefined),i=jQuery.extend({namespace:undefined,one:!1,selector:undefined,data:undefined,controls:undefined,pressed:undefined,label:undefined},i),\"string\"!=typeof i.namespace?i.namespace=\"\":\".\"!==i.namespace[0]&&(i.namespace=\".\"+i.namespace),\"boolean\"==typeof i.pressed&&(i.pressed=i.pressed?\"true\":\"false\"),this.filter(\"button\").prop(\"type\",\"button\"),this.not(\"a,button\").attr(\"role\",\"button\"),this.attr(\"tabindex\",0),null!=i.controls&&this.attr(\"aria-controls\",i.controls),null!=i.pressed&&this.attr(\"aria-pressed\",i.pressed),null!=i.label&&this.attr({\"aria-label\":i.label,title:i.label}),this.not(\"button\").on(\"keypress.aria-clickable\"+i.namespace,i.selector,e),this.on(\"click.aria-clickable\"+i.namespace,i.selector,i.data,i.one?r(o):t(o)),this},ariaDisabled:function(e){if(0===this.length||0===arguments.length)return this;var t=this.not(\"button,fieldset,input,menuitem,optgroup,option,select,textarea\"),r=this.filter(\"button,fieldset,input,menuitem,optgroup,option,select,textarea\");return e?(t.each(function(){this.setAttribute(\"disabled\",\"\"),this.setAttribute(\"aria-disabled\",\"\")}),r.each(function(){this.disabled=!0,this.setAttribute(\"aria-disabled\",\"\")})):(t.each(function(){this.removeAttribute(\"disabled\"),this.removeAttribute(\"aria-disabled\")}),r.each(function(){this.disabled=!1,this.removeAttribute(\"aria-disabled\")})),this},ariaIsDisabled:function(){return this.is(\"[disabled]\")}})}(),function(){jQuery.extend({wikiWithOptions:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(0!==r.length){var a=document.createDocumentFragment();r.forEach(function(t){return new Wikifier(a,t,e)});var i=[].concat(_toConsumableArray(a.querySelectorAll(\".error\"))).map(function(e){return e.textContent.replace(errorPrologRegExp,\"\")});if(i.length>0)throw new Error(i.join(\"; \"))}},wiki:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];this.wikiWithOptions.apply(this,[undefined].concat(t))}}),jQuery.fn.extend({wikiWithOptions:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(0===this.length||0===r.length)return this;var a=document.createDocumentFragment();return r.forEach(function(t){return new Wikifier(a,t,e)}),this.append(a),this},wiki:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.wikiWithOptions.apply(this,[undefined].concat(t))}})}();var Util=function(){function e(e){if(e instanceof Array)return Object.freeze(e.reduce(function(e,t,r){return e[t]=r,e},Object.create(null)));if(e instanceof Object)return Object.freeze(Object.assign(Object.create(null),e));throw new TypeError(\"Util.toEnum obj parameter must be an array or generic object\")}function t(e){return Object.prototype.toString.call(e).slice(8,-1)}function r(e){if(null===e)return\"null\";var t=void 0===e?\"undefined\":_typeof(e);return\"object\"===t?Object.prototype.toString.call(e).slice(8,-1):t}function n(e){var t=void 0;switch(void 0===e?\"undefined\":_typeof(e)){case\"number\":t=e;break;case\"string\":t=Number(e);break;default:return!1}return!Number.isNaN(t)&&Number.isFinite(t)}function a(e){return\"boolean\"==typeof e||\"string\"==typeof e&&(\"true\"===e||\"false\"===e)}function i(e,t){return e===t||e!==e&&t!==t}function o(e){return String(e).trim().replace(/[^\\w\\s\\u2013\\u2014-]+/g,\"\").replace(/[_\\s\\u2013\\u2014-]+/g,\"-\").toLocaleLowerCase()}function s(e){if(null==e)return\"\";var t=String(e);return t&&v.test(t)?t.replace(m,function(e){return y[e]}):t}function u(e){if(null==e)return\"\";var t=String(e);return t&&w.test(t)?t.replace(b,function(e){return k[e.toLowerCase()]}):t}function l(e,t){var r=String(e),n=Math.trunc(t),a=r.charCodeAt(n);if(Number.isNaN(a))return{char:\"\",start:-1,end:-1};var i={char:r.charAt(n),start:n,end:n};if(a<55296||a>57343)return i;if(a>=55296&&a<=56319){var o=n+1;if(o>=r.length)return i;var s=r.charCodeAt(o);return s<56320||s>57343?i:(i.char=i.char+r.charAt(o),i.end=o,i)}if(0===n)return i;var u=n-1,l=r.charCodeAt(u);return l<55296||l>56319?i:(i.char=r.charAt(u)+i.char,i.start=u,i)}function c(){return S.now()}function d(e){var t=E.exec(String(e));if(null===t)throw new SyntaxError('invalid time value syntax: \"'+e+'\"');var r=Number(t[1]);if(1===t[2].length&&(r*=1e3),Number.isNaN(r)||!Number.isFinite(r))throw new RangeError('invalid time value: \"'+e+'\"');return r}function f(e){if(\"number\"!=typeof e||Number.isNaN(e)||!Number.isFinite(e)){var r=void 0;switch(void 0===e?\"undefined\":_typeof(e)){case\"string\":r='\"'+e+'\"';break;case\"number\":r=String(e);break;default:r=t(e)}throw new Error(\"invalid milliseconds: \"+r)}return e+\"ms\"}function p(e){if(!e.includes(\"-\"))switch(e){case\"bgcolor\":return\"backgroundColor\";case\"float\":return\"cssFloat\";default:return e}return(\"-ms-\"===e.slice(0,4)?e.slice(1):e).split(\"-\").map(function(e,t){return 0===t?e:e.toUpperFirst()}).join(\"\")}function h(e){var t=document.createElement(\"a\"),r=Object.create(null);t.href=e,t.search&&t.search.replace(/^\\?/,\"\").splitOrEmpty(/(?:&(?:amp;)?|;)/).forEach(function(e){var t=e.split(\"=\"),n=_slicedToArray(t,2),a=n[0],i=n[1];r[a]=i});var n=t.host&&\"/\"!==t.pathname[0]?\"/\"+t.pathname:t.pathname;return{href:t.href,protocol:t.protocol,host:t.host,hostname:t.hostname,port:t.port,path:\"\"+n+t.search,pathname:n,query:t.search,search:t.search,queries:r,searches:r,hash:t.hash}}function g(e,t,r){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e))||null===e)throw new Error(\"Util.newExceptionFrom original parameter must be an object\");if(\"function\"!=typeof t)throw new Error(\"Util.newExceptionFrom exceptionType parameter must be an error type constructor\");var n=new t(e.message);void 0!==e.name&&(n.name=e.name),void 0!==e.code&&(n.code=e.code),void 0!==e.columnNumber&&(n.columnNumber=e.columnNumber),void 0!==e.description&&(n.description=e.description),void 0!==e.fileName&&(n.fileName=e.fileName),void 0!==e.lineNumber&&(n.lineNumber=e.lineNumber),void 0!==e.number&&(n.number=e.number),void 0!==e.stack&&(n.stack=e.stack);var a=void 0===r?\"undefined\":_typeof(r);if(\"undefined\"!==a)if(\"object\"===a&&null!==r)Object.assign(n,r);else{if(\"string\"!==a)throw new Error(\"Util.newExceptionFrom override parameter must be an object or string\");n.message=r}return n}var m=/[&<>\"'`]/g,v=new RegExp(m.source),y=Object.freeze({\"&\":\"&amp;\",\"<\":\"&lt;\",\">\":\"&gt;\",'\"':\"&quot;\",\"'\":\"&#39;\",\"`\":\"&#96;\"}),b=/&(?:amp|#38|#x26|lt|#60|#x3c|gt|#62|#x3e|quot|#34|#x22|apos|#39|#x27|#96|#x60);/gi,w=new RegExp(b.source,\"i\"),k=Object.freeze({\"&amp;\":\"&\",\"&#38;\":\"&\",\"&#x26;\":\"&\",\"&lt;\":\"<\",\"&#60;\":\"<\",\"&#x3c;\":\"<\",\"&gt;\":\">\",\"&#62;\":\">\",\"&#x3e;\":\">\",\"&quot;\":'\"',\"&#34;\":'\"',\"&#x22;\":'\"',\"&apos;\":\"'\",\"&#39;\":\"'\",\"&#x27;\":\"'\",\"&#96;\":\"`\",\"&#x60;\":\"`\"}),S=Has.performance?performance:Date,E=/^([+-]?(?:\\d*\\.)?\\d+)([Mm]?[Ss])$/;return Object.freeze(Object.defineProperties({},{toEnum:{value:e},toStringTag:{value:t},getType:{value:r},isNumeric:{value:n},isBoolean:{value:a},sameValueZero:{value:i},slugify:{value:o},escape:{value:s},unescape:{value:u},charAndPosAt:{value:l},fromCssTime:{value:d},toCssTime:{value:f},fromCssProperty:{value:p},parseUrl:{value:h},newExceptionFrom:{value:g},now:{value:c},random:{value:Math.random},entityEncode:{value:s},entityDecode:{value:u},evalExpression:{value:function(){return Scripting.evalJavaScript.apply(Scripting,arguments)}},evalStatements:{value:function(){return Scripting.evalJavaScript.apply(Scripting,arguments)}}}))}(),SimpleStore=function(){function e(e,n){if(r)return r.create(e,n);for(var a=0;a<t.length;++a)if(t[a].init(e,n))return r=t[a],r.create(e,n);throw new Error(\"no valid storage adapters found\")}var t=[],r=null;return Object.freeze(Object.defineProperties({},{adapters:{value:t},create:{value:e}}))}();SimpleStore.adapters.push(function(){function e(){function e(e){try{var t=window[e],r=\"_sc_\"+String(Date.now());t.setItem(r,r);var n=t.getItem(r)===r;return t.removeItem(r),n}catch(e){}return!1}return r=e(\"localStorage\")&&e(\"sessionStorage\")}function t(e,t){if(!r)throw new Error(\"adapter not initialized\");return new n(e,t)}var r=!1,n=function(){function e(t,r){_classCallCheck(this,e);var n=t+\".\",a=null,i=null;r?(a=window.localStorage,i=\"localStorage\"):(a=window.sessionStorage,i=\"sessionStorage\"),Object.defineProperties(this,{_engine:{value:a},_prefix:{value:n},_prefixRe:{value:new RegExp(\"^\"+RegExp.escape(n))},name:{value:i},id:{value:t},persistent:{value:!!r}})}return _createClass(e,[{key:\"size\",value:function(){return this.keys().length}},{key:\"keys\",value:function(){for(var e=[],t=0;t<this._engine.length;++t){var r=this._engine.key(t);this._prefixRe.test(r)&&e.push(r.replace(this._prefixRe,\"\"))}return e}},{key:\"has\",value:function(e){return!(\"string\"!=typeof e||!e)&&this._engine.hasOwnProperty(this._prefix+e)}},{key:\"get\",value:function(t){if(\"string\"!=typeof t||!t)return null;var r=this._engine.getItem(this._prefix+t);return null==r?null:e._deserialize(r)}},{key:\"set\",value:function(t,r){if(\"string\"!=typeof t||!t)return!1;try{this._engine.setItem(this._prefix+t,e._serialize(r))}catch(e){if(/quota.?(?:exceeded|reached)/i.test(e.name+e.message))throw Util.newExceptionFrom(e,Error,this.name+\" quota exceeded\");throw e}return!0}},{key:\"delete\",value:function(e){return!(\"string\"!=typeof e||!e)&&(this._engine.removeItem(this._prefix+e),!0)}},{key:\"clear\",value:function(){for(var e=this.keys(),t=0,r=e.length;t<r;++t)this.delete(e[t]);return!0}},{key:\"length\",get:function(){return this.keys().length}}],[{key:\"_serialize\",value:function(e){return JSON.stringify(e)}},{key:\"_deserialize\",value:function(e){return JSON.parse(e&&\"{\"!=e[0]?LZString.decompressFromUTF16(e):e)}}]),e}();return Object.freeze(Object.defineProperties({},{init:{value:e},create:{value:t}}))}()),SimpleStore.adapters.push(function(){function e(e){try{var t=\"_sc_\"+String(Date.now());o._setCookie(t,o._serialize(t),undefined),i=o._deserialize(o._getCookie(t))===t,o._setCookie(t,undefined,a)}catch(e){i=!1}return i&&r(e),i}function t(e,t){if(!i)throw new Error(\"adapter not initialized\");return new o(e,t)}function r(e){if(\"\"!==document.cookie)for(var t=e+\".\",r=new RegExp(\"^\"+RegExp.escape(t)),i=e+\"!.\",s=e+\"*.\",u=/\\.(?:state|rcWarn)$/,l=document.cookie.split(/;\\s*/),c=0;c<l.length;++c){var d=l[c].split(\"=\"),f=decodeURIComponent(d[0]);if(r.test(f)){var p=decodeURIComponent(d[1]);\"\"!==p&&function(){var e=!u.test(f);o._setCookie(f,undefined,a),o._setCookie(f.replace(r,function(){return e?i:s}),p,e?n:undefined)}()}}}var n=\"Tue, 19 Jan 2038 03:14:07 GMT\",a=\"Thu, 01 Jan 1970 00:00:00 GMT\",i=!1,o=function(){function e(t,r){_classCallCheck(this,e);var n=t+(r?\"!\":\"*\")+\".\";Object.defineProperties(this,{_prefix:{value:n},_prefixRe:{value:new RegExp(\"^\"+RegExp.escape(n))},name:{value:\"cookie\"},id:{value:t},persistent:{value:!!r}})}return _createClass(e,[{key:\"size\",value:function(){return this.keys().length}},{key:\"keys\",value:function(){if(\"\"===document.cookie)return[];for(var e=document.cookie.split(/;\\s*/),t=[],r=0;r<e.length;++r){var n=e[r].split(\"=\"),a=decodeURIComponent(n[0]);if(this._prefixRe.test(a)){\"\"!==decodeURIComponent(n[1])&&t.push(a.replace(this._prefixRe,\"\"))}}return t}},{key:\"has\",value:function(t){return!(\"string\"!=typeof t||!t)&&null!==e._getCookie(this._prefix+t)}},{key:\"get\",value:function(t){if(\"string\"!=typeof t||!t)return null;var r=e._getCookie(this._prefix+t);return null===r?null:e._deserialize(r)}},{key:\"set\",value:function(t,r){if(\"string\"!=typeof t||!t)return!1;try{if(e._setCookie(this._prefix+t,e._serialize(r),this.persistent?n:undefined),!this.has(t))throw new Error(\"unknown validation error during set\")}catch(e){throw Util.newExceptionFrom(e,Error,\"cookie error: \"+e.message)}return!0}},{key:\"delete\",value:function(t){if(\"string\"!=typeof t||!t||!this.has(t))return!1;try{if(e._setCookie(this._prefix+t,undefined,a),this.has(t))throw new Error(\"unknown validation error during delete\")}catch(e){throw Util.newExceptionFrom(e,Error,\"cookie error: \"+e.message)}return!0}},{key:\"clear\",value:function(){for(var e=this.keys(),t=0,r=e.length;t<r;++t)this.delete(e[t]);return!0}},{key:\"length\",get:function(){return this.keys().length}}],[{key:\"_getCookie\",value:function(e){if(!e||\"\"===document.cookie)return null;for(var t=document.cookie.split(/;\\s*/),r=0;r<t.length;++r){var n=t[r].split(\"=\");if(e===decodeURIComponent(n[0])){return decodeURIComponent(n[1])||null}}return null}},{key:\"_setCookie\",value:function(e,t,r){if(e){var n=encodeURIComponent(e)+\"=\";null!=t&&(n+=encodeURIComponent(t)),null!=r&&(n+=\"; expires=\"+r),n+=\"; path=/\",document.cookie=n}}},{key:\"_serialize\",value:function(e){return LZString.compressToBase64(JSON.stringify(e))}},{key:\"_deserialize\",value:function(e){return JSON.parse(LZString.decompressFromBase64(e))}}]),e}();return Object.freeze(Object.defineProperties({},{init:{value:e},create:{value:t}}))}());var DebugView=function(){return function(){function e(t,r,n,a){_classCallCheck(this,e),Object.defineProperties(this,{parent:{value:t},view:{value:document.createElement(\"span\")},break:{value:document.createElement(\"wbr\")}}),jQuery(this.view).attr({title:a,\"aria-label\":a,\"data-type\":null!=r?r:\"\",\"data-name\":null!=n?n:\"\"}).addClass(\"debug\"),jQuery(this.break).addClass(\"debug hidden\"),this.parent.appendChild(this.view),this.parent.appendChild(this.break)}return _createClass(e,[{key:\"append\",value:function(e){return jQuery(this.view).append(e),this}},{key:\"modes\",value:function(e){if(null==e){var t={};return this.view.className.splitOrEmpty(/\\s+/).forEach(function(e){\"debug\"!==e&&(t[e]=!0)}),t}if(\"object\"===(void 0===e?\"undefined\":_typeof(e)))return Object.keys(e).forEach(function(t){this[e[t]?\"addClass\":\"removeClass\"](t)},jQuery(this.view)),this;throw new Error(\"DebugView.prototype.modes options parameter must be an object or null/undefined\")}},{key:\"remove\",value:function(){var e=jQuery(this.view);this.view.hasChildNodes()&&e.contents().appendTo(this.parent),e.remove(),jQuery(this.break).remove()}},{key:\"output\",get:function(){return this.view}},{key:\"type\",get:function(){return this.view.getAttribute(\"data-type\")},set:function(e){this.view.setAttribute(\"data-type\",null!=e?e:\"\")}},{key:\"name\",get:function(){return this.view.getAttribute(\"data-name\")},set:function(e){this.view.setAttribute(\"data-name\",null!=e?e:\"\")}},{key:\"title\",get:function(){return this.view.title},set:function(e){this.view.title=e}}],[{key:\"isEnabled\",value:function(){return\"enabled\"===jQuery(document.documentElement).attr(\"data-debug-view\")}},{key:\"enable\",value:function(){jQuery(document.documentElement).attr(\"data-debug-view\",\"enabled\"),jQuery.event.trigger(\":debugviewupdate\")}},{key:\"disable\",value:function(){jQuery(document.documentElement).removeAttr(\"data-debug-view\"),jQuery.event.trigger(\":debugviewupdate\")}},{key:\"toggle\",value:function(){\"enabled\"===jQuery(document.documentElement).attr(\"data-debug-view\")?e.disable():e.enable()}}]),e}()}(),PRNGWrapper=function(){return function(){function e(t,r){_classCallCheck(this,e),Object.defineProperties(this,new Math.seedrandom(t,r,function(e,t){return{_prng:{value:e},seed:{writable:!0,value:t},pull:{writable:!0,value:0},random:{value:function(){return++this.pull,this._prng()}}}}))}return _createClass(e,null,[{key:\"marshal\",value:function(e){if(!e||!e.hasOwnProperty(\"seed\")||!e.hasOwnProperty(\"pull\"))throw new Error(\"PRNG is missing required data\");return{seed:e.seed,pull:e.pull}}},{key:\"unmarshal\",value:function(t){if(!t||!t.hasOwnProperty(\"seed\")||!t.hasOwnProperty(\"pull\"))throw new Error(\"PRNG object is missing required data\");for(var r=new e(t.seed,!1),n=t.pull;n>0;--n)r.random();return r}}]),e}()}(),StyleWrapper=function(){var e=new RegExp(Patterns.cssImage,\"g\"),t=new RegExp(Patterns.cssImage);return function(){function r(e){if(_classCallCheck(this,r),null==e)throw new TypeError(\"StyleWrapper style parameter must be an HTMLStyleElement object\");Object.defineProperties(this,{style:{value:e}})}return _createClass(r,[{key:\"isEmpty\",value:function(){return 0===this.style.cssRules.length}},{key:\"set\",value:function(e){this.clear(),this.add(e)}},{key:\"add\",value:function(r){var n=r;t.test(n)&&(e.lastIndex=0,n=n.replace(e,function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup({source:e,matchStart:0});if(t.hasOwnProperty(\"error\")||t.pos<e.length)return e;var r=t.source;if(\"data:\"!==r.slice(0,5)&&Story.has(r)){var n=Story.get(r);n.tags.includes(\"Twine.image\")&&(r=n.text.trim())}return'url(\"'+r.replace(/\"/g,\"%22\")+'\")'})),this.style.styleSheet?this.style.styleSheet.cssText+=n:this.style.appendChild(document.createTextNode(n))}},{key:\"clear\",value:function(){this.style.styleSheet?this.style.styleSheet.cssText=\"\":jQuery(this.style).empty()}}]),r}()}(),Diff=function(){function e(t,n){for(var a=Object.prototype.toString,i=t instanceof Array,o=[].concat(Object.keys(t),Object.keys(n)).sort().filter(function(e,t,r){return 0===t||r[t-1]!==e}),s={},u=void 0,l=function(e){return e===u},c=0,d=o.length;c<d;++c){var f=o[c],p=t[f],h=n[f];if(t.hasOwnProperty(f))if(n.hasOwnProperty(f)){if(p===h)continue;if((void 0===p?\"undefined\":_typeof(p))===(void 0===h?\"undefined\":_typeof(h)))if(\"function\"==typeof p)p.toString()!==h.toString()&&(s[f]=[r.Copy,h]);else if(\"object\"!==(void 0===p?\"undefined\":_typeof(p))||null===p)s[f]=[r.Copy,h];else{var g=a.call(p),m=a.call(h);if(g===m)if(p instanceof Date)Number(p)!==Number(h)&&(s[f]=[r.Copy,clone(h)]);else if(p instanceof Map)s[f]=[r.Copy,clone(h)];else if(p instanceof RegExp)p.toString()!==h.toString()&&(s[f]=[r.Copy,clone(h)]);else if(p instanceof Set)s[f]=[r.Copy,clone(h)];else if(\"[object Object]\"!==g)s[f]=[r.Copy,clone(h)];else{var v=e(p,h);null!==v&&(s[f]=v)}else s[f]=[r.Copy,clone(h)]}else s[f]=[r.Copy,\"object\"!==(void 0===h?\"undefined\":_typeof(h))||null===h?h:clone(h)]}else if(i&&Util.isNumeric(f)){var y=Number(f);if(!u){u=\"\";do{u+=\"~\"}while(o.some(l));s[u]=[r.SpliceArray,y,y]}y<s[u][1]&&(s[u][1]=y),y>s[u][2]&&(s[u][2]=y)}else s[f]=r.Delete;else s[f]=[r.Copy,\"object\"!==(void 0===h?\"undefined\":_typeof(h))||null===h?h:clone(h)]}return Object.keys(s).length>0?s:null}function t(e,n){for(var a=Object.keys(n||{}),i=clone(e),o=0,s=a.length;o<s;++o){var u=a[o],l=n[u];if(l===r.Delete)delete i[u];else if(l instanceof Array)switch(l[0]){case r.SpliceArray:i.splice(l[1],l[2]-l[1]+1);break;case r.Copy:i[u]=clone(l[1]);break;case r.CopyDate:i[u]=new Date(l[1])}else i[u]=t(i[u],l)}return i}var r=Util.toEnum({Delete:0,SpliceArray:1,Copy:2,CopyDate:3});return Object.freeze(Object.defineProperties({},{Op:{value:r},diff:{value:e},patch:{value:t}}))}(),L10n=function(){function e(){r()}function t(e,t){if(!e)return\"\";var r=function(e){var t=void 0;return e.some(function(e){return!!l10nStrings.hasOwnProperty(e)&&(t=e,!0)}),t}(Array.isArray(e)?e:[e]);if(!r)return\"\";for(var i=l10nStrings[r],o=0;a.test(i);){if(++o>50)throw new Error(\"L10n.get exceeded maximum replacement iterations, probable infinite loop\");n.lastIndex=0,i=i.replace(n,function(e){var r=e.slice(1,-1);return t&&t.hasOwnProperty(r)?t[r]:l10nStrings.hasOwnProperty(r)?l10nStrings[r]:void 0})}return i}function r(){strings&&Object.keys(strings).length>0&&Object.keys(l10nStrings).forEach(function(e){try{var t=void 0;switch(e){case\"identity\":t=strings.identity;break;case\"aborting\":t=strings.aborting;break;case\"cancel\":t=strings.cancel;break;case\"close\":t=strings.close;break;case\"ok\":t=strings.ok;break;case\"errorTitle\":t=strings.errors.title;break;case\"errorNonexistentPassage\":t=strings.errors.nonexistentPassage;break;case\"errorSaveMissingData\":t=strings.errors.saveMissingData;break;case\"errorSaveIdMismatch\":t=strings.errors.saveIdMismatch;break;case\"warningDegraded\":t=strings.warnings.degraded;break;case\"debugViewTitle\":t=strings.debugView.title;break;case\"debugViewToggle\":t=strings.debugView.toggle;break;case\"uiBarToggle\":t=strings.uiBar.toggle;break;case\"uiBarBackward\":t=strings.uiBar.backward;break;case\"uiBarForward\":t=strings.uiBar.forward;break;case\"uiBarJumpto\":t=strings.uiBar.jumpto;break;case\"jumptoTitle\":t=strings.jumpto.title;break;case\"jumptoTurn\":t=strings.jumpto.turn;break;case\"jumptoUnavailable\":t=strings.jumpto.unavailable;break;case\"savesTitle\":t=strings.saves.title;break;case\"savesDisallowed\":t=strings.saves.disallowed;break;case\"savesIncapable\":t=strings.saves.incapable;break;case\"savesLabelAuto\":t=strings.saves.labelAuto;break;case\"savesLabelDelete\":t=strings.saves.labelDelete;break;case\"savesLabelExport\":t=strings.saves.labelExport;break;case\"savesLabelImport\":t=strings.saves.labelImport;break;case\"savesLabelLoad\":t=strings.saves.labelLoad;break;case\"savesLabelClear\":t=strings.saves.labelClear;break;case\"savesLabelSave\":t=strings.saves.labelSave;break;case\"savesLabelSlot\":t=strings.saves.labelSlot;break;case\"savesUnavailable\":t=strings.saves.unavailable;break;case\"savesUnknownDate\":t=strings.saves.unknownDate;break;case\"settingsTitle\":t=strings.settings.title;break;case\"settingsOff\":t=strings.settings.off;break;case\"settingsOn\":t=strings.settings.on;break;case\"settingsReset\":t=strings.settings.reset;break;case\"restartTitle\":t=strings.restart.title;break;case\"restartPrompt\":t=strings.restart.prompt;break;case\"shareTitle\":t=strings.share.title;break;case\"autoloadTitle\":t=strings.autoload.title;break;case\"autoloadCancel\":t=strings.autoload.cancel;break;case\"autoloadOk\":t=strings.autoload.ok;break;case\"autoloadPrompt\":t=strings.autoload.prompt;break;case\"macroBackText\":t=strings.macros.back.text;break;case\"macroReturnText\":t=strings.macros.return.text}t&&(l10nStrings[e]=t.replace(/%\\w+%/g,function(e){return\"{\"+e.slice(1,-1)+\"}\"}))}catch(e){}})}var n=/\\{\\w+\\}/g,a=new RegExp(n.source);return Object.freeze(Object.defineProperties({},{init:{value:e},get:{value:t}}))}(),strings={errors:{},warnings:{},debugView:{},uiBar:{},jumpto:{},saves:{},settings:{},restart:{},share:{},autoload:{},macros:{back:{},return:{}}},l10nStrings={identity:\"game\",aborting:\"Aborting\",cancel:\"Cancel\",close:\"Close\",ok:\"OK\",errorTitle:\"Error\",errorToggle:\"Toggle the error view\",errorNonexistentPassage:'the passage \"{passage}\" does not exist',errorSaveMissingData:\"save is missing required data. Either the loaded file is not a save or the save has become corrupted\",errorSaveIdMismatch:\"save is from the wrong {identity}\",_warningIntroLacking:\"Your browser either lacks or has disabled\",_warningOutroDegraded:\", so this {identity} is running in a degraded mode. You may be able to continue, however, some parts may not work properly.\",warningNoWebStorage:\"{_warningIntroLacking} the Web Storage API{_warningOutroDegraded}\",warningDegraded:\"{_warningIntroLacking} some of the capabilities required by this {identity}{_warningOutroDegraded}\",debugBarToggle:\"Toggle the debug bar\",debugBarNoWatches:\"— no watches set —\",debugBarAddWatch:\"Add watch\",debugBarDeleteWatch:\"Delete watch\",debugBarWatchAll:\"Watch all\",debugBarWatchNone:\"Delete all\",debugBarLabelAdd:\"Add\",debugBarLabelWatch:\"Watch\",debugBarLabelTurn:\"Turn\",debugBarLabelViews:\"Views\",debugBarViewsToggle:\"Toggle the debug views\",debugBarWatchToggle:\"Toggle the watch panel\",uiBarToggle:\"Toggle the UI bar\",uiBarBackward:\"Go backward within the {identity} history\",uiBarForward:\"Go forward within the {identity} history\",uiBarJumpto:\"Jump to a specific point within the {identity} history\",jumptoTitle:\"Jump To\",jumptoTurn:\"Turn\",jumptoUnavailable:\"No jump points currently available…\",savesTitle:\"Saves\",savesDisallowed:\"Saving has been disallowed on this passage.\",savesIncapable:\"{_warningIntroLacking} the capabilities required to support saves, so saves have been disabled for this session.\",savesLabelAuto:\"Autosave\",savesLabelDelete:\"Delete\",savesLabelExport:\"Save to Disk…\",savesLabelImport:\"Load from Disk…\",savesLabelLoad:\"Load\",savesLabelClear:\"Delete All\",savesLabelSave:\"Save\",savesLabelSlot:\"Slot\",savesUnavailable:\"No save slots found…\",savesUnknownDate:\"unknown\",settingsTitle:\"Settings\",settingsOff:\"Off\",settingsOn:\"On\",settingsReset:\"Reset to Defaults\",restartTitle:\"Restart\",restartPrompt:\"Are you sure that you want to restart? Unsaved progress will be lost.\",shareTitle:\"Share\",autoloadTitle:\"Autoload\",autoloadCancel:\"Go to start\",autoloadOk:\"Load autosave\",autoloadPrompt:\"An autosave exists. Load it now or go to the start?\",macroBackText:\"Back\",macroReturnText:\"Return\"},Config=function(){function e(){throw new Error(\"Config.history.mode has been deprecated and is no longer used by SugarCube, please remove it from your code\")}function t(){throw new Error(\"Config.history.tracking has been deprecated, use Config.history.maxStates instead\")}var r=!1,n=!1,a=!1,i=0,o=!0,s=!0,u=!0,l=100,c=!0,d=1e3,f=void 0,p=void 0,h=!1,g=!1,m=void 0,v=void 0,y=void 0,b=void 0,w=\"untitled-story\",k=void 0,S=void 0,E=void 0,j=8,x=void 0,O=800,T=!0;return Object.freeze({get debug(){return r},set debug(e){r=Boolean(e)},get addVisitedLinkClass(){return n},set addVisitedLinkClass(e){n=Boolean(e)},get cleanupWikifierOutput(){return a},set cleanupWikifierOutput(e){a=Boolean(e)},get loadDelay(){return i},set loadDelay(e){if(!Number.isSafeInteger(e)||e<0)throw new RangeError(\"Config.loadDelay must be a non-negative integer\");i=e},audio:Object.freeze({get pauseOnFadeToZero(){return o},set pauseOnFadeToZero(e){o=Boolean(e)},get preloadMetadata(){return s},set preloadMetadata(e){s=Boolean(e)}}),history:Object.freeze({get controls(){return u},set controls(e){if((u=Boolean(e))&&1===l)throw u=!1,new Error(\"Config.history.controls must be false when Config.history.maxStates is 1\")},get maxStates(){return l},set maxStates(e){if(!Number.isSafeInteger(e)||e<0)throw new RangeError(\"Config.history.maxStates must be a non-negative integer\");l=e,u&&1===e&&(u=!1)},get mode(){e()},set mode(t){e()},get tracking(){t()},set tracking(e){t()}}),macros:Object.freeze({get ifAssignmentError(){return c},set ifAssignmentError(e){c=Boolean(e)},get maxLoopIterations(){return d},set maxLoopIterations(e){if(!Number.isSafeInteger(e)||e<0)throw new RangeError(\"Config.macros.maxLoopIterations must be a non-negative integer\");d=e}}),navigation:Object.freeze({get override(){return f},set override(e){if(!(null==e||e instanceof Function))throw new TypeError(\"Config.navigation.override must be a function or null/undefined (received: \"+Util.getType(e)+\")\");f=e}}),passages:Object.freeze({get descriptions(){return p},set descriptions(e){if(null!=e){var t=Util.getType(e);if(\"boolean\"!==t&&\"Object\"!==t&&\"function\"!==t)throw new TypeError(\"Config.passages.descriptions must be a boolean, object, function, or null/undefined (received: \"+t+\")\")}p=e},get displayTitles(){return h},set displayTitles(e){h=Boolean(e)},get nobr(){return g},set nobr(e){g=Boolean(e)},get start(){return m},set start(e){if(null!=e){var t=Util.getType(e);if(\"string\"!==t)throw new TypeError(\"Config.passages.start must be a string or null/undefined (received: \"+t+\")\")}m=e},get transitionOut(){return v},set transitionOut(e){if(null!=e){var t=Util.getType(e);if(\"string\"!==t&&(\"number\"!==t||!Number.isSafeInteger(e)||e<0))throw new TypeError(\"Config.passages.transitionOut must be a string, non-negative integer, or null/undefined (received: \"+t+\")\")}v=e}}),saves:Object.freeze({get autoload(){return y},set autoload(e){if(null!=e){var t=Util.getType(e);if(\"boolean\"!==t&&\"string\"!==t&&\"function\"!==t)throw new TypeError(\"Config.saves.autoload must be a boolean, string, function, or null/undefined (received: \"+t+\")\")}y=e},get autosave(){return b},set autosave(e){if(null!=e){var t=Util.getType(e);if(\"boolean\"!==t&&\"string\"!==t&&(\"Array\"!==t||!e.every(function(e){return\"string\"==typeof e})))throw new TypeError(\"Config.saves.autosave must be a boolean, string, Array of strings, or null/undefined (received: \"+t+(\"Array\"===t?\" of mixed\":\"\")+\")\")}b=e},get id(){return w},set id(e){if(\"string\"!=typeof e||\"\"===e)throw new TypeError(\"Config.saves.id must be a non-empty string (received: \"+Util.getType(e)+\")\");w=e},get isAllowed(){return k},set isAllowed(e){if(!(null==e||e instanceof Function))throw new TypeError(\"Config.saves.isAllowed must be a function or null/undefined (received: \"+Util.getType(e)+\")\");k=e},get onLoad(){return S},set onLoad(e){if(!(null==e||e instanceof Function))throw new TypeError(\"Config.saves.onLoad must be a function or null/undefined (received: \"+Util.getType(e)+\")\");S=e},get onSave(){return E},set onSave(e){if(!(null==e||e instanceof Function))throw new TypeError(\"Config.saves.onSave must be a function or null/undefined (received: \"+Util.getType(e)+\")\");E=e},get slots(){return j},set slots(e){if(!Number.isSafeInteger(e)||e<0)throw new RangeError(\"Config.saves.slots must be a non-negative integer\");j=e},get version(){return x},set version(e){x=e}}),ui:Object.freeze({get stowBarInitially(){return O},set stowBarInitially(e){var t=Util.getType(e);if(\"boolean\"!==t&&(\"number\"!==t||!Number.isSafeInteger(e)||e<0))throw new TypeError(\"Config.passages.transitionOut must be a boolean or non-negative integer (received: \"+t+\")\");O=e},get updateStoryElements(){return T},set updateStoryElements(e){T=Boolean(e)}})})}(),SimpleAudio=function(){function e(){if(arguments.length<2){var e=[];throw arguments.length<1&&e.push(\"track ID\"),arguments.length<2&&e.push(\"sources\"),new Error(\"no \"+e.join(\" or \")+\" specified\")}var t=String(arguments[0]).trim(),r='track ID \"'+t+'\"';if(_.test(t))throw new Error(\"invalid \"+r+\": track IDs must not contain colons or whitespace\");var n=Array.isArray(arguments[1])?Array.from(arguments[1]):Array.from(arguments).slice(1),a=void 0;try{a=T(n)}catch(e){throw new Error(r+\": error during track initialization: \"+e.message)}if(Config.debug&&!a.hasSource())throw new Error(r+\": no supported audio sources found\");N.has(t)&&N.get(t)._destroy(),N.set(t,a)}function t(e){return N.has(e)&&N.get(e)._destroy(),N.delete(e)}function r(){N.forEach(function(e){return e._destroy()}),N.clear()}function n(e){return N.has(e)}function a(e){return N.get(e)||null}function i(){if(arguments.length<2){var e=[];throw arguments.length<1&&e.push(\"group ID\"),arguments.length<2&&e.push(\"track IDs\"),new Error(\"no \"+e.join(\" or \")+\" specified\")}var t=String(arguments[0]).trim(),r='group ID \"'+t+'\"';if(\":\"!==t[0]||_.test(t.slice(1)))throw new Error(\"invalid \"+r+\": group IDs must start with a colon and must not contain colons or whitespace\");if(A.includes(t))throw new Error(\"cannot clobber special \"+r);var n=Array.isArray(arguments[1])?Array.from(arguments[1]):Array.from(arguments).slice(1),a=void 0;try{a=new Set(n.map(function(e){if(!N.has(e))throw new Error('track \"'+e+'\" does not exist');return e}))}catch(e){throw new Error(r+\": error during group initialization: \"+e.message)}I.set(t,Object.freeze(Array.from(a)))}function o(e){return I.delete(e)}function s(){I.clear()}function u(e){return I.has(e)}function l(e){return I.get(e)||null}function c(){if(arguments.length<2){var e=[];throw arguments.length<1&&e.push(\"list ID\"),arguments.length<2&&e.push(\"track IDs\"),new Error(\"no \"+e.join(\" or \")+\" specified\")}var t=String(arguments[0]).trim(),r='list ID \"'+t+'\"';if(_.test(t))return this.error(\"invalid \"+r+\": list IDs must not contain colons or whitespace\");var n=Array.isArray(arguments[1])?Array.from(arguments[1]):Array.from(arguments).slice(1),a=void 0;try{a=new B(n.map(function(e){if(null===e)throw new Error(\"track descriptor must be a string or object (type: null)\");switch(void 0===e?\"undefined\":_typeof(e)){case\"string\":e={id:e};break;case\"object\":\nif(!e.hasOwnProperty(\"id\")&&!e.hasOwnProperty(\"sources\"))throw new Error('track descriptor must contain one of either an \"id\" or a \"sources\" property');if(e.hasOwnProperty(\"id\")&&e.hasOwnProperty(\"sources\"))throw new Error('track descriptor must contain either an \"id\" or a \"sources\" property, not both');break;default:throw new Error(\"track descriptor must be a string or object (type: \"+(void 0===e?\"undefined\":_typeof(e))+\")\")}var t=void 0,r=void 0,n=void 0;if(e.hasOwnProperty(\"id\")){if(\"string\"!=typeof e.id)throw new Error('\"id\" property must be a string');if(!N.has(e.id))throw new Error('track \"'+e.id+'\" does not exist');r=N.get(e.id)}else if(e.hasOwnProperty(\"sources\")){if(!Array.isArray(e.sources)||0===e.sources.length)throw new Error('\"sources\" property must be a non-empty array');if(e.hasOwnProperty(\"own\"))throw new Error('\"own\" property is not allowed with the \"sources\" property');try{r=T(e.sources),t=!0}catch(e){throw new Error(\"error during track initialization: \"+e.message)}if(Config.debug&&!r.hasSource())throw new Error(\"no supported audio sources found\")}if(e.hasOwnProperty(\"own\")){if(\"boolean\"!=typeof e.own)throw new Error('\"own\" property must be a boolean');t=e.own,t&&(r=r.clone())}if(e.hasOwnProperty(\"volume\")){if(\"number\"!=typeof e.volume||Number.isNaN(e.volume)||!Number.isFinite(e.volume)||e.volume<0)throw new Error('\"volume\" property must be a non-negative finite number');n=e.volume}return{own:null!=t&&t,track:r,volume:null!=n?n:r.volume()}}))}catch(e){throw new Error(r+\": error during playlist initialization: \"+e.message)}L.has(t)&&L.get(t)._destroy(),L.set(t,a)}function d(e){return L.has(e)&&L.get(e)._destroy(),L.delete(e)}function f(){L.forEach(function(e){return e._destroy()}),L.clear()}function p(e){return L.has(e)}function h(e){return L.get(e)||null}function g(){if(0===arguments.length)throw new Error(\"no track selector specified\");var e=String(arguments[0]).trim(),t=new Set;try{var r=function e(t){var r=t.id,a=void 0;switch(r){case\":all\":a=n;break;case\":looped\":a=n.filter(function(e){return N.get(e).loop()});break;case\":muted\":a=n.filter(function(e){return N.get(e).mute()});break;case\":paused\":a=n.filter(function(e){return N.get(e).isPaused()});break;case\":playing\":a=n.filter(function(e){return N.get(e).isPlaying()});break;default:a=\":\"===r[0]?I.get(r):[r]}if(t.hasOwnProperty(\"not\")){var i=t.not.map(function(t){return e(t)}).flat(1/0);a=a.filter(function(e){return!i.includes(e)})}return a},n=Array.from(N.keys());U(e).forEach(function(e){return r(e).forEach(function(e){if(!N.has(e))throw new Error('track \"'+e+'\" does not exist');t.add(e)})})}catch(e){throw new Error(\"error during runner initialization: \"+e.message)}return new V(t)}function m(){O(\"load\")}function v(){O(\"loadwithscreen\")}function y(e){if(null==e)return R;R=!!e,O(\"mute\",R)}function b(e){if(null==e)return W;if(W=!!e){var t=Visibility.changeEvent+\".SimpleAudio_masterMuteOnHidden\";jQuery(document).off(t).on(t,function(){return y(Visibility.isHidden())}),Visibility.isHidden()&&y(!0)}else jQuery(document).off(\".SimpleAudio_masterMuteOnHidden\")}function w(e){if(null==e)return M;if(\"number\"!=typeof e||Number.isNaN(e)||!Number.isFinite(e))throw new Error(\"rate must be a finite number\");M=Math.clamp(e,.2,5),O(\"rate\",M)}function k(){O(\"stop\")}function S(){O(\"unload\")}function E(e){if(null==e)return Q;if(\"number\"!=typeof e||Number.isNaN(e)||!Number.isFinite(e))throw new Error(\"volume must be a finite number\");Q=Math.clamp(e,0,1),O(\"volume\",Q)}function j(e,t){if(\"function\"!=typeof t)throw new Error(\"callback parameter must be a function\");D.set(e,t)}function x(e){D.delete(e)}function O(e,t){D.forEach(function(r){return r(e,t)})}function T(e){return new F(e.map(function(e){if(\"data:\"!==e.slice(0,5)&&Story.has(e)){var t=Story.get(e);if(t.tags.includes(\"Twine.audio\"))return t.text.trim()}var r=P.exec(e);return null===r?e:{format:r[1],src:r[2]}}))}var C=Object.freeze([\"click\",\"contextmenu\",\"dblclick\",\"keyup\",\"mouseup\",\"pointerup\",\"touchend\"]),A=Object.freeze([\":not\",\":all\",\":looped\",\":muted\",\":paused\",\":playing\"]),P=/^([\\w-]+)\\s*\\|\\s*(\\S.*)$/,_=/[:\\s]/,N=new Map,I=new Map,L=new Map,D=new Map,M=1,Q=1,R=!1,W=!1,F=function(){function e(t){if(_classCallCheck(this,e),t instanceof Array)this._create(t);else{if(!(t instanceof e))throw new Error(\"sources parameter must be either an array, of URIs or source objects, or an AudioTrack instance\");this._copy(t)}}return _createClass(e,[{key:\"_create\",value:function(t){var r=/^data:\\s*audio\\/([^;,]+)\\s*[;,]/i,n=/\\.([^.\\/\\\\]+)$/,a=e.getType,i=[],o=document.createElement(\"audio\");o.preload=\"none\",t.forEach(function(e){var t=null;switch(void 0===e?\"undefined\":_typeof(e)){case\"string\":var s=void 0;if(\"data:\"===e.slice(0,5)){if(null===(s=r.exec(e)))throw new Error(\"source data URI missing media type\")}else if(null===(s=n.exec(Util.parseUrl(e).pathname)))throw new Error(\"source URL missing file extension\");var u=a(s[1]);null!==u&&(t={src:e,type:u});break;case\"object\":if(null===e)throw new Error(\"source object cannot be null\");if(!e.hasOwnProperty(\"src\"))throw new Error('source object missing required \"src\" property');if(!e.hasOwnProperty(\"format\"))throw new Error('source object missing required \"format\" property');var l=a(e.format);null!==l&&(t={src:e.src,type:l});break;default:throw new Error(\"invalid source value (type: \"+(void 0===e?\"undefined\":_typeof(e))+\")\")}if(null!==t){Browser.isOpera&&(t.type=t.type.replace(/;.*$/,\"\"));var c=document.createElement(\"source\");c.src=t.src,c.type=t.type,o.appendChild(c),i.push(t)}}),o.hasChildNodes()&&Config.audio.preloadMetadata&&(o.preload=\"metadata\"),this._finalize(o,i,clone(t))}},{key:\"_copy\",value:function(e){this._finalize(e.audio.cloneNode(!0),clone(e.sources),clone(e.originals))}},{key:\"_finalize\",value:function(e,t,r){var n=this;Object.defineProperties(this,{audio:{configurable:!0,value:e},sources:{value:Object.freeze(t)},originals:{value:Object.freeze(r)},_error:{writable:!0,value:!1},_faderId:{writable:!0,value:null},_mute:{writable:!0,value:!1},_rate:{writable:!0,value:1},_volume:{writable:!0,value:1}}),jQuery(this.audio).on(\"loadstart.AudioTrack\",function(){return n._error=!1}).on(\"error.AudioTrack\",function(){return n._error=!0}).find(\"source:last-of-type\").on(\"error.AudioTrack\",function(){return n._trigger(\"error\")}),j(this,function(e){if(!n.audio)return void x(n);switch(e){case\"loadwithscreen\":if(n.hasSource()){var t=LoadScreen.lock();n.one(\"canplaythrough.AudioTrack_loadwithscreen error.AudioTrack_loadwithscreen\",function(){jQuery(this).off(\".AudioTrack_loadwithscreen\"),LoadScreen.unlock(t)}).load()}break;case\"load\":n.load();break;case\"mute\":n._updateAudioMute();break;case\"rate\":n._updateAudioRate();break;case\"stop\":n.stop();break;case\"volume\":n._updateAudioVolume();break;case\"unload\":n.unload()}}),this._updateAudioMute(),this._updateAudioRate(),this._updateAudioVolume()}},{key:\"_trigger\",value:function(e){jQuery(this.audio).triggerHandler(e)}},{key:\"_destroy\",value:function(){x(this),this.audio&&(jQuery(this.audio).off(),this.unload(),this._error=!0,delete this.audio)}},{key:\"clone\",value:function(){return new e(this)}},{key:\"load\",value:function(){var e=this;if(this.fadeStop(),this.audio.pause(),!this.audio.hasChildNodes()){if(0===this.sources.length)return;this.sources.forEach(function(t){var r=document.createElement(\"source\");r.src=t.src,r.type=t.type,e.audio.appendChild(r)})}\"auto\"!==this.audio.preload&&(this.audio.preload=\"auto\"),this.isLoading()||this.audio.load()}},{key:\"unload\",value:function(){this.fadeStop(),this.stop();var e=this.audio;for(e.preload=\"none\";e.hasChildNodes();)e.removeChild(e.firstChild);e.load()}},{key:\"play\",value:function(){var e=this;return this.hasSource()?this.isUnloaded()?Promise.reject(new Error(\"no sources are loaded\")):this.isFailed()?Promise.reject(new Error(\"failed to load any of the sources\")):(\"auto\"!==this.audio.preload&&(this.audio.preload=\"auto\"),Has.audioPromise?this.audio.play():new Promise(function(t,r){jQuery(e.audio).off(\".AudioTrack_play\").one(\"error.AudioTrack_play playing.AudioTrack_play\",function(n){jQuery(e).off(\".AudioTrack_play\"),\"error\"===n.type?r(new Error(\"unknown error\")):t()}),e.audio.play()})):Promise.reject(new Error(\"none of the candidate sources were acceptable\"))}},{key:\"playWhenAllowed\",value:function(){var e=this;this.play().catch(function(){var t=C.map(function(e){return e+\".AudioTrack_playWhenAllowed\"}).join(\" \");jQuery(document).one(t,function(){jQuery(document).off(\".AudioTrack_playWhenAllowed\"),e.audio.play()})})}},{key:\"pause\",value:function(){this.audio.pause()}},{key:\"stop\",value:function(){this.audio.pause(),this.time(0),this._trigger(\":stopped\")}},{key:\"fade\",value:function(e,t,r){var n=this;if(\"number\"!=typeof e)throw new TypeError(\"duration parameter must be a number\");if(\"number\"!=typeof t)throw new TypeError(\"toVolume parameter must be a number\");if(null!=r&&\"number\"!=typeof r)throw new TypeError(\"fromVolume parameter must be a number\");if(!this.hasSource())return Promise.reject(new Error(\"none of the candidate sources were acceptable\"));if(this.isUnloaded())return Promise.reject(new Error(\"no sources are loaded\"));if(this.isFailed())return Promise.reject(new Error(\"failed to load any of the sources\"));this.fadeStop();var a=Math.clamp(null==r?this.volume():r,0,1),i=Math.clamp(t,0,1);return a!==i?(this.volume(a),jQuery(this.audio).off(\"timeupdate.AudioTrack_fade\").one(\"timeupdate.AudioTrack_fade\",function(){var t=void 0,r=void 0;a<i?(t=a,r=i):(t=i,r=a);var o=Math.max(e,1),s=(i-a)/(o/.025);n._trigger(\":fading\"),n._faderId=setInterval(function(){if(!n.isPlaying())return void n.fadeStop();n.volume(Math.clamp(n.volume()+s,t,r)),Config.audio.pauseOnFadeToZero&&0===n.volume()&&n.pause(),n.volume()===i&&(n.fadeStop(),n._trigger(\":faded\"))},25)}),this.play()):void 0}},{key:\"fadeIn\",value:function(e,t){return this.fade(e,1,t)}},{key:\"fadeOut\",value:function(e,t){return this.fade(e,0,t)}},{key:\"fadeStop\",value:function(){null!==this._faderId&&(clearInterval(this._faderId),this._faderId=null)}},{key:\"loop\",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(e){return null==e?this.audio.loop:(this.audio.loop=!!e,this)})},{key:\"mute\",value:function(e){return null==e?this._mute:(this._mute=!!e,this._updateAudioMute(),this)}},{key:\"_updateAudioMute\",value:function(){this.audio.muted=this._mute||R}},{key:\"rate\",value:function(e){if(null==e)return this._rate;if(\"number\"!=typeof e)throw new TypeError(\"rate parameter must be a number\");return this._rate=Math.clamp(e,.2,5),this._updateAudioRate(),this}},{key:\"_updateAudioRate\",value:function(){this.audio.playbackRate=Math.clamp(this._rate*M,.2,5)}},{key:\"time\",value:function(e){var t=this;if(null==e)return this.audio.currentTime;if(\"number\"!=typeof e)throw new TypeError(\"time parameter must be a number\");return this.hasMetadata()?this.audio.currentTime=e:jQuery(this.audio).off(\"loadedmetadata.AudioTrack_time\").one(\"loadedmetadata.AudioTrack_time\",function(){return t.audio.currentTime=e}),this}},{key:\"volume\",value:function(e){if(null==e)return this._volume;if(\"number\"!=typeof e)throw new TypeError(\"volume parameter must be a number\");return this._volume=Math.clamp(e,0,1),this._updateAudioVolume(),this}},{key:\"_updateAudioVolume\",value:function(){this.audio.volume=Math.clamp(this._volume*Q,0,1)}},{key:\"duration\",value:function(){return this.audio.duration}},{key:\"remaining\",value:function(){return this.audio.duration-this.audio.currentTime}},{key:\"isFailed\",value:function(){return this._error}},{key:\"isLoading\",value:function(){return this.audio.networkState===HTMLMediaElement.NETWORK_LOADING}},{key:\"isUnloaded\",value:function(){return!this.audio.hasChildNodes()}},{key:\"isUnavailable\",value:function(){return!this.hasSource()||this.isUnloaded()||this.isFailed()}},{key:\"isPlaying\",value:function(){return!this.audio.paused&&this.hasSomeData()}},{key:\"isPaused\",value:function(){return this.audio.paused&&(this.audio.duration===1/0||this.audio.currentTime>0)&&!this.audio.ended}},{key:\"isStopped\",value:function(){return this.audio.paused&&0===this.audio.currentTime}},{key:\"isEnded\",value:function(){return this.audio.ended}},{key:\"isFading\",value:function(){return null!==this._faderId}},{key:\"isSeeking\",value:function(){return this.audio.seeking}},{key:\"hasSource\",value:function(){return this.sources.length>0}},{key:\"hasNoData\",value:function(){return this.audio.readyState===HTMLMediaElement.HAVE_NOTHING}},{key:\"hasMetadata\",value:function(){return this.audio.readyState>=HTMLMediaElement.HAVE_METADATA}},{key:\"hasSomeData\",value:function(){return this.audio.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA}},{key:\"hasData\",value:function(){return this.audio.readyState===HTMLMediaElement.HAVE_ENOUGH_DATA}},{key:\"on\",value:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return jQuery.fn.on.apply(jQuery(this.audio),t),this}},{key:\"one\",value:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return jQuery.fn.one.apply(jQuery(this.audio),t),this}},{key:\"off\",value:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return jQuery.fn.off.apply(jQuery(this.audio),t),this}}],[{key:\"_verifyType\",value:function(t){if(!t||!Has.audio)return null;var r=e._types;if(!r.hasOwnProperty(t)){var n=document.createElement(\"audio\");r[t]=\"\"!==n.canPlayType(t).replace(/^no$/i,\"\")}return r[t]?t:null}},{key:\"getType\",value:function(t){if(!t||!Has.audio)return null;var r=e.formats,n=t.toLowerCase(),a=r.hasOwnProperty(n)?r[n]:\"audio/\"+n;return e._verifyType(a)}},{key:\"canPlayFormat\",value:function(t){return null!==e.getType(t)}},{key:\"canPlayType\",value:function(t){return null!==e._verifyType(t)}}]),e}();Object.defineProperties(F,{formats:{value:{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\"}},_types:{value:{}}});var B=function(){function e(t){if(_classCallCheck(this,e),t instanceof Array)this._create(t);else{if(!(t instanceof e))throw new Error(\"tracks parameter must be either an array, of track objects, or an AudioTrack instance\");this._copy(t)}}return _createClass(e,[{key:\"_create\",value:function(e){var t=this;this._finalize(e.map(function(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"tracks parameter array members must be objects\");var r=void 0,n=void 0,a=void 0,i=void 0;if(e instanceof F)r=!0,n=e.rate(),a=e.clone(),i=e.volume();else{if(!e.hasOwnProperty(\"track\"))throw new Error('track object missing required \"track\" property');if(!(e.track instanceof F))throw new Error('track object\\'s \"track\" property must be an AudioTrack object');r=e.hasOwnProperty(\"own\")&&e.own,n=e.hasOwnProperty(\"rate\")?e.rate:e.track.rate(),a=e.track,i=e.hasOwnProperty(\"volume\")?e.volume:e.track.volume()}return a.stop(),a.loop(!1),a.mute(!1),a.rate(n),a.volume(i),a.on(\"ended.AudioList\",function(){return t._onEnd()}),{own:r,track:a,volume:i,rate:n}}))}},{key:\"_copy\",value:function(e){this._finalize(clone(e.tracks))}},{key:\"_finalize\",value:function(e){Object.defineProperties(this,{tracks:{configurable:!0,value:Object.freeze(e)},queue:{configurable:!0,value:[]},current:{writable:!0,value:null},_rate:{writable:!0,value:1},_volume:{writable:!0,value:1},_mute:{writable:!0,value:!1},_loop:{writable:!0,value:!1},_shuffle:{writable:!0,value:!1}})}},{key:\"_destroy\",value:function(){this.stop(),this.tracks.filter(function(e){return e.own}).forEach(function(e){return e.track._destroy()}),delete this.tracks,delete this.queue}},{key:\"load\",value:function(){this.tracks.forEach(function(e){return e.track.load()})}},{key:\"unload\",value:function(){this.stop(),this.tracks.forEach(function(e){return e.track.unload()})}},{key:\"play\",value:function(){return null!==this.current&&!this.current.track.isUnavailable()&&!this.current.track.isEnded()||(0===this.queue.length&&this._fillQueue(),this._next())?this.current.track.play():Promise.reject(new Error(\"no tracks were available\"))}},{key:\"playWhenAllowed\",value:function(){var e=this;this.play().catch(function(){var t=C.map(function(e){return e+\".AudioList_playWhenAllowed\"}).join(\" \");jQuery(document).one(t,function(){jQuery(document).off(\".AudioList_playWhenAllowed\"),e.play()})})}},{key:\"pause\",value:function(){null!==this.current&&this.current.track.pause()}},{key:\"stop\",value:function(){null!==this.current&&(this.current.track.stop(),this.current=null),this._drainQueue()}},{key:\"skip\",value:function(){this._next()?this.current.track.play():this._loop&&this.play()}},{key:\"fade\",value:function(e,t,r){if(\"number\"!=typeof e)throw new TypeError(\"duration parameter must be a number\");if(\"number\"!=typeof t)throw new TypeError(\"toVolume parameter must be a number\");if(null!=r&&\"number\"!=typeof r)throw new TypeError(\"fromVolume parameter must be a number\");if(0===this.queue.length&&this._fillQueue(),null!==this.current&&!this.current.track.isUnavailable()&&!this.current.track.isEnded()||this._next()){var n=Math.clamp(t,0,1)*this.current.volume,a=void 0;return null!=r&&(a=Math.clamp(r,0,1)*this.current.volume),this._volume=t,this.current.track.fade(e,n,a)}}},{key:\"fadeIn\",value:function(e,t){return this.fade(e,1,t)}},{key:\"fadeOut\",value:function(e,t){return this.fade(e,0,t)}},{key:\"fadeStop\",value:function(){null!==this.current&&this.current.track.fadeStop()}},{key:\"loop\",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(e){return null==e?this._loop:(this._loop=!!e,this)})},{key:\"mute\",value:function(e){return null==e?this._mute:(this._mute=!!e,null!==this.current&&this.current.track.mute(this._mute),this)}},{key:\"rate\",value:function(e){if(null==e)return this._rate;if(\"number\"!=typeof e)throw new TypeError(\"rate parameter must be a number\");return this._rate=Math.clamp(e,.2,5),null!==this.current&&this.current.track.rate(this._rate*this.current.rate),this}},{key:\"shuffle\",value:function(e){var t=this;if(null==e)return this._shuffle;if(this._shuffle=!!e,this.queue.length>0&&(this._fillQueue(),!this._shuffle&&null!==this.current&&this.queue.length>1)){var r=this.queue.findIndex(function(e){return e===t.current});if(-1!==r){var n;(n=this.queue).push.apply(n,_toConsumableArray(this.queue.splice(0,r+1)))}}return this}},{key:\"volume\",value:function(e){if(null==e)return this._volume;if(\"number\"!=typeof e)throw new TypeError(\"volume parameter must be a number\");return this._volume=Math.clamp(e,0,1),null!==this.current&&this.current.track.volume(this._volume*this.current.volume),this}},{key:\"duration\",value:function(){if(arguments.length>0)throw new Error(\"duration takes no parameters\");return this.tracks.map(function(e){return e.track.duration()}).reduce(function(e,t){return e+t},0)}},{key:\"remaining\",value:function(){if(arguments.length>0)throw new Error(\"remaining takes no parameters\");var e=this.queue.map(function(e){return e.track.duration()}).reduce(function(e,t){return e+t},0);return null!==this.current&&(e+=this.current.track.remaining()),e}},{key:\"time\",value:function(){if(arguments.length>0)throw new Error(\"time takes no parameters\");return this.duration()-this.remaining()}},{key:\"isPlaying\",value:function(){return null!==this.current&&this.current.track.isPlaying()}},{key:\"isPaused\",value:function(){return null===this.current||this.current.track.isPaused()}},{key:\"isStopped\",value:function(){return 0===this.queue.length&&null===this.current}},{key:\"isEnded\",value:function(){return 0===this.queue.length&&(null===this.current||this.current.track.isEnded())}},{key:\"isFading\",value:function(){return null!==this.current&&this.current.track.isFading()}},{key:\"_next\",value:function(){null!==this.current&&(this.current.track.stop(),this.current=null);for(var e=void 0;e=this.queue.shift();)if(!e.track.isUnavailable()){this.current=e;break}return null!==this.current&&(this.current.track.mute(this._mute),this.current.track.rate(this._rate*this.current.rate),this.current.track.volume(this._volume*this.current.volume),this.current.track.loop(!1),!0)}},{key:\"_onEnd\",value:function(){if(0===this.queue.length){if(!this._loop)return;this._fillQueue()}this._next()&&this.current.track.play()}},{key:\"_drainQueue\",value:function(){this.queue.splice(0)}},{key:\"_fillQueue\",value:function(){var e;this._drainQueue(),(e=this.queue).push.apply(e,_toConsumableArray(this.tracks.filter(function(e){return!e.track.isUnavailable()}))),0!==this.queue.length&&this._shuffle&&(this.queue.shuffle(),this.queue.length>1&&this.queue[0]===this.current&&this.queue.push(this.queue.shift()))}}]),e}(),V=function(){function e(t){if(_classCallCheck(this,e),!(t instanceof Set||t instanceof e))throw new TypeError(\"list parameter must be a Set or a AudioRunner instance\");Object.defineProperties(this,{trackIds:{value:new Set(t instanceof e?t.trackIds:t)}})}return _createClass(e,[{key:\"load\",value:function(){e._run(this.trackIds,F.prototype.load)}},{key:\"unload\",value:function(){e._run(this.trackIds,F.prototype.unload)}},{key:\"play\",value:function(){e._run(this.trackIds,F.prototype.play)}},{key:\"playWhenAllowed\",value:function(){e._run(this.trackIds,F.prototype.playWhenAllowed)}},{key:\"pause\",value:function(){e._run(this.trackIds,F.prototype.pause)}},{key:\"stop\",value:function(){e._run(this.trackIds,F.prototype.stop)}},{key:\"fade\",value:function(t,r,n){if(null==t||null==r)throw new Error(\"fade requires parameters\");e._run(this.trackIds,F.prototype.fade,t,r,n)}},{key:\"fadeIn\",value:function(t,r){if(null==t)throw new Error(\"fadeIn requires a parameter\");e._run(this.trackIds,F.prototype.fadeIn,t,1,r)}},{key:\"fadeOut\",value:function(t,r){if(null==t)throw new Error(\"fadeOut requires a parameter\");e._run(this.trackIds,F.prototype.fadeOut,t,0,r)}},{key:\"fadeStop\",value:function(){e._run(this.trackIds,F.prototype.fadeStop)}},{key:\"loop\",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(t){if(null==t)throw new Error(\"loop requires a parameter\");return e._run(this.trackIds,F.prototype.loop,t),this})},{key:\"mute\",value:function(t){if(null==t)throw new Error(\"mute requires a parameter\");return e._run(this.trackIds,F.prototype.mute,t),this}},{key:\"rate\",value:function(t){if(null==t)throw new Error(\"rate requires a parameter\");return e._run(this.trackIds,F.prototype.rate,t),this}},{key:\"time\",value:function(t){if(null==t)throw new Error(\"time requires a parameter\");return e._run(this.trackIds,F.prototype.time,t),this}},{key:\"volume\",value:function(t){if(null==t)throw new Error(\"volume requires a parameter\");return e._run(this.trackIds,F.prototype.volume,t),this}},{key:\"on\",value:function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return e._run.apply(e,[this.trackIds,F.prototype.on].concat(r)),this}},{key:\"one\",value:function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return e._run.apply(e,[this.trackIds,F.prototype.one].concat(r)),this}},{key:\"off\",value:function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return e._run.apply(e,[this.trackIds,F.prototype.off].concat(r)),this}}],[{key:\"_run\",value:function(e,t){for(var r=arguments.length,n=Array(r>2?r-2:0),a=2;a<r;a++)n[a-2]=arguments[a];e.forEach(function(e){var r=N.get(e);r&&t.apply(r,n)})}}]),e}(),U=function(){function e(e,t){var a=void 0;if(r.lastIndex=t,null===(a=r.exec(e))||\"(\"!==a[0])throw new Error('invalid \":not()\" syntax: missing parentheticals');n.lastIndex=r.lastIndex;for(var i=r.lastIndex,o={str:\"\",nextMatch:-1},s=1;null!==(a=n.exec(e));)if(\"(\"===a[0]?++s:--s,s<1){o.nextMatch=n.lastIndex,o.str=e.slice(i,o.nextMatch-1);break}return o}function t(r){for(var n=[],a=/:?[^\\s:()]+/g,i=void 0;null!==(i=a.exec(r));){var o=i[0];if(\":not\"===o){if(0===n.length)throw new Error('invalid negation: no group ID preceded \":not()\"');var s=n[n.length-1];if(\":\"!==s.id[0])throw new Error('invalid negation of track \"'+s.id+'\": only groups may be negated with \":not()\"');var u=e(r,a.lastIndex);if(-1===u.nextMatch)throw new Error('unknown error parsing \":not()\"');a.lastIndex=u.nextMatch,s.not=t(u.str)}else n.push({id:o})}return n}var r=/\\S/g,n=/[()]/g;return t}();return Object.freeze(Object.defineProperties({},{tracks:{value:Object.freeze(Object.defineProperties({},{add:{value:e},delete:{value:t},clear:{value:r},has:{value:n},get:{value:a}}))},groups:{value:Object.freeze(Object.defineProperties({},{add:{value:i},delete:{value:o},clear:{value:s},has:{value:u},get:{value:l}}))},lists:{value:Object.freeze(Object.defineProperties({},{add:{value:c},delete:{value:d},clear:{value:f},has:{value:p},get:{value:h}}))},select:{value:g},load:{value:m},loadWithScreen:{value:v},mute:{value:y},muteOnHidden:{value:b},rate:{value:w},stop:{value:k},unload:{value:S},volume:{value:E}}))}(),State=function(){function e(){session.delete(\"state\"),H=[],$=c(),J=-1,G=[],Z=null===Z?null:new PRNGWrapper(Z.seed,!1)}function t(){if(session.has(\"state\")){var e=session.get(\"state\");return null!=e&&(n(e),!0)}return!1}function r(e){var t={index:J};return e?t.history=clone(H):t.delta=A(H),G.length>0&&(t.expired=[]),null!==Z&&(t.seed=Z.seed),t}function n(e,t){if(null==e)throw new Error(\"state object is null or undefined\");if(!e.hasOwnProperty(t?\"history\":\"delta\")||0===e[t?\"history\":\"delta\"].length)throw new Error(\"state object has no history or history is empty\");if(!e.hasOwnProperty(\"index\"))throw new Error(\"state object has no index\");if(null!==Z&&!e.hasOwnProperty(\"seed\"))throw new Error(\"state object has no seed, but PRNG is enabled\");if(null===Z&&e.hasOwnProperty(\"seed\"))throw new Error(\"state object has seed, but PRNG is disabled\");H=t?clone(e.history):P(e.delta),J=e.index,G=e.hasOwnProperty(\"expired\")?[].concat(_toConsumableArray(e.expired)):[],e.hasOwnProperty(\"seed\")&&(Z.seed=e.seed),g(J)}function a(){return r(!0)}function i(e){return n(e,!0)}function o(){return G}function s(){return G.length+v()}function u(){return G.concat(H.slice(0,v()).map(function(e){return e.title}))}function l(e){return null!=e&&\"\"!==e&&(!!G.includes(e)||!!H.slice(0,v()).some(function(t){return t.title===e}))}function c(e,t){return{title:null==e?\"\":String(e),variables:null==t?{}:clone(t)}}function d(){return $}function f(){return J}function p(){return $.title}function h(){return $.variables}function g(e){if(null==e)throw new Error(\"moment activation attempted with null or undefined\");switch(void 0===e?\"undefined\":_typeof(e)){case\"object\":$=clone(e);break;case\"number\":if(b())throw new Error(\"moment activation attempted with index on empty history\");if(e<0||e>=y())throw new RangeError(\"moment activation attempted with out-of-bounds index; need [0, \"+(y()-1)+\"], got \"+e);$=clone(H[e]);break;default:throw new TypeError('moment activation attempted with a \"'+(void 0===e?\"undefined\":_typeof(e))+'\"; must be an object or valid history stack index')}return null!==Z&&(Z=PRNGWrapper.unmarshal({seed:Z.seed,pull:$.pull})),session.set(\"state\",r()),jQuery.event.trigger(\":historyupdate\"),$}function m(){return H}function v(){return J+1}function y(){return H.length}function b(){return 0===H.length}function w(){return H.length>0?H[J]:null}function k(){return H.length>0?H[H.length-1]:null}function S(){return H.length>0?H[0]:null}function E(e){return b()||e<0||e>J?null:H[e]}function j(e){if(b())return null;var t=1+(e?Math.abs(e):0);return t>v()?null:H[v()-t]}function x(e){if(b()||null==e||\"\"===e)return!1;for(var t=J;t>=0;--t)if(H[t].title===e)return!0;return!1}function O(e){if(v()<y()&&H.splice(v(),y()-v()),H.push(c(e,$.variables)),Z&&(k().pull=Z.pull),Config.history.maxStates>0)for(;y()>Config.history.maxStates;)G.push(H.shift().title);return J=y()-1,g(J),v()}function T(e){return!(null==e||e<0||e>=y()||e===J)&&(J=e,g(J),!0)}function C(e){return null!=e&&0!==e&&T(J+e)}function A(e){if(!Array.isArray(e))return null;if(0===e.length)return[];for(var t=[clone(e[0])],r=1,n=e.length;r<n;++r)t.push(Diff.diff(e[r-1],e[r]));return t}function P(e){if(!Array.isArray(e))return null;if(0===e.length)return[];for(var t=[clone(e[0])],r=1,n=e.length;r<n;++r)t.push(Diff.patch(t[r-1],e[r]));return t}function _(e,t){if(!b()){var r=void 0;throw r=\"the Story JavaScript\",new Error(\"State.initPRNG must be called during initialization, within either \"+r+\" or the StoryInit special passage\")}Z=new PRNGWrapper(e,t),$.pull=Z.pull}function N(){return null!==Z}function I(){return Z?Z.pull:NaN}function L(){return Z?Z.seed:null}function D(){return Z?Z.random():Math.random()}function M(){Y={},TempVariables=Y}function Q(){return Y}function R(e){var t=F(e);if(null!==t){for(var r=t.names,n=t.store,a=0,i=r.length;a<i;++a){if(void 0===n[r[a]])return;n=n[r[a]]}return n}}function W(e,t){var r=F(e);if(null===r)return!1;for(var n=r.names,a=n.pop(),i=r.store,o=0,s=n.length;o<s;++o){if(void 0===i[n[o]])return!1;i=i[n[o]]}return i[a]=t,!0}function F(e){for(var t={store:\"$\"===e[0]?State.variables:State.temporary,names:[]},r=e,n=void 0;null!==(n=K.exec(r));)r=r.slice(n[0].length),n[1]?t.names.push(n[1]):n[2]?t.names.push(n[2]):n[3]?t.names.push(n[3]):n[4]?t.names.push(n[4]):n[5]?t.names.push(R(n[5])):n[6]&&t.names.push(Number(n[6]));return\"\"===r?t:null}function B(){storage.delete(X)}function V(e){if(\"string\"!=typeof e)throw new TypeError(\"State.metadata.delete key parameter must be a string (received: \"+(void 0===e?\"undefined\":_typeof(e))+\")\");var t=storage.get(X);t&&t.hasOwnProperty(e)&&(1===Object.keys(t).length?storage.delete(X):(delete t[e],storage.set(X,t)))}function U(e){if(\"string\"!=typeof e)throw new TypeError(\"State.metadata.get key parameter must be a string (received: \"+(void 0===e?\"undefined\":_typeof(e))+\")\");var t=storage.get(X);return t&&t.hasOwnProperty(e)?t[e]:undefined}function z(e){if(\"string\"!=typeof e)throw new TypeError(\"State.metadata.has key parameter must be a string (received: \"+(void 0===e?\"undefined\":_typeof(e))+\")\");var t=storage.get(X);return t&&t.hasOwnProperty(e)}function q(e,t){if(\"string\"!=typeof e)throw new TypeError(\"State.metadata.set key parameter must be a string (received: \"+(void 0===e?\"undefined\":_typeof(e))+\")\");if(void 0===t)V(e);else{var r=storage.get(X)||{};r[e]=t,storage.set(X,r)}}var H=[],$=c(),J=-1,G=[],Z=null,Y={},K=new RegExp(\"^(?:\"+Patterns.variableSigil+\"(\"+Patterns.identifier+\")|\\\\.(\"+Patterns.identifier+\")|\\\\[(?:(?:\\\"((?:\\\\\\\\.|[^\\\"\\\\\\\\])+)\\\")|(?:'((?:\\\\\\\\.|[^'\\\\\\\\])+)')|(\"+Patterns.variableSigil+Patterns.identifierFirstChar+\".*)|(\\\\d+))\\\\])\"),X=\"metadata\";return Object.freeze(Object.defineProperties({},{reset:{value:e},restore:{value:t},marshalForSave:{value:a},unmarshalForSave:{value:i},expired:{get:o},turns:{get:s},passages:{get:u},hasPlayed:{value:l},active:{get:d},activeIndex:{get:f},passage:{get:p},variables:{get:h},history:{get:m},length:{get:v},size:{get:y},isEmpty:{value:b},current:{get:w},top:{get:k},bottom:{get:S},index:{value:E},peek:{value:j},has:{value:x},create:{value:O},goTo:{value:T},go:{value:C},deltaEncode:{value:A},deltaDecode:{value:P},prng:{value:Object.freeze(Object.defineProperties({},{init:{value:_},isEnabled:{value:N},pull:{get:I},seed:{get:L}}))},random:{value:D},clearTemporary:{value:M},temporary:{get:Q},getVar:{value:R},setVar:{value:W},metadata:{value:Object.freeze(Object.defineProperties({},{clear:{value:B},delete:{value:V},get:{value:U},has:{value:z},set:{value:q}}))},initPRNG:{value:_},restart:{value:function(){return Engine.restart()}},backward:{value:function(){return Engine.backward()}},forward:{value:function(){return Engine.forward()}},display:{value:function(){return Engine.display.apply(Engine,arguments)}},show:{value:function(){return Engine.show.apply(Engine,arguments)}},play:{value:function(){return Engine.play.apply(Engine,arguments)}}}))}(),Scripting=function(){function addAccessibleClickHandler(e,t,r,n,a){\nif(arguments.length<2)throw new Error(\"addAccessibleClickHandler insufficient number of parameters\");var i=void 0,o=void 0;if(\"function\"==typeof t?(i=t,o={namespace:n,one:!!r}):(i=r,o={namespace:a,one:!!n,selector:t}),\"function\"!=typeof i)throw new TypeError(\"addAccessibleClickHandler handler parameter must be a function\");return jQuery(e).ariaClick(o,i)}function insertElement(e,t,r,n,a,i){var o=jQuery(document.createElement(t));return r&&o.attr(\"id\",r),n&&o.addClass(n),i&&o.attr(\"title\",i),a&&o.text(a),e&&o.appendTo(e),o[0]}function insertText(e,t){jQuery(e).append(document.createTextNode(t))}function removeChildren(e){jQuery(e).empty()}function removeElement(e){jQuery(e).remove()}function fade(e,t){function r(){i+=.05*a,n(o,Math.easeInOut(i)),(1===a&&i>=1||-1===a&&i<=0)&&(e.style.visibility=\"in\"===t.fade?\"visible\":\"hidden\",o.parentNode.replaceChild(e,o),o=null,window.clearInterval(s),t.onComplete&&t.onComplete())}function n(e,t){e.style.zoom=1,e.style.filter=\"alpha(opacity=\"+Math.floor(100*t)+\")\",e.style.opacity=t}var a=\"in\"===t.fade?1:-1,i=void 0,o=e.cloneNode(!0),s=void 0;e.parentNode.replaceChild(o,e),\"in\"===t.fade?(i=0,o.style.visibility=\"visible\"):i=1,n(o,i),s=window.setInterval(r,25)}function scrollWindowTo(e,t){function r(){l+=a,window.scroll(0,i+u*(s*Math.easeInOut(l))),l>=1&&window.clearInterval(c)}function n(e){for(var t=0;e.offsetParent;)t+=e.offsetTop,e=e.offsetParent;return t}var a=null!=t?Number(t):.1;Number.isNaN(a)||!Number.isFinite(a)||a<0?a=.1:a>1&&(a=1);var i=window.scrollY?window.scrollY:document.body.scrollTop,o=function(e){var t=n(e),r=t+e.offsetHeight,a=window.scrollY?window.scrollY:document.body.scrollTop,i=window.innerHeight?window.innerHeight:document.body.clientHeight,o=a+i;return t>=a&&r>o&&e.offsetHeight<i?t-(i-e.offsetHeight)+20:t}(e),s=Math.abs(i-o),u=i>o?-1:1,l=0,c=void 0;c=window.setInterval(r,25)}function either(){if(0!==arguments.length)return Array.prototype.concat.apply([],arguments).random()}function forget(e){if(\"string\"!=typeof e)throw new TypeError(\"forget key parameter must be a string (received: \"+Util.getType(e)+\")\");State.metadata.delete(e)}function hasVisited(){if(0===arguments.length)throw new Error(\"hasVisited called with insufficient parameters\");if(State.isEmpty())return!1;for(var e=Array.prototype.concat.apply([],arguments),t=State.passages,r=0,n=e.length;r<n;++r)if(!t.includes(e[r]))return!1;return!0}function lastVisited(){if(0===arguments.length)throw new Error(\"lastVisited called with insufficient parameters\");if(State.isEmpty())return-1;for(var e=Array.prototype.concat.apply([],arguments),t=State.passages,r=t.length-1,n=State.turns,a=0,i=e.length;a<i&&n>-1;++a){var o=t.lastIndexOf(e[a]);n=Math.min(n,-1===o?-1:r-o)}return n}function memorize(e,t){if(\"string\"!=typeof e)throw new TypeError(\"memorize key parameter must be a string (received: \"+Util.getType(e)+\")\");State.metadata.set(e,t)}function passage(){return State.passage}function previous(){var e=State.passages;if(arguments.length>0){var t=Number(arguments[0]);if(!Number.isSafeInteger(t)||t<1)throw new RangeError(\"previous offset parameter must be a positive integer greater than zero\");return e.length>t?e[e.length-1-t]:\"\"}for(var r=e.length-2;r>=0;--r)if(e[r]!==State.passage)return e[r];return\"\"}function random(){var e=void 0,t=void 0;switch(arguments.length){case 0:throw new Error(\"random called with insufficient parameters\");case 1:e=0,t=Math.trunc(arguments[0]);break;default:e=Math.trunc(arguments[0]),t=Math.trunc(arguments[1])}if(!Number.isInteger(e))throw new Error(\"random min parameter must be an integer\");if(!Number.isInteger(t))throw new Error(\"random max parameter must be an integer\");if(e>t){var r=[t,e];e=r[0],t=r[1]}return Math.floor(State.random()*(t-e+1))+e}function randomFloat(){var e=void 0,t=void 0;switch(arguments.length){case 0:throw new Error(\"randomFloat called with insufficient parameters\");case 1:e=0,t=Number(arguments[0]);break;default:e=Number(arguments[0]),t=Number(arguments[1])}if(Number.isNaN(e)||!Number.isFinite(e))throw new Error(\"randomFloat min parameter must be a number\");if(Number.isNaN(t)||!Number.isFinite(t))throw new Error(\"randomFloat max parameter must be a number\");if(e>t){var r=[t,e];e=r[0],t=r[1]}return State.random()*(t-e)+e}function recall(e,t){if(\"string\"!=typeof e)throw new TypeError(\"recall key parameter must be a string (received: \"+Util.getType(e)+\")\");return State.metadata.has(e)?State.metadata.get(e):t}function tags(){if(0===arguments.length)return Story.get(State.passage).tags.slice(0);for(var e=Array.prototype.concat.apply([],arguments),t=[],r=0,n=e.length;r<n;++r)t=t.concat(Story.get(e[r]).tags);return t}function temporary(){return State.temporary}function time(){return null===Engine.lastPlay?0:Util.now()-Engine.lastPlay}function turns(){return State.turns}function variables(){return State.variables}function visited(){if(State.isEmpty())return 0;for(var e=Array.prototype.concat.apply([],0===arguments.length?[State.passage]:arguments),t=State.passages,r=State.turns,n=0,a=e.length;n<a&&r>0;++n)r=Math.min(r,t.count(e[n]));return r}function visitedTags(){if(0===arguments.length)throw new Error(\"visitedTags called with insufficient parameters\");if(State.isEmpty())return 0;for(var e=Array.prototype.concat.apply([],arguments),t=e.length,r=State.passages,n=new Map,a=0,i=0,o=r.length;i<o;++i){var s=r[i];if(n.has(s))n.get(s)&&++a;else{var u=Story.get(s).tags;if(u.length>0){for(var l=0,c=0;c<t;++c)u.includes(e[c])&&++l;l===t?(++a,n.set(s,!0)):n.set(s,!1)}}}return a}function evalJavaScript(code,output){return function(code,output){return eval(code)}.call(output?{output:output}:null,String(code),output)}function evalTwineScript(code,output){return function(code,output){return eval(code)}.call(output?{output:output}:null,parse(String(code)),output)}var _ref8=function(){function e(e){return Util.parseUrl(e).path.replace(/^[^\\w]+|[^\\w]+$/g,\"\").replace(/[^\\w]+/g,\"-\").toLocaleLowerCase()}function t(t){return new Promise(function(r,n){jQuery(document.createElement(\"script\")).one(\"load abort error\",function(e){jQuery(e.target).off(),\"load\"===e.type?r(e.target):n(new Error('importScripts failed to load the script \"'+t+'\".'))}).appendTo(document.head).attr({id:\"script-imported-\"+e(t),type:\"text/javascript\",src:t})})}function r(t){return new Promise(function(r,n){jQuery(document.createElement(\"link\")).one(\"load abort error\",function(e){jQuery(e.target).off(),\"load\"===e.type?r(e.target):n(new Error('importStyles failed to load the stylesheet \"'+t+'\".'))}).appendTo(document.head).attr({id:\"style-imported-\"+e(t),rel:\"stylesheet\",href:t})})}function n(e){return e.reduce(function(e,t){return e=e.then(t)},Promise.resolve())}function a(){for(var e=arguments.length,r=Array(e),a=0;a<e;a++)r[a]=arguments[a];return Promise.all(r.map(function(e){return Array.isArray(e)?n(e.map(function(e){return function(){return t(e)}})):t(e)}))}function i(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return Promise.all(t.map(function(e){return Array.isArray(e)?n(e.map(function(e){return function(){return r(e)}})):r(e)}))}return{importScripts:a,importStyles:i}}(),importScripts=_ref8.importScripts,importStyles=_ref8.importStyles,parse=function(){function e(e){if(0!==r.lastIndex)throw new RangeError(\"Scripting.parse last index is non-zero at start\");for(var a=e,i=void 0;null!==(i=r.exec(a));)if(i[5]){var o=i[5];if(\"$\"===o||\"_\"===o)continue;if(n.test(o))o=o[0];else if(\"is\"===o){var s=r.lastIndex,u=a.slice(s);/^\\s+not\\b/.test(u)&&(a=a.splice(s,u.search(/\\S/)),o=\"isnot\")}t.hasOwnProperty(o)&&(a=a.splice(i.index,o.length,t[o]),r.lastIndex+=t[o].length-o.length)}return a}var t=Object.freeze({$:\"State.variables.\",_:\"State.temporary.\",to:\"=\",eq:\"==\",neq:\"!=\",is:\"===\",isnot:\"!==\",gt:\">\",gte:\">=\",lt:\"<\",lte:\"<=\",and:\"&&\",or:\"||\",not:\"!\",def:'\"undefined\" !== typeof',ndef:'\"undefined\" === typeof'}),r=new RegExp([\"(\\\"\\\"|'')\",'(\"(?:\\\\\\\\.|[^\"\\\\\\\\])+\")',\"('(?:\\\\\\\\.|[^'\\\\\\\\])+')\",\"([=+\\\\-*\\\\/%<>&\\\\|\\\\^~!?:,;\\\\(\\\\)\\\\[\\\\]{}]+)\",\"([^\\\"'=+\\\\-*\\\\/%<>&\\\\|\\\\^~!?:,;\\\\(\\\\)\\\\[\\\\]{}\\\\s]+)\"].join(\"|\"),\"g\"),n=new RegExp(\"^\"+Patterns.variable);return e}();return Object.freeze(Object.defineProperties({},{parse:{value:parse},evalJavaScript:{value:evalJavaScript},evalTwineScript:{value:evalTwineScript}}))}(),_ref9=function(){return{EOF:-1,Lexer:function(){function e(t,r){if(_classCallCheck(this,e),arguments.length<2)throw new Error(\"Lexer constructor called with too few parameters (source:string , initialState:function)\");Object.defineProperties(this,{source:{value:t},initial:{value:r},state:{writable:!0,value:r},start:{writable:!0,value:0},pos:{writable:!0,value:0},depth:{writable:!0,value:0},items:{writable:!0,value:[]},data:{writable:!0,value:{}}})}return _createClass(e,[{key:\"reset\",value:function(){this.state=this.initial,this.start=0,this.pos=0,this.depth=0,this.items=[],this.data={}}},{key:\"run\",value:function(){for(;null!==this.state;)this.state=this.state(this);return this.items}},{key:\"nextItem\",value:function(){for(;0===this.items.length&&null!==this.state;)this.state=this.state(this);return this.items.shift()}},{key:\"next\",value:function(){return this.pos>=this.source.length?-1:this.source[this.pos++]}},{key:\"peek\",value:function(){return this.pos>=this.source.length?-1:this.source[this.pos]}},{key:\"backup\",value:function(e){this.pos-=e||1}},{key:\"forward\",value:function(e){this.pos+=e||1}},{key:\"ignore\",value:function(){this.start=this.pos}},{key:\"accept\",value:function(e){var t=this.next();return-1!==t&&(!!e.includes(t)||(this.backup(),!1))}},{key:\"acceptRe\",value:function(e){var t=this.next();return-1!==t&&(!!e.test(t)||(this.backup(),!1))}},{key:\"acceptRun\",value:function(e){for(;;){var t=this.next();if(-1===t)return;if(!e.includes(t))break}this.backup()}},{key:\"acceptRunRe\",value:function(e){for(;;){var t=this.next();if(-1===t)return;if(!e.test(t))break}this.backup()}},{key:\"emit\",value:function(e){this.items.push({type:e,text:this.source.slice(this.start,this.pos),start:this.start,pos:this.pos}),this.start=this.pos}},{key:\"error\",value:function(e,t){if(arguments.length<2)throw new Error(\"Lexer.prototype.error called with too few parameters (type:number , message:string)\");return this.items.push({type:e,message:t,text:this.source.slice(this.start,this.pos),start:this.start,pos:this.pos}),null}}],[{key:\"enumFromNames\",value:function(e){var t=e.reduce(function(e,t,r){return e[t]=r,e},{});return Object.freeze(Object.assign(Object.create(null),t))}}]),e}()}}(),EOF=_ref9.EOF,Lexer=_ref9.Lexer,Wikifier=function(){var e=0,t=function(){function t(r,n,a){_classCallCheck(this,t),t.Parser.Profile.isEmpty()&&t.Parser.Profile.compile(),Object.defineProperties(this,{source:{value:String(n)},options:{writable:!0,value:Object.assign({profile:\"all\"},a)},nextMatch:{writable:!0,value:0},output:{writable:!0,value:null},_rawArgs:{writable:!0,value:\"\"}}),null==r?this.output=document.createDocumentFragment():r.jquery?this.output=r[0]:this.output=r;try{++e,this.subWikify(this.output),1===e&&Config.cleanupWikifierOutput&&convertBreaks(this.output)}finally{--e}}return _createClass(t,[{key:\"subWikify\",value:function(e,r,n){var a=this.output,i=void 0;this.output=e,null!=n&&\"object\"===(void 0===n?\"undefined\":_typeof(n))&&(i=this.options,this.options=Object.assign({},this.options,n));var o=t.Parser.Profile.get(this.options.profile),s=r?new RegExp(\"(?:\"+r+\")\",this.options.ignoreTerminatorCase?\"gim\":\"gm\"):null,u=void 0,l=void 0;do{if(o.parserRegExp.lastIndex=this.nextMatch,s&&(s.lastIndex=this.nextMatch),l=o.parserRegExp.exec(this.source),(u=s?s.exec(this.source):null)&&(!l||u.index<=l.index))return u.index>this.nextMatch&&this.outputText(this.output,this.nextMatch,u.index),this.matchStart=u.index,this.matchLength=u[0].length,this.matchText=u[0],this.nextMatch=s.lastIndex,this.output=a,void(i&&(this.options=i));if(l){l.index>this.nextMatch&&this.outputText(this.output,this.nextMatch,l.index),this.matchStart=l.index,this.matchLength=l[0].length,this.matchText=l[0],this.nextMatch=o.parserRegExp.lastIndex;for(var c=void 0,d=1,f=l.length;d<f;++d)if(l[d]){c=d-1;break}if(o.parsers[c].handler(this),null!=TempState.break)break}}while(u||l);null==TempState.break?this.nextMatch<this.source.length&&(this.outputText(this.output,this.nextMatch,this.source.length),this.nextMatch=this.source.length):this.output.lastChild&&this.output.lastChild.nodeType===Node.ELEMENT_NODE&&\"BR\"===this.output.lastChild.nodeName.toUpperCase()&&jQuery(this.output.lastChild).remove(),this.output=a,i&&(this.options=i)}},{key:\"outputText\",value:function(e,t,r){jQuery(e).append(document.createTextNode(this.source.substring(t,r)))}},{key:\"rawArgs\",value:function(){return this._rawArgs}},{key:\"fullArgs\",value:function(){return Scripting.parse(this._rawArgs)}}],[{key:\"wikifyEval\",value:function(e){var r=document.createDocumentFragment();new t(r,e);var n=r.querySelector(\".error\");if(null!==n)throw new Error(n.textContent.replace(errorPrologRegExp,\"\"));return r}},{key:\"createInternalLink\",value:function(e,t,r,n){var a=jQuery(document.createElement(\"a\"));return null!=t&&(a.attr(\"data-passage\",t),Story.has(t)?(a.addClass(\"link-internal\"),Config.addVisitedLinkClass&&State.hasPlayed(t)&&a.addClass(\"link-visited\")):a.addClass(\"link-broken\"),a.ariaClick({one:!0},function(){\"function\"==typeof n&&n(),Engine.play(t)})),r&&a.append(document.createTextNode(r)),e&&a.appendTo(e),a[0]}},{key:\"createExternalLink\",value:function(e,t,r){var n=jQuery(document.createElement(\"a\")).attr(\"target\",\"_blank\").addClass(\"link-external\").text(r).appendTo(e);return null!=t&&n.attr({href:t,tabindex:0}),n[0]}},{key:\"isExternalLink\",value:function(e){return!Story.has(e)&&(new RegExp(\"^\"+Patterns.url,\"gim\").test(e)||/[\\/.?#]/.test(e))}}]),t}();return Object.defineProperty(t,\"Parser\",{value:function(){function e(){return d}function t(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"Wikifier.Parser.add parser parameter must be an object\");if(!e.hasOwnProperty(\"name\"))throw new Error('parser object missing required \"name\" property');if(\"string\"!=typeof e.name)throw new Error('parser object \"name\" property must be a string');if(!e.hasOwnProperty(\"match\"))throw new Error('parser object missing required \"match\" property');if(\"string\"!=typeof e.match)throw new Error('parser object \"match\" property must be a string');if(!e.hasOwnProperty(\"handler\"))throw new Error('parser object missing required \"handler\" property');if(\"function\"!=typeof e.handler)throw new Error('parser object \"handler\" property must be a function');if(e.hasOwnProperty(\"profiles\")&&!Array.isArray(e.profiles))throw new Error('parser object \"profiles\" property must be an array');if(a(e.name))throw new Error('cannot clobber existing parser \"'+e.name+'\"');d.push(e)}function r(e){var t=d.find(function(t){return t.name===e});t&&d.delete(t)}function n(){return 0===d.length}function a(e){return!!d.find(function(t){return t.name===e})}function i(e){return d.find(function(t){return t.name===e})||null}function o(){return f}function s(){var e=d,t=e.filter(function(e){return!Array.isArray(e.profiles)||e.profiles.includes(\"core\")});return f=Object.freeze({all:{parsers:e,parserRegExp:new RegExp(e.map(function(e){return\"(\"+e.match+\")\"}).join(\"|\"),\"gm\")},core:{parsers:t,parserRegExp:new RegExp(t.map(function(e){return\"(\"+e.match+\")\"}).join(\"|\"),\"gm\")}})}function u(){return\"object\"!==(void 0===f?\"undefined\":_typeof(f))||0===Object.keys(f).length}function l(e){if(\"object\"!==(void 0===f?\"undefined\":_typeof(f))||!f.hasOwnProperty(e))throw new Error('nonexistent parser profile \"'+e+'\"');return f[e]}function c(e){return\"object\"===(void 0===f?\"undefined\":_typeof(f))&&f.hasOwnProperty(e)}var d=[],f=void 0;return Object.freeze(Object.defineProperties({},{parsers:{get:e},add:{value:t},delete:{value:r},isEmpty:{value:n},has:{value:a},get:{value:i},Profile:{value:Object.freeze(Object.defineProperties({},{profiles:{get:o},compile:{value:s},isEmpty:{value:u},has:{value:c},get:{value:l}}))}}))}()}),Object.defineProperties(t,{helpers:{value:{}},getValue:{value:State.getVar},setValue:{value:State.setVar},parse:{value:Scripting.parse},evalExpression:{value:Scripting.evalTwineScript},evalStatements:{value:Scripting.evalTwineScript},textPrimitives:{value:Patterns}}),Object.defineProperties(t.helpers,{inlineCss:{value:function(){function e(e){var r={classes:[],id:\"\",styles:{}},n=void 0;do{t.lastIndex=e.nextMatch;var a=t.exec(e.source);n=a&&a.index===e.nextMatch,n&&(a[1]?r.styles[Util.fromCssProperty(a[1])]=a[2].trim():a[3]?r.styles[Util.fromCssProperty(a[3])]=a[4].trim():a[5]?r.classes=r.classes.concat(a[5].slice(1).split(/\\./)):a[6]&&(r.id=a[6].slice(1).split(/#/).pop()),e.nextMatch=t.lastIndex)}while(n);return r}var t=new RegExp(Patterns.inlineCss,\"gm\");return e}()},evalText:{value:function(e){var t=void 0;try{switch(t=Scripting.evalTwineScript(e),void 0===t?\"undefined\":_typeof(t)){case\"string\":\"\"===t.trim()&&(t=e);break;case\"number\":t=String(t);break;default:t=e}}catch(r){t=e}return t}},evalPassageId:{value:function(e){return null==e||Story.has(e)?e:t.helpers.evalText(e)}},hasBlockContext:{value:function(e){for(var t=\"function\"==typeof window.getComputedStyle,r=e.length-1;r>=0;--r){var n=e[r];switch(n.nodeType){case Node.ELEMENT_NODE:var a=n.nodeName.toUpperCase();if(\"BR\"===a)return!0;var i=t?window.getComputedStyle(n,null):n.currentStyle;if(i&&i.display){if(\"none\"===i.display)continue;return\"block\"===i.display}switch(a){case\"ADDRESS\":case\"ARTICLE\":case\"ASIDE\":case\"BLOCKQUOTE\":case\"CENTER\":case\"DIV\":case\"DL\":case\"FIGURE\":case\"FOOTER\":case\"FORM\":case\"H1\":case\"H2\":case\"H3\":case\"H4\":case\"H5\":case\"H6\":case\"HEADER\":case\"HR\":case\"MAIN\":case\"NAV\":case\"OL\":case\"P\":case\"PRE\":case\"SECTION\":case\"TABLE\":case\"UL\":return!0}return!1;case Node.COMMENT_NODE:continue;default:return!1}}return!0}},createShadowSetterCallback:{value:function(){function e(){if(!a&&!(a=t.Parser.get(\"macro\")))throw new Error('cannot find \"macro\" parser');return a}function r(){for(var t=a||e(),r=new Set,n=t.context;null!==n;n=n.parent)n._shadows&&n._shadows.forEach(function(e){return r.add(e)});return[].concat(_toConsumableArray(r))}function n(e){var t={};return r().forEach(function(e){var r=e.slice(1),n=\"$\"===e[0]?State.variables:State.temporary;t[e]=n[r]}),function(){var r=Object.keys(t),n=r.length>0?{}:null;try{return r.forEach(function(e){var r=e.slice(1),a=\"$\"===e[0]?State.variables:State.temporary;a.hasOwnProperty(r)&&(n[r]=a[r]),a[r]=t[e]}),Scripting.evalJavaScript(e)}finally{r.forEach(function(e){var r=e.slice(1),a=\"$\"===e[0]?State.variables:State.temporary;t[e]=a[r],n.hasOwnProperty(r)?a[r]=n[r]:delete a[r]})}}}var a=null;return n}()},parseSquareBracketedMarkup:{value:function(){function e(e,t){e:for(;;)switch(e.next()){case\"\\\\\":var r=e.next();if(r!==EOF&&\"\\n\"!==r)break;case EOF:case\"\\n\":return EOF;case t:break e}return e.pos}function t(e){if(!e.accept(\"[\"))return e.error(o.Error,\"malformed square-bracketed markup\");if(e.accept(\"[\"))e.data.isLink=!0,e.emit(o.LinkMeta);else{if(e.accept(\"<>\"),!(e.accept(\"Ii\")&&e.accept(\"Mm\")&&e.accept(\"Gg\")&&e.accept(\"[\")))return e.error(o.Error,\"malformed square-bracketed markup\");e.data.isLink=!1,e.emit(o.ImageMeta)}return e.depth=2,r}function r(t){for(var r=t.data.isLink?\"link\":\"image\",i=s.None;;)switch(t.next()){case EOF:case\"\\n\":return t.error(o.Error,\"unterminated \"+r+\" markup\");case'\"':if(e(t,'\"')===EOF)return t.error(o.Error,\"unterminated double quoted string in \"+r+\" markup\");break;case\"|\":i===s.None&&(i=s.LTR,t.backup(),t.emit(o.Text),t.forward(),t.emit(o.DelimLTR));break;case\"-\":i===s.None&&\">\"===t.peek()&&(i=s.LTR,t.backup(),t.emit(o.Text),t.forward(2),t.emit(o.DelimLTR));break;case\"<\":i===s.None&&\"-\"===t.peek()&&(i=s.RTL,t.backup(),t.emit(t.data.isLink?o.Link:o.Source),t.forward(2),t.emit(o.DelimRTL));break;case\"[\":++t.depth;break;case\"]\":if(1===--t.depth)switch(t.peek()){case\"[\":return++t.depth,t.backup(),i===s.RTL?t.emit(o.Text):t.emit(t.data.isLink?o.Link:o.Source),t.forward(2),t.emit(o.InnerMeta),t.data.isLink?a:n;case\"]\":return--t.depth,t.backup(),i===s.RTL?t.emit(o.Text):t.emit(t.data.isLink?o.Link:o.Source),t.forward(2),t.emit(o.RightMeta),null;default:return t.error(o.Error,\"malformed \"+r+\" markup\")}}}function n(t){for(var r=t.data.isLink?\"link\":\"image\";;)switch(t.next()){case EOF:case\"\\n\":return t.error(o.Error,\"unterminated \"+r+\" markup\");case'\"':if(e(t,'\"')===EOF)return t.error(o.Error,\"unterminated double quoted string in \"+r+\" markup link component\");break;case\"[\":++t.depth;break;case\"]\":if(1===--t.depth)switch(t.peek()){case\"[\":return++t.depth,t.backup(),t.emit(o.Link),t.forward(2),t.emit(o.InnerMeta),a;case\"]\":return--t.depth,t.backup(),t.emit(o.Link),t.forward(2),t.emit(o.RightMeta),null;default:return t.error(o.Error,\"malformed \"+r+\" markup\")}}}function a(t){for(var r=t.data.isLink?\"link\":\"image\";;)switch(t.next()){case EOF:case\"\\n\":return t.error(o.Error,\"unterminated \"+r+\" markup\");case'\"':if(e(t,'\"')===EOF)return t.error(o.Error,\"unterminated double quoted string in \"+r+\" markup setter component\");break;case\"'\":if(e(t,\"'\")===EOF)return t.error(o.Error,\"unterminated single quoted string in \"+r+\" markup setter component\");break;case\"[\":++t.depth;break;case\"]\":if(1===--t.depth)return\"]\"!==t.peek()?t.error(o.Error,\"malformed \"+r+\" markup\"):(--t.depth,t.backup(),t.emit(o.Setter),t.forward(2),t.emit(o.RightMeta),null)}}function i(e){var r=new Lexer(e.source,t);r.start=r.pos=e.matchStart;var n={},a=r.run(),i=a.last();return i&&i.type===o.Error?n.error=i.message:a.forEach(function(e){var t=e.text.trim();switch(e.type){case o.ImageMeta:n.isImage=!0,\"<\"===t[1]?n.align=\"left\":\">\"===t[1]&&(n.align=\"right\");break;case o.LinkMeta:n.isLink=!0;break;case o.Link:\"~\"===t[0]?(n.forceInternal=!0,n.link=t.slice(1)):n.link=t;break;case o.Setter:n.setter=t;break;case o.Source:n.source=t;break;case o.Text:n.text=t}}),n.pos=r.pos,n}var o=Lexer.enumFromNames([\"Error\",\"DelimLTR\",\"DelimRTL\",\"InnerMeta\",\"ImageMeta\",\"LinkMeta\",\"Link\",\"RightMeta\",\"Setter\",\"Source\",\"Text\"]),s=Lexer.enumFromNames([\"None\",\"LTR\",\"RTL\"]);return i}()}}),t}();!function(){function e(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);t&&t.index===e.matchStart&&(e.nextMatch=this.lookahead.lastIndex,jQuery(document.createDocumentFragment()).append(t[1]).appendTo(e.output))}Wikifier.Parser.add({name:\"quoteByBlock\",profiles:[\"block\"],match:\"^<<<\\\\n\",terminator:\"^<<<\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));e.subWikify(jQuery(document.createElement(\"blockquote\")).appendTo(e.output).get(0),this.terminator)}}),Wikifier.Parser.add({name:\"quoteByLine\",profiles:[\"block\"],match:\"^>+\",lookahead:/^>+/gm,terminator:\"\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));var t=[e.output],r=0,n=e.matchLength,a=void 0,i=void 0;do{if(n>r)for(i=r;i<n;++i)t.push(jQuery(document.createElement(\"blockquote\")).appendTo(t[t.length-1]).get(0));else if(n<r)for(i=r;i>n;--i)t.pop();r=n,e.subWikify(t[t.length-1],this.terminator),jQuery(document.createElement(\"br\")).appendTo(t[t.length-1]),this.lookahead.lastIndex=e.nextMatch;var o=this.lookahead.exec(e.source);a=o&&o.index===e.nextMatch,a&&(n=o[0].length,e.nextMatch+=o[0].length)}while(a)}}),Wikifier.Parser.add({name:\"macro\",profiles:[\"core\"],match:\"<<\",lookahead:new RegExp(\"<<(/?\"+Patterns.macroName+\")(?:\\\\s*)((?:(?:`(?:\\\\\\\\.|[^`\\\\\\\\])*`)|(?:\\\"(?:\\\\\\\\.|[^\\\"\\\\\\\\])*\\\")|(?:'(?:\\\\\\\\.|[^'\\\\\\\\])*')|(?:\\\\[(?:[<>]?[Ii][Mm][Gg])?\\\\[[^\\\\r\\\\n]*?\\\\]\\\\]+)|[^>]|(?:>(?!>)))*)>>\",\"gm\"),working:{source:\"\",name:\"\",arguments:\"\",index:0},context:null,handler:function(e){var t=this.lookahead.lastIndex=e.matchStart;if(this.parseTag(e)){var r=e.nextMatch,n=this.working.name,a=this.working.arguments,i=void 0;try{if(!(i=Macro.get(n))){if(Macro.tags.has(n)){var o=Macro.tags.get(n);return throwError(e.output,\"child tag <<\"+n+\">> was found outside of a call to its parent macro\"+(1===o.length?\"\":\"s\")+\" <<\"+o.join(\">>, <<\")+\">>\",e.source.slice(t,e.nextMatch))}return throwError(e.output,\"macro <<\"+n+\">> does not exist\",e.source.slice(t,e.nextMatch))}var s=null;if(i.hasOwnProperty(\"tags\")&&!(s=this.parseBody(e,i)))return e.nextMatch=r,throwError(e.output,\"cannot find a closing tag for macro <<\"+n+\">>\",e.source.slice(t,e.nextMatch)+\"…\");if(\"function\"!=typeof i.handler)return throwError(e.output,\"macro <<\"+n+\">> handler function \"+(i.hasOwnProperty(\"handler\")?\"is not a function\":\"does not exist\"),e.source.slice(t,e.nextMatch));var u=s?s[0].args:this.createArgs(a,this.skipArgs(i,i.name));if(i.hasOwnProperty(\"_MACRO_API\")){this.context=new MacroContext({macro:i,name:n,args:u,payload:s,source:e.source.slice(t,e.nextMatch),parent:this.context,parser:e});try{i.handler.call(this.context)}finally{this.context=this.context.parent}}else{var l=e._rawArgs;e._rawArgs=a;try{i.handler(e.output,n,u,e,s)}finally{e._rawArgs=l}}}catch(r){return throwError(e.output,\"cannot execute \"+(i&&i.isWidget?\"widget\":\"macro\")+\" <<\"+n+\">>: \"+r.message,e.source.slice(t,e.nextMatch))}finally{this.working.source=\"\",this.working.name=\"\",this.working.arguments=\"\",this.working.index=0}}else e.outputText(e.output,e.matchStart,e.nextMatch)},parseTag:function(e){var t=this.lookahead.exec(e.source);return!(!t||t.index!==e.matchStart||!t[1])&&(e.nextMatch=this.lookahead.lastIndex,this.working.source=e.source.slice(t.index,this.lookahead.lastIndex),this.working.name=t[1],this.working.arguments=t[2],this.working.index=t.index,!0)},parseBody:function(e,t){for(var r=this.working.name,n=\"/\"+r,a=\"end\"+r,i=!!Array.isArray(t.tags)&&t.tags,o=[],s=-1,u=1,l=this.working.source,c=this.working.name,d=this.working.arguments,f=e.nextMatch;-1!==(e.matchStart=e.source.indexOf(this.match,e.nextMatch));)if(this.parseTag(e)){var p=this.working.source,h=this.working.name,g=this.working.arguments,m=this.working.index,v=e.nextMatch;switch(h){case r:++u;break;case a:case n:--u;break;default:if(1===u&&i)for(var y=0,b=i.length;y<b;++y)h===i[y]&&(o.push({source:l,name:c,arguments:d,args:this.createArgs(d,this.skipArgs(t,c)),contents:e.source.slice(f,m)}),l=p,c=h,d=g,f=v)}if(0===u){o.push({source:l,name:c,arguments:d,args:this.createArgs(d,this.skipArgs(t,c)),contents:e.source.slice(f,m)}),s=v;break}}else this.lookahead.lastIndex=e.nextMatch=e.matchStart+this.match.length;return-1!==s?(e.nextMatch=s,o):null},createArgs:function(e,t){var r=t?[]:this.parseArgs(e);return Object.defineProperties(r,{raw:{value:e},full:{value:Scripting.parse(e)}}),r},skipArgs:function(e,t){if(e.hasOwnProperty(\"skipArgs\")){var r=e.skipArgs;return\"boolean\"==typeof r&&r||Array.isArray(r)&&r.includes(t)}return!!e.hasOwnProperty(\"skipArg0\")&&(e.skipArg0&&e.name===t)},parseArgs:function(){function e(e,t){e:for(;;)switch(e.next()){case\"\\\\\":var r=e.next();if(r!==EOF&&\"\\n\"!==r)break;case EOF:case\"\\n\":return EOF;case t:break e}return e.pos}function t(e){var t=e.source.slice(e.pos).search(c);if(t===EOF)return null;switch(0!==t&&(e.pos+=t,e.ignore()),e.next()){case\"`\":return r;case'\"':return n;case\"'\":return a;case\"[\":return i;default:return o}}function r(r){return e(r,\"`\")===EOF?r.error(u.Error,\"unterminated backquote expression\"):(r.emit(u.Expression),t)}function n(r){return e(r,'\"')===EOF?r.error(u.Error,\"unterminated double quoted string\"):(r.emit(u.String),t)}function a(r){return e(r,\"'\")===EOF?r.error(u.Error,\"unterminated single quoted string\"):(r.emit(u.String),t)}function i(e){var r=void 0;if(e.accept(\"<>IiMmGg\")?(r=\"image\",e.acceptRun(\"<>IiMmGg\")):r=\"link\",!e.accept(\"[\"))return e.error(u.Error,\"malformed \"+r+\" markup\");e.depth=2;e:for(;;)switch(e.next()){case\"\\\\\":var n=e.next();if(n!==EOF&&\"\\n\"!==n)break;case EOF:case\"\\n\":return e.error(u.Error,\"unterminated \"+r+\" markup\");case\"[\":++e.depth;break;case\"]\":if(--e.depth<0)return e.error(u.Error,\"unexpected right square bracket ']'\");if(1===e.depth){if(\"]\"===e.next()){--e.depth;break e}e.backup()}}return e.emit(u.SquareBracket),t}function o(e){var r=e.source.slice(e.pos).search(l);return e.pos=r===EOF?e.source.length:e.pos+r,e.emit(u.Bareword),r===EOF?null:t}function s(e){var r=new Lexer(e,t),n=[];return r.run().forEach(function(e){var t=e.text;switch(e.type){case u.Error:throw new Error('unable to parse macro argument \"'+t+'\": '+e.message);case u.Bareword:if(d.test(t))t=State.getVar(t);else if(/^(?:settings|setup)[.[]/.test(t))try{t=Scripting.evalTwineScript(t)}catch(e){throw new Error('unable to parse macro argument \"'+t+'\": '+e.message)}else if(\"null\"===t)t=null;else if(\"undefined\"===t)t=undefined;else if(\"true\"===t)t=!0;else if(\"false\"===t)t=!1;else if(\"NaN\"===t)t=NaN;else{var r=Number(t);Number.isNaN(r)||(t=r)}break;case u.Expression:if(\"\"===(t=t.slice(1,-1).trim()))t=undefined;else try{t=Scripting.evalTwineScript(\"(\"+t+\")\")}catch(e){throw new Error('unable to parse macro argument expression \"'+t+'\": '+e.message)}break;case u.String:try{t=Scripting.evalJavaScript(t)}catch(e){throw new Error('unable to parse macro argument string \"'+t+'\": '+e.message)}break;case u.SquareBracket:var a=Wikifier.helpers.parseSquareBracketedMarkup({source:t,matchStart:0});if(a.hasOwnProperty(\"error\"))throw new Error('unable to parse macro argument \"'+t+'\": '+a.error);if(a.pos<t.length)throw new Error('unable to parse macro argument \"'+t+'\": unexpected character(s) \"'+t.slice(a.pos)+'\" (pos: '+a.pos+\")\");a.isLink?(t={isLink:!0},t.count=a.hasOwnProperty(\"text\")?2:1,t.link=Wikifier.helpers.evalPassageId(a.link),t.text=a.hasOwnProperty(\"text\")?Wikifier.helpers.evalText(a.text):t.link,t.external=!a.forceInternal&&Wikifier.isExternalLink(t.link),t.setFn=a.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(a.setter)):null):a.isImage&&(t=function(e){var t={source:e,isImage:!0};if(\"data:\"!==e.slice(0,5)&&Story.has(e)){var r=Story.get(e);r.tags.includes(\"Twine.image\")&&(t.source=r.text,t.passage=r.title)}return t}(Wikifier.helpers.evalPassageId(a.source)),a.hasOwnProperty(\"align\")&&(t.align=a.align),a.hasOwnProperty(\"text\")&&(t.title=Wikifier.helpers.evalText(a.text)),a.hasOwnProperty(\"link\")&&(t.link=Wikifier.helpers.evalPassageId(a.link),t.external=!a.forceInternal&&Wikifier.isExternalLink(t.link)),t.setFn=a.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(a.setter)):null)}n.push(t)}),n}var u=Lexer.enumFromNames([\"Error\",\"Bareword\",\"Expression\",\"String\",\"SquareBracket\"]),l=new RegExp(Patterns.space),c=new RegExp(Patterns.notSpace),d=new RegExp(\"^\"+Patterns.variable);return s}()}),Wikifier.Parser.add({name:\"link\",profiles:[\"core\"],match:\"\\\\[\\\\[[^[]\",handler:function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup(e);if(t.hasOwnProperty(\"error\"))return void e.outputText(e.output,e.matchStart,e.nextMatch);e.nextMatch=t.pos;var r=Wikifier.helpers.evalPassageId(t.link),n=t.hasOwnProperty(\"text\")?Wikifier.helpers.evalText(t.text):r,a=t.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(t.setter)):null,i=(Config.debug?new DebugView(e.output,\"link-markup\",\"[[link]]\",e.source.slice(e.matchStart,e.nextMatch)):e).output;t.forceInternal||!Wikifier.isExternalLink(r)?Wikifier.createInternalLink(i,r,n,a):Wikifier.createExternalLink(i,r,n)}}),Wikifier.Parser.add({name:\"urlLink\",profiles:[\"core\"],match:Patterns.url,handler:function(e){e.outputText(Wikifier.createExternalLink(e.output,e.matchText),e.matchStart,e.nextMatch)}}),Wikifier.Parser.add({name:\"image\",profiles:[\"core\"],match:\"\\\\[[<>]?[Ii][Mm][Gg]\\\\[\",handler:function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup(e);if(t.hasOwnProperty(\"error\"))return void e.outputText(e.output,e.matchStart,e.nextMatch);e.nextMatch=t.pos;var r=void 0;Config.debug&&(r=new DebugView(e.output,\"image-markup\",t.hasOwnProperty(\"link\")?\"[img[][link]]\":\"[img[]]\",e.source.slice(e.matchStart,e.nextMatch)),r.modes({block:!0}))\n;var n=t.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(t.setter)):null,a=(Config.debug?r:e).output,i=void 0;if(t.hasOwnProperty(\"link\")){var o=Wikifier.helpers.evalPassageId(t.link);a=t.forceInternal||!Wikifier.isExternalLink(o)?Wikifier.createInternalLink(a,o,null,n):Wikifier.createExternalLink(a,o),a.classList.add(\"link-image\")}if(a=jQuery(document.createElement(\"img\")).appendTo(a).get(0),i=Wikifier.helpers.evalPassageId(t.source),\"data:\"!==i.slice(0,5)&&Story.has(i)){var s=Story.get(i);s.tags.includes(\"Twine.image\")&&(a.setAttribute(\"data-passage\",s.title),i=s.text.trim())}a.src=i,t.hasOwnProperty(\"text\")&&(a.title=Wikifier.helpers.evalText(t.text)),t.hasOwnProperty(\"align\")&&(a.align=t.align)}}),Wikifier.Parser.add({name:\"monospacedByBlock\",profiles:[\"block\"],match:\"^\\\\{\\\\{\\\\{\\\\n\",lookahead:/^\\{\\{\\{\\n((?:^[^\\n]*\\n)+?)(^\\}\\}\\}$\\n?)/gm,handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);if(t&&t.index===e.matchStart){var r=jQuery(document.createElement(\"pre\"));jQuery(document.createElement(\"code\")).text(t[1]).appendTo(r),r.appendTo(e.output),e.nextMatch=this.lookahead.lastIndex}}}),Wikifier.Parser.add({name:\"formatByChar\",profiles:[\"core\"],match:\"''|//|__|\\\\^\\\\^|~~|==|\\\\{\\\\{\\\\{\",handler:function(e){switch(e.matchText){case\"''\":e.subWikify(jQuery(document.createElement(\"strong\")).appendTo(e.output).get(0),\"''\");break;case\"//\":e.subWikify(jQuery(document.createElement(\"em\")).appendTo(e.output).get(0),\"//\");break;case\"__\":e.subWikify(jQuery(document.createElement(\"u\")).appendTo(e.output).get(0),\"__\");break;case\"^^\":e.subWikify(jQuery(document.createElement(\"sup\")).appendTo(e.output).get(0),\"\\\\^\\\\^\");break;case\"~~\":e.subWikify(jQuery(document.createElement(\"sub\")).appendTo(e.output).get(0),\"~~\");break;case\"==\":e.subWikify(jQuery(document.createElement(\"s\")).appendTo(e.output).get(0),\"==\");break;case\"{{{\":var t=/\\{\\{\\{((?:.|\\n)*?)\\}\\}\\}/gm;t.lastIndex=e.matchStart;var r=t.exec(e.source);r&&r.index===e.matchStart&&(jQuery(document.createElement(\"code\")).text(r[1]).appendTo(e.output),e.nextMatch=t.lastIndex)}}}),Wikifier.Parser.add({name:\"customStyle\",profiles:[\"core\"],match:\"@@\",terminator:\"@@\",blockRe:/\\s*\\n/gm,handler:function(e){var t=Wikifier.helpers.inlineCss(e);this.blockRe.lastIndex=e.nextMatch;var r=this.blockRe.exec(e.source),n=r&&r.index===e.nextMatch,a=jQuery(document.createElement(n?\"div\":\"span\")).appendTo(e.output);0===t.classes.length&&\"\"===t.id&&0===Object.keys(t.styles).length?a.addClass(\"marked\"):(t.classes.forEach(function(e){return a.addClass(e)}),\"\"!==t.id&&a.attr(\"id\",t.id),a.css(t.styles)),n?(e.nextMatch+=r[0].length,e.subWikify(a[0],\"\\\\n?\"+this.terminator)):e.subWikify(a[0],this.terminator)}}),Wikifier.Parser.add({name:\"verbatimText\",profiles:[\"core\"],match:'\"{3}|<[Nn][Oo][Ww][Ii][Kk][Ii]>',lookahead:/(?:\"{3}((?:.|\\n)*?)\"{3})|(?:<[Nn][Oo][Ww][Ii][Kk][Ii]>((?:.|\\n)*?)<\\/[Nn][Oo][Ww][Ii][Kk][Ii]>)/gm,handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);t&&t.index===e.matchStart&&(e.nextMatch=this.lookahead.lastIndex,jQuery(document.createElement(\"span\")).addClass(\"verbatim\").text(t[1]||t[2]).appendTo(e.output))}}),Wikifier.Parser.add({name:\"horizontalRule\",profiles:[\"core\"],match:\"^----+$\\\\n?|<[Hh][Rr]\\\\s*/?>\\\\n?\",handler:function(e){jQuery(document.createElement(\"hr\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"emdash\",profiles:[\"core\"],match:\"--\",handler:function(e){jQuery(document.createTextNode(\"—\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"doubleDollarSign\",profiles:[\"core\"],match:\"\\\\${2}\",handler:function(e){jQuery(document.createTextNode(\"$\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"nakedVariable\",profiles:[\"core\"],match:Patterns.variable+\"(?:(?:\\\\.\"+Patterns.identifier+\")|(?:\\\\[\\\\d+\\\\])|(?:\\\\[\\\"(?:\\\\\\\\.|[^\\\"\\\\\\\\])+\\\"\\\\])|(?:\\\\['(?:\\\\\\\\.|[^'\\\\\\\\])+'\\\\])|(?:\\\\[\"+Patterns.variable+\"\\\\]))*\",handler:function(e){var t=toStringOrDefault(State.getVar(e.matchText),null);null===t?jQuery(document.createTextNode(e.matchText)).appendTo(e.output):new Wikifier((Config.debug?new DebugView(e.output,\"variable\",e.matchText,e.matchText):e).output,t)}}),Wikifier.Parser.add({name:\"template\",profiles:[\"core\"],match:\"\\\\?\"+Patterns.templateName,handler:function(e){var t=e.matchText.slice(1),r=Template.get(t),n=null;switch(r instanceof Array&&(r=r.random()),void 0===r?\"undefined\":_typeof(r)){case\"function\":try{n=toStringOrDefault(r.call({name:t}),null)}catch(r){return throwError(e.output,\"cannot execute function template ?\"+t+\": \"+r.message,e.source.slice(e.matchStart,e.nextMatch))}break;case\"string\":n=r}null===n?jQuery(document.createTextNode(e.matchText)).appendTo(e.output):new Wikifier((Config.debug?new DebugView(e.output,\"template\",e.matchText,e.matchText):e).output,n)}}),Wikifier.Parser.add({name:\"heading\",profiles:[\"block\"],match:\"^!{1,6}\",terminator:\"\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));e.subWikify(jQuery(document.createElement(\"h\"+e.matchLength)).appendTo(e.output).get(0),this.terminator)}}),Wikifier.Parser.add({name:\"table\",profiles:[\"block\"],match:\"^\\\\|(?:[^\\\\n]*)\\\\|(?:[fhck]?)$\",lookahead:/^\\|([^\\n]*)\\|([fhck]?)$/gm,rowTerminator:\"\\\\|(?:[cfhk]?)$\\\\n?\",cellPattern:\"(?:\\\\|([^\\\\n\\\\|]*)\\\\|)|(\\\\|[cfhk]?$\\\\n?)\",cellTerminator:\"(?:\\\\u0020*)\\\\|\",rowTypes:{c:\"caption\",f:\"tfoot\",h:\"thead\",\"\":\"tbody\"},handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));var t=jQuery(document.createElement(\"table\")).appendTo(e.output).get(0),r=[],n=null,a=null,i=0,o=void 0;e.nextMatch=e.matchStart;do{this.lookahead.lastIndex=e.nextMatch;var s=this.lookahead.exec(e.source);if(o=s&&s.index===e.nextMatch){var u=s[2];\"k\"===u?(t.className=s[1],e.nextMatch+=s[0].length+1):(u!==n&&(n=u,a=jQuery(document.createElement(this.rowTypes[u])).appendTo(t)),\"c\"===n?(a.css(\"caption-side\",0===i?\"top\":\"bottom\"),e.nextMatch+=1,e.subWikify(a[0],this.rowTerminator)):this.rowHandler(e,jQuery(document.createElement(\"tr\")).appendTo(a).get(0),r),++i)}}while(o)},rowHandler:function(e,t,r){var n=this,a=new RegExp(this.cellPattern,\"gm\"),i=0,o=1,s=void 0;do{a.lastIndex=e.nextMatch;var u=a.exec(e.source);if(s=u&&u.index===e.nextMatch){if(\"~\"===u[1]){var l=r[i];l&&(++l.rowCount,l.$element.attr(\"rowspan\",l.rowCount).css(\"vertical-align\",\"middle\")),e.nextMatch=u.index+u[0].length-1}else if(\">\"===u[1])++o,e.nextMatch=u.index+u[0].length-1;else{if(u[2]){e.nextMatch=u.index+u[0].length;break}!function(){++e.nextMatch;for(var a=Wikifier.helpers.inlineCss(e),s=!1,u=!1,l=void 0;\" \"===e.source.substr(e.nextMatch,1);)s=!0,++e.nextMatch;\"!\"===e.source.substr(e.nextMatch,1)?(l=jQuery(document.createElement(\"th\")).appendTo(t),++e.nextMatch):l=jQuery(document.createElement(\"td\")).appendTo(t),r[i]={rowCount:1,$element:l},o>1&&(l.attr(\"colspan\",o),o=1),e.subWikify(l[0],n.cellTerminator),\" \"===e.matchText.substr(e.matchText.length-2,1)&&(u=!0),a.classes.forEach(function(e){return l.addClass(e)}),\"\"!==a.id&&l.attr(\"id\",a.id),s&&u?a.styles[\"text-align\"]=\"center\":s?a.styles[\"text-align\"]=\"right\":u&&(a.styles[\"text-align\"]=\"left\"),l.css(a.styles),e.nextMatch=e.nextMatch-1}()}++i}}while(s)}}),Wikifier.Parser.add({name:\"list\",profiles:[\"block\"],match:\"^(?:(?:\\\\*+)|(?:#+))\",lookahead:/^(?:(\\*+)|(#+))/gm,terminator:\"\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));e.nextMatch=e.matchStart;var t=[e.output],r=null,n=0,a=void 0,i=void 0;do{this.lookahead.lastIndex=e.nextMatch;var o=this.lookahead.exec(e.source);if(a=o&&o.index===e.nextMatch){var s=o[2]?\"ol\":\"ul\",u=o[0].length;if(e.nextMatch+=o[0].length,u>n)for(i=n;i<u;++i)t.push(jQuery(document.createElement(s)).appendTo(t[t.length-1]).get(0));else if(u<n)for(i=n;i>u;--i)t.pop();else u===n&&s!==r&&(t.pop(),t.push(jQuery(document.createElement(s)).appendTo(t[t.length-1]).get(0)));n=u,r=s,e.subWikify(jQuery(document.createElement(\"li\")).appendTo(t[t.length-1]).get(0),this.terminator)}}while(a)}}),Wikifier.Parser.add({name:\"commentByBlock\",profiles:[\"core\"],match:\"(?:/(?:%|\\\\*))|(?:\\x3c!--)\",lookahead:/(?:\\/(%|\\*)(?:(?:.|\\n)*?)\\1\\/)|(?:<!--(?:(?:.|\\n)*?)-->)/gm,handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);t&&t.index===e.matchStart&&(e.nextMatch=this.lookahead.lastIndex)}}),Wikifier.Parser.add({name:\"lineContinuation\",profiles:[\"core\"],match:\"\\\\\\\\\"+Patterns.spaceNoTerminator+\"*\\\\n|\\\\n\"+Patterns.spaceNoTerminator+\"*\\\\\\\\|\\\\n?\\\\\\\\\"+Patterns.spaceNoTerminator+\"*$|^\"+Patterns.spaceNoTerminator+\"*\\\\\\\\\\\\n?\",handler:function(e){e.nextMatch=e.matchStart+e.matchLength}}),Wikifier.Parser.add({name:\"lineBreak\",profiles:[\"core\"],match:\"\\\\n|<[Bb][Rr]\\\\s*/?>\",handler:function(e){e.options.nobr||jQuery(document.createElement(\"br\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"htmlCharacterReference\",profiles:[\"core\"],match:\"(?:(?:&#?[0-9A-Za-z]{2,8};|.)(?:&#?(?:x0*(?:3[0-6][0-9A-Fa-f]|1D[C-Fc-f][0-9A-Fa-f]|20[D-Fd-f][0-9A-Fa-f]|FE2[0-9A-Fa-f])|0*(?:76[89]|7[7-9][0-9]|8[0-7][0-9]|761[6-9]|76[2-7][0-9]|84[0-3][0-9]|844[0-7]|6505[6-9]|6506[0-9]|6507[0-1]));)+|&#?[0-9A-Za-z]{2,8};)\",handler:function(e){jQuery(document.createDocumentFragment()).append(e.matchText).appendTo(e.output)}}),Wikifier.Parser.add({name:\"xmlProlog\",profiles:[\"core\"],match:\"<\\\\?[Xx][Mm][Ll][^>]*\\\\?>\",handler:function(e){e.nextMatch=e.matchStart+e.matchLength}}),Wikifier.Parser.add({name:\"verbatimHtml\",profiles:[\"core\"],match:\"<[Hh][Tt][Mm][Ll]>\",lookahead:/<[Hh][Tt][Mm][Ll]>((?:.|\\n)*?)<\\/[Hh][Tt][Mm][Ll]>/gm,handler:e}),Wikifier.Parser.add({name:\"verbatimSvgTag\",profiles:[\"core\"],match:\"<[Ss][Vv][Gg][^>]*>\",lookahead:/(<[Ss][Vv][Gg][^>]*>(?:.|\\n)*?<\\/[Ss][Vv][Gg]>)/gm,handler:e}),Wikifier.Parser.add({name:\"verbatimScriptTag\",profiles:[\"core\"],match:\"<[Ss][Cc][Rr][Ii][Pp][Tt][^>]*>\",lookahead:/(<[Ss][Cc][Rr][Ii][Pp][Tt]*>(?:.|\\n)*?<\\/[Ss][Cc][Rr][Ii][Pp][Tt]>)/gm,handler:e}),Wikifier.Parser.add({name:\"styleTag\",profiles:[\"core\"],match:\"<[Ss][Tt][Yy][Ll][Ee][^>]*>\",lookahead:/(<[Ss][Tt][Yy][Ll][Ee]*>)((?:.|\\n)*?)(<\\/[Ss][Tt][Yy][Ll][Ee]>)/gm,imageMarkup:new RegExp(Patterns.cssImage,\"g\"),hasImageMarkup:new RegExp(Patterns.cssImage),handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);if(t&&t.index===e.matchStart){e.nextMatch=this.lookahead.lastIndex;var r=t[2];this.hasImageMarkup.test(r)&&(this.imageMarkup.lastIndex=0,r=r.replace(this.imageMarkup,function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup({source:e,matchStart:0});if(t.hasOwnProperty(\"error\")||t.pos<e.length)return e;var r=t.source;if(\"data:\"!==r.slice(0,5)&&Story.has(r)){var n=Story.get(r);n.tags.includes(\"Twine.image\")&&(r=n.text)}return'url(\"'+r.replace(/\"/g,\"%22\")+'\")'})),jQuery(document.createDocumentFragment()).append(t[1]+r+t[3]).appendTo(e.output)}}}),Wikifier.Parser.add({name:\"htmlTag\",profiles:[\"core\"],match:\"<\\\\w+(?:\\\\s+[^\\\\u0000-\\\\u001F\\\\u007F-\\\\u009F\\\\s\\\"'>\\\\/=]+(?:\\\\s*=\\\\s*(?:\\\"[^\\\"]*?\\\"|'[^']*?'|[^\\\\s\\\"'=<>`]+))?)*\\\\s*\\\\/?>\",tagRe:/^<(\\w+)/,mediaElements:[\"audio\",\"img\",\"source\",\"track\",\"video\"],nobrElements:[\"audio\",\"colgroup\",\"datalist\",\"dl\",\"figure\",\"ol\",\"optgroup\",\"picture\",\"select\",\"table\",\"tbody\",\"tfoot\",\"thead\",\"tr\",\"ul\",\"video\"],voidElements:[\"area\",\"base\",\"br\",\"col\",\"embed\",\"hr\",\"img\",\"input\",\"keygen\",\"link\",\"menuitem\",\"meta\",\"param\",\"source\",\"track\",\"wbr\"],handler:function(e){var t=this.tagRe.exec(e.matchText),r=t&&t[1],n=r&&r.toLowerCase();if(n){var a=this.voidElements.includes(n)||e.matchText.endsWith(\"/>\"),i=this.nobrElements.includes(n),o=void 0,s=void 0;if(!a){o=\"<\\\\/\"+n+\"\\\\s*>\";var u=new RegExp(o,\"gim\");u.lastIndex=e.matchStart,s=u.exec(e.source)}if(!a&&!s)return throwError(e.output,\"cannot find a closing tag for HTML <\"+r+\">\",e.matchText+\"…\");var l=e.output,c=document.createElement(e.output.tagName),d=void 0;for(c.innerHTML=e.matchText;c.firstChild;)c=c.firstChild;try{this.processAttributeDirectives(c)}catch(t){return throwError(e.output,\"<\"+n+\">: \"+t.message,e.matchText+\"…\")}c.hasAttribute(\"data-passage\")&&(this.processDataAttributes(c,n),Config.debug&&(d=new DebugView(e.output,\"html-\"+n,n,e.matchText),d.modes({block:\"img\"===n,nonvoid:s}),l=d.output)),s&&(e.subWikify(c,o,{ignoreTerminatorCase:!0,nobr:i}),d&&jQuery(c).find(\".debug.block\").length>0&&d.modes({block:!0})),l.appendChild(\"track\"===n?c.cloneNode(!0):c)}},processAttributeDirectives:function(e){[].concat(_toConsumableArray(e.attributes)).forEach(function(t){var r=t.name,n=t.value,a=\"@\"===r[0];if(a||r.startsWith(\"sc-eval:\")){var i=r.slice(a?1:8),o=void 0;try{o=Scripting.evalTwineScript(n)}catch(e){throw new Error('bad evaluation from attribute directive \"'+r+'\": '+e.message)}try{e.setAttribute(i,o),e.removeAttribute(r)}catch(e){throw new Error('cannot transform attribute directive \"'+r+'\" into attribute \"'+i+'\"')}}})},processDataAttributes:function(e,t){var r=e.getAttribute(\"data-passage\");if(null!=r){var n=Wikifier.helpers.evalPassageId(r);if(n!==r&&(r=n,e.setAttribute(\"data-passage\",n)),\"\"!==r)if(this.mediaElements.includes(t)){if(\"data:\"!==r.slice(0,5)&&Story.has(r)){r=Story.get(r);var a=void 0,i=void 0;switch(t){case\"audio\":case\"video\":i=\"Twine.\"+t;break;case\"img\":i=\"Twine.image\";break;case\"track\":i=\"Twine.vtt\";break;case\"source\":var o=$(e).closest(\"audio,picture,video\");o.length&&(a=o.get(0).tagName.toLowerCase(),i=\"Twine.\"+(\"picture\"===a?\"image\":a))}r.tags.includes(i)&&(e[\"picture\"===a?\"srcset\":\"src\"]=r.text.trim())}}else{var s=e.getAttribute(\"data-setter\"),u=void 0;null!=s&&\"\"!==(s=String(s).trim())&&(u=Wikifier.helpers.createShadowSetterCallback(Scripting.parse(s))),Story.has(r)?(e.classList.add(\"link-internal\"),Config.addVisitedLinkClass&&State.hasPlayed(r)&&e.classList.add(\"link-visited\")):e.classList.add(\"link-broken\"),jQuery(e).ariaClick({one:!0},function(){\"function\"==typeof u&&u.call(this),Engine.play(r)})}}}})}();var Template=function(){function e(e,t){if(!(s(t)||t instanceof Array&&t.length>0&&t.every(s)))throw new Error(\"invalid template type (\"+e+\"); templates must be: functions, strings, or an array of either\");(e instanceof Array?e:[e]).forEach(function(e){if(i.has(e))throw new Error(\"cannot clobber existing template ?\"+e);if(!o.test(e))throw new Error('invalid template name \"'+e+'\"');i.set(e,t)})}function t(e){(e instanceof Array?e:[e]).forEach(function(e){return i.delete(e)})}function r(e){return i.has(e)?i.get(e):null}function n(e){return i.has(e)}function a(){return i.size}var i=new Map,o=new RegExp(\"^(?:\"+Patterns.templateName+\")$\"),s=function(e){var t=void 0===e?\"undefined\":_typeof(e);return\"function\"===t||\"string\"===t};return Object.freeze(Object.defineProperties({},{add:{value:e},delete:{value:t},get:{value:r},has:{value:n},size:{get:a}}))}(),Macro=function(){function e(t,r,a){if(Array.isArray(t))return void t.forEach(function(t){return e(t,r,a)});if(!f.test(t))throw new Error('invalid macro name \"'+t+'\"');if(n(t))throw new Error(\"cannot clobber existing macro <<\"+t+\">>\");if(u(t))throw new Error(\"cannot clobber child tag <<\"+t+\">> of parent macro\"+(1===d[t].length?\"\":\"s\")+\" <<\"+d[t].join(\">>, <<\")+\">>\");try{if(\"object\"===(void 0===r?\"undefined\":_typeof(r)))c[t]=a?clone(r):r;else{if(!n(r))throw new Error(\"cannot create alias of nonexistent macro <<\"+r+\">>\");c[t]=a?clone(c[r]):c[r]}Object.defineProperty(c,t,{writable:!1}),c[t]._MACRO_API=!0}catch(e){throw\"TypeError\"===e.name?new Error(\"cannot clobber protected macro <<\"+t+\">>\"):new Error(\"unknown error when attempting to add macro <<\"+t+\">>: [\"+e.name+\"] \"+e.message)}if(c[t].hasOwnProperty(\"tags\"))if(null==c[t].tags)o(t);else{if(!Array.isArray(c[t].tags))throw new Error('bad value for \"tags\" property of macro <<'+t+\">>\");o(t,c[t].tags)}}function t(e){if(Array.isArray(e))return void e.forEach(function(e){return t(e)});if(n(e)){c[e].hasOwnProperty(\"tags\")&&s(e);try{Object.defineProperty(c,e,{writable:!0}),delete c[e]}catch(t){throw new Error(\"unknown error removing macro <<\"+e+\">>: \"+t.message)}}else if(u(e))throw new Error(\"cannot remove child tag <<\"+e+\">> of parent macro <<\"+d[e]+\">>\")}function r(){return 0===Object.keys(c).length}function n(e){return c.hasOwnProperty(e)}function a(e){var t=null;return n(e)&&\"function\"==typeof c[e].handler?t=c[e]:macros.hasOwnProperty(e)&&\"function\"==typeof macros[e].handler&&(t=macros[e]),t}function i(){var e=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"init\";Object.keys(c).forEach(function(t){\"function\"==typeof c[t][e]&&c[t][e](t)}),Object.keys(macros).forEach(function(t){\"function\"==typeof macros[t][e]&&macros[t][e](t)})}function o(e,t){if(!e)throw new Error(\"no parent specified\");for(var r=[\"/\"+e,\"end\"+e],a=[].concat(r,Array.isArray(t)?t:[]),i=0;i<a.length;++i){var o=a[i];if(n(o))throw new Error(\"cannot register tag for an existing macro\");u(o)?d[o].includes(e)||(d[o].push(e),d[o].sort()):d[o]=[e]}}function s(e){if(!e)throw new Error(\"no parent specified\");Object.keys(d).forEach(function(t){var r=d[t].indexOf(e);-1!==r&&(1===d[t].length?delete d[t]:d[t].splice(r,1))})}function u(e){return d.hasOwnProperty(e)}function l(e){return u(e)?d[e]:null}var c={},d={},f=new RegExp(\"^(?:\"+Patterns.macroName+\")$\");return Object.freeze(Object.defineProperties({},{add:{value:e},delete:{value:t},isEmpty:{value:r},has:{value:n},get:{value:a},init:{value:i},tags:{value:Object.freeze(Object.defineProperties({},{register:{value:o},unregister:{value:s},has:{value:u},get:{value:l}}))},evalStatements:{value:function(){return Scripting.evalJavaScript.apply(Scripting,arguments)}}}))}(),MacroContext=function(){return function(){function e(t){_classCallCheck(this,e);var r=Object.assign({parent:null,macro:null,name:\"\",args:null,payload:null,parser:null,source:\"\"},t);if(null===r.macro||\"\"===r.name||null===r.parser)throw new TypeError(\"context object missing required properties\");Object.defineProperties(this,{self:{value:r.macro},name:{value:r.name},args:{value:r.args},payload:{value:r.payload},source:{value:r.source},parent:{value:r.parent},parser:{value:r.parser},_output:{value:r.parser.output},_shadows:{writable:!0,value:null},_debugView:{writable:!0,value:null},_debugViewEnabled:{writable:!0,value:Config.debug}})}return _createClass(e,[{key:\"contextHas\",value:function(e){for(var t=this;null!==(t=t.parent);)if(e(t))return!0;return!1}},{key:\"contextSelect\",value:function(e){for(var t=this;null!==(t=t.parent);)if(e(t))return t;return null}},{key:\"contextSelectAll\",value:function(e){for(var t=[],r=this;null!==(r=r.parent);)e(r)&&t.push(r);return t}},{key:\"addShadow\",value:function(){var e=this;this._shadows||(this._shadows=new Set);for(var t=new RegExp(\"^\"+Patterns.variable+\"$\"),r=arguments.length,n=Array(r),a=0;a<r;a++)n[a]=arguments[a];n.flat(1/0).forEach(function(r){if(\"string\"!=typeof r)throw new TypeError(\"variable name must be a string; type: \"+(void 0===r?\"undefined\":_typeof(r)));if(!t.test(r))throw new Error('invalid variable name \"'+r+'\"');e._shadows.add(r)})}},{key:\"createShadowWrapper\",value:function(e,t,r){var n=this,a=void 0;return\"function\"==typeof e&&(a={},this.shadowView.forEach(function(e){var t=e.slice(1),r=\"$\"===e[0]?State.variables:State.temporary;a[e]=r[t]})),function(){for(var i=arguments.length,o=Array(i),s=0;s<i;s++)o[s]=arguments[s];if(\"function\"==typeof r&&r.apply(this,o),\"function\"==typeof e){var u=Object.keys(a),l=u.length>0?{}:null,c=Wikifier.Parser.get(\"macro\"),d=void 0;try{u.forEach(function(e){var t=e.slice(1),r=\"$\"===e[0]?State.variables:State.temporary;r.hasOwnProperty(t)&&(l[t]=r[t]),r[t]=a[e]}),d=c.context,c.context=n,e.apply(this,o)}finally{d!==undefined&&(c.context=d),u.forEach(function(e){var t=e.slice(1),r=\"$\"===e[0]?State.variables:State.temporary;a[e]=r[t],l.hasOwnProperty(t)?r[t]=l[t]:delete r[t]})}}\"function\"==typeof t&&t.apply(this,o)}}},{key:\"createDebugView\",value:function(e,t){return this._debugView=new DebugView(this._output,\"macro\",e||this.name,t||this.source),null!==this.payload&&this.payload.length>0&&this._debugView.modes({nonvoid:!0}),this._debugViewEnabled=!0,this._debugView}},{key:\"removeDebugView\",value:function(){null!==this._debugView&&(this._debugView.remove(),this._debugView=null),this._debugViewEnabled=!1}},{key:\"error\",value:function(e,t){return throwError(this._output,\"<<\"+this.name+\">>: \"+e,t||this.source)}},{key:\"output\",get:function(){return this._debugViewEnabled?this.debugView.output:this._output}},{key:\"shadows\",get:function(){return[].concat(_toConsumableArray(this._shadows))}},{key:\"shadowView\",get:function(){var e=new Set;return this.contextSelectAll(function(e){return e._shadows}).forEach(function(t){return t._shadows.forEach(function(t){return e.add(t)})}),[].concat(_toConsumableArray(e))}},{key:\"debugView\",get:function(){return this._debugViewEnabled?null!==this._debugView?this._debugView:this.createDebugView():null}}]),e}()}();!function(){if(Macro.add(\"capture\",{skipArgs:!0,tags:null,handler:function(){if(0===this.args.raw.length)return this.error(\"no story/temporary variable list specified\");var e={};try{for(var t=new RegExp(\"(\"+Patterns.variable+\")\",\"g\"),r=void 0;null!==(r=t.exec(this.args.raw));){var n=r[1],a=n.slice(1),i=\"$\"===n[0]?State.variables:State.temporary;i.hasOwnProperty(a)&&(e[a]=i[a]),this.addShadow(n)}new Wikifier(this.output,this.payload[0].contents)}finally{this.shadows.forEach(function(t){var r=t.slice(1),n=\"$\"===t[0]?State.variables:State.temporary;e.hasOwnProperty(r)?n[r]=e[r]:delete n[r]})}}}),Macro.add(\"set\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");try{Scripting.evalJavaScript(this.args.full)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"unset\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no story/temporary variable list specified\");for(var e=new RegExp(\"State\\\\.(variables|temporary)\\\\.(\"+Patterns.identifier+\")\",\"g\"),t=void 0;null!==(t=e.exec(this.args.full));){var r=State[t[1]],n=t[2];r.hasOwnProperty(n)&&delete r[n]}Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"remember\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");try{Scripting.evalJavaScript(this.args.full)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}for(var e=storage.get(\"remember\")||{},t=new RegExp(\"State\\\\.variables\\\\.(\"+Patterns.identifier+\")\",\"g\"),r=void 0;null!==(r=t.exec(this.args.full));){var n=r[1];e[n]=State.variables[n]}if(!storage.set(\"remember\",e))return this.error(\"unknown error, cannot remember: \"+this.args.raw);Config.debug&&this.debugView.modes({hidden:!0})},init:function(){var e=storage.get(\"remember\");e&&Object.keys(e).forEach(function(t){return State.variables[t]=e[t]})}}),Macro.add(\"forget\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no story variable list specified\");for(var e=storage.get(\"remember\"),t=new RegExp(\"State\\\\.variables\\\\.(\"+Patterns.identifier+\")\",\"g\"),r=void 0,n=!1;null!==(r=t.exec(this.args.full));){var a=r[1];State.variables.hasOwnProperty(a)&&delete State.variables[a],e&&e.hasOwnProperty(a)&&(n=!0,delete e[a])}if(n)if(0===Object.keys(e).length){if(!storage.delete(\"remember\"))return this.error(\"unknown error, cannot update remember store\")}else if(!storage.set(\"remember\",e))return this.error(\"unknown error, cannot update remember store\");Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"run\",\"set\"),Macro.add(\"script\",{skipArgs:!0,tags:null,handler:function(){var e=document.createDocumentFragment();try{Scripting.evalJavaScript(this.payload[0].contents,e)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e),this.source+this.payload[0].contents+\"<</\"+this.name+\">>\")}Config.debug&&this.createDebugView(),e.hasChildNodes()&&this.output.appendChild(e)}}),Macro.add(\"include\",{handler:function(){if(0===this.args.length)return this.error(\"no passage specified\");var e=void 0;if(e=\"object\"===_typeof(this.args[0])?this.args[0].link:this.args[0],!Story.has(e))return this.error('passage \"'+e+'\" does not exist');Config.debug&&this.debugView.modes({block:!0}),e=Story.get(e);var t=void 0;t=this.args[1]?jQuery(document.createElement(this.args[1])).addClass(e.domId+\" macro-\"+this.name).attr(\"data-passage\",e.title).appendTo(this.output):jQuery(this.output),t.wiki(e.processText())}}),Macro.add(\"nobr\",{skipArgs:!0,tags:null,handler:function(){new Wikifier(this.output,this.payload[0].contents.replace(/^\\n+|\\n+$/g,\"\").replace(/\\n+/g,\" \"))}}),Macro.add([\"print\",\"=\",\"-\"],{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");try{var e=toStringOrDefault(Scripting.evalJavaScript(this.args.full),null);null!==e&&new Wikifier(this.output,\"-\"===this.name?Util.escape(e):e)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}}}),Macro.add(\"silently\",{skipArgs:!0,tags:null,handler:function(){var e=document.createDocumentFragment();if(new Wikifier(e,this.payload[0].contents.trim()),Config.debug)this.debugView.modes({hidden:!0}),this.output.appendChild(e);else{var t=[].concat(_toConsumableArray(e.querySelectorAll(\".error\"))).map(function(e){return e.textContent});if(t.length>0)return this.error(\"error\"+(1===t.length?\"\":\"s\")+\" within contents (\"+t.join(\"; \")+\")\",this.source+this.payload[0].contents+\"<</\"+this.name+\">>\")}}}),Macro.add(\"display\",\"include\"),Macro.add(\"if\",{skipArgs:!0,tags:[\"elseif\",\"else\"],handler:function(){var e=void 0;try{var t=this.payload.length;for(e=0;e<t;++e)switch(this.payload[e].name){case\"else\":if(this.payload[e].args.raw.length>0)return/^\\s*if\\b/i.test(this.payload[e].args.raw)?this.error('whitespace is not allowed between the \"else\" and \"if\" in <<elseif>> clause'+(e>0?\" (#\"+e+\")\":\"\")):this.error(\"<<else>> does not accept a conditional expression (perhaps you meant to use <<elseif>>), invalid: \"+this.payload[e].args.raw);if(e+1!==t)return this.error(\"<<else>> must be the final clause\");break;default:if(0===this.payload[e].args.full.length)return this.error(\"no conditional expression specified for <<\"+this.payload[e].name+\">> clause\"+(e>0?\" (#\"+e+\")\":\"\"));if(Config.macros.ifAssignmentError&&/[^!=&^|<>*\\/%+-]=[^=]/.test(this.payload[e].args.full))return this.error(\"assignment operator found within <<\"+this.payload[e].name+\">> clause\"+(e>0?\" (#\"+e+\")\":\"\")+\" (perhaps you meant to use an equality operator: ==, ===, eq, is), invalid: \"+this.payload[e].args.raw)}var r=Scripting.evalJavaScript,n=!1;for(e=0;e<t;++e){if(Config.debug&&this.createDebugView(this.payload[e].name,this.payload[e].source).modes({nonvoid:!1}),\"else\"===this.payload[e].name||r(this.payload[e].args.full)){n=!0,new Wikifier(this.output,this.payload[e].contents);break}Config.debug&&this.debugView.modes({hidden:!0,invalid:!0})}if(Config.debug){for(++e;e<t;++e)this.createDebugView(this.payload[e].name,this.payload[e].source).modes({nonvoid:!1,hidden:!0,invalid:!0});this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!n,invalid:!n})}}catch(t){return this.error(\"bad conditional expression in <<\"+(0===e?\"if\":\"elseif\")+\">> clause\"+(e>0?\" (#\"+e+\")\":\"\")+\": \"+(\"object\"===(void 0===t?\"undefined\":_typeof(t))?t.message:t))}}}),Macro.add(\"switch\",{skipArgs:[\"switch\"],tags:[\"case\",\"default\"],handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");var e=this.payload.length;if(1===e)return this.error(\"no cases specified\");var t=void 0;for(t=1;t<e;++t)switch(this.payload[t].name){case\"default\":if(this.payload[t].args.length>0)return this.error(\"<<default>> does not accept values, invalid: \"+this.payload[t].args.raw);if(t+1!==e)return this.error(\"<<default>> must be the final case\");break;default:if(0===this.payload[t].args.length)return this.error(\"no value(s) specified for <<\"+this.payload[t].name+\">> (#\"+t+\")\")}var r=void 0;try{r=Scripting.evalJavaScript(this.args.full)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}var n=this.debugView,a=!1;for(Config.debug&&n.modes({nonvoid:!1,hidden:!0}),t=1;t<e;++t){if(Config.debug&&this.createDebugView(this.payload[t].name,this.payload[t].source).modes({nonvoid:!1}),\"default\"===this.payload[t].name||this.payload[t].args.some(function(e){return e===r})){a=!0,new Wikifier(this.output,this.payload[t].contents);break}Config.debug&&this.debugView.modes({hidden:!0,invalid:!0})}if(Config.debug){for(++t;t<e;++t)this.createDebugView(this.payload[t].name,this.payload[t].source).modes({nonvoid:!1,hidden:!0,invalid:!0});n.modes({nonvoid:!1,hidden:!0,invalid:!a}),this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!0,invalid:!a})}}}),Macro.add(\"for\",{skipArgs:!0,tags:null,_hasRangeRe:new RegExp(\"^\\\\S\"+Patterns.anyChar+\"*?\\\\s+range\\\\s+\\\\S\"+Patterns.anyChar+\"*?$\"),_rangeRe:new RegExp(\"^(?:State\\\\.(variables|temporary)\\\\.(\"+Patterns.identifier+\")\\\\s*,\\\\s*)?State\\\\.(variables|temporary)\\\\.(\"+Patterns.identifier+\")\\\\s+range\\\\s+(\\\\S\"+Patterns.anyChar+\"*?)$\"),_3PartRe:/^([^;]*?)\\s*;\\s*([^;]*?)\\s*;\\s*([^;]*?)$/,handler:function(){var e=this.args.full.trim(),t=this.payload[0].contents.replace(/\\n$/,\"\");if(0===e.length)this.self._handleFor.call(this,t,null,!0,null);else if(this.self._hasRangeRe.test(e)){var r=e.match(this.self._rangeRe);if(null===r)return this.error(\"invalid range form syntax, format: [index ,] value range collection\");this.self._handleForRange.call(this,t,{type:r[1],name:r[2]},{type:r[3],name:r[4]},r[5])}else{var n=void 0,a=void 0,i=void 0;if(-1===e.indexOf(\";\")){if(/^\\S+\\s+in\\s+\\S+/i.test(e))return this.error(\"invalid syntax, for…in is not supported; see: for…range\");if(/^\\S+\\s+of\\s+\\S+/i.test(e))return this.error(\"invalid syntax, for…of is not supported; see: for…range\");a=e}else{var o=e.match(this.self._3PartRe);if(null===o)return this.error(\"invalid 3-part conditional form syntax, format: [init] ; [condition] ; [post]\");n=o[1],a=o[2].trim(),i=o[3],0===a.length&&(a=!0)}this.self._handleFor.call(this,t,n,a,i)}},_handleFor:function(e,t,r,n){var a=Scripting.evalJavaScript,i=!0,o=Config.macros.maxLoopIterations;Config.debug&&this.debugView.modes({block:!0});try{if(TempState.break=null,t)try{a(t)}catch(e){return this.error(\"bad init expression: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}for(;a(r);){if(--o<0)return this.error(\"exceeded configured maximum loop iterations (\"+Config.macros.maxLoopIterations+\")\");if(new Wikifier(this.output,i?e.replace(/^\\n/,\"\"):e),i&&(i=!1),null!=TempState.break)if(1===TempState.break)TempState.break=null;else if(2===TempState.break){TempState.break=null;break}if(n)try{a(n)}catch(e){return this.error(\"bad post expression: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}}}catch(e){return this.error(\"bad conditional expression: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}finally{TempState.break=null}},_handleForRange:function(e,t,r,n){var a=!0,i=void 0;try{i=this.self._toRangeList(n)}catch(e){return this.error(e.message)}Config.debug&&this.debugView.modes({block:!0});try{TempState.break=null;for(var o=0;o<i.length;++o)if(t.name&&(State[t.type][t.name]=i[o][0]),State[r.type][r.name]=i[o][1],new Wikifier(this.output,a?e.replace(/^\\n/,\"\"):e),a&&(a=!1),null!=TempState.break)if(1===TempState.break)TempState.break=null;else if(2===TempState.break){TempState.break=null;break}}catch(e){return this.error(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e)}finally{TempState.break=null}},_toRangeList:function(e){var t=Scripting.evalJavaScript,r=void 0;try{r=t(\"{\"===e[0]?\"(\"+e+\")\":e)}catch(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"bad range expression: \"+e)\n;throw e.message=\"bad range expression: \"+e.message,e}var n=void 0;switch(void 0===r?\"undefined\":_typeof(r)){case\"string\":n=[];for(var a=0;a<r.length;){var i=Util.charAndPosAt(r,a);n.push([a,i.char]),a=1+i.end}break;case\"object\":if(Array.isArray(r))n=r.map(function(e,t){return[t,e]});else if(r instanceof Set)n=[].concat(_toConsumableArray(r)).map(function(e,t){return[t,e]});else if(r instanceof Map)n=[].concat(_toConsumableArray(r.entries()));else{if(\"Object\"!==Util.toStringTag(r))throw new Error(\"unsupported range expression type: \"+Util.toStringTag(r));n=Object.keys(r).map(function(e){return[e,r[e]]})}break;default:throw new Error(\"unsupported range expression type: \"+(void 0===r?\"undefined\":_typeof(r)))}return n}}),Macro.add([\"break\",\"continue\"],{skipArgs:!0,handler:function(){if(!this.contextHas(function(e){return\"for\"===e.name}))return this.error(\"must only be used in conjunction with its parent macro <<for>>\");TempState.break=\"continue\"===this.name?1:2,Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add([\"button\",\"link\"],{isAsync:!0,tags:null,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no \"+(\"button\"===this.name?\"button\":\"link\")+\" text specified\");var t=jQuery(document.createElement(\"button\"===this.name?\"button\":\"a\")),r=void 0;if(\"object\"===_typeof(this.args[0]))if(this.args[0].isImage){var n=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[0].source).appendTo(t);this.args[0].hasOwnProperty(\"passage\")&&n.attr(\"data-passage\",this.args[0].passage),this.args[0].hasOwnProperty(\"title\")&&n.attr(\"title\",this.args[0].title),this.args[0].hasOwnProperty(\"align\")&&n.attr(\"align\",this.args[0].align),this.args[0].hasOwnProperty(\"link\")&&(r=this.args[0].link),r=this.args[0].link}else t.append(document.createTextNode(this.args[0].text)),r=this.args[0].link;else t.wikiWithOptions({profile:\"core\"},this.args[0]),r=this.args.length>1?this.args[1]:undefined;null!=r?(t.attr(\"data-passage\",r),Story.has(r)?(t.addClass(\"link-internal\"),Config.addVisitedLinkClass&&State.hasPlayed(r)&&t.addClass(\"link-visited\")):t.addClass(\"link-broken\")):t.addClass(\"link-internal\"),t.addClass(\"macro-\"+this.name).ariaClick({namespace:\".macros\",one:null!=r},this.createShadowWrapper(\"\"!==this.payload[0].contents?function(){return Wikifier.wikifyEval(e.payload[0].contents.trim())}:null,null!=r?function(){return Engine.play(r)}:null)).appendTo(this.output)}}),Macro.add(\"checkbox\",{isAsync:!0,handler:function(){if(this.args.length<3){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"unchecked value\"),this.args.length<3&&e.push(\"checked value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');var r=Util.slugify(t),n=this.args[1],a=this.args[2],i=document.createElement(\"input\");jQuery(i).attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,type:\"checkbox\",tabindex:0}).addClass(\"macro-\"+this.name).on(\"change.macros\",this.createShadowWrapper(function(){State.setVar(t,this.checked?a:n)})).appendTo(this.output),this.args.length>3&&\"checked\"===this.args[3]?(i.checked=!0,State.setVar(t,a)):State.setVar(t,n)}}),Macro.add([\"cycle\",\"listbox\"],{isAsync:!0,skipArgs:[\"optionsfrom\"],tags:[\"option\",\"optionsfrom\"],handler:function(){var e=this;if(0===this.args.length)return this.error(\"no variable name specified\");if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');var r=Util.slugify(t),n=this.payload.length;if(1===n)return this.error(\"no options specified\");for(var a=this.args.length>1&&\"autoselect\"===this.args[1],i=[],o={option:0,optionsfrom:0},s=-1,u=1;u<n;++u){var l=this.payload[u];if(\"option\"===l.name){if(++o.option,0===l.args.length)return this.error(\"no arguments specified for <<\"+l.name+\">> (#\"+o.option+\")\");if(i.push({label:String(l.args[0]),value:1===l.args.length?l.args[0]:l.args[1]}),l.args.length>2&&\"selected\"===l.args[2]){if(a)return this.error(\"cannot specify both the autoselect and selected keywords\");if(-1!==s)return this.error(\"multiple selected keywords specified for <<\"+l.name+\">> (#\"+(s+1)+\" & #\"+o.option+\")\");s=i.length-1}}else{var c=function(){if(++o.optionsfrom,0===l.args.full.length)return{v:e.error(\"no expression specified for <<\"+l.name+\">> (#\"+o.optionsfrom+\")\")};var t=void 0;try{var r=l.args.full;t=Scripting.evalJavaScript(\"{\"===r[0]?\"(\"+r+\")\":r)}catch(t){return{v:e.error(\"bad evaluation: \"+(\"object\"===(void 0===t?\"undefined\":_typeof(t))?t.message:t))}}if(\"object\"!==(void 0===t?\"undefined\":_typeof(t))||null===t)return{v:e.error(\"expression must yield a supported collection or generic object (type: \"+(null===t?\"null\":void 0===t?\"undefined\":_typeof(t))+\")\")};if(t instanceof Array||t instanceof Set)t.forEach(function(e){return i.push({label:String(e),value:e})});else if(t instanceof Map)t.forEach(function(e,t){return i.push({label:String(t),value:e})});else{var n=Util.toStringTag(t);if(\"Object\"!==n)return{v:e.error(\"expression must yield a supported collection or generic object (object type: \"+n+\")\")};Object.keys(t).forEach(function(e){return i.push({label:e,value:t[e]})})}}();if(\"object\"===(void 0===c?\"undefined\":_typeof(c)))return c.v}}if(-1===s)if(a){var d=Util.sameValueZero,f=State.getVar(t),p=i.findIndex(function(e){return d(e.value,f)});s=-1===p?0:p}else s=0;if(\"cycle\"===this.name){var h=s;jQuery(document.createElement(\"a\")).wikiWithOptions({profile:\"core\"},i[s].label).addClass(\"macro-\"+this.name).ariaClick({namespace:\".macros\"},this.createShadowWrapper(function(){h=(h+1)%i.length,$(this).empty().wikiWithOptions({profile:\"core\"},i[h].label),State.setVar(t,i[h].value)})).appendTo(this.output)}else{var g=jQuery(document.createElement(\"select\"));i.forEach(function(e,t){jQuery(document.createElement(\"option\")).val(t).text(e.label).appendTo(g)}),g.attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,tabindex:0}).addClass(\"macro-\"+this.name).val(s).on(\"change.macros\",this.createShadowWrapper(function(){State.setVar(t,i[Number(this.value)].value)})).appendTo(this.output)}State.setVar(t,i[s].value)}}),Macro.add([\"linkappend\",\"linkprepend\",\"linkreplace\"],{isAsync:!0,tags:null,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no link text specified\");var t=jQuery(document.createElement(\"a\")),r=jQuery(document.createElement(\"span\")),n=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]);t.wikiWithOptions({profile:\"core\"},this.args[0]).addClass(\"link-internal macro-\"+this.name).ariaClick({namespace:\".macros\",one:!0},this.createShadowWrapper(function(){if(\"linkreplace\"===e.name?t.remove():t.wrap('<span class=\"macro-'+e.name+'\"></span>').replaceWith(function(){return t.html()}),\"\"!==e.payload[0].contents){var a=document.createDocumentFragment();new Wikifier(a,e.payload[0].contents),r.append(a)}n&&setTimeout(function(){return r.removeClass(\"macro-\"+e.name+\"-in\")},Engine.minDomActionDelay)})).appendTo(this.output),r.addClass(\"macro-\"+this.name+\"-insert\"),n&&r.addClass(\"macro-\"+this.name+\"-in\"),\"linkprepend\"===this.name?r.insertBefore(t):r.insertAfter(t)}}),Macro.add(\"radiobutton\",{isAsync:!0,handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"checked value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');var r=Util.slugify(t),n=this.args[1],a=document.createElement(\"input\");TempState.hasOwnProperty(this.name)||(TempState[this.name]={}),TempState[this.name].hasOwnProperty(r)||(TempState[this.name][r]=0),jQuery(a).attr({id:this.name+\"-\"+r+\"-\"+TempState[this.name][r]++,name:this.name+\"-\"+r,type:\"radio\",tabindex:0}).addClass(\"macro-\"+this.name).on(\"change.macros\",this.createShadowWrapper(function(){this.checked&&State.setVar(t,n)})).appendTo(this.output),this.args.length>2&&\"checked\"===this.args[2]&&(a.checked=!0,State.setVar(t,n))}}),Macro.add(\"textarea\",{isAsync:!0,handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"default value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');Config.debug&&this.debugView.modes({block:!0});var r=Util.slugify(t),n=this.args[1],a=\"autofocus\"===this.args[2],i=document.createElement(\"textarea\");jQuery(i).attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,rows:4,tabindex:0}).addClass(\"macro-\"+this.name).on(\"change.macros\",this.createShadowWrapper(function(){State.setVar(t,this.value)})).appendTo(this.output),State.setVar(t,n),i.textContent=n,a&&(i.setAttribute(\"autofocus\",\"autofocus\"),postdisplay[\"#autofocus:\"+i.id]=function(e){delete postdisplay[e],setTimeout(function(){return i.focus()},Engine.minDomActionDelay)})}}),Macro.add(\"textbox\",{isAsync:!0,handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"default value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');Config.debug&&this.debugView.modes({block:!0});var r=Util.slugify(t),n=this.args[1],a=document.createElement(\"input\"),i=!1,o=void 0;this.args.length>3?(o=this.args[2],i=\"autofocus\"===this.args[3]):this.args.length>2&&(\"autofocus\"===this.args[2]?i=!0:o=this.args[2]),\"object\"===(void 0===o?\"undefined\":_typeof(o))&&(o=o.link),jQuery(a).attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,type:\"text\",tabindex:0}).addClass(\"macro-\"+this.name).on(\"change.macros\",this.createShadowWrapper(function(){State.setVar(t,this.value)})).on(\"keypress.macros\",this.createShadowWrapper(function(e){13===e.which&&(e.preventDefault(),State.setVar(t,this.value),null!=o&&Engine.play(o))})).appendTo(this.output),State.setVar(t,n),a.value=n,i&&(a.setAttribute(\"autofocus\",\"autofocus\"),postdisplay[\"#autofocus:\"+a.id]=function(e){delete postdisplay[e],setTimeout(function(){return a.focus()},Engine.minDomActionDelay)})}}),Macro.add(\"click\",\"link\"),Macro.add(\"actions\",{handler:function(){for(var e=jQuery(document.createElement(\"ul\")).addClass(this.name).appendTo(this.output),t=0;t<this.args.length;++t){var r=void 0,n=void 0,a=void 0,i=void 0;\"object\"===_typeof(this.args[t])?this.args[t].isImage?(a=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[t].source),this.args[t].hasOwnProperty(\"passage\")&&a.attr(\"data-passage\",this.args[t].passage),this.args[t].hasOwnProperty(\"title\")&&a.attr(\"title\",this.args[t].title),this.args[t].hasOwnProperty(\"align\")&&a.attr(\"align\",this.args[t].align),r=this.args[t].link,i=this.args[t].setFn):(n=this.args[t].text,r=this.args[t].link,i=this.args[t].setFn):n=r=this.args[t],State.variables.hasOwnProperty(\"#actions\")&&State.variables[\"#actions\"].hasOwnProperty(r)&&State.variables[\"#actions\"][r]||jQuery(Wikifier.createInternalLink(jQuery(document.createElement(\"li\")).appendTo(e),r,null,function(e,t){return function(){State.variables.hasOwnProperty(\"#actions\")||(State.variables[\"#actions\"]={}),State.variables[\"#actions\"][e]=!0,\"function\"==typeof t&&t()}}(r,i))).addClass(\"macro-\"+this.name).append(a||document.createTextNode(n))}}}),Macro.add([\"back\",\"return\"],{handler:function(){if(this.args.length>1)return this.error(\"too many arguments specified, check the documentation for details\");var e=-1,t=void 0,r=void 0,n=void 0;if(1===this.args.length&&(\"object\"===_typeof(this.args[0])?this.args[0].isImage?(n=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[0].source),this.args[0].hasOwnProperty(\"passage\")&&n.attr(\"data-passage\",this.args[0].passage),this.args[0].hasOwnProperty(\"title\")&&n.attr(\"title\",this.args[0].title),this.args[0].hasOwnProperty(\"align\")&&n.attr(\"align\",this.args[0].align),this.args[0].hasOwnProperty(\"link\")&&(t=this.args[0].link)):1===this.args[0].count?t=this.args[0].link:(r=this.args[0].text,t=this.args[0].link):1===this.args.length&&(r=this.args[0])),null==t){for(var a=State.length-2;a>=0;--a)if(State.history[a].title!==State.passage){e=a,t=State.history[a].title;break}if(null==t&&\"return\"===this.name)for(var i=State.expired.length-1;i>=0;--i)if(State.expired[i]!==State.passage){t=State.expired[i];break}}else{if(!Story.has(t))return this.error('passage \"'+t+'\" does not exist');if(\"back\"===this.name){for(var o=State.length-2;o>=0;--o)if(State.history[o].title===t){e=o;break}if(-1===e)return this.error('cannot find passage \"'+t+'\" in the current story history')}}if(null==t)return this.error(\"cannot find passage\");var s=void 0;s=\"back\"!==this.name||-1!==e?jQuery(document.createElement(\"a\")).addClass(\"link-internal\").ariaClick({one:!0},\"return\"===this.name?function(){return Engine.play(t)}:function(){return Engine.goTo(e)}):jQuery(document.createElement(\"span\")).addClass(\"link-disabled\"),s.addClass(\"macro-\"+this.name).append(n||document.createTextNode(r||L10n.get(\"macro\"+this.name.toUpperFirst()+\"Text\"))).appendTo(this.output)}}),Macro.add(\"choice\",{handler:function(){if(0===this.args.length)return this.error(\"no passage specified\");var e=State.passage,t=void 0,r=void 0,n=void 0,a=void 0;if(1===this.args.length?\"object\"===_typeof(this.args[0])?this.args[0].isImage?(n=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[0].source),this.args[0].hasOwnProperty(\"passage\")&&n.attr(\"data-passage\",this.args[0].passage),this.args[0].hasOwnProperty(\"title\")&&n.attr(\"title\",this.args[0].title),this.args[0].hasOwnProperty(\"align\")&&n.attr(\"align\",this.args[0].align),t=this.args[0].link,a=this.args[0].setFn):(r=this.args[0].text,t=this.args[0].link,a=this.args[0].setFn):r=t=this.args[0]:(t=this.args[0],r=this.args[1]),State.variables.hasOwnProperty(\"#choice\")&&State.variables[\"#choice\"].hasOwnProperty(e)&&State.variables[\"#choice\"][e])return void jQuery(document.createElement(\"span\")).addClass(\"link-disabled macro-\"+this.name).attr(\"tabindex\",-1).append(n||document.createTextNode(r)).appendTo(this.output);jQuery(Wikifier.createInternalLink(this.output,t,null,function(){State.variables.hasOwnProperty(\"#choice\")||(State.variables[\"#choice\"]={}),State.variables[\"#choice\"][e]=!0,\"function\"==typeof a&&a()})).addClass(\"macro-\"+this.name).append(n||document.createTextNode(r))}}),Macro.add([\"addclass\",\"toggleclass\"],{handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"selector\"),this.args.length<2&&e.push(\"class names\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}var t=jQuery(this.args[0]);if(0===t.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');switch(this.name){case\"addclass\":t.addClass(this.args[1].trim());break;case\"toggleclass\":t.toggleClass(this.args[1].trim())}Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"removeclass\",{handler:function(){if(0===this.args.length)return this.error(\"no selector specified\");var e=jQuery(this.args[0]);if(0===e.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');this.args.length>1?e.removeClass(this.args[1].trim()):e.removeClass(),Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"copy\",{handler:function(){if(0===this.args.length)return this.error(\"no selector specified\");var e=jQuery(this.args[0]);if(0===e.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');jQuery(this.output).append(e.html()),Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add([\"append\",\"prepend\",\"replace\"],{tags:null,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no selector specified\");var t=jQuery(this.args[0]);if(0===t.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');if(\"\"!==this.payload[0].contents){var r=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]),n=void 0;switch(r?(n=jQuery(document.createElement(\"span\")),n.addClass(\"macro-\"+this.name+\"-insert macro-\"+this.name+\"-in\"),setTimeout(function(){return n.removeClass(\"macro-\"+e.name+\"-in\")},Engine.minDomActionDelay)):n=jQuery(document.createDocumentFragment()),n.wiki(this.payload[0].contents),this.name){case\"replace\":t.empty();case\"append\":t.append(n);break;case\"prepend\":t.prepend(n)}}else\"replace\"===this.name&&t.empty();Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"remove\",{handler:function(){if(0===this.args.length)return this.error(\"no selector specified\");var e=jQuery(this.args[0]);if(0===e.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');e.remove(),Config.debug&&this.debugView.modes({hidden:!0})}}),Has.audio){var e=function(e,t){return'only one playback action allowed per invocation, \"'+e+'\" cannot be combined with \"'+t+'\"'};Macro.add(\"audio\",{handler:function(){if(this.args.length<2){var t=[];return this.args.length<1&&t.push(\"track and/or group IDs\"),this.args.length<2&&t.push(\"actions\"),this.error(\"no \"+t.join(\" or \")+\" specified\")}var r=void 0;try{r=SimpleAudio.select(this.args[0])}catch(e){return this.error(e.message)}for(var n=this.args.slice(1),a=void 0,i=5,o=void 0,s=void 0,u=void 0,l=void 0,c=void 0,d=void 0;n.length>0;){var f=n.shift(),p=void 0;switch(f){case\"load\":case\"pause\":case\"play\":case\"stop\":case\"unload\":if(a)return this.error(e(f,a));a=f;break;case\"fadein\":if(a)return this.error(e(f,a));a=\"fade\",o=1;break;case\"fadeout\":if(a)return this.error(e(f,a));a=\"fade\",o=0;break;case\"fadeto\":if(a)return this.error(e(f,a));if(0===n.length)return this.error(\"fadeto missing required level value\");if(a=\"fade\",p=n.shift(),o=Number.parseFloat(p),Number.isNaN(o)||!Number.isFinite(o))return this.error(\"cannot parse fadeto: \"+p);break;case\"fadeoverto\":if(a)return this.error(e(f,a));if(n.length<2){var h=[];return n.length<1&&h.push(\"seconds\"),n.length<2&&h.push(\"level\"),this.error(\"fadeoverto missing required \"+h.join(\" and \")+\" value\"+(h.length>1?\"s\":\"\"))}if(a=\"fade\",p=n.shift(),i=Number.parseFloat(p),Number.isNaN(i)||!Number.isFinite(i))return this.error(\"cannot parse fadeoverto: \"+p);if(p=n.shift(),o=Number.parseFloat(p),Number.isNaN(o)||!Number.isFinite(o))return this.error(\"cannot parse fadeoverto: \"+p);break;case\"volume\":if(0===n.length)return this.error(\"volume missing required level value\");if(p=n.shift(),d=Number.parseFloat(p),Number.isNaN(d)||!Number.isFinite(d))return this.error(\"cannot parse volume: \"+p);break;case\"mute\":case\"unmute\":u=\"mute\"===f;break;case\"time\":if(0===n.length)return this.error(\"time missing required seconds value\");if(p=n.shift(),c=Number.parseFloat(p),Number.isNaN(c)||!Number.isFinite(c))return this.error(\"cannot parse time: \"+p);break;case\"loop\":case\"unloop\":s=\"loop\"===f;break;case\"goto\":if(0===n.length)return this.error(\"goto missing required passage title\");if(p=n.shift(),l=\"object\"===(void 0===p?\"undefined\":_typeof(p))?p.link:p,!Story.has(l))return this.error('passage \"'+l+'\" does not exist');break;default:return this.error(\"unknown action: \"+f)}}try{if(null!=d&&r.volume(d),null!=c&&r.time(c),null!=u&&r.mute(u),null!=s&&r.loop(s),null!=l){var g=\"ended.macros.macro-\"+this.name+\"_goto\";r.off(g).one(g,function(){r.off(g),Engine.play(l)})}switch(a){case\"fade\":r.fade(i,o);break;case\"load\":r.load();break;case\"pause\":r.pause();break;case\"play\":r.play();break;case\"stop\":r.stop();break;case\"unload\":r.unload()}Config.debug&&this.debugView.modes({hidden:!0})}catch(e){return this.error(\"error executing action: \"+e.message)}}}),Macro.add(\"cacheaudio\",{handler:function(){var e=this;if(this.args.length<2){var t=[];return this.args.length<1&&t.push(\"track ID\"),this.args.length<2&&t.push(\"sources\"),this.error(\"no \"+t.join(\" or \")+\" specified\")}var r=String(this.args[0]).trim(),n=/^format:\\s*([\\w-]+)\\s*;\\s*/i;try{SimpleAudio.tracks.add(r,this.args.slice(1).map(function(t){if(n.test(t)){if(Config.debug)return e.error('track ID \"'+r+'\": format specifier migration required, \"format:formatId;\" → \"formatId|\"');t=t.replace(n,\"$1|\")}return t}))}catch(e){return this.error(e.message)}if(Config.debug&&!SimpleAudio.tracks.get(r).hasSource())return this.error('track ID \"'+r+'\": no supported audio sources found');Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"createaudiogroup\",{tags:[\"track\"],handler:function(){if(0===this.args.length)return this.error(\"no group ID specified\");if(1===this.payload.length)return this.error(\"no tracks defined via <<track>>\");Config.debug&&this.debugView.modes({nonvoid:!1,hidden:!0});for(var e=String(this.args[0]).trim(),t=[],r=1,n=this.payload.length;r<n;++r){if(this.payload[r].args.length<1)return this.error(\"no track ID specified\");t.push(String(this.payload[r].args[0]).trim()),Config.debug&&this.createDebugView(this.payload[r].name,this.payload[r].source).modes({nonvoid:!1,hidden:!0})}try{SimpleAudio.groups.add(e,t)}catch(e){return this.error(e.message)}Config.debug&&this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!0})}}),Macro.add(\"createplaylist\",{tags:[\"track\"],handler:function(){if(0===this.args.length)return this.error(\"no list ID specified\");if(1===this.payload.length)return this.error(\"no tracks defined via <<track>>\");var e=Macro.get(\"playlist\");if(null!==e.from&&\"createplaylist\"!==e.from)return this.error(\"a playlist has already been defined with <<setplaylist>>\");Config.debug&&this.debugView.modes({nonvoid:!1,hidden:!0});for(var t=String(this.args[0]).trim(),r=[],n=1,a=this.payload.length;n<a;++n){if(0===this.payload[n].args.length)return this.error(\"no track ID specified\");for(var i={id:String(this.payload[n].args[0]).trim()},o=this.payload[n].args.slice(1);o.length>0;){var s=o.shift(),u=void 0,l=void 0;switch(s){case\"copy\":case\"own\":i.own=!0;break;case\"rate\":o.length>0&&o.shift();break;case\"volume\":if(0===o.length)return this.error(\"volume missing required level value\");if(u=o.shift(),l=Number.parseFloat(u),Number.isNaN(l)||!Number.isFinite(l))return this.error(\"cannot parse volume: \"+u);i.volume=l;break;default:return this.error(\"unknown action: \"+s)}}r.push(i),Config.debug&&this.createDebugView(this.payload[n].name,this.payload[n].source).modes({nonvoid:!1,hidden:!0})}try{SimpleAudio.lists.add(t,r)}catch(e){return this.error(e.message)}null===e.from&&(e.from=\"createplaylist\"),Config.debug&&this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!0})}}),Macro.add(\"masteraudio\",{handler:function(){if(0===this.args.length)return this.error(\"no actions specified\");for(var t=this.args.slice(0),r=void 0,n=void 0,a=void 0,i=void 0;t.length>0;){var o=t.shift(),s=void 0;switch(o){case\"load\":case\"stop\":case\"unload\":if(r)return this.error(e(o,r));r=o;break;case\"mute\":case\"unmute\":n=\"mute\"===o;break;case\"muteonhide\":case\"nomuteonhide\":a=\"muteonhide\"===o;break;case\"volume\":if(0===t.length)return this.error(\"volume missing required level value\");if(s=t.shift(),i=Number.parseFloat(s),Number.isNaN(i)||!Number.isFinite(i))return this.error(\"cannot parse volume: \"+s);break;default:return this.error(\"unknown action: \"+o)}}try{switch(null!=n&&SimpleAudio.mute(n),null!=a&&SimpleAudio.muteOnHidden(a),null!=i&&SimpleAudio.volume(i),r){case\"load\":SimpleAudio.load();break;case\"stop\":SimpleAudio.stop();break;case\"unload\":SimpleAudio.unload()}Config.debug&&this.debugView.modes({hidden:!0})}catch(e){return this.error(\"error executing action: \"+e.message)}}}),Macro.add(\"playlist\",{from:null,handler:function(){var t=this.self.from;if(null===t)return this.error(\"no playlists have been created\");var r=void 0,n=void 0;if(\"createplaylist\"===t){if(this.args.length<2){var a=[];return this.args.length<1&&a.push(\"list ID\"),this.args.length<2&&a.push(\"actions\"),this.error(\"no \"+a.join(\" or \")+\" specified\")}var i=String(this.args[0]).trim();if(!SimpleAudio.lists.has(i))return this.error('playlist \"'+i+'\" does not exist');r=SimpleAudio.lists.get(i),n=this.args.slice(1)}else{if(0===this.args.length)return this.error(\"no actions specified\");r=SimpleAudio.lists.get(\"setplaylist\"),n=this.args.slice(0)}for(var o=void 0,s=5,u=void 0,l=void 0,c=void 0,d=void 0,f=void 0;n.length>0;){var p=n.shift(),h=void 0;switch(p){case\"load\":case\"pause\":case\"play\":case\"skip\":case\"stop\":case\"unload\":if(o)return this.error(e(p,o));o=p;break;case\"fadein\":if(o)return this.error(e(p,o));o=\"fade\",u=1;break;case\"fadeout\":if(o)return this.error(e(p,o));o=\"fade\",u=0;break;case\"fadeto\":if(o)return this.error(e(p,o));if(0===n.length)return this.error(\"fadeto missing required level value\");if(o=\"fade\",h=n.shift(),u=Number.parseFloat(h),Number.isNaN(u)||!Number.isFinite(u))return this.error(\"cannot parse fadeto: \"+h);break;case\"fadeoverto\":if(o)return this.error(e(p,o));if(n.length<2){var g=[];return n.length<1&&g.push(\"seconds\"),n.length<2&&g.push(\"level\"),this.error(\"fadeoverto missing required \"+g.join(\" and \")+\" value\"+(g.length>1?\"s\":\"\"))}if(o=\"fade\",h=n.shift(),s=Number.parseFloat(h),Number.isNaN(s)||!Number.isFinite(s))return this.error(\"cannot parse fadeoverto: \"+h);if(h=n.shift(),u=Number.parseFloat(h),Number.isNaN(u)||!Number.isFinite(u))return this.error(\"cannot parse fadeoverto: \"+h);break;case\"volume\":if(0===n.length)return this.error(\"volume missing required level value\");if(h=n.shift(),f=Number.parseFloat(h),Number.isNaN(f)||!Number.isFinite(f))return this.error(\"cannot parse volume: \"+h);break;case\"mute\":case\"unmute\":c=\"mute\"===p;break;case\"loop\":case\"unloop\":l=\"loop\"===p;break;case\"shuffle\":case\"unshuffle\":d=\"shuffle\"===p;break;default:return this.error(\"unknown action: \"+p)}}try{switch(null!=f&&r.volume(f),null!=c&&r.mute(c),null!=l&&r.loop(l),null!=d&&r.shuffle(d),o){case\"fade\":r.fade(s,u);break;case\"load\":r.load();break;case\"pause\":r.pause();break;case\"play\":r.play();break;case\"skip\":r.skip();break;case\"stop\":r.stop();break;case\"unload\":r.unload()}Config.debug&&this.debugView.modes({hidden:!0})}catch(e){return this.error(\"error executing action: \"+e.message)}}}),Macro.add(\"removeaudiogroup\",{handler:function(){if(0===this.args.length)return this.error(\"no group ID specified\");var e=String(this.args[0]).trim();if(!SimpleAudio.groups.has(e))return this.error('group \"'+e+'\" does not exist');SimpleAudio.groups.delete(e),Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"removeplaylist\",{handler:function(){if(0===this.args.length)return this.error(\"no list ID specified\");var e=String(this.args[0]).trim();if(!SimpleAudio.lists.has(e))return this.error('playlist \"'+e+'\" does not exist');SimpleAudio.lists.delete(e),Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"waitforaudio\",{skipArgs:!0,handler:function(){SimpleAudio.loadWithScreen()}}),Macro.add(\"setplaylist\",{handler:function(){if(0===this.args.length)return this.error(\"no track ID(s) specified\");var e=Macro.get(\"playlist\");if(null!==e.from&&\"setplaylist\"!==e.from)return this.error(\"playlists have already been defined with <<createplaylist>>\");try{SimpleAudio.lists.add(\"setplaylist\",this.args.slice(0))}catch(e){return this.error(e.message)}null===e.from&&(e.from=\"setplaylist\"),Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"stopallaudio\",{skipArgs:!0,handler:function(){SimpleAudio.select(\":all\").stop(),Config.debug&&this.debugView.modes({hidden:!0})}})}else Macro.add([\"audio\",\"cacheaudio\",\"createaudiogroup\",\"createplaylist\",\"masteraudio\",\"playlist\",\"removeaudiogroup\",\"removeplaylist\",\"waitforaudio\",\"setplaylist\",\"stopallaudio\"],{skipArgs:!0,handler:function(){Config.debug&&this.debugView.modes({hidden:!0})}});Macro.add(\"goto\",{handler:function(){if(0===this.args.length)return this.error(\"no passage specified\");var e=void 0;if(e=\"object\"===_typeof(this.args[0])?this.args[0].link:this.args[0],!Story.has(e))return this.error('passage \"'+e+'\" does not exist');setTimeout(function(){return Engine.play(e)},Engine.minDomActionDelay)}}),Macro.add(\"repeat\",{isAsync:!0,tags:null,timers:new Set,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no time value specified\");var t=void 0;try{t=Math.max(Engine.minDomActionDelay,Util.fromCssTime(this.args[0]))}catch(e){return this.error(e.message)}Config.debug&&this.debugView.modes({block:!0});var r=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]),n=jQuery(document.createElement(\"span\")).addClass(\"macro-\"+this.name).appendTo(this.output);this.self.registerInterval(this.createShadowWrapper(function(){var t=document.createDocumentFragment();new Wikifier(t,e.payload[0].contents);var a=n;r&&(a=jQuery(document.createElement(\"span\")).addClass(\"macro-repeat-insert macro-repeat-in\").appendTo(a)),a.append(t),r&&setTimeout(function(){return a.removeClass(\"macro-repeat-in\")},Engine.minDomActionDelay)}),t)},registerInterval:function(e,t){var r=this;if(\"function\"!=typeof e)throw new TypeError(\"callback parameter must be a function\");var n=State.turns,a=this.timers,i=null;i=setInterval(function(){if(n!==State.turns)return clearInterval(i),void a.delete(i);var t=void 0;try{TempState.break=null,TempState.hasOwnProperty(\"repeatTimerId\")&&(t=TempState.repeatTimerId),TempState.repeatTimerId=i,e.call(r)}finally{void 0!==t?TempState.repeatTimerId=t:delete TempState.repeatTimerId,TempState.break=null}},t),a.add(i),prehistory.hasOwnProperty(\"#repeat-timers-cleanup\")||(prehistory[\"#repeat-timers-cleanup\"]=function(e){delete prehistory[e],a.forEach(function(e){return clearInterval(e)}),a.clear()})}}),Macro.add(\"stop\",{skipArgs:!0,handler:function(){if(!TempState.hasOwnProperty(\"repeatTimerId\"))return this.error(\"must only be used in conjunction with its parent macro <<repeat>>\");var e=Macro.get(\"repeat\").timers,t=TempState.repeatTimerId;clearInterval(t),e.delete(t),TempState.break=2,Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"timed\",{isAsync:!0,tags:[\"next\"],timers:new Set,handler:function(){if(0===this.args.length)return this.error(\"no time value specified in <<timed>>\");var e=[];try{e.push({name:this.name,source:this.source,delay:Math.max(Engine.minDomActionDelay,Util.fromCssTime(this.args[0])),content:this.payload[0].contents})}catch(e){return this.error(e.message+\" in <<timed>>\")}if(this.payload.length>1){var t=void 0;try{var r=void 0;for(t=1,r=this.payload.length;t<r;++t)e.push({name:this.payload[t].name,source:this.payload[t].source,delay:0===this.payload[t].args.length?e[e.length-1].delay:Math.max(Engine.minDomActionDelay,Util.fromCssTime(this.payload[t].args[0])),content:this.payload[t].contents})}catch(e){return this.error(e.message+\" in <<next>> (#\"+t+\")\")}}Config.debug&&this.debugView.modes({block:!0});var n=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]),a=jQuery(document.createElement(\"span\")).addClass(\"macro-\"+this.name).appendTo(this.output);this.self.registerTimeout(this.createShadowWrapper(function(e){var t=document.createDocumentFragment();new Wikifier(t,e.content);var r=a;Config.debug&&\"next\"===e.name&&(r=jQuery(new DebugView(r[0],\"macro\",e.name,e.source).output)),n&&(r=jQuery(document.createElement(\"span\")).addClass(\"macro-timed-insert macro-timed-in\").appendTo(r)),r.append(t),n&&setTimeout(function(){return r.removeClass(\"macro-timed-in\")},Engine.minDomActionDelay)}),e)},registerTimeout:function(e,t){if(\"function\"!=typeof e)throw new TypeError(\"callback parameter must be a function\");var r=State.turns,n=this.timers,a=null,i=t.shift(),o=function o(){if(n.delete(a),r===State.turns){var s=i;null!=(i=t.shift())&&(a=setTimeout(o,i.delay),n.add(a)),e.call(this,s)}};a=setTimeout(o,i.delay),n.add(a),\nprehistory.hasOwnProperty(\"#timed-timers-cleanup\")||(prehistory[\"#timed-timers-cleanup\"]=function(e){delete prehistory[e],n.forEach(function(e){return clearTimeout(e)}),n.clear()})}}),Macro.add(\"widget\",{tags:null,handler:function(){if(0===this.args.length)return this.error(\"no widget name specified\");var e=this.args[0];if(Macro.has(e)){if(!Macro.get(e).isWidget)return this.error('cannot clobber existing macro \"'+e+'\"');Macro.delete(e)}try{Macro.add(e,{isWidget:!0,handler:function(e){return function(){var t=void 0;try{State.variables.hasOwnProperty(\"args\")&&(t=State.variables.args),State.variables.args=[].concat(_toConsumableArray(this.args)),State.variables.args.raw=this.args.raw,State.variables.args.full=this.args.full,this.addShadow(\"$args\");var r=document.createDocumentFragment(),n=[];if(new Wikifier(r,e),Array.from(r.querySelectorAll(\".error\")).forEach(function(e){n.push(e.textContent)}),0!==n.length)return this.error(\"error\"+(n.length>1?\"s\":\"\")+\" within widget contents (\"+n.join(\"; \")+\")\");this.output.appendChild(r)}catch(e){return this.error(\"cannot execute widget: \"+e.message)}finally{void 0!==t?State.variables.args=t:delete State.variables.args}}}(this.payload[0].contents)}),Config.debug&&this.debugView.modes({hidden:!0})}catch(t){return this.error('cannot create widget macro \"'+e+'\": '+t.message)}}})}();var Dialog=function(){function e(e,t,r,n,a){return jQuery(e).ariaClick(function(e){e.preventDefault(),\"function\"==typeof r&&r(e),o(t,a),\"function\"==typeof n&&n(e)})}function t(){var e;return(e=g).append.apply(e,arguments),Dialog}function r(){return g.get(0)}function n(e){return g.trigger(\":dialogclosing\"),jQuery(document).off(\".dialog-close\"),y?(y.disconnect(),y=null):g.off(\".dialog-resize\"),jQuery(window).off(\".dialog-resize\"),p.removeClass(\"open\").css({left:\"\",right:\"\",top:\"\",bottom:\"\"}),jQuery(\"#ui-bar,#story\").find(\"[tabindex=-2]\").removeAttr(\"aria-hidden\").attr(\"tabindex\",0),jQuery(\"body>[tabindex=-3]\").removeAttr(\"aria-hidden\").removeAttr(\"tabindex\"),f.removeClass(\"open\"),jQuery(document.documentElement).removeAttr(\"data-dialog\"),h.empty(),g.empty().removeClass(),null!==m&&(jQuery(m).focus(),m=null),e&&e.data&&\"function\"==typeof e.data.closeFn&&e.data.closeFn(e),g.trigger(\":dialogclose\"),g.trigger(\":dialogclosed\"),Dialog}function a(){if(!document.getElementById(\"ui-dialog\")){v=function(){var e=void 0;try{var t=document.createElement(\"p\"),r=document.createElement(\"div\");t.style.width=\"100%\",t.style.height=\"200px\",r.style.position=\"absolute\",r.style.left=\"0px\",r.style.top=\"0px\",r.style.width=\"100px\",r.style.height=\"100px\",r.style.visibility=\"hidden\",r.style.overflow=\"hidden\",r.appendChild(t),document.body.appendChild(r);var n=t.offsetWidth;r.style.overflow=\"auto\";var a=t.offsetWidth;n===a&&(a=r.clientWidth),document.body.removeChild(r),e=n-a}catch(e){}return e||17}();var e=jQuery(document.createDocumentFragment()).append('<div id=\"ui-overlay\" class=\"ui-close\"></div><div id=\"ui-dialog\" tabindex=\"0\" role=\"dialog\" aria-labelledby=\"ui-dialog-title\"><div id=\"ui-dialog-titlebar\"><h1 id=\"ui-dialog-title\"></h1><button id=\"ui-dialog-close\" class=\"ui-close\" tabindex=\"0\" aria-label=\"'+L10n.get(\"close\")+'\"></button></div><div id=\"ui-dialog-body\"></div></div>');f=jQuery(e.find(\"#ui-overlay\").get(0)),p=jQuery(e.find(\"#ui-dialog\").get(0)),h=jQuery(e.find(\"#ui-dialog-title\").get(0)),g=jQuery(e.find(\"#ui-dialog-body\").get(0)),e.insertBefore(\"body>script#script-sugarcube\")}}function i(e){return p.hasClass(\"open\")&&(!e||e.splitOrEmpty(/\\s+/).every(function(e){return g.hasClass(e)}))}function o(e,t){g.trigger(\":dialogopening\");var r=jQuery.extend({top:50},e),a=r.top;return i()||(m=safeActiveElement()),jQuery(document.documentElement).attr(\"data-dialog\",\"open\"),f.addClass(\"open\"),null!==g[0].querySelector(\"img\")&&g.imagesLoaded().always(function(){return d({data:{top:a}})}),jQuery(\"body>:not(script,#store-area,tw-storydata,#ui-bar,#ui-overlay,#ui-dialog)\").attr(\"tabindex\",-3).attr(\"aria-hidden\",!0),jQuery(\"#ui-bar,#story\").find(\"[tabindex]:not([tabindex^=-])\").attr(\"tabindex\",-2).attr(\"aria-hidden\",!0),p.css(c(a)).addClass(\"open\").focus(),jQuery(window).on(\"resize.dialog-resize\",null,{top:a},jQuery.throttle(40,d)),Has.mutationObserver?(y=new MutationObserver(function(e){for(var t=0;t<e.length;++t)if(\"childList\"===e[t].type){d({data:{top:a}});break}}),y.observe(g[0],{childList:!0,subtree:!0})):g.on(\"DOMNodeInserted.dialog-resize DOMNodeRemoved.dialog-resize\",null,{top:a},jQuery.throttle(40,d)),jQuery(document).on(\"click.dialog-close\",\".ui-close\",{closeFn:t},n).on(\"keypress.dialog-close\",\".ui-close\",function(e){13!==e.which&&32!==e.which||jQuery(this).trigger(\"click\")}),g.trigger(\":dialogopen\"),g.trigger(\":dialogopened\"),Dialog}function s(e){return d(\"object\"===(void 0===e?\"undefined\":_typeof(e))?{data:e}:undefined)}function u(e,t){return g.empty().removeClass(),null!=t&&g.addClass(t),h.empty().append((null!=e?String(e):\"\")||\" \"),g.get(0)}function l(){var e;return(e=g).wiki.apply(e,arguments),Dialog}function c(e){var t=null!=e?e:50,r=jQuery(window),n={left:\"\",right:\"\",top:\"\",bottom:\"\"};p.css(n);var a=r.width()-p.outerWidth(!0)-1,i=r.height()-p.outerHeight(!0)-1;return a<=32+v&&(i-=v),i<=32+v&&(a-=v),n.left=n.right=a<=32?16:a/2>>0,n.top=i<=32?n.bottom=16:i/2>t?t:n.bottom=i/2>>0,Object.keys(n).forEach(function(e){\"\"!==n[e]&&(n[e]+=\"px\")}),n}function d(e){var t=e&&e.data&&void 0!==e.data.top?e.data.top:50;\"block\"===p.css(\"display\")&&(p.css({display:\"none\"}),p.css(jQuery.extend({display:\"\"},c(t))))}var f=null,p=null,h=null,g=null,m=null,v=0,y=null;return Object.freeze(Object.defineProperties({},{append:{value:t},body:{value:r},close:{value:n},init:{value:a},isOpen:{value:i},open:{value:o},resize:{value:s},setup:{value:u},wiki:{value:l},addClickHandler:{value:e}}))}(),Engine=function(){function e(){jQuery(\"#init-no-js,#init-lacking\").remove(),function(){var e=jQuery(document.createDocumentFragment()),t=Story.has(\"StoryInterface\")&&Story.get(\"StoryInterface\").text.trim();if(t){if(UIBar.destroy(),jQuery(document.head).find(\"#style-core-display\").remove(),e.append(t),0===e.find(\"#passages\").length)throw new Error('no element with ID \"passages\" found within \"StoryInterface\" special passage');var r=[];e.find(\"[data-passage]\").each(function(e,t){if(\"passages\"===t.id)throw new Error('\"StoryInterface\" element <'+t.nodeName.toLowerCase()+' id=\"passages\"> must not contain a \"data-passage\" content attribute');var n=t.getAttribute(\"data-passage\").trim();if(null!==t.firstElementChild)throw new Error('\"StoryInterface\" element <'+t.nodeName.toLowerCase()+' data-passage=\"'+n+'\"> contains child elements');Story.has(n)&&r.push({passage:n,element:t})}),r.length>0&&(E=r),Config.ui.updateStoryElements=!1}else e.append('<div id=\"story\" role=\"main\"><div id=\"passages\"></div></div>');e.insertBefore(\"body>script#script-sugarcube\")}(),S=new StyleWrapper(function(){return jQuery(document.createElement(\"style\")).attr({id:\"style-aria-outlines\",type:\"text/css\"}).appendTo(document.head).get(0)}()),jQuery(document).on(\"mousedown.aria-outlines keydown.aria-outlines\",function(e){return\"keydown\"===e.type?m():g()})}function t(){if(Story.has(\"StoryInit\"))try{var e=Wikifier.wikifyEval(Story.get(\"StoryInit\").text);if(Config.debug){var t=new DebugView(document.createDocumentFragment(),\"special\",\"StoryInit\",\"StoryInit\");t.modes({hidden:!0}),t.append(e),k=t.output}}catch(e){console.error(e),Alert.error(\"StoryInit\",e.message)}if(null==Config.passages.start)throw new Error(\"starting passage not selected\");if(!Story.has(Config.passages.start))throw new Error('starting passage (\"'+Config.passages.start+'\") not found');if(jQuery(document.documentElement).focus(),State.restore())f();else{var r=!0;switch(_typeof(Config.saves.autoload)){case\"boolean\":Config.saves.autoload&&Save.autosave.ok()&&Save.autosave.has()&&(r=!Save.autosave.load());break;case\"string\":\"prompt\"===Config.saves.autoload&&Save.autosave.ok()&&Save.autosave.has()&&(r=!1,UI.buildAutoload(),Dialog.open());break;case\"function\":Save.autosave.ok()&&Save.autosave.has()&&Config.saves.autoload()&&(r=!Save.autosave.load())}r&&p(Config.passages.start)}}function r(){LoadScreen.show(),window.scroll(0,0),State.reset(),jQuery.event.trigger(\":enginerestart\"),window.location.reload()}function n(){return b}function a(){return b===v.Idle}function i(){return b!==v.Idle}function o(){return b===v.Rendering}function s(){return w}function u(e){var t=State.goTo(e);return t&&f(),t}function l(e){var t=State.go(e);return t&&f(),t}function c(){return l(-1)}function d(){return l(1)}function f(){return p(State.passage,!0)}function p(e,t){var r=e;b=v.Playing,TempState={},State.clearTemporary();var n=void 0,a=void 0;if(\"function\"==typeof Config.navigation.override)try{var i=Config.navigation.override(r);i&&(r=i)}catch(e){}var o=Story.get(r);if(jQuery.event.trigger({type:\":passageinit\",passage:o}),Object.keys(prehistory).forEach(function(e){\"function\"==typeof prehistory[e]&&prehistory[e].call(this,e)},o),t||State.create(o.title),w=Util.now(),document.body.className&&(document.body.className=\"\"),Object.keys(predisplay).forEach(function(e){\"function\"==typeof predisplay[e]&&predisplay[e].call(this,e)},o),Story.has(\"PassageReady\"))try{n=Wikifier.wikifyEval(Story.get(\"PassageReady\").text)}catch(e){console.error(e),Alert.error(\"PassageReady\",e.message)}b=v.Rendering;var s=jQuery(o.render()),u=document.getElementById(\"passages\");if(u.hasChildNodes()&&(\"number\"==typeof Config.passages.transitionOut||\"string\"==typeof Config.passages.transitionOut&&\"\"!==Config.passages.transitionOut&&Has.transitionEndEvent?[].concat(_toConsumableArray(u.childNodes)).forEach(function(e){var t=jQuery(e);if(e.nodeType===Node.ELEMENT_NODE&&t.hasClass(\"passage\")){if(t.hasClass(\"passage-out\"))return;t.attr(\"id\",\"out-\"+t.attr(\"id\")).addClass(\"passage-out\"),\"string\"==typeof Config.passages.transitionOut?t.on(Has.transitionEndEvent,function(e){e.originalEvent.propertyName===Config.passages.transitionOut&&t.remove()}):setTimeout(function(){return t.remove()},Math.max(y,Config.passages.transitionOut))}else t.remove()}):jQuery(u).empty()),s.addClass(\"passage-in\").appendTo(u),setTimeout(function(){return s.removeClass(\"passage-in\")},y),Config.passages.displayTitles&&o.title!==Config.passages.start&&(document.title=o.title+\" | \"+Story.title),window.scroll(0,0),b=v.Playing,Story.has(\"PassageDone\"))try{a=Wikifier.wikifyEval(Story.get(\"PassageDone\").text)}catch(e){console.error(e),Alert.error(\"PassageDone\",e.message)}if(jQuery.event.trigger({type:\":passagedisplay\",passage:o}),Object.keys(postdisplay).forEach(function(e){\"function\"==typeof postdisplay[e]&&postdisplay[e].call(this,e)},o),null!==E?E.forEach(function(e){jQuery(e.element).empty(),new Wikifier(e.element,Story.get(e.passage).processText().trim())}):Config.ui.updateStoryElements&&UIBar.update(),Config.debug){var l=void 0;null!=n&&(l=new DebugView(document.createDocumentFragment(),\"special\",\"PassageReady\",\"PassageReady\"),l.modes({hidden:!0}),l.append(n),s.prepend(l.output)),null!=a&&(l=new DebugView(document.createDocumentFragment(),\"special\",\"PassageDone\",\"PassageDone\"),l.modes({hidden:!0}),l.append(a),s.append(l.output)),1===State.turns&&null!=k&&s.prepend(k)}switch(g(),jQuery(\"#story\").find(\"a[href]:not(.link-external)\").addClass(\"link-external\").end().find(\"a,link,button,input,select,textarea\").not(\"[tabindex]\").attr(\"tabindex\",0),_typeof(Config.saves.autosave)){case\"boolean\":Config.saves.autosave&&Save.autosave.save();break;case\"string\":o.tags.includes(Config.saves.autosave)&&Save.autosave.save();break;case\"object\":Array.isArray(Config.saves.autosave)&&o.tags.some(function(e){return Config.saves.autosave.includes(e)})&&Save.autosave.save()}return jQuery.event.trigger({type:\":passageend\",passage:o}),b=v.Idle,w=Util.now(),s[0]}function h(e,t,r){var n=!1;switch(r){case undefined:break;case\"replace\":case\"back\":n=!0;break;default:throw new Error('Engine.display option parameter called with obsolete value \"'+r+'\"; please notify the developer')}p(e,n)}function g(){S.set(\"*:focus{outline:none}\")}function m(){S.clear()}var v=Util.toEnum({Idle:\"idle\",Playing:\"playing\",Rendering:\"rendering\"}),y=40,b=v.Idle,w=null,k=null,S=null,E=null;return Object.freeze(Object.defineProperties({},{States:{value:v},minDomActionDelay:{value:y},init:{value:e},start:{value:t},restart:{value:r},state:{get:n},isIdle:{value:a},isPlaying:{value:i},isRendering:{value:o},lastPlay:{get:s},goTo:{value:u},go:{value:l},backward:{value:c},forward:{value:d},show:{value:f},play:{value:p},display:{value:h}}))}(),Passage=function(){var e=void 0;e=/^(?:debug|nobr|passage|widget|twine\\..*)$/i;return function(){function t(r,n){var a=this;_classCallCheck(this,t),Object.defineProperties(this,{title:{value:Util.unescape(r)},element:{value:n||null},tags:{value:Object.freeze(n&&n.hasAttribute(\"tags\")?n.getAttribute(\"tags\").trim().splitOrEmpty(/\\s+/).sort().filter(function(e,t,r){return 0===t||r[t-1]!==e}):[])},_excerpt:{writable:!0,value:null}}),Object.defineProperties(this,{domId:{value:\"passage-\"+Util.slugify(this.title)},classes:{value:Object.freeze(0===this.tags.length?[]:function(){return a.tags.filter(function(t){return!e.test(t)}).map(function(e){return Util.slugify(e)})}())}})}return _createClass(t,[{key:\"description\",value:function(){var e=Config.passages.descriptions;if(null!=e)switch(void 0===e?\"undefined\":_typeof(e)){case\"boolean\":if(e)return this.title;break;case\"object\":if(e instanceof Map&&e.has(this.title))return e.get(this.title);if(e.hasOwnProperty(this.title))return e[this.title];break;case\"function\":var r=e.call(this);if(r)return r;break;default:throw new TypeError(\"Config.passages.descriptions must be a boolean, object, or function\")}return null===this._excerpt&&(this._excerpt=t.getExcerptFromText(this.text)),this._excerpt}},{key:\"processText\",value:function(){if(null==this.element)return this.text;var e=this.text;return this.tags.includes(\"Twine.image\")?e=\"[img[\"+e+\"]]\":(Config.passages.nobr||this.tags.includes(\"nobr\"))&&(e=e.replace(/^\\n+|\\n+$/g,\"\").replace(/\\n+/g,\" \")),e}},{key:\"render\",value:function(){var e=this,r=this.tags.length>0?this.tags.join(\" \"):null,n=document.createElement(\"div\");return jQuery(n).attr({id:this.domId,\"data-passage\":this.title,\"data-tags\":r}).addClass(\"passage \"+this.className),jQuery(document.body).attr(\"data-tags\",r).addClass(this.className),jQuery(document.documentElement).attr(\"data-tags\",r),jQuery.event.trigger({type:\":passagestart\",content:n,passage:this}),Object.keys(prerender).forEach(function(t){\"function\"==typeof prerender[t]&&prerender[t].call(e,n,t)}),Story.has(\"PassageHeader\")&&new Wikifier(n,Story.get(\"PassageHeader\").processText()),new Wikifier(n,this.processText()),Story.has(\"PassageFooter\")&&new Wikifier(n,Story.get(\"PassageFooter\").processText()),jQuery.event.trigger({type:\":passagerender\",content:n,passage:this}),Object.keys(postrender).forEach(function(t){\"function\"==typeof postrender[t]&&postrender[t].call(e,n,t)}),this._excerpt=t.getExcerptFromNode(n),n}},{key:\"className\",get:function(){return this.classes.join(\" \")}},{key:\"text\",get:function(){if(null==this.element){var e=Util.escape(this.title);return'<div class=\"error-view\"><span class=\"error\">'+(L10n.get(\"errorTitle\")+\": \"+L10n.get(\"errorNonexistentPassage\",{passage:e}))+\"</span></div>\"}return this.element.textContent.replace(/\\r/g,\"\")}}],[{key:\"getExcerptFromNode\",value:function(e,t){if(!e.hasChildNodes())return\"\";var r=e.textContent.trim();if(\"\"!==r){var n=new RegExp(\"(\\\\S+(?:\\\\s+\\\\S+){0,\"+(t>0?t-1:7)+\"})\");r=r.replace(/\\s+/g,\" \").match(n)}return r?r[1]+\"…\":\"…\"}},{key:\"getExcerptFromText\",value:function(e,t){if(\"\"===e)return\"\";var r=new RegExp(\"(\\\\S+(?:\\\\s+\\\\S+){0,\"+(t>0?t-1:7)+\"})\"),n=e.replace(/<<.*?>>/g,\" \").replace(/<.*?>/g,\" \").trim().replace(/^\\s*\\|.*\\|.*?$/gm,\"\").replace(/\\[[<>]?img\\[[^\\]]*\\]\\]/g,\"\").replace(/\\[\\[([^|\\]]*?)(?:(?:\\||->|<-)[^\\]]*)?\\]\\]/g,\"$1\").replace(/^\\s*!+(.*?)$/gm,\"$1\").replace(/'{2}|\\/{2}|_{2}|@{2}/g,\"\").trim().replace(/\\s+/g,\" \").match(r);return n?n[1]+\"…\":\"…\"}}]),t}()}(),Save=function(){function e(){if(\"cookie\"===storage.name)return n(),Config.saves.autoload=undefined,Config.saves.autosave=undefined,Config.saves.isAllowed=undefined,Config.saves.onLoad=undefined,Config.saves.onSave=undefined,Config.saves.slots=0,!1;var e=r(),t=!1;Array.isArray(e)&&(e={autosave:null,slots:e},t=!0),Config.saves.slots!==e.slots.length&&(Config.saves.slots<e.slots.length?(e.slots.reverse(),e.slots=e.slots.filter(function(e){return!(null===e&&this.count>0)||(--this.count,!1)},{count:e.slots.length-Config.saves.slots}),e.slots.reverse()):Config.saves.slots>e.slots.length&&j(e.slots,Config.saves.slots-e.slots.length),t=!0),T(e.autosave)&&(t=!0);for(var a=0;a<e.slots.length;++a)T(e.slots[a])&&(t=!0);return x(e)&&(storage.delete(\"saves\"),t=!1),t&&O(e),P=e.slots.length-1,!0}function t(){return{autosave:null,slots:j([],Config.saves.slots)}}function r(){var e=storage.get(\"saves\");return null===e?t():e}function n(){return storage.delete(\"saves\"),!0}function a(){return i()||d()}function i(){return\"cookie\"!==storage.name&&void 0!==Config.saves.autosave}function o(){return null!==r().autosave}function s(){return r().autosave}function u(){var e=r();return null!==e.autosave&&A(e.autosave)}function l(e,t){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return!1;var n=r(),a={title:e||Story.get(State.passage).description(),date:Date.now()};return null!=t&&(a.metadata=t),n.autosave=C(a),O(n)}function c(){var e=r();return e.autosave=null,O(e)}function d(){return\"cookie\"!==storage.name&&-1!==P}function f(){return P+1}function p(){if(!d())return 0;for(var e=r(),t=0,n=0,a=e.slots.length;n<a;++n)null!==e.slots[n]&&++t;return t}function h(){return 0===p()}function g(e){if(e<0||e>P)return!1;var t=r();return!(e>=t.slots.length||null===t.slots[e])}function m(e){if(e<0||e>P)return null;var t=r();return e>=t.slots.length?null:t.slots[e]}function v(e){if(e<0||e>P)return!1;var t=r();return!(e>=t.slots.length||null===t.slots[e])&&A(t.slots[e])}function y(e,t,n){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return Dialog.isOpen()?$(document).one(\":dialogclosed\",function(){return UI.alert(L10n.get(\"savesDisallowed\"))}):UI.alert(L10n.get(\"savesDisallowed\")),!1;if(e<0||e>P)return!1;var a=r();if(e>=a.slots.length)return!1;var i={title:t||Story.get(State.passage).description(),date:Date.now()};return null!=n&&(i.metadata=n),a.slots[e]=C(i),O(a)}function b(e){if(e<0||e>P)return!1;var t=r();return!(e>=t.slots.length)&&(t.slots[e]=null,O(t))}function w(e,t){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return void(Dialog.isOpen()?$(document).one(\":dialogclosed\",function(){return UI.alert(L10n.get(\"savesDisallowed\"))}):UI.alert(L10n.get(\"savesDisallowed\")));var r=null==e?Story.domId:Util.slugify(e),n=r+\"-\"+function(){var e=new Date,t=e.getMonth()+1,r=e.getDate(),n=e.getHours(),a=e.getMinutes(),i=e.getSeconds();return t<10&&(t=\"0\"+t),r<10&&(r=\"0\"+r),n<10&&(n=\"0\"+n),a<10&&(a=\"0\"+a),i<10&&(i=\"0\"+i),\"\"+e.getFullYear()+t+r+\"-\"+n+a+i}()+\".save\",a=null==t?{}:{metadata:t},i=LZString.compressToBase64(JSON.stringify(C(a)));saveAs(new Blob([i],{type:\"text/plain;charset=UTF-8\"}),n)}function k(e){var t=e.target.files[0],r=new FileReader;jQuery(r).on(\"load\",function(e){var r=e.currentTarget;if(r.result){var n=void 0;try{n=JSON.parse(/\\.json$/i.test(t.name)||/^\\{/.test(r.result)?r.result:LZString.decompressFromBase64(r.result))}catch(e){}A(n)}}),r.readAsText(t)}function S(e){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return Dialog.isOpen()?$(document).one(\":dialogclosed\",function(){return UI.alert(L10n.get(\"savesDisallowed\"))}):UI.alert(L10n.get(\"savesDisallowed\")),null;var t=null==e?{}:{metadata:e};return LZString.compressToBase64(JSON.stringify(C(t)))}function E(e){var t=void 0;try{t=JSON.parse(LZString.decompressFromBase64(e))}catch(e){}return A(t)?t.metadata:null}function j(e,t){for(var r=0;r<t;++r)e.push(null);return e}function x(e){for(var t=e.slots,r=!0,n=0,a=t.length;n<a;++n)if(null!==t[n]){r=!1;break}return null===e.autosave&&r}function O(e){return x(e)?(storage.delete(\"saves\"),!0):storage.set(\"saves\",e)}function T(e){if(null==e||\"object\"!==(void 0===e?\"undefined\":_typeof(e)))return!1;var t=!1;return e.hasOwnProperty(\"state\")&&e.state.hasOwnProperty(\"delta\")&&e.state.hasOwnProperty(\"index\")||(e.hasOwnProperty(\"data\")?(delete e.mode,e.state={delta:State.deltaEncode(e.data)},delete e.data):e.state.hasOwnProperty(\"delta\")?e.state.hasOwnProperty(\"index\")||delete e.state.mode:(delete e.state.mode,e.state.delta=State.deltaEncode(e.state.history),delete e.state.history),e.state.index=e.state.delta.length-1,t=!0),e.state.hasOwnProperty(\"rseed\")&&(e.state.seed=e.state.rseed,delete e.state.rseed,e.state.delta.forEach(function(e,t,r){r[t].hasOwnProperty(\"rcount\")&&(r[t].pull=r[t].rcount,delete r[t].rcount)}),t=!0),(e.state.hasOwnProperty(\"expired\")&&\"number\"==typeof e.state.expired||e.state.hasOwnProperty(\"unique\")||e.state.hasOwnProperty(\"last\"))&&(e.state.hasOwnProperty(\"expired\")&&\"number\"==typeof e.state.expired&&delete e.state.expired,(e.state.hasOwnProperty(\"unique\")||e.state.hasOwnProperty(\"last\"))&&(e.state.expired=[],e.state.hasOwnProperty(\"unique\")&&(e.state.expired.push(e.state.unique),delete e.state.unique),e.state.hasOwnProperty(\"last\")&&(e.state.expired.push(e.state.last),delete e.state.last)),t=!0),t}function C(e){if(null!=e&&\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"supplemental parameter must be an object\");var t=Object.assign({},e,{id:Config.saves.id,state:State.marshalForSave()});return Config.saves.version&&(t.version=Config.saves.version),\"function\"==typeof Config.saves.onSave&&Config.saves.onSave(t),t.state.delta=State.deltaEncode(t.state.history),delete t.state.history,t}function A(e){try{if(T(e),!e||!e.hasOwnProperty(\"id\")||!e.hasOwnProperty(\"state\"))throw new Error(L10n.get(\"errorSaveMissingData\"));if(e.state.history=State.deltaDecode(e.state.delta),delete e.state.delta,\"function\"==typeof Config.saves.onLoad&&Config.saves.onLoad(e),e.id!==Config.saves.id)throw new Error(L10n.get(\"errorSaveIdMismatch\"));State.unmarshalForSave(e.state),Engine.show()}catch(e){return UI.alert(e.message.toUpperFirst()+\".</p><p>\"+L10n.get(\"aborting\")+\".\"),!1}return!0}var P=-1;return Object.freeze(Object.defineProperties({},{init:{value:e},get:{value:r},clear:{value:n},ok:{value:a},autosave:{value:Object.freeze(Object.defineProperties({},{ok:{value:i},has:{value:o},get:{value:s},load:{value:u},save:{value:l},delete:{value:c}}))},slots:{value:Object.freeze(Object.defineProperties({},{ok:{value:d},length:{get:f},isEmpty:{value:h},count:{value:p},has:{value:g},get:{value:m},load:{value:v},save:{value:y},delete:{value:b}}))},export:{value:w},import:{value:k},serialize:{value:S},deserialize:{value:E}}))}(),Setting=function(){function e(){if(storage.has(\"options\")){var e=storage.get(\"options\");null!==e&&(window.SugarCube.settings=settings=Object.assign(t(),e)),r(),storage.delete(\"options\")}n(),m.forEach(function(e){if(e.hasOwnProperty(\"onInit\")){var t={name:e.name,value:settings[e.name],default:e.default};e.hasOwnProperty(\"list\")&&(t.list=e.list),e.onInit.call(t)}})}function t(){return Object.create(null)}function r(){var e=t();return Object.keys(settings).length>0&&m.filter(function(e){return e.type!==v.Header&&settings[e.name]!==e.default}).forEach(function(t){return e[t.name]=settings[t.name]}),0===Object.keys(e).length?(storage.delete(\"settings\"),!0):storage.set(\"settings\",e)}function n(){var e=t(),r=storage.get(\"settings\")||t();m.filter(function(e){return e.type!==v.Header}).forEach(function(t){return e[t.name]=t.default}),window.SugarCube.settings=settings=Object.assign(e,r)}function a(){return window.SugarCube.settings=settings=t(),storage.delete(\"settings\"),!0}function i(e){if(0===arguments.length)a(),n();else{if(null==e||!p(e))throw new Error('nonexistent setting \"'+e+'\"');var t=h(e);t.type!==v.Header&&(settings[e]=t.default)}return r()}function o(e,t){m.forEach(e,t)}function s(e,t,r){if(arguments.length<3){var n=[];throw arguments.length<1&&n.push(\"type\"),arguments.length<2&&n.push(\"name\"),arguments.length<3&&n.push(\"definition\"),new Error(\"missing parameters, no \"+n.join(\" or \")+\" specified\")}if(\"object\"!==(void 0===r?\"undefined\":_typeof(r)))throw new TypeError(\"definition parameter must be an object\");if(p(t))throw new Error('cannot clobber existing setting \"'+t+'\"');var a={type:e,name:t,label:\"string\"==typeof r.label?r.label.trim():\"\"};if(\"string\"==typeof r.desc){var i=r.desc.trim();\"\"!==i&&(a.desc=i)}switch(e){case v.Header:break;case v.Toggle:a.default=!!r.default;break;case v.List:if(!r.hasOwnProperty(\"list\"))throw new Error(\"no list specified\");if(!Array.isArray(r.list))throw new TypeError(\"list must be an array\");if(0===r.list.length)throw new Error(\"list must not be empty\");if(a.list=Object.freeze(r.list),null==r.default)a.default=r.list[0];else{var o=r.list.indexOf(r.default);if(-1===o)throw new Error(\"list does not contain default\");a.default=r.list[o]}break;case v.Range:if(!r.hasOwnProperty(\"min\"))throw new Error(\"no min specified\");if(\"number\"!=typeof r.min||Number.isNaN(r.min)||!Number.isFinite(r.min))throw new TypeError(\"min must be a finite number\");if(!r.hasOwnProperty(\"max\"))throw new Error(\"no max specified\");if(\"number\"!=typeof r.max||Number.isNaN(r.max)||!Number.isFinite(r.max))throw new TypeError(\"max must be a finite number\");if(!r.hasOwnProperty(\"step\"))throw new Error(\"no step specified\");if(\"number\"!=typeof r.step||Number.isNaN(r.step)||!Number.isFinite(r.step)||r.step<=0)throw new TypeError(\"step must be a finite number greater than zero\");var s=function(){var e=String(r.step),t=e.lastIndexOf(\".\");return-1===t?0:e.length-t-1}();if(function(e){if(s>0){var t=Number(r.min+\"e\"+s),n=Number(r.step+\"e\"+s),a=Number(e+\"e\"+s)-t;return Number(a-a%n+t+\"e-\"+s)}var i=e-r.min;return i-i%r.step+r.min}(r.max)!==r.max)throw new RangeError(\"max (\"+r.max+\") is not a multiple of the step (\"+r.step+\") plus the min (\"+r.min+\")\");if(a.max=r.max,a.min=r.min,a.step=r.step,null==r.default)a.default=r.max;else{if(\"number\"!=typeof r.default||Number.isNaN(r.default)||!Number.isFinite(r.default))throw new TypeError(\"default must be a finite number\");if(r.default<r.min)throw new RangeError(\"default (\"+r.default+\") is less than min (\"+r.min+\")\");if(r.default>r.max)throw new RangeError(\"default (\"+r.default+\") is greater than max (\"+r.max+\")\");a.default=r.default}break;default:throw new Error(\"unknown Setting type: \"+e)}\"function\"==typeof r.onInit&&(a.onInit=Object.freeze(r.onInit)),\"function\"==typeof r.onChange&&(a.onChange=Object.freeze(r.onChange)),m.push(Object.freeze(a))}function u(e,t){s(v.Header,e,{desc:t})}function l(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];s.apply(undefined,[v.Toggle].concat(t))}function c(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];s.apply(undefined,[v.List].concat(t))}function d(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];s.apply(undefined,[v.Range].concat(t))}function f(){return 0===m.length}function p(e){return m.some(function(t){return t.name===e})}function h(e){return m.find(function(t){return t.name===e})}function g(e){p(e)&&delete settings[e];for(var t=0;t<m.length;++t)if(m[t].name===e){m.splice(t,1),g(e);break}}var m=[],v=Util.toEnum({Header:0,Toggle:1,List:2,Range:3});return Object.freeze(Object.defineProperties({},{Types:{value:v},init:{value:e},create:{value:t},save:{value:r},load:{value:n},clear:{value:a},reset:{value:i},forEach:{value:o},add:{value:s},addHeader:{value:u},addToggle:{value:l},addList:{value:c},addRange:{value:d},isEmpty:{value:f},has:{value:p},get:{value:h},delete:{value:g}}))}(),Story=function(){function e(){function e(e){if(e.tags.includesAny(n))throw new Error('starting passage \"'+e.title+'\" contains illegal tags; invalid: \"'+e.tags.filter(function(e){return n.includes(e)}).sort().join('\", \"')+'\"')}function t(e){if(a.includes(e.title)&&e.tags.includesAny(n))throw new Error('special passage \"'+e.title+'\" contains illegal tags; invalid: \"'+e.tags.filter(function(e){return n.includes(e)}).sort().join('\", \"')+'\"')}var n=[\"widget\"],a=[\"PassageDone\",\"PassageFooter\",\"PassageHeader\",\"PassageReady\",\"StoryAuthor\",\"StoryBanner\",\"StoryCaption\",\"StoryInit\",\"StoryMenu\",\"StoryShare\",\"StorySubtitle\"],i=jQuery(\"tw-storydata\"),o=i.attr(\"startnode\")||\"\";Config.passages.start=null,Config.debug=/\\bdebug\\b/.test(i.attr(\"options\")),i.children(\"style\").each(function(e){d.push(new Passage(\"tw-user-style-\"+e,this))}),i.children(\"script\").each(function(e){f.push(new Passage(\"tw-user-script-\"+e,this))}),i.children('tw-passagedata:not([tags~=\"Twine.private\"],[tags~=\"annotation\"])').each(function(){var r=jQuery(this),n=r.attr(\"pid\")||\"\",a=new Passage(r.attr(\"name\"),this);n===o&&\"\"!==o?(Config.passages.start=a.title,e(a),c[a.title]=a):a.tags.includes(\"widget\")?p.push(a):(t(a),c[a.title]=a)}),g=i.attr(\"ifid\"),r(Util.unescape(\"{{STORY_NAME}}\")),Config.saves.id=Story.domId}function t(){!function(){var e=document.createElement(\"style\");new StyleWrapper(e).add(d.map(function(e){return e.text.trim()}).join(\"\\n\")),jQuery(e).appendTo(document.head).attr({id:\"style-story\",type:\"text/css\"})}();for(var e=0;e<f.length;++e)try{Scripting.evalJavaScript(f[e].text)}catch(t){console.error(t),Alert.error(f[e].title,\"object\"===(void 0===t?\"undefined\":_typeof(t))?t.message:t)}for(var t=0;t<p.length;++t)try{Wikifier.wikifyEval(p[t].processText())}catch(e){console.error(e),Alert.error(p[t].title,\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e)}}function r(e){if(null==e||\"\"===e)throw new Error(\"story title cannot be null or empty\");if(document.title=h=Util.unescape(e),m=Util.slugify(h),\"\"===h||\"\"===m)throw new Error(\"story title must include characters from the basic Latin alphabet\")}function n(){return h}function a(){return m}function i(){return g}function o(e){var t=void 0===e?\"undefined\":_typeof(e);switch(t){case\"number\":case\"string\":return c.hasOwnProperty(String(e));case\"boolean\":case\"function\":t=\"a \"+t;break;case\"undefined\":break;default:t=null===e?\"null\":\"an \"+t}throw new TypeError(\"Story.has title parameter cannot be \"+t)}function s(e){var t=void 0===e?\"undefined\":_typeof(e);switch(t){case\"number\":case\"string\":var r=String(e);return c.hasOwnProperty(r)?c[r]:new Passage(r||\"(unknown)\");case\"boolean\":case\"function\":t=\"a \"+t;break;case\"undefined\":break;default:t=null===e?\"null\":\"an \"+t}throw new TypeError(\"Story.get title parameter cannot be \"+t)}function u(e,t){for(var r=arguments.length>2&&arguments[2]!==undefined?arguments[2]:\"title\",n=Object.keys(c),a=[],i=0;i<n.length;++i){var o=c[n[i]];if(o.hasOwnProperty(e))switch(_typeof(o[e])){case\"undefined\":break;case\"object\":o[e]instanceof Array&&o[e].some(function(e){return e==t})&&a.push(o);break;default:o[e]==t&&a.push(o)}}return a.sort(function(e,t){return e[r]==t[r]?0:e[r]<t[r]?-1:1}),a}function l(e){var t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:\"title\";if(\"function\"!=typeof e)throw new Error(\"Story.lookupWith filter parameter must be a function\");for(var r=Object.keys(c),n=[],a=0;a<r.length;++a){var i=c[r[a]];e(i)&&n.push(i)}return n.sort(function(e,r){return e[t]==r[t]?0:e[t]<r[t]?-1:1}),n}var c={},d=[],f=[],p=[],h=\"\",g=\"\",m=\"\";return Object.freeze(Object.defineProperties({},{passages:{value:c},styles:{value:d},scripts:{value:f},widgets:{value:p},load:{value:e},init:{value:t},title:{get:n},domId:{get:a},ifId:{get:i},has:{value:o},get:{value:s},lookup:{value:u},lookupWith:{value:l}}))}(),UI=function(){function e(e,t){var r=t,n=Config.debug,a=Config.cleanupWikifierOutput;Config.debug=!1,Config.cleanupWikifierOutput=!1;try{null==r&&(r=document.createElement(\"ul\"));var i=document.createDocumentFragment();new Wikifier(i,Story.get(e).processText().trim());var o=[].concat(_toConsumableArray(i.querySelectorAll(\".error\"))).map(function(e){return e.textContent.replace(errorPrologRegExp,\"\")});if(o.length>0)throw new Error(o.join(\"; \"));for(;i.hasChildNodes();){var s=i.firstChild\n;if(s.nodeType===Node.ELEMENT_NODE&&\"A\"===s.nodeName.toUpperCase()){var u=document.createElement(\"li\");r.appendChild(u),u.appendChild(s)}else i.removeChild(s)}}finally{Config.cleanupWikifierOutput=a,Config.debug=n}return r}function t(e){jQuery(Dialog.setup(\"Alert\",\"alert\")).append(\"<p>\"+e+'</p><ul class=\"buttons\"><li><button id=\"alert-ok\" class=\"ui-close\">'+L10n.get([\"alertOk\",\"ok\"])+\"</button></li></ul>\");for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];Dialog.open.apply(Dialog,r)}function r(){u(),Dialog.open.apply(Dialog,arguments)}function n(){l(),Dialog.open.apply(Dialog,arguments)}function a(){c(),Dialog.open.apply(Dialog,arguments)}function i(){d(),Dialog.open.apply(Dialog,arguments)}function o(){f(),Dialog.open.apply(Dialog,arguments)}function s(){return jQuery(Dialog.setup(L10n.get(\"autoloadTitle\"),\"autoload\")).append(\"<p>\"+L10n.get(\"autoloadPrompt\")+'</p><ul class=\"buttons\"><li><button id=\"autoload-ok\" class=\"ui-close\">'+L10n.get([\"autoloadOk\",\"ok\"])+'</button></li><li><button id=\"autoload-cancel\" class=\"ui-close\">'+L10n.get([\"autoloadCancel\",\"cancel\"])+\"</button></li></ul>\"),jQuery(document).one(\"click.autoload\",\".ui-close\",function(e){var t=\"autoload-ok\"===e.target.id;jQuery(document).one(\":dialogclosed\",function(){t&&Save.autosave.load()||Engine.play(Config.passages.start)})}),!0}function u(){var e=document.createElement(\"ul\");jQuery(Dialog.setup(L10n.get(\"jumptoTitle\"),\"jumpto list\")).append(e);for(var t=State.expired.length,r=State.size-1;r>=0;--r)if(r!==State.activeIndex){var n=Story.get(State.history[r].title);n&&n.tags.includes(\"bookmark\")&&jQuery(document.createElement(\"li\")).append(jQuery(document.createElement(\"a\")).ariaClick({one:!0},function(e){return function(){return jQuery(document).one(\":dialogclosed\",function(){return Engine.goTo(e)})}}(r)).addClass(\"ui-close\").text(L10n.get(\"jumptoTurn\")+\" \"+(t+r+1)+\": \"+n.description())).appendTo(e)}e.hasChildNodes()||jQuery(e).append(\"<li><a><em>\"+L10n.get(\"jumptoUnavailable\")+\"</em></a></li>\")}function l(){return jQuery(Dialog.setup(L10n.get(\"restartTitle\"),\"restart\")).append(\"<p>\"+L10n.get(\"restartPrompt\")+'</p><ul class=\"buttons\"><li><button id=\"restart-ok\">'+L10n.get([\"restartOk\",\"ok\"])+'</button></li><li><button id=\"restart-cancel\" class=\"ui-close\">'+L10n.get([\"restartCancel\",\"cancel\"])+\"</button></li></ul>\").find(\"#restart-ok\").ariaClick({one:!0},function(){jQuery(document).one(\":dialogclosed\",function(){return Engine.restart()}),Dialog.close()}),!0}function c(){function e(e,t,r,n){var a=jQuery(document.createElement(\"button\")).attr(\"id\",\"saves-\"+e).html(r);return t&&a.addClass(t),n?a.ariaClick(n):a.ariaDisabled(!0),jQuery(document.createElement(\"li\")).append(a)}var r=jQuery(Dialog.setup(L10n.get(\"savesTitle\"),\"saves\")),n=Save.ok();if(n&&r.append(function(){function e(e,t,r,n,a){var i=jQuery(document.createElement(\"button\")).attr(\"id\",\"saves-\"+e+\"-\"+n).addClass(e).html(r);return t&&i.addClass(t),a?\"auto\"===n?i.ariaClick({label:r+\" \"+L10n.get(\"savesLabelAuto\")},function(){return a()}):i.ariaClick({label:r+\" \"+L10n.get(\"savesLabelSlot\")+\" \"+(n+1)},function(){return a(n)}):i.ariaDisabled(!0),i}var t=Save.get(),r=jQuery(document.createElement(\"tbody\"));if(Save.autosave.ok()){var n=jQuery(document.createElement(\"td\")),a=jQuery(document.createElement(\"td\")),i=jQuery(document.createElement(\"td\")),o=jQuery(document.createElement(\"td\"));jQuery(document.createElement(\"b\")).attr({title:L10n.get(\"savesLabelAuto\"),\"aria-label\":L10n.get(\"savesLabelAuto\")}).text(\"A\").appendTo(n),t.autosave?(a.append(e(\"load\",\"ui-close\",L10n.get(\"savesLabelLoad\"),\"auto\",function(){jQuery(document).one(\":dialogclosed\",function(){return Save.autosave.load()})})),jQuery(document.createElement(\"div\")).text(t.autosave.title).appendTo(i),jQuery(document.createElement(\"div\")).addClass(\"datestamp\").html(t.autosave.date?\"\"+new Date(t.autosave.date).toLocaleString():\"<em>\"+L10n.get(\"savesUnknownDate\")+\"</em>\").appendTo(i),o.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),\"auto\",function(){Save.autosave.delete(),c()}))):(a.append(e(\"load\",null,L10n.get(\"savesLabelLoad\"),\"auto\")),i.addClass(\"empty\").text(\"•  •  •\"),o.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),\"auto\"))),jQuery(document.createElement(\"tr\")).append(n).append(a).append(i).append(o).appendTo(r)}for(var s=0,u=t.slots.length;s<u;++s){var l=jQuery(document.createElement(\"td\")),d=jQuery(document.createElement(\"td\")),f=jQuery(document.createElement(\"td\")),p=jQuery(document.createElement(\"td\"));l.append(document.createTextNode(s+1)),t.slots[s]?(d.append(e(\"save\",\"ui-close\",L10n.get(\"savesLabelSave\"),s,Save.slots.save),e(\"load\",\"ui-close\",L10n.get(\"savesLabelLoad\"),s,function(e){jQuery(document).one(\":dialogclosed\",function(){return Save.slots.load(e)})})),jQuery(document.createElement(\"div\")).text(t.slots[s].title).appendTo(f),jQuery(document.createElement(\"div\")).addClass(\"datestamp\").html(t.slots[s].date?\"\"+new Date(t.slots[s].date).toLocaleString():\"<em>\"+L10n.get(\"savesUnknownDate\")+\"</em>\").appendTo(f),p.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),s,function(e){Save.slots.delete(e),c()}))):(d.append(e(\"save\",\"ui-close\",L10n.get(\"savesLabelSave\"),s,Save.slots.save)),f.addClass(\"empty\").text(\"•  •  •\"),p.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),s))),jQuery(document.createElement(\"tr\")).append(l).append(d).append(f).append(p).appendTo(r)}return jQuery(document.createElement(\"table\")).attr(\"id\",\"saves-list\").append(r)}()),n||Has.fileAPI){var a=jQuery(document.createElement(\"ul\")).addClass(\"buttons\").appendTo(r);return Has.fileAPI&&(a.append(e(\"export\",\"ui-close\",L10n.get(\"savesLabelExport\"),function(){return Save.export()})),a.append(e(\"import\",null,L10n.get(\"savesLabelImport\"),function(){return r.find(\"#saves-import-file\").trigger(\"click\")})),jQuery(document.createElement(\"input\")).css({display:\"block\",visibility:\"hidden\",position:\"fixed\",left:\"-9999px\",top:\"-9999px\",width:\"1px\",height:\"1px\"}).attr({type:\"file\",id:\"saves-import-file\",tabindex:-1,\"aria-hidden\":!0}).on(\"change\",function(e){jQuery(document).one(\":dialogclosed\",function(){return Save.import(e)}),Dialog.close()}).appendTo(r)),n&&a.append(e(\"clear\",null,L10n.get(\"savesLabelClear\"),Save.autosave.has()||!Save.slots.isEmpty()?function(){Save.clear(),c()}:null)),!0}return t(L10n.get(\"savesIncapable\")),!1}function d(){var e=jQuery(Dialog.setup(L10n.get(\"settingsTitle\"),\"settings\"));return Setting.forEach(function(t){if(t.type===Setting.Types.Header){var r=t.name,n=Util.slugify(r),a=jQuery(document.createElement(\"div\")),i=jQuery(document.createElement(\"h2\"));return a.attr(\"id\",\"header-body-\"+n).append(i).appendTo(e),i.attr(\"id\",\"header-heading-\"+n).wiki(r),void(t.desc&&jQuery(document.createElement(\"p\")).attr(\"id\",\"header-desc-\"+n).wiki(t.desc).appendTo(a))}var o=t.name,s=Util.slugify(o),u=jQuery(document.createElement(\"div\")),l=jQuery(document.createElement(\"label\")),c=jQuery(document.createElement(\"div\")),d=void 0;switch(jQuery(document.createElement(\"div\")).append(l).append(c).appendTo(u),t.desc&&jQuery(document.createElement(\"p\")).attr(\"id\",\"setting-desc-\"+s).wiki(t.desc).appendTo(u),l.attr({id:\"setting-label-\"+s,for:\"setting-control-\"+s}).wiki(t.label),null==settings[o]&&(settings[o]=t.default),t.type){case Setting.Types.Toggle:d=jQuery(document.createElement(\"button\")),settings[o]?d.addClass(\"enabled\").text(L10n.get(\"settingsOn\")):d.text(L10n.get(\"settingsOff\")),d.ariaClick(function(){settings[o]?(jQuery(this).removeClass(\"enabled\").text(L10n.get(\"settingsOff\")),settings[o]=!1):(jQuery(this).addClass(\"enabled\").text(L10n.get(\"settingsOn\")),settings[o]=!0),Setting.save(),t.hasOwnProperty(\"onChange\")&&t.onChange.call({name:o,value:settings[o],default:t.default})});break;case Setting.Types.List:d=jQuery(document.createElement(\"select\"));for(var f=0,p=t.list.length;f<p;++f)jQuery(document.createElement(\"option\")).val(f).text(t.list[f]).appendTo(d);d.val(t.list.indexOf(settings[o])).attr(\"tabindex\",0).on(\"change\",function(){settings[o]=t.list[Number(this.value)],Setting.save(),t.hasOwnProperty(\"onChange\")&&t.onChange.call({name:o,value:settings[o],default:t.default,list:t.list})});break;case Setting.Types.Range:d=jQuery(document.createElement(\"input\")),d.attr({type:\"range\",min:t.min,max:t.max,step:t.step,value:settings[o],tabindex:0}).on(\"change input\",function(){settings[o]=Number(this.value),Setting.save(),t.hasOwnProperty(\"onChange\")&&t.onChange.call({name:o,value:settings[o],default:t.default,min:t.min,max:t.max,step:t.step})}).on(\"keypress\",function(e){13===e.which&&(e.preventDefault(),d.trigger(\"change\"))})}d.attr(\"id\",\"setting-control-\"+s).appendTo(c),u.attr(\"id\",\"setting-body-\"+s).appendTo(e)}),e.append('<ul class=\"buttons\"><li><button id=\"settings-ok\" class=\"ui-close\">'+L10n.get([\"settingsOk\",\"ok\"])+'</button></li><li><button id=\"settings-reset\">'+L10n.get(\"settingsReset\")+\"</button></li></ul>\").find(\"#settings-reset\").ariaClick({one:!0},function(){jQuery(document).one(\":dialogclosed\",function(){Setting.reset(),window.location.reload()}),Dialog.close()}),!0}function f(){try{jQuery(Dialog.setup(L10n.get(\"shareTitle\"),\"share list\")).append(e(\"StoryShare\"))}catch(e){return console.error(e),Alert.error(\"StoryShare\",e.message),!1}return!0}return Object.freeze(Object.defineProperties({},{assembleLinkList:{value:e},alert:{value:t},jumpto:{value:r},restart:{value:n},saves:{value:a},settings:{value:i},share:{value:o},buildAutoload:{value:s},buildJumpto:{value:u},buildRestart:{value:l},buildSaves:{value:c},buildSettings:{value:d},buildShare:{value:f},stow:{value:function(){return UIBar.stow()}},unstow:{value:function(){return UIBar.unstow()}},setStoryElements:{value:function(){return UIBar.update()}},isOpen:{value:function(){return Dialog.isOpen.apply(Dialog,arguments)}},body:{value:function(){return Dialog.body()}},setup:{value:function(){return Dialog.setup.apply(Dialog,arguments)}},addClickHandler:{value:function(){return Dialog.addClickHandler.apply(Dialog,arguments)}},open:{value:function(){return Dialog.open.apply(Dialog,arguments)}},close:{value:function(){return Dialog.close.apply(Dialog,arguments)}},resize:{value:function(){return Dialog.resize()}},buildDialogAutoload:{value:s},buildDialogJumpto:{value:u},buildDialogRestart:{value:l},buildDialogSaves:{value:c},buildDialogSettings:{value:d},buildDialogShare:{value:f},buildLinkListFromPassage:{value:e}}))}(),UIBar=function(){function e(){c&&(c.hide(),jQuery(document).off(\".ui-bar\"),jQuery(document.head).find(\"#style-ui-bar\").remove(),c.remove(),c=null)}function t(){return c&&c.hide(),this}function r(){if(!document.getElementById(\"ui-bar\")){var e=function(){var e=L10n.get(\"uiBarToggle\"),t=L10n.get(\"uiBarBackward\"),r=L10n.get(\"uiBarJumpto\"),n=L10n.get(\"uiBarForward\");return jQuery(document.createDocumentFragment()).append('<div id=\"ui-bar\"><div id=\"ui-bar-tray\"><button id=\"ui-bar-toggle\" tabindex=\"0\" title=\"'+e+'\" aria-label=\"'+e+'\"></button><div id=\"ui-bar-history\"><button id=\"history-backward\" tabindex=\"0\" title=\"'+t+'\" aria-label=\"'+t+'\"></button><button id=\"history-jumpto\" tabindex=\"0\" title=\"'+r+'\" aria-label=\"'+r+'\"></button><button id=\"history-forward\" tabindex=\"0\" title=\"'+n+'\" aria-label=\"'+n+'\"></button></div></div><div id=\"ui-bar-body\"><header id=\"title\" role=\"banner\"><div id=\"story-banner\"></div><h1 id=\"story-title\"></h1><div id=\"story-subtitle\"></div><div id=\"story-title-separator\"></div><p id=\"story-author\"></p></header><div id=\"story-caption\"></div><nav id=\"menu\" role=\"navigation\"><ul id=\"menu-story\"></ul><ul id=\"menu-core\"><li id=\"menu-item-saves\"><a tabindex=\"0\">'+L10n.get(\"savesTitle\")+'</a></li><li id=\"menu-item-settings\"><a tabindex=\"0\">'+L10n.get(\"settingsTitle\")+'</a></li><li id=\"menu-item-restart\"><a tabindex=\"0\">'+L10n.get(\"restartTitle\")+'</a></li><li id=\"menu-item-share\"><a tabindex=\"0\">'+L10n.get(\"shareTitle\")+\"</a></li></ul></nav></div></div>\")}();c=jQuery(e.find(\"#ui-bar\").get(0)),e.insertBefore(\"body>script#script-sugarcube\"),jQuery(document).on(\":historyupdate.ui-bar\",function(e,t){return function(){e.ariaDisabled(State.length<2),t.ariaDisabled(State.length===State.size)}}(jQuery(\"#history-backward\"),jQuery(\"#history-forward\")))}}function n(){return c&&\"none\"===c.css(\"display\")}function a(){return c&&c.hasClass(\"stowed\")}function i(){return c&&c.show(),this}function o(){c&&((\"boolean\"==typeof Config.ui.stowBarInitially?Config.ui.stowBarInitially:jQuery(window).width()<=Config.ui.stowBarInitially)&&function(){var e=jQuery(c).add(\"#story\");e.addClass(\"no-transition\"),c.addClass(\"stowed\"),setTimeout(function(){return e.removeClass(\"no-transition\")},Engine.minDomActionDelay)}(),jQuery(\"#ui-bar-toggle\").ariaClick({label:L10n.get(\"uiBarToggle\")},function(){return c.toggleClass(\"stowed\")}),Config.history.controls?(jQuery(\"#history-backward\").ariaDisabled(State.length<2).ariaClick({label:L10n.get(\"uiBarBackward\")},function(){return Engine.backward()}),Story.lookup(\"tags\",\"bookmark\").length>0?jQuery(\"#history-jumpto\").ariaClick({label:L10n.get(\"uiBarJumpto\")},function(){return UI.jumpto()}):jQuery(\"#history-jumpto\").remove(),jQuery(\"#history-forward\").ariaDisabled(State.length===State.size).ariaClick({label:L10n.get(\"uiBarForward\")},function(){return Engine.forward()})):jQuery(\"#ui-bar-history\").remove(),jQuery(\"#story-title\").text(Story.title),Story.has(\"StoryCaption\")||jQuery(\"#story-caption\").remove(),Story.has(\"StoryMenu\")||jQuery(\"#menu-story\").remove(),Config.ui.updateStoryElements||l(),jQuery(\"#menu-item-saves a\").ariaClick(function(e){e.preventDefault(),UI.buildSaves(),Dialog.open()}).text(L10n.get(\"savesTitle\")),Setting.isEmpty()?jQuery(\"#menu-item-settings\").remove():jQuery(\"#menu-item-settings a\").ariaClick(function(e){e.preventDefault(),UI.buildSettings(),Dialog.open()}).text(L10n.get(\"settingsTitle\")),jQuery(\"#menu-item-restart a\").ariaClick(function(e){e.preventDefault(),UI.buildRestart(),Dialog.open()}).text(L10n.get(\"restartTitle\")),Story.has(\"StoryShare\")?jQuery(\"#menu-item-share a\").ariaClick(function(e){e.preventDefault(),UI.buildShare(),Dialog.open()}).text(L10n.get(\"shareTitle\")):jQuery(\"#menu-item-share\").remove())}function s(e){if(c&&!c.hasClass(\"stowed\")){var t=void 0;e&&(t=jQuery(\"#story\"),t.addClass(\"no-transition\"),c.addClass(\"no-transition\")),c.addClass(\"stowed\"),e&&setTimeout(function(){t.removeClass(\"no-transition\"),c.removeClass(\"no-transition\")},Engine.minDomActionDelay)}return this}function u(e){if(c&&c.hasClass(\"stowed\")){var t=void 0;e&&(t=jQuery(\"#story\"),t.addClass(\"no-transition\"),c.addClass(\"no-transition\")),c.removeClass(\"stowed\"),e&&setTimeout(function(){t.removeClass(\"no-transition\"),c.removeClass(\"no-transition\")},Engine.minDomActionDelay)}return this}function l(){if(c){setPageElement(\"story-banner\",\"StoryBanner\"),setPageElement(\"story-subtitle\",\"StorySubtitle\"),setPageElement(\"story-author\",\"StoryAuthor\"),setPageElement(\"story-caption\",\"StoryCaption\");var e=document.getElementById(\"menu-story\");if(null!==e&&(jQuery(e).empty(),Story.has(\"StoryMenu\")))try{UI.assembleLinkList(\"StoryMenu\",e)}catch(e){console.error(e),Alert.error(\"StoryMenu\",e.message)}}}var c=null;return Object.freeze(Object.defineProperties({},{destroy:{value:e},hide:{value:t},init:{value:r},isHidden:{value:n},isStowed:{value:a},show:{value:i},start:{value:o},stow:{value:s},unstow:{value:u},update:{value:l},setStoryElements:{value:l}}))}(),DebugBar=function(){function e(){var e=L10n.get(\"debugBarToggle\"),t=L10n.get(\"debugBarAddWatch\"),o=L10n.get(\"debugBarWatchAll\"),u=L10n.get(\"debugBarWatchNone\"),c=L10n.get(\"debugBarWatchToggle\"),h=L10n.get(\"debugBarViewsToggle\");jQuery(document.createDocumentFragment()).append('<div id=\"debug-bar\"><div id=\"debug-bar-watch\" aria-hidden=\"true\" hidden=\"hidden\"><div>'+L10n.get(\"debugBarNoWatches\")+'</div>></div><div><button id=\"debug-bar-watch-toggle\" tabindex=\"0\" title=\"'+c+'\" aria-label=\"'+c+'\">'+L10n.get(\"debugBarLabelWatch\")+'</button><label id=\"debug-bar-watch-label\" for=\"debug-bar-watch-input\">'+L10n.get(\"debugBarLabelAdd\")+'</label><input id=\"debug-bar-watch-input\" name=\"debug-bar-watch-input\" type=\"text\" list=\"debug-bar-watch-list\" tabindex=\"0\"><datalist id=\"debug-bar-watch-list\" aria-hidden=\"true\" hidden=\"hidden\"></datalist><button id=\"debug-bar-watch-add\" tabindex=\"0\" title=\"'+t+'\" aria-label=\"'+t+'\"></button><button id=\"debug-bar-watch-all\" tabindex=\"0\" title=\"'+o+'\" aria-label=\"'+o+'\"></button><button id=\"debug-bar-watch-none\" tabindex=\"0\" title=\"'+u+'\" aria-label=\"'+u+'\"></button></div><div><button id=\"debug-bar-views-toggle\" tabindex=\"0\" title=\"'+h+'\" aria-label=\"'+h+'\">'+L10n.get(\"debugBarLabelViews\")+'</button><label id=\"debug-bar-turn-label\" for=\"debug-bar-turn-select\">'+L10n.get(\"debugBarLabelTurn\")+'</label><select id=\"debug-bar-turn-select\" tabindex=\"0\"></select></div><button id=\"debug-bar-toggle\" tabindex=\"0\" title=\"'+e+'\" aria-label=\"'+e+'\"></button></div><div id=\"debug-bar-hint\"></div>').appendTo(\"body\"),y=jQuery(\"#debug-bar\"),b=jQuery(y.find(\"#debug-bar-watch\").get(0)),w=jQuery(y.find(\"#debug-bar-watch-list\").get(0)),k=jQuery(y.find(\"#debug-bar-turn-select\").get(0));var g=jQuery(y.find(\"#debug-bar-toggle\").get(0)),m=jQuery(y.find(\"#debug-bar-watch-toggle\").get(0)),v=jQuery(y.find(\"#debug-bar-watch-input\").get(0)),E=jQuery(y.find(\"#debug-bar-watch-add\").get(0)),j=jQuery(y.find(\"#debug-bar-watch-all\").get(0)),x=jQuery(y.find(\"#debug-bar-watch-none\").get(0)),O=jQuery(y.find(\"#debug-bar-views-toggle\").get(0));g.ariaClick(function(){S?n():r(),S=!S,l()}),m.ariaClick(function(){b.attr(\"hidden\")?b.removeAttr(\"aria-hidden hidden\"):b.attr({\"aria-hidden\":!0,hidden:\"hidden\"}),l()}),v.on(\":addwatch\",function(){a(this.value.trim()),this.value=\"\"}).on(\"keypress\",function(e){13===e.which&&(e.preventDefault(),v.trigger(\":addwatch\"))}),E.ariaClick(function(){return v.trigger(\":addwatch\")}),j.ariaClick(i),x.ariaClick(s),k.on(\"change\",function(){Engine.goTo(Number(this.value))}),O.ariaClick(function(){DebugView.toggle(),l()}),jQuery(document).on(\":historyupdate.debug-bar\",p).on(\":passageend.debug-bar\",function(){d(),f()}).on(\":enginerestart.debug-bar\",function(){session.delete(\"debugState\")})}function t(){u(),c(),p(),d(),f()}function r(){y.css(\"right\",\"-\"+y.outerWidth()+\"px\"),l()}function n(){y.css(\"right\",0),l()}function a(e){g.test(e)&&(v.pushUnique(e),v.sort(),d(),f(),l())}function i(){Object.keys(State.variables).map(function(e){return v.pushUnique(\"$\"+e)}),Object.keys(State.temporary).map(function(e){return v.pushUnique(\"_\"+e)}),v.sort(),d(),f(),l()}function o(e){v.delete(e),d(),f(),l()}function s(){for(var e=v.length-1;e>=0;--e)v.pop();d(),f(),l()}function u(){if(session.has(\"debugState\")){var e=session.get(\"debugState\");S=e.stowed,v.push.apply(v,_toConsumableArray(e.watchList)),e.watchEnabled?b.removeAttr(\"aria-hidden hidden\"):b.attr({\"aria-hidden\":!0,hidden:\"hidden\"}),e.viewsEnabled?DebugView.enable():DebugView.disable()}}function l(){session.set(\"debugState\",{stowed:S,watchList:v,watchEnabled:!b.attr(\"hidden\"),viewsEnabled:DebugView.isEnabled()})}function c(){S?r():n()}function d(){if(0===v.length)return void b.empty().append(\"<div>\"+L10n.get(\"debugBarNoWatches\")+\"</div>\");for(var e=L10n.get(\"debugBarDeleteWatch\"),t=jQuery(document.createElement(\"table\")),r=jQuery(document.createElement(\"tbody\")),n=0,a=v.length;n<a;++n)!function(t,n){var a=v[t],i=a.slice(1),s=\"$\"===a[0]?State.variables:State.temporary,u=jQuery(document.createElement(\"tr\")),l=jQuery(document.createElement(\"button\")),c=jQuery(document.createElement(\"code\"));l.addClass(\"watch-delete\").attr(\"data-name\",a).ariaClick({one:!0,label:e},function(){return o(a)}),c.text(h(s[i])),jQuery(document.createElement(\"td\")).append(l).appendTo(u),jQuery(document.createElement(\"td\")).text(a).appendTo(u),jQuery(document.createElement(\"td\")).append(c).appendTo(u),u.appendTo(r)}(n);t.append(r),b.empty().append(t)}function f(){var e=Object.keys(State.variables),t=Object.keys(State.temporary);if(0===e.length&&0===t.length)return void w.empty();var r=[].concat(_toConsumableArray(e.map(function(e){return\"$\"+e})),_toConsumableArray(t.map(function(e){return\"_\"+e}))).sort(),n=document.createDocumentFragment();r.delete(v);for(var a=0,i=r.length;a<i;++a)jQuery(document.createElement(\"option\")).val(r[a]).appendTo(n);w.empty().append(n)}function p(){for(var e=State.size,t=State.expired.length,r=document.createDocumentFragment(),n=0;n<e;++n)jQuery(document.createElement(\"option\")).val(n).text(t+n+1+\". \"+Util.escape(State.history[n].title)).appendTo(r);k.empty().ariaDisabled(e<2).append(r).val(State.activeIndex)}function h(e){if(null===e)return\"null\";switch(void 0===e?\"undefined\":_typeof(e)){case\"number\":if(Number.isNaN(e))return\"NaN\";if(!Number.isFinite(e))return\"Infinity\";case\"boolean\":case\"symbol\":case\"undefined\":return String(e);case\"string\":return JSON.stringify(e);case\"function\":return\"Function\"}var t=Util.toStringTag(e);if(\"Date\"===t)return\"Date {\"+e.toLocaleString()+\"}\";if(\"RegExp\"===t)return\"RegExp \"+e.toString();var r=[];if(e instanceof Array||e instanceof Set){for(var n=e instanceof Array?e:Array.from(e),a=0,i=n.length;a<i;++a)r.push(n.hasOwnProperty(a)?h(n[a]):\"<empty>\");return Object.keys(n).filter(function(e){return!m.test(e)}).forEach(function(e){return r.push(h(e)+\": \"+h(n[e]))}),t+\"(\"+n.length+\") [\"+r.join(\", \")+\"]\"}return e instanceof Map?(e.forEach(function(e,t){return r.push(h(t)+\" → \"+h(e))}),t+\"(\"+e.size+\") {\"+r.join(\", \")+\"}\"):(Object.keys(e).forEach(function(t){return r.push(h(t)+\": \"+h(e[t]))}),t+\" {\"+r.join(\", \")+\"}\")}var g=new RegExp(\"^\"+Patterns.variable+\"$\"),m=/^\\d+$/,v=[],y=null,b=null,w=null,k=null,S=!0;return Object.freeze(Object.defineProperties({},{init:{value:e},start:{value:t},stow:{value:r},unstow:{value:n},watch:{value:a},watchAll:{value:i},unwatch:{value:o},unwatchAll:{value:s}}))}(),LoadScreen=function(){function e(){jQuery(document).on(\"readystatechange.SugarCube\",function(){o.size>0||(\"complete\"===document.readyState?\"loading\"===jQuery(document.documentElement).attr(\"data-init\")&&(Config.loadDelay>0?setTimeout(function(){0===o.size&&r()},Math.max(Engine.minDomActionDelay,Config.loadDelay)):r()):n())})}function t(){jQuery(document).off(\"readystatechange.SugarCube\"),o.clear(),r()}function r(){jQuery(document.documentElement).removeAttr(\"data-init\")}function n(){jQuery(document.documentElement).attr(\"data-init\",\"loading\")}function a(){return++s,o.add(s),n(),s}function i(e){if(null==e)throw new Error(\"LoadScreen.unlock called with a null or undefined ID\");o.has(e)&&o.delete(e),0===o.size&&jQuery(document).trigger(\"readystatechange\")}var o=new Set,s=0;return Object.freeze(Object.defineProperties({},{init:{value:e},clear:{value:t},hide:{value:r},show:{value:n},lock:{value:a},unlock:{value:i}}))}(),version=Object.freeze({title:\"SugarCube\",major:2,minor:29,patch:0,prerelease:null,build:45,date:new Date(\"2019-07-07T20:55:01.448Z\"),extensions:{},toString:function(){var e=this.prerelease?\"-\"+this.prerelease:\"\";return this.major+\".\"+this.minor+\".\"+this.patch+e+\"+\"+this.build},short:function(){var e=this.prerelease?\"-\"+this.prerelease:\"\";return this.title+\" (v\"+this.major+\".\"+this.minor+\".\"+this.patch+e+\")\"},long:function(){return this.title+\" v\"+this.toString()+\" (\"+this.date.toUTCString()+\")\"}}),TempState={},macros={},postdisplay={},postrender={},predisplay={},prehistory={},prerender={},session=null,settings={},setup={},storage=null,browser=Browser,config=Config,has=Has,History=State,state=State,tale=Story,TempVariables=State.temporary;window.SugarCube={},jQuery(function(){try{var e=LoadScreen.lock();LoadScreen.init(),document.normalize&&document.normalize(),Story.load(),storage=SimpleStore.create(Story.domId,!0),session=SimpleStore.create(Story.domId,!1),Dialog.init(),UIBar.init(),Engine.init(),Story.init(),L10n.init(),session.has(\"rcWarn\")||\"cookie\"!==storage.name||(session.set(\"rcWarn\",1),window.alert(L10n.get(\"warningNoWebStorage\"))),Save.init(),Setting.init(),Macro.init(),Engine.start(),Config.debug&&DebugBar.init();var t=$(window),r=setInterval(function(){t.width()&&(clearInterval(r),setTimeout(function(){UIBar.start(),Config.debug&&DebugBar.start(),LoadScreen.unlock(e)},Engine.minDomActionDelay))},Engine.minDomActionDelay);window.SugarCube={Browser:Browser,Config:Config,Dialog:Dialog,Engine:Engine,Has:Has,L10n:L10n,Macro:Macro,Passage:Passage,Save:Save,Scripting:Scripting,Setting:Setting,SimpleAudio:SimpleAudio,State:State,Story:Story,UI:UI,UIBar:UIBar,DebugBar:DebugBar,Util:Util,Visibility:Visibility,Wikifier:Wikifier,session:session,settings:settings,setup:setup,storage:storage,version:version}}catch(e){return console.error(e),LoadScreen.clear(),Alert.fatal(null,e.message,e)}})}(window,window.document,jQuery);}\n\t</script>\n</body>\n</html>\n"});
\ No newline at end of file
diff --git a/devNotes/sugarcube stuff/sugarcube-fc-changes-2.28.0.patch b/devNotes/sugarcube stuff/sugarcube-fc-changes-2.28.0.patch
new file mode 100644
index 00000000000..c34da2f36d0
--- /dev/null
+++ b/devNotes/sugarcube stuff/sugarcube-fc-changes-2.28.0.patch	
@@ -0,0 +1,73 @@
+diff -r df721eb4cd55 src/lib/jquery-plugins.js
+--- a/src/lib/jquery-plugins.js	Sun Dec 16 04:39:00 2018 -0600
++++ b/src/lib/jquery-plugins.js	Fri Jan 25 00:54:01 2019 +0100
+@@ -43,14 +43,9 @@
+		return function () {
+			const $this = jQuery(this);
+
+-			// Exit if the element is disabled.
+-			//
+-			// NOTE: This should only be necessary for elements which are not disableable
+-			// per the HTML specification as disableable elements should be made inert
+-			// automatically.
+-			if ($this.ariaIsDisabled()) {
+-				return;
+-			}
++			const dataPassage = $this.attr('data-passage');
++			const initialDataPassage = window && window.SugarCube && window.SugarCube.State && window.SugarCube.State.passage;
++			const savedYOffset = window.pageYOffset;
+
+			// Toggle "aria-pressed" status, if the attribute exists.
+			if ($this.is('[aria-pressed]')) {
+@@ -59,6 +54,11 @@
+
+			// Call the true handler.
+			fn.apply(this, arguments);
++
++			const doJump = function(){ window.scrollTo(0, savedYOffset); }
++			if ( dataPassage && (window.lastDataPassageLink === dataPassage || initialDataPassage === dataPassage))
++				doJump();
++			window.lastDataPassageLink = dataPassage;
+		};
+	}
+
+diff -r df721eb4cd55 src/lib/simplestore/adapters/webstorage.js
+--- a/src/lib/simplestore/adapters/webstorage.js	Sun Dec 16 04:39:00 2018 -0600
++++ b/src/lib/simplestore/adapters/webstorage.js	Fri Jan 25 00:54:01 2019 +0100
+@@ -189,11 +189,11 @@
+		}
+
+		static _serialize(obj) {
+-			return LZString.compressToUTF16(JSON.stringify(obj));
++			return JSON.stringify(obj);
+		}
+
+		static _deserialize(str) {
+-			return JSON.parse(LZString.decompressFromUTF16(str));
++			return JSON.parse((!str || str[0] == "{") ? str : LZString.decompressFromUTF16(str));
+		}
+	}
+
+diff -r df721eb4cd55 src/state.js
+--- a/src/state.js	Sun Dec 16 04:39:00 2018 -0600
++++ b/src/state.js	Fri Jan 25 00:54:01 2019 +0100
+@@ -104,7 +104,7 @@
+		}
+
+		if (_expired.length > 0) {
+-			stateObj.expired = [..._expired];
++			stateObj.expired = [];
+		}
+
+		if (_prng !== null) {
+diff -r df721eb4cd55 src/ui.js
+--- a/src/ui.js	Sun Dec 16 04:39:00 2018 -0600
++++ b/src/ui.js	Fri Jan 25 00:54:01 2019 +0100
+@@ -334,6 +334,7 @@
+				if (saves.slots[i]) {
+					// Add the load button.
+					$tdLoad.append(
++						createButton('save', 'ui-close', L10n.get('savesLabelSave'), i, Save.slots.save),
+						createButton('load', 'ui-close', L10n.get('savesLabelLoad'), i, slot => {
+							jQuery(document).one(':dialogclose', () => Save.slots.load(slot));
+						})
diff --git a/devNotes/sugarcube stuff/sugarcube-fc-changes.patch b/devNotes/sugarcube stuff/sugarcube-fc-changes.patch
index c34da2f36d0..3a81ee0593e 100644
--- a/devNotes/sugarcube stuff/sugarcube-fc-changes.patch	
+++ b/devNotes/sugarcube stuff/sugarcube-fc-changes.patch	
@@ -1,10 +1,10 @@
-diff -r df721eb4cd55 src/lib/jquery-plugins.js
---- a/src/lib/jquery-plugins.js	Sun Dec 16 04:39:00 2018 -0600
-+++ b/src/lib/jquery-plugins.js	Fri Jan 25 00:54:01 2019 +0100
+diff -r 3892fa22d6fa src/lib/jquery-plugins.js
+--- a/src/lib/jquery-plugins.js	Thu Jun 27 16:10:07 2019 -0500
++++ b/src/lib/jquery-plugins.js	Sun Jul 07 22:52:13 2019 +0200
 @@ -43,14 +43,9 @@
-		return function () {
-			const $this = jQuery(this);
-
+ 		return function () {
+ 			const $this = jQuery(this);
+ 
 -			// Exit if the element is disabled.
 -			//
 -			// NOTE: This should only be necessary for elements which are not disableable
@@ -16,58 +16,58 @@ diff -r df721eb4cd55 src/lib/jquery-plugins.js
 +			const dataPassage = $this.attr('data-passage');
 +			const initialDataPassage = window && window.SugarCube && window.SugarCube.State && window.SugarCube.State.passage;
 +			const savedYOffset = window.pageYOffset;
-
-			// Toggle "aria-pressed" status, if the attribute exists.
-			if ($this.is('[aria-pressed]')) {
+ 
+ 			// Toggle "aria-pressed" status, if the attribute exists.
+ 			if ($this.is('[aria-pressed]')) {
 @@ -59,6 +54,11 @@
-
-			// Call the true handler.
-			fn.apply(this, arguments);
+ 
+ 			// Call the true handler.
+ 			fn.apply(this, arguments);
 +
 +			const doJump = function(){ window.scrollTo(0, savedYOffset); }
 +			if ( dataPassage && (window.lastDataPassageLink === dataPassage || initialDataPassage === dataPassage))
 +				doJump();
 +			window.lastDataPassageLink = dataPassage;
-		};
-	}
-
-diff -r df721eb4cd55 src/lib/simplestore/adapters/webstorage.js
---- a/src/lib/simplestore/adapters/webstorage.js	Sun Dec 16 04:39:00 2018 -0600
-+++ b/src/lib/simplestore/adapters/webstorage.js	Fri Jan 25 00:54:01 2019 +0100
+ 		};
+ 	}
+ 
+diff -r 3892fa22d6fa src/lib/simplestore/adapters/webstorage.js
+--- a/src/lib/simplestore/adapters/webstorage.js	Thu Jun 27 16:10:07 2019 -0500
++++ b/src/lib/simplestore/adapters/webstorage.js	Sun Jul 07 22:52:13 2019 +0200
 @@ -189,11 +189,11 @@
-		}
-
-		static _serialize(obj) {
+ 		}
+ 
+ 		static _serialize(obj) {
 -			return LZString.compressToUTF16(JSON.stringify(obj));
 +			return JSON.stringify(obj);
-		}
-
-		static _deserialize(str) {
+ 		}
+ 
+ 		static _deserialize(str) {
 -			return JSON.parse(LZString.decompressFromUTF16(str));
 +			return JSON.parse((!str || str[0] == "{") ? str : LZString.decompressFromUTF16(str));
-		}
-	}
-
-diff -r df721eb4cd55 src/state.js
---- a/src/state.js	Sun Dec 16 04:39:00 2018 -0600
-+++ b/src/state.js	Fri Jan 25 00:54:01 2019 +0100
+ 		}
+ 	}
+ 
+diff -r 3892fa22d6fa src/state.js
+--- a/src/state.js	Thu Jun 27 16:10:07 2019 -0500
++++ b/src/state.js	Sun Jul 07 22:52:13 2019 +0200
 @@ -104,7 +104,7 @@
-		}
-
-		if (_expired.length > 0) {
+ 		}
+ 
+ 		if (_expired.length > 0) {
 -			stateObj.expired = [..._expired];
 +			stateObj.expired = [];
-		}
-
-		if (_prng !== null) {
-diff -r df721eb4cd55 src/ui.js
---- a/src/ui.js	Sun Dec 16 04:39:00 2018 -0600
-+++ b/src/ui.js	Fri Jan 25 00:54:01 2019 +0100
+ 		}
+ 
+ 		if (_prng !== null) {
+diff -r 3892fa22d6fa src/ui.js
+--- a/src/ui.js	Thu Jun 27 16:10:07 2019 -0500
++++ b/src/ui.js	Sun Jul 07 22:52:13 2019 +0200
 @@ -334,6 +334,7 @@
-				if (saves.slots[i]) {
-					// Add the load button.
-					$tdLoad.append(
+ 				if (saves.slots[i]) {
+ 					// Add the load button.
+ 					$tdLoad.append(
 +						createButton('save', 'ui-close', L10n.get('savesLabelSave'), i, Save.slots.save),
-						createButton('load', 'ui-close', L10n.get('savesLabelLoad'), i, slot => {
-							jQuery(document).one(':dialogclose', () => Save.slots.load(slot));
-						})
+ 						createButton('load', 'ui-close', L10n.get('savesLabelLoad'), i, slot => {
+ 							jQuery(document).one(':dialogclosed', () => Save.slots.load(slot));
+ 						})
diff --git a/devTools/tweeGo/storyFormats/sugarcube-2/format.js b/devTools/tweeGo/storyFormats/sugarcube-2/format.js
deleted file mode 100644
index 4d2181cf77a..00000000000
--- a/devTools/tweeGo/storyFormats/sugarcube-2/format.js
+++ /dev/null
@@ -1 +0,0 @@
-window.storyFormat({"name":"SugarCube","version":"2.28.2","description":"A full featured, highly customizable story format.  See its <a href=\"http://www.motoslave.net/sugarcube/2/#documentation\" target=\"_blank\">documentation</a>.","author":"Thomas Michael Edwards","image":"icon.svg","url":"http://www.motoslave.net/sugarcube/","license":"BSD-2-Clause","proofing":false,"source":"<!DOCTYPE html>\n<html data-init=\"no-js\">\n<head>\n<meta charset=\"UTF-8\" />\n<title>{{STORY_NAME}}</title>\n<meta name=\"viewport\" content=\"width=device-width,initial-scale=1\" />\n<!--\n\nSugarCube (v2.28.2): A free (gratis and libre) story format.\n\nCopyright © 2013–2018 Thomas Michael Edwards <thomasmedwards@gmail.com>.\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this\n   list of conditions and the following disclaimer.\n2. Redistributions in binary form must reproduce the above copyright notice,\n   this list of conditions and the following disclaimer in the documentation\n   and/or other materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\nANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\nWARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR\nANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\nLOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\nON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS\nSOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n\n-->\n<script id=\"script-libraries\" type=\"text/javascript\">\nif(document.head&&document.addEventListener&&document.querySelector&&Object.create&&Object.freeze&&JSON){document.documentElement.setAttribute(\"data-init\", \"loading\");\n/*! @source http://purl.eligrey.com/github/classList.js/blob/master/classList.js */\nif(\"document\" in self){if(!(\"classList\" in document.createElement(\"_\"))){(function(j){\"use strict\";if(!(\"Element\" in j)){return}var a=\"classList\",f=\"prototype\",m=j.Element[f],b=Object,k=String[f].trim||function(){return this.replace(/^\\s+|\\s+$/g,\"\")},c=Array[f].indexOf||function(q){var p=0,o=this.length;for(;p<o;p++){if(p in this&&this[p]===q){return p}}return -1},n=function(o,p){this.name=o;this.code=DOMException[o];this.message=p},g=function(p,o){if(o===\"\"){throw new n(\"SYNTAX_ERR\",\"An invalid or illegal string was specified\")}if(/\\s/.test(o)){throw new n(\"INVALID_CHARACTER_ERR\",\"String contains an invalid character\")}return c.call(p,o)},d=function(s){var r=k.call(s.getAttribute(\"class\")||\"\"),q=r?r.split(/\\s+/):[],p=0,o=q.length;for(;p<o;p++){this.push(q[p])}this._updateClassName=function(){s.setAttribute(\"class\",this.toString())}},e=d[f]=[],i=function(){return new d(this)};n[f]=Error[f];e.item=function(o){return this[o]||null};e.contains=function(o){o+=\"\";return g(this,o)!==-1};e.add=function(){var s=arguments,r=0,p=s.length,q,o=false;do{q=s[r]+\"\";if(g(this,q)===-1){this.push(q);o=true}}while(++r<p);if(o){this._updateClassName()}};e.remove=function(){var t=arguments,s=0,p=t.length,r,o=false,q;do{r=t[s]+\"\";q=g(this,r);while(q!==-1){this.splice(q,1);o=true;q=g(this,r)}}while(++s<p);if(o){this._updateClassName()}};e.toggle=function(p,q){p+=\"\";var o=this.contains(p),r=o?q!==true&&\"remove\":q!==false&&\"add\";if(r){this[r](p)}if(q===true||q===false){return q}else{return !o}};e.toString=function(){return this.join(\" \")};if(b.defineProperty){var l={get:i,enumerable:true,configurable:true};try{b.defineProperty(m,a,l)}catch(h){if(h.number===-2146823252){l.enumerable=false;b.defineProperty(m,a,l)}}}else{if(b[f].__defineGetter__){m.__defineGetter__(a,i)}}}(self))}else{(function(){var b=document.createElement(\"_\");b.classList.add(\"c1\",\"c2\");if(!b.classList.contains(\"c2\")){var c=function(e){var d=DOMTokenList.prototype[e];DOMTokenList.prototype[e]=function(h){var g,f=arguments.length;for(g=0;g<f;g++){h=arguments[g];d.call(this,h)}}};c(\"add\");c(\"remove\")}b.classList.toggle(\"c3\",false);if(b.classList.contains(\"c3\")){var a=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(d,e){if(1 in arguments&&!this.contains(d)===!e){return e}else{return a.call(this,d)}}}b=null}())}};\n/*!\n * https://github.com/es-shims/es5-shim\n * @license es5-shim Copyright 2009-2015 by contributors, MIT License\n * see https://github.com/es-shims/es5-shim/blob/v4.5.12/LICENSE\n */\n(function(t,r){\"use strict\";if(typeof define===\"function\"&&define.amd){define(r)}else if(typeof exports===\"object\"){module.exports=r()}else{t.returnExports=r()}})(this,function(){var t=Array;var r=t.prototype;var e=Object;var n=e.prototype;var i=Function;var a=i.prototype;var o=String;var f=o.prototype;var u=Number;var l=u.prototype;var s=r.slice;var c=r.splice;var v=r.push;var h=r.unshift;var p=r.concat;var y=r.join;var d=a.call;var g=a.apply;var w=Math.max;var b=Math.min;var T=n.toString;var m=typeof Symbol===\"function\"&&typeof Symbol.toStringTag===\"symbol\";var D;var S=Function.prototype.toString,x=/^\\s*class /,O=function isES6ClassFn(t){try{var r=S.call(t);var e=r.replace(/\\/\\/.*\\n/g,\"\");var n=e.replace(/\\/\\*[.\\s\\S]*\\*\\//g,\"\");var i=n.replace(/\\n/gm,\" \").replace(/ {2}/g,\" \");return x.test(i)}catch(a){return false}},E=function tryFunctionObject(t){try{if(O(t)){return false}S.call(t);return true}catch(r){return false}},j=\"[object Function]\",I=\"[object GeneratorFunction]\",D=function isCallable(t){if(!t){return false}if(typeof t!==\"function\"&&typeof t!==\"object\"){return false}if(m){return E(t)}if(O(t)){return false}var r=T.call(t);return r===j||r===I};var M;var U=RegExp.prototype.exec,F=function tryRegexExec(t){try{U.call(t);return true}catch(r){return false}},$=\"[object RegExp]\";M=function isRegex(t){if(typeof t!==\"object\"){return false}return m?F(t):T.call(t)===$};var N;var C=String.prototype.valueOf,k=function tryStringObject(t){try{C.call(t);return true}catch(r){return false}},A=\"[object String]\";N=function isString(t){if(typeof t===\"string\"){return true}if(typeof t!==\"object\"){return false}return m?k(t):T.call(t)===A};var R=e.defineProperty&&function(){try{var t={};e.defineProperty(t,\"x\",{enumerable:false,value:t});for(var r in t){return false}return t.x===t}catch(n){return false}}();var P=function(t){var r;if(R){r=function(t,r,n,i){if(!i&&r in t){return}e.defineProperty(t,r,{configurable:true,enumerable:false,writable:true,value:n})}}else{r=function(t,r,e,n){if(!n&&r in t){return}t[r]=e}}return function defineProperties(e,n,i){for(var a in n){if(t.call(n,a)){r(e,a,n[a],i)}}}}(n.hasOwnProperty);var J=function isPrimitive(t){var r=typeof t;return t===null||r!==\"object\"&&r!==\"function\"};var Y=u.isNaN||function isActualNaN(t){return t!==t};var Z={ToInteger:function ToInteger(t){var r=+t;if(Y(r)){r=0}else if(r!==0&&r!==1/0&&r!==-(1/0)){r=(r>0||-1)*Math.floor(Math.abs(r))}return r},ToPrimitive:function ToPrimitive(t){var r,e,n;if(J(t)){return t}e=t.valueOf;if(D(e)){r=e.call(t);if(J(r)){return r}}n=t.toString;if(D(n)){r=n.call(t);if(J(r)){return r}}throw new TypeError},ToObject:function(t){if(t==null){throw new TypeError(\"can't convert \"+t+\" to object\")}return e(t)},ToUint32:function ToUint32(t){return t>>>0}};var z=function Empty(){};P(a,{bind:function bind(t){var r=this;if(!D(r)){throw new TypeError(\"Function.prototype.bind called on incompatible \"+r)}var n=s.call(arguments,1);var a;var o=function(){if(this instanceof a){var i=g.call(r,this,p.call(n,s.call(arguments)));if(e(i)===i){return i}return this}else{return g.call(r,t,p.call(n,s.call(arguments)))}};var f=w(0,r.length-n.length);var u=[];for(var l=0;l<f;l++){v.call(u,\"$\"+l)}a=i(\"binder\",\"return function (\"+y.call(u,\",\")+\"){ return binder.apply(this, arguments); }\")(o);if(r.prototype){z.prototype=r.prototype;a.prototype=new z;z.prototype=null}return a}});var G=d.bind(n.hasOwnProperty);var H=d.bind(n.toString);var W=d.bind(s);var B=g.bind(s);if(typeof document===\"object\"&&document&&document.documentElement){try{W(document.documentElement.childNodes)}catch(X){var L=W;var q=B;W=function arraySliceIE(t){var r=[];var e=t.length;while(e-- >0){r[e]=t[e]}return q(r,L(arguments,1))};B=function arraySliceApplyIE(t,r){return q(W(t),r)}}}var K=d.bind(f.slice);var Q=d.bind(f.split);var V=d.bind(f.indexOf);var _=d.bind(v);var tt=d.bind(n.propertyIsEnumerable);var rt=d.bind(r.sort);var et=t.isArray||function isArray(t){return H(t)===\"[object Array]\"};var nt=[].unshift(0)!==1;P(r,{unshift:function(){h.apply(this,arguments);return this.length}},nt);P(t,{isArray:et});var it=e(\"a\");var at=it[0]!==\"a\"||!(0 in it);var ot=function properlyBoxed(t){var r=true;var e=true;var n=false;if(t){try{t.call(\"foo\",function(t,e,n){if(typeof n!==\"object\"){r=false}});t.call([1],function(){\"use strict\";e=typeof this===\"string\"},\"x\")}catch(i){n=true}}return!!t&&!n&&r&&e};P(r,{forEach:function forEach(t){var r=Z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=-1;var i=Z.ToUint32(e.length);var a;if(arguments.length>1){a=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.forEach callback must be a function\")}while(++n<i){if(n in e){if(typeof a===\"undefined\"){t(e[n],n,r)}else{t.call(a,e[n],n,r)}}}}},!ot(r.forEach));P(r,{map:function map(r){var e=Z.ToObject(this);var n=at&&N(this)?Q(this,\"\"):e;var i=Z.ToUint32(n.length);var a=t(i);var o;if(arguments.length>1){o=arguments[1]}if(!D(r)){throw new TypeError(\"Array.prototype.map callback must be a function\")}for(var f=0;f<i;f++){if(f in n){if(typeof o===\"undefined\"){a[f]=r(n[f],f,e)}else{a[f]=r.call(o,n[f],f,e)}}}return a}},!ot(r.map));P(r,{filter:function filter(t){var r=Z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=Z.ToUint32(e.length);var i=[];var a;var o;if(arguments.length>1){o=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.filter callback must be a function\")}for(var f=0;f<n;f++){if(f in e){a=e[f];if(typeof o===\"undefined\"?t(a,f,r):t.call(o,a,f,r)){_(i,a)}}}return i}},!ot(r.filter));P(r,{every:function every(t){var r=Z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=Z.ToUint32(e.length);var i;if(arguments.length>1){i=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.every callback must be a function\")}for(var a=0;a<n;a++){if(a in e&&!(typeof i===\"undefined\"?t(e[a],a,r):t.call(i,e[a],a,r))){return false}}return true}},!ot(r.every));P(r,{some:function some(t){var r=Z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=Z.ToUint32(e.length);var i;if(arguments.length>1){i=arguments[1]}if(!D(t)){throw new TypeError(\"Array.prototype.some callback must be a function\")}for(var a=0;a<n;a++){if(a in e&&(typeof i===\"undefined\"?t(e[a],a,r):t.call(i,e[a],a,r))){return true}}return false}},!ot(r.some));var ft=false;if(r.reduce){ft=typeof r.reduce.call(\"es5\",function(t,r,e,n){return n})===\"object\"}P(r,{reduce:function reduce(t){var r=Z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=Z.ToUint32(e.length);if(!D(t)){throw new TypeError(\"Array.prototype.reduce callback must be a function\")}if(n===0&&arguments.length===1){throw new TypeError(\"reduce of empty array with no initial value\")}var i=0;var a;if(arguments.length>=2){a=arguments[1]}else{do{if(i in e){a=e[i++];break}if(++i>=n){throw new TypeError(\"reduce of empty array with no initial value\")}}while(true)}for(;i<n;i++){if(i in e){a=t(a,e[i],i,r)}}return a}},!ft);var ut=false;if(r.reduceRight){ut=typeof r.reduceRight.call(\"es5\",function(t,r,e,n){return n})===\"object\"}P(r,{reduceRight:function reduceRight(t){var r=Z.ToObject(this);var e=at&&N(this)?Q(this,\"\"):r;var n=Z.ToUint32(e.length);if(!D(t)){throw new TypeError(\"Array.prototype.reduceRight callback must be a function\")}if(n===0&&arguments.length===1){throw new TypeError(\"reduceRight of empty array with no initial value\")}var i;var a=n-1;if(arguments.length>=2){i=arguments[1]}else{do{if(a in e){i=e[a--];break}if(--a<0){throw new TypeError(\"reduceRight of empty array with no initial value\")}}while(true)}if(a<0){return i}do{if(a in e){i=t(i,e[a],a,r)}}while(a--);return i}},!ut);var lt=r.indexOf&&[0,1].indexOf(1,2)!==-1;P(r,{indexOf:function indexOf(t){var r=at&&N(this)?Q(this,\"\"):Z.ToObject(this);var e=Z.ToUint32(r.length);if(e===0){return-1}var n=0;if(arguments.length>1){n=Z.ToInteger(arguments[1])}n=n>=0?n:w(0,e+n);for(;n<e;n++){if(n in r&&r[n]===t){return n}}return-1}},lt);var st=r.lastIndexOf&&[0,1].lastIndexOf(0,-3)!==-1;P(r,{lastIndexOf:function lastIndexOf(t){var r=at&&N(this)?Q(this,\"\"):Z.ToObject(this);var e=Z.ToUint32(r.length);if(e===0){return-1}var n=e-1;if(arguments.length>1){n=b(n,Z.ToInteger(arguments[1]))}n=n>=0?n:e-Math.abs(n);for(;n>=0;n--){if(n in r&&t===r[n]){return n}}return-1}},st);var ct=function(){var t=[1,2];var r=t.splice();return t.length===2&&et(r)&&r.length===0}();P(r,{splice:function splice(t,r){if(arguments.length===0){return[]}else{return c.apply(this,arguments)}}},!ct);var vt=function(){var t={};r.splice.call(t,0,0,1);return t.length===1}();P(r,{splice:function splice(t,r){if(arguments.length===0){return[]}var e=arguments;this.length=w(Z.ToInteger(this.length),0);if(arguments.length>0&&typeof r!==\"number\"){e=W(arguments);if(e.length<2){_(e,this.length-t)}else{e[1]=Z.ToInteger(r)}}return c.apply(this,e)}},!vt);var ht=function(){var r=new t(1e5);r[8]=\"x\";r.splice(1,1);return r.indexOf(\"x\")===7}();var pt=function(){var t=256;var r=[];r[t]=\"a\";r.splice(t+1,0,\"b\");return r[t]===\"a\"}();P(r,{splice:function splice(t,r){var e=Z.ToObject(this);var n=[];var i=Z.ToUint32(e.length);var a=Z.ToInteger(t);var f=a<0?w(i+a,0):b(a,i);var u=b(w(Z.ToInteger(r),0),i-f);var l=0;var s;while(l<u){s=o(f+l);if(G(e,s)){n[l]=e[s]}l+=1}var c=W(arguments,2);var v=c.length;var h;if(v<u){l=f;var p=i-u;while(l<p){s=o(l+u);h=o(l+v);if(G(e,s)){e[h]=e[s]}else{delete e[h]}l+=1}l=i;var y=i-u+v;while(l>y){delete e[l-1];l-=1}}else if(v>u){l=i-u;while(l>f){s=o(l+u-1);h=o(l+v-1);if(G(e,s)){e[h]=e[s]}else{delete e[h]}l-=1}}l=f;for(var d=0;d<c.length;++d){e[l]=c[d];l+=1}e.length=i-u+v;return n}},!ht||!pt);var yt=r.join;var dt;try{dt=Array.prototype.join.call(\"123\",\",\")!==\"1,2,3\"}catch(X){dt=true}if(dt){P(r,{join:function join(t){var r=typeof t===\"undefined\"?\",\":t;return yt.call(N(this)?Q(this,\"\"):this,r)}},dt)}var gt=[1,2].join(undefined)!==\"1,2\";if(gt){P(r,{join:function join(t){var r=typeof t===\"undefined\"?\",\":t;return yt.call(this,r)}},gt)}var wt=function push(t){var r=Z.ToObject(this);var e=Z.ToUint32(r.length);var n=0;while(n<arguments.length){r[e+n]=arguments[n];n+=1}r.length=e+n;return e+n};var bt=function(){var t={};var r=Array.prototype.push.call(t,undefined);return r!==1||t.length!==1||typeof t[0]!==\"undefined\"||!G(t,0)}();P(r,{push:function push(t){if(et(this)){return v.apply(this,arguments)}return wt.apply(this,arguments)}},bt);var Tt=function(){var t=[];var r=t.push(undefined);return r!==1||t.length!==1||typeof t[0]!==\"undefined\"||!G(t,0)}();P(r,{push:wt},Tt);P(r,{slice:function(t,r){var e=N(this)?Q(this,\"\"):this;return B(e,arguments)}},at);var mt=function(){try{[1,2].sort(null)}catch(t){try{[1,2].sort({})}catch(r){return false}}return true}();var Dt=function(){try{[1,2].sort(/a/);return false}catch(t){}return true}();var St=function(){try{[1,2].sort(undefined);return true}catch(t){}return false}();P(r,{sort:function sort(t){if(typeof t===\"undefined\"){return rt(this)}if(!D(t)){throw new TypeError(\"Array.prototype.sort callback must be a function\")}return rt(this,t)}},mt||!St||!Dt);var xt=!tt({toString:null},\"toString\");var Ot=tt(function(){},\"prototype\");var Et=!G(\"x\",\"0\");var jt=function(t){var r=t.constructor;return r&&r.prototype===t};var It={$applicationCache:true,$console:true,$external:true,$frame:true,$frameElement:true,$frames:true,$innerHeight:true,$innerWidth:true,$outerHeight:true,$outerWidth:true,$pageXOffset:true,$pageYOffset:true,$parent:true,$scrollLeft:true,$scrollTop:true,$scrollX:true,$scrollY:true,$self:true,$webkitIndexedDB:true,$webkitStorageInfo:true,$window:true,$width:true,$height:true,$top:true,$localStorage:true};var Mt=function(){if(typeof window===\"undefined\"){return false}for(var t in window){try{if(!It[\"$\"+t]&&G(window,t)&&window[t]!==null&&typeof window[t]===\"object\"){jt(window[t])}}catch(r){return true}}return false}();var Ut=function(t){if(typeof window===\"undefined\"||!Mt){return jt(t)}try{return jt(t)}catch(r){return false}};var Ft=[\"toString\",\"toLocaleString\",\"valueOf\",\"hasOwnProperty\",\"isPrototypeOf\",\"propertyIsEnumerable\",\"constructor\"];var $t=Ft.length;var Nt=function isArguments(t){return H(t)===\"[object Arguments]\"};var Ct=function isArguments(t){return t!==null&&typeof t===\"object\"&&typeof t.length===\"number\"&&t.length>=0&&!et(t)&&D(t.callee)};var kt=Nt(arguments)?Nt:Ct;P(e,{keys:function keys(t){var r=D(t);var e=kt(t);var n=t!==null&&typeof t===\"object\";var i=n&&N(t);if(!n&&!r&&!e){throw new TypeError(\"Object.keys called on a non-object\")}var a=[];var f=Ot&&r;if(i&&Et||e){for(var u=0;u<t.length;++u){_(a,o(u))}}if(!e){for(var l in t){if(!(f&&l===\"prototype\")&&G(t,l)){_(a,o(l))}}}if(xt){var s=Ut(t);for(var c=0;c<$t;c++){var v=Ft[c];if(!(s&&v===\"constructor\")&&G(t,v)){_(a,v)}}}return a}});var At=e.keys&&function(){return e.keys(arguments).length===2}(1,2);var Rt=e.keys&&function(){var t=e.keys(arguments);return arguments.length!==1||t.length!==1||t[0]!==1}(1);var Pt=e.keys;P(e,{keys:function keys(t){if(kt(t)){return Pt(W(t))}else{return Pt(t)}}},!At||Rt);var Jt=new Date(-0xc782b5b342b24).getUTCMonth()!==0;var Yt=new Date(-0x55d318d56a724);var Zt=new Date(14496624e5);var zt=Yt.toUTCString()!==\"Mon, 01 Jan -45875 11:59:59 GMT\";var Gt;var Ht;var Wt=Yt.getTimezoneOffset();if(Wt<-720){Gt=Yt.toDateString()!==\"Tue Jan 02 -45875\";Ht=!/^Thu Dec 10 2015 \\d\\d:\\d\\d:\\d\\d GMT[-+]\\d\\d\\d\\d(?: |$)/.test(String(Zt))}else{Gt=Yt.toDateString()!==\"Mon Jan 01 -45875\";Ht=!/^Wed Dec 09 2015 \\d\\d:\\d\\d:\\d\\d GMT[-+]\\d\\d\\d\\d(?: |$)/.test(String(Zt))}var Bt=d.bind(Date.prototype.getFullYear);var Xt=d.bind(Date.prototype.getMonth);var Lt=d.bind(Date.prototype.getDate);var qt=d.bind(Date.prototype.getUTCFullYear);var Kt=d.bind(Date.prototype.getUTCMonth);var Qt=d.bind(Date.prototype.getUTCDate);var Vt=d.bind(Date.prototype.getUTCDay);var _t=d.bind(Date.prototype.getUTCHours);var tr=d.bind(Date.prototype.getUTCMinutes);var rr=d.bind(Date.prototype.getUTCSeconds);var er=d.bind(Date.prototype.getUTCMilliseconds);var nr=[\"Sun\",\"Mon\",\"Tue\",\"Wed\",\"Thu\",\"Fri\",\"Sat\"];var ir=[\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sep\",\"Oct\",\"Nov\",\"Dec\"];var ar=function daysInMonth(t,r){return Lt(new Date(r,t,0))};P(Date.prototype,{getFullYear:function getFullYear(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);if(t<0&&Xt(this)>11){return t+1}return t},getMonth:function getMonth(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);var r=Xt(this);if(t<0&&r>11){return 0}return r},getDate:function getDate(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Bt(this);var r=Xt(this);var e=Lt(this);if(t<0&&r>11){if(r===12){return e}var n=ar(0,t+1);return n-e+1}return e},getUTCFullYear:function getUTCFullYear(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);if(t<0&&Kt(this)>11){return t+1}return t},getUTCMonth:function getUTCMonth(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);var r=Kt(this);if(t<0&&r>11){return 0}return r},getUTCDate:function getUTCDate(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=qt(this);var r=Kt(this);var e=Qt(this);if(t<0&&r>11){if(r===12){return e}var n=ar(0,t+1);return n-e+1}return e}},Jt);P(Date.prototype,{toUTCString:function toUTCString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=Vt(this);var r=Qt(this);var e=Kt(this);var n=qt(this);var i=_t(this);var a=tr(this);var o=rr(this);return nr[t]+\", \"+(r<10?\"0\"+r:r)+\" \"+ir[e]+\" \"+n+\" \"+(i<10?\"0\"+i:i)+\":\"+(a<10?\"0\"+a:a)+\":\"+(o<10?\"0\"+o:o)+\" GMT\"}},Jt||zt);P(Date.prototype,{toDateString:function toDateString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=this.getDay();var r=this.getDate();var e=this.getMonth();var n=this.getFullYear();return nr[t]+\" \"+ir[e]+\" \"+(r<10?\"0\"+r:r)+\" \"+n}},Jt||Gt);if(Jt||Ht){Date.prototype.toString=function toString(){if(!this||!(this instanceof Date)){throw new TypeError(\"this is not a Date object.\")}var t=this.getDay();var r=this.getDate();var e=this.getMonth();var n=this.getFullYear();var i=this.getHours();var a=this.getMinutes();var o=this.getSeconds();var f=this.getTimezoneOffset();var u=Math.floor(Math.abs(f)/60);var l=Math.floor(Math.abs(f)%60);return nr[t]+\" \"+ir[e]+\" \"+(r<10?\"0\"+r:r)+\" \"+n+\" \"+(i<10?\"0\"+i:i)+\":\"+(a<10?\"0\"+a:a)+\":\"+(o<10?\"0\"+o:o)+\" GMT\"+(f>0?\"-\":\"+\")+(u<10?\"0\"+u:u)+(l<10?\"0\"+l:l)};if(R){e.defineProperty(Date.prototype,\"toString\",{configurable:true,enumerable:false,writable:true})}}var or=-621987552e5;var fr=\"-000001\";var ur=Date.prototype.toISOString&&new Date(or).toISOString().indexOf(fr)===-1;var lr=Date.prototype.toISOString&&new Date(-1).toISOString()!==\"1969-12-31T23:59:59.999Z\";var sr=d.bind(Date.prototype.getTime);P(Date.prototype,{toISOString:function toISOString(){if(!isFinite(this)||!isFinite(sr(this))){throw new RangeError(\"Date.prototype.toISOString called on non-finite value.\")}var t=qt(this);var r=Kt(this);t+=Math.floor(r/12);r=(r%12+12)%12;var e=[r+1,Qt(this),_t(this),tr(this),rr(this)];t=(t<0?\"-\":t>9999?\"+\":\"\")+K(\"00000\"+Math.abs(t),0<=t&&t<=9999?-4:-6);for(var n=0;n<e.length;++n){e[n]=K(\"00\"+e[n],-2)}return t+\"-\"+W(e,0,2).join(\"-\")+\"T\"+W(e,2).join(\":\")+\".\"+K(\"000\"+er(this),-3)+\"Z\"}},ur||lr);var cr=function(){try{return Date.prototype.toJSON&&new Date(NaN).toJSON()===null&&new Date(or).toJSON().indexOf(fr)!==-1&&Date.prototype.toJSON.call({toISOString:function(){return true}})}catch(t){return false}}();if(!cr){Date.prototype.toJSON=function toJSON(t){var r=e(this);var n=Z.ToPrimitive(r);if(typeof n===\"number\"&&!isFinite(n)){return null}var i=r.toISOString;if(!D(i)){throw new TypeError(\"toISOString property is not callable\")}return i.call(r)}}var vr=Date.parse(\"+033658-09-27T01:46:40.000Z\")===1e15;var hr=!isNaN(Date.parse(\"2012-04-04T24:00:00.500Z\"))||!isNaN(Date.parse(\"2012-11-31T23:59:59.000Z\"))||!isNaN(Date.parse(\"2012-12-31T23:59:60.000Z\"));var pr=isNaN(Date.parse(\"2000-01-01T00:00:00.000Z\"));if(pr||hr||!vr){var yr=Math.pow(2,31)-1;var dr=Y(new Date(1970,0,1,0,0,0,yr+1).getTime());Date=function(t){var r=function Date(e,n,i,a,f,u,l){var s=arguments.length;var c;if(this instanceof t){var v=u;var h=l;if(dr&&s>=7&&l>yr){var p=Math.floor(l/yr)*yr;var y=Math.floor(p/1e3);v+=y;h-=y*1e3}c=s===1&&o(e)===e?new t(r.parse(e)):s>=7?new t(e,n,i,a,f,v,h):s>=6?new t(e,n,i,a,f,v):s>=5?new t(e,n,i,a,f):s>=4?new t(e,n,i,a):s>=3?new t(e,n,i):s>=2?new t(e,n):s>=1?new t(e instanceof t?+e:e):new t}else{c=t.apply(this,arguments)}if(!J(c)){P(c,{constructor:r},true)}return c};var e=new RegExp(\"^\"+\"(\\\\d{4}|[+-]\\\\d{6})\"+\"(?:-(\\\\d{2})\"+\"(?:-(\\\\d{2})\"+\"(?:\"+\"T(\\\\d{2})\"+\":(\\\\d{2})\"+\"(?:\"+\":(\\\\d{2})\"+\"(?:(\\\\.\\\\d{1,}))?\"+\")?\"+\"(\"+\"Z|\"+\"(?:\"+\"([-+])\"+\"(\\\\d{2})\"+\":(\\\\d{2})\"+\")\"+\")?)?)?)?\"+\"$\");var n=[0,31,59,90,120,151,181,212,243,273,304,334,365];var i=function dayFromMonth(t,r){var e=r>1?1:0;return n[r]+Math.floor((t-1969+e)/4)-Math.floor((t-1901+e)/100)+Math.floor((t-1601+e)/400)+365*(t-1970)};var a=function toUTC(r){var e=0;var n=r;if(dr&&n>yr){var i=Math.floor(n/yr)*yr;var a=Math.floor(i/1e3);e+=a;n-=a*1e3}return u(new t(1970,0,1,0,0,e,n))};for(var f in t){if(G(t,f)){r[f]=t[f]}}P(r,{now:t.now,UTC:t.UTC},true);r.prototype=t.prototype;P(r.prototype,{constructor:r},true);var l=function parse(r){var n=e.exec(r);if(n){var o=u(n[1]),f=u(n[2]||1)-1,l=u(n[3]||1)-1,s=u(n[4]||0),c=u(n[5]||0),v=u(n[6]||0),h=Math.floor(u(n[7]||0)*1e3),p=Boolean(n[4]&&!n[8]),y=n[9]===\"-\"?1:-1,d=u(n[10]||0),g=u(n[11]||0),w;var b=c>0||v>0||h>0;if(s<(b?24:25)&&c<60&&v<60&&h<1e3&&f>-1&&f<12&&d<24&&g<60&&l>-1&&l<i(o,f+1)-i(o,f)){w=((i(o,f)+l)*24+s+d*y)*60;w=((w+c+g*y)*60+v)*1e3+h;if(p){w=a(w)}if(-864e13<=w&&w<=864e13){return w}}return NaN}return t.parse.apply(this,arguments)};P(r,{parse:l});return r}(Date)}if(!Date.now){Date.now=function now(){return(new Date).getTime()}}var gr=l.toFixed&&(8e-5.toFixed(3)!==\"0.000\"||.9.toFixed(0)!==\"1\"||1.255.toFixed(2)!==\"1.25\"||(1000000000000000128).toFixed(0)!==\"1000000000000000128\");var wr={base:1e7,size:6,data:[0,0,0,0,0,0],multiply:function multiply(t,r){var e=-1;var n=r;while(++e<wr.size){n+=t*wr.data[e];wr.data[e]=n%wr.base;n=Math.floor(n/wr.base)}},divide:function divide(t){var r=wr.size;var e=0;while(--r>=0){e+=wr.data[r];wr.data[r]=Math.floor(e/t);e=e%t*wr.base}},numToString:function numToString(){var t=wr.size;var r=\"\";while(--t>=0){if(r!==\"\"||t===0||wr.data[t]!==0){var e=o(wr.data[t]);if(r===\"\"){r=e}else{r+=K(\"0000000\",0,7-e.length)+e}}}return r},pow:function pow(t,r,e){return r===0?e:r%2===1?pow(t,r-1,e*t):pow(t*t,r/2,e)},log:function log(t){var r=0;var e=t;while(e>=4096){r+=12;e/=4096}while(e>=2){r+=1;e/=2}return r}};var br=function toFixed(t){var r,e,n,i,a,f,l,s;r=u(t);r=Y(r)?0:Math.floor(r);if(r<0||r>20){throw new RangeError(\"Number.toFixed called with invalid number of decimals\")}e=u(this);if(Y(e)){return\"NaN\"}if(e<=-1e21||e>=1e21){return o(e)}n=\"\";if(e<0){n=\"-\";e=-e}i=\"0\";if(e>1e-21){a=wr.log(e*wr.pow(2,69,1))-69;f=a<0?e*wr.pow(2,-a,1):e/wr.pow(2,a,1);f*=4503599627370496;a=52-a;if(a>0){wr.multiply(0,f);l=r;while(l>=7){wr.multiply(1e7,0);l-=7}wr.multiply(wr.pow(10,l,1),0);l=a-1;while(l>=23){wr.divide(1<<23);l-=23}wr.divide(1<<l);wr.multiply(1,1);wr.divide(2);i=wr.numToString()}else{wr.multiply(0,f);wr.multiply(1<<-a,0);i=wr.numToString()+K(\"0.00000000000000000000\",2,2+r)}}if(r>0){s=i.length;if(s<=r){i=n+K(\"0.0000000000000000000\",0,r-s+2)+i}else{i=n+K(i,0,s-r)+\".\"+K(i,s-r)}}else{i=n+i}return i};P(l,{toFixed:br},gr);var Tr=function(){try{return 1..toPrecision(undefined)===\"1\"}catch(t){return true}}();var mr=l.toPrecision;P(l,{toPrecision:function toPrecision(t){return typeof t===\"undefined\"?mr.call(this):mr.call(this,t)}},Tr);if(\"ab\".split(/(?:ab)*/).length!==2||\".\".split(/(.?)(.?)/).length!==4||\"tesst\".split(/(s)*/)[1]===\"t\"||\"test\".split(/(?:)/,-1).length!==4||\"\".split(/.?/).length||\".\".split(/()()/).length>1){(function(){var t=typeof/()??/.exec(\"\")[1]===\"undefined\";var r=Math.pow(2,32)-1;f.split=function(e,n){var i=String(this);if(typeof e===\"undefined\"&&n===0){return[]}if(!M(e)){return Q(this,e,n)}var a=[];var o=(e.ignoreCase?\"i\":\"\")+(e.multiline?\"m\":\"\")+(e.unicode?\"u\":\"\")+(e.sticky?\"y\":\"\"),f=0,u,l,s,c;var h=new RegExp(e.source,o+\"g\");if(!t){u=new RegExp(\"^\"+h.source+\"$(?!\\\\s)\",o)}var p=typeof n===\"undefined\"?r:Z.ToUint32(n);l=h.exec(i);while(l){s=l.index+l[0].length;if(s>f){_(a,K(i,f,l.index));if(!t&&l.length>1){l[0].replace(u,function(){for(var t=1;t<arguments.length-2;t++){if(typeof arguments[t]===\"undefined\"){l[t]=void 0}}})}if(l.length>1&&l.index<i.length){v.apply(a,W(l,1))}c=l[0].length;f=s;if(a.length>=p){break}}if(h.lastIndex===l.index){h.lastIndex++}l=h.exec(i)}if(f===i.length){if(c||!h.test(\"\")){_(a,\"\")}}else{_(a,K(i,f))}return a.length>p?W(a,0,p):a}})()}else if(\"0\".split(void 0,0).length){f.split=function split(t,r){if(typeof t===\"undefined\"&&r===0){return[]}return Q(this,t,r)}}var Dr=f.replace;var Sr=function(){var t=[];\"x\".replace(/x(.)?/g,function(r,e){_(t,e)});return t.length===1&&typeof t[0]===\"undefined\"}();if(!Sr){f.replace=function replace(t,r){var e=D(r);var n=M(t)&&/\\)[*?]/.test(t.source);if(!e||!n){return Dr.call(this,t,r)}else{var i=function(e){var n=arguments.length;var i=t.lastIndex;t.lastIndex=0;var a=t.exec(e)||[];t.lastIndex=i;_(a,arguments[n-2],arguments[n-1]);return r.apply(this,a)};return Dr.call(this,t,i)}}}var xr=f.substr;var Or=\"\".substr&&\"0b\".substr(-1)!==\"b\";P(f,{substr:function substr(t,r){var e=t;if(t<0){e=w(this.length+t,0)}return xr.call(this,e,r)}},Or);var Er=\"\\t\\n\\x0B\\f\\r \\xa0\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\"+\"\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\u2028\"+\"\\u2029\\ufeff\";var jr=\"\\u200b\";var Ir=\"[\"+Er+\"]\";var Mr=new RegExp(\"^\"+Ir+Ir+\"*\");var Ur=new RegExp(Ir+Ir+\"*$\");var Fr=f.trim&&(Er.trim()||!jr.trim());P(f,{trim:function trim(){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}return o(this).replace(Mr,\"\").replace(Ur,\"\")}},Fr);var $r=d.bind(String.prototype.trim);var Nr=f.lastIndexOf&&\"abc\\u3042\\u3044\".lastIndexOf(\"\\u3042\\u3044\",2)!==-1;P(f,{lastIndexOf:function lastIndexOf(t){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}var r=o(this);var e=o(t);var n=arguments.length>1?u(arguments[1]):NaN;var i=Y(n)?Infinity:Z.ToInteger(n);var a=b(w(i,0),r.length);var f=e.length;var l=a+f;while(l>0){l=w(0,l-f);var s=V(K(r,l,a+f),e);if(s!==-1){return l+s}}return-1}},Nr);var Cr=f.lastIndexOf;P(f,{lastIndexOf:function lastIndexOf(t){return Cr.apply(this,arguments)}},f.lastIndexOf.length!==1);if(parseInt(Er+\"08\")!==8||parseInt(Er+\"0x16\")!==22){parseInt=function(t){var r=/^[-+]?0[xX]/;return function parseInt(e,n){if(typeof e===\"symbol\"){\"\"+e}var i=$r(String(e));var a=u(n)||(r.test(i)?16:10);return t(i,a)}}(parseInt)}if(1/parseFloat(\"-0\")!==-Infinity){parseFloat=function(t){return function parseFloat(r){var e=$r(String(r));var n=t(e);return n===0&&K(e,0,1)===\"-\"?-0:n}}(parseFloat)}if(String(new RangeError(\"test\"))!==\"RangeError: test\"){var kr=function toString(){if(typeof this===\"undefined\"||this===null){throw new TypeError(\"can't convert \"+this+\" to object\")}var t=this.name;if(typeof t===\"undefined\"){t=\"Error\"}else if(typeof t!==\"string\"){t=o(t)}var r=this.message;if(typeof r===\"undefined\"){r=\"\"}else if(typeof r!==\"string\"){r=o(r)}if(!t){return r}if(!r){return t}return t+\": \"+r};Error.prototype.toString=kr}if(R){var Ar=function(t,r){if(tt(t,r)){var e=Object.getOwnPropertyDescriptor(t,r);if(e.configurable){e.enumerable=false;Object.defineProperty(t,r,e)}}};Ar(Error.prototype,\"message\");if(Error.prototype.message!==\"\"){Error.prototype.message=\"\"}Ar(Error.prototype,\"name\")}if(String(/a/gim)!==\"/a/gim\"){var Rr=function toString(){var t=\"/\"+this.source+\"/\";if(this.global){t+=\"g\"}if(this.ignoreCase){t+=\"i\"}if(this.multiline){t+=\"m\"}return t};RegExp.prototype.toString=Rr}});\n//# sourceMappingURL=es5-shim.map\n/*!\n * https://github.com/paulmillr/es6-shim\n * @license es6-shim Copyright 2013-2016 by Paul Miller (http://paulmillr.com)\n *   and contributors,  MIT License\n * es6-shim: v0.35.4\n * see https://github.com/paulmillr/es6-shim/blob/0.35.4/LICENSE\n * Details and documentation:\n * https://github.com/paulmillr/es6-shim/\n */\n(function(e,t){if(typeof define===\"function\"&&define.amd){define(t)}else if(typeof exports===\"object\"){module.exports=t()}else{e.returnExports=t()}})(this,function(){\"use strict\";var e=Function.call.bind(Function.apply);var t=Function.call.bind(Function.call);var r=Array.isArray;var n=Object.keys;var o=function notThunker(t){return function notThunk(){return!e(t,this,arguments)}};var i=function(e){try{e();return false}catch(t){return true}};var a=function valueOrFalseIfThrows(e){try{return e()}catch(t){return false}};var u=o(i);var f=function(){return!i(function(){return Object.defineProperty({},\"x\",{get:function(){}})})};var s=!!Object.defineProperty&&f();var c=function foo(){}.name===\"foo\";var l=Function.call.bind(Array.prototype.forEach);var p=Function.call.bind(Array.prototype.reduce);var v=Function.call.bind(Array.prototype.filter);var y=Function.call.bind(Array.prototype.some);var h=function(e,t,r,n){if(!n&&t in e){return}if(s){Object.defineProperty(e,t,{configurable:true,enumerable:false,writable:true,value:r})}else{e[t]=r}};var b=function(e,t,r){l(n(t),function(n){var o=t[n];h(e,n,o,!!r)})};var g=Function.call.bind(Object.prototype.toString);var d=typeof/abc/===\"function\"?function IsCallableSlow(e){return typeof e===\"function\"&&g(e)===\"[object Function]\"}:function IsCallableFast(e){return typeof e===\"function\"};var m={getter:function(e,t,r){if(!s){throw new TypeError(\"getters require true ES5 support\")}Object.defineProperty(e,t,{configurable:true,enumerable:false,get:r})},proxy:function(e,t,r){if(!s){throw new TypeError(\"getters require true ES5 support\")}var n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,{configurable:n.configurable,enumerable:n.enumerable,get:function getKey(){return e[t]},set:function setKey(r){e[t]=r}})},redefine:function(e,t,r){if(s){var n=Object.getOwnPropertyDescriptor(e,t);n.value=r;Object.defineProperty(e,t,n)}else{e[t]=r}},defineByDescriptor:function(e,t,r){if(s){Object.defineProperty(e,t,r)}else if(\"value\"in r){e[t]=r.value}},preserveToString:function(e,t){if(t&&d(t.toString)){h(e,\"toString\",t.toString.bind(t),true)}}};var O=Object.create||function(e,t){var r=function Prototype(){};r.prototype=e;var o=new r;if(typeof t!==\"undefined\"){n(t).forEach(function(e){m.defineByDescriptor(o,e,t[e])})}return o};var w=function(e,t){if(!Object.setPrototypeOf){return false}return a(function(){var r=function Subclass(t){var r=new e(t);Object.setPrototypeOf(r,Subclass.prototype);return r};Object.setPrototypeOf(r,e);r.prototype=O(e.prototype,{constructor:{value:r}});return t(r)})};var j=function(){if(typeof self!==\"undefined\"){return self}if(typeof window!==\"undefined\"){return window}if(typeof global!==\"undefined\"){return global}throw new Error(\"unable to locate global object\")};var S=j();var T=S.isFinite;var I=Function.call.bind(String.prototype.indexOf);var E=Function.apply.bind(Array.prototype.indexOf);var P=Function.call.bind(Array.prototype.concat);var C=Function.call.bind(String.prototype.slice);var M=Function.call.bind(Array.prototype.push);var x=Function.apply.bind(Array.prototype.push);var N=Function.call.bind(Array.prototype.shift);var A=Math.max;var R=Math.min;var _=Math.floor;var k=Math.abs;var L=Math.exp;var F=Math.log;var D=Math.sqrt;var z=Function.call.bind(Object.prototype.hasOwnProperty);var q;var W=function(){};var G=S.Map;var H=G&&G.prototype[\"delete\"];var V=G&&G.prototype.get;var B=G&&G.prototype.has;var U=G&&G.prototype.set;var $=S.Symbol||{};var J=$.species||\"@@species\";var X=Number.isNaN||function isNaN(e){return e!==e};var K=Number.isFinite||function isFinite(e){return typeof e===\"number\"&&T(e)};var Z=d(Math.sign)?Math.sign:function sign(e){var t=Number(e);if(t===0){return t}if(X(t)){return t}return t<0?-1:1};var Y=function log1p(e){var t=Number(e);if(t<-1||X(t)){return NaN}if(t===0||t===Infinity){return t}if(t===-1){return-Infinity}return 1+t-1===0?t:t*(F(1+t)/(1+t-1))};var Q=function isArguments(e){return g(e)===\"[object Arguments]\"};var ee=function isArguments(e){return e!==null&&typeof e===\"object\"&&typeof e.length===\"number\"&&e.length>=0&&g(e)!==\"[object Array]\"&&g(e.callee)===\"[object Function]\"};var te=Q(arguments)?Q:ee;var re={primitive:function(e){return e===null||typeof e!==\"function\"&&typeof e!==\"object\"},string:function(e){return g(e)===\"[object String]\"},regex:function(e){return g(e)===\"[object RegExp]\"},symbol:function(e){return typeof S.Symbol===\"function\"&&typeof e===\"symbol\"}};var ne=function overrideNative(e,t,r){var n=e[t];h(e,t,r,true);m.preserveToString(e[t],n)};var oe=typeof $===\"function\"&&typeof $[\"for\"]===\"function\"&&re.symbol($());var ie=re.symbol($.iterator)?$.iterator:\"_es6-shim iterator_\";if(S.Set&&typeof(new S.Set)[\"@@iterator\"]===\"function\"){ie=\"@@iterator\"}if(!S.Reflect){h(S,\"Reflect\",{},true)}var ae=S.Reflect;var ue=String;var fe=typeof document===\"undefined\"||!document?null:document.all;var se=fe==null?function isNullOrUndefined(e){return e==null}:function isNullOrUndefinedAndNotDocumentAll(e){return e==null&&e!==fe};var ce={Call:function Call(t,r){var n=arguments.length>2?arguments[2]:[];if(!ce.IsCallable(t)){throw new TypeError(t+\" is not a function\")}return e(t,r,n)},RequireObjectCoercible:function(e,t){if(se(e)){throw new TypeError(t||\"Cannot call method on \"+e)}return e},TypeIsObject:function(e){if(e===void 0||e===null||e===true||e===false){return false}return typeof e===\"function\"||typeof e===\"object\"||e===fe},ToObject:function(e,t){return Object(ce.RequireObjectCoercible(e,t))},IsCallable:d,IsConstructor:function(e){return ce.IsCallable(e)},ToInt32:function(e){return ce.ToNumber(e)>>0},ToUint32:function(e){return ce.ToNumber(e)>>>0},ToNumber:function(e){if(g(e)===\"[object Symbol]\"){throw new TypeError(\"Cannot convert a Symbol value to a number\")}return+e},ToInteger:function(e){var t=ce.ToNumber(e);if(X(t)){return 0}if(t===0||!K(t)){return t}return(t>0?1:-1)*_(k(t))},ToLength:function(e){var t=ce.ToInteger(e);if(t<=0){return 0}if(t>Number.MAX_SAFE_INTEGER){return Number.MAX_SAFE_INTEGER}return t},SameValue:function(e,t){if(e===t){if(e===0){return 1/e===1/t}return true}return X(e)&&X(t)},SameValueZero:function(e,t){return e===t||X(e)&&X(t)},IsIterable:function(e){return ce.TypeIsObject(e)&&(typeof e[ie]!==\"undefined\"||te(e))},GetIterator:function(e){if(te(e)){return new q(e,\"value\")}var t=ce.GetMethod(e,ie);if(!ce.IsCallable(t)){throw new TypeError(\"value is not an iterable\")}var r=ce.Call(t,e);if(!ce.TypeIsObject(r)){throw new TypeError(\"bad iterator\")}return r},GetMethod:function(e,t){var r=ce.ToObject(e)[t];if(se(r)){return void 0}if(!ce.IsCallable(r)){throw new TypeError(\"Method not callable: \"+t)}return r},IteratorComplete:function(e){return!!e.done},IteratorClose:function(e,t){var r=ce.GetMethod(e,\"return\");if(r===void 0){return}var n,o;try{n=ce.Call(r,e)}catch(i){o=i}if(t){return}if(o){throw o}if(!ce.TypeIsObject(n)){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(!ce.TypeIsObject(t)){throw new TypeError(\"bad iterator\")}return t},IteratorStep:function(e){var t=ce.IteratorNext(e);var r=ce.IteratorComplete(t);return r?false:t},Construct:function(e,t,r,n){var o=typeof r===\"undefined\"?e:r;if(!n&&ae.construct){return ae.construct(e,t,o)}var i=o.prototype;if(!ce.TypeIsObject(i)){i=Object.prototype}var a=O(i);var u=ce.Call(e,a,t);return ce.TypeIsObject(u)?u:a},SpeciesConstructor:function(e,t){var r=e.constructor;if(r===void 0){return t}if(!ce.TypeIsObject(r)){throw new TypeError(\"Bad constructor\")}var n=r[J];if(se(n)){return t}if(!ce.IsConstructor(n)){throw new TypeError(\"Bad @@species\")}return n},CreateHTML:function(e,t,r,n){var o=ce.ToString(e);var i=\"<\"+t;if(r!==\"\"){var a=ce.ToString(n);var u=a.replace(/\"/g,\"&quot;\");i+=\" \"+r+'=\"'+u+'\"'}var f=i+\">\";var s=f+o;return s+\"</\"+t+\">\"},IsRegExp:function IsRegExp(e){if(!ce.TypeIsObject(e)){return false}var t=e[$.match];if(typeof t!==\"undefined\"){return!!t}return re.regex(e)},ToString:function ToString(e){return ue(e)}};if(s&&oe){var le=function defineWellKnownSymbol(e){if(re.symbol($[e])){return $[e]}var t=$[\"for\"](\"Symbol.\"+e);Object.defineProperty($,e,{configurable:false,enumerable:false,writable:false,value:t});return t};if(!re.symbol($.search)){var pe=le(\"search\");var ve=String.prototype.search;h(RegExp.prototype,pe,function search(e){return ce.Call(ve,e,[this])});var ye=function search(e){var t=ce.RequireObjectCoercible(this);if(!se(e)){var r=ce.GetMethod(e,pe);if(typeof r!==\"undefined\"){return ce.Call(r,e,[t])}}return ce.Call(ve,t,[ce.ToString(e)])};ne(String.prototype,\"search\",ye)}if(!re.symbol($.replace)){var he=le(\"replace\");var be=String.prototype.replace;h(RegExp.prototype,he,function replace(e,t){return ce.Call(be,e,[this,t])});var ge=function replace(e,t){var r=ce.RequireObjectCoercible(this);if(!se(e)){var n=ce.GetMethod(e,he);if(typeof n!==\"undefined\"){return ce.Call(n,e,[r,t])}}return ce.Call(be,r,[ce.ToString(e),t])};ne(String.prototype,\"replace\",ge)}if(!re.symbol($.split)){var de=le(\"split\");var me=String.prototype.split;h(RegExp.prototype,de,function split(e,t){return ce.Call(me,e,[this,t])});var Oe=function split(e,t){var r=ce.RequireObjectCoercible(this);if(!se(e)){var n=ce.GetMethod(e,de);if(typeof n!==\"undefined\"){return ce.Call(n,e,[r,t])}}return ce.Call(me,r,[ce.ToString(e),t])};ne(String.prototype,\"split\",Oe)}var we=re.symbol($.match);var je=we&&function(){var e={};e[$.match]=function(){return 42};return\"a\".match(e)!==42}();if(!we||je){var Se=le(\"match\");var Te=String.prototype.match;h(RegExp.prototype,Se,function match(e){return ce.Call(Te,e,[this])});var Ie=function match(e){var t=ce.RequireObjectCoercible(this);if(!se(e)){var r=ce.GetMethod(e,Se);if(typeof r!==\"undefined\"){return ce.Call(r,e,[t])}}return ce.Call(Te,t,[ce.ToString(e)])};ne(String.prototype,\"match\",Ie)}}var Ee=function wrapConstructor(e,t,r){m.preserveToString(t,e);if(Object.setPrototypeOf){Object.setPrototypeOf(e,t)}if(s){l(Object.getOwnPropertyNames(e),function(n){if(n in W||r[n]){return}m.proxy(e,n,t)})}else{l(Object.keys(e),function(n){if(n in W||r[n]){return}t[n]=e[n]})}t.prototype=e.prototype;m.redefine(e.prototype,\"constructor\",t)};var Pe=function(){return this};var Ce=function(e){if(s&&!z(e,J)){m.getter(e,J,Pe)}};var Me=function(e,t){var r=t||function iterator(){return this};h(e,ie,r);if(!e[ie]&&re.symbol(ie)){e[ie]=r}};var xe=function createDataProperty(e,t,r){if(s){Object.defineProperty(e,t,{configurable:true,enumerable:true,writable:true,value:r})}else{e[t]=r}};var Ne=function createDataPropertyOrThrow(e,t,r){xe(e,t,r);if(!ce.SameValue(e[t],r)){throw new TypeError(\"property is nonconfigurable\")}};var Ae=function(e,t,r,n){if(!ce.TypeIsObject(e)){throw new TypeError(\"Constructor requires `new`: \"+t.name)}var o=t.prototype;if(!ce.TypeIsObject(o)){o=r}var i=O(o);for(var a in n){if(z(n,a)){var u=n[a];h(i,a,u,true)}}return i};if(String.fromCodePoint&&String.fromCodePoint.length!==1){var Re=String.fromCodePoint;ne(String,\"fromCodePoint\",function fromCodePoint(e){return ce.Call(Re,this,arguments)})}var _e={fromCodePoint:function fromCodePoint(e){var t=[];var r;for(var n=0,o=arguments.length;n<o;n++){r=Number(arguments[n]);if(!ce.SameValue(r,ce.ToInteger(r))||r<0||r>1114111){throw new RangeError(\"Invalid code point \"+r)}if(r<65536){M(t,String.fromCharCode(r))}else{r-=65536;M(t,String.fromCharCode((r>>10)+55296));M(t,String.fromCharCode(r%1024+56320))}}return t.join(\"\")},raw:function raw(e){var t=ce.ToObject(e,\"bad callSite\");var r=ce.ToObject(t.raw,\"bad raw value\");var n=r.length;var o=ce.ToLength(n);if(o<=0){return\"\"}var i=[];var a=0;var u,f,s,c;while(a<o){u=ce.ToString(a);s=ce.ToString(r[u]);M(i,s);if(a+1>=o){break}f=a+1<arguments.length?arguments[a+1]:\"\";c=ce.ToString(f);M(i,c);a+=1}return i.join(\"\")}};if(String.raw&&String.raw({raw:{0:\"x\",1:\"y\",length:2}})!==\"xy\"){ne(String,\"raw\",_e.raw)}b(String,_e);var ke=function repeat(e,t){if(t<1){return\"\"}if(t%2){return repeat(e,t-1)+e}var r=repeat(e,t/2);return r+r};var Le=Infinity;var Fe={repeat:function repeat(e){var t=ce.ToString(ce.RequireObjectCoercible(this));var r=ce.ToInteger(e);if(r<0||r>=Le){throw new RangeError(\"repeat count must be less than infinity and not overflow maximum string size\")}return ke(t,r)},startsWith:function startsWith(e){var t=ce.ToString(ce.RequireObjectCoercible(this));if(ce.IsRegExp(e)){throw new TypeError('Cannot call method \"startsWith\" with a regex')}var r=ce.ToString(e);var n;if(arguments.length>1){n=arguments[1]}var o=A(ce.ToInteger(n),0);return C(t,o,o+r.length)===r},endsWith:function endsWith(e){var t=ce.ToString(ce.RequireObjectCoercible(this));if(ce.IsRegExp(e)){throw new TypeError('Cannot call method \"endsWith\" with a regex')}var r=ce.ToString(e);var n=t.length;var o;if(arguments.length>1){o=arguments[1]}var i=typeof o===\"undefined\"?n:ce.ToInteger(o);var a=R(A(i,0),n);return C(t,a-r.length,a)===r},includes:function includes(e){if(ce.IsRegExp(e)){throw new TypeError('\"includes\" does not accept a RegExp')}var t=ce.ToString(e);var r;if(arguments.length>1){r=arguments[1]}return I(this,t,r)!==-1},codePointAt:function codePointAt(e){var t=ce.ToString(ce.RequireObjectCoercible(this));var r=ce.ToInteger(e);var n=t.length;if(r>=0&&r<n){var o=t.charCodeAt(r);var i=r+1===n;if(o<55296||o>56319||i){return o}var a=t.charCodeAt(r+1);if(a<56320||a>57343){return o}return(o-55296)*1024+(a-56320)+65536}}};if(String.prototype.includes&&\"a\".includes(\"a\",Infinity)!==false){ne(String.prototype,\"includes\",Fe.includes)}if(String.prototype.startsWith&&String.prototype.endsWith){var De=i(function(){return\"/a/\".startsWith(/a/)});var ze=a(function(){return\"abc\".startsWith(\"a\",Infinity)===false});if(!De||!ze){ne(String.prototype,\"startsWith\",Fe.startsWith);ne(String.prototype,\"endsWith\",Fe.endsWith)}}if(oe){var qe=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".startsWith(e)});if(!qe){ne(String.prototype,\"startsWith\",Fe.startsWith)}var We=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".endsWith(e)});if(!We){ne(String.prototype,\"endsWith\",Fe.endsWith)}var Ge=a(function(){var e=/a/;e[$.match]=false;return\"/a/\".includes(e)});if(!Ge){ne(String.prototype,\"includes\",Fe.includes)}}b(String.prototype,Fe);var He=[\"\\t\\n\\x0B\\f\\r \\xa0\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\",\"\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\u2028\",\"\\u2029\\ufeff\"].join(\"\");var Ve=new RegExp(\"(^[\"+He+\"]+)|([\"+He+\"]+$)\",\"g\");var Be=function trim(){return ce.ToString(ce.RequireObjectCoercible(this)).replace(Ve,\"\")};var Ue=[\"\\x85\",\"\\u200b\",\"\\ufffe\"].join(\"\");var $e=new RegExp(\"[\"+Ue+\"]\",\"g\");var Je=/^[-+]0x[0-9a-f]+$/i;var Xe=Ue.trim().length!==Ue.length;h(String.prototype,\"trim\",Be,Xe);var Ke=function(e){return{value:e,done:arguments.length===0}};var Ze=function(e){ce.RequireObjectCoercible(e);this._s=ce.ToString(e);this._i=0};Ze.prototype.next=function(){var e=this._s;var t=this._i;if(typeof e===\"undefined\"||t>=e.length){this._s=void 0;return Ke()}var r=e.charCodeAt(t);var n,o;if(r<55296||r>56319||t+1===e.length){o=1}else{n=e.charCodeAt(t+1);o=n<56320||n>57343?1:2}this._i=t+o;return Ke(e.substr(t,o))};Me(Ze.prototype);Me(String.prototype,function(){return new Ze(this)});var Ye={from:function from(e){var r=this;var n;if(arguments.length>1){n=arguments[1]}var o,i;if(typeof n===\"undefined\"){o=false}else{if(!ce.IsCallable(n)){throw new TypeError(\"Array.from: when provided, the second argument must be a function\")}if(arguments.length>2){i=arguments[2]}o=true}var a=typeof(te(e)||ce.GetMethod(e,ie))!==\"undefined\";var u,f,s;if(a){f=ce.IsConstructor(r)?Object(new r):[];var c=ce.GetIterator(e);var l,p;s=0;while(true){l=ce.IteratorStep(c);if(l===false){break}p=l.value;try{if(o){p=typeof i===\"undefined\"?n(p,s):t(n,i,p,s)}f[s]=p}catch(v){ce.IteratorClose(c,true);throw v}s+=1}u=s}else{var y=ce.ToObject(e);u=ce.ToLength(y.length);f=ce.IsConstructor(r)?Object(new r(u)):new Array(u);var h;for(s=0;s<u;++s){h=y[s];if(o){h=typeof i===\"undefined\"?n(h,s):t(n,i,h,s)}Ne(f,s,h)}}f.length=u;return f},of:function of(){var e=arguments.length;var t=this;var n=r(t)||!ce.IsCallable(t)?new Array(e):ce.Construct(t,[e]);for(var o=0;o<e;++o){Ne(n,o,arguments[o])}n.length=e;return n}};b(Array,Ye);Ce(Array);q=function(e,t){this.i=0;this.array=e;this.kind=t};b(q.prototype,{next:function(){var e=this.i;var t=this.array;if(!(this instanceof q)){throw new TypeError(\"Not an ArrayIterator\")}if(typeof t!==\"undefined\"){var r=ce.ToLength(t.length);for(;e<r;e++){var n=this.kind;var o;if(n===\"key\"){o=e}else if(n===\"value\"){o=t[e]}else if(n===\"entry\"){o=[e,t[e]]}this.i=e+1;return Ke(o)}}this.array=void 0;return Ke()}});Me(q.prototype);var Qe=Array.of===Ye.of||function(){var e=function Foo(e){this.length=e};e.prototype=[];var t=Array.of.apply(e,[1,2]);return t instanceof e&&t.length===2}();if(!Qe){ne(Array,\"of\",Ye.of)}var et={copyWithin:function copyWithin(e,t){var r=ce.ToObject(this);var n=ce.ToLength(r.length);var o=ce.ToInteger(e);var i=ce.ToInteger(t);var a=o<0?A(n+o,0):R(o,n);var u=i<0?A(n+i,0):R(i,n);var f;if(arguments.length>2){f=arguments[2]}var s=typeof f===\"undefined\"?n:ce.ToInteger(f);var c=s<0?A(n+s,0):R(s,n);var l=R(c-u,n-a);var p=1;if(u<a&&a<u+l){p=-1;u+=l-1;a+=l-1}while(l>0){if(u in r){r[a]=r[u]}else{delete r[a]}u+=p;a+=p;l-=1}return r},fill:function fill(e){var t;if(arguments.length>1){t=arguments[1]}var r;if(arguments.length>2){r=arguments[2]}var n=ce.ToObject(this);var o=ce.ToLength(n.length);t=ce.ToInteger(typeof t===\"undefined\"?0:t);r=ce.ToInteger(typeof r===\"undefined\"?o:r);var i=t<0?A(o+t,0):R(t,o);var a=r<0?o+r:r;for(var u=i;u<o&&u<a;++u){n[u]=e}return n},find:function find(e){var r=ce.ToObject(this);var n=ce.ToLength(r.length);if(!ce.IsCallable(e)){throw new TypeError(\"Array#find: predicate must be a function\")}var o=arguments.length>1?arguments[1]:null;for(var i=0,a;i<n;i++){a=r[i];if(o){if(t(e,o,a,i,r)){return a}}else if(e(a,i,r)){return a}}},findIndex:function findIndex(e){var r=ce.ToObject(this);var n=ce.ToLength(r.length);if(!ce.IsCallable(e)){throw new TypeError(\"Array#findIndex: predicate must be a function\")}var o=arguments.length>1?arguments[1]:null;for(var i=0;i<n;i++){if(o){if(t(e,o,r[i],i,r)){return i}}else if(e(r[i],i,r)){return i}}return-1},keys:function keys(){return new q(this,\"key\")},values:function values(){return new q(this,\"value\")},entries:function entries(){return new q(this,\"entry\")}};if(Array.prototype.keys&&!ce.IsCallable([1].keys().next)){delete Array.prototype.keys}if(Array.prototype.entries&&!ce.IsCallable([1].entries().next)){delete Array.prototype.entries}if(Array.prototype.keys&&Array.prototype.entries&&!Array.prototype.values&&Array.prototype[ie]){b(Array.prototype,{values:Array.prototype[ie]});if(re.symbol($.unscopables)){Array.prototype[$.unscopables].values=true}}if(c&&Array.prototype.values&&Array.prototype.values.name!==\"values\"){var tt=Array.prototype.values;ne(Array.prototype,\"values\",function values(){return ce.Call(tt,this,arguments)});h(Array.prototype,ie,Array.prototype.values,true)}b(Array.prototype,et);if(1/[true].indexOf(true,-0)<0){h(Array.prototype,\"indexOf\",function indexOf(e){var t=E(this,arguments);if(t===0&&1/t<0){return 0}return t},true)}Me(Array.prototype,function(){return this.values()});if(Object.getPrototypeOf){Me(Object.getPrototypeOf([].values()))}var rt=function(){return a(function(){return Array.from({length:-1}).length===0})}();var nt=function(){var e=Array.from([0].entries());return e.length===1&&r(e[0])&&e[0][0]===0&&e[0][1]===0}();if(!rt||!nt){ne(Array,\"from\",Ye.from)}var ot=function(){return a(function(){return Array.from([0],void 0)})}();if(!ot){var it=Array.from;ne(Array,\"from\",function from(e){if(arguments.length>1&&typeof arguments[1]!==\"undefined\"){return ce.Call(it,this,arguments)}else{return t(it,this,e)}})}var at=-(Math.pow(2,32)-1);var ut=function(e,r){var n={length:at};n[r?(n.length>>>0)-1:0]=true;return a(function(){t(e,n,function(){throw new RangeError(\"should not reach here\")},[]);return true})};if(!ut(Array.prototype.forEach)){var ft=Array.prototype.forEach;ne(Array.prototype,\"forEach\",function forEach(e){return ce.Call(ft,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.map)){var st=Array.prototype.map;ne(Array.prototype,\"map\",function map(e){return ce.Call(st,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.filter)){var ct=Array.prototype.filter;ne(Array.prototype,\"filter\",function filter(e){return ce.Call(ct,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.some)){var lt=Array.prototype.some;ne(Array.prototype,\"some\",function some(e){return ce.Call(lt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.every)){var pt=Array.prototype.every;ne(Array.prototype,\"every\",function every(e){return ce.Call(pt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.reduce)){var vt=Array.prototype.reduce;ne(Array.prototype,\"reduce\",function reduce(e){return ce.Call(vt,this.length>=0?this:[],arguments)},true)}if(!ut(Array.prototype.reduceRight,true)){var yt=Array.prototype.reduceRight;ne(Array.prototype,\"reduceRight\",function reduceRight(e){return ce.Call(yt,this.length>=0?this:[],arguments)},true)}var ht=Number(\"0o10\")!==8;var bt=Number(\"0b10\")!==2;var gt=y(Ue,function(e){return Number(e+0+e)===0});if(ht||bt||gt){var dt=Number;var mt=/^0b[01]+$/i;var Ot=/^0o[0-7]+$/i;var wt=mt.test.bind(mt);var jt=Ot.test.bind(Ot);var St=function(e){var t;if(typeof e.valueOf===\"function\"){t=e.valueOf();if(re.primitive(t)){return t}}if(typeof e.toString===\"function\"){t=e.toString();if(re.primitive(t)){return t}}throw new TypeError(\"No default value\")};var Tt=$e.test.bind($e);var It=Je.test.bind(Je);var Et=function(){var e=function Number(t){var r;if(arguments.length>0){r=re.primitive(t)?t:St(t,\"number\")}else{r=0}if(typeof r===\"string\"){r=ce.Call(Be,r);if(wt(r)){r=parseInt(C(r,2),2)}else if(jt(r)){r=parseInt(C(r,2),8)}else if(Tt(r)||It(r)){r=NaN}}var n=this;var o=a(function(){dt.prototype.valueOf.call(n);return true});if(n instanceof e&&!o){return new dt(r)}return dt(r)};return e}();Ee(dt,Et,{});b(Et,{NaN:dt.NaN,MAX_VALUE:dt.MAX_VALUE,MIN_VALUE:dt.MIN_VALUE,NEGATIVE_INFINITY:dt.NEGATIVE_INFINITY,POSITIVE_INFINITY:dt.POSITIVE_INFINITY});Number=Et;m.redefine(S,\"Number\",Et)}var Pt=Math.pow(2,53)-1;b(Number,{MAX_SAFE_INTEGER:Pt,MIN_SAFE_INTEGER:-Pt,EPSILON:2.220446049250313e-16,parseInt:S.parseInt,parseFloat:S.parseFloat,isFinite:K,isInteger:function isInteger(e){return K(e)&&ce.ToInteger(e)===e},isSafeInteger:function isSafeInteger(e){return Number.isInteger(e)&&k(e)<=Number.MAX_SAFE_INTEGER},isNaN:X});h(Number,\"parseInt\",S.parseInt,Number.parseInt!==S.parseInt);if([,1].find(function(){return true})===1){ne(Array.prototype,\"find\",et.find)}if([,1].findIndex(function(){return true})!==0){ne(Array.prototype,\"findIndex\",et.findIndex)}var Ct=Function.bind.call(Function.bind,Object.prototype.propertyIsEnumerable);var Mt=function ensureEnumerable(e,t){if(s&&Ct(e,t)){Object.defineProperty(e,t,{enumerable:false})}};var xt=function sliceArgs(){var e=Number(this);var t=arguments.length;var r=t-e;var n=new Array(r<0?0:r);for(var o=e;o<t;++o){n[o-e]=arguments[o]}return n};var Nt=function assignTo(e){return function assignToSource(t,r){t[r]=e[r];return t}};var At=function(e,t){var r=n(Object(t));var o;if(ce.IsCallable(Object.getOwnPropertySymbols)){o=v(Object.getOwnPropertySymbols(Object(t)),Ct(t))}return p(P(r,o||[]),Nt(t),e)};var Rt={assign:function(e,t){var r=ce.ToObject(e,\"Cannot convert undefined or null to object\");return p(ce.Call(xt,1,arguments),At,r)},is:function is(e,t){return ce.SameValue(e,t)}};var _t=Object.assign&&Object.preventExtensions&&function(){var e=Object.preventExtensions({1:2});try{Object.assign(e,\"xy\")}catch(t){return e[1]===\"y\"}}();if(_t){ne(Object,\"assign\",Rt.assign)}b(Object,Rt);if(s){var kt={setPrototypeOf:function(e,r){var n;var o=function(e,t){if(!ce.TypeIsObject(e)){throw new TypeError(\"cannot set prototype on a non-object\")}if(!(t===null||ce.TypeIsObject(t))){throw new TypeError(\"can only set prototype to an object or null\"+t)}};var i=function(e,r){o(e,r);t(n,e,r);return e};try{n=e.getOwnPropertyDescriptor(e.prototype,r).set;t(n,{},null)}catch(a){if(e.prototype!=={}[r]){return}n=function(e){this[r]=e};i.polyfill=i(i({},null),e.prototype)instanceof e}return i}(Object,\"__proto__\")};b(Object,kt)}if(Object.setPrototypeOf&&Object.getPrototypeOf&&Object.getPrototypeOf(Object.setPrototypeOf({},null))!==null&&Object.getPrototypeOf(Object.create(null))===null){(function(){var e=Object.create(null);var t=Object.getPrototypeOf;var r=Object.setPrototypeOf;Object.getPrototypeOf=function(r){var n=t(r);return n===e?null:n};Object.setPrototypeOf=function(t,n){var o=n===null?e:n;return r(t,o)};Object.setPrototypeOf.polyfill=false})()}var Lt=!i(function(){return Object.keys(\"foo\")});if(!Lt){var Ft=Object.keys;ne(Object,\"keys\",function keys(e){return Ft(ce.ToObject(e))});n=Object.keys}var Dt=i(function(){return Object.keys(/a/g)});if(Dt){var zt=Object.keys;ne(Object,\"keys\",function keys(e){if(re.regex(e)){var t=[];for(var r in e){if(z(e,r)){M(t,r)}}return t}return zt(e)});n=Object.keys}if(Object.getOwnPropertyNames){var qt=!i(function(){return Object.getOwnPropertyNames(\"foo\")});if(!qt){var Wt=typeof window===\"object\"?Object.getOwnPropertyNames(window):[];var Gt=Object.getOwnPropertyNames;ne(Object,\"getOwnPropertyNames\",function getOwnPropertyNames(e){var t=ce.ToObject(e);if(g(t)===\"[object Window]\"){try{return Gt(t)}catch(r){return P([],Wt)}}return Gt(t)})}}if(Object.getOwnPropertyDescriptor){var Ht=!i(function(){return Object.getOwnPropertyDescriptor(\"foo\",\"bar\")});if(!Ht){var Vt=Object.getOwnPropertyDescriptor;ne(Object,\"getOwnPropertyDescriptor\",function getOwnPropertyDescriptor(e,t){return Vt(ce.ToObject(e),t)})}}if(Object.seal){var Bt=!i(function(){return Object.seal(\"foo\")});if(!Bt){var Ut=Object.seal;ne(Object,\"seal\",function seal(e){if(!ce.TypeIsObject(e)){return e}return Ut(e)})}}if(Object.isSealed){var $t=!i(function(){return Object.isSealed(\"foo\")});if(!$t){var Jt=Object.isSealed;ne(Object,\"isSealed\",function isSealed(e){if(!ce.TypeIsObject(e)){return true}return Jt(e)})}}if(Object.freeze){var Xt=!i(function(){return Object.freeze(\"foo\")});if(!Xt){var Kt=Object.freeze;ne(Object,\"freeze\",function freeze(e){if(!ce.TypeIsObject(e)){return e}return Kt(e)})}}if(Object.isFrozen){var Zt=!i(function(){return Object.isFrozen(\"foo\")});if(!Zt){var Yt=Object.isFrozen;ne(Object,\"isFrozen\",function isFrozen(e){if(!ce.TypeIsObject(e)){return true}return Yt(e)})}}if(Object.preventExtensions){var Qt=!i(function(){return Object.preventExtensions(\"foo\")});if(!Qt){var er=Object.preventExtensions;ne(Object,\"preventExtensions\",function preventExtensions(e){if(!ce.TypeIsObject(e)){return e}return er(e)})}}if(Object.isExtensible){var tr=!i(function(){return Object.isExtensible(\"foo\")});if(!tr){var rr=Object.isExtensible;ne(Object,\"isExtensible\",function isExtensible(e){if(!ce.TypeIsObject(e)){return false}return rr(e)})}}if(Object.getPrototypeOf){var nr=!i(function(){return Object.getPrototypeOf(\"foo\")});if(!nr){var or=Object.getPrototypeOf;ne(Object,\"getPrototypeOf\",function getPrototypeOf(e){return or(ce.ToObject(e))})}}var ir=s&&function(){var e=Object.getOwnPropertyDescriptor(RegExp.prototype,\"flags\");return e&&ce.IsCallable(e.get)}();if(s&&!ir){var ar=function flags(){if(!ce.TypeIsObject(this)){throw new TypeError(\"Method called on incompatible type: must be an object.\")}var e=\"\";if(this.global){e+=\"g\"}if(this.ignoreCase){e+=\"i\"}if(this.multiline){e+=\"m\"}if(this.unicode){e+=\"u\"}if(this.sticky){e+=\"y\"}return e};m.getter(RegExp.prototype,\"flags\",ar)}var ur=s&&a(function(){return String(new RegExp(/a/g,\"i\"))===\"/a/i\"});var fr=oe&&s&&function(){var e=/./;e[$.match]=false;return RegExp(e)===e}();var sr=a(function(){return RegExp.prototype.toString.call({source:\"abc\"})===\"/abc/\"});var cr=sr&&a(function(){return RegExp.prototype.toString.call({source:\"a\",flags:\"b\"})===\"/a/b\"});if(!sr||!cr){var lr=RegExp.prototype.toString;h(RegExp.prototype,\"toString\",function toString(){var e=ce.RequireObjectCoercible(this);if(re.regex(e)){return t(lr,e)}var r=ue(e.source);var n=ue(e.flags);return\"/\"+r+\"/\"+n},true);m.preserveToString(RegExp.prototype.toString,lr)}if(s&&(!ur||fr)){var pr=Object.getOwnPropertyDescriptor(RegExp.prototype,\"flags\").get;var vr=Object.getOwnPropertyDescriptor(RegExp.prototype,\"source\")||{};var yr=function(){return this.source};var hr=ce.IsCallable(vr.get)?vr.get:yr;var br=RegExp;var gr=function(){return function RegExp(e,t){var r=ce.IsRegExp(e);var n=this instanceof RegExp;if(!n&&r&&typeof t===\"undefined\"&&e.constructor===RegExp){return e}var o=e;var i=t;if(re.regex(e)){o=ce.Call(hr,e);i=typeof t===\"undefined\"?ce.Call(pr,e):t;return new RegExp(o,i)}else if(r){o=e.source;i=typeof t===\"undefined\"?e.flags:t}return new br(e,t)}}();Ee(br,gr,{$input:true});RegExp=gr;m.redefine(S,\"RegExp\",gr)}if(s){var dr={input:\"$_\",lastMatch:\"$&\",lastParen:\"$+\",leftContext:\"$`\",rightContext:\"$'\"};l(n(dr),function(e){if(e in RegExp&&!(dr[e]in RegExp)){m.getter(RegExp,dr[e],function get(){return RegExp[e]})}})}Ce(RegExp);var mr=1/Number.EPSILON;var Or=function roundTiesToEven(e){return e+mr-mr};var wr=Math.pow(2,-23);var jr=Math.pow(2,127)*(2-wr);var Sr=Math.pow(2,-126);var Tr=Math.E;var Ir=Math.LOG2E;var Er=Math.LOG10E;var Pr=Number.prototype.clz;delete Number.prototype.clz;var Cr={acosh:function acosh(e){var t=Number(e);if(X(t)||e<1){return NaN}if(t===1){return 0}if(t===Infinity){return t}var r=1/(t*t);if(t<2){return Y(t-1+D(1-r)*t)}var n=t/2;return Y(n+D(1-r)*n-1)+1/Ir},asinh:function asinh(e){var t=Number(e);if(t===0||!T(t)){return t}var r=k(t);var n=r*r;var o=Z(t);if(r<1){return o*Y(r+n/(D(n+1)+1))}return o*(Y(r/2+D(1+1/n)*r/2-1)+1/Ir)},atanh:function atanh(e){var t=Number(e);if(t===0){return t}if(t===-1){return-Infinity}if(t===1){return Infinity}if(X(t)||t<-1||t>1){return NaN}var r=k(t);return Z(t)*Y(2*r/(1-r))/2},cbrt:function cbrt(e){var t=Number(e);if(t===0){return t}var r=t<0;var n;if(r){t=-t}if(t===Infinity){n=Infinity}else{n=L(F(t)/3);n=(t/(n*n)+2*n)/3}return r?-n:n},clz32:function clz32(e){var t=Number(e);var r=ce.ToUint32(t);if(r===0){return 32}return Pr?ce.Call(Pr,r):31-_(F(r+.5)*Ir)},cosh:function cosh(e){var t=Number(e);if(t===0){return 1}if(X(t)){return NaN}if(!T(t)){return Infinity}var r=L(k(t)-1);return(r+1/(r*Tr*Tr))*(Tr/2)},expm1:function expm1(e){var t=Number(e);if(t===-Infinity){return-1}if(!T(t)||t===0){return t}if(k(t)>.5){return L(t)-1}var r=t;var n=0;var o=1;while(n+r!==n){n+=r;o+=1;r*=t/o}return n},hypot:function hypot(e,t){var r=0;var n=0;for(var o=0;o<arguments.length;++o){var i=k(Number(arguments[o]));if(n<i){r*=n/i*(n/i);r+=1;n=i}else{r+=i>0?i/n*(i/n):i}}return n===Infinity?Infinity:n*D(r)},log2:function log2(e){return F(e)*Ir},log10:function log10(e){return F(e)*Er},log1p:Y,sign:Z,sinh:function sinh(e){var t=Number(e);if(!T(t)||t===0){return t}var r=k(t);if(r<1){var n=Math.expm1(r);return Z(t)*n*(1+1/(n+1))/2}var o=L(r-1);return Z(t)*(o-1/(o*Tr*Tr))*(Tr/2)},tanh:function tanh(e){var t=Number(e);if(X(t)||t===0){return t}if(t>=20){return 1}if(t<=-20){return-1}return(Math.expm1(t)-Math.expm1(-t))/(L(t)+L(-t))},trunc:function trunc(e){var t=Number(e);return t<0?-_(-t):_(t)},imul:function imul(e,t){var r=ce.ToUint32(e);var n=ce.ToUint32(t);var o=r>>>16&65535;var i=r&65535;var a=n>>>16&65535;var u=n&65535;return i*u+(o*u+i*a<<16>>>0)|0},fround:function fround(e){var t=Number(e);if(t===0||t===Infinity||t===-Infinity||X(t)){return t}var r=Z(t);var n=k(t);if(n<Sr){return r*Or(n/Sr/wr)*Sr*wr}var o=(1+wr/Number.EPSILON)*n;var i=o-(o-n);if(i>jr||X(i)){return r*Infinity}return r*i}};var Mr=function withinULPDistance(e,t,r){return k(1-e/t)/Number.EPSILON<(r||8)};b(Math,Cr);h(Math,\"sinh\",Cr.sinh,Math.sinh(710)===Infinity);h(Math,\"cosh\",Cr.cosh,Math.cosh(710)===Infinity);h(Math,\"log1p\",Cr.log1p,Math.log1p(-1e-17)!==-1e-17);h(Math,\"asinh\",Cr.asinh,Math.asinh(-1e7)!==-Math.asinh(1e7));h(Math,\"asinh\",Cr.asinh,Math.asinh(1e300)===Infinity);h(Math,\"atanh\",Cr.atanh,Math.atanh(1e-300)===0);h(Math,\"tanh\",Cr.tanh,Math.tanh(-2e-17)!==-2e-17);\nh(Math,\"acosh\",Cr.acosh,Math.acosh(Number.MAX_VALUE)===Infinity);h(Math,\"acosh\",Cr.acosh,!Mr(Math.acosh(1+Number.EPSILON),Math.sqrt(2*Number.EPSILON)));h(Math,\"cbrt\",Cr.cbrt,!Mr(Math.cbrt(1e-300),1e-100));h(Math,\"sinh\",Cr.sinh,Math.sinh(-2e-17)!==-2e-17);var xr=Math.expm1(10);h(Math,\"expm1\",Cr.expm1,xr>22025.465794806718||xr<22025.465794806718);var Nr=Math.round;var Ar=Math.round(.5-Number.EPSILON/4)===0&&Math.round(-.5+Number.EPSILON/3.99)===1;var Rr=mr+1;var _r=2*mr-1;var kr=[Rr,_r].every(function(e){return Math.round(e)===e});h(Math,\"round\",function round(e){var t=_(e);var r=t===-1?-0:t+1;return e-t<.5?t:r},!Ar||!kr);m.preserveToString(Math.round,Nr);var Lr=Math.imul;if(Math.imul(4294967295,5)!==-5){Math.imul=Cr.imul;m.preserveToString(Math.imul,Lr)}if(Math.imul.length!==2){ne(Math,\"imul\",function imul(e,t){return ce.Call(Lr,Math,arguments)})}var Fr=function(){var e=S.setTimeout;if(typeof e!==\"function\"&&typeof e!==\"object\"){return}ce.IsPromise=function(e){if(!ce.TypeIsObject(e)){return false}if(typeof e._promise===\"undefined\"){return false}return true};var r=function(e){if(!ce.IsConstructor(e)){throw new TypeError(\"Bad promise constructor\")}var t=this;var r=function(e,r){if(t.resolve!==void 0||t.reject!==void 0){throw new TypeError(\"Bad Promise implementation!\")}t.resolve=e;t.reject=r};t.resolve=void 0;t.reject=void 0;t.promise=new e(r);if(!(ce.IsCallable(t.resolve)&&ce.IsCallable(t.reject))){throw new TypeError(\"Bad promise constructor\")}};var n;if(typeof window!==\"undefined\"&&ce.IsCallable(window.postMessage)){n=function(){var e=[];var t=\"zero-timeout-message\";var r=function(r){M(e,r);window.postMessage(t,\"*\")};var n=function(r){if(r.source===window&&r.data===t){r.stopPropagation();if(e.length===0){return}var n=N(e);n()}};window.addEventListener(\"message\",n,true);return r}}var o=function(){var e=S.Promise;var t=e&&e.resolve&&e.resolve();return t&&function(e){return t.then(e)}};var i=ce.IsCallable(S.setImmediate)?S.setImmediate:typeof process===\"object\"&&process.nextTick?process.nextTick:o()||(ce.IsCallable(n)?n():function(t){e(t,0)});var a=function(e){return e};var u=function(e){throw e};var f=0;var s=1;var c=2;var l=0;var p=1;var v=2;var y={};var h=function(e,t,r){i(function(){g(e,t,r)})};var g=function(e,t,r){var n,o;if(t===y){return e(r)}try{n=e(r);o=t.resolve}catch(i){n=i;o=t.reject}o(n)};var d=function(e,t){var r=e._promise;var n=r.reactionLength;if(n>0){h(r.fulfillReactionHandler0,r.reactionCapability0,t);r.fulfillReactionHandler0=void 0;r.rejectReactions0=void 0;r.reactionCapability0=void 0;if(n>1){for(var o=1,i=0;o<n;o++,i+=3){h(r[i+l],r[i+v],t);e[i+l]=void 0;e[i+p]=void 0;e[i+v]=void 0}}}r.result=t;r.state=s;r.reactionLength=0};var m=function(e,t){var r=e._promise;var n=r.reactionLength;if(n>0){h(r.rejectReactionHandler0,r.reactionCapability0,t);r.fulfillReactionHandler0=void 0;r.rejectReactions0=void 0;r.reactionCapability0=void 0;if(n>1){for(var o=1,i=0;o<n;o++,i+=3){h(r[i+p],r[i+v],t);e[i+l]=void 0;e[i+p]=void 0;e[i+v]=void 0}}}r.result=t;r.state=c;r.reactionLength=0};var O=function(e){var t=false;var r=function(r){var n;if(t){return}t=true;if(r===e){return m(e,new TypeError(\"Self resolution\"))}if(!ce.TypeIsObject(r)){return d(e,r)}try{n=r.then}catch(o){return m(e,o)}if(!ce.IsCallable(n)){return d(e,r)}i(function(){j(e,r,n)})};var n=function(r){if(t){return}t=true;return m(e,r)};return{resolve:r,reject:n}};var w=function(e,r,n,o){if(e===I){t(e,r,n,o,y)}else{t(e,r,n,o)}};var j=function(e,t,r){var n=O(e);var o=n.resolve;var i=n.reject;try{w(r,t,o,i)}catch(a){i(a)}};var T,I;var E=function(){var e=function Promise(t){if(!(this instanceof e)){throw new TypeError('Constructor Promise requires \"new\"')}if(this&&this._promise){throw new TypeError(\"Bad construction\")}if(!ce.IsCallable(t)){throw new TypeError(\"not a valid resolver\")}var r=Ae(this,e,T,{_promise:{result:void 0,state:f,reactionLength:0,fulfillReactionHandler0:void 0,rejectReactionHandler0:void 0,reactionCapability0:void 0}});var n=O(r);var o=n.reject;try{t(n.resolve,o)}catch(i){o(i)}return r};return e}();T=E.prototype;var P=function(e,t,r,n){var o=false;return function(i){if(o){return}o=true;t[e]=i;if(--n.count===0){var a=r.resolve;a(t)}}};var C=function(e,t,r){var n=e.iterator;var o=[];var i={count:1};var a,u;var f=0;while(true){try{a=ce.IteratorStep(n);if(a===false){e.done=true;break}u=a.value}catch(s){e.done=true;throw s}o[f]=void 0;var c=t.resolve(u);var l=P(f,o,r,i);i.count+=1;w(c.then,c,l,r.reject);f+=1}if(--i.count===0){var p=r.resolve;p(o)}return r.promise};var x=function(e,t,r){var n=e.iterator;var o,i,a;while(true){try{o=ce.IteratorStep(n);if(o===false){e.done=true;break}i=o.value}catch(u){e.done=true;throw u}a=t.resolve(i);w(a.then,a,r.resolve,r.reject)}return r.promise};b(E,{all:function all(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Promise is not object\")}var n=new r(t);var o,i;try{o=ce.GetIterator(e);i={iterator:o,done:false};return C(i,t,n)}catch(a){var u=a;if(i&&!i.done){try{ce.IteratorClose(o,true)}catch(f){u=f}}var s=n.reject;s(u);return n.promise}},race:function race(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Promise is not object\")}var n=new r(t);var o,i;try{o=ce.GetIterator(e);i={iterator:o,done:false};return x(i,t,n)}catch(a){var u=a;if(i&&!i.done){try{ce.IteratorClose(o,true)}catch(f){u=f}}var s=n.reject;s(u);return n.promise}},reject:function reject(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Bad promise constructor\")}var n=new r(t);var o=n.reject;o(e);return n.promise},resolve:function resolve(e){var t=this;if(!ce.TypeIsObject(t)){throw new TypeError(\"Bad promise constructor\")}if(ce.IsPromise(e)){var n=e.constructor;if(n===t){return e}}var o=new r(t);var i=o.resolve;i(e);return o.promise}});b(T,{\"catch\":function(e){return this.then(null,e)},then:function then(e,t){var n=this;if(!ce.IsPromise(n)){throw new TypeError(\"not a promise\")}var o=ce.SpeciesConstructor(n,E);var i;var b=arguments.length>2&&arguments[2]===y;if(b&&o===E){i=y}else{i=new r(o)}var g=ce.IsCallable(e)?e:a;var d=ce.IsCallable(t)?t:u;var m=n._promise;var O;if(m.state===f){if(m.reactionLength===0){m.fulfillReactionHandler0=g;m.rejectReactionHandler0=d;m.reactionCapability0=i}else{var w=3*(m.reactionLength-1);m[w+l]=g;m[w+p]=d;m[w+v]=i}m.reactionLength+=1}else if(m.state===s){O=m.result;h(g,i,O)}else if(m.state===c){O=m.result;h(d,i,O)}else{throw new TypeError(\"unexpected Promise state\")}return i.promise}});y=new r(E);I=T.then;return E}();if(S.Promise){delete S.Promise.accept;delete S.Promise.defer;delete S.Promise.prototype.chain}if(typeof Fr===\"function\"){b(S,{Promise:Fr});var Dr=w(S.Promise,function(e){return e.resolve(42).then(function(){})instanceof e});var zr=!i(function(){return S.Promise.reject(42).then(null,5).then(null,W)});var qr=i(function(){return S.Promise.call(3,W)});var Wr=function(e){var t=e.resolve(5);t.constructor={};var r=e.resolve(t);try{r.then(null,W).then(null,W)}catch(n){return true}return t===r}(S.Promise);var Gr=s&&function(){var e=0;var t=Object.defineProperty({},\"then\",{get:function(){e+=1}});Promise.resolve(t);return e===1}();var Hr=function BadResolverPromise(e){var t=new Promise(e);e(3,function(){});this.then=t.then;this.constructor=BadResolverPromise};Hr.prototype=Promise.prototype;Hr.all=Promise.all;var Vr=a(function(){return!!Hr.all([1,2])});if(!Dr||!zr||!qr||Wr||!Gr||Vr){Promise=Fr;ne(S,\"Promise\",Fr)}if(Promise.all.length!==1){var Br=Promise.all;ne(Promise,\"all\",function all(e){return ce.Call(Br,this,arguments)})}if(Promise.race.length!==1){var Ur=Promise.race;ne(Promise,\"race\",function race(e){return ce.Call(Ur,this,arguments)})}if(Promise.resolve.length!==1){var $r=Promise.resolve;ne(Promise,\"resolve\",function resolve(e){return ce.Call($r,this,arguments)})}if(Promise.reject.length!==1){var Jr=Promise.reject;ne(Promise,\"reject\",function reject(e){return ce.Call(Jr,this,arguments)})}Mt(Promise,\"all\");Mt(Promise,\"race\");Mt(Promise,\"resolve\");Mt(Promise,\"reject\");Ce(Promise)}var Xr=function(e){var t=n(p(e,function(e,t){e[t]=true;return e},{}));return e.join(\":\")===t.join(\":\")};var Kr=Xr([\"z\",\"a\",\"bb\"]);var Zr=Xr([\"z\",1,\"a\",\"3\",2]);if(s){var Yr=function fastkey(e,t){if(!t&&!Kr){return null}if(se(e)){return\"^\"+ce.ToString(e)}else if(typeof e===\"string\"){return\"$\"+e}else if(typeof e===\"number\"){if(!Zr){return\"n\"+e}return e}else if(typeof e===\"boolean\"){return\"b\"+e}return null};var Qr=function emptyObject(){return Object.create?Object.create(null):{}};var en=function addIterableToMap(e,n,o){if(r(o)||re.string(o)){l(o,function(e){if(!ce.TypeIsObject(e)){throw new TypeError(\"Iterator value \"+e+\" is not an entry object\")}n.set(e[0],e[1])})}else if(o instanceof e){t(e.prototype.forEach,o,function(e,t){n.set(t,e)})}else{var i,a;if(!se(o)){a=n.set;if(!ce.IsCallable(a)){throw new TypeError(\"bad map\")}i=ce.GetIterator(o)}if(typeof i!==\"undefined\"){while(true){var u=ce.IteratorStep(i);if(u===false){break}var f=u.value;try{if(!ce.TypeIsObject(f)){throw new TypeError(\"Iterator value \"+f+\" is not an entry object\")}t(a,n,f[0],f[1])}catch(s){ce.IteratorClose(i,true);throw s}}}}};var tn=function addIterableToSet(e,n,o){if(r(o)||re.string(o)){l(o,function(e){n.add(e)})}else if(o instanceof e){t(e.prototype.forEach,o,function(e){n.add(e)})}else{var i,a;if(!se(o)){a=n.add;if(!ce.IsCallable(a)){throw new TypeError(\"bad set\")}i=ce.GetIterator(o)}if(typeof i!==\"undefined\"){while(true){var u=ce.IteratorStep(i);if(u===false){break}var f=u.value;try{t(a,n,f)}catch(s){ce.IteratorClose(i,true);throw s}}}}};var rn={Map:function(){var e={};var r=function MapEntry(e,t){this.key=e;this.value=t;this.next=null;this.prev=null};r.prototype.isRemoved=function isRemoved(){return this.key===e};var n=function isMap(e){return!!e._es6map};var o=function requireMapSlot(e,t){if(!ce.TypeIsObject(e)||!n(e)){throw new TypeError(\"Method Map.prototype.\"+t+\" called on incompatible receiver \"+ce.ToString(e))}};var i=function MapIterator(e,t){o(e,\"[[MapIterator]]\");this.head=e._head;this.i=this.head;this.kind=t};i.prototype={isMapIterator:true,next:function next(){if(!this.isMapIterator){throw new TypeError(\"Not a MapIterator\")}var e=this.i;var t=this.kind;var r=this.head;if(typeof this.i===\"undefined\"){return Ke()}while(e.isRemoved()&&e!==r){e=e.prev}var n;while(e.next!==r){e=e.next;if(!e.isRemoved()){if(t===\"key\"){n=e.key}else if(t===\"value\"){n=e.value}else{n=[e.key,e.value]}this.i=e;return Ke(n)}}this.i=void 0;return Ke()}};Me(i.prototype);var a;var u=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}if(this&&this._es6map){throw new TypeError(\"Bad construction\")}var e=Ae(this,Map,a,{_es6map:true,_head:null,_map:G?new G:null,_size:0,_storage:Qr()});var t=new r(null,null);t.next=t.prev=t;e._head=t;if(arguments.length>0){en(Map,e,arguments[0])}return e};a=u.prototype;m.getter(a,\"size\",function(){if(typeof this._size===\"undefined\"){throw new TypeError(\"size method called on incompatible Map\")}return this._size});b(a,{get:function get(e){o(this,\"get\");var t;var r=Yr(e,true);if(r!==null){t=this._storage[r];if(t){return t.value}else{return}}if(this._map){t=V.call(this._map,e);if(t){return t.value}else{return}}var n=this._head;var i=n;while((i=i.next)!==n){if(ce.SameValueZero(i.key,e)){return i.value}}},has:function has(e){o(this,\"has\");var t=Yr(e,true);if(t!==null){return typeof this._storage[t]!==\"undefined\"}if(this._map){return B.call(this._map,e)}var r=this._head;var n=r;while((n=n.next)!==r){if(ce.SameValueZero(n.key,e)){return true}}return false},set:function set(e,t){o(this,\"set\");var n=this._head;var i=n;var a;var u=Yr(e,true);if(u!==null){if(typeof this._storage[u]!==\"undefined\"){this._storage[u].value=t;return this}else{a=this._storage[u]=new r(e,t);i=n.prev}}else if(this._map){if(B.call(this._map,e)){V.call(this._map,e).value=t}else{a=new r(e,t);U.call(this._map,e,a);i=n.prev}}while((i=i.next)!==n){if(ce.SameValueZero(i.key,e)){i.value=t;return this}}a=a||new r(e,t);if(ce.SameValue(-0,e)){a.key=+0}a.next=this._head;a.prev=this._head.prev;a.prev.next=a;a.next.prev=a;this._size+=1;return this},\"delete\":function(t){o(this,\"delete\");var r=this._head;var n=r;var i=Yr(t,true);if(i!==null){if(typeof this._storage[i]===\"undefined\"){return false}n=this._storage[i].prev;delete this._storage[i]}else if(this._map){if(!B.call(this._map,t)){return false}n=V.call(this._map,t).prev;H.call(this._map,t)}while((n=n.next)!==r){if(ce.SameValueZero(n.key,t)){n.key=e;n.value=e;n.prev.next=n.next;n.next.prev=n.prev;this._size-=1;return true}}return false},clear:function clear(){o(this,\"clear\");this._map=G?new G:null;this._size=0;this._storage=Qr();var t=this._head;var r=t;var n=r.next;while((r=n)!==t){r.key=e;r.value=e;n=r.next;r.next=r.prev=t}t.next=t.prev=t},keys:function keys(){o(this,\"keys\");return new i(this,\"key\")},values:function values(){o(this,\"values\");return new i(this,\"value\")},entries:function entries(){o(this,\"entries\");return new i(this,\"key+value\")},forEach:function forEach(e){o(this,\"forEach\");var r=arguments.length>1?arguments[1]:null;var n=this.entries();for(var i=n.next();!i.done;i=n.next()){if(r){t(e,r,i.value[1],i.value[0],this)}else{e(i.value[1],i.value[0],this)}}}});Me(a,a.entries);return u}(),Set:function(){var e=function isSet(e){return e._es6set&&typeof e._storage!==\"undefined\"};var r=function requireSetSlot(t,r){if(!ce.TypeIsObject(t)||!e(t)){throw new TypeError(\"Set.prototype.\"+r+\" called on incompatible receiver \"+ce.ToString(t))}};var o;var i=function Set(){if(!(this instanceof Set)){throw new TypeError('Constructor Set requires \"new\"')}if(this&&this._es6set){throw new TypeError(\"Bad construction\")}var e=Ae(this,Set,o,{_es6set:true,\"[[SetData]]\":null,_storage:Qr()});if(!e._es6set){throw new TypeError(\"bad set\")}if(arguments.length>0){tn(Set,e,arguments[0])}return e};o=i.prototype;var a=function(e){var t=e;if(t===\"^null\"){return null}else if(t===\"^undefined\"){return void 0}else{var r=t.charAt(0);if(r===\"$\"){return C(t,1)}else if(r===\"n\"){return+C(t,1)}else if(r===\"b\"){return t===\"btrue\"}}return+t};var u=function ensureMap(e){if(!e[\"[[SetData]]\"]){var t=new rn.Map;e[\"[[SetData]]\"]=t;l(n(e._storage),function(e){var r=a(e);t.set(r,r)});e[\"[[SetData]]\"]=t}e._storage=null};m.getter(i.prototype,\"size\",function(){r(this,\"size\");if(this._storage){return n(this._storage).length}u(this);return this[\"[[SetData]]\"].size});b(i.prototype,{has:function has(e){r(this,\"has\");var t;if(this._storage&&(t=Yr(e))!==null){return!!this._storage[t]}u(this);return this[\"[[SetData]]\"].has(e)},add:function add(e){r(this,\"add\");var t;if(this._storage&&(t=Yr(e))!==null){this._storage[t]=true;return this}u(this);this[\"[[SetData]]\"].set(e,e);return this},\"delete\":function(e){r(this,\"delete\");var t;if(this._storage&&(t=Yr(e))!==null){var n=z(this._storage,t);return delete this._storage[t]&&n}u(this);return this[\"[[SetData]]\"][\"delete\"](e)},clear:function clear(){r(this,\"clear\");if(this._storage){this._storage=Qr()}if(this[\"[[SetData]]\"]){this[\"[[SetData]]\"].clear()}},values:function values(){r(this,\"values\");u(this);return new f(this[\"[[SetData]]\"].values())},entries:function entries(){r(this,\"entries\");u(this);return new f(this[\"[[SetData]]\"].entries())},forEach:function forEach(e){r(this,\"forEach\");var n=arguments.length>1?arguments[1]:null;var o=this;u(o);this[\"[[SetData]]\"].forEach(function(r,i){if(n){t(e,n,i,i,o)}else{e(i,i,o)}})}});h(i.prototype,\"keys\",i.prototype.values,true);Me(i.prototype,i.prototype.values);var f=function SetIterator(e){this.it=e};f.prototype={isSetIterator:true,next:function next(){if(!this.isSetIterator){throw new TypeError(\"Not a SetIterator\")}return this.it.next()}};Me(f.prototype);return i}()};var nn=S.Set&&!Set.prototype[\"delete\"]&&Set.prototype.remove&&Set.prototype.items&&Set.prototype.map&&Array.isArray((new Set).keys);if(nn){S.Set=rn.Set}if(S.Map||S.Set){var on=a(function(){return new Map([[1,2]]).get(1)===2});if(!on){S.Map=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}var e=new G;if(arguments.length>0){en(Map,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,S.Map.prototype);return e};S.Map.prototype=O(G.prototype);h(S.Map.prototype,\"constructor\",S.Map,true);m.preserveToString(S.Map,G)}var an=new Map;var un=function(){var e=new Map([[1,0],[2,0],[3,0],[4,0]]);e.set(-0,e);return e.get(0)===e&&e.get(-0)===e&&e.has(0)&&e.has(-0)}();var fn=an.set(1,2)===an;if(!un||!fn){ne(Map.prototype,\"set\",function set(e,r){t(U,this,e===0?0:e,r);return this})}if(!un){b(Map.prototype,{get:function get(e){return t(V,this,e===0?0:e)},has:function has(e){return t(B,this,e===0?0:e)}},true);m.preserveToString(Map.prototype.get,V);m.preserveToString(Map.prototype.has,B)}var sn=new Set;var cn=Set.prototype[\"delete\"]&&Set.prototype.add&&Set.prototype.has&&function(e){e[\"delete\"](0);e.add(-0);return!e.has(0)}(sn);var ln=sn.add(1)===sn;if(!cn||!ln){var pn=Set.prototype.add;Set.prototype.add=function add(e){t(pn,this,e===0?0:e);return this};m.preserveToString(Set.prototype.add,pn)}if(!cn){var vn=Set.prototype.has;Set.prototype.has=function has(e){return t(vn,this,e===0?0:e)};m.preserveToString(Set.prototype.has,vn);var yn=Set.prototype[\"delete\"];Set.prototype[\"delete\"]=function SetDelete(e){return t(yn,this,e===0?0:e)};m.preserveToString(Set.prototype[\"delete\"],yn)}var hn=w(S.Map,function(e){var t=new e([]);t.set(42,42);return t instanceof e});var bn=Object.setPrototypeOf&&!hn;var gn=function(){try{return!(S.Map()instanceof S.Map)}catch(e){return e instanceof TypeError}}();if(S.Map.length!==0||bn||!gn){S.Map=function Map(){if(!(this instanceof Map)){throw new TypeError('Constructor Map requires \"new\"')}var e=new G;if(arguments.length>0){en(Map,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,Map.prototype);return e};S.Map.prototype=G.prototype;h(S.Map.prototype,\"constructor\",S.Map,true);m.preserveToString(S.Map,G)}var dn=w(S.Set,function(e){var t=new e([]);t.add(42,42);return t instanceof e});var mn=Object.setPrototypeOf&&!dn;var On=function(){try{return!(S.Set()instanceof S.Set)}catch(e){return e instanceof TypeError}}();if(S.Set.length!==0||mn||!On){var wn=S.Set;S.Set=function Set(){if(!(this instanceof Set)){throw new TypeError('Constructor Set requires \"new\"')}var e=new wn;if(arguments.length>0){tn(Set,e,arguments[0])}delete e.constructor;Object.setPrototypeOf(e,Set.prototype);return e};S.Set.prototype=wn.prototype;h(S.Set.prototype,\"constructor\",S.Set,true);m.preserveToString(S.Set,wn)}var jn=new S.Map;var Sn=!a(function(){return jn.keys().next().done});if(typeof S.Map.prototype.clear!==\"function\"||(new S.Set).size!==0||jn.size!==0||typeof S.Map.prototype.keys!==\"function\"||typeof S.Set.prototype.keys!==\"function\"||typeof S.Map.prototype.forEach!==\"function\"||typeof S.Set.prototype.forEach!==\"function\"||u(S.Map)||u(S.Set)||typeof jn.keys().next!==\"function\"||Sn||!hn){b(S,{Map:rn.Map,Set:rn.Set},true)}if(S.Set.prototype.keys!==S.Set.prototype.values){h(S.Set.prototype,\"keys\",S.Set.prototype.values,true)}Me(Object.getPrototypeOf((new S.Map).keys()));Me(Object.getPrototypeOf((new S.Set).keys()));if(c&&S.Set.prototype.has.name!==\"has\"){var Tn=S.Set.prototype.has;ne(S.Set.prototype,\"has\",function has(e){return t(Tn,this,e)})}}b(S,rn);Ce(S.Map);Ce(S.Set)}var In=function throwUnlessTargetIsObject(e){if(!ce.TypeIsObject(e)){throw new TypeError(\"target must be an object\")}};var En={apply:function apply(){return ce.Call(ce.Call,null,arguments)},construct:function construct(e,t){if(!ce.IsConstructor(e)){throw new TypeError(\"First argument must be a constructor.\")}var r=arguments.length>2?arguments[2]:e;if(!ce.IsConstructor(r)){throw new TypeError(\"new.target must be a constructor.\")}return ce.Construct(e,t,r,\"internal\")},deleteProperty:function deleteProperty(e,t){In(e);if(s){var r=Object.getOwnPropertyDescriptor(e,t);if(r&&!r.configurable){return false}}return delete e[t]},has:function has(e,t){In(e);return t in e}};if(Object.getOwnPropertyNames){Object.assign(En,{ownKeys:function ownKeys(e){In(e);var t=Object.getOwnPropertyNames(e);if(ce.IsCallable(Object.getOwnPropertySymbols)){x(t,Object.getOwnPropertySymbols(e))}return t}})}var Pn=function ConvertExceptionToBoolean(e){return!i(e)};if(Object.preventExtensions){Object.assign(En,{isExtensible:function isExtensible(e){In(e);return Object.isExtensible(e)},preventExtensions:function preventExtensions(e){In(e);return Pn(function(){return Object.preventExtensions(e)})}})}if(s){var Cn=function get(e,t,r){var n=Object.getOwnPropertyDescriptor(e,t);if(!n){var o=Object.getPrototypeOf(e);if(o===null){return void 0}return Cn(o,t,r)}if(\"value\"in n){return n.value}if(n.get){return ce.Call(n.get,r)}return void 0};var Mn=function set(e,r,n,o){var i=Object.getOwnPropertyDescriptor(e,r);if(!i){var a=Object.getPrototypeOf(e);if(a!==null){return Mn(a,r,n,o)}i={value:void 0,writable:true,enumerable:true,configurable:true}}if(\"value\"in i){if(!i.writable){return false}if(!ce.TypeIsObject(o)){return false}var u=Object.getOwnPropertyDescriptor(o,r);if(u){return ae.defineProperty(o,r,{value:n})}else{return ae.defineProperty(o,r,{value:n,writable:true,enumerable:true,configurable:true})}}if(i.set){t(i.set,o,n);return true}return false};Object.assign(En,{defineProperty:function defineProperty(e,t,r){In(e);return Pn(function(){return Object.defineProperty(e,t,r)})},getOwnPropertyDescriptor:function getOwnPropertyDescriptor(e,t){In(e);return Object.getOwnPropertyDescriptor(e,t)},get:function get(e,t){In(e);var r=arguments.length>2?arguments[2]:e;return Cn(e,t,r)},set:function set(e,t,r){In(e);var n=arguments.length>3?arguments[3]:e;return Mn(e,t,r,n)}})}if(Object.getPrototypeOf){var xn=Object.getPrototypeOf;En.getPrototypeOf=function getPrototypeOf(e){In(e);return xn(e)}}if(Object.setPrototypeOf&&En.getPrototypeOf){var Nn=function(e,t){var r=t;while(r){if(e===r){return true}r=En.getPrototypeOf(r)}return false};Object.assign(En,{setPrototypeOf:function setPrototypeOf(e,t){In(e);if(t!==null&&!ce.TypeIsObject(t)){throw new TypeError(\"proto must be an object or null\")}if(t===ae.getPrototypeOf(e)){return true}if(ae.isExtensible&&!ae.isExtensible(e)){return false}if(Nn(e,t)){return false}Object.setPrototypeOf(e,t);return true}})}var An=function(e,t){if(!ce.IsCallable(S.Reflect[e])){h(S.Reflect,e,t)}else{var r=a(function(){S.Reflect[e](1);S.Reflect[e](NaN);S.Reflect[e](true);return true});if(r){ne(S.Reflect,e,t)}}};Object.keys(En).forEach(function(e){An(e,En[e])});var Rn=S.Reflect.getPrototypeOf;if(c&&Rn&&Rn.name!==\"getPrototypeOf\"){ne(S.Reflect,\"getPrototypeOf\",function getPrototypeOf(e){return t(Rn,S.Reflect,e)})}if(S.Reflect.setPrototypeOf){if(a(function(){S.Reflect.setPrototypeOf(1,{});return true})){ne(S.Reflect,\"setPrototypeOf\",En.setPrototypeOf)}}if(S.Reflect.defineProperty){if(!a(function(){var e=!S.Reflect.defineProperty(1,\"test\",{value:1});var t=typeof Object.preventExtensions!==\"function\"||!S.Reflect.defineProperty(Object.preventExtensions({}),\"test\",{});return e&&t})){ne(S.Reflect,\"defineProperty\",En.defineProperty)}}if(S.Reflect.construct){if(!a(function(){var e=function F(){};return S.Reflect.construct(function(){},[],e)instanceof e})){ne(S.Reflect,\"construct\",En.construct)}}if(String(new Date(NaN))!==\"Invalid Date\"){var _n=Date.prototype.toString;var kn=function toString(){var e=+this;if(e!==e){return\"Invalid Date\"}return ce.Call(_n,this)};ne(Date.prototype,\"toString\",kn)}var Ln={anchor:function anchor(e){return ce.CreateHTML(this,\"a\",\"name\",e)},big:function big(){return ce.CreateHTML(this,\"big\",\"\",\"\")},blink:function blink(){return ce.CreateHTML(this,\"blink\",\"\",\"\")},bold:function bold(){return ce.CreateHTML(this,\"b\",\"\",\"\")},fixed:function fixed(){return ce.CreateHTML(this,\"tt\",\"\",\"\")},fontcolor:function fontcolor(e){return ce.CreateHTML(this,\"font\",\"color\",e)},fontsize:function fontsize(e){return ce.CreateHTML(this,\"font\",\"size\",e)},italics:function italics(){return ce.CreateHTML(this,\"i\",\"\",\"\")},link:function link(e){return ce.CreateHTML(this,\"a\",\"href\",e)},small:function small(){return ce.CreateHTML(this,\"small\",\"\",\"\")},strike:function strike(){return ce.CreateHTML(this,\"strike\",\"\",\"\")},sub:function sub(){return ce.CreateHTML(this,\"sub\",\"\",\"\")},sup:function sub(){return ce.CreateHTML(this,\"sup\",\"\",\"\")}};l(Object.keys(Ln),function(e){var r=String.prototype[e];var n=false;if(ce.IsCallable(r)){var o=t(r,\"\",' \" ');var i=P([],o.match(/\"/g)).length;n=o!==o.toLowerCase()||i>2}else{n=true}if(n){ne(String.prototype,e,Ln[e])}});var Fn=function(){if(!oe){return false}var e=typeof JSON===\"object\"&&typeof JSON.stringify===\"function\"?JSON.stringify:null;if(!e){return false}if(typeof e($())!==\"undefined\"){return true}if(e([$()])!==\"[null]\"){return true}var t={a:$()};t[$()]=true;if(e(t)!==\"{}\"){return true}return false}();var Dn=a(function(){if(!oe){return true}return JSON.stringify(Object($()))===\"{}\"&&JSON.stringify([Object($())])===\"[{}]\"});if(Fn||!Dn){var zn=JSON.stringify;ne(JSON,\"stringify\",function stringify(e){if(typeof e===\"symbol\"){return}var n;if(arguments.length>1){n=arguments[1]}var o=[e];if(!r(n)){var i=ce.IsCallable(n)?n:null;var a=function(e,r){var n=i?t(i,this,e,r):r;if(typeof n!==\"symbol\"){if(re.symbol(n)){return Nt({})(n)}else{return n}}};o.push(a)}else{o.push(n)}if(arguments.length>2){o.push(arguments[2])}return zn.apply(this,o)})}return S});\n//# sourceMappingURL=es6-shim.map\n/*! jQuery v3.3.1 | (c) JS Foundation and other contributors | jquery.org/license */\n!function(e,t){\"use strict\";\"object\"==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){\"use strict\";var n=[],r=e.document,i=Object.getPrototypeOf,o=n.slice,a=n.concat,s=n.push,u=n.indexOf,l={},c=l.toString,f=l.hasOwnProperty,p=f.toString,d=p.call(Object),h={},g=function e(t){return\"function\"==typeof t&&\"number\"!=typeof t.nodeType},y=function e(t){return null!=t&&t===t.window},v={type:!0,src:!0,noModule:!0};function m(e,t,n){var i,o=(t=t||r).createElement(\"script\");if(o.text=e,n)for(i in v)n[i]&&(o[i]=n[i]);t.head.appendChild(o).parentNode.removeChild(o)}function x(e){return null==e?e+\"\":\"object\"==typeof e||\"function\"==typeof e?l[c.call(e)]||\"object\":typeof e}var b=\"3.3.1\",w=function(e,t){return new w.fn.init(e,t)},T=/^[\\s\\uFEFF\\xA0]+|[\\s\\uFEFF\\xA0]+$/g;w.fn=w.prototype={jquery:\"3.3.1\",constructor:w,length:0,toArray:function(){return o.call(this)},get:function(e){return null==e?o.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=w.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return w.each(this,e)},map:function(e){return this.pushStack(w.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(o.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:s,sort:n.sort,splice:n.splice},w.extend=w.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for(\"boolean\"==typeof a&&(l=a,a=arguments[s]||{},s++),\"object\"==typeof a||g(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)n=a[t],a!==(r=e[t])&&(l&&r&&(w.isPlainObject(r)||(i=Array.isArray(r)))?(i?(i=!1,o=n&&Array.isArray(n)?n:[]):o=n&&w.isPlainObject(n)?n:{},a[t]=w.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},w.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]\"!==c.call(e))&&(!(t=i(e))||\"function\"==typeof(n=f.call(t,\"constructor\")&&t.constructor)&&p.call(n)===d)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e){m(e)},each:function(e,t){var n,r=0;if(C(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}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(T,\"\")},makeArray:function(e,t){var n=t||[];return null!=e&&(C(Object(e))?w.merge(n,\"string\"==typeof e?[e]:e):s.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:u.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=[],o=0,a=e.length,s=!n;o<a;o++)(r=!t(e[o],o))!==s&&i.push(e[o]);return i},map:function(e,t,n){var r,i,o=0,s=[];if(C(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&s.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&s.push(i);return a.apply([],s)},guid:1,support:h}),\"function\"==typeof Symbol&&(w.fn[Symbol.iterator]=n[Symbol.iterator]),w.each(\"Boolean Number String Function Array Date RegExp Object Error Symbol\".split(\" \"),function(e,t){l[\"[object \"+t+\"]\"]=t.toLowerCase()});function C(e){var t=!!e&&\"length\"in e&&e.length,n=x(e);return!g(e)&&!y(e)&&(\"array\"===n||0===t||\"number\"==typeof t&&t>0&&t-1 in e)}var E=function(e){var t,n,r,i,o,a,s,u,l,c,f,p,d,h,g,y,v,m,x,b=\"sizzle\"+1*new Date,w=e.document,T=0,C=0,E=ae(),k=ae(),S=ae(),D=function(e,t){return e===t&&(f=!0),0},N={}.hasOwnProperty,A=[],j=A.pop,q=A.push,L=A.push,H=A.slice,O=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},P=\"checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped\",M=\"[\\\\x20\\\\t\\\\r\\\\n\\\\f]\",R=\"(?:\\\\\\\\.|[\\\\w-]|[^\\0-\\\\xa0])+\",I=\"\\\\[\"+M+\"*(\"+R+\")(?:\"+M+\"*([*^$|!~]?=)\"+M+\"*(?:'((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\"|(\"+R+\"))|)\"+M+\"*\\\\]\",W=\":(\"+R+\")(?:\\\\((('((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\")|((?:\\\\\\\\.|[^\\\\\\\\()[\\\\]]|\"+I+\")*)|.*)\\\\)|)\",$=new RegExp(M+\"+\",\"g\"),B=new RegExp(\"^\"+M+\"+|((?:^|[^\\\\\\\\])(?:\\\\\\\\.)*)\"+M+\"+$\",\"g\"),F=new RegExp(\"^\"+M+\"*,\"+M+\"*\"),_=new RegExp(\"^\"+M+\"*([>+~]|\"+M+\")\"+M+\"*\"),z=new RegExp(\"=\"+M+\"*([^\\\\]'\\\"]*?)\"+M+\"*\\\\]\",\"g\"),X=new RegExp(W),U=new RegExp(\"^\"+R+\"$\"),V={ID:new RegExp(\"^#(\"+R+\")\"),CLASS:new RegExp(\"^\\\\.(\"+R+\")\"),TAG:new RegExp(\"^(\"+R+\"|[*])\"),ATTR:new RegExp(\"^\"+I),PSEUDO:new RegExp(\"^\"+W),CHILD:new RegExp(\"^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\\\(\"+M+\"*(even|odd|(([+-]|)(\\\\d*)n|)\"+M+\"*(?:([+-]|)\"+M+\"*(\\\\d+)|))\"+M+\"*\\\\)|)\",\"i\"),bool:new RegExp(\"^(?:\"+P+\")$\",\"i\"),needsContext:new RegExp(\"^\"+M+\"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\\\(\"+M+\"*((?:-\\\\d)?\\\\d*)\"+M+\"*\\\\)|)(?=[^-]|$)\",\"i\")},G=/^(?:input|select|textarea|button)$/i,Y=/^h\\d$/i,Q=/^[^{]+\\{\\s*\\[native \\w/,J=/^(?:#([\\w-]+)|(\\w+)|\\.([\\w-]+))$/,K=/[+~]/,Z=new RegExp(\"\\\\\\\\([\\\\da-f]{1,6}\"+M+\"?|(\"+M+\")|.)\",\"ig\"),ee=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)},te=/([\\0-\\x1f\\x7f]|^-?\\d)|^-$|[^\\0-\\x1f\\x7f-\\uFFFF\\w-]/g,ne=function(e,t){return t?\"\\0\"===e?\"\\ufffd\":e.slice(0,-1)+\"\\\\\"+e.charCodeAt(e.length-1).toString(16)+\" \":\"\\\\\"+e},re=function(){p()},ie=me(function(e){return!0===e.disabled&&(\"form\"in e||\"label\"in e)},{dir:\"parentNode\",next:\"legend\"});try{L.apply(A=H.call(w.childNodes),w.childNodes),A[w.childNodes.length].nodeType}catch(e){L={apply:A.length?function(e,t){q.apply(e,H.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function oe(e,t,r,i){var o,s,l,c,f,h,v,m=t&&t.ownerDocument,T=t?t.nodeType:9;if(r=r||[],\"string\"!=typeof e||!e||1!==T&&9!==T&&11!==T)return r;if(!i&&((t?t.ownerDocument||t:w)!==d&&p(t),t=t||d,g)){if(11!==T&&(f=J.exec(e)))if(o=f[1]){if(9===T){if(!(l=t.getElementById(o)))return r;if(l.id===o)return r.push(l),r}else if(m&&(l=m.getElementById(o))&&x(t,l)&&l.id===o)return r.push(l),r}else{if(f[2])return L.apply(r,t.getElementsByTagName(e)),r;if((o=f[3])&&n.getElementsByClassName&&t.getElementsByClassName)return L.apply(r,t.getElementsByClassName(o)),r}if(n.qsa&&!S[e+\" \"]&&(!y||!y.test(e))){if(1!==T)m=t,v=e;else if(\"object\"!==t.nodeName.toLowerCase()){(c=t.getAttribute(\"id\"))?c=c.replace(te,ne):t.setAttribute(\"id\",c=b),s=(h=a(e)).length;while(s--)h[s]=\"#\"+c+\" \"+ve(h[s]);v=h.join(\",\"),m=K.test(e)&&ge(t.parentNode)||t}if(v)try{return L.apply(r,m.querySelectorAll(v)),r}catch(e){}finally{c===b&&t.removeAttribute(\"id\")}}}return u(e.replace(B,\"$1\"),t,r,i)}function ae(){var e=[];function t(n,i){return e.push(n+\" \")>r.cacheLength&&delete t[e.shift()],t[n+\" \"]=i}return t}function se(e){return e[b]=!0,e}function ue(e){var t=d.createElement(\"fieldset\");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function le(e,t){var n=e.split(\"|\"),i=n.length;while(i--)r.attrHandle[n[i]]=t}function ce(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function fe(e){return function(t){return\"input\"===t.nodeName.toLowerCase()&&t.type===e}}function pe(e){return function(t){var n=t.nodeName.toLowerCase();return(\"input\"===n||\"button\"===n)&&t.type===e}}function de(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&&ie(t)===e:t.disabled===e:\"label\"in t&&t.disabled===e}}function he(e){return se(function(t){return t=+t,se(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function ge(e){return e&&\"undefined\"!=typeof e.getElementsByTagName&&e}n=oe.support={},o=oe.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&\"HTML\"!==t.nodeName},p=oe.setDocument=function(e){var t,i,a=e?e.ownerDocument||e:w;return a!==d&&9===a.nodeType&&a.documentElement?(d=a,h=d.documentElement,g=!o(d),w!==d&&(i=d.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener(\"unload\",re,!1):i.attachEvent&&i.attachEvent(\"onunload\",re)),n.attributes=ue(function(e){return e.className=\"i\",!e.getAttribute(\"className\")}),n.getElementsByTagName=ue(function(e){return e.appendChild(d.createComment(\"\")),!e.getElementsByTagName(\"*\").length}),n.getElementsByClassName=Q.test(d.getElementsByClassName),n.getById=ue(function(e){return h.appendChild(e).id=b,!d.getElementsByName||!d.getElementsByName(b).length}),n.getById?(r.filter.ID=function(e){var t=e.replace(Z,ee);return function(e){return e.getAttribute(\"id\")===t}},r.find.ID=function(e,t){if(\"undefined\"!=typeof t.getElementById&&g){var n=t.getElementById(e);return n?[n]:[]}}):(r.filter.ID=function(e){var t=e.replace(Z,ee);return function(e){var n=\"undefined\"!=typeof e.getAttributeNode&&e.getAttributeNode(\"id\");return n&&n.value===t}},r.find.ID=function(e,t){if(\"undefined\"!=typeof t.getElementById&&g){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode(\"id\"))&&n.value===e)return[o]}return[]}}),r.find.TAG=n.getElementsByTagName?function(e,t){return\"undefined\"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if(\"*\"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},r.find.CLASS=n.getElementsByClassName&&function(e,t){if(\"undefined\"!=typeof t.getElementsByClassName&&g)return t.getElementsByClassName(e)},v=[],y=[],(n.qsa=Q.test(d.querySelectorAll))&&(ue(function(e){h.appendChild(e).innerHTML=\"<a id='\"+b+\"'></a><select id='\"+b+\"-\\r\\\\' msallowcapture=''><option selected=''></option></select>\",e.querySelectorAll(\"[msallowcapture^='']\").length&&y.push(\"[*^$]=\"+M+\"*(?:''|\\\"\\\")\"),e.querySelectorAll(\"[selected]\").length||y.push(\"\\\\[\"+M+\"*(?:value|\"+P+\")\"),e.querySelectorAll(\"[id~=\"+b+\"-]\").length||y.push(\"~=\"),e.querySelectorAll(\":checked\").length||y.push(\":checked\"),e.querySelectorAll(\"a#\"+b+\"+*\").length||y.push(\".#.+[+~]\")}),ue(function(e){e.innerHTML=\"<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>\";var t=d.createElement(\"input\");t.setAttribute(\"type\",\"hidden\"),e.appendChild(t).setAttribute(\"name\",\"D\"),e.querySelectorAll(\"[name=d]\").length&&y.push(\"name\"+M+\"*[*^$|!~]?=\"),2!==e.querySelectorAll(\":enabled\").length&&y.push(\":enabled\",\":disabled\"),h.appendChild(e).disabled=!0,2!==e.querySelectorAll(\":disabled\").length&&y.push(\":enabled\",\":disabled\"),e.querySelectorAll(\"*,:x\"),y.push(\",.*:\")})),(n.matchesSelector=Q.test(m=h.matches||h.webkitMatchesSelector||h.mozMatchesSelector||h.oMatchesSelector||h.msMatchesSelector))&&ue(function(e){n.disconnectedMatch=m.call(e,\"*\"),m.call(e,\"[s!='']:x\"),v.push(\"!=\",W)}),y=y.length&&new RegExp(y.join(\"|\")),v=v.length&&new RegExp(v.join(\"|\")),t=Q.test(h.compareDocumentPosition),x=t||Q.test(h.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)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return f=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===r?e===d||e.ownerDocument===w&&x(w,e)?-1:t===d||t.ownerDocument===w&&x(w,t)?1:c?O(c,e)-O(c,t):0:4&r?-1:1)}:function(e,t){if(e===t)return f=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===d?-1:t===d?1:i?-1:o?1:c?O(c,e)-O(c,t):0;if(i===o)return ce(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?ce(a[r],s[r]):a[r]===w?-1:s[r]===w?1:0},d):d},oe.matches=function(e,t){return oe(e,null,null,t)},oe.matchesSelector=function(e,t){if((e.ownerDocument||e)!==d&&p(e),t=t.replace(z,\"='$1']\"),n.matchesSelector&&g&&!S[t+\" \"]&&(!v||!v.test(t))&&(!y||!y.test(t)))try{var r=m.call(e,t);if(r||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){}return oe(t,d,null,[e]).length>0},oe.contains=function(e,t){return(e.ownerDocument||e)!==d&&p(e),x(e,t)},oe.attr=function(e,t){(e.ownerDocument||e)!==d&&p(e);var i=r.attrHandle[t.toLowerCase()],o=i&&N.call(r.attrHandle,t.toLowerCase())?i(e,t,!g):void 0;return void 0!==o?o:n.attributes||!g?e.getAttribute(t):(o=e.getAttributeNode(t))&&o.specified?o.value:null},oe.escape=function(e){return(e+\"\").replace(te,ne)},oe.error=function(e){throw new Error(\"Syntax error, unrecognized expression: \"+e)},oe.uniqueSort=function(e){var t,r=[],i=0,o=0;if(f=!n.detectDuplicates,c=!n.sortStable&&e.slice(0),e.sort(D),f){while(t=e[o++])t===e[o]&&(i=r.push(o));while(i--)e.splice(r[i],1)}return c=null,e},i=oe.getText=function(e){var t,n=\"\",r=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if(\"string\"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=i(e)}else if(3===o||4===o)return e.nodeValue}else while(t=e[r++])n+=i(t);return n},(r=oe.selectors={cacheLength:50,createPseudo:se,match:V,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(Z,ee),e[3]=(e[3]||e[4]||e[5]||\"\").replace(Z,ee),\"~=\"===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]||oe.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]&&oe.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return V.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||\"\":n&&X.test(n)&&(t=a(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(Z,ee).toLowerCase();return\"*\"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=E[e+\" \"];return t||(t=new RegExp(\"(^|\"+M+\")\"+e+\"(\"+M+\"|$)\"))&&E(e,function(e){return t.test(\"string\"==typeof e.className&&e.className||\"undefined\"!=typeof e.getAttribute&&e.getAttribute(\"class\")||\"\")})},ATTR:function(e,t,n){return function(r){var i=oe.attr(r,e);return null==i?\"!=\"===t:!t||(i+=\"\",\"=\"===t?i===n:\"!=\"===t?i!==n:\"^=\"===t?n&&0===i.indexOf(n):\"*=\"===t?n&&i.indexOf(n)>-1:\"$=\"===t?n&&i.slice(-n.length)===n:\"~=\"===t?(\" \"+i.replace($,\" \")+\" \").indexOf(n)>-1:\"|=\"===t&&(i===n||i.slice(0,n.length+1)===n+\"-\"))}},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 l,c,f,p,d,h,g=o!==a?\"nextSibling\":\"previousSibling\",y=t.parentNode,v=s&&t.nodeName.toLowerCase(),m=!u&&!s,x=!1;if(y){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===v:1===p.nodeType)return!1;h=g=\"only\"===e&&!h&&\"nextSibling\"}return!0}if(h=[a?y.firstChild:y.lastChild],a&&m){x=(d=(l=(c=(f=(p=y)[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]||[])[0]===T&&l[1])&&l[2],p=d&&y.childNodes[d];while(p=++d&&p&&p[g]||(x=d=0)||h.pop())if(1===p.nodeType&&++x&&p===t){c[e]=[T,d,x];break}}else if(m&&(x=d=(l=(c=(f=(p=t)[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]||[])[0]===T&&l[1]),!1===x)while(p=++d&&p&&p[g]||(x=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===v:1===p.nodeType)&&++x&&(m&&((c=(f=p[b]||(p[b]={}))[p.uniqueID]||(f[p.uniqueID]={}))[e]=[T,x]),p===t))break;return(x-=i)===r||x%r==0&&x/r>=0}}},PSEUDO:function(e,t){var n,i=r.pseudos[e]||r.setFilters[e.toLowerCase()]||oe.error(\"unsupported pseudo: \"+e);return i[b]?i(t):i.length>1?(n=[e,e,\"\",t],r.setFilters.hasOwnProperty(e.toLowerCase())?se(function(e,n){var r,o=i(e,t),a=o.length;while(a--)e[r=O(e,o[a])]=!(n[r]=o[a])}):function(e){return i(e,0,n)}):i}},pseudos:{not:se(function(e){var t=[],n=[],r=s(e.replace(B,\"$1\"));return r[b]?se(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),t[0]=null,!n.pop()}}),has:se(function(e){return function(t){return oe(e,t).length>0}}),contains:se(function(e){return e=e.replace(Z,ee),function(t){return(t.textContent||t.innerText||i(t)).indexOf(e)>-1}}),lang:se(function(e){return U.test(e||\"\")||oe.error(\"unsupported lang: \"+e),e=e.replace(Z,ee).toLowerCase(),function(t){var n;do{if(n=g?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===h},focus:function(e){return e===d.activeElement&&(!d.hasFocus||d.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:de(!1),disabled:de(!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!r.pseudos.empty(e)},header:function(e){return Y.test(e.nodeName)},input:function(e){return G.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:he(function(){return[0]}),last:he(function(e,t){return[t-1]}),eq:he(function(e,t,n){return[n<0?n+t:n]}),even:he(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:he(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:he(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:he(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=r.pseudos.eq;for(t in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[t]=fe(t);for(t in{submit:!0,reset:!0})r.pseudos[t]=pe(t);function ye(){}ye.prototype=r.filters=r.pseudos,r.setFilters=new ye,a=oe.tokenize=function(e,t){var n,i,o,a,s,u,l,c=k[e+\" \"];if(c)return t?0:c.slice(0);s=e,u=[],l=r.preFilter;while(s){n&&!(i=F.exec(s))||(i&&(s=s.slice(i[0].length)||s),u.push(o=[])),n=!1,(i=_.exec(s))&&(n=i.shift(),o.push({value:n,type:i[0].replace(B,\" \")}),s=s.slice(n.length));for(a in r.filter)!(i=V[a].exec(s))||l[a]&&!(i=l[a](i))||(n=i.shift(),o.push({value:n,type:a,matches:i}),s=s.slice(n.length));if(!n)break}return t?s.length:s?oe.error(e):k(e,u).slice(0)};function ve(e){for(var t=0,n=e.length,r=\"\";t<n;t++)r+=e[t].value;return r}function me(e,t,n){var r=t.dir,i=t.next,o=i||r,a=n&&\"parentNode\"===o,s=C++;return t.first?function(t,n,i){while(t=t[r])if(1===t.nodeType||a)return e(t,n,i);return!1}:function(t,n,u){var l,c,f,p=[T,s];if(u){while(t=t[r])if((1===t.nodeType||a)&&e(t,n,u))return!0}else while(t=t[r])if(1===t.nodeType||a)if(f=t[b]||(t[b]={}),c=f[t.uniqueID]||(f[t.uniqueID]={}),i&&i===t.nodeName.toLowerCase())t=t[r]||t;else{if((l=c[o])&&l[0]===T&&l[1]===s)return p[2]=l[2];if(c[o]=p,p[2]=e(t,n,u))return!0}return!1}}function xe(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function be(e,t,n){for(var r=0,i=t.length;r<i;r++)oe(e,t[r],n);return n}function we(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Te(e,t,n,r,i,o){return r&&!r[b]&&(r=Te(r)),i&&!i[b]&&(i=Te(i,o)),se(function(o,a,s,u){var l,c,f,p=[],d=[],h=a.length,g=o||be(t||\"*\",s.nodeType?[s]:s,[]),y=!e||!o&&t?g:we(g,p,e,s,u),v=n?i||(o?e:h||r)?[]:a:y;if(n&&n(y,v,s,u),r){l=we(v,d),r(l,[],s,u),c=l.length;while(c--)(f=l[c])&&(v[d[c]]=!(y[d[c]]=f))}if(o){if(i||e){if(i){l=[],c=v.length;while(c--)(f=v[c])&&l.push(y[c]=f);i(null,v=[],l,u)}c=v.length;while(c--)(f=v[c])&&(l=i?O(o,f):p[c])>-1&&(o[l]=!(a[l]=f))}}else v=we(v===a?v.splice(h,v.length):v),i?i(null,a,v,u):L.apply(a,v)})}function Ce(e){for(var t,n,i,o=e.length,a=r.relative[e[0].type],s=a||r.relative[\" \"],u=a?1:0,c=me(function(e){return e===t},s,!0),f=me(function(e){return O(t,e)>-1},s,!0),p=[function(e,n,r){var i=!a&&(r||n!==l)||((t=n).nodeType?c(e,n,r):f(e,n,r));return t=null,i}];u<o;u++)if(n=r.relative[e[u].type])p=[me(xe(p),n)];else{if((n=r.filter[e[u].type].apply(null,e[u].matches))[b]){for(i=++u;i<o;i++)if(r.relative[e[i].type])break;return Te(u>1&&xe(p),u>1&&ve(e.slice(0,u-1).concat({value:\" \"===e[u-2].type?\"*\":\"\"})).replace(B,\"$1\"),n,u<i&&Ce(e.slice(u,i)),i<o&&Ce(e=e.slice(i)),i<o&&ve(e))}p.push(n)}return xe(p)}function Ee(e,t){var n=t.length>0,i=e.length>0,o=function(o,a,s,u,c){var f,h,y,v=0,m=\"0\",x=o&&[],b=[],w=l,C=o||i&&r.find.TAG(\"*\",c),E=T+=null==w?1:Math.random()||.1,k=C.length;for(c&&(l=a===d||a||c);m!==k&&null!=(f=C[m]);m++){if(i&&f){h=0,a||f.ownerDocument===d||(p(f),s=!g);while(y=e[h++])if(y(f,a||d,s)){u.push(f);break}c&&(T=E)}n&&((f=!y&&f)&&v--,o&&x.push(f))}if(v+=m,n&&m!==v){h=0;while(y=t[h++])y(x,b,a,s);if(o){if(v>0)while(m--)x[m]||b[m]||(b[m]=j.call(u));b=we(b)}L.apply(u,b),c&&!o&&b.length>0&&v+t.length>1&&oe.uniqueSort(u)}return c&&(T=E,l=w),x};return n?se(o):o}return s=oe.compile=function(e,t){var n,r=[],i=[],o=S[e+\" \"];if(!o){t||(t=a(e)),n=t.length;while(n--)(o=Ce(t[n]))[b]?r.push(o):i.push(o);(o=S(e,Ee(i,r))).selector=e}return o},u=oe.select=function(e,t,n,i){var o,u,l,c,f,p=\"function\"==typeof e&&e,d=!i&&a(e=p.selector||e);if(n=n||[],1===d.length){if((u=d[0]=d[0].slice(0)).length>2&&\"ID\"===(l=u[0]).type&&9===t.nodeType&&g&&r.relative[u[1].type]){if(!(t=(r.find.ID(l.matches[0].replace(Z,ee),t)||[])[0]))return n;p&&(t=t.parentNode),e=e.slice(u.shift().value.length)}o=V.needsContext.test(e)?0:u.length;while(o--){if(l=u[o],r.relative[c=l.type])break;if((f=r.find[c])&&(i=f(l.matches[0].replace(Z,ee),K.test(u[0].type)&&ge(t.parentNode)||t))){if(u.splice(o,1),!(e=i.length&&ve(u)))return L.apply(n,i),n;break}}}return(p||s(e,d))(i,t,!g,n,!t||K.test(e)&&ge(t.parentNode)||t),n},n.sortStable=b.split(\"\").sort(D).join(\"\")===b,n.detectDuplicates=!!f,p(),n.sortDetached=ue(function(e){return 1&e.compareDocumentPosition(d.createElement(\"fieldset\"))}),ue(function(e){return e.innerHTML=\"<a href='#'></a>\",\"#\"===e.firstChild.getAttribute(\"href\")})||le(\"type|href|height|width\",function(e,t,n){if(!n)return e.getAttribute(t,\"type\"===t.toLowerCase()?1:2)}),n.attributes&&ue(function(e){return e.innerHTML=\"<input/>\",e.firstChild.setAttribute(\"value\",\"\"),\"\"===e.firstChild.getAttribute(\"value\")})||le(\"value\",function(e,t,n){if(!n&&\"input\"===e.nodeName.toLowerCase())return e.defaultValue}),ue(function(e){return null==e.getAttribute(\"disabled\")})||le(P,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),oe}(e);w.find=E,w.expr=E.selectors,w.expr[\":\"]=w.expr.pseudos,w.uniqueSort=w.unique=E.uniqueSort,w.text=E.getText,w.isXMLDoc=E.isXML,w.contains=E.contains,w.escapeSelector=E.escape;var k=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&w(e).is(n))break;r.push(e)}return r},S=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},D=w.expr.match.needsContext;function N(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var A=/^<([a-z][^\\/\\0>:\\x20\\t\\r\\n\\f]*)[\\x20\\t\\r\\n\\f]*\\/?>(?:<\\/\\1>|)$/i;function j(e,t,n){return g(t)?w.grep(e,function(e,r){return!!t.call(e,r,e)!==n}):t.nodeType?w.grep(e,function(e){return e===t!==n}):\"string\"!=typeof t?w.grep(e,function(e){return u.call(t,e)>-1!==n}):w.filter(t,e,n)}w.filter=function(e,t,n){var r=t[0];return n&&(e=\":not(\"+e+\")\"),1===t.length&&1===r.nodeType?w.find.matchesSelector(r,e)?[r]:[]:w.find.matches(e,w.grep(t,function(e){return 1===e.nodeType}))},w.fn.extend({find:function(e){var t,n,r=this.length,i=this;if(\"string\"!=typeof e)return this.pushStack(w(e).filter(function(){for(t=0;t<r;t++)if(w.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)w.find(e,i[t],n);return r>1?w.uniqueSort(n):n},filter:function(e){return this.pushStack(j(this,e||[],!1))},not:function(e){return this.pushStack(j(this,e||[],!0))},is:function(e){return!!j(this,\"string\"==typeof e&&D.test(e)?w(e):e||[],!1).length}});var q,L=/^(?:\\s*(<[\\w\\W]+>)[^>]*|#([\\w-]+))$/;(w.fn.init=function(e,t,n){var i,o;if(!e)return this;if(n=n||q,\"string\"==typeof e){if(!(i=\"<\"===e[0]&&\">\"===e[e.length-1]&&e.length>=3?[null,e,null]:L.exec(e))||!i[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(i[1]){if(t=t instanceof w?t[0]:t,w.merge(this,w.parseHTML(i[1],t&&t.nodeType?t.ownerDocument||t:r,!0)),A.test(i[1])&&w.isPlainObject(t))for(i in t)g(this[i])?this[i](t[i]):this.attr(i,t[i]);return this}return(o=r.getElementById(i[2]))&&(this[0]=o,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):g(e)?void 0!==n.ready?n.ready(e):e(w):w.makeArray(e,this)}).prototype=w.fn,q=w(r);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};w.fn.extend({has:function(e){var t=w(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(w.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a=\"string\"!=typeof e&&w(e);if(!D.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&&w.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?w.uniqueSort(o):o)},index:function(e){return e?\"string\"==typeof e?u.call(w(e),this[0]):u.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(w.uniqueSort(w.merge(this.get(),w(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}});function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}w.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return k(e,\"parentNode\")},parentsUntil:function(e,t,n){return k(e,\"parentNode\",n)},next:function(e){return P(e,\"nextSibling\")},prev:function(e){return P(e,\"previousSibling\")},nextAll:function(e){return k(e,\"nextSibling\")},prevAll:function(e){return k(e,\"previousSibling\")},nextUntil:function(e,t,n){return k(e,\"nextSibling\",n)},prevUntil:function(e,t,n){return k(e,\"previousSibling\",n)},siblings:function(e){return S((e.parentNode||{}).firstChild,e)},children:function(e){return S(e.firstChild)},contents:function(e){return N(e,\"iframe\")?e.contentDocument:(N(e,\"template\")&&(e=e.content||e),w.merge([],e.childNodes))}},function(e,t){w.fn[e]=function(n,r){var i=w.map(this,t,n);return\"Until\"!==e.slice(-5)&&(r=n),r&&\"string\"==typeof r&&(i=w.filter(r,i)),this.length>1&&(O[e]||w.uniqueSort(i),H.test(e)&&i.reverse()),this.pushStack(i)}});var M=/[^\\x20\\t\\r\\n\\f]+/g;function R(e){var t={};return w.each(e.match(M)||[],function(e,n){t[n]=!0}),t}w.Callbacks=function(e){e=\"string\"==typeof e?R(e):w.extend({},e);var t,n,r,i,o=[],a=[],s=-1,u=function(){for(i=i||e.once,r=t=!0;a.length;s=-1){n=a.shift();while(++s<o.length)!1===o[s].apply(n[0],n[1])&&e.stopOnFalse&&(s=o.length,n=!1)}e.memory||(n=!1),t=!1,i&&(o=n?[]:\"\")},l={add:function(){return o&&(n&&!t&&(s=o.length-1,a.push(n)),function t(n){w.each(n,function(n,r){g(r)?e.unique&&l.has(r)||o.push(r):r&&r.length&&\"string\"!==x(r)&&t(r)})}(arguments),n&&!t&&u()),this},remove:function(){return w.each(arguments,function(e,t){var n;while((n=w.inArray(t,o,n))>-1)o.splice(n,1),n<=s&&s--}),this},has:function(e){return e?w.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n=\"\",this},disabled:function(){return!o},lock:function(){return i=a=[],n||t||(o=n=\"\"),this},locked:function(){return!!i},fireWith:function(e,n){return i||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||u()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!r}};return l};function I(e){return e}function W(e){throw e}function $(e,t,n,r){var i;try{e&&g(i=e.promise)?i.call(e).done(t).fail(n):e&&g(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}w.extend({Deferred:function(t){var n=[[\"notify\",\"progress\",w.Callbacks(\"memory\"),w.Callbacks(\"memory\"),2],[\"resolve\",\"done\",w.Callbacks(\"once memory\"),w.Callbacks(\"once memory\"),0,\"resolved\"],[\"reject\",\"fail\",w.Callbacks(\"once memory\"),w.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 w.Deferred(function(t){w.each(n,function(n,r){var i=g(e[r[4]])&&e[r[4]];o[r[1]](function(){var e=i&&i.apply(this,arguments);e&&g(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){var o=0;function a(t,n,r,i){return function(){var s=this,u=arguments,l=function(){var e,l;if(!(t<o)){if((e=r.apply(s,u))===n.promise())throw new TypeError(\"Thenable self-resolution\");l=e&&(\"object\"==typeof e||\"function\"==typeof e)&&e.then,g(l)?i?l.call(e,a(o,n,I,i),a(o,n,W,i)):(o++,l.call(e,a(o,n,I,i),a(o,n,W,i),a(o,n,I,n.notifyWith))):(r!==I&&(s=void 0,u=[e]),(i||n.resolveWith)(s,u))}},c=i?l:function(){try{l()}catch(e){w.Deferred.exceptionHook&&w.Deferred.exceptionHook(e,c.stackTrace),t+1>=o&&(r!==W&&(s=void 0,u=[e]),n.rejectWith(s,u))}};t?c():(w.Deferred.getStackHook&&(c.stackTrace=w.Deferred.getStackHook()),e.setTimeout(c))}}return w.Deferred(function(e){n[0][3].add(a(0,e,g(i)?i:I,e.notifyWith)),n[1][3].add(a(0,e,g(t)?t:I)),n[2][3].add(a(0,e,g(r)?r:W))}).promise()},promise:function(e){return null!=e?w.extend(e,i):i}},o={};return w.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=o.call(arguments),a=w.Deferred(),s=function(e){return function(n){r[e]=this,i[e]=arguments.length>1?o.call(arguments):n,--t||a.resolveWith(r,i)}};if(t<=1&&($(e,a.done(s(n)).resolve,a.reject,!t),\"pending\"===a.state()||g(i[n]&&i[n].then)))return a.then();while(n--)$(i[n],s(n),a.reject);return a.promise()}});var B=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;w.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&B.test(t.name)&&e.console.warn(\"jQuery.Deferred exception: \"+t.message,t.stack,n)},w.readyException=function(t){e.setTimeout(function(){throw t})};var F=w.Deferred();w.fn.ready=function(e){return F.then(e)[\"catch\"](function(e){w.readyException(e)}),this},w.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--w.readyWait:w.isReady)||(w.isReady=!0,!0!==e&&--w.readyWait>0||F.resolveWith(r,[w]))}}),w.ready.then=F.then;function _(){r.removeEventListener(\"DOMContentLoaded\",_),e.removeEventListener(\"load\",_),w.ready()}\"complete\"===r.readyState||\"loading\"!==r.readyState&&!r.documentElement.doScroll?e.setTimeout(w.ready):(r.addEventListener(\"DOMContentLoaded\",_),e.addEventListener(\"load\",_));var z=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if(\"object\"===x(n)){i=!0;for(s in n)z(e,t,s,n[s],!0,o,a)}else if(void 0!==r&&(i=!0,g(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(w(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},X=/^-ms-/,U=/-([a-z])/g;function V(e,t){return t.toUpperCase()}function G(e){return e.replace(X,\"ms-\").replace(U,V)}var Y=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function Q(){this.expando=w.expando+Q.uid++}Q.uid=1,Q.prototype={cache:function(e){var t=e[this.expando];return t||(t={},Y(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[G(t)]=n;else for(r in t)i[G(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][G(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){n=(t=Array.isArray(t)?t.map(G):(t=G(t))in r?[t]:t.match(M)||[]).length;while(n--)delete r[t[n]]}(void 0===t||w.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&&!w.isEmptyObject(t)}};var J=new Q,K=new Q,Z=/^(?:\\{[\\w\\W]*\\}|\\[[\\w\\W]*\\])$/,ee=/[A-Z]/g;function te(e){return\"true\"===e||\"false\"!==e&&(\"null\"===e?null:e===+e+\"\"?+e:Z.test(e)?JSON.parse(e):e)}function ne(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r=\"data-\"+t.replace(ee,\"-$&\").toLowerCase(),\"string\"==typeof(n=e.getAttribute(r))){try{n=te(n)}catch(e){}K.set(e,t,n)}else n=void 0;return n}w.extend({hasData:function(e){return K.hasData(e)||J.hasData(e)},data:function(e,t,n){return K.access(e,t,n)},removeData:function(e,t){K.remove(e,t)},_data:function(e,t,n){return J.access(e,t,n)},_removeData:function(e,t){J.remove(e,t)}}),w.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=K.get(o),1===o.nodeType&&!J.get(o,\"hasDataAttrs\"))){n=a.length;while(n--)a[n]&&0===(r=a[n].name).indexOf(\"data-\")&&(r=G(r.slice(5)),ne(o,r,i[r]));J.set(o,\"hasDataAttrs\",!0)}return i}return\"object\"==typeof e?this.each(function(){K.set(this,e)}):z(this,function(t){var n;if(o&&void 0===t){if(void 0!==(n=K.get(o,e)))return n;if(void 0!==(n=ne(o,e)))return n}else this.each(function(){K.set(this,e,t)})},null,t,arguments.length>1,null,!0)},removeData:function(e){return this.each(function(){K.remove(this,e)})}}),w.extend({queue:function(e,t,n){var r;if(e)return t=(t||\"fx\")+\"queue\",r=J.get(e,t),n&&(!r||Array.isArray(n)?r=J.access(e,t,w.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||\"fx\";var n=w.queue(e,t),r=n.length,i=n.shift(),o=w._queueHooks(e,t),a=function(){w.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 J.get(e,n)||J.access(e,n,{empty:w.Callbacks(\"once memory\").add(function(){J.remove(e,[t+\"queue\",n])})})}}),w.fn.extend({queue:function(e,t){var n=2;return\"string\"!=typeof e&&(t=e,e=\"fx\",n--),arguments.length<n?w.queue(this[0],e):void 0===t?this:this.each(function(){var n=w.queue(this,e,t);w._queueHooks(this,e),\"fx\"===e&&\"inprogress\"!==n[0]&&w.dequeue(this,e)})},dequeue:function(e){return this.each(function(){w.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||\"fx\",[])},promise:function(e,t){var n,r=1,i=w.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};\"string\"!=typeof e&&(t=e,e=void 0),e=e||\"fx\";while(a--)(n=J.get(o[a],e+\"queueHooks\"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var re=/[+-]?(?:\\d*\\.|)\\d+(?:[eE][+-]?\\d+|)/.source,ie=new RegExp(\"^(?:([+-])=|)(\"+re+\")([a-z%]*)$\",\"i\"),oe=[\"Top\",\"Right\",\"Bottom\",\"Left\"],ae=function(e,t){return\"none\"===(e=t||e).style.display||\"\"===e.style.display&&w.contains(e.ownerDocument,e)&&\"none\"===w.css(e,\"display\")},se=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};function ue(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return w.css(e,t,\"\")},u=s(),l=n&&n[3]||(w.cssNumber[t]?\"\":\"px\"),c=(w.cssNumber[t]||\"px\"!==l&&+u)&&ie.exec(w.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)w.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,w.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var le={};function ce(e){var t,n=e.ownerDocument,r=e.nodeName,i=le[r];return i||(t=n.body.appendChild(n.createElement(r)),i=w.css(t,\"display\"),t.parentNode.removeChild(t),\"none\"===i&&(i=\"block\"),le[r]=i,i)}function fe(e,t){for(var n,r,i=[],o=0,a=e.length;o<a;o++)(r=e[o]).style&&(n=r.style.display,t?(\"none\"===n&&(i[o]=J.get(r,\"display\")||null,i[o]||(r.style.display=\"\")),\"\"===r.style.display&&ae(r)&&(i[o]=ce(r))):\"none\"!==n&&(i[o]=\"none\",J.set(r,\"display\",n)));for(o=0;o<a;o++)null!=i[o]&&(e[o].style.display=i[o]);return e}w.fn.extend({show:function(){return fe(this,!0)},hide:function(){return fe(this)},toggle:function(e){return\"boolean\"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?w(this).show():w(this).hide()})}});var pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]+)/i,he=/^$|^module$|\\/(?:java|ecma)script/i,ge={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,\"\",\"\"]};ge.optgroup=ge.option,ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td;function ye(e,t){var n;return n=\"undefined\"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||\"*\"):\"undefined\"!=typeof e.querySelectorAll?e.querySelectorAll(t||\"*\"):[],void 0===t||t&&N(e,t)?w.merge([e],n):n}function ve(e,t){for(var n=0,r=e.length;n<r;n++)J.set(e[n],\"globalEval\",!t||J.get(t[n],\"globalEval\"))}var me=/<|&#?\\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if(\"object\"===x(o))w.merge(p,o.nodeType?[o]:o);else if(me.test(o)){a=a||f.appendChild(t.createElement(\"div\")),s=(de.exec(o)||[\"\",\"\"])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+w.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;w.merge(p,a.childNodes),(a=f.firstChild).textContent=\"\"}else p.push(t.createTextNode(o));f.textContent=\"\",d=0;while(o=p[d++])if(r&&w.inArray(o,r)>-1)i&&i.push(o);else if(l=w.contains(o.ownerDocument,o),a=ye(f.appendChild(o),\"script\"),l&&ve(a),n){c=0;while(o=a[c++])he.test(o.type||\"\")&&n.push(o)}return f}!function(){var e=r.createDocumentFragment().appendChild(r.createElement(\"div\")),t=r.createElement(\"input\");t.setAttribute(\"type\",\"radio\"),t.setAttribute(\"checked\",\"checked\"),t.setAttribute(\"name\",\"t\"),e.appendChild(t),h.checkClone=e.cloneNode(!0).cloneNode(!0).lastChild.checked,e.innerHTML=\"<textarea>x</textarea>\",h.noCloneChecked=!!e.cloneNode(!0).lastChild.defaultValue}();var be=r.documentElement,we=/^key/,Te=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ce=/^([^.]*)(?:\\.(.+)|)/;function Ee(){return!0}function ke(){return!1}function Se(){try{return r.activeElement}catch(e){}}function De(e,t,n,r,i,o){var a,s;if(\"object\"==typeof t){\"string\"!=typeof n&&(r=r||n,n=void 0);for(s in t)De(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=ke;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return w().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=w.guid++)),e.each(function(){w.event.add(this,t,i,r,n)})}w.event={global:{},add:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,y=J.get(e);if(y){n.handler&&(n=(o=n).handler,i=o.selector),i&&w.find.matchesSelector(be,i),n.guid||(n.guid=w.guid++),(u=y.events)||(u=y.events={}),(a=y.handle)||(a=y.handle=function(t){return\"undefined\"!=typeof w&&w.event.triggered!==t.type?w.event.dispatch.apply(e,arguments):void 0}),l=(t=(t||\"\").match(M)||[\"\"]).length;while(l--)d=g=(s=Ce.exec(t[l])||[])[1],h=(s[2]||\"\").split(\".\").sort(),d&&(f=w.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=w.event.special[d]||{},c=w.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&w.expr.match.needsContext.test(i),namespace:h.join(\".\")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(e,r,h,a)||e.addEventListener&&e.addEventListener(d,a)),f.add&&(f.add.call(e,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),w.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,y=J.hasData(e)&&J.get(e);if(y&&(u=y.events)){l=(t=(t||\"\").match(M)||[\"\"]).length;while(l--)if(s=Ce.exec(t[l])||[],d=g=s[1],h=(s[2]||\"\").split(\".\").sort(),d){f=w.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp(\"(^|\\\\.)\"+h.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&(\"**\"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,y.handle)||w.removeEvent(e,d,y.handle),delete u[d])}else for(d in u)w.event.remove(e,d+t[l],n,r,!0);w.isEmptyObject(u)&&J.remove(e,\"handle events\")}},dispatch:function(e){var t=w.event.fix(e),n,r,i,o,a,s,u=new Array(arguments.length),l=(J.get(this,\"events\")||{})[t.type]||[],c=w.event.special[t.type]||{};for(u[0]=t,n=1;n<arguments.length;n++)u[n]=arguments[n];if(t.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,t)){s=w.event.handlers.call(this,t,l),n=0;while((o=s[n++])&&!t.isPropagationStopped()){t.currentTarget=o.elem,r=0;while((a=o.handlers[r++])&&!t.isImmediatePropagationStopped())t.rnamespace&&!t.rnamespace.test(a.namespace)||(t.handleObj=a,t.data=a.data,void 0!==(i=((w.event.special[a.origType]||{}).handle||a.handler).apply(o.elem,u))&&!1===(t.result=i)&&(t.preventDefault(),t.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,t),t.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!(\"click\"===e.type&&e.button>=1))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&(\"click\"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+\" \"]&&(a[i]=r.needsContext?w(i,this).index(l)>-1:w.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(e,t){Object.defineProperty(w.Event.prototype,e,{enumerable:!0,configurable:!0,get:g(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[w.expando]?e:new w.Event(e)},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==Se()&&this.focus)return this.focus(),!1},delegateType:\"focusin\"},blur:{trigger:function(){if(this===Se()&&this.blur)return this.blur(),!1},delegateType:\"focusout\"},click:{trigger:function(){if(\"checkbox\"===this.type&&this.click&&N(this,\"input\"))return this.click(),!1},_default:function(e){return N(e.target,\"a\")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},w.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},w.Event=function(e,t){if(!(this instanceof w.Event))return new w.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ee:ke,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&&w.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[w.expando]=!0},w.Event.prototype={constructor:w.Event,isDefaultPrevented:ke,isPropagationStopped:ke,isImmediatePropagationStopped:ke,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ee,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ee,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ee,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},w.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&&we.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Te.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},w.event.addProp),w.each({mouseenter:\"mouseover\",mouseleave:\"mouseout\",pointerenter:\"pointerover\",pointerleave:\"pointerout\"},function(e,t){w.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return i&&(i===r||w.contains(r,i))||(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),w.fn.extend({on:function(e,t,n,r){return De(this,e,t,n,r)},one:function(e,t,n,r){return De(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,w(e.delegateTarget).off(r.namespace?r.origType+\".\"+r.namespace:r.origType,r.selector,r.handler),this;if(\"object\"==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=ke),this.each(function(){w.event.remove(this,e,n,t)})}});var Ne=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)[^>]*)\\/>/gi,Ae=/<script|<style|<link/i,je=/checked\\s*(?:[^=]|=\\s*.checked.)/i,qe=/^\\s*<!(?:\\[CDATA\\[|--)|(?:\\]\\]|--)>\\s*$/g;function Le(e,t){return N(e,\"table\")&&N(11!==t.nodeType?t:t.firstChild,\"tr\")?w(e).children(\"tbody\")[0]||e:e}function He(e){return e.type=(null!==e.getAttribute(\"type\"))+\"/\"+e.type,e}function Oe(e){return\"true/\"===(e.type||\"\").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute(\"type\"),e}function Pe(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(J.hasData(e)&&(o=J.access(e),a=J.set(t,o),l=o.events)){delete a.handle,a.events={};for(i in l)for(n=0,r=l[i].length;n<r;n++)w.event.add(t,i,l[i][n])}K.hasData(e)&&(s=K.access(e),u=w.extend({},s),K.set(t,u))}}function Me(e,t){var n=t.nodeName.toLowerCase();\"input\"===n&&pe.test(e.type)?t.checked=e.checked:\"input\"!==n&&\"textarea\"!==n||(t.defaultValue=e.defaultValue)}function Re(e,t,n,r){t=a.apply([],t);var i,o,s,u,l,c,f=0,p=e.length,d=p-1,y=t[0],v=g(y);if(v||p>1&&\"string\"==typeof y&&!h.checkClone&&je.test(y))return e.each(function(i){var o=e.eq(i);v&&(t[0]=y.call(this,i,o.html())),Re(o,t,n,r)});if(p&&(i=xe(t,e[0].ownerDocument,!1,e,r),o=i.firstChild,1===i.childNodes.length&&(i=o),o||r)){for(u=(s=w.map(ye(i,\"script\"),He)).length;f<p;f++)l=i,f!==d&&(l=w.clone(l,!0,!0),u&&w.merge(s,ye(l,\"script\"))),n.call(e[f],l,f);if(u)for(c=s[s.length-1].ownerDocument,w.map(s,Oe),f=0;f<u;f++)l=s[f],he.test(l.type||\"\")&&!J.access(l,\"globalEval\")&&w.contains(c,l)&&(l.src&&\"module\"!==(l.type||\"\").toLowerCase()?w._evalUrl&&w._evalUrl(l.src):m(l.textContent.replace(qe,\"\"),c,l))}return e}function Ie(e,t,n){for(var r,i=t?w.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||w.cleanData(ye(r)),r.parentNode&&(n&&w.contains(r.ownerDocument,r)&&ve(ye(r,\"script\")),r.parentNode.removeChild(r));return e}w.extend({htmlPrefilter:function(e){return e.replace(Ne,\"<$1></$2>\")},clone:function(e,t,n){var r,i,o,a,s=e.cloneNode(!0),u=w.contains(e.ownerDocument,e);if(!(h.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||w.isXMLDoc(e)))for(a=ye(s),r=0,i=(o=ye(e)).length;r<i;r++)Me(o[r],a[r]);if(t)if(n)for(o=o||ye(e),a=a||ye(s),r=0,i=o.length;r<i;r++)Pe(o[r],a[r]);else Pe(e,s);return(a=ye(s,\"script\")).length>0&&ve(a,!u&&ye(e,\"script\")),s},cleanData:function(e){for(var t,n,r,i=w.event.special,o=0;void 0!==(n=e[o]);o++)if(Y(n)){if(t=n[J.expando]){if(t.events)for(r in t.events)i[r]?w.event.remove(n,r):w.removeEvent(n,r,t.handle);n[J.expando]=void 0}n[K.expando]&&(n[K.expando]=void 0)}}}),w.fn.extend({detach:function(e){return Ie(this,e,!0)},remove:function(e){return Ie(this,e)},text:function(e){return z(this,function(e){return void 0===e?w.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 Re(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Le(this,e).appendChild(e)})},prepend:function(){return Re(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Le(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Re(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Re(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&&(w.cleanData(ye(e,!1)),e.textContent=\"\");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return w.clone(this,e,t)})},html:function(e){return z(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&&!Ae.test(e)&&!ge[(de.exec(e)||[\"\",\"\"])[1].toLowerCase()]){e=w.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(w.cleanData(ye(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=[];return Re(this,arguments,function(t){var n=this.parentNode;w.inArray(this,e)<0&&(w.cleanData(ye(this)),n&&n.replaceChild(t,this))},e)}}),w.each({appendTo:\"append\",prependTo:\"prepend\",insertBefore:\"before\",insertAfter:\"after\",replaceAll:\"replaceWith\"},function(e,t){w.fn[e]=function(e){for(var n,r=[],i=w(e),o=i.length-1,a=0;a<=o;a++)n=a===o?this:this.clone(!0),w(i[a])[t](n),s.apply(r,n.get());return this.pushStack(r)}});var We=new RegExp(\"^(\"+re+\")(?!px)[a-z%]+$\",\"i\"),$e=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)},Be=new RegExp(oe.join(\"|\"),\"i\");!function(){function t(){if(c){l.style.cssText=\"position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0\",c.style.cssText=\"position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%\",be.appendChild(l).appendChild(c);var t=e.getComputedStyle(c);i=\"1%\"!==t.top,u=12===n(t.marginLeft),c.style.right=\"60%\",s=36===n(t.right),o=36===n(t.width),c.style.position=\"absolute\",a=36===c.offsetWidth||\"absolute\",be.removeChild(l),c=null}}function n(e){return Math.round(parseFloat(e))}var i,o,a,s,u,l=r.createElement(\"div\"),c=r.createElement(\"div\");c.style&&(c.style.backgroundClip=\"content-box\",c.cloneNode(!0).style.backgroundClip=\"\",h.clearCloneStyle=\"content-box\"===c.style.backgroundClip,w.extend(h,{boxSizingReliable:function(){return t(),o},pixelBoxStyles:function(){return t(),s},pixelPosition:function(){return t(),i},reliableMarginLeft:function(){return t(),u},scrollboxSize:function(){return t(),a}}))}();function Fe(e,t,n){var r,i,o,a,s=e.style;return(n=n||$e(e))&&(\"\"!==(a=n.getPropertyValue(t)||n[t])||w.contains(e.ownerDocument,e)||(a=w.style(e,t)),!h.pixelBoxStyles()&&We.test(a)&&Be.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 _e(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}var ze=/^(none|table(?!-c[ea]).+)/,Xe=/^--/,Ue={position:\"absolute\",visibility:\"hidden\",display:\"block\"},Ve={letterSpacing:\"0\",fontWeight:\"400\"},Ge=[\"Webkit\",\"Moz\",\"ms\"],Ye=r.createElement(\"div\").style;function Qe(e){if(e in Ye)return e;var t=e[0].toUpperCase()+e.slice(1),n=Ge.length;while(n--)if((e=Ge[n]+t)in Ye)return e}function Je(e){var t=w.cssProps[e];return t||(t=w.cssProps[e]=Qe(e)||e),t}function Ke(e,t,n){var r=ie.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||\"px\"):t}function Ze(e,t,n,r,i,o){var a=\"width\"===t?1:0,s=0,u=0;if(n===(r?\"border\":\"content\"))return 0;for(;a<4;a+=2)\"margin\"===n&&(u+=w.css(e,n+oe[a],!0,i)),r?(\"content\"===n&&(u-=w.css(e,\"padding\"+oe[a],!0,i)),\"margin\"!==n&&(u-=w.css(e,\"border\"+oe[a]+\"Width\",!0,i))):(u+=w.css(e,\"padding\"+oe[a],!0,i),\"padding\"!==n?u+=w.css(e,\"border\"+oe[a]+\"Width\",!0,i):s+=w.css(e,\"border\"+oe[a]+\"Width\",!0,i));return!r&&o>=0&&(u+=Math.max(0,Math.ceil(e[\"offset\"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))),u}function et(e,t,n){var r=$e(e),i=Fe(e,t,r),o=\"border-box\"===w.css(e,\"boxSizing\",!1,r),a=o;if(We.test(i)){if(!n)return i;i=\"auto\"}return a=a&&(h.boxSizingReliable()||i===e.style[t]),(\"auto\"===i||!parseFloat(i)&&\"inline\"===w.css(e,\"display\",!1,r))&&(i=e[\"offset\"+t[0].toUpperCase()+t.slice(1)],a=!0),(i=parseFloat(i)||0)+Ze(e,t,n||(o?\"border\":\"content\"),a,r,i)+\"px\"}w.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Fe(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=G(t),u=Xe.test(t),l=e.style;if(u||(t=Je(s)),a=w.cssHooks[t]||w.cssHooks[s],void 0===n)return a&&\"get\"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];\"string\"==(o=typeof n)&&(i=ie.exec(n))&&i[1]&&(n=ue(e,t,i),o=\"number\"),null!=n&&n===n&&(\"number\"===o&&(n+=i&&i[3]||(w.cssNumber[s]?\"\":\"px\")),h.clearCloneStyle||\"\"!==n||0!==t.indexOf(\"background\")||(l[t]=\"inherit\"),a&&\"set\"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=G(t);return Xe.test(t)||(t=Je(s)),(a=w.cssHooks[t]||w.cssHooks[s])&&\"get\"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Fe(e,t,r)),\"normal\"===i&&t in Ve&&(i=Ve[t]),\"\"===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),w.each([\"height\",\"width\"],function(e,t){w.cssHooks[t]={get:function(e,n,r){if(n)return!ze.test(w.css(e,\"display\"))||e.getClientRects().length&&e.getBoundingClientRect().width?et(e,t,r):se(e,Ue,function(){return et(e,t,r)})},set:function(e,n,r){var i,o=$e(e),a=\"border-box\"===w.css(e,\"boxSizing\",!1,o),s=r&&Ze(e,t,r,a,o);return a&&h.scrollboxSize()===o.position&&(s-=Math.ceil(e[\"offset\"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-Ze(e,t,\"border\",!1,o)-.5)),s&&(i=ie.exec(n))&&\"px\"!==(i[3]||\"px\")&&(e.style[t]=n,n=w.css(e,t)),Ke(e,n,s)}}}),w.cssHooks.marginLeft=_e(h.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Fe(e,\"marginLeft\"))||e.getBoundingClientRect().left-se(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+\"px\"}),w.each({margin:\"\",padding:\"\",border:\"Width\"},function(e,t){w.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o=\"string\"==typeof n?n.split(\" \"):[n];r<4;r++)i[e+oe[r]+t]=o[r]||o[r-2]||o[0];return i}},\"margin\"!==e&&(w.cssHooks[e+t].set=Ke)}),w.fn.extend({css:function(e,t){return z(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=$e(e),i=t.length;a<i;a++)o[t[a]]=w.css(e,t[a],!1,r);return o}return void 0!==n?w.style(e,t,n):w.css(e,t)},e,t,arguments.length>1)}});function tt(e,t,n,r,i){return new tt.prototype.init(e,t,n,r,i)}w.Tween=tt,tt.prototype={constructor:tt,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||w.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(w.cssNumber[n]?\"\":\"px\")},cur:function(){var e=tt.propHooks[this.prop];return e&&e.get?e.get(this):tt.propHooks._default.get(this)},run:function(e){var t,n=tt.propHooks[this.prop];return this.options.duration?this.pos=t=w.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):tt.propHooks._default.set(this),this}},tt.prototype.init.prototype=tt.prototype,tt.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=w.css(e.elem,e.prop,\"\"))&&\"auto\"!==t?t:0},set:function(e){w.fx.step[e.prop]?w.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[w.cssProps[e.prop]]&&!w.cssHooks[e.prop]?e.elem[e.prop]=e.now:w.style(e.elem,e.prop,e.now+e.unit)}}},tt.propHooks.scrollTop=tt.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},w.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:\"swing\"},w.fx=tt.prototype.init,w.fx.step={};var nt,rt,it=/^(?:toggle|show|hide)$/,ot=/queueHooks$/;function at(){rt&&(!1===r.hidden&&e.requestAnimationFrame?e.requestAnimationFrame(at):e.setTimeout(at,w.fx.interval),w.fx.tick())}function st(){return e.setTimeout(function(){nt=void 0}),nt=Date.now()}function ut(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i[\"margin\"+(n=oe[r])]=i[\"padding\"+n]=e;return t&&(i.opacity=i.width=e),i}function lt(e,t,n){for(var r,i=(pt.tweeners[t]||[]).concat(pt.tweeners[\"*\"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ct(e,t,n){var r,i,o,a,s,u,l,c,f=\"width\"in t||\"height\"in t,p=this,d={},h=e.style,g=e.nodeType&&ae(e),y=J.get(e,\"fxshow\");n.queue||(null==(a=w._queueHooks(e,\"fx\")).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--,w.queue(e,\"fx\").length||a.empty.fire()})}));for(r in t)if(i=t[r],it.test(i)){if(delete t[r],o=o||\"toggle\"===i,i===(g?\"hide\":\"show\")){if(\"show\"!==i||!y||void 0===y[r])continue;g=!0}d[r]=y&&y[r]||w.style(e,r)}if((u=!w.isEmptyObject(t))||!w.isEmptyObject(d)){f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=y&&y.display)&&(l=J.get(e,\"display\")),\"none\"===(c=w.css(e,\"display\"))&&(l?c=l:(fe([e],!0),l=e.style.display||l,c=w.css(e,\"display\"),fe([e]))),(\"inline\"===c||\"inline-block\"===c&&null!=l)&&\"none\"===w.css(e,\"float\")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l=\"none\"===c?\"\":c)),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&&(g=y.hidden):y=J.access(e,\"fxshow\",{display:l}),o&&(y.hidden=!g),g&&fe([e],!0),p.done(function(){g||fe([e]),J.remove(e,\"fxshow\");for(r in d)w.style(e,r,d[r])})),u=lt(g?y[r]:0,r,p),r in y||(y[r]=u.start,g&&(u.end=u.start,u.start=0))}}function ft(e,t){var n,r,i,o,a;for(n in e)if(r=G(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=w.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 pt(e,t,n){var r,i,o=0,a=pt.prefilters.length,s=w.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;for(var t=nt||st(),n=Math.max(0,l.startTime+l.duration-t),r=1-(n/l.duration||0),o=0,a=l.tweens.length;o<a;o++)l.tweens[o].run(r);return s.notifyWith(e,[l,r,n]),r<1&&a?n:(a||s.notifyWith(e,[l,1,0]),s.resolveWith(e,[l]),!1)},l=s.promise({elem:e,props:w.extend({},t),opts:w.extend(!0,{specialEasing:{},easing:w.easing._default},n),originalProperties:t,originalOptions:n,startTime:nt||st(),duration:n.duration,tweens:[],createTween:function(t,n){var r=w.Tween(e,l.opts,t,n,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(r),r},stop:function(t){var n=0,r=t?l.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)l.tweens[n].run(1);return t?(s.notifyWith(e,[l,1,0]),s.resolveWith(e,[l,t])):s.rejectWith(e,[l,t]),this}}),c=l.props;for(ft(c,l.opts.specialEasing);o<a;o++)if(r=pt.prefilters[o].call(l,e,c,l.opts))return g(r.stop)&&(w._queueHooks(l.elem,l.opts.queue).stop=r.stop.bind(r)),r;return w.map(c,lt,l),g(l.opts.start)&&l.opts.start.call(e,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),w.fx.timer(w.extend(u,{elem:e,anim:l,queue:l.opts.queue})),l}w.Animation=w.extend(pt,{tweeners:{\"*\":[function(e,t){var n=this.createTween(e,t);return ue(n.elem,e,ie.exec(t),n),n}]},tweener:function(e,t){g(e)?(t=e,e=[\"*\"]):e=e.match(M);for(var n,r=0,i=e.length;r<i;r++)n=e[r],pt.tweeners[n]=pt.tweeners[n]||[],pt.tweeners[n].unshift(t)},prefilters:[ct],prefilter:function(e,t){t?pt.prefilters.unshift(e):pt.prefilters.push(e)}}),w.speed=function(e,t,n){var r=e&&\"object\"==typeof e?w.extend({},e):{complete:n||!n&&t||g(e)&&e,duration:e,easing:n&&t||t&&!g(t)&&t};return w.fx.off?r.duration=0:\"number\"!=typeof r.duration&&(r.duration in w.fx.speeds?r.duration=w.fx.speeds[r.duration]:r.duration=w.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue=\"fx\"),r.old=r.complete,r.complete=function(){g(r.old)&&r.old.call(this),r.queue&&w.dequeue(this,r.queue)},r},w.fn.extend({fadeTo:function(e,t,n,r){return this.filter(ae).css(\"opacity\",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=w.isEmptyObject(e),o=w.speed(t,n,r),a=function(){var t=pt(this,w.extend({},e),o);(i||J.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=w.timers,a=J.get(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&ot.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||w.dequeue(this,e)})},finish:function(e){return!1!==e&&(e=e||\"fx\"),this.each(function(){var t,n=J.get(this),r=n[e+\"queue\"],i=n[e+\"queueHooks\"],o=w.timers,a=r?r.length:0;for(n.finish=!0,w.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})}}),w.each([\"toggle\",\"show\",\"hide\"],function(e,t){var n=w.fn[t];w.fn[t]=function(e,r,i){return null==e||\"boolean\"==typeof e?n.apply(this,arguments):this.animate(ut(t,!0),e,r,i)}}),w.each({slideDown:ut(\"show\"),slideUp:ut(\"hide\"),slideToggle:ut(\"toggle\"),fadeIn:{opacity:\"show\"},fadeOut:{opacity:\"hide\"},fadeToggle:{opacity:\"toggle\"}},function(e,t){w.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),w.timers=[],w.fx.tick=function(){var e,t=0,n=w.timers;for(nt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||w.fx.stop(),nt=void 0},w.fx.timer=function(e){w.timers.push(e),w.fx.start()},w.fx.interval=13,w.fx.start=function(){rt||(rt=!0,at())},w.fx.stop=function(){rt=null},w.fx.speeds={slow:600,fast:200,_default:400},w.fn.delay=function(t,n){return t=w.fx?w.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=r.createElement(\"input\"),t=r.createElement(\"select\").appendChild(r.createElement(\"option\"));e.type=\"checkbox\",h.checkOn=\"\"!==e.value,h.optSelected=t.selected,(e=r.createElement(\"input\")).value=\"t\",e.type=\"radio\",h.radioValue=\"t\"===e.value}();var dt,ht=w.expr.attrHandle;w.fn.extend({attr:function(e,t){return z(this,w.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){w.removeAttr(this,e)})}}),w.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return\"undefined\"==typeof e.getAttribute?w.prop(e,t,n):(1===o&&w.isXMLDoc(e)||(i=w.attrHooks[t.toLowerCase()]||(w.expr.match.bool.test(t)?dt:void 0)),void 0!==n?null===n?void w.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:null==(r=w.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!h.radioValue&&\"radio\"===t&&N(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(M);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),dt={set:function(e,t,n){return!1===t?w.removeAttr(e,n):e.setAttribute(n,n),n}},w.each(w.expr.match.bool.source.match(/\\w+/g),function(e,t){var n=ht[t]||w.find.attr;ht[t]=function(e,t,r){var i,o,a=t.toLowerCase();return r||(o=ht[a],ht[a]=i,i=null!=n(e,t,r)?a:null,ht[a]=o),i}});var gt=/^(?:input|select|textarea|button)$/i,yt=/^(?:a|area)$/i;w.fn.extend({prop:function(e,t){return z(this,w.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each(function(){delete this[w.propFix[e]||e]})}}),w.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&w.isXMLDoc(e)||(t=w.propFix[t]||t,i=w.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=w.find.attr(e,\"tabindex\");return t?parseInt(t,10):gt.test(e.nodeName)||yt.test(e.nodeName)&&e.href?0:-1}}},propFix:{\"for\":\"htmlFor\",\"class\":\"className\"}}),h.optSelected||(w.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)}}),w.each([\"tabIndex\",\"readOnly\",\"maxLength\",\"cellSpacing\",\"cellPadding\",\"rowSpan\",\"colSpan\",\"useMap\",\"frameBorder\",\"contentEditable\"],function(){w.propFix[this.toLowerCase()]=this});function vt(e){return(e.match(M)||[]).join(\" \")}function mt(e){return e.getAttribute&&e.getAttribute(\"class\")||\"\"}function xt(e){return Array.isArray(e)?e:\"string\"==typeof e?e.match(M)||[]:[]}w.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,u=0;if(g(e))return this.each(function(t){w(this).addClass(e.call(this,t,mt(this)))});if((t=xt(e)).length)while(n=this[u++])if(i=mt(n),r=1===n.nodeType&&\" \"+vt(i)+\" \"){a=0;while(o=t[a++])r.indexOf(\" \"+o+\" \")<0&&(r+=o+\" \");i!==(s=vt(r))&&n.setAttribute(\"class\",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,u=0;if(g(e))return this.each(function(t){w(this).removeClass(e.call(this,t,mt(this)))});if(!arguments.length)return this.attr(\"class\",\"\");if((t=xt(e)).length)while(n=this[u++])if(i=mt(n),r=1===n.nodeType&&\" \"+vt(i)+\" \"){a=0;while(o=t[a++])while(r.indexOf(\" \"+o+\" \")>-1)r=r.replace(\" \"+o+\" \",\" \");i!==(s=vt(r))&&n.setAttribute(\"class\",s)}return this},toggleClass:function(e,t){var n=typeof e,r=\"string\"===n||Array.isArray(e);return\"boolean\"==typeof t&&r?t?this.addClass(e):this.removeClass(e):g(e)?this.each(function(n){w(this).toggleClass(e.call(this,n,mt(this),t),t)}):this.each(function(){var t,i,o,a;if(r){i=0,o=w(this),a=xt(e);while(t=a[i++])o.hasClass(t)?o.removeClass(t):o.addClass(t)}else void 0!==e&&\"boolean\"!==n||((t=mt(this))&&J.set(this,\"__className__\",t),this.setAttribute&&this.setAttribute(\"class\",t||!1===e?\"\":J.get(this,\"__className__\")||\"\"))})},hasClass:function(e){var t,n,r=0;t=\" \"+e+\" \";while(n=this[r++])if(1===n.nodeType&&(\" \"+vt(mt(n))+\" \").indexOf(t)>-1)return!0;return!1}});var bt=/\\r/g;w.fn.extend({val:function(e){var t,n,r,i=this[0];{if(arguments.length)return r=g(e),this.each(function(n){var i;1===this.nodeType&&(null==(i=r?e.call(this,n,w(this).val()):e)?i=\"\":\"number\"==typeof i?i+=\"\":Array.isArray(i)&&(i=w.map(i,function(e){return null==e?\"\":e+\"\"})),(t=w.valHooks[this.type]||w.valHooks[this.nodeName.toLowerCase()])&&\"set\"in t&&void 0!==t.set(this,i,\"value\")||(this.value=i))});if(i)return(t=w.valHooks[i.type]||w.valHooks[i.nodeName.toLowerCase()])&&\"get\"in t&&void 0!==(n=t.get(i,\"value\"))?n:\"string\"==typeof(n=i.value)?n.replace(bt,\"\"):null==n?\"\":n}}}),w.extend({valHooks:{option:{get:function(e){var t=w.find.attr(e,\"value\");return null!=t?t:vt(w.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=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!N(n.parentNode,\"optgroup\"))){if(t=w(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=w.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=w.inArray(w.valHooks.option.get(r),o)>-1)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),w.each([\"radio\",\"checkbox\"],function(){w.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=w.inArray(w(e).val(),t)>-1}},h.checkOn||(w.valHooks[this].get=function(e){return null===e.getAttribute(\"value\")?\"on\":e.value})}),h.focusin=\"onfocusin\"in e;var wt=/^(?:focusinfocus|focusoutblur)$/,Tt=function(e){e.stopPropagation()};w.extend(w.event,{trigger:function(t,n,i,o){var a,s,u,l,c,p,d,h,v=[i||r],m=f.call(t,\"type\")?t.type:t,x=f.call(t,\"namespace\")?t.namespace.split(\".\"):[];if(s=h=u=i=i||r,3!==i.nodeType&&8!==i.nodeType&&!wt.test(m+w.event.triggered)&&(m.indexOf(\".\")>-1&&(m=(x=m.split(\".\")).shift(),x.sort()),c=m.indexOf(\":\")<0&&\"on\"+m,t=t[w.expando]?t:new w.Event(m,\"object\"==typeof t&&t),t.isTrigger=o?2:3,t.namespace=x.join(\".\"),t.rnamespace=t.namespace?new RegExp(\"(^|\\\\.)\"+x.join(\"\\\\.(?:.*\\\\.|)\")+\"(\\\\.|$)\"):null,t.result=void 0,t.target||(t.target=i),n=null==n?[t]:w.makeArray(n,[t]),d=w.event.special[m]||{},o||!d.trigger||!1!==d.trigger.apply(i,n))){if(!o&&!d.noBubble&&!y(i)){for(l=d.delegateType||m,wt.test(l+m)||(s=s.parentNode);s;s=s.parentNode)v.push(s),u=s;u===(i.ownerDocument||r)&&v.push(u.defaultView||u.parentWindow||e)}a=0;while((s=v[a++])&&!t.isPropagationStopped())h=s,t.type=a>1?l:d.bindType||m,(p=(J.get(s,\"events\")||{})[t.type]&&J.get(s,\"handle\"))&&p.apply(s,n),(p=c&&s[c])&&p.apply&&Y(s)&&(t.result=p.apply(s,n),!1===t.result&&t.preventDefault());return t.type=m,o||t.isDefaultPrevented()||d._default&&!1!==d._default.apply(v.pop(),n)||!Y(i)||c&&g(i[m])&&!y(i)&&((u=i[c])&&(i[c]=null),w.event.triggered=m,t.isPropagationStopped()&&h.addEventListener(m,Tt),i[m](),t.isPropagationStopped()&&h.removeEventListener(m,Tt),w.event.triggered=void 0,u&&(i[c]=u)),t.result}},simulate:function(e,t,n){var r=w.extend(new w.Event,n,{type:e,isSimulated:!0});w.event.trigger(r,null,t)}}),w.fn.extend({trigger:function(e,t){return this.each(function(){w.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return w.event.trigger(e,t,n,!0)}}),h.focusin||w.each({focus:\"focusin\",blur:\"focusout\"},function(e,t){var n=function(e){w.event.simulate(t,e.target,w.event.fix(e))};w.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=J.access(r,t);i||r.addEventListener(e,n,!0),J.access(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=J.access(r,t)-1;i?J.access(r,t,i):(r.removeEventListener(e,n,!0),J.remove(r,t))}}});var Ct=e.location,Et=Date.now(),kt=/\\?/;w.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||w.error(\"Invalid XML: \"+t),n};var St=/\\[\\]$/,Dt=/\\r?\\n/g,Nt=/^(?:submit|button|image|reset|file)$/i,At=/^(?:input|select|textarea|keygen)/i;function jt(e,t,n,r){var i;if(Array.isArray(t))w.each(t,function(t,i){n||St.test(e)?r(e,i):jt(e+\"[\"+(\"object\"==typeof i&&null!=i?t:\"\")+\"]\",i,n,r)});else if(n||\"object\"!==x(t))r(e,t);else for(i in t)jt(e+\"[\"+i+\"]\",t[i],n,r)}w.param=function(e,t){var n,r=[],i=function(e,t){var n=g(t)?t():t;r[r.length]=encodeURIComponent(e)+\"=\"+encodeURIComponent(null==n?\"\":n)};if(Array.isArray(e)||e.jquery&&!w.isPlainObject(e))w.each(e,function(){i(this.name,this.value)});else for(n in e)jt(n,e[n],t,i);return r.join(\"&\")},w.fn.extend({serialize:function(){return w.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=w.prop(this,\"elements\");return e?w.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!w(this).is(\":disabled\")&&At.test(this.nodeName)&&!Nt.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=w(this).val();return null==n?null:Array.isArray(n)?w.map(n,function(e){return{name:t.name,value:e.replace(Dt,\"\\r\\n\")}}):{name:t.name,value:n.replace(Dt,\"\\r\\n\")}}).get()}});var qt=/%20/g,Lt=/#.*$/,Ht=/([?&])_=[^&]*/,Ot=/^(.*?):[ \\t]*([^\\r\\n]*)$/gm,Pt=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Mt=/^(?:GET|HEAD)$/,Rt=/^\\/\\//,It={},Wt={},$t=\"*/\".concat(\"*\"),Bt=r.createElement(\"a\");Bt.href=Ct.href;function Ft(e){return function(t,n){\"string\"!=typeof t&&(n=t,t=\"*\");var r,i=0,o=t.toLowerCase().match(M)||[];if(g(n))while(r=o[i++])\"+\"===r[0]?(r=r.slice(1)||\"*\",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function _t(e,t,n,r){var i={},o=e===Wt;function a(s){var u;return i[s]=!0,w.each(e[s]||[],function(e,s){var l=s(t,n,r);return\"string\"!=typeof l||o||i[l]?o?!(u=l):void 0:(t.dataTypes.unshift(l),a(l),!1)}),u}return a(t.dataTypes[0])||!i[\"*\"]&&a(\"*\")}function zt(e,t){var n,r,i=w.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&w.extend(!0,e,r),e}function Xt(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while(\"*\"===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}if(o)return o!==u[0]&&u.unshift(o),n[o]}function Ut(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if(\"*\"===o)o=u;else if(\"*\"!==u&&u!==o){if(!(a=l[u+\" \"+o]||l[\"* \"+o]))for(i in l)if((s=i.split(\" \"))[1]===o&&(a=l[u+\" \"+s[0]]||l[\"* \"+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.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 \"+u+\" to \"+o}}}return{state:\"success\",data:t}}w.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ct.href,type:\"GET\",isLocal:Pt.test(Ct.protocol),global:!0,processData:!0,async:!0,contentType:\"application/x-www-form-urlencoded; charset=UTF-8\",accepts:{\"*\":$t,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\":w.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?zt(zt(e,w.ajaxSettings),t):zt(w.ajaxSettings,e)},ajaxPrefilter:Ft(It),ajaxTransport:Ft(Wt),ajax:function(t,n){\"object\"==typeof t&&(n=t,t=void 0),n=n||{};var i,o,a,s,u,l,c,f,p,d,h=w.ajaxSetup({},n),g=h.context||h,y=h.context&&(g.nodeType||g.jquery)?w(g):w.event,v=w.Deferred(),m=w.Callbacks(\"once memory\"),x=h.statusCode||{},b={},T={},C=\"canceled\",E={readyState:0,getResponseHeader:function(e){var t;if(c){if(!s){s={};while(t=Ot.exec(a))s[t[1].toLowerCase()]=t[2]}t=s[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return c?a:null},setRequestHeader:function(e,t){return null==c&&(e=T[e.toLowerCase()]=T[e.toLowerCase()]||e,b[e]=t),this},overrideMimeType:function(e){return null==c&&(h.mimeType=e),this},statusCode:function(e){var t;if(e)if(c)E.always(e[E.status]);else for(t in e)x[t]=[x[t],e[t]];return this},abort:function(e){var t=e||C;return i&&i.abort(t),k(0,t),this}};if(v.promise(E),h.url=((t||h.url||Ct.href)+\"\").replace(Rt,Ct.protocol+\"//\"),h.type=n.method||n.type||h.method||h.type,h.dataTypes=(h.dataType||\"*\").toLowerCase().match(M)||[\"\"],null==h.crossDomain){l=r.createElement(\"a\");try{l.href=h.url,l.href=l.href,h.crossDomain=Bt.protocol+\"//\"+Bt.host!=l.protocol+\"//\"+l.host}catch(e){h.crossDomain=!0}}if(h.data&&h.processData&&\"string\"!=typeof h.data&&(h.data=w.param(h.data,h.traditional)),_t(It,h,n,E),c)return E;(f=w.event&&h.global)&&0==w.active++&&w.event.trigger(\"ajaxStart\"),h.type=h.type.toUpperCase(),h.hasContent=!Mt.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(qt,\"+\")):(d=h.url.slice(o.length),h.data&&(h.processData||\"string\"==typeof h.data)&&(o+=(kt.test(o)?\"&\":\"?\")+h.data,delete h.data),!1===h.cache&&(o=o.replace(Ht,\"$1\"),d=(kt.test(o)?\"&\":\"?\")+\"_=\"+Et+++d),h.url=o+d),h.ifModified&&(w.lastModified[o]&&E.setRequestHeader(\"If-Modified-Since\",w.lastModified[o]),w.etag[o]&&E.setRequestHeader(\"If-None-Match\",w.etag[o])),(h.data&&h.hasContent&&!1!==h.contentType||n.contentType)&&E.setRequestHeader(\"Content-Type\",h.contentType),E.setRequestHeader(\"Accept\",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+(\"*\"!==h.dataTypes[0]?\", \"+$t+\"; q=0.01\":\"\"):h.accepts[\"*\"]);for(p in h.headers)E.setRequestHeader(p,h.headers[p]);if(h.beforeSend&&(!1===h.beforeSend.call(g,E,h)||c))return E.abort();if(C=\"abort\",m.add(h.complete),E.done(h.success),E.fail(h.error),i=_t(Wt,h,n,E)){if(E.readyState=1,f&&y.trigger(\"ajaxSend\",[E,h]),c)return E;h.async&&h.timeout>0&&(u=e.setTimeout(function(){E.abort(\"timeout\")},h.timeout));try{c=!1,i.send(b,k)}catch(e){if(c)throw e;k(-1,e)}}else k(-1,\"No Transport\");function k(t,n,r,s){var l,p,d,b,T,C=n;c||(c=!0,u&&e.clearTimeout(u),i=void 0,a=s||\"\",E.readyState=t>0?4:0,l=t>=200&&t<300||304===t,r&&(b=Xt(h,E,r)),b=Ut(h,b,E,l),l?(h.ifModified&&((T=E.getResponseHeader(\"Last-Modified\"))&&(w.lastModified[o]=T),(T=E.getResponseHeader(\"etag\"))&&(w.etag[o]=T)),204===t||\"HEAD\"===h.type?C=\"nocontent\":304===t?C=\"notmodified\":(C=b.state,p=b.data,l=!(d=b.error))):(d=C,!t&&C||(C=\"error\",t<0&&(t=0))),E.status=t,E.statusText=(n||C)+\"\",l?v.resolveWith(g,[p,C,E]):v.rejectWith(g,[E,C,d]),E.statusCode(x),x=void 0,f&&y.trigger(l?\"ajaxSuccess\":\"ajaxError\",[E,h,l?p:d]),m.fireWith(g,[E,C]),f&&(y.trigger(\"ajaxComplete\",[E,h]),--w.active||w.event.trigger(\"ajaxStop\")))}return E},getJSON:function(e,t,n){return w.get(e,t,n,\"json\")},getScript:function(e,t){return w.get(e,void 0,t,\"script\")}}),w.each([\"get\",\"post\"],function(e,t){w[t]=function(e,n,r,i){return g(n)&&(i=i||r,r=n,n=void 0),w.ajax(w.extend({url:e,type:t,dataType:i,data:n,success:r},w.isPlainObject(e)&&e))}}),w._evalUrl=function(e){return w.ajax({url:e,type:\"GET\",dataType:\"script\",cache:!0,async:!1,global:!1,\"throws\":!0})},w.fn.extend({wrapAll:function(e){var t;return this[0]&&(g(e)&&(e=e.call(this[0])),t=w(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(e){return g(e)?this.each(function(t){w(this).wrapInner(e.call(this,t))}):this.each(function(){var t=w(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=g(e);return this.each(function(n){w(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(e){return this.parent(e).not(\"body\").each(function(){w(this).replaceWith(this.childNodes)}),this}}),w.expr.pseudos.hidden=function(e){return!w.expr.pseudos.visible(e)},w.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},w.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var Vt={0:200,1223:204},Gt=w.ajaxSettings.xhr();h.cors=!!Gt&&\"withCredentials\"in Gt,h.ajax=Gt=!!Gt,w.ajaxTransport(function(t){var n,r;if(h.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(Vt[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()}}}),w.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),w.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 w.globalEval(e),e}}}),w.ajaxPrefilter(\"script\",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type=\"GET\")}),w.ajaxTransport(\"script\",function(e){if(e.crossDomain){var t,n;return{send:function(i,o){t=w(\"<script>\").prop({charset:e.scriptCharset,src:e.url}).on(\"load error\",n=function(e){t.remove(),n=null,e&&o(\"error\"===e.type?404:200,e.type)}),r.head.appendChild(t[0])},abort:function(){n&&n()}}}});var Yt=[],Qt=/(=)\\?(?=&|$)|\\?\\?/;w.ajaxSetup({jsonp:\"callback\",jsonpCallback:function(){var e=Yt.pop()||w.expando+\"_\"+Et++;return this[e]=!0,e}}),w.ajaxPrefilter(\"json jsonp\",function(t,n,r){var i,o,a,s=!1!==t.jsonp&&(Qt.test(t.url)?\"url\":\"string\"==typeof t.data&&0===(t.contentType||\"\").indexOf(\"application/x-www-form-urlencoded\")&&Qt.test(t.data)&&\"data\");if(s||\"jsonp\"===t.dataTypes[0])return i=t.jsonpCallback=g(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Qt,\"$1\"+i):!1!==t.jsonp&&(t.url+=(kt.test(t.url)?\"&\":\"?\")+t.jsonp+\"=\"+i),t.converters[\"script json\"]=function(){return a||w.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?w(e).removeProp(i):e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,Yt.push(i)),a&&g(o)&&o(a[0]),a=o=void 0}),\"script\"}),h.createHTMLDocument=function(){var e=r.implementation.createHTMLDocument(\"\").body;return e.innerHTML=\"<form></form><form></form>\",2===e.childNodes.length}(),w.parseHTML=function(e,t,n){if(\"string\"!=typeof e)return[];\"boolean\"==typeof t&&(n=t,t=!1);var i,o,a;return t||(h.createHTMLDocument?((i=(t=r.implementation.createHTMLDocument(\"\")).createElement(\"base\")).href=r.location.href,t.head.appendChild(i)):t=r),o=A.exec(e),a=!n&&[],o?[t.createElement(o[1])]:(o=xe([e],t,a),a&&a.length&&w(a).remove(),w.merge([],o.childNodes))},w.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(\" \");return s>-1&&(r=vt(e.slice(s)),e=e.slice(0,s)),g(t)?(n=t,t=void 0):t&&\"object\"==typeof t&&(i=\"POST\"),a.length>0&&w.ajax({url:e,type:i||\"GET\",dataType:\"html\",data:t}).done(function(e){o=arguments,a.html(r?w(\"<div>\").append(w.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},w.each([\"ajaxStart\",\"ajaxStop\",\"ajaxComplete\",\"ajaxError\",\"ajaxSuccess\",\"ajaxSend\"],function(e,t){w.fn[t]=function(e){return this.on(t,e)}}),w.expr.pseudos.animated=function(e){return w.grep(w.timers,function(t){return e===t.elem}).length},w.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l,c=w.css(e,\"position\"),f=w(e),p={};\"static\"===c&&(e.style.position=\"relative\"),s=f.offset(),o=w.css(e,\"top\"),u=w.css(e,\"left\"),(l=(\"absolute\"===c||\"fixed\"===c)&&(o+u).indexOf(\"auto\")>-1)?(a=(r=f.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),g(t)&&(t=t.call(e,n,w.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)}},w.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){w.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\"===w.css(r,\"position\"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&\"static\"===w.css(e,\"position\"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=w(e).offset()).top+=w.css(e,\"borderTopWidth\",!0),i.left+=w.css(e,\"borderLeftWidth\",!0))}return{top:t.top-i.top-w.css(r,\"marginTop\",!0),left:t.left-i.left-w.css(r,\"marginLeft\",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&\"static\"===w.css(e,\"position\"))e=e.offsetParent;return e||be})}}),w.each({scrollLeft:\"pageXOffset\",scrollTop:\"pageYOffset\"},function(e,t){var n=\"pageYOffset\"===t;w.fn[e]=function(r){return z(this,function(e,r,i){var o;if(y(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)}}),w.each([\"top\",\"left\"],function(e,t){w.cssHooks[t]=_e(h.pixelPosition,function(e,n){if(n)return n=Fe(e,t),We.test(n)?w(e).position()[t]+\"px\":n})}),w.each({Height:\"height\",Width:\"width\"},function(e,t){w.each({padding:\"inner\"+e,content:t,\"\":\"outer\"+e},function(n,r){w.fn[r]=function(i,o){var a=arguments.length&&(n||\"boolean\"!=typeof i),s=n||(!0===i||!0===o?\"margin\":\"border\");return z(this,function(t,n,i){var o;return y(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?w.css(t,n,s):w.style(t,n,i,s)},t,a?i:void 0,a)}})}),w.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){w.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),w.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),w.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)}}),w.proxy=function(e,t){var n,r,i;if(\"string\"==typeof t&&(n=e[t],t=e,e=n),g(e))return r=o.call(arguments,2),i=function(){return e.apply(t||this,r.concat(o.call(arguments)))},i.guid=e.guid=e.guid||w.guid++,i},w.holdReady=function(e){e?w.readyWait++:w.ready(!0)},w.isArray=Array.isArray,w.parseJSON=JSON.parse,w.nodeName=N,w.isFunction=g,w.isWindow=y,w.camelCase=G,w.type=x,w.now=Date.now,w.isNumeric=function(e){var t=w.type(e);return(\"number\"===t||\"string\"===t)&&!isNaN(e-parseFloat(e))},\"function\"==typeof define&&define.amd&&define(\"jquery\",[],function(){return w});var Jt=e.jQuery,Kt=e.$;return w.noConflict=function(t){return e.$===w&&(e.$=Kt),t&&e.jQuery===w&&(e.jQuery=Jt),w},t||(e.jQuery=e.$=w),w});\n/*\n * jQuery throttle / debounce - v1.1 - 3/7/2010\n * http://benalman.com/projects/jquery-throttle-debounce-plugin/\n * \n * Copyright (c) 2010 \"Cowboy\" Ben Alman\n * Dual licensed under the MIT and GPL licenses.\n * http://benalman.com/about/license/\n */\n(function(b,c){var $=b.jQuery||b.Cowboy||(b.Cowboy={}),a;$.throttle=a=function(e,f,j,i){var h,d=0;if(typeof f!==\"boolean\"){i=j;j=f;f=c}function g(){var o=this,m=+new Date()-d,n=arguments;function l(){d=+new Date();j.apply(o,n)}function k(){h=c}if(i&&!h){l()}h&&clearTimeout(h);if(i===c&&m>e){l()}else{if(f!==true){h=setTimeout(i?k:l,i===c?e-m:e)}}}if($.guid){g.guid=j.guid=j.guid||$.guid++}return g};$.debounce=function(d,e,f){return f===c?a(d,e,false):a(d,f,e!==false)}})(this);\n/*!\n * imagesLoaded PACKAGED v4.1.0\n * JavaScript is all like \"You images are done yet or what?\"\n * MIT License\n */\n!function(t,e){\"function\"==typeof define&&define.amd?define(\"ev-emitter/ev-emitter\",e):\"object\"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}(this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return-1==n.indexOf(e)&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||[];return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return-1!=n&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=0,o=i[n];e=e||[];for(var r=this._onceEvents&&this._onceEvents[t];o;){var s=r&&r[o];s&&(this.off(t,o),delete r[o]),o.apply(this,e),n+=s?0:1,o=i[n]}return this}},t}),function(t,e){\"use strict\";\"function\"==typeof define&&define.amd?define([\"ev-emitter/ev-emitter\"],function(i){return e(t,i)}):\"object\"==typeof module&&module.exports?module.exports=e(t,require(\"ev-emitter\")):t.imagesLoaded=e(t,t.EvEmitter)}(window,function(t,e){function i(t,e){for(var i in e)t[i]=e[i];return t}function n(t){var e=[];if(Array.isArray(t))e=t;else if(\"number\"==typeof t.length)for(var i=0;i<t.length;i++)e.push(t[i]);else e.push(t);return e}function o(t,e,r){return this instanceof o?(\"string\"==typeof t&&(t=document.querySelectorAll(t)),this.elements=n(t),this.options=i({},this.options),\"function\"==typeof e?r=e:i(this.options,e),r&&this.on(\"always\",r),this.getImages(),h&&(this.jqDeferred=new h.Deferred),void setTimeout(function(){this.check()}.bind(this))):new o(t,e,r)}function r(t){this.img=t}function s(t,e){this.url=t,this.element=e,this.img=new Image}var h=t.jQuery,a=t.console;o.prototype=Object.create(e.prototype),o.prototype.options={},o.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},o.prototype.addElementImages=function(t){\"IMG\"==t.nodeName&&this.addImage(t),this.options.background===!0&&this.addElementBackgroundImages(t);var e=t.nodeType;if(e&&d[e]){for(var i=t.querySelectorAll(\"img\"),n=0;n<i.length;n++){var o=i[n];this.addImage(o)}if(\"string\"==typeof this.options.background){var r=t.querySelectorAll(this.options.background);for(n=0;n<r.length;n++){var s=r[n];this.addElementBackgroundImages(s)}}}};var d={1:!0,9:!0,11:!0};return o.prototype.addElementBackgroundImages=function(t){var e=getComputedStyle(t);if(e)for(var i=/url\\((['\"])?(.*?)\\1\\)/gi,n=i.exec(e.backgroundImage);null!==n;){var o=n&&n[2];o&&this.addBackground(o,t),n=i.exec(e.backgroundImage)}},o.prototype.addImage=function(t){var e=new r(t);this.images.push(e)},o.prototype.addBackground=function(t,e){var i=new s(t,e);this.images.push(i)},o.prototype.check=function(){function t(t,i,n){setTimeout(function(){e.progress(t,i,n)})}var e=this;return this.progressedCount=0,this.hasAnyBroken=!1,this.images.length?void this.images.forEach(function(e){e.once(\"progress\",t),e.check()}):void this.complete()},o.prototype.progress=function(t,e,i){this.progressedCount++,this.hasAnyBroken=this.hasAnyBroken||!t.isLoaded,this.emitEvent(\"progress\",[this,t,e]),this.jqDeferred&&this.jqDeferred.notify&&this.jqDeferred.notify(this,t),this.progressedCount==this.images.length&&this.complete(),this.options.debug&&a&&a.log(\"progress: \"+i,t,e)},o.prototype.complete=function(){var t=this.hasAnyBroken?\"fail\":\"done\";if(this.isComplete=!0,this.emitEvent(t,[this]),this.emitEvent(\"always\",[this]),this.jqDeferred){var e=this.hasAnyBroken?\"reject\":\"resolve\";this.jqDeferred[e](this)}},r.prototype=Object.create(e.prototype),r.prototype.check=function(){var t=this.getIsImageComplete();return t?void this.confirm(0!==this.img.naturalWidth,\"naturalWidth\"):(this.proxyImage=new Image,this.proxyImage.addEventListener(\"load\",this),this.proxyImage.addEventListener(\"error\",this),this.img.addEventListener(\"load\",this),this.img.addEventListener(\"error\",this),void(this.proxyImage.src=this.img.src))},r.prototype.getIsImageComplete=function(){return this.img.complete&&void 0!==this.img.naturalWidth},r.prototype.confirm=function(t,e){this.isLoaded=t,this.emitEvent(\"progress\",[this,this.img,e])},r.prototype.handleEvent=function(t){var e=\"on\"+t.type;this[e]&&this[e](t)},r.prototype.onload=function(){this.confirm(!0,\"onload\"),this.unbindEvents()},r.prototype.onerror=function(){this.confirm(!1,\"onerror\"),this.unbindEvents()},r.prototype.unbindEvents=function(){this.proxyImage.removeEventListener(\"load\",this),this.proxyImage.removeEventListener(\"error\",this),this.img.removeEventListener(\"load\",this),this.img.removeEventListener(\"error\",this)},s.prototype=Object.create(r.prototype),s.prototype.check=function(){this.img.addEventListener(\"load\",this),this.img.addEventListener(\"error\",this),this.img.src=this.url;var t=this.getIsImageComplete();t&&(this.confirm(0!==this.img.naturalWidth,\"naturalWidth\"),this.unbindEvents())},s.prototype.unbindEvents=function(){this.img.removeEventListener(\"load\",this),this.img.removeEventListener(\"error\",this)},s.prototype.confirm=function(t,e){this.isLoaded=t,this.emitEvent(\"progress\",[this,this.element,e])},o.makeJQueryPlugin=function(e){e=e||t.jQuery,e&&(h=e,h.fn.imagesLoaded=function(t,e){var i=new o(this,t,e);return i.jqDeferred.promise(h(this))})},o.makeJQueryPlugin(),o});\n/*! lz-string-1.3.3-min.js | (c) 2013 Pieroxy | Licensed under a WTFPL license */\nvar LZString={_keyStr:\"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\",_f:String.fromCharCode,compressToBase64:function(e){if(e==null)return\"\";var t=\"\";var n,r,i,s,o,u,a;var f=0;e=LZString.compress(e);while(f<e.length*2){if(f%2==0){n=e.charCodeAt(f/2)>>8;r=e.charCodeAt(f/2)&255;if(f/2+1<e.length)i=e.charCodeAt(f/2+1)>>8;else i=NaN}else{n=e.charCodeAt((f-1)/2)&255;if((f+1)/2<e.length){r=e.charCodeAt((f+1)/2)>>8;i=e.charCodeAt((f+1)/2)&255}else r=i=NaN}f+=3;s=n>>2;o=(n&3)<<4|r>>4;u=(r&15)<<2|i>>6;a=i&63;if(isNaN(r)){u=a=64}else if(isNaN(i)){a=64}t=t+LZString._keyStr.charAt(s)+LZString._keyStr.charAt(o)+LZString._keyStr.charAt(u)+LZString._keyStr.charAt(a)}return t},decompressFromBase64:function(e){if(e==null)return\"\";var t=\"\",n=0,r,i,s,o,u,a,f,l,c=0,h=LZString._f;e=e.replace(/[^A-Za-z0-9\\+\\/\\=]/g,\"\");while(c<e.length){u=LZString._keyStr.indexOf(e.charAt(c++));a=LZString._keyStr.indexOf(e.charAt(c++));f=LZString._keyStr.indexOf(e.charAt(c++));l=LZString._keyStr.indexOf(e.charAt(c++));i=u<<2|a>>4;s=(a&15)<<4|f>>2;o=(f&3)<<6|l;if(n%2==0){r=i<<8;if(f!=64){t+=h(r|s)}if(l!=64){r=o<<8}}else{t=t+h(r|i);if(f!=64){r=s<<8}if(l!=64){t+=h(r|o)}}n+=3}return LZString.decompress(t)},compressToUTF16:function(e){if(e==null)return\"\";var t=\"\",n,r,i,s=0,o=LZString._f;e=LZString.compress(e);for(n=0;n<e.length;n++){r=e.charCodeAt(n);switch(s++){case 0:t+=o((r>>1)+32);i=(r&1)<<14;break;case 1:t+=o(i+(r>>2)+32);i=(r&3)<<13;break;case 2:t+=o(i+(r>>3)+32);i=(r&7)<<12;break;case 3:t+=o(i+(r>>4)+32);i=(r&15)<<11;break;case 4:t+=o(i+(r>>5)+32);i=(r&31)<<10;break;case 5:t+=o(i+(r>>6)+32);i=(r&63)<<9;break;case 6:t+=o(i+(r>>7)+32);i=(r&127)<<8;break;case 7:t+=o(i+(r>>8)+32);i=(r&255)<<7;break;case 8:t+=o(i+(r>>9)+32);i=(r&511)<<6;break;case 9:t+=o(i+(r>>10)+32);i=(r&1023)<<5;break;case 10:t+=o(i+(r>>11)+32);i=(r&2047)<<4;break;case 11:t+=o(i+(r>>12)+32);i=(r&4095)<<3;break;case 12:t+=o(i+(r>>13)+32);i=(r&8191)<<2;break;case 13:t+=o(i+(r>>14)+32);i=(r&16383)<<1;break;case 14:t+=o(i+(r>>15)+32,(r&32767)+32);s=0;break}}return t+o(i+32)},decompressFromUTF16:function(e){if(e==null)return\"\";var t=\"\",n,r,i=0,s=0,o=LZString._f;while(s<e.length){r=e.charCodeAt(s)-32;switch(i++){case 0:n=r<<1;break;case 1:t+=o(n|r>>14);n=(r&16383)<<2;break;case 2:t+=o(n|r>>13);n=(r&8191)<<3;break;case 3:t+=o(n|r>>12);n=(r&4095)<<4;break;case 4:t+=o(n|r>>11);n=(r&2047)<<5;break;case 5:t+=o(n|r>>10);n=(r&1023)<<6;break;case 6:t+=o(n|r>>9);n=(r&511)<<7;break;case 7:t+=o(n|r>>8);n=(r&255)<<8;break;case 8:t+=o(n|r>>7);n=(r&127)<<9;break;case 9:t+=o(n|r>>6);n=(r&63)<<10;break;case 10:t+=o(n|r>>5);n=(r&31)<<11;break;case 11:t+=o(n|r>>4);n=(r&15)<<12;break;case 12:t+=o(n|r>>3);n=(r&7)<<13;break;case 13:t+=o(n|r>>2);n=(r&3)<<14;break;case 14:t+=o(n|r>>1);n=(r&1)<<15;break;case 15:t+=o(n|r);i=0;break}s++}return LZString.decompress(t)},compress:function(e){if(e==null)return\"\";var t,n,r={},i={},s=\"\",o=\"\",u=\"\",a=2,f=3,l=2,c=\"\",h=0,p=0,d,v=LZString._f;for(d=0;d<e.length;d+=1){s=e.charAt(d);if(!Object.prototype.hasOwnProperty.call(r,s)){r[s]=f++;i[s]=true}o=u+s;if(Object.prototype.hasOwnProperty.call(r,o)){u=o}else{if(Object.prototype.hasOwnProperty.call(i,u)){if(u.charCodeAt(0)<256){for(t=0;t<l;t++){h=h<<1;if(p==15){p=0;c+=v(h);h=0}else{p++}}n=u.charCodeAt(0);for(t=0;t<8;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}else{n=1;for(t=0;t<l;t++){h=h<<1|n;if(p==15){p=0;c+=v(h);h=0}else{p++}n=0}n=u.charCodeAt(0);for(t=0;t<16;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}delete i[u]}else{n=r[u];for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}r[o]=f++;u=String(s)}}if(u!==\"\"){if(Object.prototype.hasOwnProperty.call(i,u)){if(u.charCodeAt(0)<256){for(t=0;t<l;t++){h=h<<1;if(p==15){p=0;c+=v(h);h=0}else{p++}}n=u.charCodeAt(0);for(t=0;t<8;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}else{n=1;for(t=0;t<l;t++){h=h<<1|n;if(p==15){p=0;c+=v(h);h=0}else{p++}n=0}n=u.charCodeAt(0);for(t=0;t<16;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}delete i[u]}else{n=r[u];for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}}a--;if(a==0){a=Math.pow(2,l);l++}}n=2;for(t=0;t<l;t++){h=h<<1|n&1;if(p==15){p=0;c+=v(h);h=0}else{p++}n=n>>1}while(true){h=h<<1;if(p==15){c+=v(h);break}else p++}return c},decompress:function(e){if(e==null)return\"\";if(e==\"\")return null;var t=[],n,r=4,i=4,s=3,o=\"\",u=\"\",a,f,l,c,h,p,d,v=LZString._f,m={string:e,val:e.charCodeAt(0),position:32768,index:1};for(a=0;a<3;a+=1){t[a]=a}l=0;h=Math.pow(2,2);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}switch(n=l){case 0:l=0;h=Math.pow(2,8);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}d=v(l);break;case 1:l=0;h=Math.pow(2,16);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}d=v(l);break;case 2:return\"\"}t[3]=d;f=u=d;while(true){if(m.index>m.string.length){return\"\"}l=0;h=Math.pow(2,s);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}switch(d=l){case 0:l=0;h=Math.pow(2,8);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}t[i++]=v(l);d=i-1;r--;break;case 1:l=0;h=Math.pow(2,16);p=1;while(p!=h){c=m.val&m.position;m.position>>=1;if(m.position==0){m.position=32768;m.val=m.string.charCodeAt(m.index++)}l|=(c>0?1:0)*p;p<<=1}t[i++]=v(l);d=i-1;r--;break;case 2:return u}if(r==0){r=Math.pow(2,s);s++}if(t[d]){o=t[d]}else{if(d===i){o=f+f.charAt(0)}else{return null}}u+=o;t[i++]=f+o.charAt(0);r--;f=o;if(r==0){r=Math.pow(2,s);s++}}}};if(typeof module!==\"undefined\"&&module!=null){module.exports=LZString}\n/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */\nvar saveAs=saveAs||navigator.msSaveBlob&&navigator.msSaveBlob.bind(navigator)||function(e){\"use strict\";var t=e.document,n=function(){return e.URL||e.webkitURL||e},r=e.URL||e.webkitURL||e,i=t.createElementNS(\"http://www.w3.org/1999/xhtml\",\"a\"),s=\"download\"in i,o=function(n){var r=t.createEvent(\"MouseEvents\");r.initMouseEvent(\"click\",true,false,e,0,0,0,0,0,false,false,false,false,0,null);n.dispatchEvent(r)},u=e.webkitRequestFileSystem,a=e.requestFileSystem||u||e.mozRequestFileSystem,f=function(t){(e.setImmediate||e.setTimeout)(function(){throw t},0)},l=\"application/octet-stream\",c=0,h=[],p=function(){var e=h.length;while(e--){var t=h[e];if(typeof t===\"string\"){r.revokeObjectURL(t)}else{t.remove()}}h.length=0},d=function(e,t,n){t=[].concat(t);var r=t.length;while(r--){var i=e[\"on\"+t[r]];if(typeof i===\"function\"){try{i.call(e,n||e)}catch(s){f(s)}}}},v=function(t,r){var f=this,p=t.type,v=false,m,g,y=function(){var e=n().createObjectURL(t);h.push(e);return e},b=function(){d(f,\"writestart progress write writeend\".split(\" \"))},w=function(){if(v||!m){m=y(t)}if(g){g.location.href=m}else{window.open(m,\"_blank\")}f.readyState=f.DONE;b()},E=function(e){return function(){if(f.readyState!==f.DONE){return e.apply(this,arguments)}}},S={create:true,exclusive:false},x;f.readyState=f.INIT;if(!r){r=\"download\"}if(s){m=y(t);i.href=m;i.download=r;o(i);f.readyState=f.DONE;b();return}if(e.chrome&&p&&p!==l){x=t.slice||t.webkitSlice;t=x.call(t,0,t.size,l);v=true}if(u&&r!==\"download\"){r+=\".download\"}if(p===l||u){g=e}if(!a){w();return}c+=t.size;a(e.TEMPORARY,c,E(function(e){e.root.getDirectory(\"saved\",S,E(function(e){var n=function(){e.getFile(r,S,E(function(e){e.createWriter(E(function(n){n.onwriteend=function(t){g.location.href=e.toURL();h.push(e);f.readyState=f.DONE;d(f,\"writeend\",t)};n.onerror=function(){var e=n.error;if(e.code!==e.ABORT_ERR){w()}};\"writestart progress write abort\".split(\" \").forEach(function(e){n[\"on\"+e]=f[\"on\"+e]});n.write(t);f.abort=function(){n.abort();f.readyState=f.DONE};f.readyState=f.WRITING}),w)}),w)};e.getFile(r,{create:false},E(function(e){e.remove();n()}),E(function(e){if(e.code===e.NOT_FOUND_ERR){n()}else{w()}}))}),w)}),w)},m=v.prototype,g=function(e,t){return new v(e,t)};m.abort=function(){var e=this;e.readyState=e.DONE;d(e,\"abort\")};m.readyState=m.INIT=0;m.WRITING=1;m.DONE=2;m.error=m.onwritestart=m.onprogress=m.onwrite=m.onabort=m.onerror=m.onwriteend=null;e.addEventListener(\"unload\",p,false);return g}(self)\n/*! seedrandom.js v2.3.3 | (c) 2013 David Bau, all rights reserved. | Licensed under a BSD-style license */\n!function(a,b,c,d,e,f,g,h,i){function j(a){var b,c=a.length,e=this,f=0,g=e.i=e.j=0,h=e.S=[];for(c||(a=[c++]);d>f;)h[f]=f++;for(f=0;d>f;f++)h[f]=h[g=r&g+a[f%c]+(b=h[f])],h[g]=b;(e.g=function(a){for(var b,c=0,f=e.i,g=e.j,h=e.S;a--;)b=h[f=r&f+1],c=c*d+h[r&(h[f]=h[g=r&g+b])+(h[g]=b)];return e.i=f,e.j=g,c})(d)}function k(a,b){var c,d=[],e=typeof a;if(b&&\"object\"==e)for(c in a)try{d.push(k(a[c],b-1))}catch(f){}return d.length?d:\"string\"==e?a:a+\"\\0\"}function l(a,b){for(var c,d=a+\"\",e=0;e<d.length;)b[r&e]=r&(c^=19*b[r&e])+d.charCodeAt(e++);return n(b)}function m(c){try{return a.crypto.getRandomValues(c=new Uint8Array(d)),n(c)}catch(e){return[+new Date,a,(c=a.navigator)&&c.plugins,a.screen,n(b)]}}function n(a){return String.fromCharCode.apply(0,a)}var o=c.pow(d,e),p=c.pow(2,f),q=2*p,r=d-1,s=c[\"seed\"+i]=function(a,f,g){var h=[],r=l(k(f?[a,n(b)]:null==a?m():a,3),h),s=new j(h);return l(n(s.S),b),(g||function(a,b,d){return d?(c[i]=a,b):a})(function(){for(var a=s.g(e),b=o,c=0;p>a;)a=(a+c)*d,b*=d,c=s.g(1);for(;a>=q;)a/=2,b/=2,c>>>=1;return(a+c)/b},r,this==c)};l(c[i](),b),g&&g.exports?g.exports=s:h&&h.amd&&h(function(){return s})}(this,[],Math,256,6,52,\"object\"==typeof module&&module,\"function\"==typeof define&&define,\"random\");\n/*! console_hack.js | (c) 2015 Thomas Michael Edwards | Licensed under SugarCube's Simple BSD license */\n!function(){for(var methods=[\"assert\",\"clear\",\"count\",\"debug\",\"dir\",\"dirxml\",\"error\",\"exception\",\"group\",\"groupCollapsed\",\"groupEnd\",\"info\",\"log\",\"markTimeline\",\"profile\",\"profileEnd\",\"table\",\"time\",\"timeEnd\",\"timeline\",\"timelineEnd\",\"timeStamp\",\"trace\",\"warn\"],length=methods.length,noop=function(){},console=window.console=window.console||{};length--;){var method=methods[length];console[method]||(console[method]=noop)}}();\n}else{document.documentElement.setAttribute(\"data-init\", \"lacking\");}\n</script>\n<style id=\"style-normalize\" type=\"text/css\">/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}</style>\n<style id=\"style-init-screen\" type=\"text/css\">@-webkit-keyframes init-loading-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-o-keyframes init-loading-spin{0%{-o-transform:rotate(0);transform:rotate(0)}100%{-o-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes init-loading-spin{0%{-webkit-transform:rotate(0);-o-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(360deg);-o-transform:rotate(360deg);transform:rotate(360deg)}}#init-screen{display:none;z-index:100000;position:fixed;top:0;left:0;height:100%;width:100%;font:28px/1 Helmet,Freesans,sans-serif;font-weight:700;color:#eee;background-color:#111;text-align:center}#init-screen>div{display:none;position:relative;margin:0 auto;max-width:1136px;top:25%}html[data-init=lacking] #init-screen,html[data-init=loading] #init-screen,html[data-init=no-js] #init-screen{display:block}html[data-init=lacking] #init-lacking,html[data-init=no-js] #init-no-js{display:block;padding:0 1em}html[data-init=no-js] #init-no-js{color:red}html[data-init=loading] #init-loading{display:block;border:24px solid transparent;border-radius:50%;border-top-color:#7f7f7f;border-bottom-color:#7f7f7f;width:100px;height:100px;-webkit-animation:init-loading-spin 2s linear infinite;-o-animation:init-loading-spin 2s linear infinite;animation:init-loading-spin 2s linear infinite}html[data-init=loading] #init-loading>div{text-indent:9999em;overflow:hidden;white-space:nowrap}html[data-init=loading] #passages,html[data-init=loading] #ui-bar{display:none}</style>\n<style id=\"style-font\" type=\"text/css\">@font-face{font-family:tme-fa-icons;src:url(data:application/octet-stream;base64,d09GRgABAAAAACWoAA4AAAAAQhQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABPUy8yAAABRAAAAEQAAABWPihI/2NtYXAAAAGIAAAAOgAAAUrQXRm3Y3Z0IAAAAcQAAAAKAAAACgAAAABmcGdtAAAB0AAABZQAAAtwiJCQWWdhc3AAAAdkAAAACAAAAAgAAAAQZ2x5ZgAAB2wAABjCAAAq+uJ4WNtoZWFkAAAgMAAAADQAAAA2BZlJs2hoZWEAACBkAAAAIAAAACQIJwQZaG10eAAAIIQAAABuAAABOPTeAABsb2NhAAAg9AAAAJ4AAACeojKW6m1heHAAACGUAAAAIAAAACAA6gvwbmFtZQAAIbQAAAGPAAAC/eLsyKlwb3N0AAAjRAAAAfwAAAM0412SIHByZXAAACVAAAAAZQAAAHvdawOFeJxjYGRWYZzAwMrAwVTFtIeBgaEHQjM+YDBkZGJgYGJgZWbACgLSXFMYHF4wvPBhDvqfxRDFHMQwDSjMCJIDANLeC6V4nGNgYGBmgGAZBkYGEHAB8hjBfBYGDSDNBqQZGZgYGF74/P8PUvCCAURLMELVAwEjG8OIBwC4Ywb6AAAAAAAAAAAAAAAAAAB4nK1WaXMTRxCd1WHLNj6CDxI2gVnGcox2VpjLCBDG7EoW4BzylexCjl1Ldu6LT/wG/ZpekVSRb/y0vB4d2GAnVVQoSv2m9+1M9+ueXpPQksReWI+k3HwpprY2aWTnSUg3bFqO4kPZ2QspU0z+LoiCaLXUvu04JCISgap1hSWC2PfI0iTjQ48yWrYlvWpSbulJd9kaD+qt+vbT0FGO3QklNZuhQ+uRLanCqBJFMu2RkjYtw9VfSVrh5yvMfNUMJYLoJJLGm2EMj+Rn44xWGa3GdhxFkU2WG0WKRDM8iCKPslpin1wxQUD5oBlSXvk0onyEH5EVe5TTCnHJdprf9yU/6R3OvyTieouyJQf+QHZkB3unK/ki0toK46adbEehivB0fSfEI5uT6p/sUV7TaOB2RaYnzQiWyleQWPkJZfYPyWrhfMqXPBrVkoOcCFovc2Jf8g60HkdMiWsmyILujk6IoO6XnKHYY/q4+OO9XSwXIQTIOJb1jkq4EEYpYbOaJG0EOYiSskWV1HpHTJzyOi3iLWG/Tu3oS2e0Sag7MZ6th46tnKjkeDSp00ymTu2k5tGUBlFKOhM85tcBlB/RJK+2sZrEyqNpbDNjJJFQoIVzaSqIZSeWNAXRPJrRm7thmmvXokWaPFDPPXpPb26Fmzs9p+3AP2v8Z3UqpoO9MJ2eDshKfJp2uUnRun56hn8m8UPWAiqRLTbDlMVDtn4H5eVjS47CawNs957zK+h99kTIpIH4G/AeL9UpBUyFmFVQC9201rUsy9RqVotUZOq7IU0rX9ZpAk05Dn1jX8Y4/q+ZGUtMCd/vxOnZEZeeufYlyDSH3GZdj+Z1arFdgM5sz+k0y/Z9nebYfqDTPNvzOh1ha+t0lO2HOi2w/UinY2wvaEGT7jsEchGBXMAGEoGwdRAI20sIhK1CIGwXEQjbIgJhu4RA2H6MQNguIxC2l7Wsmn4qaRw7E8sARYgDoznuyGVuKldTyaUSrotGpzbkKXKrpKJ4Vv0rA/3ikTesgbVAukTW/IpJrnxUleOPrmh508S5Ao5Vf3tzXJ8TD2W/WPhT8L/amqqkV6x5ZHIVeSPQk+NE1yYVj67p8rmqR9f/i4oOa4F+A6UQC0VZlg2+mZDwUafTUA1c5RAzGzMP1/W6Zc3P4fybGCEL6H78NxQaC9yDTllJWe1gr9XXj2W5twflsCdYkmK+zOtb4YuMzEr7RWYpez7yecAVMCqVYasNXK3gzXsS85DpTfJMELcVZYOkjceZILGBYx4wb76TICRMXbWB2imcsIG8YMwp2O+EQ1RvlOVwe6F9Ho2Uf2tX7MgZFU0Q+G32Rtjrs1DyW6yBhCe/1NdAVSFNxbipgEsj5YZq8GFcrdtGMk6gr6jYDcuyig8fR9x3So5lIPlIEatHRz+tvUKd1Ln9yihu3zv9CIJBaWL+9r6Z4qCUd7WSZVZtA1O3GpVT15rDxasO3c2j7nvH2Sdy1jTddE/c9L6mVbeDg7lZEO3bHJSlTC6o68MOG6jLzaXQ6mVckt52DzAsMKDfoRUb/1f3cfg8V6oKo+NIvZ2oH6PPYgzyDzh/R/UF6OcxTLmGlOd7lxOfbtzD2TJdxV2sn+LfwKy15mbpGnBD0w2Yh6xaHbrKDXynBjo90tyO9BDwse4K8QBgE8Bi8InuWsbzKYDxfMYcH+Bz5jBoMofBFnMYbDNnDWCHOQx2mcNgjzkMvmDOOsCXzGEQModBxBwGT5gTADxlDoOvmMPga+Yw+IY59wG+ZQ6DmDkMEuYw2Nd0ayhzixd0F6htUBXowPQTFvewONRUGbK/44Vhf28Qs38wiKk/aro9pP7EC0P92SCm/mIQU3/VdGdI/Y0Xhvq7QUz9wyCmPtMvxnKZwV9GvkuFA8ouNp/z98T7B8IaQLYAAQAB//8AD3icrToNcBzVefe9/b3dvd29u909/dyd7ke6k86yLEunOyHJsrCxJWyJGmEcLMDYxBhHNsZQBzOAkjQmFDrGIq5gHEIcCILOAGZq3IQO04RkIGkgaUMKMbQznSlJW0wgJtOQHxRr1e+93TvJwq7JTD3y2/f//bzvfX/vAhAIzL3KPcYNBFIB8UR9EJYuAcuAqGNbOiwDSczkuorlaJ6WTeVSRwMIDveY8aN20GztjzMhW4P2H+kNUPM5NaVNQE0K3tWM77vv8rJqgnT33VJE4WWIfd/QbKHZjcXcZiFAqjCDgUJA/mZTWOIIwi0vAwNiUjkW9THIZs6DAbnj6ffGP/P+0y2vv+5SXGLKuXHJPJH92c+yT7x3883wnI9W/DxI4T9+bm7uOL+MUwNywAg0BJYFQgNKa2NDzFBEjqeM0SFXLHU4YKe7yjFoSmdEKWw5nemOUj5czMXCliilM7lyuFgqp3HaDf1j/fhH+s6cfm4MEpA8c0BSQBO5CUkD5fJi05kDjSUoNnETTUUSXtpPVm0aGHDdmV0nNkPiMUWeHZMVRSZPSlp0dqypCKVG8iT9IK5AEeamyZGAjecW5tm5SSBm8ojiSqBsYoXDTRtuymw13V8axjB+p2EPlsMGcRzTTRkGOLRpmk/AzSZ+A97ecx+QN8g9gUbc26F7N+GJiN5pLGMA8hUo7EQcHI455A0PwrS3I37N+bZhTE8bex1aeeIJ4+MTjTY6gcH+iIvgGWQRdh2TR9sS81kspCzytguLfBcyuBOLXuhwYnZnh8NFUs6plLPLScGpWBKwkYztwsop7Hie9r7rYK/9brWXTg9U+RiBX+GJiyc0rgIv7UNJe3vPjrFdyZOV/byNUkyW/0AuIi/h+h6U5a64SmW5ieGcya2AYimG+EUtnZN08ImgveV+KOYykiiJVMrbkI+dHUkC9+nyPUFdD94j639r1uTq7FiSNrR1hXS8uLbGapYUSbpaJvzmp5aODbU9iJNBU1gJa5LFTCqihNpDigmWWtc2GjUy7Y2m3hHk14qmPJXp2cTInZudO85dhzw2AuXAJQHl+Yt7l0RVjkO8u4q5JZARE2A5yNxStNgGWcQSj7izA1HucCgJOsRsb7xYWgn9XAwvRqaN4HAS4ENF3kXFFovJ/muW3zsYDK3jxaCQbOouOPXZPmBDNZG4krS0N2/9wakf7hHv+IcPX/jcaGWZAp9fvrFtv66UeSlXn4zYdZo5kLNwIJJRTbEu3jz62Zf37Xv5l7RAeugZfAQ7kJ5koA3PoJB1eP8MpHRVWqpygyITpiKz4DCoHMENlun+wrDA0bNZ9jmJZdZwhhx9UnewMKztg2yAlie9j6O7Lzrks7tYdRdOO4u/FJ9e5G93RyFTJ1f5G17IZDs7z25uEfuFBYwlvYpUUuTnKJO6umg5IymD88yGGxbycjN2JOkIVk6wUoEzm/0O5T/Owb92Jg8NyL/6qFrl30IZ5nSgMp3nch7DkvOMCaMeoQ1U4JZxQncenmAMmcAei/S7V9CvAccW8mczwtMCceSQ8nwhXWuKAeQPJbRCc9RnhoSyhvBL+WgxTzsk0Y567IFj+35wa4Xq7ykS5YIm7UIdq4iCfKcsiIoSvFFWONUnFovZoXHKhXE69R9hTOIEgZPcJ0VZRrx+i3j9hhtFPqQDnYjX8uaEpS2+F4twiVkOylSJAwfvBZO3XBnoTaEHtltSWAGKIEl3SJIQ1CRESIRnLFtJRc88GckEbQuOBTO5zBXziL0JIPKiyMtzggwiMc+czmbDEbDMbJaLhC3LPzPuFOKaD6zEM+tt15gNxTPLIg5dvglCfGmbmakYmqmKsEfRVOWWAXjqvEzVeamT6botq9321Vu2rIb7KOrufmZ24LWmoiI3yspJJ65e704JprBSFGH3pxXLhAQe9fBzbM1rq7YAm1dsctvZSiqu8G94rxwS/LQ7JYorRR0XXq/GmSh4dJADKAsSk70ajQ8gHdE0MhzVjOCbVDSvKINd1PhKVN+fgMTG2zYCvIaq+V2mmsNTP36IRLD6xO7ejWTDisfc7zCVD6tQW+/eMTW1Y3fSt20foe+hBZpQ3zfGfH3vyzmCZNvHFoJFVPrRjj7m6I26M3r7KHQxgD5c2H/4tQdIeJLJ+yQDvTsZOwv4jYfJQxVaxxmtKtNTTVaQnRmS6kkWvfBoNvCeIT55jt41PJZwpg3YYeJYGK+dppgK/sF+R/8ggZIOBlnyNoK/qpwokLZ6uCFRKCTKV8HeGaYksPg2Xj/3fyQZb6dhGWv2QLLQU4DW7lZwf77Hw+vb3AjzexKIVywkEXoGlB1JUqr4FW3A7BZlDzgzhZ5W0tyfI1da7mmn13JvsZOFxLuJIRsmLXJVskByA41iu/uvSds9bWOnPZQ4lSgANm+xqQ6gMPlGH2YR79rSDIXLXQBujHZSxkCpSIeynwCdNxEFJ2HVmSDaFPxQYoIN2BfCM8E6zTCu66VDSQ97KkPfIa8i7nGUITNAZagDhYFJjeg5rXh+bcBuYamT/JWmRVE8Iopeb/3ud1ZdSIs4TkQLcaogJ63Z5dGUxEfefz8qSKko+Qm2PB/ZgyEEMngmjkjovYB0GBog+n9COzD7MiQ73pfOA5S8NLseIst+QWbPC9y/J8dRv7QFliCNWcnzAYlI3fE8hdNVbBPY1WEeZxm8m5mKOdypQRG1qhiRgQBnZbr7N20qT1ipoPsLVYWEGq8hE3BoLPn2tV8PhWVe0WTB4nIN3WMD7cmIiDZEhaSSROulWMbk2+sX4LIs0Iq4NNdUfV3mDeqCbaEOligmbYSFCaU0VRVULrhTKoKlIMubNvV3ZyyOByWMilXkBpNjcIjihTjBrwzF/bmKF1iMJNsHxrobcnxElDVF0C3u69fevP5txIsEcUrVZyR96DPqiI/C+zGTp0uZGkXVP6PG1RncET7Ey/eKjnX885QeWw83krsCIVyvMp8TD9P3rEvMFUkFZxS6Rw25ytWQJ/52/tqLyQSDrc7Dpiq/H2XDgYsVBgjnK7BF95EwLKLNKLh0bg5x74VXPNwJO1fq7raB588j7pbhat78pDKjPE1td1Jl6Hhn8Q73LdISsCrrgwuijljQ28Tinnavx+Xu9ap6jYqn2QzNaly7RoVJ99MoBl/DvmtU1X0Lu3FCnO37XXKEW832Nai8BYnDKKvIF92W3F9dotK94ahCNyJPuW+5b2L1WrQ2X6fSc1TBejLg77uvsm8FX2b1ghWk6cbjuB1FUIVm9y0f6aMKfMbdhjshNGihFKgIgE7044ZvkbXz+zbh3chXN/f35Z6mOyF2b/m7H6V7HVV3XYOYtiDOig/J25bh+xPuAPMdxRPRc8V1YU8Z2mEv9OIO2O6DTg8Wtt2C3+lCcjBRmEaNVbDhi0nLnUK1ttvqdVpsexruQ93WGnf3T9s47N+te7nN5FeohRGeChUfIvZx5htAPYTNjQl/ea/tTlkW7LZ7nIK3dyNsGUwWpq0+a4k/ALvozB5nurkCqwthUdrq5mnzBD/tu5rpfPVYuC6L0VZwnMfd/YnGxgTc97jjFNjGFvRQ6iyrYPfZjyPVyQJM233YRF5YVb1xgLzjwVMX3NOwZ/K7wtJZx4W8pGRNNzf4ZOBeCKgPCxuKcUYmxQNycbjP5wGlEJGk8OZc369tR3gtaZ+X6CbmVkIONRVJcugpluk1TQL1Fqmfy1ELVi4hYy1zJhYNj4zu7RkfbuebN17fv+q2Fj4sDgtE7Hv2uk89uneIH7j9yNWjR1YMmUvJSzO6s9QcGWkbHt83PtzW0yWCMMLr4roNcMm+o88e3XdJ/0VDkWiFDxSv5YhXq8d3nVAryjjtoDXp7Ojn2gg6ijGHIUxDpQZ0Y2lQym2+5NZHN219to8XhsUw33Lb6p6dG9DVGN598/bmkXA0NoPeR2t4qO/h0U8d3bcKtmB5yeilos6PCCB29fgINjeNmEsdfaYmGhm6qB9RrPhEx7mrEbfGwCDauZXNJo09wLJ1oAhSe1NxWkUDKKJofMqeE+szt8S4K9JYmjbLXRRtylOU1vWN//mVy4/0DVGNqM9QJT7SvL287ot5MSZoGC/oyHTWO7p3vdd5s6RB439/5fKH6aIaEDh46AVkpMqWo1YdaWpe1690hzT4e79jxGuLvD+R0iUwuiJ+TLUM4+yrA8aAdsVAsX1JFgMsTkCF4ceBdtgLZ8oXaENnPpfPipLA6A57nn4+XI1hUbCoYmig1KP5pH44Kybnq4cUyatKivvTmXpeOC7y8J4il3yHncWVz+SDrc5zTqucPyYro3Af7XP30/I8ddJxsQAgXIFbz37QdsmqNhJl0K6145C0rkWzExAX8aM3sDpwYyA8oF83PNBXWu7xRPQMIT1E6syw7M4F2tFwOmyhVKQ7+uH/lz9DribLBF4jsuze94lYBc+7LzLOXMw4c+66u52EZz/QLEWxyA0XZFuA9+OVUfSTwyzWCw0o3a0Jx9BYTrKp2AZiEi9qGSs6OFhZkPboRDXesZKpbcd3UOjV8dMgNNQhr1pJh0Qy5petVIQ48Zq1KefMj7zIhluf3pQeBs5JfUuJMGcgHFRik16gP1mzHX2EmroaYhmVysETLOo54aSGU/gHzbEwdRvCMXuGhUczHj3HkZ42Rk9LYIDS07c8YRuqSBg91Pmnwo8VghFR2Y9oKTmxziSwi0HTN2I1cMvT3E7Fezk/Pae1UnYyUwqdRnqCNZPoXSJSk6hxGWmRBKqBSMqyTP97/wmaJcQCGpqbG5Iw6vhEtHpEVWihepULpFG3rqG0rOha2qTxJIC0YOSYFjrxEtP8nlSlIxvu7PLcRKmS76mk04Sq0HoTqJ04CcfcK+DDIU34mhCX/dByaAiDy58ibicVeRdNJrNyezI2G/ESlUKsZDxiOtLJk/ChXCc9Imp+1nO2xL6QZIkkWiizM7SHIF9q9K8ZpQDx8zOjgWaMzORvdrSGPJ2sEzRYZer9O2gmWD4zSTr6sSuH8Uc/IGjmyLIMOHUV0G48840967ixy2v6zIhcU+pr3bDj9u0bc1xfqUbO9sUuH3O/iqEbFPqaPbOBZuFTO57rx7mxvnDL7avRFLah/ei55LZCpKddjqz4OxhyH6YRLuzA0rcfY5yC8rQTcb08JdLYleZW8TZ0lGgSCyVfQoQtRDiPV6BqKLryzL7kqRmkuoGdE5UzlKWy39mJQlU1OChf1KrEHOYcsdMhvaO3j5JN+zZBXJZ2Kmq0WRSMDSFJGqmtC0q8eZesmfWxPxNNca3DC3KzYsg7MBBXhJ2yHmvy5sojNXVBmQvfhUdoxJ0NgiENWTzfqwd3SOjC927ceNvGjbfTUTNp13eIumhvAKEvJA/HTUW6Maj1CeJAUtBFrcOI1xugSWxubV1qqaRJ1gZvqiHLbKqwOo5TR9hELw7/iBsjL/t6WXl+SWN9VOO5RfnTtJcwreTFY35bWthGB+bMB+yOcGEDg4bztxbkUR0wh1h2kJWgV0awMR+Hjvn5mlrmu9BMCMpYsZynmQC8KR2xco4maZIg5jN5CU86ViJ/s27nzqlxgFc6167fuXP92s5XYOdDO8j4pYNYw16IjR8eH79U0ra3Y6V9uyat20l2P7AbsKpjJ81Tzs39nt9PXgqYeL9LNB+Yi9uMN1BEZ0knnvijDiZLEDg6dJ30NuA9oQEVh9U0uk/kgO8A+R94pvWy8YveWn0ZWbfmLepJXdqz5Z5B94qhu7d2k75r7l0Lx2gVtvTMr6FXgDY7p56d6qSNS+/e0ke6r//CQ1/YXiTdW++u+FK/529HfC3klvzNhK3Te4txIUFlkuQ8tIjguXrUG6WAPWgMsIcDF664d3v3DHXwhQ07YMul2I9QDvtQXz+bokoej3uUo5mt1Qi7f/m58pGoIAyavsnnFiUl8cbhKTpRmI+CKw9Y1oKc5GvZZJCT6kWJcCHNzzDS3KTQKEocr/6Fe1GoUf+1rq/QG/W/hs9goz8E649Xc5M6HxXjAnDV9OT9spBFuwOC26Prv2bzQ3RhCHfwaYpW8+LxqOzlYOZR7/Kf/RbmXMktCzAr3jWP/Kqt5KUqZDq4uTqyBbYGfL17HcuL19KcjykyePSoAP2bNgILH1qOXXFwA9l471P3bOIvOwRXL8j+k0OjB6cPjrLCfe2sXP/824QcsAMZlOmGWiMo0rwb4K1qo+mH/LkBVlXdA+cFXFFWvz0//AXvbZ6+ac3GoyzHHvXfzCqvNILfLi9qV7KBJ/03OPbql/A+XlcDa3g9C1/rnPPU/XzkR4E3q/4p6kHES6V3vVx1M7x3EG4RnpwfhuT9B8mTF4BG6w/vZp7SbtoL4oJBkCuYe2+LL3GT6CtdzGKjNas6FGaHETyqOIeljCSdy4azYTwkLxFIL08OHSKaM+7sonl9vERpGguhHaS5bUgz24xu3ETTPsVKqntkIZfpqR1MdBfQKd6hmiFHviU1QZ260MQ2FSOcbfDmVoyFeHkb9rq/db9KFWsP6uutqz6LgZW6R+JrIjp86Gp6jSXL+7RoUv38yjEracH0NiVpKdu2ISBl27QDRdTKAT9WHoc/IL/p7w4sptcdmtpFR6IcZRnNXDnaT909x7Ykjj6PwmlFdP9FMuWgQvb8nAiKpHB7iS4/r+pk678LRCWOGpq9QwfOlOGlbpDkEPwThngKL7puibAY5LvMl+ZQQ8Yx4mxF/wZjkGJ7a3NjKl5jyjiJ/hAhLzVVExN+9qMpZsAyWImhu/eF2NlfcmS6bxq6lNlO9CZvxpjon/G7R5k1SqVwuFwOv3HTTZn0TTelSQs2wtjpPkNH8D/RH++b3mkosx0KLkzSlfi92qSrzPKX2arMTe692ChjJ7T5I75t3I487EIe5jXKQ6pg6Q83qs/lEn3noSFynmb4aOrBF9sEoBuHhKFYcL11up41emofLCQGE60wVdeDClSvn5qqM41Go7t+iuWUHqzrNrOGWTsFst5TtwLXXPk0Syc9fSX2rsBFmzadY6C/Fge8d+e5uXHkfyiQRc6vwTu2Ylkhz95Fq2/8+YVv/CxSqb7xxyqhDjDBRxFBxcQnSYzeBfrYNqGJjej4TLDfWEywII42hqZ+/BB/6I2DkCn0WS9uv3PD4Z0DpG/3oemDe7u5NS/aMOWtol60t2qCusYTSi19uHn1iHiQOpz2i2v6xx/4xqE9PfyqHQ+N3Ln9RftsmoxADcYAyvMt9Y73lr7wdwTUmb8g/u53GOaw6pPizJC9MJrEj7noG9sG1CNhmWN2BcF2dpRzGBfz5XrojEWZRxuj6aCYY0tiLJOTMmK2uJJQjxj/8hjKEB1iGHCj4JTpxczQzEtehAevG+5pUO12twtCjfG4I979yJB4a7RlZbDdVGV1OMgDQPZQY+ERm1wqiVyYJwJHMrGaP+o9YKbUlE2ApL6YEiyylNT9ESff74qtvCgqNSZcBVOa+2Hr9q9E70rVikGTcxRJ4BSQa6ImzpQIEXk+OFbqhvQRQ4souDWotqAiL2Xqm+AZ/Yz0kXcCOnvfqg1779vzOXtqtvPMii9Ig5+dwj87Kf4bQ6EJfdRt4PyQZYFY0/NXERbE5vPzi+As2njhToFqfp7h6ufXYTFiZ6MCryyG/xQX5qIBFddLfr6b+SYsHc3P1ocikRD5rxCMuNslxeBKuiZjzQpUY6kFvwNgPtyioHRxkEr9fv+HE5AwHFc9q0neOXOa/kiAi9ByQX3et1fZb2+q7yCL914QN5y1GVt/DOVaR29JPCECXV9iGaI84A7sQ9W3Y4dLZe4vVR1Mxd3Hc7rq7lNVOKjqHM9xqmiceVWXNTgoiO6fswpN0R/EfnefyHtnMvcsdw1nzMOJiSzGpQ+SPmclxmVRqlVM0HG5wNFSQYAIRhjE3ZDTsobwJbifVegTxj7sx7mCRwvp5XSWh6/QYs/TwjyMahKsVCYZVaeECMTR56MplPyzCfrSPO/dL0m8RwvpQ1oS56aF7i/58Mpn0eOHaKxcTNGd84cLd4oCvXPu3B+4a8kPUA7rmSzJ7E3Zy7OzuJEm/Mt+7Eh/pyDPMx7xF7luuh/CY9hDe4WZYLqvW+YhFlJiWX1PO0aOB6L0t3AVOUK7V/XSqP8Dx/CavHCY8erwC3jhyKHZR2nu9wXvpz4vKN4dwOIA22sZ/S1RTbhyBxbvF/XeXzEQpfEUTa0hLTTE+RigN9vzQhBp0RzT5OUaKazwlhEU8u0fx8D9XmGdwVmmZmpavDGuichhJJUz1nn5pp9yj5H3GG7DgZtovmnn5YNFiiT/JyIZqw6Uvd+i0TRIFwumFw7SVEg/TYvQDM/8hE9O4uTWEVlECuyU2tLW1oKK3jIk+bItDxy6TZKw36mttdZgKDxo1fIRzrFMSbrt0J/Cl8KVh1OcozuqGUyO7RxLBk3UrA6XfmDTF97qwAErpOl655GnjnTqOidyIQsHO08G/hcLt/j/AAB4nGNgZGBgAOLaW41M8fw2Xxm4mV8ARRguss1QhNC5H/9//Z/FUsEcBORyMDCBRAFTFwxveJxjYGRgYA76n8UQxVLGwPD/FUsFA1AEBfgBAHyYBUh4nGN+wcDAvACCWfSBNIgviMBM1kA6koGBMRWVBqsDYqYmiF4wHQkxg+kUBMPVWEP0gTDYvBdoahZAzYxEY0ciuWUBFjkoZimDYLC8IKpehmsQccYvSGYgYZB7YBhFL5o8cxTQjDUI/wIArpclrwAAAAAAAAA6AIYA3AEKAUgBgAGgAfoCYgKqAwIDOgOGA9wEQAR4BLYFAgU8BZoFzAYMBlIGmga6BtgG+AcYB0QHcAecB8gIAAg2CG4IpgjyCUAJrAo0CtALOAueDAoMYA0ADVANjg3mDiQOjg7GDvgPOA+ED84QPBB2EN4RNhGgEfISchKoEsgS6BMGEz4TXhOSE8QT+BQsFGIUiBTWFX0AAAABAAAATgBuAAYAAAAAAAIAAAAQAHMAAAAiC3AAAAAAeJx1kctOGzEUhn9DoIKgLloJdcdZIRDK5CKhSqyoogJrhLJDwgyeSzpjRx4HlGfgLcoz8Dp9j+76Z2KhqFJmZM93Ph/bxx4AX/AHCqvnnG3FCgeMVryFT/gReZv+JnKHfBd5B108RN6l/xV5H2d4idzFV/zmCqqzx2iK98gK39RR5C18Vt8jb9P/jNwh30fewaGaR96lf428j4l6i9zFsfo7drOFL/MiyMn4VEaD4bk8LsRRlVZXouehcL6RS8mcDaaqXJK6OtSml+lemTrb3Jp8Xmm/rtZ5YnxTOivDZLCur401XgfztNytec5HIWSSeVfLVdxHZt5NTRqSIoTZRb+/vj/GcJhhAY8SOQoECE5oT/kdYYAhf4zgkRnCzFVWCQuNikZjzhlFO9IwvmTLGFlaw4yKnCBlX9PUdD2Oa/Zlay1n3dLmXKei9xuzNvkJ7XLvso2F9SaselP2Na1tZ+i2wqePszV4ZhUj2sBZy1P4tmrB1X/nEd7XcmxKk9In7a0F2gv0+W44/z/KQo7lAHicbZLnlpswEIW5Bgy4bLLpvfeE9N57z76DLARWEJKOEEucpw8CO/kTncOdT6PhnlHxRt4wJt7/x47nYQQfAUKMESFGggmmmGGOLezBXmxjH/bjAA7iEA7jCI7iGI7jBE7iFE7jDM7iHM7jAi7iEi7jCq7iGq7jBlLcxC3cxh3cxT3cxwM8xCM8xhM8xTM8xwu8xCu8xhu8xTu8xwd8xCd8xhd8xTd8xw/sBLUlZuIkZZW2q0hzahvDRqocUyIpE4EWTR1WXDZ1sGRCz5yklBsqWBZwmauZk01mTqxl0nIlUyLs9r/Zej35m4kFl2XKftlAKFomTlKlmfQ1l74lRdB9dbxQqqyIKbc2MPQZGqbFKsqVaYnJ4ky1Ms24iQXLrYPE8GLZ07jRfaIvcf5JX+NoMhQ5jLoqFwenBS8Gpw7WTh05py6MaOtT2ibEGNXWKW1Da0i9nPY6dNe7CEWy7pc+5EJpvfJVnvtUFUHFZBPWS2LYxKqiECztVpINypAuGS2nvQ6Gs+H0hsk0U3ZznDETguua1/MNpLvMWH/RFGEuuobCihScxqS2zPC6jH4rVaVcxn1UjQ1yJW1QK2MTJ6nrPOqp0d3Vk1WoSVOz7p0oHeWdTbpoh5i3sVWpezp23AGTWch+Mmonu0o0Vb+l6RqdabLmRnveH9ru7j54nGPw3sFwIihiIyNjX+QGxp0cDBwMyQUbGVidNjIwaEFoDhR6JwMDAycyi5nBZaMKY0dgxAaHjoiNzCkuG9VAvF0cDQyMLA4dySERICWRQLCRgUdrB+P/1g0svRuZGFwAB9MiuAAAAA==) format('woff')}</style>\n<style id=\"style-core\" type=\"text/css\">html{font:16px/1 Helmet,Freesans,sans-serif}#store-area,tw-storydata{display:none!important;z-index:0}.no-transition{-o-transition:none!important;transition:none!important}:focus{outline:thin dotted}:disabled{cursor:not-allowed!important}body{color:#eee;background-color:#111}a{cursor:pointer;color:#68d;text-decoration:none;-o-transition-duration:.2s;transition-duration:.2s}a:hover{color:#8af;text-decoration:underline}a.link-broken{color:#c22}a.link-broken:hover{color:#e44}a[disabled],span.link-disabled{color:#aaa;cursor:not-allowed!important;text-decoration:none}area{cursor:pointer}button{cursor:pointer;color:#eee;background-color:#35a;border:1px solid #57c;line-height:normal;padding:.4em;-o-transition-duration:.2s;transition-duration:.2s;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}button:hover{background-color:#57c;border-color:#79e}button:disabled{background-color:#444;border:1px solid #666}input,select,textarea{color:#eee;background-color:transparent;border:1px solid #444;padding:.4em}select{padding:.34em .4em}input[type=text]{min-width:18em}textarea{min-width:30em;resize:vertical}input[type=checkbox],input[type=file],input[type=radio],select{cursor:pointer}input[type=range]{-webkit-appearance:none;min-height:1.2em}input[type=range]:focus{outline:0}input[type=range]::-webkit-slider-runnable-track{background:#222;border:1px solid #444;border-radius:0;cursor:pointer;height:10px;width:100%}input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;background:#35a;border:1px solid #57c;border-radius:0;cursor:pointer;height:18px;margin-top:-5px;width:33px}input[type=range]:focus::-webkit-slider-runnable-track{background:#222}input[type=range]::-moz-range-track{background:#222;border:1px solid #444;border-radius:0;cursor:pointer;height:10px;width:100%}input[type=range]::-moz-range-thumb{background:#35a;border:1px solid #57c;border-radius:0;cursor:pointer;height:18px;width:33px}input[type=range]::-ms-track{background:0 0;border-color:transparent;color:transparent;cursor:pointer;height:10px;width:calc(100% - 1px)}input[type=range]::-ms-fill-lower{background:#222;border:1px solid #444;border-radius:0}input[type=range]::-ms-fill-upper{background:#222;border:1px solid #444;border-radius:0}input[type=range]::-ms-thumb{background:#35a;border:1px solid #57c;border-radius:0;cursor:pointer;height:16px;width:33px}input:not(:disabled):focus,input:not(:disabled):hover,select:not(:disabled):focus,select:not(:disabled):hover,textarea:not(:disabled):focus,textarea:not(:disabled):hover{background-color:#333;border-color:#eee}hr{display:block;height:1px;border:none;border-top:1px solid #eee;margin:1em 0;padding:0}audio,canvas,progress,video{max-width:100%;vertical-align:middle}.error-view{background-color:#511;border-left:.5em solid #c22;display:inline-block;margin:.1em;max-width:100%;padding:0 .25em;position:relative}.error-view>.error-toggle{background-color:transparent;border:none;line-height:inherit;left:0;padding:0;position:absolute;top:0;width:1.75em}.error-view>.error{display:inline-block;margin-left:.25em}.error-view>.error-toggle+.error{margin-left:1.5em}.error-view>.error-source[hidden]{display:none}.error-view>.error-source:not([hidden]){background-color:rgba(0,0,0,.2);display:block;margin:0 0 .25em;overflow-x:auto;padding:.25em}.highlight,.marked{color:#ff0;font-weight:700;font-style:italic}.nobr{white-space:nowrap}.error-view>.error-toggle:before,.error-view>.error:before,[data-icon-after]:after,[data-icon-before]:before,[data-icon]:before,a.link-external:after{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}[data-icon]:before{content:attr(data-icon)}[data-icon-before]:before{content:attr(data-icon-before) \"\\00a0\"}[data-icon-after]:after{content:\"\\00a0\" attr(data-icon-after)}.error-view>.error-toggle:before{content:\"\\e81a\"}.error-view>.error-toggle.enabled:before{content:\"\\e818\"}.error-view>.error:before{content:\"\\e80d\\00a0\\00a0\"}a.link-external:after{content:\"\\00a0\\e80e\"}</style>\n<style id=\"style-core-display\" type=\"text/css\">#story{z-index:10;margin:2.5em;-o-transition:margin-left .2s ease-in;transition:margin-left .2s ease-in}@media screen and (max-width:1136px){#story{margin-right:1.5em}}#passages{max-width:54em;margin:0 auto}</style>\n<style id=\"style-core-passage\" type=\"text/css\">.passage{line-height:1.75;text-align:left;-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}.passage-in{opacity:0}.passage ol,.passage ul{margin-left:.5em;padding-left:1.5em}.passage table{margin:1em 0;border-collapse:collapse;font-size:100%}.passage caption,.passage td,.passage th,.passage tr{padding:3px}</style>\n<style id=\"style-core-macro\" type=\"text/css\">.macro-append-insert,.macro-linkappend-insert,.macro-linkprepend-insert,.macro-linkreplace-insert,.macro-prepend-insert,.macro-repeat-insert,.macro-replace-insert,.macro-timed-insert{-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}.macro-append-in,.macro-linkappend-in,.macro-linkprepend-in,.macro-linkreplace-in,.macro-prepend-in,.macro-repeat-in,.macro-replace-in,.macro-timed-in{opacity:0}</style>\n<style id=\"style-ui-dialog\" type=\"text/css\">html[data-dialog] body{overflow:hidden}#ui-overlay.open{visibility:visible;-o-transition:opacity .2s ease-in;transition:opacity .2s ease-in}#ui-overlay:not(.open){-o-transition:visibility .2s step-end,opacity .2s ease-in;transition:visibility .2s step-end,opacity .2s ease-in}#ui-overlay{visibility:hidden;opacity:0;z-index:100000;position:fixed;top:-50%;left:-50%;height:200%;width:200%}#ui-dialog.open{display:block;-o-transition:opacity .2s ease-in;transition:opacity .2s ease-in}#ui-dialog{display:none;opacity:0;z-index:100100;position:fixed;top:50px;margin:0;padding:0}#ui-dialog>*{box-sizing:border-box}#ui-dialog-titlebar{position:relative}#ui-dialog-close{display:block;position:absolute;right:0;top:0;white-space:nowrap}#ui-dialog-body{overflow:auto;min-width:280px;height:92%;height:calc(100% - 2.1em)}#ui-overlay{background-color:#000}#ui-overlay.open{opacity:.8}#ui-dialog{max-width:66em}#ui-dialog.open{opacity:1}#ui-dialog-titlebar{background-color:#444;min-height:24px}#ui-dialog-title{margin:0;padding:.2em 3.5em .2em .5em;font-size:1.5em;text-align:center;text-transform:uppercase}#ui-dialog-close{cursor:pointer;font-size:120%;margin:0;padding:0;width:3.6em;height:92%;background-color:transparent;border:1px solid transparent;-o-transition-duration:.2s;transition-duration:.2s}#ui-dialog-close:hover{background-color:#b44;border-color:#d66}#ui-dialog-body{background-color:#111;border:1px solid #444;text-align:left;line-height:1.5;padding:1em}#ui-dialog-body>:first-child{margin-top:0}#ui-dialog-body hr{background-color:#444}#ui-dialog-body ul.buttons{margin:0;padding:0;list-style:none}#ui-dialog-body ul.buttons li{display:inline-block;margin:0;padding:.4em .4em 0 0}#ui-dialog-body ul.buttons>li+li>button{margin-left:1em}#ui-dialog-close{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#ui-dialog-close{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}</style>\n<style id=\"style-ui\" type=\"text/css\">#ui-dialog-body.settings [id|=setting-body]>div:first-child{display:table;width:100%}#ui-dialog-body.settings [id|=setting-label]{display:table-cell;padding:.4em 2em .4em 0}#ui-dialog-body.settings [id|=setting-label]+div{display:table-cell;min-width:8em;text-align:right;vertical-align:middle;white-space:nowrap}#ui-dialog-body.list{padding:0}#ui-dialog-body.list ul{margin:0;padding:0;list-style:none;border:1px solid transparent}#ui-dialog-body.list li{margin:0}#ui-dialog-body.list li:not(:first-child){border-top:1px solid #444}#ui-dialog-body.list li a{display:block;padding:.25em .75em;border:1px solid transparent;color:#eee;text-decoration:none}#ui-dialog-body.list li a:hover{background-color:#333;border-color:#eee}#ui-dialog-body.saves{padding:0 0 1px}#ui-dialog-body.saves>:not(:first-child){border-top:1px solid #444}#ui-dialog-body.saves table{border-spacing:0;width:100%}#ui-dialog-body.saves tr:not(:first-child){border-top:1px solid #444}#ui-dialog-body.saves td{padding:.33em .33em}#ui-dialog-body.saves td:first-child{min-width:1.5em;text-align:center}#ui-dialog-body.saves td:nth-child(3){line-height:1.2}#ui-dialog-body.saves td:last-child{text-align:right}#ui-dialog-body.saves .empty{color:#999;speak:none;text-align:center;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#ui-dialog-body.saves .datestamp{font-size:75%;margin-left:1em}#ui-dialog-body.saves ul.buttons li{padding:.4em}#ui-dialog-body.saves ul.buttons>li+li>button{margin-left:.2em}#ui-dialog-body.saves ul.buttons li:last-child{float:right}#ui-dialog-body.settings div[id|=header-body]{margin:1em 0}#ui-dialog-body.settings div[id|=header-body]:first-child{margin-top:0}#ui-dialog-body.settings div[id|=header-body]:not(:first-child){border-top:1px solid #444;padding-top:1em}#ui-dialog-body.settings div[id|=header-body]>*{margin:0}#ui-dialog-body.settings h2[id|=header-heading]{font-size:1.375em}#ui-dialog-body.settings p[id|=header-desc],#ui-dialog-body.settings p[id|=setting-desc]{font-size:87.5%;margin:0 0 0 .5em}#ui-dialog-body.settings div[id|=setting-body]+div[id|=setting-body]{margin:1em 0}#ui-dialog-body.settings [id|=setting-control]{white-space:nowrap}#ui-dialog-body.settings button[id|=setting-control]{color:#eee;background-color:transparent;border:1px solid #444;padding:.4em}#ui-dialog-body.settings button[id|=setting-control]:hover{background-color:#333;border-color:#eee}#ui-dialog-body.settings button[id|=setting-control].enabled{background-color:#282;border-color:#4a4}#ui-dialog-body.settings button[id|=setting-control].enabled:hover{background-color:#4a4;border-color:#6c6}#ui-dialog-body.settings input[type=range][id|=setting-control]{max-width:35vw}#ui-dialog-body.list a,#ui-dialog-body.settings span[id|=setting-input]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#ui-dialog-body.saves button[id=saves-clear]:before,#ui-dialog-body.saves button[id=saves-export]:before,#ui-dialog-body.saves button[id=saves-import]:before,#ui-dialog-body.settings button[id|=setting-control].enabled:after,#ui-dialog-body.settings button[id|=setting-control]:after{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}#ui-dialog-body.saves button[id=saves-export]:before{content:\"\\e829\\00a0\"}#ui-dialog-body.saves button[id=saves-import]:before{content:\"\\e82a\\00a0\"}#ui-dialog-body.saves button[id=saves-clear]:before{content:\"\\e827\\00a0\"}#ui-dialog-body.settings button[id|=setting-control]:after{content:\"\\00a0\\00a0\\e830\"}#ui-dialog-body.settings button[id|=setting-control].enabled:after{content:\"\\00a0\\00a0\\e831\"}</style>\n<style id=\"style-ui-bar\" type=\"text/css\">#story{margin-left:20em}#ui-bar.stowed~#story{margin-left:4.5em}@media screen and (max-width:1136px){#story{margin-left:19em}#ui-bar.stowed~#story{margin-left:3.5em}}@media screen and (max-width:768px){#story{margin-left:3.5em}}#ui-bar{position:fixed;z-index:50;top:0;left:0;width:17.5em;height:100%;margin:0;padding:0;-o-transition:left .2s ease-in;transition:left .2s ease-in}#ui-bar.stowed{left:-15.5em}#ui-bar-body{height:90%;height:calc(100% - 2.5em);margin:2.5em 0;padding:0 1.5em}#ui-bar.stowed #ui-bar-body,#ui-bar.stowed #ui-bar-history{visibility:hidden;-o-transition:visibility .2s step-end;transition:visibility .2s step-end}#ui-bar{background-color:#222;border-right:1px solid #444;text-align:center}#ui-bar-tray{position:absolute;top:.2em;left:0;right:0}#ui-bar a{text-decoration:none}#ui-bar hr{border-color:#444}#ui-bar-history [id|=history],#ui-bar-toggle{font-size:1.2em;line-height:inherit;color:#eee;background-color:transparent;border:1px solid #444}#ui-bar-toggle{display:block;position:absolute;top:0;right:0;border-right:none;padding:.3em .45em .25em}#ui-bar.stowed #ui-bar-toggle{padding:.3em .35em .25em .55em}#ui-bar-toggle:hover{background-color:#444;border-color:#eee}#ui-bar-history{margin:0 auto}#ui-bar-history [id|=history]{padding:.2em .45em .35em}#ui-bar-history #history-jumpto{padding:.2em .665em .35em}#ui-bar-history [id|=history]:not(:first-child){margin-left:1.2em}#ui-bar-history [id|=history]:hover{background-color:#444;border-color:#eee}#ui-bar-history [id|=history]:disabled{color:#444;background-color:transparent;border-color:#444}#ui-bar-body{line-height:1.5;overflow:auto}#ui-bar-body>:not(:first-child){margin-top:2em}#story-title{margin:0;font-size:162.5%}#story-author{margin-top:2em;font-weight:700}#menu ul{margin:1em 0 0;padding:0;list-style:none;border:1px solid #444}#menu ul:empty{display:none}#menu li{margin:0}#menu li:not(:first-child){border-top:1px solid #444}#menu li a{display:block;padding:.25em .75em;border:1px solid transparent;color:#eee;text-transform:uppercase}#menu li a:hover{background-color:#444;border-color:#eee}#menu a,#ui-bar-history [id|=history],#ui-bar-toggle{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#menu-core li[id|=menu-item] a:before,#ui-bar-history [id|=history],#ui-bar-toggle:before{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}#ui-bar-toggle:before{content:\"\\e81d\"}#ui-bar.stowed #ui-bar-toggle:before{content:\"\\e81e\"}#menu-item-saves a:before{content:\"\\e82b\\00a0\"}#menu-item-settings a:before{content:\"\\e82d\\00a0\"}#menu-item-restart a:before{content:\"\\e82c\\00a0\"}#menu-item-share a:before{content:\"\\e82f\\00a0\"}</style>\n<style id=\"style-ui-debug\" type=\"text/css\">#debug-bar{background-color:#222;border-left:1px solid #444;border-top:1px solid #444;bottom:0;margin:0;max-height:75%;padding:.5em;position:fixed;right:0;z-index:99900}#debug-bar>div:not([id])+div{margin-top:.5em}#debug-bar>div>label{margin-right:.5em}#debug-bar>div>input[type=text]{min-width:0;width:8em}#debug-bar>div>select{width:15em}#debug-bar-toggle{color:#eee;background-color:#222;border:1px solid #444;height:101%;height:calc(100% + 1px);left:-2em;left:calc(-2em - 1px);position:absolute;top:-1px;width:2em}#debug-bar-toggle:hover{background-color:#333;border-color:#eee}#debug-bar-hint{bottom:.175em;font-size:4.5em;opacity:.33;pointer-events:none;position:fixed;right:.6em;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;white-space:nowrap}#debug-bar-watch{background-color:#222;border-left:1px solid #444;border-top:1px solid #444;bottom:102%;bottom:calc(100% + 1px);font-size:.9em;left:-1px;max-height:650%;max-height:65vh;position:absolute;overflow-x:hidden;overflow-y:scroll;right:0;z-index:99800}#debug-bar-watch[hidden]{display:none}#debug-bar-watch div{color:#999;font-style:italic;margin:1em auto;text-align:center}#debug-bar-watch table{width:100%}#debug-bar-watch tr:nth-child(2n){background-color:rgba(127,127,127,.15)}#debug-bar-watch td{padding:.2em 0}#debug-bar-watch td:first-child+td{padding:.2em .3em .2em .1em}#debug-bar-watch .watch-delete{background-color:transparent;border:none;color:#c00}#debug-bar-watch-all,#debug-bar-watch-none{margin-left:.5em}#debug-bar-views-toggle,#debug-bar-watch-toggle{color:#eee;background-color:transparent;border:1px solid #444;margin-right:1em;padding:.4em}#debug-bar-views-toggle:hover,#debug-bar-watch-toggle:hover{background-color:#333;border-color:#eee}#debug-bar-watch:not([hidden])~div #debug-bar-watch-toggle,html[data-debug-view] #debug-bar-views-toggle{background-color:#282;border-color:#4a4}#debug-bar-watch:not([hidden])~div #debug-bar-watch-toggle:hover,html[data-debug-view] #debug-bar-views-toggle:hover{background-color:#4a4;border-color:#6c6}#debug-bar-hint:after,#debug-bar-toggle:before,#debug-bar-views-toggle:after,#debug-bar-watch .watch-delete:before,#debug-bar-watch-add:before,#debug-bar-watch-all:before,#debug-bar-watch-none:before,#debug-bar-watch-toggle:after{font-family:tme-fa-icons;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;speak:none}#debug-bar-toggle:before{content:\"\\e838\"}#debug-bar-hint:after{content:\"\\e838\\202f\\e822\"}#debug-bar-watch .watch-delete:before{content:\"\\e804\"}#debug-bar-watch-add:before{content:\"\\e805\"}#debug-bar-watch-all:before{content:\"\\e83a\"}#debug-bar-watch-none:before{content:\"\\e827\"}#debug-bar-views-toggle:after,#debug-bar-watch-toggle:after{content:\"\\00a0\\00a0\\e830\"}#debug-bar-watch:not([hidden])~div #debug-bar-watch-toggle:after,html[data-debug-view] #debug-bar-views-toggle:after{content:\"\\00a0\\00a0\\e831\"}html[data-debug-view] .debug{padding:.25em;background-color:#234}html[data-debug-view] .debug[title]{cursor:help}html[data-debug-view] .debug.block{display:inline-block;vertical-align:middle}html[data-debug-view] .debug.invalid{text-decoration:line-through}html[data-debug-view] .debug.hidden,html[data-debug-view] .debug.hidden .debug{background-color:#555}html:not([data-debug-view]) .debug.hidden{display:none}html[data-debug-view] .debug[data-name][data-type].nonvoid:after,html[data-debug-view] .debug[data-name][data-type]:before{background-color:rgba(0,0,0,.25);font-family:monospace,monospace;white-space:pre}html[data-debug-view] .debug[data-name][data-type]:before{content:attr(data-name)}html[data-debug-view] .debug[data-name][data-type|=macro]:before{content:\"<<\" attr(data-name) \">>\"}html[data-debug-view] .debug[data-name][data-type|=macro].nonvoid:after{content:\"<</\" attr(data-name) \">>\"}html[data-debug-view] .debug[data-name][data-type|=html]:before{content:\"<\" attr(data-name) \">\"}html[data-debug-view] .debug[data-name][data-type|=html].nonvoid:after{content:\"</\" attr(data-name) \">\"}html[data-debug-view] .debug[data-name][data-type]:not(:empty):before{margin-right:.25em}html[data-debug-view] .debug[data-name][data-type].nonvoid:not(:empty):after{margin-left:.25em}html[data-debug-view] .debug[data-name][data-type|=special],html[data-debug-view] .debug[data-name][data-type|=special]:before{display:block}</style>\n</head>\n<body>\n\t<div id=\"init-screen\">\n\t\t<div id=\"init-no-js\"><noscript>JavaScript is required. Please enable it to continue.</noscript></div>\n\t\t<div id=\"init-lacking\">Your browser lacks required capabilities. Please upgrade it or switch to another to continue.</div>\n\t\t<div id=\"init-loading\"><div>Loading&hellip;</div></div>\n\t</div>\n\t<div id=\"store-area\" hidden>{{STORY_DATA}}</div>\n\t<script id=\"script-sugarcube\" type=\"text/javascript\">\n\t/*! SugarCube JS */\n\tif(document.documentElement.getAttribute(\"data-init\")===\"loading\"){!function(window,document,jQuery,undefined){\"use strict\";function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError(\"Cannot call a class as a function\")}function _toConsumableArray(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t<e.length;t++)r[t]=e[t];return r}return Array.from(e)}var _createClass=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,\"value\"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),_slicedToArray=function(){function e(e,t){var r=[],n=!0,a=!1,i=undefined;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){a=!0,i=e}finally{try{!n&&s.return&&s.return()}finally{if(a)throw i}}return r}return function(t,r){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,r);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},errorPrologRegExp=/^(?:(?:uncaught\\s+(?:exception:\\s+)?)?\\w*(?:error|exception|_err):\\s+)+/i,Alert=function(){function e(e,t,r,n){var a=\"fatal\"===e,i=\"Apologies! \"+(a?\"A fatal\":\"An\")+\" error has occurred.\";i+=a?\" Aborting.\":\" You may be able to continue, but some parts may not work properly.\",null==t&&null==r||(i+=\"\\n\\nError\",null!=t&&(i+=\" [\"+t+\"]\"),i+=null!=r?\": \"+r.replace(errorPrologRegExp,\"\")+\".\":\": unknown error.\"),\"object\"===(void 0===n?\"undefined\":_typeof(n))&&n.stack&&(i+=\"\\n\\nStack Trace:\\n\"+n.stack),window.alert(i)}function t(t,r,n){e(null,t,r,n)}function r(t,r,n){e(\"fatal\",t,r,n)}return function(e){window.onerror=function(n,a,i,o,s){\"complete\"===document.readyState?t(null,n,s):(r(null,n,s),window.onerror=e,\"function\"==typeof window.onerror&&window.onerror.apply(this,arguments))}}(window.onerror),Object.freeze(Object.defineProperties({},{error:{value:t},fatal:{value:r}}))}(),Patterns=function(){var e=function(){var e=new Map([[\" \",\"\\\\u0020\"],[\"\\f\",\"\\\\f\"],[\"\\n\",\"\\\\n\"],[\"\\r\",\"\\\\r\"],[\"\\t\",\"\\\\t\"],[\"\\v\",\"\\\\v\"],[\" \",\"\\\\u00a0\"],[\" \",\"\\\\u1680\"],[\"᠎\",\"\\\\u180e\"],[\" \",\"\\\\u2000\"],[\" \",\"\\\\u2001\"],[\" \",\"\\\\u2002\"],[\" \",\"\\\\u2003\"],[\" \",\"\\\\u2004\"],[\" \",\"\\\\u2005\"],[\" \",\"\\\\u2006\"],[\" \",\"\\\\u2007\"],[\" \",\"\\\\u2008\"],[\" \",\"\\\\u2009\"],[\" \",\"\\\\u200a\"],[\"\\u2028\",\"\\\\u2028\"],[\"\\u2029\",\"\\\\u2029\"],[\" \",\"\\\\u202f\"],[\" \",\"\\\\u205f\"],[\" \",\"\\\\u3000\"],[\"\\ufeff\",\"\\\\ufeff\"]]),t=/^\\s$/,r=\"\";return e.forEach(function(e,n){t.test(n)||(r+=e)}),r?\"[\\\\s\"+r+\"]\":\"\\\\s\"}(),t=\"\\\\s\"===e?\"\\\\S\":e.replace(/^\\[/,\"[^\"),r=\"[0-9A-Z_a-z\\\\-\\\\u00c0-\\\\u00d6\\\\u00d8-\\\\u00f6\\\\u00f8-\\\\u00ff\\\\u0150\\\\u0170\\\\u0151\\\\u0171]\",n=r.replace(\"\\\\-\",\"\"),a=function(){return\"(\"+r+\"+)\\\\(([^\\\\)\\\\|\\\\n]+)\\\\):|(\"+r+\"+):([^;\\\\|\\\\n]+);|((?:\\\\.\"+r+\"+)+);|((?:#\"+r+\"+)+);\"}();return Object.freeze({space:e,spaceNoTerminator:\"[\\\\u0020\\\\f\\\\t\\\\v\\\\u00a0\\\\u1680\\\\u180e\\\\u2000-\\\\u200a\\\\u202f\\\\u205f\\\\u3000\\\\ufeff]\",lineTerminator:\"[\\\\n\\\\r\\\\u2028\\\\u2029]\",notSpace:t,anyLetter:r,anyLetterStrict:n,identifierFirstChar:\"[$A-Z_a-z]\",identifier:\"[$A-Z_a-z][$0-9A-Z_a-z]*\",variableSigil:\"[$_]\",variable:\"[$_][$A-Z_a-z][$0-9A-Z_a-z]*\",macroName:\"[A-Za-z][\\\\w-]*|[=-]\",cssImage:\"\\\\[[<>]?[Ii][Mm][Gg]\\\\[(?:\\\\s|\\\\S)*?\\\\]\\\\]+\",inlineCss:a,url:\"(?:file|https?|mailto|ftp|javascript|irc|news|data):[^\\\\s'\\\"]+\"})}();!function(){!function(e){if(e&&e.prototype&&null==e.prototype.firstElementChild){var t=Node.ELEMENT_NODE;Object.defineProperty(e.prototype,\"firstElementChild\",{get:function(){for(var e=this.childNodes,r=0;r<e.length;++r){var n=e[r];if(n.nodeType===t)return n}return null}})}}(window.Node||window.Element)}(),function(){function e(e,t){var r=Number.parseInt(e,10)||0;if(r<1)return\"\";var n=void 0===t?\"\":String(t);for(\"\"===n&&(n=\" \");n.length<r;){var a=n.length,i=r-a;n+=a>i?n.slice(0,i):n}return n.length>r&&(n=n.slice(0,r)),n}var t=function(){function e(e,n){var a=String(e);if(!a)return a;switch(n){case\"start\":return t.test(a)?a.replace(t,\"\"):a;case\"end\":return r.test(a)?a.replace(r,\"\"):a;default:throw new Error('_trimString called with incorrect where parameter value: \"'+n+'\"')}}var t=new RegExp(\"^\"+Patterns.space+Patterns.space+\"*\"),r=new RegExp(\"\"+Patterns.space+Patterns.space+\"*$\");return e}();Array.prototype.includes||Object.defineProperty(Array.prototype,\"includes\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.includes called on null or undefined\");if(0===arguments.length)return!1;var e=this.length>>>0;if(0===e)return!1;var t=arguments[0],r=Number(arguments[1])||0;for(r<0&&(r=Math.max(0,e+r));r<e;++r){var n=this[r];if(n===t||n!==n&&t!==t)return!0}return!1}}),String.prototype.padStart||Object.defineProperty(String.prototype,\"padStart\",{configurable:!0,writable:!0,value:function(t,r){if(null==this)throw new TypeError(\"String.prototype.padStart called on null or undefined\");var n=String(this),a=n.length,i=Number.parseInt(t,10);return i<=a?n:e(i-a,r)+n}}),String.prototype.padEnd||Object.defineProperty(String.prototype,\"padEnd\",{configurable:!0,writable:!0,value:function(t,r){if(null==this)throw new TypeError(\"String.prototype.padEnd called on null or undefined\");var n=String(this),a=n.length,i=Number.parseInt(t,10);return i<=a?n:n+e(i-a,r)}}),String.prototype.trimStart||Object.defineProperty(String.prototype,\"trimStart\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimStart called on null or undefined\");return t(this,\"start\")}}),String.prototype.trimLeft||Object.defineProperty(String.prototype,\"trimLeft\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimLeft called on null or undefined\");return t(this,\"start\")}}),String.prototype.trimEnd||Object.defineProperty(String.prototype,\"trimEnd\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimEnd called on null or undefined\");return t(this,\"end\")}}),String.prototype.trimRight||Object.defineProperty(String.prototype,\"trimRight\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.trimRight called on null or undefined\");return t(this,\"end\")}})}(),function(){function _random(){var e=void 0,t=void 0;switch(arguments.length){case 0:throw new Error(\"_random called with insufficient parameters\");case 1:e=0,t=arguments[0];break;default:e=arguments[0],t=arguments[1]}if(e>t){var r=[t,e];e=r[0],t=r[1]}return Math.floor(_nativeMathRandom()*(t-e+1))+e}function _randomIndex(e,t){var r=void 0,n=void 0;switch(t.length){case 1:r=0,n=e-1;break;case 2:r=0,n=Math.trunc(t[1]);break;default:r=Math.trunc(t[1]),n=Math.trunc(t[2])}return Number.isNaN(r)?r=0:!Number.isFinite(r)||r>=e?r=e-1:r<0&&(r=e+r)<0&&(r=0),Number.isNaN(n)?n=0:!Number.isFinite(n)||n>=e?n=e-1:n<0&&(n=e+n)<0&&(n=e-1),_random(r,n)}function _getCodePointStartAndEnd(e,t){var r=e.charCodeAt(t);if(Number.isNaN(r))return{char:\"\",start:-1,end:-1};if(r<55296||r>57343)return{char:e.charAt(t),start:t,end:t};if(r>=55296&&r<=56319){var n=t+1;if(n>=e.length)throw new Error(\"high surrogate without trailing low surrogate\");var a=e.charCodeAt(n);if(a<56320||a>57343)throw new Error(\"high surrogate without trailing low surrogate\");return{char:e.charAt(t)+e.charAt(n),start:t,end:n}}if(0===t)throw new Error(\"low surrogate without leading high surrogate\");var i=t-1,o=e.charCodeAt(i);if(o<55296||o>56319)throw new Error(\"low surrogate without leading high surrogate\");return{char:e.charAt(i)+e.charAt(t),start:i,end:t}}var _nativeMathRandom=Math.random;Object.defineProperty(Array,\"random\",{configurable:!0,writable:!0,value:function(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e))||null===e||!Object.prototype.hasOwnProperty.call(e,\"length\"))throw new TypeError(\"Array.random array parameter must be an array or array-lke object\");var t=e.length>>>0;if(0!==t){return e[0===arguments.length?_random(0,t-1):_randomIndex(t,Array.prototype.slice.call(arguments,1))]}}}),Object.defineProperty(Array.prototype,\"concatUnique\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.concatUnique called on null or undefined\");var e=Array.from(this);if(0===arguments.length)return e;var t=Array.prototype.reduce.call(arguments,function(e,t){return e.concat(t)},[]),r=t.length;if(0===r)return e;for(var n=Array.prototype.indexOf,a=Array.prototype.push,i=0;i<r;++i){var o=t[i];-1===n.call(e,o)&&a.call(e,o)}return e}}),Object.defineProperty(Array.prototype,\"count\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.count called on null or undefined\");for(var e=Array.prototype.indexOf,t=arguments[0],r=Number(arguments[1])||0,n=0;-1!==(r=e.call(this,t,r));)++n,++r;return n}}),Object.defineProperty(Array.prototype,\"delete\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.delete called on null or undefined\");if(0===arguments.length)return[];var e=this.length>>>0;if(0===e)return[];for(var t=Array.prototype.concat.apply([],arguments),r=t.length,n=[],a=0;a<e;++a)for(var i=this[a],o=0;o<r;++o){var s=t[o];if(i===s||i!==i&&s!==s){n.push(a);break}}for(var u=[],l=0,c=n.length;l<c;++l)u[l]=this[n[l]];for(var d=Array.prototype.splice,f=n.length-1;f>=0;--f)d.call(this,n[f],1);return u}}),Object.defineProperty(Array.prototype,\"deleteAt\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.deleteAt called on null or undefined\");if(0===arguments.length)return[];var e=this.length>>>0;if(0===e)return[];for(var t=Array.prototype.splice,r=[].concat(_toConsumableArray(new Set(Array.prototype.concat.apply([],arguments).map(function(t){return t<0?Math.max(0,e+t):t})).values())),n=[].concat(_toConsumableArray(r)).sort(function(e,t){return t-e}),a=[],i=0,o=r.length;i<o;++i)a[i]=this[r[i]];for(var s=0,u=n.length;s<u;++s)t.call(this,n[s],1);return a}}),Object.defineProperty(Array.prototype,\"deleteWith\",{configurable:!0,writable:!0,value:function(e,t){if(null==this)throw new TypeError(\"Array.prototype.deleteWith called on null or undefined\");if(\"function\"!=typeof e)throw new Error(\"Array.prototype.deleteWith predicate parameter must be a function\");var r=this.length>>>0;if(0===r)return[];for(var n=Array.prototype.splice,a=[],i=[],o=0;o<r;++o)e.call(t,this[o],o,this)&&(i.push(this[o]),a.push(o));for(var s=a.length-1;s>=0;--s)n.call(this,a[s],1);return i}}),Object.defineProperty(Array.prototype,\"first\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.first called on null or undefined\");if(0!=this.length>>>0)return this[0]}}),Object.defineProperty(Array.prototype,\"flatten\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.flatten called on null or undefined\");return Array.prototype.reduce.call(this,function(e,t){return e.concat(Array.isArray(t)?t.flatten():t)},[])}}),Object.defineProperty(Array.prototype,\"includesAll\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.includesAll called on null or undefined\");if(1===arguments.length)return Array.isArray(arguments[0])?Array.prototype.includesAll.apply(this,arguments[0]):Array.prototype.includes.apply(this,arguments);for(var e=0,t=arguments.length;e<t;++e)if(!Array.prototype.some.call(this,function(e){return e===this.val||e!==e&&this.val!==this.val},{val:arguments[e]}))return!1;return!0}}),Object.defineProperty(Array.prototype,\"includesAny\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.includesAny called on null or undefined\");if(1===arguments.length)return Array.isArray(arguments[0])?Array.prototype.includesAny.apply(this,arguments[0]):Array.prototype.includes.apply(this,arguments);for(var e=0,t=arguments.length;e<t;++e)if(Array.prototype.some.call(this,function(e){return e===this.val||e!==e&&this.val!==this.val},{val:arguments[e]}))return!0;return!1}}),Object.defineProperty(Array.prototype,\"last\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.last called on null or undefined\");var e=this.length>>>0;if(0!==e)return this[e-1]}}),Object.defineProperty(Array.prototype,\"pluck\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.pluck called on null or undefined\");var e=this.length>>>0;if(0!==e){var t=0===arguments.length?_random(0,e-1):_randomIndex(e,[].concat(Array.prototype.slice.call(arguments)));return Array.prototype.splice.call(this,t,1)[0]}}}),Object.defineProperty(Array.prototype,\"pluckMany\",{configurable:!0,writable:!0,value:function(e){if(null==this)throw new TypeError(\"Array.prototype.pluckMany called on null or undefined\");var t=this.length>>>0;if(0===t)return[];var r=Math.trunc(e);if(!Number.isInteger(r))throw new Error(\"Array.prototype.pluckMany want parameter must be an integer\");if(r<1)return[];r>t&&(r=t);var n=Array.prototype.splice,a=[],i=t-1;do{a.push(n.call(this,_random(0,i--),1)[0])}while(a.length<r);return a}}),Object.defineProperty(Array.prototype,\"pushUnique\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.pushUnique called on null or undefined\");var e=arguments.length;if(0===e)return this.length>>>0;for(var t=Array.prototype.indexOf,r=Array.prototype.push,n=0;n<e;++n){var a=arguments[n];-1===t.call(this,a)&&r.call(this,a)}return this.length>>>0}}),Object.defineProperty(Array.prototype,\"random\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.random called on null or undefined\");var e=this.length>>>0;if(0!==e){return this[0===arguments.length?_random(0,e-1):_randomIndex(e,[].concat(Array.prototype.slice.call(arguments)))]}}}),Object.defineProperty(Array.prototype,\"randomMany\",{configurable:!0,writable:!0,value:function(e){if(null==this)throw new TypeError(\"Array.prototype.randomMany called on null or undefined\");var t=this.length>>>0;if(0===t)return[];var r=Math.trunc(e);if(!Number.isInteger(r))throw new Error(\"Array.prototype.randomMany want parameter must be an integer\");if(r<1)return[];r>t&&(r=t);var n=new Map,a=[],i=t-1;do{var o=void 0;do{o=_random(0,i)}while(n.has(o));n.set(o,!0),a.push(this[o])}while(a.length<r);return a}}),Object.defineProperty(Array.prototype,\"shuffle\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.shuffle called on null or undefined\");var e=this.length>>>0;if(0===e)return this;for(var t=e-1;t>0;--t){var r=Math.floor(_nativeMathRandom()*(t+1));if(t!==r){var n=this[t];this[t]=this[r],this[r]=n}}return this}}),Object.defineProperty(Array.prototype,\"unshiftUnique\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.unshiftUnique called on null or undefined\");var e=arguments.length;if(0===e)return this.length>>>0;for(var t=Array.prototype.indexOf,r=Array.prototype.unshift,n=0;n<e;++n){var a=arguments[n];-1===t.call(this,a)&&r.call(this,a)}return this.length>>>0}}),Object.defineProperty(Function.prototype,\"partial\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Function.prototype.partial called on null or undefined\");var e=Array.prototype.slice,t=this,r=e.call(arguments,0);return function(){for(var n=[],a=0,i=0;i<r.length;++i)n.push(r[i]===undefined?arguments[a++]:r[i]);return t.apply(this,n.concat(e.call(arguments,a)))}}}),Object.defineProperty(Math,\"clamp\",{configurable:!0,writable:!0,value:function(e,t,r){var n=Number(e);return Number.isNaN(n)?NaN:n.clamp(t,r)}}),Object.defineProperty(Math,\"easeInOut\",{configurable:!0,writable:!0,value:function(e){return 1-(Math.cos(Number(e)*Math.PI)+1)/2}}),Object.defineProperty(Number.prototype,\"clamp\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Number.prototype.clamp called on null or undefined\");if(2!==arguments.length)throw new Error(\"Number.prototype.clamp called with an incorrect number of parameters\");var e=Number(arguments[0]),t=Number(arguments[1]);if(e>t){var r=[t,e];e=r[0],t=r[1]}return Math.min(Math.max(this,e),t)}}),RegExp.escape||function(){var e=/[\\\\^$*+?.()|[\\]{}]/g,t=new RegExp(e.source);Object.defineProperty(RegExp,\"escape\",{configurable:!0,writable:!0,value:function(r){var n=String(r);return n&&t.test(n)?n.replace(e,\"\\\\$&\"):n}})}(),function(){var e=/{(\\d+)(?:,([+-]?\\d+))?}/g,t=new RegExp(e.source);Object.defineProperty(String,\"format\",{configurable:!0,writable:!0,value:function(r){function n(e,t,r){if(!t)return e;var n=Math.abs(t)-e.length;if(n<1)return e;var a=String(r).repeat(n);return t<0?e+a:a+e}if(arguments.length<2)return 0===arguments.length?\"\":r;var a=2===arguments.length&&Array.isArray(arguments[1])?[].concat(_toConsumableArray(arguments[1])):Array.prototype.slice.call(arguments,1);return 0===a.length?r:t.test(r)?(e.lastIndex=0,r.replace(e,function(e,t,r){var i=a[t];if(null==i)return\"\";for(;\"function\"==typeof i;)i=i();switch(void 0===i?\"undefined\":_typeof(i)){case\"string\":break;case\"object\":i=JSON.stringify(i);break;default:i=String(i)}return n(i,r?Number.parseInt(r,10):0,\" \")})):r}})}(),Object.defineProperty(String.prototype,\"contains\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.contains called on null or undefined\");return-1!==String.prototype.indexOf.apply(this,arguments)}}),Object.defineProperty(String.prototype,\"count\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.count called on null or undefined\");var e=String(arguments[0]||\"\");if(\"\"===e)return 0;for(var t=String.prototype.indexOf,r=e.length,n=Number(arguments[1])||0,a=0;-1!==(n=t.call(this,e,n));)++a,n+=r;return a}}),Object.defineProperty(String.prototype,\"first\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.first called on null or undefined\");return _getCodePointStartAndEnd(String(this),0).char}}),Object.defineProperty(String.prototype,\"last\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.last called on null or undefined\");var e=String(this);return _getCodePointStartAndEnd(e,e.length-1).char}}),Object.defineProperty(String.prototype,\"splice\",{configurable:!0,writable:!0,value:function(e,t,r){if(null==this)throw new TypeError(\"String.prototype.splice called on null or undefined\");var n=this.length>>>0;if(0===n)return\"\";var a=Number(e);Number.isSafeInteger(a)?a<0&&(a+=n)<0&&(a=0):a=0,a>n&&(a=n);var i=Number(t);(!Number.isSafeInteger(i)||i<0)&&(i=0);var o=this.slice(0,a);return void 0!==r&&(o+=r),a+i<n&&(o+=this.slice(a+i)),o}}),Object.defineProperty(String.prototype,\"splitOrEmpty\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.splitOrEmpty called on null or undefined\");return\"\"===String(this)?[]:String.prototype.split.apply(this,arguments)}}),Object.defineProperty(String.prototype,\"toLocaleUpperFirst\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.toLocaleUpperFirst called on null or undefined\");var e=String(this),t=_getCodePointStartAndEnd(e,0),r=t.char,n=t.end;return-1===n?\"\":r.toLocaleUpperCase()+e.slice(n+1)}}),Object.defineProperty(String.prototype,\"toUpperFirst\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.toUpperFirst called on null or undefined\");var e=String(this),t=_getCodePointStartAndEnd(e,0),r=t.char,n=t.end;return-1===n?\"\":r.toUpperCase()+e.slice(n+1)}}),Object.defineProperty(Date.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:date)\",this.toISOString()]}}),Object.defineProperty(Function.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:eval)\",\"(\"+this.toString()+\")\"]}}),Object.defineProperty(Map.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:map)\",[].concat(_toConsumableArray(this))]}}),Object.defineProperty(RegExp.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:eval)\",this.toString()]}}),Object.defineProperty(Set.prototype,\"toJSON\",{configurable:!0,writable:!0,value:function(){return[\"(revive:set)\",[].concat(_toConsumableArray(this))]}}),Object.defineProperty(JSON,\"reviveWrapper\",{configurable:!0,writable:!0,value:function(e,t){if(\"string\"!=typeof e)throw new TypeError(\"JSON.reviveWrapper code parameter must be a string\");return[\"(revive:eval)\",[e,t]]}}),Object.defineProperty(JSON,\"_real_parse\",{value:JSON.parse}),Object.defineProperty(JSON,\"parse\",{configurable:!0,writable:!0,value:function value(text,reviver){return JSON._real_parse(text,function(key,val){var value=val;if(Array.isArray(value)&&2===value.length)switch(value[0]){case\"(revive:set)\":value=new Set(value[1]);break;case\"(revive:map)\":value=new Map(value[1]);break;case\"(revive:date)\":value=new Date(value[1]);break;case\"(revive:eval)\":try{if(Array.isArray(value[1])){var $ReviveData$=value[1][1];value=eval(value[1][0])}else value=eval(value[1])}catch(e){}}else if(\"string\"==typeof value&&\"@@revive@@\"===value.slice(0,10))try{value=eval(value.slice(10))}catch(e){}if(\"function\"==typeof reviver)try{value=reviver(key,value)}catch(e){}return value})}}),Object.defineProperty(Array.prototype,\"contains\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.contains called on null or undefined\");return Array.prototype.includes.apply(this,arguments)}}),Object.defineProperty(Array.prototype,\"containsAll\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.containsAll called on null or undefined\");return Array.prototype.includesAll.apply(this,arguments)}}),Object.defineProperty(Array.prototype,\"containsAny\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"Array.prototype.containsAny called on null or undefined\");return Array.prototype.includesAny.apply(this,arguments)}}),Object.defineProperty(String.prototype,\"readBracketedList\",{configurable:!0,writable:!0,value:function(){if(null==this)throw new TypeError(\"String.prototype.readBracketedList called on null or undefined\");for(var e=new RegExp(\"(?:\\\\[\\\\[((?:\\\\s|\\\\S)*?)\\\\]\\\\])|([^\\\"'\\\\s]\\\\S*)\",\"gm\"),t=[],r=void 0;null!==(r=e.exec(this));)r[1]?t.push(r[1]):r[2]&&t.push(r[2]);return t}})}();var Browser=function(){var e=navigator.userAgent.toLowerCase(),t=e.includes(\"windows phone\"),r=Object.freeze({Android:!t&&e.includes(\"android\"),BlackBerry:/blackberry|bb10/.test(e),iOS:!t&&/ip(?:hone|ad|od)/.test(e),Windows:t||e.includes(\"iemobile\"),any:function(){return r.Android||r.BlackBerry||r.iOS||r.Windows}}),n=!r.Windows&&!/khtml|trident|edge/.test(e)&&e.includes(\"gecko\"),a=!e.includes(\"opera\")&&/msie|trident/.test(e),i=a?function(){var t=/(?:msie\\s+|rv:)(\\d+\\.\\d)/.exec(e);return t?Number(t[1]):0}():null,o=e.includes(\"opera\")||e.includes(\" opr/\"),s=o?function(){var t=new RegExp((/khtml|chrome/.test(e)?\"opr\":\"version\")+\"\\\\/(\\\\d+\\\\.\\\\d+)\"),r=t.exec(e);return r?Number(r[1]):0}():null,u=e.includes(\"vivaldi\");return Object.freeze({userAgent:e,isMobile:r,isGecko:n,isIE:a,ieVersion:i,isOpera:o,operaVersion:s,isVivaldi:u})}(),Has=function(){var e=function(){try{return\"function\"==typeof document.createElement(\"audio\").canPlayType}catch(e){}return!1}(),t=e&&function(){try{var e=document.createElement(\"audio\").play();return e.catch(function(){}),e instanceof Promise}catch(e){}return!1}(),r=function(){try{return\"Blob\"in window&&\"File\"in window&&\"FileList\"in window&&\"FileReader\"in window&&!Browser.isMobile.any()&&(!Browser.isOpera||Browser.operaVersion>=15)}catch(e){}return!1}(),n=function(){try{return\"geolocation\"in navigator&&\"function\"==typeof navigator.geolocation.getCurrentPosition&&\"function\"==typeof navigator.geolocation.watchPosition}catch(e){}return!1}(),a=function(){try{return\"MutationObserver\"in window&&\"function\"==typeof window.MutationObserver}catch(e){}return!1}(),i=function(){try{return\"performance\"in window&&\"function\"==typeof window.performance.now}catch(e){}return!1}();return Object.freeze({audio:e,audioPromise:t,fileAPI:r,geolocation:n,mutationObserver:a,performance:i})}(),Visibility=function(){function e(){return Boolean(r&&document[r.hiddenProperty])}function t(){return r&&document[r.stateProperty]||\"visible\"}var r=function(){try{return Object.freeze([{hiddenProperty:\"hidden\",stateProperty:\"visibilityState\",changeEvent:\"visibilitychange\"},{hiddenProperty:\"webkitHidden\",stateProperty:\"webkitVisibilityState\",changeEvent:\"webkitvisibilitychange\"},{hiddenProperty:\"mozHidden\",stateProperty:\"mozVisibilityState\",changeEvent:\"mozvisibilitychange\"},{hiddenProperty:\"msHidden\",stateProperty:\"msVisibilityState\",changeEvent:\"msvisibilitychange\"}].find(function(e){return e.hiddenProperty in document}))}catch(e){}return null}();return Object.freeze(Object.defineProperties({},{isHidden:{value:e},state:{value:t},hiddenProperty:{value:r.hiddenProperty},stateProperty:{value:r.stateProperty},changeEvent:{value:r.changeEvent}}))}(),_ref3=function(){function e(t){if(\"object\"!==(void 0===t?\"undefined\":_typeof(t))||null===t)return t;if(t instanceof String)return String(t);if(t instanceof Number)return Number(t);if(t instanceof Boolean)return Boolean(t);if(\"function\"==typeof t.clone)return t.clone(!0);if(t.nodeType&&\"function\"==typeof t.cloneNode)return t.cloneNode(!0);var r=void 0;return t instanceof Array?r=new Array(t.length):t instanceof Date?r=new Date(t.getTime()):t instanceof Map?(r=new Map,t.forEach(function(t,n){return r.set(n,e(t))})):t instanceof RegExp?r=new RegExp(t):t instanceof Set?(r=new Set,t.forEach(function(t){return r.add(e(t))})):r=Object.create(Object.getPrototypeOf(t)),Object.keys(t).forEach(function(n){return r[n]=e(t[n])}),r}function t(e){for(var t=document.createDocumentFragment(),r=document.createElement(\"p\"),n=void 0;null!==(n=e.firstChild);){if(n.nodeType===Node.ELEMENT_NODE){switch(n.nodeName.toUpperCase()){case\"BR\":if(null!==n.nextSibling&&n.nextSibling.nodeType===Node.ELEMENT_NODE&&\"BR\"===n.nextSibling.nodeName.toUpperCase()){e.removeChild(n.nextSibling),e.removeChild(n),t.appendChild(r),r=document.createElement(\"p\");continue}if(!r.hasChildNodes()){e.removeChild(n);continue}break;case\"ADDRESS\":case\"ARTICLE\":case\"ASIDE\":case\"BLOCKQUOTE\":case\"CENTER\":case\"DIV\":case\"DL\":case\"FIGURE\":case\"FOOTER\":case\"FORM\":case\"H1\":case\"H2\":case\"H3\":case\"H4\":case\"H5\":case\"H6\":case\"HEADER\":case\"HR\":case\"MAIN\":case\"NAV\":case\"OL\":case\"P\":case\"PRE\":case\"SECTION\":case\"TABLE\":case\"UL\":r.hasChildNodes()&&(t.appendChild(r),r=document.createElement(\"p\")),t.appendChild(n);continue}}r.appendChild(n)}r.hasChildNodes()&&t.appendChild(r),e.appendChild(t)}function r(){try{return document.activeElement||null}catch(e){return null}}function n(e,t,r){var n=\"object\"===(void 0===e?\"undefined\":_typeof(e))?e:document.getElementById(e);if(null==n)return null;var a=Array.isArray(t)?t:[t];jQuery(n).empty();for(var i=0,o=a.length;i<o;++i)if(Story.has(a[i]))return new Wikifier(n,Story.get(a[i]).processText().trim()),n;if(null!=r){var s=String(r).trim();\"\"!==s&&new Wikifier(n,s)}return n}function a(e,t,r){var n=jQuery(document.createElement(\"div\")),a=jQuery(document.createElement(\"button\")),i=jQuery(document.createElement(\"pre\")),o=L10n.get(\"errorTitle\")+\": \"+(t||\"unknown error\");return a.addClass(\"error-toggle\").ariaClick({label:L10n.get(\"errorToggle\")},function(){a.hasClass(\"enabled\")?(a.removeClass(\"enabled\"),i.attr({\"aria-hidden\":!0,hidden:\"hidden\"})):(a.addClass(\"enabled\"),i.removeAttr(\"aria-hidden hidden\"))}).appendTo(n),jQuery(document.createElement(\"span\")).addClass(\"error\").text(o).appendTo(n),jQuery(document.createElement(\"code\")).text(r).appendTo(i),i.addClass(\"error-source\").attr({\"aria-hidden\":!0,hidden:\"hidden\"}).appendTo(n),n.addClass(\"error-view\").appendTo(e),console.warn(o+\"\\n\\t\"+r.replace(/\\n/g,\"\\n\\t\")),!1}function i(e,t){var r=i;switch(void 0===e?\"undefined\":_typeof(e)){case\"number\":if(Number.isNaN(e))return t;break;case\"object\":if(null===e)return t;if(Array.isArray(e))return e.map(function(e){return r(e,t)}).join(\", \");if(e instanceof Set)return[].concat(_toConsumableArray(e)).map(function(e){return r(e,t)}).join(\", \");if(e instanceof Map){return\"{ \"+[].concat(_toConsumableArray(e)).map(function(e){var n=_slicedToArray(e,2),a=n[0],i=n[1];return r(a,t)+\" → \"+r(i,t)}).join(\", \")+\" }\"}return e instanceof Date?e.toLocaleString():\"function\"==typeof e.toString?e.toString():Object.prototype.toString.call(e);case\"function\":case\"undefined\":return t}return String(e)}return Object.freeze(Object.defineProperties({},{clone:{value:e},convertBreaks:{value:t},safeActiveElement:{value:r},setPageElement:{value:n},throwError:{value:a},toStringOrDefault:{value:i}}))}(),clone=_ref3.clone,convertBreaks=_ref3.convertBreaks,safeActiveElement=_ref3.safeActiveElement,setPageElement=_ref3.setPageElement,throwError=_ref3.throwError,toStringOrDefault=_ref3.toStringOrDefault;!function(){function e(e){13!==e.which&&32!==e.which||(e.preventDefault(),jQuery(safeActiveElement()||this).trigger(\"click\"))}function t(e){return function(){var t=jQuery(this),r=t.attr(\"data-passage\"),n=window&&window.SugarCube&&window.SugarCube.State&&window.SugarCube.State.passage,a=window.pageYOffset;t.is(\"[aria-pressed]\")&&t.attr(\"aria-pressed\",\"true\"===t.attr(\"aria-pressed\")?\"false\":\"true\"),e.apply(this,arguments);!r||window.lastDataPassageLink!==r&&n!==r||function(){window.scrollTo(0,a)}(),window.lastDataPassageLink=r}}function r(e){return t(function(){jQuery(this).off(\".aria-clickable\").removeAttr(\"tabindex aria-controls aria-pressed\").not(\"a,button\").removeAttr(\"role\").end().filter(\"button\").prop(\"disabled\",!0),e.apply(this,arguments)})}jQuery.fn.extend({ariaClick:function(n,a){if(0===this.length||0===arguments.length)return this;var i=n,o=a;return null==o&&(o=i,i=undefined),i=jQuery.extend({namespace:undefined,one:!1,selector:undefined,data:undefined,controls:undefined,pressed:undefined,label:undefined},i),\"string\"!=typeof i.namespace?i.namespace=\"\":\".\"!==i.namespace[0]&&(i.namespace=\".\"+i.namespace),\"boolean\"==typeof i.pressed&&(i.pressed=i.pressed?\"true\":\"false\"),this.filter(\"button\").prop(\"type\",\"button\"),this.not(\"a,button\").attr(\"role\",\"button\"),this.attr(\"tabindex\",0),null!=i.controls&&this.attr(\"aria-controls\",i.controls),null!=i.pressed&&this.attr(\"aria-pressed\",i.pressed),null!=i.label&&this.attr({\"aria-label\":i.label,title:i.label}),this.not(\"button\").on(\"keypress.aria-clickable\"+i.namespace,i.selector,e),this.on(\"click.aria-clickable\"+i.namespace,i.selector,i.data,i.one?r(o):t(o)),this},ariaDisabled:function(e){if(0===this.length||0===arguments.length)return this;var t=this.not(\"button,fieldset,input,menuitem,optgroup,option,select,textarea\"),r=this.filter(\"button,fieldset,input,menuitem,optgroup,option,select,textarea\");return e?(t.each(function(){this.setAttribute(\"disabled\",\"\"),this.setAttribute(\"aria-disabled\",\"\")}),r.each(function(){this.disabled=!0,this.setAttribute(\"aria-disabled\",\"\")})):(t.each(function(){this.removeAttribute(\"disabled\"),this.removeAttribute(\"aria-disabled\")}),r.each(function(){this.disabled=!1,this.removeAttribute(\"aria-disabled\")})),this},ariaIsDisabled:function(){return this.is(\"[disabled]\")}})}(),function(){jQuery.extend({wikiWithOptions:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(0!==r.length){var a=document.createDocumentFragment();r.forEach(function(t){return new Wikifier(a,t,e)});var i=[].concat(_toConsumableArray(a.querySelectorAll(\".error\"))).map(function(e){return e.textContent.replace(errorPrologRegExp,\"\")});if(i.length>0)throw new Error(i.join(\"; \"))}},wiki:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r]\n;this.wikiWithOptions.apply(this,[undefined].concat(t))}}),jQuery.fn.extend({wikiWithOptions:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(0===this.length||0===r.length)return this;var a=document.createDocumentFragment();return r.forEach(function(t){return new Wikifier(a,t,e)}),this.append(a),this},wiki:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.wikiWithOptions.apply(this,[undefined].concat(t))}})}();var Util=function(){function e(e){return Object.freeze(Object.assign(Object.create(null),e))}function t(e){return Object.prototype.toString.call(e).slice(8,-1)}function r(e){var t=void 0;switch(void 0===e?\"undefined\":_typeof(e)){case\"number\":t=e;break;case\"string\":t=Number(e);break;default:return!1}return!Number.isNaN(t)&&Number.isFinite(t)}function n(e){return\"boolean\"==typeof e||\"string\"==typeof e&&(\"true\"===e||\"false\"===e)}function a(e,t){return e===t||e!==e&&t!==t}function i(e){return String(e).trim().replace(/[^\\w\\s\\u2013\\u2014-]+/g,\"\").replace(/[_\\s\\u2013\\u2014-]+/g,\"-\").toLocaleLowerCase()}function o(e){if(null==e)return\"\";var t=String(e);return t&&m.test(t)?t.replace(g,function(e){return v[e]}):t}function s(e){if(null==e)return\"\";var t=String(e);return t&&b.test(t)?t.replace(y,function(e){return w[e.toLowerCase()]}):t}function u(e,t){var r=String(e),n=Math.trunc(t),a=r.charCodeAt(n);if(Number.isNaN(a))return{char:\"\",start:-1,end:-1};var i={char:r.charAt(n),start:n,end:n};if(a<55296||a>57343)return i;if(a>=55296&&a<=56319){var o=n+1;if(o>=r.length)return i;var s=r.charCodeAt(o);return s<56320||s>57343?i:(i.char=i.char+r.charAt(o),i.end=o,i)}if(0===n)return i;var u=n-1,l=r.charCodeAt(u);return l<55296||l>56319?i:(i.char=r.charAt(u)+i.char,i.start=u,i)}function l(){return k.now()}function c(e){var t=S.exec(String(e));if(null===t)throw new SyntaxError('invalid time value syntax: \"'+e+'\"');var r=Number(t[1]);if(1===t[2].length&&(r*=1e3),Number.isNaN(r)||!Number.isFinite(r))throw new RangeError('invalid time value: \"'+e+'\"');return r}function d(e){if(\"number\"!=typeof e||Number.isNaN(e)||!Number.isFinite(e)){var r=void 0;switch(void 0===e?\"undefined\":_typeof(e)){case\"string\":r='\"'+e+'\"';break;case\"number\":r=String(e);break;default:r=t(e)}throw new Error(\"invalid milliseconds: \"+r)}return e+\"ms\"}function f(e){if(!e.includes(\"-\"))switch(e){case\"bgcolor\":return\"backgroundColor\";case\"float\":return\"cssFloat\";default:return e}return(\"-ms-\"===e.slice(0,4)?e.slice(1):e).split(\"-\").map(function(e,t){return 0===t?e:e.toUpperFirst()}).join(\"\")}function h(e){var t=document.createElement(\"a\"),r=Object.create(null);t.href=e,t.search&&t.search.replace(/^\\?/,\"\").splitOrEmpty(/(?:&(?:amp;)?|;)/).forEach(function(e){var t=e.split(\"=\"),n=_slicedToArray(t,2),a=n[0],i=n[1];r[a]=i});var n=t.host&&\"/\"!==t.pathname[0]?\"/\"+t.pathname:t.pathname;return{href:t.href,protocol:t.protocol,host:t.host,hostname:t.hostname,port:t.port,path:\"\"+n+t.search,pathname:n,query:t.search,search:t.search,queries:r,searches:r,hash:t.hash}}function p(e,t,r){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e))||null===e)throw new Error(\"Util.newExceptionFrom original parameter must be an object\");if(\"function\"!=typeof t)throw new Error(\"Util.newExceptionFrom exceptionType parameter must be an error type constructor\");var n=new t(e.message);void 0!==e.name&&(n.name=e.name),void 0!==e.code&&(n.code=e.code),void 0!==e.columnNumber&&(n.columnNumber=e.columnNumber),void 0!==e.description&&(n.description=e.description),void 0!==e.fileName&&(n.fileName=e.fileName),void 0!==e.lineNumber&&(n.lineNumber=e.lineNumber),void 0!==e.number&&(n.number=e.number),void 0!==e.stack&&(n.stack=e.stack);var a=void 0===r?\"undefined\":_typeof(r);if(\"undefined\"!==a)if(\"object\"===a&&null!==r)Object.assign(n,r);else{if(\"string\"!==a)throw new Error(\"Util.newExceptionFrom override parameter must be an object or string\");n.message=r}return n}var g=/[&<>\"'`]/g,m=new RegExp(g.source),v=Object.freeze({\"&\":\"&amp;\",\"<\":\"&lt;\",\">\":\"&gt;\",'\"':\"&quot;\",\"'\":\"&#39;\",\"`\":\"&#96;\"}),y=/&(?:amp|#38|#x26|lt|#60|#x3c|gt|#62|#x3e|quot|#34|#x22|apos|#39|#x27|#96|#x60);/gi,b=new RegExp(y.source,\"i\"),w=Object.freeze({\"&amp;\":\"&\",\"&#38;\":\"&\",\"&#x26;\":\"&\",\"&lt;\":\"<\",\"&#60;\":\"<\",\"&#x3c;\":\"<\",\"&gt;\":\">\",\"&#62;\":\">\",\"&#x3e;\":\">\",\"&quot;\":'\"',\"&#34;\":'\"',\"&#x22;\":'\"',\"&apos;\":\"'\",\"&#39;\":\"'\",\"&#x27;\":\"'\",\"&#96;\":\"`\",\"&#x60;\":\"`\"}),k=Has.performance?performance:Date,S=/^([+-]?(?:\\d*\\.)?\\d+)([Mm]?[Ss])$/;return Object.freeze(Object.defineProperties({},{toEnum:{value:e},toStringTag:{value:t},isNumeric:{value:r},isBoolean:{value:n},sameValueZero:{value:a},slugify:{value:i},escape:{value:o},unescape:{value:s},charAndPosAt:{value:u},fromCssTime:{value:c},toCssTime:{value:d},fromCssProperty:{value:f},parseUrl:{value:h},newExceptionFrom:{value:p},now:{value:l},random:{value:Math.random},entityEncode:{value:o},entityDecode:{value:s},evalExpression:{value:function(){return Scripting.evalJavaScript.apply(Scripting,arguments)}},evalStatements:{value:function(){return Scripting.evalJavaScript.apply(Scripting,arguments)}}}))}(),SimpleStore=function(){function e(e,n){if(r)return r.create(e,n);for(var a=0;a<t.length;++a)if(t[a].init(e,n))return r=t[a],r.create(e,n);throw new Error(\"no valid storage adapters found\")}var t=[],r=null;return Object.freeze(Object.defineProperties({},{adapters:{value:t},create:{value:e}}))}();SimpleStore.adapters.push(function(){function e(){function e(e){try{var t=window[e],r=\"_sc_\"+String(Date.now());t.setItem(r,r);var n=t.getItem(r)===r;return t.removeItem(r),n}catch(e){}return!1}return r=e(\"localStorage\")&&e(\"sessionStorage\")}function t(e,t){if(!r)throw new Error(\"adapter not initialized\");return new n(e,t)}var r=!1,n=function(){function e(t,r){_classCallCheck(this,e);var n=t+\".\",a=null,i=null;r?(a=window.localStorage,i=\"localStorage\"):(a=window.sessionStorage,i=\"sessionStorage\"),Object.defineProperties(this,{_engine:{value:a},_prefix:{value:n},_prefixRe:{value:new RegExp(\"^\"+RegExp.escape(n))},name:{value:i},id:{value:t},persistent:{value:!!r}})}return _createClass(e,[{key:\"size\",value:function(){return this.keys().length}},{key:\"keys\",value:function(){for(var e=[],t=0;t<this._engine.length;++t){var r=this._engine.key(t);this._prefixRe.test(r)&&e.push(r.replace(this._prefixRe,\"\"))}return e}},{key:\"has\",value:function(e){return!(\"string\"!=typeof e||!e)&&this._engine.hasOwnProperty(this._prefix+e)}},{key:\"get\",value:function(t){if(\"string\"!=typeof t||!t)return null;var r=this._engine.getItem(this._prefix+t);return null==r?null:e._deserialize(r)}},{key:\"set\",value:function(t,r){if(\"string\"!=typeof t||!t)return!1;try{this._engine.setItem(this._prefix+t,e._serialize(r))}catch(e){if(/quota.?(?:exceeded|reached)/i.test(e.name+e.message))throw Util.newExceptionFrom(e,Error,this.name+\" quota exceeded\");throw e}return!0}},{key:\"delete\",value:function(e){return!(\"string\"!=typeof e||!e)&&(this._engine.removeItem(this._prefix+e),!0)}},{key:\"clear\",value:function(){for(var e=this.keys(),t=0,r=e.length;t<r;++t)this.delete(e[t]);return!0}},{key:\"length\",get:function(){return this.keys().length}}],[{key:\"_serialize\",value:function(e){return JSON.stringify(e)}},{key:\"_deserialize\",value:function(e){return JSON.parse(e&&\"{\"!=e[0]?LZString.decompressFromUTF16(e):e)}}]),e}();return Object.freeze(Object.defineProperties({},{init:{value:e},create:{value:t}}))}()),SimpleStore.adapters.push(function(){function e(e){try{var t=\"_sc_\"+String(Date.now());o._setCookie(t,o._serialize(t),undefined),i=o._deserialize(o._getCookie(t))===t,o._setCookie(t,undefined,a)}catch(e){i=!1}return i&&r(e),i}function t(e,t){if(!i)throw new Error(\"adapter not initialized\");return new o(e,t)}function r(e){if(\"\"!==document.cookie)for(var t=e+\".\",r=new RegExp(\"^\"+RegExp.escape(t)),i=e+\"!.\",s=e+\"*.\",u=/\\.(?:state|rcWarn)$/,l=document.cookie.split(/;\\s*/),c=0;c<l.length;++c){var d=l[c].split(\"=\"),f=decodeURIComponent(d[0]);if(r.test(f)){var h=decodeURIComponent(d[1]);\"\"!==h&&function(){var e=!u.test(f);o._setCookie(f,undefined,a),o._setCookie(f.replace(r,function(){return e?i:s}),h,e?n:undefined)}()}}}var n=\"Tue, 19 Jan 2038 03:14:07 GMT\",a=\"Thu, 01 Jan 1970 00:00:00 GMT\",i=!1,o=function(){function e(t,r){_classCallCheck(this,e);var n=t+(r?\"!\":\"*\")+\".\";Object.defineProperties(this,{_prefix:{value:n},_prefixRe:{value:new RegExp(\"^\"+RegExp.escape(n))},name:{value:\"cookie\"},id:{value:t},persistent:{value:!!r}})}return _createClass(e,[{key:\"size\",value:function(){return this.keys().length}},{key:\"keys\",value:function(){if(\"\"===document.cookie)return[];for(var e=document.cookie.split(/;\\s*/),t=[],r=0;r<e.length;++r){var n=e[r].split(\"=\"),a=decodeURIComponent(n[0]);if(this._prefixRe.test(a)){\"\"!==decodeURIComponent(n[1])&&t.push(a.replace(this._prefixRe,\"\"))}}return t}},{key:\"has\",value:function(t){return!(\"string\"!=typeof t||!t)&&null!==e._getCookie(this._prefix+t)}},{key:\"get\",value:function(t){if(\"string\"!=typeof t||!t)return null;var r=e._getCookie(this._prefix+t);return null===r?null:e._deserialize(r)}},{key:\"set\",value:function(t,r){if(\"string\"!=typeof t||!t)return!1;try{if(e._setCookie(this._prefix+t,e._serialize(r),this.persistent?n:undefined),!this.has(t))throw new Error(\"unknown validation error during set\")}catch(e){throw Util.newExceptionFrom(e,Error,\"cookie error: \"+e.message)}return!0}},{key:\"delete\",value:function(t){if(\"string\"!=typeof t||!t||!this.has(t))return!1;try{if(e._setCookie(this._prefix+t,undefined,a),this.has(t))throw new Error(\"unknown validation error during delete\")}catch(e){throw Util.newExceptionFrom(e,Error,\"cookie error: \"+e.message)}return!0}},{key:\"clear\",value:function(){for(var e=this.keys(),t=0,r=e.length;t<r;++t)this.delete(e[t]);return!0}},{key:\"length\",get:function(){return this.keys().length}}],[{key:\"_getCookie\",value:function(e){if(!e||\"\"===document.cookie)return null;for(var t=document.cookie.split(/;\\s*/),r=0;r<t.length;++r){var n=t[r].split(\"=\");if(e===decodeURIComponent(n[0])){return decodeURIComponent(n[1])||null}}return null}},{key:\"_setCookie\",value:function(e,t,r){if(e){var n=encodeURIComponent(e)+\"=\";null!=t&&(n+=encodeURIComponent(t)),null!=r&&(n+=\"; expires=\"+r),n+=\"; path=/\",document.cookie=n}}},{key:\"_serialize\",value:function(e){return LZString.compressToBase64(JSON.stringify(e))}},{key:\"_deserialize\",value:function(e){return JSON.parse(LZString.decompressFromBase64(e))}}]),e}();return Object.freeze(Object.defineProperties({},{init:{value:e},create:{value:t}}))}());var DebugView=function(){return function(){function e(t,r,n,a){_classCallCheck(this,e),Object.defineProperties(this,{parent:{value:t},view:{value:document.createElement(\"span\")},break:{value:document.createElement(\"wbr\")}}),jQuery(this.view).attr({title:a,\"aria-label\":a,\"data-type\":null!=r?r:\"\",\"data-name\":null!=n?n:\"\"}).addClass(\"debug\"),jQuery(this.break).addClass(\"debug hidden\"),this.parent.appendChild(this.view),this.parent.appendChild(this.break)}return _createClass(e,[{key:\"append\",value:function(e){return jQuery(this.view).append(e),this}},{key:\"modes\",value:function(e){if(null==e){var t={};return this.view.className.splitOrEmpty(/\\s+/).forEach(function(e){\"debug\"!==e&&(t[e]=!0)}),t}if(\"object\"===(void 0===e?\"undefined\":_typeof(e)))return Object.keys(e).forEach(function(t){this[e[t]?\"addClass\":\"removeClass\"](t)},jQuery(this.view)),this;throw new Error(\"DebugView.prototype.modes options parameter must be an object or null/undefined\")}},{key:\"remove\",value:function(){var e=jQuery(this.view);this.view.hasChildNodes()&&e.contents().appendTo(this.parent),e.remove(),jQuery(this.break).remove()}},{key:\"output\",get:function(){return this.view}},{key:\"type\",get:function(){return this.view.getAttribute(\"data-type\")},set:function(e){this.view.setAttribute(\"data-type\",null!=e?e:\"\")}},{key:\"name\",get:function(){return this.view.getAttribute(\"data-name\")},set:function(e){this.view.setAttribute(\"data-name\",null!=e?e:\"\")}},{key:\"title\",get:function(){return this.view.title},set:function(e){this.view.title=e}}],[{key:\"isEnabled\",value:function(){return\"enabled\"===jQuery(document.documentElement).attr(\"data-debug-view\")}},{key:\"enable\",value:function(){jQuery(document.documentElement).attr(\"data-debug-view\",\"enabled\"),jQuery.event.trigger(\":debugviewupdate\")}},{key:\"disable\",value:function(){jQuery(document.documentElement).removeAttr(\"data-debug-view\"),jQuery.event.trigger(\":debugviewupdate\")}},{key:\"toggle\",value:function(){\"enabled\"===jQuery(document.documentElement).attr(\"data-debug-view\")?e.disable():e.enable()}}]),e}()}(),PRNGWrapper=function(){return function(){function e(t,r){_classCallCheck(this,e),Object.defineProperties(this,new Math.seedrandom(t,r,function(e,t){return{_prng:{value:e},seed:{writable:!0,value:t},pull:{writable:!0,value:0},random:{value:function(){return++this.pull,this._prng()}}}}))}return _createClass(e,null,[{key:\"marshal\",value:function(e){if(!e||!e.hasOwnProperty(\"seed\")||!e.hasOwnProperty(\"pull\"))throw new Error(\"PRNG is missing required data\");return{seed:e.seed,pull:e.pull}}},{key:\"unmarshal\",value:function(t){if(!t||!t.hasOwnProperty(\"seed\")||!t.hasOwnProperty(\"pull\"))throw new Error(\"PRNG object is missing required data\");for(var r=new e(t.seed,!1),n=t.pull;n>0;--n)r.random();return r}}]),e}()}(),StyleWrapper=function(){var e=new RegExp(Patterns.cssImage,\"g\"),t=new RegExp(Patterns.cssImage);return function(){function r(e){if(_classCallCheck(this,r),null==e)throw new TypeError(\"StyleWrapper style parameter must be an HTMLStyleElement object\");Object.defineProperties(this,{style:{value:e}})}return _createClass(r,[{key:\"isEmpty\",value:function(){return 0===this.style.cssRules.length}},{key:\"set\",value:function(e){this.clear(),this.add(e)}},{key:\"add\",value:function(r){var n=r;t.test(n)&&(e.lastIndex=0,n=n.replace(e,function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup({source:e,matchStart:0});if(t.hasOwnProperty(\"error\")||t.pos<e.length)return e;var r=t.source;if(\"data:\"!==r.slice(0,5)&&Story.has(r)){var n=Story.get(r);n.tags.includes(\"Twine.image\")&&(r=n.text.trim())}return'url(\"'+r.replace(/\"/g,\"%22\")+'\")'})),this.style.styleSheet?this.style.styleSheet.cssText+=n:this.style.appendChild(document.createTextNode(n))}},{key:\"clear\",value:function(){this.style.styleSheet?this.style.styleSheet.cssText=\"\":jQuery(this.style).empty()}}]),r}()}(),Diff=function(){function e(t,n){for(var a=Object.prototype.toString,i=t instanceof Array,o=[].concat(Object.keys(t),Object.keys(n)).sort().filter(function(e,t,r){return 0===t||r[t-1]!==e}),s={},u=void 0,l=function(e){return e===u},c=0,d=o.length;c<d;++c){var f=o[c],h=t[f],p=n[f];if(t.hasOwnProperty(f))if(n.hasOwnProperty(f)){if(h===p)continue;if((void 0===h?\"undefined\":_typeof(h))===(void 0===p?\"undefined\":_typeof(p)))if(\"function\"==typeof h)h.toString()!==p.toString()&&(s[f]=[r.Copy,p]);else if(\"object\"!==(void 0===h?\"undefined\":_typeof(h))||null===h)s[f]=[r.Copy,p];else{var g=a.call(h),m=a.call(p);if(g===m)if(h instanceof Date)Number(h)!==Number(p)&&(s[f]=[r.Copy,clone(p)]);else if(h instanceof Map)s[f]=[r.Copy,clone(p)];else if(h instanceof RegExp)h.toString()!==p.toString()&&(s[f]=[r.Copy,clone(p)]);else if(h instanceof Set)s[f]=[r.Copy,clone(p)];else if(\"[object Object]\"!==g)s[f]=[r.Copy,clone(p)];else{var v=e(h,p);null!==v&&(s[f]=v)}else s[f]=[r.Copy,clone(p)]}else s[f]=[r.Copy,\"object\"!==(void 0===p?\"undefined\":_typeof(p))||null===p?p:clone(p)]}else if(i&&Util.isNumeric(f)){var y=Number(f);if(!u){u=\"\";do{u+=\"~\"}while(o.some(l));s[u]=[r.SpliceArray,y,y]}y<s[u][1]&&(s[u][1]=y),y>s[u][2]&&(s[u][2]=y)}else s[f]=r.Delete;else s[f]=[r.Copy,\"object\"!==(void 0===p?\"undefined\":_typeof(p))||null===p?p:clone(p)]}return Object.keys(s).length>0?s:null}function t(e,n){for(var a=Object.keys(n||{}),i=clone(e),o=0,s=a.length;o<s;++o){var u=a[o],l=n[u];if(l===r.Delete)delete i[u];else if(l instanceof Array)switch(l[0]){case r.SpliceArray:i.splice(l[1],l[2]-l[1]+1);break;case r.Copy:i[u]=clone(l[1]);break;case r.CopyDate:i[u]=new Date(l[1])}else i[u]=t(i[u],l)}return i}var r=Util.toEnum({Delete:0,SpliceArray:1,Copy:2,CopyDate:3});return Object.freeze(Object.defineProperties({},{Op:{value:r},diff:{value:e},patch:{value:t}}))}(),L10n=function(){function e(){r()}function t(e,t){if(!e)return\"\";var r=function(e){var t=void 0;return e.some(function(e){return!!l10nStrings.hasOwnProperty(e)&&(t=e,!0)}),t}(Array.isArray(e)?e:[e]);if(!r)return\"\";for(var i=l10nStrings[r],o=0;a.test(i);){if(++o>50)throw new Error(\"L10n.get exceeded maximum replacement iterations, probable infinite loop\");n.lastIndex=0,i=i.replace(n,function(e){var r=e.slice(1,-1);return t&&t.hasOwnProperty(r)?t[r]:l10nStrings.hasOwnProperty(r)?l10nStrings[r]:void 0})}return i}function r(){strings&&Object.keys(strings).length>0&&Object.keys(l10nStrings).forEach(function(e){try{var t=void 0;switch(e){case\"identity\":t=strings.identity;break;case\"aborting\":t=strings.aborting;break;case\"cancel\":t=strings.cancel;break;case\"close\":t=strings.close;break;case\"ok\":t=strings.ok;break;case\"errorTitle\":t=strings.errors.title;break;case\"errorNonexistentPassage\":t=strings.errors.nonexistentPassage;break;case\"errorSaveMissingData\":t=strings.errors.saveMissingData;break;case\"errorSaveIdMismatch\":t=strings.errors.saveIdMismatch;break;case\"warningDegraded\":t=strings.warnings.degraded;break;case\"debugViewTitle\":t=strings.debugView.title;break;case\"debugViewToggle\":t=strings.debugView.toggle;break;case\"uiBarToggle\":t=strings.uiBar.toggle;break;case\"uiBarBackward\":t=strings.uiBar.backward;break;case\"uiBarForward\":t=strings.uiBar.forward;break;case\"uiBarJumpto\":t=strings.uiBar.jumpto;break;case\"jumptoTitle\":t=strings.jumpto.title;break;case\"jumptoTurn\":t=strings.jumpto.turn;break;case\"jumptoUnavailable\":t=strings.jumpto.unavailable;break;case\"savesTitle\":t=strings.saves.title;break;case\"savesDisallowed\":t=strings.saves.disallowed;break;case\"savesIncapable\":t=strings.saves.incapable;break;case\"savesLabelAuto\":t=strings.saves.labelAuto;break;case\"savesLabelDelete\":t=strings.saves.labelDelete;break;case\"savesLabelExport\":t=strings.saves.labelExport;break;case\"savesLabelImport\":t=strings.saves.labelImport;break;case\"savesLabelLoad\":t=strings.saves.labelLoad;break;case\"savesLabelClear\":t=strings.saves.labelClear;break;case\"savesLabelSave\":t=strings.saves.labelSave;break;case\"savesLabelSlot\":t=strings.saves.labelSlot;break;case\"savesUnavailable\":t=strings.saves.unavailable;break;case\"savesUnknownDate\":t=strings.saves.unknownDate;break;case\"settingsTitle\":t=strings.settings.title;break;case\"settingsOff\":t=strings.settings.off;break;case\"settingsOn\":t=strings.settings.on;break;case\"settingsReset\":t=strings.settings.reset;break;case\"restartTitle\":t=strings.restart.title;break;case\"restartPrompt\":t=strings.restart.prompt;break;case\"shareTitle\":t=strings.share.title;break;case\"autoloadTitle\":t=strings.autoload.title;break;case\"autoloadCancel\":t=strings.autoload.cancel;break;case\"autoloadOk\":t=strings.autoload.ok;break;case\"autoloadPrompt\":t=strings.autoload.prompt;break;case\"macroBackText\":t=strings.macros.back.text;break;case\"macroReturnText\":t=strings.macros.return.text}t&&(l10nStrings[e]=t.replace(/%\\w+%/g,function(e){return\"{\"+e.slice(1,-1)+\"}\"}))}catch(e){}})}var n=/\\{\\w+\\}/g,a=new RegExp(n.source);return Object.freeze(Object.defineProperties({},{init:{value:e},get:{value:t}}))}(),strings={errors:{},warnings:{},debugView:{},uiBar:{},jumpto:{},saves:{},settings:{},restart:{},share:{},autoload:{},macros:{back:{},return:{}}},l10nStrings={identity:\"game\",aborting:\"Aborting\",cancel:\"Cancel\",close:\"Close\",ok:\"OK\",errorTitle:\"Error\",errorToggle:\"Toggle the error view\",errorNonexistentPassage:'the passage \"{passage}\" does not exist',errorSaveMissingData:\"save is missing required data. Either the loaded file is not a save or the save has become corrupted\",errorSaveIdMismatch:\"save is from the wrong {identity}\",_warningIntroLacking:\"Your browser either lacks or has disabled\",_warningOutroDegraded:\", so this {identity} is running in a degraded mode. You may be able to continue, however, some parts may not work properly.\",warningNoWebStorage:\"{_warningIntroLacking} the Web Storage API{_warningOutroDegraded}\",warningDegraded:\"{_warningIntroLacking} some of the capabilities required by this {identity}{_warningOutroDegraded}\",debugBarToggle:\"Toggle the debug bar\",debugBarNoWatches:\"— no watches set —\",debugBarAddWatch:\"Add watch\",debugBarDeleteWatch:\"Delete watch\",debugBarWatchAll:\"Watch all\",debugBarWatchNone:\"Delete all\",debugBarLabelAdd:\"Add\",debugBarLabelWatch:\"Watch\",debugBarLabelTurn:\"Turn\",debugBarLabelViews:\"Views\",debugBarViewsToggle:\"Toggle the debug views\",debugBarWatchToggle:\"Toggle the watch panel\",uiBarToggle:\"Toggle the UI bar\",uiBarBackward:\"Go backward within the {identity} history\",uiBarForward:\"Go forward within the {identity} history\",uiBarJumpto:\"Jump to a specific point within the {identity} history\",jumptoTitle:\"Jump To\",jumptoTurn:\"Turn\",jumptoUnavailable:\"No jump points currently available…\",savesTitle:\"Saves\",savesDisallowed:\"Saving has been disallowed on this passage.\",savesIncapable:\"{_warningIntroLacking} the capabilities required to support saves, so saves have been disabled for this session.\",savesLabelAuto:\"Autosave\",savesLabelDelete:\"Delete\",savesLabelExport:\"Save to Disk…\",savesLabelImport:\"Load from Disk…\",savesLabelLoad:\"Load\",savesLabelClear:\"Delete All\",savesLabelSave:\"Save\",savesLabelSlot:\"Slot\",savesUnavailable:\"No save slots found…\",savesUnknownDate:\"unknown\",settingsTitle:\"Settings\",settingsOff:\"Off\",settingsOn:\"On\",settingsReset:\"Reset to Defaults\",restartTitle:\"Restart\",restartPrompt:\"Are you sure that you want to restart? Unsaved progress will be lost.\",shareTitle:\"Share\",autoloadTitle:\"Autoload\",autoloadCancel:\"Go to start\",autoloadOk:\"Load autosave\",autoloadPrompt:\"An autosave exists. Load it now or go to the start?\",macroBackText:\"Back\",macroReturnText:\"Return\"},Config=function(){function e(){throw new Error(\"Config.history.mode has been deprecated and is no longer used by SugarCube, please remove it from your code\")}function t(){throw new Error(\"Config.history.tracking has been deprecated, use Config.history.maxStates instead\")}return Object.seal({debug:!1,addVisitedLinkClass:!1,cleanupWikifierOutput:!1,loadDelay:0,audio:Object.seal({pauseOnFadeToZero:!0,preloadMetadata:!0}),history:Object.seal({controls:!0,maxStates:100,get mode(){e()},set mode(t){e()},get tracking(){t()},set tracking(e){t()}}),macros:Object.seal({ifAssignmentError:!0,maxLoopIterations:1e3}),navigation:Object.seal({override:undefined}),passages:Object.seal({descriptions:undefined,displayTitles:!1,nobr:!1,start:undefined,transitionOut:undefined}),saves:Object.seal({autoload:undefined,autosave:undefined,id:\"untitled-story\",isAllowed:undefined,onLoad:undefined,onSave:undefined,slots:8,version:undefined}),ui:Object.seal({stowBarInitially:800,updateStoryElements:!0}),transitionEndEventName:function(){for(var e=new Map([[\"transition\",\"transitionend\"],[\"MSTransition\",\"msTransitionEnd\"],[\"WebkitTransition\",\"webkitTransitionEnd\"],[\"MozTransition\",\"transitionend\"]]),t=[].concat(_toConsumableArray(e.keys())),r=document.createElement(\"div\"),n=0;n<t.length;++n)if(r.style[t[n]]!==undefined)return e.get(t[n]);return\"\"}()})}(),SimpleAudio=function(){function e(){if(arguments.length<2){var e=[];throw arguments.length<1&&e.push(\"track ID\"),arguments.length<2&&e.push(\"sources\"),new Error(\"no \"+e.join(\" or \")+\" specified\")}var t=String(arguments[0]).trim(),r='track ID \"'+t+'\"';if(_.test(t))throw new Error(\"invalid \"+r+\": track IDs must not contain colons or whitespace\");var n=Array.isArray(arguments[1])?Array.from(arguments[1]):Array.from(arguments).slice(1),a=void 0;try{a=T(n)}catch(e){throw new Error(r+\": error during track initialization: \"+e.message)}if(Config.debug&&!a.hasSource())throw new Error(r+\": no supported audio sources found\");N.has(t)&&N.get(t)._destroy(),N.set(t,a)}function t(e){return N.has(e)&&N.get(e)._destroy(),N.delete(e)}function r(){N.forEach(function(e){return e._destroy()}),N.clear()}function n(e){return N.has(e)}function a(e){return N.get(e)||null}function i(){if(arguments.length<2){var e=[];throw arguments.length<1&&e.push(\"group ID\"),arguments.length<2&&e.push(\"track IDs\"),new Error(\"no \"+e.join(\" or \")+\" specified\")}var t=String(arguments[0]).trim(),r='group ID \"'+t+'\"';if(\":\"!==t[0]||_.test(t.slice(1)))throw new Error(\"invalid \"+r+\": group IDs must start with a colon and must not contain colons or whitespace\");if(A.includes(t))throw new Error(\"cannot clobber special \"+r);var n=Array.isArray(arguments[1])?Array.from(arguments[1]):Array.from(arguments).slice(1),a=void 0;try{a=new Set(n.map(function(e){if(!N.has(e))throw new Error('track \"'+e+'\" does not exist');return e}))}catch(e){throw new Error(r+\": error during group initialization: \"+e.message)}I.set(t,Object.freeze(Array.from(a)))}function o(e){return I.delete(e)}function s(){I.clear()}function u(e){return I.has(e)}function l(e){return I.get(e)||null}function c(){if(arguments.length<2){var e=[];throw arguments.length<1&&e.push(\"list ID\"),arguments.length<2&&e.push(\"track IDs\"),new Error(\"no \"+e.join(\" or \")+\" specified\")}var t=String(arguments[0]).trim(),r='list ID \"'+t+'\"';if(_.test(t))return this.error(\"invalid \"+r+\": list IDs must not contain colons or whitespace\");var n=Array.isArray(arguments[1])?Array.from(arguments[1]):Array.from(arguments).slice(1),a=void 0;try{a=new V(n.map(function(e){if(null===e)throw new Error(\"track descriptor must be a string or object (type: null)\");switch(void 0===e?\"undefined\":_typeof(e)){case\"string\":e={id:e};break;case\"object\":if(!e.hasOwnProperty(\"id\")&&!e.hasOwnProperty(\"sources\"))throw new Error('track descriptor must contain one of either an \"id\" or a \"sources\" property');if(e.hasOwnProperty(\"id\")&&e.hasOwnProperty(\"sources\"))throw new Error('track descriptor must contain either an \"id\" or a \"sources\" property, not both');break;default:throw new Error(\"track descriptor must be a string or object (type: \"+(void 0===e?\"undefined\":_typeof(e))+\")\")}var t=void 0,r=void 0,n=void 0;if(e.hasOwnProperty(\"id\")){if(\"string\"!=typeof e.id)throw new Error('\"id\" property must be a string');if(!N.has(e.id))throw new Error('track \"'+e.id+'\" does not exist');r=N.get(e.id)}else if(e.hasOwnProperty(\"sources\")){if(!Array.isArray(e.sources)||0===e.sources.length)throw new Error('\"sources\" property must be a non-empty array');try{r=T(e.sources)}catch(e){throw new Error(\"error during track initialization: \"+e.message)}if(Config.debug&&!r.hasSource())throw new Error(\"no supported audio sources found\")}if(e.hasOwnProperty(\"copy\")){if(e.hasOwnProperty(\"sources\"))throw new Error('\"copy\" property is not allowed with the \"sources\" property');if(\"boolean\"!=typeof(t=e.copy))throw new Error('\"copy\" property must be a boolean')}if(e.hasOwnProperty(\"volume\")&&(\"number\"!=typeof(n=e.volume)||Number.isNaN(n)||!Number.isFinite(n)))throw new Error('\"volume\" property must be a finite number');return{copy:t,track:r,volume:null!=n?n:r.volume()}}))}catch(e){throw new Error(r+\": error during playlist initialization: \"+e.message)}D.has(t)&&D.get(t)._destroy(),D.set(t,a)}function d(e){return D.has(e)&&D.get(e)._destroy(),D.delete(e)}function f(){D.forEach(function(e){return e._destroy()}),D.clear()}function h(e){return D.has(e)}function p(e){return D.get(e)||null}function g(){if(0===arguments.length)throw new Error(\"no track selector specified\");var e=String(arguments[0]).trim(),t=new Set;try{var r=function e(t){var r=t.id,a=void 0;switch(r){case\":all\":a=n;break;case\":looped\":a=n.filter(function(e){return N.get(e).isLooped()});break;case\":muted\":a=n.filter(function(e){return N.get(e).isMuted()});break;case\":paused\":a=n.filter(function(e){return N.get(e).isPaused()});break;case\":playing\":a=n.filter(function(e){return N.get(e).isPlaying()});break;default:a=\":\"===r[0]?I.get(r):[r]}if(t.hasOwnProperty(\"not\")){var i=t.not.map(function(t){return e(t)}).flatten();a=a.filter(function(e){return!i.includes(e)})}return a},n=Array.from(N.keys());U(e).forEach(function(e){return r(e).forEach(function(e){if(!N.has(e))throw new Error('track \"'+e+'\" does not exist');t.add(e)})})}catch(e){throw new Error(\"error during runner initialization: \"+e.message)}return new B(t)}function m(){C(\"load\")}function v(){C(\"loadwithscreen\")}function y(e){if(null==e)return R;R=!!e,C(\"mute\",R)}function b(e){if(null==e)return W;if(W=!!e){var t=Visibility.changeEvent+\".SimpleAudio:masterMuteOnHidden\";jQuery(document).off(t).on(t,function(){return y(Visibility.isHidden())}),Visibility.isHidden()&&y(!0)}else jQuery(document).off(\".SimpleAudio:masterMuteOnHidden\")}function w(e){if(null==e)return M;if(\"number\"!=typeof e||Number.isNaN(e)||!Number.isFinite(e))throw new Error(\"rate must be a finite number\");M=Math.clamp(e,.2,5),C(\"rate\",M)}function k(){C(\"stop\")}function S(){C(\"unload\")}function E(e){if(null==e)return Q;if(\"number\"!=typeof e||Number.isNaN(e)||!Number.isFinite(e))throw new Error(\"volume must be a finite number\");Q=Math.clamp(e,0,1),C(\"volume\",Q)}function x(e,t){if(\"function\"!=typeof t)throw new Error(\"callback parameter must be a function\");L.set(e,t)}function j(e){L.delete(e)}function C(e,t){L.forEach(function(r){return r(e,t)})}function T(e){return new F(e.map(function(e){if(\"data:\"!==e.slice(0,5)&&Story.has(e)){var t=Story.get(e);if(t.tags.includes(\"Twine.audio\"))return t.text.trim()}var r=P.exec(e);return null===r?e:{format:r[1],src:r[2]}}))}var O=Object.freeze([\"click\",\"contextmenu\",\"dblclick\",\"keyup\",\"mouseup\",\"pointerup\",\"touchend\"]),A=Object.freeze([\":not\",\":all\",\":looped\",\":muted\",\":paused\",\":playing\"]),P=/^([\\w-]+)\\s*\\|\\s*(\\S.*)$/,_=/[:\\s]/,N=new Map,I=new Map,D=new Map,L=new Map,M=1,Q=1,R=!1,W=!1,F=function(){function e(t){if(_classCallCheck(this,e),t instanceof Array)this._create(t);else{if(!(t instanceof e))throw new Error(\"sources parameter must be either an array, of URIs or source objects, or an AudioTrack instance\");this._copy(t)}}return _createClass(e,[{key:\"_create\",value:function(t){var r=/^data:\\s*audio\\/([^;,]+)\\s*[;,]/i,n=/\\.([^.\\/\\\\]+)$/,a=e.getType,i=[],o=document.createElement(\"audio\");o.preload=\"none\",t.forEach(function(e){var t=null;switch(void 0===e?\"undefined\":_typeof(e)){case\"string\":var s=void 0;if(\"data:\"===e.slice(0,5)){if(null===(s=r.exec(e)))throw new Error(\"source data URI missing media type\")}else if(null===(s=n.exec(Util.parseUrl(e).pathname)))throw new Error(\"source URL missing file extension\");var u=a(s[1]);null!==u&&(t={src:e,type:u});break;case\"object\":if(null===e)throw new Error(\"source object cannot be null\");if(!e.hasOwnProperty(\"src\"))throw new Error('source object missing required \"src\" property');if(!e.hasOwnProperty(\"format\"))throw new Error('source object missing required \"format\" property');var l=a(e.format);null!==l&&(t={src:e.src,type:l});break;default:throw new Error(\"invalid source value (type: \"+(void 0===e?\"undefined\":_typeof(e))+\")\")}if(null!==t){Browser.isOpera&&(t.type=t.type.replace(/;.*$/,\"\"));var c=document.createElement(\"source\");c.src=t.src,c.type=t.type,o.appendChild(c),i.push(t)}}),o.hasChildNodes()&&Config.audio.preloadMetadata&&(o.preload=\"metadata\"),this._finalize(o,i,clone(t))}},{key:\"_copy\",value:function(e){this._finalize(e.audio.cloneNode(!0),clone(e.sources),clone(e.originals))}},{key:\"_finalize\",value:function(e,t,r){var n=this;Object.defineProperties(this,{audio:{configurable:!0,value:e},sources:{value:Object.freeze(t)},originals:{value:Object.freeze(r)},_error:{writable:!0,value:!1},_faderId:{writable:!0,value:null},_mute:{writable:!0,value:!1},_rate:{writable:!0,value:1},_volume:{writable:!0,value:1}}),jQuery(this.audio).on(\"loadstart\",function(){return n._error=!1}).on(\"error\",function(){return n._error=!0}).find(\"source:last-of-type\").on(\"error\",function(){return n._trigger(\"error\")}),x(this,function(e){if(!n.audio)return void j(n);switch(e){case\"loadwithscreen\":if(n.hasSource()){var t=LoadScreen.lock();n.one(\"canplaythrough.AudioTrack:loadwithscreen error.AudioTrack:loadwithscreen\",function(){\njQuery(this).off(\".AudioTrack:loadwithscreen\"),LoadScreen.unlock(t)}).load()}break;case\"load\":n.load();break;case\"mute\":n._updateAudioMute();break;case\"rate\":n._updateAudioRate();break;case\"stop\":n.stop();break;case\"volume\":n._updateAudioVolume();break;case\"unload\":n.unload()}})}},{key:\"_trigger\",value:function(e){jQuery(this.audio).triggerHandler(e)}},{key:\"_destroy\",value:function(){j(this),this.audio&&(jQuery(this.audio).off(),this.unload(),this._error=!0,delete this.audio)}},{key:\"clone\",value:function(){return new e(this)}},{key:\"load\",value:function(){var e=this;if(this.fadeStop(),this.audio.pause(),!this.audio.hasChildNodes()){if(0===this.sources.length)return;this.sources.forEach(function(t){var r=document.createElement(\"source\");r.src=t.src,r.type=t.type,e.audio.appendChild(r)})}\"auto\"!==this.audio.preload&&(this.audio.preload=\"auto\"),this.isLoading()||this.audio.load()}},{key:\"unload\",value:function(){this.fadeStop(),this.stop();var e=this.audio;for(e.preload=\"none\";e.hasChildNodes();)e.removeChild(e.firstChild);e.load()}},{key:\"play\",value:function(){var e=this;return this.hasSource()?this.isUnloaded()?Promise.reject(new Error(\"no sources are loaded\")):this.isFailed()?Promise.reject(new Error(\"failed to load any of the sources\")):(\"auto\"!==this.audio.preload&&(this.audio.preload=\"auto\"),Has.audioPromise?this.audio.play():new Promise(function(t,r){jQuery(e.audio).off(\".AudioTrack:play\").one(\"error.AudioTrack:play playing.AudioTrack:play\",function(n){jQuery(e).off(\".AudioTrack:play\"),\"error\"===n.type?r(new Error(\"unknown error\")):t()}),e.audio.play()})):Promise.reject(new Error(\"none of the candidate sources were acceptable\"))}},{key:\"playWhenAllowed\",value:function(){var e=this;this.play().catch(function(){var t=O.map(function(e){return e+\".AudioTrack:playWhenAllowed\"}).join(\" \");jQuery(document).one(t,function(){jQuery(document).off(\".AudioTrack:playWhenAllowed\"),e.audio.play()})})}},{key:\"pause\",value:function(){this.audio.pause()}},{key:\"stop\",value:function(){this.audio.pause(),this.time(0),this._trigger(\":stop\")}},{key:\"fade\",value:function(e,t,r){var n=this;if(\"number\"!=typeof e)throw new TypeError(\"duration parameter must be a number\");if(\"number\"!=typeof t)throw new TypeError(\"toVolume parameter must be a number\");if(null!=r&&\"number\"!=typeof r)throw new TypeError(\"fromVolume parameter must be a number\");if(!this.hasSource())return Promise.reject(new Error(\"none of the candidate sources were acceptable\"));if(this.isUnloaded())return Promise.reject(new Error(\"no sources are loaded\"));if(this.isFailed())return Promise.reject(new Error(\"failed to load any of the sources\"));this.fadeStop();var a=Math.clamp(null==r?this.volume():r,0,1),i=Math.clamp(t,0,1);return a!==i?(this.volume(a),jQuery(this.audio).off(\"timeupdate.AudioTrack:fade\").one(\"timeupdate.AudioTrack:fade\",function(){var t=void 0,r=void 0;a<i?(t=a,r=i):(t=i,r=a);var o=Math.max(e,1),s=(i-a)/(o/.025);n._faderId=setInterval(function(){if(!n.isPlaying())return void n.fadeStop();n.volume(Math.clamp(n.volume()+s,t,r)),Config.audio.pauseOnFadeToZero&&0===n.volume()&&n.pause(),n.volume()===i&&(n.fadeStop(),n._trigger(\":fade\"))},25)}),this.play()):void 0}},{key:\"fadeIn\",value:function(e,t){this.fade(e,1,t)}},{key:\"fadeOut\",value:function(e,t){this.fade(e,0,t)}},{key:\"fadeStop\",value:function(){null!==this._faderId&&(clearInterval(this._faderId),this._faderId=null)}},{key:\"loop\",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(e){return null==e?this.audio.loop:(this.audio.loop=!!e,this)})},{key:\"mute\",value:function(e){return null==e?this._mute:(this._mute=!!e,this._updateAudioMute(),this)}},{key:\"_updateAudioMute\",value:function(){this.audio.muted=this._mute||R}},{key:\"rate\",value:function(e){if(null==e)return this._rate;if(\"number\"!=typeof e)throw new TypeError(\"rate parameter must be a number\");return this._rate=Math.clamp(e,.2,5),this._updateAudioRate(),this}},{key:\"_updateAudioRate\",value:function(){this.audio.playbackRate=Math.clamp(this._rate*M,.2,5)}},{key:\"time\",value:function(e){var t=this;if(null==e)return this.audio.currentTime;if(\"number\"!=typeof e)throw new TypeError(\"time parameter must be a number\");return this.hasMetadata()?this.audio.currentTime=e:jQuery(this.audio).off(\"loadedmetadata.AudioTrack:time\").one(\"loadedmetadata.AudioTrack:time\",function(){return t.audio.currentTime=e}),this}},{key:\"volume\",value:function(e){if(null==e)return this._volume;if(\"number\"!=typeof e)throw new TypeError(\"volume parameter must be a number\");return this._volume=Math.clamp(e,0,1),this._updateAudioVolume(),this}},{key:\"_updateAudioVolume\",value:function(){this.audio.volume=Math.clamp(this._volume*Q,0,1)}},{key:\"duration\",value:function(){return this.audio.duration}},{key:\"paused\",value:function(){return this.audio.paused}},{key:\"remaining\",value:function(){return this.audio.duration-this.audio.currentTime}},{key:\"isFailed\",value:function(){return this._error}},{key:\"isLoading\",value:function(){return this.audio.networkState===HTMLMediaElement.NETWORK_LOADING}},{key:\"isUnloaded\",value:function(){return!this.audio.hasChildNodes()}},{key:\"isUnavailable\",value:function(){return!this.hasSource()||this.isUnloaded()||this.isFailed()}},{key:\"isPlaying\",value:function(){return!this.audio.ended&&!this.audio.paused&&this.hasSomeData()}},{key:\"isPaused\",value:function(){return this.audio.paused&&(this.audio.duration===1/0||this.audio.currentTime>0)&&!this.audio.ended}},{key:\"isEnded\",value:function(){return this.audio.ended}},{key:\"isFading\",value:function(){return null!==this._faderId}},{key:\"isMuted\",value:function(){return this._mute}},{key:\"isLooped\",value:function(){return this.audio.loop}},{key:\"isSeeking\",value:function(){return this.audio.seeking}},{key:\"hasSource\",value:function(){return this.sources.length>0}},{key:\"hasNoData\",value:function(){return this.audio.readyState===HTMLMediaElement.HAVE_NOTHING}},{key:\"hasMetadata\",value:function(){return this.audio.readyState>=HTMLMediaElement.HAVE_METADATA}},{key:\"hasSomeData\",value:function(){return this.audio.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA}},{key:\"hasData\",value:function(){return this.audio.readyState===HTMLMediaElement.HAVE_ENOUGH_DATA}},{key:\"on\",value:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return jQuery.fn.on.apply(jQuery(this.audio),t),this}},{key:\"one\",value:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return jQuery.fn.one.apply(jQuery(this.audio),t),this}},{key:\"off\",value:function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return jQuery.fn.off.apply(jQuery(this.audio),t),this}}],[{key:\"_verifyType\",value:function(t){if(!t||!Has.audio)return null;var r=e._types;if(!r.hasOwnProperty(t)){var n=document.createElement(\"audio\");r[t]=\"\"!==n.canPlayType(t).replace(/^no$/i,\"\")}return r[t]?t:null}},{key:\"getType\",value:function(t){if(!t||!Has.audio)return null;var r=e.formats,n=t.toLowerCase(),a=r.hasOwnProperty(n)?r[n]:\"audio/\"+n;return e._verifyType(a)}},{key:\"canPlayFormat\",value:function(t){return null!==e.getType(t)}},{key:\"canPlayType\",value:function(t){return null!==e._verifyType(t)}}]),e}();Object.defineProperties(F,{formats:{value:{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\"}},_types:{value:{}}});var V=function(){function e(t){if(_classCallCheck(this,e),t instanceof Array)this._create(t);else{if(!(t instanceof e))throw new Error(\"tracks parameter must be either an array, of track objects, or an AudioTrack instance\");this._copy(t)}}return _createClass(e,[{key:\"_create\",value:function(e){var t=this;this._finalize(e.map(function(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"tracks parameter array members must be objects\");var r=void 0,n=void 0,a=void 0,i=void 0;if(e instanceof F)r=!0,n=e.rate(),a=e.clone(),i=e.volume();else{if(!e.hasOwnProperty(\"track\"))throw new Error('track object missing required \"track\" property');if(!(e.track instanceof F))throw new Error('track object\\'s \"track\" property must be an AudioTrack object');r=e.hasOwnProperty(\"copy\")&&e.copy,n=e.hasOwnProperty(\"rate\")?e.rate:e.track.rate(),a=r?e.track.clone():e.track,i=e.hasOwnProperty(\"volume\")?e.volume:e.track.volume()}return a.stop(),a.loop(!1),a.mute(!1),a.rate(n),a.volume(i),a.on(\"ended.AudioList\",function(){return t._onEnd()}),{copy:r,track:a,volume:i,rate:n}}))}},{key:\"_copy\",value:function(e){this._finalize(clone(e.tracks))}},{key:\"_finalize\",value:function(e){Object.defineProperties(this,{tracks:{configurable:!0,value:Object.freeze(e)},queue:{configurable:!0,value:[]},current:{writable:!0,value:null},_rate:{writable:!0,value:1},_volume:{writable:!0,value:1},_mute:{writable:!0,value:!1},_loop:{writable:!0,value:!1},_shuffle:{writable:!0,value:!1}})}},{key:\"_destroy\",value:function(){this.stop(),this.tracks.filter(function(e){return e.copy}).forEach(function(e){return e.track._destroy()}),delete this.tracks,delete this.queue}},{key:\"load\",value:function(){this.tracks.forEach(function(e){return e.track.load()})}},{key:\"unload\",value:function(){this.stop(),this.tracks.forEach(function(e){return e.track.unload()})}},{key:\"play\",value:function(){(null!==this.current&&!this.current.track.isUnavailable()&&!this.current.track.isEnded()||(0===this.queue.length&&this._fillQueue(),this._next()))&&this.current.track.play()}},{key:\"pause\",value:function(){null!==this.current&&this.current.track.pause()}},{key:\"stop\",value:function(){null!==this.current&&(this.current.track.stop(),this.current=null),this._drainQueue()}},{key:\"skip\",value:function(){this._next()?this.current.track.play():this._loop&&this.play()}},{key:\"fade\",value:function(e,t,r){if(\"number\"!=typeof e)throw new TypeError(\"duration parameter must be a number\");if(\"number\"!=typeof t)throw new TypeError(\"toVolume parameter must be a number\");if(null!=r&&\"number\"!=typeof r)throw new TypeError(\"fromVolume parameter must be a number\");if(0===this.queue.length&&this._fillQueue(),null!==this.current&&!this.current.track.isUnavailable()&&!this.current.track.isEnded()||this._next()){var n=Math.clamp(t,0,1)*this.current.volume,a=void 0;null!=r&&(a=Math.clamp(r,0,1)*this.current.volume),this.current.track.fade(e,n,a),this._volume=t}}},{key:\"fadeIn\",value:function(e,t){this.fade(e,1,t)}},{key:\"fadeOut\",value:function(e,t){this.fade(e,0,t)}},{key:\"loop\",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(e){return null==e?this._loop:(this._loop=!!e,this)})},{key:\"mute\",value:function(e){return null==e?this._mute:(this._mute=!!e,null!==this.current&&this.current.track.mute(this._mute),this)}},{key:\"rate\",value:function(e){if(null==e)return this._rate;if(\"number\"!=typeof e)throw new TypeError(\"rate parameter must be a number\");return this._rate=Math.clamp(e,.2,5),null!==this.current&&this.current.track.rate(this._rate*this.current.rate),this}},{key:\"shuffle\",value:function(e){var t=this;if(null==e)return this._shuffle;if(this._shuffle=!!e,this.queue.length>0&&(this._fillQueue(),!this._shuffle&&null!==this.current&&this.queue.length>1)){var r=this.queue.findIndex(function(e){return e===t.current});if(-1!==r){var n;(n=this.queue).push.apply(n,_toConsumableArray(this.queue.splice(0,r+1)))}}return this}},{key:\"volume\",value:function(e){if(null==e)return this._volume;if(\"number\"!=typeof e)throw new TypeError(\"volume parameter must be a number\");return this._volume=Math.clamp(e,0,1),null!==this.current&&this.current.track.volume(this._volume*this.current.volume),this}},{key:\"duration\",value:function(){if(arguments.length>0)throw new Error(\"duration takes no parameters\");return this.tracks.map(function(e){return e.track.duration()}).reduce(function(e,t){return e+t},0)}},{key:\"remaining\",value:function(){if(arguments.length>0)throw new Error(\"remaining takes no parameters\");var e=this.queue.map(function(e){return e.track.duration()}).reduce(function(e,t){return e+t},0);return null!==this.current&&(e+=this.current.track.remaining()),e}},{key:\"time\",value:function(){if(arguments.length>0)throw new Error(\"time takes no parameters\");return this.duration()-this.remaining()}},{key:\"isPlaying\",value:function(){return null!==this.current&&this.current.track.isPlaying()}},{key:\"isEnded\",value:function(){return 0===this.queue.length&&(null===this.current||this.current.track.isEnded())}},{key:\"isPaused\",value:function(){return null===this.current||this.current.track.isPaused()}},{key:\"isMuted\",value:function(){return this._mute}},{key:\"isLooped\",value:function(){return this._loop}},{key:\"isShuffled\",value:function(){return this._shuffle}},{key:\"_next\",value:function(){null!==this.current&&(this.current.track.stop(),this.current=null);for(var e=void 0;e=this.queue.shift();)if(!e.track.isUnavailable()){this.current=e;break}return null!==this.current&&(this.current.track.mute(this._mute),this.current.track.rate(this._rate*this.current.rate),this.current.track.volume(this._volume*this.current.volume),!0)}},{key:\"_onEnd\",value:function(){if(0===this.queue.length){if(!this._loop)return;this._fillQueue()}this._next()&&this.current.track.play()}},{key:\"_drainQueue\",value:function(){this.queue.splice(0)}},{key:\"_fillQueue\",value:function(){var e;this._drainQueue(),(e=this.queue).push.apply(e,_toConsumableArray(this.tracks.filter(function(e){return!e.track.isUnavailable()}))),0!==this.queue.length&&this._shuffle&&(this.queue.shuffle(),this.queue.length>1&&this.queue[0]===this.current&&this.queue.push(this.queue.shift()))}}]),e}(),B=function(){function e(t){if(_classCallCheck(this,e),!(t instanceof Set||t instanceof e))throw new TypeError(\"list parameter must be a Set or a AudioRunner instance\");Object.defineProperties(this,{trackIds:{value:new Set(t instanceof e?t.trackIds:t)}})}return _createClass(e,[{key:\"load\",value:function(){e._run(this.trackIds,F.prototype.load)}},{key:\"unload\",value:function(){e._run(this.trackIds,F.prototype.unload)}},{key:\"play\",value:function(){e._run(this.trackIds,F.prototype.play)}},{key:\"playWhenAllowed\",value:function(){e._run(this.trackIds,F.prototype.playWhenAllowed)}},{key:\"pause\",value:function(){e._run(this.trackIds,F.prototype.pause)}},{key:\"stop\",value:function(){e._run(this.trackIds,F.prototype.stop)}},{key:\"fade\",value:function(t,r,n){if(null==t||null==r)throw new Error(\"fade requires parameters\");e._run(this.trackIds,F.prototype.fade,t,r,n)}},{key:\"fadeIn\",value:function(t,r){if(null==t)throw new Error(\"fadeIn requires a parameter\");e._run(this.trackIds,F.prototype.fadeIn,t,1,r)}},{key:\"fadeOut\",value:function(t,r){if(null==t)throw new Error(\"fadeOut requires a parameter\");e._run(this.trackIds,F.prototype.fadeOut,t,0,r)}},{key:\"fadeStop\",value:function(){e._run(this.trackIds,F.prototype.fadeStop)}},{key:\"loop\",value:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(t){if(null==t)throw new Error(\"loop requires a parameter\");return e._run(this.trackIds,F.prototype.loop,t),this})},{key:\"mute\",value:function(t){if(null==t)throw new Error(\"mute requires a parameter\");return e._run(this.trackIds,F.prototype.mute,t),this}},{key:\"rate\",value:function(t){if(null==t)throw new Error(\"rate requires a parameter\");return e._run(this.trackIds,F.prototype.rate,t),this}},{key:\"time\",value:function(t){if(null==t)throw new Error(\"time requires a parameter\");return e._run(this.trackIds,F.prototype.time,t),this}},{key:\"volume\",value:function(t){if(null==t)throw new Error(\"volume requires a parameter\");return e._run(this.trackIds,F.prototype.volume,t),this}},{key:\"on\",value:function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return e._run.apply(e,[this.trackIds,F.prototype.on].concat(r)),this}},{key:\"one\",value:function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return e._run.apply(e,[this.trackIds,F.prototype.one].concat(r)),this}},{key:\"off\",value:function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return e._run.apply(e,[this.trackIds,F.prototype.off].concat(r)),this}}],[{key:\"_run\",value:function(e,t){for(var r=arguments.length,n=Array(r>2?r-2:0),a=2;a<r;a++)n[a-2]=arguments[a];e.forEach(function(e){var r=N.get(e);r&&t.apply(r,n)})}}]),e}(),U=function(){function e(e,t){var a=void 0;if(r.lastIndex=t,null===(a=r.exec(e))||\"(\"!==a[0])throw new Error('invalid \":not()\" syntax: missing parentheticals');n.lastIndex=r.lastIndex;for(var i=r.lastIndex,o={str:\"\",nextMatch:-1},s=1;null!==(a=n.exec(e));)if(\"(\"===a[0]?++s:--s,s<1){o.nextMatch=n.lastIndex,o.str=e.slice(i,o.nextMatch-1);break}return o}function t(r){for(var n=[],a=/:?[^\\s:()]+/g,i=void 0;null!==(i=a.exec(r));){var o=i[0];if(\":not\"===o){if(0===n.length)throw new Error('invalid negation: no group ID preceded \":not()\"');var s=n[n.length-1];if(\":\"!==s.id[0])throw new Error('invalid negation of track \"'+s.id+'\": only groups may be negated with \":not()\"');var u=e(r,a.lastIndex);if(-1===u.nextMatch)throw new Error('unknown error parsing \":not()\"');a.lastIndex=u.nextMatch,s.not=t(u.str)}else n.push({id:o})}return n}var r=/\\S/g,n=/[()]/g;return t}();return Object.freeze(Object.defineProperties({},{tracks:{value:Object.freeze(Object.defineProperties({},{add:{value:e},delete:{value:t},clear:{value:r},has:{value:n},get:{value:a}}))},groups:{value:Object.freeze(Object.defineProperties({},{add:{value:i},delete:{value:o},clear:{value:s},has:{value:u},get:{value:l}}))},lists:{value:Object.freeze(Object.defineProperties({},{add:{value:c},delete:{value:d},clear:{value:f},has:{value:h},get:{value:p}}))},select:{value:g},load:{value:m},loadWithScreen:{value:v},mute:{value:y},muteOnHidden:{value:b},rate:{value:w},stop:{value:k},unload:{value:S},volume:{value:E}}))}(),State=function(){function e(){session.delete(\"state\"),R=[],W=c(),F=-1,V=[],B=null===B?null:new PRNGWrapper(B.seed,!1)}function t(){if(session.has(\"state\")){var e=session.get(\"state\");return null!=e&&(n(e),!0)}return!1}function r(e){var t={index:F};return e?t.history=clone(R):t.delta=A(R),V.length>0&&(t.expired=[]),null!==B&&(t.seed=B.seed),t}function n(e,t){if(null==e)throw new Error(\"state object is null or undefined\");if(!e.hasOwnProperty(t?\"history\":\"delta\")||0===e[t?\"history\":\"delta\"].length)throw new Error(\"state object has no history or history is empty\");if(!e.hasOwnProperty(\"index\"))throw new Error(\"state object has no index\");if(null!==B&&!e.hasOwnProperty(\"seed\"))throw new Error(\"state object has no seed, but PRNG is enabled\");if(null===B&&e.hasOwnProperty(\"seed\"))throw new Error(\"state object has seed, but PRNG is disabled\");R=t?clone(e.history):P(e.delta),F=e.index,V=e.hasOwnProperty(\"expired\")?[].concat(_toConsumableArray(e.expired)):[],e.hasOwnProperty(\"seed\")&&(B.seed=e.seed),g(F)}function a(){return r(!0)}function i(e){return n(e,!0)}function o(){return V}function s(){return V.length+v()}function u(){return V.concat(R.slice(0,v()).map(function(e){return e.title}))}function l(e){return null!=e&&\"\"!==e&&(!!V.includes(e)||!!R.slice(0,v()).some(function(t){return t.title===e}))}function c(e,t){return{title:null==e?\"\":String(e),variables:null==t?{}:clone(t)}}function d(){return W}function f(){return F}function h(){return W.title}function p(){return W.variables}function g(e){if(null==e)throw new Error(\"moment activation attempted with null or undefined\");switch(void 0===e?\"undefined\":_typeof(e)){case\"object\":W=clone(e);break;case\"number\":if(b())throw new Error(\"moment activation attempted with index on empty history\");if(e<0||e>=y())throw new RangeError(\"moment activation attempted with out-of-bounds index; need [0, \"+(y()-1)+\"], got \"+e);W=clone(R[e]);break;default:throw new TypeError('moment activation attempted with a \"'+(void 0===e?\"undefined\":_typeof(e))+'\"; must be an object or valid history stack index')}return null!==B&&(B=PRNGWrapper.unmarshal({seed:B.seed,pull:W.pull})),session.set(\"state\",r()),jQuery.event.trigger(\":historyupdate\"),W}function m(){return R}function v(){return F+1}function y(){return R.length}function b(){return 0===R.length}function w(){return R.length>0?R[F]:null}function k(){return R.length>0?R[R.length-1]:null}function S(){return R.length>0?R[0]:null}function E(e){return b()||e<0||e>F?null:R[e]}function x(e){if(b())return null;var t=1+(e?Math.abs(e):0);return t>v()?null:R[v()-t]}function j(e){if(b()||null==e||\"\"===e)return!1;for(var t=F;t>=0;--t)if(R[t].title===e)return!0;return!1}function C(e){if(v()<y()&&R.splice(v(),y()-v()),R.push(c(e,W.variables)),B&&(k().pull=B.pull),Config.history.maxStates>0)for(;y()>Config.history.maxStates;)V.push(R.shift().title);return F=y()-1,g(F),v()}function T(e){return!(null==e||e<0||e>=y()||e===F)&&(F=e,g(F),!0)}function O(e){return null!=e&&0!==e&&T(F+e)}function A(e){if(!Array.isArray(e))return null;if(0===e.length)return[];for(var t=[clone(e[0])],r=1,n=e.length;r<n;++r)t.push(Diff.diff(e[r-1],e[r]));return t}function P(e){if(!Array.isArray(e))return null;if(0===e.length)return[];for(var t=[clone(e[0])],r=1,n=e.length;r<n;++r)t.push(Diff.patch(t[r-1],e[r]));return t}function _(e,t){if(!b()){var r=void 0;throw r=\"the Story JavaScript\",new Error(\"State.initPRNG must be called during initialization, within either \"+r+\" or the StoryInit special passage\")}B=new PRNGWrapper(e,t),W.pull=B.pull}function N(){return B?B.random():Math.random()}function I(){U={},TempVariables=U}function D(){return U}function L(e){var t=Q(e);if(null!==t){for(var r=t.names,n=t.store,a=0,i=r.length;a<i;++a){if(void 0===n[r[a]])return;n=n[r[a]]}return n}}function M(e,t){var r=Q(e);if(null===r)return!1;for(var n=r.names,a=n.pop(),i=r.store,o=0,s=n.length;o<s;++o){if(void 0===i[n[o]])return!1;i=i[n[o]]}return i[a]=t,!0}function Q(e){for(var t={store:\"$\"===e[0]?State.variables:State.temporary,names:[]},r=e,n=void 0;null!==(n=z.exec(r));)r=r.slice(n[0].length),n[1]?t.names.push(n[1]):n[2]?t.names.push(n[2]):n[3]?t.names.push(n[3]):n[4]?t.names.push(n[4]):n[5]?t.names.push(L(n[5])):n[6]&&t.names.push(Number(n[6]));return\"\"===r?t:null}var R=[],W=c(),F=-1,V=[],B=null,U={},z=new RegExp(\"^(?:\"+Patterns.variableSigil+\"(\"+Patterns.identifier+\")|\\\\.(\"+Patterns.identifier+\")|\\\\[(?:(?:\\\"((?:\\\\\\\\.|[^\\\"\\\\\\\\])+)\\\")|(?:'((?:\\\\\\\\.|[^'\\\\\\\\])+)')|(\"+Patterns.variableSigil+Patterns.identifierFirstChar+\".*)|(\\\\d+))\\\\])\");return Object.freeze(Object.defineProperties({},{reset:{value:e},restore:{value:t},marshalForSave:{value:a},unmarshalForSave:{value:i},expired:{get:o},turns:{get:s},passages:{get:u},hasPlayed:{value:l},active:{get:d},activeIndex:{get:f},passage:{get:h},variables:{get:p},history:{get:m},length:{get:v},size:{get:y},isEmpty:{value:b},current:{get:w},top:{get:k},bottom:{get:S},index:{value:E},peek:{value:x},has:{value:j},create:{value:C},goTo:{value:T},go:{value:O},deltaEncode:{value:A},deltaDecode:{value:P},initPRNG:{value:_},random:{value:N},clearTemporary:{value:I},temporary:{get:D},getVar:{value:L},setVar:{value:M},restart:{value:function(){return Engine.restart()}},backward:{value:function(){return Engine.backward()}},forward:{value:function(){return Engine.forward()}},display:{value:function(){return Engine.display.apply(Engine,arguments)}},show:{value:function(){return Engine.show.apply(Engine,arguments)}},play:{value:function(){return Engine.play.apply(Engine,arguments)}}}))}(),Scripting=function(){function addAccessibleClickHandler(e,t,r,n,a){if(arguments.length<2)throw new Error(\"addAccessibleClickHandler insufficient number of parameters\");var i=void 0,o=void 0;if(\"function\"==typeof t?(i=t,o={namespace:n,one:!!r}):(i=r,o={namespace:a,one:!!n,selector:t}),\"function\"!=typeof i)throw new TypeError(\"addAccessibleClickHandler handler parameter must be a function\");return jQuery(e).ariaClick(o,i)}function insertElement(e,t,r,n,a,i){var o=jQuery(document.createElement(t));return r&&o.attr(\"id\",r),n&&o.addClass(n),i&&o.attr(\"title\",i),a&&o.text(a),e&&o.appendTo(e),o[0]}function insertText(e,t){jQuery(e).append(document.createTextNode(t))}function removeChildren(e){jQuery(e).empty()}function removeElement(e){jQuery(e).remove()}function fade(e,t){function r(){i+=.05*a,n(o,Math.easeInOut(i)),(1===a&&i>=1||-1===a&&i<=0)&&(e.style.visibility=\"in\"===t.fade?\"visible\":\"hidden\",o.parentNode.replaceChild(e,o),o=null,window.clearInterval(s),t.onComplete&&t.onComplete())}function n(e,t){e.style.zoom=1,e.style.filter=\"alpha(opacity=\"+Math.floor(100*t)+\")\",e.style.opacity=t}var a=\"in\"===t.fade?1:-1,i=void 0,o=e.cloneNode(!0),s=void 0;e.parentNode.replaceChild(o,e),\"in\"===t.fade?(i=0,o.style.visibility=\"visible\"):i=1,n(o,i),s=window.setInterval(r,25)}function scrollWindowTo(e,t){function r(){l+=a,window.scroll(0,i+u*(s*Math.easeInOut(l))),l>=1&&window.clearInterval(c)}function n(e){for(var t=0;e.offsetParent;)t+=e.offsetTop,e=e.offsetParent;return t}var a=null!=t?Number(t):.1;Number.isNaN(a)||!Number.isFinite(a)||a<0?a=.1:a>1&&(a=1);var i=window.scrollY?window.scrollY:document.body.scrollTop,o=function(e){var t=n(e),r=t+e.offsetHeight,a=window.scrollY?window.scrollY:document.body.scrollTop,i=window.innerHeight?window.innerHeight:document.body.clientHeight,o=a+i;return t>=a&&r>o&&e.offsetHeight<i?t-(i-e.offsetHeight)+20:t}(e),s=Math.abs(i-o),u=i>o?-1:1,l=0,c=void 0;c=window.setInterval(r,25)}function either(){if(0!==arguments.length)return Array.prototype.concat.apply([],arguments).random()}function hasVisited(){if(0===arguments.length)throw new Error(\"hasVisited called with insufficient parameters\");if(State.isEmpty())return!1;for(var e=Array.prototype.concat.apply([],arguments),t=State.passages,r=0,n=e.length;r<n;++r)if(!t.includes(e[r]))return!1;return!0}function lastVisited(){if(0===arguments.length)throw new Error(\"lastVisited called with insufficient parameters\");if(State.isEmpty())return-1;for(var e=Array.prototype.concat.apply([],arguments),t=State.passages,r=t.length-1,n=State.turns,a=0,i=e.length;a<i&&n>-1;++a){var o=t.lastIndexOf(e[a]);n=Math.min(n,-1===o?-1:r-o)}return n}function passage(){return State.passage}function previous(){var e=State.passages;if(arguments.length>0){var t=Number(arguments[0]);if(!Number.isSafeInteger(t)||t<1)throw new RangeError(\"previous offset parameter must be a positive integer greater than zero\");return e.length>t?e[e.length-1-t]:\"\"}for(var r=e.length-2;r>=0;--r)if(e[r]!==State.passage)return e[r];return\"\"}function random(){var e=void 0,t=void 0;switch(arguments.length){case 0:throw new Error(\"random called with insufficient parameters\");case 1:e=0,t=Math.trunc(arguments[0]);break;default:e=Math.trunc(arguments[0]),t=Math.trunc(arguments[1])}if(!Number.isInteger(e))throw new Error(\"random min parameter must be an integer\");if(!Number.isInteger(t))throw new Error(\"random max parameter must be an integer\");if(e>t){var r=[t,e];e=r[0],t=r[1]}return Math.floor(State.random()*(t-e+1))+e}function randomFloat(){var e=void 0,t=void 0;switch(arguments.length){case 0:throw new Error(\"randomFloat called with insufficient parameters\");case 1:e=0,t=Number(arguments[0]);break;default:e=Number(arguments[0]),t=Number(arguments[1])}if(Number.isNaN(e)||!Number.isFinite(e))throw new Error(\"randomFloat min parameter must be a number\");if(Number.isNaN(t)||!Number.isFinite(t))throw new Error(\"randomFloat max parameter must be a number\");if(e>t){var r=[t,e];e=r[0],t=r[1]}return State.random()*(t-e)+e}function tags(){if(0===arguments.length)return Story.get(State.passage).tags.slice(0);for(var e=Array.prototype.concat.apply([],arguments),t=[],r=0,n=e.length;r<n;++r)t=t.concat(Story.get(e[r]).tags);return t}function temporary(){return State.temporary}function time(){return null===Engine.lastPlay?0:Util.now()-Engine.lastPlay}function turns(){return State.turns}function variables(){return State.variables}function visited(){if(State.isEmpty())return 0;for(var e=Array.prototype.concat.apply([],0===arguments.length?[State.passage]:arguments),t=State.passages,r=State.turns,n=0,a=e.length;n<a&&r>0;++n)r=Math.min(r,t.count(e[n]));return r}function visitedTags(){if(0===arguments.length)throw new Error(\"visitedTags called with insufficient parameters\");if(State.isEmpty())return 0;for(var e=Array.prototype.concat.apply([],arguments),t=e.length,r=State.passages,n=new Map,a=0,i=0,o=r.length;i<o;++i){var s=r[i];if(n.has(s))n.get(s)&&++a;else{var u=Story.get(s).tags;if(u.length>0){for(var l=0,c=0;c<t;++c)u.includes(e[c])&&++l;l===t?(++a,n.set(s,!0)):n.set(s,!1)}}}return a}function evalJavaScript(code,output){return function(code,output){return eval(code)}.call(output?{output:output}:null,String(code),output)}function evalTwineScript(code,output){return function(code,output){return eval(code)}.call(output?{output:output}:null,parse(String(code)),output)}var _ref8=function(){function e(e){return Util.parseUrl(e).path.replace(/^[^\\w]+|[^\\w]+$/g,\"\").replace(/[^\\w]+/g,\"-\").toLocaleLowerCase()}function t(t){return new Promise(function(r,n){jQuery(document.createElement(\"script\")).one(\"load abort error\",function(e){jQuery(e.target).off(),\"load\"===e.type?r(e.target):n(new Error('importScripts failed to load the script \"'+t+'\".'))}).appendTo(document.head).attr({id:\"script-imported-\"+e(t),type:\"text/javascript\",src:t})})}function r(t){return new Promise(function(r,n){jQuery(document.createElement(\"link\")).one(\"load abort error\",function(e){jQuery(e.target).off(),\"load\"===e.type?r(e.target):n(new Error('importStyles failed to load the stylesheet \"'+t+'\".'))}).appendTo(document.head).attr({id:\"style-imported-\"+e(t),rel:\"stylesheet\",href:t})})}function n(e){return e.reduce(function(e,t){return e=e.then(t)},Promise.resolve())}function a(){for(var e=arguments.length,r=Array(e),a=0;a<e;a++)r[a]=arguments[a];return Promise.all(r.map(function(e){return Array.isArray(e)?n(e.map(function(e){return function(){return t(e)}})):t(e)}))}function i(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return Promise.all(t.map(function(e){return Array.isArray(e)?n(e.map(function(e){return function(){return r(e)}})):r(e)}))}return{importScripts:a,importStyles:i}}(),importScripts=_ref8.importScripts,importStyles=_ref8.importStyles,parse=function(){function e(e){if(0!==r.lastIndex)throw new RangeError(\"Scripting.parse last index is non-zero at start\");for(var a=e,i=void 0;null!==(i=r.exec(a));)if(i[5]){var o=i[5];if(\"$\"===o||\"_\"===o)continue;if(n.test(o))o=o[0];else if(\"is\"===o){var s=r.lastIndex,u=a.slice(s);/^\\s+not\\b/.test(u)&&(a=a.splice(s,u.search(/\\S/)),o=\"isnot\")}t.hasOwnProperty(o)&&(a=a.splice(i.index,o.length,t[o]),r.lastIndex+=t[o].length-o.length)}return a}var t=Object.freeze({$:\"State.variables.\",_:\"State.temporary.\",to:\"=\",eq:\"==\",neq:\"!=\",is:\"===\",isnot:\"!==\",gt:\">\",gte:\">=\",lt:\"<\",lte:\"<=\",and:\"&&\",or:\"||\",not:\"!\",def:'\"undefined\" !== typeof',ndef:'\"undefined\" === typeof'}),r=new RegExp([\"(\\\"\\\"|'')\",'(\"(?:\\\\\\\\.|[^\"\\\\\\\\])+\")',\"('(?:\\\\\\\\.|[^'\\\\\\\\])+')\",\"([=+\\\\-*\\\\/%<>&\\\\|\\\\^~!?:,;\\\\(\\\\)\\\\[\\\\]{}]+)\",\"([^\\\"'=+\\\\-*\\\\/%<>&\\\\|\\\\^~!?:,;\\\\(\\\\)\\\\[\\\\]{}\\\\s]+)\"].join(\"|\"),\"g\"),n=new RegExp(\"^\"+Patterns.variable);return e}();return Object.freeze(Object.defineProperties({},{parse:{value:parse},evalJavaScript:{value:evalJavaScript},evalTwineScript:{value:evalTwineScript}}))}(),_ref9=function(){return{EOF:-1,Lexer:function(){function e(t,r){if(_classCallCheck(this,e),arguments.length<2)throw new Error(\"Lexer constructor called with too few parameters (source:string , initialState:function)\");Object.defineProperties(this,{source:{value:t},initial:{value:r},state:{writable:!0,value:r},start:{writable:!0,value:0},pos:{writable:!0,value:0},depth:{writable:!0,value:0},items:{writable:!0,value:[]},data:{writable:!0,value:{}}})}return _createClass(e,[{key:\"reset\",value:function(){this.state=this.initial,this.start=0,this.pos=0,this.depth=0,this.items=[],\nthis.data={}}},{key:\"run\",value:function(){for(;null!==this.state;)this.state=this.state(this);return this.items}},{key:\"nextItem\",value:function(){for(;0===this.items.length&&null!==this.state;)this.state=this.state(this);return this.items.shift()}},{key:\"next\",value:function(){return this.pos>=this.source.length?-1:this.source[this.pos++]}},{key:\"peek\",value:function(){return this.pos>=this.source.length?-1:this.source[this.pos]}},{key:\"backup\",value:function(e){this.pos-=e||1}},{key:\"forward\",value:function(e){this.pos+=e||1}},{key:\"ignore\",value:function(){this.start=this.pos}},{key:\"accept\",value:function(e){var t=this.next();return-1!==t&&(!!e.includes(t)||(this.backup(),!1))}},{key:\"acceptRe\",value:function(e){var t=this.next();return-1!==t&&(!!e.test(t)||(this.backup(),!1))}},{key:\"acceptRun\",value:function(e){for(;;){var t=this.next();if(-1===t)return;if(!e.includes(t))break}this.backup()}},{key:\"acceptRunRe\",value:function(e){for(;;){var t=this.next();if(-1===t)return;if(!e.test(t))break}this.backup()}},{key:\"emit\",value:function(e){this.items.push({type:e,text:this.source.slice(this.start,this.pos),start:this.start,pos:this.pos}),this.start=this.pos}},{key:\"error\",value:function(e,t){if(arguments.length<2)throw new Error(\"Lexer.prototype.error called with too few parameters (type:number , message:string)\");return this.items.push({type:e,message:t,text:this.source.slice(this.start,this.pos),start:this.start,pos:this.pos}),null}}],[{key:\"enumFromNames\",value:function(e){var t=e.reduce(function(e,t,r){return e[t]=r,e},{});return Object.freeze(Object.assign(Object.create(null),t))}}]),e}()}}(),EOF=_ref9.EOF,Lexer=_ref9.Lexer,Wikifier=function(){var e=0,t=function(){function t(r,n,a){_classCallCheck(this,t),t.Parser.Profile.isEmpty()&&t.Parser.Profile.compile(),Object.defineProperties(this,{source:{value:String(n)},options:{writable:!0,value:Object.assign({profile:\"all\"},a)},nextMatch:{writable:!0,value:0},output:{writable:!0,value:null},_rawArgs:{writable:!0,value:\"\"}}),null==r?this.output=document.createDocumentFragment():r.jquery?this.output=r[0]:this.output=r;try{++e,this.subWikify(this.output),1===e&&Config.cleanupWikifierOutput&&convertBreaks(this.output)}finally{--e}}return _createClass(t,[{key:\"subWikify\",value:function(e,r,n){var a=this.output,i=void 0;this.output=e,null!=n&&\"object\"===(void 0===n?\"undefined\":_typeof(n))&&(i=this.options,this.options=Object.assign({},this.options,n));var o=t.Parser.Profile.get(this.options.profile),s=r?new RegExp(\"(?:\"+r+\")\",this.options.ignoreTerminatorCase?\"gim\":\"gm\"):null,u=void 0,l=void 0;do{if(o.parserRegExp.lastIndex=this.nextMatch,s&&(s.lastIndex=this.nextMatch),l=o.parserRegExp.exec(this.source),(u=s?s.exec(this.source):null)&&(!l||u.index<=l.index))return u.index>this.nextMatch&&this.outputText(this.output,this.nextMatch,u.index),this.matchStart=u.index,this.matchLength=u[0].length,this.matchText=u[0],this.nextMatch=s.lastIndex,this.output=a,void(i&&(this.options=i));if(l){l.index>this.nextMatch&&this.outputText(this.output,this.nextMatch,l.index),this.matchStart=l.index,this.matchLength=l[0].length,this.matchText=l[0],this.nextMatch=o.parserRegExp.lastIndex;for(var c=void 0,d=1,f=l.length;d<f;++d)if(l[d]){c=d-1;break}if(o.parsers[c].handler(this),null!=TempState.break)break}}while(u||l);null==TempState.break?this.nextMatch<this.source.length&&(this.outputText(this.output,this.nextMatch,this.source.length),this.nextMatch=this.source.length):this.output.lastChild&&this.output.lastChild.nodeType===Node.ELEMENT_NODE&&\"BR\"===this.output.lastChild.nodeName.toUpperCase()&&jQuery(this.output.lastChild).remove(),this.output=a,i&&(this.options=i)}},{key:\"outputText\",value:function(e,t,r){jQuery(e).append(document.createTextNode(this.source.substring(t,r)))}},{key:\"rawArgs\",value:function(){return this._rawArgs}},{key:\"fullArgs\",value:function(){return Scripting.parse(this._rawArgs)}}],[{key:\"wikifyEval\",value:function(e){var r=document.createDocumentFragment();new t(r,e);var n=r.querySelector(\".error\");if(null!==n)throw new Error(n.textContent.replace(errorPrologRegExp,\"\"));return r}},{key:\"createInternalLink\",value:function(e,t,r,n){var a=jQuery(document.createElement(\"a\"));return null!=t&&(a.attr(\"data-passage\",t),Story.has(t)?(a.addClass(\"link-internal\"),Config.addVisitedLinkClass&&State.hasPlayed(t)&&a.addClass(\"link-visited\")):a.addClass(\"link-broken\"),a.ariaClick({one:!0},function(){\"function\"==typeof n&&n(),Engine.play(t)})),r&&a.append(document.createTextNode(r)),e&&a.appendTo(e),a[0]}},{key:\"createExternalLink\",value:function(e,t,r){var n=jQuery(document.createElement(\"a\")).attr(\"target\",\"_blank\").addClass(\"link-external\").text(r).appendTo(e);return null!=t&&n.attr({href:t,tabindex:0}),n[0]}},{key:\"isExternalLink\",value:function(e){return!Story.has(e)&&(new RegExp(\"^\"+Patterns.url,\"gim\").test(e)||/[\\/.?#]/.test(e))}}]),t}();return Object.defineProperty(t,\"Parser\",{value:function(){function e(){return d}function t(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"Wikifier.Parser.add parser parameter must be an object\");if(!e.hasOwnProperty(\"name\"))throw new Error('parser object missing required \"name\" property');if(\"string\"!=typeof e.name)throw new Error('parser object \"name\" property must be a string');if(!e.hasOwnProperty(\"match\"))throw new Error('parser object missing required \"match\" property');if(\"string\"!=typeof e.match)throw new Error('parser object \"match\" property must be a string');if(!e.hasOwnProperty(\"handler\"))throw new Error('parser object missing required \"handler\" property');if(\"function\"!=typeof e.handler)throw new Error('parser object \"handler\" property must be a function');if(e.hasOwnProperty(\"profiles\")&&!Array.isArray(e.profiles))throw new Error('parser object \"profiles\" property must be an array');if(a(e.name))throw new Error('cannot clobber existing parser \"'+e.name+'\"');d.push(e)}function r(e){var t=d.find(function(t){return t.name===e});t&&d.delete(t)}function n(){return 0===d.length}function a(e){return!!d.find(function(t){return t.name===e})}function i(e){return d.find(function(t){return t.name===e})||null}function o(){return f}function s(){var e=d,t=e.filter(function(e){return!Array.isArray(e.profiles)||e.profiles.includes(\"core\")});return f=Object.freeze({all:{parsers:e,parserRegExp:new RegExp(e.map(function(e){return\"(\"+e.match+\")\"}).join(\"|\"),\"gm\")},core:{parsers:t,parserRegExp:new RegExp(t.map(function(e){return\"(\"+e.match+\")\"}).join(\"|\"),\"gm\")}})}function u(){return\"object\"!==(void 0===f?\"undefined\":_typeof(f))||0===Object.keys(f).length}function l(e){if(\"object\"!==(void 0===f?\"undefined\":_typeof(f))||!f.hasOwnProperty(e))throw new Error('nonexistent parser profile \"'+e+'\"');return f[e]}function c(e){return\"object\"===(void 0===f?\"undefined\":_typeof(f))&&f.hasOwnProperty(e)}var d=[],f=void 0;return Object.freeze(Object.defineProperties({},{parsers:{get:e},add:{value:t},delete:{value:r},isEmpty:{value:n},has:{value:a},get:{value:i},Profile:{value:Object.freeze(Object.defineProperties({},{profiles:{get:o},compile:{value:s},isEmpty:{value:u},has:{value:c},get:{value:l}}))}}))}()}),Object.defineProperties(t,{helpers:{value:{}},getValue:{value:State.getVar},setValue:{value:State.setVar},parse:{value:Scripting.parse},evalExpression:{value:Scripting.evalTwineScript},evalStatements:{value:Scripting.evalTwineScript},textPrimitives:{value:Patterns}}),Object.defineProperties(t.helpers,{inlineCss:{value:function(){function e(e){var r={classes:[],id:\"\",styles:{}},n=void 0;do{t.lastIndex=e.nextMatch;var a=t.exec(e.source);n=a&&a.index===e.nextMatch,n&&(a[1]?r.styles[Util.fromCssProperty(a[1])]=a[2].trim():a[3]?r.styles[Util.fromCssProperty(a[3])]=a[4].trim():a[5]?r.classes=r.classes.concat(a[5].slice(1).split(/\\./)):a[6]&&(r.id=a[6].slice(1).split(/#/).pop()),e.nextMatch=t.lastIndex)}while(n);return r}var t=new RegExp(Patterns.inlineCss,\"gm\");return e}()},evalText:{value:function(e){var t=void 0;try{switch(t=Scripting.evalTwineScript(e),void 0===t?\"undefined\":_typeof(t)){case\"string\":\"\"===t.trim()&&(t=e);break;case\"number\":t=String(t);break;default:t=e}}catch(r){t=e}return t}},evalPassageId:{value:function(e){return null==e||Story.has(e)?e:t.helpers.evalText(e)}},hasBlockContext:{value:function(e){for(var t=\"function\"==typeof window.getComputedStyle,r=e.length-1;r>=0;--r){var n=e[r];switch(n.nodeType){case Node.ELEMENT_NODE:var a=n.nodeName.toUpperCase();if(\"BR\"===a)return!0;var i=t?window.getComputedStyle(n,null):n.currentStyle;if(i&&i.display){if(\"none\"===i.display)continue;return\"block\"===i.display}switch(a){case\"ADDRESS\":case\"ARTICLE\":case\"ASIDE\":case\"BLOCKQUOTE\":case\"CENTER\":case\"DIV\":case\"DL\":case\"FIGURE\":case\"FOOTER\":case\"FORM\":case\"H1\":case\"H2\":case\"H3\":case\"H4\":case\"H5\":case\"H6\":case\"HEADER\":case\"HR\":case\"MAIN\":case\"NAV\":case\"OL\":case\"P\":case\"PRE\":case\"SECTION\":case\"TABLE\":case\"UL\":return!0}return!1;case Node.COMMENT_NODE:continue;default:return!1}}return!0}},createShadowSetterCallback:{value:function(){function e(){if(!a&&!(a=t.Parser.get(\"macro\")))throw new Error('cannot find \"macro\" parser');return a}function r(){for(var t=a||e(),r=new Set,n=t.context;null!==n;n=n.parent)n._shadows&&n._shadows.forEach(function(e){return r.add(e)});return[].concat(_toConsumableArray(r))}function n(e){var t={};return r().forEach(function(e){var r=e.slice(1),n=\"$\"===e[0]?State.variables:State.temporary;t[e]=n[r]}),function(){var r=Object.keys(t),n=r.length>0?{}:null;try{return r.forEach(function(e){var r=e.slice(1),a=\"$\"===e[0]?State.variables:State.temporary;a.hasOwnProperty(r)&&(n[r]=a[r]),a[r]=t[e]}),Scripting.evalJavaScript(e)}finally{r.forEach(function(e){var r=e.slice(1),a=\"$\"===e[0]?State.variables:State.temporary;t[e]=a[r],n.hasOwnProperty(r)?a[r]=n[r]:delete a[r]})}}}var a=null;return n}()},parseSquareBracketedMarkup:{value:function(){function e(e,t){e:for(;;)switch(e.next()){case\"\\\\\":var r=e.next();if(r!==EOF&&\"\\n\"!==r)break;case EOF:case\"\\n\":return EOF;case t:break e}return e.pos}function t(e){if(!e.accept(\"[\"))return e.error(o.Error,\"malformed square-bracketed markup\");if(e.accept(\"[\"))e.data.isLink=!0,e.emit(o.LinkMeta);else{if(e.accept(\"<>\"),!(e.accept(\"Ii\")&&e.accept(\"Mm\")&&e.accept(\"Gg\")&&e.accept(\"[\")))return e.error(o.Error,\"malformed square-bracketed markup\");e.data.isLink=!1,e.emit(o.ImageMeta)}return e.depth=2,r}function r(t){for(var r=t.data.isLink?\"link\":\"image\",i=s.None;;)switch(t.next()){case EOF:case\"\\n\":return t.error(o.Error,\"unterminated \"+r+\" markup\");case'\"':if(e(t,'\"')===EOF)return t.error(o.Error,\"unterminated double quoted string in \"+r+\" markup\");break;case\"|\":i===s.None&&(i=s.LTR,t.backup(),t.emit(o.Text),t.forward(),t.emit(o.DelimLTR));break;case\"-\":i===s.None&&\">\"===t.peek()&&(i=s.LTR,t.backup(),t.emit(o.Text),t.forward(2),t.emit(o.DelimLTR));break;case\"<\":i===s.None&&\"-\"===t.peek()&&(i=s.RTL,t.backup(),t.emit(t.data.isLink?o.Link:o.Source),t.forward(2),t.emit(o.DelimRTL));break;case\"[\":++t.depth;break;case\"]\":if(1===--t.depth)switch(t.peek()){case\"[\":return++t.depth,t.backup(),i===s.RTL?t.emit(o.Text):t.emit(t.data.isLink?o.Link:o.Source),t.forward(2),t.emit(o.InnerMeta),t.data.isLink?a:n;case\"]\":return--t.depth,t.backup(),i===s.RTL?t.emit(o.Text):t.emit(t.data.isLink?o.Link:o.Source),t.forward(2),t.emit(o.RightMeta),null;default:return t.error(o.Error,\"malformed \"+r+\" markup\")}}}function n(t){for(var r=t.data.isLink?\"link\":\"image\";;)switch(t.next()){case EOF:case\"\\n\":return t.error(o.Error,\"unterminated \"+r+\" markup\");case'\"':if(e(t,'\"')===EOF)return t.error(o.Error,\"unterminated double quoted string in \"+r+\" markup link component\");break;case\"[\":++t.depth;break;case\"]\":if(1===--t.depth)switch(t.peek()){case\"[\":return++t.depth,t.backup(),t.emit(o.Link),t.forward(2),t.emit(o.InnerMeta),a;case\"]\":return--t.depth,t.backup(),t.emit(o.Link),t.forward(2),t.emit(o.RightMeta),null;default:return t.error(o.Error,\"malformed \"+r+\" markup\")}}}function a(t){for(var r=t.data.isLink?\"link\":\"image\";;)switch(t.next()){case EOF:case\"\\n\":return t.error(o.Error,\"unterminated \"+r+\" markup\");case'\"':if(e(t,'\"')===EOF)return t.error(o.Error,\"unterminated double quoted string in \"+r+\" markup setter component\");break;case\"'\":if(e(t,\"'\")===EOF)return t.error(o.Error,\"unterminated single quoted string in \"+r+\" markup setter component\");break;case\"[\":++t.depth;break;case\"]\":if(1===--t.depth)return\"]\"!==t.peek()?t.error(o.Error,\"malformed \"+r+\" markup\"):(--t.depth,t.backup(),t.emit(o.Setter),t.forward(2),t.emit(o.RightMeta),null)}}function i(e){var r=new Lexer(e.source,t);r.start=r.pos=e.matchStart;var n={},a=r.run(),i=a.last();return i&&i.type===o.Error?n.error=i.message:a.forEach(function(e){var t=e.text.trim();switch(e.type){case o.ImageMeta:n.isImage=!0,\"<\"===t[1]?n.align=\"left\":\">\"===t[1]&&(n.align=\"right\");break;case o.LinkMeta:n.isLink=!0;break;case o.Link:\"~\"===t[0]?(n.forceInternal=!0,n.link=t.slice(1)):n.link=t;break;case o.Setter:n.setter=t;break;case o.Source:n.source=t;break;case o.Text:n.text=t}}),n.pos=r.pos,n}var o=Lexer.enumFromNames([\"Error\",\"DelimLTR\",\"DelimRTL\",\"InnerMeta\",\"ImageMeta\",\"LinkMeta\",\"Link\",\"RightMeta\",\"Setter\",\"Source\",\"Text\"]),s=Lexer.enumFromNames([\"None\",\"LTR\",\"RTL\"]);return i}()}}),t}();!function(){function e(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);t&&t.index===e.matchStart&&(e.nextMatch=this.lookahead.lastIndex,jQuery(document.createDocumentFragment()).append(t[1]).appendTo(e.output))}Wikifier.Parser.add({name:\"quoteByBlock\",profiles:[\"block\"],match:\"^<<<\\\\n\",terminator:\"^<<<\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));e.subWikify(jQuery(document.createElement(\"blockquote\")).appendTo(e.output).get(0),this.terminator)}}),Wikifier.Parser.add({name:\"quoteByLine\",profiles:[\"block\"],match:\"^>+\",lookahead:/^>+/gm,terminator:\"\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));var t=[e.output],r=0,n=e.matchLength,a=void 0,i=void 0;do{if(n>r)for(i=r;i<n;++i)t.push(jQuery(document.createElement(\"blockquote\")).appendTo(t[t.length-1]).get(0));else if(n<r)for(i=r;i>n;--i)t.pop();r=n,e.subWikify(t[t.length-1],this.terminator),jQuery(document.createElement(\"br\")).appendTo(t[t.length-1]),this.lookahead.lastIndex=e.nextMatch;var o=this.lookahead.exec(e.source);a=o&&o.index===e.nextMatch,a&&(n=o[0].length,e.nextMatch+=o[0].length)}while(a)}}),Wikifier.Parser.add({name:\"macro\",profiles:[\"core\"],match:\"<<\",lookahead:new RegExp(\"<<(/?\"+Patterns.macroName+\")(?:\\\\s*)((?:(?:`(?:\\\\\\\\.|[^`\\\\\\\\])*`)|(?:\\\"(?:\\\\\\\\.|[^\\\"\\\\\\\\])*\\\")|(?:'(?:\\\\\\\\.|[^'\\\\\\\\])*')|(?:\\\\[(?:[<>]?[Ii][Mm][Gg])?\\\\[[^\\\\r\\\\n]*?\\\\]\\\\]+)|[^>]|(?:>(?!>)))*)>>\",\"gm\"),working:{source:\"\",name:\"\",arguments:\"\",index:0},context:null,handler:function(e){var t=this.lookahead.lastIndex=e.matchStart;if(this.parseTag(e)){var r=e.nextMatch,n=this.working.name,a=this.working.arguments,i=void 0;try{if(!(i=Macro.get(n))){if(Macro.tags.has(n)){var o=Macro.tags.get(n);return throwError(e.output,\"child tag <<\"+n+\">> was found outside of a call to its parent macro\"+(1===o.length?\"\":\"s\")+\" <<\"+o.join(\">>, <<\")+\">>\",e.source.slice(t,e.nextMatch))}return throwError(e.output,\"macro <<\"+n+\">> does not exist\",e.source.slice(t,e.nextMatch))}var s=null;if(i.hasOwnProperty(\"tags\")&&!(s=this.parseBody(e,i)))return e.nextMatch=r,throwError(e.output,\"cannot find a closing tag for macro <<\"+n+\">>\",e.source.slice(t,e.nextMatch)+\"…\");if(\"function\"!=typeof i.handler)return throwError(e.output,\"macro <<\"+n+\">> handler function \"+(i.hasOwnProperty(\"handler\")?\"is not a function\":\"does not exist\"),e.source.slice(t,e.nextMatch));var u=s?s[0].args:this.createArgs(a,this.skipArgs(i,i.name));if(i.hasOwnProperty(\"_MACRO_API\")){this.context=new MacroContext({macro:i,name:n,args:u,payload:s,source:e.source.slice(t,e.nextMatch),parent:this.context,parser:e});try{i.handler.call(this.context)}finally{this.context=this.context.parent}}else{var l=e._rawArgs;e._rawArgs=a;try{i.handler(e.output,n,u,e,s)}finally{e._rawArgs=l}}}catch(r){return throwError(e.output,\"cannot execute \"+(i&&i.isWidget?\"widget\":\"macro\")+\" <<\"+n+\">>: \"+r.message,e.source.slice(t,e.nextMatch))}finally{this.working.source=\"\",this.working.name=\"\",this.working.arguments=\"\",this.working.index=0}}else e.outputText(e.output,e.matchStart,e.nextMatch)},parseTag:function(e){var t=this.lookahead.exec(e.source);return!(!t||t.index!==e.matchStart||!t[1])&&(e.nextMatch=this.lookahead.lastIndex,this.working.source=e.source.slice(t.index,this.lookahead.lastIndex),this.working.name=t[1],this.working.arguments=t[2],this.working.index=t.index,!0)},parseBody:function(e,t){for(var r=this.working.name,n=\"/\"+r,a=\"end\"+r,i=!!Array.isArray(t.tags)&&t.tags,o=[],s=-1,u=1,l=this.working.source,c=this.working.name,d=this.working.arguments,f=e.nextMatch;-1!==(e.matchStart=e.source.indexOf(this.match,e.nextMatch));)if(this.parseTag(e)){var h=this.working.source,p=this.working.name,g=this.working.arguments,m=this.working.index,v=e.nextMatch;switch(p){case r:++u;break;case a:case n:--u;break;default:if(1===u&&i)for(var y=0,b=i.length;y<b;++y)p===i[y]&&(o.push({source:l,name:c,arguments:d,args:this.createArgs(d,this.skipArgs(t,c)),contents:e.source.slice(f,m)}),l=h,c=p,d=g,f=v)}if(0===u){o.push({source:l,name:c,arguments:d,args:this.createArgs(d,this.skipArgs(t,c)),contents:e.source.slice(f,m)}),s=v;break}}else this.lookahead.lastIndex=e.nextMatch=e.matchStart+this.match.length;return-1!==s?(e.nextMatch=s,o):null},createArgs:function(e,t){var r=t?[]:this.parseArgs(e);return Object.defineProperties(r,{raw:{value:e},full:{value:Scripting.parse(e)}}),r},skipArgs:function(e,t){if(e.hasOwnProperty(\"skipArgs\")){var r=e.skipArgs;return\"boolean\"==typeof r&&r||Array.isArray(r)&&r.includes(t)}return!!e.hasOwnProperty(\"skipArg0\")&&(e.skipArg0&&e.name===t)},parseArgs:function(){function e(e,t){e:for(;;)switch(e.next()){case\"\\\\\":var r=e.next();if(r!==EOF&&\"\\n\"!==r)break;case EOF:case\"\\n\":return EOF;case t:break e}return e.pos}function t(e){var t=e.source.slice(e.pos).search(c);if(t===EOF)return null;switch(0!==t&&(e.pos+=t,e.ignore()),e.next()){case\"`\":return r;case'\"':return n;case\"'\":return a;case\"[\":return i;default:return o}}function r(r){return e(r,\"`\")===EOF?r.error(u.Error,\"unterminated backquote expression\"):(r.emit(u.Expression),t)}function n(r){return e(r,'\"')===EOF?r.error(u.Error,\"unterminated double quoted string\"):(r.emit(u.String),t)}function a(r){return e(r,\"'\")===EOF?r.error(u.Error,\"unterminated single quoted string\"):(r.emit(u.String),t)}function i(e){var r=void 0;if(e.accept(\"<>IiMmGg\")?(r=\"image\",e.acceptRun(\"<>IiMmGg\")):r=\"link\",!e.accept(\"[\"))return e.error(u.Error,\"malformed \"+r+\" markup\");e.depth=2;e:for(;;)switch(e.next()){case\"\\\\\":var n=e.next();if(n!==EOF&&\"\\n\"!==n)break;case EOF:case\"\\n\":return e.error(u.Error,\"unterminated \"+r+\" markup\");case\"[\":++e.depth;break;case\"]\":if(--e.depth<0)return e.error(u.Error,\"unexpected right square bracket ']'\");if(1===e.depth){if(\"]\"===e.next()){--e.depth;break e}e.backup()}}return e.emit(u.SquareBracket),t}function o(e){var r=e.source.slice(e.pos).search(l);return e.pos=r===EOF?e.source.length:e.pos+r,e.emit(u.Bareword),r===EOF?null:t}function s(e){var r=new Lexer(e,t),n=[];return r.run().forEach(function(e){var t=e.text;switch(e.type){case u.Error:throw new Error('unable to parse macro argument \"'+t+'\": '+e.message);case u.Bareword:if(d.test(t))t=State.getVar(t);else if(/^(?:settings|setup)[.[]/.test(t))try{t=Scripting.evalTwineScript(t)}catch(e){throw new Error('unable to parse macro argument \"'+t+'\": '+e.message)}else if(\"null\"===t)t=null;else if(\"undefined\"===t)t=undefined;else if(\"true\"===t)t=!0;else if(\"false\"===t)t=!1;else{var r=Number(t);Number.isNaN(r)||(t=r)}break;case u.Expression:if(\"\"===(t=t.slice(1,-1).trim()))t=undefined;else try{t=Scripting.evalTwineScript(\"(\"+t+\")\")}catch(e){throw new Error('unable to parse macro argument expression \"'+t+'\": '+e.message)}break;case u.String:try{t=Scripting.evalJavaScript(t)}catch(e){throw new Error('unable to parse macro argument string \"'+t+'\": '+e.message)}break;case u.SquareBracket:var a=Wikifier.helpers.parseSquareBracketedMarkup({source:t,matchStart:0});if(a.hasOwnProperty(\"error\"))throw new Error('unable to parse macro argument \"'+t+'\": '+a.error);if(a.pos<t.length)throw new Error('unable to parse macro argument \"'+t+'\": unexpected character(s) \"'+t.slice(a.pos)+'\" (pos: '+a.pos+\")\");a.isLink?(t={isLink:!0},t.count=a.hasOwnProperty(\"text\")?2:1,t.link=Wikifier.helpers.evalPassageId(a.link),t.text=a.hasOwnProperty(\"text\")?Wikifier.helpers.evalText(a.text):t.link,t.external=!a.forceInternal&&Wikifier.isExternalLink(t.link),t.setFn=a.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(a.setter)):null):a.isImage&&(t=function(e){var t={source:e,isImage:!0};if(\"data:\"!==e.slice(0,5)&&Story.has(e)){var r=Story.get(e);r.tags.includes(\"Twine.image\")&&(t.source=r.text,t.passage=r.title)}return t}(Wikifier.helpers.evalPassageId(a.source)),a.hasOwnProperty(\"align\")&&(t.align=a.align),a.hasOwnProperty(\"text\")&&(t.title=Wikifier.helpers.evalText(a.text)),a.hasOwnProperty(\"link\")&&(t.link=Wikifier.helpers.evalPassageId(a.link),t.external=!a.forceInternal&&Wikifier.isExternalLink(t.link)),t.setFn=a.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(a.setter)):null)}n.push(t)}),n}var u=Lexer.enumFromNames([\"Error\",\"Bareword\",\"Expression\",\"String\",\"SquareBracket\"]),l=new RegExp(Patterns.space),c=new RegExp(Patterns.notSpace),d=new RegExp(\"^\"+Patterns.variable);return s}()}),Wikifier.Parser.add({name:\"link\",profiles:[\"core\"],match:\"\\\\[\\\\[[^[]\",handler:function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup(e);if(t.hasOwnProperty(\"error\"))return void e.outputText(e.output,e.matchStart,e.nextMatch);e.nextMatch=t.pos;var r=Wikifier.helpers.evalPassageId(t.link),n=t.hasOwnProperty(\"text\")?Wikifier.helpers.evalText(t.text):r,a=t.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(t.setter)):null,i=(Config.debug?new DebugView(e.output,\"link-markup\",\"[[link]]\",e.source.slice(e.matchStart,e.nextMatch)):e).output;t.forceInternal||!Wikifier.isExternalLink(r)?Wikifier.createInternalLink(i,r,n,a):Wikifier.createExternalLink(i,r,n)}}),Wikifier.Parser.add({name:\"urlLink\",profiles:[\"core\"],match:Patterns.url,handler:function(e){e.outputText(Wikifier.createExternalLink(e.output,e.matchText),e.matchStart,e.nextMatch)}}),Wikifier.Parser.add({name:\"image\",profiles:[\"core\"],match:\"\\\\[[<>]?[Ii][Mm][Gg]\\\\[\",handler:function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup(e);if(t.hasOwnProperty(\"error\"))return void e.outputText(e.output,e.matchStart,e.nextMatch);e.nextMatch=t.pos;var r=void 0;Config.debug&&(r=new DebugView(e.output,\"image-markup\",t.hasOwnProperty(\"link\")?\"[img[][link]]\":\"[img[]]\",e.source.slice(e.matchStart,e.nextMatch)),r.modes({block:!0}));var n=t.hasOwnProperty(\"setter\")?Wikifier.helpers.createShadowSetterCallback(Scripting.parse(t.setter)):null,a=(Config.debug?r:e).output,i=void 0;if(t.hasOwnProperty(\"link\")){var o=Wikifier.helpers.evalPassageId(t.link);a=t.forceInternal||!Wikifier.isExternalLink(o)?Wikifier.createInternalLink(a,o,null,n):Wikifier.createExternalLink(a,o),a.classList.add(\"link-image\")}if(a=jQuery(document.createElement(\"img\")).appendTo(a).get(0),i=Wikifier.helpers.evalPassageId(t.source),\"data:\"!==i.slice(0,5)&&Story.has(i)){var s=Story.get(i);s.tags.includes(\"Twine.image\")&&(a.setAttribute(\"data-passage\",s.title),i=s.text.trim())}a.src=i,t.hasOwnProperty(\"text\")&&(a.title=Wikifier.helpers.evalText(t.text)),t.hasOwnProperty(\"align\")&&(a.align=t.align)}}),Wikifier.Parser.add({name:\"monospacedByBlock\",profiles:[\"block\"],match:\"^\\\\{\\\\{\\\\{\\\\n\",lookahead:/^\\{\\{\\{\\n((?:^[^\\n]*\\n)+?)(^\\}\\}\\}$\\n?)/gm,handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);if(t&&t.index===e.matchStart){var r=jQuery(document.createElement(\"pre\"));jQuery(document.createElement(\"code\")).text(t[1]).appendTo(r),r.appendTo(e.output),e.nextMatch=this.lookahead.lastIndex}}}),Wikifier.Parser.add({name:\"formatByChar\",profiles:[\"core\"],match:\"''|//|__|\\\\^\\\\^|~~|==|\\\\{\\\\{\\\\{\",handler:function(e){switch(e.matchText){case\"''\":e.subWikify(jQuery(document.createElement(\"strong\")).appendTo(e.output).get(0),\"''\");break;case\"//\":e.subWikify(jQuery(document.createElement(\"em\")).appendTo(e.output).get(0),\"//\");break;case\"__\":e.subWikify(jQuery(document.createElement(\"u\")).appendTo(e.output).get(0),\"__\");break;case\"^^\":e.subWikify(jQuery(document.createElement(\"sup\")).appendTo(e.output).get(0),\"\\\\^\\\\^\");break;case\"~~\":e.subWikify(jQuery(document.createElement(\"sub\")).appendTo(e.output).get(0),\"~~\");break;case\"==\":e.subWikify(jQuery(document.createElement(\"s\")).appendTo(e.output).get(0),\"==\");break;case\"{{{\":var t=/\\{\\{\\{((?:.|\\n)*?)\\}\\}\\}/gm;t.lastIndex=e.matchStart;var r=t.exec(e.source);r&&r.index===e.matchStart&&(jQuery(document.createElement(\"code\")).text(r[1]).appendTo(e.output),e.nextMatch=t.lastIndex)}}}),Wikifier.Parser.add({name:\"customStyle\",profiles:[\"core\"],match:\"@@\",terminator:\"@@\",blockRe:/\\s*\\n/gm,handler:function(e){var t=Wikifier.helpers.inlineCss(e);this.blockRe.lastIndex=e.nextMatch;var r=this.blockRe.exec(e.source),n=r&&r.index===e.nextMatch,a=jQuery(document.createElement(n?\"div\":\"span\")).appendTo(e.output);0===t.classes.length&&\"\"===t.id&&0===Object.keys(t.styles).length?a.addClass(\"marked\"):(t.classes.forEach(function(e){return a.addClass(e)}),\"\"!==t.id&&a.attr(\"id\",t.id),a.css(t.styles)),n?(e.nextMatch+=r[0].length,e.subWikify(a[0],\"\\\\n?\"+this.terminator)):e.subWikify(a[0],this.terminator)}}),Wikifier.Parser.add({name:\"verbatimText\",profiles:[\"core\"],match:'\"{3}|<[Nn][Oo][Ww][Ii][Kk][Ii]>',lookahead:/(?:\"{3}((?:.|\\n)*?)\"{3})|(?:<[Nn][Oo][Ww][Ii][Kk][Ii]>((?:.|\\n)*?)<\\/[Nn][Oo][Ww][Ii][Kk][Ii]>)/gm,handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);t&&t.index===e.matchStart&&(e.nextMatch=this.lookahead.lastIndex,jQuery(document.createElement(\"span\")).addClass(\"verbatim\").text(t[1]||t[2]).appendTo(e.output))}}),Wikifier.Parser.add({name:\"horizontalRule\",profiles:[\"core\"],match:\"^----+$\\\\n?|<[Hh][Rr]\\\\s*/?>\\\\n?\",handler:function(e){jQuery(document.createElement(\"hr\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"emdash\",profiles:[\"core\"],match:\"--\",handler:function(e){jQuery(document.createTextNode(\"—\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"doubleDollarSign\",profiles:[\"core\"],match:\"\\\\${2}\",handler:function(e){jQuery(document.createTextNode(\"$\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"nakedVariable\",profiles:[\"core\"],match:Patterns.variable+\"(?:(?:\\\\.\"+Patterns.identifier+\")|(?:\\\\[\\\\d+\\\\])|(?:\\\\[\\\"(?:\\\\\\\\.|[^\\\"\\\\\\\\])+\\\"\\\\])|(?:\\\\['(?:\\\\\\\\.|[^'\\\\\\\\])+'\\\\])|(?:\\\\[\"+Patterns.variable+\"\\\\]))*\",handler:function(e){var t=toStringOrDefault(State.getVar(e.matchText),null);null===t?jQuery(document.createTextNode(e.matchText)).appendTo(e.output):new Wikifier((Config.debug?new DebugView(e.output,\"variable\",e.matchText,e.matchText):e).output,t)}}),Wikifier.Parser.add({name:\"heading\",profiles:[\"block\"],match:\"^!{1,6}\",terminator:\"\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));e.subWikify(jQuery(document.createElement(\"h\"+e.matchLength)).appendTo(e.output).get(0),this.terminator)}}),Wikifier.Parser.add({name:\"table\",profiles:[\"block\"],match:\"^\\\\|(?:[^\\\\n]*)\\\\|(?:[fhck]?)$\",lookahead:/^\\|([^\\n]*)\\|([fhck]?)$/gm,rowTerminator:\"\\\\|(?:[cfhk]?)$\\\\n?\",cellPattern:\"(?:\\\\|([^\\\\n\\\\|]*)\\\\|)|(\\\\|[cfhk]?$\\\\n?)\",cellTerminator:\"(?:\\\\u0020*)\\\\|\",rowTypes:{c:\"caption\",f:\"tfoot\",h:\"thead\",\"\":\"tbody\"},handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));var t=jQuery(document.createElement(\"table\")).appendTo(e.output).get(0),r=[],n=null,a=null,i=0,o=void 0;e.nextMatch=e.matchStart;do{this.lookahead.lastIndex=e.nextMatch;var s=this.lookahead.exec(e.source);if(o=s&&s.index===e.nextMatch){var u=s[2];\"k\"===u?(t.className=s[1],e.nextMatch+=s[0].length+1):(u!==n&&(n=u,a=jQuery(document.createElement(this.rowTypes[u])).appendTo(t)),\"c\"===n?(a.css(\"caption-side\",0===i?\"top\":\"bottom\"),e.nextMatch+=1,e.subWikify(a[0],this.rowTerminator)):this.rowHandler(e,jQuery(document.createElement(\"tr\")).appendTo(a).get(0),r),++i)}}while(o)},rowHandler:function(e,t,r){var n=this,a=new RegExp(this.cellPattern,\"gm\"),i=0,o=1,s=void 0;do{a.lastIndex=e.nextMatch;var u=a.exec(e.source);if(s=u&&u.index===e.nextMatch){if(\"~\"===u[1]){var l=r[i];l&&(++l.rowCount,l.$element.attr(\"rowspan\",l.rowCount).css(\"vertical-align\",\"middle\")),e.nextMatch=u.index+u[0].length-1}else if(\">\"===u[1])++o,e.nextMatch=u.index+u[0].length-1;else{if(u[2]){e.nextMatch=u.index+u[0].length;break}!function(){++e.nextMatch;for(var a=Wikifier.helpers.inlineCss(e),s=!1,u=!1,l=void 0;\" \"===e.source.substr(e.nextMatch,1);)s=!0,++e.nextMatch;\"!\"===e.source.substr(e.nextMatch,1)?(l=jQuery(document.createElement(\"th\")).appendTo(t),++e.nextMatch):l=jQuery(document.createElement(\"td\")).appendTo(t),r[i]={rowCount:1,$element:l},o>1&&(l.attr(\"colspan\",o),o=1),e.subWikify(l[0],n.cellTerminator),\" \"===e.matchText.substr(e.matchText.length-2,1)&&(u=!0),a.classes.forEach(function(e){return l.addClass(e)}),\"\"!==a.id&&l.attr(\"id\",a.id),s&&u?a.styles[\"text-align\"]=\"center\":s?a.styles[\"text-align\"]=\"right\":u&&(a.styles[\"text-align\"]=\"left\"),l.css(a.styles),e.nextMatch=e.nextMatch-1}()}++i}}while(s)}}),Wikifier.Parser.add({name:\"list\",profiles:[\"block\"],match:\"^(?:(?:\\\\*+)|(?:#+))\",lookahead:/^(?:(\\*+)|(#+))/gm,terminator:\"\\\\n\",handler:function(e){if(!Wikifier.helpers.hasBlockContext(e.output.childNodes))return void jQuery(e.output).append(document.createTextNode(e.matchText));e.nextMatch=e.matchStart;var t=[e.output],r=null,n=0,a=void 0,i=void 0;do{this.lookahead.lastIndex=e.nextMatch;var o=this.lookahead.exec(e.source);if(a=o&&o.index===e.nextMatch){var s=o[2]?\"ol\":\"ul\",u=o[0].length;if(e.nextMatch+=o[0].length,u>n)for(i=n;i<u;++i)t.push(jQuery(document.createElement(s)).appendTo(t[t.length-1]).get(0));else if(u<n)for(i=n;i>u;--i)t.pop();else u===n&&s!==r&&(t.pop(),t.push(jQuery(document.createElement(s)).appendTo(t[t.length-1]).get(0)));n=u,r=s,e.subWikify(jQuery(document.createElement(\"li\")).appendTo(t[t.length-1]).get(0),this.terminator)}}while(a)}}),Wikifier.Parser.add({name:\"commentByBlock\",profiles:[\"core\"],match:\"(?:/(?:%|\\\\*))|(?:\\x3c!--)\",lookahead:/(?:\\/(%|\\*)(?:(?:.|\\n)*?)\\1\\/)|(?:<!--(?:(?:.|\\n)*?)-->)/gm,handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);t&&t.index===e.matchStart&&(e.nextMatch=this.lookahead.lastIndex)}}),Wikifier.Parser.add({name:\"lineContinuation\",profiles:[\"core\"],match:\"\\\\\\\\\"+Patterns.spaceNoTerminator+\"*(?:\\\\n|$)|(?:^|\\\\n)\"+Patterns.spaceNoTerminator+\"*\\\\\\\\\",handler:function(e){e.nextMatch=e.matchStart+e.matchLength}}),Wikifier.Parser.add({name:\"lineBreak\",profiles:[\"core\"],match:\"\\\\n|<[Bb][Rr]\\\\s*/?>\",handler:function(e){e.options.nobr||jQuery(document.createElement(\"br\")).appendTo(e.output)}}),Wikifier.Parser.add({name:\"htmlCharacterReference\",profiles:[\"core\"],match:\"(?:(?:&#?[0-9A-Za-z]{2,8};|.)(?:&#?(?:x0*(?:3[0-6][0-9A-Fa-f]|1D[C-Fc-f][0-9A-Fa-f]|20[D-Fd-f][0-9A-Fa-f]|FE2[0-9A-Fa-f])|0*(?:76[89]|7[7-9][0-9]|8[0-7][0-9]|761[6-9]|76[2-7][0-9]|84[0-3][0-9]|844[0-7]|6505[6-9]|6506[0-9]|6507[0-1]));)+|&#?[0-9A-Za-z]{2,8};)\",handler:function(e){jQuery(document.createDocumentFragment()).append(e.matchText).appendTo(e.output)}}),Wikifier.Parser.add({name:\"xmlProlog\",profiles:[\"core\"],match:\"<\\\\?[Xx][Mm][Ll][^>]*\\\\?>\",handler:function(e){e.nextMatch=e.matchStart+e.matchLength}}),Wikifier.Parser.add({name:\"verbatimHtml\",profiles:[\"core\"],match:\"<[Hh][Tt][Mm][Ll]>\",\nlookahead:/<[Hh][Tt][Mm][Ll]>((?:.|\\n)*?)<\\/[Hh][Tt][Mm][Ll]>/gm,handler:e}),Wikifier.Parser.add({name:\"verbatimSvgTag\",profiles:[\"core\"],match:\"<[Ss][Vv][Gg][^>]*>\",lookahead:/(<[Ss][Vv][Gg][^>]*>(?:.|\\n)*?<\\/[Ss][Vv][Gg]>)/gm,handler:e}),Wikifier.Parser.add({name:\"verbatimScriptTag\",profiles:[\"core\"],match:\"<[Ss][Cc][Rr][Ii][Pp][Tt][^>]*>\",lookahead:/(<[Ss][Cc][Rr][Ii][Pp][Tt]*>(?:.|\\n)*?<\\/[Ss][Cc][Rr][Ii][Pp][Tt]>)/gm,handler:e}),Wikifier.Parser.add({name:\"styleTag\",profiles:[\"core\"],match:\"<[Ss][Tt][Yy][Ll][Ee][^>]*>\",lookahead:/(<[Ss][Tt][Yy][Ll][Ee]*>)((?:.|\\n)*?)(<\\/[Ss][Tt][Yy][Ll][Ee]>)/gm,imageMarkup:new RegExp(Patterns.cssImage,\"g\"),hasImageMarkup:new RegExp(Patterns.cssImage),handler:function(e){this.lookahead.lastIndex=e.matchStart;var t=this.lookahead.exec(e.source);if(t&&t.index===e.matchStart){e.nextMatch=this.lookahead.lastIndex;var r=t[2];this.hasImageMarkup.test(r)&&(this.imageMarkup.lastIndex=0,r=r.replace(this.imageMarkup,function(e){var t=Wikifier.helpers.parseSquareBracketedMarkup({source:e,matchStart:0});if(t.hasOwnProperty(\"error\")||t.pos<e.length)return e;var r=t.source;if(\"data:\"!==r.slice(0,5)&&Story.has(r)){var n=Story.get(r);n.tags.includes(\"Twine.image\")&&(r=n.text)}return'url(\"'+r.replace(/\"/g,\"%22\")+'\")'})),jQuery(document.createDocumentFragment()).append(t[1]+r+t[3]).appendTo(e.output)}}}),Wikifier.Parser.add({name:\"htmlTag\",profiles:[\"core\"],match:\"<\\\\w+(?:\\\\s+[^\\\\u0000-\\\\u001F\\\\u007F-\\\\u009F\\\\s\\\"'>\\\\/=]+(?:\\\\s*=\\\\s*(?:\\\"[^\\\"]*?\\\"|'[^']*?'|[^\\\\s\\\"'=<>`]+))?)*\\\\s*\\\\/?>\",tagRe:/^<(\\w+)/,mediaElements:[\"audio\",\"img\",\"source\",\"track\",\"video\"],nobrElements:[\"audio\",\"colgroup\",\"datalist\",\"dl\",\"figure\",\"ol\",\"optgroup\",\"picture\",\"select\",\"table\",\"tbody\",\"tfoot\",\"thead\",\"tr\",\"ul\",\"video\"],voidElements:[\"area\",\"base\",\"br\",\"col\",\"embed\",\"hr\",\"img\",\"input\",\"keygen\",\"link\",\"menuitem\",\"meta\",\"param\",\"source\",\"track\",\"wbr\"],handler:function(e){var t=this.tagRe.exec(e.matchText),r=t&&t[1],n=r&&r.toLowerCase();if(n){var a=this.voidElements.includes(n)||e.matchText.endsWith(\"/>\"),i=this.nobrElements.includes(n),o=void 0,s=void 0;if(!a){o=\"<\\\\/\"+n+\"\\\\s*>\";var u=new RegExp(o,\"gim\");u.lastIndex=e.matchStart,s=u.exec(e.source)}if(!a&&!s)return throwError(e.output,\"cannot find a closing tag for HTML <\"+r+\">\",e.matchText+\"…\");var l=e.output,c=document.createElement(e.output.tagName),d=void 0;for(c.innerHTML=e.matchText;c.firstChild;)c=c.firstChild;try{this.processAttributeDirectives(c)}catch(t){return throwError(e.output,\"<\"+n+\">: \"+t.message,e.matchText+\"…\")}c.hasAttribute(\"data-passage\")&&(this.processDataAttributes(c,n),Config.debug&&(d=new DebugView(e.output,\"html-\"+n,n,e.matchText),d.modes({block:\"img\"===n,nonvoid:s}),l=d.output)),s&&(e.subWikify(c,o,{ignoreTerminatorCase:!0,nobr:i}),d&&jQuery(c).find(\".debug.block\").length>0&&d.modes({block:!0})),l.appendChild(\"track\"===n?c.cloneNode(!0):c)}},processAttributeDirectives:function(e){[].concat(_toConsumableArray(e.attributes)).forEach(function(t){var r=t.name,n=t.value,a=\"@\"===r[0];if(a||r.startsWith(\"sc-eval:\")){var i=r.slice(a?1:8),o=void 0;try{o=Scripting.evalTwineScript(n)}catch(e){throw new Error('bad evaluation from attribute directive \"'+r+'\": '+e.message)}try{e.setAttribute(i,o),e.removeAttribute(r)}catch(e){throw new Error('cannot transform attribute directive \"'+r+'\" into attribute \"'+i+'\"')}}})},processDataAttributes:function(e,t){var r=e.getAttribute(\"data-passage\");if(null!=r){var n=Wikifier.helpers.evalPassageId(r);if(n!==r&&(r=n,e.setAttribute(\"data-passage\",n)),\"\"!==r)if(this.mediaElements.includes(t)){if(\"data:\"!==r.slice(0,5)&&Story.has(r)){r=Story.get(r);var a=void 0,i=void 0;switch(t){case\"audio\":case\"video\":i=\"Twine.\"+t;break;case\"img\":i=\"Twine.image\";break;case\"track\":i=\"Twine.vtt\";break;case\"source\":var o=$(e).closest(\"audio,picture,video\");o.length&&(a=o.get(0).tagName.toLowerCase(),i=\"Twine.\"+(\"picture\"===a?\"image\":a))}r.tags.includes(i)&&(e[\"picture\"===a?\"srcset\":\"src\"]=r.text.trim())}}else{var s=e.getAttribute(\"data-setter\"),u=void 0;null!=s&&\"\"!==(s=String(s).trim())&&(u=Wikifier.helpers.createShadowSetterCallback(Scripting.parse(s))),Story.has(r)?(e.classList.add(\"link-internal\"),Config.addVisitedLinkClass&&State.hasPlayed(r)&&e.classList.add(\"link-visited\")):e.classList.add(\"link-broken\"),jQuery(e).ariaClick({one:!0},function(){\"function\"==typeof u&&u.call(this),Engine.play(r)})}}}})}();var Macro=function(){function e(t,r,a){if(Array.isArray(t))return void t.forEach(function(t){return e(t,r,a)});if(!f.test(t))throw new Error('invalid macro name \"'+t+'\"');if(n(t))throw new Error(\"cannot clobber existing macro <<\"+t+\">>\");if(u(t))throw new Error(\"cannot clobber child tag <<\"+t+\">> of parent macro\"+(1===d[t].length?\"\":\"s\")+\" <<\"+d[t].join(\">>, <<\")+\">>\");try{if(\"object\"===(void 0===r?\"undefined\":_typeof(r)))c[t]=a?clone(r):r;else{if(!n(r))throw new Error(\"cannot create alias of nonexistent macro <<\"+r+\">>\");c[t]=a?clone(c[r]):c[r]}Object.defineProperty(c,t,{writable:!1}),c[t]._MACRO_API=!0}catch(e){throw\"TypeError\"===e.name?new Error(\"cannot clobber protected macro <<\"+t+\">>\"):new Error(\"unknown error when attempting to add macro <<\"+t+\">>: [\"+e.name+\"] \"+e.message)}if(c[t].hasOwnProperty(\"tags\"))if(null==c[t].tags)o(t);else{if(!Array.isArray(c[t].tags))throw new Error('bad value for \"tags\" property of macro <<'+t+\">>\");o(t,c[t].tags)}}function t(e){if(Array.isArray(e))return void e.forEach(function(e){return t(e)});if(n(e)){c[e].hasOwnProperty(\"tags\")&&s(e);try{Object.defineProperty(c,e,{writable:!0}),delete c[e]}catch(t){throw new Error(\"unknown error removing macro <<\"+e+\">>: \"+t.message)}}else if(u(e))throw new Error(\"cannot remove child tag <<\"+e+\">> of parent macro <<\"+d[e]+\">>\")}function r(){return 0===Object.keys(c).length}function n(e){return c.hasOwnProperty(e)}function a(e){var t=null;return n(e)&&\"function\"==typeof c[e].handler?t=c[e]:macros.hasOwnProperty(e)&&\"function\"==typeof macros[e].handler&&(t=macros[e]),t}function i(){var e=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"init\";Object.keys(c).forEach(function(t){\"function\"==typeof c[t][e]&&c[t][e](t)}),Object.keys(macros).forEach(function(t){\"function\"==typeof macros[t][e]&&macros[t][e](t)})}function o(e,t){if(!e)throw new Error(\"no parent specified\");for(var r=[\"/\"+e,\"end\"+e],a=[].concat(r,Array.isArray(t)?t:[]),i=0;i<a.length;++i){var o=a[i];if(n(o))throw new Error(\"cannot register tag for an existing macro\");u(o)?d[o].includes(e)||(d[o].push(e),d[o].sort()):d[o]=[e]}}function s(e){if(!e)throw new Error(\"no parent specified\");Object.keys(d).forEach(function(t){var r=d[t].indexOf(e);-1!==r&&(1===d[t].length?delete d[t]:d[t].splice(r,1))})}function u(e){return d.hasOwnProperty(e)}function l(e){return u(e)?d[e]:null}var c={},d={},f=new RegExp(\"^(?:\"+Patterns.macroName+\")$\");return Object.freeze(Object.defineProperties({},{add:{value:e},delete:{value:t},isEmpty:{value:r},has:{value:n},get:{value:a},init:{value:i},tags:{value:Object.freeze(Object.defineProperties({},{register:{value:o},unregister:{value:s},has:{value:u},get:{value:l}}))},evalStatements:{value:function(){return Scripting.evalJavaScript.apply(Scripting,arguments)}}}))}(),MacroContext=function(){return function(){function e(t){_classCallCheck(this,e);var r=Object.assign({parent:null,macro:null,name:\"\",args:null,payload:null,parser:null,source:\"\"},t);if(null===r.macro||\"\"===r.name||null===r.parser)throw new TypeError(\"context object missing required properties\");Object.defineProperties(this,{self:{value:r.macro},name:{value:r.name},args:{value:r.args},payload:{value:r.payload},source:{value:r.source},parent:{value:r.parent},parser:{value:r.parser},_output:{value:r.parser.output},_shadows:{writable:!0,value:null},_debugView:{writable:!0,value:null},_debugViewEnabled:{writable:!0,value:Config.debug}})}return _createClass(e,[{key:\"contextHas\",value:function(e){for(var t=this;null!==(t=t.parent);)if(e(t))return!0;return!1}},{key:\"contextSelect\",value:function(e){for(var t=this;null!==(t=t.parent);)if(e(t))return t;return null}},{key:\"contextSelectAll\",value:function(e){for(var t=[],r=this;null!==(r=r.parent);)e(r)&&t.push(r);return t}},{key:\"addShadow\",value:function(){var e=this;this._shadows||(this._shadows=new Set);for(var t=new RegExp(\"^\"+Patterns.variable+\"$\"),r=arguments.length,n=Array(r),a=0;a<r;a++)n[a]=arguments[a];n.flatten().forEach(function(r){if(\"string\"!=typeof r)throw new TypeError(\"variable name must be a string; type: \"+(void 0===r?\"undefined\":_typeof(r)));if(!t.test(r))throw new Error('invalid variable name \"'+r+'\"');e._shadows.add(r)})}},{key:\"createShadowWrapper\",value:function(e,t,r){var n=this,a=void 0;return\"function\"==typeof e&&(a={},this.shadowView.forEach(function(e){var t=e.slice(1),r=\"$\"===e[0]?State.variables:State.temporary;a[e]=r[t]})),function(){for(var i=arguments.length,o=Array(i),s=0;s<i;s++)o[s]=arguments[s];if(\"function\"==typeof r&&r.apply(this,o),\"function\"==typeof e){var u=Object.keys(a),l=u.length>0?{}:null,c=Wikifier.Parser.get(\"macro\"),d=void 0;try{u.forEach(function(e){var t=e.slice(1),r=\"$\"===e[0]?State.variables:State.temporary;r.hasOwnProperty(t)&&(l[t]=r[t]),r[t]=a[e]}),d=c.context,c.context=n,e.apply(this,o)}finally{d!==undefined&&(c.context=d),u.forEach(function(e){var t=e.slice(1),r=\"$\"===e[0]?State.variables:State.temporary;a[e]=r[t],l.hasOwnProperty(t)?r[t]=l[t]:delete r[t]})}}\"function\"==typeof t&&t.apply(this,o)}}},{key:\"createDebugView\",value:function(e,t){return this._debugView=new DebugView(this._output,\"macro\",e||this.name,t||this.source),null!==this.payload&&this.payload.length>0&&this._debugView.modes({nonvoid:!0}),this._debugViewEnabled=!0,this._debugView}},{key:\"removeDebugView\",value:function(){null!==this._debugView&&(this._debugView.remove(),this._debugView=null),this._debugViewEnabled=!1}},{key:\"error\",value:function(e,t){return throwError(this._output,\"<<\"+this.name+\">>: \"+e,t||this.source)}},{key:\"output\",get:function(){return this._debugViewEnabled?this.debugView.output:this._output}},{key:\"shadows\",get:function(){return[].concat(_toConsumableArray(this._shadows))}},{key:\"shadowView\",get:function(){var e=new Set;return this.contextSelectAll(function(e){return e._shadows}).forEach(function(t){return t._shadows.forEach(function(t){return e.add(t)})}),[].concat(_toConsumableArray(e))}},{key:\"debugView\",get:function(){return this._debugViewEnabled?null!==this._debugView?this._debugView:this.createDebugView():null}}]),e}()}();!function(){if(Macro.add(\"capture\",{skipArgs:!0,tags:null,handler:function(){if(0===this.args.raw.length)return this.error(\"no story/temporary variable list specified\");var e={};try{for(var t=new RegExp(\"(\"+Patterns.variable+\")\",\"g\"),r=void 0;null!==(r=t.exec(this.args.raw));){var n=r[1],a=n.slice(1),i=\"$\"===n[0]?State.variables:State.temporary;i.hasOwnProperty(a)&&(e[a]=i[a]),this.addShadow(n)}new Wikifier(this.output,this.payload[0].contents)}finally{this.shadows.forEach(function(t){var r=t.slice(1),n=\"$\"===t[0]?State.variables:State.temporary;e.hasOwnProperty(r)?n[r]=e[r]:delete n[r]})}}}),Macro.add(\"set\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");try{Scripting.evalJavaScript(this.args.full)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"unset\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no story/temporary variable list specified\");for(var e=new RegExp(\"State\\\\.(variables|temporary)\\\\.(\"+Patterns.identifier+\")\",\"g\"),t=void 0;null!==(t=e.exec(this.args.full));){var r=State[t[1]],n=t[2];r.hasOwnProperty(n)&&delete r[n]}Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"remember\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");try{Scripting.evalJavaScript(this.args.full)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}for(var e=storage.get(\"remember\")||{},t=new RegExp(\"State\\\\.variables\\\\.(\"+Patterns.identifier+\")\",\"g\"),r=void 0;null!==(r=t.exec(this.args.full));){var n=r[1];e[n]=State.variables[n]}if(!storage.set(\"remember\",e))return this.error(\"unknown error, cannot remember: \"+this.args.raw);Config.debug&&this.debugView.modes({hidden:!0})},init:function(){var e=storage.get(\"remember\");e&&Object.keys(e).forEach(function(t){return State.variables[t]=e[t]})}}),Macro.add(\"forget\",{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no story variable list specified\");for(var e=storage.get(\"remember\"),t=new RegExp(\"State\\\\.variables\\\\.(\"+Patterns.identifier+\")\",\"g\"),r=void 0,n=!1;null!==(r=t.exec(this.args.full));){var a=r[1];State.variables.hasOwnProperty(a)&&delete State.variables[a],e&&e.hasOwnProperty(a)&&(n=!0,delete e[a])}if(n&&!storage.set(\"remember\",e))return this.error(\"unknown error, cannot update remember store\");Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"run\",\"set\"),Macro.add(\"script\",{skipArgs:!0,tags:null,handler:function(){var e=document.createDocumentFragment();try{Scripting.evalJavaScript(this.payload[0].contents,e),Config.debug&&this.createDebugView(this.name,this.source+this.payload[0].contents+\"<</\"+this.name+\">>\")}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e),this.source+this.payload[0].contents+\"<</\"+this.name+\">>\")}e.hasChildNodes()&&this.output.appendChild(e)}}),Macro.add(\"include\",{handler:function(){if(0===this.args.length)return this.error(\"no passage specified\");var e=void 0;if(e=\"object\"===_typeof(this.args[0])?this.args[0].link:this.args[0],!Story.has(e))return this.error('passage \"'+e+'\" does not exist');Config.debug&&this.debugView.modes({block:!0}),e=Story.get(e);var t=void 0;t=this.args[1]?jQuery(document.createElement(this.args[1])).addClass(e.domId+\" macro-\"+this.name).attr(\"data-passage\",e.title).appendTo(this.output):jQuery(this.output),t.wiki(e.processText())}}),Macro.add(\"nobr\",{skipArgs:!0,tags:null,handler:function(){new Wikifier(this.output,this.payload[0].contents.replace(/^\\n+|\\n+$/g,\"\").replace(/\\n+/g,\" \"))}}),Macro.add([\"print\",\"=\",\"-\"],{skipArgs:!0,handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");try{var e=toStringOrDefault(Scripting.evalJavaScript(this.args.full),null);null!==e&&new Wikifier(this.output,\"-\"===this.name?Util.escape(e):e)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}}}),Macro.add(\"silently\",{skipArgs:!0,tags:null,handler:function(){var e=document.createDocumentFragment();if(new Wikifier(e,this.payload[0].contents.trim()),Config.debug)this.debugView.modes({hidden:!0}),this.output.appendChild(e);else{var t=[].concat(_toConsumableArray(e.querySelectorAll(\".error\"))).map(function(e){return e.textContent});if(t.length>0)return this.error(\"error\"+(1===t.length?\"\":\"s\")+\" within contents (\"+t.join(\"; \")+\")\",this.source+this.payload[0].contents+\"<</\"+this.name+\">>\")}}}),Macro.add(\"display\",\"include\"),Macro.add(\"if\",{skipArgs:!0,tags:[\"elseif\",\"else\"],handler:function(){var e=void 0;try{var t=this.payload.length;for(e=0;e<t;++e)switch(this.payload[e].name){case\"else\":if(this.payload[e].args.raw.length>0)return/^\\s*if\\b/i.test(this.payload[e].args.raw)?this.error('whitespace is not allowed between the \"else\" and \"if\" in <<elseif>> clause'+(e>0?\" (#\"+e+\")\":\"\")):this.error(\"<<else>> does not accept a conditional expression (perhaps you meant to use <<elseif>>), invalid: \"+this.payload[e].args.raw);if(e+1!==t)return this.error(\"<<else>> must be the final clause\");break;default:if(0===this.payload[e].args.full.length)return this.error(\"no conditional expression specified for <<\"+this.payload[e].name+\">> clause\"+(e>0?\" (#\"+e+\")\":\"\"));if(Config.macros.ifAssignmentError&&/[^!=&^|<>*\\/%+-]=[^=]/.test(this.payload[e].args.full))return this.error(\"assignment operator found within <<\"+this.payload[e].name+\">> clause\"+(e>0?\" (#\"+e+\")\":\"\")+\" (perhaps you meant to use an equality operator: ==, ===, eq, is), invalid: \"+this.payload[e].args.raw)}var r=Scripting.evalJavaScript,n=!1;for(e=0;e<t;++e){if(Config.debug&&this.createDebugView(this.payload[e].name,this.payload[e].source).modes({nonvoid:!1}),\"else\"===this.payload[e].name||r(this.payload[e].args.full)){n=!0,new Wikifier(this.output,this.payload[e].contents);break}Config.debug&&this.debugView.modes({hidden:!0,invalid:!0})}if(Config.debug){for(++e;e<t;++e)this.createDebugView(this.payload[e].name,this.payload[e].source).modes({nonvoid:!1,hidden:!0,invalid:!0});this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!n,invalid:!n})}}catch(t){return this.error(\"bad conditional expression in <<\"+(0===e?\"if\":\"elseif\")+\">> clause\"+(e>0?\" (#\"+e+\")\":\"\")+\": \"+(\"object\"===(void 0===t?\"undefined\":_typeof(t))?t.message:t))}}}),Macro.add(\"switch\",{skipArgs:[\"switch\"],tags:[\"case\",\"default\"],handler:function(){if(0===this.args.full.length)return this.error(\"no expression specified\");var e=this.payload.length;if(1===e)return this.error(\"no cases specified\");var t=void 0;for(t=1;t<e;++t)switch(this.payload[t].name){case\"default\":if(this.payload[t].args.length>0)return this.error(\"<<default>> does not accept values, invalid: \"+this.payload[t].args.raw);if(t+1!==e)return this.error(\"<<default>> must be the final case\");break;default:if(0===this.payload[t].args.length)return this.error(\"no value(s) specified for <<\"+this.payload[t].name+\">> (#\"+t+\")\")}var r=void 0;try{r=Scripting.evalJavaScript(this.args.full)}catch(e){return this.error(\"bad evaluation: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}var n=this.debugView,a=!1;for(Config.debug&&n.modes({nonvoid:!1,hidden:!0}),t=1;t<e;++t){if(Config.debug&&this.createDebugView(this.payload[t].name,this.payload[t].source).modes({nonvoid:!1}),\"default\"===this.payload[t].name||this.payload[t].args.some(function(e){return e===r})){a=!0,new Wikifier(this.output,this.payload[t].contents);break}Config.debug&&this.debugView.modes({hidden:!0,invalid:!0})}if(Config.debug){for(++t;t<e;++t)this.createDebugView(this.payload[t].name,this.payload[t].source).modes({nonvoid:!1,hidden:!0,invalid:!0});n.modes({nonvoid:!1,hidden:!0,invalid:!a}),this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!0,invalid:!a})}}}),Macro.add(\"for\",{skipArgs:!0,tags:null,_hasRangeRe:new RegExp(\"^\\\\S.*?\\\\s+range\\\\s+\\\\S.*?$\"),_rangeRe:new RegExp(\"^(?:State\\\\.(variables|temporary)\\\\.(\"+Patterns.identifier+\")\\\\s*,\\\\s*)?State\\\\.(variables|temporary)\\\\.(\"+Patterns.identifier+\")\\\\s+range\\\\s+(\\\\S.*?)$\"),_3PartRe:/^([^;]*?)\\s*;\\s*([^;]*?)\\s*;\\s*([^;]*?)$/,handler:function(){var e=this.args.full.trim(),t=this.payload[0].contents.replace(/\\n$/,\"\");if(0===e.length)this.self._handleFor.call(this,t,null,!0,null);else if(this.self._hasRangeRe.test(e)){var r=e.match(this.self._rangeRe);if(null===r)return this.error(\"invalid range form syntax, format: [index ,] value range collection\");this.self._handleForRange.call(this,t,{type:r[1],name:r[2]},{type:r[3],name:r[4]},r[5])}else{var n=void 0,a=void 0,i=void 0;if(-1===e.indexOf(\";\")){if(/^\\S+\\s+in\\s+\\S+/i.test(e))return this.error(\"invalid syntax, for…in is not supported; see: for…range\");if(/^\\S+\\s+of\\s+\\S+/i.test(e))return this.error(\"invalid syntax, for…of is not supported; see: for…range\");a=e}else{var o=e.match(this.self._3PartRe);if(null===o)return this.error(\"invalid 3-part conditional form syntax, format: [init] ; [condition] ; [post]\");n=o[1],a=o[2].trim(),i=o[3],0===a.length&&(a=!0)}this.self._handleFor.call(this,t,n,a,i)}},_handleFor:function(e,t,r,n){var a=Scripting.evalJavaScript,i=!0,o=Config.macros.maxLoopIterations;Config.debug&&this.debugView.modes({block:!0});try{if(TempState.break=null,t)try{a(t)}catch(e){return this.error(\"bad init expression: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}for(;a(r);){if(--o<0)return this.error(\"exceeded configured maximum loop iterations (\"+Config.macros.maxLoopIterations+\")\");if(new Wikifier(this.output,i?e.replace(/^\\n/,\"\"):e),i&&(i=!1),null!=TempState.break)if(1===TempState.break)TempState.break=null;else if(2===TempState.break){TempState.break=null;break}if(n)try{a(n)}catch(e){return this.error(\"bad post expression: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}}}catch(e){return this.error(\"bad conditional expression: \"+(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e))}finally{TempState.break=null}},_handleForRange:function(e,t,r,n){var a=!0,i=void 0;try{i=this.self._toRangeList(n)}catch(e){return this.error(e.message)}Config.debug&&this.debugView.modes({block:!0});try{TempState.break=null;for(var o=0;o<i.length;++o)if(t.name&&(State[t.type][t.name]=i[o][0]),State[r.type][r.name]=i[o][1],new Wikifier(this.output,a?e.replace(/^\\n/,\"\"):e),a&&(a=!1),null!=TempState.break)if(1===TempState.break)TempState.break=null;else if(2===TempState.break){TempState.break=null;break}}catch(e){return this.error(\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e)}finally{TempState.break=null}},_toRangeList:function(e){var t=Scripting.evalJavaScript,r=void 0;try{r=t(\"{\"===e[0]?\"(\"+e+\")\":e)}catch(e){if(\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"bad range expression: \"+e);throw e.message=\"bad range expression: \"+e.message,e}var n=void 0;switch(void 0===r?\"undefined\":_typeof(r)){case\"string\":n=[];for(var a=0;a<r.length;){var i=Util.charAndPosAt(r,a);n.push([a,i.char]),a=1+i.end}break;case\"object\":if(Array.isArray(r))n=r.map(function(e,t){return[t,e]});else if(r instanceof Set)n=[].concat(_toConsumableArray(r)).map(function(e,t){return[t,e]});else if(r instanceof Map)n=[].concat(_toConsumableArray(r.entries()));else{if(\"Object\"!==Util.toStringTag(r))throw new Error(\"unsupported range expression type: \"+Util.toStringTag(r));n=Object.keys(r).map(function(e){return[e,r[e]]})}break;default:throw new Error(\"unsupported range expression type: \"+(void 0===r?\"undefined\":_typeof(r)))}return n}}),Macro.add([\"break\",\"continue\"],{skipArgs:!0,handler:function(){if(!this.contextHas(function(e){return\"for\"===e.name}))return this.error(\"must only be used in conjunction with its parent macro <<for>>\");TempState.break=\"continue\"===this.name?1:2,Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add([\"button\",\"link\"],{isAsync:!0,tags:null,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no \"+(\"button\"===this.name?\"button\":\"link\")+\" text specified\");Config.debug&&this.createDebugView(this.name,this.source+this.payload[0].contents+\"<</\"+this.name+\">>\");var t=jQuery(document.createElement(\"button\"===this.name?\"button\":\"a\")),r=void 0;if(\"object\"===_typeof(this.args[0]))if(this.args[0].isImage){var n=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[0].source).appendTo(t);this.args[0].hasOwnProperty(\"passage\")&&n.attr(\"data-passage\",this.args[0].passage),this.args[0].hasOwnProperty(\"title\")&&n.attr(\"title\",this.args[0].title),this.args[0].hasOwnProperty(\"align\")&&n.attr(\"align\",this.args[0].align),this.args[0].hasOwnProperty(\"link\")&&(r=this.args[0].link),r=this.args[0].link}else t.append(document.createTextNode(this.args[0].text)),r=this.args[0].link;else t.wikiWithOptions({profile:\"core\"},this.args[0]),r=this.args.length>1?this.args[1]:undefined;null!=r?(t.attr(\"data-passage\",r),Story.has(r)?(t.addClass(\"link-internal\"),Config.addVisitedLinkClass&&State.hasPlayed(r)&&t.addClass(\"link-visited\")):t.addClass(\"link-broken\")):t.addClass(\"link-internal\"),t.addClass(\"macro-\"+this.name).ariaClick({namespace:\".macros\",one:null!=r},this.createShadowWrapper(\"\"!==this.payload[0].contents?function(){return Wikifier.wikifyEval(e.payload[0].contents.trim())}:null,null!=r?function(){return Engine.play(r)}:null)).appendTo(this.output)}}),Macro.add(\"checkbox\",{isAsync:!0,handler:function(){if(this.args.length<3){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"unchecked value\"),this.args.length<3&&e.push(\"checked value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');var r=Util.slugify(t),n=this.args[1],a=this.args[2],i=document.createElement(\"input\");jQuery(i).attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,type:\"checkbox\",tabindex:0}).addClass(\"macro-\"+this.name).on(\"change\",function(){State.setVar(t,this.checked?a:n)}).appendTo(this.output),this.args.length>3&&\"checked\"===this.args[3]?(i.checked=!0,State.setVar(t,a)):State.setVar(t,n)}}),Macro.add([\"linkappend\",\"linkprepend\",\"linkreplace\"],{isAsync:!0,tags:null,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no link text specified\");Config.debug&&this.createDebugView(this.name,this.source+this.payload[0].contents+\"<</\"+this.name+\">>\");var t=jQuery(document.createElement(\"a\")),r=jQuery(document.createElement(\"span\")),n=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]);t.wikiWithOptions({profile:\"core\"},this.args[0]).addClass(\"link-internal macro-\"+this.name).ariaClick({namespace:\".macros\",one:!0},this.createShadowWrapper(function(){if(\"linkreplace\"===e.name?t.remove():t.wrap('<span class=\"macro-'+e.name+'\"></span>').replaceWith(function(){return t.html()}),\"\"!==e.payload[0].contents){var a=document.createDocumentFragment();new Wikifier(a,e.payload[0].contents),r.append(a)}n&&setTimeout(function(){return r.removeClass(\"macro-\"+e.name+\"-in\")},Engine.minDomActionDelay)})).appendTo(this.output),r.addClass(\"macro-\"+this.name+\"-insert\"),n&&r.addClass(\"macro-\"+this.name+\"-in\"),\"linkprepend\"===this.name?r.insertBefore(t):r.insertAfter(t)}}),Macro.add(\"listbox\",{isAsync:!0,skipArgs:[\"optionsfrom\"],tags:[\"option\",\"optionsfrom\"],handler:function(){var e=this;if(0===this.args.length)return this.error(\"no variable name specified\");if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');var r=Util.slugify(t),n=this.payload.length;if(1===n)return this.error(\"no options specified\");for(var a=this.args.length>1&&\"autoselect\"===this.args[1],i=[],o={option:0,optionsfrom:0},s=-1,u=1;u<n;++u){var l=this.payload[u];if(\"option\"===l.name){if(++o.option,l.args.length<2){var c=[];return l.args.length<1&&c.push(\"label\"),l.args.length<2&&c.push(\"value\"),this.error(\"no \"+c.join(\" or \")+\" specified for <<\"+l.name+\">> (#\"+o.option+\")\")}if(\"string\"!=typeof l.args[0])return this.error(\"label must be a string for <<\"+l.name+\">> (#\"+o.option+\")\");if(i.push({label:l.args[0],value:l.args[1]}),l.args.length>2&&\"selected\"===l.args[2]){if(a)return this.error(\"cannot specify both the autoselect and selected keywords\");if(-1!==s)return this.error(\"multiple selected keywords specified for <<\"+l.name+\">> (#\"+(s+1)+\" & #\"+o.option+\")\");s=i.length-1}}else{var d=function(){if(++o.optionsfrom,0===l.args.full.length)return{v:e.error(\"no expression specified for <<\"+l.name+\">> (#\"+o.optionsfrom+\")\")};var t=void 0;try{var r=l.args.full;t=Scripting.evalJavaScript(\"{\"===r[0]?\"(\"+r+\")\":r)}catch(t){return{v:e.error(\"bad evaluation: \"+(\"object\"===(void 0===t?\"undefined\":_typeof(t))?t.message:t))}}if(\"object\"!==(void 0===t?\"undefined\":_typeof(t))||null===t)return{v:e.error(\"expression must yield a supported collection or generic object (type: \"+(null===t?\"null\":void 0===t?\"undefined\":_typeof(t))+\")\")};if(t instanceof Array||t instanceof Set)t.forEach(function(e){return i.push({label:String(e),value:e})});else if(t instanceof Map)t.forEach(function(e,t){return i.push({label:String(t),value:e})});else{var n=Util.toStringTag(t);if(\"Object\"!==n)return{v:e.error(\"expression must yield a supported collection or generic object (object type: \"+n+\")\")};Object.keys(t).forEach(function(e){return i.push({label:e,value:t[e]})})}}();if(\"object\"===(void 0===d?\"undefined\":_typeof(d)))return d.v}}if(-1===s)if(a){var f=Util.sameValueZero,h=State.getVar(t),p=i.findIndex(function(e){return f(e.value,h)});s=-1===p?0:p}else s=0;var g=jQuery(document.createElement(\"select\"));i.forEach(function(e,t){jQuery(document.createElement(\"option\")).val(t).text(e.label).appendTo(g)}),g.attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,tabindex:0}).addClass(\"macro-\"+this.name).val(s).on(\"change\",function(){State.setVar(t,i[Number(this.value)].value)}).appendTo(this.output),State.setVar(t,i[s].value)}}),Macro.add(\"radiobutton\",{isAsync:!0,handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"checked value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');var r=Util.slugify(t),n=this.args[1],a=document.createElement(\"input\");TempState.hasOwnProperty(this.name)||(TempState[this.name]={}),TempState[this.name].hasOwnProperty(r)||(TempState[this.name][r]=0),jQuery(a).attr({id:this.name+\"-\"+r+\"-\"+TempState[this.name][r]++,name:this.name+\"-\"+r,type:\"radio\",tabindex:0}).addClass(\"macro-\"+this.name).on(\"change\",function(){this.checked&&State.setVar(t,n)}).appendTo(this.output),this.args.length>2&&\"checked\"===this.args[2]&&(a.checked=!0,State.setVar(t,n))}}),Macro.add(\"textarea\",{isAsync:!0,handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"default value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');Config.debug&&this.debugView.modes({block:!0});var r=Util.slugify(t),n=this.args[1],a=\"autofocus\"===this.args[2],i=document.createElement(\"textarea\");jQuery(i).attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,rows:4,tabindex:0}).addClass(\"macro-\"+this.name).on(\"change\",function(){State.setVar(t,this.value)}).appendTo(this.output),State.setVar(t,n),i.textContent=n,a&&(i.setAttribute(\"autofocus\",\"autofocus\"),postdisplay[\"#autofocus:\"+i.id]=function(e){delete postdisplay[e],setTimeout(function(){return i.focus()},Engine.minDomActionDelay)})}}),Macro.add(\"textbox\",{isAsync:!0,handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"variable name\"),this.args.length<2&&e.push(\"default value\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}if(\"string\"!=typeof this.args[0])return this.error(\"variable name argument is not a string\");var t=this.args[0].trim();if(\"$\"!==t[0]&&\"_\"!==t[0])return this.error('variable name \"'+this.args[0]+'\" is missing its sigil ($ or _)');Config.debug&&this.debugView.modes({block:!0});var r=Util.slugify(t),n=this.args[1],a=document.createElement(\"input\"),i=!1,o=void 0;this.args.length>3?(o=this.args[2],i=\"autofocus\"===this.args[3]):this.args.length>2&&(\"autofocus\"===this.args[2]?i=!0:o=this.args[2]),\"object\"===(void 0===o?\"undefined\":_typeof(o))&&(o=o.link),jQuery(a).attr({id:this.name+\"-\"+r,name:this.name+\"-\"+r,type:\"text\",tabindex:0}).addClass(\"macro-\"+this.name).on(\"change\",function(){State.setVar(t,this.value)}).on(\"keypress\",function(e){13===e.which&&(e.preventDefault(),State.setVar(t,this.value),null!=o&&Engine.play(o))}).appendTo(this.output),State.setVar(t,n),a.value=n,i&&(a.setAttribute(\"autofocus\",\"autofocus\"),postdisplay[\"#autofocus:\"+a.id]=function(e){delete postdisplay[e],setTimeout(function(){return a.focus()},Engine.minDomActionDelay)})}}),Macro.add(\"click\",\"link\"),Macro.add(\"actions\",{handler:function(){\nfor(var e=jQuery(document.createElement(\"ul\")).addClass(this.name).appendTo(this.output),t=0;t<this.args.length;++t){var r=void 0,n=void 0,a=void 0,i=void 0;\"object\"===_typeof(this.args[t])?this.args[t].isImage?(a=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[t].source),this.args[t].hasOwnProperty(\"passage\")&&a.attr(\"data-passage\",this.args[t].passage),this.args[t].hasOwnProperty(\"title\")&&a.attr(\"title\",this.args[t].title),this.args[t].hasOwnProperty(\"align\")&&a.attr(\"align\",this.args[t].align),r=this.args[t].link,i=this.args[t].setFn):(n=this.args[t].text,r=this.args[t].link,i=this.args[t].setFn):n=r=this.args[t],State.variables.hasOwnProperty(\"#actions\")&&State.variables[\"#actions\"].hasOwnProperty(r)&&State.variables[\"#actions\"][r]||jQuery(Wikifier.createInternalLink(jQuery(document.createElement(\"li\")).appendTo(e),r,null,function(e,t){return function(){State.variables.hasOwnProperty(\"#actions\")||(State.variables[\"#actions\"]={}),State.variables[\"#actions\"][e]=!0,\"function\"==typeof t&&t()}}(r,i))).addClass(\"macro-\"+this.name).append(a||document.createTextNode(n))}}}),Macro.add([\"back\",\"return\"],{handler:function(){if(this.args.length>1)return this.error(\"too many arguments specified, check the documentation for details\");var e=-1,t=void 0,r=void 0,n=void 0;if(1===this.args.length&&(\"object\"===_typeof(this.args[0])?this.args[0].isImage?(n=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[0].source),this.args[0].hasOwnProperty(\"passage\")&&n.attr(\"data-passage\",this.args[0].passage),this.args[0].hasOwnProperty(\"title\")&&n.attr(\"title\",this.args[0].title),this.args[0].hasOwnProperty(\"align\")&&n.attr(\"align\",this.args[0].align),this.args[0].hasOwnProperty(\"link\")&&(t=this.args[0].link)):1===this.args[0].count?t=this.args[0].link:(r=this.args[0].text,t=this.args[0].link):1===this.args.length&&(r=this.args[0])),null==t){for(var a=State.length-2;a>=0;--a)if(State.history[a].title!==State.passage){e=a,t=State.history[a].title;break}if(null==t&&\"return\"===this.name)for(var i=State.expired.length-1;i>=0;--i)if(State.expired[i]!==State.passage){t=State.expired[i];break}}else{if(!Story.has(t))return this.error('passage \"'+t+'\" does not exist');if(\"back\"===this.name){for(var o=State.length-2;o>=0;--o)if(State.history[o].title===t){e=o;break}if(-1===e)return this.error('cannot find passage \"'+t+'\" in the current story history')}}if(null==t)return this.error(\"cannot find passage\");var s=void 0;s=\"back\"!==this.name||-1!==e?jQuery(document.createElement(\"a\")).addClass(\"link-internal\").ariaClick({one:!0},\"return\"===this.name?function(){return Engine.play(t)}:function(){return Engine.goTo(e)}):jQuery(document.createElement(\"span\")).addClass(\"link-disabled\"),s.addClass(\"macro-\"+this.name).append(n||document.createTextNode(r||L10n.get(\"macro\"+this.name.toUpperFirst()+\"Text\"))).appendTo(this.output)}}),Macro.add(\"choice\",{handler:function(){if(0===this.args.length)return this.error(\"no passage specified\");var e=State.passage,t=void 0,r=void 0,n=void 0,a=void 0;if(1===this.args.length?\"object\"===_typeof(this.args[0])?this.args[0].isImage?(n=jQuery(document.createElement(\"img\")).attr(\"src\",this.args[0].source),this.args[0].hasOwnProperty(\"passage\")&&n.attr(\"data-passage\",this.args[0].passage),this.args[0].hasOwnProperty(\"title\")&&n.attr(\"title\",this.args[0].title),this.args[0].hasOwnProperty(\"align\")&&n.attr(\"align\",this.args[0].align),t=this.args[0].link,a=this.args[0].setFn):(r=this.args[0].text,t=this.args[0].link,a=this.args[0].setFn):r=t=this.args[0]:(t=this.args[0],r=this.args[1]),State.variables.hasOwnProperty(\"#choice\")&&State.variables[\"#choice\"].hasOwnProperty(e)&&State.variables[\"#choice\"][e])return void jQuery(document.createElement(\"span\")).addClass(\"link-disabled macro-\"+this.name).attr(\"tabindex\",-1).append(n||document.createTextNode(r)).appendTo(this.output);jQuery(Wikifier.createInternalLink(this.output,t,null,function(){State.variables.hasOwnProperty(\"#choice\")||(State.variables[\"#choice\"]={}),State.variables[\"#choice\"][e]=!0,\"function\"==typeof a&&a()})).addClass(\"macro-\"+this.name).append(n||document.createTextNode(r))}}),Macro.add([\"addclass\",\"toggleclass\"],{handler:function(){if(this.args.length<2){var e=[];return this.args.length<1&&e.push(\"selector\"),this.args.length<2&&e.push(\"class names\"),this.error(\"no \"+e.join(\" or \")+\" specified\")}var t=jQuery(this.args[0]);if(0===t.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');switch(this.name){case\"addclass\":t.addClass(this.args[1].trim());break;case\"toggleclass\":t.toggleClass(this.args[1].trim())}}}),Macro.add(\"removeclass\",{handler:function(){if(0===this.args.length)return this.error(\"no selector specified\");var e=jQuery(this.args[0]);if(0===e.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');this.args.length>1?e.removeClass(this.args[1].trim()):e.removeClass()}}),Macro.add(\"copy\",{handler:function(){if(0===this.args.length)return this.error(\"no selector specified\");var e=jQuery(this.args[0]);if(0===e.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');jQuery(this.output).append(e.html())}}),Macro.add([\"append\",\"prepend\",\"replace\"],{tags:null,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no selector specified\");var t=jQuery(this.args[0]);if(0===t.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');if(\"\"!==this.payload[0].contents){var r=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]),n=void 0;switch(r?(n=jQuery(document.createElement(\"span\")),n.addClass(\"macro-\"+this.name+\"-insert macro-\"+this.name+\"-in\"),setTimeout(function(){return n.removeClass(\"macro-\"+e.name+\"-in\")},Engine.minDomActionDelay)):n=jQuery(document.createDocumentFragment()),n.wiki(this.payload[0].contents),this.name){case\"replace\":t.empty();case\"append\":t.append(n);break;case\"prepend\":t.prepend(n)}}else\"replace\"===this.name&&t.empty()}}),Macro.add(\"remove\",{handler:function(){if(0===this.args.length)return this.error(\"no selector specified\");var e=jQuery(this.args[0]);if(0===e.length)return this.error('no elements matched the selector \"'+this.args[0]+'\"');e.remove()}}),Has.audio){var e=function(e,t){return'only one playback action allowed per invocation, \"'+e+'\" cannot be combined with \"'+t+'\"'};Macro.add(\"audio\",{handler:function(){if(this.args.length<2){var t=[];return this.args.length<1&&t.push(\"track and/or group IDs\"),this.args.length<2&&t.push(\"actions\"),this.error(\"no \"+t.join(\" or \")+\" specified\")}var r=void 0;try{r=SimpleAudio.select(this.args[0])}catch(e){return this.error(e.message)}for(var n=this.args.slice(1),a=void 0,i=5,o=void 0,s=void 0,u=void 0,l=void 0,c=void 0,d=void 0;n.length>0;){var f=n.shift(),h=void 0;switch(f){case\"load\":case\"pause\":case\"play\":case\"stop\":case\"unload\":if(a)return this.error(e(f,a));a=f;break;case\"fadein\":if(a)return this.error(e(f,a));a=\"fade\",o=1;break;case\"fadeout\":if(a)return this.error(e(f,a));a=\"fade\",o=0;break;case\"fadeto\":if(a)return this.error(e(f,a));if(0===n.length)return this.error(\"fadeto missing required level value\");if(a=\"fade\",h=n.shift(),o=Number.parseFloat(h),Number.isNaN(o)||!Number.isFinite(o))return this.error(\"cannot parse fadeto: \"+h);break;case\"fadeoverto\":if(a)return this.error(e(f,a));if(n.length<2){var p=[];return n.length<1&&p.push(\"seconds\"),n.length<2&&p.push(\"level\"),this.error(\"fadeoverto missing required \"+p.join(\" and \")+\" value\"+(p.length>1?\"s\":\"\"))}if(a=\"fade\",h=n.shift(),i=Number.parseFloat(h),Number.isNaN(i)||!Number.isFinite(i))return this.error(\"cannot parse fadeoverto: \"+h);if(h=n.shift(),o=Number.parseFloat(h),Number.isNaN(o)||!Number.isFinite(o))return this.error(\"cannot parse fadeoverto: \"+h);break;case\"volume\":if(0===n.length)return this.error(\"volume missing required level value\");if(h=n.shift(),d=Number.parseFloat(h),Number.isNaN(d)||!Number.isFinite(d))return this.error(\"cannot parse volume: \"+h);break;case\"mute\":case\"unmute\":u=\"mute\"===f;break;case\"time\":if(0===n.length)return this.error(\"time missing required seconds value\");if(h=n.shift(),c=Number.parseFloat(h),Number.isNaN(c)||!Number.isFinite(c))return this.error(\"cannot parse time: \"+h);break;case\"loop\":case\"unloop\":s=\"loop\"===f;break;case\"goto\":if(0===n.length)return this.error(\"goto missing required passage title\");if(h=n.shift(),l=\"object\"===(void 0===h?\"undefined\":_typeof(h))?h.link:h,!Story.has(l))return this.error('passage \"'+l+'\" does not exist');break;default:return this.error(\"unknown action: \"+f)}}try{if(null!=d&&r.volume(d),null!=c&&r.time(c),null!=u&&r.mute(u),null!=s&&r.loop(s),null!=l){var g=\"ended.macro-\"+this.name+\":goto\";r.off(g).one(g,function(){r.off(g),Engine.play(l)})}switch(a){case\"fade\":r.fade(i,o);break;case\"load\":r.load();break;case\"pause\":r.pause();break;case\"play\":r.play();break;case\"stop\":r.stop();break;case\"unload\":r.unload()}Config.debug&&this.createDebugView()}catch(e){return this.error(\"error executing action: \"+e.message)}}}),Macro.add(\"cacheaudio\",{handler:function(){var e=this;if(this.args.length<2){var t=[];return this.args.length<1&&t.push(\"track ID\"),this.args.length<2&&t.push(\"sources\"),this.error(\"no \"+t.join(\" or \")+\" specified\")}var r=String(this.args[0]).trim(),n=/^format:\\s*([\\w-]+)\\s*;\\s*/i;try{SimpleAudio.tracks.add(r,this.args.slice(1).map(function(t){if(n.test(t)){if(Config.debug)return e.error('track ID \"'+r+'\": format specifier migration required, \"format:formatId;\" → \"formatId|\"');t=t.replace(n,\"$1|\")}return t}))}catch(e){return this.error(e.message)}if(Config.debug&&!SimpleAudio.tracks.get(r).hasSource())return this.error('track ID \"'+r+'\": no supported audio sources found');Config.debug&&this.createDebugView()}}),Macro.add(\"createaudiogroup\",{tags:[\"track\"],handler:function(){if(0===this.args.length)return this.error(\"no group ID specified\");if(1===this.payload.length)return this.error(\"no tracks defined via <<track>>\");Config.debug&&this.debugView.modes({nonvoid:!1,hidden:!0});for(var e=String(this.args[0]).trim(),t=[],r=1,n=this.payload.length;r<n;++r){if(this.payload[r].args.length<1)return this.error(\"no track ID specified\");t.push(String(this.payload[r].args[0]).trim()),Config.debug&&this.createDebugView(this.payload[r].name,this.payload[r].source).modes({nonvoid:!1,hidden:!0})}try{SimpleAudio.groups.add(e,t)}catch(e){return this.error(e.message)}Config.debug&&this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!0})}}),Macro.add(\"createplaylist\",{tags:[\"track\"],handler:function(){if(0===this.args.length)return this.error(\"no list ID specified\");if(1===this.payload.length)return this.error(\"no tracks defined via <<track>>\");var e=Macro.get(\"playlist\");if(null!==e.from&&\"createplaylist\"!==e.from)return this.error(\"a playlist has already been defined with <<setplaylist>>\");Config.debug&&this.debugView.modes({nonvoid:!1,hidden:!0});for(var t=String(this.args[0]).trim(),r=[],n=1,a=this.payload.length;n<a;++n){if(this.payload[n].args.length<2){var i=[];return this.payload[n].args.length<1&&i.push(\"track ID\"),this.payload[n].args.length<2&&i.push(\"actions\"),this.error(\"no \"+i.join(\" or \")+\" specified\")}for(var o={id:String(this.payload[n].args[0]).trim()},s=this.payload[n].args.slice(1);s.length>0;){var u=s.shift(),l=void 0,c=void 0;switch(u){case\"copy\":o.copy=!0;break;case\"rate\":s.length>0&&s.shift();break;case\"volume\":if(0===s.length)return this.error(\"volume missing required level value\");if(l=s.shift(),c=Number.parseFloat(l),Number.isNaN(c)||!Number.isFinite(c))return this.error(\"cannot parse volume: \"+l);o.volume=c;break;default:return this.error(\"unknown action: \"+u)}}r.push(o),Config.debug&&this.createDebugView(this.payload[n].name,this.payload[n].source).modes({nonvoid:!1,hidden:!0})}try{SimpleAudio.lists.add(t,r)}catch(e){return this.error(e.message)}null===e.from&&(e.from=\"createplaylist\"),Config.debug&&this.createDebugView(\"/\"+this.name,\"<</\"+this.name+\">>\").modes({nonvoid:!1,hidden:!0})}}),Macro.add(\"masteraudio\",{handler:function(){if(0===this.args.length)return this.error(\"no actions specified\");for(var t=this.args.slice(0),r=void 0,n=void 0,a=void 0,i=void 0;t.length>0;){var o=t.shift(),s=void 0;switch(o){case\"load\":case\"stop\":case\"unload\":if(r)return this.error(e(o,r));r=o;break;case\"mute\":case\"unmute\":n=\"mute\"===o;break;case\"muteonhide\":case\"nomuteonhide\":a=\"muteonhide\"===o;break;case\"volume\":if(0===t.length)return this.error(\"volume missing required level value\");if(s=t.shift(),i=Number.parseFloat(s),Number.isNaN(i)||!Number.isFinite(i))return this.error(\"cannot parse volume: \"+s);break;default:return this.error(\"unknown action: \"+o)}}try{switch(null!=n&&SimpleAudio.mute(n),null!=a&&SimpleAudio.muteOnHidden(a),null!=i&&SimpleAudio.volume(i),r){case\"load\":SimpleAudio.load();break;case\"stop\":SimpleAudio.stop();break;case\"unload\":SimpleAudio.unload()}Config.debug&&this.createDebugView()}catch(e){return this.error(\"error executing action: \"+e.message)}}}),Macro.add(\"playlist\",{from:null,handler:function(){var t=this.self.from;if(null===t)return this.error(\"no playlists have been created\");var r=void 0,n=void 0;if(\"createplaylist\"===t){if(this.args.length<2){var a=[];return this.args.length<1&&a.push(\"list ID\"),this.args.length<2&&a.push(\"actions\"),this.error(\"no \"+a.join(\" or \")+\" specified\")}var i=String(this.args[0]).trim();if(!SimpleAudio.lists.has(i))return this.error('playlist \"'+i+'\" does not exist');r=SimpleAudio.lists.get(i),n=this.args.slice(1)}else{if(0===this.args.length)return this.error(\"no actions specified\");r=SimpleAudio.lists.get(\"setplaylist\"),n=this.args.slice(0)}for(var o=void 0,s=5,u=void 0,l=void 0,c=void 0,d=void 0,f=void 0;n.length>0;){var h=n.shift(),p=void 0;switch(h){case\"load\":case\"pause\":case\"play\":case\"skip\":case\"stop\":case\"unload\":if(o)return this.error(e(h,o));o=h;break;case\"fadein\":if(o)return this.error(e(h,o));o=\"fade\",u=1;break;case\"fadeout\":if(o)return this.error(e(h,o));o=\"fade\",u=0;break;case\"fadeto\":if(o)return this.error(e(h,o));if(0===n.length)return this.error(\"fadeto missing required level value\");if(o=\"fade\",p=n.shift(),u=Number.parseFloat(p),Number.isNaN(u)||!Number.isFinite(u))return this.error(\"cannot parse fadeto: \"+p);break;case\"fadeoverto\":if(o)return this.error(e(h,o));if(n.length<2){var g=[];return n.length<1&&g.push(\"seconds\"),n.length<2&&g.push(\"level\"),this.error(\"fadeoverto missing required \"+g.join(\" and \")+\" value\"+(g.length>1?\"s\":\"\"))}if(o=\"fade\",p=n.shift(),s=Number.parseFloat(p),Number.isNaN(s)||!Number.isFinite(s))return this.error(\"cannot parse fadeoverto: \"+p);if(p=n.shift(),u=Number.parseFloat(p),Number.isNaN(u)||!Number.isFinite(u))return this.error(\"cannot parse fadeoverto: \"+p);break;case\"volume\":if(0===n.length)return this.error(\"volume missing required level value\");if(p=n.shift(),f=Number.parseFloat(p),Number.isNaN(f)||!Number.isFinite(f))return this.error(\"cannot parse volume: \"+p);break;case\"mute\":case\"unmute\":c=\"mute\"===h;break;case\"loop\":case\"unloop\":l=\"loop\"===h;break;case\"shuffle\":case\"unshuffle\":d=\"shuffle\"===h;break;default:return this.error(\"unknown action: \"+h)}}try{switch(null!=f&&r.volume(f),null!=c&&r.mute(c),null!=l&&r.loop(l),null!=d&&r.shuffle(d),o){case\"fade\":r.fade(s,u);break;case\"load\":r.load();break;case\"pause\":r.pause();break;case\"play\":r.play();break;case\"skip\":r.skip();break;case\"stop\":r.stop();break;case\"unload\":r.unload()}Config.debug&&this.createDebugView()}catch(e){return this.error(\"error executing action: \"+e.message)}}}),Macro.add(\"removeaudiogroup\",{handler:function(){if(0===this.args.length)return this.error(\"no group ID specified\");var e=String(this.args[0]).trim();if(!SimpleAudio.groups.has(e))return this.error('group \"'+e+'\" does not exist');SimpleAudio.groups.delete(e),Config.debug&&this.createDebugView()}}),Macro.add(\"removeplaylist\",{handler:function(){if(0===this.args.length)return this.error(\"no list ID specified\");var e=String(this.args[0]).trim();if(!SimpleAudio.lists.has(e))return this.error('playlist \"'+e+'\" does not exist');SimpleAudio.lists.delete(e),Config.debug&&this.createDebugView()}}),Macro.add(\"waitforaudio\",{skipArgs:!0,handler:function(){SimpleAudio.loadWithScreen()}}),Macro.add(\"setplaylist\",{handler:function(){if(0===this.args.length)return this.error(\"no track ID(s) specified\");var e=Macro.get(\"playlist\");if(null!==e.from&&\"setplaylist\"!==e.from)return this.error(\"playlists have already been defined with <<createplaylist>>\");try{SimpleAudio.lists.add(\"setplaylist\",this.args.slice(0))}catch(e){return this.error(e.message)}null===e.from&&(e.from=\"setplaylist\"),Config.debug&&this.createDebugView()}}),Macro.add(\"stopallaudio\",{skipArgs:!0,handler:function(){SimpleAudio.select(\":all\").stop(),Config.debug&&this.createDebugView()}})}else Macro.add([\"audio\",\"cacheaudio\",\"createaudiogroup\",\"createplaylist\",\"masteraudio\",\"playlist\",\"removeaudiogroup\",\"removeplaylist\",\"waitforaudio\",\"setplaylist\",\"stopallaudio\"],{skipArgs:!0,handler:function(){}});Macro.add(\"goto\",{handler:function(){if(0===this.args.length)return this.error(\"no passage specified\");var e=void 0;if(e=\"object\"===_typeof(this.args[0])?this.args[0].link:this.args[0],!Story.has(e))return this.error('passage \"'+e+'\" does not exist');setTimeout(function(){return Engine.play(e)},Engine.minDomActionDelay)}}),Macro.add(\"repeat\",{isAsync:!0,tags:null,timers:new Set,handler:function(){var e=this;if(0===this.args.length)return this.error(\"no time value specified\");var t=void 0;try{t=Math.max(Engine.minDomActionDelay,Util.fromCssTime(this.args[0]))}catch(e){return this.error(e.message)}Config.debug&&this.debugView.modes({block:!0});var r=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]),n=jQuery(document.createElement(\"span\")).addClass(\"macro-\"+this.name).appendTo(this.output);this.self.registerInterval(this.createShadowWrapper(function(){var t=document.createDocumentFragment();new Wikifier(t,e.payload[0].contents);var a=n;r&&(a=jQuery(document.createElement(\"span\")).addClass(\"macro-repeat-insert macro-repeat-in\").appendTo(a)),a.append(t),r&&setTimeout(function(){return a.removeClass(\"macro-repeat-in\")},Engine.minDomActionDelay)}),t)},registerInterval:function(e,t){var r=this;if(\"function\"!=typeof e)throw new TypeError(\"callback parameter must be a function\");var n=State.turns,a=this.timers,i=null;i=setInterval(function(){if(n!==State.turns)return clearInterval(i),void a.delete(i);var t=void 0;try{TempState.break=null,TempState.hasOwnProperty(\"repeatTimerId\")&&(t=TempState.repeatTimerId),TempState.repeatTimerId=i,e.call(r)}finally{void 0!==t?TempState.repeatTimerId=t:delete TempState.repeatTimerId,TempState.break=null}},t),a.add(i),prehistory.hasOwnProperty(\"#repeat-timers-cleanup\")||(prehistory[\"#repeat-timers-cleanup\"]=function(e){delete prehistory[e],a.forEach(function(e){return clearInterval(e)}),a.clear()})}}),Macro.add(\"stop\",{skipArgs:!0,handler:function(){if(!TempState.hasOwnProperty(\"repeatTimerId\"))return this.error(\"must only be used in conjunction with its parent macro <<repeat>>\");var e=Macro.get(\"repeat\").timers,t=TempState.repeatTimerId;clearInterval(t),e.delete(t),TempState.break=2,Config.debug&&this.debugView.modes({hidden:!0})}}),Macro.add(\"timed\",{isAsync:!0,tags:[\"next\"],timers:new Set,handler:function(){if(0===this.args.length)return this.error(\"no time value specified in <<timed>>\");var e=[];try{e.push({name:this.name,source:this.source,delay:Math.max(Engine.minDomActionDelay,Util.fromCssTime(this.args[0])),content:this.payload[0].contents})}catch(e){return this.error(e.message+\" in <<timed>>\")}if(this.payload.length>1){var t=void 0;try{var r=void 0;for(t=1,r=this.payload.length;t<r;++t)e.push({name:this.payload[t].name,source:this.payload[t].source,delay:0===this.payload[t].args.length?e[e.length-1].delay:Math.max(Engine.minDomActionDelay,Util.fromCssTime(this.payload[t].args[0])),content:this.payload[t].contents})}catch(e){return this.error(e.message+\" in <<next>> (#\"+t+\")\")}}Config.debug&&this.debugView.modes({block:!0});var n=this.args.length>1&&/^(?:transition|t8n)$/.test(this.args[1]),a=jQuery(document.createElement(\"span\")).addClass(\"macro-\"+this.name).appendTo(this.output);this.self.registerTimeout(this.createShadowWrapper(function(e){var t=document.createDocumentFragment();new Wikifier(t,e.content);var r=a;Config.debug&&\"next\"===e.name&&(r=jQuery(new DebugView(r[0],\"macro\",e.name,e.source).output)),n&&(r=jQuery(document.createElement(\"span\")).addClass(\"macro-timed-insert macro-timed-in\").appendTo(r)),r.append(t),n&&setTimeout(function(){return r.removeClass(\"macro-timed-in\")},Engine.minDomActionDelay)}),e)},registerTimeout:function(e,t){if(\"function\"!=typeof e)throw new TypeError(\"callback parameter must be a function\");var r=State.turns,n=this.timers,a=null,i=t.shift(),o=function o(){if(n.delete(a),r===State.turns){var s=i;null!=(i=t.shift())&&(a=setTimeout(o,i.delay),n.add(a)),e.call(this,s)}};a=setTimeout(o,i.delay),n.add(a),prehistory.hasOwnProperty(\"#timed-timers-cleanup\")||(prehistory[\"#timed-timers-cleanup\"]=function(e){delete prehistory[e],n.forEach(function(e){return clearTimeout(e)}),n.clear()})}}),Macro.add(\"widget\",{tags:null,handler:function(){if(0===this.args.length)return this.error(\"no widget name specified\");var e=this.args[0];if(Macro.has(e)){if(!Macro.get(e).isWidget)return this.error('cannot clobber existing macro \"'+e+'\"');Macro.delete(e)}try{Macro.add(e,{isWidget:!0,handler:function(e){return function(){var t=void 0;try{State.variables.hasOwnProperty(\"args\")&&(t=State.variables.args),State.variables.args=[].concat(_toConsumableArray(this.args)),State.variables.args.raw=this.args.raw,State.variables.args.full=this.args.full,this.addShadow(\"$args\");var r=document.createDocumentFragment(),n=[];if(new Wikifier(r,e),Array.from(r.querySelectorAll(\".error\")).forEach(function(e){n.push(e.textContent)}),0!==n.length)return this.error(\"error\"+(n.length>1?\"s\":\"\")+\" within widget contents (\"+n.join(\"; \")+\")\");this.output.appendChild(r)}catch(e){return this.error(\"cannot execute widget: \"+e.message)}finally{void 0!==t?State.variables.args=t:delete State.variables.args}}}(this.payload[0].contents)}),Config.debug&&this.createDebugView(this.name,this.source+this.payload[0].contents+\"<</\"+this.name+\">>\")}catch(t){return this.error('cannot create widget macro \"'+e+'\": '+t.message)}}})}();var Dialog=function(){function e(){m=function(){var e=void 0;try{var t=document.createElement(\"p\"),r=document.createElement(\"div\");t.style.width=\"100%\",t.style.height=\"200px\",r.style.position=\"absolute\",r.style.left=\"0px\",r.style.top=\"0px\",r.style.width=\"100px\",r.style.height=\"100px\",r.style.visibility=\"hidden\",r.style.overflow=\"hidden\",r.appendChild(t),document.body.appendChild(r);var n=t.offsetWidth;r.style.overflow=\"auto\";var a=t.offsetWidth;n===a&&(a=r.clientWidth),document.body.removeChild(r),e=n-a}catch(e){}return e||17}();var e=jQuery(document.createDocumentFragment()).append('<div id=\"ui-overlay\" class=\"ui-close\"></div><div id=\"ui-dialog\" tabindex=\"0\" role=\"dialog\" aria-labelledby=\"ui-dialog-title\"><div id=\"ui-dialog-titlebar\"><h1 id=\"ui-dialog-title\"></h1><button id=\"ui-dialog-close\" class=\"ui-close\" tabindex=\"0\" aria-label=\"'+L10n.get(\"close\")+'\"></button></div><div id=\"ui-dialog-body\"></div></div>');d=jQuery(e.find(\"#ui-overlay\").get(0)),f=jQuery(e.find(\"#ui-dialog\").get(0)),h=jQuery(e.find(\"#ui-dialog-title\").get(0)),p=jQuery(e.find(\"#ui-dialog-body\").get(0)),e.insertBefore(\"#store-area\")}function t(e){return f.hasClass(\"open\")&&(!e||e.splitOrEmpty(/\\s+/).every(function(e){return p.hasClass(e)}))}function r(e,t){return p.empty().removeClass(),null!=t&&p.addClass(t),h.empty().append((null!=e?String(e):\"\")||\" \"),p.get(0)}function n(){return p.get(0)}function a(){var e;return(e=p).append.apply(e,arguments),Dialog}function i(){var e;return(e=p).wiki.apply(e,arguments),Dialog}function o(e,t,r,n,a){return jQuery(e).ariaClick(function(e){e.preventDefault(),\"function\"==typeof r&&r(e),s(t,a),\"function\"==typeof n&&n(e)})}function s(e,r){var n=jQuery.extend({top:50},e),a=n.top;t()||(g=safeActiveElement()),jQuery(document.documentElement).attr(\"data-dialog\",\"open\"),d.addClass(\"open\"),null!==p[0].querySelector(\"img\")&&p.imagesLoaded().always(function(){return l({data:{top:a}})}),jQuery(\"body>:not(script,#store-area,#ui-bar,#ui-overlay,#ui-dialog)\").attr(\"tabindex\",-3).attr(\"aria-hidden\",!0),jQuery(\"#ui-bar,#story\").find(\"[tabindex]:not([tabindex^=-])\").attr(\"tabindex\",-2).attr(\"aria-hidden\",!0);var i=c(a);return f.css(i).addClass(\"open\").focus(),jQuery(window).on(\"resize.dialog-resize\",null,{top:a},jQuery.throttle(40,l)),Has.mutationObserver?(v=new MutationObserver(function(e){for(var t=0;t<e.length;++t)if(\"childList\"===e[t].type){l({data:{top:a}});break}}),v.observe(p[0],{childList:!0,subtree:!0})):p.on(\"DOMNodeInserted.dialog-resize DOMNodeRemoved.dialog-resize\",null,{top:a},jQuery.throttle(40,l)),jQuery(document).on(\"click.dialog-close\",\".ui-close\",{closeFn:r},u).on(\"keypress.dialog-close\",\".ui-close\",function(e){13!==e.which&&32!==e.which||jQuery(this).trigger(\"click\")}),setTimeout(function(){return jQuery.event.trigger(\":dialogopen\")},Engine.minDomActionDelay),Dialog}function u(e){return jQuery(document).off(\".dialog-close\"),v?(v.disconnect(),v=null):p.off(\".dialog-resize\"),jQuery(window).off(\".dialog-resize\"),f.removeClass(\"open\").css({left:\"\",right:\"\",top:\"\",bottom:\"\"}),jQuery(\"#ui-bar,#story\").find(\"[tabindex=-2]\").removeAttr(\"aria-hidden\").attr(\"tabindex\",0),jQuery(\"body>[tabindex=-3]\").removeAttr(\"aria-hidden\").removeAttr(\"tabindex\"),h.empty(),p.empty().removeClass(),d.removeClass(\"open\"),jQuery(document.documentElement).removeAttr(\"data-dialog\"),null!==g&&(jQuery(g).focus(),g=null),e&&e.data&&\"function\"==typeof e.data.closeFn&&e.data.closeFn(e),setTimeout(function(){return jQuery.event.trigger(\":dialogclose\")},Engine.minDomActionDelay),Dialog}function l(e){var t=e&&e.data&&void 0!==e.data.top?e.data.top:50;\"block\"===f.css(\"display\")&&(f.css({display:\"none\"}),f.css(jQuery.extend({display:\"\"},c(t))))}function c(e){var t=null!=e?e:50,r=jQuery(window),n={left:\"\",right:\"\",top:\"\",bottom:\"\"};f.css(n);var a=r.width()-f.outerWidth(!0)-1,i=r.height()-f.outerHeight(!0)-1;return a<=32+m&&(i-=m),i<=32+m&&(a-=m),n.left=n.right=a<=32?16:a/2>>0,n.top=i<=32?n.bottom=16:i/2>t?t:n.bottom=i/2>>0,Object.keys(n).forEach(function(e){\"\"!==n[e]&&(n[e]+=\"px\")}),n}var d=null,f=null,h=null,p=null,g=null,m=0,v=null;return Object.freeze(Object.defineProperties({},{init:{value:e},isOpen:{value:t},setup:{value:r},body:{value:n},append:{value:a},wiki:{value:i},addClickHandler:{value:o},open:{value:s},close:{value:u},resize:{value:function(e){return l(\"object\"===(void 0===e?\"undefined\":_typeof(e))?{data:e}:undefined)}}}))}(),Engine=function(){function e(){jQuery(\"#init-no-js,#init-lacking\").remove(),function(){var e=jQuery(document.createDocumentFragment()),t=Story.has(\"StoryInterface\")&&Story.get(\"StoryInterface\").text.trim();if(t){if(UIBar.destroy(),jQuery(document.head).find(\"#style-core-display\").remove(),e.append(t),0===e.find(\"#passages\").length)throw new Error('no element with ID \"passages\" found within \"StoryInterface\" special passage');var r=[];e.find(\"[data-passage]\").each(function(e,t){if(\"passages\"===t.id)throw new Error('\"StoryInterface\" element <'+t.nodeName.toLowerCase()+' id=\"passages\"> must not contain a \"data-passage\" content attribute');var n=t.getAttribute(\"data-passage\").trim();if(null!==t.firstElementChild)throw new Error('\"StoryInterface\" element <'+t.nodeName.toLowerCase()+' data-passage=\"'+n+'\"> contains child elements');Story.has(n)&&r.push({passage:n,element:t})}),r.length>0&&(E=r),Config.ui.updateStoryElements=!1}else e.append('<div id=\"story\" role=\"main\"><div id=\"passages\"></div></div>');e.insertBefore(\"#store-area\")}(),S=new StyleWrapper(function(){return jQuery(document.createElement(\"style\")).attr({id:\"style-aria-outlines\",type:\"text/css\"}).appendTo(document.head).get(0)}()),jQuery(document).on(\"mousedown.aria-outlines keydown.aria-outlines\",function(e){return\"keydown\"===e.type?m():g()})}function t(){if(Story.has(\"StoryInit\"))try{var e=Wikifier.wikifyEval(Story.get(\"StoryInit\").text);if(Config.debug){var t=new DebugView(document.createDocumentFragment(),\"special\",\"StoryInit\",\"StoryInit\");t.modes({hidden:!0}),t.append(e),k=t.output}}catch(e){console.error(e),Alert.error(\"StoryInit\",e.message)}if(Config.history.maxStates=Math.max(0,Config.history.maxStates),Number.isSafeInteger(Config.history.maxStates)||(Config.history.maxStates=100),1===Config.history.maxStates&&(Config.history.controls=!1),null==Config.passages.start)throw new Error(\"starting passage not selected\");if(!Story.has(Config.passages.start))throw new Error('starting passage (\"'+Config.passages.start+'\") not found');if(jQuery(document.documentElement).focus(),State.restore())f();else{var r=!0;switch(_typeof(Config.saves.autoload)){case\"boolean\":Config.saves.autoload&&Save.autosave.ok()&&Save.autosave.has()&&(r=!Save.autosave.load());break;case\"string\":\"prompt\"===Config.saves.autoload&&Save.autosave.ok()&&Save.autosave.has()&&(r=!1,UI.buildAutoload(),Dialog.open());break;case\"function\":Save.autosave.ok()&&Save.autosave.has()&&Config.saves.autoload()&&(r=!Save.autosave.load())}r&&h(Config.passages.start)}}function r(){LoadScreen.show(),window.scroll(0,0),State.reset(),jQuery.event.trigger(\":enginerestart\"),window.location.reload()}function n(){return b}function a(){return b===v.Idle}function i(){return b!==v.Idle}function o(){return b===v.Rendering}function s(){return w}function u(e){var t=State.goTo(e);return t&&f(),t}function l(e){var t=State.go(e);return t&&f(),t}function c(){return l(-1)}function d(){return l(1)}function f(){return h(State.passage,!0)}function h(e,t){var r=e;b=v.Playing,TempState={},State.clearTemporary();var n=void 0,a=void 0;if(\"function\"==typeof Config.navigation.override)try{var i=Config.navigation.override(r);i&&(r=i)}catch(e){}var o=Story.get(r);if(jQuery.event.trigger({type:\":passageinit\",passage:o}),Object.keys(prehistory).forEach(function(e){\"function\"==typeof prehistory[e]&&prehistory[e].call(this,e)},o),t||State.create(o.title),w=Util.now(),document.body.className&&(document.body.className=\"\"),Object.keys(predisplay).forEach(function(e){\"function\"==typeof predisplay[e]&&predisplay[e].call(this,e)},o),Story.has(\"PassageReady\"))try{n=Wikifier.wikifyEval(Story.get(\"PassageReady\").text)}catch(e){console.error(e),Alert.error(\"PassageReady\",e.message)}b=v.Rendering;var s=jQuery(o.render()),u=document.getElementById(\"passages\");if(u.hasChildNodes()&&(\"number\"==typeof Config.passages.transitionOut||\"string\"==typeof Config.passages.transitionOut&&\"\"!==Config.passages.transitionOut&&\"\"!==Config.transitionEndEventName?[].concat(_toConsumableArray(u.childNodes)).forEach(function(e){var t=jQuery(e);if(e.nodeType===Node.ELEMENT_NODE&&t.hasClass(\"passage\")){if(t.hasClass(\"passage-out\"))return;t.attr(\"id\",\"out-\"+t.attr(\"id\")).addClass(\"passage-out\"),\"string\"==typeof Config.passages.transitionOut?t.on(Config.transitionEndEventName,function(e){e.originalEvent.propertyName===Config.passages.transitionOut&&t.remove()}):setTimeout(function(){return t.remove()},Math.max(y,Config.passages.transitionOut))}else t.remove()}):jQuery(u).empty()),s.addClass(\"passage-in\").appendTo(u),setTimeout(function(){return s.removeClass(\"passage-in\")},y),Config.passages.displayTitles&&o.title!==Config.passages.start&&(document.title=o.title+\" | \"+Story.title),window.scroll(0,0),b=v.Playing,Story.has(\"PassageDone\"))try{a=Wikifier.wikifyEval(Story.get(\"PassageDone\").text)}catch(e){console.error(e),Alert.error(\"PassageDone\",e.message)}if(jQuery.event.trigger({type:\":passagedisplay\",passage:o}),Object.keys(postdisplay).forEach(function(e){\"function\"==typeof postdisplay[e]&&postdisplay[e].call(this,e)},o),null!==E?E.forEach(function(e){jQuery(e.element).empty(),new Wikifier(e.element,Story.get(e.passage).processText().trim())}):Config.ui.updateStoryElements&&UIBar.setStoryElements(),Config.debug){var l=void 0\n;null!=n&&(l=new DebugView(document.createDocumentFragment(),\"special\",\"PassageReady\",\"PassageReady\"),l.modes({hidden:!0}),l.append(n),s.prepend(l.output)),null!=a&&(l=new DebugView(document.createDocumentFragment(),\"special\",\"PassageDone\",\"PassageDone\"),l.modes({hidden:!0}),l.append(a),s.append(l.output)),1===State.turns&&null!=k&&s.prepend(k)}switch(g(),jQuery(\"#story\").find(\"a[href]:not(.link-external)\").addClass(\"link-external\").end().find(\"a,link,button,input,select,textarea\").not(\"[tabindex]\").attr(\"tabindex\",0),_typeof(Config.saves.autosave)){case\"boolean\":Config.saves.autosave&&Save.autosave.save();break;case\"string\":o.tags.includes(Config.saves.autosave)&&Save.autosave.save();break;case\"object\":Array.isArray(Config.saves.autosave)&&o.tags.some(function(e){return Config.saves.autosave.includes(e)})&&Save.autosave.save()}return jQuery.event.trigger({type:\":passageend\",passage:o}),b=v.Idle,w=Util.now(),s[0]}function p(e,t,r){var n=!1;switch(r){case undefined:break;case\"replace\":case\"back\":n=!0;break;default:throw new Error('Engine.display option parameter called with obsolete value \"'+r+'\"; please notify the developer')}h(e,n)}function g(){S.set(\"*:focus{outline:none}\")}function m(){S.clear()}var v=Util.toEnum({Idle:\"idle\",Playing:\"playing\",Rendering:\"rendering\"}),y=40,b=v.Idle,w=null,k=null,S=null,E=null;return Object.freeze(Object.defineProperties({},{States:{value:v},minDomActionDelay:{value:y},init:{value:e},start:{value:t},restart:{value:r},state:{get:n},isIdle:{value:a},isPlaying:{value:i},isRendering:{value:o},lastPlay:{get:s},goTo:{value:u},go:{value:l},backward:{value:c},forward:{value:d},show:{value:f},play:{value:h},display:{value:p}}))}(),Passage=function(){var e=void 0;e=/^(?:debug|nobr|passage|widget|twine\\..*)$/i;return function(){function t(r,n){var a=this;_classCallCheck(this,t),Object.defineProperties(this,{title:{value:Util.unescape(r)},element:{value:n||null},tags:{value:Object.freeze(n&&n.hasAttribute(\"tags\")?n.getAttribute(\"tags\").trim().splitOrEmpty(/\\s+/).sort().filter(function(e,t,r){return 0===t||r[t-1]!==e}):[])},_excerpt:{writable:!0,value:null}}),Object.defineProperties(this,{domId:{value:\"passage-\"+Util.slugify(this.title)},classes:{value:Object.freeze(0===this.tags.length?[]:function(){return a.tags.filter(function(t){return!e.test(t)}).map(function(e){return Util.slugify(e)})}())}})}return _createClass(t,[{key:\"description\",value:function(){var e=Config.passages.descriptions;if(null!=e)switch(void 0===e?\"undefined\":_typeof(e)){case\"boolean\":if(e)return this.title;break;case\"object\":if(e instanceof Map&&e.has(this.title))return e.get(this.title);if(e.hasOwnProperty(this.title))return e[this.title];break;case\"function\":var r=e.call(this);if(r)return r;break;default:throw new TypeError(\"Config.passages.descriptions must be a boolean, object, or function\")}return null===this._excerpt&&(this._excerpt=t.getExcerptFromText(this.text)),this._excerpt}},{key:\"processText\",value:function(){if(null==this.element)return this.text;var e=this.text;return this.tags.includes(\"Twine.image\")?e=\"[img[\"+e+\"]]\":(Config.passages.nobr||this.tags.includes(\"nobr\"))&&(e=e.replace(/^\\n+|\\n+$/g,\"\").replace(/\\n+/g,\" \")),e}},{key:\"render\",value:function(){var e=this,r=this.tags.length>0?this.tags.join(\" \"):null,n=document.createElement(\"div\");return jQuery(n).attr({id:this.domId,\"data-passage\":this.title,\"data-tags\":r}).addClass(\"passage \"+this.className),jQuery(document.body).attr(\"data-tags\",r).addClass(this.className),jQuery(document.documentElement).attr(\"data-tags\",r),jQuery.event.trigger({type:\":passagestart\",content:n,passage:this}),Object.keys(prerender).forEach(function(t){\"function\"==typeof prerender[t]&&prerender[t].call(e,n,t)}),Story.has(\"PassageHeader\")&&new Wikifier(n,Story.get(\"PassageHeader\").processText()),new Wikifier(n,this.processText()),Story.has(\"PassageFooter\")&&new Wikifier(n,Story.get(\"PassageFooter\").processText()),jQuery.event.trigger({type:\":passagerender\",content:n,passage:this}),Object.keys(postrender).forEach(function(t){\"function\"==typeof postrender[t]&&postrender[t].call(e,n,t)}),this._excerpt=t.getExcerptFromNode(n),n}},{key:\"className\",get:function(){return this.classes.join(\" \")}},{key:\"text\",get:function(){if(null==this.element){var e=Util.escape(this.title);return'<div class=\"error-view\"><span class=\"error\">'+(L10n.get(\"errorTitle\")+\": \"+L10n.get(\"errorNonexistentPassage\",{passage:e}))+\"</span></div>\"}return this.element.textContent.replace(/\\r/g,\"\")}}],[{key:\"getExcerptFromNode\",value:function(e,t){if(!e.hasChildNodes())return\"\";var r=e.textContent.trim();if(\"\"!==r){var n=new RegExp(\"(\\\\S+(?:\\\\s+\\\\S+){0,\"+(t>0?t-1:7)+\"})\");r=r.replace(/\\s+/g,\" \").match(n)}return r?r[1]+\"…\":\"…\"}},{key:\"getExcerptFromText\",value:function(e,t){if(\"\"===e)return\"\";var r=new RegExp(\"(\\\\S+(?:\\\\s+\\\\S+){0,\"+(t>0?t-1:7)+\"})\"),n=e.replace(/<<.*?>>/g,\" \").replace(/<.*?>/g,\" \").trim().replace(/^\\s*\\|.*\\|.*?$/gm,\"\").replace(/\\[[<>]?img\\[[^\\]]*\\]\\]/g,\"\").replace(/\\[\\[([^|\\]]*?)(?:(?:\\||->|<-)[^\\]]*)?\\]\\]/g,\"$1\").replace(/^\\s*!+(.*?)$/gm,\"$1\").replace(/'{2}|\\/{2}|_{2}|@{2}/g,\"\").trim().replace(/\\s+/g,\" \").match(r);return n?n[1]+\"…\":\"…\"}}]),t}()}(),Save=function(){function e(){if(\"cookie\"===storage.name)return n(),Config.saves.autosave=undefined,Config.saves.slots=0,!1;Config.saves.slots=Math.max(0,Config.saves.slots),Number.isSafeInteger(Config.saves.slots)||(Config.saves.slots=8);var e=r(),t=!1;Array.isArray(e)&&(e={autosave:null,slots:e},t=!0),Config.saves.slots!==e.slots.length&&(Config.saves.slots<e.slots.length?(e.slots.reverse(),e.slots=e.slots.filter(function(e){return!(null===e&&this.count>0)||(--this.count,!1)},{count:e.slots.length-Config.saves.slots}),e.slots.reverse()):Config.saves.slots>e.slots.length&&x(e.slots,Config.saves.slots-e.slots.length),t=!0),T(e.autosave)&&(t=!0);for(var a=0;a<e.slots.length;++a)T(e.slots[a])&&(t=!0);return j(e)&&(storage.delete(\"saves\"),t=!1),t&&C(e),P=e.slots.length-1,!0}function t(){return{autosave:null,slots:x([],Config.saves.slots)}}function r(){var e=storage.get(\"saves\");return null===e?t():e}function n(){return storage.delete(\"saves\"),!0}function a(){return i()||d()}function i(){return\"cookie\"!==storage.name&&void 0!==Config.saves.autosave}function o(){return null!==r().autosave}function s(){return r().autosave}function u(){var e=r();return null!==e.autosave&&A(e.autosave)}function l(e,t){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return!1;var n=r(),a={title:e||Story.get(State.passage).description(),date:Date.now()};return null!=t&&(a.metadata=t),n.autosave=O(a),C(n)}function c(){var e=r();return e.autosave=null,C(e)}function d(){return\"cookie\"!==storage.name&&-1!==P}function f(){return P+1}function h(){if(!d())return 0;for(var e=r(),t=0,n=0,a=e.slots.length;n<a;++n)null!==e.slots[n]&&++t;return t}function p(){return 0===h()}function g(e){if(e<0||e>P)return!1;var t=r();return!(e>=t.slots.length||null===t.slots[e])}function m(e){if(e<0||e>P)return null;var t=r();return e>=t.slots.length?null:t.slots[e]}function v(e){if(e<0||e>P)return!1;var t=r();return!(e>=t.slots.length||null===t.slots[e])&&A(t.slots[e])}function y(e,t,n){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return Dialog.isOpen()?$(document).one(\":dialogclose\",function(){return UI.alert(L10n.get(\"savesDisallowed\"))}):UI.alert(L10n.get(\"savesDisallowed\")),!1;if(e<0||e>P)return!1;var a=r();if(e>=a.slots.length)return!1;var i={title:t||Story.get(State.passage).description(),date:Date.now()};return null!=n&&(i.metadata=n),a.slots[e]=O(i),C(a)}function b(e){if(e<0||e>P)return!1;var t=r();return!(e>=t.slots.length)&&(t.slots[e]=null,C(t))}function w(e,t){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return void(Dialog.isOpen()?$(document).one(\":dialogclose\",function(){return UI.alert(L10n.get(\"savesDisallowed\"))}):UI.alert(L10n.get(\"savesDisallowed\")));var r=null==e?Story.domId:Util.slugify(e),n=r+\"-\"+function(){var e=new Date,t=e.getMonth()+1,r=e.getDate(),n=e.getHours(),a=e.getMinutes(),i=e.getSeconds();return t<10&&(t=\"0\"+t),r<10&&(r=\"0\"+r),n<10&&(n=\"0\"+n),a<10&&(a=\"0\"+a),i<10&&(i=\"0\"+i),\"\"+e.getFullYear()+t+r+\"-\"+n+a+i}()+\".save\",a=null==t?{}:{metadata:t},i=LZString.compressToBase64(JSON.stringify(O(a)));saveAs(new Blob([i],{type:\"text/plain;charset=UTF-8\"}),n)}function k(e){var t=e.target.files[0],r=new FileReader;jQuery(r).on(\"load\",function(e){var r=e.currentTarget;if(r.result){var n=void 0;try{n=JSON.parse(/\\.json$/i.test(t.name)||/^\\{/.test(r.result)?r.result:LZString.decompressFromBase64(r.result))}catch(e){}A(n)}}),r.readAsText(t)}function S(e){if(\"function\"==typeof Config.saves.isAllowed&&!Config.saves.isAllowed())return Dialog.isOpen()?$(document).one(\":dialogclose\",function(){return UI.alert(L10n.get(\"savesDisallowed\"))}):UI.alert(L10n.get(\"savesDisallowed\")),null;var t=null==e?{}:{metadata:e};return LZString.compressToBase64(JSON.stringify(O(t)))}function E(e){var t=void 0;try{t=JSON.parse(LZString.decompressFromBase64(e))}catch(e){}return A(t)?t.metadata:null}function x(e,t){for(var r=0;r<t;++r)e.push(null);return e}function j(e){for(var t=e.slots,r=!0,n=0,a=t.length;n<a;++n)if(null!==t[n]){r=!1;break}return null===e.autosave&&r}function C(e){return j(e)?(storage.delete(\"saves\"),!0):storage.set(\"saves\",e)}function T(e){if(null==e||\"object\"!==(void 0===e?\"undefined\":_typeof(e)))return!1;var t=!1;return e.hasOwnProperty(\"state\")&&e.state.hasOwnProperty(\"delta\")&&e.state.hasOwnProperty(\"index\")||(e.hasOwnProperty(\"data\")?(delete e.mode,e.state={delta:State.deltaEncode(e.data)},delete e.data):e.state.hasOwnProperty(\"delta\")?e.state.hasOwnProperty(\"index\")||delete e.state.mode:(delete e.state.mode,e.state.delta=State.deltaEncode(e.state.history),delete e.state.history),e.state.index=e.state.delta.length-1,t=!0),e.state.hasOwnProperty(\"rseed\")&&(e.state.seed=e.state.rseed,delete e.state.rseed,e.state.delta.forEach(function(e,t,r){r[t].hasOwnProperty(\"rcount\")&&(r[t].pull=r[t].rcount,delete r[t].rcount)}),t=!0),(e.state.hasOwnProperty(\"expired\")&&\"number\"==typeof e.state.expired||e.state.hasOwnProperty(\"unique\")||e.state.hasOwnProperty(\"last\"))&&(e.state.hasOwnProperty(\"expired\")&&\"number\"==typeof e.state.expired&&delete e.state.expired,(e.state.hasOwnProperty(\"unique\")||e.state.hasOwnProperty(\"last\"))&&(e.state.expired=[],e.state.hasOwnProperty(\"unique\")&&(e.state.expired.push(e.state.unique),delete e.state.unique),e.state.hasOwnProperty(\"last\")&&(e.state.expired.push(e.state.last),delete e.state.last)),t=!0),t}function O(e){if(null!=e&&\"object\"!==(void 0===e?\"undefined\":_typeof(e)))throw new Error(\"supplemental parameter must be an object\");var t=Object.assign({},e,{id:Config.saves.id,state:State.marshalForSave()});return Config.saves.version&&(t.version=Config.saves.version),\"function\"==typeof Config.saves.onSave&&Config.saves.onSave(t),t.state.delta=State.deltaEncode(t.state.history),delete t.state.history,t}function A(e){try{if(T(e),!e||!e.hasOwnProperty(\"id\")||!e.hasOwnProperty(\"state\"))throw new Error(L10n.get(\"errorSaveMissingData\"));if(e.state.history=State.deltaDecode(e.state.delta),delete e.state.delta,\"function\"==typeof Config.saves.onLoad&&Config.saves.onLoad(e),e.id!==Config.saves.id)throw new Error(L10n.get(\"errorSaveIdMismatch\"));State.unmarshalForSave(e.state),Engine.show()}catch(e){return UI.alert(e.message.toUpperFirst()+\".</p><p>\"+L10n.get(\"aborting\")+\".\"),!1}return!0}var P=-1;return Object.freeze(Object.defineProperties({},{init:{value:e},get:{value:r},clear:{value:n},ok:{value:a},autosave:{value:Object.freeze(Object.defineProperties({},{ok:{value:i},has:{value:o},get:{value:s},load:{value:u},save:{value:l},delete:{value:c}}))},slots:{value:Object.freeze(Object.defineProperties({},{ok:{value:d},length:{get:f},isEmpty:{value:p},count:{value:h},has:{value:g},get:{value:m},load:{value:v},save:{value:y},delete:{value:b}}))},export:{value:w},import:{value:k},serialize:{value:S},deserialize:{value:E}}))}(),Setting=function(){function e(){if(storage.has(\"options\")){var e=storage.get(\"options\");null!==e&&(window.SugarCube.settings=settings=Object.assign(t(),e)),r(),storage.delete(\"options\")}n(),m.forEach(function(e){if(e.hasOwnProperty(\"onInit\")){var t={name:e.name,value:settings[e.name],default:e.default};e.hasOwnProperty(\"list\")&&(t.list=e.list),e.onInit.call(t)}})}function t(){return Object.create(null)}function r(){var e=t();return Object.keys(settings).length>0&&m.filter(function(e){return e.type!==v.Header&&settings[e.name]!==e.default}).forEach(function(t){return e[t.name]=settings[t.name]}),0===Object.keys(e).length?(storage.delete(\"settings\"),!0):storage.set(\"settings\",e)}function n(){var e=t(),r=storage.get(\"settings\")||t();m.filter(function(e){return e.type!==v.Header}).forEach(function(t){return e[t.name]=t.default}),window.SugarCube.settings=settings=Object.assign(e,r)}function a(){return window.SugarCube.settings=settings=t(),storage.delete(\"settings\"),!0}function i(e){if(0===arguments.length)a(),n();else{if(null==e||!h(e))throw new Error('nonexistent setting \"'+e+'\"');var t=p(e);t.type!==v.Header&&(settings[e]=t.default)}return r()}function o(e,t){m.forEach(e,t)}function s(e,t,r){if(arguments.length<3){var n=[];throw arguments.length<1&&n.push(\"type\"),arguments.length<2&&n.push(\"name\"),arguments.length<3&&n.push(\"definition\"),new Error(\"missing parameters, no \"+n.join(\" or \")+\" specified\")}if(\"object\"!==(void 0===r?\"undefined\":_typeof(r)))throw new TypeError(\"definition parameter must be an object\");if(h(t))throw new Error('cannot clobber existing setting \"'+t+'\"');var a={type:e,name:t,label:\"string\"==typeof r.label?r.label.trim():\"\"};if(\"string\"==typeof r.desc){var i=r.desc.trim();\"\"!==i&&(a.desc=i)}switch(e){case v.Header:break;case v.Toggle:a.default=!!r.default;break;case v.List:if(!r.hasOwnProperty(\"list\"))throw new Error(\"no list specified\");if(!Array.isArray(r.list))throw new TypeError(\"list must be an array\");if(0===r.list.length)throw new Error(\"list must not be empty\");if(a.list=Object.freeze(r.list),null==r.default)a.default=r.list[0];else{var o=r.list.indexOf(r.default);if(-1===o)throw new Error(\"list does not contain default\");a.default=r.list[o]}break;case v.Range:if(!r.hasOwnProperty(\"min\"))throw new Error(\"no min specified\");if(\"number\"!=typeof r.min||Number.isNaN(r.min)||!Number.isFinite(r.min))throw new TypeError(\"min must be a finite number\");if(!r.hasOwnProperty(\"max\"))throw new Error(\"no max specified\");if(\"number\"!=typeof r.max||Number.isNaN(r.max)||!Number.isFinite(r.max))throw new TypeError(\"max must be a finite number\");if(!r.hasOwnProperty(\"step\"))throw new Error(\"no step specified\");if(\"number\"!=typeof r.step||Number.isNaN(r.step)||!Number.isFinite(r.step)||r.step<=0)throw new TypeError(\"step must be a finite number greater than zero\");var s=function(){var e=String(r.step),t=e.lastIndexOf(\".\");return-1===t?0:e.length-t-1}();if(function(e){if(s>0){var t=Number(r.min+\"e\"+s),n=Number(r.step+\"e\"+s),a=Number(e+\"e\"+s)-t;return Number(a-a%n+t+\"e-\"+s)}var i=e-r.min;return i-i%r.step+r.min}(r.max)!==r.max)throw new RangeError(\"max (\"+r.max+\") is not a multiple of the step (\"+r.step+\") plus the min (\"+r.min+\")\");if(a.max=r.max,a.min=r.min,a.step=r.step,null==r.default)a.default=r.max;else{if(\"number\"!=typeof r.default||Number.isNaN(r.default)||!Number.isFinite(r.default))throw new TypeError(\"default must be a finite number\");if(r.default<r.min)throw new RangeError(\"default (\"+r.default+\") is less than min (\"+r.min+\")\");if(r.default>r.max)throw new RangeError(\"default (\"+r.default+\") is greater than max (\"+r.max+\")\");a.default=r.default}break;default:throw new Error(\"unknown Setting type: \"+e)}\"function\"==typeof r.onInit&&(a.onInit=Object.freeze(r.onInit)),\"function\"==typeof r.onChange&&(a.onChange=Object.freeze(r.onChange)),m.push(Object.freeze(a))}function u(e,t){s(v.Header,e,{desc:t})}function l(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];s.apply(undefined,[v.Toggle].concat(t))}function c(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];s.apply(undefined,[v.List].concat(t))}function d(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];s.apply(undefined,[v.Range].concat(t))}function f(){return 0===m.length}function h(e){return m.some(function(t){return t.name===e})}function p(e){return m.find(function(t){return t.name===e})}function g(e){h(e)&&delete settings[e];for(var t=0;t<m.length;++t)if(m[t].name===e){m.splice(t,1),g(e);break}}var m=[],v=Util.toEnum({Header:0,Toggle:1,List:2,Range:3});return Object.freeze(Object.defineProperties({},{Types:{value:v},init:{value:e},create:{value:t},save:{value:r},load:{value:n},clear:{value:a},reset:{value:i},forEach:{value:o},add:{value:s},addHeader:{value:u},addToggle:{value:l},addList:{value:c},addRange:{value:d},isEmpty:{value:f},has:{value:h},get:{value:p},delete:{value:g}}))}(),Story=function(){function e(){function e(e){if(e.tags.includesAny(n))throw new Error('starting passage \"'+e.title+'\" contains illegal tags; invalid: \"'+e.tags.filter(function(e){return n.includes(e)}).sort().join('\", \"')+'\"')}function t(e){if(a.includes(e.title)&&e.tags.includesAny(n))throw new Error('special passage \"'+e.title+'\" contains illegal tags; invalid: \"'+e.tags.filter(function(e){return n.includes(e)}).sort().join('\", \"')+'\"')}var n=[\"widget\"],a=[\"PassageDone\",\"PassageFooter\",\"PassageHeader\",\"PassageReady\",\"StoryAuthor\",\"StoryBanner\",\"StoryCaption\",\"StoryInit\",\"StoryMenu\",\"StoryShare\",\"StorySubtitle\"],i=jQuery(\"#store-area>tw-storydata\"),o=i.attr(\"startnode\")||\"\";Config.passages.start=null,Config.debug=/\\bdebug\\b/.test(i.attr(\"options\")),i.children(\"style\").each(function(e){d.push(new Passage(\"tw-user-style-\"+e,this))}),i.children(\"script\").each(function(e){f.push(new Passage(\"tw-user-script-\"+e,this))}),i.children('tw-passagedata:not([tags~=\"Twine.private\"],[tags~=\"annotation\"])').each(function(){var r=jQuery(this),n=r.attr(\"pid\")||\"\",a=new Passage(r.attr(\"name\"),this);n===o&&\"\"!==o?(Config.passages.start=a.title,e(a),c[a.title]=a):a.tags.includes(\"widget\")?h.push(a):(t(a),c[a.title]=a)}),g=i.attr(\"ifid\"),r(Util.unescape(\"{{STORY_NAME}}\")),Config.saves.id=Story.domId}function t(){!function(){var e=document.createElement(\"style\");new StyleWrapper(e).add(d.map(function(e){return e.text.trim()}).join(\"\\n\")),jQuery(e).appendTo(document.head).attr({id:\"style-story\",type:\"text/css\"})}();for(var e=0;e<f.length;++e)try{Scripting.evalJavaScript(f[e].text)}catch(t){console.error(t),Alert.error(f[e].title,\"object\"===(void 0===t?\"undefined\":_typeof(t))?t.message:t)}for(var t=0;t<h.length;++t)try{Wikifier.wikifyEval(h[t].processText())}catch(e){console.error(e),Alert.error(h[t].title,\"object\"===(void 0===e?\"undefined\":_typeof(e))?e.message:e)}}function r(e){if(null==e||\"\"===e)throw new Error(\"story title cannot be null or empty\");document.title=p=Util.unescape(e),m=Util.slugify(p)}function n(){return p}function a(){return m}function i(){return g}function o(e){var t=void 0===e?\"undefined\":_typeof(e);switch(t){case\"number\":case\"string\":return c.hasOwnProperty(String(e));case\"boolean\":case\"function\":t=\"a \"+t;break;case\"undefined\":break;default:t=null===e?\"null\":\"an \"+t}throw new TypeError(\"Story.has title parameter cannot be \"+t)}function s(e){var t=void 0===e?\"undefined\":_typeof(e);switch(t){case\"number\":case\"string\":var r=String(e);return c.hasOwnProperty(r)?c[r]:new Passage(r||\"(unknown)\");case\"boolean\":case\"function\":t=\"a \"+t;break;case\"undefined\":break;default:t=null===e?\"null\":\"an \"+t}throw new TypeError(\"Story.get title parameter cannot be \"+t)}function u(e,t){for(var r=arguments.length>2&&arguments[2]!==undefined?arguments[2]:\"title\",n=Object.keys(c),a=[],i=0;i<n.length;++i){var o=c[n[i]];if(o.hasOwnProperty(e))switch(_typeof(o[e])){case\"undefined\":break;case\"object\":o[e]instanceof Array&&o[e].some(function(e){return e==t})&&a.push(o);break;default:o[e]==t&&a.push(o)}}return a.sort(function(e,t){return e[r]==t[r]?0:e[r]<t[r]?-1:1}),a}function l(e){var t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:\"title\";if(\"function\"!=typeof e)throw new Error(\"Story.lookupWith filter parameter must be a function\");for(var r=Object.keys(c),n=[],a=0;a<r.length;++a){var i=c[r[a]];e(i)&&n.push(i)}return n.sort(function(e,r){return e[t]==r[t]?0:e[t]<r[t]?-1:1}),n}var c={},d=[],f=[],h=[],p=\"\",g=\"\",m=\"\";return Object.freeze(Object.defineProperties({},{passages:{value:c},styles:{value:d},scripts:{value:f},widgets:{value:h},load:{value:e},init:{value:t},title:{get:n},domId:{get:a},ifId:{get:i},has:{value:o},get:{value:s},lookup:{value:u},lookupWith:{value:l}}))}(),UI=function(){function e(e,t){var r=t,n=Config.debug,a=Config.cleanupWikifierOutput;Config.debug=!1,Config.cleanupWikifierOutput=!1;try{null==r&&(r=document.createElement(\"ul\"));var i=document.createDocumentFragment();new Wikifier(i,Story.get(e).processText().trim());var o=[].concat(_toConsumableArray(i.querySelectorAll(\".error\"))).map(function(e){return e.textContent.replace(errorPrologRegExp,\"\")});if(o.length>0)throw new Error(o.join(\"; \"));for(;i.hasChildNodes();){var s=i.firstChild;if(s.nodeType===Node.ELEMENT_NODE&&\"A\"===s.nodeName.toUpperCase()){var u=document.createElement(\"li\");r.appendChild(u),u.appendChild(s)}else i.removeChild(s)}}finally{Config.cleanupWikifierOutput=a,Config.debug=n}return r}function t(e){jQuery(Dialog.setup(\"Alert\",\"alert\")).append(\"<p>\"+e+'</p><ul class=\"buttons\"><li><button id=\"alert-ok\" class=\"ui-close\">'+L10n.get([\"alertOk\",\"ok\"])+\"</button></li></ul>\");for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];Dialog.open.apply(Dialog,r)}function r(){u(),Dialog.open.apply(Dialog,arguments)}function n(){l(),Dialog.open.apply(Dialog,arguments)}function a(){c(),Dialog.open.apply(Dialog,arguments)}function i(){d(),Dialog.open.apply(Dialog,arguments)}function o(){f(),Dialog.open.apply(Dialog,arguments)}function s(){return jQuery(Dialog.setup(L10n.get(\"autoloadTitle\"),\"autoload\")).append(\"<p>\"+L10n.get(\"autoloadPrompt\")+'</p><ul class=\"buttons\"><li><button id=\"autoload-ok\" class=\"ui-close\">'+L10n.get([\"autoloadOk\",\"ok\"])+'</button></li><li><button id=\"autoload-cancel\" class=\"ui-close\">'+L10n.get([\"autoloadCancel\",\"cancel\"])+\"</button></li></ul>\"),jQuery(document).one(\"click.autoload\",\".ui-close\",function(e){var t=\"autoload-ok\"===e.target.id;jQuery(document).one(\":dialogclose\",function(){t&&Save.autosave.load()||Engine.play(Config.passages.start)})}),!0}function u(){var e=document.createElement(\"ul\");jQuery(Dialog.setup(L10n.get(\"jumptoTitle\"),\"jumpto list\")).append(e);for(var t=State.expired.length,r=State.size-1;r>=0;--r)if(r!==State.activeIndex){var n=Story.get(State.history[r].title);n&&n.tags.includes(\"bookmark\")&&jQuery(document.createElement(\"li\")).append(jQuery(document.createElement(\"a\")).ariaClick({one:!0},function(e){return function(){return jQuery(document).one(\":dialogclose\",function(){return Engine.goTo(e)})}}(r)).addClass(\"ui-close\").text(L10n.get(\"jumptoTurn\")+\" \"+(t+r+1)+\": \"+n.description())).appendTo(e)}e.hasChildNodes()||jQuery(e).append(\"<li><a><em>\"+L10n.get(\"jumptoUnavailable\")+\"</em></a></li>\")}function l(){return jQuery(Dialog.setup(L10n.get(\"restartTitle\"),\"restart\")).append(\"<p>\"+L10n.get(\"restartPrompt\")+'</p><ul class=\"buttons\"><li><button id=\"restart-ok\">'+L10n.get([\"restartOk\",\"ok\"])+'</button></li><li><button id=\"restart-cancel\" class=\"ui-close\">'+L10n.get([\"restartCancel\",\"cancel\"])+\"</button></li></ul>\").find(\"#restart-ok\").ariaClick({one:!0},function(){jQuery(document).one(\":dialogclose\",function(){return Engine.restart()}),Dialog.close()}),!0}function c(){function e(e,t,r,n){var a=jQuery(document.createElement(\"button\")).attr(\"id\",\"saves-\"+e).html(r);return t&&a.addClass(t),n?a.ariaClick(n):a.ariaDisabled(!0),jQuery(document.createElement(\"li\")).append(a)}var r=jQuery(Dialog.setup(L10n.get(\"savesTitle\"),\"saves\")),n=Save.ok();if(n&&r.append(function(){function e(e,t,r,n,a){var i=jQuery(document.createElement(\"button\")).attr(\"id\",\"saves-\"+e+\"-\"+n).addClass(e).html(r);return t&&i.addClass(t),a?\"auto\"===n?i.ariaClick({label:r+\" \"+L10n.get(\"savesLabelAuto\")},function(){return a()}):i.ariaClick({label:r+\" \"+L10n.get(\"savesLabelSlot\")+\" \"+(n+1)},function(){return a(n)}):i.ariaDisabled(!0),i}var t=Save.get(),r=jQuery(document.createElement(\"tbody\"));if(Save.autosave.ok()){var n=jQuery(document.createElement(\"td\")),a=jQuery(document.createElement(\"td\")),i=jQuery(document.createElement(\"td\")),o=jQuery(document.createElement(\"td\"));jQuery(document.createElement(\"b\")).attr({title:L10n.get(\"savesLabelAuto\"),\"aria-label\":L10n.get(\"savesLabelAuto\")}).text(\"A\").appendTo(n),t.autosave?(a.append(e(\"load\",\"ui-close\",L10n.get(\"savesLabelLoad\"),\"auto\",function(){jQuery(document).one(\":dialogclose\",function(){return Save.autosave.load()})})),jQuery(document.createElement(\"div\")).text(t.autosave.title).appendTo(i),jQuery(document.createElement(\"div\")).addClass(\"datestamp\").html(t.autosave.date?\"\"+new Date(t.autosave.date).toLocaleString():\"<em>\"+L10n.get(\"savesUnknownDate\")+\"</em>\").appendTo(i),o.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),\"auto\",function(){Save.autosave.delete(),c()}))):(a.append(e(\"load\",null,L10n.get(\"savesLabelLoad\"),\"auto\")),i.addClass(\"empty\").text(\"•  •  •\"),o.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),\"auto\"))),jQuery(document.createElement(\"tr\")).append(n).append(a).append(i).append(o).appendTo(r)}for(var s=0,u=t.slots.length;s<u;++s){var l=jQuery(document.createElement(\"td\")),d=jQuery(document.createElement(\"td\")),f=jQuery(document.createElement(\"td\")),h=jQuery(document.createElement(\"td\"));l.append(document.createTextNode(s+1)),t.slots[s]?(d.append(e(\"save\",\"ui-close\",L10n.get(\"savesLabelSave\"),s,Save.slots.save),e(\"load\",\"ui-close\",L10n.get(\"savesLabelLoad\"),s,function(e){jQuery(document).one(\":dialogclose\",function(){return Save.slots.load(e)})})),jQuery(document.createElement(\"div\")).text(t.slots[s].title).appendTo(f),jQuery(document.createElement(\"div\")).addClass(\"datestamp\").html(t.slots[s].date?\"\"+new Date(t.slots[s].date).toLocaleString():\"<em>\"+L10n.get(\"savesUnknownDate\")+\"</em>\").appendTo(f),h.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),s,function(e){Save.slots.delete(e),c()}))):(d.append(e(\"save\",\"ui-close\",L10n.get(\"savesLabelSave\"),s,Save.slots.save)),f.addClass(\"empty\").text(\"•  •  •\"),h.append(e(\"delete\",null,L10n.get(\"savesLabelDelete\"),s))),jQuery(document.createElement(\"tr\")).append(l).append(d).append(f).append(h).appendTo(r)}return jQuery(document.createElement(\"table\")).attr(\"id\",\"saves-list\").append(r)}()),n||Has.fileAPI){var a=jQuery(document.createElement(\"ul\")).addClass(\"buttons\").appendTo(r);return Has.fileAPI&&(a.append(e(\"export\",\"ui-close\",L10n.get(\"savesLabelExport\"),function(){return Save.export()})),a.append(e(\"import\",null,L10n.get(\"savesLabelImport\"),function(){return r.find(\"#saves-import-file\").trigger(\"click\")})),jQuery(document.createElement(\"input\")).css({display:\"block\",visibility:\"hidden\",position:\"fixed\",left:\"-9999px\",top:\"-9999px\",width:\"1px\",height:\"1px\"}).attr({type:\"file\",id:\"saves-import-file\",tabindex:-1,\"aria-hidden\":!0}).on(\"change\",function(e){jQuery(document).one(\":dialogclose\",function(){return Save.import(e)}),Dialog.close()}).appendTo(r)),n&&a.append(e(\"clear\",null,L10n.get(\"savesLabelClear\"),Save.autosave.has()||!Save.slots.isEmpty()?function(){Save.clear(),c()}:null)),!0}return t(L10n.get(\"savesIncapable\")),!1}function d(){var e=jQuery(Dialog.setup(L10n.get(\"settingsTitle\"),\"settings\"));return Setting.forEach(function(t){if(t.type===Setting.Types.Header){var r=t.name,n=Util.slugify(r),a=jQuery(document.createElement(\"div\")),i=jQuery(document.createElement(\"h2\"));return a.attr(\"id\",\"header-body-\"+n).append(i).appendTo(e),i.attr(\"id\",\"header-heading-\"+n).wiki(r),void(t.desc&&jQuery(document.createElement(\"p\")).attr(\"id\",\"header-desc-\"+n).wiki(t.desc).appendTo(a))}var o=t.name,s=Util.slugify(o),u=jQuery(document.createElement(\"div\")),l=jQuery(document.createElement(\"label\")),c=jQuery(document.createElement(\"div\")),d=void 0;switch(jQuery(document.createElement(\"div\")).append(l).append(c).appendTo(u),t.desc&&jQuery(document.createElement(\"p\")).attr(\"id\",\"setting-desc-\"+s).wiki(t.desc).appendTo(u),l.attr({id:\"setting-label-\"+s,for:\"setting-control-\"+s}).wiki(t.label),null==settings[o]&&(settings[o]=t.default),t.type){case Setting.Types.Toggle:d=jQuery(document.createElement(\"button\")),settings[o]?d.addClass(\"enabled\").text(L10n.get(\"settingsOn\")):d.text(L10n.get(\"settingsOff\")),d.ariaClick(function(){settings[o]?(jQuery(this).removeClass(\"enabled\").text(L10n.get(\"settingsOff\")),settings[o]=!1):(jQuery(this).addClass(\"enabled\").text(L10n.get(\"settingsOn\")),settings[o]=!0),Setting.save(),t.hasOwnProperty(\"onChange\")&&t.onChange.call({name:o,value:settings[o],default:t.default})});break;case Setting.Types.List:d=jQuery(document.createElement(\"select\"));for(var f=0,h=t.list.length;f<h;++f)jQuery(document.createElement(\"option\")).val(f).text(t.list[f]).appendTo(d);d.val(t.list.indexOf(settings[o])).attr(\"tabindex\",0).on(\"change\",function(){settings[o]=t.list[Number(this.value)],Setting.save(),t.hasOwnProperty(\"onChange\")&&t.onChange.call({name:o,value:settings[o],default:t.default,list:t.list})});break;case Setting.Types.Range:d=jQuery(document.createElement(\"input\")),d.attr({type:\"range\",min:t.min,max:t.max,step:t.step,value:settings[o],tabindex:0}).on(\"change input\",function(){settings[o]=Number(this.value),Setting.save(),t.hasOwnProperty(\"onChange\")&&t.onChange.call({name:o,value:settings[o],default:t.default,min:t.min,max:t.max,step:t.step})}).on(\"keypress\",function(e){13===e.which&&(e.preventDefault(),d.trigger(\"change\"))})}d.attr(\"id\",\"setting-control-\"+s).appendTo(c),u.attr(\"id\",\"setting-body-\"+s).appendTo(e)}),e.append('<ul class=\"buttons\"><li><button id=\"settings-ok\" class=\"ui-close\">'+L10n.get([\"settingsOk\",\"ok\"])+'</button></li><li><button id=\"settings-reset\">'+L10n.get(\"settingsReset\")+\"</button></li></ul>\").find(\"#settings-reset\").ariaClick({one:!0},function(){jQuery(document).one(\":dialogclose\",function(){Setting.reset(),window.location.reload()}),Dialog.close()}),!0}function f(){try{jQuery(Dialog.setup(L10n.get(\"shareTitle\"),\"share list\")).append(e(\"StoryShare\"))}catch(e){return console.error(e),Alert.error(\"StoryShare\",e.message),!1}return!0}return Object.freeze(Object.defineProperties({},{assembleLinkList:{value:e},alert:{value:t},jumpto:{value:r},restart:{value:n},saves:{value:a},settings:{value:i},share:{value:o},buildAutoload:{value:s},buildJumpto:{value:u},buildRestart:{value:l},buildSaves:{value:c},buildSettings:{value:d},buildShare:{value:f},stow:{value:function(){return UIBar.stow()}},unstow:{value:function(){return UIBar.unstow()}},setStoryElements:{value:function(){return UIBar.setStoryElements()}},isOpen:{value:function(){return Dialog.isOpen.apply(Dialog,arguments)}},body:{value:function(){return Dialog.body()}},setup:{value:function(){return Dialog.setup.apply(Dialog,arguments)}},addClickHandler:{value:function(){return Dialog.addClickHandler.apply(Dialog,arguments)}},open:{value:function(){return Dialog.open.apply(Dialog,arguments)}},close:{value:function(){return Dialog.close.apply(Dialog,arguments)}},resize:{value:function(){return Dialog.resize()}},buildDialogAutoload:{value:s},buildDialogJumpto:{value:u},buildDialogRestart:{value:l},buildDialogSaves:{value:c},buildDialogSettings:{value:d},buildDialogShare:{value:f},buildLinkListFromPassage:{value:e}}))}(),UIBar=function(){function e(){o||document.getElementById(\"ui-bar\")||(!function(){var e=L10n.get(\"uiBarToggle\"),t=L10n.get(\"uiBarBackward\"),r=L10n.get(\"uiBarJumpto\"),n=L10n.get(\"uiBarForward\")\n;jQuery(document.createDocumentFragment()).append('<div id=\"ui-bar\"><div id=\"ui-bar-tray\"><button id=\"ui-bar-toggle\" tabindex=\"0\" title=\"'+e+'\" aria-label=\"'+e+'\"></button><div id=\"ui-bar-history\"><button id=\"history-backward\" tabindex=\"0\" title=\"'+t+'\" aria-label=\"'+t+'\"></button><button id=\"history-jumpto\" tabindex=\"0\" title=\"'+r+'\" aria-label=\"'+r+'\"></button><button id=\"history-forward\" tabindex=\"0\" title=\"'+n+'\" aria-label=\"'+n+'\"></button></div></div><div id=\"ui-bar-body\"><header id=\"title\" role=\"banner\"><div id=\"story-banner\"></div><h1 id=\"story-title\"></h1><div id=\"story-subtitle\"></div><div id=\"story-title-separator\"></div><p id=\"story-author\"></p></header><div id=\"story-caption\"></div><nav id=\"menu\" role=\"navigation\"><ul id=\"menu-story\"></ul><ul id=\"menu-core\"><li id=\"menu-item-saves\"><a tabindex=\"0\">'+L10n.get(\"savesTitle\")+'</a></li><li id=\"menu-item-settings\"><a tabindex=\"0\">'+L10n.get(\"settingsTitle\")+'</a></li><li id=\"menu-item-restart\"><a tabindex=\"0\">'+L10n.get(\"restartTitle\")+'</a></li><li id=\"menu-item-share\"><a tabindex=\"0\">'+L10n.get(\"shareTitle\")+\"</a></li></ul></nav></div></div>\").insertBefore(\"#store-area\")}(),jQuery(document).on(\":historyupdate.ui-bar\",function(e,t){return function(){e.ariaDisabled(State.length<2),t.ariaDisabled(State.length===State.size)}}(jQuery(\"#history-backward\"),jQuery(\"#history-forward\"))))}function t(){if(!o){var e=jQuery(\"#ui-bar\");(\"boolean\"==typeof Config.ui.stowBarInitially?Config.ui.stowBarInitially:jQuery(window).width()<=Config.ui.stowBarInitially)&&function(){var t=jQuery(e).add(\"#story\");t.addClass(\"no-transition\"),e.addClass(\"stowed\"),setTimeout(function(){return t.removeClass(\"no-transition\")},Engine.minDomActionDelay)}(),jQuery(\"#ui-bar-toggle\").ariaClick({label:L10n.get(\"uiBarToggle\")},function(){return e.toggleClass(\"stowed\")}),Config.history.controls?(jQuery(\"#history-backward\").ariaDisabled(State.length<2).ariaClick({label:L10n.get(\"uiBarBackward\")},function(){return Engine.backward()}),Story.lookup(\"tags\",\"bookmark\").length>0?jQuery(\"#history-jumpto\").ariaClick({label:L10n.get(\"uiBarJumpto\")},function(){return UI.jumpto()}):jQuery(\"#history-jumpto\").remove(),jQuery(\"#history-forward\").ariaDisabled(State.length===State.size).ariaClick({label:L10n.get(\"uiBarForward\")},function(){return Engine.forward()})):jQuery(\"#ui-bar-history\").remove(),jQuery(\"#story-title\").text(Story.title),Story.has(\"StoryCaption\")||jQuery(\"#story-caption\").remove(),Story.has(\"StoryMenu\")||jQuery(\"#menu-story\").remove(),Config.ui.updateStoryElements||i(),Dialog.addClickHandler(\"#menu-item-saves a\",null,UI.buildSaves).text(L10n.get(\"savesTitle\")),Setting.isEmpty()?jQuery(\"#menu-item-settings\").remove():Dialog.addClickHandler(\"#menu-item-settings a\",null,UI.buildSettings).text(L10n.get(\"settingsTitle\")),Dialog.addClickHandler(\"#menu-item-restart a\",null,UI.buildRestart).text(L10n.get(\"restartTitle\")),Story.has(\"StoryShare\")?Dialog.addClickHandler(\"#menu-item-share a\",null,UI.buildShare).text(L10n.get(\"shareTitle\")):jQuery(\"#menu-item-share\").remove()}}function r(){o||(jQuery(document).off(\".ui-bar\"),jQuery(\"#ui-bar\").remove(),jQuery(document.head).find(\"#style-ui-bar\").remove(),Config.ui.updateStoryElements=!1,o=!0)}function n(e){if(!o){var t=jQuery(\"#ui-bar\");e&&t.addClass(\"no-transition\"),t.addClass(\"stowed\"),e&&setTimeout(function(){return t.removeClass(\"no-transition\")},Engine.minDomActionDelay)}}function a(e){if(!o){var t=jQuery(\"#ui-bar\");e&&t.addClass(\"no-transition\"),t.removeClass(\"stowed\"),e&&setTimeout(function(){return t.removeClass(\"no-transition\")},Engine.minDomActionDelay)}}function i(){if(!o){setPageElement(\"story-banner\",\"StoryBanner\"),setPageElement(\"story-subtitle\",\"StorySubtitle\"),setPageElement(\"story-author\",\"StoryAuthor\"),setPageElement(\"story-caption\",\"StoryCaption\");var e=document.getElementById(\"menu-story\");if(null!==e&&(jQuery(e).empty(),Story.has(\"StoryMenu\")))try{UI.assembleLinkList(\"StoryMenu\",e)}catch(e){console.error(e),Alert.error(\"StoryMenu\",e.message)}}}var o=!1;return Object.freeze(Object.defineProperties({},{init:{value:e},start:{value:t},destroy:{value:r},stow:{value:n},unstow:{value:a},setStoryElements:{value:i}}))}(),DebugBar=function(){function e(){var e=L10n.get(\"debugBarToggle\"),t=L10n.get(\"debugBarAddWatch\"),o=L10n.get(\"debugBarWatchAll\"),u=L10n.get(\"debugBarWatchNone\"),c=L10n.get(\"debugBarWatchToggle\"),p=L10n.get(\"debugBarViewsToggle\");jQuery(document.createDocumentFragment()).append('<div id=\"debug-bar\"><div id=\"debug-bar-watch\" aria-hidden=\"true\" hidden=\"hidden\"><div>'+L10n.get(\"debugBarNoWatches\")+'</div>></div><div><button id=\"debug-bar-watch-toggle\" tabindex=\"0\" title=\"'+c+'\" aria-label=\"'+c+'\">'+L10n.get(\"debugBarLabelWatch\")+'</button><label id=\"debug-bar-watch-label\" for=\"debug-bar-watch-input\">'+L10n.get(\"debugBarLabelAdd\")+'</label><input id=\"debug-bar-watch-input\" name=\"debug-bar-watch-input\" type=\"text\" list=\"debug-bar-watch-list\" tabindex=\"0\"><datalist id=\"debug-bar-watch-list\" aria-hidden=\"true\" hidden=\"hidden\"></datalist><button id=\"debug-bar-watch-add\" tabindex=\"0\" title=\"'+t+'\" aria-label=\"'+t+'\"></button><button id=\"debug-bar-watch-all\" tabindex=\"0\" title=\"'+o+'\" aria-label=\"'+o+'\"></button><button id=\"debug-bar-watch-none\" tabindex=\"0\" title=\"'+u+'\" aria-label=\"'+u+'\"></button></div><div><button id=\"debug-bar-views-toggle\" tabindex=\"0\" title=\"'+p+'\" aria-label=\"'+p+'\">'+L10n.get(\"debugBarLabelViews\")+'</button><label id=\"debug-bar-turn-label\" for=\"debug-bar-turn-select\">'+L10n.get(\"debugBarLabelTurn\")+'</label><select id=\"debug-bar-turn-select\" tabindex=\"0\"></select></div><button id=\"debug-bar-toggle\" tabindex=\"0\" title=\"'+e+'\" aria-label=\"'+e+'\"></button></div><div id=\"debug-bar-hint\"></div>').appendTo(\"body\"),y=jQuery(\"#debug-bar\"),b=jQuery(y.find(\"#debug-bar-watch\").get(0)),w=jQuery(y.find(\"#debug-bar-watch-list\").get(0)),k=jQuery(y.find(\"#debug-bar-turn-select\").get(0));var g=jQuery(y.find(\"#debug-bar-toggle\").get(0)),m=jQuery(y.find(\"#debug-bar-watch-toggle\").get(0)),v=jQuery(y.find(\"#debug-bar-watch-input\").get(0)),E=jQuery(y.find(\"#debug-bar-watch-add\").get(0)),x=jQuery(y.find(\"#debug-bar-watch-all\").get(0)),j=jQuery(y.find(\"#debug-bar-watch-none\").get(0)),C=jQuery(y.find(\"#debug-bar-views-toggle\").get(0));g.ariaClick(function(){S?n():r(),S=!S,l()}),m.ariaClick(function(){b.attr(\"hidden\")?b.removeAttr(\"aria-hidden hidden\"):b.attr({\"aria-hidden\":!0,hidden:\"hidden\"}),l()}),v.on(\":addwatch\",function(){a(this.value.trim()),this.value=\"\"}).on(\"keypress\",function(e){13===e.which&&(e.preventDefault(),v.trigger(\":addwatch\"))}),E.ariaClick(function(){return v.trigger(\":addwatch\")}),x.ariaClick(i),j.ariaClick(s),k.on(\"change\",function(){Engine.goTo(Number(this.value))}),C.ariaClick(function(){DebugView.toggle(),l()}),jQuery(document).on(\":historyupdate.debug-bar\",h).on(\":passageend.debug-bar\",function(){d(),f()}).on(\":enginerestart.debug-bar\",function(){session.delete(\"debugState\")})}function t(){u(),c(),h(),d(),f()}function r(){y.css(\"right\",\"-\"+y.outerWidth()+\"px\"),l()}function n(){y.css(\"right\",0),l()}function a(e){g.test(e)&&(v.pushUnique(e),v.sort(),d(),f(),l())}function i(){Object.keys(State.variables).map(function(e){return v.pushUnique(\"$\"+e)}),Object.keys(State.temporary).map(function(e){return v.pushUnique(\"_\"+e)}),v.sort(),d(),f(),l()}function o(e){v.delete(e),d(),f(),l()}function s(){for(var e=v.length-1;e>=0;--e)v.pop();d(),f(),l()}function u(){if(session.has(\"debugState\")){var e=session.get(\"debugState\");S=e.stowed,v.push.apply(v,_toConsumableArray(e.watchList)),e.watchEnabled?b.removeAttr(\"aria-hidden hidden\"):b.attr({\"aria-hidden\":!0,hidden:\"hidden\"}),e.viewsEnabled?DebugView.enable():DebugView.disable()}}function l(){session.set(\"debugState\",{stowed:S,watchList:v,watchEnabled:!b.attr(\"hidden\"),viewsEnabled:DebugView.isEnabled()})}function c(){S?r():n()}function d(){if(0===v.length)return void b.empty().append(\"<div>\"+L10n.get(\"debugBarNoWatches\")+\"</div>\");for(var e=L10n.get(\"debugBarDeleteWatch\"),t=jQuery(document.createElement(\"table\")),r=jQuery(document.createElement(\"tbody\")),n=0,a=v.length;n<a;++n)!function(t,n){var a=v[t],i=a.slice(1),s=\"$\"===a[0]?State.variables:State.temporary,u=jQuery(document.createElement(\"tr\")),l=jQuery(document.createElement(\"button\")),c=jQuery(document.createElement(\"code\"));l.addClass(\"watch-delete\").attr(\"data-name\",a).ariaClick({one:!0,label:e},function(){return o(a)}),c.text(p(s[i])),jQuery(document.createElement(\"td\")).append(l).appendTo(u),jQuery(document.createElement(\"td\")).text(a).appendTo(u),jQuery(document.createElement(\"td\")).append(c).appendTo(u),u.appendTo(r)}(n);t.append(r),b.empty().append(t)}function f(){var e=Object.keys(State.variables),t=Object.keys(State.temporary);if(0===e.length&&0===t.length)return void w.empty();var r=[].concat(_toConsumableArray(e.map(function(e){return\"$\"+e})),_toConsumableArray(t.map(function(e){return\"_\"+e}))).sort(),n=document.createDocumentFragment();r.delete(v);for(var a=0,i=r.length;a<i;++a)jQuery(document.createElement(\"option\")).val(r[a]).appendTo(n);w.empty().append(n)}function h(){for(var e=State.size,t=State.expired.length,r=document.createDocumentFragment(),n=0;n<e;++n)jQuery(document.createElement(\"option\")).val(n).text(t+n+1+\". \"+Util.escape(State.history[n].title)).appendTo(r);k.empty().ariaDisabled(e<2).append(r).val(State.activeIndex)}function p(e){if(null===e)return\"null\";switch(void 0===e?\"undefined\":_typeof(e)){case\"number\":if(Number.isNaN(e))return\"NaN\";if(!Number.isFinite(e))return\"Infinity\";case\"boolean\":case\"symbol\":case\"undefined\":return String(e);case\"string\":return JSON.stringify(e);case\"function\":return\"Function\"}var t=Util.toStringTag(e);if(\"Date\"===t)return\"Date {\"+e.toLocaleString()+\"}\";if(\"RegExp\"===t)return\"RegExp \"+e.toString();var r=[];if(e instanceof Array||e instanceof Set){for(var n=e instanceof Array?e:Array.from(e),a=0,i=n.length;a<i;++a)r.push(n.hasOwnProperty(a)?p(n[a]):\"<empty>\");return Object.keys(n).filter(function(e){return!m.test(e)}).forEach(function(e){return r.push(p(e)+\": \"+p(n[e]))}),t+\"(\"+n.length+\") [\"+r.join(\", \")+\"]\"}return e instanceof Map?(e.forEach(function(e,t){return r.push(p(t)+\" → \"+p(e))}),t+\"(\"+e.size+\") {\"+r.join(\", \")+\"}\"):(Object.keys(e).forEach(function(t){return r.push(p(t)+\": \"+p(e[t]))}),t+\" {\"+r.join(\", \")+\"}\")}var g=new RegExp(\"^\"+Patterns.variable+\"$\"),m=/^\\d+$/,v=[],y=null,b=null,w=null,k=null,S=!0;return Object.freeze(Object.defineProperties({},{init:{value:e},start:{value:t},stow:{value:r},unstow:{value:n},watch:{value:a},watchAll:{value:i},unwatch:{value:o},unwatchAll:{value:s}}))}(),LoadScreen=function(){function e(){jQuery(document).on(\"readystatechange.SugarCube\",function(){o.size>0||(\"complete\"===document.readyState?\"loading\"===jQuery(document.documentElement).attr(\"data-init\")&&(Config.loadDelay>0?setTimeout(function(){0===o.size&&r()},Math.max(Engine.minDomActionDelay,Config.loadDelay)):r()):n())})}function t(){jQuery(document).off(\"readystatechange.SugarCube\"),o.clear(),r()}function r(){jQuery(document.documentElement).removeAttr(\"data-init\")}function n(){jQuery(document.documentElement).attr(\"data-init\",\"loading\")}function a(){return++s,o.add(s),n(),s}function i(e){if(null==e)throw new Error(\"LoadScreen.unlock called with a null or undefined ID\");o.has(e)&&o.delete(e),0===o.size&&jQuery(document).trigger(\"readystatechange\")}var o=new Set,s=0;return Object.freeze(Object.defineProperties({},{init:{value:e},clear:{value:t},hide:{value:r},show:{value:n},lock:{value:a},unlock:{value:i}}))}(),version=Object.freeze({title:\"SugarCube\",major:2,minor:28,patch:2,prerelease:null,build:3,date:new Date(\"2019-01-29T02:24:12.265Z\"),extensions:{},toString:function(){var e=this.prerelease?\"-\"+this.prerelease:\"\";return this.major+\".\"+this.minor+\".\"+this.patch+e+\"+\"+this.build},short:function(){var e=this.prerelease?\"-\"+this.prerelease:\"\";return this.title+\" (v\"+this.major+\".\"+this.minor+\".\"+this.patch+e+\")\"},long:function(){return this.title+\" v\"+this.toString()+\" (\"+this.date.toUTCString()+\")\"}}),TempState={},macros={},postdisplay={},postrender={},predisplay={},prehistory={},prerender={},session=null,settings={},setup={},storage=null,browser=Browser,config=Config,has=Has,History=State,state=State,tale=Story,TempVariables=State.temporary;window.SugarCube={},jQuery(function(){try{var e=LoadScreen.lock();LoadScreen.init(),document.normalize&&document.normalize(),Story.load(),storage=SimpleStore.create(Story.domId,!0),session=SimpleStore.create(Story.domId,!1),Dialog.init(),UIBar.init(),Engine.init(),Story.init(),L10n.init(),session.has(\"rcWarn\")||\"cookie\"!==storage.name||(session.set(\"rcWarn\",1),window.alert(L10n.get(\"warningNoWebStorage\"))),Save.init(),Setting.init(),Macro.init(),Engine.start(),Config.debug&&DebugBar.init();var t=$(window),r=setInterval(function(){t.width()&&(clearInterval(r),setTimeout(function(){UIBar.start(),Config.debug&&DebugBar.start(),LoadScreen.unlock(e)},Engine.minDomActionDelay))},Engine.minDomActionDelay);window.SugarCube={Browser:Browser,Config:Config,Dialog:Dialog,Engine:Engine,Has:Has,L10n:L10n,Macro:Macro,Passage:Passage,Save:Save,Scripting:Scripting,Setting:Setting,SimpleAudio:SimpleAudio,State:State,Story:Story,UI:UI,UIBar:UIBar,DebugBar:DebugBar,Util:Util,Visibility:Visibility,Wikifier:Wikifier,session:session,settings:settings,setup:setup,storage:storage,version:version}}catch(e){return console.error(e),LoadScreen.clear(),Alert.fatal(null,e.message,e)}})}(window,window.document,jQuery);}\n\t</script>\n</body>\n</html>\n"});
\ No newline at end of file
diff --git a/devTools/tweeGo/storyFormats/sugarcube-2/format.js b/devTools/tweeGo/storyFormats/sugarcube-2/format.js
new file mode 120000
index 00000000000..3e99d51073a
--- /dev/null
+++ b/devTools/tweeGo/storyFormats/sugarcube-2/format.js
@@ -0,0 +1 @@
+../../../../devNotes/sugarcube stuff/2.29.0-format.js
\ No newline at end of file
-- 
GitLab