appium-remote-debugger
Version:
Appium proxy for Remote Debugger protocol
113 lines (107 loc) • 49.8 kB
JavaScript
function(){return (function(){var aa=this||self;function ba(a){return"string"==typeof a}function ca(a,b){a=a.split(".");var c=aa;a[0]in c||"undefined"==typeof c.execScript||c.execScript("var "+a[0]);for(var d;a.length&&(d=a.shift());)a.length||void 0===b?c[d]&&c[d]!==Object.prototype[d]?c=c[d]:c=c[d]={}:c[d]=b}
function da(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 ea(a){var b=da(a);return"array"==b||"object"==b&&"number"==typeof a.length}function fa(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}function ha(a,b,c){return a.call.apply(a.bind,arguments)}
function ia(a,b,c){if(!a)throw Error();if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var e=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(e,d);return a.apply(b,e)}}return function(){return a.apply(b,arguments)}}function ja(a,b,c){Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ja=ha:ja=ia;return ja.apply(null,arguments)}
function ka(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var d=c.slice();d.push.apply(d,arguments);return a.apply(this,d)}}var la=Date.now||function(){return+new Date};function h(a,b){function c(){}c.prototype=b.prototype;a.K=b.prototype;a.prototype=new c;a.prototype.constructor=a}
function ma(a,b,c){var d=arguments.callee.caller;if("undefined"!==typeof d.K){for(var e=Array(arguments.length-1),f=1;f<arguments.length;f++)e[f-1]=arguments[f];d.K.constructor.apply(a,e)}else{if("string"!=typeof b&&"symbol"!=typeof b)throw Error("method names provided to goog.base must be a string or a symbol");e=Array(arguments.length-2);for(f=2;f<arguments.length;f++)e[f-2]=arguments[f];f=!1;for(var g=a.constructor.prototype;g;g=Object.getPrototypeOf(g))if(g[b]===d)f=!0;else if(f){g[b].apply(a,
e);return}if(a[b]===d)a.constructor.prototype[b].apply(a,e);else throw Error("goog.base called from a method of one name to a method of a different name");}};/*
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 na(a,b,c){this.a=a;this.b=b||1;this.f=c||1};var oa=Array.prototype.indexOf?function(a,b){return Array.prototype.indexOf.call(a,b,void 0)}:function(a,b){if("string"===typeof a)return"string"!==typeof b||1!=b.length?-1:a.indexOf(b,0);for(var c=0;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},n=Array.prototype.forEach?function(a,b){Array.prototype.forEach.call(a,b,void 0)}:function(a,b){for(var c=a.length,d="string"===typeof a?a.split(""):a,e=0;e<c;e++)e in d&&b.call(void 0,d[e],e,a)},pa=Array.prototype.map?function(a,b){return Array.prototype.map.call(a,
b,void 0)}:function(a,b){for(var c=a.length,d=Array(c),e="string"===typeof a?a.split(""):a,f=0;f<c;f++)f in e&&(d[f]=b.call(void 0,e[f],f,a));return d},qa=Array.prototype.reduce?function(a,b,c){return Array.prototype.reduce.call(a,b,c)}:function(a,b,c){var d=c;n(a,function(e,f){d=b.call(void 0,d,e,f,a)});return d},ra=Array.prototype.some?function(a,b){return Array.prototype.some.call(a,b,void 0)}:function(a,b){for(var c=a.length,d="string"===typeof 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 sa(a){return Array.prototype.concat.apply([],arguments)}function ta(a,b,c){return 2>=arguments.length?Array.prototype.slice.call(a,b):Array.prototype.slice.call(a,b,c)};var ua=String.prototype.trim?function(a){return a.trim()}:function(a){return/^[\s\xa0]*([\s\S]*?)[\s\xa0]*$/.exec(a)[1]};
function va(a){var b=0;a=ua(String(a)).split(".");for(var c=ua("4").split("."),d=Math.max(a.length,c.length),e=0;0==b&&e<d;e++){var f=a[e]||"",g=c[e]||"";do{f=/(\d*)(\D*)(.*)/.exec(f)||["","","",""];g=/(\d*)(\D*)(.*)/.exec(g)||["","","",""];if(0==f[0].length&&0==g[0].length)break;b=wa(0==f[1].length?0:parseInt(f[1],10),0==g[1].length?0:parseInt(g[1],10))||wa(0==f[2].length,0==g[2].length)||wa(f[2],g[2]);f=f[3];g=g[3]}while(0==b)}return b}function wa(a,b){return a<b?-1:a>b?1:0};var xa;a:{var ya=aa.navigator;if(ya){var za=ya.userAgent;if(za){xa=za;break a}}xa=""}function t(a){return-1!=xa.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 u(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 t("Firefox")||t("FxiOS")}function Ea(){return(t("Chrome")||t("CriOS"))&&!t("Edge")};function Fa(a){return String(a).replace(/\-([a-z])/g,function(b,c){return c.toUpperCase()})};function Ga(){return t("iPhone")&&!t("iPod")&&!t("iPad")};var Ha=t("Macintosh"),Ia=t("Windows");function Ja(a){this.b=a;this.a=0}function Ka(a){a=a.match(La);for(var b=0;b<a.length;b++)Ma.test(a[b])&&a.splice(b,1);return new Ja(a)}var La=/\$?(?:(?![0-9-\.])(?:\*|[\w-\.]+):)?(?![0-9-\.])(?:\*|[\w-\.]+)|\/\/|\.\.|::|\d+(?:\.\d*)?|\.\d+|"[^"]*"|'[^']*'|[!<>]=|\s+|./g,Ma=/^\s/;function v(a,b){return a.b[a.a+(b||0)]}function w(a){return a.b[a.a++]}function Na(a){return a.b.length<=a.a};function y(a,b){this.x=void 0!==a?a:0;this.y=void 0!==b?b:0}y.prototype.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};y.prototype.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};y.prototype.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};y.prototype.scale=function(a,b){this.x*=a;this.y*="number"===typeof b?b:a;return this};function Oa(a,b){this.width=a;this.height=b}Oa.prototype.aspectRatio=function(){return this.width/this.height};Oa.prototype.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};Oa.prototype.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};Oa.prototype.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};
Oa.prototype.scale=function(a,b){this.width*=a;this.height*="number"===typeof b?b:a;return this};function Pa(a){return a?a.parentWindow||a.defaultView:window}function Qa(a,b){if(!a||!b)return!1;if(a.contains&&1==b.nodeType)return a==b||a.contains(b);if("undefined"!=typeof a.compareDocumentPosition)return a==b||!!(a.compareDocumentPosition(b)&16);for(;b&&a!=b;)b=b.parentNode;return b==a}
function Ra(a,b){if(a==b)return 0;if(a.compareDocumentPosition)return a.compareDocumentPosition(b)&2?1:-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?Sa(a,b):!c&&Qa(e,b)?-1*Ta(a,b):!d&&Qa(f,a)?Ta(b,a):(c?a.sourceIndex:e.sourceIndex)-(d?b.sourceIndex:f.sourceIndex)}d=B(a);c=d.createRange();c.selectNode(a);c.collapse(!0);a=d.createRange();a.selectNode(b);
a.collapse(!0);return c.compareBoundaryPoints(aa.Range.START_TO_END,a)}function Ta(a,b){var c=a.parentNode;if(c==b)return-1;for(;b.parentNode!=c;)b=b.parentNode;return Sa(b,a)}function Sa(a,b){for(;b=b.previousSibling;)if(b==a)return-1;return 1}function B(a){return 9==a.nodeType?a:a.ownerDocument||a.document}function Ua(a){this.a=a||aa.document||document}Ua.prototype.getElementsByTagName=function(a,b){return(b||this.a).getElementsByTagName(String(a))};function C(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(9==c||1==c){a=9==c?a.documentElement:a.firstChild;c=0;var d=[];for(b="";a;){do 1!=a.nodeType&&(b+=a.nodeValue),d[c++]=a;while(a=a.firstChild);for(;c&&!(a=d[--c].nextSibling););}}else b=a.nodeValue;return b}
function Va(a,b,c){if(null===b)return!0;try{if(!a.getAttribute)return!1}catch(d){return!1}return null==c?!!a.getAttribute(b):a.getAttribute(b,2)==c}function Wa(a,b,c,d,e){return Xa.call(null,a,b,ba(c)?c:null,ba(d)?d:null,e||new D)}
function Xa(a,b,c,d,e){b.getElementsByName&&d&&"name"==c?(b=b.getElementsByName(d),n(b,function(f){a.a(f)&&e.add(f)})):b.getElementsByClassName&&d&&"class"==c?(b=b.getElementsByClassName(d),n(b,function(f){f.className==d&&a.a(f)&&e.add(f)})):a instanceof E?Ya(a,b,c,d,e):b.getElementsByTagName&&(b=b.getElementsByTagName(a.f()),n(b,function(f){Va(f,c,d)&&e.add(f)}));return e}function Ya(a,b,c,d,e){for(b=b.firstChild;b;b=b.nextSibling)Va(b,c,d)&&a.a(b)&&e.add(b),Ya(a,b,c,d,e)};function D(){this.b=this.a=null;this.o=0}function Za(a){this.f=a;this.a=this.b=null}function $a(a,b){if(!a.a)return b;if(!b.a)return a;var c=a.a;b=b.a;for(var d=null,e,f=0;c&&b;)c.f==b.f?(e=c,c=c.a,b=b.a):0<Ra(c.f,b.f)?(e=b,b=b.a):(e=c,c=c.a),(e.b=d)?d.a=e:a.a=e,d=e,f++;for(e=c||b;e;)e.b=d,d=d.a=e,f++,e=e.a;a.b=d;a.o=f;return a}function ab(a,b){b=new Za(b);b.a=a.a;a.b?a.a.b=b:a.a=a.b=b;a.a=b;a.o++}D.prototype.add=function(a){a=new Za(a);a.b=this.b;this.a?this.b.a=a:this.a=this.b=a;this.b=a;this.o++};
function bb(a){return(a=a.a)?a.f:null}function cb(a){return(a=bb(a))?C(a):""}function F(a,b){return new db(a,!!b)}function db(a,b){this.f=a;this.b=(this.v=b)?a.b:a.a;this.a=null}function G(a){var b=a.b;if(null==b)return null;var c=a.a=b;a.b=a.v?b.b:b.a;return c.f};function H(a){this.l=a;this.b=this.i=!1;this.f=null}function I(a){return"\n "+a.toString().split("\n").join("\n ")}function eb(a,b){a.i=b}function fb(a,b){a.b=b}function J(a,b){a=a.a(b);return a instanceof D?+cb(a):+a}function K(a,b){a=a.a(b);return a instanceof D?cb(a):""+a}function gb(a,b){a=a.a(b);return a instanceof D?!!a.o:!!a};function hb(a,b,c){H.call(this,a.l);this.c=a;this.j=b;this.u=c;this.i=b.i||c.i;this.b=b.b||c.b;this.c==ib&&(c.b||c.i||4==c.l||0==c.l||!b.f?b.b||b.i||4==b.l||0==b.l||!c.f||(this.f={name:c.f.name,A:b}):this.f={name:b.f.name,A:c})}h(hb,H);
function jb(a,b,c,d,e){b=b.a(d);c=c.a(d);var f;if(b instanceof D&&c instanceof D){b=F(b);for(d=G(b);d;d=G(b))for(e=F(c),f=G(e);f;f=G(e))if(a(C(d),C(f)))return!0;return!1}if(b instanceof D||c instanceof D){b instanceof D?(e=b,d=c):(e=c,d=b);f=F(e);for(var g=typeof d,l=G(f);l;l=G(f)){switch(g){case "number":l=+C(l);break;case "boolean":l=!!C(l);break;case "string":l=C(l);break;default:throw Error("Illegal primitive type for comparison.");}if(e==b&&a(l,d)||e==c&&a(d,l))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)}hb.prototype.a=function(a){return this.c.s(this.j,this.u,a)};hb.prototype.toString=function(){var a="Binary Expression: "+this.c;a+=I(this.j);return a+=I(this.u)};function kb(a,b,c,d){this.O=a;this.J=b;this.l=c;this.s=d}kb.prototype.toString=function(){return this.O};var lb={};
function L(a,b,c,d){if(lb.hasOwnProperty(a))throw Error("Binary operator already created: "+a);a=new kb(a,b,c,d);return lb[a.toString()]=a}L("div",6,1,function(a,b,c){return J(a,c)/J(b,c)});L("mod",6,1,function(a,b,c){return J(a,c)%J(b,c)});L("*",6,1,function(a,b,c){return J(a,c)*J(b,c)});L("+",5,1,function(a,b,c){return J(a,c)+J(b,c)});L("-",5,1,function(a,b,c){return J(a,c)-J(b,c)});L("<",4,2,function(a,b,c){return jb(function(d,e){return d<e},a,b,c)});
L(">",4,2,function(a,b,c){return jb(function(d,e){return d>e},a,b,c)});L("<=",4,2,function(a,b,c){return jb(function(d,e){return d<=e},a,b,c)});L(">=",4,2,function(a,b,c){return jb(function(d,e){return d>=e},a,b,c)});var ib=L("=",3,2,function(a,b,c){return jb(function(d,e){return d==e},a,b,c,!0)});L("!=",3,2,function(a,b,c){return jb(function(d,e){return d!=e},a,b,c,!0)});L("and",2,2,function(a,b,c){return gb(a,c)&&gb(b,c)});L("or",1,2,function(a,b,c){return gb(a,c)||gb(b,c)});function mb(a,b){if(b.a.length&&4!=a.l)throw Error("Primary expression must evaluate to nodeset if filter has predicate(s).");H.call(this,a.l);this.c=a;this.j=b;this.i=a.i;this.b=a.b}h(mb,H);mb.prototype.a=function(a){a=this.c.a(a);return nb(this.j,a)};mb.prototype.toString=function(){var a="Filter:"+I(this.c);return a+=I(this.j)};function pb(a,b){if(b.length<a.I)throw Error("Function "+a.m+" expects at least"+a.I+" arguments, "+b.length+" given");if(null!==a.D&&b.length>a.D)throw Error("Function "+a.m+" expects at most "+a.D+" arguments, "+b.length+" given");a.N&&n(b,function(c,d){if(4!=c.l)throw Error("Argument "+d+" to function "+a.m+" is not of type Nodeset: "+c);});H.call(this,a.l);this.B=a;this.c=b;eb(this,a.i||ra(b,function(c){return c.i}));fb(this,a.M&&!b.length||a.L&&!!b.length||ra(b,function(c){return c.b}))}
h(pb,H);pb.prototype.a=function(a){return this.B.s.apply(null,sa(a,this.c))};pb.prototype.toString=function(){var a="Function: "+this.B;if(this.c.length){var b=qa(this.c,function(c,d){return c+I(d)},"Arguments:");a+=I(b)}return a};function qb(a,b,c,d,e,f,g,l){this.m=a;this.l=b;this.i=c;this.M=d;this.L=!1;this.s=e;this.I=f;this.D=void 0!==g?g:f;this.N=!!l}qb.prototype.toString=function(){return this.m};var rb={};
function M(a,b,c,d,e,f,g,l){if(rb.hasOwnProperty(a))throw Error("Function already created: "+a+".");rb[a]=new qb(a,b,c,d,e,f,g,l)}M("boolean",2,!1,!1,function(a,b){return gb(b,a)},1);M("ceiling",1,!1,!1,function(a,b){return Math.ceil(J(b,a))},1);M("concat",3,!1,!1,function(a,b){return qa(ta(arguments,1),function(c,d){return c+K(d,a)},"")},2,null);M("contains",2,!1,!1,function(a,b,c){b=K(b,a);a=K(c,a);return-1!=b.indexOf(a)},2);M("count",1,!1,!1,function(a,b){return b.a(a).o},1,1,!0);
M("false",2,!1,!1,function(){return!1},0);M("floor",1,!1,!1,function(a,b){return Math.floor(J(b,a))},1);M("id",4,!1,!1,function(a,b){var c=a.a,d=9==c.nodeType?c:c.ownerDocument;a=K(b,a).split(/\s+/);var e=[];n(a,function(g){g=d.getElementById(g);!g||0<=oa(e,g)||e.push(g)});e.sort(Ra);var f=new D;n(e,function(g){f.add(g)});return f},1);M("lang",2,!1,!1,function(){return!1},1);M("last",1,!0,!1,function(a){if(1!=arguments.length)throw Error("Function last expects ()");return a.f},0);
M("local-name",3,!1,!0,function(a,b){return(a=b?bb(b.a(a)):a.a)?a.localName||a.nodeName.toLowerCase():""},0,1,!0);M("name",3,!1,!0,function(a,b){return(a=b?bb(b.a(a)):a.a)?a.nodeName.toLowerCase():""},0,1,!0);M("namespace-uri",3,!0,!1,function(){return""},0,1,!0);M("normalize-space",3,!1,!0,function(a,b){return(b?K(b,a):C(a.a)).replace(/[\s\xa0]+/g," ").replace(/^\s+|\s+$/g,"")},0,1);M("not",2,!1,!1,function(a,b){return!gb(b,a)},1);M("number",1,!1,!0,function(a,b){return b?J(b,a):+C(a.a)},0,1);
M("position",1,!0,!1,function(a){return a.b},0);M("round",1,!1,!1,function(a,b){return Math.round(J(b,a))},1);M("starts-with",2,!1,!1,function(a,b,c){b=K(b,a);a=K(c,a);return 0==b.lastIndexOf(a,0)},2);M("string",3,!1,!0,function(a,b){return b?K(b,a):C(a.a)},0,1);M("string-length",1,!1,!0,function(a,b){return(b?K(b,a):C(a.a)).length},0,1);
M("substring",3,!1,!1,function(a,b,c,d){c=J(c,a);if(isNaN(c)||Infinity==c||-Infinity==c)return"";d=d?J(d,a):Infinity;if(isNaN(d)||-Infinity===d)return"";c=Math.round(c)-1;var e=Math.max(c,0);a=K(b,a);return Infinity==d?a.substring(e):a.substring(e,c+Math.round(d))},2,3);M("substring-after",3,!1,!1,function(a,b,c){b=K(b,a);a=K(c,a);c=b.indexOf(a);return-1==c?"":b.substring(c+a.length)},2);
M("substring-before",3,!1,!1,function(a,b,c){b=K(b,a);a=K(c,a);a=b.indexOf(a);return-1==a?"":b.substring(0,a)},2);M("sum",1,!1,!1,function(a,b){a=F(b.a(a));b=0;for(var c=G(a);c;c=G(a))b+=+C(c);return b},1,1,!0);M("translate",3,!1,!1,function(a,b,c,d){b=K(b,a);c=K(c,a);var e=K(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);M("true",2,!1,!1,function(){return!0},0);function E(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 sb(a){return"comment"==a||"text"==a||"processing-instruction"==a||"node"==a}E.prototype.a=function(a){return null===this.b||this.b==a.nodeType};E.prototype.f=function(){return this.j};
E.prototype.toString=function(){var a="Kind Test: "+this.j;null===this.c||(a+=I(this.c));return a};function tb(a){H.call(this,3);this.c=a.substring(1,a.length-1)}h(tb,H);tb.prototype.a=function(){return this.c};tb.prototype.toString=function(){return"Literal: "+this.c};function ub(a,b){this.m=a.toLowerCase();a="*"==this.m?"*":"http://www.w3.org/1999/xhtml";this.b=b?b.toLowerCase():a}ub.prototype.a=function(a){var b=a.nodeType;if(1!=b&&2!=b)return!1;b=void 0!==a.localName?a.localName:a.nodeName;return"*"!=this.m&&this.m!=b.toLowerCase()?!1:"*"==this.b?!0:this.b==(a.namespaceURI?a.namespaceURI.toLowerCase():"http://www.w3.org/1999/xhtml")};ub.prototype.f=function(){return this.m};
ub.prototype.toString=function(){return"Name Test: "+("http://www.w3.org/1999/xhtml"==this.b?"":this.b+":")+this.m};function vb(a){H.call(this,1);this.c=a}h(vb,H);vb.prototype.a=function(){return this.c};vb.prototype.toString=function(){return"Number: "+this.c};function wb(a,b){H.call(this,a.l);this.j=a;this.c=b;this.i=a.i;this.b=a.b;1==this.c.length&&(a=this.c[0],a.C||a.c!=xb||(a=a.u,"*"!=a.f()&&(this.f={name:a.f(),A:null})))}h(wb,H);function yb(){H.call(this,4)}h(yb,H);yb.prototype.a=function(a){var b=new D;a=a.a;9==a.nodeType?b.add(a):b.add(a.ownerDocument);return b};yb.prototype.toString=function(){return"Root Helper Expression"};function zb(){H.call(this,4)}h(zb,H);zb.prototype.a=function(a){var b=new D;b.add(a.a);return b};zb.prototype.toString=function(){return"Context Helper Expression"};
function Ab(a){return"/"==a||"//"==a}wb.prototype.a=function(a){var b=this.j.a(a);if(!(b instanceof D))throw Error("Filter expression must evaluate to nodeset.");a=this.c;for(var c=0,d=a.length;c<d&&b.o;c++){var e=a[c],f=F(b,e.c.v);if(e.i||e.c!=Bb)if(e.i||e.c!=Cb){var g=G(f);for(b=e.a(new na(g));null!=(g=G(f));)g=e.a(new na(g)),b=$a(b,g)}else g=G(f),b=e.a(new na(g));else{for(g=G(f);(b=G(f))&&(!g.contains||g.contains(b))&&b.compareDocumentPosition(g)&8;g=b);b=e.a(new na(g))}}return b};
wb.prototype.toString=function(){var a="Path Expression:"+I(this.j);if(this.c.length){var b=qa(this.c,function(c,d){return c+I(d)},"Steps:");a+=I(b)}return a};function Db(a,b){this.a=a;this.v=!!b}
function nb(a,b,c){for(c=c||0;c<a.a.length;c++)for(var d=a.a[c],e=F(b),f=b.o,g,l=0;g=G(e);l++){var k=a.v?f-l:l+1;g=d.a(new na(g,k,f));if("number"==typeof g)k=k==g;else if("string"==typeof g||"boolean"==typeof g)k=!!g;else if(g instanceof D)k=0<g.o;else throw Error("Predicate.evaluate returned an unexpected type.");if(!k){k=e;g=k.f;var q=k.a;if(!q)throw Error("Next must be called at least once before remove.");var p=q.b;q=q.a;p?p.a=q:g.a=q;q?q.b=p:g.b=p;g.o--;k.a=null}}return b}
Db.prototype.toString=function(){return qa(this.a,function(a,b){return a+I(b)},"Predicates:")};function N(a,b,c,d){H.call(this,4);this.c=a;this.u=b;this.j=c||new Db([]);this.C=!!d;b=this.j;b=0<b.a.length?b.a[0].f:null;a.R&&b&&(this.f={name:b.name,A:b.A});a:{a=this.j;for(b=0;b<a.a.length;b++)if(c=a.a[b],c.i||1==c.l||0==c.l){a=!0;break a}a=!1}this.i=a}h(N,H);
N.prototype.a=function(a){var b=a.a,c=this.f,d=null,e=null,f=0;c&&(d=c.name,e=c.A?K(c.A,a):null,f=1);if(this.C)if(this.i||this.c!=Eb)if(b=F((new N(Fb,new E("node"))).a(a)),c=G(b))for(a=this.s(c,d,e,f);null!=(c=G(b));)a=$a(a,this.s(c,d,e,f));else a=new D;else a=Wa(this.u,b,d,e),a=nb(this.j,a,f);else a=this.s(a.a,d,e,f);return a};N.prototype.s=function(a,b,c,d){a=this.c.B(this.u,a,b,c);return a=nb(this.j,a,d)};
N.prototype.toString=function(){var a="Step:"+I("Operator: "+(this.C?"//":"/"));this.c.m&&(a+=I("Axis: "+this.c));a+=I(this.u);if(this.j.a.length){var b=qa(this.j.a,function(c,d){return c+I(d)},"Predicates:");a+=I(b)}return a};function Gb(a,b,c,d){this.m=a;this.B=b;this.v=c;this.R=d}Gb.prototype.toString=function(){return this.m};var Hb={};function O(a,b,c,d){if(Hb.hasOwnProperty(a))throw Error("Axis already created: "+a);b=new Gb(a,b,c,!!d);return Hb[a]=b}
O("ancestor",function(a,b){for(var c=new D;b=b.parentNode;)a.a(b)&&ab(c,b);return c},!0);O("ancestor-or-self",function(a,b){var c=new D;do a.a(b)&&ab(c,b);while(b=b.parentNode);return c},!0);
var xb=O("attribute",function(a,b){var c=new D,d=a.f();if(b=b.attributes)if(a instanceof E&&null===a.b||"*"==d)for(a=0;d=b[a];a++)c.add(d);else(d=b.getNamedItem(d))&&c.add(d);return c},!1),Eb=O("child",function(a,b,c,d,e){c=ba(c)?c:null;d=ba(d)?d:null;e=e||new D;for(b=b.firstChild;b;b=b.nextSibling)Va(b,c,d)&&a.a(b)&&e.add(b);return e},!1,!0);O("descendant",Wa,!1,!0);
var Fb=O("descendant-or-self",function(a,b,c,d){var e=new D;Va(b,c,d)&&a.a(b)&&e.add(b);return Wa(a,b,c,d,e)},!1,!0),Bb=O("following",function(a,b,c,d){var e=new D;do for(var f=b;f=f.nextSibling;)Va(f,c,d)&&a.a(f)&&e.add(f),e=Wa(a,f,c,d,e);while(b=b.parentNode);return e},!1,!0);O("following-sibling",function(a,b){for(var c=new D;b=b.nextSibling;)a.a(b)&&c.add(b);return c},!1);O("namespace",function(){return new D},!1);
var Ib=O("parent",function(a,b){var c=new D;if(9==b.nodeType)return c;if(2==b.nodeType)return c.add(b.ownerElement),c;b=b.parentNode;a.a(b)&&c.add(b);return c},!1),Cb=O("preceding",function(a,b,c,d){var e=new D,f=[];do f.unshift(b);while(b=b.parentNode);for(var g=1,l=f.length;g<l;g++){var k=[];for(b=f[g];b=b.previousSibling;)k.unshift(b);for(var q=0,p=k.length;q<p;q++)b=k[q],Va(b,c,d)&&a.a(b)&&e.add(b),e=Wa(a,b,c,d,e)}return e},!0,!0);
O("preceding-sibling",function(a,b){for(var c=new D;b=b.previousSibling;)a.a(b)&&ab(c,b);return c},!0);var Jb=O("self",function(a,b){var c=new D;a.a(b)&&c.add(b);return c},!1);function Kb(a){H.call(this,1);this.c=a;this.i=a.i;this.b=a.b}h(Kb,H);Kb.prototype.a=function(a){return-J(this.c,a)};Kb.prototype.toString=function(){return"Unary Expression: -"+I(this.c)};function Lb(a){H.call(this,4);this.c=a;eb(this,ra(this.c,function(b){return b.i}));fb(this,ra(this.c,function(b){return b.b}))}h(Lb,H);Lb.prototype.a=function(a){var b=new D;n(this.c,function(c){c=c.a(a);if(!(c instanceof D))throw Error("Path expression must evaluate to NodeSet.");b=$a(b,c)});return b};Lb.prototype.toString=function(){return qa(this.c,function(a,b){return a+I(b)},"Union Expression:")};function Mb(a,b){this.a=a;this.b=b}function Nb(a){for(var b,c=[];;){P(a,"Missing right hand side of binary expression.");b=Ob(a);var d=w(a.a);if(!d)break;var e=(d=lb[d]||null)&&d.J;if(!e){a.a.a--;break}for(;c.length&&e<=c[c.length-1].J;)b=new hb(c.pop(),c.pop(),b);c.push(b,d)}for(;c.length;)b=new hb(c.pop(),c.pop(),b);return b}function P(a,b){if(Na(a.a))throw Error(b);}function Pb(a,b){a=w(a.a);if(a!=b)throw Error("Bad token, expected: "+b+" got: "+a);}
function Qb(a){a=w(a.a);if(")"!=a)throw Error("Bad token: "+a);}function Rb(a){a=w(a.a);if(2>a.length)throw Error("Unclosed literal string");return new tb(a)}
function Sb(a){var b=[];if(Ab(v(a.a))){var c=w(a.a);var d=v(a.a);if("/"==c&&(Na(a.a)||"."!=d&&".."!=d&&"@"!=d&&"*"!=d&&!/(?![0-9])[\w]/.test(d)))return new yb;d=new yb;P(a,"Missing next location step.");c=Tb(a,c);b.push(c)}else{a:{c=v(a.a);d=c.charAt(0);switch(d){case "$":throw Error("Variable reference not allowed in HTML XPath");case "(":w(a.a);c=Nb(a);P(a,'unclosed "("');Pb(a,")");break;case '"':case "'":c=Rb(a);break;default:if(isNaN(+c))if(!sb(c)&&/(?![0-9])[\w]/.test(d)&&"("==v(a.a,1)){c=w(a.a);
c=rb[c]||null;w(a.a);for(d=[];")"!=v(a.a);){P(a,"Missing function argument list.");d.push(Nb(a));if(","!=v(a.a))break;w(a.a)}P(a,"Unclosed function argument list.");Qb(a);c=new pb(c,d)}else{c=null;break a}else c=new vb(+w(a.a))}"["==v(a.a)&&(d=new Db(Ub(a)),c=new mb(c,d))}if(c)if(Ab(v(a.a)))d=c;else return c;else c=Tb(a,"/"),d=new zb,b.push(c)}for(;Ab(v(a.a));)c=w(a.a),P(a,"Missing next location step."),c=Tb(a,c),b.push(c);return new wb(d,b)}
function Tb(a,b){if("/"!=b&&"//"!=b)throw Error('Step op should be "/" or "//"');if("."==v(a.a)){var c=new N(Jb,new E("node"));w(a.a);return c}if(".."==v(a.a))return c=new N(Ib,new E("node")),w(a.a),c;if("@"==v(a.a)){var d=xb;w(a.a);P(a,"Missing attribute name")}else if("::"==v(a.a,1)){if(!/(?![0-9])[\w]/.test(v(a.a).charAt(0)))throw Error("Bad token: "+w(a.a));var e=w(a.a);d=Hb[e]||null;if(!d)throw Error("No axis with name: "+e);w(a.a);P(a,"Missing node name")}else d=Eb;e=v(a.a);if(/(?![0-9])[\w\*]/.test(e.charAt(0)))if("("==
v(a.a,1)){if(!sb(e))throw Error("Invalid node type: "+e);e=w(a.a);if(!sb(e))throw Error("Invalid type name: "+e);Pb(a,"(");P(a,"Bad nodetype");var f=v(a.a).charAt(0),g=null;if('"'==f||"'"==f)g=Rb(a);P(a,"Bad nodetype");Qb(a);e=new E(e,g)}else if(e=w(a.a),f=e.indexOf(":"),-1==f)e=new ub(e);else{g=e.substring(0,f);if("*"==g)var l="*";else if(l=a.b(g),!l)throw Error("Namespace prefix not declared: "+g);e=e.substr(f+1);e=new ub(e,l)}else throw Error("Bad token: "+w(a.a));a=new Db(Ub(a),d.v);return c||
new N(d,e,a,"//"==b)}function Ub(a){for(var b=[];"["==v(a.a);){w(a.a);P(a,"Missing predicate expression.");var c=Nb(a);b.push(c);P(a,"Unclosed predicate expression.");Pb(a,"]")}return b}function Ob(a){if("-"==v(a.a))return w(a.a),new Kb(Ob(a));var b=Sb(a);if("|"!=v(a.a))a=b;else{for(b=[b];"|"==w(a.a);)P(a,"Missing next union location path."),b.push(Sb(a));a.a.a--;a=new Lb(b)}return a};function Vb(a){switch(a.nodeType){case 1:return ka(Wb,a);case 9:return Vb(a.documentElement);case 11:case 10:case 6:case 12:return Xb;default:return a.parentNode?Vb(a.parentNode):Xb}}function Xb(){return null}function Wb(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?Wb(a.parentNode,b):null};function Yb(a,b){if(!a.length)throw Error("Empty XPath expression.");a=Ka(a);if(Na(a))throw Error("Invalid XPath expression.");b?"function"==da(b)||(b=ja(b.lookupNamespaceURI,b)):b=function(){return null};var c=Nb(new Mb(a,b));if(!Na(a))throw Error("Bad token: "+w(a));this.evaluate=function(d,e){d=c.a(new na(d));return new Q(d,e)}}
function Q(a,b){if(0==b)if(a instanceof D)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 D))throw Error("value could not be converted to the specified type");this.resultType=b;switch(b){case 2:this.stringValue=a instanceof D?cb(a):""+a;break;case 1:this.numberValue=a instanceof D?+cb(a):+a;break;case 3:this.booleanValue=a instanceof D?0<a.o:!!a;break;case 4:case 5:case 6:case 7:var c=
F(a);var d=[];for(var e=G(c);e;e=G(c))d.push(e);this.snapshotLength=a.o;this.invalidIteratorState=!1;break;case 8:case 9:this.singleNodeValue=bb(a);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>=d.length?null:d[f++]};this.snapshotItem=function(g){if(6!=b&&7!=b)throw Error("snapshotItem called with wrong result type");return g>=d.length||0>g?null:d[g]}}Q.ANY_TYPE=0;
Q.NUMBER_TYPE=1;Q.STRING_TYPE=2;Q.BOOLEAN_TYPE=3;Q.UNORDERED_NODE_ITERATOR_TYPE=4;Q.ORDERED_NODE_ITERATOR_TYPE=5;Q.UNORDERED_NODE_SNAPSHOT_TYPE=6;Q.ORDERED_NODE_SNAPSHOT_TYPE=7;Q.ANY_UNORDERED_NODE_TYPE=8;Q.FIRST_ORDERED_NODE_TYPE=9;function Zb(a){this.lookupNamespaceURI=Vb(a)}
function $b(a,b){a=a||aa;var c=a.Document&&a.Document.prototype||a.document;if(!c.evaluate||b)a.XPathResult=Q,c.evaluate=function(d,e,f,g){return(new Yb(d,f)).evaluate(e,g)},c.createExpression=function(d,e){return new Yb(d,e)},c.createNSResolver=function(d){return new Zb(d)}}ca("wgxpath.install",$b);ca("wgxpath.install",$b);var cc={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",
darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",
ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",
lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",
moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",
seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};var dc="backgroundColor borderTopColor borderRightColor borderBottomColor borderLeftColor color outlineColor".split(" "),ec=/#([0-9a-fA-F])([0-9a-fA-F])([0-9a-fA-F])/,fc=/^#(?:[0-9a-f]{3}){1,2}$/i,gc=/^(?:rgba)?\((\d{1,3}),\s?(\d{1,3}),\s?(\d{1,3}),\s?(0|1|0\.\d*)\)$/i,hc=/^(?:rgb)?\((0|[1-9]\d{0,2}),\s?(0|[1-9]\d{0,2}),\s?(0|[1-9]\d{0,2})\)$/i;function R(a,b){this.code=a;this.a=S[a]||ic;this.message=b||"";a=this.a.replace(/((?:^|\s+)[a-z])/g,function(c){return c.toUpperCase().replace(/^[\s\xa0]+/g,"")});b=a.length-5;if(0>b||a.indexOf("Error",b)!=b)a+="Error";this.name=a;a=Error(this.message);a.name=this.name;this.stack=a.stack||""}h(R,Error);var ic="unknown error",S={15:"element not selectable",11:"element not visible"};S[31]=ic;S[30]=ic;S[24]="invalid cookie domain";S[29]="invalid element coordinates";S[12]="invalid element state";
S[32]="invalid selector";S[51]="invalid selector";S[52]="invalid selector";S[17]="javascript error";S[405]="unsupported operation";S[34]="move target out of bounds";S[27]="no such alert";S[7]="no such element";S[8]="no such frame";S[23]="no such window";S[28]="script timeout";S[33]="session not created";S[10]="stale element reference";S[21]="timeout";S[25]="unable to set cookie";S[26]="unexpected alert open";S[13]=ic;S[9]="unknown command";var jc=Da(),kc=Ga()||t("iPod"),lc=t("iPad"),mc=t("Android")&&!(Ea()||Da()||t("Opera")||t("Silk")),nc=Ea(),oc=t("Safari")&&!(Ea()||t("Coast")||t("Opera")||t("Edge")||t("Edg/")||t("OPR")||Da()||t("Silk")||t("Android"))&&!(Ga()||t("iPad")||t("iPod"));function pc(a){return(a=a.exec(xa))?a[1]:""}var qc=function(){if(jc)return pc(/Firefox\/([0-9.]+)/);if(nc)return Ga()||t("iPad")||t("iPod")?pc(/CriOS\/([0-9.]+)/):pc(/Chrome\/([0-9.]+)/);if(oc&&!(Ga()||t("iPad")||t("iPod")))return pc(/Version\/([0-9.]+)/);if(kc||lc){var a=/Version\/(\S+).*Mobile\/(\S+)/.exec(xa);if(a)return a[1]+"."+a[2]}else if(mc)return(a=pc(/Android\s+([0-9.]+)/))?a:pc(/Version\/([0-9.]+)/);return""}();var rc=lc||kc,sc;if(mc){var tc=/Android\s+([0-9\.]+)/.exec(xa);sc=tc?tc[1]:"0"}else sc="0";var uc=sc;function vc(a,b){b&&"string"!==typeof b&&(b=b.toString());return!!a&&1==a.nodeType&&(!b||a.tagName.toUpperCase()==b)};var T={};T.G=function(){var a={T:"http://www.w3.org/2000/svg"};return function(b){return a[b]||null}}();
T.s=function(a,b,c){var d=B(a);if(!d.documentElement)return null;mc&&$b(Pa(d));try{for(var e=d.createNSResolver?d.createNSResolver(d.documentElement):T.G,f={},g=d.getElementsByTagName("*"),l=0;l<g.length;++l){var k=g[l],q=k.namespaceURI;if(q&&!f[q]){var p=k.lookupPrefix(q);if(!p){var z=q.match(".*/(\\w+)/?$");p=z?z[1]:"xhtml"}f[q]=p}}var A={},r;for(r in f)A[f[r]]=r;e=function(m){return A[m]||null};try{return d.evaluate(b,a,e,c,null)}catch(m){if("TypeError"===m.name)return e=d.createNSResolver?d.createNSResolver(d.documentElement):
T.G,d.evaluate(b,a,e,c,null);throw m;}}catch(m){throw new R(32,"Unable to locate an element with the xpath expression "+b+" because of the following error:\n"+m);}};T.H=function(a,b){if(!a||1!=a.nodeType)throw new R(32,'The result of the xpath expression "'+b+'" is: '+a+". It should be an element.");};
T.P=function(a,b){var c=function(){var d=T.s(b,a,9);return d?d.singleNodeValue||null:b.selectSingleNode?(d=B(b),d.setProperty&&d.setProperty("SelectionLanguage","XPath"),b.selectSingleNode(a)):null}();null===c||T.H(c,a);return c};
T.S=function(a,b){var c=function(){var d=T.s(b,a,7);if(d){for(var e=d.snapshotLength,f=[],g=0;g<e;++g)f.push(d.snapshotItem(g));return f}return b.selectNodes?(d=B(b),d.setProperty&&d.setProperty("SelectionLanguage","XPath"),b.selectNodes(a)):[]}();n(c,function(d){T.H(d,a)});return c};function wc(a,b,c,d){this.b=a;this.f=b;this.c=c;this.a=d}wc.prototype.ceil=function(){this.b=Math.ceil(this.b);this.f=Math.ceil(this.f);this.c=Math.ceil(this.c);this.a=Math.ceil(this.a);return this};wc.prototype.floor=function(){this.b=Math.floor(this.b);this.f=Math.floor(this.f);this.c=Math.floor(this.c);this.a=Math.floor(this.a);return this};wc.prototype.round=function(){this.b=Math.round(this.b);this.f=Math.round(this.f);this.c=Math.round(this.c);this.a=Math.round(this.a);return this};
wc.prototype.scale=function(a,b){b="number"===typeof b?b:a;this.a*=a;this.f*=a;this.b*=b;this.c*=b;return this};function U(a,b,c,d){this.a=a;this.b=b;this.width=c;this.height=d}U.prototype.ceil=function(){this.a=Math.ceil(this.a);this.b=Math.ceil(this.b);this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};U.prototype.floor=function(){this.a=Math.floor(this.a);this.b=Math.floor(this.b);this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};
U.prototype.round=function(){this.a=Math.round(this.a);this.b=Math.round(this.b);this.width=Math.round(this.width);this.height=Math.round(this.height);return this};U.prototype.scale=function(a,b){b="number"===typeof b?b:a;this.a*=a;this.width*=a;this.b*=b;this.height*=b;return this};function xc(a,b){var c=B(a);return c.defaultView&&c.defaultView.getComputedStyle&&(a=c.defaultView.getComputedStyle(a,null))?a[b]||a.getPropertyValue(b)||"":""};function yc(a){for(a=a.parentNode;a&&1!=a.nodeType&&9!=a.nodeType&&11!=a.nodeType;)a=a.parentNode;return vc(a)?a:null}
function zc(a,b){b=Fa(b);if("float"==b||"cssFloat"==b||"styleFloat"==b)b="cssFloat";a=xc(a,b)||Ac(a,b);if(null===a)a=null;else if(0<=oa(dc,b)){b:{var c=a.match(gc);if(c){b=Number(c[1]);var d=Number(c[2]),e=Number(c[3]);c=Number(c[4]);if(0<=b&&255>=b&&0<=d&&255>=d&&0<=e&&255>=e&&0<=c&&1>=c){b=[b,d,e,c];break b}}b=null}if(!b)b:{if(e=a.match(hc))if(b=Number(e[1]),d=Number(e[2]),e=Number(e[3]),0<=b&&255>=b&&0<=d&&255>=d&&0<=e&&255>=e){b=[b,d,e,1];break b}b=null}if(!b)b:{b=a.toLowerCase();d=cc[b.toLowerCase()];
if(!d&&(d="#"==b.charAt(0)?b:"#"+b,4==d.length&&(d=d.replace(ec,"#$1$1$2$2$3$3")),!fc.test(d))){b=null;break b}b=[parseInt(d.substr(1,2),16),parseInt(d.substr(3,2),16),parseInt(d.substr(5,2),16),1]}a=b?"rgba("+b.join(", ")+")":a}return a}function Ac(a,b){var c=a.currentStyle||a.style,d=c[b];void 0===d&&"function"==da(c.getPropertyValue)&&(d=c.getPropertyValue(b));return"inherit"!=d?void 0!==d?d:null:(a=yc(a))?Ac(a,b):null}
function Bc(a,b){function c(m){function x(ob){if(ob==g)return!0;var ac=zc(ob,"display");return 0==ac.lastIndexOf("inline",0)||"contents"==ac||"absolute"==bc&&"static"==zc(ob,"position")?!1:!0}var bc=zc(m,"position");if("fixed"==bc)return q=!0,m==g?null:g;for(m=yc(m);m&&!x(m);)m=yc(m);return m}function d(m){var x=m;if("visible"==k)if(m==g&&l)x=l;else if(m==l)return{x:"visible",y:"visible"};x={x:zc(x,"overflow-x"),y:zc(x,"overflow-y")};m==g&&(x.x="visible"==x.x?"auto":x.x,x.y="visible"==x.y?"auto":
x.y);return x}function e(m){if(m==g){var x=(new Ua(f)).a;m=x.scrollingElement?x.scrollingElement:x.body||x.documentElement;x=x.parentWindow||x.defaultView;m=new y(x.pageXOffset||m.scrollLeft,x.pageYOffset||m.scrollTop)}else m=new y(m.scrollLeft,m.scrollTop);return m}b=Cc(a,b);var f=B(a),g=f.documentElement,l=f.body,k=zc(g,"overflow"),q;for(a=c(a);a;a=c(a)){var p=d(a);if("visible"!=p.x||"visible"!=p.y){var z=Dc(a);if(0==z.width||0==z.height)return"hidden";var A=b.f<z.a,r=b.c<z.b;if(A&&"hidden"==p.x||
r&&"hidden"==p.y)return"hidden";if(A&&"visible"!=p.x||r&&"visible"!=p.y){A=e(a);r=b.c<z.b-A.y;if(b.f<z.a-A.x&&"visible"!=p.x||r&&"visible"!=p.x)return"hidden";b=Bc(a);return"hidden"==b?"hidden":"scroll"}A=b.a>=z.a+z.width;z=b.b>=z.b+z.height;if(A&&"hidden"==p.x||z&&"hidden"==p.y)return"hidden";if(A&&"visible"!=p.x||z&&"visible"!=p.y){if(q&&(p=e(a),b.a>=g.scrollWidth-p.x||b.f>=g.scrollHeight-p.y))return"hidden";b=Bc(a);return"hidden"==b?"hidden":"scroll"}}}return"none"}
function Dc(a){var b;var c=vc(a,"MAP");if(c||vc(a,"AREA")){var d=c?a:vc(a.parentNode,"MAP")?a.parentNode:null,e=b=null;if(d&&d.name&&(b=T.P('/descendant::*[@usemap = "#'+d.name+'"]',B(d)))&&(e=Dc(b),!c&&"default"!=a.shape.toLowerCase())){c=Ec(a);d=Math.min(Math.max(c.a,0),e.width);var f=Math.min(Math.max(c.b,0),e.height);e=new U(d+e.a,f+e.b,Math.min(c.width,e.width-d),Math.min(c.height,e.height-f))}b={image:b,rect:e||new U(0,0,0,0)}}else b=null;if(b)return b.rect;if(vc(a,"HTML"))return a=(Pa(B(a))||
window).document,a="CSS1Compat"==a.compatMode?a.documentElement:a.body,a=new Oa(a.clientWidth,a.clientHeight),new U(0,0,a.width,a.height);try{var g=a.getBoundingClientRect()}catch(l){return new U(0,0,0,0)}return new U(g.left,g.top,g.right-g.left,g.bottom-g.top)}
function Ec(a){var b=a.shape.toLowerCase();a=a.coords.split(",");if("rect"==b&&4==a.length){b=a[0];var c=a[1];return new U(b,c,a[2]-b,a[3]-c)}if("circle"==b&&3==a.length)return b=a[2],new U(a[0]-b,a[1]-b,2*b,2*b);if("poly"==b&&2<a.length){b=a[0];c=a[1];for(var d=b,e=c,f=2;f+1<a.length;f+=2)b=Math.min(b,a[f]),d=Math.max(d,a[f]),c=Math.min(c,a[f+1]),e=Math.max(e,a[f+1]);return new U(b,c,d-b,e-c)}return new U(0,0,0,0)}
function Cc(a,b){a=Dc(a);a=new wc(a.b,a.a+a.width,a.b+a.height,a.a);b&&(b=b instanceof U?b:new U(b.x,b.y,1,1),a.a=Math.min(Math.max(a.a+b.a,a.a),a.f),a.b=Math.min(Math.max(a.b+b.b,a.b),a.c),a.f=Math.min(Math.max(a.a+b.width,a.a),a.f),a.c=Math.min(Math.max(a.b+b.height,a.b),a.c));return a};var Fc=aa.JSON.stringify;function Gc(a){function b(c,d){switch(da(c)){case "string":case "number":case "boolean":return c;case "function":return c.toString();case "array":return pa(c,function(f){return b(f,d)});case "object":if(0<=d.indexOf(c))throw new R(17,"Recursive object cannot be transferred");if(u(c,"nodeType")&&(1==c.nodeType||9==c.nodeType)){var e={};e.ELEMENT=Hc(c);return e}if(u(c,"document"))return e={},e.WINDOW=Hc(c),e;d.push(c);if(ea(c))return pa(c,function(f){return b(f,d)});c=Aa(c,function(f,g){return"number"==
typeof g||ba(g)});return Ba(c,function(f){return b(f,d)});default:return null}}return b(a,[])}function Ic(a,b){return"array"==da(a)?pa(a,function(c){return Ic(c,b)}):fa(a)?"function"==typeof a?a:u(a,"ELEMENT")?Jc(a.ELEMENT,b):u(a,"WINDOW")?Jc(a.WINDOW,b):Ba(a,function(c){return Ic(c,b)}):a}function Kc(a){a=a||document;var b=a.$wdc_;b||(b=a.$wdc_={},b.F=la());b.F||(b.F=la());return b}function Hc(a){var b=Kc(a.ownerDocument),c=Ca(b,function(d){return d==a});c||(c=":wdc:"+b.F++,b[c]=a);return c}
function Jc(a,b){a=decodeURIComponent(a);b=b||document;var c=Kc(b);if(!u(c,a))throw new R(10,"Element does not exist in cache");var d=c[a];if(u(d,"setInterval")){if(d.closed)throw delete c[a],new R(23,"Window has been closed.");return d}for(var e=d;e;){if(e==b.documentElement)return d;e.host&&11===e.nodeType&&(e=e.host);e=e.parentNode}delete c[a];throw new R(10,"Element is no longer attached to the DOM");};var Lc=mc?!(mc?0<=va(uc):0<=va(qc)):!rc;function V(a,b,c){this.a=a;this.b=b;this.f=c}V.prototype.create=function(a){a=B(a).createEvent("HTMLEvents");a.initEvent(this.a,this.b,this.f);return a};V.prototype.toString=function(){return this.a};function W(a,b,c){ma(this,a,b,c)}h(W,V);
W.prototype.create=function(a,b){if(this==Mc)throw new R(9,"Browser does not support a mouse pixel scroll event.");var c=B(a);a=Pa(c);c=c.createEvent("MouseEvents");this==Nc&&(c.wheelDelta=b.wheelDelta);c.initMouseEvent(this.a,this.b,this.f,a,1,b.clientX,b.clientY,b.clientX,b.clientY,b.ctrlKey,b.altKey,b.shiftKey,b.metaKey,b.button,b.relatedTarget);return c};function Oc(a,b,c){ma(this,a,b,c)}h(Oc,V);
Oc.prototype.create=function(a,b){a=B(a).createEvent("Events");a.initEvent(this.a,this.b,this.f);a.altKey=b.altKey;a.ctrlKey=b.ctrlKey;a.metaKey=b.metaKey;a.shiftKey=b.shiftKey;a.keyCode=b.charCode||b.keyCode;a.charCode=this==Pc?a.keyCode:0;return a};function Qc(a,b,c){ma(this,a,b,c)}h(Qc,V);
Qc.prototype.create=function(a,b){function c(A){A=pa(A,function(r){return g.createTouch(l,a,r.identifier,r.pageX,r.pageY,r.screenX,r.screenY)});return g.createTouchList.apply(g,A)}function d(A){var r=pa(A,function(m){return{identifier:m.identifier,screenX:m.screenX,screenY:m.screenY,clientX:m.clientX,clientY:m.clientY,pageX:m.pageX,pageY:m.pageY,target:a}});r.item=function(m){return r[m]};return r}function e(A){return pa(A,function(r){return new Touch({identifier:r.identifier,screenX:r.screenX,screenY:r.screenY,
clientX:r.clientX,clientY:r.clientY,pageX:r.pageX,pageY:r.pageY,target:a})})}function f(A,r){switch(A){case 1:return d(r);case 2:return c(r);case 3:return e(r)}return null}var g=B(a),l=Pa(g);if(Lc)var k=1;else if(TouchEvent.prototype.initTouchEvent)k=2;else if(TouchEvent&&0<TouchEvent.length)k=3;else throw new R(9,"Not able to create touch events in this browser");var q=f(k,b.changedTouches),p=b.touches==b.changedTouches?q:f(k,b.touches),z=b.targetTouches==b.changedTouches?q:f(k,b.targetTouches);
if(1==k)k=g.createEvent("MouseEvents"),k.initMouseEvent(this.a,this.b,this.f,l,1,0,0,b.clientX,b.clientY,b.ctrlKey,b.altKey,b.shiftKey,b.metaKey,0,b.relatedTarget),k.touches=p,k.targetTouches=z,k.changedTouches=q,k.scale=b.scale,k.rotation=b.rotation;else if(2==k)k=g.createEvent("TouchEvent"),0==k.initTouchEvent.length?k.initTouchEvent(p,z,q,this.a,l,0,0,b.clientX,b.clientY,b.ctrlKey,b.altKey,b.shiftKey,b.metaKey):k.initTouchEvent(this.a,this.b,this.f,l,1,0,0,b.clientX,b.clientY,b.ctrlKey,b.altKey,
b.shiftKey,b.metaKey,p,z,q,b.scale,b.rotation),k.relatedTarget=b.relatedTarget;else if(3==k)k=new TouchEvent(this.a,{touches:p,targetTouches:z,changedTouches:q,bubbles:this.b,cancelable:this.f,ctrlKey:b.ctrlKey,shiftKey:b.shiftKey,altKey:b.altKey,metaKey:b.metaKey});else throw new R(9,"Illegal TouchEventStrategy_ value (this is a bug)");return k};function X(a,b,c){ma(this,a,b,c)}h(X,V);X.prototype.create=function(){throw new R(9,"Browser does not support MSGesture events.");};
function Y(a,b,c){ma(this,a,b,c)}h(Y,V);Y.prototype.create=function(){throw new R(9,"Browser does not support MSPointer events.");};new W("click",!0,!0);new W("contextmenu",!0,!0);new W("dblclick",!0,!0);new W("mousedown",!0,!0);new W("mousemove",!0,!1);new W("mouseout",!0,!0);new W("mouseover",!0,!0);new W("mouseup",!0,!0);var Nc=new W("mousewheel",!0,!0),Mc=new W("MozMousePixelScroll",!0,!0);new Oc("keydown",!0,!0);var Pc=new Oc("keypress",!0,!0);new Oc("keyup",!0,!0);new Qc("touchend",!0,!0);
new Qc("touchmove",!0,!0);new Qc("touchstart",!0,!0);new X("MSGestureChange",!0,!0);new X("MSGestureEnd",!0,!0);new X("MSGestureHold",!0,!0);new X("MSGestureStart",!0,!0);new X("MSGestureTap",!0,!0);new X("MSInertiaStart",!0,!0);new Y("MSGotPointerCapture",!0,!1);new Y("MSLostPointerCapture",!0,!1);new Y("MSPointerCancel",!0,!0);new Y("MSPointerDown",!0,!0);new Y("MSPointerMove",!0,!0);new Y("MSPointerOver",!0,!0);new Y("MSPointerOut",!0,!0);new Y("MSPointerUp",!0,!0);function Rc(a,b){this.b={};this.a=[];this.f=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)this.set(arguments[d],arguments[d+1])}else if(a)if(a instanceof Rc)for(c=Sc(a),d=0;d<c.length;d++)this.set(c[d],a.get(c[d]));else for(d in a)this.set(d,a[d])}
function Sc(a){if(a.f!=a.a.length){for(var b=0,c=0;b<a.a.length;){var d=a.a[b];Object.prototype.hasOwnProperty.call(a.b,d)&&(a.a[c++]=d);b++}a.a.length=c}if(a.f!=a.a.length){var e={};for(c=b=0;b<a.a.length;)d=a.a[b],Object.prototype.hasOwnProperty.call(e,d)||(a.a[c++]=d,e[d]=1),b++;a.a.length=c}return a.a.concat()}Rc.prototype.get=function(a,b){return Object.prototype.hasOwnProperty.call(this.b,a)?this.b[a]:b};
Rc.prototype.set=function(a,b){Object.prototype.hasOwnProperty.call(this.b,a)||(this.f++,this.a.push(a));this.b[a]=b};var Tc={};function Z(a,b,c){fa(a)&&(a=a.g);a=new Uc(a);!b||b in Tc&&!c||(Tc[b]={key:a,shift:!1},c&&(Tc[c]={key:a,shift:!0}));return a}function Uc(a){this.code=a}Z(8);Z(9);Z(13);var Vc=Z(16),Wc=Z(17),Xc=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 Yc=Z(Ia?{h:91,g:91}:Ha?{h:224,g:91}:{h:0,g:91});Z(Ia?{h:92,g:92}:Ha?{h:224,g:93}:{h:0,g:92});Z(Ia?{h:93,g:93}:Ha?{h:0,g:0}:{h:93,g:null});Z({h:96,g:96},"0");Z({h:97,g:97},"1");
Z({h:98,g:98},"2");Z({h:99,g:99},"3");Z({h:100,g:100},"4");Z({h:101,g:101},"5");Z({h:102,g:102},"6");Z({h:103,g:103},"7");Z({h:104,g:104},"8");Z({h:105,g:105},"9");Z({h:106,g:106},"*");Z({h:107,g:107},"+");Z({h:109,g:109},"-");Z({h:110,g:110},".");Z({h: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({h:107,g:187},"=","+");Z(108,",");Z({h:109,g:189},"-","_");Z(188,",","<");Z(190,".",">");Z(191,"/","?");Z(192,"`","~");Z(219,"[","{");
Z(220,"\\","|");Z(221,"]","}");Z({h:59,g:186},";",":");Z(222,"'",'"');var Zc=new Rc;Zc.set(1,Vc);Zc.set(2,Wc);Zc.set(4,Xc);Zc.set(8,Yc);(function(a){var b=new Rc;n(Sc(a),function(c){b.set(a.get(c).code,c)});return b})(Zc);function $c(a,b){a:if("scroll"==Bc(a,b)){if(a.scrollIntoView&&(a.scrollIntoView(),"none"==Bc(a,b)))break a;for(var c=Cc(a,b),d=yc(a);d;d=yc(d)){var e=d,f=Dc(e);var g=e;var l=xc(g,"borderLeftWidth");var k=xc(g,"borderRightWidth");var q=xc(g,"borderTopWidth");g=xc(g,"borderBottomWidth");k=new wc(parseFloat(q),parseFloat(k),parseFloat(g),parseFloat(l));l=c.a-f.a-k.a;f=c.b-f.b-k.b;k=e.clientHeight+c.b-c.c;e.scrollLeft+=Math.min(l,Math.max(l-(e.clientWidth+c.a-c.f),0));e.scrollTop+=Math.min(f,Math.max(f-
k,0))}Bc(a,b)}a=Cc(a,b);return new y(a.a,a.b)};ca("_",function(a,b){a=[a];try{var c;b?c=Jc(b.WINDOW):c=window;var d=Ic(a,c.document),e=$c.apply(null,d);var f={status:0,value:Gc(e)}}catch(g){f={status:u(g,"code")?g.code:13,value:{message:g.message}}}return Fc(f)});; return this._.apply(null,arguments);}).apply(window, arguments);}