text: window.JSON||(window.JSON={}),function(){function f(e){return 10>e?"0"+e:e}function quote(e){return escapable.lastIndex=0,escapable.test(e)?'"'+e.replace(escapable,function(e){var t=meta[e];return"string"==typeof t?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}function str(e,t){var n,i,r,o,a,s=gap,l=t[e];switch(l&&"object"==typeof l&&"function"==typeof l.toJSON&&(l=l.toJSON(e)),"function"==typeof rep&&(l=rep.call(t,e,l)),typeof l){case"string":return quote(l);case"number":return isFinite(l)?l+"":"null";case"boolean":case"null":return l+"";case"object":if(!l)return"null";if(gap+=indent,a=[],"[object Array]"===Object.prototype.toString.apply(l)){for(o=l.length,n=0;o>n;n+=1)a[n]=str(n,l)||"null";return r=0===a.length?"[]":gap?"[\n"+gap+a.join(",\n"+gap)+"\n"+s+"]":"["+a.join(",")+"]",gap=s,r}if(rep&&"object"==typeof rep)for(o=rep.length,n=0;o>n;n+=1)i=rep[n],"string"==typeof i&&(r=str(i,l),r&&a.push(quote(i)+(gap?": ":":")+r));else for(i in l)Object.hasOwnProperty.call(l,i)&&(r=str(i,l),r&&a.push(quote(i)+(gap?": ":":")+r));return r=0===a.length?"{}":gap?"{\n"+gap+a.join(",\n"+gap)+"\n"+s+"}":"{"+a.join(",")+"}",gap=s,r}}"function"!=typeof Date.prototype.toJSON&&(Date.prototype.toJSON=function(){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()});var JSON=window.JSON,cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,gap,indent,meta={"\b":"\\b","	":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},rep;"function"!=typeof JSON.stringify&&(JSON.stringify=function(e,t,n){var i;if(gap="",indent="","number"==typeof n)for(i=0;n>i;i+=1)indent+=" ";else"string"==typeof n&&(indent=n);if(rep=t,!t||"function"==typeof t||"object"==typeof t&&"number"==typeof t.length)return str("",{"":e});throw Error("JSON.stringify")}),"function"!=typeof JSON.parse&&(JSON.parse=function(text,reviver){function walk(e,t){var n,i,r=e[t];if(r&&"object"==typeof r)for(n in r)Object.hasOwnProperty.call(r,n)&&(i=walk(r,n),void 0!==i?r[n]=i:delete r[n]);return reviver.call(e,t,r)}var j;if(text+="",cx.lastIndex=0,cx.test(text)&&(text=text.replace(cx,function(e){return"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})),/^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return j=eval("("+text+")"),"function"==typeof reviver?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}(),function(e,t){"use strict";var n=e.History=e.History||{};if(n.Adapter!==void 0)throw Error("History.js Adapter has already been loaded...");n.Adapter={handlers:{},_uid:1,uid:function(e){return e._uid||(e._uid=n.Adapter._uid++)},bind:function(e,t,i){var r=n.Adapter.uid(e);n.Adapter.handlers[r]=n.Adapter.handlers[r]||{},n.Adapter.handlers[r][t]=n.Adapter.handlers[r][t]||[],n.Adapter.handlers[r][t].push(i),e["on"+t]=function(e,t){return function(i){n.Adapter.trigger(e,t,i)}}(e,t)},trigger:function(e,t,i){i=i||{};var r,o,a=n.Adapter.uid(e);for(n.Adapter.handlers[a]=n.Adapter.handlers[a]||{},n.Adapter.handlers[a][t]=n.Adapter.handlers[a][t]||[],r=0,o=n.Adapter.handlers[a][t].length;o>r;++r)n.Adapter.handlers[a][t][r].apply(this,[i])},extractEventData:function(e,n){var i=n&&n[e]||t;return i},onDomLoad:function(t){var n=e.setTimeout(function(){t()},2e3);e.onload=function(){clearTimeout(n),t()}}},n.init!==void 0&&n.init()}(window),function(e){"use strict";var t=e.document,n=e.setTimeout||n,i=e.clearTimeout||i,r=e.setInterval||r,o=e.History=e.History||{};if(o.initHtml4!==void 0)throw Error("History.js HTML4 Support has already been loaded...");o.initHtml4=function(){return o.initHtml4.initialized!==void 0?!1:(o.initHtml4.initialized=!0,o.enabled=!0,o.savedHashes=[],o.isLastHash=function(e){var t,n=o.getHashByIndex();return t=e===n},o.saveHash=function(e){return o.isLastHash(e)?!1:(o.savedHashes.push(e),!0)},o.getHashByIndex=function(e){var t=null;return t=e===void 0?o.savedHashes[o.savedHashes.length-1]:0>e?o.savedHashes[o.savedHashes.length+e]:o.savedHashes[e]},o.discardedHashes={},o.discardedStates={},o.discardState=function(e,t,n){var i,r=o.getHashByState(e);return i={discardedState:e,backState:n,forwardState:t},o.discardedStates[r]=i,!0},o.discardHash=function(e,t,n){var i={discardedHash:e,backState:n,forwardState:t};return o.discardedHashes[e]=i,!0},o.discardedState=function(e){var t,n=o.getHashByState(e);return t=o.discardedStates[n]||!1},o.discardedHash=function(e){var t=o.discardedHashes[e]||!1;return t},o.recycleState=function(e){var t=o.getHashByState(e);return o.discardedState(e)&&delete o.discardedStates[t],!0},o.emulated.hashChange&&(o.hashChangeInit=function(){o.checkerFunction=null;var n,i,a,s,l="";return o.isInternetExplorer()?(n="historyjs-iframe",i=t.createElement("iframe"),i.setAttribute("id",n),i.style.display="none",t.body.appendChild(i),i.contentWindow.document.open(),i.contentWindow.document.close(),a="",s=!1,o.checkerFunction=function(){if(s)return!1;s=!0;var t=o.getHash()||"",n=o.unescapeHash(i.contentWindow.document.location.hash)||"";return t!==l?(l=t,n!==t&&(a=n=t,i.contentWindow.document.open(),i.contentWindow.document.close(),i.contentWindow.document.location.hash=o.escapeHash(t)),o.Adapter.trigger(e,"hashchange")):n!==a&&(a=n,o.setHash(n,!1)),s=!1,!0}):o.checkerFunction=function(){var t=o.getHash();return t!==l&&(l=t,o.Adapter.trigger(e,"hashchange")),!0},o.intervalList.push(r(o.checkerFunction,o.options.hashChangeInterval)),!0},o.Adapter.onDomLoad(o.hashChangeInit)),o.emulated.pushState&&(o.onHashChange=function(n){var i,r=n&&n.newURL||t.location.href,a=o.getHashByUrl(r),s=null,l=null;return o.isLastHash(a)?(o.busy(!1),!1):(o.doubleCheckComplete(),o.saveHash(a),a&&o.isTraditionalAnchor(a)?(o.Adapter.trigger(e,"anchorchange"),o.busy(!1),!1):(s=o.extractState(o.getFullUrl(a||t.location.href,!1),!0),o.isLastSavedState(s)?(o.busy(!1),!1):(l=o.getHashByState(s),i=o.discardedState(s),i?(o.getHashByIndex(-2)===o.getHashByState(i.forwardState)?o.back(!1):o.forward(!1),!1):(o.pushState(s.data,s.title,s.url,!1),!0))))},o.Adapter.bind(e,"hashchange",o.onHashChange),o.pushState=function(n,i,r,a){if(o.getHashByUrl(r))throw Error("History.js does not support states with fragement-identifiers (hashes/anchors).");if(a!==!1&&o.busy())return o.pushQueue({scope:o,callback:o.pushState,args:arguments,queue:a}),!1;o.busy(!0);var s=o.createStateObject(n,i,r),l=o.getHashByState(s),c=o.getState(!1),u=o.getHashByState(c),d=o.getHash();return o.storeState(s),o.expectedStateId=s.id,o.recycleState(s),o.setTitle(s),l===u?(o.busy(!1),!1):l!==d&&l!==o.getShortUrl(t.location.href)?(o.setHash(l,!1),!1):(o.saveState(s),o.Adapter.trigger(e,"statechange"),o.busy(!1),!0)},o.replaceState=function(e,t,n,i){if(o.getHashByUrl(n))throw Error("History.js does not support states with fragement-identifiers (hashes/anchors).");if(i!==!1&&o.busy())return o.pushQueue({scope:o,callback:o.replaceState,args:arguments,queue:i}),!1;o.busy(!0);var r=o.createStateObject(e,t,n),a=o.getState(!1),s=o.getStateByIndex(-2);return o.discardState(a,r,s),o.pushState(r.data,r.title,r.url,!1),!0}),o.emulated.pushState&&o.getHash()&&!o.emulated.hashChange&&o.Adapter.onDomLoad(function(){o.Adapter.trigger(e,"hashchange")}),void 0)},o.init!==void 0&&o.init()}(window),function(e,t){"use strict";var n=e.console||t,i=e.document,r=e.navigator,o=e.sessionStorage||!1,a=e.setTimeout,s=e.clearTimeout,l=e.setInterval,c=e.clearInterval,u=e.JSON,d=e.alert,h=e.History=e.History||{},p=e.history;if(u.stringify=u.stringify||u.encode,u.parse=u.parse||u.decode,h.init!==void 0)throw Error("History.js Core has already been loaded...");h.init=function(){return h.Adapter===void 0?!1:(h.initCore!==void 0&&h.initCore(),h.initHtml4!==void 0&&h.initHtml4(),!0)},h.initCore=function(){if(h.initCore.initialized!==void 0)return!1;if(h.initCore.initialized=!0,h.options=h.options||{},h.options.hashChangeInterval=h.options.hashChangeInterval||100,h.options.safariPollInterval=h.options.safariPollInterval||500,h.options.doubleCheckInterval=h.options.doubleCheckInterval||500,h.options.storeInterval=h.options.storeInterval||1e3,h.options.busyDelay=h.options.busyDelay||250,h.options.debug=h.options.debug||!1,h.options.initialTitle=h.options.initialTitle||i.title,h.intervalList=[],h.clearAllIntervals=function(){var e,t=h.intervalList;if(t!==void 0&&null!==t){for(e=0;t.length>e;e++)c(t[e]);h.intervalList=null}},h.debug=function(){(h.options.debug||!1)&&h.log.apply(h,arguments)},h.log=function(){var e,t,r,o,a,s=n!==void 0&&n.log!==void 0&&n.log.apply!==void 0,l=i.getElementById("log");for(s?(o=Array.prototype.slice.call(arguments),e=o.shift(),n.debug!==void 0?n.debug.apply(n,[e,o]):n.log.apply(n,[e,o])):e="\n"+arguments[0]+"\n",t=1,r=arguments.length;r>t;++t){if(a=arguments[t],"object"==typeof a&&u!==void 0)try{a=u.stringify(a)}catch(c){}e+="\n"+a+"\n"}return l?(l.value+=e+"\n-----\n",l.scrollTop=l.scrollHeight-l.clientHeight):s||d(e),!0},h.getInternetExplorerMajorVersion=function(){var e=h.getInternetExplorerMajorVersion.cached=h.getInternetExplorerMajorVersion.cached!==void 0?h.getInternetExplorerMajorVersion.cached:function(){for(var e=3,t=i.createElement("div"),n=t.getElementsByTagName("i");(t.innerHTML="<!--[if gt IE "+ ++e+"]><i></i><![endif]-->")&&n[0];);return e>4?e:!1}();return e},h.isInternetExplorer=function(){var e=h.isInternetExplorer.cached=h.isInternetExplorer.cached!==void 0?h.isInternetExplorer.cached:Boolean(h.getInternetExplorerMajorVersion());return e},h.emulated={pushState:!Boolean(e.history&&e.history.pushState&&e.history.replaceState&&!/ Mobile\/([1-7][a-z]|(8([abcde]|f(1[0-8]))))/i.test(r.userAgent)&&!/AppleWebKit\/5([0-2]|3[0-2])/i.test(r.userAgent)),hashChange:Boolean(!("onhashchange"in e||"onhashchange"in i)||h.isInternetExplorer()&&8>h.getInternetExplorerMajorVersion())},h.enabled=!h.emulated.pushState,h.bugs={setHash:Boolean(!h.emulated.pushState&&"Apple Computer, Inc."===r.vendor&&/AppleWebKit\/5([0-2]|3[0-3])/.test(r.userAgent)),safariPoll:Boolean(!h.emulated.pushState&&"Apple Computer, Inc."===r.vendor&&/AppleWebKit\/5([0-2]|3[0-3])/.test(r.userAgent)),ieDoubleCheck:Boolean(h.isInternetExplorer()&&8>h.getInternetExplorerMajorVersion()),hashEscape:Boolean(h.isInternetExplorer()&&7>h.getInternetExplorerMajorVersion())},h.isEmptyObject=function(e){for(var t in e)return!1;return!0},h.cloneObject=function(e){var t,n;return e?(t=u.stringify(e),n=u.parse(t)):n={},n},h.getRootUrl=function(){var e=i.location.protocol+"//"+(i.location.hostname||i.location.host);return i.location.port&&(e+=":"+i.location.port),e+="/"},h.getBaseHref=function(){var e=i.getElementsByTagName("base"),t=null,n="";return 1===e.length&&(t=e[0],n=t.href.replace(/[^\/]+$/,"")),n=n.replace(/\/+$/,""),n&&(n+="/"),n},h.getBaseUrl=function(){var e=h.getBaseHref()||h.getBasePageUrl()||h.getRootUrl();return e},h.getPageUrl=function(){var e,t=h.getState(!1,!1),n=(t||{}).url||i.location.href;return e=n.replace(/\/+$/,"").replace(/[^\/]+$/,function(e){return/\./.test(e)?e:e+"/"})},h.getBasePageUrl=function(){var e=i.location.href.replace(/[#\?].*/,"").replace(/[^\/]+$/,function(e){return/[^\/]$/.test(e)?"":e}).replace(/\/+$/,"")+"/";return e},h.getFullUrl=function(e,t){var n=e,i=e.substring(0,1);return t=t===void 0?!0:t,/[a-z]+\:\/\//.test(e)||(n="/"===i?h.getRootUrl()+e.replace(/^\/+/,""):"#"===i?h.getPageUrl().replace(/#.*/,"")+e:"?"===i?h.getPageUrl().replace(/[\?#].*/,"")+e:t?h.getBaseUrl()+e.replace(/^(\.\/)+/,""):h.getBasePageUrl()+e.replace(/^(\.\/)+/,"")),n.replace(/\#$/,"")},h.getShortUrl=function(e){var t=e,n=h.getBaseUrl(),i=h.getRootUrl();return h.emulated.pushState&&(t=t.replace(n,"")),t=t.replace(i,"/"),h.isTraditionalAnchor(t)&&(t="./"+t),t=t.replace(/^(\.\/)+/g,"./").replace(/\#$/,"")},h.store={},h.idToState=h.idToState||{},h.stateToId=h.stateToId||{},h.urlToId=h.urlToId||{},h.storedStates=h.storedStates||[],h.savedStates=h.savedStates||[],h.normalizeStore=function(){h.store.idToState=h.store.idToState||{},h.store.urlToId=h.store.urlToId||{},h.store.stateToId=h.store.stateToId||{}},h.getState=function(e,t){e===void 0&&(e=!0),t===void 0&&(t=!0);var n=h.getLastSavedState();return!n&&t&&(n=h.createStateObject()),e&&(n=h.cloneObject(n),n.url=n.cleanUrl||n.url),n},h.getIdByState=function(e){var t,n=h.extractId(e.url);if(!n)if(t=h.getStateString(e),h.stateToId[t]!==void 0)n=h.stateToId[t];else if(h.store.stateToId[t]!==void 0)n=h.store.stateToId[t];else{for(;n=(new Date).getTime()+(Math.random()+"").replace(/\D/g,""),h.idToState[n]!==void 0||h.store.idToState[n]!==void 0;);h.stateToId[t]=n,h.idToState[n]=e}return n},h.normalizeState=function(e){var t,n;return e&&"object"==typeof e||(e={}),e.normalized!==void 0?e:(e.data&&"object"==typeof e.data||(e.data={}),t={},t.normalized=!0,t.title=e.title||"",t.url=h.getFullUrl(h.unescapeString(e.url||i.location.href)),t.hash=h.getShortUrl(t.url),t.data=h.cloneObject(e.data),t.id=h.getIdByState(t),t.cleanUrl=t.url.replace(/\??\&_suid.*/,""),t.url=t.cleanUrl,n=!h.isEmptyObject(t.data),(t.title||n)&&(t.hash=h.getShortUrl(t.url).replace(/\??\&_suid.*/,""),/\?/.test(t.hash)||(t.hash+="?"),t.hash+="&_suid="+t.id),t.hashedUrl=h.getFullUrl(t.hash),(h.emulated.pushState||h.bugs.safariPoll)&&h.hasUrlDuplicate(t)&&(t.url=t.hashedUrl),t)},h.createStateObject=function(e,t,n){var i={data:e,title:t,url:n};return i=h.normalizeState(i)},h.getStateById=function(e){e+="";var n=h.idToState[e]||h.store.idToState[e]||t;return n},h.getStateString=function(e){var t,n,i;return t=h.normalizeState(e),n={data:t.data,title:e.title,url:e.url},i=u.stringify(n)},h.getStateId=function(e){var t,n;return t=h.normalizeState(e),n=t.id},h.getHashByState=function(e){var t,n;return t=h.normalizeState(e),n=t.hash},h.extractId=function(e){var t,n,i;return n=/(.*)\&_suid=([0-9]+)$/.exec(e),i=n?n[1]||e:e,t=n?(n[2]||"")+"":"",t||!1},h.isTraditionalAnchor=function(e){var t=!/[\/\?\.]/.test(e);return t},h.extractState=function(e,t){var n,i,r=null;return t=t||!1,n=h.extractId(e),n&&(r=h.getStateById(n)),r||(i=h.getFullUrl(e),n=h.getIdByUrl(i)||!1,n&&(r=h.getStateById(n)),!r&&t&&!h.isTraditionalAnchor(e)&&(r=h.createStateObject(null,null,i))),r},h.getIdByUrl=function(e){var n=h.urlToId[e]||h.store.urlToId[e]||t;return n},h.getLastSavedState=function(){return h.savedStates[h.savedStates.length-1]||t},h.getLastStoredState=function(){return h.storedStates[h.storedStates.length-1]||t},h.hasUrlDuplicate=function(e){var t,n=!1;return t=h.extractState(e.url),n=t&&t.id!==e.id},h.storeState=function(e){return h.urlToId[e.url]=e.id,h.storedStates.push(h.cloneObject(e)),e},h.isLastSavedState=function(e){var t,n,i,r=!1;return h.savedStates.length&&(t=e.id,n=h.getLastSavedState(),i=n.id,r=t===i),r},h.saveState=function(e){return h.isLastSavedState(e)?!1:(h.savedStates.push(h.cloneObject(e)),!0)},h.getStateByIndex=function(e){var t=null;return t=e===void 0?h.savedStates[h.savedStates.length-1]:0>e?h.savedStates[h.savedStates.length+e]:h.savedStates[e]},h.getHash=function(){var e=h.unescapeHash(i.location.hash);return e},h.unescapeString=function(t){for(var n,i=t;n=e.unescape(i),n!==i;)i=n;return i},h.unescapeHash=function(e){var t=h.normalizeHash(e);return t=h.unescapeString(t)},h.normalizeHash=function(e){var t=e.replace(/[^#]*#/,"").replace(/#.*/,"");return t},h.setHash=function(e,t){var n,r,o;return t!==!1&&h.busy()?(h.pushQueue({scope:h,callback:h.setHash,args:arguments,queue:t}),!1):(n=h.escapeHash(e),h.busy(!0),r=h.extractState(e,!0),r&&!h.emulated.pushState?h.pushState(r.data,r.title,r.url,!1):i.location.hash!==n&&(h.bugs.setHash?(o=h.getPageUrl(),h.pushState(null,null,o+"#"+n,!1)):i.location.hash=n),h)},h.escapeHash=function(t){var n=h.normalizeHash(t);return n=e.escape(n),h.bugs.hashEscape||(n=n.replace(/\%21/g,"!").replace(/\%26/g,"&").replace(/\%3D/g,"=").replace(/\%3F/g,"?")),n},h.getHashByUrl=function(e){var t=(e+"").replace(/([^#]*)#?([^#]*)#?(.*)/,"$2");return t=h.unescapeHash(t)},h.setTitle=function(e){var t,n=e.title;n||(t=h.getStateByIndex(0),t&&t.url===e.url&&(n=t.title||h.options.initialTitle));try{i.getElementsByTagName("title")[0].innerHTML=n.replace("<","&lt;").replace(">","&gt;").replace(" & "," &amp; ")}catch(r){}return i.title=n,h},h.queues=[],h.busy=function(e){if(e!==void 0?h.busy.flag=e:h.busy.flag===void 0&&(h.busy.flag=!1),!h.busy.flag){s(h.busy.timeout);var t=function(){var e,n,i;if(!h.busy.flag)for(e=h.queues.length-1;e>=0;--e)n=h.queues[e],0!==n.length&&(i=n.shift(),h.fireQueueItem(i),h.busy.timeout=a(t,h.options.busyDelay))};h.busy.timeout=a(t,h.options.busyDelay)}return h.busy.flag},h.busy.flag=!1,h.fireQueueItem=function(e){return e.callback.apply(e.scope||h,e.args||[])},h.pushQueue=function(e){return h.queues[e.queue||0]=h.queues[e.queue||0]||[],h.queues[e.queue||0].push(e),h},h.queue=function(e,t){return"function"==typeof e&&(e={callback:e}),t!==void 0&&(e.queue=t),h.busy()?h.pushQueue(e):h.fireQueueItem(e),h},h.clearQueue=function(){return h.busy.flag=!1,h.queues=[],h},h.stateChanged=!1,h.doubleChecker=!1,h.doubleCheckComplete=function(){return h.stateChanged=!0,h.doubleCheckClear(),h},h.doubleCheckClear=function(){return h.doubleChecker&&(s(h.doubleChecker),h.doubleChecker=!1),h},h.doubleCheck=function(e){return h.stateChanged=!1,h.doubleCheckClear(),h.bugs.ieDoubleCheck&&(h.doubleChecker=a(function(){return h.doubleCheckClear(),h.stateChanged||e(),!0},h.options.doubleCheckInterval)),h},h.safariStatePoll=function(){var t,n=h.extractState(i.location.href);if(!h.isLastSavedState(n))return t=n,t||(t=h.createStateObject()),h.Adapter.trigger(e,"popstate"),h},h.back=function(e){return e!==!1&&h.busy()?(h.pushQueue({scope:h,callback:h.back,args:arguments,queue:e}),!1):(h.busy(!0),h.doubleCheck(function(){h.back(!1)}),p.go(-1),!0)},h.forward=function(e){return e!==!1&&h.busy()?(h.pushQueue({scope:h,callback:h.forward,args:arguments,queue:e}),!1):(h.busy(!0),h.doubleCheck(function(){h.forward(!1)}),p.go(1),!0)},h.go=function(e,t){var n;if(e>0)for(n=1;e>=n;++n)h.forward(t);else{if(!(0>e))throw Error("History.go: History.go requires a positive or negative integer passed.");for(n=-1;n>=e;--n)h.back(t)}return h},h.emulated.pushState){var f=function(){};h.pushState=h.pushState||f,h.replaceState=h.replaceState||f}else h.onPopState=function(t,n){var r,o,a=!1,s=!1;return h.doubleCheckComplete(),r=h.getHash(),r?(o=h.extractState(r||i.location.href,!0),o?h.replaceState(o.data,o.title,o.url,!1):(h.Adapter.trigger(e,"anchorchange"),h.busy(!1)),h.expectedStateId=!1,!1):(a=h.Adapter.extractEventData("state",t,n)||!1,s=a?h.getStateById(a):h.expectedStateId?h.getStateById(h.expectedStateId):h.extractState(i.location.href),s||(s=h.createStateObject(null,null,i.location.href)),h.expectedStateId=!1,h.isLastSavedState(s)?(h.busy(!1),!1):(h.storeState(s),h.saveState(s),h.setTitle(s),h.Adapter.trigger(e,"statechange"),h.busy(!1),!0))},h.Adapter.bind(e,"popstate",h.onPopState),h.pushState=function(t,n,i,r){if(h.getHashByUrl(i)&&h.emulated.pushState)throw Error("History.js does not support states with fragement-identifiers (hashes/anchors).");if(r!==!1&&h.busy())return h.pushQueue({scope:h,callback:h.pushState,args:arguments,queue:r}),!1;h.busy(!0);var o=h.createStateObject(t,n,i);return h.isLastSavedState(o)?h.busy(!1):(h.storeState(o),h.expectedStateId=o.id,p.pushState(o.id,o.title,o.url),h.Adapter.trigger(e,"popstate")),!0},h.replaceState=function(t,n,i,r){if(h.getHashByUrl(i)&&h.emulated.pushState)throw Error("History.js does not support states with fragement-identifiers (hashes/anchors).");if(r!==!1&&h.busy())return h.pushQueue({scope:h,callback:h.replaceState,args:arguments,queue:r}),!1;h.busy(!0);var o=h.createStateObject(t,n,i);return h.isLastSavedState(o)?h.busy(!1):(h.storeState(o),h.expectedStateId=o.id,p.replaceState(o.id,o.title,o.url),h.Adapter.trigger(e,"popstate")),!0};if(o){try{h.store=u.parse(o.getItem("History.store"))||{}}catch(g){h.store={}}h.normalizeStore()}else h.store={},h.normalizeStore();h.Adapter.bind(e,"beforeunload",h.clearAllIntervals),h.Adapter.bind(e,"unload",h.clearAllIntervals),h.saveState(h.storeState(h.extractState(i.location.href,!0))),o&&(h.onUnload=function(){var e,t;try{e=u.parse(o.getItem("History.store"))||{}}catch(n){e={}}e.idToState=e.idToState||{},e.urlToId=e.urlToId||{},e.stateToId=e.stateToId||{};for(t in h.idToState)h.idToState.hasOwnProperty(t)&&(e.idToState[t]=h.idToState[t]);for(t in h.urlToId)h.urlToId.hasOwnProperty(t)&&(e.urlToId[t]=h.urlToId[t]);for(t in h.stateToId)h.stateToId.hasOwnProperty(t)&&(e.stateToId[t]=h.stateToId[t]);h.store=e,h.normalizeStore(),o.setItem("History.store",u.stringify(e))},h.intervalList.push(l(h.onUnload,h.options.storeInterval)),h.Adapter.bind(e,"beforeunload",h.onUnload),h.Adapter.bind(e,"unload",h.onUnload)),h.emulated.pushState||(h.bugs.safariPoll&&h.intervalList.push(l(h.safariStatePoll,h.options.safariPollInterval)),("Apple Computer, Inc."===r.vendor||"Mozilla"===(r.appCodeName||""))&&(h.Adapter.bind(e,"hashchange",function(){h.Adapter.trigger(e,"popstate")}),h.getHash()&&h.Adapter.onDomLoad(function(){h.Adapter.trigger(e,"hashchange")})))},h.init()}(window);