forked from igorlino/annotorious-bower
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathannotorious.min.js
255 lines (246 loc) · 102 KB
/
annotorious.min.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
;(function() {
var f,m=this;function n(a){return void 0!==a}function aa(a,b){var c=a.split("."),d=m;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)!c.length&&n(b)?d[e]=b:d=d[e]?d[e]:d[e]={}}function ba(){}function ca(a){a.ic=function(){return a.de?a.de:a.de=new a}}
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){return"array"==da(a)}function fa(a){var b=da(a);return"array"==b||"object"==b&&"number"==typeof a.length}function p(a){return"string"==typeof a}function q(a){return"number"==typeof a}function r(a){return"function"==da(a)}function ga(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}function ha(a){return a[ia]||(a[ia]=++ja)}var ia="closure_uid_"+(1E9*Math.random()>>>0),ja=0;
function ka(a,b,c){return a.call.apply(a.bind,arguments)}function la(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 ma(a,b,c){ma=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ka:la;return ma.apply(null,arguments)}
function na(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)}}function u(a,b){function c(){}c.prototype=b.prototype;a.w=b.prototype;a.prototype=new c;a.prototype.constructor=a;a.mf=function(a,c,g){for(var h=Array(arguments.length-2),k=2;k<arguments.length;k++)h[k-2]=arguments[k];return b.prototype[c].apply(a,h)}};var oa;var pa=String.prototype.trim?function(a){return a.trim()}:function(a){return a.replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")};function qa(a){if(!ra.test(a))return a;-1!=a.indexOf("\x26")&&(a=a.replace(sa,"\x26amp;"));-1!=a.indexOf("\x3c")&&(a=a.replace(ta,"\x26lt;"));-1!=a.indexOf("\x3e")&&(a=a.replace(ua,"\x26gt;"));-1!=a.indexOf('"')&&(a=a.replace(va,"\x26quot;"));-1!=a.indexOf("'")&&(a=a.replace(ya,"\x26#39;"));-1!=a.indexOf("\x00")&&(a=a.replace(za,"\x26#0;"));return a}
var sa=/&/g,ta=/</g,ua=/>/g,va=/"/g,ya=/'/g,za=/\x00/g,ra=/[\x00&<>"']/;function Aa(a,b){return a<b?-1:a>b?1:0}function Ba(a){return String(a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()})}function Ca(a){var b=p(void 0)?"undefined".replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08"):"\\s";return a.replace(new RegExp("(^"+(b?"|["+b+"]+":"")+")([a-z])","g"),function(a,b,e){return b+e.toUpperCase()})};var Da=Array.prototype.indexOf?function(a,b,c){return Array.prototype.indexOf.call(a,b,c)}:function(a,b,c){c=null==c?0:0>c?Math.max(0,a.length+c):c;if(p(a))return p(b)&&1==b.length?a.indexOf(b,c):-1;for(;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},w=Array.prototype.forEach?function(a,b,c){Array.prototype.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=p(a)?a.split(""):a,g=0;g<d;g++)g in e&&b.call(c,e[g],g,a)},Ea=Array.prototype.filter?function(a,b,c){return Array.prototype.filter.call(a,
b,c)}:function(a,b,c){for(var d=a.length,e=[],g=0,h=p(a)?a.split(""):a,k=0;k<d;k++)if(k in h){var l=h[k];b.call(c,l,k,a)&&(e[g++]=l)}return e},Fa=Array.prototype.map?function(a,b,c){return Array.prototype.map.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=Array(d),g=p(a)?a.split(""):a,h=0;h<d;h++)h in g&&(e[h]=b.call(c,g[h],h,a));return e},Ga=Array.prototype.every?function(a,b,c){return Array.prototype.every.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=p(a)?a.split(""):a,g=0;g<d;g++)if(g in
e&&!b.call(c,e[g],g,a))return!1;return!0};function Ha(a,b){var c;a:{c=a.length;for(var d=p(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:p(a)?a.charAt(c):a[c]}function Ia(a,b){return 0<=Da(a,b)}function y(a,b){var c=Da(a,b),d;(d=0<=c)&&Array.prototype.splice.call(a,c,1);return d}function Ja(a){var b=a.length;if(0<b){for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}return[]}
function Ka(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(fa(d)){var e=a.length||0,g=d.length||0;a.length=e+g;for(var h=0;h<g;h++)a[e+h]=d[h]}else a.push(d)}}function Pa(a,b,c){return 2>=arguments.length?Array.prototype.slice.call(a,b):Array.prototype.slice.call(a,b,c)}function Qa(a,b){a.sort(b||Ra)}function Ra(a,b){return a>b?1:a<b?-1:0};var Sa;a:{var Ta=m.navigator;if(Ta){var Ua=Ta.userAgent;if(Ua){Sa=Ua;break a}}Sa=""}function z(a){return-1!=Sa.indexOf(a)};function Va(a,b,c){for(var d in a)b.call(c,a[d],d,a)}function Wa(a,b){for(var c in a)if(b.call(void 0,a[c],c,a))return!0;return!1}var Xa="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Ya(a,b){for(var c,d,e=1;e<arguments.length;e++){d=arguments[e];for(c in d)a[c]=d[c];for(var g=0;g<Xa.length;g++)c=Xa[g],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}};var Za=z("Opera")||z("OPR"),A=z("Trident")||z("MSIE"),$a=z("Edge"),D=z("Gecko")&&!(-1!=Sa.toLowerCase().indexOf("webkit")&&!z("Edge"))&&!(z("Trident")||z("MSIE"))&&!z("Edge"),E=-1!=Sa.toLowerCase().indexOf("webkit")&&!z("Edge"),ab=z("Macintosh");function bb(){var a=Sa;if(D)return/rv\:([^\);]+)(\)|;)/.exec(a);if($a)return/Edge\/([\d\.]+)/.exec(a);if(A)return/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(a);if(E)return/WebKit\/(\S+)/.exec(a)}function cb(){var a=m.document;return a?a.documentMode:void 0}
var db=function(){if(Za&&m.opera){var a;var b=m.opera.version;try{a=b()}catch(c){a=b}return a}a="";(b=bb())&&(a=b?b[1]:"");return A&&(b=cb(),b>parseFloat(a))?String(b):a}(),eb={};
function F(a){var b;if(!(b=eb[a])){b=0;for(var c=pa(String(db)).split("."),d=pa(String(a)).split("."),e=Math.max(c.length,d.length),g=0;0==b&&g<e;g++){var h=c[g]||"",k=d[g]||"",l=RegExp("(\\d*)(\\D*)","g"),t=RegExp("(\\d*)(\\D*)","g");do{var B=l.exec(h)||["","",""],C=t.exec(k)||["","",""];if(0==B[0].length&&0==C[0].length)break;b=Aa(0==B[1].length?0:parseInt(B[1],10),0==C[1].length?0:parseInt(C[1],10))||Aa(0==B[2].length,0==C[2].length)||Aa(B[2],C[2])}while(0==b)}b=eb[a]=0<=b}return b}
var fb=m.document,jb=fb&&A?cb()||("CSS1Compat"==fb.compatMode?parseInt(db,10):5):void 0;var kb=!A||9<=jb;!D&&!A||A&&9<=jb||D&&F("1.9.1");A&&F("9");var lb=A||Za||E;function mb(){this.Xe="";this.ue=nb}var nb={};function ob(){this.We="";this.te=pb;this.Ce=null}var pb={};function G(a,b){this.x=n(a)?a:0;this.y=n(b)?b:0}f=G.prototype;f.clone=function(){return new G(this.x,this.y)};f.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};f.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};f.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};f.translate=function(a,b){a instanceof G?(this.x+=a.x,this.y+=a.y):(this.x+=a,q(b)&&(this.y+=b));return this};
f.scale=function(a,b){var c=q(b)?b:a;this.x*=a;this.y*=c;return this};function qb(a,b){this.width=a;this.height=b}f=qb.prototype;f.clone=function(){return new qb(this.width,this.height)};f.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};f.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};f.scale=function(a,b){var c=q(b)?b:a;this.width*=a;this.height*=c;return this};function rb(a){return a?new sb(H(a)):oa||(oa=new sb)}function tb(){var a=document,b=null;return(b=a.getElementsByClassName?a.getElementsByClassName("openseadragon-container")[0]:a.querySelectorAll&&a.querySelector?a.querySelector(".openseadragon-container"):ub()[0])||null}
function ub(){var a,b,c,d;a=document;if(a.querySelectorAll&&a.querySelector)return a.querySelectorAll(".openseadragon-container");if(a.getElementsByClassName){var e=a.getElementsByClassName("openseadragon-container");return e}e=a.getElementsByTagName("*");d={};for(b=c=0;a=e[b];b++){var g=a.className;"function"==typeof g.split&&Ia(g.split(/\s+/),"openseadragon-container")&&(d[c++]=a)}d.length=c;return d}
function vb(a,b){Va(b,function(b,d){"style"==d?a.style.cssText=b:"class"==d?a.className=b:"for"==d?a.htmlFor=b:wb.hasOwnProperty(d)?a.setAttribute(wb[d],b):0==d.lastIndexOf("aria-",0)||0==d.lastIndexOf("data-",0)?a.setAttribute(d,b):a[d]=b})}var wb={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",frameborder:"frameBorder",height:"height",maxlength:"maxLength",role:"role",rowspan:"rowSpan",type:"type",usemap:"useMap",valign:"vAlign",width:"width"};
function xb(a,b,c){var d=arguments,e=document,g=d[0],h=d[1];if(!kb&&h&&(h.name||h.type)){g=["\x3c",g];h.name&&g.push(' name\x3d"',qa(h.name),'"');if(h.type){g.push(' type\x3d"',qa(h.type),'"');var k={};Ya(k,h);delete k.type;h=k}g.push("\x3e");g=g.join("")}g=e.createElement(g);h&&(p(h)?g.className=h:ea(h)?g.className=h.join(" "):vb(g,h));2<d.length&&yb(e,g,d,2);return g}
function yb(a,b,c,d){function e(c){c&&b.appendChild(p(c)?a.createTextNode(c):c)}for(;d<c.length;d++){var g=c[d];if(!fa(g)||ga(g)&&0<g.nodeType)e(g);else{var h;a:{if(g&&"number"==typeof g.length){if(ga(g)){h="function"==typeof g.item||"string"==typeof g.item;break a}if(r(g)){h="function"==typeof g.item;break a}}h=!1}w(h?Ja(g):g,e)}}}function zb(a){for(var b;b=a.firstChild;)a.removeChild(b)}function Ab(a){return a&&a.parentNode?a.parentNode.removeChild(a):null}
function Bb(a,b){var c=b.parentNode;c&&c.replaceChild(a,b)}function Cb(a){return ga(a)&&1==a.nodeType}function Db(a){var b;if(lb&&!(A&&F("9")&&!F("10")&&m.SVGElement&&a instanceof m.SVGElement)&&(b=a.parentElement))return b;b=a.parentNode;return Cb(b)?b:null}function Gb(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 H(a){return 9==a.nodeType?a:a.ownerDocument||a.document}function Hb(a,b){if("textContent"in a)a.textContent=b;else if(3==a.nodeType)a.data=b;else if(a.firstChild&&3==a.firstChild.nodeType){for(;a.lastChild!=a.firstChild;)a.removeChild(a.lastChild);a.firstChild.data=b}else zb(a),a.appendChild(H(a).createTextNode(String(b)))}function Ib(a,b){b?a.tabIndex=0:(a.tabIndex=-1,a.removeAttribute("tabIndex"))}function Jb(a){a=a.getAttributeNode("tabindex");return null!=a&&a.specified}
function Kb(a){a=a.tabIndex;return q(a)&&0<=a&&32768>a}function sb(a){this.W=a||m.document||document}f=sb.prototype;f.Wd=rb;f.c=function(a){return p(a)?this.W.getElementById(a):a};f.$=sb.prototype.c;f.wa=vb;f.createElement=function(a){return this.W.createElement(a)};f.createTextNode=function(a){return this.W.createTextNode(String(a))};
function Lb(a){var b=a.W;a=b.scrollingElement?b.scrollingElement:E?b.body||b.documentElement:b.documentElement;b=b.parentWindow||b.defaultView;return A&&F("10")&&b.pageYOffset!=a.scrollTop?new G(a.scrollLeft,a.scrollTop):new G(b.pageXOffset||a.scrollLeft,b.pageYOffset||a.scrollTop)}f.appendChild=function(a,b){a.appendChild(b)};f.append=function(a,b){yb(H(a),a,arguments,1)};f.canHaveChildren=function(a){if(1!=a.nodeType)return!1;switch(a.tagName){case "APPLET":case "AREA":case "BASE":case "BR":case "COL":case "COMMAND":case "EMBED":case "FRAME":case "HR":case "IMG":case "INPUT":case "IFRAME":case "ISINDEX":case "KEYGEN":case "LINK":case "NOFRAMES":case "NOSCRIPT":case "META":case "OBJECT":case "PARAM":case "SCRIPT":case "SOURCE":case "STYLE":case "TRACK":case "WBR":return!1}return!0};
f.removeNode=Ab;f.contains=Gb;f.cd=function(a){var b;(b="A"==a.tagName||"INPUT"==a.tagName||"TEXTAREA"==a.tagName||"SELECT"==a.tagName||"BUTTON"==a.tagName?!a.disabled&&(!Jb(a)||Kb(a)):Jb(a)&&Kb(a))&&A?(a=r(a.getBoundingClientRect)?a.getBoundingClientRect():{height:a.offsetHeight,width:a.offsetWidth},a=null!=a&&0<a.height&&0<a.width):a=b;return a};function Mb(){return!0};/*
Portions of this code are from the Dojo Toolkit, received by
The Closure Library Authors under the BSD license. All other code is
Copyright 2005-2009 The Closure Library Authors. All Rights Reserved.
The "New" BSD License:
Copyright (c) 2005-2009, The Dojo Foundation
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
Neither the name of the Dojo Foundation nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
var I=function(){function a(a,c){if(!a)return[];if(a.constructor==Array)return a;if(!p(a))return[a];if(p(c)&&(c=p(c)?document.getElementById(c):c,!c))return[];c=c||document;var e=c.ownerDocument||c.documentElement;Ma=c.contentType&&"application/xml"==c.contentType||Za&&(c.doctype||"[object XMLDocument]"==e.toString())||!!e&&(wa?e.xml:c.xmlVersion||e.xmlVersion);return(e=d(a)(c))&&e.tc?e:b(e)}function b(a){if(a&&a.tc)return a;var b=[];if(!a||!a.length)return b;a[0]&&b.push(a[0]);if(2>a.length)return b;
Z++;if(wa&&Ma){var c=Z+"";a[0].setAttribute("_zipIdx",c);for(var d=1,e;e=a[d];d++)a[d].getAttribute("_zipIdx")!=c&&b.push(e),e.setAttribute("_zipIdx",c)}else if(wa&&a.Be)try{for(d=1;e=a[d];d++)Eb(e)&&b.push(e)}catch(g){}else for(a[0]&&(a[0]._zipIdx=Z),d=1;e=a[d];d++)a[d]._zipIdx!=Z&&b.push(e),e._zipIdx=Z;return b}function c(a,b){if(!b)return 1;var c=kf(a);return b[c]?0:b[c]=1}function d(a,b){if(rd){var c=sd[a];if(c&&!b)return c}if(c=td[a])return c;var c=a.charAt(0),g=-1==a.indexOf(" ");0<=a.indexOf("#")&&
g&&(b=!0);if(!rd||b||-1!="\x3e~+".indexOf(c)||wa&&-1!=a.indexOf(":")||ud&&0<=a.indexOf(".")||-1!=a.indexOf(":contains")||-1!=a.indexOf("|\x3d")){var h=a.split(/\s*,\s*/);return td[a]=2>h.length?e(a):function(a){for(var b=0,c=[],d;d=h[b++];)c=c.concat(e(d)(a));return c}}var k=0<="\x3e~+".indexOf(a.charAt(a.length-1))?a+" *":a;return sd[a]=function(b){try{if(9!=b.nodeType&&!g)throw Error("");var c=b.querySelectorAll(k);wa?c.Be=!0:c.tc=!0;return c}catch(e){return d(a,!0)(b)}}}function e(a){var b=vd(pa(a));
if(1==b.length){var c=g(b[0]);return function(a){if(a=c(a,[]))a.tc=!0;return a}}return function(a){a=gb(a);for(var c,d,e=b.length,h,La,k=0;k<e;k++){La=[];c=b[k];d=a.length-1;0<d&&(h={},La.tc=!0);d=g(c);for(var qd=0;c=a[qd];qd++)d(c,La,h);if(!La.length)break;a=La}return La}}function g(a){var b=wd[a.ob];if(b)return b;var c=a.ce,c=c?c.uc:"",d=t(a,{S:1}),e="*"==a.tag,g=document.getElementsByClassName;if(c)g={S:1},e&&(g.tag=1),d=t(a,g),"+"==c?b=l(d):"~"==c?b=k(d):"\x3e"==c&&(b=h(d));else if(a.id)d=!a.ee&&
e?Mb:t(a,{S:1,id:1}),b=function(b,c){var e=rb(b).c(a.id),g;if((g=e&&d(e))&&!(g=9==b.nodeType)){for(g=e.parentNode;g&&g!=b;)g=g.parentNode;g=!!g}if(g)return gb(e,c)};else if(g&&/\{\s*\[native code\]\s*\}/.test(String(g))&&a.qa.length&&!ud)var d=t(a,{S:1,qa:1,id:1}),lf=a.qa.join(" "),b=function(a,b){for(var c=gb(0,b),e,g=0,h=a.getElementsByClassName(lf);e=h[g++];)d(e,a)&&c.push(e);return c};else e||a.ee?(d=t(a,{S:1,tag:1,id:1}),b=function(b,c){for(var e=gb(0,c),g,h=0,jf=b.getElementsByTagName(a.Zc());g=
jf[h++];)d(g,b)&&e.push(g);return e}):b=function(b,c){for(var d=gb(0,c),e,g=0,h=b.getElementsByTagName(a.Zc());e=h[g++];)d.push(e);return d};return wd[a.ob]=b}function h(a){a=a||Mb;return function(b,d,e){for(var g=0,h=b[xd];b=h[g++];)hb(b)&&(!e||c(b,e))&&a(b,g)&&d.push(b);return d}}function k(a){return function(b,d,e){for(b=b[ib];b;){if(hb(b)){if(e&&!c(b,e))break;a(b)&&d.push(b)}b=b[ib]}return d}}function l(a){return function(b,d,e){for(;b=b[ib];)if(!Fb||Eb(b)){e&&!c(b,e)||!a(b)||d.push(b);break}return d}}
function t(a,b){if(!a)return Mb;b=b||{};var c=null;b.S||(c=Na(c,Eb));b.tag||"*"!=a.tag&&(c=Na(c,function(b){return b&&b.tagName==a.Zc()}));b.qa||w(a.qa,function(a,b){var d=new RegExp("(?:^|\\s)"+a+"(?:\\s|$)");c=Na(c,function(a){return d.test(a.className)});c.count=b});b.Va||w(a.Va,function(a){var b=a.name;oc[b]&&(c=Na(c,oc[b](b,a.value)))});b.ac||w(a.ac,function(a){var b,d=a.Sc;a.type&&yd[a.type]?b=yd[a.type](d,a.kd):d.length&&(b=mf(d));b&&(c=Na(c,b))});b.id||a.id&&(c=Na(c,function(b){return!!b&&
b.id==a.id}));c||"default"in b||(c=Mb);return c}function B(a){return xa(a)%2}function C(a){return!(xa(a)%2)}function xa(a){var b=a.parentNode,c=0,d=b[xd],e=a._i||-1,g=b._l||-1;if(!d)return-1;d=d.length;if(g==d&&0<=e&&0<=g)return e;b._l=d;e=-1;for(b=b.firstElementChild||b.firstChild;b;b=b[ib])hb(b)&&(b._i=++c,a===b&&(e=c));return e}function zd(a){for(;a=a[ib];)if(hb(a))return!1;return!0}function Ad(a){for(;a=a[nf];)if(hb(a))return!1;return!0}function Oa(a,b){return a?"class"==b?a.className||"":"for"==
b?a.htmlFor||"":"style"==b?a.style.cssText||"":(Ma?a.getAttribute(b):a.getAttribute(b,2))||"":""}function Eb(a){return 1==a.nodeType}function Na(a,b){return a?b?function(){return a.apply(window,arguments)&&b.apply(window,arguments)}:a:b}function vd(a){function b(){0<=t&&(v.id=c(t,x).replace(/\\/g,""),t=-1);if(0<=B){var a=B==x?null:c(B,x);0>"\x3e~+".indexOf(a)?v.tag=a:v.uc=a;B=-1}0<=l&&(v.qa.push(c(l+1,x).replace(/\\/g,"")),l=-1)}function c(b,d){return pa(a.slice(b,d))}a=0<="\x3e~+".indexOf(a.slice(-1))?
a+" * ":a+" ";for(var d=[],e=-1,g=-1,h=-1,k=-1,l=-1,t=-1,B=-1,C="",J="",xa,x=0,Z=a.length,v=null,K=null;C=J,J=a.charAt(x),x<Z;x++)"\\"!=C&&(v||(xa=x,v={ob:null,Va:[],ac:[],qa:[],tag:null,uc:null,id:null,Zc:function(){return Ma?this.Ue:this.tag}},B=x),0<=e?"]"==J?(K.Sc?K.kd=c(h||e+1,x):K.Sc=c(e+1,x),!(e=K.kd)||'"'!=e.charAt(0)&&"'"!=e.charAt(0)||(K.kd=e.slice(1,-1)),v.ac.push(K),K=null,e=h=-1):"\x3d"==J&&(h=0<="|~^$*".indexOf(C)?C:"",K.type=h+J,K.Sc=c(e+1,x-h.length),h=x+1):0<=g?")"==J&&(0<=k&&(K.value=
c(g+1,x)),k=g=-1):"#"==J?(b(),t=x+1):"."==J?(b(),l=x):":"==J?(b(),k=x):"["==J?(b(),e=x,K={}):"("==J?(0<=k&&(K={name:c(k+1,x),value:null},v.Va.push(K)),g=x):" "==J&&C!=J&&(b(),0<=k&&v.Va.push({name:c(k+1,x)}),v.ee=v.Va.length||v.ac.length||v.qa.length,v.pf=v.ob=c(xa,x),v.Ue=v.tag=v.uc?null:v.tag||"*",v.tag&&(v.tag=v.tag.toUpperCase()),d.length&&d[d.length-1].uc&&(v.ce=d.pop(),v.ob=v.ce.ob+" "+v.ob),d.push(v),v=null));return d}function gb(a,b){var c=b||[];a&&c.push(a);return c}var ud=E&&"BackCompat"==
document.compatMode,wa=A&&!F("9"),xd=document.firstChild.children?"children":"childNodes",Ma=!1,yd={"*\x3d":function(a,b){return function(c){return 0<=Oa(c,a).indexOf(b)}},"^\x3d":function(a,b){return function(c){return 0==Oa(c,a).indexOf(b)}},"$\x3d":function(a,b){return function(c){c=" "+Oa(c,a);return c.lastIndexOf(b)==c.length-b.length}},"~\x3d":function(a,b){var c=" "+b+" ";return function(b){return 0<=(" "+Oa(b,a)+" ").indexOf(c)}},"|\x3d":function(a,b){b=" "+b;return function(c){c=" "+Oa(c,
a);return c==b||0==c.indexOf(b+"-")}},"\x3d":function(a,b){return function(c){return Oa(c,a)==b}}},Fb="undefined"==typeof document.firstChild.nextElementSibling,ib=Fb?"nextSibling":"nextElementSibling",nf=Fb?"previousSibling":"previousElementSibling",hb=Fb?Eb:Mb,oc={checked:function(){return function(a){return a.checked||a.attributes.checked}},"first-child":function(){return Ad},"last-child":function(){return zd},"only-child":function(){return function(a){return Ad(a)&&zd(a)?!0:!1}},empty:function(){return function(a){var b=
a.childNodes;for(a=a.childNodes.length-1;0<=a;a--){var c=b[a].nodeType;if(1===c||3==c)return!1}return!0}},contains:function(a,b){var c=b.charAt(0);if('"'==c||"'"==c)b=b.slice(1,-1);return function(a){return 0<=a.innerHTML.indexOf(b)}},not:function(a,b){var c=vd(b)[0],d={S:1};"*"!=c.tag&&(d.tag=1);c.qa.length||(d.qa=1);var e=t(c,d);return function(a){return!e(a)}},"nth-child":function(a,b){if("odd"==b)return B;if("even"==b)return C;if(-1!=b.indexOf("n")){var c=b.split("n",2),d=c[0]?"-"==c[0]?-1:parseInt(c[0],
10):1,e=c[1]?parseInt(c[1],10):0,g=0,h=-1;0<d?0>e?e=e%d&&d+e%d:0<e&&(e>=d&&(g=e-e%d),e%=d):0>d&&(d*=-1,0<e&&(h=e,e%=d));if(0<d)return function(a){a=xa(a);return a>=g&&(0>h||a<=h)&&a%d==e};b=e}var k=parseInt(b,10);return function(a){return xa(a)==k}}},mf=wa?function(a){var b=a.toLowerCase();"class"==b&&(a="className");return function(c){return Ma?c.getAttribute(a):c[a]||c[b]}}:function(a){return function(b){return b&&b.getAttribute&&b.hasAttribute(a)}},wd={},td={},sd={},rd=!!document.querySelectorAll&&
(!E||F("526")),Z=0,kf=wa?function(a){return Ma?a.getAttribute("_uid")||a.setAttribute("_uid",++Z)||Z:a.uniqueID}:function(a){return a._uid||(a._uid=++Z)};a.Va=oc;return a}();aa("goog.dom.query",I);aa("goog.dom.query.pseudos",I.Va);var Nb=!A||9<=jb,Ob=!A||9<=jb,Pb=A&&!F("9");!E||F("528");D&&F("1.9b")||A&&F("8")||Za&&F("9.5")||E&&F("528");D&&!F("8")||A&&F("9");function Qb(){0!=Rb&&(Sb[ha(this)]=this);this.Pa=this.Pa;this.Sa=this.Sa}var Rb=0,Sb={};Qb.prototype.Pa=!1;Qb.prototype.Fb=function(){if(!this.Pa&&(this.Pa=!0,this.N(),0!=Rb)){var a=ha(this);delete Sb[a]}};function Tb(a,b){a.Pa?b.call(void 0):(a.Sa||(a.Sa=[]),a.Sa.push(n(void 0)?ma(b,void 0):b))}Qb.prototype.N=function(){if(this.Sa)for(;this.Sa.length;)this.Sa.shift()()};function Ub(a){a&&"function"==typeof a.Fb&&a.Fb()};function Vb(a,b){this.type=a;this.currentTarget=this.target=b;this.defaultPrevented=this.Ua=!1;this.ie=!0}Vb.prototype.stopPropagation=function(){this.Ua=!0};Vb.prototype.preventDefault=function(){this.defaultPrevented=!0;this.ie=!1};function Wb(a){a.preventDefault()};function Xb(a){Xb[" "](a);return a}Xb[" "]=ba;function L(a,b){Vb.call(this,a?a.type:"");this.relatedTarget=this.currentTarget=this.target=null;this.charCode=this.keyCode=this.button=this.screenY=this.screenX=this.clientY=this.clientX=this.offsetY=this.offsetX=0;this.metaKey=this.shiftKey=this.altKey=this.ctrlKey=!1;this.state=null;this.nd=!1;this.T=null;a&&this.init(a,b)}u(L,Vb);var Yb=[1,4,2];
L.prototype.init=function(a,b){var c=this.type=a.type,d=a.changedTouches?a.changedTouches[0]:null;this.target=a.target||a.srcElement;this.currentTarget=b;var e=a.relatedTarget;if(e){if(D){var g;a:{try{Xb(e.nodeName);g=!0;break a}catch(h){}g=!1}g||(e=null)}}else"mouseover"==c?e=a.fromElement:"mouseout"==c&&(e=a.toElement);this.relatedTarget=e;null===d?(this.offsetX=E||void 0!==a.offsetX?a.offsetX:a.layerX,this.offsetY=E||void 0!==a.offsetY?a.offsetY:a.layerY,this.clientX=void 0!==a.clientX?a.clientX:
a.pageX,this.clientY=void 0!==a.clientY?a.clientY:a.pageY,this.screenX=a.screenX||0,this.screenY=a.screenY||0):(this.clientX=void 0!==d.clientX?d.clientX:d.pageX,this.clientY=void 0!==d.clientY?d.clientY:d.pageY,this.screenX=d.screenX||0,this.screenY=d.screenY||0);this.button=a.button;this.keyCode=a.keyCode||0;this.charCode=a.charCode||("keypress"==c?a.keyCode:0);this.ctrlKey=a.ctrlKey;this.altKey=a.altKey;this.shiftKey=a.shiftKey;this.metaKey=a.metaKey;this.nd=ab?a.metaKey:a.ctrlKey;this.state=a.state;
this.T=a;a.defaultPrevented&&this.preventDefault()};function Zb(a){return(Nb?0==a.T.button:"click"==a.type?!0:!!(a.T.button&Yb[0]))&&!(E&&ab&&a.ctrlKey)}L.prototype.stopPropagation=function(){L.w.stopPropagation.call(this);this.T.stopPropagation?this.T.stopPropagation():this.T.cancelBubble=!0};
L.prototype.preventDefault=function(){L.w.preventDefault.call(this);var a=this.T;if(a.preventDefault)a.preventDefault();else if(a.returnValue=!1,Pb)try{if(a.ctrlKey||112<=a.keyCode&&123>=a.keyCode)a.keyCode=-1}catch(b){}};var $b="closure_listenable_"+(1E6*Math.random()|0),ac=0;function bc(a,b,c,d,e){this.listener=a;this.xc=null;this.src=b;this.type=c;this.Cb=!!d;this.hb=e;this.key=++ac;this.pb=this.bc=!1}function cc(a){a.pb=!0;a.listener=null;a.xc=null;a.src=null;a.hb=null};function dc(a){this.src=a;this.J={};this.Tb=0}f=dc.prototype;f.add=function(a,b,c,d,e){var g=a.toString();a=this.J[g];a||(a=this.J[g]=[],this.Tb++);var h=ec(a,b,d,e);-1<h?(b=a[h],c||(b.bc=!1)):(b=new bc(b,this.src,g,!!d,e),b.bc=c,a.push(b));return b};f.remove=function(a,b,c,d){a=a.toString();if(!(a in this.J))return!1;var e=this.J[a];b=ec(e,b,c,d);return-1<b?(cc(e[b]),Array.prototype.splice.call(e,b,1),0==e.length&&(delete this.J[a],this.Tb--),!0):!1};
function fc(a,b){var c=b.type;c in a.J&&y(a.J[c],b)&&(cc(b),0==a.J[c].length&&(delete a.J[c],a.Tb--))}f.Ha=function(a){a=a&&a.toString();var b=0,c;for(c in this.J)if(!a||c==a){for(var d=this.J[c],e=0;e<d.length;e++)++b,cc(d[e]);delete this.J[c];this.Tb--}return b};f.Nb=function(a,b,c,d){a=this.J[a.toString()];var e=-1;a&&(e=ec(a,b,c,d));return-1<e?a[e]:null};
f.hasListener=function(a,b){var c=n(a),d=c?a.toString():"",e=n(b);return Wa(this.J,function(a){for(var h=0;h<a.length;++h)if(!(c&&a[h].type!=d||e&&a[h].Cb!=b))return!0;return!1})};function ec(a,b,c,d){for(var e=0;e<a.length;++e){var g=a[e];if(!g.pb&&g.listener==b&&g.Cb==!!c&&g.hb==d)return e}return-1};var gc="closure_lm_"+(1E6*Math.random()|0),hc={},ic=0;
function M(a,b,c,d,e){if(ea(b)){for(var g=0;g<b.length;g++)M(a,b[g],c,d,e);return null}c=jc(c);if(a&&a[$b])a=a.l(b,c,d,e);else{if(!b)throw Error("Invalid event type");var g=!!d,h=kc(a);h||(a[gc]=h=new dc(a));c=h.add(b,c,!1,d,e);if(!c.xc){d=lc();c.xc=d;d.src=a;d.listener=c;if(a.addEventListener)a.addEventListener(b.toString(),d,g);else if(a.attachEvent)a.attachEvent(mc(b.toString()),d);else throw Error("addEventListener and attachEvent are unavailable.");ic++}a=c}return a}
function lc(){var a=nc,b=Ob?function(c){return a.call(b.src,b.listener,c)}:function(c){c=a.call(b.src,b.listener,c);if(!c)return c};return b}function pc(a,b,c,d,e){if(ea(b))for(var g=0;g<b.length;g++)pc(a,b[g],c,d,e);else c=jc(c),a&&a[$b]?a.ya(b,c,d,e):a&&(a=kc(a))&&(b=a.Nb(b,c,!!d,e))&&N(b)}
function N(a){if(!q(a)&&a&&!a.pb){var b=a.src;if(b&&b[$b])fc(b.sa,a);else{var c=a.type,d=a.xc;b.removeEventListener?b.removeEventListener(c,d,a.Cb):b.detachEvent&&b.detachEvent(mc(c),d);ic--;(c=kc(b))?(fc(c,a),0==c.Tb&&(c.src=null,b[gc]=null)):cc(a)}}}function mc(a){return a in hc?hc[a]:hc[a]="on"+a}function qc(a,b,c,d){var e=!0;if(a=kc(a))if(b=a.J[b.toString()])for(b=b.concat(),a=0;a<b.length;a++){var g=b[a];g&&g.Cb==c&&!g.pb&&(g=rc(g,d),e=e&&!1!==g)}return e}
function rc(a,b){var c=a.listener,d=a.hb||a.src;a.bc&&N(a);return c.call(d,b)}
function nc(a,b){if(a.pb)return!0;if(!Ob){var c;if(!(c=b))a:{c=["window","event"];for(var d=m,e;e=c.shift();)if(null!=d[e])d=d[e];else{c=null;break a}c=d}e=c;c=new L(e,this);d=!0;if(!(0>e.keyCode||void 0!=e.returnValue)){a:{var g=!1;if(0==e.keyCode)try{e.keyCode=-1;break a}catch(l){g=!0}if(g||void 0==e.returnValue)e.returnValue=!0}e=[];for(g=c.currentTarget;g;g=g.parentNode)e.push(g);for(var g=a.type,h=e.length-1;!c.Ua&&0<=h;h--){c.currentTarget=e[h];var k=qc(e[h],g,!0,c),d=d&&k}for(h=0;!c.Ua&&h<
e.length;h++)c.currentTarget=e[h],k=qc(e[h],g,!1,c),d=d&&k}return d}return rc(a,new L(b,this))}function kc(a){a=a[gc];return a instanceof dc?a:null}var sc="__closure_events_fn_"+(1E9*Math.random()>>>0);function jc(a){if(r(a))return a;a[sc]||(a[sc]=function(b){return a.handleEvent(b)});return a[sc]};function tc(a){Qb.call(this);this.Ob=a;this.v={}}u(tc,Qb);var uc=[];f=tc.prototype;f.l=function(a,b,c,d){ea(b)||(b&&(uc[0]=b.toString()),b=uc);for(var e=0;e<b.length;e++){var g=M(a,b[e],c||this.handleEvent,d||!1,this.Ob||this);if(!g)break;this.v[g.key]=g}return this};
f.ya=function(a,b,c,d,e){if(ea(b))for(var g=0;g<b.length;g++)this.ya(a,b[g],c,d,e);else c=c||this.handleEvent,e=e||this.Ob||this,c=jc(c),d=!!d,b=a&&a[$b]?a.Nb(b,c,d,e):a?(a=kc(a))?a.Nb(b,c,d,e):null:null,b&&(N(b),delete this.v[b.key]);return this};f.Ha=function(){Va(this.v,function(a,b){this.v.hasOwnProperty(b)&&N(a)},this);this.v={}};f.N=function(){tc.w.N.call(this);this.Ha()};f.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented");};function vc(){Qb.call(this);this.sa=new dc(this);this.ze=this;this.wc=null}u(vc,Qb);vc.prototype[$b]=!0;f=vc.prototype;f.rd=function(a){this.wc=a};f.addEventListener=function(a,b,c,d){M(this,a,b,c,d)};f.removeEventListener=function(a,b,c,d){pc(this,a,b,c,d)};
f.dispatchEvent=function(a){var b,c=this.wc;if(c)for(b=[];c;c=c.wc)b.push(c);var c=this.ze,d=a.type||a;if(p(a))a=new Vb(a,c);else if(a instanceof Vb)a.target=a.target||c;else{var e=a;a=new Vb(d,c);Ya(a,e)}var e=!0,g;if(b)for(var h=b.length-1;!a.Ua&&0<=h;h--)g=a.currentTarget=b[h],e=wc(g,d,!0,a)&&e;a.Ua||(g=a.currentTarget=c,e=wc(g,d,!0,a)&&e,a.Ua||(e=wc(g,d,!1,a)&&e));if(b)for(h=0;!a.Ua&&h<b.length;h++)g=a.currentTarget=b[h],e=wc(g,d,!1,a)&&e;return e};
f.N=function(){vc.w.N.call(this);this.sa&&this.sa.Ha(void 0);this.wc=null};f.l=function(a,b,c,d){return this.sa.add(String(a),b,!1,c,d)};f.ya=function(a,b,c,d){return this.sa.remove(String(a),b,c,d)};function wc(a,b,c,d){b=a.sa.J[String(b)];if(!b)return!0;b=b.concat();for(var e=!0,g=0;g<b.length;++g){var h=b[g];if(h&&!h.pb&&h.Cb==c){var k=h.listener,l=h.hb||h.src;h.bc&&fc(a.sa,h);e=!1!==k.call(l,d)&&e}}return e&&0!=d.ie}f.Nb=function(a,b,c,d){return this.sa.Nb(String(a),b,c,d)};
f.hasListener=function(a,b){return this.sa.hasListener(n(a)?String(a):void 0,b)};function xc(a,b,c,d){this.top=a;this.right=b;this.bottom=c;this.left=d}f=xc.prototype;f.clone=function(){return new xc(this.top,this.right,this.bottom,this.left)};f.contains=function(a){return this&&a?a instanceof xc?a.left>=this.left&&a.right<=this.right&&a.top>=this.top&&a.bottom<=this.bottom:a.x>=this.left&&a.x<=this.right&&a.y>=this.top&&a.y<=this.bottom:!1};
f.expand=function(a,b,c,d){ga(a)?(this.top-=a.top,this.right+=a.right,this.bottom+=a.bottom,this.left-=a.left):(this.top-=a,this.right+=b,this.bottom+=c,this.left-=d);return this};f.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};f.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};
f.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this};f.translate=function(a,b){a instanceof G?(this.left+=a.x,this.right+=a.x,this.top+=a.y,this.bottom+=a.y):(this.left+=a,this.right+=a,q(b)&&(this.top+=b,this.bottom+=b));return this};f.scale=function(a,b){var c=q(b)?b:a;this.left*=a;this.right*=a;this.top*=c;this.bottom*=c;return this};function yc(a,b,c,d){this.left=a;this.top=b;this.width=c;this.height=d}f=yc.prototype;f.clone=function(){return new yc(this.left,this.top,this.width,this.height)};f.contains=function(a){return a instanceof yc?this.left<=a.left&&this.left+this.width>=a.left+a.width&&this.top<=a.top&&this.top+this.height>=a.top+a.height:a.x>=this.left&&a.x<=this.left+this.width&&a.y>=this.top&&a.y<=this.top+this.height};
f.ceil=function(){this.left=Math.ceil(this.left);this.top=Math.ceil(this.top);this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.left=Math.floor(this.left);this.top=Math.floor(this.top);this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};f.round=function(){this.left=Math.round(this.left);this.top=Math.round(this.top);this.width=Math.round(this.width);this.height=Math.round(this.height);return this};
f.translate=function(a,b){a instanceof G?(this.left+=a.x,this.top+=a.y):(this.left+=a,q(b)&&(this.top+=b));return this};f.scale=function(a,b){var c=q(b)?b:a;this.left*=a;this.width*=a;this.top*=c;this.height*=c;return this};function O(a,b,c){if(p(b))(b=zc(a,b))&&(a.style[b]=c);else for(var d in b){c=a;var e=b[d],g=zc(c,d);g&&(c.style[g]=e)}}var Ac={};function zc(a,b){var c=Ac[b];if(!c){var d=Ba(b),c=d;void 0===a.style[d]&&(d=(E?"Webkit":D?"Moz":A?"ms":Za?"O":null)+Ca(d),void 0!==a.style[d]&&(c=d));Ac[b]=c}return c}function Bc(a,b){var c=a.style[Ba(b)];return"undefined"!==typeof c?c:a.style[zc(a,b)]||""}
function P(a,b){var c=H(a);return c.defaultView&&c.defaultView.getComputedStyle&&(c=c.defaultView.getComputedStyle(a,null))?c[b]||c.getPropertyValue(b)||"":""}function Cc(a,b){return P(a,b)||(a.currentStyle?a.currentStyle[b]:null)||a.style&&a.style[b]}function Dc(a,b,c){var d;b instanceof G?(d=b.x,b=b.y):(d=b,b=c);a.style.left=Ec(d,!1);a.style.top=Ec(b,!1)}
function Fc(a){var b;try{b=a.getBoundingClientRect()}catch(c){return{left:0,top:0,right:0,bottom:0}}A&&a.ownerDocument.body&&(a=a.ownerDocument,b.left-=a.documentElement.clientLeft+a.body.clientLeft,b.top-=a.documentElement.clientTop+a.body.clientTop);return b}function Gc(a,b){var c=Hc(a),d=Hc(b);return new G(c.x-d.x,c.y-d.y)}function Hc(a){if(1==a.nodeType)return a=Fc(a),new G(a.left,a.top);a=a.changedTouches?a.changedTouches[0]:a;return new G(a.clientX,a.clientY)}
function Ic(a,b,c){if(b instanceof qb)c=b.height,b=b.width;else if(void 0==c)throw Error("missing height argument");a.style.width=Ec(b,!0);a.style.height=Ec(c,!0)}function Ec(a,b){"number"==typeof a&&(a=(b?Math.round(a):a)+"px");return a}function Jc(a){var b=Kc;if("none"!=Cc(a,"display"))return b(a);var c=a.style,d=c.display,e=c.visibility,g=c.position;c.visibility="hidden";c.position="absolute";c.display="inline";a=b(a);c.display=d;c.position=g;c.visibility=e;return a}
function Kc(a){var b=a.offsetWidth,c=a.offsetHeight,d=E&&!b&&!c;return n(b)&&!d||!a.getBoundingClientRect?new qb(b,c):(a=Fc(a),new qb(a.right-a.left,a.bottom-a.top))}function Lc(a){var b=H(a),c=new G(0,0),d;d=b?H(b):document;var e;(e=!A||9<=jb)||(rb(d),e=!0);a!=(e?d.documentElement:d.body)&&(d=Fc(a),b=Lb(rb(b)),c.x=d.left+b.x,c.y=d.top+b.y);a=Jc(a);return new yc(c.x,c.y,a.width,a.height)}
function Q(a,b){var c=a.style;"opacity"in c?c.opacity=b:"MozOpacity"in c?c.MozOpacity=b:"filter"in c&&(c.filter=""===b?"":"alpha(opacity\x3d"+100*b+")")}function R(a,b){a.style.display=b?"":"none"}function Mc(a){return"rtl"==Cc(a,"direction")}var Nc=D?"MozUserSelect":E?"WebkitUserSelect":null;
function Oc(a,b){if(/^\d+px?$/.test(b))return parseInt(b,10);var c=a.style.left,d=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;a.style.left=b;var e=a.style.pixelLeft;a.style.left=c;a.runtimeStyle.left=d;return e}function Pc(a,b){var c=a.currentStyle?a.currentStyle[b]:null;return c?Oc(a,c):0}
function Qc(a,b){if(A){var c=Pc(a,b+"Left"),d=Pc(a,b+"Right"),e=Pc(a,b+"Top"),g=Pc(a,b+"Bottom");return new xc(e,d,g,c)}c=P(a,b+"Left");d=P(a,b+"Right");e=P(a,b+"Top");g=P(a,b+"Bottom");return new xc(parseFloat(e),parseFloat(d),parseFloat(g),parseFloat(c))}var Rc={thin:2,medium:4,thick:6};function Sc(a,b){if("none"==(a.currentStyle?a.currentStyle[b+"Style"]:null))return 0;var c=a.currentStyle?a.currentStyle[b+"Width"]:null;return c in Rc?Rc[c]:Oc(a,c)}
function Tc(a){if(A&&!(9<=jb)){var b=Sc(a,"borderLeft"),c=Sc(a,"borderRight"),d=Sc(a,"borderTop");a=Sc(a,"borderBottom");return new xc(d,c,a,b)}b=P(a,"borderLeftWidth");c=P(a,"borderRightWidth");d=P(a,"borderTopWidth");a=P(a,"borderBottomWidth");return new xc(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))};function Uc(a,b,c){vc.call(this);this.target=a;this.handle=b||a;this.gd=c||new yc(NaN,NaN,NaN,NaN);this.W=H(a);this.ia=new tc(this);Tb(this,na(Ub,this.ia));this.deltaY=this.deltaX=this.ne=this.me=this.screenY=this.screenX=this.clientY=this.clientX=0;this.Xc=!0;this.Qa=!1;this.ge=!0;this.be=0;this.sd=this.Pe=!1;M(this.handle,["touchstart","mousedown"],this.ke,!1,this)}u(Uc,vc);var Vc=m.document&&m.document.documentElement&&!!m.document.documentElement.setCapture;f=Uc.prototype;f.hc=function(){return this.ia};
function Wc(a,b){a.gd=b||new yc(NaN,NaN,NaN,NaN)}f.Ac=function(a){this.Xc=a};f.N=function(){Uc.w.N.call(this);pc(this.handle,["touchstart","mousedown"],this.ke,!1,this);this.ia.Ha();Vc&&this.W.releaseCapture();this.handle=this.target=null};function Xc(a){n(a.Wa)||(a.Wa=Mc(a.target));return a.Wa}
f.ke=function(a){var b="mousedown"==a.type;if(!this.Xc||this.Qa||b&&!Zb(a))this.dispatchEvent("earlycancel");else{if(0==this.be)if(this.dispatchEvent(new Yc("start",this,a.clientX,a.clientY)))this.Qa=!0,this.ge&&a.preventDefault();else return;else this.ge&&a.preventDefault();var b=this.W,c=b.documentElement,d=!Vc;this.ia.l(b,["touchmove","mousemove"],this.Ne,d);this.ia.l(b,["touchend","mouseup"],this.gc,d);Vc?(c.setCapture(!1),this.ia.l(c,"losecapture",this.gc)):this.ia.l(b?b.parentWindow||b.defaultView:
window,"blur",this.gc);A&&this.Pe&&this.ia.l(b,"dragstart",Wb);this.Ze&&this.ia.l(this.Ze,"scroll",this.Te,d);this.clientX=this.me=a.clientX;this.clientY=this.ne=a.clientY;this.screenX=a.screenX;this.screenY=a.screenY;this.sd?(a=this.target,b=a.offsetLeft,c=a.offsetParent,c||"fixed"!=Cc(a,"position")||(c=H(a).documentElement),c?(D?(d=Tc(c),b+=d.left):8<=jb&&!(9<=jb)&&(d=Tc(c),b-=d.left),a=Mc(c)?c.clientWidth-(b+a.offsetWidth):b):a=b):a=this.target.offsetLeft;this.deltaX=a;this.deltaY=this.target.offsetTop;
this.md=Lb(rb(this.W))}};f.gc=function(a){this.ia.Ha();Vc&&this.W.releaseCapture();this.Qa?(this.Qa=!1,this.dispatchEvent(new Yc("end",this,a.clientX,a.clientY,0,Zc(this,this.deltaX),$c(this,this.deltaY)))):this.dispatchEvent("earlycancel")};
f.Ne=function(a){if(this.Xc){var b=(this.sd&&Xc(this)?-1:1)*(a.clientX-this.clientX),c=a.clientY-this.clientY;this.clientX=a.clientX;this.clientY=a.clientY;this.screenX=a.screenX;this.screenY=a.screenY;if(!this.Qa){var d=this.me-this.clientX,e=this.ne-this.clientY;if(d*d+e*e>this.be)if(this.dispatchEvent(new Yc("start",this,a.clientX,a.clientY)))this.Qa=!0;else{this.Pa||this.gc(a);return}}c=ad(this,b,c);b=c.x;c=c.y;this.Qa&&this.dispatchEvent(new Yc("beforedrag",this,a.clientX,a.clientY,0,b,c))&&
(bd(this,a,b,c),a.preventDefault())}};function ad(a,b,c){var d=Lb(rb(a.W));b+=d.x-a.md.x;c+=d.y-a.md.y;a.md=d;a.deltaX+=b;a.deltaY+=c;return new G(Zc(a,a.deltaX),$c(a,a.deltaY))}f.Te=function(a){var b=ad(this,0,0);a.clientX=this.clientX;a.clientY=this.clientY;bd(this,a,b.x,b.y)};function bd(a,b,c,d){a.Td(c,d);a.dispatchEvent(new Yc("drag",a,b.clientX,b.clientY,0,c,d))}
function Zc(a,b){var c=a.gd,d=isNaN(c.left)?null:c.left,c=isNaN(c.width)?0:c.width;return Math.min(null!=d?d+c:Infinity,Math.max(null!=d?d:-Infinity,b))}function $c(a,b){var c=a.gd,d=isNaN(c.top)?null:c.top,c=isNaN(c.height)?0:c.height;return Math.min(null!=d?d+c:Infinity,Math.max(null!=d?d:-Infinity,b))}f.Td=function(a,b){this.sd&&Xc(this)?this.target.style.right=a+"px":this.target.style.left=a+"px";this.target.style.top=b+"px"};
function Yc(a,b,c,d,e,g,h){Vb.call(this,a);this.clientX=c;this.clientY=d;this.left=n(g)?g:b.deltaX;this.top=n(h)?h:b.deltaY}u(Yc,Vb);function cd(a){for(var b=0,c=0;a&&!isNaN(a.offsetLeft)&&!isNaN(a.offsetTop);)b+=a.offsetLeft-a.scrollLeft,c+=a.offsetTop-a.scrollTop,a=a.offsetParent;return{top:c,left:b}}function dd(a){window.addEventListener?window.addEventListener("load",a,!1):window.attachEvent&&window.attachEvent("onload",a)}
function ed(a,b){var c=document.createElement("div");O(c,"position","absolute");O(c,"top","0px");O(c,"right","0px");O(c,"width","5px");O(c,"height","100%");O(c,"cursor","e-resize");a.appendChild(c);var d=Tc(a),d=Lc(a).width-d.right-d.left,c=new Uc(c);Wc(c,new yc(d,0,800,0));c.Td=function(c){O(a,"width",c+"px");b&&b()}};function fd(){this.ub=[]}fd.prototype.o=function(a,b){this.ub[a]||(this.ub[a]=[]);this.ub[a].push(b)};fd.prototype.yc=function(a,b){var c=this.ub[a];c&&y(c,b)};fd.prototype.fireEvent=function(a,b,c){var d=!1;(a=this.ub[a])&&w(a,function(a){a=a(b,c);n(a)&&!a&&(d=!0)});return d};function gd(a,b){this.la={};this.v=[];this.eb=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 a&&this.addAll(a)}function S(a){hd(a);for(var b=[],c=0;c<a.v.length;c++)b.push(a.la[a.v[c]]);return b}function id(a){hd(a);return a.v.concat()}f=gd.prototype;f.clear=function(){this.la={};this.eb=this.v.length=0};
f.remove=function(a){return jd(this.la,a)?(delete this.la[a],this.eb--,this.v.length>2*this.eb&&hd(this),!0):!1};function hd(a){if(a.eb!=a.v.length){for(var b=0,c=0;b<a.v.length;){var d=a.v[b];jd(a.la,d)&&(a.v[c++]=d);b++}a.v.length=c}if(a.eb!=a.v.length){for(var e={},c=b=0;b<a.v.length;)d=a.v[b],jd(e,d)||(a.v[c++]=d,e[d]=1),b++;a.v.length=c}}f.get=function(a,b){return jd(this.la,a)?this.la[a]:b};f.set=function(a,b){jd(this.la,a)||(this.eb++,this.v.push(a));this.la[a]=b};
f.addAll=function(a){var b;if(a instanceof gd)b=id(a),a=S(a);else{b=[];var c=0,d;for(d in a)b[c++]=d;c=[];d=0;for(var e in a)c[d++]=a[e];a=c}for(e=0;e<b.length;e++)this.set(b[e],a[e])};f.forEach=function(a,b){for(var c=id(this),d=0;d<c.length;d++){var e=c[d],g=this.get(e);a.call(b,g,e,this)}};f.clone=function(){return new gd(this)};function jd(a,b){return Object.prototype.hasOwnProperty.call(a,b)};function T(a,b){this.x=a;this.y=b};function kd(a){this.points=a}function ld(a){for(var b=0,c=a.length-1,d=0;d<a.length;d++)b+=(a[c].x+a[d].x)*(a[c].y-a[d].y),c=d;return b/2}
function md(a,b){for(var c,d=c=0,e,g=a.length-1,h=0;h<a.length;h++)e=a[h].x*a[g].y-a[g].x*a[h].y,c+=(a[h].x+a[g].x)*e,d+=(a[h].y+a[g].y)*e,g=h;e=6*ld(a);c=new T(Math.abs(c/e),Math.abs(d/e));d=[];for(e=0;e<a.length;e++){var g=a[e],k=(0>ld(a)?-1:1)*b,h=g.x-c.x,l=g.y-c.y,t=0<k?1:0>k?-1:0,k=Math.sqrt(Math.pow(k,2)/(1+Math.pow(h/l,2)));d.push({x:g.x+Math.abs(h/l*k)*(0<h?1:0>h?-1:0)*t,y:g.y+Math.abs(k)*(0<l?1:0>l?-1:0)*t})}return d};function nd(a,b,c,d){0<c?(this.x=a,this.width=c):(this.x=a+c,this.width=-c);0<d?(this.y=b,this.height=d):(this.y=b+d,this.height=-d)};function od(a,b,c,d){this.type=a;this.geometry=b;c&&(this.units=c);this.style=d?d:{}}function pd(a){return"rect"==a.type?a.geometry.width*a.geometry.height:"polygon"==a.type?Math.abs(ld(a.geometry.points)):0}function Bd(a){if("rect"==a.type)return a;if("polygon"==a.type){for(var b=a.geometry.points,c=b[0].x,d=b[0].x,e=b[0].y,g=b[0].y,h=1;h<b.length;h++)b[h].x>d&&(d=b[h].x),b[h].x<c&&(c=b[h].x),b[h].y>g&&(g=b[h].y),b[h].y<e&&(e=b[h].y);return new od("rect",new nd(c,e,d-c,g-e),!1,a.style)}}
function Cd(a,b){var c;c=a.geometry.points;var d=0>ld(c)?-1:1;if(4>c.length)c=md(c,d*b);else{for(var e=c.length-1,g=1,h=[],k=0;k<c.length;k++)e=md([c[e],c[k],c[g]],d*b),h.push(e[1]),e=k,g++,g>c.length-1&&(g=0);c=h}return new od("polygon",new kd(c),!1,a.style)}function Dd(a,b){if("rect"==a.type){var c=b(a.geometry);return new od("rect",c,!1,a.style)}if("polygon"==a.type){var d=[];w(a.geometry.points,function(a){d.push(b(a))});return new od("polygon",new kd(d),!1,a.style)}}
function Ed(a){return JSON.stringify(a.geometry)};function Fd(a,b,c){this.src=a;this.text=b;this.shapes=[c];this.context=document.URL};function Gd(){}function Hd(a,b){a.j=new gd;a.Gd=[];a.xb=[];a.bb=[];a.$a=[];a.Fc=[];a.Vb={kb:!1,jb:!1};a.ab=new gd;a.Gc=void 0;a.Od=b}function Id(a,b){var c=a.ab.get(b);c||(c={kb:!1,jb:!1},a.ab.set(b,c));return c}
function Jd(a,b){var c=a.jc(b);if(!a.j.get(c)){var d=a.ld(b),e=[],g=[];w(a.Gd,function(a){d.o(a.type,a.hb)});w(a.xb,function(a){if(a.onInitAnnotator)a.onInitAnnotator(d)});w(a.$a,function(a){a.src==c&&(d.V(a),e.push(a))});w(a.Fc,function(a){a.src==c&&(d.O(a),g.push(a))});w(e,function(b){y(a.$a,b)});w(g,function(b){y(a.Fc,b)});var h=a.ab.get(c);h?(h.kb&&d.aa(),h.jb&&d.ua(),a.ab.remove(c)):(a.Vb.kb&&d.aa(),a.Vb.jb&&d.ua());a.Gc&&d.wa(a.Gc);a.j.set(c,d);y(a.bb,b)}}
function Kd(a){var b,c;for(c=a.bb.length;0<c;c--){for(var d=b=a.bb[c-1],e=d.offsetTop,g=d.offsetLeft,h=d.offsetWidth,k=d.offsetHeight;d.offsetParent;)d=d.offsetParent,e+=d.offsetTop,g+=d.offsetLeft;e<window.pageYOffset+window.innerHeight&&g<window.pageXOffset+window.innerWidth&&e+k>window.pageYOffset&&g+h>window.pageXOffset&&Jd(a,b)}}function Ld(a,b,c){if(b){var d=a.j.get(b);d?c?d.Xa():d.ua():Id(a,b).jb=c}else w(S(a.j),function(a){c?a.Xa():a.ua()}),a.Vb.jb=!c,w(S(a.ab),function(a){a.jb=!c})}
function Md(a,b,c){if(b){var d=a.j.get(b);d?c?d.ma():d.aa():Id(a,b).kb=c}else w(S(a.j),function(a){c?a.ma():a.aa()}),a.Vb.kb=!c,w(S(a.ab),function(a){a.kb=!c})}f=Gd.prototype;f.pa=function(a,b){var c=void 0,d=void 0;p(a)?(c=a,d=b):r(a)&&(d=a);c?(c=this.j.get(c))&&c.pa(d):w(S(this.j),function(a){a.pa(d)})};f.stopSelection=function(a){a?(a=this.j.get(a))&&a.stopSelection():w(S(this.j),function(a){a.stopSelection()})};
f.V=function(a,b){if(Nd(this,a.src)){var c=this.j.get(a.src);c?c.V(a,b):(this.$a.push(a),b&&y(this.$a,b))}};f.o=function(a,b){w(S(this.j),function(c){c.o(a,b)});this.Gd.push({type:a,hb:b})};f.$b=function(a){this.xb.push(a);w(S(this.j),function(b){if(a.onInitAnnotator)a.onInitAnnotator(b)})};function Nd(a,b){return jd(a.j.la,b)?!0:null!=Ha(a.bb,function(c){return a.jc(c)==b})}f.F=function(a){if(a){var b=this.j.get(a);b&&(b.F(),this.j.remove(a))}else w(S(this.j),function(a){a.F()}),this.j.clear()};
f.Ca=function(a){if(Nd(this,a)&&(a=this.j.get(a)))return a.Ca().getName()};f.I=function(a){if(a){var b=this.j.get(a);return b?b.I():Ea(this.$a,function(b){return b.src==a})}var c=[];w(S(this.j),function(a){Ka(c,a.I())});Ka(c,this.$a);return c};f.Da=function(a){if(Nd(this,a)&&(a=this.j.get(a)))return Fa(a.Da(),function(a){return a.getName()})};f.ua=function(a){Ld(this,a,!1)};f.aa=function(a){Md(this,a,!1)};
f.G=function(a){if(a){if(Nd(this,a.src)){var b=this.j.get(a.src);b&&b.G(a)}}else w(S(this.j),function(a){a.G()})};f.init=function(){this.Od&&Ka(this.bb,this.Od());Kd(this);var a=this,b=M(window,"scroll",function(){0<a.bb.length?Kd(a):N(b)})};f.jd=function(a){this.supports(a)&&Jd(this,a)};f.O=function(a){if(Nd(this,a.src)){var b=this.j.get(a.src);b?b.O(a):this.Fc.push(a)}};f.Sb=function(a,b){if(Nd(this,a)){var c=this.j.get(a);c&&c.je(b)}};f.wa=function(a){this.Gc=a;w(S(this.j),function(b){b.wa(a)})};
f.Xa=function(a){Ld(this,a,!0)};f.ma=function(a){Md(this,a,!0)};function Od(a){a=a.className;return p(a)&&a.match(/\S+/g)||[]}function Pd(a,b){var c=Od(a);Qd(c,Pa(arguments,1));a.className=c.join(" ")}function Qd(a,b){for(var c=0;c<b.length;c++)Ia(a,b[c])||a.push(b[c])}function Rd(a,b){return Ea(a,function(a){return!Ia(b,a)})}function Sd(a,b,c){var d=Od(a);p(b)?y(d,b):ea(b)&&(d=Rd(d,b));p(c)&&!Ia(d,c)?d.push(c):ea(c)&&Qd(d,c);a.className=d.join(" ")};var Td={},Ud={},Vd={};function Wd(){throw Error("Do not instantiate directly");}Wd.prototype.Vc=null;Wd.prototype.Kb=function(){return this.content};Wd.prototype.toString=function(){return this.content};function Xd(a,b){var c;a:{var d=a(b||Yd,void 0,void 0);c=rb().createElement("DIV");d=Zd(d);c.innerHTML=d;if(1==c.childNodes.length&&(d=c.firstChild,1==d.nodeType)){c=d;break a}}return c}function Zd(a){if(!ga(a))return String(a);if(a instanceof Wd){if(a.Db===Td)return a.Kb();if(a.Db===Vd)return qa(a.Kb())}return"zSoyz"}var Yd={};function $d(a,b){null!=a&&this.append.apply(this,arguments)}f=$d.prototype;f.Ma="";f.set=function(a){this.Ma=""+a};f.append=function(a,b,c){this.Ma+=a;if(null!=b)for(var d=1;d<arguments.length;d++)this.Ma+=arguments[d];return this};f.clear=function(){this.Ma=""};f.toString=function(){return this.Ma};/*
Portions of this code are from the google-caja project, received by
Google under the Apache license (http://code.google.com/p/google-caja/).
All other code is Copyright 2009 Google, Inc. All Rights Reserved.
// Copyright (C) 2006 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
*/
function ae(){}
var be={lt:"\x3c",gt:"\x3e",amp:"\x26",nbsp:"\u00a0",quot:'"',apos:"'"},ce={a:0,abbr:0,acronym:0,address:0,applet:16,area:2,b:0,base:18,basefont:18,bdo:0,big:0,blockquote:0,body:49,br:2,button:0,canvas:0,caption:0,center:0,cite:0,code:0,col:2,colgroup:1,dd:1,del:0,dfn:0,dir:0,div:0,dl:0,dt:1,em:0,fieldset:0,font:0,form:0,frame:18,frameset:16,h1:0,h2:0,h3:0,h4:0,h5:0,h6:0,head:49,hr:2,html:49,i:0,iframe:20,img:2,input:2,ins:0,isindex:18,kbd:0,label:0,legend:0,li:1,link:18,map:0,menu:0,meta:18,noframes:20,
noscript:20,object:16,ol:0,optgroup:0,option:1,p:1,param:18,pre:0,q:0,s:0,samp:0,script:20,select:0,small:0,span:0,strike:0,strong:0,style:20,sub:0,sup:0,table:0,tbody:1,td:1,textarea:8,tfoot:1,th:1,thead:1,title:24,tr:1,tt:0,u:0,ul:0,"var":0},de=/&/g,ee=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,fe=/</g,ge=/>/g,he=/\"/g,ie=/=/g,je=/\0/g,ke=/&(#\d+|#x[0-9A-Fa-f]+|\w+);/g,le=/^#(\d+)$/,me=/^#x([0-9A-Fa-f]+)$/,ne=/^\s*(?:(?:([a-z][a-z-]*)(\s*=\s*("[^"]*"|'[^']*'|(?=[a-z][a-z-]*\s*=)|[^>"'\s]*))?)|(\/?>)|[^a-z\s>]+)/i,
oe=/^(?:&(\#[0-9]+|\#[x][0-9a-f]+|\w+);|<[!]--[\s\S]*?--\x3e|<!\w[^>]*>|<\?[^>*]*>|<(\/)?([a-z][a-z0-9]*)|([^<&>]+)|([<&>]))/i;
ae.prototype.parse=function(a,b){var c=null,d=!1,e=[],g,h,k;a.ba=[];for(a.Fa=!1;b;){var l=b.match(d?ne:oe);b=b.substring(l[0].length);if(d)if(l[1]){var t=l[1].toLowerCase();if(l[2]){l=l[3];switch(l.charCodeAt(0)){case 34:case 39:l=l.substring(1,l.length-1)}l=pe(this,l.replace(je,""))}else l=t;e.push(t,l)}else l[4]&&(void 0!==h&&(k?a.le&&a.le(g,e):a.Ud&&a.Ud(g)),k&&h&12&&(c=null===c?b.toLowerCase():c.substring(c.length-b.length),d=c.indexOf("\x3c/"+g),0>d&&(d=b.length),h&4?a.Rd&&a.Rd(b.substring(0,
d)):a.he&&a.he(b.substring(0,d).replace(ee,"\x26amp;$1").replace(fe,"\x26lt;").replace(ge,"\x26gt;")),b=b.substring(d)),g=h=k=void 0,e.length=0,d=!1);else if(l[1])qe(a,l[0]);else if(l[3])k=!l[2],d=!0,g=l[3].toLowerCase(),h=ce.hasOwnProperty(g)?ce[g]:void 0;else if(l[4])qe(a,l[4]);else if(l[5])switch(l[5]){case "\x3c":qe(a,"\x26lt;");break;case "\x3e":qe(a,"\x26gt;");break;default:qe(a,"\x26amp;")}}for(c=a.ba.length;0<=--c;)a.xa.append("\x3c/",a.ba[c],"\x3e");a.ba.length=0};
function pe(a,b){return b.replace(ke,ma(function(a,b){var e;e=b.toLowerCase();if(be.hasOwnProperty(e))e=be[e];else{var g=e.match(le);e=g?String.fromCharCode(parseInt(g[1],10)):(g=e.match(me))?String.fromCharCode(parseInt(g[1],16)):""}return e},a))};function re(a,b){var c=new $d;(new ae).parse(new se(c,b,void 0),a);return c.toString()}function se(a,b,c){this.xa=a;this.ba=[];this.Fa=!1;this.pe=b||null;this.sc=c||null}
var te={"*::class":9,"*::dir":0,"*::id":4,"*::lang":0,"*::onclick":2,"*::ondblclick":2,"*::onkeydown":2,"*::onkeypress":2,"*::onkeyup":2,"*::onload":2,"*::onmousedown":2,"*::onmousemove":2,"*::onmouseout":2,"*::onmouseover":2,"*::onmouseup":2,"*::style":3,"*::title":0,"*::accesskey":0,"*::tabindex":0,"*::onfocus":2,"*::onblur":2,"a::coords":0,"a::href":1,"a::hreflang":0,"a::name":7,"a::onblur":2,"a::rel":0,"a::rev":0,"a::shape":0,"a::target":10,"a::type":0,"area::accesskey":0,"area::alt":0,"area::coords":0,
"area::href":1,"area::nohref":0,"area::onfocus":2,"area::shape":0,"area::tabindex":0,"area::target":10,"bdo::dir":0,"blockquote::cite":1,"br::clear":0,"button::accesskey":0,"button::disabled":0,"button::name":8,"button::onblur":2,"button::onfocus":2,"button::tabindex":0,"button::type":0,"button::value":0,"caption::align":0,"col::align":0,"col::char":0,"col::charoff":0,"col::span":0,"col::valign":0,"col::width":0,"colgroup::align":0,"colgroup::char":0,"colgroup::charoff":0,"colgroup::span":0,"colgroup::valign":0,
"colgroup::width":0,"del::cite":1,"del::datetime":0,"dir::compact":0,"div::align":0,"dl::compact":0,"font::color":0,"font::face":0,"font::size":0,"form::accept":0,"form::action":1,"form::autocomplete":0,"form::enctype":0,"form::method":0,"form::name":7,"form::onreset":2,"form::onsubmit":2,"form::target":10,"h1::align":0,"h2::align":0,"h3::align":0,"h4::align":0,"h5::align":0,"h6::align":0,"hr::align":0,"hr::noshade":0,"hr::size":0,"hr::width":0,"img::align":0,"img::alt":0,"img::border":0,"img::height":0,
"img::hspace":0,"img::ismap":0,"img::longdesc":1,"img::name":7,"img::src":1,"img::usemap":11,"img::vspace":0,"img::width":0,"input::accept":0,"input::accesskey":0,"input::autocomplete":0,"input::align":0,"input::alt":0,"input::checked":0,"input::disabled":0,"input::ismap":0,"input::maxlength":0,"input::name":8,"input::onblur":2,"input::onchange":2,"input::onfocus":2,"input::onselect":2,"input::readonly":0,"input::size":0,"input::src":1,"input::tabindex":0,"input::type":0,"input::usemap":11,"input::value":0,
"ins::cite":1,"ins::datetime":0,"label::accesskey":0,"label::for":5,"label::onblur":2,"label::onfocus":2,"legend::accesskey":0,"legend::align":0,"li::type":0,"li::value":0,"map::name":7,"menu::compact":0,"ol::compact":0,"ol::start":0,"ol::type":0,"optgroup::disabled":0,"optgroup::label":0,"option::disabled":0,"option::label":0,"option::selected":0,"option::value":0,"p::align":0,"pre::width":0,"q::cite":1,"select::disabled":0,"select::multiple":0,"select::name":8,"select::onblur":2,"select::onchange":2,
"select::onfocus":2,"select::size":0,"select::tabindex":0,"table::align":0,"table::bgcolor":0,"table::border":0,"table::cellpadding":0,"table::cellspacing":0,"table::frame":0,"table::rules":0,"table::summary":0,"table::width":0,"tbody::align":0,"tbody::char":0,"tbody::charoff":0,"tbody::valign":0,"td::abbr":0,"td::align":0,"td::axis":0,"td::bgcolor":0,"td::char":0,"td::charoff":0,"td::colspan":0,"td::headers":6,"td::height":0,"td::nowrap":0,"td::rowspan":0,"td::scope":0,"td::valign":0,"td::width":0,
"textarea::accesskey":0,"textarea::cols":0,"textarea::disabled":0,"textarea::name":8,"textarea::onblur":2,"textarea::onchange":2,"textarea::onfocus":2,"textarea::onselect":2,"textarea::readonly":0,"textarea::rows":0,"textarea::tabindex":0,"tfoot::align":0,"tfoot::char":0,"tfoot::charoff":0,"tfoot::valign":0,"th::abbr":0,"th::align":0,"th::axis":0,"th::bgcolor":0,"th::char":0,"th::charoff":0,"th::colspan":0,"th::headers":6,"th::height":0,"th::nowrap":0,"th::rowspan":0,"th::scope":0,"th::valign":0,
"th::width":0,"thead::align":0,"thead::char":0,"thead::charoff":0,"thead::valign":0,"tr::align":0,"tr::bgcolor":0,"tr::char":0,"tr::charoff":0,"tr::valign":0,"ul::compact":0,"ul::type":0};
se.prototype.le=function(a,b){if(!this.Fa&&ce.hasOwnProperty(a)){var c=ce[a];if(!(c&32))if(c&16)this.Fa=!(c&2);else{for(var d=b,e=0;e<d.length;e+=2){var g=d[e],h=d[e+1],k=null,l;if((l=a+"::"+g,te.hasOwnProperty(l))||(l="*::"+g,te.hasOwnProperty(l)))k=te[l];if(null!==k)switch(k){case 0:break;case 2:case 3:h=null;break;case 4:case 5:case 6:case 7:case 8:case 9:h=this.sc?this.sc(h):h;break;case 1:h=this.pe&&this.pe(h);break;case 11:h&&"#"===h.charAt(0)?(h=this.sc?this.sc(h):h)&&(h="#"+h):h=null;break;
default:h=null}else h=null;d[e+1]=h}if(b=d){c&2||this.ba.push(a);this.xa.append("\x3c",a);c=0;for(d=b.length;c<d;c+=2)e=b[c],g=b[c+1],null!==g&&void 0!==g&&this.xa.append(" ",e,'\x3d"',g.replace(de,"\x26amp;").replace(fe,"\x26lt;").replace(ge,"\x26gt;").replace(he,"\x26#34;").replace(ie,"\x26#61;"),'"');this.xa.append("\x3e")}}}};
se.prototype.Ud=function(a){if(this.Fa)this.Fa=!1;else if(ce.hasOwnProperty(a)){var b=ce[a];if(!(b&50)){if(b&1)for(b=this.ba.length;0<=--b;){var c=this.ba[b];if(c===a)break;if(!(ce[c]&1))return}else for(b=this.ba.length;0<=--b&&this.ba[b]!==a;);if(!(0>b)){for(var d=this.ba.length;--d>b;)c=this.ba[d],ce[c]&1||this.xa.append("\x3c/",c,"\x3e");this.ba.length=b;this.xa.append("\x3c/",a,"\x3e")}}}};function qe(a,b){a.Fa||a.xa.append(b)}se.prototype.he=function(a){this.Fa||this.xa.append(a)};
se.prototype.Rd=function(a){this.Fa||this.xa.append(a)};function ue(a){if(a.classList)return a.classList;a=a.className;return p(a)&&a.match(/\S+/g)||[]}function ve(a,b){return a.classList?a.classList.contains(b):Ia(ue(a),b)}function we(a,b){a.classList?a.classList.add(b):ve(a,b)||(a.className+=0<a.className.length?" "+b:b)}function xe(a,b){if(a.classList)w(b,function(b){we(a,b)});else{var c={};w(ue(a),function(a){c[a]=!0});w(b,function(a){c[a]=!0});a.className="";for(var d in c)a.className+=0<a.className.length?" "+d:d}}
function ye(a,b){a.classList?a.classList.remove(b):ve(a,b)&&(a.className=Ea(ue(a),function(a){return a!=b}).join(" "))}function ze(a,b){a.classList?w(b,function(b){ye(a,b)}):a.className=Ea(ue(a),function(a){return!Ia(b,a)}).join(" ")};function Ae(a,b,c,d,e){if(!(A||$a||E&&F("525")))return!0;if(ab&&e)return Be(a);if(e&&!d)return!1;q(b)&&(b=Ce(b));if(!c&&(17==b||18==b||ab&&91==b))return!1;if((E||$a)&&d&&c)switch(a){case 220:case 219:case 221:case 192:case 186:case 189:case 187:case 188:case 190:case 191:case 192:case 222:return!1}if(A&&d&&b==a)return!1;switch(a){case 13:return!0;case 27:return!(E||$a)}return Be(a)}
function Be(a){if(48<=a&&57>=a||96<=a&&106>=a||65<=a&&90>=a||(E||$a)&&0==a)return!0;switch(a){case 32:case 43:case 63:case 64:case 107:case 109:case 110:case 111:case 186:case 59:case 189:case 187:case 61:case 188:case 190:case 191:case 192:case 222:case 219:case 220:case 221:return!0;default:return!1}}function Ce(a){if(D)a=De(a);else if(ab&&E)a:switch(a){case 93:a=91;break a}return a}
function De(a){switch(a){case 61:return 187;case 59:return 186;case 173:return 189;case 224:return 91;case 0:return 224;default:return a}};function Ee(a,b){vc.call(this);a&&Fe(this,a,b)}u(Ee,vc);f=Ee.prototype;f.C=null;f.oc=null;f.ed=null;f.pc=null;f.X=-1;f.Ga=-1;f.Rc=!1;
var Ge={3:13,12:144,63232:38,63233:40,63234:37,63235:39,63236:112,63237:113,63238:114,63239:115,63240:116,63241:117,63242:118,63243:119,63244:120,63245:121,63246:122,63247:123,63248:44,63272:46,63273:36,63275:35,63276:33,63277:34,63289:144,63302:45},He={Up:38,Down:40,Left:37,Right:39,Enter:13,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,"U+007F":46,Home:36,End:35,PageUp:33,PageDown:34,Insert:45},Ie=A||$a||E&&F("525"),Je=ab&&D;f=Ee.prototype;
f.Ie=function(a){if(E||$a)if(17==this.X&&!a.ctrlKey||18==this.X&&!a.altKey||ab&&91==this.X&&!a.metaKey)this.Ga=this.X=-1;-1==this.X&&(a.ctrlKey&&17!=a.keyCode?this.X=17:a.altKey&&18!=a.keyCode?this.X=18:a.metaKey&&91!=a.keyCode&&(this.X=91));Ie&&!Ae(a.keyCode,this.X,a.shiftKey,a.ctrlKey,a.altKey)?this.handleEvent(a):(this.Ga=Ce(a.keyCode),Je&&(this.Rc=a.altKey))};f.Ke=function(a){this.Ga=this.X=-1;this.Rc=a.altKey};
f.handleEvent=function(a){var b=a.T,c,d,e=b.altKey;A&&"keypress"==a.type?(c=this.Ga,d=13!=c&&27!=c?b.keyCode:0):(E||$a)&&"keypress"==a.type?(c=this.Ga,d=0<=b.charCode&&63232>b.charCode&&Be(c)?b.charCode:0):Za&&!E?(c=this.Ga,d=Be(c)?b.keyCode:0):(c=b.keyCode||this.Ga,d=b.charCode||0,Je&&(e=this.Rc),ab&&63==d&&224==c&&(c=191));var g=c=Ce(c),h=b.keyIdentifier;c?63232<=c&&c in Ge?g=Ge[c]:25==c&&a.shiftKey&&(g=9):h&&h in He&&(g=He[h]);a=g==this.X;this.X=g;b=new Ke(g,d,a,b);b.altKey=e;this.dispatchEvent(b)};
f.c=function(){return this.C};function Fe(a,b,c){a.pc&&a.detach();a.C=b;a.oc=M(a.C,"keypress",a,c);a.ed=M(a.C,"keydown",a.Ie,c,a);a.pc=M(a.C,"keyup",a.Ke,c,a)}f.detach=function(){this.oc&&(N(this.oc),N(this.ed),N(this.pc),this.pc=this.ed=this.oc=null);this.C=null;this.Ga=this.X=-1};f.N=function(){Ee.w.N.call(this);this.detach()};function Ke(a,b,c,d){L.call(this,d);this.type="key";this.keyCode=a;this.charCode=b;this.repeat=c}u(Ke,L);function Le(){}ca(Le);Le.prototype.Se=0;function Me(a){vc.call(this);this.Gb=a||rb();this.Wa=Ne;this.nc=null;this.ka=!1;this.C=null;this.Ea=void 0;this.Na=this.cc=this.va=null;this.qe=!1}u(Me,vc);Me.prototype.Oe=Le.ic();var Ne=null;
function Oe(a,b){switch(a){case 1:return b?"disable":"enable";case 2:return b?"highlight":"unhighlight";case 4:return b?"activate":"deactivate";case 8:return b?"select":"unselect";case 16:return b?"check":"uncheck";case 32:return b?"focus":"blur";case 64:return b?"open":"close"}throw Error("Invalid component state");}function Pe(a,b){if(a.va&&a.va.Na){var c=a.va.Na,d=a.nc;d in c&&delete c[d];c=a.va.Na;if(null!==c&&b in c)throw Error('The object already contains the key "'+b+'"');c[b]=a}a.nc=b}f=Me.prototype;
f.c=function(){return this.C};f.hc=function(){this.Ea||(this.Ea=new tc(this));return this.Ea};f.getParent=function(){return this.va};f.rd=function(a){if(this.va&&this.va!=a)throw Error("Method not supported");Me.w.rd.call(this,a)};f.Wd=function(){return this.Gb};f.Eb=function(a){if(this.ka)throw Error("Component already rendered");if(a&&this.Bb(a)){this.qe=!0;var b=H(a);this.Gb&&this.Gb.W==b||(this.Gb=rb(a));this.Sd(a);this.fb()}else throw Error("Invalid element to decorate");};f.Bb=function(){return!0};
f.Sd=function(a){this.C=a};f.fb=function(){this.ka=!0;Qe(this,function(a){!a.ka&&a.c()&&a.fb()})};f.Ib=function(){Qe(this,function(a){a.ka&&a.Ib()});this.Ea&&this.Ea.Ha();this.ka=!1};f.N=function(){this.ka&&this.Ib();this.Ea&&(this.Ea.Fb(),delete this.Ea);Qe(this,function(a){a.Fb()});!this.qe&&this.C&&Ab(this.C);this.va=this.C=this.Na=this.cc=null;Me.w.N.call(this)};f.Lb=function(){return this.C};f.qb=function(a){if(this.ka)throw Error("Component already rendered");this.Wa=a};
function Qe(a,b){a.cc&&w(a.cc,b,void 0)}f.removeChild=function(a,b){if(a){var c=p(a)?a:a.nc||(a.nc=":"+(a.Oe.Se++).toString(36)),d;this.Na&&c?(d=this.Na,d=(null!==d&&c in d?d[c]:void 0)||null):d=null;a=d;if(c&&a){d=this.Na;c in d&&delete d[c];y(this.cc,a);b&&(a.Ib(),a.C&&Ab(a.C));c=a;if(null==c)throw Error("Unable to set parent component");c.va=null;Me.w.rd.call(c,null)}}if(!a)throw Error("Child is not in parent component");return a};var Re;function Se(a,b,c){ea(c)&&(c=c.join(" "));var d="aria-"+b;""===c||void 0==c?(Re||(Re={atomic:!1,autocomplete:"none",dropeffect:"none",haspopup:!1,live:"off",multiline:!1,multiselectable:!1,orientation:"vertical",readonly:!1,relevant:"additions text",required:!1,sort:"none",busy:!1,disabled:!1,hidden:!1,invalid:"false"}),c=Re,b in c?a.setAttribute(d,c[b]):a.removeAttribute(d)):a.setAttribute(d,c)};function Te(){}var Ue;ca(Te);var Ve={button:"pressed",checkbox:"checked",menuitem:"selected",menuitemcheckbox:"checked",menuitemradio:"checked",radio:"checked",tab:"selected",treeitem:"selected"};f=Te.prototype;f.Lb=function(a){return a};f.Hb=function(a,b,c){if(a=a.c?a.c():a){var d=[b];A&&!F("7")&&(d=We(ue(a),b),d.push(b));(c?xe:ze)(a,d)}};f.Bb=function(){return!0};
f.Eb=function(a,b){b.id&&Pe(a,b.id);var c=this.Lb(b);c&&c.firstChild?Xe(a,c.firstChild.nextSibling?Ja(c.childNodes):c.firstChild):a.Oa=null;var d=0,e=this.Mb(),g=this.Mb(),h=!1,k=!1,l=!1,t=Ja(ue(b));w(t,function(a){h||a!=e?k||a!=g?d|=Ye(this,a):k=!0:(h=!0,g==e&&(k=!0));1==Ye(this,a)&&Jb(c)&&Kb(c)&&Ib(c,!1)},this);a.H=d;h||(t.push(e),g==e&&(k=!0));k||t.push(g);var B=a.ja;B&&t.push.apply(t,B);if(A&&!F("7")){var C=We(t);0<C.length&&(t.push.apply(t,C),l=!0)}if(!h||!k||B||l)b.className=t.join(" ");return b};
f.qd=function(a,b){Se(a,"label",b)};f.zc=function(a,b){var c=!b,d=A||Za?a.getElementsByTagName("*"):null;if(Nc){if(c=c?"none":"",a.style&&(a.style[Nc]=c),d)for(var e=0,g;g=d[e];e++)g.style&&(g.style[Nc]=c)}else if(A||Za)if(c=c?"on":"",a.setAttribute("unselectable",c),d)for(e=0;g=d[e];e++)g.setAttribute("unselectable",c)};f.qb=function(a,b){this.Hb(a,this.Mb()+"-rtl",b)};f.cd=function(a){var b;return a.ca&32&&(b=a.gb())?Jb(b)&&Kb(b):!1};
f.Bc=function(a,b){var c;if(a.ca&32&&(c=a.gb())){if(!b&&a.H&32){try{c.blur()}catch(d){}a.H&32&&a.Xd()}(Jb(c)&&Kb(c))!=b&&Ib(c,b)}};f.Y=function(a,b,c){var d=a.c();if(d){var e;this.dc||Ze(this);(e=this.dc[b])&&this.Hb(a,e,c);this.rb(d,b,c)}};f.rb=function(a,b,c){Ue||(Ue={1:"disabled",8:"selected",16:"checked",64:"expanded"});b=Ue[b];var d=a.getAttribute("role")||null;d&&(d=Ve[d]||b,b="checked"==b||"selected"==b?d:b);b&&Se(a,b,c)};
f.Ia=function(a,b){var c=this.Lb(a);if(c&&(zb(c),b))if(p(b))Hb(c,b);else{var d=function(a){if(a){var b=H(c);c.appendChild(p(a)?b.createTextNode(a):a)}};ea(b)?w(b,d):!fa(b)||"nodeType"in b?d(b):w(Ja(b),d)}};f.gb=function(a){return a.c()};f.Mb=function(){return"goog-control"};function We(a,b){var c=[];b&&(a=a.concat([b]));w([],function(d){!Ga(d,na(Ia,a))||b&&!Ia(d,b)||c.push(d.join("_"))});return c}
function Ye(a,b){if(!a.oe){a.dc||Ze(a);var c=a.dc,d={},e;for(e in c)d[c[e]]=e;a.oe=d}c=parseInt(a.oe[b],10);return isNaN(c)?0:c}function Ze(a){var b=a.Mb();b.replace(/\xa0|\s/g," ");a.dc={1:b+"-disabled",2:b+"-hover",4:b+"-active",8:b+"-selected",16:b+"-checked",32:b+"-focused",64:b+"-open"}};var $e={};function U(a,b,c){Me.call(this,c);if(!b){b=this.constructor;for(var d;b;){d=ha(b);if(d=$e[d])break;b=b.w?b.w.constructor:null}b=d?r(d.ic)?d.ic():new d:null}this.D=b;this.Oa=n(a)?a:null;this.Qd=null}u(U,Me);f=U.prototype;f.Oa=null;f.H=0;f.ca=39;f.Tc=255;f.af=0;f.Ya=!0;f.ja=null;f.ad=!0;f.Qc=!1;f.Ve=null;function af(a){a.ka&&0!=a.ad&&bf(a,!1);a.ad=!1}f.gb=function(){return this.D.gb(this)};
f.Hb=function(a,b){b?a&&(this.ja?Ia(this.ja,a)||this.ja.push(a):this.ja=[a],this.D.Hb(this,a,!0)):a&&this.ja&&y(this.ja,a)&&(0==this.ja.length&&(this.ja=null),this.D.Hb(this,a,!1))};f.qd=function(a){this.Qd=a;var b=this.c();b&&this.D.qd(b,a)};f.Lb=function(){return this.D.Lb(this.c())};f.Bb=function(a){return this.D.Bb(a)};
f.Sd=function(a){var b=this.C=a=this.D.Eb(this,a),c=this.Ve||void 0;if(c){var d=b.getAttribute("role")||null;c!=d&&(c?b.setAttribute("role",c):b.removeAttribute("role"))}this.Qc||this.D.zc(a,!1);this.Ya="none"!=a.style.display};
f.fb=function(){U.w.fb.call(this);var a=this.D,b=this.C,c=this.Qd;null!=c&&a.qd(b,c);this.Ya||Se(b,"hidden",!this.Ya);this.isEnabled()||a.rb(b,1,!this.isEnabled());this.ca&8&&a.rb(b,8,!!(this.H&8));this.ca&16&&a.rb(b,16,!!(this.H&16));this.ca&64&&a.rb(b,64,!!(this.H&64));a=this.D;null==this.Wa&&(this.Wa=Mc(this.ka?this.C:this.Gb.W.body));this.Wa&&a.qb(this.c(),!0);this.isEnabled()&&a.Bc(this,this.Ya);this.ca&-2&&(this.ad&&bf(this,!0),this.ca&32&&(a=this.gb()))&&(b=this.mb||(this.mb=new Ee),Fe(b,a),
this.hc().l(b,"key",this.Je).l(a,"focus",this.He).l(a,"blur",this.Xd))};function bf(a,b){var c=a.hc(),d=a.c();b?(c.l(d,"mouseover",a.$d).l(d,"mousedown",a.$c).l(d,"mouseup",a.bd).l(d,"mouseout",a.Zd),a.lc!=ba&&c.l(d,"contextmenu",a.lc),A&&(c.l(d,"dblclick",a.Yd),a.Pb||(a.Pb=new cf(a),Tb(a,na(Ub,a.Pb))))):(c.ya(d,"mouseover",a.$d).ya(d,"mousedown",a.$c).ya(d,"mouseup",a.bd).ya(d,"mouseout",a.Zd),a.lc!=ba&&c.ya(d,"contextmenu",a.lc),A&&(c.ya(d,"dblclick",a.Yd),Ub(a.Pb),a.Pb=null))}
f.Ib=function(){U.w.Ib.call(this);this.mb&&this.mb.detach();this.Ya&&this.isEnabled()&&this.D.Bc(this,!1)};f.N=function(){U.w.N.call(this);this.mb&&(this.mb.Fb(),delete this.mb);delete this.D;this.Pb=this.ja=this.Oa=null};f.Kb=function(){return this.Oa};f.Ia=function(a){this.D.Ia(this.c(),a);this.Oa=a};function Xe(a,b){a.Oa=b}f.qb=function(a){U.w.qb.call(this,a);var b=this.c();b&&this.D.qb(b,a)};f.zc=function(a){this.Qc=a;var b=this.c();b&&this.D.zc(b,a)};f.isEnabled=function(){return!(this.H&1)};
f.Ac=function(a){var b=this.getParent();b&&"function"==typeof b.isEnabled&&!b.isEnabled()||!df(this,1,!a)||(a||(this.setActive(!1),ef(this,!1)),this.Ya&&this.D.Bc(this,a),this.Y(1,!a,!0))};function ef(a,b){df(a,2,b)&&a.Y(2,b)}f.setActive=function(a){df(this,4,a)&&this.Y(4,a)};f.Y=function(a,b,c){c||1!=a?this.ca&a&&b!=!!(this.H&a)&&(this.D.Y(this,a,b),this.H=b?this.H|a:this.H&~a):this.Ac(!b)};function V(a,b){return!!(a.Tc&b)&&!!(a.ca&b)}
function df(a,b,c){return!!(a.ca&b)&&!!(a.H&b)!=c&&(!(a.af&b)||a.dispatchEvent(Oe(b,c)))&&!a.Pa}f.$d=function(a){(!a.relatedTarget||!Gb(this.c(),a.relatedTarget))&&this.dispatchEvent("enter")&&this.isEnabled()&&V(this,2)&&ef(this,!0)};f.Zd=function(a){a.relatedTarget&&Gb(this.c(),a.relatedTarget)||!this.dispatchEvent("leave")||(V(this,4)&&this.setActive(!1),V(this,2)&&ef(this,!1))};f.lc=ba;
f.$c=function(a){this.isEnabled()&&(V(this,2)&&ef(this,!0),Zb(a)&&(V(this,4)&&this.setActive(!0),this.D&&this.D.cd(this)&&this.gb().focus()));!this.Qc&&Zb(a)&&a.preventDefault()};f.bd=function(a){this.isEnabled()&&(V(this,2)&&ef(this,!0),this.H&4&&ff(this,a)&&V(this,4)&&this.setActive(!1))};f.Yd=function(a){this.isEnabled()&&ff(this,a)};
function ff(a,b){if(V(a,16)){var c=!(a.H&16);df(a,16,c)&&a.Y(16,c)}V(a,8)&&df(a,8,!0)&&a.Y(8,!0);V(a,64)&&(c=!(a.H&64),df(a,64,c)&&a.Y(64,c));c=new Vb("action",a);b&&(c.altKey=b.altKey,c.ctrlKey=b.ctrlKey,c.metaKey=b.metaKey,c.shiftKey=b.shiftKey,c.nd=b.nd);return a.dispatchEvent(c)}f.He=function(){V(this,32)&&df(this,32,!0)&&this.Y(32,!0)};f.Xd=function(){V(this,4)&&this.setActive(!1);V(this,32)&&df(this,32,!1)&&this.Y(32,!1)};
f.Je=function(a){return this.Ya&&this.isEnabled()&&13==a.keyCode&&ff(this,a)?(a.preventDefault(),a.stopPropagation(),!0):!1};if(!r(U))throw Error("Invalid component class "+U);if(!r(Te))throw Error("Invalid renderer class "+Te);var gf=ha(U);$e[gf]=Te;function hf(){return new U(null)}if(!r(hf))throw Error("Invalid decorator function "+hf);
function cf(a){Qb.call(this);this.fc=a;this.ec=!1;this.Ob=new tc(this);Tb(this,na(Ub,this.Ob));a=this.fc.C;this.Ob.l(a,"mousedown",this.Le).l(a,"mouseup",this.Me).l(a,"click",this.Ge)}u(cf,Qb);cf.prototype.Le=function(){this.ec=!1};cf.prototype.Me=function(){this.ec=!0};cf.prototype.Ge=function(a){if(this.ec)this.ec=!1;else{var b=a.T,c=b.button,d=b.type;b.button=0;b.type="mousedown";this.fc.$c(new L(b,a.currentTarget));b.type="mouseup";this.fc.bd(new L(b,a.currentTarget));b.button=c;b.type=d}};
cf.prototype.N=function(){this.fc=null;cf.w.N.call(this)};function of(){}u(of,Te);ca(of);f=of.prototype;f.Eb=function(a,b){af(a);a.Tc&=-256;if(a.ka&&a.H&32)throw Error("Component already rendered");a.H&32&&a.Y(32,!1);a.ca&=-33;of.w.Eb.call(this,a,b);a.Ia(b.value);return b};f.Bb=function(a){return"TEXTAREA"==a.tagName};f.qb=ba;f.cd=function(a){return a.isEnabled()};f.Bc=ba;f.Y=function(a,b,c){of.w.Y.call(this,a,b,c);(a=a.c())&&1==b&&(a.disabled=c)};f.rb=ba;f.Ia=function(a,b){a&&(a.value=b)};f.Mb=function(){return"goog-textarea"};function pf(a,b,c){U.call(this,a,b||of.ic(),c);af(this);this.zc(!0);this.ib=""!=a;a||(this.Oa="")}u(pf,U);var qf=!(A&&!(11<=jb));f=pf.prototype;f.lb=!1;f.mc=!1;f.ib=!1;f.ta=0;f.Qe=0;f.fe=0;f.ae=!1;f.rc=!1;f.pd=!1;f.od=!1;f.nb="";function rf(a){return a.Ta.top+a.Ta.bottom+a.Uc.top+a.Uc.bottom}function sf(a){var b=a.fe,c=a.c();b&&c&&a.rc&&(b-=rf(a));return b}function tf(a){return a.c().value!=a.nb||uf(a)||a.ib?a.c().value:""}f.Ia=function(a){pf.w.Ia.call(this,a);this.ib=""!=a;this.resize()};
f.Ac=function(a){pf.w.Ac.call(this,a);this.c().disabled=!a};f.resize=function(){this.c()&&this.kc()};function uf(a){return"placeholder"in a.c()}function vf(a){a.nb&&(uf(a)?a.c().placeholder=a.nb:!a.c()||a.ib||a.mc||(we(a.c(),wf),a.c().value=a.nb))}
f.fb=function(){pf.w.fb.call(this);var a=this.c();O(a,{overflowY:"hidden",overflowX:"auto",boxSizing:"border-box",MsBoxSizing:"border-box",WebkitBoxSizing:"border-box",MozBoxSizing:"border-box"});this.Ta=Qc(a,"padding");this.Uc=Tc(a);this.hc().l(a,"scroll",this.kc).l(a,"focus",this.kc).l(a,"keyup",this.kc).l(a,"mouseup",this.Re).l(a,"blur",this.Ae);vf(this);this.resize()};
function xf(a){if(!a.ae){var b=a.c().cloneNode(!1);O(b,{position:"absolute",height:"auto",top:"-9999px",margin:"0",padding:"1px",border:"1px solid #000",overflow:"hidden"});a.Wd().W.body.appendChild(b);var c=b.scrollHeight;b.style.padding="10px";var d=b.scrollHeight;a.pd=d>c;b.style.borderWidth="10px";a.od=b.scrollHeight>d;b.style.height="100px";100!=b.offsetHeight&&(a.rc=!0);Ab(b);a.ae=!0}b=a.c();isNaN(a.Ta.top)&&(a.Ta=Qc(b,"padding"),a.Uc=Tc(b));var c=a.c().scrollHeight,e=a.c(),d=e.offsetHeight-
e.clientHeight;if(!a.pd)var g=a.Ta,d=d-(g.top+g.bottom);a.od||(e=Tc(e),d-=e.top+e.bottom);c+=0<d?d:0;a.rc?c-=rf(a):(a.pd||(d=a.Ta,c+=d.top+d.bottom),a.od||(a=Tc(b),c+=a.top+a.bottom));return c}function yf(a,b){a.ta!=b&&(a.ta=b,a.c().style.height=b+"px")}function zf(a){var b=a.c();b.style.height="auto";var c=b.value.match(/\n/g)||[];b.rows=c.length+1;a.ta=0}var wf="textarea-placeholder-input";pf.prototype.Ae=function(){uf(this)||(this.mc=!1,""==this.c().value&&(this.ib=!1,vf(this)))};
pf.prototype.kc=function(a){if(!this.lb){var b=this.c();!uf(this)&&a&&"focus"==a.type&&(b.value==this.nb&&this.nb&&!this.mc&&(ye(b,wf),b.value=""),this.mc=!0,this.ib=""!=b.value);var c=!1;this.lb=!0;a=this.ta;if(b.scrollHeight){var d=!1,e=!1,g=xf(this),h=b.offsetHeight,k=sf(this),l;l=this.Qe;var t=this.c();l&&t&&this.rc&&(l-=rf(this));k&&g<k?(yf(this,k),d=!0):l&&g>l?(yf(this,l),b.style.overflowY="",e=!0):h!=g?yf(this,g):this.ta||(this.ta=g);d||e||!qf||(c=!0)}else zf(this);this.lb=!1;c&&(b=this.c(),
this.lb||(this.lb=!0,(e=b.scrollHeight)?(g=xf(this),c=sf(this),c&&g<=c||(d=this.Ta,b.style.paddingBottom=d.bottom+1+"px",xf(this)==g&&(b.style.paddingBottom=d.bottom+e+"px",b.scrollTop=0,e=xf(this)-e,e>=c?yf(this,e):yf(this,c)),b.style.paddingBottom=d.bottom+"px")):zf(this),this.lb=!1));a!=this.ta&&this.dispatchEvent("resize")}};
pf.prototype.Re=function(){var a=this.c(),b=a.offsetHeight;a.filters&&a.filters.length&&(a=a.filters.item("DXImageTransform.Microsoft.DropShadow"))&&(b-=a.offX);b!=this.ta&&(this.ta=this.fe=b)};A&&F(8);function Af(a){if(null!=a)switch(a.Vc){case 1:return 1;case -1:return-1;case 0:return 0}return null}function Bf(){Wd.call(this)}u(Bf,Wd);Bf.prototype.Db=Td;function Cf(a){return null!=a&&a.Db===Td?a:a instanceof ob?Df(a instanceof ob&&a.constructor===ob&&a.te===pb?a.We:"type_error:SafeHtml",a.Ce):Df(qa(String(String(a))),Af(a))}var Df=function(a){function b(a){this.content=a}b.prototype=a.prototype;return function(a,d){var e=new b(String(a));void 0!==d&&(e.Vc=d);return e}}(Bf);
(function(a){function b(a){this.content=a}b.prototype=a.prototype;return function(a,d){var e=String(a);if(!e)return"";e=new b(e);void 0!==d&&(e.Vc=d);return e}})(Bf);function Ef(a){return a.replace(/<\//g,"\x3c\\/").replace(/\]\]>/g,"]]\\\x3e")}function Ff(a){null!=a&&a.Db===Td?(a=String(a.Kb()).replace(Gf,"").replace(Hf,"\x26lt;"),a=String(a).replace(If,Jf)):a=qa(String(a));return a}
function Kf(a){null!=a&&a.Db===Ud?a=Ef(a.Kb()):null==a?a="":a instanceof mb?(a=a instanceof mb&&a.constructor===mb&&a.ue===nb?a.Xe:"type_error:SafeStyle",a=Ef(a)):(a=String(a),a=Lf.test(a)?a:"zSoyz");return a}
var Mf={"\x00":"\x26#0;","\t":"\x26#9;","\n":"\x26#10;","\x0B":"\x26#11;","\f":"\x26#12;","\r":"\x26#13;"," ":"\x26#32;",'"':"\x26quot;","\x26":"\x26amp;","'":"\x26#39;","-":"\x26#45;","/":"\x26#47;","\x3c":"\x26lt;","\x3d":"\x26#61;","\x3e":"\x26gt;","`":"\x26#96;","\u0085":"\x26#133;","\u00a0":"\x26#160;","\u2028":"\x26#8232;","\u2029":"\x26#8233;"};function Jf(a){return Mf[a]}
var If=/[\x00\x22\x27\x3c\x3e]/g,Lf=/^(?!-*(?:expression|(?:moz-)?binding))(?:[.#]?-?(?:[_a-z0-9-]+)(?:-[_a-z0-9-]+)*-?|-?(?:[0-9]+(?:\.[0-9]*)?|\.[0-9]+)(?:[a-z]{1,2}|%)?|!important|)$/i,Gf=/<(?:!|\/?([a-zA-Z][a-zA-Z0-9:\-]*))(?:[^>'"]|"[^"]*"|'[^']*')*>/g,Hf=/</g;function Nf(){return Df('\x3cdiv class\x3d"annotorious-popup top-left"\x3e\x3cdiv class\x3d"annotorious-popup-buttons"\x3e\x3ca class\x3d"annotorious-popup-button annotorious-popup-button-edit" href\x3d"javascript:void(0);"\x3eEdit\x3c/a\x3e\x3ca class\x3d"annotorious-popup-button annotorious-popup-button-delete" href\x3d"javascript:void(0);"\x3eDelete\x3c/a\x3e\x3c/div\x3e\x3cspan class\x3d"annotorious-popup-text"\x3e\x3c/span\x3e\x3c/div\x3e')}
function Of(){return Df('\x3cdiv class\x3d"annotorious-editor"\x3e\x3cform\x3e\x3ctextarea class\x3d"annotorious-editor-text" placeholder\x3d"Add a Comment..." tabindex\x3d"1"\x3e\x3c/textarea\x3e\x3cdiv class\x3d"annotorious-editor-button-container"\x3e\x3ca class\x3d"annotorious-editor-button annotorious-editor-button-cancel" href\x3d"javascript:void(0);" tabindex\x3d"3"\x3eCancel\x3c/a\x3e\x3ca class\x3d"annotorious-editor-button annotorious-editor-button-save" href\x3d"javascript:void(0);" tabindex\x3d"2"\x3eSave\x3c/a\x3e\x3c/div\x3e\x3c/form\x3e\x3c/div\x3e')};function Pf(a){this.element=Xd(Of);this.g=a;this.xe=a.getItem();this.cb=new pf("");this.ve=I(".annotorious-editor-button-cancel",this.element)[0];this.Ed=I(".annotorious-editor-button-save",this.element)[0];this.we=Db(this.Ed);this.tb=[];var b=this;M(this.ve,"click",function(c){c.preventDefault();a.stopSelection(b.Md);b.close()});M(this.Ed,"click",function(c){c.preventDefault();c=b.Vd();a.V(c);a.stopSelection();b.Md?a.fireEvent("onAnnotationUpdated",c,a.getItem()):a.fireEvent("onAnnotationCreated",
c,a.getItem());b.close()});R(this.element,!1);a.element.appendChild(this.element);this.cb.Eb(I(".annotorious-editor-text",this.element)[0]);ed(this.element,function(){b.cb.resize()})}f=Pf.prototype;f.Pc=function(a){var b=xb("div","annotorious-editor-field");p(a)?b.innerHTML=a:r(a)?this.tb.push({S:b,Yc:a}):Cb(a)&&b.appendChild(a);a=this.we;a.parentNode&&a.parentNode.insertBefore(b,a)};
f.open=function(a){(this.Wb=this.Md=a)&&this.cb.Ia(String(a.text));R(this.element,!0);this.cb.c().focus();w(this.tb,function(b){var c=b.Yc(a);p(c)?b.S.innerHTML=c:Cb(c)&&(zb(b.S),b.S.appendChild(c))});this.g.fireEvent("onEditorShown",a)};f.close=function(){R(this.element,!1);this.cb.Ia("")};f.setPosition=function(a){Dc(this.element,a.x,a.y)};f.Vd=function(){var a=re(tf(this.cb),function(a){return a});this.Wb?this.Wb.text=a:this.Wb=new Fd(this.xe.src,a,this.g.Ca().getShape());return this.Wb};
Pf.prototype.addField=Pf.prototype.Pc;Pf.prototype.getAnnotation=Pf.prototype.Vd;function Qf(a,b,c){var d=this;c||(c="Click and Drag to Annotate");this.element=Xd(Rf,{qc:c});this.g=a;this.Jd=I(".annotorious-hint-msg",this.element)[0];this.Hd=I(".annotorious-hint-icon",this.element)[0];this.Nc=function(){d.show()};this.Mc=function(){Sf(d)};this.Ec();Sf(this);b.appendChild(this.element)}
Qf.prototype.Ec=function(){var a=this;this.Ld=M(this.Hd,"mouseover",function(){a.show();window.clearTimeout(a.Jc)});this.Kd=M(this.Hd,"mouseout",function(){Sf(a)});this.g.o("onMouseOverItem",this.Nc);this.g.o("onMouseOutOfItem",this.Mc)};Qf.prototype.Xb=function(){N(this.Ld);N(this.Kd);this.g.yc("onMouseOverItem",this.Nc);this.g.yc("onMouseOutOfItem",this.Mc)};Qf.prototype.show=function(){window.clearTimeout(this.Jc);Q(this.Jd,.8);var a=this;this.Jc=window.setTimeout(function(){Sf(a)},3E3)};
function Sf(a){window.clearTimeout(a.Jc);Q(a.Jd,0)}Qf.prototype.F=function(){this.Xb();delete this.Ld;delete this.Kd;delete this.Nc;delete this.Mc;Ab(this.element)};function Tf(a){this.element=Xd(Nf);this.g=a;this.ye=I(".annotorious-popup-text",this.element)[0];this.za=I(".annotorious-popup-buttons",this.element)[0];this.Hc=!0;this.tb=[];var b=I(".annotorious-popup-button-edit",this.za)[0],c=I(".annotorious-popup-button-delete",this.za)[0],d=this;M(b,"mouseover",function(){Pd(b,"annotorious-popup-button-active")});M(b,"mouseout",function(){});M(b,"click",function(){O(d.element,"pointer-events","none");a.Wc(d.h)});M(c,"mouseover",function(){Pd(c,"annotorious-popup-button-active")});
M(c,"mouseout",function(){});M(c,"click",function(){a.fireEvent("beforeAnnotationRemoved",d.h)||(O(d.element,"pointer-events","none"),a.O(d.h),a.fireEvent("onAnnotationRemoved",d.h))});Uf&&(M(this.element,"mouseover",function(){window.clearTimeout(d.Fd);1>Bc(d.za,"opacity")&&Q(d.za,1);d.clearHideTimer()}),M(this.element,"mouseout",function(){}),a.o("onMouseOutOfItem",function(){}));Q(this.element,0);O(this.element,"pointer-events","none");a.element.appendChild(this.element)}f=Tf.prototype;
f.Pc=function(a){var b=xb("div","annotorious-popup-field");p(a)?b.innerHTML=a:r(a)?this.tb.push({S:b,Yc:a}):Cb(a)&&b.appendChild(a);this.element.appendChild(b)};f.startHideTimer=function(){this.Hc=!1;if(!this.yb){var a=this;this.yb=window.setTimeout(function(){a.g.fireEvent("beforePopupHide",a);a.Hc||(Q(a.element,0),O(a.element,"pointer-events","none"),Q(a.za,1),delete a.yb)},150)}};f.clearHideTimer=function(){this.Hc=!0;this.yb&&(window.clearTimeout(this.yb),delete this.yb)};
f.show=function(a,b){this.clearHideTimer();b&&this.setPosition(b);a&&this.setAnnotation(a);this.Fd&&window.clearTimeout(this.Fd);Q(this.za,1);Q(this.element,1);O(this.element,"pointer-events","auto");this.g.fireEvent("onPopupShown",this.h)};f.setPosition=function(a){Dc(this.element,new G(a.x,a.y))};
f.setAnnotation=function(a){this.h=a;this.ye.innerHTML=a.text?a.text.replace(/\n/g,"\x3cbr/\x3e"):'\x3cspan class\x3d"annotorious-popup-empty"\x3eNo comment\x3c/span\x3e';"editable"in a&&0==a.editable?R(this.za,!1):R(this.za,!0);w(this.tb,function(b){var c=b.Yc(a);p(c)?b.S.innerHTML=c:Cb(c)&&(zb(b.S),b.S.appendChild(c))})};Tf.prototype.addField=Tf.prototype.Pc;function Vf(){}f=Vf.prototype;f.V=function(a,b){this.m.V(a,b)};f.o=function(a,b){this.L.o(a,b)};f.fireEvent=function(a,b,c){return this.L.fireEvent(a,b,c)};f.Ca=function(){return this.K};f.G=function(a){this.m.G(a)};f.O=function(a){this.m.O(a)};f.yc=function(a,b){this.L.yc(a,b)};f.stopSelection=function(a){Uf&&R(this.f,!1);this.zb&&(this.zb(),delete this.zb);this.K.stopSelection();a&&this.m.V(a)};
function Wf(a,b){M(b,Xf,function(c){console.log("start selection event");console.log(c);c=Yf(c,b);a.m.G(!1);a.Zb?(R(a.f,!0),a.K.startSelection(c.x,c.y)):(c=a.m.Jb(c.x,c.y),0<c.length&&a.m.G(c[0]))})};function Zf(a,b){this.ga=a;this.g=b;this.Za=[];this.oa=[];this.Ka=this.ga.getContext("2d");this.Ja=!0;this.Yb=!1;var c=this;M(this.ga,$f,function(a){if(c.Ja){var b=ag(c,a.offsetX,a.offsetY);b?(c.Yb=c.Yb&&b==c.h,c.h)?c.h!=b&&(c.Ja=!1,c.g.popup.startHideTimer()):(c.h=b,bg(c),c.g.fireEvent("onMouseOverAnnotation",{R:c.h,mouseEvent:a})):!c.Yb&&c.h&&(c.Ja=!1,c.g.popup.startHideTimer())}else c.sb=a});M(this.ga,Xf,function(){void 0!==c.h&&0!=c.h&&c.g.fireEvent("onAnnotationClicked",c.h)});b.o("onMouseOutOfItem",
function(){delete c.h;c.Ja=!0});b.o("beforePopupHide",function(){if(!c.Ja&&c.sb){var a=c.h;c.h=ag(c,c.sb.offsetX,c.sb.offsetY);c.Ja=!0;a!=c.h?(bg(c),c.g.fireEvent("onMouseOutOfAnnotation",{R:a,mouseEvent:c.sb}),c.g.fireEvent("onMouseOverAnnotation",{R:c.h,mouseEvent:c.sb})):c.h&&c.g.popup.clearHideTimer()}else bg(c)})}f=Zf.prototype;
f.V=function(a,b){b&&(b==this.h&&delete this.h,y(this.Za,b),delete this.oa[Ed(b.shapes[0])]);this.Za.push(a);var c=a.shapes[0];if("pixel"!=c.units)var d=this,c=Dd(c,function(a){return d.g.Ra(a)});this.oa[Ed(a.shapes[0])]=c;bg(this)};f.O=function(a){a==this.h&&delete this.h;y(this.Za,a);delete this.oa[Ed(a.shapes[0])];bg(this)};f.I=function(){return Ja(this.Za)};f.G=function(a){(this.h=a)?this.Yb=!0:this.g.popup.startHideTimer();bg(this);this.Ja=!0};
function ag(a,b,c){a=a.Jb(b,c);if(0<a.length)return a[0]}
f.Jb=function(a,b){var c=[],d=this;w(this.Za,function(e){var g;g=d.oa[Ed(e.shapes[0])];if("rect"==g.type)g=a<g.geometry.x||b<g.geometry.y||a>g.geometry.x+g.geometry.width||b>g.geometry.y+g.geometry.height?!1:!0;else if("polygon"==g.type){g=g.geometry.points;for(var h=!1,k=g.length-1,l=0;l<g.length;l++)g[l].y>b!=g[k].y>b&&a<(g[k].x-g[l].x)*(b-g[l].y)/(g[k].y-g[l].y)+g[l].x&&(h=!h),k=l;g=h}else g=!1;g&&c.push(e)});Qa(c,function(a,b){var c=d.oa[Ed(a.shapes[0])],k=d.oa[Ed(b.shapes[0])];return pd(c)-pd(k)});
return c};function cg(a,b,c){var d=Ha(a.g.Da(),function(a){return a.getSupportedShapeType()==b.type});d?d.drawShape(a.Ka,b,c):console.log("WARNING unsupported shape type: "+b.type)}function bg(a){a.Ka.clearRect(0,0,a.ga.width,a.ga.height);w(a.Za,function(b){b!=a.h&&cg(a,a.oa[Ed(b.shapes[0])])});if(a.h){var b=a.oa[Ed(a.h.shapes[0])];cg(a,b,!0);b=Bd(b).geometry;a.g.popup.show(a.h,new T(b.x,b.y+b.height+5))}};var dg="ontouchstart"in window,Uf=!dg,Xf=dg?"touchstart":"mousedown",eg=dg?"touchenter":"mouseover",$f=dg?"touchmove":"mousemove",fg=dg?"touchend":"mouseup",gg=dg?"touchleave":"mouseout";function Yf(a,b){var c=!1;a.offsetX=a.offsetX?a.offsetX:!1;a.offsetY=a.offsetY?a.offsetY:!1;return c=a.offsetX&&a.offsetY||!a.T.changedTouches?{x:a.offsetX,y:a.offsetY}:{x:a.T.changedTouches[0].clientX-cd(b).left,y:a.T.changedTouches[0].clientY-cd(b).top}};function hg(){}f=hg.prototype;f.init=function(a,b){this.Ad="#000000";this.Cd="#ffffff";this.ud=!1;this.wd="#000000";this.yd="#fff000";this.vd=!1;this.xd=this.Dd=this.Bd=1;this.zd=1.2;this.ga=b;this.g=a;this.Ka=b.getContext("2d");this.Ka.lineWidth=1;this.Ic=!1};
f.Ec=function(){var a=this,b=this.ga;this.Kc=M(this.ga,$f,function(c){c=Yf(c,b);if(a.Ic){a.P={x:c.x,y:c.y};a.Ka.clearRect(0,0,b.width,b.height);c=a.P.x-a.Z.x;var d=a.P.y-a.Z.y;a.drawShape(a.Ka,{type:"rect",geometry:{x:0<c?a.Z.x:a.P.x,y:0<d?a.Z.y:a.P.y,width:Math.abs(c),height:Math.abs(d)},style:{}})}});this.Lc=M(b,fg,function(c){var d=Yf(c,b),e=a.getShape();c=c.T?c.T:c;a.Ic=!1;e?(a.Xb(),a.g.fireEvent("onSelectionCompleted",{mouseEvent:c,shape:e,viewportBounds:a.getViewportBounds()})):(a.g.fireEvent("onSelectionCanceled"),
c=a.g.Jb(d.x,d.y),0<c.length&&a.g.G(c[0]))})};f.Xb=function(){this.Kc&&(N(this.Kc),delete this.Kc);this.Lc&&(N(this.Lc),delete this.Lc)};f.getName=function(){return"rect_drag"};f.getSupportedShapeType=function(){return"rect"};
f.wa=function(a){a.hasOwnProperty("outline")&&(this.Ad=a.outline);a.hasOwnProperty("stroke")&&(this.Cd=a.stroke);a.hasOwnProperty("fill")&&(this.ud=a.fill);a.hasOwnProperty("hi_outline")&&(this.wd=a.hi_outline);a.hasOwnProperty("hi_stroke")&&(this.yd=a.hi_stroke);a.hasOwnProperty("hi_fill")&&(this.vd=a.hi_fill);a.hasOwnProperty("outline_width")&&(this.Bd=a.outline_width);a.hasOwnProperty("stroke_width")&&(this.Dd=a.stroke_width);a.hasOwnProperty("hi_outline_width")&&(this.xd=a.hi_outline_width);a.hasOwnProperty("hi_stroke_width")&&
(this.zd=a.hi_stroke_width)};f.startSelection=function(a,b){var c={x:a,y:b};this.Ic=!0;this.Ec(c);this.Z=new T(a,b);this.g.fireEvent("onSelectionStarted",{offsetX:a,offsetY:b});O(document.body,"-webkit-user-select","none")};f.stopSelection=function(){this.Xb();this.Ka.clearRect(0,0,this.ga.width,this.ga.height);O(document.body,"-webkit-user-select","auto");delete this.P};
f.getShape=function(){if(this.P&&3<Math.abs(this.P.x-this.Z.x)&&3<Math.abs(this.P.y-this.Z.y)){var a=this.getViewportBounds(),a=this.g.Cc({x:a.left,y:a.top,width:a.right-a.left,height:a.bottom-a.top});return new od("rect",a)}};f.getViewportBounds=function(){var a,b;this.P.x>this.Z.x?(a=this.P.x,b=this.Z.x):(a=this.Z.x,b=this.P.x);var c,d;this.P.y>this.Z.y?(c=this.Z.y,d=this.P.y):(c=this.P.y,d=this.Z.y);return{top:c,right:a,bottom:d,left:b}};
f.drawShape=function(a,b,c){var d,e,g,h;b.style||(b.style={});"rect"==b.type&&(c?(d=b.style.hi_fill||this.vd,c=b.style.hi_stroke||this.yd,e=b.style.hi_outline||this.wd,g=b.style.hi_outline_width||this.xd,h=b.style.hi_stroke_width||this.zd):(d=b.style.fill||this.ud,c=b.style.stroke||this.Cd,e=b.style.outline||this.Ad,g=b.style.outline_width||this.Bd,h=b.style.stroke_width||this.Dd),b=b.geometry,e&&(a.lineJoin="round",a.lineWidth=g,a.strokeStyle=e,a.strokeRect(b.x+g/2,b.y+g/2,b.width-g,b.height-g)),
c&&(a.lineJoin="miter",a.lineWidth=h,a.strokeStyle=c,a.strokeRect(b.x+g+h/2,b.y+g+h/2,b.width-2*g-h,b.height-2*g-h)),d&&(a.lineJoin="miter",a.lineWidth=h,a.fillStyle=d,a.fillRect(b.x+g+h/2,b.y+g+h/2,b.width-2*g-h,b.height-2*g-h)))};function ig(a){return Df('\x3ccanvas class\x3d"annotorious-item annotorious-opacity-fade" style\x3d"position:absolute; top:0px; left:0px; width:'+Ff(Kf(a.width))+"px; height:"+Ff(Kf(a.height))+'px; z-index:0" width\x3d"'+Ff(a.width)+'" height\x3d"'+Ff(a.height)+'"\x3e\x3c/canvas\x3e')}
function Rf(a){return Df('\x3cdiv class\x3d"annotorious-hint" style\x3d"white-space:nowrap; position:absolute; top:0px; left:0px; pointer-events:none;"\x3e\x3cdiv class\x3d"annotorious-hint-msg annotorious-opacity-fade"\x3e'+Cf(a.qc)+'\x3c/div\x3e\x3cdiv class\x3d"annotorious-hint-icon" style\x3d"pointer-events:auto"\x3e\x3c/div\x3e\x3c/div\x3e')};function W(a,b){this.na=a;this.Nd={padding:a.style.padding,margin:a.style.margin};this.L=new fd;this.Aa=[];this.Zb=!0;this.element=xb("div","annotorious-annotationlayer");O(this.element,"position","relative");O(this.element,"display","inline-block");jg(a,this.element);Bb(this.element,a);this.element.appendChild(a);var c=Lc(a);this.Ba=Xd(ig,{width:c.width,height:c.height});Uf&&Pd(this.Ba,"annotorious-item-unfocus");this.element.appendChild(this.Ba);this.f=Xd(ig,{width:c.width,height:c.height});Uf&&
R(this.f,!1);this.element.appendChild(this.f);this.popup=b?b:new Tf(this);c=new hg;c.init(this,this.f);this.Aa.push(c);this.K=c;this.editor=new Pf(this);this.m=new Zf(this.Ba,this);this.vb=new Qf(this,this.element);var d=this;Uf&&(M(this.element,eg,function(a){a=a.relatedTarget;a&&Gb(d.element,a)||(d.L.fireEvent("onMouseOverItem"),Sd(d.Ba,"annotorious-item-unfocus","annotorious-item-focus"))}),M(this.element,gg,function(a){a=a.relatedTarget;a&&Gb(d.element,a)||(d.L.fireEvent("onMouseOutOfItem"),Sd(d.Ba,
"annotorious-item-focus","annotorious-item-unfocus"))}));Wf(this,dg?this.f:this.Ba);this.L.o("onSelectionCompleted",function(a){var b=a.viewportBounds;d.editor.setPosition(new T(b.left+d.na.offsetLeft,b.bottom+4+d.na.offsetTop));d.editor.open(!1,a)});this.L.o("onSelectionCanceled",function(){Uf&&R(d.f,!1);d.K.stopSelection()})}u(W,Vf);
function jg(a,b){function c(c,d){O(b,"margin-"+c,d+"px");O(a,"margin-"+c,0);O(a,"padding-"+c,0)}var d=Qc(a,"margin"),e=Qc(a,"padding");0==d.top&&0==e.top||c("top",d.top+e.top);0==d.right&&0==e.right||c("right",d.right+e.right);0==d.bottom&&0==e.bottom||c("bottom",d.bottom+e.bottom);0==d.left&&0==e.left||c("left",d.left+e.left)}f=W.prototype;f.pa=function(){};f.Pd=function(a){a.init(this,this.f);this.Aa.push(a)};
f.F=function(){var a=this.na;a.style.margin=this.Nd.margin;a.style.padding=this.Nd.padding;Bb(a,this.element)};
f.Wc=function(a){this.m.O(a);var b=Ha(this.Aa,function(b){return b.getSupportedShapeType()==a.shapes[0].type});if(b){R(this.f,!0);this.m.G(!1);var c=this.f.getContext("2d"),d=a.shapes[0],e=this,d="pixel"==d.units?d:Dd(d,function(a){return e.Ra(a)});b.drawShape(c,d)}b=Bd(a.shapes[0]).geometry;b="pixel"==a.shapes[0].units?new T(b.x,b.y+b.height):this.Ra(new T(b.x,b.y+b.height));this.editor.setPosition(new T(b.x+this.na.offsetLeft,b.y+4+this.na.offsetTop));this.editor.open(a)};
f.Ra=function(a){var b=Jc(this.na);return a.width?{x:a.x*b.width,y:a.y*b.height,width:a.width*b.width,height:a.height*b.height}:{x:a.x*b.width,y:a.y*b.height}};f.Ca=function(){return this.K};f.I=function(){return this.m.I()};f.Jb=function(a,b){return Ja(this.m.Jb(a,b))};f.Da=function(){return this.Aa};f.getItem=function(){return{src:kg(this.na),element:this.na}};function kg(a){var b=a.getAttribute("data-original");return b?b:a.src}f.ua=function(){R(this.Ba,!1)};
f.aa=function(){this.Zb=!1;this.vb&&(this.vb.F(),delete this.vb)};f.je=function(a){(this.K=Ha(this.Aa,function(b){return b.getName()==a}))||console.log('WARNING: selector "'+a+'" not available')};f.wa=function(a){w(this.Aa,function(b){b.wa(a)});bg(this.m)};f.Xa=function(){R(this.Ba,!0)};f.ma=function(){this.Zb=!0;this.vb||(this.vb=new Qf(this,this.element))};f.stopSelection=function(a){Uf&&R(this.f,!1);this.K.stopSelection();a&&this.m.V(a)};
f.Cc=function(a){var b=Jc(this.na);return a.width?{x:a.x/b.width,y:a.y/b.height,width:a.width/b.width,height:a.height/b.height}:{x:a.x/b.width,y:a.y/b.height}};W.prototype.addSelector=W.prototype.Pd;W.prototype.fireEvent=W.prototype.fireEvent;W.prototype.setCurrentSelector=W.prototype.je;W.prototype.toItemCoordinates=W.prototype.Cc;function lg(){Hd(this,function(){return I("img.annotatable",document)})}u(lg,Gd);lg.prototype.jc=function(a){return kg(a)};lg.prototype.ld=function(a){return new W(a)};lg.prototype.supports=function(a){return Cb(a)?"IMG"==a.tagName:!1};function mg(a){return Df('\x3cdiv class\x3d"annotorious-opacity-fade" style\x3d"white-space:nowrap; position:absolute; pointer-events:none; top:80px; width:100%; text-align:center;"\x3e\x3cdiv class\x3d"annotorious-ol-hint" style\x3d"width: 400px; margin:0px auto;"\x3e'+Cf(a.qc)+"\x3c/dvi\x3e\x3c/div\x3e")};function ng(a,b){this.ha=a;this.da=Lc(b.element);this.A=b.popup;O(this.A.element,"z-index",99E3);this.M=[];this.Ub=new OpenLayers.gf.ff("Annotorious");this.ha.jf(this.Ub);var c=this;this.ha.nf.register("move",this.ha,function(){c.U&&c.wb()});b.o("beforePopupHide",function(){c.La==c.U?c.A.clearHideTimer():c.Ab(c.La,c.U)})}f=ng.prototype;f.F=function(){this.Ub.F()};
f.wb=function(){var a=this.U.Rb.ra,b=Lc(a),c=Gc(a,this.ha.ra),a=c.y,c=c.x,d=b.width,e=b.height,b=Lc(this.A.element),a={y:a+e+5};c+b.width>this.da.width?(Sd(this.A.element,"top-left","top-right"),a.x=c+d-b.width):(Sd(this.A.element,"top-right","top-left"),a.x=c);0>a.x&&(a.x=0);a.x+b.width>this.da.width&&(a.x=this.da.width-b.width);a.y+b.height>this.da.height&&(a.y=this.da.height-b.height);this.A.setPosition(a)};f.Oc=function(a){this.A.setAnnotation(a);this.wb();this.A.show()};
f.Ab=function(a,b){a?(Gc(a.Rb.ra,this.ha.ra),Bc(a.Rb.ra,"height"),O(a.Qb,"border-color","#fff000"),this.U=a,this.Oc(a.R)):delete this.U;b&&O(b.Qb,"border-color","#fff")};
f.V=function(a){var b=a.shapes[0].geometry,b=new OpenLayers.hf.ef(new OpenLayers.df(b.x,b.y,b.x+b.width,b.y+b.height));Pd(b.ra,"annotorious-ol-boxmarker-outer");O(b.ra,"border",null);var c=xb("div","annotorious-ol-boxmarker-inner");Ic(c,"100%","100%");b.ra.appendChild(c);var d={R:a,Rb:b,Qb:c},e=this;M(c,"mouseover",function(){e.U||e.Ab(d);e.La=d});M(c,"mouseout",function(){delete e.La;e.A.startHideTimer()});this.M.push(d);Qa(this.M,function(a,b){return pd(b.R.shapes[0])-pd(a.R.shapes[0])});var g=
1E4;w(this.M,function(a){O(a.Rb.ra,"z-index",g);g++});this.Ub.kf(b)};f.O=function(a){var b=Ha(this.M,function(b){return b.R==a});b&&(y(this.M,b),this.Ub.qf(b.Rb))};f.I=function(){return Fa(this.M,function(a){return a.R})};f.G=function(a){a||this.A.startHideTimer()};function og(a){function b(){var a=parseInt(P(d.element,"width"),10),b=parseInt(P(d.element,"height"),10);Ic(d.f,a,b);d.f.width=a;d.f.height=b}this.ha=a;this.element=a.ra;var c=Bc(this.element,"position");"absolute"!=c&&"relative"!=c&&O(this.element,"position","relative");this.L=new fd;this.fa=Xd(mg,{qc:"Click and Drag"});O(this.fa,"z-index",9998);Q(this.fa,0);this.element.appendChild(this.fa);this.popup=new Tf(this);this.m=new ng(a,this);this.f=Xd(ig,{width:"0",height:"0"});R(this.f,!1);O(this.f,
"position","absolute");O(this.f,"top","0px");O(this.f,"z-index",9999);this.element.appendChild(this.f);var d=this;b();this.K=new hg;this.K.init(this,this.f);this.zb=void 0;this.editor=new Pf(this);O(this.editor.element,"z-index",1E4);window.addEventListener?window.addEventListener("resize",b,!1):window.attachEvent&&window.attachEvent("onresize",b);M(this.element,"mouseover",function(a){(a=a.relatedTarget)&&Gb(d.element,a)||d.L.fireEvent("onMouseOverItem")});M(this.element,"mouseout",function(a){(a=
a.relatedTarget)&&Gb(d.element,a)||d.L.fireEvent("onMouseOutOfItem")});M(this.f,"mousedown",function(a){var b=Hc(d.element);d.K.startSelection(a.clientX-b.x,a.clientY-b.y)});this.L.o("onSelectionCompleted",function(a){O(d.f,"pointer-events","none");a=a.viewportBounds;d.editor.setPosition(new T(a.left,a.bottom+4));d.editor.open()});this.L.o("onSelectionCanceled",function(){d.stopSelection()})}u(og,Vf);f=og.prototype;f.ma=function(){};f.aa=function(){};
f.pa=function(a){O(this.f,"pointer-events","auto");var b=this;R(this.f,!0);Q(this.fa,.8);window.setTimeout(function(){Q(b.fa,0)},2E3);a&&(this.zb=a)};f.F=function(){this.m.F();Ab(this.fa);Ab(this.f)};f.Pd=function(){};f.Wc=function(a){this.m.O(a);var b=this.K,c=this;if(b){R(this.f,!0);this.m.G(void 0);var d=this.f.getContext("2d"),e=Dd(a.shapes[0],function(a){return c.Ra(a)});console.log(e);b.drawShape(d,e);b=Bd(e).geometry;this.editor.setPosition(new T(b.x,b.y+b.height));this.editor.open(a)}};
f.Ra=function(a){var b=this.ha.Fe(new OpenLayers.re(a.x,a.y));return(a=a.width?this.ha.Fe(new OpenLayers.re(a.x+a.width,a.y+a.height)):!1)?{x:b.x,y:a.y,width:a.x-b.x+2,height:b.y-a.y+2}:{x:b.x,y:b.y}};f.I=function(){return this.m.I()};f.Da=function(){};f.getItem=function(){return{src:"map://openlayers/something"}};f.Sb=function(){};
f.Cc=function(a){var b=this.ha.Ee(new OpenLayers.se(a.x,a.y));return(a=a.width?new OpenLayers.se(a.x+a.width-2,a.y+a.height-2):!1)?(a=this.ha.Ee(a),b={x:b.hd,y:a.fd,width:a.hd-b.hd,height:b.fd-a.fd},console.log(b),b):{x:b.hd,y:b.fd}};function pg(){Hd(this)}u(pg,Gd);pg.prototype.jc=function(){return"map://openlayers/something"};pg.prototype.ld=function(a){return new og(a)};pg.prototype.supports=function(a){return a instanceof OpenLayers.Map};function qg(a,b){this.ea=a;this.da=Lc(a.element);this.A=b.popup;O(this.A.element,"z-index",99E3);this.M=[];var c=this;this.ea.o("animation",function(){c.U&&c.wb()});b.o("beforePopupHide",function(){c.La==c.U?c.A.clearHideTimer():c.Ab(c.La,c.U)})}f=qg.prototype;
f.wb=function(){var a=this.ea.element,b=this.U.vc,c=Lc(b),b=Gc(b,a),a=b.y,b=b.x,d=c.width,e=c.height,c=Lc(this.A.element),a={x:b,y:a+e+12};Sd(this.A.element,"top-right","top-left");this.ea.of()||(b+c.width>this.da.width&&(Sd(this.A.element,"top-left","top-right"),a.x=b+d-c.width),0>a.x&&(a.x=0),a.x+c.width>this.da.width&&(a.x=this.da.width-c.width),a.y+c.height>this.da.height&&(a.y=this.da.height-c.height));this.A.setPosition(a)};f.Oc=function(a){this.A.setAnnotation(a);this.wb();this.A.show()};
f.Ab=function(a,b){a?(O(a.Qb,"border-color","#fff000"),this.U=a,this.Oc(a.R)):delete this.U;b&&O(b.Qb,"border-color","#fff")};
f.V=function(a){var b=a.shapes[0].geometry,c=xb("div","annotorious-ol-boxmarker-outer"),d=xb("div","annotorious-ol-boxmarker-inner");Ic(d,"100%","100%");c.appendChild(d);var b=new OpenSeadragon.Rect(b.x,b.y,b.width,b.height),e={R:a,vc:c,Qb:d},g=this;M(d,"mouseover",function(){g.U||g.Ab(e);g.La=e});M(d,"mouseout",function(){delete g.La;g.A.startHideTimer()});this.M.push(e);Qa(this.M,function(a,b){return pd(b.R.shapes[0])-pd(a.R.shapes[0])});var h=1;w(this.M,function(a){O(a.vc,"z-index",h);h++});this.ea.De.lf(c,
b)};f.O=function(a){var b=Ha(this.M,function(b){return b.R==a});b&&(y(this.M,b),this.ea.De.Ye(b.vc))};f.I=function(){return Fa(this.M,function(a){console.log(a);return a.R})};f.G=function(){};f.F=function(){var a=this;w(this.M,function(b){a.ea.Ye(b.vc)});this.M=[]};function rg(a){this.element=a.element;O(tb(),"z-index",0);this.ea=a;this.L=new fd;this.Aa=[];this.Zb=!0;this.fa=Xd(mg,{qc:"Click and Drag"});Q(this.fa,0);this.element.appendChild(this.fa);this.popup=new Tf(this);this.m=new qg(a,this);this.f=Xd(ig,{width:"0",height:"0"});R(this.f,!1);this.element.appendChild(this.f);var b=this;(function(){var a=parseInt(P(b.element,"width"),10),d=parseInt(P(b.element,"height"),10);Ic(b.f,a,d);b.f.width=a;b.f.height=d})();a=new hg;a.init(this,this.f);this.Aa.push(a);
this.K=a;this.editor=new Pf(this);Wf(this,this.f);this.L.o("onSelectionCompleted",function(a){a=a.viewportBounds;b.editor.setPosition(new T(a.left,a.bottom+4));b.editor.open()});this.L.o("onSelectionCanceled",function(){b.stopSelection()})}u(rg,Vf);f=rg.prototype;f.ma=function(){};f.aa=function(){};f.F=function(){this.m.F();delete this.m};f.pa=function(a){O(this.f,"pointer-events","auto");var b=this;R(this.f,!0);Q(this.fa,.8);window.setTimeout(function(){Q(b.fa,0)},2E3);a&&(this.zb=a)};
f.Wc=function(a){this.m.O(a);var b=this.K,c=this;if(b){R(this.f,!0);this.m.G(void 0);var d=this.f.getContext("2d"),e=Dd(a.shapes[0],function(a){return c.Ra(a)});b.drawShape(d,e);b=Bd(e).geometry;this.editor.setPosition(new T(b.x,b.y+b.height+4));this.editor.open(a)}};
f.Ra=function(a){var b=cd(this.element);b.top+=window.pageYOffset;b.left+=window.pageXOffset;var c=new OpenSeadragon.Dc(a.x,a.y);a=a.width?new OpenSeadragon.Dc(a.x+a.width,a.y+a.height):!1;c=this.ea.viewport.bf(c);return a?(a=this.ea.viewport.bf(a),{x:c.x-b.left,y:c.y-b.top,width:a.x-c.x+2,height:a.y-c.y+2}):c};f.I=function(){return this.m.I()};f.Da=function(){};f.getItem=function(){return{src:"dzi://openseadragon/something"}};f.Sb=function(){};f.Ca=function(){return this.K};
f.Cc=function(a){var b=cd(this.element);b.top+=window.pageYOffset;b.left+=window.pageXOffset;var c=new OpenSeadragon.Dc(a.x+b.left,a.y+b.top);a=a.width?new OpenSeadragon.Dc(a.x+b.left+a.width-2,a.y+b.top+a.height-2):!1;c=this.ea.viewport.cf(c);return a?(a=this.ea.viewport.cf(a),{x:c.x,y:c.y,width:a.x-c.x,height:a.y-c.y}):c};function sg(){Hd(this)}u(sg,Gd);sg.prototype.jc=function(){return"dzi://openseadragon/something"};sg.prototype.ld=function(a){return new rg(a)};sg.prototype.supports=function(a){return a.id&&0==a.id.indexOf("openseadragon")&&a.hasOwnProperty("drawer")?!0:!1};function X(){this.Id=!1;this.B=[new lg];window.OpenLayers&&this.B.push(new pg);window.OpenSeadragon&&this.B.push(new sg);this.xb=[];var a=this;dd(function(){tg(a)})}function tg(a){a.Id||(w(a.B,function(a){a.init()}),w(a.xb,function(b){b.initPlugin&&b.initPlugin(a);w(a.B,function(a){a.$b(b)})}),a.Id=!0)}function Y(a,b){return Ha(a.B,function(a){return Nd(a,b)})}f=X.prototype;f.pa=function(a,b){var c=void 0,d=void 0;p(a)?(c=a,d=b):r(a)&&(d=a);if(c){var e=Y(this,c);e&&e.pa(c,d)}else w(this.B,function(a){a.pa(d)})};
f.V=function(a,b){var c;c=a.src;if(!(0<c.indexOf("://"))){var d=document.createElement("a");d.href=c;c=d.protocol+"//"+d.host+d.pathname}a.src=c;(c=Y(this,a.src))&&c.V(a,b)};f.o=function(a,b){w(this.B,function(c){c.o(a,b)})};f.$b=function(a,b){try{var c=new window.annotorious.plugin[a](b);"complete"==document.readyState?(c.initPlugin&&c.initPlugin(this),w(this.B,function(a){a.$b(c)})):this.xb.push(c)}catch(d){console.log("Could not load plugin: "+a)}};
f.F=function(a){if(a){var b=Y(this,a);b&&b.F(a)}else w(this.B,function(a){a.F()})};f.Ca=function(a){var b=Y(this,a);if(b)return b.Ca(a)};f.I=function(a){if(a){var b=Y(this,a);return b?b.I(a):[]}var c=[];w(this.B,function(a){Ka(c,a.I())});return c};f.Da=function(a){var b=Y(this,a);return b?b.Da(a):[]};f.ua=function(a){if(a){var b=Y(this,a);b&&b.ua(a)}else w(this.B,function(a){a.ua()})};f.aa=function(a){if(a){var b=Y(this,a);b&&b.aa(a)}else w(this.B,function(a){a.aa()})};
f.stopSelection=function(a){if(a){var b=Y(this,a);b&&b.stopSelection(a)}else w(this.B,function(a){a.stopSelection()})};f.G=function(a){if(a){var b=Y(this,a.src);b&&b.G(a)}else w(this.B,function(a){a.G()})};f.jd=function(a){tg(this);var b=Ha(this.B,function(b){return b.supports(a)});if(b)b.jd(a);else throw"Error: Annotorious does not support this media type in the current version or build configuration.";};f.Ha=function(a){var b=this;w(this.I(a),function(a){b.O(a)})};
f.O=function(a){var b=Y(this,a.src);b&&b.O(a)};f.reset=function(){w(this.B,function(a){a.F();a.init()})};f.Sb=function(a,b){var c=Y(this,a);c&&c.Sb(a,b)};f.wa=function(a){w(this.B,function(b){b.wa(a)})};f.$e=function(a){a?this.ma(void 0):this.aa(void 0)};f.Xa=function(a){if(a){var b=Y(this,a);b&&b.Xa(a)}else w(this.B,function(a){a.Xa()})};f.ma=function(a){if(a){var b=Y(this,a);b&&b.ma(a)}else w(this.B,function(a){a.ma()})};window.anno=new X;X.prototype.activateSelector=X.prototype.pa;X.prototype.addAnnotation=X.prototype.V;X.prototype.addHandler=X.prototype.o;X.prototype.addPlugin=X.prototype.$b;X.prototype.destroy=X.prototype.F;X.prototype.getActiveSelector=X.prototype.Ca;X.prototype.getAnnotations=X.prototype.I;X.prototype.getAvailableSelectors=X.prototype.Da;X.prototype.hideAnnotations=X.prototype.ua;X.prototype.hideSelectionWidget=X.prototype.aa;X.prototype.highlightAnnotation=X.prototype.G;X.prototype.makeAnnotatable=X.prototype.jd;
X.prototype.removeAll=X.prototype.Ha;X.prototype.removeAnnotation=X.prototype.O;X.prototype.reset=X.prototype.reset;X.prototype.setActiveSelector=X.prototype.Sb;X.prototype.setProperties=X.prototype.wa;X.prototype.showAnnotations=X.prototype.Xa;X.prototype.showSelectionWidget=X.prototype.ma;window.annotorious||(window.annotorious={});window.annotorious.plugin||(window.annotorious.plugin={});
window.annotorious.geometry||(window.annotorious.geometry={},window.annotorious.geometry.expand=Cd,window.annotorious.geometry.getBoundingRect=Bd);X.prototype.setSelectionEnabled=X.prototype.$e;
})();