UNPKG

selenium-atoms

Version:
91 lines (85 loc) 37.9 kB
function(){return function(){var g=this;function aa(a,b){var c=a.split("."),d=g;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d[e]?d=d[e]:d=d[e]={}:d[e]=b} function ba(a){var b=typeof a;if("object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;var c=Object.prototype.toString.call(a);if("[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a.length&&"undefined"!=typeof a.splice&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a.call&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("call"))return"function"}else return"null"; else if("function"==b&&"undefined"==typeof a.call)return"object";return b}function ca(a){var b=ba(a);return"array"==b||"object"==b&&"number"==typeof a.length}function k(a){return"string"==typeof a}function da(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}function ga(a,b,c){return a.call.apply(a.bind,arguments)} function ha(a,b,c){if(!a)throw Error();if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var c=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(c,d);return a.apply(b,c)}}return function(){return a.apply(b,arguments)}}function ia(a,b,c){ia=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ga:ha;return ia.apply(null,arguments)} function ja(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=c.slice();b.push.apply(b,arguments);return a.apply(this,b)}}var ka=Date.now||function(){return+new Date};function l(a,b){function c(){}c.prototype=b.prototype;a.L=b.prototype;a.prototype=new c;a.prototype.constructor=a;a.K=function(a,c,f){for(var h=Array(arguments.length-2),m=2;m<arguments.length;m++)h[m-2]=arguments[m];return b.prototype[c].apply(a,h)}};var la=String.prototype.trim?function(a){return a.trim()}:function(a){return a.replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")}; function ma(a,b){for(var c=0,d=la(String(a)).split("."),e=la(String(b)).split("."),f=Math.max(d.length,e.length),h=0;0==c&&h<f;h++){var m=d[h]||"",t=e[h]||"",A=RegExp("(\\d*)(\\D*)","g"),O=RegExp("(\\d*)(\\D*)","g");do{var ea=A.exec(m)||["","",""],fa=O.exec(t)||["","",""];if(0==ea[0].length&&0==fa[0].length)break;c=na(0==ea[1].length?0:parseInt(ea[1],10),0==fa[1].length?0:parseInt(fa[1],10))||na(0==ea[2].length,0==fa[2].length)||na(ea[2],fa[2])}while(0==c)}return c} function na(a,b){return a<b?-1:a>b?1:0};var oa=Array.prototype;function pa(a,b){if(k(a))return k(b)&&1==b.length?a.indexOf(b,0):-1;for(var c=0;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1}function n(a,b){for(var c=a.length,d=k(a)?a.split(""):a,e=0;e<c;e++)e in d&&b.call(void 0,d[e],e,a)}function qa(a,b){for(var c=a.length,d=[],e=0,f=k(a)?a.split(""):a,h=0;h<c;h++)if(h in f){var m=f[h];b.call(void 0,m,h,a)&&(d[e++]=m)}return d} function ra(a,b){for(var c=a.length,d=Array(c),e=k(a)?a.split(""):a,f=0;f<c;f++)f in e&&(d[f]=b.call(void 0,e[f],f,a));return d}function p(a,b,c){var d=c;n(a,function(c,f){d=b.call(void 0,d,c,f,a)});return d}function sa(a,b){for(var c=a.length,d=k(a)?a.split(""):a,e=0;e<c;e++)if(e in d&&b.call(void 0,d[e],e,a))return!0;return!1}function ta(a,b){var c;a:{c=a.length;for(var d=k(a)?a.split(""):a,e=0;e<c;e++)if(e in d&&b.call(void 0,d[e],e,a)){c=e;break a}c=-1}return 0>c?null:k(a)?a.charAt(c):a[c]} function ua(a){return oa.concat.apply(oa,arguments)}function va(a,b,c){return 2>=arguments.length?oa.slice.call(a,b):oa.slice.call(a,b,c)};function wa(a,b){this.code=a;this.a=q[a]||xa;this.message=b||"";var c=this.a.replace(/((?:^|\s+)[a-z])/g,function(a){return a.toUpperCase().replace(/^[\s\xa0]+/g,"")}),d=c.length-5;if(0>d||c.indexOf("Error",d)!=d)c+="Error";this.name=c;c=Error(this.message);c.name=this.name;this.stack=c.stack||""}l(wa,Error);var xa="unknown error",q={15:"element not selectable",11:"element not visible"};q[31]=xa;q[30]=xa;q[24]="invalid cookie domain";q[29]="invalid element coordinates";q[12]="invalid element state"; q[32]="invalid selector";q[51]="invalid selector";q[52]="invalid selector";q[17]="javascript error";q[405]="unsupported operation";q[34]="move target out of bounds";q[27]="no such alert";q[7]="no such element";q[8]="no such frame";q[23]="no such window";q[28]="script timeout";q[33]="session not created";q[10]="stale element reference";q[21]="timeout";q[25]="unable to set cookie";q[26]="unexpected alert open";q[13]=xa;q[9]="unknown command";wa.prototype.toString=function(){return this.name+": "+this.message};var r;a:{var ya=g.navigator;if(ya){var za=ya.userAgent;if(za){r=za;break a}}r=""}function u(a){return-1!=r.indexOf(a)};function Aa(a,b){var c={},d;for(d in a)b.call(void 0,a[d],d,a)&&(c[d]=a[d]);return c}function Ba(a,b){var c={},d;for(d in a)c[d]=b.call(void 0,a[d],d,a);return c}function v(a,b){return null!==a&&b in a}function Ca(a,b){for(var c in a)if(b.call(void 0,a[c],c,a))return c};function Da(){return u("Opera")||u("OPR")}function Ea(){return(u("Chrome")||u("CriOS"))&&!Da()&&!u("Edge")};function Fa(){return u("iPhone")&&!u("iPod")&&!u("iPad")};var Ga=Da(),w=u("Trident")||u("MSIE"),Ha=u("Edge"),x=u("Gecko")&&!(-1!=r.toLowerCase().indexOf("webkit")&&!u("Edge"))&&!(u("Trident")||u("MSIE"))&&!u("Edge"),Ia=-1!=r.toLowerCase().indexOf("webkit")&&!u("Edge"),Ja=u("Macintosh"),Ka=u("Windows");function La(){var a=r;if(x)return/rv\:([^\);]+)(\)|;)/.exec(a);if(Ha)return/Edge\/([\d\.]+)/.exec(a);if(w)return/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(a);if(Ia)return/WebKit\/(\S+)/.exec(a)}function Ma(){var a=g.document;return a?a.documentMode:void 0} var Na=function(){if(Ga&&g.opera){var a;var b=g.opera.version;try{a=b()}catch(c){a=b}return a}a="";(b=La())&&(a=b?b[1]:"");return w&&(b=Ma(),b>parseFloat(a))?String(b):a}(),Oa={};function Pa(a){return Oa[a]||(Oa[a]=0<=ma(Na,a))}var Qa=g.document,Ra=Qa&&w?Ma()||("CSS1Compat"==Qa.compatMode?parseInt(Na,10):5):void 0;!x&&!w||w&&9<=Ra||x&&Pa("1.9.1");w&&Pa("9");function Sa(a){for(;a&&1!=a.nodeType;)a=a.previousSibling;return a}function Ta(a,b){if(a.contains&&1==b.nodeType)return a==b||a.contains(b);if("undefined"!=typeof a.compareDocumentPosition)return a==b||Boolean(a.compareDocumentPosition(b)&16);for(;b&&a!=b;)b=b.parentNode;return b==a} function Ua(a,b){if(a==b)return 0;if(a.compareDocumentPosition)return a.compareDocumentPosition(b)&2?1:-1;if(w&&!(9<=Ra)){if(9==a.nodeType)return-1;if(9==b.nodeType)return 1}if("sourceIndex"in a||a.parentNode&&"sourceIndex"in a.parentNode){var c=1==a.nodeType,d=1==b.nodeType;if(c&&d)return a.sourceIndex-b.sourceIndex;var e=a.parentNode,f=b.parentNode;return e==f?Va(a,b):!c&&Ta(e,b)?-1*Wa(a,b):!d&&Ta(f,a)?Wa(b,a):(c?a.sourceIndex:e.sourceIndex)-(d?b.sourceIndex:f.sourceIndex)}d=9==a.nodeType?a:a.ownerDocument|| a.document;c=d.createRange();c.selectNode(a);c.collapse(!0);d=d.createRange();d.selectNode(b);d.collapse(!0);return c.compareBoundaryPoints(g.Range.START_TO_END,d)}function Wa(a,b){var c=a.parentNode;if(c==b)return-1;for(var d=b;d.parentNode!=c;)d=d.parentNode;return Va(d,a)}function Va(a,b){for(var c=b;c=c.previousSibling;)if(c==a)return-1;return 1}function Xa(a,b){for(var c=0;a;){if(b(a))return a;a=a.parentNode;c++}return null};var Ya=u("Firefox"),Za=Fa()||u("iPod"),$a=u("iPad"),y=u("Android")&&!(Ea()||u("Firefox")||Da()||u("Silk")),ab=Ea(),bb=u("Safari")&&!(Ea()||u("Coast")||Da()||u("Edge")||u("Silk")||u("Android"))&&!(Fa()||u("iPad")||u("iPod"));/* The MIT License Copyright (c) 2007 Cybozu Labs, Inc. Copyright (c) 2012 Google Inc. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ function z(a,b,c){this.a=a;this.b=b||1;this.h=c||1};var B=w&&!(9<=Ra),cb=w&&!(8<=Ra);function db(a,b,c,d){this.a=a;this.nodeName=c;this.nodeValue=d;this.nodeType=2;this.parentNode=this.ownerElement=b}function eb(a,b){var c=cb&&"href"==b.nodeName?a.getAttribute(b.nodeName,2):b.nodeValue;return new db(b,a,b.nodeName,c)};function fb(a){this.b=a;this.a=0}function gb(a){a=a.match(hb);for(var b=0;b<a.length;b++)ib.test(a[b])&&a.splice(b,1);return new fb(a)}var hb=RegExp("\\$?(?:(?![0-9-])[\\w-]+:)?(?![0-9-])[\\w-]+|\\/\\/|\\.\\.|::|\\d+(?:\\.\\d*)?|\\.\\d+|\"[^\"]*\"|'[^']*'|[!<>]=|\\s+|.","g"),ib=/^\s/;function C(a,b){return a.b[a.a+(b||0)]}function D(a){return a.b[a.a++]}function jb(a){return a.b.length<=a.a};function E(a){var b=null,c=a.nodeType;1==c&&(b=a.textContent,b=void 0==b||null==b?a.innerText:b,b=void 0==b||null==b?"":b);if("string"!=typeof b)if(B&&"title"==a.nodeName.toLowerCase()&&1==c)b=a.text;else if(9==c||1==c){a=9==c?a.documentElement:a.firstChild;for(var c=0,d=[],b="";a;){do 1!=a.nodeType&&(b+=a.nodeValue),B&&"title"==a.nodeName.toLowerCase()&&(b+=a.text),d[c++]=a;while(a=a.firstChild);for(;c&&!(a=d[--c].nextSibling););}}else b=a.nodeValue;return""+b} function F(a,b,c){if(null===b)return!0;try{if(!a.getAttribute)return!1}catch(d){return!1}cb&&"class"==b&&(b="className");return null==c?!!a.getAttribute(b):a.getAttribute(b,2)==c}function kb(a,b,c,d,e){return(B?lb:mb).call(null,a,b,k(c)?c:null,k(d)?d:null,e||new G)} function lb(a,b,c,d,e){if(a instanceof H||8==a.b||c&&null===a.b){var f=b.all;if(!f)return e;a=nb(a);if("*"!=a&&(f=b.getElementsByTagName(a),!f))return e;if(c){for(var h=[],m=0;b=f[m++];)F(b,c,d)&&h.push(b);f=h}for(m=0;b=f[m++];)"*"==a&&"!"==b.tagName||I(e,b);return e}ob(a,b,c,d,e);return e} function mb(a,b,c,d,e){b.getElementsByName&&d&&"name"==c&&!w?(b=b.getElementsByName(d),n(b,function(b){a.a(b)&&I(e,b)})):b.getElementsByClassName&&d&&"class"==c?(b=b.getElementsByClassName(d),n(b,function(b){b.className==d&&a.a(b)&&I(e,b)})):a instanceof J?ob(a,b,c,d,e):b.getElementsByTagName&&(b=b.getElementsByTagName(a.h()),n(b,function(a){F(a,c,d)&&I(e,a)}));return e} function pb(a,b,c,d,e){var f;if((a instanceof H||8==a.b||c&&null===a.b)&&(f=b.childNodes)){var h=nb(a);if("*"!=h&&(f=qa(f,function(a){return a.tagName&&a.tagName.toLowerCase()==h}),!f))return e;c&&(f=qa(f,function(a){return F(a,c,d)}));n(f,function(a){"*"==h&&("!"==a.tagName||"*"==h&&1!=a.nodeType)||I(e,a)});return e}return qb(a,b,c,d,e)}function qb(a,b,c,d,e){for(b=b.firstChild;b;b=b.nextSibling)F(b,c,d)&&a.a(b)&&I(e,b);return e} function ob(a,b,c,d,e){for(b=b.firstChild;b;b=b.nextSibling)F(b,c,d)&&a.a(b)&&I(e,b),ob(a,b,c,d,e)}function nb(a){if(a instanceof J){if(8==a.b)return"!";if(null===a.b)return"*"}return a.h()};function G(){this.b=this.a=null;this.s=0}function rb(a){this.node=a;this.a=this.b=null}function sb(a,b){if(!a.a)return b;if(!b.a)return a;for(var c=a.a,d=b.a,e=null,f=null,h=0;c&&d;){var f=c.node,m=d.node;f==m||f instanceof db&&m instanceof db&&f.a==m.a?(f=c,c=c.a,d=d.a):0<Ua(c.node,d.node)?(f=d,d=d.a):(f=c,c=c.a);(f.b=e)?e.a=f:a.a=f;e=f;h++}for(f=c||d;f;)f.b=e,e=e.a=f,h++,f=f.a;a.b=e;a.s=h;return a} G.prototype.unshift=function(a){a=new rb(a);a.a=this.a;this.b?this.a.b=a:this.a=this.b=a;this.a=a;this.s++};function I(a,b){var c=new rb(b);c.b=a.b;a.a?a.b.a=c:a.a=a.b=c;a.b=c;a.s++}function tb(a){return(a=a.a)?a.node:null}function ub(a){return(a=tb(a))?E(a):""}function K(a,b){return new vb(a,!!b)}function vb(a,b){this.h=a;this.b=(this.c=b)?a.b:a.a;this.a=null}function L(a){var b=a.b;if(null==b)return null;var c=a.a=b;a.b=a.c?b.b:b.a;return c.node};function M(a){this.m=a;this.b=this.i=!1;this.h=null}function N(a){return"\n "+a.toString().split("\n").join("\n ")}function wb(a,b){a.i=b}function xb(a,b){a.b=b}function P(a,b){var c=a.a(b);return c instanceof G?+ub(c):+c}function Q(a,b){var c=a.a(b);return c instanceof G?ub(c):""+c}function yb(a,b){var c=a.a(b);return c instanceof G?!!c.s:!!c};function zb(a,b,c){M.call(this,a.m);this.c=a;this.j=b;this.w=c;this.i=b.i||c.i;this.b=b.b||c.b;this.c==Ab&&(c.b||c.i||4==c.m||0==c.m||!b.h?b.b||b.i||4==b.m||0==b.m||!c.h||(this.h={name:c.h.name,A:b}):this.h={name:b.h.name,A:c})}l(zb,M); function Bb(a,b,c,d,e){b=b.a(d);c=c.a(d);var f;if(b instanceof G&&c instanceof G){e=K(b);for(d=L(e);d;d=L(e))for(b=K(c),f=L(b);f;f=L(b))if(a(E(d),E(f)))return!0;return!1}if(b instanceof G||c instanceof G){b instanceof G?e=b:(e=c,c=b);e=K(e);b=typeof c;for(d=L(e);d;d=L(e)){switch(b){case "number":d=+E(d);break;case "boolean":d=!!E(d);break;case "string":d=E(d);break;default:throw Error("Illegal primitive type for comparison.");}if(a(d,c))return!0}return!1}return e?"boolean"==typeof b||"boolean"==typeof c? a(!!b,!!c):"number"==typeof b||"number"==typeof c?a(+b,+c):a(b,c):a(+b,+c)}zb.prototype.a=function(a){return this.c.v(this.j,this.w,a)};zb.prototype.toString=function(){var a="Binary Expression: "+this.c,a=a+N(this.j);return a+=N(this.w)};function Cb(a,b,c,d){this.a=a;this.F=b;this.m=c;this.v=d}Cb.prototype.toString=function(){return this.a};var Db={};function R(a,b,c,d){if(Db.hasOwnProperty(a))throw Error("Binary operator already created: "+a);a=new Cb(a,b,c,d);return Db[a.toString()]=a} R("div",6,1,function(a,b,c){return P(a,c)/P(b,c)});R("mod",6,1,function(a,b,c){return P(a,c)%P(b,c)});R("*",6,1,function(a,b,c){return P(a,c)*P(b,c)});R("+",5,1,function(a,b,c){return P(a,c)+P(b,c)});R("-",5,1,function(a,b,c){return P(a,c)-P(b,c)});R("<",4,2,function(a,b,c){return Bb(function(a,b){return a<b},a,b,c)});R(">",4,2,function(a,b,c){return Bb(function(a,b){return a>b},a,b,c)});R("<=",4,2,function(a,b,c){return Bb(function(a,b){return a<=b},a,b,c)}); R(">=",4,2,function(a,b,c){return Bb(function(a,b){return a>=b},a,b,c)});var Ab=R("=",3,2,function(a,b,c){return Bb(function(a,b){return a==b},a,b,c,!0)});R("!=",3,2,function(a,b,c){return Bb(function(a,b){return a!=b},a,b,c,!0)});R("and",2,2,function(a,b,c){return yb(a,c)&&yb(b,c)});R("or",1,2,function(a,b,c){return yb(a,c)||yb(b,c)});function Eb(a,b){if(b.a.length&&4!=a.m)throw Error("Primary expression must evaluate to nodeset if filter has predicate(s).");M.call(this,a.m);this.c=a;this.j=b;this.i=a.i;this.b=a.b}l(Eb,M);Eb.prototype.a=function(a){a=this.c.a(a);return Fb(this.j,a)};Eb.prototype.toString=function(){var a;a="Filter:"+N(this.c);return a+=N(this.j)};function Gb(a,b){if(b.length<a.G)throw Error("Function "+a.o+" expects at least"+a.G+" arguments, "+b.length+" given");if(null!==a.D&&b.length>a.D)throw Error("Function "+a.o+" expects at most "+a.D+" arguments, "+b.length+" given");a.H&&n(b,function(b,d){if(4!=b.m)throw Error("Argument "+d+" to function "+a.o+" is not of type Nodeset: "+b);});M.call(this,a.m);this.j=a;this.c=b;wb(this,a.i||sa(b,function(a){return a.i}));xb(this,a.J&&!b.length||a.I&&!!b.length||sa(b,function(a){return a.b}))} l(Gb,M);Gb.prototype.a=function(a){return this.j.v.apply(null,ua(a,this.c))};Gb.prototype.toString=function(){var a="Function: "+this.j;if(this.c.length)var b=p(this.c,function(a,b){return a+N(b)},"Arguments:"),a=a+N(b);return a};function Hb(a,b,c,d,e,f,h,m,t){this.o=a;this.m=b;this.i=c;this.J=d;this.I=e;this.v=f;this.G=h;this.D=void 0!==m?m:h;this.H=!!t}Hb.prototype.toString=function(){return this.o};var Ib={}; function S(a,b,c,d,e,f,h,m){if(Ib.hasOwnProperty(a))throw Error("Function already created: "+a+".");Ib[a]=new Hb(a,b,c,d,!1,e,f,h,m)}S("boolean",2,!1,!1,function(a,b){return yb(b,a)},1);S("ceiling",1,!1,!1,function(a,b){return Math.ceil(P(b,a))},1);S("concat",3,!1,!1,function(a,b){return p(va(arguments,1),function(b,d){return b+Q(d,a)},"")},2,null);S("contains",2,!1,!1,function(a,b,c){b=Q(b,a);a=Q(c,a);return-1!=b.indexOf(a)},2);S("count",1,!1,!1,function(a,b){return b.a(a).s},1,1,!0); S("false",2,!1,!1,function(){return!1},0);S("floor",1,!1,!1,function(a,b){return Math.floor(P(b,a))},1);S("id",4,!1,!1,function(a,b){function c(a){if(B){var b=e.all[a];if(b){if(b.nodeType&&a==b.id)return b;if(b.length)return ta(b,function(b){return a==b.id})}return null}return e.getElementById(a)}var d=a.a,e=9==d.nodeType?d:d.ownerDocument,d=Q(b,a).split(/\s+/),f=[];n(d,function(a){a=c(a);!a||0<=pa(f,a)||f.push(a)});f.sort(Ua);var h=new G;n(f,function(a){I(h,a)});return h},1); S("lang",2,!1,!1,function(){return!1},1);S("last",1,!0,!1,function(a){if(1!=arguments.length)throw Error("Function last expects ()");return a.h},0);S("local-name",3,!1,!0,function(a,b){var c=b?tb(b.a(a)):a.a;return c?c.localName||c.nodeName.toLowerCase():""},0,1,!0);S("name",3,!1,!0,function(a,b){var c=b?tb(b.a(a)):a.a;return c?c.nodeName.toLowerCase():""},0,1,!0);S("namespace-uri",3,!0,!1,function(){return""},0,1,!0); S("normalize-space",3,!1,!0,function(a,b){return(b?Q(b,a):E(a.a)).replace(/[\s\xa0]+/g," ").replace(/^\s+|\s+$/g,"")},0,1);S("not",2,!1,!1,function(a,b){return!yb(b,a)},1);S("number",1,!1,!0,function(a,b){return b?P(b,a):+E(a.a)},0,1);S("position",1,!0,!1,function(a){return a.b},0);S("round",1,!1,!1,function(a,b){return Math.round(P(b,a))},1);S("starts-with",2,!1,!1,function(a,b,c){b=Q(b,a);a=Q(c,a);return 0==b.lastIndexOf(a,0)},2);S("string",3,!1,!0,function(a,b){return b?Q(b,a):E(a.a)},0,1); S("string-length",1,!1,!0,function(a,b){return(b?Q(b,a):E(a.a)).length},0,1);S("substring",3,!1,!1,function(a,b,c,d){c=P(c,a);if(isNaN(c)||Infinity==c||-Infinity==c)return"";d=d?P(d,a):Infinity;if(isNaN(d)||-Infinity===d)return"";c=Math.round(c)-1;var e=Math.max(c,0);a=Q(b,a);if(Infinity==d)return a.substring(e);b=Math.round(d);return a.substring(e,c+b)},2,3);S("substring-after",3,!1,!1,function(a,b,c){b=Q(b,a);a=Q(c,a);c=b.indexOf(a);return-1==c?"":b.substring(c+a.length)},2); S("substring-before",3,!1,!1,function(a,b,c){b=Q(b,a);a=Q(c,a);a=b.indexOf(a);return-1==a?"":b.substring(0,a)},2);S("sum",1,!1,!1,function(a,b){for(var c=K(b.a(a)),d=0,e=L(c);e;e=L(c))d+=+E(e);return d},1,1,!0);S("translate",3,!1,!1,function(a,b,c,d){b=Q(b,a);c=Q(c,a);var e=Q(d,a);a={};for(d=0;d<c.length;d++){var f=c.charAt(d);f in a||(a[f]=e.charAt(d))}c="";for(d=0;d<b.length;d++)f=b.charAt(d),c+=f in a?a[f]:f;return c},3);S("true",2,!1,!1,function(){return!0},0);function J(a,b){this.j=a;this.c=void 0!==b?b:null;this.b=null;switch(a){case "comment":this.b=8;break;case "text":this.b=3;break;case "processing-instruction":this.b=7;break;case "node":break;default:throw Error("Unexpected argument");}}function Jb(a){return"comment"==a||"text"==a||"processing-instruction"==a||"node"==a}J.prototype.a=function(a){return null===this.b||this.b==a.nodeType};J.prototype.h=function(){return this.j}; J.prototype.toString=function(){var a="Kind Test: "+this.j;null===this.c||(a+=N(this.c));return a};function Kb(a){M.call(this,3);this.c=a.substring(1,a.length-1)}l(Kb,M);Kb.prototype.a=function(){return this.c};Kb.prototype.toString=function(){return"Literal: "+this.c};function H(a,b){this.o=a.toLowerCase();this.c=b?b.toLowerCase():"http://www.w3.org/1999/xhtml"}H.prototype.a=function(a){var b=a.nodeType;return 1!=b&&2!=b?!1:"*"!=this.o&&this.o!=a.nodeName.toLowerCase()?!1:this.c==(a.namespaceURI?a.namespaceURI.toLowerCase():"http://www.w3.org/1999/xhtml")};H.prototype.h=function(){return this.o};H.prototype.toString=function(){return"Name Test: "+("http://www.w3.org/1999/xhtml"==this.c?"":this.c+":")+this.o};function Lb(a){M.call(this,1);this.c=a}l(Lb,M);Lb.prototype.a=function(){return this.c};Lb.prototype.toString=function(){return"Number: "+this.c};function Mb(a,b){M.call(this,a.m);this.j=a;this.c=b;this.i=a.i;this.b=a.b;if(1==this.c.length){var c=this.c[0];c.C||c.c!=Nb||(c=c.w,"*"!=c.h()&&(this.h={name:c.h(),A:null}))}}l(Mb,M);function Ob(){M.call(this,4)}l(Ob,M);Ob.prototype.a=function(a){var b=new G;a=a.a;9==a.nodeType?I(b,a):I(b,a.ownerDocument);return b};Ob.prototype.toString=function(){return"Root Helper Expression"};function Pb(){M.call(this,4)}l(Pb,M);Pb.prototype.a=function(a){var b=new G;I(b,a.a);return b};Pb.prototype.toString=function(){return"Context Helper Expression"}; function Qb(a){return"/"==a||"//"==a}Mb.prototype.a=function(a){var b=this.j.a(a);if(!(b instanceof G))throw Error("Filter expression must evaluate to nodeset.");a=this.c;for(var c=0,d=a.length;c<d&&b.s;c++){var e=a[c],f=K(b,e.c.a),h;if(e.i||e.c!=Rb)if(e.i||e.c!=Sb)for(h=L(f),b=e.a(new z(h));null!=(h=L(f));)h=e.a(new z(h)),b=sb(b,h);else h=L(f),b=e.a(new z(h));else{for(h=L(f);(b=L(f))&&(!h.contains||h.contains(b))&&b.compareDocumentPosition(h)&8;h=b);b=e.a(new z(h))}}return b}; Mb.prototype.toString=function(){var a;a="Path Expression:"+N(this.j);if(this.c.length){var b=p(this.c,function(a,b){return a+N(b)},"Steps:");a+=N(b)}return a};function Tb(a,b){this.a=a;this.b=!!b} function Fb(a,b,c){for(c=c||0;c<a.a.length;c++)for(var d=a.a[c],e=K(b),f=b.s,h,m=0;h=L(e);m++){var t=a.b?f-m:m+1;h=d.a(new z(h,t,f));if("number"==typeof h)t=t==h;else if("string"==typeof h||"boolean"==typeof h)t=!!h;else if(h instanceof G)t=0<h.s;else throw Error("Predicate.evaluate returned an unexpected type.");if(!t){t=e;h=t.h;var A=t.a;if(!A)throw Error("Next must be called at least once before remove.");var O=A.b,A=A.a;O?O.a=A:h.a=A;A?A.b=O:h.b=O;h.s--;t.a=null}}return b} Tb.prototype.toString=function(){return p(this.a,function(a,b){return a+N(b)},"Predicates:")};function T(a,b,c,d){M.call(this,4);this.c=a;this.w=b;this.j=c||new Tb([]);this.C=!!d;b=this.j;b=0<b.a.length?b.a[0].h:null;a.b&&b&&(a=b.name,a=B?a.toLowerCase():a,this.h={name:a,A:b.A});a:{a=this.j;for(b=0;b<a.a.length;b++)if(c=a.a[b],c.i||1==c.m||0==c.m){a=!0;break a}a=!1}this.i=a}l(T,M); T.prototype.a=function(a){var b=a.a,c=null,c=this.h,d=null,e=null,f=0;c&&(d=c.name,e=c.A?Q(c.A,a):null,f=1);if(this.C)if(this.i||this.c!=Ub)if(a=K((new T(Vb,new J("node"))).a(a)),b=L(a))for(c=this.v(b,d,e,f);null!=(b=L(a));)c=sb(c,this.v(b,d,e,f));else c=new G;else c=kb(this.w,b,d,e),c=Fb(this.j,c,f);else c=this.v(a.a,d,e,f);return c};T.prototype.v=function(a,b,c,d){a=this.c.h(this.w,a,b,c);return a=Fb(this.j,a,d)}; T.prototype.toString=function(){var a;a="Step:"+N("Operator: "+(this.C?"//":"/"));this.c.o&&(a+=N("Axis: "+this.c));a+=N(this.w);if(this.j.a.length){var b=p(this.j.a,function(a,b){return a+N(b)},"Predicates:");a+=N(b)}return a};function Wb(a,b,c,d){this.o=a;this.h=b;this.a=c;this.b=d}Wb.prototype.toString=function(){return this.o};var Xb={};function U(a,b,c,d){if(Xb.hasOwnProperty(a))throw Error("Axis already created: "+a);b=new Wb(a,b,c,!!d);return Xb[a]=b} U("ancestor",function(a,b){for(var c=new G,d=b;d=d.parentNode;)a.a(d)&&c.unshift(d);return c},!0);U("ancestor-or-self",function(a,b){var c=new G,d=b;do a.a(d)&&c.unshift(d);while(d=d.parentNode);return c},!0); var Nb=U("attribute",function(a,b){var c=new G,d=a.h();if("style"==d&&b.style&&B)return I(c,new db(b.style,b,"style",b.style.cssText)),c;var e=b.attributes;if(e)if(a instanceof J&&null===a.b||"*"==d)for(var d=0,f;f=e[d];d++)B?f.nodeValue&&I(c,eb(b,f)):I(c,f);else(f=e.getNamedItem(d))&&(B?f.nodeValue&&I(c,eb(b,f)):I(c,f));return c},!1),Ub=U("child",function(a,b,c,d,e){return(B?pb:qb).call(null,a,b,k(c)?c:null,k(d)?d:null,e||new G)},!1,!0);U("descendant",kb,!1,!0); var Vb=U("descendant-or-self",function(a,b,c,d){var e=new G;F(b,c,d)&&a.a(b)&&I(e,b);return kb(a,b,c,d,e)},!1,!0),Rb=U("following",function(a,b,c,d){var e=new G;do for(var f=b;f=f.nextSibling;)F(f,c,d)&&a.a(f)&&I(e,f),e=kb(a,f,c,d,e);while(b=b.parentNode);return e},!1,!0);U("following-sibling",function(a,b){for(var c=new G,d=b;d=d.nextSibling;)a.a(d)&&I(c,d);return c},!1);U("namespace",function(){return new G},!1); var Yb=U("parent",function(a,b){var c=new G;if(9==b.nodeType)return c;if(2==b.nodeType)return I(c,b.ownerElement),c;var d=b.parentNode;a.a(d)&&I(c,d);return c},!1),Sb=U("preceding",function(a,b,c,d){var e=new G,f=[];do f.unshift(b);while(b=b.parentNode);for(var h=1,m=f.length;h<m;h++){var t=[];for(b=f[h];b=b.previousSibling;)t.unshift(b);for(var A=0,O=t.length;A<O;A++)b=t[A],F(b,c,d)&&a.a(b)&&I(e,b),e=kb(a,b,c,d,e)}return e},!0,!0); U("preceding-sibling",function(a,b){for(var c=new G,d=b;d=d.previousSibling;)a.a(d)&&c.unshift(d);return c},!0);var Zb=U("self",function(a,b){var c=new G;a.a(b)&&I(c,b);return c},!1);function $b(a){M.call(this,1);this.c=a;this.i=a.i;this.b=a.b}l($b,M);$b.prototype.a=function(a){return-P(this.c,a)};$b.prototype.toString=function(){return"Unary Expression: -"+N(this.c)};function ac(a){M.call(this,4);this.c=a;wb(this,sa(this.c,function(a){return a.i}));xb(this,sa(this.c,function(a){return a.b}))}l(ac,M);ac.prototype.a=function(a){var b=new G;n(this.c,function(c){c=c.a(a);if(!(c instanceof G))throw Error("Path expression must evaluate to NodeSet.");b=sb(b,c)});return b};ac.prototype.toString=function(){return p(this.c,function(a,b){return a+N(b)},"Union Expression:")};function bc(a,b){this.a=a;this.b=b}function cc(a){for(var b,c=[];;){V(a,"Missing right hand side of binary expression.");b=dc(a);var d=D(a.a);if(!d)break;var e=(d=Db[d]||null)&&d.F;if(!e){a.a.a--;break}for(;c.length&&e<=c[c.length-1].F;)b=new zb(c.pop(),c.pop(),b);c.push(b,d)}for(;c.length;)b=new zb(c.pop(),c.pop(),b);return b}function V(a,b){if(jb(a.a))throw Error(b);}function ec(a,b){var c=D(a.a);if(c!=b)throw Error("Bad token, expected: "+b+" got: "+c);} function fc(a){a=D(a.a);if(")"!=a)throw Error("Bad token: "+a);}function gc(a){a=D(a.a);if(2>a.length)throw Error("Unclosed literal string");return new Kb(a)}function hc(a){var b=D(a.a),c=b.indexOf(":");if(-1==c)return new H(b);var d=b.substring(0,c);a=a.b(d);if(!a)throw Error("Namespace prefix not declared: "+d);b=b.substr(c+1);return new H(b,a)} function ic(a){var b,c=[],d;if(Qb(C(a.a))){b=D(a.a);d=C(a.a);if("/"==b&&(jb(a.a)||"."!=d&&".."!=d&&"@"!=d&&"*"!=d&&!/(?![0-9])[\w]/.test(d)))return new Ob;d=new Ob;V(a,"Missing next location step.");b=jc(a,b);c.push(b)}else{a:{b=C(a.a);d=b.charAt(0);switch(d){case "$":throw Error("Variable reference not allowed in HTML XPath");case "(":D(a.a);b=cc(a);V(a,'unclosed "("');ec(a,")");break;case '"':case "'":b=gc(a);break;default:if(isNaN(+b))if(!Jb(b)&&/(?![0-9])[\w]/.test(d)&&"("==C(a.a,1)){b=D(a.a); b=Ib[b]||null;D(a.a);for(d=[];")"!=C(a.a);){V(a,"Missing function argument list.");d.push(cc(a));if(","!=C(a.a))break;D(a.a)}V(a,"Unclosed function argument list.");fc(a);b=new Gb(b,d)}else{b=null;break a}else b=new Lb(+D(a.a))}"["==C(a.a)&&(d=new Tb(kc(a)),b=new Eb(b,d))}if(b)if(Qb(C(a.a)))d=b;else return b;else b=jc(a,"/"),d=new Pb,c.push(b)}for(;Qb(C(a.a));)b=D(a.a),V(a,"Missing next location step."),b=jc(a,b),c.push(b);return new Mb(d,c)} function jc(a,b){var c,d,e;if("/"!=b&&"//"!=b)throw Error('Step op should be "/" or "//"');if("."==C(a.a))return d=new T(Zb,new J("node")),D(a.a),d;if(".."==C(a.a))return d=new T(Yb,new J("node")),D(a.a),d;var f;if("@"==C(a.a))f=Nb,D(a.a),V(a,"Missing attribute name");else if("::"==C(a.a,1)){if(!/(?![0-9])[\w]/.test(C(a.a).charAt(0)))throw Error("Bad token: "+D(a.a));c=D(a.a);f=Xb[c]||null;if(!f)throw Error("No axis with name: "+c);D(a.a);V(a,"Missing node name")}else f=Ub;c=C(a.a);if(/(?![0-9])[\w]/.test(c.charAt(0)))if("("== C(a.a,1)){if(!Jb(c))throw Error("Invalid node type: "+c);c=D(a.a);if(!Jb(c))throw Error("Invalid type name: "+c);ec(a,"(");V(a,"Bad nodetype");e=C(a.a).charAt(0);var h=null;if('"'==e||"'"==e)h=gc(a);V(a,"Bad nodetype");fc(a);c=new J(c,h)}else c=hc(a);else if("*"==c)c=hc(a);else throw Error("Bad token: "+D(a.a));e=new Tb(kc(a),f.a);return d||new T(f,c,e,"//"==b)} function kc(a){for(var b=[];"["==C(a.a);){D(a.a);V(a,"Missing predicate expression.");var c=cc(a);b.push(c);V(a,"Unclosed predicate expression.");ec(a,"]")}return b}function dc(a){if("-"==C(a.a))return D(a.a),new $b(dc(a));var b=ic(a);if("|"!=C(a.a))a=b;else{for(b=[b];"|"==D(a.a);)V(a,"Missing next union location path."),b.push(ic(a));a.a.a--;a=new ac(b)}return a};function lc(a){switch(a.nodeType){case 1:return ja(mc,a);case 9:return lc(a.documentElement);case 11:case 10:case 6:case 12:return nc;default:return a.parentNode?lc(a.parentNode):nc}}function nc(){return null}function mc(a,b){if(a.prefix==b)return a.namespaceURI||"http://www.w3.org/1999/xhtml";var c=a.getAttributeNode("xmlns:"+b);return c&&c.specified?c.value||null:a.parentNode&&9!=a.parentNode.nodeType?mc(a.parentNode,b):null};function oc(a,b){if(!a.length)throw Error("Empty XPath expression.");var c=gb(a);if(jb(c))throw Error("Invalid XPath expression.");b?"function"==ba(b)||(b=ia(b.lookupNamespaceURI,b)):b=function(){return null};var d=cc(new bc(c,b));if(!jb(c))throw Error("Bad token: "+D(c));this.evaluate=function(a,b){var c=d.a(new z(a));return new W(c,b)}} function W(a,b){if(0==b)if(a instanceof G)b=4;else if("string"==typeof a)b=2;else if("number"==typeof a)b=1;else if("boolean"==typeof a)b=3;else throw Error("Unexpected evaluation result.");if(2!=b&&1!=b&&3!=b&&!(a instanceof G))throw Error("value could not be converted to the specified type");this.resultType=b;var c;switch(b){case 2:this.stringValue=a instanceof G?ub(a):""+a;break;case 1:this.numberValue=a instanceof G?+ub(a):+a;break;case 3:this.booleanValue=a instanceof G?0<a.s:!!a;break;case 4:case 5:case 6:case 7:var d= K(a);c=[];for(var e=L(d);e;e=L(d))c.push(e instanceof db?e.a:e);this.snapshotLength=a.s;this.invalidIteratorState=!1;break;case 8:case 9:d=tb(a);this.singleNodeValue=d instanceof db?d.a:d;break;default:throw Error("Unknown XPathResult type.");}var f=0;this.iterateNext=function(){if(4!=b&&5!=b)throw Error("iterateNext called with wrong result type");return f>=c.length?null:c[f++]};this.snapshotItem=function(a){if(6!=b&&7!=b)throw Error("snapshotItem called with wrong result type");return a>=c.length|| 0>a?null:c[a]}}W.ANY_TYPE=0;W.NUMBER_TYPE=1;W.STRING_TYPE=2;W.BOOLEAN_TYPE=3;W.UNORDERED_NODE_ITERATOR_TYPE=4;W.ORDERED_NODE_ITERATOR_TYPE=5;W.UNORDERED_NODE_SNAPSHOT_TYPE=6;W.ORDERED_NODE_SNAPSHOT_TYPE=7;W.ANY_UNORDERED_NODE_TYPE=8;W.FIRST_ORDERED_NODE_TYPE=9;function pc(a){this.lookupNamespaceURI=lc(a)} aa("wgxpath.install",function(a){a=a||g;var b=a.document;b.evaluate||(a.XPathResult=W,b.evaluate=function(a,b,e,f){return(new oc(a,e)).evaluate(b,f)},b.createExpression=function(a,b){return new oc(a,b)},b.createNSResolver=function(a){return new pc(a)})});function qc(a){return(a=a.exec(r))?a[1]:""}var rc=function(){if(Ya)return qc(/Firefox\/([0-9.]+)/);if(w||Ha||Ga)return Na;if(ab)return qc(/Chrome\/([0-9.]+)/);if(bb&&!(Fa()||u("iPad")||u("iPod")))return qc(/Version\/([0-9.]+)/);if(Za||$a){var a;if(a=/Version\/(\S+).*Mobile\/(\S+)/.exec(r))return a[1]+"."+a[2]}else if(y)return(a=qc(/Android\s+([0-9.]+)/))?a:qc(/Version\/([0-9.]+)/);return""}();var sc,tc;function uc(a){return vc?sc(a):w?0<=ma(Ra,a):Pa(a)}function wc(a){vc?tc(a):y?ma(xc,a):ma(rc,a)} var vc=function(){if(!x)return!1;var a=g.Components;if(!a)return!1;try{if(!a.classes)return!1}catch(b){return!1}var c=a.classes,a=a.interfaces,d=c["@mozilla.org/xpcom/version-comparator;1"].getService(a.nsIVersionComparator),c=c["@mozilla.org/xre/app-info;1"].getService(a.nsIXULAppInfo),e=c.platformVersion,f=c.version;sc=function(a){return 0<=d.compare(e,""+a)};tc=function(a){d.compare(f,""+a)};return!0}(),yc;if(y){var zc=/Android\s+([0-9\.]+)/.exec(r);yc=zc?zc[1]:"0"}else yc="0";var xc=yc;y&&wc(2.3); y&&wc(4);bb&&wc(6);function Ac(a,b){return!!a&&1==a.nodeType&&(!b||a.tagName.toUpperCase()==b)}var Bc="BUTTON INPUT OPTGROUP OPTION SELECT TEXTAREA".split(" "); function Cc(a){var b=a.tagName.toUpperCase();return 0<=pa(Bc,b)?a.disabled?!1:a.parentNode&&1==a.parentNode.nodeType&&"OPTGROUP"==b||"OPTION"==b?Cc(a.parentNode):!Xa(a,function(a){var b=a.parentNode;if(b&&Ac(b,"FIELDSET")&&b.disabled){if(!Ac(a,"LEGEND"))return!0;for(;a=void 0!==a.previousElementSibling?a.previousElementSibling:Sa(a.previousSibling);)if(Ac(a,"LEGEND"))return!0}return!1}):!0};Ia||vc&&wc(3.6);w&&uc(10);y&&wc(4);function X(a,b){this.u={};this.l=[];this.b=this.a=0;var c=arguments.length;if(1<c){if(c%2)throw Error("Uneven number of arguments");for(var d=0;d<c;d+=2)Y(this,arguments[d],arguments[d+1])}else if(a){var e;if(a instanceof X)for(d=Dc(a),Ec(a),e=[],c=0;c<a.l.length;c++)e.push(a.u[a.l[c]]);else{var c=[],f=0;for(d in a)c[f++]=d;d=c;c=[];f=0;for(e in a)c[f++]=a[e];e=c}for(c=0;c<d.length;c++)Y(this,d[c],e[c])}}function Dc(a){Ec(a);return a.l.concat()} X.prototype.clear=function(){this.u={};this.b=this.a=this.l.length=0};function Ec(a){if(a.a!=a.l.length){for(var b=0,c=0;b<a.l.length;){var d=a.l[b];Object.prototype.hasOwnProperty.call(a.u,d)&&(a.l[c++]=d);b++}a.l.length=c}if(a.a!=a.l.length){for(var e={},c=b=0;b<a.l.length;)d=a.l[b],Object.prototype.hasOwnProperty.call(e,d)||(a.l[c++]=d,e[d]=1),b++;a.l.length=c}}X.prototype.get=function(a,b){return Object.prototype.hasOwnProperty.call(this.u,a)?this.u[a]:b}; function Y(a,b,c){Object.prototype.hasOwnProperty.call(a.u,b)||(a.a++,a.l.push(b),a.b++);a.u[b]=c}X.prototype.forEach=function(a,b){for(var c=Dc(this),d=0;d<c.length;d++){var e=c[d],f=this.get(e);a.call(b,f,e,this)}};X.prototype.clone=function(){return new X(this)};var Fc={};function Z(a,b,c){da(a)&&(a=x?a.f:a.g);a=new Gc(a);!b||b in Fc&&!c||(Fc[b]={key:a,shift:!1},c&&(Fc[c]={key:a,shift:!0}));return a}function Gc(a){this.code=a}Z(8);Z(9);Z(13);var Hc=Z(16),Ic=Z(17),Jc=Z(18);Z(19);Z(20);Z(27);Z(32," ");Z(33);Z(34);Z(35);Z(36);Z(37);Z(38);Z(39);Z(40);Z(44);Z(45);Z(46);Z(48,"0",")");Z(49,"1","!");Z(50,"2","@");Z(51,"3","#");Z(52,"4","$");Z(53,"5","%");Z(54,"6","^");Z(55,"7","&");Z(56,"8","*");Z(57,"9","(");Z(65,"a","A");Z(66,"b","B");Z(67,"c","C");Z(68,"d","D"); Z(69,"e","E");Z(70,"f","F");Z(71,"g","G");Z(72,"h","H");Z(73,"i","I");Z(74,"j","J");Z(75,"k","K");Z(76,"l","L");Z(77,"m","M");Z(78,"n","N");Z(79,"o","O");Z(80,"p","P");Z(81,"q","Q");Z(82,"r","R");Z(83,"s","S");Z(84,"t","T");Z(85,"u","U");Z(86,"v","V");Z(87,"w","W");Z(88,"x","X");Z(89,"y","Y");Z(90,"z","Z");var Kc=Z(Ka?{f:91,g:91}:Ja?{f:224,g:91}:{f:0,g:91});Z(Ka?{f:92,g:92}:Ja?{f:224,g:93}:{f:0,g:92});Z(Ka?{f:93,g:93}:Ja?{f:0,g:0}:{f:93,g:null});Z({f:96,g:96},"0");Z({f:97,g:97},"1"); Z({f:98,g:98},"2");Z({f:99,g:99},"3");Z({f:100,g:100},"4");Z({f:101,g:101},"5");Z({f:102,g:102},"6");Z({f:103,g:103},"7");Z({f:104,g:104},"8");Z({f:105,g:105},"9");Z({f:106,g:106},"*");Z({f:107,g:107},"+");Z({f:109,g:109},"-");Z({f:110,g:110},".");Z({f:111,g:111},"/");Z(144);Z(112);Z(113);Z(114);Z(115);Z(116);Z(117);Z(118);Z(119);Z(120);Z(121);Z(122);Z(123);Z({f:107,g:187},"=","+");Z(108,",");Z({f:109,g:189},"-","_");Z(188,",","<");Z(190,".",">");Z(191,"/","?");Z(192,"`","~");Z(219,"[","{"); Z(220,"\\","|");Z(221,"]","}");Z({f:59,g:186},";",":");Z(222,"'",'"');var Lc=new X;Y(Lc,1,Hc);Y(Lc,2,Ic);Y(Lc,4,Jc);Y(Lc,8,Kc);(function(a){var b=new X;n(Dc(a),function(c){Y(b,a.get(c).code,c)});return b})(Lc);x&&uc(12);function Mc(){} function Nc(a,b,c){if(null==b)c.push("null");else{if("object"==typeof b){if("array"==ba(b)){var d=b;b=d.length;c.push("[");for(var e="",f=0;f<b;f++)c.push(e),Nc(a,d[f],c),e=",";c.push("]");return}if(b instanceof String||b instanceof Number||b instanceof Boolean)b=b.valueOf();else{c.push("{");e="";for(d in b)Object.prototype.hasOwnProperty.call(b,d)&&(f=b[d],"function"!=typeof f&&(c.push(e),Oc(d,c),c.push(":"),Nc(a,f,c),e=","));c.push("}");return}}switch(typeof b){case "string":Oc(b,c);break;case "number":c.push(isFinite(b)&& !isNaN(b)?String(b):"null");break;case "boolean":c.push(String(b));break;case "function":c.push("null");break;default:throw Error("Unknown type: "+typeof b);}}}var Pc={'"':'\\"',"\\":"\\\\","/":"\\/","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\x0B":"\\u000b"},Qc=/\uffff/.test("\uffff")?/[\\\"\x00-\x1f\x7f-\uffff]/g:/[\\\"\x00-\x1f\x7f-\xff]/g; function Oc(a,b){b.push('"',a.replace(Qc,function(a){var b=Pc[a];b||(b="\\u"+(a.charCodeAt(0)|65536).toString(16).substr(1),Pc[a]=b);return b}),'"')};Ia||x&&uc(3.5)||w&&uc(8);function Rc(a){switch(ba(a)){case "string":case "number":case "boolean":return a;case "function":return a.toString();case "array":return ra(a,Rc);case "object":if(v(a,"nodeType")&&(1==a.nodeType||9==a.nodeType)){var b={};b.ELEMENT=Sc(a);return b}if(v(a,"document"))return b={},b.WINDOW=Sc(a),b;if(ca(a))return ra(a,Rc);a=Aa(a,function(a,b){return"number"==typeof b||k(b)});return Ba(a,Rc);default:return null}} function Tc(a,b){return"array"==ba(a)?ra(a,function(a){return Tc(a,b)}):da(a)?"function"==typeof a?a:v(a,"ELEMENT")?Uc(a.ELEMENT,b):v(a,"WINDOW")?Uc(a.WINDOW,b):Ba(a,function(a){return Tc(a,b)}):a}function Vc(a){a=a||document;var b=a.$wdc_;b||(b=a.$wdc_={},b.B=ka());b.B||(b.B=ka());return b}function Sc(a){var b=Vc(a.ownerDocument),c=Ca(b,function(b){return b==a});c||(c=":wdc:"+b.B++,b[c]=a);return c} function Uc(a,b){a=decodeURIComponent(a);var c=b||document,d=Vc(c);if(!v(d,a))throw new wa(10,"Element does not exist in cache");var e=d[a];if(v(e,"setInterval")){if(e.closed)throw delete d[a],new wa(23,"Window has been closed.");return e}for(var f=e;f;){if(f==c.documentElement)return e;f=f.parentNode}delete d[a];throw new wa(10,"Element is no longer attached to the DOM");};aa("_",function(a,b){var c=[a],d=Cc,e;try{var f;b?f=Uc(b.WINDOW):f=window;var h=Tc(c,f.document),m=d.apply(null,h);e={status:0,value:Rc(m)}}catch(t){e={status:v(t,"code")?t.code:13,value:{message:t.message}}}c=[];Nc(new Mc,e,c);return c.join("")});; return this._.apply(null,arguments);}.apply({navigator:typeof window!=undefined?window.navigator:null,document:typeof window!=undefined?window.document:null}, arguments);}